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

:root {
  --bg: #f6f9fc;
  --bg-alt: #eef3f8;
  --surface: #ffffff;
  --surface-hover: #f8fafc;
  --border: #dbe4ee;
  --border-light: #c5d3e0;
  --text: #152535;
  --text-muted: #5a6b7d;
  --text-dim: #8496a8;
  --accent: #0d9488;
  --accent-dark: #0f766e;
  --accent-light: #14b8a6;
  --accent-glow: rgba(13, 148, 136, 0.14);
  --on-accent: #ffffff;
  --teal: #0891b2;
  --teal-dim: rgba(8, 145, 178, 0.1);
  --success: #10b981;
  --danger: #ef4444;
  --radius: 12px;
  --radius-lg: 20px;
  --font: 'Instrument Sans', system-ui, sans-serif;
  --serif: 'Newsreader', Georgia, serif;
  --max: 1140px;
  --nav-h: 72px;
  --reveal-ease: cubic-bezier(0.16, 1, 0.3, 1);
  --reveal-duration: 0.85s;
}

html { scroll-behavior: smooth; font-size: 16px; -webkit-font-smoothing: antialiased; }

body {
  font-family: var(--font);
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(56, 189, 248, 0.08), transparent 55%),
    linear-gradient(180deg, #f8fbfe 0%, var(--bg) 35%),
    var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 1.5rem; }
.container-narrow { max-width: 720px; }

.view { display: none; }
.view.active { display: block; }

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.02em; }
h1 { font-family: var(--serif); font-size: clamp(2.5rem, 5.5vw, 3.75rem); font-weight: 500; }
h1 em { font-style: italic; color: var(--accent); }
h2 { font-family: var(--serif); font-size: clamp(1.75rem, 3.5vw, 2.5rem); font-weight: 500; margin-bottom: 0.75rem; }
h3 { font-size: 1.1rem; font-weight: 600; }

/* Nav */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  transition: background 0.3s, border-color 0.3s;
}

.nav.scrolled {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 24px rgba(21, 37, 53, 0.06);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 1.05rem;
}

.logo small { font-weight: 500; color: var(--text-muted); font-size: 0.85rem; }

.nav-links { display: flex; align-items: center; gap: 2rem; }
.nav-links a { color: var(--text-muted); text-decoration: none; font-size: 0.9rem; font-weight: 500; transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }

.nav-cta {
  background: var(--accent) !important;
  color: var(--on-accent) !important;
  padding: 0.5rem 1.1rem;
  border-radius: 8px;
  font-weight: 600 !important;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-left: auto;
  margin-right: 1rem;
}

.lang-switch button {
  padding: 0.35rem 0.65rem;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.lang-switch button:hover {
  color: var(--text);
}

.lang-switch button.active {
  background: var(--accent);
  color: var(--on-accent);
}

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: transform 0.3s, opacity 0.3s; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 10px;
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.15s;
}

.btn:hover { opacity: 0.9; }
.btn-primary {
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  color: var(--on-accent);
  box-shadow: 0 4px 20px rgba(13, 148, 136, 0.22);
}
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-full { width: 100%; }
.btn-lg { padding: 1rem 1.5rem; font-size: 1rem; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 3rem) 0 4rem;
  overflow: hidden;
}

.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-orb { position: absolute; border-radius: 50%; filter: blur(80px); }
.hero-orb-1 { width: 500px; height: 500px; background: rgba(13, 148, 136, 0.14); top: -100px; right: -100px; }
.hero-orb-2 { width: 400px; height: 400px; background: rgba(56, 189, 248, 0.12); bottom: -50px; left: -100px; }

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(21, 37, 53, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(21, 37, 53, 0.04) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black, transparent);
}

.hero-content {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-sub { font-size: 1.15rem; color: var(--text-muted); margin: 1.5rem 0 2rem; max-width: 480px; line-height: 1.7; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3rem; }
.hero-stats { display: flex; align-items: center; gap: 1.5rem; }
.stat-num { display: block; font-size: 1.5rem; font-weight: 700; color: var(--accent); }
.stat-label { font-size: 0.8rem; color: var(--text-dim); }
.stat-divider { width: 1px; height: 32px; background: var(--border); }

/* Hero visual */
.hero-visual { position: relative; padding-right: 20px; padding-bottom: 20px; }

.visual-card { border-radius: var(--radius-lg); border: 1px solid var(--border); }

.visual-card-back {
  position: absolute;
  top: 0; left: 0; right: 20px; bottom: 20px;
  transform: translate(20px, 20px);
  background: var(--bg-alt);
  opacity: 0.5;
  z-index: 0;
}

.visual-card-main {
  position: relative;
  z-index: 1;
  background: var(--surface);
  box-shadow: 0 20px 50px rgba(21, 37, 53, 0.1);
  overflow: hidden;
}

.visual-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}

.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot-red { background: #f87171; }
.dot-yellow { background: #fbbf24; }
.dot-green { background: #34d399; }
.visual-title { margin-left: 0.5rem; font-size: 0.8rem; color: var(--text-muted); font-weight: 500; }
.radar-preview { padding: 1rem; display: flex; justify-content: center; }

/* Sections */
.section { padding: 6rem 0; }
.section-alt { background: var(--bg-alt); }
.section-header { text-align: center; max-width: 640px; margin: 0 auto 3.5rem; }
.section-header p { color: var(--text-muted); font-size: 1.05rem; }

.trust-bar { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 2rem 0; background: var(--bg-alt); }
.trust-inner { text-align: center; }
.trust-inner > p { font-size: 0.8rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em; }

.steps {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 1.5rem;
  align-items: start;
}

.step { text-align: center; padding: 1.5rem; }
.step-num { font-size: 0.8rem; font-weight: 700; color: var(--accent); margin-bottom: 0.75rem; }
.step h3 { margin-bottom: 0.5rem; }
.step p { color: var(--text-muted); font-size: 0.9rem; }
.step-connector {
  width: 40px;
  height: 1px;
  background: var(--border);
  margin-top: 2.5rem;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.6s var(--reveal-ease);
  transition-delay: var(--reveal-delay, 0.2s);
}

.step-connector.is-visible { transform: scaleX(1); }
.steps > .step-connector:nth-child(2) { --reveal-delay: 0.15s; }
.steps > .step-connector:nth-child(4) { --reveal-delay: 0.35s; }

.dimension-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.dimension-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: 0 4px 16px rgba(21, 37, 53, 0.04);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.dimension-card:hover {
  border-color: var(--accent);
  box-shadow: 0 8px 24px rgba(21, 37, 53, 0.08);
}
.dimension-icon { font-size: 1.75rem; display: block; margin-bottom: 0.75rem; }
.dimension-card p { color: var(--text-muted); font-size: 0.85rem; margin-top: 0.35rem; }

/* Start form */
.start-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  text-align: center;
  box-shadow: 0 8px 32px rgba(21, 37, 53, 0.06);
}

.start-card h2 { margin-bottom: 0.5rem; }
.start-card > p { color: var(--text-muted); margin-bottom: 1.5rem; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; text-align: left; }
.form-group { margin-bottom: 1.25rem; text-align: left; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.4rem; color: var(--text-muted); }
.form-group input {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.95rem;
}

.form-group input:focus { outline: none; border-color: var(--accent); }
.start-error { color: var(--danger); font-size: 0.9rem; margin-bottom: 1rem; text-align: center; }

/* Quiz */
.quiz-section { padding: calc(var(--nav-h) + 3rem) 0 4rem; min-height: 100vh; }
.quiz-progress { margin-bottom: 2rem; }
.progress-track { height: 6px; background: var(--surface); border-radius: 3px; overflow: hidden; margin-bottom: 0.75rem; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent-dark)); border-radius: 3px; transition: width 0.3s; width: 0; }
.progress-text { font-size: 0.85rem; color: var(--text-muted); }

.quiz-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 8px 32px rgba(21, 37, 53, 0.06);
}

.question-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.question-category {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-glow);
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
}

.question-maturity { font-size: 0.8rem; color: var(--text-dim); }
.question-text { font-size: 1.2rem; margin-bottom: 1.5rem; line-height: 1.5; }

.question-options { display: flex; flex-direction: column; gap: 0.65rem; margin-bottom: 2rem; }

.option-btn {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  width: 100%;
  text-align: left;
  padding: 1rem 1.15rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.95rem;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.option-btn:hover { border-color: var(--border-light); background: var(--surface-hover); }
.option-btn.selected { border-color: var(--accent); background: var(--accent-glow); }

.option-score {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50%;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
}

.option-btn.selected .option-score {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
}

.option-text { line-height: 1.45; }

.quiz-nav { display: flex; justify-content: space-between; gap: 1rem; }

/* Results */
.results-section { padding: calc(var(--nav-h) + 3rem) 0 4rem; }
.results-header { text-align: center; margin-bottom: 3rem; }
.results-sub { color: var(--text-muted); font-size: 1.05rem; }

.results-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.results-chart-card,
.results-scores-card,
.results-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: 0 4px 20px rgba(21, 37, 53, 0.05);
}

.results-chart-card h3,
.results-scores-card h3,
.results-card h3 { margin-bottom: 1.25rem; }

.chart-wrap {
  position: relative;
  max-width: 420px;
  margin: 0 auto;
}

.chart-legend {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.legend-item { display: flex; align-items: center; gap: 0.4rem; }
.legend-dot { width: 10px; height: 10px; border-radius: 50%; }
.legend-dot.current { background: var(--accent); }
.legend-dot.target { background: var(--teal); }

.gap-bars { display: flex; flex-direction: column; gap: 1rem; }

.gap-row-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  margin-bottom: 0.4rem;
}

.gap-value { font-weight: 600; color: var(--accent); }
.gap-value small { color: var(--text-dim); font-weight: 500; }

.gap-track {
  position: relative;
  height: 8px;
  background: var(--bg);
  border-radius: 4px;
  overflow: visible;
}

.gap-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-dark));
  border-radius: 4px;
  transition: width 0.6s ease;
}

.gap-target {
  position: absolute;
  top: -3px;
  width: 2px;
  height: 14px;
  background: var(--teal);
  border-radius: 1px;
  transform: translateX(-50%);
}

.overall-score {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.overall-label { color: var(--text-muted); font-size: 0.9rem; }
.overall-value { font-size: 2rem; font-weight: 700; color: var(--accent); font-family: var(--serif); }

.recommendations { list-style: none; display: flex; flex-direction: column; gap: 0.85rem; }
.recommendations li {
  padding: 1rem 1.15rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
}

.recommendations strong { color: var(--text); display: block; margin-bottom: 0.25rem; }

.results-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* Footer */
.footer { border-top: 1px solid var(--border); padding: 3rem 0 1.5rem; margin-top: 2rem; }
.footer-inner { display: grid; grid-template-columns: 1.5fr 1fr; gap: 3rem; margin-bottom: 2rem; }
.footer-brand p { color: var(--text-muted); font-size: 0.9rem; margin-top: 0.75rem; max-width: 280px; }
.footer-links h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-dim); margin-bottom: 1rem; }
.footer-links a { display: block; color: var(--text-muted); text-decoration: none; font-size: 0.9rem; margin-bottom: 0.5rem; }
.footer-links a:hover { color: var(--text); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 1.5rem; }
.footer-bottom p { font-size: 0.8rem; color: var(--text-dim); }

/* Scroll reveal animations */
.scroll-reveal,
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity var(--reveal-duration) var(--reveal-ease),
    transform var(--reveal-duration) var(--reveal-ease);
  transition-delay: var(--reveal-delay, 0s);
  will-change: opacity, transform;
}

.scroll-reveal.is-visible,
.reveal.visible { opacity: 1; transform: translateY(0); }

.scroll-reveal--left { transform: translateX(-36px); }
.scroll-reveal--left.is-visible { transform: translateX(0); }
.scroll-reveal--right { transform: translateX(36px); }
.scroll-reveal--right.is-visible { transform: translateX(0); }
.scroll-reveal--scale { transform: scale(0.94); }
.scroll-reveal--scale.is-visible { transform: scale(1); }
.scroll-reveal--fade { transform: none; }
.scroll-reveal--fade.is-visible { transform: none; }

.scroll-delay-1, .reveal-delay-1 { --reveal-delay: 0.1s; }
.scroll-delay-2, .reveal-delay-2 { --reveal-delay: 0.2s; }
.scroll-delay-3, .reveal-delay-3 { --reveal-delay: 0.3s; }
.scroll-delay-4, .reveal-delay-4 { --reveal-delay: 0.4s; }

.scroll-stagger > .scroll-reveal:nth-child(1),
.scroll-stagger > *:nth-child(1).scroll-reveal { --reveal-delay: 0s; }
.scroll-stagger > .scroll-reveal:nth-child(2),
.scroll-stagger > *:nth-child(2).scroll-reveal { --reveal-delay: 0.08s; }
.scroll-stagger > .scroll-reveal:nth-child(3),
.scroll-stagger > *:nth-child(3).scroll-reveal { --reveal-delay: 0.16s; }
.scroll-stagger > .scroll-reveal:nth-child(4),
.scroll-stagger > *:nth-child(4).scroll-reveal { --reveal-delay: 0.24s; }
.scroll-stagger > .scroll-reveal:nth-child(5),
.scroll-stagger > *:nth-child(5).scroll-reveal { --reveal-delay: 0.32s; }
.scroll-stagger > .scroll-reveal:nth-child(6),
.scroll-stagger > *:nth-child(6).scroll-reveal { --reveal-delay: 0.4s; }

.stat-num.counting { display: inline-block; }

.hero-visual.is-visible .visual-card-main {
  animation: heroCardFloat 6s ease-in-out infinite;
}

@keyframes heroCardFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

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

  .scroll-reveal,
  .reveal,
  .step-connector {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .hero-visual.is-visible .visual-card-main { animation: none; }
}

/* Responsive */
@media (max-width: 960px) {
  .hero-content { grid-template-columns: 1fr; gap: 3rem; }
  .hero-visual { max-width: 480px; margin: 0 auto; }
  .steps { grid-template-columns: 1fr; gap: 2rem; }
  .step-connector { display: none; }
  .dimension-grid { grid-template-columns: 1fr 1fr; }
  .results-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .lang-switch {
    margin-right: 0.75rem;
  }

  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0; right: 0;
    background: rgba(255, 255, 255, 0.98);
    flex-direction: column;
    padding: 1.5rem;
    gap: 1rem;
    border-bottom: 1px solid var(--border);
    transform: translateY(-120%);
    opacity: 0;
    transition: transform 0.3s, opacity 0.3s;
    pointer-events: none;
  }
  .nav-links.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .dimension-grid { grid-template-columns: 1fr; }
}