/* ==========================================================================
   TarotMate — design system (production)
   ========================================================================== */

:root {
  --green: #1c4634;
  --green-deep: #0e2a20;
  --green-mid: #173a2c;
  --gold: #c9a24d;
  --gold-light: #e6cd8f;
  --cream: #f6efdd;
  --red: #9c2b3a;
  --ink: #241d13;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background: var(--cream);
  color: var(--ink);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container {
  max-width: 1160px;
  margin: 0 auto;
}

.container--wide {
  max-width: 1240px;
  margin: 0 auto;
}

/* ---- keyframes ---- */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
@keyframes marqueeScroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes floatBadge { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes floatLogo { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-16px); } }

/* ---- scroll reveal ---- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- one-shot entrance animation (plays on load, independent of element height/scroll) ---- */
.page-enter { animation: fadeInUp 0.8s ease both; }

/* ==========================================================================
   Navigation
   ========================================================================== */

.site-nav-wrap {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  padding: 20px 3vw;
  transition: padding 0.3s ease;
}
.site-nav {
  width: 100%;
  max-width: 1240px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 10px 10px 22px;
  background: rgba(14,42,32,0.35);
  box-shadow: none;
  border: 1px solid rgba(230,205,143,0.16);
  border-radius: 60px;
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease, padding 0.3s ease, border-radius 0.3s ease, max-width 0.3s ease;
}

/* En dessous de 640px : la barre passe en pleine largeur, collée en haut, au scroll */
@media (max-width: 639px) {
  .site-nav-wrap.is-scrolled { padding: 0; }
  .site-nav-wrap.is-scrolled .site-nav {
    max-width: 100%;
    padding: 6px 24px;
    border-radius: 0;
    background: rgba(14,42,32,0.55);
    border-color: rgba(230,205,143,0.28);
    box-shadow: 0 8px 32px rgba(0,0,0,0.28);
    backdrop-filter: blur(22px) saturate(180%);
    -webkit-backdrop-filter: blur(22px) saturate(180%);
  }
  .site-nav-wrap.is-scrolled .nav-brand-logo { height: 26px; }
}

/* A partir de 640px : pilule flottante inchangée au repos ; au scroll elle remonte un peu, s'affine légèrement et le fond s'assombrit */
@media (min-width: 640px) {
  .site-nav-wrap.is-scrolled { padding-top: 12px; }
  .site-nav-wrap.is-scrolled .site-nav {
    padding-top: 7px;
    padding-bottom: 7px;
    background: rgba(14,42,32,0.55);
    border-color: rgba(230,205,143,0.28);
    box-shadow: 0 8px 32px rgba(0,0,0,0.28);
    backdrop-filter: blur(22px) saturate(180%);
    -webkit-backdrop-filter: blur(22px) saturate(180%);
  }
}

.nav-brand { display: flex; align-items: center; gap: 10px; }
.nav-brand-logo { height: 34px; width: auto; transition: height 0.3s ease; }

.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-link { position: relative; font-size: 14px; font-weight: 600; letter-spacing: 0.3px; color: var(--cream); opacity: 0.82; }
.nav-link:hover { opacity: 1; color: var(--gold-light); }
.nav-link.is-active { opacity: 1; color: var(--gold-light); }

.nav-cta { background: var(--gold); color: var(--green-deep); font-size: 14px; font-weight: 700; padding: 11px 22px; border-radius: 40px; letter-spacing: 0.2px; }
.nav-cta:hover { background: var(--gold-light); }

.nav-link--admin { color: var(--red); opacity: 1; font-weight: 800; letter-spacing: 0.6px; }
.nav-link--admin:hover { color: var(--red); opacity: 0.8; }

.nav-lang { display: flex; align-items: center; gap: 2px; }
.nav-lang-link { display: flex; align-items: center; font-size: 12px; font-weight: 700; letter-spacing: 0.4px; color: var(--cream); opacity: 0.55; padding: 4px 6px; border-radius: 20px; }
.nav-lang-link:hover { opacity: 1; }
.nav-lang-link.is-active { opacity: 1; background: rgba(255, 255, 255, 0.12); color: var(--gold-light); }
.nav-lang-flag { font-family: "Noto Color Emoji", sans-serif; font-size: 16px; line-height: 1; }

.nav-lang-dropdown { position: relative; }
.nav-lang-toggle { display: flex; align-items: center; gap: 5px; background: none; border: none; color: var(--cream); padding: 6px 8px; border-radius: 20px; cursor: pointer; }
.nav-lang-toggle:hover { background: rgba(255, 255, 255, 0.08); }
.nav-lang-caret { font-size: 10px; color: var(--gold-light); opacity: 0.75; transition: transform 0.2s ease; }
.nav-lang-dropdown.is-open .nav-lang-caret { transform: rotate(180deg); }
.nav-lang-menu {
  position: absolute; top: calc(100% + 10px); right: 0;
  min-width: 170px;
  background: var(--green-deep);
  border: 1px solid rgba(230, 205, 143, 0.2);
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  padding: 6px;
  display: flex; flex-direction: column; gap: 2px;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  z-index: 10;
}
.nav-lang-dropdown.is-open .nav-lang-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-lang-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; font-size: 13px; font-weight: 600; color: var(--cream); opacity: 0.75; }
.nav-lang-item:hover { opacity: 1; background: rgba(255, 255, 255, 0.08); }
.nav-lang-item.is-active { opacity: 1; color: var(--gold-light); background: rgba(255, 255, 255, 0.1); }

.nav-toggle {
  display: none;
  position: relative;
  width: 40px; height: 40px;
  background: none; border: none; padding: 0; cursor: pointer;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  z-index: 101;
}
.nav-toggle span {
  width: 22px; height: 2px; background: var(--gold-light); display: block; border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.2s ease, width 0.3s ease;
}
.nav-toggle.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-active span:nth-child(2) { opacity: 0; width: 0; }
.nav-toggle.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

html.has-menu-open, html.has-menu-open body { overflow: hidden; }

.mobile-menu {
  position: fixed; inset: 0; z-index: 99;
  background: linear-gradient(165deg, var(--green-deep), var(--green-mid));
  display: flex;
  flex-direction: column; align-items: stretch; justify-content: flex-start;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: translateY(-16px);
  transition: opacity 0.28s ease, transform 0.28s ease, visibility 0.28s;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0); }

.mobile-menu-inner {
  width: 100%;
  padding: 108px 28px 40px;
  display: flex; flex-direction: column; align-items: stretch; gap: 28px;
}

.mobile-menu-links { display: flex; flex-direction: column; }
.mobile-menu-links a {
  font-family: 'Playfair Display', serif; font-size: 22px; font-weight: 600; color: var(--cream);
  padding: 14px 4px;
  border-bottom: 1px solid rgba(230, 205, 143, 0.14);
  text-align: center;
  opacity: 0.88;
  transition: opacity 0.2s ease, color 0.2s ease;
}
.mobile-menu-links a:first-child { border-top: 1px solid rgba(230, 205, 143, 0.14); }
.mobile-menu-links a:hover, .mobile-menu-links a:active { opacity: 1; color: var(--gold-light); }
.mobile-menu-links a.is-active { opacity: 1; color: var(--gold-light); }

.mobile-menu-langs { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.mobile-menu-langs-label { font-size: 11px; font-weight: 700; letter-spacing: 1.4px; text-transform: uppercase; color: var(--gold-light); opacity: 0.65; }
.mobile-menu-langs-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; width: 100%; max-width: 340px; }
.mobile-menu-lang-chip {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-family: 'Inter', sans-serif; font-size: 12px; font-weight: 700; letter-spacing: 0.3px;
  color: var(--cream); opacity: 0.75;
  padding: 9px 6px;
  border: 1px solid rgba(230, 205, 143, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  transition: opacity 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.mobile-menu-lang-chip .nav-lang-flag { font-size: 15px; }
.mobile-menu-lang-chip:hover { opacity: 1; background: rgba(255, 255, 255, 0.08); }
.mobile-menu-lang-chip.is-active { opacity: 1; color: var(--green-deep); background: var(--gold-light); border-color: var(--gold-light); }

.mobile-menu-cta { align-self: center; font-family: 'Inter', sans-serif; font-weight: 700; padding: 13px 32px; font-size: 16px; }

@media (max-width: 899px) {
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
}

@media (max-height: 560px) {
  .mobile-menu-inner { padding-top: 88px; gap: 18px; }
  .mobile-menu-links a { padding: 9px 4px; font-size: 19px; }
}

/* ==========================================================================
   Buttons / badges / chips
   ========================================================================== */

.badge-pill {
  display: inline-block;
  padding: 6px 16px;
  border: 1px solid var(--gold);
  border-radius: 30px;
  color: var(--gold-light);
  font-size: 12px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  white-space: nowrap;
}

.store-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 13px 24px; border-radius: 12px;
  font-weight: 700; font-size: 14.5px;
}
.store-btn .dot { width: 20px; height: 20px; border-radius: 5px; flex: none; }
.store-btn--light { background: var(--cream); color: var(--green-deep); }
.store-btn--light:hover { background: var(--gold-light); }
.store-btn--light .dot { background: var(--green-deep); }
.store-btn--outline { background: transparent; color: var(--cream); border: 1.5px solid var(--gold); }
.store-btn--outline:hover { border-color: var(--gold-light); color: var(--gold-light); }
.store-btn--outline .dot { background: var(--gold); }
.store-btn--large { padding: 14px 28px; font-size: 15px; }

/* Store pas encore publié (TM_STORES url = null) : grisé, non cliquable */
.store-btn.is-soon { opacity: 0.55; cursor: default; }
.store-btn--light.is-soon:hover { background: var(--cream); }
.store-btn--outline.is-soon:hover { border-color: var(--gold); color: var(--cream); }
.footer-link.is-soon, .footer-link.is-soon:hover { cursor: default; opacity: 0.5; color: var(--cream); }
.soon-tag {
  margin-left: 2px; padding: 2px 8px; border-radius: 20px;
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.8px; text-transform: uppercase;
  border: 1px solid currentColor;
}

.chip {
  display: flex; align-items: center; gap: 8px;
  background: rgba(230,205,143,0.08);
  border: 1px solid rgba(230,205,143,0.22);
  border-radius: 30px;
  padding: 8px 16px;
  font-size: 13px;
  color: var(--cream);
  opacity: 0.85;
}
.chip .dot-sm { width: 6px; height: 6px; border-radius: 50%; background: var(--gold-light); }

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  position: relative;
  min-height: 100vh;
  background: #13301e;
  padding: clamp(130px,15vw,170px) 6vw 0;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.hero-blob { position: absolute; border-radius: 50%; pointer-events: none; }
.hero-blob--red { width: 640px; height: 640px; background: var(--red); opacity: 0.16; filter: blur(120px); top: -220px; left: -160px; }
.hero-blob--gold { width: 560px; height: 560px; background: var(--gold); opacity: 0.14; filter: blur(130px); bottom: -200px; right: -160px; }
.hero-pattern {
  position: absolute; inset: 0; opacity: 0.05; pointer-events: none;
  background-image: repeating-linear-gradient(45deg, var(--gold) 0 2px, transparent 2px 26px);
}

.hero-grid {
  max-width: 1320px; margin: 0 auto; width: 100%; flex: 1;
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
  position: relative; z-index: 1;
}
.hero-media { flex: 1.2 1 360px; min-width: 280px; display: flex; justify-content: flex-start; position: relative; }
.hero-logo { width: 100%; max-width: 560px; height: auto; object-fit: contain; filter: drop-shadow(0 40px 70px rgba(0,0,0,0.55)); position: relative; z-index: 1; animation: floatLogo 5s ease-in-out infinite; }

.hero-content { flex: 1 1 380px; min-width: 300px; }
.hero-badges { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 28px; }
.hero-title { font-family: 'Playfair Display', serif; font-size: clamp(40px,5.6vw,66px); line-height: 1.03; font-weight: 800; color: var(--cream); margin: 0 0 26px; letter-spacing: -1px; }
.hero-title em { font-style: normal; color: var(--gold-light); }
.hero-text { font-size: clamp(16px,1.6vw,19px); line-height: 1.65; color: var(--cream); opacity: 0.78; max-width: 460px; margin: 0 0 34px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 36px; }
.hero-chips { display: flex; gap: 12px; flex-wrap: wrap; }

.marquee-wrap {
  position: relative; z-index: 1; margin-top: 56px; padding: 16px 0;
  border-top: 1px solid rgba(230,205,143,0.15);
  overflow: hidden; white-space: nowrap;
}
.marquee-track { display: inline-flex; gap: 48px; animation: marqueeScroll 22s linear infinite; }
.marquee-item { font-family: 'Playfair Display', serif; font-size: 15px; color: var(--gold-light); opacity: 0.7; letter-spacing: 0.5px; }

/* languages strip */
.langs-strip { background: #e9dcb9; padding: 34px 6vw; }
.langs-strip__inner { max-width: 1100px; margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 28px; text-align: center; }
.langs-strip__label { font-family: 'Playfair Display', serif; font-size: 17px; font-weight: 700; color: var(--ink); white-space: nowrap; }
.langs-strip__flags { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.lang-flag { display: flex; align-items: center; gap: 6px; background: rgba(28,70,52,0.07); border: 1px solid rgba(28,70,52,0.16); border-radius: 30px; padding: 6px 14px; font-size: 13.5px; color: var(--ink); opacity: 0.85; }
.lang-flag__emoji { font-family: "Noto Color Emoji", sans-serif; font-size: 17px; line-height: 1; }

/* ==========================================================================
   Sections
   ========================================================================== */

.section { padding: clamp(70px,8vw,110px) 6vw; }

@media (max-width: 640px) {
  .section { padding-left: 28px; padding-right: 28px; }
}
.section--cream { background: var(--cream); }
.section--deep { background: var(--green-deep); }
.section--mid { background: var(--green-mid); }

.section-head { text-align: center; margin-bottom: 64px; }
.eyebrow { font-size: 13px; letter-spacing: 2px; text-transform: uppercase; font-weight: 700; margin-bottom: 14px; }
.eyebrow--red { color: var(--red); }
.eyebrow--gold { color: var(--gold-light); }
.section-title { font-family: 'Playfair Display', serif; font-size: clamp(28px,3.6vw,42px); font-weight: 700; margin: 0; }
.section-title--light { color: var(--cream); }
.section-title--dark { color: var(--ink); }
.section-sub { font-size: 16px; opacity: 0.65; margin: 14px auto 0; max-width: 520px; }
.section-sub--light { color: var(--cream); }

/* advantages */
.advantages-grid {
  display: grid; grid-template-columns: repeat(auto-fit,minmax(260px,1fr)); gap: 2px;
  background: rgba(28,70,52,0.12); border: 1px solid rgba(28,70,52,0.14);
  border-radius: 18px; overflow: hidden;
}
.advantage-card { background: var(--cream); padding: 34px 28px; display: flex; flex-direction: column; gap: 14px; }
.advantage-icon {
  width: 57px; height: 57px; border-radius: 14px;
  background: linear-gradient(135deg, var(--green) 0%, var(--green-deep) 100%);
  box-shadow: 0 10px 20px rgba(14,42,32,0.3);
  display: flex; align-items: center; justify-content: center;
}
.advantage-icon__glyph { fill: var(--gold-light); filter: drop-shadow(0 2px 4px rgba(0,0,0,0.35)); }
.advantage-icon--red .advantage-icon__glyph { fill: var(--gold); }
.advantage-card h3 { font-family: 'Playfair Display', serif; font-size: 18px; font-weight: 600; margin: 0; color: var(--green-deep); }
.advantage-card p { font-size: 14.5px; line-height: 1.55; color: var(--ink); opacity: 0.72; margin: 0; }

/* features */
.feature-row { display: flex; align-items: center; gap: 56px; flex-wrap: wrap; margin-bottom: 90px; }
.feature-row.reverse { flex-direction: row-reverse; }
.feature-row:last-child { margin-bottom: 0; }
.feature-text { flex: 1 1 380px; min-width: 300px; }
.feature-subtitle { color: var(--gold-light); font-size: 16px; line-height: 1.5; margin: 0 0 10px; opacity: 0.85; }
.feature-title { font-family: 'Playfair Display', serif; font-size: clamp(22px,2.6vw,30px); font-weight: 600; color: var(--cream); margin: 0 0 18px; }
.feature-points { list-style: none; margin: 0; padding: 0; }
.feature-points li { display: flex; gap: 12px; margin-bottom: 12px; align-items: flex-start; }
.feature-points li::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); margin-top: 8px; flex: none; }
.feature-points p { font-size: 15px; line-height: 1.6; color: var(--cream); opacity: 0.78; margin: 0; }
.feature-media { flex: 1 1 280px; min-width: 260px; display: flex; justify-content: center; }

/* device shot — screenshot mockups that already include their own phone/tablet bezel */
.device-shot {
  width: 230px; max-width: 100%; height: auto; display: block;
  filter: drop-shadow(0 40px 70px rgba(0,0,0,0.45));
}
.device-shot--tablet { width: min(720px, 82vw); }

/* image placeholder (screenshots / blog covers not yet supplied) */
.img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  text-align: center; padding: 16px;
  background:
    repeating-linear-gradient(45deg, rgba(230,205,143,0.08) 0 2px, transparent 2px 18px),
    var(--green);
  color: var(--gold-light);
  font-size: 12.5px; letter-spacing: 0.4px; line-height: 1.5;
}

/* devices showcase — phone + tablet side by side */
.devices-showcase { display: flex; align-items: center; justify-content: center; gap: 56px; flex-wrap: wrap; margin-top: 8px; }
.devices-item { display: flex; flex-direction: column; align-items: center; gap: 18px; margin: 0; }
.devices-caption { font-size: 13px; letter-spacing: 1.5px; text-transform: uppercase; font-weight: 700; color: var(--gold-light); opacity: 0.85; }

/* formats */
.formats-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(240px,1fr)); gap: 22px; }
.format-card { background: var(--green); border-radius: 18px; padding: 32px 26px; display: flex; flex-direction: column; gap: 20px; }
.format-dots { display: flex; gap: 6px; }
.format-dot { width: 22px; height: 22px; color: var(--gold-light); }
.format-count { font-family: 'Playfair Display', serif; font-size: 34px; font-weight: 700; color: var(--cream); }
.format-desc { font-size: 14.5px; line-height: 1.55; color: var(--cream); opacity: 0.75; }

/* stats */
.stats-row { display: flex; align-items: center; gap: 64px; flex-wrap: wrap; }
.stats-media { flex: 1 1 300px; min-width: 260px; display: flex; justify-content: center; }
.stats-content { flex: 1 1 420px; min-width: 300px; }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.stat-card { border-left: 2px solid var(--gold); padding-left: 16px; }
.stat-card__title { font-family: 'Playfair Display', serif; font-size: 16px; font-weight: 600; color: var(--cream); margin-bottom: 4px; }
.stat-card__text { font-size: 13.5px; color: var(--cream); opacity: 0.68; line-height: 1.5; }

@media (max-width: 640px) {
  /* Ces blocs utilisent flex-basis + min-width pour une mise en page à deux
     colonnes sur desktop/tablette ; en dessous de 640px ils sont déjà en une
     seule colonne (flex-wrap), donc le min-width ne sert plus qu'à provoquer
     un débordement horizontal sur les petits téléphones (ex. 320-360px). */
  .hero-content, .hero-media,
  .feature-text, .feature-media,
  .stats-content, .stats-media {
    min-width: 0;
  }
}

/* blog */
.blog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 48px; }
.blog-more { font-weight: 700; color: var(--green-deep); font-size: 14.5px; }
.blog-more:hover { color: var(--red); }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(280px,1fr)); gap: 24px; }
.blog-card { display: block; color: var(--ink); }
.blog-card:hover { opacity: 0.85; }
.blog-thumb { aspect-ratio: 16/10; border-radius: 16px; overflow: hidden; border: 1px solid rgba(28,70,52,0.14); }
.blog-meta { font-size: 12.5px; color: var(--red); margin-top: 16px; letter-spacing: 1px; text-transform: uppercase; font-weight: 700; }
.blog-title { font-family: 'Playfair Display', serif; font-size: 21px; margin-top: 8px; line-height: 1.3; color: var(--green-deep); font-weight: 600; }

/* download card */
.download-card {
  position: relative; overflow: hidden; border-radius: 32px;
  border: 1px solid rgba(230,205,143,0.3);
  background: radial-gradient(ellipse at 50% 0%, var(--green) 0%, var(--green-deep) 70%);
  padding: clamp(48px,7vw,88px) 6vw; text-align: center;
}
.download-card img { width: 240px; max-width: 60%; margin: 0 auto; }
.download-card h2 { font-family: 'Playfair Display', serif; font-size: clamp(30px,4.4vw,52px); font-weight: 800; color: var(--cream); margin: 26px 0 0; letter-spacing: -0.5px; }
.download-card p { font-size: 17px; color: var(--cream); opacity: 0.78; line-height: 1.6; margin: 16px auto 0; max-width: 480px; }
.download-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 36px; }

/* ==========================================================================
   Inner-page hero banner (blog, règles, variantes)
   ========================================================================== */

.page-hero {
  position: relative; overflow: hidden;
  background: #13301e;
  padding: clamp(150px,18vw,190px) 6vw 64px;
  text-align: center;
}
.page-hero .hero-blob,
.page-hero .hero-pattern { position: absolute; }
.page-hero-inner { position: relative; z-index: 1; max-width: 760px; margin: 0 auto; }
.page-hero .eyebrow { justify-content: center; }
.page-hero h1 { font-family: 'Playfair Display', serif; font-size: clamp(32px,4.6vw,54px); font-weight: 800; color: var(--cream); margin: 0 0 16px; letter-spacing: -0.5px; }
.page-hero p { font-size: 16.5px; line-height: 1.65; color: var(--cream); opacity: 0.78; margin: 0; }

/* Variante compacte pour les pages d'administration : moins d'espace perdu, plus de contenu utile à l'écran. */
.page-hero--admin { padding: 104px 6vw 20px; }
.page-hero--admin h1 { font-size: clamp(24px,2.8vw,32px); margin: 0 0 6px; }
.page-hero--admin .eyebrow { margin-bottom: 4px; }
.page-hero--admin p { font-size: 14.5px; }
.section--admin { padding: 22px 6vw 60px; }

/* ==========================================================================
   Login form
   ========================================================================== */

.container--narrow { max-width: 440px; margin: 0 auto; }
.login-card {
  display: flex; flex-direction: column; gap: 18px;
  background: var(--green); border-radius: 20px; padding: 40px 34px;
}
.login-field { display: flex; flex-direction: column; gap: 8px; }
.login-field span { font-size: 13px; font-weight: 700; letter-spacing: 0.3px; color: var(--gold-light); }
.login-field input,
.login-field textarea {
  font-family: 'Inter', sans-serif; font-size: 15px; color: var(--cream);
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px; padding: 12px 14px; outline: none;
}
.login-field textarea { resize: vertical; min-height: 150px; }
.login-field input:focus,
.login-field textarea:focus { border-color: var(--gold); }
/* Neutralise le fond bleu/jaune de l'autocomplétion navigateur pour que les
   champs texte restent visuellement identiques au textarea (#1c4634 + 6% blanc). */
.login-field input:-webkit-autofill,
.login-field input:-webkit-autofill:hover,
.login-field input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--cream);
  caret-color: var(--cream);
  -webkit-box-shadow: 0 0 0 1000px #2a5140 inset;
  transition: background-color 9999s ease-in-out 0s;
}
.login-error {
  font-size: 14px; color: var(--cream); background: var(--red);
  border-radius: 10px; padding: 12px 14px;
}
.login-success {
  font-size: 14px; line-height: 1.6; color: var(--cream); background: var(--green);
  border-radius: 20px; padding: 24px 28px;
}
.login-submit { border: none; cursor: pointer; margin-top: 6px; }

/* ==========================================================================
   Prose (article / rules / variants content)
   ========================================================================== */

.prose { max-width: 760px; margin: 0 auto; }
.prose h2 { font-family: 'Playfair Display', serif; font-size: clamp(24px,3vw,32px); font-weight: 700; color: var(--green-deep); margin: 56px 0 18px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-family: 'Playfair Display', serif; font-size: 20px; font-weight: 600; color: var(--green-deep); margin: 30px 0 12px; }
.prose p { font-size: 16px; line-height: 1.75; color: var(--ink); opacity: 0.82; margin: 0 0 18px; }
.prose ul, .prose ol { margin: 0 0 18px; padding-left: 22px; }
.prose li { font-size: 16px; line-height: 1.7; color: var(--ink); opacity: 0.82; margin-bottom: 8px; }
.prose strong { color: var(--green-deep); }
.prose table { width: 100%; border-collapse: collapse; margin: 0; font-size: 15px; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 24px; }
.prose th, .prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid rgba(28,70,52,0.14); }
.prose th { color: var(--green-deep); font-weight: 700; }
.prose blockquote {
  margin: 0 0 24px; padding: 18px 22px; border-left: 3px solid var(--gold);
  background: rgba(28,70,52,0.05); color: var(--ink); opacity: 0.85; font-size: 15.5px; line-height: 1.6;
}

.article-meta { display: flex; gap: 10px; align-items: center; justify-content: center; flex-wrap: wrap; font-size: 13px; color: var(--gold-light); text-transform: uppercase; letter-spacing: 1px; font-weight: 700; margin-bottom: 18px; }
.article-meta .dot-sep { opacity: 0.5; }

.back-link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; color: var(--green-deep); margin-bottom: 28px; }
.back-link:hover { color: var(--red); }

.blog-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.article-cover { max-width: 760px; margin: 0 auto 36px; border-radius: 16px; overflow: hidden; border: 1px solid rgba(28,70,52,0.14); }
.article-cover img { width: 100%; display: block; }

/* toc / summary cards used on règles + variantes pages */
.summary-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap: 18px; margin: 0 0 56px; }
.summary-card { background: var(--cream); border: 1px solid rgba(28,70,52,0.14); border-radius: 16px; padding: 22px 24px; }
.summary-card .num { font-family: 'Playfair Display', serif; font-size: 22px; font-weight: 700; color: var(--red); margin-bottom: 6px; }
.summary-card h3 { margin: 0 0 6px; font-size: 16px; }
.summary-card p { margin: 0; font-size: 13.5px; opacity: 0.7; }

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer { background: var(--green-deep); padding: 56px 6vw 32px; border-top: 1px solid rgba(230,205,143,0.18); }
.footer-top { max-width: 1160px; margin: 0 auto; display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; padding-bottom: 36px; }
.footer-brand { max-width: 280px; }
.footer-brand-row { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.footer-brand-row img { width: 180px; border-radius: 8px; object-fit: cover; }
.footer-brand-row span { font-family: 'Playfair Display', serif; font-size: 18px; font-weight: 700; color: var(--cream); }
.footer-brand p { font-size: 13.5px; color: var(--cream); opacity: 0.6; line-height: 1.6; margin: 0; }
.footer-cols { display: flex; gap: 56px; flex-wrap: wrap; }
.footer-col-title { color: var(--gold-light); font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; margin-bottom: 16px; font-weight: 700; }
.footer-link { display: block; font-size: 14px; color: var(--cream); opacity: 0.7; margin-bottom: 10px; }
.footer-link:hover { opacity: 1; color: var(--gold-light); }
.footer-bottom { max-width: 1160px; margin: 0 auto; padding-top: 24px; border-top: 1px solid rgba(230,205,143,0.12); font-size: 12.5px; color: var(--cream); opacity: 0.5; display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; }
.footer-bottom a { color: inherit; text-decoration: underline; }
.footer-bottom a:hover { color: var(--gold-light); opacity: 1; }
.footer-legal-links { display: flex; flex-wrap: wrap; }
.footer-legal-link { padding: 0 12px; border-right: 1px solid rgba(255,255,255,0.2); }
.footer-legal-link:first-child { padding-left: 0; }
.footer-legal-link:last-child { border-right: none; padding-right: 0; }

@media (max-width: 640px) {
  .footer-brand { max-width: 100%; text-align: center; }
  .footer-brand-row { justify-content: center; }

  .footer-link { padding: 9px 4px; margin-bottom: 0; font-size: 15px; }

  .footer-bottom { flex-direction: column; align-items: center; text-align: center; gap: 4px; padding-bottom: 56px; opacity: 1; }
  .footer-copy { opacity: 0.6; }
  .footer-legal-links { flex-direction: column; align-items: stretch; width: 100%; }
  .footer-legal-link {
    display: block; width: 100%; padding: 9px 4px; border-right: none;
    border-bottom: 1px solid rgba(230,205,143,0.14);
    font-size: 12.5px; text-decoration: none; opacity: 0.65;
  }
  .footer-legal-link:last-child { border-bottom: none; }
  .footer-legal-link:hover { opacity: 1; }
}

/* ==========================================================================
   Admin
   ========================================================================== */

.admin-dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap: 18px; }
.admin-dashboard-card { display: block; background: var(--green); border-radius: 16px; padding: 26px 24px; }
.admin-dashboard-card:hover { background: var(--green-mid); }
.admin-dashboard-card-title { font-family: 'Playfair Display', serif; font-size: 19px; font-weight: 700; color: var(--gold-light); margin-bottom: 8px; }
.admin-dashboard-card p { font-size: 14px; line-height: 1.55; color: var(--cream); opacity: 0.78; margin: 0; }

.admin-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.admin-btn { border: none; cursor: pointer; }

.admin-notice { background: rgba(28,70,52,0.08); border: 1px solid rgba(28,70,52,0.16); color: var(--green-deep); border-radius: 10px; padding: 12px 16px; font-size: 14px; margin-bottom: 20px; }
.admin-empty { text-align: center; opacity: 0.7; padding: 40px 0; }

.admin-table-wrap { overflow-x: auto; border-radius: 16px; border: 1px solid rgba(28,70,52,0.14); background: #fff; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th, .admin-table td { text-align: left; padding: 14px 16px; border-bottom: 1px solid rgba(28,70,52,0.1); vertical-align: middle; white-space: nowrap; }
.admin-table th { color: var(--green-deep); font-size: 12px; letter-spacing: 0.6px; text-transform: uppercase; opacity: 0.65; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-table-title { font-weight: 700; color: var(--green-deep); white-space: normal; }
.admin-table-title:hover { color: var(--red); }
.admin-table-slug { font-size: 12px; opacity: 0.55; margin-top: 2px; }
.admin-table-actions { display: flex; gap: 14px; align-items: center; }
.admin-table-actions a { font-weight: 600; color: var(--green-deep); }
.admin-table-actions a:hover { color: var(--red); }
.admin-table-actions form { display: inline; margin: 0; }

.admin-badge { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: 0.4px; text-transform: uppercase; padding: 4px 10px; border-radius: 20px; }
.admin-badge--publie { background: rgba(28,70,52,0.12); color: var(--green-deep); }
.admin-badge--brouillon { background: rgba(156,43,58,0.1); color: var(--red); }
.admin-badge--lang { background: rgba(28,70,52,0.08); color: var(--green-deep); opacity: 0.8; }
.admin-badge:not(.admin-badge--publie):not(.admin-badge--brouillon):not(.admin-badge--lang) { background: rgba(0,0,0,0.08); color: inherit; opacity: 0.7; margin-left: 6px; }

.admin-lang-flags { display: flex; flex-wrap: wrap; gap: 4px; }
.admin-lang-flag {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 26px; border-radius: 7px; font-size: 15px; line-height: 1;
  text-decoration: none; border: 1px solid rgba(28,70,52,0.14); background: rgba(28,70,52,0.04);
  opacity: 0.35; transition: opacity .15s ease, transform .15s ease;
}
.admin-lang-flag:hover { opacity: 1; transform: translateY(-1px); }
.admin-lang-flag.is-complete { opacity: 1; border-color: rgba(28,70,52,0.3); background: rgba(28,70,52,0.1); }
.admin-lang-flag.is-incomplete { opacity: 0.35; }
.admin-lang-flag.is-incomplete:hover { opacity: 1; }

.admin-link-danger { background: none; border: none; cursor: pointer; font-family: 'Inter', sans-serif; font-size: 14px; font-weight: 600; color: var(--red); padding: 0; }
.admin-link-danger:hover { text-decoration: underline; }

.admin-form { display: flex; flex-direction: column; gap: 18px; margin-top: 12px; }
.admin-form .login-field input,
.admin-form .login-field select,
.admin-form .login-field textarea {
  font-family: 'Inter', sans-serif; font-size: 15px; color: var(--cream);
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px; padding: 12px 14px; outline: none; resize: vertical; width: 100%;
}
.admin-form .login-field input:focus,
.admin-form .login-field select:focus,
.admin-form .login-field textarea:focus { border-color: var(--gold); }
.admin-form .login-field input[type="file"] { padding: 8px; }
.admin-form .login-field input[type="date"] { color-scheme: dark; }
.admin-textarea-mono { font-family: 'SFMono-Regular', Consolas, monospace; font-size: 13.5px; line-height: 1.65; }
.admin-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.admin-checkbox { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--cream); opacity: 0.85; margin-top: 10px; }
.admin-checkbox input { width: auto; }
.admin-cover-preview { display: flex; flex-direction: column; gap: 10px; }
.admin-cover-preview img { max-width: 100%; border-radius: 12px; border: 1px solid rgba(255,255,255,0.14); }
.admin-errors ul { margin: 0; padding-left: 18px; }

/* Formulaire d'article : grande colonne d'édition + colonne latérale de méta-données. */
.admin-form--split { display: grid; grid-template-columns: minmax(0,1fr) 380px; align-items: start; gap: 28px; }
.admin-form-main { display: flex; flex-direction: column; gap: 18px; background: var(--green); border-radius: 20px; padding: 34px; }
.admin-form-main .login-field textarea[name="contenu"] { min-height: 60vh; }
.admin-form-side { display: flex; flex-direction: column; gap: 18px; position: sticky; top: 24px; }
.admin-form-side-block { display: flex; flex-direction: column; gap: 16px; background: var(--green); border-radius: 16px; padding: 22px; }
.admin-form-side-title { font-size: 12px; letter-spacing: 1px; text-transform: uppercase; font-weight: 700; color: var(--gold-light); }
.admin-btn--block { width: 100%; text-align: center; }

.admin-static-value {
  font-size: 15px; color: var(--cream); background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.14); border-radius: 10px; padding: 12px 14px;
}

.admin-translation-list { display: flex; flex-direction: column; gap: 10px; list-style: none; margin: 0; padding: 0; }
.admin-translation-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  font-size: 13.5px; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,0.04);
  border-left: 3px solid transparent;
}
.admin-translation-item.is-complete { border-left-color: var(--gold); }
.admin-translation-item.is-missing { border-left-color: var(--red); opacity: 0.85; }
.admin-translation-lang { font-weight: 700; color: var(--cream); }
.admin-translation-status { color: var(--cream); opacity: 0.7; margin-right: auto; margin-left: 10px; }
.admin-translation-item a { font-weight: 600; color: var(--gold-light); }
.admin-translation-item a:hover { color: var(--gold); }
.admin-translation-hint { font-size: 12.5px; color: var(--cream); opacity: 0.65; margin: 4px 0 0; line-height: 1.5; }
.admin-translation-hint--ok { color: var(--gold-light); opacity: 0.95; }
.admin-translation-hint--warning { color: #e0a95a; opacity: 0.95; }
.admin-translation-hint--warning code { background: rgba(255,255,255,0.1); padding: 1px 5px; border-radius: 4px; }
.admin-char-counter { display: block; font-size: 11.5px; color: var(--cream); opacity: 0.5; margin-top: 3px; text-align: right; }
.admin-char-counter.is-over { color: #e07a7a; opacity: 1; }
.admin-fr-ref { margin: 2px 0 5px; }
.login-field .admin-fr-ref-text { font-size: 9px; font-weight: 200; color: #fff; letter-spacing: normal; }
.admin-fr-ref-copy { background: none; border: none; cursor: pointer; font-size: 11px; line-height: 1; padding: 0; margin-left: 2px; opacity: 0.6; vertical-align: middle; }
.admin-fr-ref-copy:hover { opacity: 1; }
.admin-fr-ref-copy.is-copied { opacity: 1; }

.ai-translate-card { margin-top: 24px; }

@media (max-width: 900px) {
  .admin-form--split { grid-template-columns: 1fr; }
  .admin-form-side { position: static; }
}

@media (max-width: 640px) {
  .admin-form-row { grid-template-columns: 1fr; }
  .admin-table th, .admin-table td { white-space: normal; }
}

/* ==========================================================================
   Back-to-top button
   ========================================================================== */

.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 90;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  background: rgba(14,42,32,0.92);
  color: var(--gold-light);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease, background 0.2s ease, border-color 0.2s ease;
  box-shadow: 0 10px 24px rgba(0,0,0,0.25);
}
.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.back-to-top:hover {
  background: var(--gold);
  color: var(--green-deep);
  border-color: var(--gold-light);
}
.back-to-top svg { width: 18px; height: 18px; }

@media (max-width: 599px) {
  .back-to-top { right: 16px; bottom: 16px; width: 42px; height: 42px; }
}
