:root {
  color-scheme: light;
  --background: #f7f2e2;
  --surface: #ffffff;
  --ink: #2f3524;
  --muted: #6c7259;
  --accent: #dc9a2e;
  --accent-dark: #a76c11;
  --accent-soft: #fbe9c6;
  --leaf: #5b8c4a;
  --leaf-dark: #3f6a34;
  --leaf-soft: #e1efd9;
  --border: #ded9c2;
  --shadow: 0 18px 50px rgba(47, 53, 36, 0.12);
  --max-width: 1160px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 15% 0%, rgba(91, 140, 74, 0.12), transparent 32rem),
    var(--background);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-underline-offset: 0.18em; }
a:hover { color: var(--accent-dark); }
a:focus-visible { outline: 3px solid #6b93d6; outline-offset: 4px; border-radius: 6px; }

.site-header,
main,
footer {
  width: min(calc(100% - 40px), var(--max-width));
  margin-inline: auto;
}

.site-header {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 1.06rem;
  font-weight: 800;
  text-decoration: none;
}

.brand img { border-radius: 13px; }

nav { display: flex; align-items: center; gap: 26px; }
nav a { color: var(--muted); font-weight: 700; text-decoration: none; }
nav a[aria-current="page"] { color: var(--ink); }

.hero {
  min-height: 650px;
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  align-items: center;
  gap: clamp(36px, 7vw, 88px);
  padding: 64px 0 92px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--accent-dark);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1, h2, h3 { margin-top: 0; line-height: 1.08; letter-spacing: -0.035em; }

h1 { margin-bottom: 24px; font-size: clamp(3.25rem, 7vw, 5.7rem); }
h2 { margin-bottom: 18px; font-size: clamp(2.1rem, 4vw, 3.55rem); }
h3 { margin-bottom: 10px; font-size: 1.35rem; }

.hero-text {
  max-width: 600px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.08rem, 1.8vw, 1.3rem);
}

.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin: 30px 0 16px; }
.hero-badges span {
  padding: 9px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.66);
  font-size: 0.9rem;
  font-weight: 800;
}

/* Hero visual: a CSS-only sketch of the swap board, no photo asset required. */
.hero-visual { position: relative; min-height: 520px; }

.board-frame {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 22px;
  padding: clamp(26px, 5vw, 46px);
  border: 1px solid rgba(222, 217, 194, 0.9);
  border-radius: 42px;
  background: linear-gradient(150deg, #fff 6%, var(--accent-soft) 130%);
  box-shadow: var(--shadow);
}

.queue-row { display: flex; gap: 10px; }
.queue-card {
  flex: 1;
  aspect-ratio: 3 / 4;
  border-radius: 14px;
  background: linear-gradient(160deg, var(--leaf) 0%, var(--accent) 100%);
}
.queue-card:nth-child(2) { opacity: 0.78; }
.queue-card:nth-child(3) { opacity: 0.58; }
.queue-card:nth-child(4) { opacity: 0.4; }

.puzzle-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  padding: 14px;
  border: 5px solid var(--ink);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 16px 38px rgba(47, 53, 36, 0.18);
}
.puzzle-board .tile {
  aspect-ratio: 1;
  border-radius: 8px;
  background: #f1ede0;
  border: 1px solid rgba(47, 53, 36, 0.12);
}
.puzzle-board .tile:nth-child(odd) { background: #eef1e4; }
.tile-swap {
  background: var(--accent-soft) !important;
  box-shadow: inset 0 0 0 2px var(--accent);
}
.tile-target {
  background: var(--leaf-soft) !important;
  box-shadow: inset 0 0 0 2px var(--leaf);
}

.prop-row { display: flex; gap: 10px; }
.prop-chip {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  font-size: 0.85rem;
  font-weight: 800;
}

.features { padding: 96px 0; border-top: 1px solid var(--border); }
.section-heading { max-width: 760px; margin-bottom: 42px; }
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.feature-grid article,
.document-card,
.faq-grid article {
  border: 1px solid var(--border);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 8px 26px rgba(47, 53, 36, 0.05);
}
.feature-grid article { padding: 30px; }
.feature-grid p,
.privacy-callout p,
.document-heading p,
.document-card p,
.faq-grid p { margin: 0; color: var(--muted); }
.feature-number { display: block; margin-bottom: 26px; color: var(--accent); font-weight: 900; }

.privacy-callout {
  margin: 30px auto 110px;
  padding: clamp(30px, 5vw, 62px);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: end;
  border-radius: 34px;
  background: var(--ink);
  color: #f8f7ee;
}
.privacy-callout p { max-width: 740px; color: #d6d8c6; }
.secondary-link,
.primary-link {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-radius: 15px;
  font-weight: 900;
  text-decoration: none;
}
.secondary-link { background: #f8f7ee; color: var(--ink); white-space: nowrap; }
.primary-link { margin-top: 26px; background: var(--accent); color: #221704; }

.document-page { max-width: 920px; padding: 72px 0 110px; }
.document-heading { max-width: 760px; margin-bottom: 38px; }
.document-heading h1 { font-size: clamp(3rem, 7vw, 5rem); }
.document-heading > p:not(.eyebrow) { font-size: 1.15rem; }
.document-card { padding: clamp(28px, 6vw, 64px); }
.document-card section + section { margin-top: 42px; padding-top: 42px; border-top: 1px solid var(--border); }
.document-card h2,
.faq-grid h2 { margin-bottom: 12px; font-size: 1.4rem; }
.document-card a { color: var(--accent-dark); font-weight: 800; }

.support-heading { text-align: center; margin-inline: auto; }
.faq-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.faq-grid article { padding: 28px; }

footer {
  padding: 44px 0 50px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: start;
  border-top: 1px solid var(--border);
}
footer p { margin: 4px 0 0; color: var(--muted); font-size: 0.9rem; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 20px; }
.footer-links a { color: var(--muted); font-weight: 700; }
.copyright { grid-column: 1 / -1; }

.not-found {
  min-height: 100vh;
  display: grid;
  place-content: center;
  justify-items: center;
  text-align: center;
  padding: 30px;
}
.not-found img { border-radius: 32px; margin-bottom: 24px; }
.not-found h1 { max-width: 720px; font-size: clamp(2.4rem, 6vw, 4.8rem); }
.not-found p:not(.eyebrow) { color: var(--muted); }

@media (max-width: 780px) {
  .site-header { min-height: 74px; }
  nav { gap: 15px; font-size: 0.9rem; }
  .brand span { display: none; }
  .hero { grid-template-columns: 1fr; padding: 48px 0 76px; }
  .hero-visual { min-height: 440px; }
  .feature-grid,
  .faq-grid { grid-template-columns: 1fr; }
  .privacy-callout { grid-template-columns: 1fr; align-items: start; }
  footer { grid-template-columns: 1fr; }
  .footer-links { justify-content: flex-start; }
}

@media (max-width: 460px) {
  .site-header, main, footer { width: min(calc(100% - 28px), var(--max-width)); }
  nav a:first-child { display: none; }
  h1 { font-size: 3.2rem; }
  .hero-visual { min-height: 380px; }
  .board-frame { border-radius: 30px; padding: 22px; gap: 16px; }
  .puzzle-board { border-width: 4px; border-radius: 19px; padding: 10px; }
  .feature-grid article, .faq-grid article { padding: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
