:root {
  color-scheme: light dark;
  --bg: #faf7f2;
  --surface: #ffffff;
  --text: #1f2937;
  --muted: #596273;
  --outline: #d9d6d1;
  --primary: #6d28d9;
  --primary-soft: #ede9fe;
  --shadow: 0 18px 50px rgba(15, 23, 42, .08);
  font-family: Verdana, Geneva, Tahoma, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); line-height: 1.65; }
a { color: var(--primary); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: .14em; }
a:focus-visible { outline: 3px solid #f59e0b; outline-offset: 4px; border-radius: 4px; }
.skip-link { position: fixed; left: 1rem; top: 1rem; max-width: calc(100% - 2rem); transform: translateY(calc(-100% - 2rem)); z-index: 10; padding: .75rem 1rem; background: var(--text); color: var(--surface); }
.skip-link:focus { transform: translateY(0); }
.site-header, footer { width: min(1080px, calc(100% - 2rem)); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.site-header { min-height: 76px; border-bottom: 1px solid var(--outline); }
.brand { min-height: 44px; display: inline-flex; align-items: center; gap: .7rem; color: var(--text); font-weight: 800; text-decoration: none; letter-spacing: -.02em; }
.brand-mark { width: 40px; height: 40px; flex-shrink: 0; display: grid; place-items: center; border-radius: 13px; background: var(--primary); color: white; font-size: .78rem; box-shadow: inset 0 0 0 1px rgba(255,255,255,.28); }
nav { display: flex; gap: .3rem; }
nav a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 .8rem; border-radius: 12px; color: var(--text); text-decoration: none; }
nav a:hover, nav a[aria-current="page"] { background: var(--primary-soft); color: #4c1d95; }
main { width: min(1080px, calc(100% - 2rem)); margin: 0 auto; }
.hero { position: relative; overflow: hidden; margin: 4.5rem 0 2rem; padding: clamp(2rem, 6vw, 4.5rem); border: 1px solid #c4b5fd; border-radius: 32px; background: linear-gradient(135deg, #ffffff 0%, #f5f0ff 72%, #ede9fe 100%); box-shadow: var(--shadow); }
.hero::after { content: ""; position: absolute; width: 240px; height: 240px; right: -80px; bottom: -110px; border: 38px solid rgba(109,40,217,.10); border-radius: 50%; }
.eyebrow { margin: 0 0 .65rem; color: var(--primary); font-size: .78rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.025em; overflow-wrap: anywhere; hyphens: auto; }
h1 { max-width: 820px; margin: 0; font-size: clamp(2.35rem, 7vw, 5rem); }
h2 { margin-top: 2.2rem; font-size: clamp(1.45rem, 3vw, 2rem); }
h3 { margin-top: 1.7rem; }
.lead { max-width: 760px; color: var(--muted); font-size: clamp(1.05rem, 2vw, 1.25rem); }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.6rem; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; padding: .65rem 1rem; border: 1px solid var(--outline); border-radius: 14px; background: var(--surface); color: var(--text); font-weight: 700; text-decoration: none; }
.button.primary { border-color: var(--primary); background: var(--primary); color: white; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.card, .translation, .document { border: 1px solid var(--outline); border-radius: 24px; background: var(--surface); box-shadow: var(--shadow); }
.card { padding: 1.5rem; }
.card h2 { margin-top: 0; font-size: 1.15rem; }
.card p, .translation p { color: var(--muted); }
.translation { margin: 2rem 0 4rem; padding: clamp(1.5rem, 4vw, 2.5rem); overflow-wrap: anywhere; }
.translation h2 { margin-top: 0; }
.document { max-width: 860px; margin: 3rem auto; padding: clamp(1.4rem, 5vw, 4rem); }
.document h1 { font-size: clamp(2.2rem, 6vw, 4rem); }
.document-title { font-size: clamp(2rem, 5vw, 3.25rem); }
.document p, .document li { max-width: 76ch; overflow-wrap: anywhere; }
.language-nav { flex-wrap: wrap; justify-content: flex-start; margin-bottom: 1.25rem; }
.language-nav a { min-width: 44px; text-decoration: underline; }
.document section { scroll-margin-top: 1rem; }
.document hr { margin: 4rem 0; border: 0; border-top: 1px solid var(--outline); }
.steps { display: grid; gap: .8rem; }
.steps article { padding: .15rem 1rem; border-left: 4px solid #c4b5fd; background: color-mix(in srgb, var(--primary-soft) 45%, transparent); }
.policy section > p { color: var(--muted); }
.policy strong { color: var(--text); }
footer { min-height: 92px; padding: 1rem 0; border-top: 1px solid var(--outline); color: var(--muted); font-size: .88rem; }

@media (max-width: 760px) {
  .site-header { align-items: flex-start; flex-wrap: wrap; padding: .8rem 0; }
  .brand > span:last-child { max-width: 10ch; line-height: 1.1; }
  nav { flex-wrap: wrap; justify-content: flex-end; }
  .site-header nav { width: 100%; justify-content: flex-start; }
  nav a { padding: 0 .55rem; }
  .hero { margin-top: 2rem; border-radius: 24px; }
  .grid { grid-template-columns: 1fr; }
  footer { align-items: flex-start; flex-direction: column; justify-content: center; }
}

@media (prefers-color-scheme: dark) {
  :root { --bg: #111827; --surface: #18212f; --text: #f9fafb; --muted: #d1d5db; --outline: #475569; --primary: #c4b5fd; --primary-soft: #4c1d95; --shadow: 0 18px 50px rgba(0,0,0,.26); }
  .brand-mark, .button.primary { background: #8b5cf6; color: #fff; }
  nav a:hover, nav a[aria-current="page"] { color: #ede9fe; }
  .hero { border-color: #6d28d9; background: linear-gradient(135deg, #18212f 0%, #241b38 100%); }
}

@media (prefers-contrast: more) {
  :root { --outline: currentColor; --shadow: none; }
  .card, .translation, .document, .hero, .button { border-width: 2px; }
}

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