:root {
    color-scheme: light only;
    forced-color-adjust: none;
    --ink: #0a0a0a;
    --paper: #fff8e8;
    --pink: #f7c8d8;
    --pink-d: #ff8fb0;
    --yellow: #ffd84a;
    --lime: #c8e85b;
    --mint: #a3eed7;
    --lavender: #c9b6f5;
    --gray: #8a8a8a;
  }
  /* Force le navigateur (Samsung Internet, Chrome) à NE PAS inverser les couleurs
     même si "mode sombre forcé" est activé côté téléphone. */
  *, *::before, *::after { forced-color-adjust: none; }
  html { color-scheme: light only; }
  html.dark { color-scheme: dark; }
  html.standalone-app .site-only { display: none !important; }

  /* ─── BOUTON TOGGLE THÈME ─── */
  .theme-toggle {
    position: fixed;
    top: 12px;
    right: 12px;
    z-index: 100;
    width: 40px; height: 40px;
    border: 3px solid var(--ink);
    background: #fff;
    box-shadow: 3px 3px 0 var(--ink);
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    padding: 0;
    font-size: 18px;
    line-height: 1;
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .sound-toggle {
    position: fixed;
    top: 62px;
    right: 12px;
    z-index: 100;
    width: 40px;
    height: 40px;
    border: 3px solid var(--ink);
    background: #fff;
    box-shadow: 3px 3px 0 var(--ink);
    color: #0a0a0a;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-size: 17px;
    line-height: 1;
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .sound-toggle:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--ink); }
  .sound-toggle:active { transform: translate(3px, 3px); box-shadow: 0 0 0 var(--ink); }
  .theme-toggle:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--ink); }
  .theme-toggle:active { transform: translate(3px, 3px); box-shadow: 0 0 0 var(--ink); }
  @media (max-width: 768px) {
    .theme-toggle { top: 8px; right: 8px; width: 34px; height: 34px; font-size: 15px; }
    .sound-toggle { top: 50px; right: 8px; width: 34px; height: 34px; font-size: 14px; }
  }

  /* ─── MODE SOMBRE (toggle manuel via html.dark) ─── */
  html.dark, html.dark body {
    background: #0a0a0a !important;
    background-color: #0a0a0a !important;
    background-image: radial-gradient(rgba(255,255,255,0.06) 0.6px, transparent 0.7px) !important;
    color: #f0e8d8 !important;
  }
  html.dark { --ink: #f0e8d8; --paper: #1c1c1c; --lavender: #000; }
  html.dark .frame,
  html.dark .frame-thick,
  html.dark .nav,
  html.dark .mobile-tabs,
  html.dark .deck-body,
  html.dark .session-card,
  html.dark .fig {
    background: #1c1c1c !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
  }
  html.dark .frame { box-shadow: 6px 6px 0 #000 !important; }
  html.dark .frame-thick { box-shadow: 8px 8px 0 #000 !important; }
  html.dark .nav { border-bottom-color: #f0e8d8 !important; }
  html.dark .section-banner h2 {
    background: #1c1c1c !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 4px 4px 0 #000 !important;
  }
  html.dark .section-banner .bar { background: #f0e8d8 !important; }
  html.dark .pack-section-done .section-banner h2 {
    background: #16351e !important;
    color: #f0e8d8 !important;
  }
  html.dark .btn {
    background: #2a2025 !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 4px 4px 0 #000 !important;
  }
  html.dark .btn-y { background: var(--yellow) !important; color: #0a0a0a !important; }
  html.dark .btn-m { background: var(--mint) !important; color: #0a0a0a !important; }
  html.dark .btn-l { background: #0a0a0a !important; color: #f0e8d8 !important; }
  html.dark .btn-y, html.dark .btn-m { border-color: #0a0a0a !important; }
  html.dark .btn-l {
    background: #0a0a0a !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
  }
  html.dark .btn::before { border-left-color: currentColor; }
  html.dark .logo { color: #f0e8d8 !important; }
  html.dark .nav-links a { color: #f0e8d8 !important; }
  html.dark .nav-links a:hover,
  html.dark .nav-links a.active { border-bottom-color: #f0e8d8 !important; }
  html.dark .theme-toggle {
    background: #2a2025;
    border-color: #f0e8d8;
    box-shadow: 3px 3px 0 #000;
    color: #f0e8d8;
  }
  html.dark .sound-toggle {
    background: #2a2025;
    border-color: #f0e8d8;
    box-shadow: 3px 3px 0 #000;
    color: #f0e8d8;
  }
  /* Boutons jaunes en dark : forcer le texte noir (le var(--ink) cream est illisible) */
  html.dark .pwa-install-btn {
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
    box-shadow: 4px 4px 0 #0a0a0a !important;
  }
  /* Stripes de cartes : ré-attribuer les variantes pour rester visibles en dark */
  html.dark .deck.v .deck-img { background: var(--pink-d) !important; color: #0a0a0a !important; }
  html.dark .deck.w .deck-img { background: #f0e8d8 !important; color: #0a0a0a !important; }
  html.dark .deck.k .deck-img { background: #2a2a2a !important; color: #f0e8d8 !important; }
  html.dark .deck.k,
  html.dark .deck.k .deck-body { background: #1c1c1c !important; color: #f0e8d8 !important; }
  html.dark .deck-img .fig { background: #fff !important; color: #0a0a0a !important; border-color: #0a0a0a !important; }
  html.dark .deck-status,
  html.dark .deck-status-nouveau,
  html.dark .deck-status-en-cours,
  html.dark .deck-status-a-consolider,
  html.dark .deck-status-solide,
  html.dark .deck-status-maitrise,
  html.dark .deck-done-overlay,
  html.dark .session-pack-badge {
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .deck-status { background: #f0e8d8 !important; }
  html.dark .deck-status-nouveau { background: #b8b8b8 !important; }
  html.dark .deck-status-en-cours { background: var(--pink-d) !important; }
  html.dark .deck-status-a-consolider { background: var(--yellow) !important; }
  html.dark .deck-status-solide { background: var(--mint) !important; }
  html.dark .deck-status-maitrise,
  html.dark .deck-done-overlay { background: var(--lime) !important; }
  html.dark .deck-privacy {
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .deck-privacy-public { background: var(--mint) !important; }
  html.dark .deck-privacy-private { background: var(--yellow) !important; }
  html.dark .session-pack-badge { background: #f0e8d8 !important; }
  html.dark .account-tab,
  html.dark .social-name-row,
  html.dark .social-secure-note,
  html.dark .account-stats > div,
  html.dark .account-profile-card > div {
    background: #111 !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 3px 3px 0 #000 !important;
  }
  html.dark .account-divider::before,
  html.dark .account-divider::after {
    background: #f0e8d8 !important;
  }
  html.dark .account-profile-form,
  html.dark .account-password-update,
  html.dark .account-local-tools,
  html.dark .account-details {
    border-color: #f0e8d8 !important;
  }
  html.dark .account-tab.on {
    background: var(--yellow) !important;
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .account-input,
  html.dark .mock-input,
  html.dark .mock-textarea,
  html.dark .pc-visibility-option,
  html.dark .search-input,
  html.dark .social-pack-select {
    background: #0f0f0f !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 3px 3px 0 #000 !important;
  }
  html.dark .account-input:focus,
  html.dark .mock-input:focus,
  html.dark .mock-textarea:focus,
  html.dark .search-input:focus {
    background: var(--yellow) !important;
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .account-input::placeholder,
  html.dark .mock-input::placeholder,
  html.dark .mock-textarea::placeholder,
  html.dark .search-input::placeholder {
    color: rgba(240, 232, 216, 0.65) !important;
  }
  html.dark .account-input:focus::placeholder,
  html.dark .mock-input:focus::placeholder,
  html.dark .mock-textarea:focus::placeholder,
  html.dark .search-input:focus::placeholder {
    color: rgba(10, 10, 10, 0.65) !important;
  }
  html.dark .pc-visibility-option:has(input:checked) {
    background: var(--yellow) !important;
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .pc-visibility-option:has(input:checked) .pc-visibility-sub {
    color: #242424 !important;
  }
  html.dark .social-board-sub,
  html.dark .mock-sub,
  html.dark .mock-muted,
  html.dark .mock-card-desc,
  html.dark .pc-visibility-sub,
  html.dark .pc-safety-note,
  html.dark .extras-back,
  html.dark .extras-memo {
    color: #d5cbbb !important;
  }
  /* Bouton + AJOUTER sur les cartes : noir + texte blanc, visible sur toute teinte */
  html.dark .deck-add-btn {
    background: #0a0a0a !important;
    color: #fff !important;
    border-color: #0a0a0a !important;
    box-shadow: 2px 2px 0 var(--pink-d) !important;
  }
  html.dark .deck-add-btn.deck-added-check {
    background: var(--lime) !important;
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
    box-shadow: 2px 2px 0 #0a0a0a !important;
  }

  /* Pilules de filtre catégories : rose pâle en dark, sauf l'active qui reste jaune */
  html.dark .filter-pill {
    background: var(--pink) !important;
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
    box-shadow: 2px 2px 0 #000 !important;
  }
  html.dark .filter-pill.on {
    background: var(--yellow) !important;
    color: #0a0a0a !important;
  }
  html.dark .start-panel,
  html.dark .start-auth-nudge {
    background: #111 !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 4px 4px 0 #000 !important;
  }
  html.dark .start-title,
  html.dark .start-copy,
  html.dark .start-auth-nudge span {
    color: #f0e8d8 !important;
  }
  html.dark .start-kicker,
  html.dark .start-down {
    background: var(--yellow) !important;
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .daily-learning-slot,
  html.dark .daily-learning-panel {
    background: #111 !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 4px 4px 0 #000 !important;
  }
  html.dark .daily-learning-title,
  html.dark .daily-learning-hook,
  html.dark .daily-learning-body {
    color: #f0e8d8 !important;
  }
  html.dark .daily-learning-fact,
  html.dark .daily-resource-group {
    background: #1c1c1c !important;
    color: #f0e8d8 !important;
    border-color: #f0e8d8 !important;
    box-shadow: 3px 3px 0 #000 !important;
  }
  html.dark .daily-resource-title,
  html.dark .daily-resource-link {
    color: #f0e8d8 !important;
  }
  html.dark .daily-visual-overlay,
  html.dark .daily-visual-kicker,
  html.dark .daily-visual-cta {
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }

  /* Blocs colorés en mode nuit : garder texte noir sur jaune/rose/menthe. */
  html.dark .daily-review-block,
  html.dark .daily-review-block *,
  html.dark .dashboard-col.dash-col-work,
  html.dark .dashboard-col.dash-col-work *,
  html.dark .dashboard-col.dash-col-almost,
  html.dark .dashboard-col.dash-col-almost *,
  html.dark .fig-todo,
  html.dark .fig-done {
    color: #0a0a0a !important;
    border-color: #0a0a0a !important;
  }
  html.dark .fig-todo {
    background: var(--yellow) !important;
  }
  html.dark .fig-done {
    background: var(--lime) !important;
  }
  html.dark .daily-review-block {
    background: var(--yellow) !important;
    box-shadow: 6px 6px 0 #000 !important;
  }
  html.dark .dashboard-col.dash-col-work {
    background: var(--pink) !important;
    box-shadow: 4px 4px 0 #000 !important;
  }
  html.dark .dashboard-col.dash-col-almost {
    background: var(--mint) !important;
    box-shadow: 4px 4px 0 #000 !important;
  }
  html.dark .dash-title,
  html.dark .dash-list li {
    border-color: rgba(10, 10, 10, 0.25) !important;
  }
  html.dark .dash-pack-due,
  html.dark .dash-pack-pct {
    border-color: #0a0a0a !important;
  }
  * { box-sizing: border-box; }
  html, body {
    margin:0; padding:0;
    background:#f7c8d8 !important;
    color:#0a0a0a !important;
    font-family:'Space Mono', ui-monospace, monospace;
    overflow-x: hidden;
    overflow-y: auto;
    min-height: 100%;
    max-width: 100vw;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: auto;
    touch-action: pan-y;
  }
  /* Mobile : éviter que la section-banner (titre + boutons) déborde */
  @media (max-width: 768px) {
    .section-banner { flex-wrap: wrap; }
  }

  body {
    background-image: radial-gradient(#0a0a0a 0.6px, transparent 0.7px);
    background-size: 5px 5px;
    background-color: #f7c8d8;
  }
  .pixel { font-family:'Press Start 2P', monospace; letter-spacing:0; line-height:1.1; }
  .mono { font-family:'Space Mono', monospace; }
  .vt   { font-family:'VT323', monospace; }
  .ital { font-style: italic; }

  .container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
  .frame {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 6px 6px 0 var(--ink);
  }
  .frame-thick {
    background: #fff;
    border: 4px solid var(--ink);
    box-shadow: 8px 8px 0 var(--ink);
  }
  .btn {
    display: inline-flex; align-items: center; gap: 10px;
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 12px 18px;
    font-family: 'Space Mono', monospace;
    font-weight: 700; font-size: 13px;
    letter-spacing: 0.08em; text-transform: uppercase;
    color: var(--ink); text-decoration: none;
    cursor: pointer;
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .btn:hover { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--ink); }
  .btn:active { transform: translate(4px, 4px); box-shadow: 0 0 0 var(--ink); }
  .btn-y { background: var(--yellow); }
  .btn-m { background: var(--mint); }
  .btn-l { background: var(--lavender); }
  .btn-big { padding: 16px 22px; font-size: 15px; }
  .btn::before {
    content: ''; width: 0; height: 0;
    border-style: solid;
    border-width: 7px 0 7px 11px;
    border-color: transparent transparent transparent var(--ink);
  }

  .fig {
    display: inline-block;
    border: 2px solid var(--ink);
    background: #fff;
    padding: 3px 9px 2px;
    font-family: 'Space Mono', monospace;
    font-size: 11px; font-weight: 700;
    line-height: 1.2;
  }

  /* ─── TOP BAR ─── */
  .nav {
    border-bottom: 4px solid var(--ink);
    background: #fff;
    position: sticky; top: 0; z-index: 50;
  }
  .nav-inner {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 24px;
  }
  .logo {
    font-family: 'Press Start 2P', monospace;
    font-size: 22px;
    color: var(--ink);
    text-decoration: none;
  }
  .logo span { color: var(--pink-d); }
  .nav-links { display: flex; gap: 22px; }
  .nav-links a {
    font-family: 'Space Mono', monospace; font-weight: 700;
    font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase;
    color: var(--ink); text-decoration: none;
    border-bottom: 2px solid transparent;
    padding-bottom: 2px;
  }
  .nav-links a:hover { border-bottom-color: var(--ink); }
  .nav-links a.active { border-bottom-color: var(--ink); }

  /* ─── ISSUE BAR ─── */
  .issue-bar {
    background: var(--ink); color: #fff;
    font-family: 'Space Mono', monospace; font-size: 11px;
    letter-spacing: 0.15em; text-transform: uppercase;
    padding: 6px 0;
    overflow: hidden; white-space: nowrap;
  }
  .ticker { display: inline-block; padding-left: 100%; animation: tick 30s linear infinite; }
  @keyframes tick { from { transform: translateX(0); } to { transform: translateX(-100%); } }
  .ticker span { margin-right: 40px; }
  .ticker .dot { color: var(--yellow); }

  /* ─── HERO ─── */
  .hero {
    padding: 36px 0 28px;
  }
  .masthead {
    display: flex; align-items: flex-end; justify-content: space-between;
    padding: 18px 28px 14px;
    border-bottom: 4px solid var(--ink);
  }
  .masthead h1 {
    font-family: 'Press Start 2P', monospace;
    font-size: 96px;
    margin: 0;
    line-height: 0.95;
    color: var(--ink);
  }
  .masthead-issue {
    border: 3px solid var(--ink);
    background: var(--yellow);
    padding: 6px 12px 5px;
    font-family: 'Space Mono', monospace; font-weight: 700;
    font-size: 12px; letter-spacing: 0.1em;
    box-shadow: 3px 3px 0 var(--ink);
  }
  .deck-tagline {
    padding: 10px 28px;
    font-family: 'Space Mono', monospace; font-style: italic;
    font-size: 18px;
    border-bottom: 3px solid var(--ink);
  }
  .hero-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    padding: 0;
  }
  .hero-left {
    padding: 28px 28px;
    border-right: 3px solid var(--ink);
  }
  .hero-eyebrow {
    font-family: 'Space Mono', monospace; font-weight: 700;
    font-size: 11px; letter-spacing: 0.15em; text-transform: uppercase;
    padding-bottom: 8px; margin-bottom: 12px;
    border-bottom: 2px solid var(--ink);
  }
  .hero-h {
    font-family: 'Press Start 2P', monospace;
    font-size: 44px; line-height: 1.05;
    margin: 0 0 18px;
    color: var(--ink);
  }
  .hero-h em { color: var(--pink-d); font-style: normal; }
  .hero-p {
    font-family: 'Space Mono', monospace;
    font-size: 15px; line-height: 1.65;
    margin: 0 0 22px;
    max-width: 52ch;
  }
  .hero-cta-row { display: flex; gap: 14px; flex-wrap: wrap; }

  .start-panel {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 18px;
    margin-bottom: 22px;
    position: relative;
  }
  .start-kicker {
    display: inline-block;
    background: var(--mint);
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    padding: 4px 8px 3px;
    font-family: 'Press Start 2P', system-ui, monospace;
    font-size: 8px;
    letter-spacing: 0.06em;
    margin-bottom: 12px;
  }
  .start-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 22px;
    line-height: 1.2;
    margin: 0 0 10px;
    color: var(--ink);
  }
  .start-copy {
    font-family: 'Space Mono', monospace;
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 16px;
    max-width: 58ch;
  }
  .start-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
  }
  .start-down {
    position: absolute;
    right: 14px;
    top: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 3px solid var(--ink);
    background: var(--yellow);
    box-shadow: 3px 3px 0 var(--ink);
    font-family: 'Press Start 2P', system-ui, monospace;
    font-size: 18px;
    line-height: 1;
    text-decoration: none;
    color: var(--ink);
    cursor: pointer;
  }
  .start-down:hover {
    transform: translate(1px, 1px);
    box-shadow: 2px 2px 0 var(--ink);
  }
  .start-auth-nudge {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 16px;
    padding: 12px;
    border: 2px dashed var(--ink);
    background: var(--paper);
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    line-height: 1.4;
  }
  .start-auth-nudge[hidden] { display: none; }
  .start-auth-nudge span { flex: 1; min-width: 180px; }

  .daily-learning-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 24px;
    line-height: 1.25;
    margin: 0 0 12px;
    color: var(--ink);
    max-width: 100%;
    overflow-wrap: anywhere;
  }
  .daily-learning-hook {
    font-family: 'Space Mono', monospace;
    font-style: italic;
    font-weight: 700;
    font-size: 15px;
    line-height: 1.45;
    margin: 0 0 10px;
  }
  .daily-learning-body {
    font-family: 'Space Mono', monospace;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 14px;
    width: 100%;
    max-width: none;
    overflow-wrap: anywhere;
  }
  .daily-learning-facts {
    display: grid;
    gap: 8px;
    margin: 0 0 16px;
  }
  .daily-learning-fact {
    background: #fff;
    border: 2px solid var(--ink);
    box-shadow: 3px 3px 0 var(--ink);
    padding: 8px 10px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 12px;
    line-height: 1.35;
  }
  .daily-learning-resources {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 16px;
  }
  .daily-resource-group {
    background: var(--paper);
    border: 2px solid var(--ink);
    padding: 10px;
    min-width: 0;
  }
  .daily-resource-title,
  .daily-pack-label {
    font-family: 'Press Start 2P', monospace;
    font-size: 8px;
    line-height: 1.3;
    margin-bottom: 8px;
    color: var(--ink);
  }
  .daily-resource-link {
    display: block;
    color: var(--ink);
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 12px;
    line-height: 1.35;
    text-decoration: underline;
    text-underline-offset: 2px;
    overflow-wrap: anywhere;
  }
  .daily-resource-link + .daily-resource-link { margin-top: 8px; }
  .daily-pack-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    background: var(--yellow);
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 14px;
  }
  .daily-pack-name {
    font-family: 'Space Mono', monospace;
    font-weight: 900;
    font-size: 15px;
    margin-bottom: 3px;
  }
  .daily-pack-count {
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    font-style: italic;
  }
  .daily-pack-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
  }
  .daily-pack-added {
    background: var(--lime) !important;
  }

  .daily-learning-slot {
    grid-column: 1 / -1;
    padding: 0 28px 28px;
    border-top: 3px solid var(--ink);
    background: var(--paper);
  }
  .daily-learning-slot[hidden] {
    display: none !important;
  }
  .daily-learning-panel {
    margin-top: 28px;
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 18px;
  }
  .daily-learning-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
  }
  .daily-learning-head .hero-eyebrow {
    flex: 1;
    margin-bottom: 0;
  }
  .daily-learning-close {
    flex: 0 0 auto;
  }

  .hero-right {
    padding: 0;
    position: relative;
    background: #0a0a0a;
    overflow: hidden;
    min-height: 360px;
  }
  .daily-visual-card {
    cursor: pointer;
    color: #0a0a0a;
    touch-action: pan-y;
  }
  .daily-visual-art,
  .daily-visual-art *,
  .daily-visual-overlay,
  .hero-caption,
  .hero-fig-tag {
    pointer-events: none;
  }
  .daily-visual-card:focus-visible {
    outline: 4px solid var(--yellow);
    outline-offset: -8px;
  }
  .daily-visual-card:hover .daily-visual-cta {
    transform: translate(1px, 1px);
    box-shadow: 2px 2px 0 #0a0a0a;
  }
  .hero-fig-tag {
    position: absolute; top: 10px; left: 10px;
    z-index: 2;
  }
  .daily-visual-art {
    width: 100%;
    height: 100%;
    min-height: 360px;
  }
  .daily-visual-art svg {
    width: 100%;
    height: 100%;
    min-height: 360px;
    display: block;
  }
  .hero-caption {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: #fff; border-top: 3px solid var(--ink);
    padding: 8px 14px;
    font-family: 'Space Mono', monospace; font-size: 12px;
  }
  .daily-visual-overlay {
    position: absolute;
    left: 18px;
    bottom: 48px;
    z-index: 3;
    max-width: min(360px, calc(100% - 36px));
    background: rgba(255, 248, 232, 0.94);
    color: #0a0a0a;
    border: 3px solid #0a0a0a;
    box-shadow: 4px 4px 0 #0a0a0a;
    padding: 12px;
  }
  .daily-visual-kicker {
    display: inline-block;
    background: var(--yellow);
    border: 2px solid #0a0a0a;
    padding: 3px 6px 2px;
    font-family: 'Press Start 2P', monospace;
    font-size: 8px;
    line-height: 1.25;
    margin-bottom: 10px;
  }
  .daily-visual-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 20px;
    line-height: 1.15;
    margin-bottom: 10px;
  }
  .daily-visual-cta {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    background: var(--yellow);
    color: #0a0a0a;
    border: 3px solid #0a0a0a;
    box-shadow: 3px 3px 0 #0a0a0a;
    padding: 8px 10px;
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    line-height: 1.2;
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .daily-visual-cta::before {
    content: "▶";
    margin-right: 8px;
  }

  /* ─── STATS STRIP ─── */
  .stats {
    display: grid; grid-template-columns: repeat(4, 1fr);
    border-top: 3px solid var(--ink);
    border-bottom: 3px solid var(--ink);
    background: #fff;
  }
  .stat {
    padding: 18px 22px;
    border-left: 3px solid var(--ink);
  }
  .stat:first-child { border-left: none; }
  .stat-n {
    font-family: 'Press Start 2P', monospace; font-size: 26px;
    margin: 0 0 6px; color: var(--ink);
  }
  .stat-l {
    font-family: 'Space Mono', monospace; font-weight: 700;
    font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  }

  /* ─── SECTION BANNERS ─── */
  .section-banner {
    margin: 40px 0 18px;
    display: flex; align-items: center; gap: 14px;
  }
  .section-banner .bar {
    flex: 1; height: 4px; background: var(--ink);
  }
  .section-banner h2 {
    font-family: 'Press Start 2P', monospace;
    font-size: 28px;
    margin: 0;
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 10px 18px 9px;
  }

  /* ─── DECK CARDS ─── */
  .deck-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
  }
  .deck-grid.deck-grid-compact {
    grid-template-columns: repeat(auto-fit, minmax(230px, 280px));
    justify-content: center;
  }
  .deck {
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    overflow: hidden;
    display: flex; flex-direction: column;
  }
  .deck-img {
    aspect-ratio: 4/3;
    border-bottom: 3px solid var(--ink);
    position: relative;
    overflow: hidden;
  }
  .deck-img .fig {
    position: absolute; top: 8px; left: 8px;
    font-size: 9px; padding: 2px 6px;
    border-width: 1.5px;
  }
  .deck-img .dot-circ {
    position: absolute; top: 8px; right: 8px;
    width: 22px; height: 22px; border-radius: 50%;
    border: 2px solid var(--ink); background: #fff;
  }
  .deck-body { padding: 12px 14px 14px; }
  .deck-cat {
    font-family: 'Space Mono', monospace; font-weight: 700;
    font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase;
    margin-bottom: 6px;
  }
  .deck-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 14px; line-height: 1.25;
    margin: 0 0 10px; color: var(--ink);
    /* Évite tout débordement : casse les mots trop longs si besoin */
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
  }
  /* Titre long (> 24 caractères) : police plus petite + Space Mono pour
     gagner en compacité, tout en gardant le look brutaliste. */
  .deck-title.deck-title-long {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.02em;
    line-height: 1.3;
  }
  .deck-meta {
    display: flex; gap: 2px;
    margin-bottom: 8px;
  }
  .deck-meta .seg {
    flex: 1; height: 8px;
    border: 1.5px solid var(--ink);
    background: #fff;
  }
  .deck-meta .seg.on { background: var(--ink); }
  .deck-foot {
    display: flex; justify-content: space-between;
    font-family: 'Space Mono', monospace; font-weight: 700;
    font-size: 11px; letter-spacing: 0.08em;
  }

  .deck.y .deck-img { background: var(--yellow); }
  .deck.l .deck-img { background: var(--lime); }
  .deck.m .deck-img { background: var(--mint); }
  .deck.v .deck-img { background: var(--lavender); }
  .deck.p .deck-img { background: var(--pink-d); }
  .deck.g .deck-img { background: var(--gray); }
  .deck.w .deck-img { background: #fff; }
  .deck.k .deck-img { background: var(--ink); }
  .deck.k { color: #fff; background: var(--ink); }
  .deck.k .deck-body { background: var(--ink); color: #fff; }
  .deck.k .deck-title, .deck.k .deck-cat, .deck.k .deck-foot { color: #fff; }
  .deck.k .deck-meta .seg { border-color: #fff; background: var(--ink); }
  .deck.k .deck-meta .seg.on { background: #fff; }

  /* ─── HOW IT WORKS ─── */
  .how {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px;
  }
  .how-step {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 22px;
    position: relative;
  }
  .how-step .num {
    position: absolute; top: -18px; left: -18px;
    width: 50px; height: 50px;
    border: 3px solid var(--ink);
    background: var(--yellow);
    box-shadow: 3px 3px 0 var(--ink);
    display: flex; align-items: center; justify-content: center;
    font-family: 'Press Start 2P', monospace; font-size: 16px;
  }
  .how-step.b .num { background: var(--lavender); }
  .how-step.c .num { background: var(--mint); }
  .how-h {
    font-family: 'Press Start 2P', monospace;
    font-size: 16px; margin: 14px 0 10px; line-height: 1.2;
  }
  .how-p {
    font-family: 'Space Mono', monospace; font-size: 13px; line-height: 1.6;
  }
  .how-art {
    margin-top: 14px;
    aspect-ratio: 5/3;
    border: 2px solid var(--ink);
    background: var(--pink);
    background-image: radial-gradient(#0a0a0a 0.5px, transparent 0.6px);
    background-size: 4px 4px;
    position: relative;
    overflow: hidden;
  }

  /* ─── PRICING ─── */
  .pricing { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 22px; }
  .price {
    background: #fff; border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 22px;
  }
  .price.feat { background: var(--yellow); transform: translateY(-12px); }
  .price-name {
    font-family: 'Press Start 2P', monospace; font-size: 14px;
    margin: 0 0 14px;
  }
  .price-amt {
    font-family: 'Press Start 2P', monospace; font-size: 36px;
    margin: 0 0 6px;
  }
  .price-per {
    font-family: 'Space Mono', monospace; font-size: 12px;
    letter-spacing: 0.05em; margin-bottom: 18px;
  }
  .price ul {
    list-style: none; padding: 0; margin: 0 0 20px;
    border-top: 2px dashed var(--ink); padding-top: 14px;
  }
  .price li {
    font-family: 'Space Mono', monospace; font-size: 13px;
    padding: 5px 0 5px 22px;
    position: relative;
    line-height: 1.4;
  }
  .price li::before {
    content: ''; position: absolute; left: 0; top: 8px;
    width: 10px; height: 10px;
    background: var(--ink);
    /* tiny pixel checkmark via box-shadow */
  }
  .price li::after {
    content: ''; position: absolute; left: 2px; top: 12px;
    width: 2px; height: 2px;
    background: #fff;
    box-shadow: 2px 0 0 #fff, 4px -2px 0 #fff, 6px -4px 0 #fff;
  }
  .price-tag {
    position: absolute; top: -14px; right: -14px;
    background: var(--pink-d); border: 3px solid var(--ink);
    box-shadow: 3px 3px 0 var(--ink);
    padding: 6px 10px 5px;
    font-family: 'Press Start 2P', monospace; font-size: 10px;
    transform: rotate(6deg);
  }
  .price { position: relative; }

  /* ─── TESTIMONIAL STRIP ─── */
  .testimonial {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 6px 6px 0 var(--ink);
    padding: 26px 30px;
    display: grid; grid-template-columns: auto 1fr auto; gap: 22px; align-items: center;
  }
  .avatar {
    width: 90px; height: 90px;
    border: 3px solid var(--ink);
    background: var(--lime);
    overflow: hidden;
    position: relative;
  }
  .quote-mark {
    font-family: 'Press Start 2P', monospace;
    font-size: 56px;
    line-height: 1;
    color: var(--ink);
  }
  .quote-text {
    font-family: 'Space Mono', monospace; font-style: italic;
    font-size: 17px; line-height: 1.5;
    margin: 0;
  }
  .quote-who {
    margin-top: 8px;
    font-family: 'Space Mono', monospace; font-weight: 700; font-size: 12px;
    letter-spacing: 0.1em; text-transform: uppercase;
  }

  /* ─── CTA FOOT ─── */
  .cta-foot {
    margin: 60px 0 40px;
    background: var(--ink);
    color: #fff;
    border: 4px solid var(--ink);
    box-shadow: 8px 8px 0 var(--pink-d);
    padding: 50px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
  }
  .cta-foot::before {
    content: ''; position: absolute; inset: 0;
    background-image: radial-gradient(#fff 0.5px, transparent 0.6px);
    background-size: 6px 6px;
    opacity: 0.15;
  }
  .cta-foot h2 {
    font-family: 'Press Start 2P', monospace;
    font-size: 48px; line-height: 1.05;
    margin: 0 0 20px;
    position: relative;
  }
  .cta-foot p {
    font-family: 'Space Mono', monospace; font-style: italic;
    font-size: 17px; margin: 0 0 26px;
    position: relative;
  }
  .cta-foot .btn { box-shadow: 4px 4px 0 var(--pink-d); }

  /* ─── DONATE ─── */
  .donate-grid {
    position: relative;
    display: grid; grid-template-columns: auto 1fr;
    gap: 36px; align-items: center;
    text-align: left;
  }
  .donate-jar {
    width: 180px; height: 180px;
    border: 3px solid #fff;
    background: var(--ink);
    position: relative;
    flex-shrink: 0;
  }
  .donate-jar svg { width: 100%; height: 100%; display: block; }
  .donate-body { position: relative; }
  .donate-body h2 { margin-bottom: 14px !important; font-size: 42px !important; }
  .donate-body h2 em { color: var(--yellow); font-style: normal; }
  .donate-body p { margin-bottom: 22px !important; }
  .donate-row {
    display: flex; flex-wrap: wrap; gap: 12px;
    margin-bottom: 18px;
  }
  .donate-amt {
    background: #fff; color: var(--ink);
    border: 3px solid #fff;
    box-shadow: 4px 4px 0 var(--pink-d);
    padding: 12px 18px;
    font-family: 'Press Start 2P', monospace;
    font-size: 16px; line-height: 1;
    cursor: pointer; text-decoration: none;
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .donate-amt:hover { transform: translate(2px,2px); box-shadow: 2px 2px 0 var(--pink-d); }
  .donate-amt.on { background: var(--yellow); }
  .donate-amt.free { background: var(--ink); color: #fff; border-color: #fff; }
  .donate-amt.free:hover { background: var(--pink-d); }
  .donate-cta-row {
    display: flex; gap: 14px; align-items: center; flex-wrap: wrap;
    margin-top: 8px;
  }
  .donate-reassure {
    margin-top: 18px !important;
    font-family: 'Space Mono', monospace !important; font-style: normal !important;
    font-size: 11px !important;
    letter-spacing: 0.12em; text-transform: uppercase;
    color: #fff; opacity: 0.7;
  }
  @media (max-width: 760px) {
    .donate-grid { grid-template-columns: 1fr; text-align: center; }
    .donate-row, .donate-cta-row { justify-content: center; }
    .donate-jar { margin: 0 auto; }
  }

  /* ─── FOOTER ─── */
  footer {
    border-top: 4px solid var(--ink);
    background: #fff;
    padding: 28px 24px 22px;
  }
  .footer-inner {
    max-width: 1280px; margin: 0 auto;
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px;
  }
  .footer-col h4 {
    font-family: 'Press Start 2P', monospace; font-size: 11px;
    margin: 0 0 12px;
  }
  .footer-col ul { list-style: none; padding: 0; margin: 0; }
  .footer-col li {
    font-family: 'Space Mono', monospace; font-size: 13px;
    padding: 3px 0;
  }
  .footer-col li a { color: var(--ink); text-decoration: none; }
  .footer-col li a:hover { text-decoration: underline; }
  .colophon {
    margin-top: 22px; padding-top: 14px;
    border-top: 2px dashed var(--ink);
    font-family: 'Space Mono', monospace; font-size: 11px;
    letter-spacing: 0.1em; text-transform: uppercase;
    display: flex; justify-content: space-between;
  }

  /* ─── MES PAQUETS ─── */
  .theme-row { margin-bottom: 36px; }
  .theme-label { display: flex; align-items: center; gap: 14px; margin: 0 0 16px; }
  .theme-num { font-family: 'Press Start 2P', monospace; font-size: 14px; width: 44px; height: 44px; background: var(--yellow); border: 3px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); display: flex; align-items: center; justify-content: center; }
  .theme-label h3 { font-family: 'Press Start 2P', monospace; font-size: 22px; margin: 0; flex: 1; }
  .deck-grid.four { grid-template-columns: repeat(4, 1fr); }
  .deck.mine { position: relative; }
  .mine-badge { position: absolute; top: -10px; right: -10px; z-index: 3; background: var(--ink); color: #fff; border: 2px solid var(--ink); padding: 4px 9px 3px; font-family: 'Space Mono', monospace; font-weight: 700; font-size: 10px; letter-spacing: 0.08em; box-shadow: 2px 2px 0 var(--ink); }
  .mine-badge.stolen-badge { background: var(--pink-d); color: var(--ink); }
  .deck.add { border: 3px dashed var(--ink); box-shadow: none; background: transparent; display: flex; align-items: center; justify-content: center; min-height: 280px; }
  .deck.add.ghost { opacity: 0.25; }
  .add-inner { text-align: center; }
  .add-plus { font-family: 'Press Start 2P', monospace; font-size: 36px; margin-bottom: 8px; }
  .add-label { font-family: 'Space Mono', monospace; font-weight: 700; font-size: 12px; letter-spacing: 0.08em; }

  /* ─── CRÉER ─── */
  .create-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 26px; align-items: start; }
  .create-form { padding: 26px 28px; }
  .create-row { margin-bottom: 18px; }
  .create-row.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
  .create-row label { display: block; font-family: 'Space Mono', monospace; font-weight: 700; font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 6px; }
  .input { border: 2px solid var(--ink); background: #fff; padding: 10px 12px; font-family: 'Space Mono', monospace; font-size: 14px; box-shadow: 3px 3px 0 var(--ink); }
  .caret { animation: blink 1s steps(2) infinite; margin-left: 2px; }
  @keyframes blink { 50% { opacity: 0; } }
  .swatches { display: flex; gap: 8px; padding: 8px 0; }
  .sw { width: 32px; height: 32px; border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); cursor: pointer; }
  .sw.on { outline: 3px solid var(--ink); outline-offset: 3px; }
  .cards-list { display: flex; flex-direction: column; gap: 6px; }
  .mini-card { border: 2px solid var(--ink); background: #fff; padding: 8px 12px; display: flex; align-items: center; gap: 10px; font-family: 'Space Mono', monospace; font-size: 13px; box-shadow: 2px 2px 0 var(--ink); }
  .mini-card.add-card { background: var(--yellow); font-weight: 700; letter-spacing: 0.08em; justify-content: center; text-transform: uppercase; }
  .create-preview { position: relative; padding: 30px 20px 30px 30px; }
  .preview-tag { position: absolute; top: 0; left: 0; }

  /* ─── QUIZ ─── */
  .quiz-hero { padding: 30px; display: grid; grid-template-columns: 1fr 1.2fr; gap: 30px; align-items: center; }
  .rule-num { display: inline-block; background: var(--pink-d); border: 2px solid var(--ink); padding: 3px 10px 2px; font-family: 'Space Mono', monospace; font-weight: 700; font-size: 11px; letter-spacing: 0.1em; box-shadow: 2px 2px 0 var(--ink); margin-bottom: 12px; }
  .rule-title { font-family: 'Press Start 2P', monospace; font-size: 22px; line-height: 1.2; margin: 0 0 14px; }
  .rule-p { font-family: 'Space Mono', monospace; font-size: 14px; line-height: 1.6; margin: 0; }
  .quiz-vs { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: center; border: 3px solid var(--ink); padding: 22px; background: #fff; box-shadow: 4px 4px 0 var(--ink); }
  .vs-side { text-align: center; }
  .vs-avatar { width: 80px; height: 80px; border: 3px solid var(--ink); margin: 0 auto 10px; box-shadow: 3px 3px 0 var(--ink); }
  .vs-avatar svg { width: 100%; height: 100%; display: block; }
  .vs-name { font-family: 'Press Start 2P', monospace; font-size: 13px; margin-bottom: 4px; }
  .vs-score { font-family: 'Space Mono', monospace; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }
  .vs-mid { text-align: center; }
  .vs-flash { font-family: 'Press Start 2P', monospace; font-size: 36px; color: var(--ink); background: var(--yellow); padding: 8px 14px; border: 3px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); display: inline-block; transform: rotate(-4deg); margin-bottom: 12px; }
  .vs-stake { font-family: 'Space Mono', monospace; font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 6px; }
  .vs-pkg { background: var(--pink-d); font-size: 12px; }
  .opponents { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
  .opp { display: grid; grid-template-columns: 80px 1fr auto; gap: 16px; align-items: center; background: #fff; border: 3px solid var(--ink); box-shadow: 4px 4px 0 var(--ink); padding: 14px 18px; }
  .opp .vs-avatar { width: 64px; height: 64px; margin: 0; }
  .opp-top { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; font-family: 'Press Start 2P', monospace; font-size: 13px; }
  .opp-shared { font-family: 'Space Mono', monospace; font-size: 12px; line-height: 1.5; }

  /* ─── PIXEL DECORATIONS (svg utility) ─── */
  .pix-bg svg { display: block; width: 100%; height: 100%; }

  @media (max-width: 980px) {
    .deck-grid.four { grid-template-columns: 1fr 1fr; }
    .create-grid { grid-template-columns: 1fr; }
    .quiz-hero { grid-template-columns: 1fr; }
    .opponents { grid-template-columns: 1fr; }
    .opp { grid-template-columns: 56px 1fr; }
    .opp .btn { grid-column: 1 / -1; }
    .masthead h1 { font-size: 64px; }
    .hero-h { font-size: 32px; }
    .hero-grid { grid-template-columns: 1fr; }
    .hero-left { border-right: none; border-bottom: 3px solid var(--ink); }
    .daily-learning-slot { padding: 0 18px 22px; }
    .daily-learning-resources { grid-template-columns: 1fr; }
    .stats { grid-template-columns: 1fr 1fr; }
    .deck-grid { grid-template-columns: 1fr 1fr; }
    .how, .pricing { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr 1fr; }
    .testimonial { grid-template-columns: 1fr; text-align: center; }
  }
  /* ─── APP-SPECIFIC ADDITIONS ─── */

  /* Single-page sections (hide non-active) */
  .page-section { display: none; }
  .page-section.active { display: block; }

  /* Hide legacy screens — only quiz-session is used */
  .screen { display: none; }
  .screen.active { display: block; }

  /* Mobile nav (responsive) */
  @media (max-width: 760px) {
    .nav-inner { flex-wrap: wrap; padding: 12px 16px; gap: 8px; }
    .nav-links { order: 3; flex-basis: 100%; gap: 14px; overflow-x: auto; padding-bottom: 4px; }
    .nav-links a { white-space: nowrap; font-size: 11px; }
    .logo { font-size: 17px; }
    .nav-inner > .btn { font-size: 11px; padding: 8px 12px; }
    .container { padding: 0 14px; }
    .section-banner h2 { font-size: 16px; padding: 6px 10px; }
    .section-banner { gap: 8px; margin: 20px 0 14px; }
  }

  /* Make deck cards clickable and feedback */
  .deck { cursor: pointer; background: #fff; transition: transform 0.08s, box-shadow 0.08s; }
  .deck:hover { transform: translate(2px, 2px); box-shadow: 3px 3px 0 var(--ink); }
  .deck:active { transform: translate(5px, 5px); box-shadow: 0 0 0 var(--ink); }

  /* Big centered emoji inside .deck-img */
  .deck-emoji {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 56px;
    line-height: 1;
  }

  /* ─── FLASHCARD SESSION ─── */
  .session-wrap { max-width: 760px; margin: 0 auto; padding: 24px 16px 60px; }
  .session-top {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 18px; gap: 14px; flex-wrap: wrap;
  }
  .session-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 18px;
    flex: 1; min-width: 0;
    word-break: break-word;
  }
  .session-progress {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 14px;
    background: var(--yellow);
    border: 2px solid var(--ink);
    padding: 4px 10px;
    box-shadow: 2px 2px 0 var(--ink);
  }
  .session-card {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 6px 6px 0 var(--ink);
    padding: 36px 26px;
    min-height: 280px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    margin-bottom: 22px;
  }
  .session-card-label {
    font-family: 'Press Start 2P', monospace;
    font-size: 11px;
    background: var(--pink-d);
    color: var(--ink);
    display: inline-block;
    padding: 5px 10px 4px;
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    margin: 0 auto 18px;
  }
  .session-card.flipped .session-card-label { background: var(--lime); }
  .session-card-text {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 20px;
    line-height: 1.55;
    color: var(--ink);
  }
  .session-card-answer {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 22px;
    line-height: 1.5;
    color: var(--ink);
    background: var(--lime);
    border: 2px solid var(--ink);
    padding: 14px 16px;
    margin-top: 14px;
    display: inline-block;
    max-width: 100%;
    box-shadow: 3px 3px 0 var(--ink);
  }
  .session-card-memo {
    margin-top: 16px;
    padding: 12px;
    background: var(--paper);
    border: 2px dashed var(--ink);
    font-family: 'Space Mono', monospace;
    font-style: italic;
    font-size: 13px;
    line-height: 1.5;
    text-align: left;
  }
  .session-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .session-quality {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }
  .btn-q {
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    background: #fff;
    color: var(--ink);
    padding: 14px 8px;
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    text-align: center;
    cursor: pointer;
    line-height: 1.4;
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .btn-q:hover { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--ink); }
  .btn-q.btn-q-again { background: var(--pink-d); }
  .btn-q.btn-q-hard { background: var(--lavender); }
  .btn-q.btn-q-good { background: var(--lime); }
  .btn-q.btn-q-easy { background: var(--mint); }
  .btn-q .q-num {
    display: block;
    font-size: 10px;
    margin-bottom: 4px;
  }

  @media (max-width: 540px) {
    .session-quality { grid-template-columns: repeat(2, 1fr); }
    .btn-q { font-size: 8px; padding: 12px 6px; }
    .session-card-text { font-size: 16px; }
    .session-card-answer { font-size: 14px; }
    .session-title { font-size: 14px; }
    .deck-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  }

  /* ─── RESULT ─── */
  .result-wrap {
    max-width: 600px; margin: 0 auto;
    text-align: center;
    padding: 40px 20px;
  }
  .result-emoji { font-size: 64px; margin-bottom: 16px; }
  .result-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 20px;
    margin-bottom: 20px;
  }
  .result-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 24px;
  }
  .result-stat {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 14px 10px;
  }
  .result-stat-n {
    font-family: 'Press Start 2P', monospace;
    font-size: 22px;
    color: var(--ink);
    margin-bottom: 6px;
  }
  .result-stat-l {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 10px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
  }

  /* ─── TOASTS / CELEBRATIONS ─── */
  .gam-toast {
    position: fixed;
    top: 80px; left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 12px 20px;
    font-family: 'Press Start 2P', monospace;
    font-size: 11px;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.25s, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
    text-align: center;
    max-width: 90vw;
    line-height: 1.4;
  }
  .gam-toast.gam-toast-show { opacity: 1; transform: translateX(-50%) translateY(0); }
  .gam-toast-combo { background: var(--yellow); }
  .gam-toast-streak { background: var(--pink-d); }
  .gam-toast-celebrate { background: var(--lime); }

  .gam-confetti-container {
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none; z-index: 9998;
    overflow: hidden;
  }
  .gam-confetti {
    position: absolute; top: -10px;
    width: 10px; height: 10px;
    border: 1px solid var(--ink);
    animation: confetti-fall linear forwards;
  }
  @keyframes confetti-fall {
    0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
    100% { transform: translateY(110vh) rotate(720deg); opacity: 0.5; }
  }

  /* Filter pills above deck grid */
  .filter-bar {
    display: flex; gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 22px;
  }
  .filter-pill {
    background: #fff;
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    padding: 6px 12px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
    color: var(--ink);
    transition: transform 0.06s, box-shadow 0.06s;
  }
  .filter-pill:hover { transform: translate(1px, 1px); box-shadow: 1px 1px 0 var(--ink); }
  .filter-pill.on { background: var(--yellow); }

  /* "Done today" green tint */
  .deck.deck-done-today { outline: 4px solid var(--lime); outline-offset: -3px; }

  /* Force hidden attribute to work with grid/flex elements */
  .session-actions[hidden], .session-quality[hidden],
  #session-card-answer[hidden], #session-card-memo[hidden] {
    display: none !important;
  }

  /* ─── RÉVISION DU JOUR — BLOC TOP DE MES PAQUETS ─── */
  .daily-review-block {
    background: var(--yellow);
    border: 4px solid var(--ink);
    box-shadow: 8px 8px 0 var(--ink);
    padding: 22px 26px;
    margin: 26px 0 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
  }
  .daily-review-left { flex: 1; min-width: 200px; }
  .daily-review-eyebrow {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.16em;
    margin-bottom: 8px;
  }
  .daily-review-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 22px;
    line-height: 1.15;
    margin: 0 0 8px;
  }
  .daily-review-sub {
    font-family: 'Space Mono', monospace;
    font-style: italic;
    font-size: 13px;
  }
  #btn-daily-review {
    background: var(--ink);
    color: #fff;
    border-color: var(--ink);
    box-shadow: 4px 4px 0 var(--pink-d);
  }
  #btn-daily-review:hover { box-shadow: 2px 2px 0 var(--pink-d); }

  /* ─── DASHBOARD ─── */
  .dashboard-block { margin-bottom: 30px; }
  .dashboard-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
  .dashboard-col {
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 14px;
  }
  .dashboard-col.dash-col-work { background: var(--pink); }
  .dashboard-col.dash-col-almost { background: var(--mint); }
  .dash-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 11px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 2px dashed var(--ink);
  }
  .dash-list { list-style: none; padding: 0; margin: 0; }
  .dash-list li {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 12px;
    padding: 6px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    border-bottom: 1px solid rgba(10,10,10,0.1);
  }
  .dash-list li:last-child { border-bottom: none; }
  .dash-list li:hover .dash-pack-name { text-decoration: underline; }
  .dash-pack-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .dash-pack-pct, .dash-pack-due {
    background: var(--ink);
    color: #fff;
    padding: 2px 8px 1px;
    font-size: 10px;
    flex-shrink: 0;
  }
  .dash-pack-pct { background: var(--ink); }
  .dash-col-work .dash-pack-due { background: var(--pink-d); color: var(--ink); }
  .dash-col-almost .dash-pack-pct { background: var(--lime); color: var(--ink); }

  /* ─── SECTIONS (À faire / Done) ─── */
  .pack-section { margin-bottom: 36px; }
  .pack-section-banner {
    margin: 30px 0 18px;
  }
  .fig-todo { background: var(--yellow); }
  .fig-done { background: var(--lime); }
  .pack-section-done .deck-grid {
    opacity: 0.85;
  }
  .pack-section-done .section-banner h2 {
    background: var(--lime);
  }

  /* ─── DECK : Status pill + done overlay + mini stats ─── */
  .deck-status {
    display: inline-block;
    margin-left: 6px;
    background: var(--ink);
    color: #fff;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 9px;
    letter-spacing: 0.06em;
    padding: 2px 6px 1px;
    text-transform: uppercase;
    vertical-align: middle;
  }
  .deck-status-nouveau { background: var(--gray); }
  .deck-status-en-cours { background: var(--pink-d); color: var(--ink); }
  .deck-status-a-consolider { background: var(--yellow); color: var(--ink); }
  .deck-status-solide { background: var(--mint); color: var(--ink); }
  .deck-status-maitrise { background: var(--lime); color: var(--ink); }
  .deck-privacy {
    display: inline-block;
    margin-left: 6px;
    border: 1.5px solid var(--ink);
    background: #fff;
    color: var(--ink);
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 9px;
    letter-spacing: 0.06em;
    padding: 1px 6px;
    text-transform: uppercase;
    vertical-align: middle;
  }
  .deck-privacy-public { background: var(--mint); }
  .deck-privacy-private { background: var(--yellow); }

  .deck-mini-stats {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 10px;
    margin: 6px 0 8px;
    color: var(--ink);
  }
  .deck-mini-stats span { white-space: nowrap; }
  .deck-mini-due { color: var(--pink-d); }
  .deck-mini-mastered { color: #2a7a2a; }

  /* Done deck overlay */
  .deck-done-overlay {
    position: absolute;
    top: 8px; right: 8px;
    background: var(--lime);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    padding: 3px 7px 2px;
    z-index: 3;
    animation: doneBadgePop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  }
  .deck-done-today {
    position: relative;
  }
  .deck-mastered { border-color: var(--ink); }
  @keyframes doneBadgePop {
    0% { transform: scale(0) rotate(-10deg); opacity: 0; }
    100% { transform: scale(1) rotate(0); opacity: 1; }
  }

  /* Pack badge inside session card (daily review) */
  .session-pack-badge {
    display: inline-block;
    background: var(--lavender);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 10px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 4px 9px 3px;
    margin: 0 auto 12px;
    align-self: center;
  }

  @media (max-width: 760px) {
    .dashboard-row { grid-template-columns: 1fr; }
    .daily-review-title { font-size: 18px; }
    .daily-review-block { padding: 18px; }
    .pack-section-banner h2 { font-size: 14px; }
  }

  /* ============================================================
     COLLECTION : bouton AJOUTER + animation
     ============================================================ */
  .deck { position: relative; }

  .deck-add-btn {
    position: absolute;
    top: 8px; right: 8px;
    z-index: 5;
    background: var(--ink);
    color: #fff;
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--pink-d);
    padding: 5px 9px 4px;
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    cursor: pointer;
    line-height: 1;
    transition: transform 0.08s, box-shadow 0.08s, background 0.2s;
  }
  .deck-add-btn:hover {
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--pink-d);
    background: var(--pink-d);
    color: var(--ink);
  }
  .deck-add-btn.deck-added-check {
    background: var(--lime);
    color: var(--ink);
    border-color: var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    cursor: default;
  }
  .deck-add-btn.deck-added-check:hover {
    transform: none;
    box-shadow: 2px 2px 0 var(--ink);
    background: var(--lime);
  }

  /* Si done overlay aussi présent, on offset le bouton AJOUTER */
  .deck-done-overlay + .deck-add-btn { top: 38px; }

  /* Bouton SUPPRIMER sur Mes Paquets — petit ✕ discret en haut à droite */
  .deck { position: relative; }
  .deck-remove-btn {
    position: absolute;
    top: 8px; right: 8px;
    z-index: 5;
    background: #fff;
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    width: 28px; height: 28px;
    padding: 0;
    font-family: 'Space Mono', monospace;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.08s, box-shadow 0.08s, background 0.15s;
  }
  .deck-remove-btn:hover {
    background: var(--pink-d);
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--ink);
  }
  /* Si overlay DONE présent, décale le bouton SUPPRIMER */
  .deck-done-overlay + .deck-remove-btn { top: 38px; }

  /* Animation "ajout" : scale + flash vert */
  .deck-just-added {
    animation: deck-add-pulse 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
  }
  @keyframes deck-add-pulse {
    0% { transform: scale(1); box-shadow: 5px 5px 0 var(--ink); }
    30% {
      transform: scale(1.08);
      box-shadow: 7px 7px 0 var(--lime), 0 0 20px var(--lime);
    }
    60% { transform: scale(0.98); }
    100% { transform: scale(1); box-shadow: 5px 5px 0 var(--ink); }
  }

  /* Fade-in du deck remplacé après animation */
  .deck-fade-in { animation: deck-fade-in 0.4s ease-out; }
  @keyframes deck-fade-in {
    0% { opacity: 0.5; transform: scale(0.95); }
    100% { opacity: 1; transform: scale(1); }
  }

  /* Style des decks déjà ajoutés (subtil) */
  .deck-added {
    /* Pas besoin d'effet visible — le badge AJOUTÉ suffit */
  }
  .deck-added::before {
    /* Petite bande lime à gauche pour rappeler que c'est dans la collection */
    content: "";
    position: absolute;
    left: -3px; top: -3px; bottom: -3px;
    width: 4px;
    background: var(--lime);
    z-index: 2;
  }

  /* Add burst — petite explosion d'emojis */
  .add-burst {
    position: fixed;
    width: 0; height: 0;
    z-index: 9999;
    pointer-events: none;
  }
  .add-burst-piece {
    position: absolute;
    font-size: 20px;
    line-height: 1;
    animation: burst-fly 0.9s ease-out forwards;
    --dx: 0; --dy: 0;
  }
  @keyframes burst-fly {
    0% { transform: translate(0, 0) scale(0); opacity: 1; }
    20% { transform: translate(calc(var(--dx) * 0.4), calc(var(--dy) * 0.4)) scale(1.2); opacity: 1; }
    100% { transform: translate(var(--dx), var(--dy)) scale(0.6); opacity: 0; }
  }

  /* Bouton "Mélanger" dans banner */
  .btn-shuffle {
    font-size: 11px !important;
    padding: 6px 12px !important;
    background: var(--lavender);
    flex-shrink: 0;
  }
  .btn-shuffle:hover { background: var(--pink-d); }
  @media (max-width: 760px) {
    .btn-shuffle { font-size: 9px !important; padding: 5px 8px !important; }
  }

  /* ============================================================
     🦆 CANARD — Style identique à l'app desktop (canard de bureau)
     ============================================================ */

  /* Conteneur du canard — flotte sur la page */
  .duck-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 120px;
    height: 120px;
    z-index: 9990;
    cursor: grab;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
  }
  .duck-container:active { cursor: grabbing; }

  /* Image du canard. Animation breathe = fallback si sprite non animé. */
  .duck-img {
    width: 110px;
    height: 110px;
    object-fit: contain;
    pointer-events: none;
    transform-origin: 50% 90%;
    animation: duck-breathe 3.2s ease-in-out infinite;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.22));
    transition: transform 0.18s ease;
  }
  .duck-container.animated .duck-img { animation: none; }

  @keyframes duck-breathe {
    0%, 100% { transform: scale(1) translateY(0); }
    50%      { transform: scale(1.03) translateY(-2px); }
  }

  /* Fallback emoji */
  .duck-fallback {
    font-size: 90px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.22));
    animation: duck-breathe 3.2s ease-in-out infinite;
    pointer-events: none;
  }

  /* Tailles */
  .duck-container.duck-size-sm { width: 80px; height: 80px; }
  .duck-container.duck-size-sm .duck-img { width: 76px; height: 76px; }
  .duck-container.duck-size-sm .duck-fallback { font-size: 64px; }

  .duck-container.duck-size-lg { width: 160px; height: 160px; }
  .duck-container.duck-size-lg .duck-img { width: 150px; height: 150px; }
  .duck-container.duck-size-lg .duck-fallback { font-size: 130px; }

  /* Réactions */
  .duck-container.happy .duck-img,
  .duck-container.happy .duck-fallback {
    animation: duck-happy 0.6s ease;
  }
  .duck-container.sad .duck-img,
  .duck-container.sad .duck-fallback {
    animation: duck-sad 0.6s ease;
  }
  .duck-container.petted .duck-img,
  .duck-container.petted .duck-fallback {
    animation: duck-petted 0.5s ease;
  }
  @keyframes duck-happy {
    0%   { transform: scale(1); }
    30%  { transform: scale(1.18) translateY(-12px); }
    60%  { transform: scale(1.05) translateY(0); }
    100% { transform: scale(1); }
  }
  @keyframes duck-sad {
    0%, 100% { transform: translateX(0); }
    20%      { transform: translateX(-8px) rotate(-3deg); }
    40%      { transform: translateX(8px) rotate(3deg); }
    60%      { transform: translateX(-5px); }
    80%      { transform: translateX(5px); }
  }
  @keyframes duck-petted {
    0%   { transform: scale(1) rotate(0); }
    30%  { transform: scale(1.12) translateY(-6px) rotate(-3deg); }
    60%  { transform: scale(1.04) translateY(-2px) rotate(2deg); }
    100% { transform: scale(1) rotate(0); }
  }

  /* Cœur qui monte quand on caresse */
  .duck-heart {
    position: fixed;
    font-size: 22px;
    color: #ff4d6d;
    text-shadow: 0 1px 2px rgba(0,0,0,0.18);
    pointer-events: none;
    transform: translate(calc(-50% + var(--dx, 0px)), 0) scale(0);
    animation: duck-heart-rise 1.4s ease-out forwards;
    z-index: 9999;
    will-change: transform, opacity;
  }
  @keyframes duck-heart-rise {
    0%   { opacity: 0; transform: translate(calc(-50% + var(--dx, 0px)), 0)    scale(0.4); }
    15%  { opacity: 1; transform: translate(calc(-50% + var(--dx, 0px)), -6px) scale(calc(var(--s, 1) * 1.15)); }
    100% { opacity: 0; transform: translate(calc(-50% + var(--dx, 0px)), -90px) scale(calc(var(--s, 1) * 0.7)); }
  }

  /* Badge niveau / score */
  .duck-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 4px 8px;
    background: rgba(20, 20, 30, 0.86);
    color: #fff;
    border-radius: 10px;
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    font-weight: 700;
    pointer-events: none;
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.15s ease, transform 0.15s ease;
    white-space: nowrap;
    z-index: 5;
  }
  .duck-container:hover .duck-badge,
  .duck-badge.show {
    opacity: 1;
    transform: translateY(0);
  }
  .duck-badge-level {
    font-size: 11px;
    color: #ffd66b;
    font-family: 'Press Start 2P', monospace;
  }

  /* ─── Bulle de question ─── */
  .duck-bubble {
    position: fixed;
    width: 240px;
    background: #ffffff;
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 12px;
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    line-height: 1.4;
    color: var(--ink);
    z-index: 9991;
  }
  .duck-bubble-hidden { display: none; }

  .duck-bubble-category {
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    background: var(--lavender);
    color: var(--ink);
    display: inline-block;
    padding: 4px 8px 3px;
    border: 2px solid var(--ink);
    margin-bottom: 8px;
  }
  .duck-bubble-question {
    font-weight: 700;
    font-size: 12.5px;
    margin-bottom: 10px;
  }
  .duck-bubble-answers {
    display: flex;
    flex-direction: column;
    gap: 5px;
  }
  .duck-answer-btn {
    text-align: left;
    background: #fff;
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    padding: 7px 10px;
    font-size: 11.5px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    color: var(--ink);
    cursor: pointer;
    transition: transform 0.08s, box-shadow 0.08s, background 0.15s;
  }
  .duck-answer-btn:hover:not(:disabled) {
    background: var(--yellow);
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--ink);
  }
  .duck-answer-btn.correct {
    background: var(--lime);
    border-color: var(--ink);
  }
  .duck-answer-btn.wrong {
    background: var(--pink-d);
    border-color: var(--ink);
  }
  .duck-answer-btn:disabled { cursor: default; }

  .duck-bubble-close {
    position: absolute;
    top: -10px; right: -10px;
    background: var(--ink);
    color: #fff;
    border: 2px solid var(--ink);
    width: 24px; height: 24px;
    border-radius: 50%;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    cursor: pointer;
    line-height: 1;
  }

  /* ─── Page CANARD : preview & settings ─── */
  .duck-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
  .duck-settings-card { padding: 22px; }
  .duck-h {
    font-family: 'Press Start 2P', monospace;
    font-size: 13px;
    margin: 0 0 12px;
  }
  .duck-help {
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    font-style: italic;
    margin-bottom: 14px;
    line-height: 1.4;
  }

  /* Preview du sprite réel */
  .duck-preview-big {
    width: 180px; height: 180px;
    background: var(--paper);
    border: 3px solid var(--ink);
    box-shadow: 6px 6px 0 var(--ink);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 14px;
  }
  #duck-preview-img {
    width: 160px; height: 160px;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.22));
    animation: duck-breathe 3.2s ease-in-out infinite;
  }
  .duck-preview-label {
    font-family: 'Press Start 2P', monospace;
    font-size: 13px;
    text-align: center;
    margin-bottom: 14px;
  }
  .duck-preview-actions { text-align: center; }

  /* Sélecteur de niveau (carrousel de sprites) */
  .duck-level-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 14px;
  }
  .duck-level-card {
    background: #fff;
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    padding: 10px 6px;
    cursor: pointer;
    font-family: 'Space Mono', monospace;
    text-align: center;
    transition: transform 0.08s, box-shadow 0.08s;
  }
  .duck-level-card:hover:not(.locked) {
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--ink);
  }
  .duck-level-card.on { background: var(--yellow); }
  .duck-level-card.locked { opacity: 0.45; cursor: not-allowed; }
  .duck-level-mini-img {
    width: 60px; height: 60px;
    object-fit: contain;
    margin: 0 auto 4px;
    display: block;
  }
  .duck-level-lbl {
    font-size: 9px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 4px;
  }
  .duck-level-thresh {
    font-family: 'Press Start 2P', monospace;
    font-size: 8px;
  }

  /* Boutons size / interval */
  .duck-size-row, .duck-interval-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }
  .duck-size-btn.on, .duck-interval-btn.on { background: var(--yellow); }

  /* Toggle + actions */
  .duck-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    margin-top: 10px;
  }
  .duck-toggle input { width: 18px; height: 18px; cursor: pointer; }
  .duck-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
  }
  .duck-tips { list-style: none; padding: 0; margin: 0; }
  .duck-tips li {
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    padding: 5px 0 5px 20px;
    position: relative;
    line-height: 1.5;
  }
  .duck-tips li::before {
    content: '🦆';
    position: absolute;
    left: 0; top: 5px;
    font-size: 12px;
  }

  @media (max-width: 760px) {
    .duck-settings-grid { grid-template-columns: 1fr; }
    .duck-level-row { grid-template-columns: repeat(2, 1fr); }
    .duck-bubble { width: calc(100vw - 28px); left: 14px !important; max-width: 320px; }
    .duck-container { bottom: 80px; right: 14px; }
  }

  /* ─── Bouton SUPPRIMER (poubelle) sur les flashcards ─── */
  .session-card { position: relative; }
  .card-delete-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 28px;
    height: 28px;
    background: transparent;
    border: 2px solid var(--ink);
    border-radius: 0;
    color: var(--ink);
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.35;
    transition: opacity 0.15s, background 0.15s, transform 0.1s;
    z-index: 3;
  }
  .card-delete-btn:hover {
    opacity: 1;
    background: var(--pink-d);
    color: var(--ink);
  }
  .card-delete-btn:active {
    transform: scale(0.92);
  }
  .card-delete-btn svg {
    pointer-events: none;
  }

  /* Toast de confirmation suppression */
  .card-delete-toast {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(-30px);
    background: var(--pink-d);
    color: var(--ink);
    border: 3px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 10px 18px;
    font-family: 'Press Start 2P', monospace;
    font-size: 11px;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.2s, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
  }
  .card-delete-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }

  /* ─── KEYWORDS dans les réponses (Wikipedia popover) ─── */
  .kw {
    background: rgba(10, 10, 10, 0.06);
    border-bottom: 2px dotted var(--ink);
    cursor: help;
    padding: 0 2px;
    transition: background 0.12s;
    border-radius: 2px;
  }
  .kw:hover {
    background: var(--yellow);
  }

  /* Popover Wikipedia / recherche */
  .kw-popover {
    position: fixed;
    background: #fff;
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 12px;
    z-index: 9995;
    min-width: 200px;
    max-width: 280px;
    font-family: 'Space Mono', monospace;
    animation: kw-pop-in 0.15s ease-out;
  }
  @keyframes kw-pop-in {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
  }
  .kw-pop-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 11px;
    line-height: 1.3;
    margin-bottom: 10px;
    color: var(--ink);
    border-bottom: 2px dashed var(--ink);
    padding-bottom: 6px;
  }
  .kw-pop-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }
  .kw-pop-btn {
    background: #fff;
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    padding: 7px 10px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 12px;
    text-decoration: none;
    color: var(--ink);
    text-align: center;
    cursor: pointer;
    transition: transform 0.08s, box-shadow 0.08s, background 0.15s;
  }
  .kw-pop-btn:hover {
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--ink);
  }
  .kw-pop-wiki { background: var(--lime); }
  .kw-pop-search { background: var(--mint); }

  /* ─── Page CANARD : hero card desktop ─── */
  .duck-hero-card {
    padding: 30px;
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 30px;
    align-items: center;
    margin-bottom: 24px;
    background: var(--yellow);
  }
  .duck-hero-img {
    width: 180px;
    height: 180px;
    background: var(--paper);
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .duck-hero-img img {
    width: 160px;
    height: 160px;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.22));
    animation: duck-breathe 3.2s ease-in-out infinite;
  }
  .duck-hero-text h3 {
    font-family: 'Press Start 2P', monospace;
    font-size: 18px;
    line-height: 1.3;
    margin: 0 0 14px;
  }
  .duck-hero-text p {
    font-family: 'Space Mono', monospace;
    font-size: 14px;
    line-height: 1.6;
  }
  @media (max-width: 700px) {
    .duck-hero-card {
      grid-template-columns: 1fr;
      text-align: center;
    }
    .duck-hero-img {
      margin: 0 auto;
    }
    .duck-hero-text h3 { font-size: 14px; }
  }
  code {
    font-family: 'Space Mono', monospace;
    background: var(--ink);
    color: #fff;
    padding: 2px 6px;
    font-size: 12px;
  }

  /* ─── Banner launch desktop duck ─── */
  .duck-launch-banner {
    background: var(--yellow);
    border: 4px solid var(--ink);
    box-shadow: 8px 8px 0 var(--pink-d);
    padding: 26px 28px;
    margin-bottom: 26px;
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 24px;
    align-items: center;
  }
  .duck-launch-icon {
    width: 140px; height: 140px;
    background: var(--paper);
    border: 3px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .duck-launch-icon img {
    width: 120px; height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.22));
    animation: duck-breathe 3.2s ease-in-out infinite;
  }
  .duck-launch-body h3 {
    font-family: 'Press Start 2P', monospace;
    font-size: 16px;
    line-height: 1.3;
    margin: 0 0 8px;
  }
  .duck-launch-sub {
    font-family: 'Space Mono', monospace;
    font-style: italic;
    font-size: 13px;
    margin-bottom: 14px;
  }
  #btn-launch-desktop-duck {
    background: var(--ink);
    color: #fff;
    border-color: var(--ink);
    box-shadow: 5px 5px 0 var(--pink-d);
  }
  #btn-launch-desktop-duck:hover {
    box-shadow: 2px 2px 0 var(--pink-d);
  }
  .duck-launch-hint {
    margin-top: 12px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.6);
    border: 2px dashed var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    line-height: 1.5;
  }

  @media (max-width: 700px) {
    .duck-launch-banner { grid-template-columns: 1fr; text-align: center; }
    .duck-launch-icon { margin: 0 auto; }
    .duck-launch-body h3 { font-size: 13px; }
  }

  /* État "ouverture demandée" */
  #btn-launch-desktop-duck.duck-launching,
  #btn-launch-desktop-duck.duck-launched {
    background: var(--lime);
    color: var(--ink);
    box-shadow: 3px 3px 0 var(--ink);
  }
  #btn-launch-desktop-duck.duck-launching:hover,
  #btn-launch-desktop-duck.duck-launched:hover {
    box-shadow: 1px 1px 0 var(--ink);
  }

  /* ─── Input nom du canard ─── */
  .duck-name-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    flex-wrap: wrap;
  }
  .duck-name-label {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 13px;
    color: var(--ink);
  }
  .duck-name-input {
    flex: 1;
    min-width: 140px;
    background: var(--paper);
    border: 2px solid var(--ink);
    box-shadow: 2px 2px 0 var(--ink);
    padding: 8px 10px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 14px;
    color: var(--ink);
    outline: none;
  }
  .duck-name-input:focus {
    background: #fff;
    box-shadow: 3px 3px 0 var(--ink);
  }

/* ===== BOUTIQUE MOCK — style CULTURE!!! brutaliste ===== */

/* Lien dans la nav */
.nav-shop-link {
  background: var(--yellow);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 4px 10px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
}
.nav-shop-link:hover {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0 var(--ink);
  border-bottom-color: var(--ink) !important;
}

/* Backdrop + modal */
.mock-modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(10, 10, 10, 0.55);
  z-index: 9999;
  display: flex; align-items: flex-start; justify-content: center;
  padding: 40px 20px;
  overflow-y: auto;
  animation: mock-fade-in 0.18s ease;
}
@keyframes mock-fade-in { from { opacity: 0; } to { opacity: 1; } }

.mock-modal {
  background: var(--paper);
  width: min(960px, 100%);
  padding: 24px 28px 32px;
  position: relative;
  margin: 0 auto;
}

.mock-close {
  position: absolute; top: 10px; right: 14px;
  background: var(--ink); color: #fff;
  border: 2px solid var(--ink);
  width: 36px; height: 36px;
  font-size: 22px; font-weight: 700;
  cursor: pointer;
  box-shadow: 3px 3px 0 #777;
  font-family: inherit;
}
.mock-close:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 #777; }

.mock-header { display: flex; gap: 18px; align-items: center; margin-bottom: 18px; padding-right: 50px; }
.mock-big-duck { font-size: 48px; line-height: 1; }
.mock-title { font-family: 'Press Start 2P', system-ui, monospace; font-size: 18px; margin: 0 0 6px; letter-spacing: 0.02em; }
.mock-sub { margin: 0; font-size: 13px; color: #444; }

/* Tabs */
.mock-tabs {
  display: flex; flex-wrap: wrap; gap: 8px;
  border-bottom: 3px solid var(--ink);
  padding-bottom: 14px; margin-bottom: 18px;
}
.mock-tab {
  background: var(--paper);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 8px 12px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
  cursor: pointer;
  color: var(--ink);
}
.mock-tab:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--ink); }
.mock-tab.on { background: var(--ink); color: var(--paper); }

.mock-tab-content { padding-top: 4px; }

/* Headings & meta */
.mock-h {
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 14px;
  margin: 0 0 8px;
  letter-spacing: 0.02em;
}
.mock-muted { color: #555; font-size: 13px; margin: 0 0 16px; }
.mock-label {
  display: block;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  letter-spacing: 0.06em;
  margin: 12px 0 6px;
}
.mock-input, .mock-textarea {
  width: 100%; box-sizing: border-box;
  background: var(--paper);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 9px 11px;
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  color: var(--ink);
  outline: none;
}
.mock-input:focus, .mock-textarea:focus { background: #fff; box-shadow: 4px 4px 0 var(--ink); }
.mock-textarea { min-height: 120px; resize: vertical; }
.mock-row-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
@media (max-width: 640px) { .mock-row-3 { grid-template-columns: 1fr; } }
.mock-cta { margin-top: 16px; }

/* Grille de skins */
.mock-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
}
.mock-card {
  background: var(--paper);
  padding: 14px;
  text-align: center;
}
.mock-card.is-equipped { background: var(--yellow); }
.mock-skin-emoji { font-size: 42px; line-height: 1; margin-bottom: 8px; }
.mock-card-title { font-family: 'Press Start 2P', system-ui, monospace; font-size: 11px; margin: 4px 0 6px; letter-spacing: 0.02em; }
.mock-card-desc { font-size: 12px; color: #444; margin: 0 0 10px; min-height: 36px; }
.mock-card-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 12px; }
.mock-badge {
  display: inline-block;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 8px;
  border: 1.5px solid var(--ink);
  padding: 3px 6px;
  background: #fff;
  letter-spacing: 0.04em;
}
.mock-badge.rarity-gratuit { background: #d6f5dc; }
.mock-badge.rarity-commun  { background: #e3eafc; }
.mock-badge.rarity-rare    { background: #fff0b3; }
.mock-badge.rarity-premium { background: #f7c8d8; }

/* Donation */
.mock-donate-row {
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-bottom: 18px;
}
.mock-box {
  background: #fff;
  padding: 12px 14px;
  font-size: 13px;
}

/* Premium */
.mock-price { background: var(--paper); padding: 18px; max-width: 420px; }
.mock-big-price { font-family: 'Press Start 2P', system-ui, monospace; font-size: 18px; margin: 6px 0 12px; }
.mock-perks { margin: 0 0 16px 18px; padding: 0; font-size: 13px; line-height: 1.6; }

/* Résultats AI / Document */
.mock-result { margin-top: 14px; }
.mock-loading {
  background: var(--yellow);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 14px;
  font-size: 13px;
  text-align: center;
}
.mock-pack-preview { background: #fff; padding: 16px; margin-top: 10px; }
.mock-flashcard {
  background: var(--paper);
  border: 2px solid var(--ink);
  padding: 10px 12px;
  margin: 8px 0;
  font-size: 13px;
}
.mock-flashcard p { margin: 6px 0; }
.mock-flashcard small { color: #666; font-style: italic; }
.mock-upload {
  background: #fff;
  padding: 16px;
  margin-bottom: 14px;
  text-align: center;
}
.mock-upload input[type="file"] {
  margin-top: 8px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
}

/* Paywall */
.mock-paywall { background: var(--yellow); padding: 16px; }

/* Toast */
.mock-toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%);
  background: var(--ink); color: var(--paper);
  border: 2px solid var(--ink);
  box-shadow: 4px 4px 0 var(--yellow);
  padding: 12px 18px;
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  z-index: 10000;
  animation: mock-toast-in 0.2s ease;
}
@keyframes mock-toast-in {
  from { opacity: 0; transform: translate(-50%, 14px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

/* ===== SOCIAL ===== */

/* ===== PREMIUM ===== */

.premium-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(190px, 260px);
  gap: 22px;
  align-items: center;
  background: var(--paper);
  padding: 24px;
  margin-bottom: 24px;
}
.premium-kicker {
  display: inline-block;
  background: var(--mint);
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  padding: 5px 9px 4px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
  margin-bottom: 12px;
}
.premium-hero h3,
.premium-feedback h3 {
  margin: 0 0 10px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 18px;
  line-height: 1.35;
}
.premium-hero p,
.premium-card p,
.premium-feedback p {
  margin: 0;
  font-family: 'Space Mono', monospace;
  font-size: 14px;
  line-height: 1.55;
}
.premium-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}
.premium-card {
  background: #fff;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 330px;
}
.premium-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
.premium-icon {
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--lavender);
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  font-size: 26px;
}
.premium-badge {
  background: var(--pink-d);
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  padding: 5px 8px 4px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 8px;
  white-space: nowrap;
}
.premium-card h3 {
  margin: 0;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 13px;
  line-height: 1.4;
}
.premium-card .btn {
  margin-top: auto;
  justify-content: center;
}
.premium-feedback {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(320px, 1.2fr);
  gap: 24px;
  align-items: start;
  background: var(--paper);
  padding: 24px;
  margin-bottom: 56px;
}
.premium-feedback-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.premium-choice-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.premium-choice {
  background: #fff;
  color: var(--ink);
  border: 3px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 11px 10px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}
.premium-choice:hover {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0 var(--ink);
}
.premium-choice.on {
  background: var(--yellow);
  transform: none;
  box-shadow: 4px 4px 0 var(--ink);
}
.premium-feedback-textarea {
  min-height: 110px;
  resize: vertical;
}
.premium-feedback-status {
  min-height: 18px;
  margin: 0;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  font-weight: 700;
}
.premium-feedback-status.is-error { color: #b42318; }
.premium-feedback-status a {
  color: inherit;
  text-decoration: underline;
}

@media (max-width: 900px) {
  .premium-grid { grid-template-columns: 1fr; }
  .premium-card { min-height: 0; }
  .premium-feedback,
  .premium-hero { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .premium-hero,
  .premium-card,
  .premium-feedback {
    padding: 16px;
  }
  .premium-hero h3,
  .premium-feedback h3 {
    font-size: 14px;
  }
  .premium-choice-row {
    grid-template-columns: 1fr;
  }
}

.social-tabs {
  display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px;
}
.social-tab {
  background: var(--paper);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 8px 12px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
  cursor: pointer;
  color: var(--ink);
}
.social-tab:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--ink); }
.social-tab.on { background: var(--ink); color: var(--paper); }

.social-content { padding-top: 4px; }
.social-board { background: var(--paper); padding: 18px 20px; }
.social-board-header {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
  margin-bottom: 12px;
}
.social-h { font-family: 'Press Start 2P', system-ui, monospace; font-size: 12px; letter-spacing: 0.02em; }
.social-board-sub { font-size: 13px; color: #444; margin: 6px 0 14px; }
.social-me-rank { font-size: 13px; }
.social-secure-note {
  background: #fff;
  border: 2px dashed var(--ink);
  padding: 10px 12px;
  margin: 0 0 14px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  line-height: 1.45;
}
.social-name-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: #fff;
  border: 2px solid var(--ink);
  padding: 10px 12px;
  margin-bottom: 14px;
}
.social-name-row label { font-size: 12px; font-weight: 700; }
.social-name-row input { flex: 1; min-width: 140px; }
.social-pack-select { max-width: 320px; }

/* ===== COMPTE ===== */

.account-content {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 22px;
  align-items: start;
  margin-bottom: 56px;
}
.account-panel {
  padding: 24px;
  background: var(--paper);
}
.account-kicker {
  display: inline-block;
  background: var(--mint);
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  padding: 4px 8px 3px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  margin-bottom: 12px;
}
.account-title {
  margin: 0 0 10px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 16px;
  line-height: 1.35;
}
.account-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}
.account-tab {
  background: #fff;
  color: var(--ink);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 8px 10px;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 9px;
  cursor: pointer;
}
.account-tab.on {
  background: var(--yellow);
}
.account-text {
  margin: 0 0 12px;
  max-width: 700px;
  font-size: 14px;
  line-height: 1.55;
}
.account-google-btn {
  width: 100%;
  max-width: 520px;
  justify-content: center;
  margin-top: 8px;
}
.account-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 520px;
  margin: 18px 0 2px;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}
.account-divider::before,
.account-divider::after {
  content: "";
  flex: 1;
  height: 2px;
  background: var(--ink);
}
.account-form {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 18px;
}
.account-form-stack {
  flex-direction: column;
  align-items: stretch;
  max-width: 520px;
}
.account-input {
  flex: 1;
  min-width: 220px;
  border: 3px solid var(--ink);
  background: #fff;
  color: var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 12px 14px;
  font-family: 'Space Mono', monospace;
  font-size: 14px;
}
.account-input:focus {
  outline: none;
  background: var(--yellow);
}
.account-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}
.account-main-actions .btn {
  min-height: 56px;
}
.account-profile-card {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 16px;
}
.account-profile-card > div {
  border: 2px solid var(--ink);
  background: #fff;
  box-shadow: 3px 3px 0 var(--ink);
  padding: 10px 12px;
}
.account-profile-card span {
  display: block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.account-profile-card strong {
  display: block;
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.account-profile-form {
  border-top: 2px solid var(--ink);
  margin-top: 16px;
  padding-top: 18px;
}
.account-secondary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 14px;
}
.account-local-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 520px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 2px solid var(--ink);
}
.account-link-btn {
  border: 0;
  background: transparent;
  color: var(--ink);
  padding: 0;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}
.account-link-btn[disabled] {
  opacity: 0.5;
  cursor: wait;
}
.account-password-update {
  border-top: 2px solid var(--ink);
  margin-top: 20px;
  padding-top: 18px;
}
.account-status {
  min-height: 20px;
  margin-top: 14px;
  font-size: 12px;
  font-weight: 700;
}
.account-details {
  border-top: 2px solid var(--ink);
  margin-top: 18px;
  padding-top: 14px;
}
.account-details summary {
  cursor: pointer;
  list-style: none;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 10px;
  line-height: 1.35;
}
.account-details summary::-webkit-details-marker {
  display: none;
}
.account-details summary::before {
  content: "▶";
  display: inline-block;
  margin-right: 8px;
}
.account-details[open] summary::before {
  transform: rotate(90deg);
}
.account-details-text {
  margin-top: 14px;
}
.account-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.account-stats > div {
  background: #fff;
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  padding: 16px 14px;
  min-height: 96px;
}
.account-stats strong {
  display: block;
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 20px;
  line-height: 1;
  margin-bottom: 10px;
}
.account-stats span {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.25;
}
.btn[disabled] {
  opacity: 0.55;
  cursor: wait;
}

/* Lignes du scoreboard */
.scoreboard { display: flex; flex-direction: column; gap: 4px; }
.sb-row {
  display: grid;
  grid-template-columns: 56px 40px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: #fff;
  border: 2px solid var(--ink);
  font-size: 14px;
}
.sb-row.me {
  background: var(--yellow);
  box-shadow: 3px 3px 0 var(--ink);
}
.sb-rank { font-family: 'Press Start 2P', system-ui, monospace; font-size: 11px; }
.sb-avatar { font-size: 22px; line-height: 1; text-align: center; }
.sb-name { font-weight: 700; }
.sb-score { font-family: 'Press Start 2P', system-ui, monospace; font-size: 10px; letter-spacing: 0.04em; }

/* Empty state */
.social-empty {
  background: var(--paper);
  padding: 20px;
  text-align: center;
  font-size: 14px;
}

/* Paquets publics */
.steal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 8px;
}
.steal-card {
  background: #fff;
  padding: 14px;
  text-align: center;
}
.steal-emoji { font-size: 42px; line-height: 1; margin-bottom: 6px; }
.steal-meta {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; color: #555;
  margin-bottom: 10px;
}
.steal-author { font-style: italic; }
.social-modal-inner { max-width: 540px; }

/* ===== PACK CREATOR ===== */
.pack-modal-wide { max-width: 720px; }
.pc-row-2 { display: grid; grid-template-columns: 80px 1fr; gap: 12px; }
.pc-icon-input { max-width: 120px; }
@media (max-width: 480px) { .pc-row-2 { grid-template-columns: 1fr; } }

.pc-visibility-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 8px 0 16px;
}
.pc-visibility-option {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 10px;
  align-items: start;
  background: #fff;
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 12px;
  cursor: pointer;
}
.pc-visibility-option input {
  margin: 3px 0 0;
  accent-color: var(--ink);
}
.pc-visibility-title {
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  line-height: 1.25;
}
.pc-visibility-sub {
  grid-column: 2;
  color: #444;
  font-size: 12px;
  line-height: 1.35;
}
.pc-visibility-option:has(input:checked) {
  background: var(--yellow);
}
.pc-safety-note {
  margin: -6px 0 16px;
  color: #444;
  font-size: 13px;
  line-height: 1.35;
}
@media (max-width: 560px) { .pc-visibility-row { grid-template-columns: 1fr; } }

.pc-cards { display: flex; flex-direction: column; gap: 12px; margin: 10px 0 14px; }
.pc-card { background: #fff; padding: 12px; position: relative; }
.pc-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.pc-card-head strong {
  font-family: 'Press Start 2P', system-ui, monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
}
.pc-del {
  background: var(--ink); color: #fff;
  border: 2px solid var(--ink);
  width: 28px; height: 28px;
  font-size: 14px; cursor: pointer; font-weight: 700;
  box-shadow: 2px 2px 0 #999;
}
.pc-del:hover { transform: translate(1px, 1px); box-shadow: 1px 1px 0 #999; }
.pc-hr { border: 0; border-top: 2px dashed var(--ink); margin: 18px 0 10px; }
.pc-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 16px; }

/* Extras list */
.extras-item {
  background: var(--paper);
  padding: 10px 12px;
  margin-bottom: 8px;
  position: relative;
  padding-right: 44px;
}
.extras-item .pc-del { position: absolute; top: 10px; right: 10px; }
.extras-back { font-size: 13px; color: #444; margin-top: 2px; }
.extras-memo { font-size: 12px; color: #777; font-style: italic; margin-top: 4px; }

.session-topbar {
  display: flex; justify-content: space-between; align-items: center;
  gap: 10px; flex-wrap: wrap;
}

/* ===== BARRE DE RECHERCHE (page TROUVER) ===== */
.search-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 18px 0 12px;
}
.search-input {
  flex: 1;
  background: var(--paper);
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  padding: 12px 16px;
  font-family: 'Space Mono', monospace;
  font-weight: 700;
  font-size: 15px;
  color: var(--ink);
  outline: none;
}
.search-input:focus {
  background: #fff;
  box-shadow: 5px 5px 0 var(--ink);
}
.search-input::placeholder {
  color: #777;
  font-weight: 400;
}
.search-clear {
  background: var(--ink);
  color: var(--paper);
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--yellow);
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}
.search-clear:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--yellow);
}

.trouver-empty {
  grid-column: 1 / -1;
  padding: 34px;
  text-align: center;
}
.trouver-empty h3 {
  font-size: 16px;
  margin: 0 0 14px;
}
.trouver-empty p {
  font-size: 14px;
  line-height: 1.55;
  margin: 0 auto 18px;
  max-width: 560px;
}
.trouver-empty-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===== INSTALL DUCK APP : DOWNLOAD + HELP ===== */
.duck-launch-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 6px;
}
#btn-download-desktop-duck {
  background: var(--mint);
  text-decoration: none;
  display: inline-flex; align-items: center; gap: 10px;
}
#btn-download-desktop-duck:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--ink);
}

.duck-install-help {
  margin-top: 14px;
  background: var(--paper);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 10px 14px;
}
.duck-install-help summary {
  cursor: pointer;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  padding: 2px 0;
  user-select: none;
}
.duck-install-help summary:hover { color: var(--pink-d); }
.duck-install-steps {
  margin: 10px 0 4px 18px;
  padding: 0;
  font-size: 13px;
  line-height: 1.6;
  font-family: 'Space Mono', monospace;
}
.duck-install-steps li { margin-bottom: 6px; }
.duck-install-steps code {
  background: #fff;
  border: 1.5px solid var(--ink);
  padding: 1px 6px;
  font-size: 12px;
}
.duck-install-note {
  display: block;
  font-size: 11px;
  color: #666;
  font-style: italic;
  margin-top: 4px;
}

/* ===== DOWNLOAD ROW : 3 plateformes ===== */
.duck-download-row {
  margin-top: 20px;
  padding: 14px 16px;
  background: var(--mint);
  border: 3px solid var(--ink);
  box-shadow: 5px 5px 0 var(--ink);
}
.duck-download-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  margin-bottom: 12px;
}
.duck-download-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
}
.duck-dl-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: #fff;
  text-decoration: none;
  text-transform: none;
  letter-spacing: 0;
  font-size: 12px;
  text-align: left;
}
.duck-dl-btn::before { display: none; } /* enlève le triangle play */
.duck-dl-emoji {
  font-size: 26px;
  line-height: 1;
}
.duck-dl-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.duck-dl-info strong {
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.duck-dl-info small {
  font-size: 11px;
  color: #555;
  text-transform: none;
  letter-spacing: 0;
}

.duck-install-os { margin-top: 12px; }
.duck-install-os strong {
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  display: block;
  margin-top: 8px;
  margin-bottom: 4px;
}

/* ===== PWA INSTALL BUTTON (Android/Chrome/Edge) ===== */
.pwa-install-btn {
  position: fixed;
  bottom: 18px;
  right: 18px;
  z-index: 9999;
  background: var(--yellow);
  color: var(--ink);
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  padding: 12px 16px;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  cursor: pointer;
  animation: pwa-install-pulse 2s ease-in-out infinite;
}
.pwa-install-btn:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--ink);
  animation: none;
}
@keyframes pwa-install-pulse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* ===== PWA INSTALL MODAL ===== */
.pwa-modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(10, 10, 10, 0.6);
  z-index: 10000;
  display: flex; align-items: flex-start; justify-content: center;
  padding: 40px 16px;
  overflow-y: auto;
  animation: pwa-fade-in 0.18s ease;
}
@keyframes pwa-fade-in { from { opacity: 0; } to { opacity: 1; } }

.pwa-modal {
  background: var(--paper);
  width: min(560px, 100%);
  padding: 22px 24px 26px;
  position: relative;
}
.pwa-modal-close {
  position: absolute; top: 10px; right: 14px;
  background: var(--ink); color: #fff;
  border: 2px solid var(--ink);
  width: 36px; height: 36px;
  font-size: 22px; font-weight: 700;
  cursor: pointer;
  box-shadow: 3px 3px 0 #777;
  font-family: inherit;
}
.pwa-modal-close:hover { transform: translate(1px, 1px); box-shadow: 2px 2px 0 #777; }

.pwa-modal-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 14px;
  letter-spacing: 0.02em;
  margin: 0 50px 8px 0;
}
.pwa-modal-sub {
  margin: 0 0 18px;
  font-size: 13px;
  color: #444;
}

.pwa-section {
  background: #fff;
  border: 2px solid var(--ink);
  padding: 12px 14px;
  margin-bottom: 12px;
}
.pwa-section.pwa-section-active {
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--ink);
}
.pwa-section h3 {
  font-family: 'Press Start 2P', monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
  margin: 0 0 10px;
}
.pwa-section ol {
  margin: 0 0 8px 18px;
  padding: 0;
  font-size: 13.5px;
  line-height: 1.55;
  font-family: 'Space Mono', monospace;
}
.pwa-section ol li { margin-bottom: 4px; }
.pwa-section .pwa-warn {
  font-size: 12px;
  font-style: italic;
  color: #6a3a00;
  margin: 8px 0 0;
}
.pwa-ios-share-icon {
  display: inline-block;
  font-size: 18px;
  vertical-align: -2px;
  margin: 0 2px;
}
.pwa-modal-foot {
  font-size: 12.5px;
  color: #555;
  margin: 14px 0 0;
  font-style: italic;
}

/* ===== COMING SOON FEATURE CARDS ===== */
.coming-soon-card {
  background: var(--paper);
  border: 3px solid var(--ink);
  box-shadow: 6px 6px 0 var(--ink);
  padding: 22px 24px;
  position: relative;
}
.coming-tag {
  position: absolute;
  top: -14px; right: 18px;
  background: var(--pink-d);
  color: var(--ink);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 6px 12px 5px;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
}
.coming-example {
  background: #fff;
  border: 2px solid var(--ink);
  padding: 10px 12px;
  margin: 14px 0;
  font-size: 13px;
  line-height: 1.5;
}
.coming-cta-line {
  margin: 14px 0 10px;
  font-size: 14px;
}

/* ===== FEEDBACK SURVEY MODAL ===== */
.fb-modal-inner {
  max-width: 580px;
  padding: 22px 26px 24px;
}
.fb-coming-tag {
  display: inline-block;
  background: var(--pink-d);
  color: var(--ink);
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  padding: 4px 10px 3px;
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
  margin-bottom: 10px;
}
.fb-divider {
  height: 3px;
  background: var(--ink);
  margin: 16px 0 14px;
}
.fb-intro {
  font-size: 14px;
  margin: 0 0 14px;
}
.fb-question { margin-bottom: 16px; }
.fb-label {
  display: block;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  margin-bottom: 8px;
}
.fb-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.fb-options-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}
.fb-options-vert {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.fb-options-vert .fb-opt {
  text-align: left;
  justify-content: flex-start;
}

.fb-opt {
  background: var(--paper);
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  padding: 9px 12px;
  font-family: 'Space Mono', monospace;
  font-weight: 700;
  font-size: 12.5px;
  color: var(--ink);
  cursor: pointer;
  transition: transform 0.08s, box-shadow 0.08s;
}
.fb-opt:hover {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0 var(--ink);
}
.fb-opt.on {
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--ink);
  transform: none;
}
.fb-textarea {
  min-height: 70px;
  resize: vertical;
}
.fb-actions {
  margin-top: 18px;
  display: flex;
  justify-content: flex-end;
}
.fb-submit { font-size: 13px; }
.fb-foot {
  margin: 14px 0 0;
  font-size: 12px;
  color: #555;
  font-style: italic;
}

/* ═════════════════════════════════════════════════════════
   VERSION MOBILE — quand l'écran ≤ 640px, le site se transforme
   en app : nav du haut cachée, barre d'onglets en bas, mise
   en page compactée style iOS.
   ═════════════════════════════════════════════════════════ */

/* Barre d'onglets bas — masquée par défaut (desktop) */
.mobile-tabs { display: none; }

@media (max-width: 640px) {
  /* Hide desktop top nav, show bottom tab bar */
  .nav { display: none !important; }
  .mobile-tabs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(56px, 1fr));
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: #fff;
    border-top: 3px solid var(--ink);
    box-shadow: 0 -4px 0 var(--ink);
    z-index: 100;
    padding-bottom: env(safe-area-inset-bottom, 0);
  }
  .mtab {
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    min-width: 0;
    padding: 8px 4px 10px;
    text-decoration: none;
    color: var(--ink);
    border: 2px solid transparent;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 9px;
    letter-spacing: 0.05em;
    transition: background 0.1s;
  }
  .mtab-label {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .mtab.active {
    background: var(--yellow);
    border-color: var(--ink);
    box-shadow: inset 0 2px 0 var(--ink);
  }
  .mtab-icon {
    font-size: 20px;
    line-height: 1;
    margin-bottom: 4px;
  }

  /* Body padding pour pas que le contenu soit caché par la barre */
  body { padding-bottom: 70px; }

  /* Container : padding réduit */
  .container { padding: 0 14px; }

  /* Section banners : plus compacts */
  .section-banner { margin: 18px 0 12px; }
  .section-banner {
    flex-wrap: wrap;
  }
  .section-banner h2 {
    font-size: 14px;
    padding: 7px 10px 6px;
    box-shadow: 3px 3px 0 var(--ink);
    border-width: 2.5px;
  }
  .section-banner .bar { height: 3px; }
  .section-banner .fig { font-size: 9px; padding: 2px 6px; }
  .section-banner .btn {
    flex: 1 1 160px;
    justify-content: center;
  }

  /* Hero : tout en colonne, plus compact, masque le gros SVG */
  .hero { padding: 18px 0 14px; }
  .frame-thick {
    border-width: 3px;
    box-shadow: 5px 5px 0 var(--ink);
  }
  .masthead h1 { font-size: 36px; }
  .masthead { padding: 12px 14px 10px; }
  .deck-tagline { font-size: 13px; padding: 8px 14px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-left {
    padding: 16px 14px;
    border-right: none;
    border-bottom: 3px solid var(--ink);
  }
  .start-panel {
    padding: 14px;
    margin-bottom: 18px;
  }
  .start-title {
    font-size: 15px;
    line-height: 1.35;
    padding-right: 46px;
  }
  .start-copy {
    font-size: 12px;
  }
  .start-actions .btn-big {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
  .start-down {
    width: 36px;
    height: 36px;
    font-size: 15px;
    right: 10px;
    top: 10px;
  }
  .start-auth-nudge {
    align-items: stretch;
    flex-direction: column;
    font-size: 12px;
  }
  .hero-right { min-height: 260px; }
  .daily-visual-overlay {
    left: 12px;
    bottom: 42px;
    max-width: calc(100% - 24px);
    padding: 10px;
  }
  .daily-visual-title {
    font-size: 14px;
  }
  .daily-visual-kicker,
  .daily-visual-cta {
    font-size: 7px;
  }
  .daily-learning-slot {
    padding: 0 14px 18px;
  }
  .daily-learning-panel {
    margin-top: 14px;
    padding: 14px;
  }
  .daily-learning-head {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .daily-learning-close {
    justify-content: center;
  }
  .hero-eyebrow { font-size: 10px; }
  .daily-learning-title {
    font-size: 15px;
    line-height: 1.35;
  }
  .daily-learning-hook,
  .daily-learning-body {
    font-size: 12px;
  }
  .daily-learning-fact,
  .daily-resource-link,
  .daily-pack-count {
    font-size: 11px;
  }
  .daily-pack-box {
    padding: 12px;
  }
  .daily-pack-actions {
    width: 100%;
  }
  .daily-pack-actions .btn {
    flex: 1 1 100%;
    justify-content: center;
  }
  .hero-cta-row { gap: 8px; }
  .hero-cta-row .btn-big {
    flex: 1;
    padding: 12px 12px;
    font-size: 11px;
    justify-content: center;
  }

  /* Deck grid : 2 colonnes au lieu de 4 */
  .deck-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 12px;
  }
  .deck-grid.deck-grid-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .deck { box-shadow: 3px 3px 0 var(--ink); border-width: 2.5px; }
  .deck-body { padding: 8px 10px 10px; }
  .deck-title { font-size: 11px; line-height: 1.25; margin-bottom: 6px; }
  .deck-title.deck-title-long { font-size: 10px; }
  .deck-cat { font-size: 8px; }
  .deck-foot { font-size: 9px; }
  .deck-meta .seg { height: 5px; }

  /* Boutons : plus compacts */
  .btn { padding: 10px 12px; font-size: 11px; box-shadow: 3px 3px 0 var(--ink); border-width: 2.5px; }
  .btn-big { padding: 13px 14px; font-size: 12px; }

  /* Compte */
  .account-content { grid-template-columns: 1fr; gap: 14px; }
  .account-panel { padding: 18px 16px; }
  .account-title { font-size: 13px; }
  .account-form, .account-actions { align-items: stretch; }
  .account-input { min-width: 0; width: 100%; }
  .account-profile-card { grid-template-columns: 1fr; }
  .account-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .account-stats > div { min-height: 82px; padding: 13px 10px; }
  .account-stats strong { font-size: 16px; }
  .account-stats span { font-size: 10px; }

  /* Barre de recherche */
  .search-row { gap: 8px; margin: 14px 0 10px; }
  .search-input {
    padding: 10px 12px;
    font-size: 14px;
    box-shadow: 3px 3px 0 var(--ink);
    border-width: 2.5px;
  }

  /* Filter bar : scroll horizontal compact */
  .filter-bar { overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .filter-bar::-webkit-scrollbar { display: none; }

  /* Cache le bouton "shuffle" du banner Trouver si écran tout petit */
  .btn-shuffle { font-size: 10px; padding: 8px 10px; }

  /* Page CANARD : grid en colonne */
  .duck-settings-grid {
    grid-template-columns: 1fr !important;
    gap: 12px;
  }
  .duck-launch-banner {
    grid-template-columns: 1fr !important;
    text-align: center;
  }
  .duck-launch-icon img { width: 80px; }
  .duck-h { font-size: 12px; }

  /* Session flashcard : padding/fonts réduits */
  .session-card-text { font-size: 17px; }
  .session-card-answer { font-size: 15px; }

  /* Bouton PWA install : adapte sa position pour ne pas masquer la tab bar */
  .pwa-install-btn { bottom: 84px; }

  /* Boutique modal : adapté au petit écran */
  .mock-modal { padding: 18px 16px 22px; }
  .mock-modal-backdrop { padding: 20px 12px; }
  .mock-tabs { gap: 6px; padding-bottom: 10px; margin-bottom: 14px; }
  .mock-tab { padding: 6px 8px; font-size: 8px; }
  .mock-grid { grid-template-columns: 1fr 1fr; }

  /* Page Social : grid compact */
  .steal-grid { grid-template-columns: 1fr; }
  .scoreboard .sb-row { grid-template-columns: 44px 32px 1fr auto; padding: 7px 9px; font-size: 13px; }
  .sb-rank { font-size: 10px; }
  .sb-avatar { font-size: 19px; }
}

/* Très petits écrans (iPhone SE etc.) */
@media (max-width: 380px) {
  .masthead h1 { font-size: 28px; }
  .mtab-label { font-size: 8px; }
  .mtab-icon { font-size: 18px; }
  .deck-grid.deck-grid-compact { grid-template-columns: 1fr !important; }
  .deck-title { font-size: 10px; }
  .btn { padding: 9px 10px; font-size: 10px; }
}

/* ===== DUCK NOTIFICATIONS UI ===== */
.duck-notif-status {
  font-size: 13px;
  margin: 8px 0 12px;
}
.duck-notif-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.duck-notif-int-btn {
  flex: 1;
  min-width: 70px;
  padding: 9px 8px;
  font-size: 11px;
  justify-content: center;
}
.duck-notif-int-btn.on {
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--ink);
}
