:root {
  --color-dark: #17203F;
  --color-paper: #FCFCFD;
  --color-text: #151823;
  --color-brand: #1441EB;
  --color-accent: #6EEDBD;
  --radius-card: 8px;
  --radius-btn: 6px;
  --card-border: 0;
  --card-shadow: 0 10px 28px -14px rgba(21, 24, 35, 0.3);
  --section-y: clamp(5rem, 10vw, 9rem);
  --gap: clamp(1.5rem, 3vw, 2.5rem);
  --content-max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--color-paper);
  color: var(--color-text);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--color-brand); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--color-brand); text-decoration: underline; }

/* Surface Utilities */
.surface-dark { background: var(--color-dark); color: var(--color-paper); }
.surface-dark a { color: var(--color-accent); }
.surface-dark .hl { color: var(--color-accent); }
.surface-paper { background: var(--color-paper); color: var(--color-text); }
.surface-paper a { color: var(--color-brand); }
.surface-paper .hl { color: var(--color-brand); }

/* Container */
.container { max-width: var(--content-max); margin: 0 auto; padding: 0 var(--gap); }

/* Sections */
.section { padding-block: var(--section-y); position: relative; }
.section + .section { border-top: 1px solid rgba(21, 24, 35, 0.1); }
.surface-dark .section + .section { border-color: rgba(252, 252, 253, 0.1); }

/* Typography */
h1, h2, h3 { font-weight: 700; letter-spacing: 0.02em; line-height: 1.2; }
h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: calc(var(--gap) * 0.5); }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); margin-bottom: calc(var(--gap) * 0.25); }
.subtitle { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.14em; margin-bottom: 0.5rem; color: var(--color-brand); }
.surface-dark .subtitle { color: var(--color-accent); }
p { margin-bottom: 1rem; max-width: 38em; }
ul, ol { padding-left: 1.25rem; margin-bottom: 1rem; }
li { margin-bottom: 0.5rem; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1.5rem; border-radius: var(--radius-btn);
  font-weight: 600; font-size: 1rem; cursor: pointer;
  transition: transform 0.2s, opacity 0.2s, background 0.2s;
}
.btn-primary { background: var(--color-accent); color: var(--color-dark); border: none; }
.btn-primary:hover { transform: translateY(-2px); opacity: 0.95; }
.btn-secondary { background: transparent; border: 1px solid var(--color-text); color: var(--color-text); }
.surface-dark .btn-secondary { border-color: var(--color-paper); color: var(--color-paper); }
.btn:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }

/* Cards */
.card {
  background: var(--color-paper); border: var(--card-border);
  border-radius: var(--radius-card); box-shadow: var(--card-shadow);
  padding: var(--gap); transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 14px 32px -12px rgba(21, 24, 35, 0.35); }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: var(--gap); }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: var(--gap); }

/* Tables */
table { width: 100%; max-width: 100%; border-collapse: collapse; margin: 1rem 0; table-layout: auto; }
th, td { padding: 0.75rem 1rem; text-align: left; border-bottom: 1px solid rgba(21, 24, 35, 0.1); overflow-wrap: break-word; word-break: break-word; }
th { font-weight: 600; }
tr:last-child td { border-bottom: none; }

/* Details/FAQ */
details { margin-bottom: 1rem; border: 1px solid rgba(21, 24, 35, 0.1); border-radius: var(--radius-card); overflow: hidden; }
summary { padding: 1rem; cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; align-items: center; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 1.2rem; }
details[open] summary::after { content: "−"; }
details p { padding: 0 1rem 1rem; margin: 0; }

/* Header/Footer */
header { position: sticky; top: 0; z-index: 100; background: rgba(252, 252, 253, 0.95); backdrop-filter: blur(8px); border-bottom: 1px solid rgba(21, 24, 35, 0.08); }
.nav-wrap { display: flex; justify-content: space-between; align-items: center; height: 64px; }
nav { display: flex; gap: 1.5rem; align-items: center; }
nav a { font-weight: 500; font-size: 0.95rem; }
nav a[aria-current="page"] { color: var(--color-brand); font-weight: 700; }
footer { padding: var(--section-y) 0; border-top: 1px solid rgba(21, 24, 35, 0.1); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: var(--gap); }
.footer-col h4 { margin-bottom: 0.75rem; font-weight: 600; }
.footer-col a { display: block; margin-bottom: 0.5rem; font-size: 0.9rem; }

/* SVG Animation Classes */
.svg-anim { width: 100%; height: auto; }
@keyframes draw-line { to { stroke-dashoffset: 0; } }
@keyframes float-up { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes rotate-sync { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
@keyframes breathe { 0%, 100% { opacity: 0.4; } 50% { opacity: 1; } }
@keyframes slide-in { from { transform: translateX(20px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.anim-draw { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw-line 4s ease-in-out infinite alternate; }
.anim-float { animation: float-up 6s ease-in-out infinite; }
.anim-rotate { animation: rotate-sync 12s linear infinite; transform-box: fill-box; transform-origin: center; }
.anim-breathe { animation: breathe 4s ease-in-out infinite; }
.anim-slide { animation: slide-in 5s ease-out infinite alternate; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
