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

/* ── Tokens ─────────────────────────────────────────────────────── */
:root {
  --blue: #007AFF;
  --blue-hover: #0066D6;
  --blue-pale: #EBF3FF;
  --ink: #0D1117;
  --ink-secondary: #4B5563;
  --ink-muted: #9CA3AF;
  --border: #E5E7EB;
  --surface: #F7F8FA;
  --white: #FFFFFF;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
}

/* ── i18n ───────────────────────────────────────────────────────── */
[data-lang] { display: none; }
[data-lang].active { display: revert; }

/* ── Base ───────────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

/* ── Reveal animation ───────────────────────────────────────────── */
@keyframes reveal-up {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
}

.reveal.visible {
  animation: reveal-up 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.reveal-d1.visible { animation-delay: 0.08s; }
.reveal-d2.visible { animation-delay: 0.16s; }
.reveal-d3.visible { animation-delay: 0.24s; }
.reveal-d4.visible { animation-delay: 0.32s; }

/* ── Header ─────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 32px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 21px;
  font-weight: 800;
  color: var(--blue);
  text-decoration: none;
  letter-spacing: -0.4px;
}
.logo:hover { text-decoration: none; }

.header-right {
  display: flex;
  align-items: center;
  gap: 28px;
}

.header-nav {
  display: flex;
  gap: 24px;
}

.header-nav a {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-secondary);
  text-decoration: none;
  letter-spacing: -0.1px;
  transition: color 0.2s;
}
.header-nav a:hover {
  color: var(--ink);
  text-decoration: none;
}

.lang-toggle {
  display: flex;
  border-radius: 8px;
  overflow: hidden;
  border: 1.5px solid var(--border);
}

.lang-toggle button {
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  padding: 5px 12px;
  border: none;
  background: transparent;
  color: var(--ink-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.lang-toggle button.active {
  background: var(--blue);
  color: var(--white);
}

/* ── Hero ───────────────────────────────────────────────────────── */
.hero {
  text-align: center;
  padding: 100px 32px 80px;
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--blue);
  background: var(--blue-pale);
  padding: 7px 18px;
  border-radius: 100px;
  margin-bottom: 32px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.hero-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--blue);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.hero h1 {
  font-size: clamp(38px, 6vw, 60px);
  font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1.06;
  margin-bottom: 20px;
  color: var(--ink);
}

.hero h1 em {
  font-style: normal;
  color: var(--blue);
}

.hero-sub {
  font-size: clamp(17px, 2.2vw, 20px);
  color: var(--ink-secondary);
  line-height: 1.55;
  max-width: 480px;
  margin: 0 auto 44px;
  font-weight: 400;
}

/* ── Store buttons ──────────────────────────────────────────────── */
.store-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 28px;
  border-radius: var(--r-md);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s;
  cursor: default;
  letter-spacing: -0.1px;
}

.store-btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
}

.store-btn--apple {
  background: var(--ink);
  color: var(--white);
}
.store-btn--apple:hover {
  box-shadow: 0 8px 24px rgba(13, 17, 23, 0.15);
}

.store-btn--google {
  background: var(--white);
  color: var(--ink);
  border: 1.5px solid var(--border);
}
.store-btn--google:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  border-color: #ccc;
}

.store-btn svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.store-btn small {
  font-size: 10px;
  font-weight: 500;
  opacity: 0.6;
  display: block;
  line-height: 1;
  margin-bottom: 2px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.store-btn .btn-text {
  text-align: left;
  line-height: 1.2;
}

/* ── Section common ─────────────────────────────────────────────── */
.section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 80px 32px;
}

.section-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 12px;
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-header h2 {
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 800;
  letter-spacing: -0.8px;
  line-height: 1.15;
  margin-bottom: 14px;
}

.section-header p {
  font-size: 17px;
  color: var(--ink-secondary);
  max-width: 440px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ── Feature cards ──────────────────────────────────────────────── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.feature-card {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 36px 32px;
  border: 1px solid transparent;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.feature-card:hover {
  border-color: var(--border);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.feature-icon {
  width: 44px;
  height: 44px;
  background: var(--blue);
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--white);
}

.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-card h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.2px;
}

.feature-card p {
  font-size: 15px;
  color: var(--ink-secondary);
  line-height: 1.6;
}

/* ── Languages ──────────────────────────────────────────────────── */
.languages-grid {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.language-card {
  text-align: center;
  padding: 32px 28px 28px;
  border-radius: var(--r-lg);
  background: var(--surface);
  min-width: 140px;
  flex: 1;
  max-width: 200px;
  border: 1px solid transparent;
  transition: border-color 0.3s, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.language-card:hover {
  border-color: var(--border);
  transform: translateY(-2px);
}

.flag-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  margin: 0 auto 16px;
  overflow: hidden;
  border: 2px solid var(--white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  position: relative;
}

/* CSS flags — solid color blocks, no gradients */
.flag-en {
  background: var(--white);
}
.flag-en::before {
  content: '';
  position: absolute;
  top: 50%; left: 0;
  width: 100%; height: 12px;
  background: #C8102E;
  transform: translateY(-50%);
}
.flag-en::after {
  content: '';
  position: absolute;
  left: 50%; top: 0;
  width: 12px; height: 100%;
  background: #C8102E;
  transform: translateX(-50%);
}

.flag-fr {
  display: flex;
}
.flag-fr::before {
  content: '';
  flex: 1;
  background: #002395;
}
.flag-fr::after {
  content: '';
  flex: 1;
  background: #ED2939;
}
/* middle white strip is the gap */
.flag-fr { background: var(--white); gap: 0; }
.flag-fr::before, .flag-fr::after { flex: 1; }

.flag-es {
  background: #C60B1E;
}
.flag-es::before {
  content: '';
  position: absolute;
  top: 25%; left: 0;
  width: 100%; height: 50%;
  background: #FFC400;
}

.flag-dz {
  display: flex;
}
.flag-dz::before {
  content: '';
  flex: 1;
  background: #006233;
}
.flag-dz::after {
  content: '';
  flex: 1;
  background: var(--white);
}

.language-card span {
  font-size: 15px;
  font-weight: 700;
  display: block;
  letter-spacing: -0.1px;
}

.language-card small {
  font-size: 13px;
  color: var(--ink-muted);
  display: block;
  margin-top: 2px;
  font-weight: 500;
}

/* ── CTA ────────────────────────────────────────────────────────── */
.cta-section {
  text-align: center;
  padding: 72px 32px;
  margin: 0 32px;
  background: var(--blue);
  border-radius: var(--r-xl);
  max-width: 1056px;
  margin-left: auto;
  margin-right: auto;
}

.cta-section h2 {
  font-size: clamp(26px, 3.5vw, 34px);
  font-weight: 800;
  margin-bottom: 10px;
  letter-spacing: -0.5px;
  color: var(--white);
}

.cta-section p {
  font-size: 17px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 36px;
}

.cta-section .store-btn--apple {
  background: var(--white);
  color: var(--ink);
}
.cta-section .store-btn--apple:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.cta-section .store-btn--google {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.3);
}
.cta-section .store-btn--google:hover {
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: none;
}

/* ── Footer ─────────────────────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 48px 0;
  margin-top: 96px;
}

.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-copyright {
  font-size: 14px;
  color: var(--ink-muted);
  font-weight: 500;
}

.footer-links {
  display: flex;
  gap: 28px;
}

.footer-links a {
  font-size: 14px;
  color: var(--ink-secondary);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--ink);
  text-decoration: none;
}

.footer-email {
  font-size: 14px;
  color: var(--ink-muted);
  font-weight: 500;
}

/* ── Legal pages ────────────────────────────────────────────────── */
.legal-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 32px 96px;
}

.legal-content h1 {
  font-size: clamp(30px, 4vw, 40px);
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.8px;
  margin-bottom: 8px;
  line-height: 1.15;
}

.legal-content .last-updated {
  font-size: 14px;
  color: var(--ink-muted);
  margin-bottom: 48px;
  font-weight: 500;
}

.legal-content .intro {
  font-size: 18px;
  color: var(--ink-secondary);
  line-height: 1.75;
  margin-bottom: 48px;
}

.legal-content h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--ink);
  margin-top: 48px;
  margin-bottom: 16px;
  letter-spacing: -0.3px;
}

.legal-content h3 {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  margin-top: 32px;
  margin-bottom: 12px;
}

.legal-content p {
  margin-bottom: 16px;
  color: var(--ink-secondary);
  line-height: 1.7;
}

.legal-content ul,
.legal-content ol {
  margin-bottom: 16px;
  padding-left: 24px;
}

.legal-content li {
  margin-bottom: 8px;
  color: var(--ink-secondary);
  line-height: 1.65;
}

.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 24px;
  font-size: 15px;
}

.legal-content th,
.legal-content td {
  text-align: left;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.legal-content th {
  font-weight: 700;
  color: var(--ink);
  background: var(--surface);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.contact-block {
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 24px 28px;
  margin-top: 16px;
  margin-bottom: 16px;
}

.contact-block p {
  margin-bottom: 4px;
  font-size: 15px;
}

.contact-block p:last-child {
  margin-bottom: 0;
}

/* ── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .header-inner { padding: 0 20px; }
  .header-nav { display: none; }

  .hero {
    padding: 56px 20px 48px;
  }

  .hero-sub { margin-bottom: 36px; }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .feature-card { padding: 28px 24px; }

  .section {
    padding: 56px 20px;
  }

  .section-header { margin-bottom: 40px; }

  .languages-grid { gap: 12px; }
  .language-card {
    min-width: 0;
    padding: 24px 16px 20px;
  }
  .flag-icon { width: 44px; height: 44px; }

  .cta-section {
    margin: 0 12px;
    padding: 48px 20px;
    border-radius: var(--r-lg);
  }

  .legal-content {
    padding: 40px 20px 64px;
  }

  .legal-content h2 { font-size: 18px; }
  .legal-content .intro { font-size: 16px; }

  .legal-content table { font-size: 14px; }
  .legal-content th,
  .legal-content td { padding: 10px 12px; }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    padding: 0 20px;
  }

  .footer-links { flex-wrap: wrap; gap: 16px; }
}

@media (max-width: 480px) {
  .store-buttons { flex-direction: column; align-items: center; }
  .store-btn { width: 100%; max-width: 260px; justify-content: center; }
  .languages-grid { gap: 8px; }
  .language-card { padding: 20px 12px 16px; }
}
