/* Bens Airco Service, design 2 "Fris": Material 3 surfaces after the PAIR Guidebook / design.google.
   Tokens and rules: docs/designs/bensaircoservice-fris.md */
@font-face { font-family: "Google Sans Flex"; src: url(/fonts/google-sans-flex-latin.woff2) format("woff2"); font-weight: 300 800; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url(/fonts/space-grotesk-latin-500.woff2) format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --primary: #374C9F; --on-primary: #fff;
  --primary-container: #DDE1FF; --on-primary-container: #0B1A55;
  --hero: #28397A; --hero-speckle: #0F1B4A; --hero-button: #B9C3FF;
  --secondary-container: #DFE3F4;
  --tertiary: #9A432D; --tertiary-container: #FFDBD1;
  --background: #FDFDF5; --surface: #FAFAF2; --surface-low: #F4F4ED; --surface-mid: #EEEEE7;
  --inverse-surface: #2F312C;
  --on-surface: #1A1C18; --on-surface-variant: #45464F; --outline-variant: #C6C6D0;
  --riso-paper: #EFE6D4; --riso-orange: #D9531E; --riso-teal: #2A8CA3;

  --brand: var(--primary); --ink: var(--on-surface); --paper: var(--background);
  --font-body: "Google Sans Flex", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-head: var(--font-body);
  --font-label: "Space Grotesk", var(--font-body);
  --rail: 96px;
  --gutter: clamp(16px, 2vw, 24px);
  --max: var(--mmcms-max, 1120px);
  --r-xl: 24px; --r-l: 16px; --r-s: 8px;
  --focus: 3px solid var(--primary);
}

body { background: var(--background); color: var(--on-surface); font-size: 1rem; line-height: 1.5; }
h1, h2, h3 { font-weight: 400; letter-spacing: -.01em; }
a { color: var(--primary); }
.muted { color: var(--on-surface-variant); }
.ic, .shell svg, .rail svg, .bottomnav svg, .topbar svg { width: 1.25em; height: 1.25em; flex: none; }

/* ---------- chips & buttons ---------- */
.chip { display: inline-flex; align-items: center; gap: .3em; padding: .3rem .65rem; border-radius: var(--r-s); background: var(--surface);
        font: 500 .8125rem/1.2 var(--font-label); letter-spacing: .7px; text-transform: uppercase; color: var(--on-primary-container); }
.chip--warm { background: var(--tertiary-container); color: #3B0A00; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 48px; padding: 0 1.6rem; border: 0; border-radius: 9999px;
       font: 500 1rem/1 var(--font-body); letter-spacing: .01em; text-decoration: none; cursor: pointer; transition: background-color .2s, box-shadow .2s, color .2s; }
.btn--sm { min-height: 40px; padding: 0 1rem; font-size: .875rem; }
.btn--filled { background: var(--primary); color: var(--on-primary); }
.btn--filled:hover { background: color-mix(in oklch, var(--primary), black 12%); color: var(--on-primary); box-shadow: 0 1px 3px rgb(0 0 0 / .25); }
.btn--tonal { background: var(--primary-container); color: var(--on-primary-container); }
.btn--tonal:hover { background: color-mix(in oklch, var(--primary-container), var(--primary) 12%); color: var(--on-primary-container); }
.btn--hero { background: var(--hero-button); color: var(--on-primary-container); font-size: 1.15rem; min-height: 56px; padding: 0 2rem; }
.btn--hero:hover { background: color-mix(in oklch, var(--hero-button), white 25%); color: var(--on-primary-container); }
.btn--ghost { color: #fff; box-shadow: inset 0 0 0 1px rgb(255 255 255 / .55); }
.btn--ghost:hover { background: rgb(255 255 255 / .1); color: #fff; }

/* ---------- navigation rail (desktop) / top bar + bottom bar (mobile) ---------- */
.rail { display: none; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
          padding: 10px var(--gutter); background: color-mix(in srgb, var(--background) 92%, transparent); backdrop-filter: blur(8px); }
.top-logo img { height: 40px; width: auto; }
.bottomnav { position: fixed; inset: auto 0 0 0; z-index: 20; display: flex; justify-content: space-around; gap: 4px;
             padding: 12px 8px calc(12px + env(safe-area-inset-bottom)); background: var(--surface-mid); }
.bottomnav a, .rail li a { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 1; text-decoration: none; color: var(--on-surface-variant);
                           font-size: .75rem; font-weight: 500; }
.rail-ic svg { width: 24px; height: 24px; }
.rail-ic { display: grid; place-items: center; width: 56px; height: 32px; border-radius: 9999px; transition: background-color .2s; color: var(--on-surface); }
.bottomnav a:hover .rail-ic, .rail li a:hover .rail-ic { background: color-mix(in srgb, var(--on-surface) 8%, transparent); }
.bottomnav a[aria-current] .rail-ic, .rail a[aria-current] .rail-ic { background: var(--secondary-container); color: var(--on-primary-container); }
.bottomnav a[aria-current], .rail a[aria-current] { color: var(--on-surface); font-weight: 700; }
body { padding-bottom: calc(84px + env(safe-area-inset-bottom)); }

@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .topbar, .bottomnav { display: none; }
  .rail { position: fixed; inset: 0 auto 0 0; z-index: 20; width: var(--rail); display: flex; flex-direction: column; align-items: center; gap: 28px;
          padding: 20px 0 24px; background: var(--surface); border-right: 1px solid var(--surface-mid); }
  .rail-logo img { width: 72px; height: auto; }
  .rail ul { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 14px; }
  .rail li a { font-size: .72rem; text-align: center; line-height: 1.2; max-width: 84px; }
  .rail li a .rail-lb { padding: 0 4px; }
  .rail-fab { margin-top: auto; display: grid; place-items: center; width: 56px; height: 56px; border-radius: var(--r-l); background: var(--primary-container);
              color: var(--on-primary-container); box-shadow: 0 1px 3px rgb(0 0 0 / .2), 0 4px 8px rgb(0 0 0 / .08); transition: box-shadow .2s; }
  .rail-fab:hover { color: var(--on-primary-container); box-shadow: 0 2px 6px rgb(0 0 0 / .22), 0 8px 16px rgb(0 0 0 / .1); }
  .shell { margin-left: var(--rail); }
}

/* ---------- hero banner ---------- */
.shell { padding: 0 var(--gutter); }
main { padding-top: var(--gutter); }
.hero { position: relative; isolation: isolate; overflow: hidden; display: grid; align-items: center; gap: var(--gutter);
        min-height: clamp(220px, 40vh, 540px); padding: clamp(32px, 6vw, 88px) clamp(24px, 8vw, 220px) clamp(48px, 8vw, 110px);
        border-radius: var(--r-xl); background: var(--hero); color: #fff; }
/* Speckle texture (the Guidebook's ink splatter), densest at the bottom. */
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.32' numOctaves='4' seed='7'/%3E%3CfeColorMatrix values='0 0 0 0 .06 0 0 0 0 .1 0 0 0 0 .29 0 0 0 -16 8.6'/%3E%3C/filter%3E%3Crect width='600' height='600' filter='url(%23n)'/%3E%3C/svg%3E") 0 0 / 600px 600px;
  -webkit-mask: radial-gradient(120% 70% at 60% 115%, #000 30%, transparent 75%); mask: radial-gradient(120% 70% at 60% 115%, #000 30%, transparent 75%); }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(60% 60% at 15% 110%, color-mix(in srgb, var(--hero-speckle) 80%, transparent), transparent 70%); }
.hero h1 { font-size: clamp(2.1rem, 4.2vw, 3.1rem); line-height: 1.15; max-width: 22ch; margin: 0; }
.hero-kicker { margin: 0 0 1rem; font: 500 .8125rem/1.2 var(--font-label); letter-spacing: .7px; text-transform: uppercase; color: var(--hero-button); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 2rem; }
.hero--home { padding-right: clamp(24px, 4vw, 48px); }
.hero-photo { border-radius: var(--r-l); overflow: hidden; aspect-ratio: 4 / 3; box-shadow: 0 10px 30px rgb(0 0 0 / .25); }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) {
  .hero--home { grid-template-columns: 1.15fr 1fr; padding-left: clamp(32px, 6vw, 120px); }
}

/* ---------- pill tab bar ---------- */
.tabs { position: sticky; top: 64px; z-index: 10; margin: var(--gutter) 0 0; padding: 8px; border-radius: 9999px; background: var(--surface);
        border: 1px solid var(--surface-mid); box-shadow: 0 1px 2px rgb(0 0 0 / .12), 0 1px 3px 1px rgb(0 0 0 / .06); overflow-x: auto; scrollbar-width: none; }
.tabs ul { list-style: none; display: flex; justify-content: space-around; gap: 6px; margin: 0; padding: 0; }
.tabs a { display: block; white-space: nowrap; padding: .55rem 1.4rem; border-radius: 9999px; color: var(--on-surface); text-decoration: none; font-weight: 500; transition: background-color .2s; }
.tabs a:hover { background: color-mix(in srgb, var(--on-surface) 6%, transparent); color: var(--on-surface); }
.tabs a.is-on { background: var(--secondary-container); color: var(--on-primary-container); }
@media (min-width: 900px) { .tabs { top: 12px; } }

/* ---------- sections ---------- */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 clamp(0px, 4vw, 64px); }
.sec { padding-top: clamp(48px, 7vw, 96px); }
.sec > h2, .certs h2, .cta h2 { font-size: clamp(2rem, 3.6vw, 3rem); line-height: 1.12; margin: 0 0 clamp(24px, 3vw, 48px); }
.intro { display: grid; gap: 1.5rem 4rem; }
.intro .lead, .contact .lead { font-size: clamp(1.15rem, 1.4vw, 1.3rem); line-height: 1.45; }
.intro .rest { color: var(--on-surface-variant); }
.intro :where(p, li) { max-width: 62ch; }
@media (min-width: 900px) { .intro { grid-template-columns: 1.1fr 1fr; } .intro--one { grid-template-columns: minmax(0, 46rem); } }

/* riso illustration (design.google library hero) */
.riso { margin: clamp(48px, 7vw, 96px) 0 0; border-radius: 4px; overflow: hidden; background: var(--riso-paper); }
.riso svg { width: 100%; height: auto; }

/* principle rows (voordelen) */
.rows { list-style: none; margin: 0; padding: 12px; display: grid; gap: 0; border-radius: var(--r-xl); background: var(--secondary-container); counter-reset: none; }
.row { padding: 16px 20px 20px; border: 1px solid color-mix(in srgb, var(--on-surface) 55%, transparent); border-radius: var(--r-l); background: var(--secondary-container); }
.row + .row { margin-top: -1px; }
.row:first-child { border-radius: var(--r-l) var(--r-l) 4px 4px; } .row:last-child { border-radius: 4px 4px var(--r-l) var(--r-l); }
.row:not(:first-child):not(:last-child) { border-radius: 4px; }
.row { max-width: none; }
.row p { margin: .6rem 0 0; font-size: clamp(1.1rem, 1.6vw, 1.5rem); line-height: 1.35; max-width: none; }

/* chapter cards (merken) */
.cards { display: grid; gap: 24px; }
@media (min-width: 760px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .card { grid-template-columns: 116px 1fr; min-height: 0; } .card-text { padding: 20px; } .card-text p { font-size: .875rem; } }
.card { display: grid; grid-template-columns: minmax(120px, 37%) 1fr; border-radius: var(--r-xl); overflow: hidden; background: var(--surface-low); min-height: 230px;
        transition: transform .25s ease, box-shadow .25s; }
.card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgb(0 0 0 / .08); }
.card-art { position: relative; isolation: isolate; display: grid; place-items: center; background: var(--primary-container); border-radius: var(--r-xl); padding: 16px; overflow: hidden; }
.card-art::before { content: ""; position: absolute; width: 70%; aspect-ratio: 1; border-radius: 50%; background: color-mix(in srgb, var(--primary) 30%, var(--primary-container)); left: -18%; bottom: -22%; z-index: -1; }
.card-art::after { content: ""; position: absolute; width: 34px; aspect-ratio: 1; border-radius: 50%; border: 2px solid var(--primary); right: 14%; top: 14%; }
.card-art img { width: 100%; height: auto; border-radius: 12px; box-shadow: 0 6px 16px rgb(11 26 85 / .18); }
.card-text { padding: 24px clamp(20px, 3vw, 40px); align-self: center; }
.card-text h3 { font-size: clamp(1.5rem, 2.2vw, 2rem); margin: .8rem 0 .5rem; line-height: 1.2; }
.card-text p { margin: 0; color: var(--on-surface-variant); font-size: .95rem; }

/* certificates */
.certs { display: grid; gap: 24px; align-items: center; padding: clamp(24px, 4vw, 48px); border-radius: var(--r-xl); background: var(--surface-low); }
.certs h2 { margin: .9rem 0 .6rem; }
.certs p { margin: 0; color: var(--on-surface-variant); max-width: 44ch; }
.cert-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 16px; }
.cert-list li { display: grid; place-items: center; width: 160px; height: 120px; padding: 18px; border-radius: var(--r-l); background: #fff; }
.cert-list img { max-width: 100%; max-height: 84px; width: auto; height: auto; }
@media (min-width: 900px) { .certs { grid-template-columns: 1.2fr 1fr; } .cert-list { justify-content: flex-end; } }

/* gallery + lightbox */
.gallery { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(46%, 220px), 1fr)); gap: 12px; }
.gallery a { display: block; border-radius: var(--r-l); overflow: hidden; background: var(--surface-mid); }
.gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .4s ease; }
.gallery a:hover img { transform: scale(1.04); }
.lb { padding: 0; border: 0; background: transparent; max-width: 100vw; max-height: 100dvh; width: 100vw; height: 100dvh; }
.lb::backdrop { background: rgb(15 18 30 / .88); }
.lb[open] { display: grid; place-items: center; }
.lb img { max-width: min(92vw, 1600px); max-height: 86dvh; width: auto; border-radius: var(--r-l); }
.lb-btn { position: fixed; display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; background: var(--surface); color: var(--on-surface); }
.lb-btn svg { width: 22px; height: 22px; }
.lb-close { top: 16px; right: 16px; } .lb-prev { left: 16px; top: 50%; } .lb-next { right: 16px; top: 50%; }

/* contact */
.contact { display: grid; gap: clamp(24px, 4vw, 56px); }
@media (min-width: 900px) { .contact { grid-template-columns: 1.5fr 1fr; } }
.contact .lead { margin-bottom: 2rem; }
.form { display: grid; gap: 16px; padding: clamp(20px, 3vw, 32px); border-radius: var(--r-xl); background: var(--surface-low); }
@media (min-width: 600px) { .form { grid-template-columns: 1fr 1fr; } .field--full { grid-column: 1 / -1; } }
.hp { position: absolute; left: -9999px; }
.field { position: relative; }
.field input, .field textarea { width: 100%; padding: 26px 16px 8px; border: 0; border-bottom: 1px solid var(--on-surface-variant); border-radius: 4px 4px 0 0;
                                background: var(--surface-mid); color: var(--on-surface); transition: border-color .2s, background-color .2s; }
.field input:hover, .field textarea:hover { background: color-mix(in srgb, var(--surface-mid), var(--on-surface) 5%); }
.field input:focus, .field textarea:focus { outline: none; border-bottom: 2px solid var(--primary); padding-bottom: 7px; }
.field input:focus-visible, .field textarea:focus-visible { box-shadow: 0 0 0 2px var(--primary-container); }
.field label { position: absolute; left: 16px; top: 17px; color: var(--on-surface-variant); pointer-events: none; transform-origin: left top; transition: transform .15s, color .15s; }
.field :is(input, textarea):is(:focus, :not(:placeholder-shown)) + label { transform: translateY(-10px) scale(.75); }
.field :is(input, textarea):focus + label { color: var(--primary); }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.form-foot .muted { font-size: .9rem; }
.contact-photo { width: 100%; max-height: 420px; object-fit: cover; object-position: top; border-radius: var(--r-xl); margin-bottom: 16px; }
.contact-list { list-style: none; margin: 0; padding: 8px; border-radius: var(--r-xl); background: var(--secondary-container); }
.contact-list a { display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: var(--r-l); color: var(--on-surface); text-decoration: none; overflow-wrap: anywhere; }
.contact-list a:hover { background: color-mix(in srgb, var(--on-surface) 6%, transparent); }
.contact-list small { display: block; font: 500 .72rem/1.3 var(--font-label); letter-spacing: .7px; text-transform: uppercase; color: var(--on-surface-variant); }
.ci { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--surface); color: var(--primary); flex: none; }

/* call to action */
.cta { position: relative; overflow: hidden; display: grid; gap: 24px; align-items: center; margin-top: clamp(56px, 8vw, 112px);
       padding: clamp(28px, 5vw, 56px); border-radius: var(--r-xl); background: var(--hero); color: #fff; }
.cta h2 { margin: 0 0 .4rem; color: #fff; max-width: 18ch; }
.cta .btn { white-space: nowrap; justify-self: start; }
.cta p { margin: 0; color: rgb(255 255 255 / .8); }
@media (min-width: 900px) { .cta { grid-template-columns: 1fr auto; } }

/* footer */
.foot { max-width: var(--max); margin: clamp(48px, 7vw, 96px) auto 0; padding: clamp(24px, 4vw, 48px) clamp(0px, 4vw, 64px) 32px; border-top: 1px solid var(--outline-variant); }
.foot-grid { display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.foot .label { margin: 0 0 .8rem; font: 500 .8125rem/1.2 var(--font-label); letter-spacing: .7px; text-transform: uppercase; color: var(--on-surface-variant); }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.foot a { color: var(--on-surface); text-decoration: none; }
.foot a:hover { color: var(--primary); text-decoration: underline; }
.foot-social a { display: inline-flex; align-items: center; gap: .5rem; }
.foot-logo { width: 120px; height: auto; margin-bottom: .8rem; }
.foot-text { margin-top: 32px; font-size: .85rem; color: var(--on-surface-variant); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; } }
