/*
 * Kadikado landing page — kadikado.fr
 *
 * Colors mirror frontend/src/theme/palette.ts and the light/dark themes in
 * frontend/src/theme/index.ts (see docs/design-system.md). Keep the two in sync: the landing
 * page has no build step, so it cannot import the palette and repeats the values here.
 */

@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/roboto-latin-400-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/roboto-latin-500-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/roboto-latin-700-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 900;
  font-display: swap;
  src: url('fonts/roboto-latin-900-normal.woff2') format('woff2');
}

:root {
  color-scheme: light dark;

  /* Light theme — same roles as frontend/src/theme/index.ts */
  --bg: #fafafa;
  --surface: #ffffff;
  --surface-variant: #e4e7eb;
  --text: #1f2933;
  --text-muted: #52606d;
  --border: #e4e7eb;
  --primary: #0f766e;
  --primary-strong: #115e59;
  --on-primary: #ffffff;
  --primary-container: #e6f2f0;
  --on-primary-container: #115e59;
  --secondary: #a65a2b;
  --secondary-container: #fbede2;
  --on-secondary-container: #8f4b1e;
  --accent: #c97a40;
  --logo-tile: #ffffff;
  --band: #134e4a;
  --on-band: #fafafa;
  --on-band-muted: #b8dcd7;
  --band-accent: #e8b183;
  --shadow: 0 1px 2px rgb(31 41 51 / 6%), 0 12px 32px rgb(31 41 51 / 10%);

  --radius: 20px;
  --radius-sm: 12px;
  --max: 1120px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1f2933;
    --surface: #323f4b;
    --surface-variant: #3e4c59;
    --text: #fafafa;
    --text-muted: #b4bdc6;
    --border: #3e4c59;
    --primary: #2dd4bf;
    --primary-strong: #5eead4;
    --on-primary: #1f2933;
    --primary-container: #123f3c;
    --on-primary-container: #5eead4;
    --secondary: #e8b183;
    --secondary-container: #3d2a1a;
    --on-secondary-container: #e8b183;
    --accent: #e8b183;
    --band: #123f3c;
    --on-band: #fafafa;
    --on-band-muted: #b4bdc6;
    --band-accent: #e8b183;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 12px 32px rgb(0 0 0 / 35%);
  }
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

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

body {
  margin: 0;
  font-family: 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

h1,
h2,
h3 {
  line-height: 1.15;
  margin: 0;
  text-wrap: balance;
}

p {
  margin: 0;
}

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

.skip-link {
  position: absolute;
  left: 12px;
  top: -48px;
  padding: 8px 14px;
  background: var(--primary);
  color: var(--on-primary);
  border-radius: 8px;
  z-index: 100;
}
.skip-link:focus {
  top: 12px;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 1rem;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn-primary {
  background: var(--primary);
  color: var(--on-primary);
  box-shadow: 0 6px 18px rgb(15 118 110 / 28%);
}
.btn-primary:hover {
  background: var(--primary-strong);
}
.btn-ghost {
  color: var(--primary);
  border: 1.5px solid currentColor;
}
.btn-ghost:hover {
  background: var(--primary-container);
}
.btn-sm {
  min-height: 40px;
  padding: 0 18px;
  font-size: 0.9375rem;
}
.btn-light {
  background: var(--on-band);
  color: var(--band);
}
.btn-light:hover {
  background: #ffffff;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 68px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--primary);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.logo-tile {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--logo-tile);
}
.logo-tile img {
  width: 34px;
  height: 34px;
}
.header-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}
.header-link {
  padding: 8px 10px;
  font-weight: 500;
  font-size: 0.9375rem;
  text-decoration: none;
  color: var(--text-muted);
  border-radius: 8px;
}
.header-link:hover {
  color: var(--text);
}
.lang-switch {
  display: inline-grid;
  place-items: center;
  min-width: 40px;
  height: 32px;
  padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--text-muted);
}
.lang-switch:hover {
  color: var(--text);
  border-color: var(--text-muted);
}

@media (max-width: 640px) {
  .header-link.hide-sm {
    display: none;
  }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 56px 0 72px;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: -20% -10% auto auto;
  width: 60vw;
  max-width: 760px;
  aspect-ratio: 1;
  background: radial-gradient(circle, var(--primary-container) 0%, transparent 65%);
  z-index: -1;
}
.hero .container {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: center;
  gap: 56px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--secondary-container);
  color: var(--on-secondary-container);
  font-weight: 500;
  font-size: 0.875rem;
  margin-bottom: 20px;
}
.hero h1 {
  font-size: clamp(2.4rem, 5.4vw, 4rem);
  font-weight: 900;
  letter-spacing: -0.03em;
}
.hero h1 em {
  font-style: normal;
  color: var(--primary);
}
.hero .lead {
  margin-top: 20px;
  font-size: 1.1875rem;
  color: var(--text-muted);
  max-width: 34em;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.reassurance {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
  color: var(--text-muted);
  font-size: 0.9375rem;
}
.reassurance li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.reassurance li::before {
  content: '✓';
  font-weight: 700;
  color: var(--primary);
}

/* Mock gift-list card */
.mock {
  position: relative;
  justify-self: center;
  width: 100%;
  max-width: 440px;
}
.mock-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px;
  transform: rotate(-1.5deg);
}
.mock-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.mock-avatar {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary-container);
  font-size: 1.4rem;
}
.mock-title {
  font-weight: 700;
  font-size: 1.0625rem;
}
.mock-sub {
  font-size: 0.8125rem;
  color: var(--text-muted);
}
.mock-items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.mock-item {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-sm);
  background: var(--bg);
  border: 1px solid var(--border);
}
.mock-thumb {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--surface);
  font-size: 1.25rem;
}
.mock-name {
  font-weight: 500;
  font-size: 0.9375rem;
  line-height: 1.3;
}
.mock-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
}
.chip-taken {
  background: var(--surface-variant);
  color: var(--text-muted);
}
.chip-pick {
  background: var(--primary);
  color: var(--on-primary);
}
.progress {
  height: 6px;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--surface-variant);
  overflow: hidden;
}
.progress span {
  display: block;
  width: 60%; /* the hero mock's group gift: €180 of €300 */
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
}
.mock-float {
  position: absolute;
  right: -12px;
  bottom: -28px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 16px;
  background: var(--band);
  color: var(--on-band);
  box-shadow: var(--shadow);
  transform: rotate(2.5deg);
  font-size: 0.875rem;
}
.mock-float strong {
  display: block;
  font-size: 1rem;
}
.mock-float .emoji {
  font-size: 1.6rem;
}
.mock-float small {
  color: var(--on-band-muted);
}

/* ---------- Occasions ---------- */

.occasions {
  padding: 8px 0 40px;
}
.occasions h2 {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 18px;
}
.occasion-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.occasion-list li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-weight: 500;
}
.occasion-list li.more {
  background: var(--primary-container);
  color: var(--on-primary-container);
  border-color: transparent;
}

/* ---------- Sections ---------- */

.section {
  padding: 88px 0;
}
.section-head {
  max-width: 680px;
  margin: 0 auto 48px;
  text-align: center;
}
.kicker {
  display: block;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 10px;
}
.section-head h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.75rem);
  font-weight: 900;
  letter-spacing: -0.02em;
}
.section-head p {
  margin-top: 14px;
  color: var(--text-muted);
  font-size: 1.125rem;
}

/* Follows another section's bottom padding, so no top padding of its own. */
.section.section-flush-top {
  padding-top: 0;
}

/* Features */
.features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.feature {
  padding: 28px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.feature-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 18px;
  border-radius: 14px;
  background: var(--primary-container);
  font-size: 1.6rem;
}
.feature:nth-child(even) .feature-icon {
  background: var(--secondary-container);
}
.feature h3 {
  font-size: 1.1875rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.feature p {
  color: var(--text-muted);
  font-size: 1rem;
}

/* Steps */
.steps-section {
  background: var(--surface);
  border-block: 1px solid var(--border);
}
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.step {
  position: relative;
  counter-increment: step;
  text-align: center;
  padding: 0 12px;
}
.step::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 900;
  font-size: 1.5rem;
}
.step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 28px;
  left: calc(50% + 44px);
  width: calc(100% - 88px + 32px);
  border-top: 2px dashed var(--border);
}
.step h3 {
  font-size: 1.1875rem;
  font-weight: 700;
  margin-bottom: 6px;
}
.step p {
  color: var(--text-muted);
}

/* Secret Santa band */
.santa {
  background: var(--band);
  color: var(--on-band);
  overflow: hidden;
}
.santa .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 56px;
}
.santa .kicker {
  color: var(--band-accent);
}
.santa h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.75rem);
  font-weight: 900;
  letter-spacing: -0.02em;
}
.santa .lead {
  margin-top: 16px;
  color: var(--on-band-muted);
  font-size: 1.125rem;
}
.santa-points {
  display: grid;
  gap: 16px;
  margin: 28px 0 32px;
  padding: 0;
  list-style: none;
}
.santa-points li {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 14px;
  align-items: start;
}
.santa-points .dot {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgb(255 255 255 / 10%);
  font-size: 1.1rem;
}
.santa-points strong {
  display: block;
}
.santa-points span.desc {
  color: var(--on-band-muted);
  font-size: 0.975rem;
}

.draw {
  position: relative;
  justify-self: center;
  width: 100%;
  max-width: 420px;
}
.draw-card {
  background: var(--surface);
  color: var(--text);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 24px 60px rgb(0 0 0 / 30%);
}
.draw-card h3 {
  font-size: 1.125rem;
  font-weight: 700;
}
.draw-card .mock-sub {
  margin-top: 2px;
}
.people {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0;
  padding: 0;
  list-style: none;
}
.people li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px 4px 4px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 0.875rem;
  font-weight: 500;
}
.people .av {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--primary-container);
  color: var(--on-primary-container);
  font-size: 0.75rem;
  font-weight: 700;
}
.people li:nth-child(even) .av {
  background: var(--secondary-container);
  color: var(--on-secondary-container);
}
.reveal {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius-sm);
  background: var(--primary-container);
  color: var(--on-primary-container);
}
.reveal .emoji {
  font-size: 2rem;
}
.reveal small {
  display: block;
  font-size: 0.8125rem;
}
.reveal strong {
  font-size: 1.375rem;
  font-weight: 900;
}
.rule {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* Why */
.why {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.why li {
  padding: 32px 28px;
  border-radius: var(--radius);
  background: var(--primary-container);
  color: var(--on-primary-container);
}
.why li:nth-child(2) {
  background: var(--secondary-container);
  color: var(--on-secondary-container);
}
.why .big {
  display: block;
  font-size: 2.25rem;
  margin-bottom: 12px;
}
.why h3 {
  font-size: 1.3125rem;
  font-weight: 900;
  margin-bottom: 8px;
  color: var(--text);
}
.why p {
  color: var(--text-muted);
}

/* FAQ */
.faq {
  max-width: 760px;
  margin: 0 auto;
  display: grid;
  gap: 12px;
}
.faq details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0 22px;
}
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0;
  font-weight: 700;
  font-size: 1.0625rem;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: '+';
  flex: none;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--primary-container);
  color: var(--on-primary-container);
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1;
  transition: transform 0.2s ease;
}
.faq details[open] summary::after {
  transform: rotate(45deg);
}
.faq details p {
  padding: 0 0 20px;
  color: var(--text-muted);
}

/* Final CTA */
.cta {
  padding: 0 0 96px;
}
.cta-box {
  position: relative;
  overflow: hidden;
  padding: 64px 32px;
  border-radius: 28px;
  background: var(--band);
  color: var(--on-band);
  text-align: center;
}
.cta-box::before,
.cta-box::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  opacity: 0.18;
  background: var(--accent);
}
.cta-box::before {
  width: 280px;
  height: 280px;
  left: -90px;
  top: -120px;
}
.cta-box::after {
  width: 200px;
  height: 200px;
  right: -60px;
  bottom: -90px;
  background: #2dd4bf;
}
.cta-box h2 {
  position: relative;
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  font-weight: 900;
  letter-spacing: -0.02em;
}
.cta-box p {
  position: relative;
  margin: 14px auto 28px;
  max-width: 36em;
  color: var(--on-band-muted);
  font-size: 1.125rem;
}
.cta-box .btn {
  position: relative;
}

/* Footer */
.site-footer {
  padding: 40px 0 48px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.9375rem;
}
.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer-links a {
  text-decoration: none;
}
.footer-links a:hover {
  color: var(--text);
  text-decoration: underline;
}

/* ---------- Responsive ---------- */

@media (max-width: 1000px) {
  .features {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 860px) {
  .hero {
    padding: 32px 0 72px;
  }
  .hero .container,
  .santa .container {
    grid-template-columns: 1fr;
    gap: 56px;
  }
  .mock-float {
    right: 0;
  }
  .steps {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .step:not(:last-child)::after {
    display: none;
  }
  .why {
    grid-template-columns: 1fr;
  }
  .section {
    padding: 64px 0;
  }
}

@media (max-width: 560px) {
  .container {
    padding: 0 16px;
  }
  .features {
    grid-template-columns: 1fr;
  }
  .hero-actions .btn {
    flex: 1 1 100%;
  }
  .mock-card {
    padding: 16px;
    transform: none;
  }
  .mock-item {
    grid-template-columns: 36px 1fr;
  }
  .mock-item .chip,
  .mock-item .mock-action {
    grid-column: 2;
    justify-self: start;
  }
  .mock-float {
    transform: none;
    right: 8px;
    bottom: -32px;
  }
  .cta-box {
    padding: 48px 20px;
  }
}
