:root {
  --bg: #ffffff;
  --bg-alt: #f6f7f9;
  --surface: #ffffff;
  --border: #e7e9ee;
  --text: #14161c;
  --text-soft: #565d6b;
  --accent: #2f6bff;
  --accent-soft: rgba(47, 107, 255, 0.1);
  --shadow: 0 1px 2px rgba(20, 22, 28, 0.04), 0 8px 24px rgba(20, 22, 28, 0.06);
  --radius: 16px;
  --maxw: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="dark"] {
  --bg: #0d0f14;
  --bg-alt: #12151c;
  --surface: #161a22;
  --border: #242a35;
  --text: #f2f4f8;
  --text-soft: #a2abbb;
  --accent: #6b9bff;
  --accent-soft: rgba(107, 155, 255, 0.14);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 12px 32px rgba(0, 0, 0, 0.4);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background 0.4s var(--ease), color 0.4s var(--ease);
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

a { color: inherit; text-decoration: none; }

/* Accessible keyboard focus */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}
a:focus-visible, .btn:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: absolute; left: -999px; top: 8px; z-index: 200;
  background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 10px;
}
.skip-link:focus { left: 8px; }

/* NAV */
.nav {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: saturate(180%) blur(12px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.nav.is-scrolled { border-bottom-color: var(--border); }
.nav__inner { display: flex; align-items: center; gap: 16px; height: 68px; }
.nav__brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.05rem; letter-spacing: -0.02em; }
.nav__logo {
  width: 20px; height: 20px; border-radius: 6px;
  background: conic-gradient(from 210deg, var(--accent), #8f5bff 60%, var(--accent));
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.nav__links { margin-left: auto; display: flex; align-items: center; gap: 28px; }
.nav__links a { color: var(--text-soft); font-weight: 500; font-size: 0.95rem; transition: color 0.2s var(--ease); }
.nav__links a:hover { color: var(--text); }
.nav__cta {
  color: var(--text) !important; border: 1px solid var(--border);
  padding: 8px 16px; border-radius: 999px; transition: all 0.2s var(--ease);
}
.nav__cta:hover { border-color: var(--accent); color: var(--accent) !important; }

.nav__lang {
  font-weight: 600; font-size: 0.85rem; color: var(--text-soft);
  border: 1px solid var(--border); border-radius: 999px; padding: 7px 12px;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.nav__lang:hover { border-color: var(--accent); color: var(--accent); }

.theme-toggle {
  width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--surface); cursor: pointer; display: grid; place-items: center;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-toggle:active { transform: scale(0.94); }
.theme-toggle__icon { width: 16px; height: 16px; border-radius: 50%; background: var(--text); position: relative; transition: all 0.3s var(--ease); }
[data-theme="dark"] .theme-toggle__icon { background: transparent; box-shadow: inset -5px -4px 0 0 var(--text); transform: rotate(-30deg); }

.nav__burger { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav__burger span { width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: transform 0.3s var(--ease), opacity 0.3s var(--ease); }
.nav__burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* HERO */
.hero { position: relative; padding: clamp(72px, 12vw, 140px) 0 clamp(64px, 10vw, 120px); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -20% 30% auto -10%; height: 520px;
  background: radial-gradient(50% 50% at 50% 50%, var(--accent-soft), transparent 70%);
  filter: blur(20px); pointer-events: none;
}
.hero__inner { position: relative; max-width: 820px; }
.hero__eyebrow { color: var(--accent); font-weight: 600; letter-spacing: 0.02em; margin-bottom: 20px; font-size: 0.95rem; }
.hero__title { font-size: clamp(2.2rem, 6vw, 4rem); line-height: 1.06; letter-spacing: -0.03em; font-weight: 700; }
.hero__title span { color: var(--text-soft); }
.hero__lead { margin-top: 24px; font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--text-soft); max-width: 620px; }
.hero__actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 14px; }
.hero__trust { margin-top: 22px; font-size: 0.9rem; color: var(--text-soft); font-weight: 500; }

/* BUTTONS */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 24px; border-radius: 999px; font-weight: 600; font-size: 0.98rem;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  border: 1px solid transparent; cursor: pointer;
}
.btn--primary { background: var(--accent); color: #fff; box-shadow: 0 8px 20px var(--accent-soft); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px var(--accent-soft); }
.btn--ghost { border-color: var(--border); color: var(--text); background: var(--surface); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }

/* SECTIONS */
.section { padding: clamp(64px, 10vw, 120px) 0; }
.section--alt { background: var(--bg-alt); }
.section__head { max-width: 640px; margin-bottom: 56px; }
.section__kicker { color: var(--accent); font-weight: 600; font-size: 0.9rem; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 12px; }
.section__title { font-size: clamp(1.7rem, 4vw, 2.6rem); letter-spacing: -0.025em; line-height: 1.12; font-weight: 700; }
.section__intro { margin-top: 16px; color: var(--text-soft); font-size: 1.08rem; }

/* GRID + CARDS */
.grid { display: grid; gap: 24px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px 28px; transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }
.card__icon { font-size: 1.7rem; width: 52px; height: 52px; display: grid; place-items: center; border-radius: 14px; background: var(--accent-soft); margin-bottom: 20px; }
.card h3 { font-size: 1.2rem; letter-spacing: -0.01em; margin-bottom: 10px; }
.card p { color: var(--text-soft); font-size: 0.98rem; }
.card a { color: var(--accent); font-weight: 600; }

.app-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 30px 28px; transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}
.app-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }
.app-card__icon { font-size: 1.7rem; width: 52px; height: 52px; display: grid; place-items: center; border-radius: 14px; background: var(--accent-soft); margin-bottom: 18px; }
.app-card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.app-card__top h3 { font-size: 1.3rem; letter-spacing: -0.02em; }
.app-card__tag { color: var(--text-soft); font-size: 0.85rem; font-weight: 500; margin: 6px 0 14px; }
.app-card p:last-child { color: var(--text-soft); font-size: 0.98rem; }
.badge {
  font-size: 0.75rem; font-weight: 600; padding: 5px 11px; border-radius: 999px; white-space: nowrap;
  background: var(--accent-soft); color: var(--accent); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
}
.badge--soon { background: rgba(34, 197, 94, 0.12); color: #16a34a; border-color: rgba(34, 197, 94, 0.3); }
[data-theme="dark"] .badge--soon { color: #4ade80; }

/* ABOUT */
.about { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; align-items: center; }
.about__text p { color: var(--text-soft); margin-top: 16px; font-size: 1.05rem; }
.about__stats { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.stat {
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  padding: 24px 20px; text-align: center;
}
.stat:first-child { grid-column: 1 / -1; }
.stat__num { display: block; font-size: 1.9rem; font-weight: 700; letter-spacing: -0.02em; color: var(--accent); }
.stat__label { color: var(--text-soft); font-size: 0.9rem; }

/* CTA */
.section--cta { background: var(--bg-alt); }
.cta { text-align: center; max-width: 720px; margin: 0 auto; }
.cta__lead { color: var(--text-soft); font-size: 1.1rem; margin-top: 16px; }
.cta__actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.cta__mail { margin-top: 24px; color: var(--text-soft); font-size: 0.95rem; }
.cta__mail a { color: var(--accent); font-weight: 600; }

/* FOOTER */
.footer { border-top: 1px solid var(--border); padding: 48px 0 32px; }
.footer__inner { display: flex; flex-wrap: wrap; gap: 24px; justify-content: space-between; align-items: flex-start; }
.footer__brand { font-weight: 700; letter-spacing: -0.02em; }
.footer__addr { color: var(--text-soft); font-size: 0.9rem; margin-top: 6px; }
.footer__links { display: flex; flex-wrap: wrap; gap: 22px; }
.footer__links a { color: var(--text-soft); font-size: 0.9rem; transition: color 0.2s var(--ease); }
.footer__links a:hover { color: var(--accent); }
.footer__copy { color: var(--text-soft); font-size: 0.82rem; margin-top: 32px; }

/* REVEAL ANIMATION */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

/* LEGAL PAGES */
.legal { padding: clamp(48px, 8vw, 96px) 0; max-width: 760px; }
.legal h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); letter-spacing: -0.02em; margin-bottom: 8px; }
.legal h2 { font-size: 1.2rem; margin: 32px 0 8px; }
.legal p, .legal address { color: var(--text-soft); font-style: normal; margin-bottom: 8px; }
.legal a { color: var(--accent); }
.legal .back { display: inline-block; margin-bottom: 32px; color: var(--accent); font-weight: 600; }

/* RESPONSIVE */
@media (max-width: 900px) {
  .grid--3 { grid-template-columns: 1fr; }
  .about { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 720px) {
  .grid--2 { grid-template-columns: 1fr; }
  .theme-toggle { margin-left: auto; }
  .nav__burger { display: flex; }
  .nav__links {
    position: fixed; inset: 68px 0 auto 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border);
    padding: 8px 24px 20px; margin: 0;
    transform: translateY(-120%); transition: transform 0.35s var(--ease); align-items: stretch;
  }
  .nav__links.is-open { transform: translateY(0); }
  .nav__links a { padding: 14px 0; border-bottom: 1px solid var(--border); }
  .nav__links a:last-child { border-bottom: 0; }
  .nav__cta { text-align: center; margin-top: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
