/* Voice Craft Swift — Safelight Room — main.css */
:root {
  --surface-ink: #050506;
  --surface-hull: #0B0D0F;
  --surface-bench: #121519;
  --text-primary: #EDEFF0;
  --text-secondary: #E4E7E9;
  --text-muted: #B0B8BD;
  --hairline: #1E2328;
  --accent: #C8452F;
  --accent-dim: #6B2417;
  --shell: 1240px;
  --measure: 62ch;
  --baseline: 8px;
  --font-display: "Young Serif", Georgia, serif;
  --font-body: "Hanken Grotesk", system-ui, sans-serif;
  --font-mono: "Geist Mono", "Courier New", monospace;
  --ease: cubic-bezier(.16, 1, .3, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  margin: 0;
  overflow-x: clip;
  font-family: var(--font-body);
  font-size: clamp(17px, 1.05vw, 18px);
  line-height: 1.68;
  color: var(--text-primary);
  background: var(--surface-ink);
  min-height: 100vh;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--text-secondary); text-decoration-color: var(--accent-dim); }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 9999;
  background: var(--surface-bench); color: var(--text-primary); padding: 12px 16px;
}
.skip-link:focus { left: 16px; top: 16px; }

.shell { width: min(var(--shell), 100% - 48px); margin-inline: auto; }
@media (max-width: 640px) {
  .shell { width: min(var(--shell), 100% - 32px); }
}
.grid-8-4 {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 48px;
}
@media (max-width: 900px) { .grid-8-4 { grid-template-columns: 1fr; } }

.site-header {
  background: var(--surface-ink);
  border-bottom: 1px solid var(--hairline);
  position: sticky; top: 0; z-index: 100;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(var(--baseline) * 2) 0; gap: 24px; flex-wrap: wrap;
}
.brand {
  font-family: var(--font-display); font-size: 1.25rem; color: var(--text-primary);
  text-decoration: none; letter-spacing: 0.01em;
}
.brand span { color: var(--accent); }
.site-nav ul {
  display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; margin: 0; padding: 0;
}
.site-nav a {
  font-size: 0.9rem; text-decoration: none; color: var(--text-muted);
  padding: 6px 0; border-bottom: 1px solid transparent;
}
.site-nav a:hover, .site-nav a[aria-current="page"] {
  color: var(--text-primary); border-bottom-color: var(--accent);
}
.nav-cta {
  font-weight: 600; color: var(--accent) !important;
  border: 1px solid var(--accent-dim) !important; padding: 8px 14px !important;
  border-radius: 0;
}
.nav-cta:hover { background: var(--accent-dim); color: var(--text-primary) !important; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid var(--hairline);
  cursor: pointer;
  flex-shrink: 0;
}
.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  transition: transform 160ms var(--ease), opacity 160ms var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 900px) {
  .nav-toggle { display: flex; }
  .site-nav {
    display: none;
    width: 100%;
    order: 3;
    padding: 8px 0 12px;
    border-top: 1px solid var(--hairline);
  }
  .site-nav.is-open { display: block; }
  .site-nav ul {
    flex-direction: column;
    gap: 4px;
  }
  .site-nav a {
    display: block;
    padding: 10px 0;
    font-size: 0.95rem;
  }
  .nav-cta {
    display: inline-block;
    margin-top: 4px;
  }
  .header-inner { flex-wrap: wrap; }
}

main { padding-bottom: calc(var(--baseline) * 8); }

.hero {
  min-height: 72vh; position: relative; display: grid;
  grid-template-columns: 1fr 1fr; align-items: end; gap: 32px;
  padding: calc(var(--baseline) * 8) 0 calc(var(--baseline) * 6);
  background: var(--surface-ink);
  overflow: hidden;
}
.hero .shell.hero { overflow: hidden; }
.hero-copy { padding-bottom: calc(var(--baseline) * 4); max-width: 38ch; }
.hero-copy h1 {
  font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 400; line-height: 1.12; margin: 0 0 16px;
}
.hero-mono { font-family: var(--font-mono); font-size: 0.78rem; color: var(--text-muted); letter-spacing: 0.04em; }
.hero-photo {
  position: relative;
  overflow: hidden;
}
.hero-photo img {
  width: 100%;
  max-width: 100%;
  margin-left: auto;
  border-left: 1px solid var(--hairline);
}
@media (min-width: 901px) {
  .hero-photo img {
    width: 105%;
    max-width: 105%;
  }
}
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-photo img { width: 100%; max-width: 100%; }
}

.section { padding: calc(var(--baseline) * 8) 0; }
.section-ink { background: var(--surface-ink); }
.section-hull { background: var(--surface-hull); }
.section-bench { background: var(--surface-bench); }

.section-rule {
  border: none; border-top: 1px solid var(--hairline); margin: 0;
  position: relative;
}
.section-rule::after {
  content: ""; position: absolute; top: -1px; left: 0; width: 8px; height: 1px;
  background: var(--accent);
}

.eyebrow {
  font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--text-muted); margin-bottom: 12px;
}
.prose { max-width: var(--measure); }
.prose p { margin: 0 0 1.2em; }
.prose-narrow { max-width: 66ch; }

h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: 1.2; }
h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); margin: 0 0 24px; }

/* A-S1 Exposure Row */
.exposure-row {
  display: grid; grid-template-columns: 64px 1fr 32px; gap: 24px;
  padding: calc(var(--baseline) * 4) 0;
  border-bottom: 1px solid var(--hairline);
  align-items: start;
}
@media (max-width: 640px) {
  .exposure-row { grid-template-columns: 48px 1fr; gap: 16px; }
  .exposure-tick { display: none; }
}
.exposure-num {
  font-family: var(--font-mono); font-size: 0.85rem; color: var(--text-muted);
}
.exposure-title { font-family: var(--font-display); font-size: 1.5rem; margin: 0 0 12px; }
.exposure-tick {
  width: 8px; height: 8px; background: var(--accent); margin-top: 8px;
  opacity: 0.88; animation: tick-on 160ms var(--ease) both;
}
@keyframes tick-on { from { opacity: 0; } to { opacity: 0.88; } }

/* A-S2 Drying Line */
.drying-section { position: relative; padding-top: calc(var(--baseline) * 6); }
.drying-line {
  height: 1px; background: var(--hairline); margin-bottom: 0;
}
.drying-items {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px;
  margin-top: 0;
}
.drying-item {
  position: relative; padding-top: 48px;
}
.drying-item::before {
  content: ""; position: absolute; top: 0; left: 50%; width: 1px;
  height: var(--hang, 40px); background: var(--hairline); transform: translateX(-50%);
}
.drying-item:nth-child(1) { --hang: 32px; padding-top: 40px; }
.drying-item:nth-child(2) { --hang: 56px; padding-top: 64px; }
.drying-item:nth-child(3) { --hang: 24px; padding-top: 32px; }
.drying-item:nth-child(4) { --hang: 72px; padding-top: 80px; }
.drying-item:nth-child(5) { --hang: 48px; padding-top: 56px; }
.drying-items--pair { grid-template-columns: repeat(2, 1fr); }
.drying-items--pair .drying-item:nth-child(n) { --hang: 40px; padding-top: 48px; }
.drying-item h3 { font-size: 1.1rem; margin: 0 0 8px; }
@media (max-width: 768px) {
  .drying-items, .drying-items--pair { grid-template-columns: 1fr; }
  .drying-item::before { left: 8px; transform: none; }
}

/* A-S3 Trial Strip */
.trial-strip {
  display: grid; grid-template-columns: 2fr 1fr 2fr 1fr; gap: 8px;
  margin: calc(var(--baseline) * 4) 0;
}
.trial-strip figure { margin: 0; }
.trial-strip img { width: 100%; height: 220px; object-fit: cover; filter: brightness(0.92); }
.trial-caption {
  grid-column: 2; font-family: var(--font-mono); font-size: 0.72rem;
  color: var(--text-muted); margin-top: 8px;
}
@media (max-width: 768px) {
  .trial-strip { grid-template-columns: 1fr 1fr; }
  .trial-caption { grid-column: 1 / -1; }
}

/* A-S4 Flat Drawer */
.flat-drawer {
  margin-top: calc(var(--baseline) * 6);
  padding: calc(var(--baseline) * 4);
  border: 1px solid var(--hairline); border-left: 3px solid var(--accent-dim);
  font-family: var(--font-mono); font-size: 0.82rem; line-height: 1.7;
  color: var(--text-secondary); background: var(--surface-hull);
}
@media (min-width: 900px) {
  .flat-drawer { margin-top: 100px; }
}
.flat-drawer ul { margin: 0; padding-left: 1.2em; }
.flat-drawer li { margin-bottom: 6px; }

.photo-grid {
  display: grid; grid-template-columns: 1.2fr 1fr 0.9fr; gap: 12px;
}
.photo-grid--duo { grid-template-columns: 1fr 1fr; }
.photo-grid img { height: 280px; object-fit: cover; width: 100%; }
@media (max-width: 768px) { .photo-grid, .photo-grid--duo { grid-template-columns: 1fr; } }

.photo-inline { margin: calc(var(--baseline) * 4) 0; }
.photo-inline img { width: 100%; max-height: 420px; object-fit: cover; }
.photo-inline--full {
  max-width: 560px;
}
.photo-inline--full img {
  width: 100%;
  max-height: 320px;
  height: auto;
  object-fit: contain;
  object-position: left center;
  background: var(--surface-hull);
}
@media (max-width: 640px) {
  .photo-inline--full { max-width: 100%; }
  .photo-inline--full img { max-height: 260px; }
}

.section-link { margin-top: 24px; }
.section-gap-top { margin-top: calc(var(--baseline) * 4); }
.meta-updated {
  font-family: var(--font-mono); font-size: 0.78rem;
  color: var(--text-muted); margin-top: calc(var(--baseline) * 4);
}

.aside-col { font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-muted); }

/* FAQ Loupe layout */
.faq-layout {
  display: grid; grid-template-columns: 220px 1fr; gap: 48px; align-items: start;
}
.faq-nav { position: sticky; top: 100px; }
.faq-nav ul { list-style: none; margin: 0; padding: 0; }
.faq-nav a {
  display: block; font-family: var(--font-mono); font-size: 0.78rem;
  color: var(--text-muted); text-decoration: none; padding: 8px 0;
  border-bottom: 1px solid transparent;
}
.faq-nav a:hover { color: var(--accent); border-bottom-color: var(--hairline); }
.faq-item { margin-bottom: calc(var(--baseline) * 5); scroll-margin-top: 100px; }
.faq-q { font-family: var(--font-display); font-size: 1.35rem; margin: 0 0 12px; }
@media (max-width: 768px) { .faq-layout { grid-template-columns: 1fr; } .faq-nav { position: static; } }

/* Contact Lightlock */
.contact-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start;
}
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }

.contact-block p { margin: 0 0 12px; }
.contact-block a { color: var(--accent); }

/* Maps */
.map-wrap { width: 100%; position: relative; overflow: hidden; }
.map-wrap iframe { border: 0; width: 100%; display: block; max-width: 100%; }

.map-a .map-wrap iframe {
  height: 520px; filter: grayscale(0.5) brightness(0.6) contrast(1.12);
  border-right: 1px solid var(--accent-dim);
}
.map-a .map-caption { font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted); margin-top: 8px; }

.map-b { margin: calc(var(--baseline) * 4) 0 0; border-top: 1px solid var(--hairline); }
.map-b .map-wrap iframe { height: 190px; width: 100%; filter: grayscale(0.5) brightness(0.6) contrast(1.12); }
.map-b .map-caption { text-align: right; font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted); margin-top: 6px; }

.map-c { margin: calc(var(--baseline) * 6) 0; }
.map-c .map-wrap iframe { height: 300px; filter: grayscale(0.5) brightness(0.6) contrast(1.12); }
.map-c .map-caption { font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted); margin-top: 8px; }

.map-d { margin: calc(var(--baseline) * 4) 0; }
.map-d .map-wrap {
  border: 1px solid var(--accent-dim); padding: 4px; background: var(--surface-hull);
}
.map-d .map-wrap iframe { height: 210px; filter: grayscale(0.5) brightness(0.6) contrast(1.12); }
.map-d .map-caption { font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted); margin-top: 8px; }

@media (max-width: 640px) {
  .map-a .map-wrap iframe { height: 320px; }
  .map-b .map-wrap iframe { height: 190px; }
}

.signed-note {
  margin-top: calc(var(--baseline) * 4); padding-top: calc(var(--baseline) * 3);
  border-top: 1px solid var(--hairline); font-style: normal;
}
.disclaimer {
  font-size: 0.88rem; color: var(--text-muted); margin-top: calc(var(--baseline) * 4);
  padding: calc(var(--baseline) * 2); border-left: 2px solid var(--accent-dim);
}

.record-list { list-style: none; margin: 0; padding: 0; }
.record-list li {
  padding: calc(var(--baseline) * 2) 0; border-bottom: 1px solid var(--hairline);
  font-family: var(--font-mono); font-size: 0.85rem;
}

.site-footer {
  background: var(--surface-ink); border-top: 1px solid var(--hairline);
  padding: calc(var(--baseline) * 6) 0 calc(var(--baseline) * 4);
  color: var(--text-muted); font-size: 0.88rem;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr; gap: 32px;
}
.footer-entity { color: var(--text-secondary); margin-bottom: 8px; font-weight: 600; }
.footer-links { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px 20px; }
.footer-links a { color: var(--text-secondary); text-decoration: none; }
.footer-links a:hover { color: var(--accent); }
.footer-copy { margin-top: calc(var(--baseline) * 3); font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-muted); }
.site-footer a { color: var(--text-secondary); }
.site-footer a:hover { color: var(--accent); }
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr; } }

/* Cookie banner */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
  max-width: 420px; margin: 16px;
  background: var(--surface-hull); border: 1px solid var(--accent-dim);
  padding: 20px; color: var(--text-primary);
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}
.cookie-banner[hidden] { display: none !important; }
html[data-cookie-consent="set"] #vcs-cookie-banner { display: none !important; }
.cookie-banner p { margin: 0 0 16px; font-size: 0.88rem; line-height: 1.5; color: var(--text-secondary); }
.cookie-banner a { color: var(--accent); }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cookie-actions button {
  font-family: var(--font-body); font-size: 0.82rem; cursor: pointer;
  padding: 8px 14px; background: transparent; color: var(--text-primary);
  border: 1px solid var(--accent); transition: background 160ms var(--ease);
}
.cookie-actions button:hover { background: var(--accent-dim); }
.cookie-actions button.primary { background: var(--accent-dim); border-color: var(--accent); }
.cookie-panel { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--hairline); }
.cookie-panel[hidden] { display: none !important; }
.cookie-toggle { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; font-size: 0.85rem; }
.cookie-toggle input[type="checkbox"] { accent-color: var(--accent); width: 18px; height: 18px; }
.cookie-toggle input:disabled { opacity: 0.6; }
@media (max-width: 640px) {
  .cookie-banner { max-width: none; left: 0; right: 0; margin: 0; border-left: none; border-right: none; border-bottom: none; }
}

.legal-page h1 { font-family: var(--font-display); font-size: 2rem; }
.legal-page h2 { font-size: 1.3rem; margin-top: 32px; color: var(--text-primary); }
.legal-page p, .legal-page li { color: var(--text-secondary); }
.legal-page ul { padding-left: 1.2em; }

.error-page { text-align: left; padding: calc(var(--baseline) * 10) 0; }
.error-page h1 { font-family: var(--font-display); font-size: 2.4rem; }
.error-links { list-style: none; padding: 0; margin: 24px 0; }
.error-links li { margin-bottom: 8px; }

.hairline-draw {
  height: 1px; background: var(--hairline); transform-origin: left;
  animation: draw-line 480ms var(--ease) both;
}
@keyframes draw-line { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.photo-fade { animation: fade-up 240ms var(--ease) both; }
@keyframes fade-up {
  from { opacity: 0.88; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important; animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

.manage-cookies-btn {
  font-family: var(--font-body); cursor: pointer; padding: 10px 18px;
  background: transparent; color: var(--accent); border: 1px solid var(--accent-dim);
  margin-top: 16px;
}
.manage-cookies-btn:hover { background: var(--accent-dim); color: var(--text-primary); }
