/* ============================================================
   Oldy — site vitrine. L'app tourne DANS l'écran d'un vieil ordi
   pixel-art posé sur un bureau. Thème "coral". Palette reprise 1:1
   de oldy-app/theme/themes/index.ts.
   ============================================================ */
@font-face {
  font-family: 'VT323';
  src: url('assets/VT323-Regular.ttf') format('truetype');
  font-display: swap;
}

:root {
  /* Thème coral */
  --grad-top: #E8896E;  --grad-mid: #F0A98C;  --grad-bot: #F8D2B0;
  --win-body: #FCF6F0;  --win-border: #8A4434;
  --border-light: #F6D9C4; --border-dark: #8A4434;
  --title-from: #D86F52; --title-to: #F0A07E; --title-text: #FFFFFF;
  --btn-face: #F8E6D8; --btn-hi: #FFFFFF; --btn-sh: #D0A890; --btn-text: #44291E; --btn-pressed: #EED8C8;
  --text-primary: #44291E; --text-secondary: #76584A; --accent: #C85A3E;
  --tb-from: #D86F52; --tb-to: #F0A07E; --tb-border: #8A4434;
  --online: #5AAE8A; --away: #F2B84A; --offline: #B0998A;
  --pixel: 'VT323', 'Courier New', monospace;

  /* Position de l'écran DANS la NOUVELLE image (zone sombre mesurée
     37.62/21.46 → 63.48/59.13), RENTRÉE de ~2% (le cadre du CRT déborde sur
     l'OS) ; hauteur légèrement réduite → l'OS déborde d'1-2px, pas de ligne. */
  --scr-left: 38.14%; --scr-top: 22.2%; --scr-w: 24.83%; --scr-h: 36.1%;
  /* Résolution logique de l'OS ; hauteur calée sur le ratio du CRT (~0.819)
     pour remplir pile l'écran. Scale ajusté en JS. */
  --os-w: 1000px; --os-h: 819px; --os-scale: 0.4;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; }
body {
  font-family: var(--pixel);
  background: #1c1210;
  color: var(--text-primary);
  -webkit-font-smoothing: none;
  user-select: none; -webkit-user-select: none;
}
.hidden { display: none !important; }
img { -webkit-user-drag: none; user-drag: none; }

/* ============================================================
   Scène : l'ordi sur le bureau, centré, aussi grand que possible
   ============================================================ */
.stage {
  position: fixed; inset: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at center, #2a1a16 0%, #150d0b 100%);
}
.scene {
  position: relative; aspect-ratio: 16 / 9;
  /* COVER : au moins aussi grand que le viewport dans les 2 axes → pas de bandes
     (le surplus est rogné par overflow:hidden du .stage). */
  width: max(100vw, 177.78vh); height: auto;
  transform-origin: center center;
  transition: transform 0.85s cubic-bezier(.62,.03,.2,1);
  will-change: transform;
}
.scene-img { display: block; width: 100%; height: 100%; image-rendering: pixelated; }

/* L'écran du CRT (fenêtre de l'OS), positionné en % sur l'image */
.screen {
  position: absolute;
  left: var(--scr-left); top: var(--scr-top);
  width: var(--scr-w); height: var(--scr-h);
  overflow: hidden;
  background: #0f0a12;
  border-radius: 22px; /* épouse la courbure du CRT (scale avec le zoom) */
  box-shadow: inset 0 0 14px rgba(0,0,0,0.35);
}

/* L'OS : taille logique fixe, mis à l'échelle pour remplir l'écran */
.os {
  position: absolute; top: 0; left: 0;
  width: var(--os-w); height: var(--os-h);
  transform-origin: top left;
  transform: scale(var(--os-scale));
  overflow: hidden;
}

/* Reflet verre + vignette CRT (au-dessus de l'OS, non cliquable) */
.glass {
  position: absolute; inset: 0; pointer-events: none; z-index: 60; border-radius: inherit;
  background:
    radial-gradient(ellipse at 50% 34%, rgba(255,255,255,0.07) 0%, rgba(0,0,0,0) 46%),
    radial-gradient(ellipse at 50% 50%, rgba(0,0,0,0) 74%, rgba(0,0,0,0.18) 100%),
    repeating-linear-gradient(to bottom, rgba(0,0,0,0) 0 2px, rgba(0,0,0,0.035) 3px);
  /* Lèvre du bezel : le cadre plastique projette son ombre sur les bords de l'écran. */
  box-shadow: inset 0 0 0 2px rgba(26,12,9,0.55), inset 0 0 30px 7px rgba(8,4,8,0.6);
}

/* Invite hors écran */
.scene-hint {
  position: absolute; left: 50%; bottom: 15%; transform: translateX(-50%);
  color: #ffe6c8; font-family: var(--pixel); font-size: 26px; letter-spacing: 1px;
  text-shadow: 0 2px 6px rgba(0,0,0,0.7); pointer-events: none;
  animation: hintPulse 1.8s ease-in-out infinite; z-index: 30;
}
@keyframes hintPulse { 0%,100%{opacity:.55} 50%{opacity:1} }

/* Boutons flottants (reculer / son) */
.zoom-back, .mute-btn {
  position: fixed; z-index: 80; cursor: pointer;
  font-family: var(--pixel); font-size: 20px; color: #fff;
  background: rgba(0,0,0,0.4); border: 1px solid rgba(255,255,255,0.3);
  border-radius: 8px; padding: 8px 14px; backdrop-filter: blur(2px);
}
.zoom-back { left: 16px; top: 16px; }
.mute-btn { right: 16px; top: 16px; padding: 8px 12px; z-index: 2100; }
.zoom-back:hover, .mute-btn:hover { background: rgba(0,0,0,0.6); }

/* ============================================================
   OS — écran power
   ============================================================ */
.power-screen {
  position: absolute; inset: 0; z-index: 10;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at center, #14100f 0%, #0a0708 80%);
}
.power-btn {
  border: none; background: none; padding: 0; cursor: pointer;
  display: grid; place-items: center; gap: 10px;
  animation: pulseGlow 2.4s ease-in-out infinite; transition: transform 0.12s;
}
.power-btn:active { transform: scale(0.93); }
.power-label { color: #ffd089; font-size: 30px; letter-spacing: 2px; }
@keyframes pulseGlow {
  0%,100% { filter: drop-shadow(0 0 3px rgba(255,208,137,0.35)); }
  50%     { filter: drop-shadow(0 0 18px rgba(255,208,137,0.85)); }
}

/* ============================================================
   OS — boot
   ============================================================ */
.boot {
  position: absolute; inset: 0; z-index: 9;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, var(--grad-top), var(--grad-mid) 55%, var(--grad-bot));
}
.boot.fade-out { animation: bootFade 0.6s ease forwards; }
@keyframes bootFade { to { opacity: 0; } }
.boot-inner { text-align: center; }
.boot-logo { width: 120px; height: 120px; border-radius: 24px; box-shadow: 0 10px 30px rgba(0,0,0,0.35); animation: floaty 3s ease-in-out infinite; }
@keyframes floaty { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-8px)} }
.boot-name { color: #fff; font-size: 58px; letter-spacing: 3px; margin: 16px 0 28px; text-shadow: 0 3px 0 rgba(0,0,0,0.25); }
.boot-status { color: rgba(255,255,255,0.92); font-size: 24px; height: 28px; letter-spacing: 1px; }
.seg-bar { display: flex; gap: 4px; width: 300px; margin: 0 auto 20px; padding: 4px; border-radius: 6px; background: rgba(0,0,0,0.18); border: 1px solid rgba(255,255,255,0.35); }
.seg-bar > i { flex: 1; height: 18px; border-radius: 2px; background: rgba(255,255,255,0.18); transition: background 0.2s; }
.seg-bar > i.on { background: #fff; box-shadow: 0 0 8px rgba(255,255,255,0.6); }

/* ============================================================
   OS — bureau
   ============================================================ */
.desktop {
  position: absolute; inset: 0; z-index: 5;
  background: linear-gradient(160deg, var(--grad-top), var(--grad-mid) 55%, var(--grad-bot));
  background-image: url('assets/wallpaper_coral.png');
  background-size: cover; background-position: center;
  animation: dtIn 0.6s ease;
}
@keyframes dtIn { from { opacity: 0; } to { opacity: 1; } }

.icons { position: absolute; top: 20px; left: 20px; display: flex; flex-direction: column; gap: 22px; z-index: 12; }
.icon { width: 92px; text-align: center; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 6px 4px; border-radius: 8px; border: 1px solid transparent; }
.icon:hover { background: rgba(255,255,255,0.16); border-color: rgba(255,255,255,0.28); }
.icon.pulse { animation: iconPulse 1.8s ease-in-out infinite; }
@keyframes iconPulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.07)} }
.icon svg, .icon .glyph, .icon .pic { width: 50px; height: 50px; filter: drop-shadow(0 2px 3px rgba(0,0,0,0.3)); }
.pic { display: block; image-rendering: pixelated; }
.wt-icon { display: inline-flex; align-items: center; justify-content: center; }
.wt-icon .pic { width: 100%; height: 100%; }
.icon span { color: #fff; font-size: 19px; line-height: 1.05; text-shadow: 0 1px 2px rgba(0,0,0,0.6); }
.icon.trash { position: absolute; bottom: 80px; right: 24px; top: auto; }

.windows { position: absolute; inset: 0; z-index: 20; pointer-events: none; }
.win {
  position: absolute; pointer-events: auto;
  background: var(--win-body); border: 1px solid var(--win-border);
  border-radius: 8px; overflow: hidden;
  box-shadow: inset 1px 1px 0 var(--border-light), inset -1px -1px 0 var(--border-dark), 0 16px 40px rgba(43,58,90,0.35);
  display: flex; flex-direction: column; animation: winOpen 0.18s ease;
}
@keyframes winOpen { from { transform: scale(0.96); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.win-title { display: flex; align-items: center; gap: 8px; padding: 8px 9px; cursor: grab; background: linear-gradient(180deg, var(--title-from), var(--title-to)); color: var(--title-text); font-size: 20px; letter-spacing: 0.5px; }
.win-title .wt-icon { width: 20px; height: 20px; }
.win-title .wt-label { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.win-btns { display: flex; gap: 5px; }
.win-btns button { width: 22px; height: 22px; border-radius: 4px; cursor: pointer; border: 1px solid var(--border-dark); background: var(--btn-face); color: var(--btn-text); font-size: 14px; line-height: 1; display: grid; place-items: center; }
.win-btns button:hover { background: var(--btn-pressed); }
.win-body { flex: 1; overflow: auto; padding: 16px 18px; color: var(--text-primary); font-size: 20px; line-height: 1.4; background: var(--win-body); }
.win-body p { margin-bottom: 11px; }
.win-body .muted { color: var(--text-secondary); font-size: 18px; }
.lock-badge { display: inline-block; margin-top: 6px; padding: 4px 10px; border-radius: 20px; background: #FBEDE2; border: 1px solid var(--border-light); color: var(--accent); font-size: 17px; }
.cta-btn { display: inline-block; margin-top: 8px; cursor: pointer; padding: 9px 18px; border-radius: 6px; font-family: var(--pixel); font-size: 21px; color: #fff; border: 1px solid var(--border-dark); background: linear-gradient(180deg, var(--title-from), var(--title-to)); box-shadow: inset 1px 1px 0 rgba(255,255,255,0.4); }
.cta-btn:active { transform: translateY(1px); }

/* Taskbar pleine largeur de l'ÉCRAN */
.taskbar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 40;
  width: 100%; height: 56px; display: flex; align-items: center; gap: 8px; padding: 0 10px;
  background: linear-gradient(180deg, var(--tb-from), var(--tb-to));
  border-top: 2px solid var(--border-light);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.35), 0 -3px 14px rgba(43,58,90,0.35);
}
.start-btn { display: flex; align-items: center; gap: 8px; cursor: pointer; height: 42px; padding: 0 16px 0 9px; border-radius: 8px; border: 1px solid var(--border-dark); background: linear-gradient(180deg, #fff, var(--btn-face)); box-shadow: inset 1px 1px 0 #fff; color: var(--btn-text); font-family: var(--pixel); font-size: 22px; }
.start-btn:active { background: var(--btn-pressed); }
.start-logo { width: 26px; height: 26px; border-radius: 5px; }
.start-glyph { width: 22px; height: 22px; flex-shrink: 0; }
.tabs { flex: 1; display: flex; gap: 6px; overflow-x: auto; height: 42px; align-items: center; }
.tab { display: flex; align-items: center; gap: 6px; cursor: pointer; height: 38px; padding: 0 13px; border-radius: 7px; white-space: nowrap; background: rgba(255,255,255,0.18); border: 1px solid rgba(255,255,255,0.3); color: #fff; font-size: 18px; max-width: 190px; }
.tab .tab-label { overflow: hidden; text-overflow: ellipsis; }
.tab.active { background: rgba(255,255,255,0.42); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.6); }
.tray { display: flex; align-items: center; gap: 10px; padding: 0 8px; }
.tray-dot { width: 13px; height: 13px; border-radius: 50%; background: var(--online); box-shadow: 0 0 0 2px rgba(0,0,0,0.15); }
.clock { color: #fff; font-size: 22px; letter-spacing: 1px; text-shadow: 0 1px 2px rgba(0,0,0,0.4); min-width: 56px; text-align: center; }

.start-menu {
  position: absolute; left: 10px; bottom: 64px; z-index: 45; width: 244px; padding: 8px;
  background: var(--win-body); border: 1px solid var(--win-border); border-radius: 10px;
  box-shadow: inset 1px 1px 0 var(--border-light), inset -1px -1px 0 var(--border-dark), 0 14px 34px rgba(43,58,90,0.4);
  animation: winOpen 0.14s ease;
}
.sm-head { display: flex; align-items: center; gap: 8px; padding: 9px 11px; margin-bottom: 6px; border-radius: 7px; color: #fff; font-size: 24px; background: linear-gradient(180deg, var(--title-from), var(--title-to)); }
.sm-logo { width: 24px; height: 24px; border-radius: 5px; }
.sm-item { display: block; width: 100%; text-align: left; cursor: pointer; padding: 10px 13px; border: none; border-radius: 6px; background: transparent; font-family: var(--pixel); font-size: 21px; color: var(--text-primary); }
.sm-item:hover { background: var(--btn-face); }
.sm-sep { height: 1px; background: var(--border-light); margin: 6px 4px; }

/* Extinction */
#shutdownOverlay {
  position: absolute; inset: 0; z-index: 100; background: #000;
  display: flex; align-items: center; justify-content: center; animation: dtIn 0.5s ease;
}

/* ---------- OldyLive Messenger (façon MSN) ---------- */
.msn { display: flex; flex-direction: column; height: 100%; background: var(--win-body); font-family: var(--pixel); }

/* En-tête "To:" */
.msn-to { display: flex; align-items: center; justify-content: space-between; margin: 10px; padding: 9px 12px; border: 2px solid var(--win-border); border-radius: 4px; background: #fff; }
.msn-to-label { font-size: 22px; color: #3a2a20; }
.msn-to-label b { color: #23150e; }
.msn-to-status { font-size: 18px; color: #9a8a7c; display: flex; align-items: center; gap: 7px; }
.msn-dot { width: 11px; height: 11px; border-radius: 50%; background: #b0998a; }
.msn-dot.on { background: #5aae8a; box-shadow: 0 0 5px #5aae8a; }

/* Conversation : journal + colonne avatars (Léa en haut, moi en bas) */
.msn-main { flex: 1; display: flex; gap: 8px; padding: 0 10px; min-height: 0; }
.msn-log { flex: 1; overflow-y: auto; border: 2px solid var(--win-border); border-radius: 4px; background: #fff; padding: 10px 12px; }
.msn-avatars { width: 92px; flex-shrink: 0; display: flex; flex-direction: column; justify-content: space-between; }
.msn-av { width: 92px; height: 92px; object-fit: cover; border: 3px solid #a8a29a; background: #f0e6da; transition: border-color 0.4s ease; }
.msn-av.me { border-color: #5aae8a; }
.msn-av.buddy.online { border-color: #5aae8a; }

/* Messages au format MSN : "Nom HH:MM :" puis le texte */
.msn-msg { margin-bottom: 13px; }
.msn-meta { font-size: 16px; letter-spacing: 0.5px; color: #a3907f; }
.msn-from { font-weight: bold; }
.msn-from.buddy { color: #c85a3e; }
.msn-from.me { color: #4b9e78; }
.msn-text { font-size: 22px; color: #26160e; line-height: 1.3; margin-top: 2px; word-break: break-word; }
.msn-receipt { text-align: right; color: #4b9e78; font-size: 20px; margin-top: 1px; letter-spacing: 2px; }
.msn-sys { text-align: center; font-size: 15px; color: #a3907f; font-style: italic; margin: 6px 0 10px; }
.msn-typing { font-size: 16px; color: #a3907f; font-style: italic; margin-bottom: 8px; }
.msn-ctaline { text-align: center; margin: 8px 0 4px; }
.msn-ctaline.flash { animation: ctaFlash 0.6s ease; }
@keyframes ctaFlash { 0%,100% { transform: scale(1); } 50% { transform: scale(1.09); } }

/* Boutons façon Windows 98 : coins carrés + relief biseauté (clair haut-gauche /
   foncé bas-droite), teinté chaud pour rester coral. Enfoncé au clic (bevel inversé). */
.msn-tool, .msn-act {
  border: none; border-radius: 0; background: #d8cbbb; color: #23150e;
  font-family: var(--pixel); cursor: pointer;
  box-shadow: inset -1px -1px 0 #5e4a38, inset 1px 1px 0 #fff, inset -2px -2px 0 #a58e78, inset 2px 2px 0 #f4ebe0;
}
.msn-tool:active, .msn-act:active {
  box-shadow: inset 1px 1px 0 #5e4a38, inset -1px -1px 0 #fff, inset 2px 2px 0 #a58e78, inset -2px -2px 0 #f4ebe0;
}
.msn-toolbar { display: flex; gap: 8px; padding: 9px 10px 4px; }
.msn-tool { display: flex; align-items: center; gap: 7px; padding: 8px 13px; font-size: 19px; }
.msn-tool svg { width: 24px; height: 24px; }
.msn-act { padding: 10px 26px; font-size: 20px; }

/* Saisie + actions */
.msn-inputwrap { padding: 6px 10px; }
/* La boîte de saisie CONTIENT soit le placeholder, soit les réponses (choix). */
.msn-input {
  width: 100%; min-height: 66px; box-sizing: border-box;
  border: 2px solid var(--win-border); background: #fff; padding: 6px;
  font-family: var(--pixel); cursor: text; box-shadow: inset 1px 1px 0 #a58e78;
  display: flex; flex-direction: column; gap: 5px; justify-content: center;
}
.msn-input.choosing { cursor: default; justify-content: flex-start; }
.msn-input .msn-ph { color: #a3907f; font-size: 22px; padding: 2px 6px; }
.msn-actions { display: flex; justify-content: space-between; padding: 4px 10px 12px; }

/* Réponses de l'utilisateur — intégrées DANS la boîte de saisie */
.msn-choice {
  cursor: pointer; text-align: left; font-family: var(--pixel); font-size: 20px; color: #26160e;
  background: #f6efe6; border: 1px solid var(--border-light); padding: 8px 12px; width: 100%;
  transition: background 0.15s, padding-left 0.12s;
}
.msn-choice:hover { background: #FBEDE2; padding-left: 16px; }
.msn-choice-cur { color: var(--accent); font-weight: bold; }

/* Bouton « Créer ton compte Oldy » */
.msn-createwrap { text-align: center; margin: 12px 0 4px; }
.msn-create {
  cursor: pointer; font-family: var(--pixel); font-size: 22px; color: #241207;
  background: linear-gradient(180deg, #ffd89a, #f0a860); border: none; border-radius: 10px;
  padding: 12px 22px; box-shadow: 0 0 22px rgba(255,190,120,0.5);
  animation: startPulse 2.2s ease-in-out infinite; transition: transform 0.12s;
}
.msn-create:hover { transform: translateY(-2px); }
.msn-create:active { transform: scale(0.97); }

/* Pop-up « La suite, ça se passe sur ton téléphone » */
.phone-modal {
  position: fixed; inset: 0; z-index: 3000; display: flex; align-items: center; justify-content: center;
  background: rgba(18,11,9,0.66); animation: dtIn 0.25s ease; padding: 16px;
}
.phone-card {
  position: relative; background: var(--win-body); border: 2px solid var(--win-border); border-radius: 14px;
  padding: 34px 34px 34px; max-width: min(94vw, 580px); text-align: center;
  box-shadow: inset 1px 1px 0 var(--border-light), 0 20px 50px rgba(0,0,0,0.5);
}
.phone-close {
  position: absolute; top: 10px; right: 12px; cursor: pointer; width: 32px; height: 32px;
  border: 1px solid var(--border-dark); border-radius: 6px; background: var(--btn-face);
  color: var(--text-primary); font-size: 19px;
}
.phone-title { font-family: var(--pixel); font-size: clamp(24px, 3.4vw, 34px); color: var(--text-primary); margin-bottom: 24px; line-height: 1.25; }
.phone-stores { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; }

/* Wizz : l'écran tremble */
@keyframes screenShake {
  0%,100% { transform: translate(0,0); }
  12% { transform: translate(-5px, 3px); } 26% { transform: translate(5px, -3px); }
  40% { transform: translate(-4px, -3px); } 55% { transform: translate(4px, 3px); }
  70% { transform: translate(-3px, 2px); } 85% { transform: translate(2px, -2px); }
}
.screen.shake { animation: screenShake 0.62s ease; }

/* ============================================================
   Nav transparente + boutons stores (chrome marketing, vue "assis" masquée)
   ============================================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 90;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px; font-family: var(--pixel);
  background: linear-gradient(to bottom, rgba(20,12,10,0.55), rgba(20,12,10,0));
  transition: opacity 0.4s;
}
.nav-brand {
  display: flex; align-items: center; gap: 11px; color: #fff; cursor: pointer;
  font-size: 36px; letter-spacing: 1.5px;
  text-shadow: 0 0 14px rgba(255,200,140,0.45), 0 3px 8px rgba(0,0,0,0.6);
}
.nav-brand img { width: 46px; height: 46px; border-radius: 9px; image-rendering: pixelated; box-shadow: 0 3px 10px rgba(0,0,0,0.45); }
/* Menus centrés dans l'espace ENTRE le logo (gauche) et le FR/volume (droite) :
   flex:1 prend la place restante, justify-center centre, padding-right dégage les
   boutons flottants → aucun chevauchement quelle que soit la largeur. */
.nav-links { display: flex; gap: 14px; flex: 1; justify-content: center; padding-right: 150px; }
.nav-links button {
  background: none; border: none; cursor: pointer; color: #fff; white-space: nowrap;
  font-family: var(--pixel); font-size: 18px; padding: 6px 9px; border-radius: 7px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}
.nav-links button:hover { background: rgba(255,255,255,0.16); }
.lang-sel {
  position: fixed; top: 16px; right: 74px; z-index: 2100; cursor: pointer;
  font-family: var(--pixel); font-size: 18px; color: #fff;
  background: rgba(0,0,0,0.4); border: 1px solid rgba(255,255,255,0.3);
  border-radius: 8px; padding: 9px 8px; backdrop-filter: blur(2px);
}
.lang-sel option { color: #000; }
/* Le sélecteur de langue suit le chrome : caché quand on est "assis" */
body.zoomed .lang-sel { opacity: 0; pointer-events: none; }

.downloads {
  position: fixed; left: 50%; bottom: 72px; transform: translateX(-50%); z-index: 2100;
  display: flex; gap: 26px; transition: opacity 0.4s;
}
.store-btn {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  background: #111; color: #fff; border: 1px solid #333; border-radius: 12px;
  padding: 9px 18px; box-shadow: 0 6px 18px rgba(0,0,0,0.4);
  transition: transform 0.12s, background 0.2s;
}
.store-btn:hover { background: #222; transform: translateY(-2px); }
.store-ico { width: 26px; height: 26px; }
.store-txt { display: flex; flex-direction: column; line-height: 1.05; text-align: left; }
.store-txt small { font-family: system-ui, sans-serif; font-size: 11px; opacity: 0.85; }
.store-txt b { font-family: system-ui, sans-serif; font-size: 18px; font-weight: 600; }

/* Chrome marketing masqué quand on est "assis". Pendant l'intro : nav masquée
   mais les boutons stores restent visibles en bas. */
body.zoomed .nav, body.zoomed .downloads,
body.intro-active .nav { opacity: 0; pointer-events: none; }

/* ============================================================
   Modale d'info (nav)
   ============================================================ */
.info-modal {
  /* z-index au-dessus de TOUT : l'intro est à 2000, les downloads/lang/mute à 2100,
     la modale téléphone à 3000 → sinon la modale s'affiche derrière l'écran d'intro. */
  position: fixed; inset: 0; z-index: 3100; display: flex; align-items: center; justify-content: center;
  background: rgba(20,12,10,0.6); backdrop-filter: blur(3px); animation: dtIn 0.25s ease;
}
.info-card {
  position: relative; width: min(92vw, 520px); max-height: 80vh; overflow: auto;
  background: var(--win-body); border: 1px solid var(--win-border); border-radius: 12px;
  padding: 26px 28px; box-shadow: inset 1px 1px 0 var(--border-light), 0 20px 50px rgba(0,0,0,0.4);
  font-family: var(--pixel); color: var(--text-primary);
}
/* Modale « L'application » : plus large, captures des stores en alternance G/D. */
.info-card.wide { width: min(94vw, 860px); }
.app-shots { display: flex; flex-direction: column; gap: 26px; margin-top: 18px; }
.shot { display: flex; align-items: center; gap: 22px; }
.shot.alt { flex-direction: row-reverse; }        /* une à gauche, une à droite… */
.shot img {
  width: 190px; flex: 0 0 190px; border-radius: 12px; display: block;
  border: 1px solid var(--win-border); box-shadow: 0 8px 22px rgba(0,0,0,0.28);
}
.shot-txt { flex: 1; min-width: 0; }
.shot-txt b { display: block; font-size: 21px; color: var(--accent); margin-bottom: 6px; }
.shot-txt p { font-size: 17px; line-height: 1.45; margin: 0; }
@media (max-width: 640px) {
  .shot, .shot.alt { flex-direction: column; text-align: center; gap: 12px; }
  .shot img { width: min(70vw, 220px); flex: none; }
}

/* Inscription à la bêta Android (Netlify Forms). */
.beta-form { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.beta-form input[type="email"] {
  flex: 1; min-width: 180px; padding: 12px 14px; font: inherit; font-size: 17px;
  background: #fff; color: var(--text-primary);
  border: 1px solid var(--win-border); border-radius: 10px;
}
.beta-form button {
  padding: 12px 20px; font: inherit; font-weight: 600; font-size: 16px; cursor: pointer;
  background: var(--accent); color: #fff; border: none; border-radius: 10px;
}
.beta-form button:hover { filter: brightness(1.05); }
.beta-form button:disabled { opacity: 0.6; cursor: default; }
.beta-hint {
  margin-top: 10px; padding: 10px 14px; font-size: 15px; line-height: 1.4;
  background: rgba(217, 138, 74, 0.10); border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0;
}
.beta-msg { margin-top: 14px; font-size: 17px; color: var(--accent); }
.beta-msg a { color: var(--accent); }

/* Bloc de clôture « Et bien plus ! » sous les captures. */
.more-block {
  margin-top: 26px; padding: 18px 20px;
  background: rgba(217, 138, 74, 0.10);
  border: 1px dashed var(--accent);
  border-radius: 12px;
}
.more-block > b { display: block; font-size: 21px; color: var(--accent); margin-bottom: 6px; }
.more-block p { font-size: 17px; line-height: 1.45; margin: 0; }

/* Fenêtre « Changer de thème » (OS) : aperçus des fonds d'écran. */
.theme-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 12px 0; }
.theme-grid figure { margin: 0; }
.theme-grid img {
  width: 100%; display: block; border-radius: 6px;
  border: 1px solid var(--win-border); image-rendering: pixelated;
}
.theme-grid figcaption { font-size: 15px; text-align: center; margin-top: 4px; opacity: 0.85; }

/* Boutons stores à l'intérieur d'une fenêtre de l'OS. */
.win-stores { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.win-stores .store-btn { transform: scale(0.92); transform-origin: left center; }

.info-card h2 { font-size: 30px; color: var(--accent); margin-bottom: 14px; }
.info-card p { font-size: 19px; line-height: 1.5; margin-bottom: 12px; }
.info-card b { color: var(--accent); }
.info-close {
  position: absolute; top: 14px; right: 16px; cursor: pointer;
  width: 30px; height: 30px; border-radius: 6px; border: 1px solid var(--border-dark);
  background: var(--btn-face); color: var(--btn-text); font-size: 20px;
}
.info-close:hover { background: var(--btn-pressed); }

/* ============================================================
   Intro — remonter le temps
   ============================================================ */
/* La scène (derrière l'intro) est SEULEMENT floue (même cadrage que la version
   nette) → au reveal le flou se lève, sans zoom ni recadrage. */
.stage { transition: filter 1s ease; }
body.intro-active .stage { filter: blur(26px) brightness(0.94); }

.intro {
  position: fixed; inset: 0; z-index: 2000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(18,11,9,0.62);
  font-family: var(--pixel); text-align: center;
}
.intro.gone { animation: introOut 1s ease forwards; }
@keyframes introOut { to { opacity: 0; visibility: hidden; } }
.intro-content { transition: opacity 0.8s; }
.intro-logo {
  width: 108px; height: 108px; border-radius: 22px; display: block; margin: 0 auto 22px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5); image-rendering: pixelated;
  animation: introFloat 3s ease-in-out infinite;
}
@keyframes introFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.intro-title { color: #ffe6c8; font-size: clamp(40px, 8vw, 92px); letter-spacing: 2px; text-shadow: 0 4px 12px rgba(0,0,0,0.6); }
.intro-sub { color: #ffcfa8; font-size: clamp(18px, 3vw, 30px); margin-top: 12px; text-shadow: 0 2px 8px rgba(0,0,0,0.6); }
.intro-start {
  margin-top: 34px; cursor: pointer; font-family: var(--pixel);
  display: inline-flex; align-items: center; gap: 10px;
  font-size: clamp(20px, 3vw, 30px); color: #241207;
  background: linear-gradient(180deg, #ffd89a, #f0a860);
  border: none; border-radius: 12px; padding: 13px 28px;
  box-shadow: 0 0 26px rgba(255,190,120,0.5); transition: transform 0.12s, box-shadow 0.3s;
  animation: startPulse 2.2s ease-in-out infinite;
}
.intro-start:hover { transform: translateY(-2px); }
.intro-start:active { transform: scale(0.96); }
@keyframes startPulse { 0%,100%{box-shadow:0 0 14px rgba(255,190,120,0.35)} 50%{box-shadow:0 0 34px rgba(255,190,120,0.7)} }
.intro-year {
  margin-top: 40px; color: #fff; font-size: clamp(70px, 16vw, 200px); line-height: 1;
  letter-spacing: 4px; text-shadow: 0 0 34px rgba(255,180,120,0.6); min-height: 1.1em;
  opacity: 0; transition: opacity 0.6s ease;
}
.intro-year.show { opacity: 1; }
.intro-skip {
  position: fixed; right: 20px; bottom: 20px; cursor: pointer;
  background: rgba(0,0,0,0.35); border: 1px solid rgba(255,255,255,0.25); border-radius: 8px;
  color: #fff; font-family: var(--pixel); font-size: 18px; padding: 8px 14px;
}

/* Responsive : sur mobile la scène remplit la largeur ; le zoom rend l'écran jouable. */
@media (max-width: 640px) {
  .scene-hint { font-size: 20px; bottom: 13%; }
  .nav { padding: 10px 14px; }
  .nav-links button { font-size: 16px; padding: 5px 8px; }
  .nav-brand { font-size: 22px; }
  .store-btn { padding: 7px 12px; }
  .store-txt b { font-size: 15px; }
}
