/* ===== APP HEADER ===== */
.appHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--panel);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border-light);
}

.appHeaderLeft {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.headerLogo {
  border-radius: 12px;
  object-fit: contain;
}

.appTitle {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--ink-0);
  letter-spacing: -0.02em;
}

.burgerBtn {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.burgerLine {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--ink-0);
  border-radius: 2px;
}

.menuWrapper {
  position: relative;
}

.mobileMenu {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  background: var(--panel);
  border-radius: 1.35rem;
  box-shadow: 0 14px 36px #0000002e;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-width: 220px;
  z-index: 200;
  animation: slideDown 180ms ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.menuDivider {
  height: 1px;
  background: var(--border-light);
  margin: 0.25rem 0;
}

.logoutBtn {
  margin-top: 0.1rem;
  width: 100%;
  text-align: center;
}

.loadingScreen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  min-height: 60vh;
  color: var(--muted);
}

/* ===== PAGE LAYOUT ===== */
.page {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-bottom: 2rem;
}

/* ===== TABS (burger menu legacy) ===== */
.tab {
  border: 1px solid var(--border);
  background: var(--panel-warm);
  color: var(--ink-1);
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-btn);
  font-size: 0.88rem;
  font-weight: 700;
  text-align: center;
}

.tabActive {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}

/* ===== MAIN TAB BAR (inline content tabs) ===== */
.contentTabBar {
  display: flex;
  gap: 0.45rem;
  padding: 0 0.5rem;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
}

.contentTabBar::-webkit-scrollbar {
  display: none;
}

.contentTabItem {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-btn);
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  text-decoration: none;
  border: 1.5px solid var(--border);
  background: var(--panel);
  color: var(--muted);
  transition: color 120ms, background 120ms, border-color 120ms;
}

.contentTabItem:hover {
  color: var(--ink-1);
  border-color: var(--ink-1);
}

.contentTabItemActive {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 800;
}

.contentTabItemActive:hover {
  color: #fff;
  border-color: var(--accent-strong);
  background: var(--accent-strong);
}

/* ===== TOPBAR (fallback for desktop) ===== */
.topbar {
  padding: 0.95rem 1.1rem;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.9rem;
  align-items: center;
}

.topbar h1 {
  color: var(--ink-0);
  font-size: 1.3rem;
}

.topbarMeta {
  margin-top: 0.7rem;
}

.topbarNav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: flex-end;
}

/* ===== PROJECT SWITCHER ===== */
.projectSwitcher {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.projectSwitcherLabel {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink-1);
}

.projectSwitcherSelect {
  min-width: 200px;
  border: 1px solid var(--border);
  background: var(--panel-warm);
  border-radius: var(--radius-input);
  padding: 0.4rem 0.52rem;
  color: var(--ink-1);
  font-weight: 700;
}

.projectSwitcherMeta {
  border: 1px solid var(--border);
  border-radius: var(--radius-btn);
  padding: 0.22rem 0.58rem;
  background: var(--panel-warm);
  color: var(--ink-1);
  font-size: 0.78rem;
}

.projectSwitcherError {
  color: var(--accent);
  font-size: 0.85rem;
}

/* ===== BABY BANNER ===== */
.babyBanner {
  padding: 0.85rem 1rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem;
  background: var(--panel-warm);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-card);
  border-left: 4px solid var(--teal);
}

.babyBannerLabel {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink-1);
}

.babyTabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

.babyTab {
  position: relative;
  border: 2px solid var(--border);
  background: var(--panel-warm);
  color: var(--ink-1);
  border-radius: var(--radius-btn);
  padding: 0.48rem 1rem;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.babyTabActive {
  border-color: var(--teal-strong);
  background: rgba(142, 218, 224, 0.15);
  color: var(--ink-0);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.babyTabDirtyDot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

/* ===== HERO / BANNER SECTION ===== */
.hero {
  position: relative;
  padding: 0.9rem 0 0;
  background: #d2f0f2;
  overflow: hidden;
  min-height: 264px;
  container-type: inline-size;
}

.heroSoftPink {
  background: #f8dfe8;
}

/* Texte titre + sous-titre, flux normal en haut */
.heroInner {
  position: relative;
  z-index: 6;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.1rem;
  padding: 0 1rem;
}

.hero h2 {
  font-family: var(--font-baloo), sans-serif;
  font-size: 1.8rem;
  font-weight: 400;
  color: #000;
  line-height: 1.15;
}

.hero p {
  font-family: var(--font-baloo), sans-serif;
  font-size: 0.95rem;
  font-weight: 400;
  color: #000;
  line-height: 1.3;
}

@container (max-width: 430px) {
  .heroInner {
    padding: 0 3.9rem;
  }

  .hero p {
    max-width: none;
    white-space: nowrap;
    font-size: 0.78rem;
    line-height: 1.12;
  }

  .heroProjectPhoto {
    top: 82px;
  }
}

@container (max-width: 330px) {
  .hero h2 {
    font-size: 1.35rem;
    line-height: 1.06;
  }

  .heroInner {
    padding: 0 4.2rem;
  }

  .hero p {
    max-width: 8.6rem;
    white-space: normal;
    font-size: 0.66rem;
    line-height: 1.08;
  }
}

/* Photo de profil — absolute, centrée horizontalement */
.heroProjectPhoto {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 68px;
  z-index: 15;
  width: 124px;
  height: 124px;
  border-radius: 50%;
  border: 6px solid #fff;
  overflow: hidden;
  box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
  background: #e4f4fb;
  pointer-events: none;
}

/* Familles — absolute en bas, space-between */
.heroBannerRow {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  z-index: 5;
}

.heroBannerImageWrap {
  display: flex;
  align-items: flex-end;
}

.heroBannerImage {
  height: auto;
  object-fit: contain;
}

.heroBannerImageLeft {
  width: 199px;
}

.heroBannerImageRight {
  width: 202px;
}

/* Vague SVG en bas — derrière les familles */
.heroWave {
  position: absolute;
  bottom: 0;
  left: -1px;
  right: -1px;
  z-index: 3;
  pointer-events: none;
  line-height: 0;
  display: flex;
}

/* Décorations coins haut gauche/droite */
.heroCornerDecoFrame {
  position: absolute;
  top: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 10;
}

.heroCornerDecoFrameLeft {
  left: 0;
  width: 128px;
  height: 164px;
}

.heroCornerDecoFrameRight {
  right: 0;
  width: 148px;
  height: 174px;
}

.heroCornerDeco {
  object-fit: cover;
}

.heroCornerDecoLeft {
  object-position: left top;
}

.heroCornerDecoRight {
  object-position: right top;
}

/* statPill gardé pour éventuelle utilisation ailleurs */
.statPill {
  border: 1px solid rgba(231, 223, 210, 0.95);
  border-radius: var(--radius-btn);
  padding: 0.4rem 0.9rem;
  min-width: 6.5rem;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 4px 12px rgba(0, 80, 120, 0.08);
  font-size: 0.875rem;
  color: var(--ink-1);
  font-weight: 700;
}

/* ===== TILES GRID ===== */

.sectionTitle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.3rem 0;
}

.sectionTitle h2 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--ink-0);
  text-align: center;
}

.tilesGrid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 0 0.5rem;
  align-items: stretch;
}

.tileShell {
  display: grid;
  container-type: inline-size;
}

.tileShell > .tile {
  height: 100%;
}

.tileShellWeight {
  grid-column: 1 / -1;
  overflow: visible;
}

/* ===== TILE CARD ===== */
.tile {
  background: var(--panel);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  position: relative;
  overflow: hidden;
}

.tileFavorite {
  border-color: var(--teal);
  background: linear-gradient(170deg, #fef9f0, #fdf6ec);
}

.tileHeader {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.4rem;
}

.tileHeader h3 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--ink-0);
}

.tileHeader p {
  font-size: 0.82rem;
  color: var(--muted);
}

.tileIcon {
  width: 48px;
  height: 48px;
  object-fit: contain;
  margin-bottom: 0.2rem;
}

.badge {
  align-self: center;
  border-radius: var(--radius-btn);
  border: 1px solid var(--border);
  background: var(--panel-warm);
  color: var(--ink-1);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
}

.tileBody {
  display: grid;
  gap: 0.5rem;
}

.tileFooter {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: center;
}

.tileFooter .btn-primary {
  width: 100%;
  border-radius: var(--radius-btn);
  padding: 0.65rem;
  font-size: 0.85rem;
}

.pointsLabel {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--ink-0);
}

.pointsLabelIcon {
  width: 22px;
  height: 22px;
}

.dirty {
  font-size: 0.8rem;
  color: #c89020;
  text-align: center;
}

.success,
.error {
  border-radius: var(--radius-input);
  border: 1px solid var(--border);
  padding: 0.45rem 0.6rem;
  font-size: 0.82rem;
  text-align: center;
}

.success {
  background: #e8f6e8;
  color: #256b25;
}

.error {
  background: #ffeceb;
  color: #8e2f2f;
}

.fieldGrid {
  display: grid;
  gap: 0.5rem;
}

.optionIconsRow {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.optionIconBtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  background: none;
  border: 2px solid transparent;
  border-radius: var(--radius-card);
  padding: 0.5rem 0.7rem;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease;
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--ink-1);
}

.optionIconBtn:hover {
  background: var(--panel-warm);
}

.optionIconBtnActive {
  border-color: var(--teal-strong);
  background: rgba(142, 218, 224, 0.12);
}

.numberInputRow {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: #fafafa;
  border: 1px solid var(--border);
  border-radius: var(--radius-input);
  padding: 0 0.6rem;
}

.numberInputRow input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0.6rem 0;
  font-size: 0.95rem;
  outline: none;
  min-width: 0;
}

.numberUnit {
  font-weight: 700;
  color: var(--muted);
  font-size: 0.9rem;
  white-space: nowrap;
}

/* ===== WEIGHT EDITOR ===== */
.weightEditor {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.weightValue {
  font-size: 1.2rem;
  color: var(--ink-0);
  font-weight: 800;
  text-align: center;
}

.sliderGroup {
  display: grid;
  gap: 0.3rem;
  width: 100%;
}

.sliderGroup label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink-1);
}

.sliderGroup input[type="range"] {
  width: 100%;
  accent-color: var(--teal-strong);
  height: 8px;
}

.sliderMeta {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 600;
}

/* ===== WEIGHT TILE FIGMA REDESIGN ===== */
.weightTileWrapper {
  position: relative;
  container-type: inline-size;
}

.weightTile {
  display: grid !important;
  grid-template-columns: 43.92% 56.08%;
  grid-template-rows: minmax(0, 1fr);
  padding: 0 !important;
  gap: 0 !important;
  width: 100%;
  aspect-ratio: 1266 / 666;
  min-height: 0;
  align-items: stretch;
  container-type: inline-size;
  overflow: hidden !important;
  isolation: isolate;
  background: #ffffff !important;
  border: none !important;
  border-radius: 2rem !important;
  box-shadow: 4px 4px 24px 0px rgba(0, 0, 0, 0.25) !important;
}

.weightTileLeft {
  min-width: 0;
  min-height: 0;
  height: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  position: relative;
  overflow: hidden;
  border-top-left-radius: inherit;
  border-bottom-left-radius: inherit;
  padding: 0;
}

.weightTileLeftCircle {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 95.15%;
  height: 78.68%;
  background: url("/images/pictos/weight-backdrop-figma.svg") no-repeat left bottom / 100% 100%;
  z-index: 0;
}

.weightTileLeftCircleGirl {
  background-image: url("/images/pictos/weight-backdrop-figma-girl.svg");
}

.weightTileLeftImg {
  position: relative;
  z-index: 1;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain;
  object-position: left bottom;
  display: block;
  transform: none;
}

.weightTileRight {
  display: flex;
  flex-direction: column;
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  margin-left: -0.4cqi;
  padding: 3.8cqi 3.9cqi 3.2cqi 0.6cqi;
}

.weightMedalIcon {
  position: absolute;
  top: -4.7cqi;
  right: -0.2cqi;
  width: 12.8cqi !important;
  max-width: none !important;
  height: auto !important;
  object-fit: contain;
  z-index: 10;
}

.weightTitleBlock {
  display: grid;
  gap: 0.2cqi;
  width: 79%;
  margin-left: 2.2cqi;
  padding: 0;
}

.weightTitleLine {
  font-size: clamp(0.92rem, 4.12cqi, 1.38rem);
  font-weight: 700;
  color: var(--ink-0);
  line-height: 0.95;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.weightTitleLineSub {
  font-size: clamp(0.9rem, 3.95cqi, 1.34rem);
  font-weight: 700;
  color: var(--ink-0);
  line-height: 0.95;
  white-space: nowrap;
}

.weightValueRow {
  display: flex;
  align-items: flex-end;
  gap: 0.8cqi;
  flex-wrap: nowrap;
  margin-top: 4.6cqi;
  margin-bottom: 2.5cqi;
}

.weightValueLabel {
  font-size: clamp(0.86rem, 3.5cqi, 1.16rem);
  font-weight: 700;
  color: var(--ink-0);
  line-height: 1;
  white-space: nowrap;
}

.predictionAnswerBadgeSurface {
  color: var(--ink-0);
  white-space: nowrap;
  background: #cdedec;
  border: 2px solid #b6d8d7;
  border-radius: 1.7cqi;
}

.predictionAnswerBadgeSurfaceVisible {
  background: #cdedec;
}

.predictionAnswerBadgeSurfaceGirl {
  background: #fce4ec;
  border-color: #f7bdc6;
}

.predictionAnswerBadgeSurfaceBoy {
  background: #cdedec;
  border-color: #b6d8d7;
}

.predictionAnswerBadgeSurfacePlaceholder {
  background: #fffaf2;
  border-color: #e8dece;
  color: #b1a692;
}

.weightValueBadge {
  display: block;
  padding: 0.45cqi 1.45cqi 0.35cqi;
  font-size: clamp(1.08rem, 4.7cqi, 1.62rem);
  font-weight: 400;
  line-height: 0.9;
}

.weightSliderBlock {
  display: grid;
  gap: 2cqi;
}

.weightSliderGroup {
  display: grid;
  gap: 0.65cqi;
}

.weightSlider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: max(7px, 1.5cqi);
  border-radius: 9999px;
  background: linear-gradient(
    to right,
    #46a9ba var(--fill-pct, 50%),
    #d8d8d6 var(--fill-pct, 50%)
  );
  outline: none;
  cursor: pointer;
  border: 2px solid #c7c7c7;
}

.weightSlider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: clamp(1.45rem, 5.3cqi, 1.95rem);
  height: clamp(1.45rem, 5.3cqi, 1.95rem);
  border-radius: 50%;
  background: #46a9ba;
  border: 3px solid #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  cursor: pointer;
}

.weightSlider::-moz-range-thumb {
  width: clamp(1.45rem, 5.3cqi, 1.95rem);
  height: clamp(1.45rem, 5.3cqi, 1.95rem);
  border-radius: 50%;
  background: #46a9ba;
  border: 3px solid #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  cursor: pointer;
}

.weightSlider:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.weightSliderGirl {
  background: linear-gradient(
    to right,
    var(--accent) var(--fill-pct, 50%),
    #d8d8d6 var(--fill-pct, 50%)
  );
}

.weightSliderGirl::-webkit-slider-thumb {
  background: var(--accent);
}

.weightSliderGirl::-moz-range-thumb {
  background: var(--accent);
}

.weightSliderMeta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--ink-0);
}

.weightSliderMetaValue {
  font-size: clamp(0.74rem, 3.05cqi, 1.04rem);
  font-weight: 400;
  line-height: 1;
}

.weightTileFooter {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: stretch;
  margin-top: 2.4cqi;
}

.weightTileFooter:empty {
  display: none;
}

@container (max-width: 510px) {
  .weightTile {
    aspect-ratio: 1266 / 714;
    min-height: clamp(14rem, 53vw, 15rem);
  }

  .weightTileLeftCircle {
    width: 100%;
    height: 76%;
  }

  .weightTileRight {
    margin-left: 0;
    padding: clamp(0.55rem, 3.2cqi, 0.85rem) clamp(0.5rem, 2.8cqi, 0.75rem)
      clamp(0.62rem, 3.2cqi, 0.9rem) clamp(0.45rem, 2.1cqi, 0.65rem);
  }

  .weightTileFooter {
    margin-top: clamp(0.4rem, 1.8cqi, 0.72rem);
    padding-bottom: 0.08rem;
  }

  .weightTileFooter .dirty {
    font-size: clamp(0.72rem, 2.05cqi, 0.8rem);
    line-height: 1.08;
  }

  .weightMedalIcon {
    top: -4cqi;
    right: 0.2cqi;
    width: 12cqi !important;
  }

  .weightTitleBlock {
    width: 83%;
    margin-left: 1.1cqi;
  }

  .weightValueRow {
    margin-top: clamp(0.35rem, 2.2cqi, 0.6rem);
    margin-bottom: clamp(0.3rem, 1.8cqi, 0.5rem);
  }

  /* Lissage mobile: éviter le saut visuel brutal autour de 510px */
  .weightSliderBlock {
    gap: clamp(0.75rem, 4.2cqi, 1.05rem);
  }

  .weightSliderGroup {
    gap: clamp(0.35rem, 1.9cqi, 0.6rem);
  }

  .weightSlider {
    height: clamp(0.78rem, 2.6cqi, 0.98rem);
    border-width: 2px;
  }

  .weightSlider::-webkit-slider-thumb {
    width: clamp(1.45rem, 6.2cqi, 1.82rem);
    height: clamp(1.45rem, 6.2cqi, 1.82rem);
  }

  .weightSlider::-moz-range-thumb {
    width: clamp(1.45rem, 6.2cqi, 1.82rem);
    height: clamp(1.45rem, 6.2cqi, 1.82rem);
  }

  .weightSliderMeta {
    padding-inline: 0.1rem;
  }

  .weightSliderMetaValue {
    font-size: clamp(0.68rem, 2.55cqi, 0.86rem);
    line-height: 1;
    white-space: nowrap;
  }
}

@container (max-width: 400px) {
  .weightTitleBlock {
    width: 86%;
    margin-left: 0;
  }

  .weightTitleLine,
  .weightTitleLineSub,
  .weightValueLabel {
    white-space: normal;
  }

  .weightValueRow {
    flex-wrap: wrap;
    row-gap: 0.8cqi;
    margin-top: 3cqi;
    margin-bottom: 1.7cqi;
  }

  .weightValueBadge {
    font-size: clamp(1rem, 4.3cqi, 1.2rem);
  }

  .weightSliderBlock {
    gap: clamp(0.68rem, 3.8cqi, 0.95rem);
  }

  .weightSliderGroup {
    gap: clamp(0.32rem, 1.8cqi, 0.52rem);
  }

  .weightSlider {
    height: clamp(0.74rem, 2.5cqi, 0.9rem);
  }

  .weightSlider::-webkit-slider-thumb {
    width: clamp(1.38rem, 5.8cqi, 1.68rem);
    height: clamp(1.38rem, 5.8cqi, 1.68rem);
  }

  .weightSlider::-moz-range-thumb {
    width: clamp(1.38rem, 5.8cqi, 1.68rem);
    height: clamp(1.38rem, 5.8cqi, 1.68rem);
  }
}

@container (max-width: 350px) {
  .weightMedalIcon {
    width: 10.5cqi !important;
  }

  .weightTitleLine {
    font-size: clamp(0.8rem, 3.9cqi, 1rem);
  }

  .weightTitleLineSub {
    font-size: clamp(0.78rem, 3.7cqi, 0.98rem);
  }

  .weightValueLabel {
    font-size: clamp(0.74rem, 3.2cqi, 0.95rem);
  }

  .weightSliderMetaValue {
    font-size: clamp(0.66rem, 2.7cqi, 0.88rem);
  }
}

@container (max-width: 320px) {
  .weightTile {
    aspect-ratio: auto !important;
    min-height: 8.8rem;
    grid-template-columns: 40% 60%;
  }

  .weightTileLeftCircle {
    height: 72%;
  }

  .weightTitleBlock {
    width: 100%;
    margin-left: 0;
    gap: 0.1rem;
  }

  .weightTitleLine,
  .weightTitleLineSub,
  .weightValueLabel {
    white-space: nowrap;
  }

  .weightTitleLine {
    font-size: clamp(0.6rem, 3.1cqi, 0.74rem);
  }

  .weightTitleLineSub {
    font-size: clamp(0.58rem, 3cqi, 0.72rem);
  }

  .weightValueLabel {
    font-size: clamp(0.54rem, 2.7cqi, 0.66rem);
  }

  .weightValueBadge {
    padding: 0.15rem 0.35rem 0.1rem;
    font-size: clamp(0.74rem, 3.7cqi, 0.9rem);
  }

  .weightSliderBlock {
    gap: 0.5rem;
  }

  .weightSliderGroup {
    gap: 0.28rem;
  }

  .weightSlider {
    height: 0.58rem;
  }

  .weightSlider::-webkit-slider-thumb {
    width: 1.18rem;
    height: 1.18rem;
  }

  .weightSlider::-moz-range-thumb {
    width: 1.18rem;
    height: 1.18rem;
  }

  .weightSliderMetaValue {
    font-size: clamp(0.5rem, 2.4cqi, 0.62rem);
  }
}

/* ===== LEGACY TILES — CONTAINER QUERIES (colonne étroite < 172px) ===== */
@container (max-width: 172px) {
  /* Prénoms : padding-right réservant la place pour la tête de bébé */
  .legacyNamesTitleCentered {
    padding-right: 1.6rem;
  }

  /* Prénoms : réduire la marge et le texte du helper pour éviter le clipping */
  .legacyNamesHelper {
    margin-top: 0.45rem;
    font-size: 0.78rem;
    line-height: 1.2;
  }
}

/* ===== LEGACY MOBILE TILES ===== */
.legacyMiniTile {
  min-height: clamp(13.2rem, 54vw, 15.8rem);
  justify-content: space-between;
  gap: 0;
  padding: 0.85rem 0.85rem 0.8rem;
  border-radius: 1.35rem;
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.12);
}

.legacyMiniHeader {
  position: relative;
  min-height: 2.15rem;
  text-align: center;
}

.legacyMiniHeader h3 {
  font-size: clamp(1rem, 4.8vw, 1.42rem);
  line-height: 0.95;
  color: var(--ink-0);
  text-align: center;
  width: 100%;
}

.legacyMiniDeco {
  position: absolute;
  top: -0.12rem;
  right: 0;
  width: 1.8rem;
  height: auto;
}

.legacyMiniPoints {
  font-size: 1rem;
  line-height: 1.05;
  font-weight: 900;
  text-align: center;
  color: var(--ink-0);
}

.legacyMiniFooter {
  display: grid;
  gap: 0.35rem;
  margin-top: 0.55rem;
}

.legacyMiniButton {
  width: 100%;
  min-height: 2.45rem;
  border-radius: 999px !important;
  font-size: 0.92rem;
}

.legacyMiniCornerBaby {
  position: absolute;
  bottom: 0.35rem;
  width: 3.6rem;
  height: auto;
  pointer-events: none;
}

.legacyMiniCornerBabyLeft {
  left: 0.3rem;
}

.legacyMiniCornerBabyRight {
  right: 0.3rem;
}

.legacySexTile {
  align-items: center;
}

.legacySexTile .legacyMiniHeader {
  width: 100%;
}

.legacySexTopBaby {
  position: absolute;
  top: -0.15rem;
  left: -0.1rem;
  width: 3rem;
  height: auto;
  pointer-events: none;
}

.sexChoiceRow {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
  width: 100%;
  margin: 0.65rem 0 0.8rem;
}

.sexChoiceButton {
  border: 0;
  background: none;
  padding: 0.15rem;
  display: inline-grid;
  place-items: center;
  position: relative;
  transition: transform 0.18s ease;
  justify-self: center;
}

.sexChoiceButton:disabled {
  opacity: 0.6;
}

.sexChoiceButtonActive {
  transform: translateY(-0.08rem) scale(1.03);
}


.sexChoiceIcon {
  width: min(100%, 4.7rem);
  height: auto;
  transition: filter 0.18s ease;
}

.sexChoiceButtonActiveGirl .sexChoiceIcon {
  filter: drop-shadow(0 0 16px rgba(232, 89, 110, 0.55));
}

.sexChoiceButtonActiveBoy .sexChoiceIcon {
  filter: drop-shadow(0 0 16px rgba(92, 197, 205, 0.55));
}

.sexAnswerRow {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  width: 100%;
  margin-top: 0.05rem;
}

.sexAnswerBadge {
  display: block;
  padding: 0.28rem 0.85rem 0.18rem;
  font-size: clamp(1.08rem, 5.3vw, 1.62rem);
  font-weight: 400;
  line-height: 0.9;
}

.legacyNamesTile {
  align-items: stretch;
}

.legacyNamesTopBaby {
  position: absolute;
  top: -0.15rem;
  right: -0.1rem;
  width: 3rem;
  height: auto;
}

.legacyNamesTitleCentered {
  width: 100%;
  text-align: center;
}

.namesLauncher {
  width: 100%;
  margin-top: 0.6rem;
  border: 2px solid #e6e5e0;
  background: #fffef9;
  border-radius: 999px;
  min-height: 2.55rem;
  padding: 0.6rem 0.9rem;
  text-align: left;
  font-size: 0.95rem;
  font-weight: 700;
  color: #c2bdb4;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.namesLauncherFilled {
  color: var(--ink-0);
}

.legacyNamesHelper {
  margin-top: 1rem;
  font-size: 0.9rem;
  line-height: 1.25;
  font-weight: 800;
  color: var(--ink-0);
  text-align: center;
}

.legacyNamesToy {
  position: absolute;
  right: 0.3rem;
  bottom: 3.6rem;
  width: 3rem;
  height: auto;
  pointer-events: none;
}

.legacyMeasureTile {
  gap: 0;
}

.measureEntryRow {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.6rem;
  margin: 1rem 0 0.8rem;
}

.measureEntryIcon {
  width: 5.5rem;
  height: auto;
  object-fit: contain;
}

.measureFieldStack {
  display: grid;
  gap: 0.55rem;
  min-width: 0;
}

.measureInputWrap {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  min-height: 2.55rem;
  padding: 0.2rem 0.3rem 0.2rem 0.8rem;
  border: 2px solid #e6e5e0;
  border-radius: 999px;
  background: #fffef9;
}

.measureInputWrap input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink-0);
  outline: none;
}

.measureInputWrap span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.35rem;
  height: 2rem;
  padding: 0 0.7rem;
  border-radius: 999px;
  background: #f4f1e8;
  font-size: 0.95rem;
  font-weight: 900;
  color: var(--ink-0);
}

.measureStepControls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  width: 100%;
  min-height: 2.95rem;
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid #eadfce;
  background: linear-gradient(180deg, #fffaf2 0%, #f7eddc 100%);
  box-shadow:
    0 8px 18px rgba(214, 192, 153, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.measureStepButton {
  min-height: 2.95rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink-0);
  font-family: var(--font-baloo), system-ui, sans-serif;
  font-size: 1.85rem;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition:
    background-color 0.18s ease,
    transform 0.12s ease,
    opacity 0.18s ease,
    color 0.18s ease;
}

.measureStepButton span {
  transform: translateY(-0.08rem);
}

.measureStepButton + .measureStepButton {
  border-left: 1px solid rgba(182, 159, 121, 0.5);
  background: linear-gradient(180deg, #fdeef1 0%, #f9dfe5 100%);
}

.measureStepButtonAccent {
  color: var(--accent-strong);
}

.measureStepButton:disabled {
  opacity: 0.48;
}

.measureStepButton:not(:disabled):hover {
  background: rgba(255, 255, 255, 0.24);
}

.measureStepButtonAccent:not(:disabled):hover {
  background: linear-gradient(180deg, #fce8ed 0%, #f6d4dc 100%);
}

.measureStepButton:not(:disabled):active {
  background: rgba(45, 45, 45, 0.06);
  transform: translateY(1px);
}

.predictionModalBackdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(2px);
}

.predictionModal {
  width: min(100%, 26rem);
  max-height: min(90vh, 42rem);
  overflow-y: auto;
  background: var(--panel);
  border-radius: 1.35rem;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.18);
  padding: 1rem;
  display: grid;
  gap: 0.9rem;
}

.predictionModalHeader {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.predictionModalHeader h3 {
  font-size: 1.18rem;
  line-height: 0.96;
  color: var(--ink-0);
}

.predictionModalHeader p {
  margin-top: 0.3rem;
  font-size: 0.84rem;
  color: var(--ink-1);
}

.predictionModalClose {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 1.35rem;
  line-height: 1;
  padding: 0.15rem;
}

.predictionModalGrid {
  display: grid;
  gap: 0.65rem;
}

.predictionModalField {
  display: grid;
  gap: 0.35rem;
}

.predictionModalField span {
  font-size: 0.86rem;
  font-weight: 800;
  color: var(--ink-0);
}

.predictionModalField input {
  width: 100%;
  min-height: 2.65rem;
  padding: 0.72rem 0.9rem;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-input);
  background: #fffefb;
  font-size: 0.96rem;
  color: var(--ink-0);
}

.predictionModalActions {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
}

@media (max-width: 520px) {
  .statPill {
    min-width: 0;
    padding: 0.42rem 0.85rem;
    font-size: 0.88rem;
  }

  .weightTile,
  .weightTile *,
  .legacyMiniTile,
  .legacyMiniTile *,
  .sexChoiceButton,
  .namesLauncher,
  .measureStepButton,
  .weightSlider {
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
  }

  .weightSlider {
    touch-action: pan-y;
  }

  .measureInputWrap input,
  .predictionModalField input {
    -webkit-user-select: text;
    user-select: text;
  }

  .legacyMiniTile {
    min-height: clamp(15rem, 64vw, 17.5rem);
    padding: 0.85rem 0.8rem 0.85rem;
  }

  .legacyMiniHeader h3 {
    font-size: clamp(0.94rem, 5vw, 1.25rem);
  }

  .legacyMiniPoints,
  .legacyNamesHelper {
    font-size: 0.9rem;
  }

  /* Bébés en coin — réduire pour ne pas chevaucher le contenu */
  .legacyMiniCornerBaby {
    width: 2rem;
    bottom: 0.2rem;
  }

  .legacyMiniCornerBabyLeft {
    left: 0.15rem;
  }

  .legacyMiniCornerBabyRight {
    right: 0.15rem;
  }

  /* Bébé en haut de la tile Prénom */
  .legacyNamesTopBaby {
    width: 3.5rem;
    top: -0.05rem;
    right: 0;
  }

  .legacySexTopBaby {
    width: 3.5rem;
    top: -0.05rem;
    left: 0;
  }

  /* Jouet bébé en bas de la tile Prénom */
  .legacyNamesToy {
    width: 2rem;
    bottom: 2.5rem;
    right: 0.15rem;
  }

  /* Icône sexe — taille raisonnable */
  .sexChoiceIcon {
    width: min(100%, 4.2rem);
  }

  /* Tile mesure : réduire l'icône réglette/règle */
  .measureEntryRow {
    gap: 0.4rem;
    margin: 0.7rem 0 0.6rem;
  }

  .measureFieldStack {
    gap: 0.45rem;
  }

  .measureStepControls {
    gap: 0.45rem;
  }

  .measureStepButton {
    min-height: 2.3rem;
    font-size: 1.2rem;
  }

  .measureEntryIcon {
    width: 2.8rem;
  }

  /* Badge "cm" / "g" — compact */
  .measureInputWrap {
    min-height: 2.7rem;
    padding: 0.15rem 0.2rem 0.15rem 0.6rem;
  }

  .measureInputWrap input {
    font-size: 0.9rem;
  }

  .measureInputWrap span {
    min-width: 1.4rem;
    height: 1.6rem;
    padding: 0 0.35rem;
    font-size: 0.78rem;
  }

  .measureEntryIcon {
    width: 3.2rem;
  }

  .namesLauncher {
    min-height: 2.7rem;
    padding: 0.65rem 0.8rem;
    font-size: 0.85rem;
  }

}

@media (max-width: 380px) {
  .measureEntryRow {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 0.4rem;
    margin: 0.5rem 0 0.5rem;
  }

  .measureEntryIcon {
    width: 2.7rem;
  }

  .measureInputWrap {
    width: 100%;
  }
}

/* ===== PANEL BLOCK ===== */
.panelBlock {
  padding: 0.9rem 1rem;
  display: grid;
  gap: 0.7rem;
  margin: 0 0.5rem;
  background: var(--panel-warm);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-card);
}

.panelBlock h2 {
  color: var(--ink-0);
}

/* ===== GLOBAL SAVE BAR ===== */
.globalSaveBar {
  padding: 0.85rem 1rem;
  margin: 0 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  align-items: center;
  text-align: center;
  background: var(--panel);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

.globalSaveBar .btn-primary {
  width: 100%;
  padding: 0.8rem;
  font-size: 0.95rem;
}

/* ===== SCOREBOARD / LISTS ===== */
.recapHero {
  margin: 0;
  min-height: 264px;
  padding: 1.5rem 1rem;
  border-radius: 0;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.85), transparent 28%),
    radial-gradient(circle at 100% 0, rgba(255, 255, 255, 0.58), transparent 34%),
    linear-gradient(150deg, #d7f1f1 0%, #dff5ef 46%, #fbe6de 100%);
  border: none;
  box-shadow: none;
}

.recapHeroClosed {
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.72), transparent 28%),
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.42), transparent 34%),
    linear-gradient(150deg, #f8e8dc 0%, #ffd8ca 46%, #ffcad4 100%);
}

.recapHeroFinalized {
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.74), transparent 28%),
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.45), transparent 34%),
    linear-gradient(150deg, #e2f5eb 0%, #d7f2ef 48%, #d8eff8 100%);
}

.recapHero::before {
  content: "";
  position: absolute;
  inset: auto -6% -18% -6%;
  height: 40%;
  border-radius: 50% 50% 0 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.35), transparent 28%),
    linear-gradient(180deg, rgba(146, 220, 204, 0.18), rgba(128, 205, 175, 0.56));
  z-index: 0;
}

.recapHero::after {
  content: "";
  position: absolute;
  right: -1.2rem;
  bottom: 2rem;
  width: 9.5rem;
  height: 9.5rem;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0) 54%),
    linear-gradient(180deg, rgba(255, 217, 196, 0.5), rgba(255, 214, 214, 0.2));
  opacity: 0.9;
  z-index: 0;
}

.recapHeroContent {
  display: grid;
  gap: 0.75rem;
  position: relative;
  z-index: 1;
  align-content: center;
  min-height: 100%;
  max-width: 28rem;
}

.recapHeroEyebrow,
.recapSectionEyebrow {
  display: inline-flex;
  width: fit-content;
  padding: 0.32rem 0.65rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--ink-1);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow: 0 8px 20px rgba(114, 180, 170, 0.12);
}

.recapHero h1 {
  font-size: clamp(1.7rem, 4vw, 2.35rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  max-width: 11ch;
}

.recapHero p {
  max-width: 52ch;
  color: var(--ink-1);
  font-size: 1rem;
  line-height: 1.5;
}

.recapHeroMeta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.recapHeroMeta span {
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.65);
  color: var(--ink-1);
  font-size: 0.83rem;
  font-weight: 700;
}

.recapHeroStats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.2rem;
}

.recapHeroStatChip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-card);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(6px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  min-width: 4.5rem;
}

.recapHeroStatChipSex {
  background: rgba(255, 255, 255, 0.9);
}

.recapHeroStatValue {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--ink-0);
  line-height: 1.1;
  font-family: var(--font-baloo);
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.recapHeroStatPercent {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--teal-strong);
  line-height: 1;
}

.recapHeroStatLabel {
  font-size: 0.64rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.15rem;
  white-space: nowrap;
}

.recapHeroEmpty {
  color: var(--ink-1);
  font-size: 0.92rem;
  opacity: 0.75;
}

.indicesHero {
  height: 264px;
  min-height: 264px;
  background:
    radial-gradient(circle at 16% 20%, rgba(255, 255, 255, 0.84), transparent 28%),
    radial-gradient(circle at 92% 18%, rgba(255, 255, 255, 0.48), transparent 26%),
    linear-gradient(150deg, #fce7ee 0%, #edf7f3 48%, #d9f0f3 100%);
}

.indicesHero::before {
  background:
    radial-gradient(circle at 28% 18%, rgba(255, 255, 255, 0.42), transparent 28%),
    linear-gradient(180deg, rgba(255, 190, 204, 0.22), rgba(116, 207, 211, 0.45));
}

.indicesHero::after {
  right: auto;
  left: -2rem;
  bottom: 1.45rem;
  width: 8.2rem;
  height: 8.2rem;
  background:
    radial-gradient(circle at 34% 30%, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0) 54%),
    linear-gradient(180deg, rgba(191, 237, 239, 0.7), rgba(255, 218, 225, 0.28));
}

.indicesHero h1 {
  max-width: 18rem;
  font-size: clamp(1.45rem, 3.5vw, 2rem);
}

.indicesHero p {
  max-width: 39ch;
  font-size: 0.94rem;
}

.indicesHero .recapHeroContent {
  gap: 0.55rem;
}

.indicesHero .recapHeroStats {
  gap: 0.45rem;
  margin-top: 0;
}

.indicesHero .recapHeroStatChip {
  background: rgba(255, 255, 255, 0.78);
  padding: 0.48rem 0.76rem;
  box-shadow: 0 8px 20px rgba(86, 158, 160, 0.1);
}

.indicesHero .recapHeroStatValue {
  font-size: 1rem;
}

.indicesHeroIllustration {
  position: absolute;
  right: clamp(0.5rem, 6vw, 4.5rem);
  bottom: 1.4rem;
  width: clamp(8rem, 26vw, 14rem);
  height: clamp(8rem, 26vw, 14rem);
  z-index: 1;
  pointer-events: none;
}

.indicesHeroCardBack,
.indicesHeroCardMiddle,
.indicesHeroCardFront,
.indicesHeroCardAccent,
.indicesHeroCardLineStrong,
.indicesHeroCardLineSoft,
.indicesHeroCardBadge {
  position: absolute;
  display: block;
}

.indicesHeroCardBack,
.indicesHeroCardMiddle,
.indicesHeroCardFront {
  border-radius: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 18px 34px rgba(88, 143, 149, 0.12);
}

.indicesHeroCardBack {
  inset: 18% 14% 18% 24%;
  transform: rotate(12deg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(240, 250, 249, 0.84)),
    linear-gradient(140deg, rgba(196, 239, 239, 0.55), rgba(253, 228, 233, 0.48));
  opacity: 0.9;
}

.indicesHeroCardMiddle {
  inset: 11% 18% 14% 16%;
  transform: rotate(5deg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(247, 252, 251, 0.92)),
    linear-gradient(140deg, rgba(236, 247, 243, 0.62), rgba(255, 237, 241, 0.45));
}

.indicesHeroCardFront {
  inset: 7% 20% 16% 12%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(252, 248, 244, 0.92));
}

.indicesHeroCardAccent {
  left: 12%;
  top: 18%;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.9rem;
  background: linear-gradient(145deg, rgba(232, 89, 110, 0.22), rgba(142, 218, 224, 0.34));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.indicesHeroCardLineStrong,
.indicesHeroCardLineSoft {
  left: 12%;
  height: 0.42rem;
  border-radius: 999px;
  background: rgba(98, 180, 186, 0.22);
}

.indicesHeroCardLineStrong {
  top: 48%;
  width: 56%;
}

.indicesHeroCardLineSoft {
  top: 62%;
  width: 40%;
  background: rgba(232, 89, 110, 0.16);
}

.indicesHeroCardBadge {
  right: 11%;
  bottom: 13%;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 50%;
  border: 0.38rem solid rgba(255, 255, 255, 0.86);
  background: linear-gradient(145deg, rgba(142, 218, 224, 0.9), rgba(232, 89, 110, 0.42));
  box-shadow: 0 10px 22px rgba(88, 143, 149, 0.16);
}

/* ── History hero ── */

.historyHero {
  height: 264px;
  min-height: 264px;
  background:
    radial-gradient(circle at 16% 20%, rgba(255, 255, 255, 0.84), transparent 28%),
    radial-gradient(circle at 90% 15%, rgba(255, 255, 255, 0.48), transparent 26%),
    linear-gradient(150deg, #ece0f8 0%, #f4eeff 48%, #fce5ef 100%);
}

.historyHero::before {
  background:
    radial-gradient(circle at 28% 18%, rgba(255, 255, 255, 0.42), transparent 28%),
    linear-gradient(180deg, rgba(195, 162, 230, 0.22), rgba(210, 170, 220, 0.42));
}

.historyHero::after {
  right: 0.5rem;
  bottom: 1.8rem;
  background:
    radial-gradient(circle at 34% 30%, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0) 54%),
    linear-gradient(180deg, rgba(220, 195, 245, 0.65), rgba(255, 210, 230, 0.3));
}

.historyHero h1 {
  max-width: 14ch;
}

.historyHero .recapHeroContent {
  gap: 0.55rem;
}

.historyHero .recapHeroStats {
  gap: 0.45rem;
  margin-top: 0;
}

.historyHero .recapHeroStatChip {
  background: rgba(255, 255, 255, 0.78);
  padding: 0.48rem 0.76rem;
  box-shadow: 0 8px 20px rgba(160, 120, 200, 0.1);
}

.historyHero .recapHeroStatValue {
  font-size: 1.1rem;
  line-height: 1.2;
}

/* Decorative: vertical timeline with dots */
.historyHeroIllustration {
  position: absolute;
  right: clamp(0.8rem, 7vw, 5rem);
  top: 50%;
  transform: translateY(-50%);
  width: clamp(5rem, 14vw, 8rem);
  height: clamp(8rem, 20vw, 11rem);
  z-index: 1;
  pointer-events: none;
}

.historyHeroLine,
.historyHeroDot1,
.historyHeroDot2,
.historyHeroDot3 {
  position: absolute;
  display: block;
}

.historyHeroLine {
  left: 50%;
  top: 0;
  bottom: 0;
  width: 0.35rem;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(180, 145, 225, 0.48), rgba(225, 175, 210, 0.36));
  transform: translateX(-50%);
}

.historyHeroDot1,
.historyHeroDot2,
.historyHeroDot3 {
  left: 50%;
  transform: translateX(-50%);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  border: 0.28rem solid rgba(185, 148, 228, 0.52);
  box-shadow: 0 4px 12px rgba(160, 120, 200, 0.18);
}

.historyHeroDot1 {
  top: 8%;
  width: 1.15rem;
  height: 1.15rem;
}

.historyHeroDot2 {
  top: 44%;
  width: 1.65rem;
  height: 1.65rem;
  border-color: rgba(200, 152, 232, 0.68);
  box-shadow: 0 6px 16px rgba(160, 120, 200, 0.24);
}

.historyHeroDot3 {
  top: 80%;
  width: 1rem;
  height: 1rem;
}

@media (max-width: 520px) {
  .historyHero {
    padding: 1.15rem 0.9rem;
  }

  .historyHero .recapHeroContent {
    max-width: 100%;
  }

  .historyHero h1 {
    font-size: 1.42rem;
  }

  .historyHero p {
    max-width: 31ch;
    font-size: 0.86rem;
    line-height: 1.35;
  }

  .historyHeroIllustration {
    opacity: 0.4;
    right: -1.5rem;
  }
}

@media (max-width: 520px) {
  .indicesHero {
    padding: 1.15rem 0.9rem;
  }

  .indicesHero .recapHeroContent {
    max-width: 100%;
  }

  .indicesHero h1 {
    max-width: 15rem;
    font-size: 1.42rem;
  }

  .indicesHero p {
    max-width: 31ch;
    font-size: 0.86rem;
    line-height: 1.35;
  }

  .indicesHeroIllustration {
    opacity: 0.45;
    right: -2.2rem;
    bottom: 0.8rem;
  }

  .indicesHeroCardBack,
  .indicesHeroCardMiddle,
  .indicesHeroCardFront {
    border-radius: 1.2rem;
  }

  .indicesHeroCardAccent {
    width: 1.8rem;
    height: 1.8rem;
  }

  .indicesHeroCardBadge {
    width: 2.2rem;
    height: 2.2rem;
    border-width: 0.3rem;
  }

  .indicesHero .recapHeroStatChip {
    padding: 0.42rem 0.58rem;
    min-width: 3.9rem;
  }

  .indicesHero .recapHeroStatValue {
    font-size: 0.88rem;
  }
}

.recapSectionHeading {
  display: grid;
  gap: 0.35rem;
}

.recapSectionHeading p {
  color: var(--muted);
  line-height: 1.45;
}

.recapDivider {
  border: none;
  border-top: 2px dashed var(--border);
  margin: 0.25rem 0.5rem;
  opacity: 0.7;
}

.recapKpiGrid {
  display: grid;
  gap: 0.7rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0 0.5rem;
}

.recapKpiCard {
  display: grid;
  gap: 0.2rem;
  padding: 0.9rem 1rem;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow-card);
  min-height: 126px;
}

.recapKpiLabel {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.recapKpiCard strong {
  color: var(--accent-strong);
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.15;
  margin-top: auto;
}

.recapKpiCard p {
  color: var(--ink-1);
  font-size: 0.82rem;
  line-height: 1.4;
  margin-top: 0.25rem;
}

.recapTrendGrid {
  display: grid;
  gap: 0.7rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.recapTrendCard {
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: var(--panel-warm);
}

.recapTrendHead {
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
  align-items: flex-start;
}

.recapTrendHead h3 {
  font-size: 1rem;
}

.recapTrendHead p {
  margin-top: 0.2rem;
  color: var(--ink-1);
  font-weight: 700;
  line-height: 1.35;
}

.recapTrendBadge {
  flex-shrink: 0;
  padding: 0.36rem 0.6rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--ink-1);
  font-size: 0.78rem;
  font-weight: 800;
}

.recapTrendDetails {
  display: grid;
  gap: 0.25rem;
}

.recapTrendDetails p {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
}

.recapAccordionList {
  display: grid;
  gap: 0.7rem;
  margin: 0 0.5rem;
}

.recapAccordionCard {
  border: 1px solid var(--border);
  border-radius: 24px;
  background: var(--panel);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.recapAccordionCardOpen {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-soft), 0 12px 30px rgba(0,0,0,0.08);
}

.recapAccordionSummary {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.95rem 1rem;
  cursor: pointer;
}

.recapAccordionSummary strong {
  font-size: 1rem;
  font-weight: 800;
  color: var(--ink-0);
}

.recapAccordionSummary:hover {
  background: rgba(0, 0, 0, 0.02);
}

.recapAccordionToggle {
  color: var(--accent);
  font-weight: 800;
  font-size: 0.82rem;
}

.recapAccordionMeta {
  display: grid;
  gap: 0.15rem;
  text-align: right;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.recapAccordionBody {
  display: grid;
  gap: 0.8rem;
  padding: 0 1rem 1rem;
}

.summaryGrid {
  display: grid;
  gap: 0.7rem;
  grid-template-columns: 1fr;
}

.summaryCard {
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  background: var(--panel-warm);
  padding: 0.75rem;
  display: grid;
  gap: 0.35rem;
}

.summaryCard h3 {
  font-size: 1rem;
  color: var(--ink-0);
}

.summaryCard p {
  color: var(--muted);
  font-size: 0.9rem;
}

.activityList {
  display: grid;
  gap: 0.5rem;
}

.activityItem {
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  background: var(--panel-warm);
  padding: 0.7rem 0.75rem;
  display: grid;
  gap: 0.28rem;
}

.activityMeta {
  font-size: 0.8rem;
  color: var(--muted);
}

.boardCard {
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  background: var(--panel-warm);
  padding: 0.8rem;
  display: grid;
  gap: 0.45rem;
}

.boardEntries {
  display: grid;
  gap: 0.45rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.boardEntry {
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 0.65rem 0.75rem;
  background: var(--bg-0);
  box-shadow: var(--shadow-card);
  text-align: left;
  display: grid;
  gap: 0.5rem;
  width: 100%;
  cursor: pointer;
}

.boardEntry strong {
  color: var(--ink-0);
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.boardEntryValues {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink-0);
  line-height: 1.35;
}

.boardEntryHeader {
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
  align-items: center;
}

.boardEntryHeader span {
  color: var(--ink-1);
  font-size: 0.8rem;
  font-weight: 700;
}

.boardEntryActive {
  border-style: solid;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-soft);
}

.recapAvatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #ffe7cc;
  color: var(--ink-0);
  display: grid;
  place-items: center;
  overflow: hidden;
  font-size: 0.85rem;
  font-weight: 800;
  flex-shrink: 0;
}

.recapAvatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.recapAvatarSm {
  width: 28px;
  height: 28px;
  font-size: 0.72rem;
}

.recapAvatarLg {
  width: 58px;
  height: 58px;
  font-size: 1rem;
}

.recapIdentityRow {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}

.recapIdentityRow strong {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.recapScoreboardLayout {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
}

.recapScoreboardList {
  display: grid;
  gap: 0.45rem;
  align-content: start;
  grid-auto-rows: 98px;
}

.recapScoreCard {
  width: 100%;
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.65rem 0.8rem;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #fffdf9 0%, #fff4e6 100%);
  cursor: pointer;
  text-align: left;
  min-height: 98px;
  height: 100%;
  align-self: start;
}

.recapScoreCardCompact {
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.7rem;
  align-items: center;
}

.recapScoreCardPodium {
  background: linear-gradient(180deg, #fff7d9 0%, #fff0d8 100%);
}

.recapScoreCard:not(:has(.recapScoreRank)) {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.recapScoreCardActive {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-soft);
}

.recapScoreRank {
  width: 2.3rem;
  height: 2.3rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1px solid var(--border);
  font-weight: 800;
  color: var(--ink-1);
}

.recapScoreIdentity {
  display: grid;
  min-width: 0;
}

.recapScoreIdentity strong {
  font-size: 0.98rem;
}

.recapScoreIdentity span {
  color: var(--muted);
  font-size: 0.82rem;
}

.recapScorePoints {
  display: grid;
  justify-items: end;
}

.recapScorePoints strong {
  font-size: 1.2rem;
}

.recapScorePoints span {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.recapParticipantPanel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.8rem;
  padding: 1rem;
  border-radius: 24px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 100%);
  align-self: start;
  overflow: hidden;
  min-width: 0;
  position: relative;
}

/* ---- Navigation participant (flèches + nom cliquable) ---- */
.recapParticipantNav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  position: relative;
  user-select: none;
  margin: 0 0.5rem;
}

.recapNavArrow {
  flex-shrink: 0;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: var(--panel);
  color: var(--ink-0);
  font-size: 1.5rem;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  box-shadow: 0 2px 6px rgba(0,0,0,0.07);
}

.recapNavArrow:disabled {
  opacity: 0.25;
  cursor: default;
}

.recapNavArrow:not(:disabled):hover {
  background: var(--bg-1);
}

.recapNavCenter {
  flex: 1;
  min-width: 0;
}

.recapNavNameBtn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.75rem;
  border-radius: 14px;
  border: 1.5px solid var(--border);
  background: var(--panel);
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.recapNavNameBtn:hover {
  background: var(--border-light);
}

.recapNavNameInfo {
  flex: 1;
  min-width: 0;
  display: grid;
}

.recapNavNameInfo strong {
  font-size: clamp(0.78rem, 3.8vw, 0.95rem);
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recapNavNameInfo span {
  font-size: 0.78rem;
  color: var(--muted);
}

.recapNavChevron {
  flex-shrink: 0;
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---- Dropdown participants ---- */
.recapDropdownOverlay {
  position: fixed;
  inset: 0;
  z-index: 10;
  border: 0;
  padding: 0;
  background: transparent;
}

.recapParticipantDropdown {
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  right: 0;
  width: 100%;
  z-index: 20;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-card);
  overflow-x: hidden;
  overflow-y: auto;
  max-height: 60vh;
  display: grid;
}

.recapDropdownItem {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.8rem;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-size: 0.93rem;
  color: var(--ink-0);
  transition: background 0.12s;
}

.recapDropdownItem:hover {
  background: var(--bg-1);
}

.recapDropdownItem span:first-of-type {
  flex: 1;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
  font-weight: 600;
}

.recapDropdownItemActive {
  background: var(--accent-soft);
}

.recapDropdownItemActive:hover {
  background: var(--accent-soft);
}

.recapDropdownPoints {
  flex-shrink: 0;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted);
}

.recapParticipantHeader {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: flex-start;
}

.recapParticipantHeader h3 {
  font-size: 1.05rem;
}

.recapParticipantHeader p {
  color: var(--muted);
  margin-top: 0.15rem;
}

.recapParticipantTag {
  padding: 0.38rem 0.62rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

.recapParticipantPredictions {
  display: grid;
  gap: 0.6rem;
}

.recapParticipantCard {
  display: grid;
  gap: 0.45rem;
  padding: 0.75rem 0.9rem;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card);
  margin: 0 0.5rem;
}

/* Meta row: title label + points badge */
.recapParticipantCardMeta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.recapParticipantCardLabel {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recapParticipantCardPoints {
  flex-shrink: 0;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: var(--star-yellow);
  color: #7a5800;
  font-size: 0.75rem;
  font-weight: 800;
}

.recapParticipantCardPointsMuted {
  flex-shrink: 0;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
}

/* Generic value */
.recapParticipantCardValue {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink-0);
  line-height: 1.35;
  white-space: nowrap;
  font-size: clamp(0.88rem, 3.3vw, 1.05rem);
}

.recapParticipantCardEmpty {
  font-size: 0.88rem;
  color: var(--muted);
  font-style: italic;
}

/* ---- SEX CARD ---- */
.recapParticipantCardSex {
  padding: 0.65rem 0.9rem;
}

.recapSexAnswer {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: 14px;
  background: var(--accent-soft);
}

.recapSexAnswerGarcon {
  background: #e4f6f8;
}

.recapSexAnswerFille {
  background: var(--accent-soft);
}

.recapSexIcon {
  flex-shrink: 0;
  object-fit: contain;
}

.recapSexLabel {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--accent-strong);
  line-height: 1.2;
}

.recapSexAnswerGarcon .recapSexLabel {
  color: var(--teal-strong);
}

/* ---- WEIGHT CARD ---- */
.recapWeightAnswer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.recapWeightBadge {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

/* ---- NAMES CARD ---- */
.recapParticipantNamesList {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.recapParticipantNameChip {
  padding: 0.22rem 0.65rem;
  border-radius: 999px;
  background: var(--panel);
  border: 1px solid var(--border);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink-0);
}

.recapParticipantNameLine {
  min-height: 1.45em;
  color: var(--muted);
  line-height: 1.45;
}

.recapParticipantNameLineEmpty {
  opacity: 0;
}

/* ===== RECAP — VIEWER PANEL (mise en avant du participant consulté) ===== */
.recapParticipantFocusPanel {
  display: grid;
  gap: 0.6rem;
  margin: 0 0.5rem;
  padding: 0.65rem;
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 250, 242, 0.92)),
    var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow: 0 12px 30px rgba(80, 55, 45, 0.12);
}

.recapViewerWrapper {
  position: relative;
}

.recapViewerPanel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 0.55rem;
  padding: 0;
  border-radius: 20px;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.recapViewerArrow {
  width: 2.35rem;
  border-radius: 16px;
  border: 1.5px solid var(--border);
  background: var(--panel);
  color: var(--accent-strong);
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition: background 0.15s, transform 0.15s, border-color 0.15s, color 0.15s;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.07);
}

.recapViewerArrow:not(:disabled):hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

.recapViewerArrow:disabled {
  opacity: 0.3;
  cursor: default;
}

.recapViewerMain {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
  align-items: center;
}

.recapViewerIdentityDropdownAnchor {
  position: relative;
  min-width: 0;
}

.recapViewerIdentityButton,
.recapViewerIdentityStatic {
  width: 100%;
  min-width: 0;
  border-radius: 18px;
  border: 1.5px solid rgba(232, 89, 110, 0.14);
  background: linear-gradient(135deg, rgba(252, 228, 232, 0.38), rgba(255, 255, 255, 0.98));
  box-shadow: 0 10px 22px rgba(80, 55, 45, 0.08);
}

.recapViewerIdentityButton {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.8rem;
  color: var(--ink-0);
  cursor: pointer;
  text-align: left;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s, background 0.15s;
}

.recapViewerIdentityButton:hover {
  transform: translateY(-1px);
  border-color: rgba(232, 89, 110, 0.28);
  box-shadow: 0 14px 28px rgba(80, 55, 45, 0.12);
}

.recapViewerIdentityButton:focus-visible {
  outline: 2px solid rgba(232, 89, 110, 0.3);
  outline-offset: 2px;
}

.recapViewerIdentityButtonOpen {
  border-color: rgba(232, 89, 110, 0.4);
  box-shadow: 0 14px 28px rgba(80, 55, 45, 0.12);
}

.recapViewerIdentityStatic {
  padding: 0.65rem 0.8rem;
}

.recapViewerIdentity {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.recapViewerIdentityHint {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.2rem;
  padding: 0.38rem 0.48rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(232, 89, 110, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
  flex-shrink: 0;
}

.recapViewerText {
  display: grid;
  gap: 0.1rem;
  min-width: 0;
}

.recapViewerKicker {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-strong);
}

.recapViewerName {
  font-size: clamp(1.15rem, 4.6vw, 1.55rem);
  font-weight: 900;
  font-family: var(--font-baloo), var(--font-space-grotesk), sans-serif;
  color: var(--ink-0);
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recapViewerMeta {
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 600;
}

.recapViewerAvatar {
  width: 64px;
  height: 64px;
  font-size: 1.2rem;
  flex-shrink: 0;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.recapViewerListChevron {
  font-size: 0.76rem;
  color: var(--accent-strong);
}

/* Strip horizontal de participants (scroll-snap mobile) */
.recapParticipantStrip {
  display: flex;
  gap: 0.45rem;
  list-style: none;
  margin: 0 0.5rem;
  padding: 0.3rem 0.1rem 0.55rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.recapParticipantStrip::-webkit-scrollbar {
  height: 6px;
}

.recapParticipantStrip::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 999px;
}

.recapParticipantStrip > li {
  scroll-snap-align: start;
}

.recapParticipantChip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.65rem 0.3rem 0.35rem;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: var(--panel);
  color: var(--ink-0);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.recapParticipantChip:hover {
  background: var(--bg-1);
  border-color: var(--accent-soft);
  transform: translateY(-1px);
}

.recapParticipantChip small {
  display: inline-grid;
  place-items: center;
  width: 1.2rem;
  height: 1.2rem;
  border-radius: 999px;
  background: var(--bg-1);
  color: var(--muted);
  font-size: 0.65rem;
  font-weight: 800;
}

.recapParticipantChipActive {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 6px 16px rgba(232, 89, 110, 0.35);
}

.recapParticipantChipActive:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: #fff;
}

.recapParticipantChipActive small {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

/* Grille de réponses compacte, assemblée au participant consulté */
.recapAnswersGrid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.45rem;
}

.recapAnswersGrid > .recapParticipantCard {
  margin: 0;
  padding: 0.52rem 0.58rem;
  gap: 0.28rem;
  border-radius: 14px;
  min-width: 0;
  box-shadow: 0 5px 16px rgba(80, 55, 45, 0.08);
}

.recapAnswersGrid .recapParticipantCardLabel {
  font-size: 0.62rem;
  white-space: normal;
  line-height: 1.15;
}

.recapAnswersGrid .recapParticipantCardValue {
  font-size: clamp(0.8rem, 3.4vw, 0.9rem);
  white-space: nowrap;
}

.recapAnswersGrid .recapSexAnswer {
  padding: 0.32rem 0.48rem;
  gap: 0.38rem;
  min-height: 2.55rem;
}

.recapAnswersGrid .recapSexLabel {
  font-size: 0.95rem;
}

.recapAnswersGrid .recapSexIcon {
  width: 34px;
  height: 34px;
}

.recapAnswersGrid .recapWeightBadge {
  font-size: clamp(0.75rem, 3.2vw, 0.82rem);
  padding: 0.18rem 0.42rem;
  white-space: nowrap;
}

.recapAnswersGrid .recapParticipantNameChip {
  font-size: 0.76rem;
  padding: 0.14rem 0.46rem;
}

.recapAnswersGrid .recapParticipantCardMetric {
  grid-column: span 2;
  order: 1;
}

.recapAnswersGrid .recapParticipantCardSexCompact,
.recapAnswersGrid .recapParticipantCardNamesCompact {
  grid-column: span 3;
  order: 2;
}

/* ===== FINALIZED PRONOSTICS ===== */
.finalResults {
  display: grid;
  gap: 0.8rem;
  padding: 0 0.5rem 0.5rem;
}

.finalWinnerCard {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.85rem;
  align-items: center;
  min-height: 168px;
  padding: 1.05rem;
  border-radius: 28px;
  background:
    radial-gradient(circle at 92% 8%, rgba(255, 255, 255, 0.8), transparent 27%),
    radial-gradient(circle at 6% 100%, rgba(142, 218, 224, 0.3), transparent 32%),
    linear-gradient(135deg, #fffdf8 0%, #fff1dc 48%, #ffe0e7 100%);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow: 0 14px 34px rgba(80, 55, 45, 0.13);
}

.finalWinnerCard::after {
  content: "";
  position: absolute;
  right: -1.9rem;
  bottom: -2.2rem;
  width: 9rem;
  height: 9rem;
  border-radius: 50%;
  background: linear-gradient(145deg, rgba(255, 217, 102, 0.66), rgba(232, 89, 110, 0.16));
  z-index: 0;
}

.finalWinnerMain,
.finalWinnerScoreBadge {
  position: relative;
  z-index: 1;
}

.finalWinnerMain {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
}

.finalWinnerIdentityRow {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
}

.finalWinnerAvatar,
.finalScoreAvatar {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: 50%;
  background: #ffe7cc;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  color: var(--ink-0);
  font-weight: 900;
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.88);
}

.finalWinnerAvatar {
  width: 72px;
  height: 72px;
  font-size: 1.2rem;
}

.finalWinnerAvatar img,
.finalScoreAvatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.finalWinnerKicker {
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.finalWinnerCard h3 {
  font-family: var(--font-baloo), var(--font-space-grotesk), sans-serif;
  color: var(--ink-0);
  font-size: clamp(1.75rem, 5vw, 2.55rem);
  font-weight: 800;
  line-height: 1;
  overflow-wrap: anywhere;
}

.finalWinnerSubtitle {
  margin-top: 0.2rem;
  color: var(--ink-1);
  font-size: 0.95rem;
  font-weight: 700;
}

.finalWinnerScoreBadge {
  display: grid;
  place-items: center;
  align-self: stretch;
  min-width: 6.6rem;
  padding: 0.85rem;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.88);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 8px 18px rgba(160, 120, 70, 0.1);
}

.finalWinnerScoreBadge strong {
  font-size: clamp(2rem, 7vw, 3rem);
  line-height: 0.95;
  color: var(--accent-strong);
}

.finalWinnerScoreBadge span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.finalScoreboardList {
  display: grid;
  gap: 0.45rem;
}

.finalScoreRow {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.65rem;
  min-height: 64px;
  padding: 0.62rem 0.75rem;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 6px 18px rgba(80, 55, 45, 0.07);
}

.finalScoreRowWinner {
  border-color: rgba(255, 217, 102, 0.95);
  background: linear-gradient(135deg, #fff8db, #fff2e4 58%, #fff7ef);
}

.finalRank {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  background: var(--panel-warm);
  border: 1px solid var(--border);
  color: var(--ink-1);
  font-size: 0.82rem;
  font-weight: 900;
}

.finalScoreAvatar {
  width: 38px;
  height: 38px;
  font-size: 0.78rem;
}

.finalScoreRow strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink-0);
}

.finalScorePoints {
  justify-self: end;
  padding: 0.32rem 0.62rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 0.82rem;
  font-weight: 900;
  white-space: nowrap;
}

.finalAnswersSection {
  display: grid;
  gap: 0.65rem;
  margin-top: 0.2rem;
}

.finalAnswerGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.finalAnswerCard {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.7rem;
  align-items: start;
  padding: 0.8rem;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 250, 242, 0.92));
  box-shadow: 0 7px 22px rgba(80, 55, 45, 0.08);
  min-width: 0;
}

.finalAnswerIconWrap {
  display: grid;
  place-items: center;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(252, 228, 232, 0.82), rgba(224, 247, 248, 0.72));
}

.finalAnswerIcon {
  width: 2.4rem;
  height: 2.4rem;
  object-fit: contain;
}

.finalAnswerText {
  display: grid;
  gap: 0.48rem;
  min-width: 0;
}

.finalAnswerText h3 {
  color: var(--ink-0);
  font-size: 1rem;
  line-height: 1.15;
}

.finalAnswerText dl {
  display: grid;
  gap: 0.42rem;
}

.finalAnswerText dl div {
  display: grid;
  gap: 0.12rem;
}

.finalAnswerText dt {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.finalAnswerText dd {
  color: var(--ink-0);
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

@media (max-width: 480px) {
  .recapParticipantFocusPanel {
    padding: 0.5rem;
    border-radius: 20px;
  }

  .recapViewerPanel {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.4rem;
  }

  .recapViewerArrow {
    width: 2.15rem;
    font-size: 1.35rem;
  }

  .recapViewerAvatar {
    width: 48px;
    height: 48px;
  }

  .recapViewerMain {
    grid-template-columns: minmax(0, 1fr);
  }

  .recapViewerIdentityButton,
  .recapViewerIdentityStatic {
    padding: 0.55rem 0.65rem;
    border-radius: 16px;
  }

  .recapViewerIdentityButton {
    gap: 0.55rem;
  }

  .recapViewerIdentityHint {
    min-width: 2rem;
    padding: 0.28rem 0.42rem;
  }

  .recapParticipantCardValue,
  .recapWeightBadge,
  .recapHeroStatValue {
    font-size: clamp(0.75rem, 3.9vw, 0.95rem);
  }

  .recapAnswersGrid .recapParticipantCardValue,
  .recapAnswersGrid .recapWeightBadge {
    font-size: clamp(0.72rem, 3.6vw, 0.86rem);
  }
}

@media (max-width: 650px) {
  .finalWinnerCard,
  .finalAnswerGrid {
    grid-template-columns: 1fr;
  }

  .finalWinnerScoreBadge {
    grid-template-columns: auto auto;
    justify-content: center;
    align-self: auto;
    min-width: 0;
    gap: 0.45rem;
  }
}

@media (max-width: 420px) {
  .finalWinnerCard {
    padding: 0.9rem;
    border-radius: 24px;
  }

  .finalWinnerIdentityRow {
    align-items: flex-start;
  }

  .finalWinnerAvatar {
    width: 58px;
    height: 58px;
  }

  .finalScoreRow {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .finalScoreAvatar {
    display: none;
  }
}

.scoreTable {
  width: 100%;
  border-collapse: collapse;
}

.scoreTable th,
.scoreTable td {
  border-bottom: 1px solid var(--border);
  text-align: left;
  padding: 0.55rem;
}

.scoreTable th {
  color: var(--ink-0);
  font-weight: 700;
}

.empty {
  padding: 0.8rem;
  border: 1px dashed var(--border);
  border-radius: var(--radius-input);
  color: var(--muted);
  background: var(--panel-warm);
  text-align: center;
}

/* ===== RESPONSIVE ===== */

@media (max-width: 580px) {
  .recapScoreboardLayout {
    grid-template-columns: 1fr;
  }

  .recapParticipantPanel {
    position: static;
  }

  .recapScoreboardList {
    grid-auto-rows: auto;
  }
}

@media (max-width: 650px) {
  .tilesGrid {
    grid-template-columns: 1fr;
    gap: 0.6rem;
    padding: 0 0.4rem;
  }

  .tileShellWeight {
    grid-column: auto;
  }
}

@media (max-width: 480px) {
  .recapAccordionSummary,
  .boardEntryHeader,
  .recapParticipantHeader,
  .recapParticipantCardMeta {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
  }

  .recapAccordionMeta,
  .recapScorePoints,
  .boardEntryHeader span {
    justify-items: start;
    text-align: left;
  }

  .boardEntries {
    grid-template-columns: 1fr;
  }

  .boardEntry,
  .recapAccordionBody,
  .recapSexAnswer,
  .recapParticipantCardValue,
  .recapParticipantNameChip {
    min-width: 0;
  }

  .recapSexAnswer {
    flex-wrap: wrap;
  }

  .recapSexLabel,
  .boardEntryValues,
  .recapParticipantCardLabel,
  .recapParticipantCardValue {
    overflow-wrap: anywhere;
    word-break: break-word;
  }
}

/* @media (max-width: 520px) {
  .tilesGrid {
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
    padding: 0 0.4rem;
  }

  .tileShellWeight {
    grid-column: 1 / -1;
  }

  .topbar {
    grid-template-columns: 1fr;
  }

  .topbarNav {
    justify-content: flex-start;
  }

  .globalSaveBar {
    flex-direction: column;
    align-items: center;
  }

  .recapKpiGrid,
  .recapTrendGrid,
  .boardEntries,
  .recapScoreboardLayout {
    grid-template-columns: 1fr;
  }

  .recapScoreboardList {
    grid-auto-rows: auto;
  }

  .recapAccordionSummary,
  .recapParticipantHeader,
  .boardEntryHeader {
    grid-template-columns: 1fr;
    display: grid;
  }

  .recapAccordionMeta,
  .recapScorePoints {
    justify-items: start;
    text-align: left;
  }

  .recapScoreCard {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .recapScoreCardCompact {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .recapScoreRank {
    grid-row: span 2;
  }

  .recapParticipantPanel {
    position: static;
  }
} */
/* 
@media (max-width: 380px) {
  .hero {
    aspect-ratio: 115 / 92;
  }

  .heroBannerRow {
    gap: 0.6rem;
  }

  .heroProjectPhoto {
    top: 31%;
    width: clamp(6.25rem, 28vw, 6.9rem);
    height: clamp(6.25rem, 28vw, 6.9rem);
  }

  .heroCornerDecoFrameLeft {
    width: clamp(5rem, 24vw, 5.8rem);
    height: clamp(6.5rem, 31vw, 7.5rem);
  }

  .heroCornerDecoFrameRight {
    width: clamp(5.5rem, 26vw, 6.5rem);
    height: clamp(6.6rem, 32vw, 7.8rem);
  }

  .tilesGrid {
    grid-template-columns: 1fr;
  }

  .recapHero,
  .panelBlock {
    margin: 0 0.35rem;
  }

  .recapScoreCard {
    grid-template-columns: 1fr;
  }
}

