/*
Theme Name: kuijstransport
Theme URI: https://kuijs-transport.nl
Author: BlueCT Site Factory
Description: Maatwerk classic PHP theme voor Int. Transportbedrijf Kuijs B.V. Layout in PHP, content in SCF.
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: kuijstransport
*/

/* ============================================================
   DESIGN TOKENS
   Brand red #dd3333 (accents/fills/icons, 3:1) | charcoal #202020
   Darkened reds for small text + button fills (4.5:1 verified)
   ============================================================ */
:root {
  --brand: #dd3333;          /* fills, borders, icons, large headings (>=3:1) */
  --brand-dark: #b21717;     /* button fill — white text = ~7:1 */
  --brand-hover: #cf1f1f;    /* button hover — white text = ~5.4:1 */
  --accent-text: #bf1d1d;    /* SMALL accent text on light bg — ~6.2:1 */
  --ink: #202020;            /* headings + body text */
  --muted: #4a4a4a;          /* secondary text — ~8.8:1 on white */
  --bg: #ffffff;
  --bg-alt: #f5f5f5;
  --bg-dark: #202020;
  --on-dark: #ffffff;
  --on-dark-muted: #d8d8d8;  /* ~11:1 on charcoal */
  --line: #e2e2e2;
  --line-dark: #3a3a3a;

  --maxw: 1280px;
  --prose: 760px;
  --radius: 10px;
  --shadow: 0 6px 24px rgba(0,0,0,.08);
  --shadow-lift: 0 14px 38px rgba(0,0,0,.14);

  --font-head: "Poppins", system-ui, "Segoe UI", sans-serif;
  --font-body: "Roboto", system-ui, "Segoe UI", sans-serif;

  --step: clamp(2.5rem, 6vw, 5rem);
}

/* ============================================================
   RESET / BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-text); }
a:hover { color: var(--brand-hover); }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.18; font-weight: 700; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); letter-spacing: -.01em; }
h3 { font-size: clamp(1.2rem, 2.2vw, 1.45rem); }
p { margin: 0 0 1rem; }
ul, ol { margin: 0 0 1rem; padding-left: 1.25rem; }

/* ============================================================
   LAYOUT PRIMITIVES
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1rem, 5vw, 2rem);
}
.section { padding-block: var(--step); }
.section--alt { background: var(--bg-alt); }
.section--dark { background: var(--bg-dark); color: var(--on-dark); }
.section--dark h1, .section--dark h2, .section--dark h3 { color: var(--on-dark); }
.section--dark p { color: var(--on-dark-muted); }

/* Long-form prose measure — ONLY applied to genuinely long bodies */
.prose--longform { max-width: var(--prose); }
.prose--longform > * { max-width: 100%; }
.prose--longform img { border-radius: var(--radius); margin-block: 1.5rem; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent-text);   /* dark red — small text, needs 4.5:1 */
  margin-bottom: .75rem;
}
.section--dark .eyebrow,
.hero .eyebrow { color: #ff9d9d; } /* light red on charcoal/hero — high contrast */
.lead { font-size: 1.2rem; color: var(--muted); max-width: 60ch; }
.section--dark .lead { color: var(--on-dark-muted); }
.section__head { margin-bottom: 2.5rem; }
.text-center { text-align: center; }
.center-col { margin-inline: auto; }

/* ============================================================
   BUTTONS — every variant's label verified >=4.5:1 on its bg
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: .9rem 1.6rem;
  border-radius: 999px;
  border: 2px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform .25s ease, background-color .25s ease, color .25s ease, box-shadow .25s ease;
}
.btn--primary { background: var(--brand-dark); color: #fff; }   /* white on #b21717 ~7:1 */
.btn--primary:hover { background: var(--brand-hover); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-lift); }
/* Outline variant: dark-red label + border on LIGHT backgrounds only */
.btn--outline { background: transparent; color: var(--accent-text); border-color: var(--brand); }
.btn--outline:hover { background: var(--brand-dark); color: #fff; border-color: var(--brand-dark); transform: translateY(-2px); }
/* On dark sections: white-bordered ghost with white label (white on charcoal ~16:1) */
.btn--ghost-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.btn--ghost-light:hover { background: #fff; color: var(--ink); border-color: #fff; transform: translateY(-2px); }

/* ============================================================
   HEADER / NAV
   ============================================================ */
.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 1000;
  background: var(--ink); color: #fff; padding: .75rem 1.25rem; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

.site-header {
  position: sticky; top: 0; z-index: 100;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 76px;
}
.site-logo img { max-height: 48px; width: auto; }
.site-logo .logo-text { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; color: var(--ink); text-decoration: none; }

.header-nav-wrap { display: flex; align-items: center; gap: 1.5rem; }
.primary-nav ul { list-style: none; display: flex; gap: 1.6rem; margin: 0; padding: 0; }
.primary-nav a {
  font-family: var(--font-head); font-weight: 500; font-size: 1rem;
  color: var(--ink); text-decoration: none; padding: .35rem 0;
  position: relative;
}
.primary-nav a:hover, .primary-nav .current-menu-item > a { color: var(--accent-text); }
.primary-nav a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: -2px; height: 2px;
  background: var(--brand); transition: right .25s ease;
}
.primary-nav a:hover::after, .primary-nav .current-menu-item > a::after { right: 0; }
.header-cta { white-space: nowrap; }

.nav-toggle {
  display: none;
  width: 46px; height: 46px;
  border: 1px solid var(--line); border-radius: 8px;
  background: #fff; cursor: pointer; padding: 0;
  align-items: center; justify-content: center;
}
.nav-toggle .bar, .nav-toggle .bar::before, .nav-toggle .bar::after {
  display: block; width: 22px; height: 2px; background: var(--ink); position: relative; transition: transform .25s ease, opacity .25s ease;
}
.nav-toggle .bar::before, .nav-toggle .bar::after { content: ""; position: absolute; left: 0; }
.nav-toggle .bar::before { top: -7px; }
.nav-toggle .bar::after { top: 7px; }
.nav-toggle[aria-expanded="true"] .bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .bar::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bar::after { transform: translateY(-7px) rotate(-45deg); }

/* ============================================================
   HERO
   ============================================================ */
.hero { position: relative; background: var(--bg-dark); color: #fff; overflow: hidden; }
.hero__media { position: absolute; inset: 0; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; opacity: .42; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, rgba(20,20,20,.85), rgba(20,20,20,.45)); }
.hero__inner { position: relative; z-index: 2; padding-block: clamp(4rem, 11vw, 8rem); max-width: 760px; }
.hero h1 { color: #fff; }
.hero p { color: var(--on-dark-muted); font-size: 1.2rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 1.75rem; }
.hero--compact .hero__inner { padding-block: clamp(3rem, 8vw, 5.5rem); }

/* ============================================================
   GRIDS — cards / services / steps
   ============================================================ */
.grid { display: grid; gap: 1.75rem; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.75rem; box-shadow: var(--shadow);
  transition: transform .3s ease, box-shadow .3s ease;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.card .icon {
  width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(221,51,51,.12); color: var(--brand); margin-bottom: 1rem;
}
.card .icon svg { width: 26px; height: 26px; }
.card h3 { margin-bottom: .4rem; }
.card p { color: var(--muted); margin-bottom: 1rem; }
.card .card__link { margin-top: auto; font-family: var(--font-head); font-weight: 600; color: var(--accent-text); text-decoration: none; }
.card .card__link:hover { color: var(--brand-hover); }

/* Stat blocks */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.stat { text-align: center; }
.stat .num { font-family: var(--font-head); font-weight: 700; font-size: clamp(2rem, 4vw, 2.8rem); color: var(--brand); line-height: 1; }
.stat .lbl { color: var(--muted); font-size: .95rem; margin-top: .35rem; }
.section--dark .stat .lbl { color: var(--on-dark-muted); }
.section--dark .stat .num { color: #ff8a8a; }

/* Feature split */
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.split__media img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; object-fit: cover; }
.split--reverse .split__media { order: 2; }
.check-list { list-style: none; padding: 0; margin: 1.25rem 0 0; }
.check-list li { position: relative; padding-left: 2rem; margin-bottom: .8rem; }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: .28em; width: 20px; height: 20px;
  background: var(--brand); border-radius: 50%;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23fff' d='M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E") center/14px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23fff' d='M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E") center/14px no-repeat;
}

/* CTA band */
.cta-band { background: var(--brand-dark); color: #fff; border-radius: var(--radius); padding: clamp(2rem, 5vw, 3.25rem); text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.92); max-width: 56ch; margin-inline: auto; }
.cta-band .btn--ghost-light { margin-top: 1.25rem; }

/* ============================================================
   NEWS / POSTS
   ============================================================ */
.post-card { overflow: hidden; padding: 0; }
.post-card__media { aspect-ratio: 16/10; overflow: hidden; }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.post-card:hover .post-card__media img { transform: scale(1.04); }
.post-card__body { padding: 1.5rem; display: flex; flex-direction: column; flex: 1; }
.post-meta { font-size: .85rem; color: var(--muted); margin-bottom: .5rem; }
.post-card h3 { font-size: 1.25rem; }

/* Vacancy list */
.vac-list { display: grid; gap: 1.25rem; }
.vac-item {
  display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; justify-content: space-between;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow); transition: transform .3s ease, box-shadow .3s ease;
}
.vac-item:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.vac-item h3 { margin: 0 0 .3rem; }
.vac-tags { display: flex; flex-wrap: wrap; gap: .5rem .9rem; font-size: .9rem; color: var(--muted); }
.vac-tags span { display: inline-flex; align-items: center; gap: .35rem; }
.vac-tag-pill { background: var(--bg-alt); border-radius: 999px; padding: .25rem .75rem; }

/* ============================================================
   CONTACT
   ============================================================ */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 3.5rem); align-items: start; }
.info-list { list-style: none; padding: 0; margin: 0; }
.info-list li { display: flex; gap: .9rem; padding: .7rem 0; border-bottom: 1px solid var(--line); }
.info-list .ico { color: var(--brand); flex: none; margin-top: .15rem; }
.info-list a { color: var(--ink); text-decoration: none; }
.info-list a:hover { color: var(--accent-text); }
.info-card { background: var(--bg-alt); border-radius: var(--radius); padding: 1.75rem; }
.person { display: flex; gap: 1rem; align-items: center; margin-top: 1.5rem; }
.person img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.person .name { font-family: var(--font-head); font-weight: 600; }
.person .role { color: var(--muted); font-size: .92rem; }
.form-seam { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.75rem; box-shadow: var(--shadow); }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--bg-dark); color: var(--on-dark-muted); padding-block: clamp(3rem, 6vw, 4.5rem) 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 2rem; }
.site-footer h4 { color: #fff; font-size: 1.05rem; margin-bottom: 1rem; }
.site-footer a { color: var(--on-dark-muted); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-logo img { max-height: 46px; margin-bottom: 1rem; }
.footer-menu { list-style: none; padding: 0; margin: 0; }
.footer-menu li { margin-bottom: .55rem; }
.social-row { display: flex; gap: .75rem; margin-top: 1rem; }
.social-row a { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--line-dark); border-radius: 50%; color: var(--on-dark-muted); }
.social-row a:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
.social-row svg { width: 18px; height: 18px; }
.footer-bottom { border-top: 1px solid var(--line-dark); margin-top: 2.5rem; padding-top: 1.5rem; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; font-size: .85rem; }
.footer-bottom a { text-decoration: underline; }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .5s ease-out, transform .5s ease-out; }
.reveal.is-visible { opacity: 1; transform: none; }

:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 3px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .header-nav-wrap {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: .5rem 0 1rem;
    display: none;
  }
  .header-nav-wrap.is-open { display: flex; }
  .primary-nav ul { flex-direction: column; gap: 0; }
  .primary-nav a { display: block; padding: .85rem clamp(1rem, 5vw, 2rem); border-bottom: 1px solid var(--line); }
  .primary-nav a::after { display: none; }
  .header-cta { padding: .85rem clamp(1rem, 5vw, 2rem) 0; }
  .header-cta .btn { width: 100%; justify-content: center; }
  .split { grid-template-columns: 1fr; }
  .split--reverse .split__media { order: 0; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .grid--3, .grid--2 { grid-template-columns: 1fr; }
}

@media (max-width: 599px) {
  .grid, .stats, .vac-list { grid-template-columns: 1fr; align-items: stretch; }
  .grid > *, .stats > *, .vac-list > * { width: 100%; text-align: left; align-items: stretch; }
  .stat { text-align: left; }
  .hero__actions .btn, .cta-band .btn { width: 100%; justify-content: center; }
  .vac-item { flex-direction: column; align-items: stretch; }
}

/* ============================================================
   REDUCED MOTION — disable all motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
}
