/* MontessoriPlay : vitrine, assistance et pages légales.
   Direction « éditorial Montessori » : papier crème, beaucoup d'air, titres
   Fraunces, texte Quicksand (comme l'app), couleurs du vrai matériel en
   petites touches. Clair seulement. Aucune ressource externe, hors mesure
   d'audience Cloudflare. */

/* ---------- Polices (licence OFL, voir fonts/OFL-*.txt) ---------- */

@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2212;
}
@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces-italic.woff2") format("woff2");
  font-weight: 300 600;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2212;
}
@font-face {
  font-family: "Quicksand";
  src: url("fonts/quicksand-500.woff2") format("woff2");
  font-weight: 400 550;
  font-display: swap;
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2212;
}
@font-face {
  font-family: "Quicksand";
  src: url("fonts/quicksand-700.woff2") format("woff2");
  font-weight: 551 800;
  font-display: swap;
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2212;
}
@font-face {
  font-family: "Baloo Bhaijaan 2";
  src: url("fonts/baloobhaijaan2-500.woff2") format("woff2");
  font-weight: 300 550;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F;
}
@font-face {
  font-family: "Baloo Bhaijaan 2";
  src: url("fonts/baloobhaijaan2-700.woff2") format("woff2");
  font-weight: 551 800;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F;
}
@font-face {
  font-family: "Jua";
  src: url("fonts/jua-6e6b2f51.woff2") format("woff2");
  font-weight: 300 800;
  font-display: swap;
  unicode-range: U+1100-11FF, U+3000-303F, U+3130-318F, U+AC00-D7AF, U+FF00-FFEF;
}

/* ---------- Couleurs : celles du matériel ---------- */

:root {
  color-scheme: light;
  --paper: #FAF5EC;
  --paper-deep: #F3EBDD;
  --card: #FFFCF6;
  --wood-light: #EBD9BE;
  --wood: #CDA97E;
  --wood-dark: #8C6A45;
  --ink: #3A2E24;          /* brun foncé chaud, jamais de noir pur */
  --ink-soft: #6A5848;
  --rule: #E2D5C1;
  --pink: #E7A8AF;         /* tour rose */
  --pink-deep: #A9505E;
  --red: #C2443A;          /* barres numériques */
  --blue: #3C6A9E;
  --gold: #B8862A;         /* perles dorées */
  --sage: #6B8F71;
  --sage-deep: #4A6650;
  --water: #4E869C;
  --focus: #3C6A9E;
  --serif: "Fraunces", "Baloo Bhaijaan 2", "Jua", Georgia, "Times New Roman", serif;
  --sans: "Quicksand", "Baloo Bhaijaan 2", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR",
    system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --measure: 38rem;
  --page: 74rem;
}

/* ---------- Base ---------- */

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

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

body {
  margin: 0;
  background-color: var(--paper);
  /* grain de papier très léger */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .45 0 0 0 0 .36 0 0 0 0 .25 0 0 0 .045 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 500;
  font-size: 1.0625rem;
  line-height: 1.7;
  overflow-wrap: break-word;
}
:lang(ar) body, body:lang(ar) { line-height: 1.85; }
:lang(ko) { word-break: keep-all; }

.wrap {
  max-width: var(--page);
  margin-inline: auto;
  padding-inline: 20px;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-optical-sizing: auto;
  line-height: 1.08;
  letter-spacing: -0.012em;
  margin: 0;
  text-wrap: balance;
}
:lang(ar) :is(h1, h2, h3), :lang(ko) :is(h1, h2, h3) { letter-spacing: 0; line-height: 1.3; }
:lang(ar) :is(h1, h2, h3) { font-weight: 700; }

p { margin: 0 0 1em; }

a { color: var(--ink); text-decoration-color: var(--wood); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { text-decoration-color: var(--ink); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

img, video { max-width: 100%; height: auto; display: block; }

.skip {
  position: absolute;
  inset-inline-start: 1rem;
  top: -4rem;
  background: var(--card);
  padding: 0.5rem 1rem;
  z-index: 10;
}
.skip:focus { top: 0.75rem; }

.eyebrow {
  display: block;
  margin: 0 0 1.1rem;
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
:lang(ar) .eyebrow, :lang(ko) .eyebrow { letter-spacing: 0.02em; font-size: 0.9rem; text-transform: none; }

.rule { width: 2.5rem; height: 2px; border: 0; margin: 0 0 1.5rem; background: var(--pink); }

/* ---------- En-tête ---------- */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.25rem;
  border-bottom: 1px solid var(--rule);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
}
.brand img { width: 1.9rem; height: 1.9rem; border-radius: 0.5rem; }
.top-nav { display: flex; align-items: center; gap: 1.4rem; font-size: 0.95rem; }
.top-nav > a { text-decoration: none; color: var(--ink-soft); }
@media (max-width: 30rem) { .top-nav > a { display: none; } }
.top-nav > a:hover, .top-nav > a[aria-current] { color: var(--ink); text-decoration: underline; text-decoration-color: var(--wood); }

.lang-menu { position: relative; }
.lang-menu summary {
  list-style: none;
  cursor: pointer;
  color: var(--ink);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 700;
}
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary::after {
  content: "";
  width: 0.4rem; height: 0.4rem;
  border-inline-end: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-0.15rem) rotate(45deg);
}
.lang-menu[open] summary::after { transform: translateY(0.1rem) rotate(-135deg); }
.langs {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + 0.25rem);
  z-index: 5;
  margin: 0;
  padding: 0.5rem 0;
  list-style: none;
  min-width: 11rem;
  background: var(--card);
  border: 1px solid var(--rule);
  box-shadow: 0 18px 40px rgba(58, 46, 36, 0.12);
}
.langs a { display: block; padding: 0.4rem 1.1rem; text-decoration: none; }
.langs a:hover { background: var(--paper-deep); }
.langs a[aria-current="page"] { font-weight: 700; }
.langs a[aria-current="page"]::before { content: "· "; color: var(--pink-deep); }
html:not([lang="ar"]) .langs [lang="ar"],
html:not([lang="ko"]) .langs [lang="ko"] { font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }

/* ---------- Boutons des stores : pleins, sobres ---------- */

.stores { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
.store {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-width: 10.5rem;
  min-height: 3.4rem;
  padding: 0.5rem 1.4rem;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  line-height: 1.15;
}
.store small { font-size: 0.72rem; font-weight: 500; letter-spacing: 0.04em; opacity: 0.72; }
.store strong { font-size: 1.05rem; font-weight: 700; }
a.store:hover { background: var(--wood-dark); }
.store.soon { cursor: default; }

/* ---------- Téléphone dessiné en CSS ---------- */

.phone {
  margin: 0;
  padding: 0.45rem;
  border-radius: 2.2rem;
  background: #2F2620;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset, 0 30px 60px -20px rgba(58, 46, 36, 0.45), 0 8px 18px rgba(58, 46, 36, 0.14);
}
.phone img { border-radius: 1.8rem; width: 100%; height: auto; aspect-ratio: auto; object-fit: contain; background: var(--paper-deep); }
/* l'écran entier, jamais rogné : le cadre suit le rapport de la capture */
.phone > img { max-width: none; }

/* ---------- Accueil : en-tête éditorial ---------- */

.hero {
  display: grid;
  gap: 2.5rem;
  padding-block: 3rem 4.5rem;
}
.hero h1 {
  font-size: clamp(2.6rem, 9vw, 5rem);
  font-weight: 350;
}
.hero .lead {
  margin-top: 1.5rem;
  max-width: 32rem;
  font-size: 1.15rem;
  color: var(--ink-soft);
}
.hero-visual { position: relative; margin-inline-end: 0; padding-bottom: 3rem; }
.hero-visual picture img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 1.25rem;
}
.hero-visual .phone {
  position: absolute;
  inset-inline-end: -0.25rem;
  bottom: 0;
  width: 38%;
  max-width: 13.5rem;
  transform: rotate(2.5deg);
}
[dir="rtl"] .hero-visual .phone { transform: rotate(-2.5deg); }

/* Bande des points forts */
.band {
  border-block: 1px solid var(--rule);
  padding-block: 1.6rem;
}
.band ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
  font-family: var(--serif);
  font-size: 1.12rem;
}
.band li { display: inline-flex; align-items: baseline; gap: 0.6rem; }
.band li::before {
  content: "";
  flex: none;
  width: 0.5rem; height: 0.5rem;
  border-radius: 50%;
  background: var(--c, var(--pink));
  transform: translateY(-0.12rem);
}
.band li:nth-child(1) { --c: var(--pink); }
.band li:nth-child(2) { --c: var(--red); }
.band li:nth-child(3) { --c: var(--blue); }
.band li:nth-child(4) { --c: var(--gold); }
.band li:nth-child(5) { --c: var(--wood); }
.band li:nth-child(6) { --c: var(--sage); }

/* Phrase d'ouverture */
.statement { padding-block: 5.5rem 3rem; }
.statement p {
  max-width: 46rem;
  font-family: var(--serif);
  font-weight: 330;
  font-size: clamp(1.45rem, 3.4vw, 2.15rem);
  line-height: 1.38;
  text-wrap: pretty;
}
:lang(ar) .statement p, :lang(ko) .statement p { font-weight: 500; }
:lang(ko) :is(.statement p, .band ul, .gallery figcaption, .figure-note, .faq summary) { font-family: var(--sans); font-weight: 700; }
:lang(ko) .statement p { font-weight: 500; }

section.block { padding-block: 3.5rem; }
.block-head { margin-bottom: 2.75rem; max-width: var(--measure); }
.block-head h2 { font-size: clamp(2rem, 5.2vw, 3.25rem); }
.block-head p { margin-top: 1rem; color: var(--ink-soft); }

/* Vidéo */
.video {
  border-radius: 1.25rem;
  overflow: hidden;
  background: var(--wood-light);
  box-shadow: 0 40px 80px -40px rgba(58, 46, 36, 0.5), 0 10px 24px rgba(58, 46, 36, 0.10);
  aspect-ratio: 16 / 9;
}
.video video { width: 100%; height: 100%; object-fit: cover; }

/* Les six domaines : liste numérotée éditoriale */
.domains { list-style: none; margin: 0; padding: 0; counter-reset: d; }
.domain {
  counter-increment: d;
  display: grid;
  gap: 1.25rem;
  padding-block: 2.25rem;
  border-top: 1px solid var(--rule);
}
.domain:last-child { border-bottom: 1px solid var(--rule); }
.domain .num {
  font-family: "Fraunces", Georgia, serif;
  font-style: italic;
  font-weight: 300;
  font-size: 1.1rem;
  color: var(--c);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.domain .num::before { content: counter(d, decimal-leading-zero); }
.domain .num::after { content: ""; width: 2.5rem; height: 2px; background: var(--c); }
.domain h3 { font-size: clamp(1.75rem, 4vw, 2.5rem); margin: 0.35rem 0 0.75rem; }
.domain p { max-width: var(--measure); color: var(--ink-soft); margin: 0; }
.domain img { width: min(80%, 22rem); max-height: 15rem; object-fit: contain; margin-inline: auto; }
.d-language { --c: var(--blue); }
.d-maths { --c: var(--gold); }
.d-sensorial { --c: var(--pink-deep); }
.d-practical { --c: var(--wood-dark); }
.d-culture { --c: var(--sage-deep); }
.d-lab { --c: var(--water); }

/* Galerie de téléphones décalés */
.gallery {
  list-style: none;
  margin: 0 -20px;
  padding: 1rem 20px 2rem;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(64vw, 15rem);
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 20px;
  scrollbar-width: none;
}
.gallery::-webkit-scrollbar { display: none; }
.gallery li { scroll-snap-align: start; }
.gallery figcaption, .figure-note {
  margin-top: 1.1rem;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 350;
  font-size: 1.05rem;
  line-height: 1.35;
  color: var(--ink-soft);
}
:lang(ar) .gallery figcaption, :lang(ko) .gallery figcaption { font-style: normal; }
.gallery figure { margin: 0; }

/* Pour l'enfant / pour l'adulte */
.duo { display: grid; gap: 4rem; }
.duo-item { display: grid; gap: 2rem; align-items: center; }
.duo-item h3 { font-size: clamp(1.75rem, 4vw, 2.5rem); margin-bottom: 1.25rem; }
.duo-item ul { list-style: none; margin: 0; padding: 0; max-width: var(--measure); }
.duo-item li { padding: 0.8rem 0; border-top: 1px solid var(--rule); color: var(--ink-soft); }
.duo-item li:last-child { border-bottom: 1px solid var(--rule); }
.duo-visual > img { border-radius: 1.25rem; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.duo-visual .phone { width: min(62%, 16rem); margin-inline: auto; }

/* Offre */
.offer {
  background: var(--paper-deep);
  border-radius: 1.5rem;
  padding: 3rem 1.5rem;
  text-align: center;
}
.offer .block-head { margin-inline: auto; }
.offer .eyebrow { color: var(--gold); }
.offer-text { max-width: var(--measure); margin-inline: auto; color: var(--ink-soft); }
.offer .stores { justify-content: center; }
.closing { margin-top: 4.5rem; }
.closing img { width: 100%; border-radius: 1.25rem; aspect-ratio: 2 / 1; object-fit: cover; }

/* ---------- Pages de texte : assistance, légal ---------- */

.page { padding-block: 3.5rem 4rem; }
.page-head { max-width: 44rem; margin-bottom: 3rem; }
.page-head h1 { font-size: clamp(2.4rem, 7vw, 3.75rem); font-weight: 350; }
.page-head p { margin-top: 1.1rem; font-size: 1.1rem; color: var(--ink-soft); }
.updated { margin-top: 0.75rem; font-size: 0.9rem; color: var(--ink-soft); }

.prose { max-width: var(--measure); }
.prose p { margin-bottom: 1.15em; }

.aside {
  max-width: var(--measure);
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
}
.aside h2 { font-size: 1.6rem; margin-bottom: 0.9rem; }
.aside .eyebrow { color: var(--sage-deep); }

.contact {
  max-width: var(--measure);
  padding: 2rem 0 2.25rem;
  border-block: 1px solid var(--rule);
}
.contact h2 { font-size: 1.75rem; margin-bottom: 0.75rem; }
.mail {
  display: inline-block;
  margin: 0.5rem 0 1.25rem;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 4vw, 1.6rem);
  font-weight: 400;
  text-decoration-color: var(--pink);
  text-decoration-thickness: 2px;
}
.contact .note { color: var(--ink-soft); font-size: 0.95rem; margin: 0; }

.faq { max-width: 46rem; margin-top: 3.5rem; }
.faq > h2 { font-size: clamp(1.9rem, 5vw, 2.6rem); margin-bottom: 1.5rem; }
.faq details { border-top: 1px solid var(--rule); }
.faq details:last-of-type { border-bottom: 1px solid var(--rule); }
.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding: 1.2rem 0;
  font-family: var(--serif);
  font-size: 1.25rem;
  line-height: 1.3;
}
:lang(ar) .faq summary { font-weight: 700; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-family: var(--sans);
  font-weight: 500;
  font-size: 1.4rem;
  color: var(--pink-deep);
  line-height: 1;
}
.faq details[open] summary::after { content: "–"; }
.faq .answer { padding: 0 0 1.25rem; max-width: var(--measure); color: var(--ink-soft); }
.faq .answer b { color: var(--ink); font-weight: 700; }
.faq .answer p { margin-bottom: 0.7rem; }

.back-links { display: flex; flex-wrap: wrap; gap: 1.5rem; margin-top: 3rem; }
.back::before { content: "← "; }
[dir="rtl"] .back::before { content: "→ "; }

/* ---------- Choix de la langue et 404 ---------- */

.chooser { padding-block: 4rem 3rem; text-align: center; }
.chooser img.mark { width: 4.5rem; height: 4.5rem; margin: 0 auto 1.5rem; border-radius: 1.1rem; }
.chooser h1 { font-size: clamp(2.6rem, 8vw, 4rem); font-weight: 350; }
.chooser > p { margin-top: 1rem; color: var(--ink-soft); }
.chooser ul {
  list-style: none;
  margin: 3rem auto 0;
  padding: 0;
  max-width: 40rem;
  text-align: start;
  border-top: 1px solid var(--rule);
}
.chooser li a {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 1rem 0.25rem;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
}
.chooser li a:hover strong { text-decoration: underline; text-decoration-color: var(--wood); }
.chooser li strong { font-family: var(--serif); font-weight: 400; font-size: 1.3rem; }
.chooser li span { color: var(--ink-soft); font-size: 0.95rem; }

/* ---------- Pied de page ---------- */

.foot {
  margin-top: 3rem;
  padding-block: 3rem 3.5rem;
  border-top: 1px solid var(--rule);
  font-size: 0.88rem;
  color: var(--ink-soft);
}
.foot-brand { font-family: "Fraunces", Georgia, serif; font-size: 1.4rem; color: var(--ink); margin-bottom: 1.25rem; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin-bottom: 1.75rem; font-size: 0.95rem; font-weight: 700; }
.foot p { margin: 0.3rem 0; max-width: 50rem; }
.ltr { direction: ltr; unicode-bidi: isolate; }

/* ---------- Apparition douce ---------- */

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .reveal {
      animation: reveal linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 35%;
    }
    @keyframes reveal { from { opacity: 0; translate: 0 1.25rem; } to { opacity: 1; translate: 0 0; } }
  }
}

/* ---------- Grands écrans ---------- */

@media (min-width: 48rem) {
  .wrap { padding-inline: 40px; }
  .band ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.65rem 2.25rem; }
  .gallery { margin-inline: -40px; padding-inline: 40px; scroll-padding-inline: 40px; }
  .domain { grid-template-columns: 1fr 1fr; align-items: center; column-gap: 4rem; }
  .domain:nth-child(even) .domain-text { order: 2; }
  .offer { padding: 4.5rem 3rem; }
}

@media (min-width: 64rem) {
  body { font-size: 1.1rem; }
  .hero {
    grid-template-columns: 4fr 6fr;
    align-items: center;
    column-gap: 5rem;
    padding-block: 5rem 6rem;
  }
  .hero-visual { padding-bottom: 0; }
  .hero-visual picture img { aspect-ratio: 5 / 4; }
  .hero-visual .phone {
    inset-inline-end: auto;
    inset-inline-start: -2.5rem;
    bottom: -4rem;
    width: 27%;
  }
  .statement { padding-block: 8rem 4rem; }
  .statement p { margin-inline-start: 16%; }
  section.block { padding-block: 6rem; }
  .gallery {
    margin: 0;
    padding: 0 0 4rem;
    overflow: visible;
    grid-auto-flow: row;
    grid-template-columns: repeat(var(--cols, 3), minmax(0, 15.5rem));
    justify-content: center;
    gap: 4.5rem;
  }
  .gallery.n4 { --cols: 4; gap: 3rem; }
  .gallery li:nth-child(2) { translate: 0 4rem; }
  .gallery li:nth-child(4) { translate: 0 2rem; }
  .duo-item { grid-template-columns: 5fr 6fr; column-gap: 5rem; }
  .duo-item:nth-child(even) .duo-visual { order: 2; }
  .duo-visual > img { max-width: 26rem; }
  .duo-item:nth-child(even) .duo-visual > img { margin-inline-start: auto; }
  .foot-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 3rem; }
}
