/* NoAutonomo.ai landing. Contract: DESIGN.md.
   Token values are copied from spain-autonomo-taxes/frontend/src/styles/styles.css (:root);
   tests/test_landing.py fails when the shared tokens drift.
   The application is the owner: change it first, then this copy. */
:root {
  color-scheme: light;
  --bg: #f4f6f5;
  --surface: #ffffff;
  --surface-muted: #eef2f0;
  --text: #18211f;
  --muted: #66706d;
  --line: #d8dfdc;
  --sidebar: #202927;
  --sidebar-muted: #9fb0aa;
  --accent: #11866f;
  --accent-dark: #0b6b59;
  --accent-soft: #dcefe9;
  --radius: 6px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 106.25%;
  line-height: 1.5;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; color: var(--text); background: var(--bg); overflow-wrap: anywhere; }
a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; }
a:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

.skip { position: absolute; left: 16px; top: 16px; transform: translateY(-200%); padding: 8px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.skip:focus { transform: none; z-index: 10; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }

/* Header */
header.site { border-bottom: 1px solid var(--line); background: var(--surface); }
header.site .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; min-height: 64px; }
.wordmark { font-weight: 700; font-size: 1.1rem; color: var(--text); text-decoration: none; }
.wordmark span { color: var(--accent-dark); }
nav.site { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-left: auto; align-items: center; }
nav.site a { color: var(--text); text-decoration: none; padding: 8px 0; min-height: 40px; display: inline-flex; align-items: center; }
nav.site a:hover { text-decoration: underline; }
nav.site a.button { min-height: 44px; padding: 0 18px; }
.languages { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-left: auto; }
.languages a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text); }
.languages a[aria-current="page"] { color: var(--accent-dark); font-weight: 700; text-decoration-thickness: 2px; }

/* Buttons: same shape as .primary-button/.secondary-button in the app */
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; border-radius: 5px; border: 1px solid transparent; font-weight: 650; text-decoration: none; }
.button.primary { color: #fff; background: var(--accent); border-color: var(--accent); }
.button.primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.button.secondary { color: var(--text); background: var(--surface); border-color: var(--line); }
.button.secondary:hover { border-color: var(--text); }

/* Type and rhythm */
section { padding: 64px 0; }
section + section { border-top: 1px solid var(--line); }
h1 { font-size: 2.25rem; line-height: 1.15; margin: 0 0 16px; max-width: 20ch; }
h2 { font-size: 1.5rem; line-height: 1.25; margin: 0 0 24px; font-weight: 650; }
h3 { font-size: 1.05rem; margin: 0 0 8px; }
p { margin: 0 0 16px; max-width: 68ch; }
.lead { font-size: 1.2rem; max-width: 56ch; }
.muted { color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0 40px; }
.after-quote { margin-top: 16px; }

/* Hero and the DEMO-001 trail */
.hero .wrap { display: grid; gap: 40px; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; }
.trail { list-style: none; margin: 0; padding: 0; }
.trail li { position: relative; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.trail li + li { margin-top: 28px; }
.trail li + li::before { content: "↓"; position: absolute; top: -26px; left: 18px; color: var(--muted); font-size: 1.1rem; line-height: 1; }
.trail small { display: block; color: var(--muted); font-size: 0.85rem; margin-bottom: 4px; }
.trail strong { display: block; font-size: 1.15rem; }
.trail .row { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; flex-wrap: wrap; }
.trail .amount { font-variant-numeric: tabular-nums; font-size: 1.15rem; font-weight: 650; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 0.8rem; font-weight: 600; }
.badge.ok { color: #07573f; background: var(--accent-soft); }
.badge.neutral { color: var(--text); background: var(--surface-muted); }
.caption { font-size: 0.9rem; color: var(--muted); margin-top: 12px; }

/* Sections */
.cols { display: grid; gap: 24px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cols.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.panel ul { margin: 0; padding-left: 20px; }
.panel li + li { margin-top: 8px; }
.steps { counter-reset: n; display: grid; gap: 24px; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0; padding: 0; list-style: none; }
.steps li { counter-increment: n; }
.steps li::before { content: counter(n); display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--accent-soft); color: #07573f; font-weight: 700; margin-bottom: 12px; }
.product-preview { margin: 24px 0 0; }
.product-preview img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius); }
blockquote { margin: 0; padding: 0 0 0 20px; border-left: 3px solid var(--accent); max-width: 60ch; }
blockquote p { font-size: 1.15rem; }
.invite { background: var(--surface); }
.invite .wrap { display: grid; gap: 24px; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: center; }
.invite .actions { margin: 0; }

/* Footer */
footer { background: var(--sidebar); color: #fff; padding: 40px 0; font-size: 0.95rem; }
footer a { color: #fff; }
footer .wrap { display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
footer p { color: var(--sidebar-muted); margin: 0; }

@media (max-width: 760px) {
  :root { font-size: 100%; }
  section { padding: 48px 0; }
  h1 { font-size: 1.75rem; }
  nav.site a:not(.button) { display: none; }
  .languages { flex-basis: 100%; margin-left: 0; border-top: 1px solid var(--line); }
  .hero .wrap, .cols, .cols.two, .steps, .invite .wrap, footer .wrap { grid-template-columns: minmax(0, 1fr); }
  .actions .button { flex: 1 1 100%; }
}

@media print {
  header.site nav, .skip { display: none; }
  footer { color: var(--text); background: none; }
  footer a, footer p { color: var(--text); }
}
