/* =========================================================
   PORTFOLIO — Bureau Windows XP Thème Global
   ========================================================= */

:root {
  --th: 357; --tl: 1; --hr: 0deg;
  --face: #ececec;
  --face-light: #f1f1f1;
  --face-dark: #acacac;
  --ink: #000;
  --desk: #0b0b0d; /* Fond noir */
  --accent: hsl(var(--th) 80% calc(46% * var(--tl)));
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Tahoma', 'Segoe UI', Arial, sans-serif;
  -webkit-user-select: none;
  user-select: none;
}

html, body { height: 100%; }

body {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  background-color: var(--desk);
  /* Fond noir, comme la barre des tâches. */
  background-image: none;
}

button { font: inherit; }
:focus-visible { outline: 2px solid #000; outline-offset: 1px; }

/* ---------------------------------------------------------
   BARRE DES TÂCHES WINDOWS XP (EN BAS)
   --------------------------------------------------------- */
#menu-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 9000;
  height: 32px;
  display: flex;
  align-items: center;
  background: linear-gradient(to bottom, #2b2b31 0%, #0b0b0d 100%);
  border-top: 1px solid hsl(var(--th) 83% calc(45% * var(--tl)));
  padding: 0;
  font-size: 12px;
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.start-button {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 14px 0 8px;
  background: linear-gradient(to bottom, hsl(var(--th) 100% 71%) 0%, hsl(var(--th) 78% calc(49% * var(--tl))) 45%, hsl(var(--th) 86% calc(37% * var(--tl))) 100%);   /* rouge vif : reste lisible sous les lignes de l'écran CRT */
  border-top-right-radius: 12px;
  border-bottom-right-radius: 12px;
  border-right: 1px solid hsl(var(--th) 89% calc(19% * var(--tl)));
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.55), inset 0 -2px 3px hsl(var(--th) 100% calc(12% * var(--tl)) / 0.35), 0 0 9px hsl(var(--th) 100% 72% / 0.45);
  cursor: pointer;
  font-weight: bold;
  font-style: italic;
  font-size: 14px;
  letter-spacing: .2px;
  text-shadow: 1px 1px 2px hsl(var(--th) 100% calc(12% * var(--tl)) / 0.9);
}

.start-button:hover {
  background: linear-gradient(to bottom, hsl(var(--th) 100% 76%) 0%, hsl(var(--th) 86% calc(58% * var(--tl))) 45%, hsl(var(--th) 79% calc(44% * var(--tl))) 100%);
}

.taskbar-windows {
  display: flex;
  gap: 4px;
  padding: 0 6px;
  flex: 1;
  overflow-x: auto;
}

.taskbar-item {
  height: 24px;
  padding: 0 10px;
  background: linear-gradient(to bottom, #3d3d45 0%, #1a1a1f 100%);
  border: 1px solid #000;
  border-radius: 3px;
  color: #fff;
  font-size: 11px;
  display: flex;
  align-items: center;
  cursor: pointer;
  max-width: 130px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.taskbar-item.is-active {
  background: linear-gradient(to bottom, #050506 0%, #25252b 100%);
  border-color: hsl(var(--th) 83% calc(45% * var(--tl)));
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.4);
}

#clock {
  display: flex;
  align-items: center;
  padding: 0 12px;
  height: 100%;
  background: linear-gradient(to bottom, #17171b 0%, #050506 100%);
  border-left: 1px solid #3d3d45;
  font-size: 11px;
  text-shadow: 1px 1px 1px rgba(0,0,0,0.5);
}

/* Menu Démarrer XP */
#apple-menu {
  position: absolute;
  bottom: 32px;
  left: 0;
  width: 250px;
  background: #fff;
  border: 1px solid #413739;
  border-top-left-radius: 4px;
  border-top-right-radius: 4px;
  box-shadow: 3px -3px 8px rgba(0, 0, 0, 0.4);
  font-size: 12px;
  overflow: hidden;
}

.start-menu-header {
  background: linear-gradient(to bottom, hsl(var(--th) 77% calc(52% * var(--tl))) 0%, hsl(var(--th) 83% calc(36% * var(--tl))) 100%);
  padding: 10px;
  color: #fff;
  border-bottom: 2px solid #fff;
  font-size: 13px;
}

.start-menu-body { padding: 4px 0; background: #fff; }

.start-menu-footer {
  display: flex;
  border-top: 1px solid #d4d4d4;
  background: linear-gradient(to bottom, #f4f4f4 0%, #d6d6d6 100%);
}

.power-btn {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  background: none;
  border: 0;
  text-align: left;
  cursor: default;
  color: #4e4244;
  font-weight: bold;
  font-size: 12px;
}
.power-btn:hover { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; }
.power-icon { font-size: 14px; }

#apple-menu button {
  display: block;
  width: 100%;
  padding: 8px 16px;
  background: none;
  border: 0;
  text-align: left;
  cursor: default;
  color: #000;
}

#apple-menu button:hover { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; }
#apple-menu hr { border: 0; border-top: 1px solid #d4d4d4; margin: 4px 8px; }

/* ---------------------------------------------------------
   BUREAU ET ICÔNES
   --------------------------------------------------------- */
#desktop {
  position: relative;
  flex: 1 1 auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 32px; /* Laisse la place pour la barre des tâches */
}
/* Les icônes passent en colonne suivante au lieu de glisser sous la barre des tâches ou de se chevaucher */
#desktop { flex-wrap: wrap; align-content: flex-start; min-height: 0; overflow: hidden; column-gap: 6px; }

.icon {
  width: 86px;
  padding: 6px 2px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: default;
  text-align: center;
  border: 1px solid transparent;
  border-radius: 3px;
}

.icon:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

.icon svg { filter: hue-rotate(var(--hr)) drop-shadow(1px 1px 2px rgba(0, 0, 0, 0.6)); }

.icon span {
  padding: 1px 3px;
  color: #fff;
  font-size: 11px;
  line-height: 1.2;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.9);
  border-radius: 2px;
}

.icon.is-selected span {
  background: hsl(var(--th) 60% calc(48% * var(--tl)));
  color: #fff;
  text-shadow: none;
}

.icon.is-selected {
  background: hsl(var(--th) 60% calc(48% * var(--tl)) / 0.3);
  border-color: hsl(var(--th) 60% calc(48% * var(--tl)) / 0.6);
}

#icon-trash { margin-top: auto; }
.icon.is-locked,
#apple-menu button.is-locked { display: none; }
.icon.is-new { animation: icon-pop 1.4s ease-out; }

@keyframes icon-pop {
  0%   { transform: scale(0.4); opacity: 0; }
  35%  { transform: scale(1.15); opacity: 1; }
  50%  { transform: scale(1); }
  60%, 80% { filter: brightness(1.9); }
  70%, 100% { filter: none; }
}

/* Notifications */
#toast-zone {
  position: absolute;
  top: 10px;
  right: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
  z-index: 8000;
}

.toast {
  min-width: 220px;
  padding: 10px 14px;
  background: #fff;
  border: 1px solid #767676;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.3);
  font-size: 11px;
  line-height: 1.4;
  animation: toast-in 0.25s ease-out;
}

.toast strong { display: block; font-size: 11px; color: hsl(var(--th) 83% calc(36% * var(--tl))); font-weight: bold; }
.toast span { font-weight: bold; color: #000; }
.toast.is-out { opacity: 0; transition: opacity 0.5s ease; }

@keyframes toast-in {
  from { transform: translateX(14px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

/* ---------------------------------------------------------
   FENÊTRES (Style Windows XP Luna)
   --------------------------------------------------------- */
.window {
  position: absolute;
  width: 380px;
  min-width: 260px;
  min-height: 160px;
  display: flex;
  flex-direction: column;
  background: var(--face);
  border: 3px solid hsl(var(--th) 80% calc(45% * var(--tl)));
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  border-bottom-left-radius: 3px;
  border-bottom-right-radius: 3px;
  box-shadow: 4px 4px 12px rgba(0, 0, 0, 0.45);
  z-index: 10;
  overflow: hidden;
}

.window:not(.is-active) { border-color: #a39596; }
.window.is-opening { animation: win-open 0.16s ease-out; }

@keyframes win-open {
  from { transform: scale(0.88); opacity: 0.4; }
  to   { transform: scale(1); opacity: 1; }
}

.title-bar {
  position: relative;
  flex: none;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(to bottom, hsl(var(--th) 80% calc(47% * var(--tl))) 0%, hsl(var(--th) 80% calc(60% * var(--tl))) 4%, hsl(var(--th) 80% calc(58% * var(--tl))) 10%, hsl(var(--th) 80% calc(52% * var(--tl))) 50%, hsl(var(--th) 80% calc(43% * var(--tl))) 100%);
  padding: 0 8px;
  cursor: grab;
}

.window:not(.is-active) .title-bar {
  background: linear-gradient(to bottom, #a39596 0%, hsl(var(--th) 25% 77%) 100%);
}

.title-bar:active { cursor: grabbing; }

.title-text {
  position: relative;
  z-index: 2;
  margin-left: 2px;
  background: transparent;
  font-size: 12px;
  font-weight: bold;
  color: #fff;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.6);
  white-space: nowrap;
}

.window-controls { display: flex; gap: 3px; }

.close-btn, .zoom-btn, .min-btn {
  position: relative;
  z-index: 2;
  width: 21px;
  height: 21px;
  flex: none;
  background: linear-gradient(to bottom, #f2f2f2 0%, #d8d8d8 100%);
  border: 1px solid #fff;
  border-radius: 3px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 2px rgba(0,0,0,0.3);
  font-size: 11px;
  font-weight: bold;
  color: #000;
}

.close-btn { 
  background: linear-gradient(to bottom, #4a4a52 0%, #1a1a1f 55%, #000 100%);
  border-color: #fff;
  color: #fff;
}

.zoom-btn, .min-btn { 
  background: linear-gradient(to bottom, hsl(var(--th) 76% calc(68% * var(--tl))) 0%, hsl(var(--th) 76% calc(47% * var(--tl))) 50%, hsl(var(--th) 80% calc(35% * var(--tl))) 100%);
  border-color: hsl(var(--th) 25% 80%);
  color: #fff;
}

.close-btn:active { background: #000; }
.zoom-btn:active, .min-btn:active { background: #3f3537; }

.window-content {
  flex: 1 1 auto;
  min-height: 0;
  margin: 1px 3px 3px 3px;
  padding: 12px;
  background: #fff;
  border: 1px solid #717171;
  font-size: 12px;
  line-height: 1.5;
  overflow: auto;
}

.window-content--flush { padding: 0; border: 0; box-shadow: none; margin: 0; }
.hidden { display: none; }

.resize-handle {
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 12px;
  height: 12px;
  cursor: nwse-resize;
  background: linear-gradient(135deg, transparent 50%, #7a7a7a 50%, #7a7a7a 60%, transparent 60%);
  touch-action: none;
}

/* ---------------------------------------------------------
   ANIMATION DE DÉMARRAGE WINDOWS XP AUTHENTIQUE
   --------------------------------------------------------- */
#boot-screen {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: #000;
  transition: opacity 0.5s ease;
}

.xp-boot-box {
  text-align: center;
  color: #fff;
  width: 320px;
}

.xp-logo-img {
  display: block;
  height: 90px;
  width: auto;
  object-fit: contain;
  margin: 0 auto 24px;
}

.start-logo-img {
  height: 18px;
  width: auto;
  object-fit: contain;
  margin-right: 4px;
}

.xp-boot-box h1 {
  font-size: 16px;
  font-weight: normal;
  letter-spacing: 1px;
  margin-bottom: -5px;
}

.xp-boot-box h1 .reg { font-size: 10px; vertical-align: super; }

.xp-boot-box h2 {
  font-size: 32px;
  font-weight: bold;
  font-style: italic;
  letter-spacing: 2px;
  margin-bottom: 35px;
}

.xp-boot-box h2 .xp-text { color: #f25022; }

.loading-bar-container {
  width: 180px;
  height: 14px;
  margin: 0 auto;
  border: 1px solid #333;
  border-radius: 7px;
  background: #111;
  padding: 2px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.8);
}

.loading-progress {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, hsl(var(--th) 80% calc(34% * var(--tl))) 0%, hsl(var(--th) 80% calc(61% * var(--tl))) 50%, hsl(var(--th) 80% calc(34% * var(--tl))) 100%);
  border-radius: 5px;
  animation: xp-load 3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes xp-load {
  0% { width: 0%; transform: translateX(-20%); }
  50% { width: 60%; }
  100% { width: 100%; transform: translateX(0%); }
}

/* Contenus additionnels */
.doc { font-family: 'Courier New', monospace; font-size: 12px; line-height: 1.6; }
.doc h3 { font-weight: bold; margin-top: 10px; border-bottom: 1px solid #ccc; }
.card h3 { font-size: 14px; margin-bottom: 2px; }
.card p { margin-bottom: 12px; color: #333; }
.mailto-btn { display: inline-block; padding: 5px 16px; background: linear-gradient(to bottom, #f3f3f3 0%, #e5e5e5 100%); border: 1px solid #3f3537; border-radius: 3px; color: #000; text-decoration: none; font-size: 12px; cursor: pointer; }

/* =========================================================
   RECTANGLE DE SÉLECTION & CORBEILLE
   ========================================================= */

/* Le vrai rectangle bleu de sélection Windows XP */
#selection-box {
  position: absolute;
  background: hsl(var(--th) 80% calc(46% * var(--tl)) / 0.3); /* Bleu transparent */
  border: 1px solid hsl(var(--th) 80% calc(46% * var(--tl)));
  pointer-events: none; /* Pour que le rectangle ne bloque pas la souris */
  z-index: 1000;
  display: none; /* Caché par défaut */
}

/* On prépare l'intérieur de la fenêtre Corbeille pour accueillir les icônes */
#window-trash .window-content {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 15px;
  position: relative;
}

#window-trash .icon {
  width: 70px; /* Légèrement plus petit dans la fenêtre */
}

#window-trash .icon span {
  color: #000; /* Texte noir sur fond blanc dans l'explorateur */
  text-shadow: none;
}

#window-trash .icon.is-selected span {
  color: #fff;
}
/* ---------- Éléments de travaux, contact, invitation ---------- */
.item { display: flex; gap: 10px; align-items: center; padding: 8px; margin-bottom: 8px; border: 1px solid #ccc; background: #fff; transition: background .3s, box-shadow .3s; }
.item .thumb { flex: 0 0 56px; height: 42px; display: flex; align-items: center; justify-content: center; color: #fff; font: bold 18px monospace; border: 1px solid #000; }
.item h3 { margin: 0 0 2px; }
.item p { margin: 0; }
.item.is-highlight { background: hsl(var(--th) 100% 95%); box-shadow: 0 0 0 2px hsl(var(--th) 83% calc(45% * var(--tl))); }
.card .cta { margin: 10px 0 0; }
.card .cta a, .doc a { color: hsl(var(--th) 80% calc(35% * var(--tl))); cursor: pointer; }
#taskbar-contact { margin-left: auto; margin-right: 8px; padding: 3px 12px; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#f3f3f3,#e5e5e5); font-size: 12px; cursor: pointer; }
#taskbar-contact:hover { background: hsl(var(--th) 100% 95%); }
#gallery-invite { position: absolute; right: 24px; bottom: 56px; width: 250px; padding: 10px 12px; background: #fff; border: 1px solid #000; border-radius: 4px; font-size: 12px; display: flex; flex-direction: column; gap: 6px; z-index: 5; }
#gallery-invite.is-hidden { display: none; }
#gallery-invite button { align-self: flex-start; padding: 4px 12px; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#f3f3f3,#e5e5e5); cursor: pointer; }

/* ---------- Explorateur Windows XP ---------- */
.xp-menubar { display: flex; gap: 14px; padding: 2px 8px; background: #ececec; border-bottom: 1px solid #d4d4d4; font-size: 11px; }
.xp-toolbar { display: flex; gap: 4px; padding: 3px 6px; background: #ececec; border-bottom: 1px solid #acacac; }
.xp-tool { padding: 3px 10px; background: transparent; border: 1px solid transparent; border-radius: 3px; font-size: 11px; cursor: pointer; }
.xp-tool:hover:not(:disabled) { background: #fff; border-color: #acacac; }
.xp-tool:disabled { color: #999; cursor: default; }
.explorer-address { display: flex; align-items: center; gap: 8px; padding: 4px 8px; background: #ececec; border-bottom: 1px solid #acacac; font-size: 11px; }
.explorer-address div { flex: 1; padding: 2px 6px; background: #fff; border: 1px solid #a39596; }
.explorer-layout { display: flex; flex: 1; min-height: 0; }
.explorer-side { flex: 0 0 170px; padding: 10px; overflow: auto; background: linear-gradient(to bottom, hsl(var(--th) 69% calc(69% * var(--tl))), hsl(var(--th) 58% calc(61% * var(--tl)))); }
.side-panel { margin-bottom: 10px; background: #e7e6e6; border-radius: 4px; overflow: hidden; font-size: 11px; }
.side-panel h4 { margin: 0; padding: 5px 8px; background: linear-gradient(to right, #fff, hsl(var(--th) 26% 87%)); color: hsl(var(--th) 71% calc(45% * var(--tl))); font-size: 11px; }
.side-panel a, .side-panel p { display: block; margin: 0; padding: 4px 8px; color: hsl(var(--th) 71% calc(45% * var(--tl))); text-decoration: none; cursor: pointer; }
.side-panel a:hover { color: hsl(var(--th) 80% calc(63% * var(--tl))); text-decoration: underline; }
.side-panel p { color: #000; }
.explorer-body { flex: 1; background: #fff; padding: 10px; overflow: auto; }
.xp-status { padding: 3px 8px; background: #ececec; border-top: 1px solid #acacac; font-size: 11px; }
#projets-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; align-content: start; }
.file { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px 4px; background: none; border: 1px solid transparent; cursor: pointer; font: inherit; }
.file:hover { background: #f2f1f1; border-color: hsl(var(--th) 26% 83%); }
.file:focus-visible .file-name, .file:active .file-name { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; }
.file-icon.thumb { width: 64px; height: 48px; border: 1px solid #a39596; background: #fff; padding: 2px; display: flex; }
.file-icon.thumb span { flex: 1; display: flex; align-items: center; justify-content: center; color: #fff; font: bold 14px monospace; }
.file-icon.thumb img { width: 100%; height: 100%; object-fit: cover; }
.file-name { font-size: 11px; line-height: 1.25; text-align: center; color: #000; word-break: break-word; }
.item[data-projet] { cursor: pointer; }
.item[data-projet]:hover { background: #f2f1f1; }

/* ---------- Fiche projet : image à gauche, texte à droite ---------- */
.projet-view { display: flex; gap: 16px; align-items: flex-start; background: #fff; padding: 14px; }
.projet-image { flex: 0 0 55%; aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; border: 1px solid #000; overflow: hidden; }
.projet-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.projet-image span { font: bold 48px monospace; color: #fff; }
.projet-info { flex: 1; min-width: 0; }
.projet-nom { font-size: 18px; margin: 0 0 8px; }
.projet-desc { font-size: 13px; line-height: 1.5; color: #333; margin: 0 0 12px; }
@media (max-width: 600px) { .projet-view { flex-direction: column; } .projet-image { flex-basis: auto; width: 100%; } }

/* ---------- Démarrage : rien du bureau ne dépasse sous l'écran noir ---------- */
body.booting #desktop, body.booting #menu-bar { visibility: hidden; }

/* ---------- Fenêtre en plein écran ---------- */
.window.is-maximized { border-radius: 0; max-width: none; box-shadow: none; }
.window.is-maximized .resize-handle { display: none; }
.window.is-maximized .window-content { flex: 1; min-height: 0; overflow: auto; }
#window-studio.is-maximized .window-content { display: flex; }
#window-studio.is-maximized #game-shell { flex: 1; display: flex; flex-direction: column; align-items: center; }
#window-studio.is-maximized #game-frame { width: auto; max-width: 100%; height: calc(100vh - 290px); min-height: 200px; }
#window-studio.is-maximized #game-dialogue,
#window-studio.is-maximized #game-pad,
#window-studio.is-maximized #game-keys { width: 100%; max-width: calc((100vh - 290px) * 1.5); }

/* ---------- Réduire / barre des tâches / son ---------- */
.window.is-minimized { display: none; }
.taskbar-item { flex: 0 1 150px; }
#vol-btn { background: none; border: 0; color: #fff; font-size: 14px; padding: 0 8px; height: 100%; cursor: pointer; }
#vol-btn:hover { background: rgba(255,255,255,.15); }
.icon span { text-shadow: 1px 1px 2px #000; }

/* ---------- Menu Démarrer à deux colonnes ---------- */
#apple-menu { width: 400px; border-radius: 6px 6px 0 0; }
#apple-menu .start-menu-header { display: flex; align-items: center; gap: 10px; padding: 8px 12px; }
.avatar { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 6px; border: 2px solid #fff; background: linear-gradient(#8fd23a,#4ea51f); color: #fff; font: bold 16px Tahoma, sans-serif; overflow: hidden; flex: none; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.start-cols { display: flex; }
.start-left { flex: 1.25; background: #fff; padding: 6px 0; }
.start-right { flex: 1; background: hsl(var(--th) 74% 94%); border-left: 1px solid hsl(var(--th) 50% 76%); padding: 6px 0; }
#apple-menu .start-left button { display: flex; align-items: center; gap: 10px; padding: 6px 10px; }
#apple-menu .start-left button b { display: block; font-size: 12px; }
#apple-menu .start-left button small { display: block; font-size: 10px; color: #666; }
#apple-menu .start-left button:hover small { color: #eeeced; }
#apple-menu .start-left .si { font-size: 24px; }
#apple-menu .start-right button { padding: 6px 12px; color: hsl(var(--th) 77% calc(31% * var(--tl))); font-weight: bold; font-size: 11px; }
#apple-menu .start-right button:hover { color: #fff; }

/* ---------- Clic droit ---------- */
#ctx-menu { position: fixed; z-index: 9500; min-width: 190px; padding: 2px; background: #fff; border: 1px solid #acacac; box-shadow: 3px 3px 5px rgba(0,0,0,.35); font-size: 12px; }
#ctx-menu.hidden { display: none; }
#ctx-menu button { display: block; width: 100%; padding: 5px 24px; text-align: left; background: none; border: 0; cursor: default; }
#ctx-menu button:hover { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; }
#ctx-menu hr { border: 0; border-top: 1px solid #d4d4d4; margin: 2px 0; }

/* ---------- Extinction ---------- */
#shutdown-screen { position: fixed; inset: 0; z-index: 20000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 24px; transition: background .6s; }
#shutdown-screen.hidden { display: none; }
#shutdown-screen.stage1 { background: hsl(var(--th) 65% calc(61% * var(--tl))); color: #fff; }
#shutdown-screen.stage1 button { display: none; }
#shutdown-screen.stage2 { background: #000; color: hsl(var(--th) 100% calc(62% * var(--tl))); }
#shutdown-screen .sd-text { font-size: 22px; text-align: center; padding: 0 20px; }
#shutdown-screen button { padding: 6px 20px; background: linear-gradient(#f3f3f3,#e5e5e5); border: 1px solid #3f3537; border-radius: 3px; cursor: pointer; }

/* ---------- Fausse erreur XP ---------- */
#xp-error { position: fixed; z-index: 9800; top: 36%; left: 50%; transform: translateX(-50%); width: 340px; background: #ececec; border: 3px solid hsl(var(--th) 80% calc(45% * var(--tl))); border-radius: 8px 8px 3px 3px; box-shadow: 4px 6px 14px rgba(0,0,0,.5); }
#xp-error.hidden { display: none; }
.err-bar { padding: 5px 8px; background: linear-gradient(hsl(var(--th) 80% calc(62% * var(--tl))),hsl(var(--th) 80% calc(43% * var(--tl)))); color: #fff; font-weight: bold; font-size: 12px; }
.err-body { display: flex; gap: 12px; align-items: center; padding: 16px; font-size: 12px; }
.err-ico { flex: none; width: 32px; height: 32px; border-radius: 50%; background: hsl(var(--th) 71% calc(53% * var(--tl))); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: bold; }
.err-actions { display: flex; justify-content: center; gap: 8px; padding: 0 0 14px; }
.err-actions button { min-width: 74px; padding: 4px 12px; background: linear-gradient(#f3f3f3,#e5e5e5); border: 1px solid #3f3537; border-radius: 3px; cursor: pointer; }
.err-actions button:disabled { color: #999; cursor: default; }

/* ---------- Assistant ---------- */
#clippy { position: fixed; right: 24px; bottom: 44px; z-index: 9400; display: flex; align-items: flex-end; gap: 8px; }
#clippy.hidden { display: none; }
.clippy-bubble { max-width: 230px; padding: 10px 12px; background: #fff; border: 1px solid #000; border-radius: 8px; font-size: 12px; }
.clippy-actions { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.clippy-actions button { padding: 3px 8px; font-size: 11px; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#f3f3f3,#e5e5e5); cursor: pointer; }

/* ---------- Formulaire de contact ---------- */
.contact-head { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.contact-head p { margin: 0; }
#contact-form label { display: block; margin-bottom: 8px; font-size: 11px; }
#contact-form input, #contact-form textarea { display: block; width: 100%; margin-top: 2px; padding: 4px 6px; border: 1px solid #a39596; font: 12px Tahoma, sans-serif; -webkit-user-select: text; user-select: text; }
#contact-status { margin: 8px 0 0; font-size: 11px; color: #1b6b1b; min-height: 14px; }
.projet-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 10px; }
.projet-tags span { padding: 2px 8px; background: #f2f1f1; border: 1px solid hsl(var(--th) 26% 83%); border-radius: 10px; font-size: 11px; }

/* ---------- Démineur ---------- */
.mines { background: #c0c0c0; padding: 8px; }
.mines-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; padding: 4px; border: 2px inset #fff; }
.lcd { font: bold 18px 'Courier New', monospace; color: hsl(var(--th) 100% calc(50% * var(--tl))); background: #000; padding: 1px 4px; }
#mines-face { font-size: 18px; width: 30px; height: 30px; cursor: pointer; }
#mines-grid { display: grid; grid-template-columns: repeat(9, 24px); border: 2px inset #fff; width: max-content; margin: 0 auto; }
.mcell { width: 24px; height: 24px; padding: 0; font: bold 13px Tahoma, sans-serif; background: #c0c0c0; border: 2px outset #fff; cursor: pointer; line-height: 1; }
.mcell.open { border: 1px solid #808080; background: #d4d4d4; cursor: default; }
.mcell.boom { background: hsl(var(--th) 100% calc(67% * var(--tl))); }
.mcell[data-n="1"] { color: hsl(var(--th) 80% calc(50% * var(--tl))); } .mcell[data-n="2"] { color: #080; } .mcell[data-n="3"] { color: hsl(var(--th) 100% calc(50% * var(--tl))); } .mcell[data-n="4"] { color: #493f40; } .mcell[data-n="5"] { color: hsl(var(--th) 100% calc(27% * var(--tl))); }
.mines-bottom { text-align: center; margin-top: 6px; }
#mines-flag { font-size: 11px; padding: 3px 8px; cursor: pointer; }
#mines-flag.on { background: hsl(var(--th) 100% 95%); border: 2px inset #aaa; }
#mines-msg { margin-top: 6px; font-size: 11px; text-align: center; min-height: 14px; }
#mines-msg a { color: hsl(var(--th) 80% calc(35% * var(--tl))); }

/* ---------- Téléphone ---------- */
@media (max-width: 700px) {
  #apple-menu { width: 100vw; }
  .icon span { font-size: 11px; }
  #taskbar-contact { margin-right: 4px; padding: 3px 6px; }
  .taskbar-item { flex-basis: 80px; }
  #clippy { right: 8px; left: 8px; }
  #gallery-invite { right: 8px; left: 8px; width: auto; }
}

/* ---------- Finitions ---------- */
.icon span { text-shadow: 0 0 3px #000, 1px 1px 2px #000; }
#apple-menu .start-left .si { width: 28px; text-align: center; flex: none; }
#ctx-menu { min-width: 240px; }
#ctx-menu button { white-space: nowrap; }
@media (max-width: 700px) { .explorer-side { display: none; } }

/* ---------- CV ---------- */
.cv { font-size: 12px; line-height: 1.55; }
.cv-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 6px; }
.cv-photo { width: 84px; height: 104px; border-radius: 4px; flex: none; font-size: 22px; }
.cv h2 { font-size: 22px; margin: 0; }
.cv-role { margin: 0 0 6px; color: hsl(var(--th) 100% calc(33% * var(--tl))); font-weight: bold; font-size: 13px; letter-spacing: .5px; text-transform: uppercase; }
.cv-actions { margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.cv h3 { margin: 14px 0 4px; padding-bottom: 2px; color: hsl(var(--th) 100% calc(33% * var(--tl))); font-size: 13px; letter-spacing: 1.5px; text-transform: uppercase; border-bottom: 1px solid #ccc; }
.cv ul { margin: 0; padding-left: 18px; }
.cv li { margin-bottom: 3px; }
.cv a { color: hsl(var(--th) 80% calc(35% * var(--tl))); cursor: pointer; }
.cv a.mailto-btn { color: #000; }
@media (max-width: 700px) { .cv-head { flex-direction: column; } }

@media (max-width: 700px) { .cv-head { flex-direction: column-reverse; } }
.cv-head > div { flex: 1; min-width: 0; }

/* ---------- Thèmes (clic droit sur le bureau) ----------
   Tout le thème suit la teinte --th : rouge (défaut), rose, vert. Le noir et le blanc ne changent pas. */
html.theme-rose { --th: 330; --tl: 1.1; --hr: -27deg; }
html.theme-vert { --th: 138; --tl: .78; --hr: 141deg; }

/* ---------- Disponibilité, langue, Messenger ---------- */
#dispo-badge { display: flex; align-items: center; gap: 6px; margin: 0 8px 0 auto; padding: 3px 10px; border: 1px solid #1e5a1e; border-radius: 10px; background: linear-gradient(#e9ffe3,#c8f0bd); font-size: 11px; cursor: pointer; white-space: nowrap; }
#dispo-badge:hover { background: #fff; }
#dispo-badge.hidden { display: none; }
#dispo-badge .dot, .msn-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #2fb52f; box-shadow: 0 0 0 0 rgba(47,181,47,.6); animation: pulse-dot 2s infinite; }
@keyframes pulse-dot { 70% { box-shadow: 0 0 0 6px rgba(47,181,47,0); } 100% { box-shadow: 0 0 0 0 rgba(47,181,47,0); } }
#taskbar-contact { margin-left: 0; }
#lang-btn { background: none; border: 0; color: #fff; font: bold 11px Tahoma, sans-serif; padding: 0 8px; height: 100%; cursor: pointer; }
#lang-btn:hover { background: rgba(255,255,255,.15); }
.music-body { background: #121212; }
.music-body iframe { display: block; border: 0; }
.msn-head { display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: linear-gradient(#faf9f9,#ebe9ea); border-bottom: 1px solid hsl(var(--th) 25% 75%); font-size: 12px; }
.msn-head .avatar { width: 38px; height: 38px; font-size: 14px; }
.msn-head small { display: flex; align-items: center; gap: 5px; color: #333; }
.msn-body { display: flex; flex-direction: column; background: #fff; }
#msn-log { flex: 1; overflow-y: auto; padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.msn-msg { max-width: 85%; padding: 6px 10px; border-radius: 10px; font-size: 12px; line-height: 1.4; }
.msn-msg.bot { align-self: flex-start; background: #f2f1f1; border: 1px solid hsl(var(--th) 26% 83%); }
.msn-msg.me { align-self: flex-end; background: hsl(var(--th) 100% 95%); border: 1px solid hsl(var(--th) 50% 76%); }
.msn-msg.typing { color: #666; font-style: italic; }
#msn-options { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px; border-top: 1px solid #d4d4d4; background: #ececec; }
#msn-options button { padding: 4px 10px; font-size: 11px; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#f3f3f3,#e5e5e5); cursor: pointer; }
#msn-options button:hover { background: hsl(var(--th) 100% 95%); }
@media (max-width: 900px) { #dispo-text { display: none; } #dispo-badge { padding: 3px 7px; } }
@media (max-width: 700px) { #dispo-badge { display: none; } }

.music-body { display: flex; flex-direction: column; }
.music-body iframe { flex: 1; min-height: 0; width: 100%; height: auto; }
.music-foot { flex: none; margin: 0; padding: 6px 10px; background: #1e1e1e; color: #bbb; font-size: 11px; text-align: center; }
.music-foot a { color: #1ed760; }

.music-tabs { display: flex; gap: 2px; padding: 4px 4px 0; background: #ececec; }
.music-tabs.hidden { display: none; }
.music-tabs button { padding: 4px 10px; font-size: 11px; border: 1px solid #919b9c; border-bottom: 0; border-radius: 3px 3px 0 0; background: #e5e5e5; cursor: pointer; }
.music-tabs button.on { background: #fff; font-weight: bold; }
.music-body iframe.hidden { display: none; }

/* ---------- Navigateur Internet ---------- */
#nav-form { gap: 6px; }
#nav-form input { flex: 1; min-width: 0; padding: 3px 6px; border: 1px solid #a39596; font: 12px Tahoma, sans-serif; -webkit-user-select: text; user-select: text; }
.nav-hint { padding: 3px 8px; background: #fff; border-bottom: 1px solid #acacac; font-size: 11px; }
.nav-hint.hidden { display: none; }
.nav-hint a { color: hsl(var(--th) 80% calc(35% * var(--tl))); }
.nav-body { position: relative; background: #fff; display: flex; }
.nav-body iframe { flex: 1; width: 100%; border: 0; background: #fff; }
.nav-body iframe.hidden, #nav-homepage.hidden { display: none; }
#nav-homepage { flex: 1; overflow: auto; padding: 24px 28px; background: linear-gradient(#f3f3f3, #fff 160px); }
.nav-logo { font: italic bold 38px Georgia, serif; color: #000; margin-bottom: 14px; }
.nav-logo span { color: #f25022; }
#nav-search { display: flex; gap: 6px; max-width: 460px; margin-bottom: 22px; }
#nav-search input { flex: 1; padding: 6px 8px; border: 1px solid #a39596; font: 13px Tahoma, sans-serif; -webkit-user-select: text; user-select: text; }
#nav-search button { padding: 6px 14px; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#f3f3f3,#e5e5e5); cursor: pointer; }
#nav-homepage h4 { margin: 14px 0 6px; padding-bottom: 3px; color: hsl(var(--th) 71% calc(45% * var(--tl))); border-bottom: 1px solid hsl(var(--th) 26% 83%); font-size: 13px; }
.nav-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.nav-links a { color: hsl(var(--th) 80% calc(35% * var(--tl))); text-decoration: underline; cursor: pointer; font-size: 13px; }

#msn-form { display: flex; gap: 6px; padding: 6px 8px; border-top: 1px solid hsl(var(--th) 25% 75%); background: #faf9f9; }
#msn-form.hidden { display: none; }
#msn-input { flex: 1; min-width: 0; padding: 4px 6px; font-size: 12px; border: 1px solid #a39596; border-radius: 3px; }
#msn-form button { padding: 4px 10px; font-size: 11px; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#f3f3f3,#e5e5e5); cursor: pointer; }
#msn-form button:disabled { opacity: .5; cursor: default; }


/* ---------- Visionneuse multi-médias (images, vidéo, PDF) ---------- */
.projet-view { flex-wrap: wrap; }
.projet-image video { width: 100%; height: 100%; object-fit: contain; background: #000; display: block; }
.projet-image:has(img:not(.x)) { background: #f4f4f4; }
.projet-image img { object-fit: contain; }
.pdf-link { position: relative; display: block; width: 100%; height: 100%; }
.pdf-badge { position: absolute; right: 6px; bottom: 6px; font: bold 11px Tahoma, sans-serif !important; background: hsl(var(--th) 67% calc(54% * var(--tl))); color: #fff; padding: 2px 8px; border-radius: 3px; }
.projet-medias { order: 3; flex: 0 0 100%; display: flex; gap: 6px; overflow-x: auto; padding-top: 4px; }
.projet-medias button { flex: 0 0 auto; width: 84px; background: #fff; border: 2px solid hsl(var(--th) 26% 83%); border-radius: 3px; padding: 2px; cursor: pointer; font-family: inherit; }
.projet-medias button.on { border-color: hsl(var(--th) 66% calc(55% * var(--tl))); background: #f2f1f1; }
.projet-medias img { width: 100%; height: 50px; object-fit: cover; display: block; }
.projet-medias small { display: block; font-size: 10px; text-align: center; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }


/* ---------- Zoom : bouton, PDF intégré, loupe plein écran ---------- */
.projet-image { position: relative; }
.projet-image img.zoomable { cursor: zoom-in; }
.zoom-open { position: absolute; top: 6px; right: 6px; z-index: 2; padding: 3px 9px; font: 12px Tahoma, sans-serif; background: rgba(255,255,255,.92); border: 1px solid #555; border-radius: 3px; cursor: pointer; }
.zoom-open:hover { background: #fff; }
.pdf-frame { width: 100%; height: 100%; border: 0; background: #fff; display: block; }
.pdf-open { position: absolute; left: 6px; bottom: 6px; z-index: 2; font: 11px Tahoma, sans-serif !important; background: rgba(255,255,255,.92); color: hsl(var(--th) 80% calc(33% * var(--tl))); padding: 2px 8px; border: 1px solid #555; border-radius: 3px; text-decoration: none; }
.window.is-pdf .projet-view { flex-direction: column; }
.window.is-pdf .projet-image { flex: 0 0 auto; width: 100%; aspect-ratio: 16 / 10; }
.window.is-pdf .projet-info { flex: 0 0 100%; }
.lightbox { position: fixed; inset: 0; z-index: 2147483000; background: rgba(14, 12, 12, .94); display: flex; flex-direction: column; }
.lightbox.hidden { display: none; }
.lb-bar { display: flex; gap: 6px; align-items: center; padding: 8px 12px; color: #fff; font: 13px Tahoma, sans-serif; }
.lb-title { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-bar button { min-width: 36px; height: 32px; font: bold 16px Tahoma, sans-serif; background: #ececec; border: 2px outset #fff; cursor: pointer; }
.lb-bar.pdf button[data-z="in"], .lb-bar.pdf button[data-z="out"], .lb-bar.pdf button[data-z="fit"] { display: none; }
.lb-stage { flex: 1; min-height: 0; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; touch-action: none; cursor: grab; }
.lb-stage.drag { cursor: grabbing; }
.lb-img { max-width: 96%; max-height: 96%; user-select: none; -webkit-user-drag: none; transform-origin: center center; will-change: transform; }
.lb-pdf { width: 100%; height: 100%; border: 0; background: #fff; }


/* ---------- PDF = pages feuilletables ---------- */
.window.is-pdf .projet-image { overflow: hidden; background: #6b6b73; }
.pdf-pages { width: 100%; height: 100%; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 8px; box-sizing: border-box; }
.pdf-pages img { width: 100%; height: auto !important; object-fit: contain; flex: 0 0 auto; box-shadow: 0 1px 6px rgba(0,0,0,.5); background: #fff; }
.lb-bar .lb-count { margin-right: 6px; opacity: .8; }
.lightbox.single [data-z="prev"], .lightbox.single [data-z="next"] { display: none; }

.window.is-pdf .projet-image { aspect-ratio: auto; height: min(58vh, 520px); }
.window.is-pdf .projet-view { padding: 10px 14px; }


/* =========================================================
   ADAPTATION AUX APPAREILS : téléphone, tablette, PC
   ========================================================= */
html, body { height: 100%; }
@supports (height: 100dvh) { body { height: 100dvh; } }
body { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

/* Les fenêtres ne dépassent jamais l'écran ni la barre des tâches */
.window { max-width: 100vw; max-height: calc(100vh - 32px); }
@supports (height: 100dvh) { .window { max-height: calc(100dvh - 32px); } }
.title-bar, .resize-handle { touch-action: none; }
#apple-menu { max-height: calc(100vh - 32px); overflow-y: auto; max-width: 100vw; }

/* Tablette (≈ 701 – 1100 px) */
@media (min-width: 701px) and (max-width: 1100px) {
  .icon { width: 82px; }
  #apple-menu { width: 360px; }
  .explorer-side { width: 150px; }
  #clippy { right: 12px; }
}

/* Écrans tactiles : cibles plus grandes */
@media (pointer: coarse) {
  .close-btn, .zoom-btn, .min-btn { width: 28px; height: 26px; }
  .title-bar { min-height: 32px; }
  .resize-handle { width: 24px; height: 24px; }
  #apple-menu .start-left button, #apple-menu .start-right button { padding-top: 10px; padding-bottom: 10px; }
  .taskbar-item { height: 26px; }
  .icon { padding: 8px 2px; }
  .zoom-open, .lb-bar button { min-height: 36px; }
}

/* Téléphone en paysage ou écrans très bas : tout se compacte */
@media (max-height: 520px) {
  #desktop { padding: 8px; gap: 4px; }
  .icon { width: 70px; padding: 2px; gap: 2px; }
  .icon svg, .icon img { width: 30px; height: 30px; }
  .icon span { font-size: 10px; }
  #clippy, #gallery-invite { display: none; }
  #apple-menu .start-menu-header { padding: 4px 10px; }
  #apple-menu .start-left button, #apple-menu .start-right button { padding-top: 4px; padding-bottom: 4px; }
}

/* Petits téléphones en portrait */
@media (max-width: 420px) {
  .icon { width: 76px; }
  #apple-menu .start-cols { flex-direction: column; }
  #apple-menu .start-right { border-left: 0; border-top: 1px solid hsl(var(--th) 50% 76%); }
  .projet-medias button { width: 72px; }
  .lb-bar { flex-wrap: wrap; }
}

/* Le bureau occupe exactement l'écran : rien ne peut élargir la page (fenêtre qui déborde, zoom involontaire) */
html { overflow: hidden; overscroll-behavior: none; }
body { position: fixed; top: 0; left: 0; right: 0; width: 100%; overscroll-behavior: none; }


/* Corbeille : toujours en bas à droite du bureau, jamais déplacée par les autres icônes */
#icon-trash { position: absolute; right: 14px; bottom: 10px; margin: 0; z-index: 1; }

.icon { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }


/* =========================================================
   MASCOTTE
   ========================================================= */
.avatar-masc { background: linear-gradient(#f5f4f4,hsl(var(--th) 25% 87%)); border-color: #fff; }
.avatar-masc img { object-fit: contain; padding: 2px; }
.clippy-body { width: 56px; height: auto; flex: none; animation: masc-bob 3s ease-in-out infinite; }

/* Fenêtre de bienvenue */
.masc-body { display: flex; flex-direction: column; background: linear-gradient(#f9f9f9,#eceaeb); padding: 14px 16px 10px; gap: 10px; overflow: auto; }
.masc-stage { flex: 1; display: flex; align-items: center; gap: 14px; min-height: 0; }
.masc-img { width: 130px; max-width: 34%; height: auto; flex: none; animation: masc-bob 3.2s ease-in-out infinite; filter: drop-shadow(0 3px 3px rgba(0,0,0,.2)); }
.masc-img.talking { animation: masc-talk .32s ease-in-out infinite; }
.masc-bubble { position: relative; flex: 1; min-height: 96px; padding: 12px 14px; background: #fff; border: 2px solid hsl(var(--th) 70% calc(36% * var(--tl))); border-radius: 14px; font-size: 14px; line-height: 1.5; color: #2c2526; cursor: default; box-shadow: 0 2px 0 hsl(var(--th) 70% calc(36% * var(--tl)) / .25); }
.masc-bubble::before { content: ''; position: absolute; left: -11px; top: 38px; width: 18px; height: 18px; background: #fff; border-left: 2px solid hsl(var(--th) 70% calc(36% * var(--tl))); border-bottom: 2px solid hsl(var(--th) 70% calc(36% * var(--tl))); transform: rotate(45deg); }
.masc-bubble p { margin: 0; }
.masc-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; min-height: 34px; }
.masc-actions button { padding: 6px 14px; font: 12px Tahoma, sans-serif; border: 1px solid #3f3537; border-radius: 4px; background: linear-gradient(#fff,#e3e3e0); cursor: pointer; }
.masc-actions button.main { background: linear-gradient(hsl(var(--th) 79% calc(68% * var(--tl))),hsl(var(--th) 74% calc(53% * var(--tl)))); color: #fff; font-weight: bold; }
.masc-actions button:hover { filter: brightness(1.06); }
.masc-dots { display: flex; gap: 6px; justify-content: center; }
.masc-dots i { width: 7px; height: 7px; border-radius: 50%; background: hsl(var(--th) 26% 83%); }
.masc-dots i.on { background: hsl(var(--th) 74% calc(53% * var(--tl))); }
@keyframes masc-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes masc-talk { 0%,100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-3px) scale(1.03, .98); } }
@media (prefers-reduced-motion: reduce) { .masc-img, .clippy-body { animation: none !important; } }

/* Bulle discrète pour les visiteurs qui reviennent */
#masc-toast { position: fixed; left: 12px; bottom: 44px; z-index: 9300; display: flex; align-items: flex-end; gap: 8px; max-width: min(360px, calc(100vw - 24px)); padding: 8px 10px; background: #fff; border: 2px solid hsl(var(--th) 70% calc(36% * var(--tl))); border-radius: 14px; box-shadow: 0 4px 12px rgba(0,0,0,.3); animation: masc-in .35s ease-out; }
#masc-toast.hidden { display: none; }
#masc-toast img { flex: none; height: auto; }
.masc-toast-main { flex: 1; min-width: 0; font-size: 12.5px; line-height: 1.4; color: #2c2526; }
.masc-toast-main p { margin: 2px 0 0; }
#masc-toast-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
#masc-toast-actions:empty { display: none; }
#masc-toast-actions button { padding: 3px 10px; font: 11.5px Tahoma, sans-serif; border: 1px solid #3f3537; border-radius: 4px; background: linear-gradient(hsl(var(--th) 79% calc(68% * var(--tl))),hsl(var(--th) 74% calc(53% * var(--tl)))); color: #fff; cursor: pointer; }
#masc-toast-close { align-self: flex-start; border: 0; background: none; font-size: 18px; line-height: 1; cursor: pointer; color: #556; padding: 0 2px; }
@keyframes masc-in { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }

@media (max-width: 520px) {
  .masc-stage { flex-direction: column; text-align: left; }
  .masc-img { width: 90px; max-width: none; }
  .masc-bubble { width: 100%; box-sizing: border-box; font-size: 13px; min-height: 80px; }
  .masc-bubble::before { left: 40px; top: -10px; border-left: 2px solid hsl(var(--th) 70% calc(36% * var(--tl))); border-top: 2px solid hsl(var(--th) 70% calc(36% * var(--tl))); border-bottom: 0; }
  #masc-toast { right: 12px; }
}
@media (max-height: 520px) { #masc-toast { display: none; } }

/* ===== BUGSY : virus ami (virus.js) ===== */
#guide{position:fixed;left:0;top:0;z-index:9200;width:var(--w,92px);cursor:grab;touch-action:none;user-select:none;outline:none}
#guide.drag{cursor:grabbing}
#guide svg{display:block;width:100%;height:auto;overflow:visible}

#guide .gd-body{transform-origin:50% 100%;filter:drop-shadow(0 4px 3px rgba(0,0,0,.28));animation:gd-bob 3s ease-in-out infinite}
#guide.walk .gd-body{animation:gd-walk .28s ease-in-out infinite}
#guide.talk .gd-body{animation:gd-talk .3s ease-in-out infinite}
#guide.jump .gd-body{animation:gd-jump .6s cubic-bezier(.3,1.5,.5,1)}
#guide.pop .gd-body{animation:gd-pop .7s cubic-bezier(.3,1.7,.5,1)}
#guide.talk .mo{animation:gd-mouth .22s ease-in-out infinite;transform-box:fill-box;transform-origin:top}
#guide.sleep .gd-body{animation:gd-snore 3.5s ease-in-out infinite}
#guide.sleep .ey{animation:none;transform:scaleY(.12)}
#guide.sleep::after{content:'z Z z';position:absolute;right:-8px;top:-14px;font:bold 14px Tahoma,sans-serif;color:hsl(var(--th) 66% calc(49% * var(--tl)));animation:gd-z 2s ease-in-out infinite}
@keyframes gd-bob{0%,100%{transform:translateY(0)}50%{transform:translateY(-5px)}}
@keyframes gd-walk{0%,100%{transform:translateY(0) rotate(-5deg)}50%{transform:translateY(-9px) rotate(5deg)}}
@keyframes gd-talk{0%,100%{transform:scale(1)}50%{transform:scale(1.04,.96)}}
@keyframes gd-jump{0%{transform:scale(1.15,.8)}40%{transform:translateY(-26px) scale(.92,1.1)}100%{transform:none}}
@keyframes gd-pop{0%{transform:scale(0) rotate(-120deg)}100%{transform:none}}
@keyframes gd-mouth{50%{transform:scaleY(.4)}}
@keyframes gd-snore{0%,100%{transform:scale(1)}50%{transform:scale(1.05,.95)}}
@keyframes gd-z{0%{opacity:0;transform:translateY(6px)}50%{opacity:1}100%{opacity:0;transform:translateY(-10px)}}
#guide-bubble{position:absolute;left:calc(100% + 10px);bottom:35%;width:250px;padding:10px 12px;background:#fff;border:2px solid hsl(var(--th) 70% calc(36% * var(--tl)));border-radius:12px;font:13px/1.45 Tahoma,sans-serif;color:#2c2526;box-shadow:0 3px 10px rgba(0,0,0,.3);cursor:default}
#guide-bubble.left{left:auto;right:calc(100% + 10px)}
#guide-bubble.down{bottom:auto;top:5%}
#guide-bubble.hidden{display:none}
#guide-bubble p{margin:0;min-height:1.4em}
.gd-btns{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}.gd-btns:empty{display:none}
.gd-btns button,.gd-bt button{padding:4px 12px;font:12px Tahoma,sans-serif;border:1px solid #3f3537;border-radius:3px;background:linear-gradient(#fff,#e3e3e3);cursor:pointer}
.gd-btns button.main,.gd-bt button.main{box-shadow:inset 0 0 0 2px hsl(var(--th) 24% 76%)}
#gd-ring{position:fixed;z-index:9190;border:3px solid #fff;border-radius:8px;pointer-events:none;box-shadow:0 0 0 4px rgba(255,255,255,.35),0 0 18px #fff;transition:all .5s;animation:gd-pulse .9s ease-in-out infinite alternate}
@keyframes gd-pulse{to{box-shadow:0 0 0 9px rgba(255,255,255,.15),0 0 26px #fff}}
.gd-tb{display:flex;justify-content:space-between;align-items:center;padding:5px 8px;border-radius:7px 7px 0 0;background:linear-gradient(hsl(var(--th) 80% calc(47% * var(--tl))),hsl(var(--th) 80% calc(62% * var(--tl))) 12%,hsl(var(--th) 80% calc(46% * var(--tl))) 88%,hsl(var(--th) 80% calc(36% * var(--tl))));color:#fff;font-weight:bold}
.gd-tb i{font-style:normal;background:#e0482b;border:1px solid #fff;border-radius:3px;padding:0 6px}
.gd-bd{padding:12px}.gd-bd p{margin:0 0 8px}
@media(max-width:700px){#guide{--w:70px}#guide-bubble,#guide-bubble.left,#guide-bubble.down{position:fixed;left:8px;right:8px;top:auto;width:auto;bottom:calc(var(--tbh,36px) + 100px)}}
@media(prefers-reduced-motion:reduce){#guide .gd-body,#guide .mo{animation:none!important}}   /* la lueur jaune (#gd-ring) garde sa pulsation : c'est un simple halo doux */

#guide.beam .gd-body{animation:gd-beam 1s steps(10) both}
@keyframes gd-beam{0%{opacity:0;filter:brightness(3) hue-rotate(40deg);clip-path:inset(0 0 100% 0)}100%{opacity:1;clip-path:inset(0)}}
#gd-run{position:fixed;left:50%;top:38%;z-index:9450;width:380px;max-width:92vw;transform:translate(-50%,-50%);background:#ececec;border:1px solid hsl(var(--th) 80% calc(44% * var(--tl)));border-radius:8px 8px 0 0;font:12px Tahoma,sans-serif;box-shadow:4px 6px 18px rgba(0,0,0,.5)}
#gd-run[hidden]{display:none}
#gd-run input{width:100%;box-sizing:border-box;padding:4px;font:12px Tahoma,sans-serif;border:1px solid #a39596}
.gd-err{color:hsl(var(--th) 100% calc(40% * var(--tl)));min-height:2.6em;margin:6px 0 0}.gd-bt{display:flex;justify-content:flex-end;gap:8px}

/* ===== Animations de fenêtres + assistant intégré (fenetres.js, guide-os.js) ===== */
.window.is-opening { animation: none; }
.taskbar-item:active { padding-top: 1px; box-shadow: inset 0 2px 3px rgba(0,0,0,.5); }
#gd-tray { background: none; border: 0; padding: 0 4px; height: 100%; cursor: pointer; }
#gd-tray:hover { filter: brightness(1.25); }
#gd-tray img { display: block; }
#gd-menu { position: fixed; z-index: 9300; min-width: 210px; padding: 2px; background: #fff; border: 1px solid #acacac; box-shadow: 2px 2px 4px rgba(0,0,0,.4); font: 12px Tahoma, sans-serif; }
#gd-menu[hidden] { display: none; }
#gd-menu button { display: block; width: 100%; padding: 4px 22px; border: 0; background: none; text-align: left; font: inherit; cursor: pointer; }
#gd-menu button:hover, #gd-menu button:focus { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; outline: 0; }
#gd-menu .off, #gd-menu .off:hover { color: #777; background: none; cursor: default; }
#gd-balloon { position: fixed; right: 10px; bottom: 42px; z-index: 9460; width: 240px; padding: 8px 26px 8px 10px; background: #fff; border: 1px solid #000; border-radius: 8px; font: 12px Tahoma, sans-serif; cursor: pointer; box-shadow: 2px 3px 8px rgba(0,0,0,.4); animation: gd-bal .3s ease-out; }
#gd-balloon i { position: absolute; right: 8px; top: 4px; font-style: normal; }
#gd-balloon p { margin: 4px 0 0; }
#gd-balloon::after { content: ''; position: absolute; right: 16px; bottom: -9px; border: 9px solid transparent; border-top-color: #000; border-bottom: 0; }
@keyframes gd-bal { from { opacity: 0; transform: translateY(8px); } }
#guide.sit .gd-body { animation: gd-sit 3s ease-in-out infinite; }
@keyframes gd-sit { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }

/* poses de l'assistant (bras = .arm.l / .arm.r dans le SVG, pivot à l'épaule) */
#guide .arm.l { transform-origin: 20px 66px; transition: transform .25s; }
#guide .arm.r { transform-origin: 100px 66px; transition: transform .25s; }
#guide.pose-wave .arm.r { animation: gd-wave .45s ease-in-out infinite alternate; }
#guide.pose-point-l .arm.l { transform: rotate(45deg); }
#guide.pose-think .arm.l { transform: rotate(110deg); }

#guide.pose-cheer .arm.r { animation: gd-cheer-r .3s ease-in-out infinite alternate; }
#guide.pose-cheer .arm.l { animation: gd-cheer-l .3s ease-in-out infinite alternate; }
#guide.pose-cheer .gd-body { animation: gd-jump .6s ease-in-out infinite; }
@keyframes gd-wave { from { transform: rotate(-100deg); } to { transform: rotate(-125deg); } }
@keyframes gd-cheer-r { from { transform: rotate(-110deg); } to { transform: rotate(-135deg); } }
@keyframes gd-cheer-l { from { transform: rotate(110deg); } to { transform: rotate(135deg); } }
@media (prefers-reduced-motion: reduce) { #guide .arm { animation: none !important; } }

/* visite v2 : projecteur, Pixel agrandi, bulle lisible */
#gd-spot { position: fixed; z-index: 9180; pointer-events: none; border: 3px solid #fff; border-radius: 10px; box-shadow: 0 0 0 9999px rgba(26, 22, 23, .62), 0 0 22px #fff; transition: all .55s cubic-bezier(.4,0,.2,1); }
@media (min-width: 701px) { body.gd-tour #guide { --w: 124px; } body.gd-tour #guide-bubble { width: 310px; font-size: 14px; } }
.gd-step { margin-bottom: 4px; font: bold 11px Tahoma, sans-serif; color: hsl(var(--th) 70% calc(36% * var(--tl))); }
.gd-prog { height: 4px; margin-top: 8px; overflow: hidden; border-radius: 2px; background: #d6d6d6; }
.gd-prog b { display: block; width: 0; height: 100%; background: #37c837; transition: width .1s linear; }
#guide.pose-point-r .arm.r { transform: rotate(-45deg); }

/* menu clic droit de la barre des tâches + économiseur d'écran (extras.js) */
#tb-menu { position: fixed; z-index: 9500; min-width: 210px; padding: 2px; background: #fff; border: 1px solid #acacac; box-shadow: 3px 3px 5px rgba(0,0,0,.35); font: 12px Tahoma, sans-serif; }
#tb-menu.hidden { display: none; }
#tb-menu button { display: block; width: 100%; padding: 5px 24px; text-align: left; background: none; border: 0; font: inherit; cursor: default; }
#tb-menu button:hover:not(:disabled) { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; }
#tb-menu button:disabled { color: #9a9a9a; }
#tb-menu hr { margin: 2px 0; border: 0; border-top: 1px solid #d4d4d4; }
#ss { position: fixed; inset: 0; z-index: 9600; width: 100%; height: 100%; background: #0a0809; cursor: none; }
#ss[hidden] { display: none; }

/* tuto en vrais gestes : jamais d'overlay, « Passer » toujours visible, cibles tactiles confortables */
.gd-skip { display: block; margin-top: 8px; padding: 4px 10px; font: 12px Tahoma, sans-serif; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#fff, #e3e3e3); cursor: pointer; }
@media (hover: none) and (pointer: coarse), (max-width: 700px) { .gd-skip, .gd-btns button { min-height: 44px; min-width: 44px; font-size: 14px; } }
#gd-ring.dim { animation: none; box-shadow: 0 0 0 9999px rgba(26, 22, 23, .62), 0 0 22px #fff; }
#gd-dim { position: fixed; inset: 0; z-index: 9185; background: rgba(26, 22, 23, .6); pointer-events: none; transition: opacity .3s; }
.window.gd-hl { box-shadow: 0 0 0 4px #fff, 0 0 26px 4px rgba(255,255,255,.85), 4px 4px 12px rgba(0,0,0,.45); }
.title-bar.gd-hl { box-shadow: inset 0 0 0 3px #fff, inset 0 0 14px #fff; }
button.gd-hl { box-shadow: 0 0 0 3px #fff, 0 0 12px 3px rgba(255,255,255,.9); position: relative; z-index: 2; }
#gd-ring { transition: all .18s ease-out; }
#gd-dim { transition: opacity .2s; }
.taskbar-item.gd-hl { box-shadow: 0 0 0 3px #fff, 0 0 12px 3px rgba(255,255,255,.9); position: relative; z-index: 2; }

/* tuto : la lueur et le trou du grisé glissent d'une appli à l'autre (plus d'apparition instantanée) */
#gd-ring { transition: left .45s cubic-bezier(.4,0,.2,1), top .45s cubic-bezier(.4,0,.2,1), width .45s cubic-bezier(.4,0,.2,1), height .45s cubic-bezier(.4,0,.2,1), opacity .3s; }
#gd-dim { transition: opacity .3s, clip-path .45s cubic-bezier(.4,0,.2,1); }
body.gd-tour .window, body.gd-tour .title-bar, body.gd-tour .window-controls button, body.gd-tour .taskbar-item { transition: box-shadow .4s ease; }

/* renommer (renommer.js) */
#rn-menu { position: fixed; z-index: 9500; min-width: 210px; padding: 2px; background: #fff; border: 1px solid #acacac; box-shadow: 3px 3px 5px rgba(0,0,0,.35); font: 12px Tahoma, sans-serif; }
#rn-menu.hidden { display: none; }
#rn-menu button { display: block; width: 100%; padding: 5px 24px; text-align: left; background: none; border: 0; font: inherit; color: #000; cursor: default; white-space: nowrap; }
#rn-menu button:hover:not(:disabled) { background: hsl(var(--th) 60% calc(48% * var(--tl))); color: #fff; }
#rn-menu button:disabled { color: #9a9a9a; }
.rn-input { width: 100%; min-width: 70px; box-sizing: border-box; padding: 1px 2px; font: inherit; font-size: 11px; text-align: center; color: #000; background: #fff; border: 1px solid hsl(var(--th) 60% calc(48% * var(--tl))); border-radius: 0; outline: none; user-select: text; -webkit-user-select: text; }

/* bulles de Pixel : elles « poppent » depuis Pixel, rebondissent à chaque nouveau message et s'effacent en douceur */
#guide-bubble { transform-origin: 0 85%; }
#guide-bubble.left { transform-origin: 100% 85%; }
#guide-bubble.down { transform-origin: 0 15%; }
#guide-bubble:not(.hidden) { animation: gd-bub-in .34s cubic-bezier(.34,1.56,.64,1) both; }
#guide-bubble.leaving { animation: gd-bub-out .16s ease-in forwards; pointer-events: none; }
#guide-bubble.swap { animation: gd-bub-swap .26s cubic-bezier(.34,1.56,.64,1); }
@keyframes gd-bub-in { from { opacity: 0; transform: scale(.55) translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes gd-bub-out { to { opacity: 0; transform: scale(.9) translateY(4px); } }
@keyframes gd-bub-swap { from { transform: scale(.93); opacity: .55; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) {            /* mouvement réduit : simple fondu, sans zoom */
  @keyframes gd-bub-in { from { opacity: 0; } to { opacity: 1; } }
  @keyframes gd-bub-out { to { opacity: 0; } }
  @keyframes gd-bub-swap { from { opacity: .5; } to { opacity: 1; } }
}

/* =========================================================
   ÉCRAN CRT (crt.js). Couches, de bas en haut : lignes + grille RVB > grain
   > cadre arrondi > barre de rafraîchissement > reflet. Rien ne bloque les clics.
   --crt = intensité (0 à 1). 0.62 par défaut.
   IMPORTANT : #crt n'a ni opacity, ni filter, ni will-change, sinon les backdrop-filter des couches ne voient plus la page.
   ========================================================= */
#crt { --crt: .60; position: fixed; inset: 0; z-index: 99990; pointer-events: none; overflow: hidden; }
#crt.off { display: none; }
#crt > i { position: absolute; inset: 0; display: block; }
#crt .crt-scan {
  background:
    repeating-linear-gradient(to bottom, rgba(0,0,0,calc(.26 * var(--crt))) 0, rgba(0,0,0,calc(.26 * var(--crt))) 1px, transparent 1px, transparent 3px),
    linear-gradient(90deg, rgba(255,40,40,calc(.11 * var(--crt))) 0 33.3%, rgba(40,255,40,calc(.08 * var(--crt))) 33.3% 66.6%, rgba(60,60,255,calc(.11 * var(--crt))) 66.6% 100%);
  background-size: 100% 3px, 3px 100%;
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 60px), rgba(0,0,0,.3) calc(100% - 36px));
  mask-image: linear-gradient(to bottom, #000 calc(100% - 60px), rgba(0,0,0,.3) calc(100% - 36px));
  animation: crt-flick 6s infinite; }
#crt .crt-noise { inset: -64px; background-size: 96px 96px; opacity: calc(.07 * var(--crt)); animation: crt-grain .45s steps(1) infinite; }
/* la vitre : trou arrondi dans un grand cadre noir, ombres internes qui « bombent » les bords */
#crt .crt-glass { inset: 5px; border-radius: 24px / 28px;
  box-shadow: 0 0 0 100vmax #060606, inset 0 0 calc(90px * var(--crt)) rgba(0,0,0,calc(.55 * var(--crt))), inset 0 0 16px rgba(0,0,0,.7), inset 0 0 2px 1px rgba(255,255,255,.2); }
#crt::after { content: ''; position: absolute; inset: 5px; border-radius: 24px / 28px;
  background: radial-gradient(ellipse 55% 36% at 22% 9%, rgba(255,255,255,calc(.16 * var(--crt))), transparent 70%),
              radial-gradient(ellipse 90% 90% at 50% 50%, transparent 65%, rgba(0,0,0,calc(.22 * var(--crt))) 100%); }
#crt .crt-band { height: 22vh; bottom: auto; background: linear-gradient(transparent, rgba(255,255,255,calc(.07 * var(--crt))), transparent); transform: translateY(-24vh); animation: crt-roll 8s linear infinite; }
@keyframes crt-flick { 0%, 100% { opacity: 1; } 3% { opacity: .93; } 6% { opacity: 1; } 52% { opacity: .97; } 54% { opacity: 1; } }
@keyframes crt-roll { to { transform: translateY(105vh); } }
@keyframes crt-grain { 0% { transform: translate(0,0); } 25% { transform: translate(-23px,17px); } 50% { transform: translate(31px,-40px); } 75% { transform: translate(-45px,-12px); } }
@media (prefers-reduced-motion: reduce) { #crt .crt-scan, #crt .crt-noise, #crt .crt-band { animation: none; } }

/* écran CRT actif : la barre des tâches est décalée vers l'intérieur pour que « démarrer » et l'horloge ne soient plus rognés par les coins arrondis */
html.crt-on #menu-bar { padding-left: 14px; padding-right: 14px; box-sizing: border-box; }
html.crt-on .start-button { border-top-left-radius: 12px; border-bottom-left-radius: 12px; border-left: 1px solid hsl(var(--th) 89% calc(19% * var(--tl))); }

/* =========================================================
   BARRE DES TÂCHES : boutons plus visibles (contraste, taille, relief)
   ========================================================= */
.start-button { font-size: 15px; font-weight: 800; box-shadow: inset 1px 1px 0 rgba(255,255,255,.7), inset 0 -2px 3px hsl(var(--th) 100% calc(12% * var(--tl)) / .35), 0 0 12px hsl(var(--th) 100% 72% / .7); text-shadow: 0 1px 0 rgba(0,0,0,.9), 0 0 3px rgba(0,0,0,.8); }
.taskbar-item { height: 26px; padding: 0 12px; font-size: 12px; font-weight: 700; background: linear-gradient(to bottom, #6a6a76 0%, #3a3a43 100%); border: 1px solid #b4b4c0; text-shadow: 0 1px 1px rgba(0,0,0,.8); box-shadow: inset 0 1px 0 rgba(255,255,255,.3); }
.taskbar-item:hover { background: linear-gradient(to bottom, #7c7c89 0%, #484853 100%); }
.taskbar-item.is-active { background: linear-gradient(to bottom, #15151a 0%, #3a3a43 100%); border-color: hsl(var(--th) 100% 68%); box-shadow: inset 0 1px 3px rgba(0,0,0,.6), 0 0 6px hsl(var(--th) 100% 60% / .6); }
#dispo-badge { padding: 4px 12px; font-size: 12px; font-weight: 700; color: #0a360a; border: 1px solid #0f4a0f; background: linear-gradient(#f2ffee,#bfeab2); box-shadow: 0 0 6px rgba(80,220,80,.45); }
#taskbar-contact { padding: 4px 14px; font-size: 12px; font-weight: 700; color: #000; border: 1px solid #fff; background: linear-gradient(#ffffff,#dcdcdc); box-shadow: 0 0 6px rgba(255,255,255,.35); }
#lang-btn, #vol-btn, #gd-tray { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.35); border-radius: 3px; height: 24px; margin: 0 2px; color: #fff; text-shadow: 0 1px 1px #000; }
#lang-btn { font: 800 12px Tahoma, sans-serif; padding: 0 9px; }
#vol-btn { font-size: 16px; padding: 0 8px; }
#gd-tray { padding: 0 6px; }
#lang-btn:hover, #vol-btn:hover, #gd-tray:hover { background: rgba(255,255,255,.3); }
#clock { font-size: 12px; font-weight: 700; color: #fff; border-left: 1px solid #8a8a96; }
/* lignes CRT presque absentes sur la barre des tâches */
#crt .crt-scan { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 60px), rgba(0,0,0,.12) calc(100% - 36px)); mask-image: linear-gradient(to bottom, #000 calc(100% - 60px), rgba(0,0,0,.12) calc(100% - 36px)); }

/* =========================================================
   PROPOSITION PLEIN ÉCRAN (plein-ecran.js)
   ========================================================= */
#fs-ask { position: fixed; z-index: 9900; left: 50%; top: 40%; transform: translate(-50%, -50%); width: 380px; max-width: 92vw; background: #ececec; color: #000; font: 12px Tahoma, sans-serif; border: 3px solid hsl(var(--th) 80% calc(45% * var(--tl))); border-radius: 8px 8px 3px 3px; box-shadow: 4px 8px 22px rgba(0,0,0,.65); animation: fs-in .3s ease-out; }
#fs-ask .fs-title { display: flex; justify-content: space-between; align-items: center; padding: 4px 6px 4px 10px; color: #fff; font-weight: 700; font-size: 13px; background: linear-gradient(to bottom, hsl(var(--th) 100% 66%), hsl(var(--th) 80% calc(40% * var(--tl)))); text-shadow: 1px 1px 1px rgba(0,0,0,.6); }
#fs-ask .fs-x { width: 22px; height: 22px; border: 1px solid #fff; border-radius: 3px; background: hsl(var(--th) 80% calc(45% * var(--tl))); color: #fff; font-weight: 700; cursor: pointer; }
#fs-ask .fs-body { display: flex; gap: 14px; align-items: center; padding: 16px 16px 8px; }
#fs-ask .fs-ico { font-size: 34px; line-height: 1; }
#fs-ask p { margin: 0 0 6px; font-size: 13px; }
#fs-ask small { color: #444; }
#fs-ask .fs-btns { display: flex; justify-content: flex-end; gap: 8px; padding: 8px 16px 14px; }
#fs-ask .fs-btns button { min-width: 96px; padding: 5px 12px; font: 700 12px Tahoma, sans-serif; border: 1px solid #3f3537; border-radius: 3px; background: linear-gradient(#fff,#ddd); cursor: pointer; }
#fs-ask .fs-btns .fs-ok { border-color: hsl(var(--th) 80% calc(40% * var(--tl))); box-shadow: 0 0 0 2px hsl(var(--th) 100% 75% / .6); }
#fs-ask .fs-btns button:hover { background: #fff; }
@keyframes fs-in { from { opacity: 0; transform: translate(-50%, -46%); } to { opacity: 1; transform: translate(-50%, -50%); } }

/* =========================================================
   BARRE DES TÂCHES : boutons relevés d'un petit peu (taille inchangée), décollés du bord bas de l'écran
   ========================================================= */
#menu-bar { height: 36px; padding-bottom: 5px; box-sizing: border-box; }
#desktop { margin-bottom: 36px; }
#apple-menu { bottom: 36px; max-height: calc(100vh - 36px); }
.window { max-height: calc(100vh - 36px); }
@supports (height: 100dvh) { .window { max-height: calc(100dvh - 36px); } }

/* résumé pour les moteurs de recherche et les IA : présent dans la page mais invisible (accessible aux lecteurs d'écran) */
.seo-resume { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
