:root {
  --navy: #102D4E;
  --navy-deep: #0F172A;
  --bg: #ffffff;
  --bg-alt: #F8FAFC;
  --text: #0F172A;
  --text-muted: #59636e;
  --border: #E7ECF3;
  --accent: #0EA5D8;
  --accent-2: #22E5C7;
  --accent-bg: #EAF7FB;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0F172A;
    --bg-alt: #16223A;
    --text: #E6E8EB;
    --text-muted: #A2ACB8;
    --border: #24334C;
    --accent: #38D3F0;
    --accent-2: #22E5C7;
    --accent-bg: #16283A;
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.65;
}
a { color: var(--accent); }

/* ---------- Site header / footer (shared) ----------
   The header always uses a light background with dark content,
   regardless of the page/system color scheme, so it stays legible
   even when the rest of the page switches to dark mode. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid #E7ECF3;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.02);
}
.site-header .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 16px 24px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { height: 26px; width: auto; display: block; }
.site-nav { display: flex; align-items: center; gap: 18px; }
.site-nav a:not(.btn) {
  color: #334155;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
}
.site-nav a:not(.btn):hover { color: var(--navy); }
.site-nav .btn { margin-left: 4px; }

/* Language switch pill, always light (lives inside the light header) */
.lang-switch {
  display: flex;
  align-items: center;
  background: #EEF2F7;
  border: 1px solid #E7ECF3;
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
}
.lang-switch button {
  appearance: none;
  border: none;
  background: transparent;
  color: #59636e;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 5px 11px;
  border-radius: 999px;
  cursor: pointer;
  line-height: 1.2;
}
.lang-switch button.active {
  background: var(--navy);
  color: #fff;
}
.lang-switch button:not(.active):hover { color: var(--navy); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent-2), var(--accent) 70%);
  color: #04222c;
}
.btn-primary:hover { filter: brightness(1.05); }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
}

.site-footer {
  margin-top: 80px;
  border-top: 1px solid var(--border);
  padding: 36px 24px 40px;
}
.site-footer .inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
  color: var(--text-muted);
  font-size: 0.88rem;
}
.site-footer .links { display: flex; gap: 20px; flex-wrap: wrap; }
.site-footer a { color: var(--text-muted); text-decoration: none; }
.site-footer a:hover { color: var(--accent); }

/* ---------- Legal document pages (termini / privacy) ---------- */
.wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 16px 24px 96px;
}
.legal-header { margin-bottom: 40px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.legal-header h1 { font-size: 1.9rem; margin: 0 0 8px; letter-spacing: -0.01em; }
.updated { color: var(--text-muted); font-size: 0.95rem; }
.intro {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 20px;
  margin: 24px 0;
  font-size: 0.97rem;
}
.intro p { margin: 0 0 10px; }
.intro p:last-child { margin-bottom: 0; }
nav.toc {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 40px;
}
nav.toc h2 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin: 0 0 12px;
}
nav.toc ol {
  columns: 2;
  -webkit-columns: 2;
  column-gap: 32px;
  margin: 0;
  padding-left: 20px;
  font-size: 0.92rem;
}
nav.toc li { break-inside: avoid; margin-bottom: 6px; }
nav.toc a { color: var(--accent); text-decoration: none; }
nav.toc a:hover { text-decoration: underline; }
section.legal { margin: 36px 0; scroll-margin-top: 20px; }
section.legal h2 {
  font-size: 1.25rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
  margin: 0 0 14px;
}
section.legal h3 { font-size: 1.02rem; margin: 20px 0 8px; color: var(--text); }
.legal p { margin: 0 0 12px; }
.legal ul { padding-left: 22px; margin: 0 0 12px; }
.legal li { margin-bottom: 6px; }
.legal strong { font-weight: 600; }
.legal table { width: 100%; border-collapse: collapse; margin: 12px 0 16px; font-size: 0.92rem; }
.legal th, .legal td { text-align: left; padding: 8px 10px; border: 1px solid var(--border); vertical-align: top; }
.legal th { background: var(--bg-alt); }
code, .placeholder {
  background: var(--accent-bg);
  color: var(--accent);
  padding: 1px 6px;
  border-radius: 5px;
  font-size: 0.85em;
}
.note {
  font-size: 0.85rem;
  color: var(--text-muted);
  border-left: 3px solid var(--accent);
  padding: 8px 14px;
  background: var(--accent-bg);
  border-radius: 0 6px 6px 0;
  margin: 12px 0;
}
.back-top { display: inline-block; margin-top: 8px; font-size: 0.82rem; color: var(--text-muted); text-decoration: none; }
.back-top:hover { color: var(--accent); }

@media (max-width: 640px) {
  nav.toc ol { columns: 1; }
  .wrap { padding: 8px 18px 64px; }
  .site-nav { gap: 12px; }
  .site-nav a:not(.btn) { display: none; }
}

/* ---------- Landing page ---------- */
.hero {
  max-width: 1080px;
  margin: 0 auto;
  padding: 60px 24px 40px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}
.hero-copy .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-bg);
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.hero-copy h1 {
  font-size: clamp(2rem, 4vw, 2.9rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
}
.hero-copy h1 .grad {
  background: linear-gradient(120deg, var(--accent-2), var(--accent) 65%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-copy p.lead {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin: 0 0 28px;
  max-width: 46ch;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--navy);
  color: #fff;
  text-decoration: none;
  font-size: 0.85rem;
  border: 1px solid var(--navy);
}
@media (prefers-color-scheme: dark) {
  .store-badge { background: #1c2c44; border-color: #2a3a54; }
}
.store-badge svg { flex-shrink: 0; }
.store-badge .store-text { display: flex; flex-direction: column; line-height: 1.2; }
.store-badge .store-text small { font-size: 0.68rem; opacity: 0.8; }
.store-badge .store-text strong { font-size: 0.95rem; }
.store-badge[aria-disabled="true"] { opacity: 0.6; pointer-events: none; }
.soon-tag {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 6px;
}

.hero-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-art .glow {
  position: absolute;
  inset: -10%;
  background: radial-gradient(closest-side, var(--accent-bg), transparent 70%);
  filter: blur(4px);
  z-index: 0;
}
.hero-art .phone-mock {
  position: relative;
  z-index: 1;
  width: min(280px, 70vw);
  aspect-ratio: 9/18;
  border-radius: 34px;
  background: var(--navy);
  padding: 12px;
  box-shadow: 0 30px 60px -20px rgba(16,45,78,0.45);
}
.hero-art .phone-screen {
  width: 100%;
  height: 100%;
  border-radius: 24px;
  background: var(--bg-alt);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hero-art .phone-topbar {
  padding: 16px 16px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.hero-art .phone-topbar img { height: 18px; width: auto; }
.hero-art .phone-card {
  margin: 8px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
}
.hero-art .phone-card .row {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.hero-art .phone-card .row strong { color: var(--text); font-weight: 600; }
.hero-art .phone-total {
  margin: 4px 14px 14px;
  background: linear-gradient(135deg, var(--accent-2), var(--accent) 70%);
  border-radius: 12px;
  padding: 14px;
  color: #04222c;
}
.hero-art .phone-total small { display: block; font-size: 0.68rem; opacity: 0.75; }
.hero-art .phone-total strong { font-size: 1.35rem; }

.section {
  max-width: 1080px;
  margin: 0 auto;
  padding: 64px 24px;
}
.section-head { text-align: center; max-width: 620px; margin: 0 auto 44px; }
.section-head .kicker {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.section-head h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin: 10px 0 12px; letter-spacing: -0.01em; }
.section-head p { color: var(--text-muted); margin: 0; }

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 24px;
}
.feature-card .icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent-2), var(--accent) 70%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  color: #04222c;
}
.feature-card h3 { margin: 0 0 8px; font-size: 1.05rem; }
.feature-card p { margin: 0; color: var(--text-muted); font-size: 0.92rem; }

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  counter-reset: step;
}
.step { position: relative; padding-left: 46px; }
.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0; top: 0;
  width: 32px; height: 32px;
  border-radius: 999px;
  background: var(--navy);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}
@media (prefers-color-scheme: dark) { .step::before { background: #24344e; } }
.step h3 { margin: 2px 0 6px; font-size: 1rem; }
.step p { margin: 0; color: var(--text-muted); font-size: 0.92rem; }

.cta-band {
  max-width: 1080px;
  margin: 0 auto 64px;
  padding: 48px 40px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--navy), #0b2237);
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.cta-band h2 { margin: 0 0 6px; font-size: 1.5rem; }
.cta-band p { margin: 0; color: #b9c6d8; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; padding-top: 32px; }
  .hero-art { order: -1; }
  .features { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .cta-band { flex-direction: column; text-align: center; }
}
