/* ========================================================================
   ORORE — Outil pédagogique interactif
   Direction : Manuscrit éclairé moderne (chaleur méditerranéenne)
   ======================================================================== */

/* ---------- 1. RESET & BASE ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; background: none; }
a { color: inherit; text-decoration: none; }

/* ---------- 2. VARIABLES (palette + tokens) ---------- */
:root {
  /* Couleurs principales */
  --ink: #1a1f2e;            /* Bleu nuit, texte principal */
  --ink-soft: #3a4252;
  --cream: #faf6ee;          /* Fond crème, papier ancien */
  --paper: #f3ecdd;          /* Variante plus chaude */
  --ochre: #c8842a;          /* Ocre/safran, accent chaud */
  --ochre-dark: #9a5f1a;
  --ochre-soft: #e8c896;
  --gold: #d4a04c;           /* Or vieilli pour highlights */
  --terracotta: #b85c3c;     /* Rouge méditerranéen */
  --jade: #2d5f4c;           /* Vert profond pour accents asiatiques */
  --jade-soft: #6b9b85;
  --shadow: rgba(26, 31, 46, 0.12);
  --shadow-strong: rgba(26, 31, 46, 0.25);

  /* Typographie */
  --font-display: "Fraunces", "Playfair Display", Georgia, serif;
  --font-body: "Newsreader", "Source Serif Pro", Georgia, serif;
  --font-sans: "DM Sans", -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", "Courier New", monospace;

  /* Espacement & tailles */
  --container: 1280px;
  --radius-sm: 4px;
  --radius-md: 12px;
  --radius-lg: 24px;

  /* Transitions */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- 3. CORPS DOCUMENT ---------- */
body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  min-height: 100vh;
  background-image:
    radial-gradient(ellipse at top left, rgba(200, 132, 42, 0.08), transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(45, 95, 76, 0.06), transparent 60%);
}

/* Grain texture subtile (papier ancien) */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.4;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- 4. TYPOGRAPHIE ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--ink);
}
h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); font-weight: 400; }
h2 { font-size: clamp(1.8rem, 3vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.7rem); }
h4 { font-size: 1.15rem; font-weight: 600; }
.serif { font-family: var(--font-display); }
.sans  { font-family: var(--font-sans); }

/* Italique élégant de Fraunces */
.display-italic { font-family: var(--font-display); font-style: italic; font-weight: 300; }

/* Twemoji : rendu uniforme des emojis comme images SVG */
img.emoji {
  height: 1em;
  width: 1em;
  margin: 0 .05em 0 .1em;
  vertical-align: -0.1em;
  display: inline-block;
}
.subject-icon img.emoji,
.tradition-card .icon img.emoji,
.key-fact .icon img.emoji {
  height: 1em;
  width: 1em;
}

/* ---------- 5. LAYOUT GÉNÉRAL ---------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 2;
}

main { padding: 2rem 0 4rem; }

/* ---------- 6. NAVIGATION / HEADER ---------- */
.site-header {
  position: relative;
  z-index: 10;
  padding: 1.5rem 0;
  border-bottom: 1px solid rgba(26, 31, 46, 0.1);
}
.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.brand {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}
.brand-mark {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 2rem;
  letter-spacing: -0.04em;
  color: var(--ink);
}
.brand-mark::first-letter {
  color: var(--ochre);
  font-style: italic;
}
.brand-tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--ink-soft);
  font-weight: 300;
}
.nav-links {
  display: flex;
  gap: 2rem;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.nav-links a {
  color: var(--ink-soft);
  transition: color 0.2s var(--ease);
}
.nav-links a:hover { color: var(--ochre); }

/* ---------- 7. HOMEPAGE — HERO ---------- */
.hero {
  padding: 5rem 0 3rem;
  text-align: center;
  position: relative;
}
.hero-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--ochre);
  margin-bottom: 1.5rem;
  display: inline-block;
}
.hero h1 {
  max-width: 900px;
  margin: 0 auto 1.5rem;
}
.hero h1 em {
  color: var(--ochre);
  font-style: italic;
  font-weight: 300;
}
.hero-lead {
  font-size: 1.25rem;
  color: var(--ink-soft);
  max-width: 640px;
  margin: 0 auto;
  font-family: var(--font-display);
  font-weight: 300;
  font-style: italic;
}
.hero-divider {
  width: 80px;
  height: 1px;
  background: var(--ochre);
  margin: 3rem auto 0;
  position: relative;
}
.hero-divider::before,
.hero-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 6px;
  height: 6px;
  background: var(--ochre);
  border-radius: 50%;
  transform: translateY(-50%);
}
.hero-divider::before { left: -20px; }
.hero-divider::after  { right: -20px; }

/* ---------- 8. SECTION TITRES ---------- */
.section-title {
  text-align: center;
  margin: 3rem 0 2.5rem;
}
.section-title h2 { margin-bottom: 0.5rem; }
.section-title .subtitle {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  color: var(--ink-soft);
}

/* ---------- 9. SUBJECTS GRID (matières) ---------- */
.subjects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}
.subject-card {
  position: relative;
  padding: 2rem 1.75rem;
  background: var(--paper);
  border: 1px solid rgba(26, 31, 46, 0.08);
  border-radius: var(--radius-md);
  transition: all 0.3s var(--ease);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
}
.subject-card.active:hover {
  transform: translateY(-4px);
  border-color: var(--ochre);
  box-shadow: 0 12px 32px var(--shadow);
}
.subject-card.locked {
  opacity: 0.5;
  cursor: not-allowed;
  background: transparent;
}
.subject-card.locked:hover { transform: none; }
.subject-icon {
  font-size: 2.5rem;
  filter: sepia(0.1);
}
.subject-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
}
.subject-status {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.3rem 0.8rem;
  border-radius: 99px;
}
.subject-status.available {
  background: var(--ochre);
  color: var(--cream);
}
.subject-status.coming {
  background: rgba(26, 31, 46, 0.08);
  color: var(--ink-soft);
}

/* ---------- 10. BUTTONS ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  border-radius: 99px;
  transition: all 0.25s var(--ease);
  cursor: pointer;
  text-transform: none;
}
.btn-primary {
  background: var(--ink);
  color: var(--cream);
  border: 1px solid var(--ink);
}
.btn-primary:hover {
  background: var(--ochre);
  border-color: var(--ochre);
}
.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
}
.btn-outline:hover {
  background: var(--ink);
  color: var(--cream);
}
.btn-gold {
  background: var(--gold);
  color: var(--ink);
  border: 1px solid var(--gold);
}
.btn-gold:hover {
  background: var(--ochre-dark);
  color: var(--cream);
  border-color: var(--ochre-dark);
}

/* ---------- 11. GEO PAGE — Carte du monde ---------- */
.geo-intro {
  text-align: center;
  padding: 2rem 0 1rem;
}
.geo-intro p {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.1rem;
}
.world-map-wrapper {
  position: relative;
  max-width: 1100px;
  margin: 1rem auto 3rem;
  padding: 2rem;
  background: var(--paper);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 24px var(--shadow);
  border: 1px solid rgba(26, 31, 46, 0.08);
}
.world-map-wrapper svg {
  width: 100%;
  height: auto;
  display: block;
}
.world-map-wrapper .country {
  fill: #e0d6c0;
  stroke: #b8a980;
  stroke-width: 0.4;
  stroke-linejoin: round;
  transition: fill 0.25s var(--ease);
}
.world-map-wrapper .country.available {
  fill: var(--ochre);
  stroke: var(--ochre-dark);
  stroke-width: 1;
  cursor: pointer;
  filter: drop-shadow(0 2px 4px rgba(154, 95, 26, 0.3));
}
.world-map-wrapper .country.available:hover {
  fill: var(--ochre-dark);
  filter: drop-shadow(0 4px 8px rgba(154, 95, 26, 0.5));
}
.country-tooltip {
  position: absolute;
  background: var(--ink);
  color: var(--cream);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  z-index: 5;
}
.country-tooltip.show { opacity: 1; }

/* ---------- 12. LESSON PAGE ---------- */
.lesson-header {
  text-align: center;
  padding: 2rem 0 1rem;
  position: relative;
}
.lesson-header .flag { font-size: 3rem; margin-bottom: 0.5rem; }
.lesson-header h1 {
  margin-bottom: 0.5rem;
}
.lesson-header .lesson-subtitle {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.2rem;
}

/* Toolbar avec actions */
.lesson-toolbar {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin: 1.5rem 0;
  flex-wrap: wrap;
}

/* Key facts intro */
.key-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin: 2rem 0 3rem;
}
.key-fact {
  background: var(--paper);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  text-align: center;
  border: 1px solid rgba(26, 31, 46, 0.08);
  transition: transform 0.2s var(--ease);
}
.key-fact:hover { transform: translateY(-2px); }
.key-fact .icon { font-size: 2rem; margin-bottom: 0.5rem; }
.key-fact .label {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.key-fact .value {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--ink);
  margin: 0.25rem 0;
}
.key-fact .comment {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 0.85rem;
  color: var(--ochre-dark);
}

/* ---------- 13. CARTE CHINE & HOTSPOTS ---------- */
.china-section {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2rem;
  margin: 2rem 0;
}
@media (max-width: 1024px) {
  .china-section { grid-template-columns: 1fr; }
}

.china-map-container {
  background: var(--paper);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  border: 1px solid rgba(26, 31, 46, 0.08);
  box-shadow: 0 8px 24px var(--shadow);
  position: relative;
  min-height: 500px;
}
.china-map-container svg { width: 100%; height: auto; display: block; }

/* Pays voisins (contexte autour de la Chine) */
.china-map-container .neighbor {
  fill: #e8dec9;
  stroke: #c4b690;
  stroke-width: 0.4;
  opacity: 0.7;
}

/* La Chine elle-même : territoire principal en ocre */
.china-map-container .china-territory {
  fill: var(--ochre-soft);
  stroke: var(--ochre-dark);
  stroke-width: 1.2;
  opacity: 0.85;
  filter: drop-shadow(0 2px 6px rgba(154, 95, 26, 0.25));
}

/* Étiquettes pays voisins (très discrètes) */
.china-map-container .label-country {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 14px;
  font-weight: 500;
  fill: #6a5a3e;
  stroke: var(--paper);
  stroke-width: 4px;
  paint-order: stroke fill;
  stroke-linejoin: round;
  pointer-events: none;
  text-anchor: middle;
}
.china-map-container .label-sea {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 13px;
  fill: #3a5a73;
  stroke: var(--paper);
  stroke-width: 4px;
  paint-order: stroke fill;
  stroke-linejoin: round;
  pointer-events: none;
  text-anchor: middle;
}

.hotspot-marker {
  cursor: pointer;
}
.hotspot-marker circle.inner,
.hotspot-marker circle.outer {
  transition: r 0.2s var(--ease), fill 0.2s var(--ease);
  transform-box: fill-box;
  transform-origin: center;
}
.hotspot-marker text {
  transition: font-size 0.2s var(--ease), fill 0.2s var(--ease);
}
.hotspot-marker:hover circle.inner { r: 9; fill: var(--ochre-dark); }
.hotspot-marker:hover circle.outer { r: 18; opacity: 0.45; }
.hotspot-marker:hover text { font-size: 16px; fill: var(--ochre-dark); }
.hotspot-marker.active circle.inner { fill: var(--ochre); r: 9; }
.hotspot-marker.active circle.outer { opacity: 0.5; }
.hotspot-marker.active text { fill: var(--ochre-dark); }

.hotspot-marker circle.outer {
  fill: var(--ochre);
  opacity: 0.25;
}
.hotspot-marker circle.inner {
  fill: var(--terracotta);
  stroke: var(--cream);
  stroke-width: 2;
}
.hotspot-marker text {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 700;
  fill: var(--ink);
  text-anchor: middle;
  pointer-events: none;
  paint-order: stroke;
  stroke: var(--cream);
  stroke-width: 4;
  stroke-linejoin: round;
  letter-spacing: 0.01em;
}
@keyframes pulse {
  0%, 100% { opacity: 0.25; }
  50% { opacity: 0.05; }
}
.hotspot-marker circle.outer {
  animation: pulse 2.5s infinite ease-in-out;
}

/* Panel contenu hotspot */
.hotspot-panel {
  background: var(--paper);
  border-radius: var(--radius-lg);
  padding: 2rem;
  border: 1px solid rgba(26, 31, 46, 0.08);
  box-shadow: 0 8px 24px var(--shadow);
  min-height: 500px;
  overflow-y: auto;
  max-height: 70vh;
}
.hotspot-panel.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
}
.hotspot-panel .pinyin {
  font-family: var(--font-sans);
  color: var(--ochre-dark);
  font-size: 1rem;
  margin-top: 0.25rem;
}
.hotspot-panel .chinese-name {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--jade);
  margin: 0.25rem 0;
}
.hotspot-panel h3 {
  margin-bottom: 0.25rem;
  color: var(--ink);
}
.hotspot-panel .intro-text {
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 1rem 0;
  color: var(--ink-soft);
}
.hotspot-panel .key-points {
  list-style: none;
  margin: 1.25rem 0;
}
.hotspot-panel .key-points li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.6rem;
  line-height: 1.6;
}
.hotspot-panel .key-points li::before {
  content: '✦';
  position: absolute;
  left: 0;
  color: var(--ochre);
  font-size: 0.85rem;
}
.hotspot-panel .anecdote {
  background: rgba(212, 160, 76, 0.12);
  border-left: 3px solid var(--gold);
  padding: 1rem 1.25rem;
  margin: 1.25rem 0 0.5rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  line-height: 1.6;
}
.hotspot-panel .anecdote::before {
  content: '✦ Le savais-tu ?';
  display: block;
  font-style: normal;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ochre-dark);
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.hotspot-panel .images {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin: 1.25rem 0;
}
.hotspot-panel .images img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid rgba(26, 31, 46, 0.1);
}
.image-placeholder {
  background: linear-gradient(135deg, var(--ochre-soft), var(--paper));
  border-radius: var(--radius-md);
  padding: 3rem 1rem;
  text-align: center;
  color: var(--ochre-dark);
  font-style: italic;
  font-family: var(--font-display);
}

/* ---------- 14. ONGLETS (Traditions / Timeline / Quiz) ---------- */
.tabs-section {
  margin: 4rem 0;
  background: var(--paper);
  border-radius: var(--radius-lg);
  padding: 2rem;
  border: 1px solid rgba(26, 31, 46, 0.08);
}
.tabs-nav {
  display: flex;
  gap: 0.5rem;
  border-bottom: 1px solid rgba(26, 31, 46, 0.1);
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.tab-btn {
  padding: 0.85rem 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--ink-soft);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.2s var(--ease);
}
.tab-btn:hover { color: var(--ink); }
.tab-btn.active {
  color: var(--ochre);
  border-bottom-color: var(--ochre);
  font-weight: 600;
}
.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.3s var(--ease); }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Traditions grid */
.traditions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.tradition-card {
  background: var(--cream);
  padding: 1.5rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(26, 31, 46, 0.08);
}
.tradition-card .icon { font-size: 2.5rem; margin-bottom: 0.75rem; }
.tradition-card h4 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--ink);
}
.tradition-card p { font-size: 0.95rem; line-height: 1.6; }
.tradition-card .fun-fact {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(26, 31, 46, 0.15);
  font-style: italic;
  font-size: 0.9rem;
  color: var(--ochre-dark);
}

/* Timeline */
.timeline-container { position: relative; padding: 1rem 0; }
.timeline-container::before {
  content: '';
  position: absolute;
  left: 30px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--ochre), var(--terracotta), var(--jade));
}
.timeline-item {
  position: relative;
  padding-left: 5rem;
  margin-bottom: 1.5rem;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: 23px;
  top: 8px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--cream);
  border: 3px solid var(--ochre);
}
.timeline-year {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--ochre-dark);
}
.timeline-label {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0.15rem 0;
}
.timeline-event { line-height: 1.6; }

/* Prononciations */
.pronunciations-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}
.pronunciation-card {
  background: var(--cream);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(26, 31, 46, 0.08);
  display: flex;
  align-items: center;
  gap: 1rem;
}
.pronunciation-card .french {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  font-size: 0.95rem;
}
.pronunciation-card .chinese {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--jade);
  margin: 0.25rem 0;
}
.pronunciation-card .pinyin {
  font-family: var(--font-sans);
  color: var(--ochre-dark);
  font-size: 0.9rem;
}
.pronunciation-card .play-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--ochre);
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all 0.2s var(--ease);
  flex-shrink: 0;
}
.pronunciation-card .play-btn:hover {
  background: var(--ink);
  transform: scale(1.05);
}

/* Quiz */
.quiz-container { max-width: 700px; margin: 0 auto; }
.quiz-question {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
  text-align: center;
  line-height: 1.4;
}
.quiz-options {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}
.quiz-option {
  padding: 1rem 1.25rem;
  background: var(--cream);
  border: 2px solid rgba(26, 31, 46, 0.1);
  border-radius: var(--radius-md);
  text-align: left;
  transition: all 0.2s var(--ease);
  font-size: 1rem;
}
.quiz-option:hover {
  border-color: var(--ochre);
  background: rgba(200, 132, 42, 0.05);
}
.quiz-option.correct {
  border-color: var(--jade);
  background: rgba(45, 95, 76, 0.12);
}
.quiz-option.wrong {
  border-color: var(--terracotta);
  background: rgba(184, 92, 60, 0.12);
}
.quiz-feedback {
  margin-top: 1rem;
  padding: 1rem;
  background: var(--paper);
  border-left: 3px solid var(--ochre);
  font-style: italic;
  display: none;
}
.quiz-feedback.show { display: block; animation: fadeIn 0.3s var(--ease); }
.quiz-progress {
  text-align: center;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}
.quiz-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 1.5rem;
}

/* ---------- 15. Q&A MODAL ---------- */
.qa-modal {
  position: fixed;
  inset: 0;
  background: rgba(26, 31, 46, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 2rem;
}
.qa-modal.show { display: flex; animation: fadeIn 0.3s var(--ease); }
.qa-modal-content {
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 3rem 2.5rem;
  max-width: 600px;
  width: 100%;
  text-align: center;
  position: relative;
}
.qa-modal-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  font-size: 1.5rem;
  color: var(--ink-soft);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  transition: all 0.2s var(--ease);
}
.qa-modal-close:hover { background: rgba(26, 31, 46, 0.08); color: var(--ink); }

.qa-modal h2 {
  font-family: var(--font-display);
  margin-bottom: 0.5rem;
}
.qa-modal .qa-subtitle {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  margin-bottom: 2rem;
}

.mic-button {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--ochre);
  color: var(--cream);
  font-size: 3rem;
  margin: 1rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s var(--ease);
  box-shadow: 0 8px 24px rgba(200, 132, 42, 0.4);
  user-select: none;
}
.mic-button:hover { transform: scale(1.05); }
.mic-button.recording {
  background: var(--terracotta);
  animation: micPulse 1.5s infinite;
}
@keyframes micPulse {
  0%, 100% { box-shadow: 0 8px 24px rgba(184, 92, 60, 0.4), 0 0 0 0 rgba(184, 92, 60, 0.4); }
  50% { box-shadow: 0 8px 24px rgba(184, 92, 60, 0.4), 0 0 0 30px rgba(184, 92, 60, 0); }
}

.mic-instruction {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--ink-soft);
  margin: 1rem 0;
}

.transcription {
  background: var(--paper);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  margin: 1.5rem 0;
  min-height: 60px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.1rem;
  display: none;
}
.transcription.show { display: block; }
.transcription .label {
  font-family: var(--font-sans);
  font-style: normal;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: block;
  margin-bottom: 0.5rem;
}

.qa-answer {
  background: rgba(45, 95, 76, 0.08);
  border-left: 3px solid var(--jade);
  padding: 1.25rem 1.5rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 1.5rem 0;
  text-align: left;
  display: none;
}
.qa-answer.show { display: block; animation: fadeIn 0.3s var(--ease); }
.qa-answer .label {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--jade);
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.qa-answer p { line-height: 1.6; font-size: 1.05rem; }

.qa-text-fallback {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 0;
}
.qa-text-fallback input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(26, 31, 46, 0.2);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  background: var(--cream);
}
.qa-text-fallback input:focus {
  outline: none;
  border-color: var(--ochre);
}

.loading-dots {
  display: inline-flex;
  gap: 0.4rem;
  margin: 1rem 0;
}
.loading-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ochre);
  animation: bounce 1.4s infinite ease-in-out both;
}
.loading-dots span:nth-child(1) { animation-delay: -0.32s; }
.loading-dots span:nth-child(2) { animation-delay: -0.16s; }
@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.5); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

/* ---------- 16. FOOTER ---------- */
.site-footer {
  text-align: center;
  padding: 3rem 0 2rem;
  margin-top: 4rem;
  border-top: 1px solid rgba(26, 31, 46, 0.1);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.site-footer p { margin: 0.3rem 0; }

/* ---------- 17. MODE PRÉSENTATION (FULLSCREEN) ---------- */
body.presentation-mode .site-header,
body.presentation-mode .site-footer,
body.presentation-mode .lesson-toolbar { display: none; }
body.presentation-mode main { padding: 1rem 0; }
body.presentation-mode .container { max-width: 100%; padding: 0 1.5rem; }
body.presentation-mode .lesson-header h1 { font-size: 5rem; }
body.presentation-mode .hotspot-panel { font-size: 1.15rem; }
body.presentation-mode .hotspot-panel .intro-text { font-size: 1.25rem; }

/* ---------- 18. RESPONSIVE ---------- */
@media (max-width: 768px) {
  .container { padding: 0 1.25rem; }
  .site-header .container { flex-direction: column; gap: 1rem; }
  .nav-links { gap: 1rem; font-size: 0.8rem; }
  .hero { padding: 3rem 0 2rem; }
  .lesson-toolbar { flex-direction: column; }
  .lesson-toolbar .btn { width: 100%; justify-content: center; }
}

/* ============================================================
   AJOUTS v4 : drapeau, popups, galeries personnages & cuisine
   ============================================================ */

/* ---------- DRAPEAU BADGE (en-tête leçon) ---------- */
.flag-badge {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  cursor: pointer;
  margin-bottom: 0.75rem;
  transition: transform 0.2s var(--ease);
}
.flag-badge:hover { transform: translateY(-3px) scale(1.03); }
.flag-badge #flag-svg-target {
  width: 120px;
  height: 80px;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 4px 14px var(--shadow);
  border: 1px solid rgba(26,31,46,0.1);
}
.flag-hint {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ochre-dark);
  opacity: 0.85;
}

/* ---------- MODAL DÉTAIL GÉNÉRIQUE ---------- */
.detail-modal {
  position: fixed;
  inset: 0;
  background: rgba(26, 31, 46, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 2rem;
  overflow-y: auto;
}
.detail-modal.show { display: flex; animation: fadeIn 0.3s var(--ease); }
.detail-modal-content {
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  max-width: 720px;
  width: 100%;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.detail-modal-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  font-size: 1.4rem;
  color: var(--ink-soft);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  transition: all 0.2s var(--ease);
  z-index: 2;
}
.detail-modal-close:hover { background: rgba(26,31,46,0.08); color: var(--ink); }

/* ---------- DÉTAIL DRAPEAU ---------- */
.flag-detail { text-align: center; }
.flag-large {
  width: 300px;
  max-width: 100%;
  margin: 0 auto 1.5rem;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 24px var(--shadow);
  border: 1px solid rgba(26,31,46,0.1);
}
.flag-large svg { width: 100%; height: auto; display: block; }
.flag-adopted {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  margin-bottom: 1.5rem;
}
.flag-detail h4 {
  margin: 1.5rem 0 0.75rem;
  color: var(--ochre-dark);
}
.flag-symbolism {
  list-style: none;
  text-align: left;
  max-width: 520px;
  margin: 0 auto;
}
.flag-symbolism li {
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: 0.75rem;
  line-height: 1.6;
}
.flag-symbolism li::before {
  content: '★';
  position: absolute;
  left: 0;
  color: var(--ochre);
}

/* ---------- HYMNE ---------- */
.anthem-block {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px dashed rgba(26,31,46,0.2);
  text-align: center;
}
.anthem-name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}
.anthem-chinese { color: var(--jade); font-size: 1.1rem; }
.anthem-desc {
  font-size: 0.95rem;
  color: var(--ink-soft);
  line-height: 1.6;
  margin: 0.75rem auto;
  max-width: 520px;
}
.anthem-audio { width: 100%; max-width: 400px; margin: 1rem auto 0.5rem; display: block; }
.anthem-note {
  font-size: 0.75rem;
  font-style: italic;
  color: var(--ink-soft);
  opacity: 0.7;
}

/* ---------- TABLEAU PERSONNAGES (4 colonnes) ---------- */
.personalities-table {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
@media (max-width: 900px) {
  .personalities-table { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .personalities-table { grid-template-columns: 1fr; }
}
.personality-column {
  background: var(--cream);
  border-radius: var(--radius-md);
  padding: 1rem;
  border: 1px solid rgba(26,31,46,0.08);
}
.personality-column-header {
  text-align: center;
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid var(--ochre-soft);
}
.personality-column-header .theme-icon { font-size: 1.5rem; display: block; }
.personality-column-header .theme-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--ink);
}
.personality-cards { display: flex; flex-direction: column; gap: 1rem; }
.personality-card {
  cursor: pointer;
  text-align: center;
  padding: 0.75rem;
  border-radius: var(--radius-md);
  transition: all 0.2s var(--ease);
  border: 1px solid transparent;
}
.personality-card:hover {
  background: var(--paper);
  border-color: var(--ochre-soft);
  transform: translateY(-3px);
  box-shadow: 0 6px 16px var(--shadow);
}
.personality-photo { margin-bottom: 0.5rem; }
.personality-photo img {
  width: 80px;
  height: 80px;
  margin: 0 auto;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--ochre-soft);
  box-shadow: 0 2px 8px var(--shadow);
}
.photo-placeholder {
  width: 80px;
  height: 80px;
  margin: 0 auto;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--ochre-soft), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.photo-placeholder::after {
  content: attr(data-initials);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--ink);
}
.personality-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1rem;
  color: var(--ink);
}
.personality-role {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--ink-soft);
  margin-top: 0.15rem;
}

/* ---------- DÉTAIL PERSONNAGE ---------- */
.person-detail { display: grid; grid-template-columns: 180px 1fr; gap: 1.5rem; align-items: start; }
@media (max-width: 600px) { .person-detail { grid-template-columns: 1fr; text-align: center; } }
.person-detail-photo { position: relative; }
.photo-placeholder-large {
  width: 160px;
  height: 160px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--ochre-soft), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}
.photo-placeholder-large::after {
  content: attr(data-initials);
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 600;
  color: var(--ink);
}
.person-detail-photo img {
  width: 160px;
  height: 160px;
  object-fit: cover;
  border-radius: var(--radius-md);
}
.person-role {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--ochre-dark);
  letter-spacing: 0.03em;
  margin-bottom: 1rem;
}

/* ---------- GALERIE CUISINE ---------- */
.cuisine-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1.25rem;
}
.cuisine-card {
  cursor: pointer;
  text-align: center;
  padding: 1rem;
  border-radius: var(--radius-md);
  background: var(--cream);
  border: 1px solid rgba(26,31,46,0.08);
  transition: all 0.2s var(--ease);
}
.cuisine-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px var(--shadow);
  border-color: var(--ochre-soft);
}
.cuisine-photo { margin-bottom: 0.75rem; }
.cuisine-photo .photo-placeholder,
.cuisine-photo img {
  width: 100%;
  height: 120px;
  border-radius: var(--radius-sm);
}
.cuisine-photo .photo-placeholder {
  border-radius: var(--radius-sm);
}
.cuisine-photo .photo-placeholder::after { font-size: 2.5rem; }
.cuisine-photo img { object-fit: cover; }
.cuisine-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.05rem;
}
.cuisine-chinese { color: var(--jade); font-size: 0.9rem; }

.dish-detail { text-align: center; }
.dish-detail-photo { margin-bottom: 1rem; }
.dish-detail-photo .photo-placeholder-large,
.dish-detail-photo img {
  width: 240px;
  height: 180px;
  margin: 0 auto;
  border-radius: var(--radius-md);
}
.dish-detail-photo img { object-fit: cover; }
.dish-detail .key-points { text-align: left; max-width: 480px; margin: 1rem auto; }
.dish-detail .intro-text { max-width: 520px; margin: 1rem auto; }

/* ============================================================
   v6 : ONBOARDING (popup prénom + tour guidé)
   ============================================================ */
.onboarding-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26, 31, 46, 0.85);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1.5rem;
  animation: fadeIn 0.4s var(--ease);
}
.onboarding-card {
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 3rem 2.5rem;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: 0 25px 70px rgba(0,0,0,0.5);
  animation: popIn 0.5s var(--ease);
}
@keyframes popIn {
  0% { transform: scale(0.85) translateY(20px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}
.onboarding-orore {
  font-size: 3.5rem;
  margin-bottom: 0.5rem;
  animation: float 3s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
.onboarding-card h2 {
  font-family: var(--font-display);
  margin-bottom: 0.75rem;
}
.onboarding-sub {
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-style: italic;
  line-height: 1.6;
  margin-bottom: 1.75rem;
}
.onboarding-input {
  width: 100%;
  padding: 1rem 1.25rem;
  font-family: var(--font-body);
  font-size: 1.2rem;
  text-align: center;
  border: 2px solid var(--ochre-soft);
  border-radius: var(--radius-md);
  background: white;
  margin-bottom: 1.25rem;
  transition: border-color 0.2s var(--ease);
}
.onboarding-input:focus {
  outline: none;
  border-color: var(--ochre);
}
.onboarding-btn {
  width: 100%;
  justify-content: center;
  font-size: 1.05rem;
  padding: 1rem;
}
.onboarding-skip {
  display: block;
  margin: 1rem auto 0;
  background: none;
  color: var(--ink-soft);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  text-decoration: underline;
  opacity: 0.7;
}
.onboarding-skip:hover { opacity: 1; }

/* Tour guidé */
.tour-spotlight {
  position: fixed;
  inset: 0;
  z-index: 1100;
  pointer-events: auto;
  cursor: pointer;
}
.tour-hole {
  position: absolute;
  border-radius: 12px;
  box-shadow: 0 0 0 9999px rgba(26, 31, 46, 0.82);
  border: 3px solid var(--gold);
  transition: all 0.3s var(--ease);
  pointer-events: none;
}
.tour-tooltip {
  position: fixed;
  z-index: 1101;
  background: var(--cream);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  max-width: 340px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.4);
  animation: popIn 0.3s var(--ease);
}
.tour-step-count {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ochre-dark);
  margin-bottom: 0.5rem;
}
.tour-tooltip h4 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}
.tour-tooltip p {
  color: var(--ink-soft);
  line-height: 1.5;
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
}
.tour-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.tour-skip-all {
  background: none;
  color: var(--ink-soft);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  text-decoration: underline;
}
.tour-next { padding: 0.6rem 1.25rem; font-size: 0.9rem; }

/* Salutation personnalisée */
.child-greeting {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--ochre-dark);
  text-align: center;
  margin-top: 0.5rem;
}

/* ============================================================
   v6 : JEUX CARTE INTERACTIFS
   ============================================================ */
.games-wrapper {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
}
.game-block {
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  border: 1px solid rgba(26,31,46,0.08);
}
.game-intro { text-align: center; margin-bottom: 1rem; }
.game-intro h3 { margin-bottom: 0.4rem; }
.game-intro p {
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-style: italic;
}
.game-feedback {
  margin-top: 0.75rem;
  min-height: 2rem;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  justify-content: center;
}
.game-feedback.win .game-win {
  color: var(--jade);
  font-weight: 600;
  font-size: 1.1rem;
  animation: popIn 0.4s var(--ease);
}
.game-feedback.lose .game-lose {
  color: var(--terracotta);
  font-weight: 500;
}
.game-map {
  background: var(--paper);
  border-radius: var(--radius-md);
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.game-map svg { width: 100%; height: auto; }
/* Dans les jeux, tous les pays réagissent au survol */
.game-map .country:hover { fill: var(--ochre-soft); }
.game-map .hotspot-marker circle.inner { fill: var(--terracotta); }
.game-map .hotspot-marker:hover circle.inner { fill: var(--ochre-dark); r: 10; }

/* ============================================================
   v6 : POLISH — animations d'apparition + accents Chine
   ============================================================ */
/* Apparition en cascade des key-facts */
.key-fact {
  animation: riseUp 0.5s var(--ease) both;
}
.key-fact:nth-child(1) { animation-delay: 0.05s; }
.key-fact:nth-child(2) { animation-delay: 0.10s; }
.key-fact:nth-child(3) { animation-delay: 0.15s; }
.key-fact:nth-child(4) { animation-delay: 0.20s; }
.key-fact:nth-child(5) { animation-delay: 0.25s; }
.key-fact:nth-child(6) { animation-delay: 0.30s; }
@keyframes riseUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Apparition des cartes personnages */
.personality-card, .cuisine-card, .tradition-card {
  animation: riseUp 0.4s var(--ease) both;
}

/* Accent thématique Chine : liseré rouge/or en haut de page leçon */
.lesson-header::before {
  content: '';
  display: block;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, #de2910 0%, #de2910 50%, #ffde00 50%, #ffde00 100%);
  border-radius: 2px;
  margin-bottom: 1.5rem;
  max-width: 200px;
  margin-left: auto;
  margin-right: auto;
}

/* Le drapeau dans l'en-tête : petite animation d'ondulation au survol */
.flag-badge:hover #flag-svg-target {
  animation: wave 0.6s var(--ease);
}
@keyframes wave {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-2deg); }
  75% { transform: rotate(2deg); }
}

/* Hotspots : apparition en fondu (opacité seule, pour ne pas écraser le translate de positionnement) */
@keyframes hotspotFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.hotspot-marker {
  animation: hotspotFadeIn 0.6s var(--ease) both;
}

/* Transition douce sur les onglets */
.tab-btn { position: relative; }
.tab-btn::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 50%;
  width: 0; height: 2px;
  background: var(--ochre);
  transition: all 0.25s var(--ease);
  transform: translateX(-50%);
}
.tab-btn:hover::after { width: 60%; }
.tab-btn.active::after { width: 100%; }

/* ============================================================
   v6b : Surtitre "Exposé de [prénom]"
   ============================================================ */
.lesson-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ochre);
  margin-bottom: 0.5rem;
  font-weight: 600;
}
/* Le titre du pays devient le focus principal */
.lesson-header h1 {
  margin-bottom: 0.25rem;
}

/* ============================================================
   v8 : POPUP "LE PERSONNAGE SE PRÉSENTE"
   ============================================================ */
.self-intro-detail { text-align: center; }
.self-intro-photo { margin-bottom: 1rem; }
.self-intro-photo .photo-placeholder-large,
.self-intro-photo img {
  width: 140px;
  height: 140px;
  margin: 0 auto;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--ochre-soft);
  box-shadow: 0 4px 16px var(--shadow);
}
.self-intro-detail h3 { margin-bottom: 0.1rem; }
.self-intro-bubble {
  position: relative;
  background: rgba(200, 132, 42, 0.10);
  border: 1px solid var(--ochre-soft);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  margin: 1.5rem auto;
  max-width: 540px;
  text-align: left;
}
.self-intro-bubble::before {
  content: '';
  position: absolute;
  top: -10px; left: 50%;
  transform: translateX(-50%);
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-bottom: 10px solid var(--ochre-soft);
}
.self-intro-bubble .bubble-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ochre-dark);
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.self-intro-bubble p {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--ink);
}
.self-intro-audio { margin: 1rem auto; }
.self-intro-chosen {
  margin-top: 1.25rem;
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--jade);
  font-weight: 500;
}

/* ============================================================
   v10 : Bouton "Changer de prénom" dans le header
   ============================================================ */
.change-name-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.85rem;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  background: var(--paper);
  border: 1px solid rgba(26, 31, 46, 0.12);
  border-radius: 99px;
  cursor: pointer;
  transition: all 0.2s var(--ease);
  text-transform: none;
}
.change-name-btn:hover {
  background: var(--ochre-soft);
  color: var(--ink);
  border-color: var(--ochre);
}
.change-name-btn .change-name-current {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  color: var(--ochre-dark);
  font-size: 0.9rem;
}
.change-name-btn .change-name-action {
  font-size: 0.7rem;
  text-transform: uppercase;
  opacity: 0.7;
}
.change-name-btn::before {
  content: '👤';
  font-size: 0.9rem;
}

@media (max-width: 600px) {
  .change-name-btn .change-name-action { display: none; }
}

/* ============================================================
   v10 : Nouveaux jeux (Qui est-ce, Reconnais le plat, Qui suis-je)
   ============================================================ */
.picture-game-card { text-align: center; }
.picture-game-photo {
  margin: 0 auto 1.25rem;
  width: 180px;
  height: 180px;
}
.picture-game-photo .photo-placeholder-large,
.picture-game-photo img {
  width: 180px;
  height: 180px;
  border-radius: var(--radius-md);
  object-fit: cover;
  border: 3px solid var(--ochre-soft);
  box-shadow: 0 4px 16px var(--shadow);
}

.picture-game-choices {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  max-width: 520px;
  margin: 0 auto;
}
.picture-game-choice {
  padding: 1rem 1.25rem;
  background: var(--cream);
  border: 2px solid rgba(26, 31, 46, 0.1);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s var(--ease);
  text-align: center;
}
.picture-game-choice:hover:not(:disabled) {
  border-color: var(--ochre);
  background: rgba(200, 132, 42, 0.08);
  transform: translateY(-2px);
}
.picture-game-choice:disabled { cursor: not-allowed; opacity: 0.7; }
.picture-game-choice.correct {
  border-color: var(--jade);
  background: rgba(45, 95, 76, 0.15);
  font-weight: 600;
  color: var(--jade);
}
.picture-game-choice.wrong {
  border-color: var(--terracotta);
  background: rgba(184, 92, 60, 0.15);
  color: var(--terracotta);
}

/* Grille des plats (4 photos cliquables) */
.dish-game-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  max-width: 480px;
  margin: 0 auto 1rem;
}
.dish-game-choice {
  padding: 0.5rem;
  background: var(--cream);
  border: 3px solid rgba(26, 31, 46, 0.1);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s var(--ease);
}
.dish-game-choice:hover:not(:disabled) {
  border-color: var(--ochre);
  transform: translateY(-3px);
  box-shadow: 0 6px 16px var(--shadow);
}
.dish-game-choice:disabled { cursor: not-allowed; opacity: 0.6; }
.dish-game-choice.correct {
  border-color: var(--jade);
  box-shadow: 0 0 0 4px rgba(45, 95, 76, 0.25);
}
.dish-game-choice.wrong {
  border-color: var(--terracotta);
}

/* Carte "Qui suis-je ?" */
.whoami-card { text-align: center; max-width: 600px; margin: 0 auto; }
.whoami-bubble {
  background: rgba(200, 132, 42, 0.10);
  border: 2px dashed var(--ochre-soft);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  text-align: left;
}
.whoami-bubble .bubble-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ochre-dark);
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.whoami-bubble p {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--ink);
}

@media (max-width: 500px) {
  .picture-game-choices { grid-template-columns: 1fr; }
  .dish-game-grid { grid-template-columns: 1fr 1fr; }
}