/* Theme colours (--primary, --accent, --ink, --paper and their --on-* text colours) come from the admin panel, printed inline in <head>. */
:root {
  --display: 'Young Serif', Georgia, serif;
  --body: 'Hanken Grotesk', system-ui, sans-serif;
  --muted: color-mix(in oklab, var(--ink) 68%, var(--paper));
  --line: color-mix(in oklab, var(--ink) 15%, var(--paper));
  --tint: color-mix(in oklab, var(--primary) 9%, var(--paper));
  --surface: color-mix(in oklab, var(--paper) 45%, #fff);
  --gutter: clamp(1rem, 4vw, 3rem);
  --r-lg: 28px;
  --r: 16px;
  --r-sm: 10px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1.0625rem/1.65 var(--body); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { color: inherit; }
figure { margin: 0; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.08; letter-spacing: -0.01em; margin: 0 0 .5em; text-wrap: balance; }
p { margin: 0 0 1em; text-wrap: pretty; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(100% - 2 * var(--gutter), 1240px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 1rem; z-index: 99; background: var(--ink); color: var(--paper); padding: .75rem 1rem; border-radius: var(--r-sm); }
.skip:focus { left: 1rem; }
.ph { display: block; width: 100%; height: 100%; min-height: 160px; background: repeating-linear-gradient(135deg, var(--tint) 0 14px, color-mix(in oklab, var(--primary) 14%, var(--paper)) 14px 15px); }

/* Buttons & links */
.btn { display: inline-flex; align-items: center; gap: .6rem; padding: .95rem 1.6rem; border: 0; border-radius: 999px; background: var(--accent); color: var(--on-accent); font: 600 1rem/1 var(--body); text-decoration: none; cursor: pointer; transition: background .2s; }
.btn:hover { background: color-mix(in oklab, var(--accent) 85%, var(--ink)); }
.btn.alt { background: var(--primary); color: var(--on-primary); }
.btn.alt:hover { background: color-mix(in oklab, var(--primary) 85%, var(--ink)); }
.link { font-weight: 600; text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 7px; transition: text-underline-offset .2s; }
.link:hover { text-underline-offset: 4px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 30; background: color-mix(in oklab, var(--paper) 88%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 84px; position: relative; }
.brand { display: flex; align-items: center; gap: .8rem; text-decoration: none; min-width: 0; }
.brand img { max-height: 52px; max-width: 200px; width: auto; }
.brand b { display: block; font: 400 1.4rem/1.1 var(--display); }
.brand small { display: block; font-size: .82rem; color: var(--muted); }
.mark { flex: none; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: var(--primary); color: var(--on-primary); font: 400 1.35rem/1 var(--display); }
.nav { display: flex; align-items: center; gap: .25rem; }
.nav a { padding: .6rem 1rem; border-radius: 999px; text-decoration: none; font-weight: 500; font-size: .98rem; transition: background .2s; }
.nav a:hover, .nav a[aria-current] { background: var(--tint); }
.nav a.cta { background: var(--primary); color: var(--on-primary); margin-left: .5rem; }
.menu-btn { display: none; align-items: center; gap: .6rem; padding: .6rem 1rem; border: 1px solid var(--line); border-radius: 999px; background: none; color: inherit; font: 500 .95rem var(--body); cursor: pointer; }
.menu-btn span, .menu-btn span::before { display: block; width: 16px; height: 2px; background: currentColor; position: relative; transition: transform .2s; }
.menu-btn span::before { content: ''; position: absolute; top: 5px; }
.menu-btn span { transform: translateY(-2.5px); }
.menu-open .menu-btn span { transform: translateY(0) rotate(45deg); }
.menu-open .menu-btn span::before { top: 0; transform: rotate(-90deg); }

/* Home: slider */
.hero { position: relative; margin: .25rem var(--gutter) 0; border-radius: var(--r-lg); overflow: hidden; background: var(--primary); color: var(--on-primary); }
.slides { display: grid; }
.slide { grid-area: 1 / 1; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); min-height: min(80vh, 720px); opacity: 0; visibility: hidden; transition: opacity .9s ease, visibility 0s .9s; }
.slide.on { opacity: 1; visibility: visible; transition-delay: 0s; }
.slide .copy { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: clamp(2rem, 5vw, 4.5rem); padding-bottom: 7.5rem; }
.slide-title { font-size: clamp(2.4rem, 4.4vw, 4.1rem); line-height: 1.02; margin-bottom: .45em; }
.slide p { font-size: 1.15rem; max-width: 34ch; margin-bottom: 2rem; opacity: .86; }
.slide figure { overflow: hidden; }
.slide img, .slide .ph { width: 100%; height: 100%; object-fit: cover; transform: scale(1.07); transition: transform 8s cubic-bezier(.2, .6, .3, 1); }
.slide.on img { transform: none; }
.hero-ctrl { position: absolute; left: clamp(2rem, 5vw, 4.5rem); bottom: 2.25rem; width: calc(41.66% - 2 * clamp(2rem, 5vw, 4.5rem)); display: flex; align-items: center; gap: 1rem; }
.count { font-size: .92rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bars { flex: 1; display: flex; gap: 6px; }
.bars button { flex: 1; position: relative; height: 22px; padding: 0; border: 0; background: none; cursor: pointer; }
.bars button::before, .bars span { content: ''; position: absolute; left: 0; top: 10px; height: 2px; border-radius: 2px; }
.bars button::before { right: 0; background: color-mix(in oklab, var(--on-primary) 30%, transparent); }
.bars span { width: 0; background: var(--on-primary); }
.bars .on span { animation: fill 6.5s linear forwards; }
.hero:hover .bars .on span, .hero:focus-within .bars .on span { animation-play-state: paused; }
@keyframes fill { to { width: 100%; } }
.arrow { flex: none; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; border: 1px solid color-mix(in oklab, var(--on-primary) 40%, transparent); background: none; color: inherit; cursor: pointer; transition: background .2s; }
.arrow:hover { background: color-mix(in oklab, var(--on-primary) 14%, transparent); }

/* Sections */
.section { padding-block: clamp(4.5rem, 9vw, 8rem); }
.tinted { background: var(--tint); }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 52ch; }
.split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.split h2 { font-size: clamp(2.2rem, 4.2vw, 3.5rem); }
.split figure { border-radius: var(--r-lg); overflow: hidden; }
.split img, .split .ph { width: 100%; height: 100%; object-fit: cover; }
.intro figure { aspect-ratio: 4 / 5; }
.intro .lead { margin-bottom: 2rem; }

.feature { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }
.feature figure { aspect-ratio: 5 / 4; }
.feature.flip figure { order: 2; }
.feature p { color: var(--muted); max-width: 46ch; }
.feature .link { display: inline-block; margin-top: .75rem; }
.band { background: var(--ink); color: var(--on-ink); }
.band .feature p { color: color-mix(in oklab, var(--on-ink) 72%, var(--ink)); }
.feature-row { padding-block: clamp(3.5rem, 7vw, 6rem); }
.feature-row:first-child:not(.band) { padding-top: 0; }

.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem 3rem; flex-wrap: wrap; margin-bottom: clamp(2rem, 4vw, 3.25rem); }
.sec-head h2 { font-size: clamp(2.2rem, 4.2vw, 3.5rem); margin: 0; }
.sec-head p { color: var(--muted); max-width: 40ch; margin: 0; }

.cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 2.5rem clamp(1rem, 2.5vw, 2rem); }
.cat { text-decoration: none; }
.cat figure { aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden; background: var(--tint); }
.cat img, .card img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .6, .3, 1); }
.cat:hover img, .card:hover img { transform: scale(1.04); }
.cat h3 { font-size: 1.55rem; margin: 1.1rem 0 .15rem; }
.cat span { color: var(--muted); font-size: .92rem; }
.cat:hover h3, .card:hover h3 { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }

/* Inner pages */
.page-head { padding-block: clamp(2.5rem, 6vw, 5rem) clamp(2rem, 4vw, 3.5rem); }
.page-head h1 { font-size: clamp(2.8rem, 6.5vw, 5.25rem); line-height: 1; margin: .35em 0 .3em; max-width: 16ch; }
.crumbs { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 0; padding: 0; font-size: .92rem; color: var(--muted); }
.crumbs li + li::before { content: '/'; margin-right: .5rem; opacity: .5; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2rem; }
.chips a { padding: .55rem 1.1rem; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 500; font-size: .95rem; transition: border-color .2s; }
.chips a:hover { border-color: var(--ink); }
.chips a[aria-current] { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 3rem clamp(1rem, 2.5vw, 2rem); }
.listing { padding-bottom: clamp(4rem, 8vw, 7rem); }
.card { text-decoration: none; }
.card figure { aspect-ratio: 1; border-radius: var(--r); overflow: hidden; background: var(--tint); margin-bottom: 1.1rem; }
.card h3 { font-size: 1.35rem; margin-bottom: .3rem; }
.card p { color: var(--muted); font-size: .96rem; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.empty { padding: 3rem; border: 1px dashed var(--line); border-radius: var(--r); text-align: center; color: var(--muted); margin: 0; }

/* Product */
.product { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(2rem, 5vw, 5rem); align-items: start; padding-block: 1.5rem clamp(4rem, 8vw, 7rem); }
.gallery .main { aspect-ratio: 1; border-radius: var(--r-lg); overflow: hidden; background: var(--tint); }
.gallery .main img { width: 100%; height: 100%; object-fit: cover; }
.thumbs { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: .9rem; }
.thumbs button { width: 88px; aspect-ratio: 1; padding: 0; border: 2px solid transparent; border-radius: var(--r-sm); overflow: hidden; background: none; cursor: pointer; opacity: .7; transition: opacity .2s, border-color .2s; }
.thumbs button:hover, .thumbs [aria-pressed="true"] { opacity: 1; }
.thumbs [aria-pressed="true"] { border-color: var(--primary); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }
.info { position: sticky; top: 110px; }
.info h1 { font-size: clamp(2.3rem, 4vw, 3.4rem); margin: .5em 0 .35em; }
.info .lead { margin-bottom: 1.5rem; }
.specs { display: grid; grid-template-columns: auto 1fr; margin: 2rem 0 2.25rem; border-top: 1px solid var(--line); }
.specs dt, .specs dd { margin: 0; padding: .85rem 0; border-bottom: 1px solid var(--line); }
.specs dt { color: var(--muted); padding-right: 2rem; }
.related { padding-block: clamp(3.5rem, 7vw, 6rem) 0; border-top: 1px solid var(--line); }
.related h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); margin-bottom: 2rem; }

/* About */
.about-hero { aspect-ratio: 21 / 9; border-radius: var(--r-lg); overflow: hidden; }
.about-hero img { width: 100%; height: 100%; object-fit: cover; }
.story { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; }
.story figure { aspect-ratio: 4 / 5; margin-top: 2rem; }
.story .body { font-size: 1.15rem; max-width: 60ch; padding-top: .5rem; }
.story .body p:first-child { font: 400 clamp(1.4rem, 2.2vw, 1.75rem)/1.4 var(--display); margin-bottom: 1.25em; }
.values { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.5rem, 4vw, 3.5rem); }
.value { border-top: 2px solid var(--primary); padding-top: 1.5rem; }
.value h3 { font-size: 1.55rem; }
.value p { color: var(--muted); margin: 0; }

/* Contact */
.contact { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; padding-bottom: clamp(4rem, 8vw, 6rem); }
.details { margin: 0; }
.details dt { font-size: .92rem; color: var(--muted); margin-top: 1.75rem; }
.details dt:first-child { margin-top: 0; }
.details dd { margin: .3rem 0 0; font-size: 1.15rem; }
.details a { text-decoration: none; }
.details a:hover { text-decoration: underline; }
.form { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(1.5rem, 4vw, 3rem); }
.form h2 { font-size: 2rem; }
.form label { display: block; font-weight: 500; font-size: .95rem; margin-bottom: 1.1rem; }
.form input, .form textarea { display: block; width: 100%; margin-top: .4rem; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--paper); color: inherit; font: inherit; transition: border-color .2s; }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 22%, transparent); }
.form textarea { min-height: 150px; resize: vertical; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
.hp { position: absolute; left: -9999px; }
.notice { padding: 1rem 1.25rem; border-radius: var(--r-sm); background: var(--tint); border-left: 4px solid var(--primary); margin-bottom: 1.5rem; }
.notice.err { border-color: #b3261e; background: color-mix(in oklab, #b3261e 8%, var(--paper)); }
.map { padding-bottom: clamp(4rem, 8vw, 6rem); }
.map iframe { display: block; width: 100%; height: 440px; border: 0; border-radius: var(--r-lg); }

/* Footer */
.site-footer { background: var(--ink); color: var(--on-ink); padding-block: clamp(3.5rem, 7vw, 5.5rem) 2rem; }
.foot-top { display: grid; grid-template-columns: minmax(0, 4fr) repeat(3, minmax(0, 2fr)); gap: 2.5rem; }
.foot-brand b { display: block; font: 400 clamp(2rem, 3.5vw, 2.75rem)/1.05 var(--display); }
.foot-brand p { opacity: .7; }
.site-footer h2 { font: 600 .95rem var(--body); margin: .4rem 0 1rem; opacity: .6; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: .45rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; text-underline-offset: 4px; }
.site-footer p { font-size: .98rem; }
.social { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; margin-top: 1.5rem !important; }
.foot-bottom { margin-top: 3.5rem; padding-top: 1.5rem; border-top: 1px solid color-mix(in oklab, var(--on-ink) 15%, var(--ink)); font-size: .88rem; opacity: .7; }

/* Tablet & phone */
@media (max-width: 900px) {
  .split, .story, .product, .contact { grid-template-columns: 1fr; }
  .feature.flip figure { order: 0; }
  .intro figure { aspect-ratio: 4 / 3; }
  .story figure { display: none; }
  .info { position: static; }
  .values { grid-template-columns: 1fr; }
  .foot-top { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
  .about-hero { aspect-ratio: 4 / 3; }
}
@media (max-width: 820px) {
  .menu-btn { display: inline-flex; }
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; padding: .75rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); box-shadow: 0 20px 40px -20px color-mix(in oklab, var(--ink) 40%, transparent); }
  .menu-open .nav { display: flex; }
  .nav a.cta { margin: .25rem 0 0; text-align: center; }
  .brand small { display: none; }
  .slide { grid-template-columns: 1fr; min-height: 0; }
  .slide figure { order: -1; aspect-ratio: 4 / 3; }
  .slide .copy { padding: 1.75rem 1.5rem 6rem; }
  .hero-ctrl { left: 1.5rem; right: 1.5rem; bottom: 1.5rem; width: auto; }
}
@media (max-width: 560px) {
  .form .row, .foot-top { grid-template-columns: 1fr; }
  .specs { grid-template-columns: 1fr; }
  .specs dt { border-bottom: 0; padding-bottom: 0; }
  .map iframe { height: 320px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
