/* Wood Lock website — shared styles.
   Warm wood palette, fluid type, mobile-first layout, automatic dark mode. */

:root {
  --bg: #faf4ea;
  --bg-alt: #f1e6d6;
  --surface: #ffffff;
  --surface-2: #fbf6ee;
  --text: #3b2618;
  --muted: #7d6450;
  --line: rgba(59, 38, 24, 0.12);
  --brand: #8e4b2a;
  --brand-dark: #5e2d17;
  --brand-ink: #fff4e4;
  --gold: #e0a42a;
  --gold-soft: #f7e1a8;
  --green: #5e7f3a;
  --walnut-1: #3a2416;
  --walnut-2: #24160c;
  --shadow-sm: 0 2px 6px rgba(40, 20, 8, 0.08);
  --shadow: 0 14px 40px rgba(40, 20, 8, 0.14);
  --radius: 20px;
  --radius-sm: 12px;
  --max: 1160px;
  --gutter: clamp(16px, 4vw, 32px);
  --font: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b120c;
    --bg-alt: #221710;
    --surface: #2b1f17;
    --surface-2: #33251b;
    --text: #f3e6d3;
    --muted: #bba58d;
    --line: rgba(243, 230, 211, 0.12);
    --brand: #e39a62;
    --brand-dark: #b8703e;
    --brand-ink: #1b120c;
    --gold-soft: #4a3a1c;
    --green: #93bf63;
    --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.3);
    --shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: clamp(16px, 0.35vw + 15px, 18px);
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--brand-dark); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 4.6vw + 0.8rem, 3.9rem); font-weight: 900; }
h2 { font-size: clamp(1.6rem, 2.4vw + 0.8rem, 2.5rem); font-weight: 900; }
h3 { font-size: clamp(1.15rem, 0.6vw + 1rem, 1.35rem); font-weight: 800; }
p { margin: 0 0 1em; }

.container { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.section { padding-block: clamp(56px, 8vw, 110px); }
.section--alt { background: var(--bg-alt); }
.eyebrow {
  display: inline-block; font-size: 0.8rem; font-weight: 800; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--brand); margin-bottom: 10px;
}
.lead { font-size: clamp(1.05rem, 0.6vw + 0.95rem, 1.25rem); color: var(--muted); max-width: 62ch; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.skip-link {
  position: absolute; left: -999px; top: 8px; background: var(--brand); color: var(--brand-ink);
  padding: 8px 14px; border-radius: 8px; z-index: 100;
}
.skip-link:focus { left: 8px; }

/* ------------------------------------------------------------ header -- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-weight: 900; font-size: 1.2rem; }
.brand img { width: 40px; height: 40px; border-radius: 11px; box-shadow: var(--shadow-sm); }
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  display: block; padding: 8px 12px; border-radius: 10px; text-decoration: none;
  color: var(--text); font-weight: 700; font-size: 0.95rem;
}
.nav-links a:hover { background: var(--surface-2); color: var(--brand); }
.nav-links a[aria-current="page"] { color: var(--brand); background: var(--surface-2); }
.nav-cta { margin-left: 8px; }
.nav-links .nav-cta a.btn { display: inline-flex; padding: 9px 16px; color: #fff4e4; background: linear-gradient(180deg, #b2693f, #8e4b2a 55%, #6e3519); }
.nav-links .nav-cta a.btn:hover { color: #fff; }
.nav-links .nav-cta a.btn svg { width: 16px; height: 16px; }
.nav-toggle {
  display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface); color: var(--text); cursor: pointer; align-items: center; justify-content: center;
}
.nav-toggle svg { width: 22px; height: 22px; }

@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 2px;
    padding: 10px var(--gutter) 18px; background: var(--bg);
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 14px; font-size: 1.02rem; }
  .nav-cta { margin: 8px 0 0; }
  .nav-cta .btn { width: 100%; justify-content: center; }
}

/* ----------------------------------------------------------- buttons -- */
.btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 13px 22px; border-radius: 999px;
  font-weight: 800; font-size: 1rem; text-decoration: none; border: 0; cursor: pointer;
  background: linear-gradient(180deg, #b2693f, #8e4b2a 55%, #6e3519);
  color: #fff4e4; box-shadow: 0 6px 16px rgba(94, 45, 23, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { color: #fff4e4; transform: translateY(-1px); box-shadow: 0 10px 22px rgba(94, 45, 23, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.25); }
.btn--ghost { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); border: 1px solid var(--line); }
.btn--ghost:hover { color: var(--brand); }
.btn--small { padding: 9px 16px; font-size: 0.92rem; }
.btn svg { width: 20px; height: 20px; flex: none; }

.play-badge {
  display: inline-flex; align-items: center; gap: 12px; padding: 10px 20px 10px 16px;
  background: #111; color: #fff; border-radius: 14px; text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.18); box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease;
}
.play-badge:hover { color: #fff; transform: translateY(-1px); }
.play-badge svg { width: 30px; height: 30px; }
.play-badge small { display: block; font-size: 0.68rem; letter-spacing: 0.06em; opacity: 0.85; text-transform: uppercase; }
.play-badge strong { display: block; font-size: 1.15rem; line-height: 1.1; }

/* -------------------------------------------------------------- hero -- */
.hero {
  position: relative; overflow: hidden; color: #fff4e4;
  background:
    radial-gradient(1200px 600px at 15% 0%, rgba(255, 201, 138, 0.22), transparent 60%),
    linear-gradient(160deg, #6e3519 0%, var(--walnut-1) 45%, var(--walnut-2) 100%);
}
.hero::before {
  content: ""; position: absolute; inset: 0; opacity: 0.18; pointer-events: none;
  background-image: repeating-linear-gradient(95deg, rgba(0, 0, 0, 0.35) 0 2px, transparent 2px 9px),
    repeating-linear-gradient(97deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 23px);
}
.hero .container {
  position: relative; display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center;
  gap: clamp(28px, 5vw, 64px); padding-block: clamp(48px, 7vw, 96px);
}
.hero h1 { color: #fff4e4; text-shadow: 0 3px 14px rgba(0, 0, 0, 0.35); }
.hero h1 span { color: var(--gold); }
.hero .lead { color: rgba(246, 221, 176, 0.92); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 26px; }
.hero-stats { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 12px 30px; margin-top: 30px; }
.hero-stats div { font-weight: 800; }
.hero-stats strong { display: block; font-size: 1.7rem; color: var(--gold); line-height: 1.1; }
.hero-stats span { font-size: 0.9rem; color: rgba(246, 221, 176, 0.85); font-weight: 700; }
.hero-art { display: flex; justify-content: center; }
.hero-art img {
  width: min(100%, 340px); filter: drop-shadow(0 30px 45px rgba(0, 0, 0, 0.55));
  transform: rotate(3deg);
}
.hero .btn--ghost { background: rgba(255, 244, 228, 0.1); color: #fff4e4; border-color: rgba(255, 244, 228, 0.25); }
.hero .btn--ghost:hover { background: rgba(255, 244, 228, 0.18); color: #fff; }

@media (max-width: 860px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; }
  .hero .lead { margin-inline: auto; }
  .hero-actions, .hero-stats { justify-content: center; }
  .hero-stats { grid-template-columns: repeat(4, auto); }
  .hero-art img { width: min(72%, 300px); transform: none; }
}
@media (max-width: 520px) {
  .hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 320px; margin-inline: auto; }
}

/* ------------------------------------------------------ page heading -- */
.page-hero {
  background: linear-gradient(160deg, #6e3519, var(--walnut-1) 55%, var(--walnut-2));
  color: #fff4e4; padding-block: clamp(44px, 6vw, 80px);
}
.page-hero h1 { color: #fff4e4; font-size: clamp(2rem, 3.4vw + 0.8rem, 3.2rem); }
.page-hero .lead { color: rgba(246, 221, 176, 0.9); }
.page-hero .eyebrow { color: var(--gold); }
.breadcrumb { font-size: 0.9rem; margin-bottom: 14px; color: rgba(246, 221, 176, 0.8); }
.breadcrumb a { color: rgba(246, 221, 176, 0.95); }

/* ------------------------------------------------------------- cards -- */
.grid { display: grid; gap: clamp(16px, 2vw, 24px); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }

.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(20px, 2.4vw, 28px); box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card p:last-child { margin-bottom: 0; }
.card .icon {
  width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 16px;
  background: linear-gradient(145deg, #c47a4a, #8e4b2a); color: #fff4e4; box-shadow: 0 6px 14px rgba(142, 75, 42, 0.3);
}
.card .icon svg { width: 26px; height: 26px; }
.card .icon.gold { background: linear-gradient(145deg, #f2c14e, #b07414); }
.card .icon.green { background: linear-gradient(145deg, #86b066, #4e7431); }
.card .icon.blue { background: linear-gradient(145deg, #6a9ccc, #2f5c88); }
.card .icon.red { background: linear-gradient(145deg, #d86a55, #9e3322); }
.card .icon.purple { background: linear-gradient(145deg, #b27fd0, #6e3b8c); }
.card p { color: var(--muted); }

/* ------------------------------------------------------- screenshots -- */
.shots {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(220px, 1fr);
  gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px 4px 22px;
  scrollbar-width: thin;
}
.shots figure { margin: 0; scroll-snap-align: center; }
.shots img { border-radius: 22px; box-shadow: var(--shadow); aspect-ratio: 9 / 16; object-fit: cover; width: 100%; }
@media (max-width: 700px) { .shots { grid-auto-columns: 72%; } }

/* ------------------------------------------------------------- modes -- */
.mode { display: flex; gap: 18px; align-items: flex-start; }
.mode .icon { flex: none; margin: 0; }
.tag {
  display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 0.78rem; font-weight: 800;
  background: var(--gold-soft); color: var(--text); margin-bottom: 8px;
}

/* ------------------------------------------------------------- steps -- */
.steps { counter-reset: step; display: grid; gap: 18px; padding: 0; list-style: none; }
.steps li {
  position: relative; padding: 22px 22px 22px 78px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.steps li::before {
  counter-increment: step; content: counter(step); position: absolute; left: 20px; top: 20px;
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  font-weight: 900; color: #fff4e4; background: linear-gradient(145deg, #c47a4a, #8e4b2a);
}
.steps h3 { margin-bottom: 4px; }
.steps p { margin: 0; color: var(--muted); }

/* ------------------------------------------------------ split layout -- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.board-figure { display: flex; justify-content: center; }
.board-figure svg { width: min(100%, 360px); height: auto; filter: drop-shadow(0 18px 30px rgba(40, 20, 8, 0.3)); }

/* ------------------------------------------------------------ tables -- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface); }
table { width: 100%; border-collapse: collapse; min-width: 480px; }
th, td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--surface-2); font-weight: 800; font-size: 0.92rem; }
tr:last-child td { border-bottom: 0; }

/* --------------------------------------------------------------- FAQ -- */
.faq-tools { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 26px; }
.search {
  flex: 1 1 280px; display: flex; align-items: center; gap: 10px; padding: 0 16px; min-height: 52px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px; box-shadow: var(--shadow-sm);
}
.search input { flex: 1; border: 0; outline: 0; background: transparent; font: inherit; color: var(--text); min-width: 0; }
.search svg { width: 20px; height: 20px; color: var(--muted); flex: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; font-weight: 700;
  font-size: 0.9rem; padding: 8px 14px; border-radius: 999px; cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); border-color: transparent; }
.faq-group { margin-bottom: 34px; }
.faq-group h2 { font-size: clamp(1.25rem, 1vw + 1rem, 1.6rem); }
details {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  margin-bottom: 12px; box-shadow: var(--shadow-sm); overflow: hidden;
}
summary {
  list-style: none; cursor: pointer; padding: 18px 56px 18px 20px; font-weight: 800; position: relative;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: ""; position: absolute; right: 22px; top: 50%; width: 11px; height: 11px;
  border-right: 2.5px solid var(--brand); border-bottom: 2.5px solid var(--brand);
  transform: translateY(-70%) rotate(45deg); transition: transform 0.2s ease;
}
details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
details .answer { padding: 0 20px 18px; color: var(--muted); }
details .answer p:last-child { margin-bottom: 0; }
.no-results { display: none; color: var(--muted); text-align: center; padding: 30px; }

/* ------------------------------------------------------- legal pages -- */
.legal { display: grid; grid-template-columns: 260px 1fr; gap: clamp(24px, 4vw, 56px); align-items: start; }
.toc {
  position: sticky; top: 92px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow-sm);
}
.toc h2 { font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.toc ol { margin: 0; padding-left: 20px; font-size: 0.93rem; }
.toc li { margin: 4px 0; }
.toc a { text-decoration: none; color: var(--text); }
.toc a:hover { color: var(--brand); }
.prose { max-width: 76ch; }
.prose h2 { font-size: clamp(1.3rem, 1vw + 1rem, 1.65rem); margin-top: 2.2em; scroll-margin-top: 90px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.4em; }
.prose ul { padding-left: 1.3em; }
.prose li { margin: 0.35em 0; }
.meta-box {
  background: var(--surface); border: 1px solid var(--line); border-left: 5px solid var(--gold);
  border-radius: var(--radius-sm); padding: 16px 20px; margin-bottom: 30px; font-size: 0.95rem;
}
.meta-box p { margin: 0.2em 0; }
@media (max-width: 900px) {
  .legal { grid-template-columns: 1fr; }
  .toc { position: static; }
}

/* --------------------------------------------------------------- CTA -- */
.cta {
  border-radius: calc(var(--radius) + 8px); padding: clamp(32px, 5vw, 60px); color: #fff4e4; text-align: center;
  background: radial-gradient(700px 300px at 20% 0%, rgba(255, 201, 138, 0.25), transparent 60%),
    linear-gradient(150deg, #8e4b2a, #3a2416);
  box-shadow: var(--shadow);
}
.cta h2 { color: #fff4e4; }
.cta p { color: rgba(246, 221, 176, 0.9); max-width: 56ch; margin-inline: auto; }
.cta .hero-actions { justify-content: center; }

/* ------------------------------------------------------------ footer -- */
.site-footer { background: var(--walnut-2); color: rgba(246, 221, 176, 0.85); padding-block: 48px 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 28px; }
.site-footer h3 { color: #fff4e4; font-size: 1rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 7px 0; }
.site-footer a { color: rgba(246, 221, 176, 0.9); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer .brand { color: #fff4e4; margin-bottom: 12px; }
.footer-bottom {
  margin-top: 36px; padding-top: 20px; border-top: 1px solid rgba(246, 221, 176, 0.15);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: 0.88rem;
}
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------ misc helpers -- */
.note {
  display: flex; gap: 12px; padding: 16px 18px; border-radius: var(--radius-sm);
  background: var(--gold-soft); color: var(--text); margin: 18px 0;
}
.note svg { width: 22px; height: 22px; flex: none; color: var(--brand); margin-top: 2px; }
.note p { margin: 0; }
.kbd { font-weight: 800; color: var(--brand); }
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .card, .btn, .play-badge { transition: none; }
}
