/* ===== Accueil guilhem.xyz : Amiga 500 ===== */
.gx { --beige:#E7DFC8; --creme:#F3EEDF; --brun:#8C7B5E; --noir:#121008; --bleu:#0055AA; --orange:#FF8800; --blanc:#fff;
  --arc: linear-gradient(90deg,#E23B2E 0 20%,#F5A623 20% 40%,#F8E71C 40% 60%,#39B54A 60% 80%,#2E86DE 80%);
  font-family: 'Share Tech Mono', ui-monospace, Consolas, monospace; color: var(--noir); }
.gx h1, .gx h2, .gx h3 { font-family: 'Pixelify Sans', 'Share Tech Mono', monospace; font-weight: 600; line-height: 1.08; margin: 0 0 .8rem; }
.gx h2 { font-size: clamp(1.7rem, 4vw, 2.6rem); }
.gx p { margin: 0 0 1rem; }
.gx-chemin { display: inline-block; font-size: .85rem; letter-spacing: .06em; color: var(--brun); margin-bottom: .9rem !important; padding-bottom: 4px; background: var(--arc) bottom / 100% 3px no-repeat; }
.gx-intro { color: #4a4232; max-width: 38rem; }
.gx-a-completer { background: #F8E71C; color: var(--noir); padding: 0 .2em; }

/* Touches de clavier */
.gx-touche { display: inline-block; font: inherit; font-size: 1rem; text-decoration: none; color: var(--noir); cursor: pointer;
  background: var(--creme); border: 2px solid var(--brun); border-radius: 7px; padding: .6rem 1.1rem;
  box-shadow: 0 5px 0 var(--brun), 0 7px 12px rgba(40,30,10,.25); transform: translateY(0);
  transition: transform .08s ease, box-shadow .08s ease; }
.gx-touche:hover { color: var(--noir); background: #fff; }
.gx-touche:active, .gx-touche.is-pressee { transform: translateY(4px); box-shadow: 0 1px 0 var(--brun), 0 2px 4px rgba(40,30,10,.25); }
.gx-touche:focus-visible { outline: 3px solid var(--bleu); outline-offset: 3px; }
.gx-touche-orange { background: var(--orange); }
.gx-touche-orange:hover { background: #ff9a26; }
.gx-touches { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 1.5rem; }

/* ----- Scène : récit à gauche, machine à droite (collante) ----- */
.gx-scene { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(1.5rem, 4vw, 4rem); max-width: 1180px; margin: 0 auto; padding: clamp(2rem, 5vw, 4rem) 0 0; }
.gx-recit { grid-column: 1; grid-row: 1; }
.gx-colonne-machine { grid-column: 2; grid-row: 1; }
.gx-machine { position: sticky; top: 1rem; margin: 0; }
.gx-machine { position: sticky; } /* la position de l'écran est relative à la machine (sticky crée aussi un repère) */
.gx-svg { display: block; width: 100%; height: auto; overflow: visible; }
.gx-hero { min-height: min(78vh, 680px); display: flex; flex-direction: column; justify-content: center; }
.gx-titre { font-size: clamp(2.4rem, 6vw, 4.2rem); }
.gx-souligne { background: var(--arc) left 92% / 100% .14em no-repeat; }
.gx-chapo { font-size: clamp(1.05rem, 1.6vw, 1.2rem); max-width: 36rem; }

/* Étapes de la veille */
.gx-veille { padding-top: 2rem; }
.gx-etapes { list-style: none; margin: 2rem 0 2.5rem; padding: 0; }
.gx-etape { min-height: 62vh; display: flex; flex-direction: column; justify-content: center; padding: 1.5rem 0; opacity: .45; transition: opacity .3s ease; }
.gx-etape.is-active { opacity: 1; }
.gx-etape-vide { min-height: 30vh; opacity: 1; }
.gx-etape-tete { display: flex; align-items: center; gap: .7rem; font-size: .85rem; color: var(--brun); margin-bottom: .6rem; }
.gx-pastille { width: 16px; height: 18px; border-radius: 2px; border: 1px solid rgba(0,0,0,.35); flex: none; }
.gx-etape h3 { font-size: clamp(1.35rem, 2.6vw, 1.8rem); }
.gx-etape h3 a { text-decoration: none; color: var(--noir); }
.gx-etape h3 a:hover { color: var(--bleu); }
.gx-etape .gx-extrait { color: #4a4232; }
.gx-lire { color: var(--bleu); }

/* ----- Écran du moniteur (Workbench) ----- */
.gx-ecran { position: absolute; border-radius: 9% / 12%; overflow: hidden; background: #05080f; }
.gx-ecran-contenu { position: absolute; inset: 0; background: var(--bleu); color: #fff; font-size: clamp(7px, 1.05vw, 12.5px); line-height: 1.35; display: flex; flex-direction: column;
  opacity: 0; transform: scaleY(.01); filter: brightness(3); }
.gx-ecran.is-allume .gx-ecran-contenu { animation: gx-allumage .9s ease-out forwards; }
@keyframes gx-allumage { 0% { opacity: 1; transform: scaleY(.01) scaleX(.6); filter: brightness(4); } 40% { transform: scaleY(.02) scaleX(1); } 70% { transform: scaleY(1); filter: brightness(1.6); } 100% { opacity: 1; transform: none; filter: none; } }
.gx-barre { display: flex; justify-content: space-between; background: #fff; color: var(--bleu); padding: .25em .7em; font-weight: 700; }
.gx-barre-info { color: var(--orange); }
.gx-fenetre { flex: 1; margin: .7em; border: 2px solid #fff; display: flex; flex-direction: column; min-height: 0; }
.gx-fenetre-titre { background: repeating-linear-gradient(0deg, #fff 0 1px, var(--bleu) 1px 3px); padding: .15em .6em; line-height: 1; }
.gx-fenetre-titre span { background: #fff; color: var(--bleu); padding: 0 .4em; }
.gx-sortie { flex: 1; margin: 0; padding: .5em .7em; font: inherit; white-space: pre-wrap; overflow: hidden; color: #fff; }
.gx-sortie .o { color: var(--orange); }
.gx-sortie .c::after { content: "█"; color: var(--orange); animation: gx-curseur 1s steps(1) infinite; }
@keyframes gx-curseur { 50% { opacity: 0; } }
.gx-balayage { position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.22) 0 1px, transparent 1px 3px),
              radial-gradient(ellipse at center, rgba(255,255,255,.10) 0%, transparent 55%, rgba(0,0,0,.45) 100%);
  box-shadow: inset 0 0 30px rgba(0,0,0,.6); }
.gx-ecran.is-allume { box-shadow: 0 0 40px rgba(46,134,222,.35); }

/* Touches du clavier SVG, voyants */
.gx-touche-svg { transition: transform .06s ease, fill .06s ease; transform-box: fill-box; transform-origin: center; }
.gx-touche-svg.is-pressee { transform: translateY(1.6px) scale(.94); fill: #c4bba2; }
.gx-led-lecteur.is-lit, .gx-led-amiga.is-lit { fill: #FF8800; filter: drop-shadow(0 0 3px #FF8800); }
.gx-volante { transform-box: view-box; }

/* ----- Sections suivantes ----- */
.gx-section { max-width: 1180px; margin: clamp(4rem, 9vw, 7rem) auto 0; }

/* Frigo amande + listings d'imprimante */
.gx-frigo { position: relative; background: linear-gradient(90deg, #EADBC2, #F2E6D1 40%, #E6D5B9); border: 2px solid #C9B794; border-radius: 22px;
  padding: clamp(1.5rem, 4vw, 3rem) clamp(1rem, 3vw, 2.5rem) clamp(2rem, 4vw, 3rem); margin: 1.5rem 0 2rem; box-shadow: inset -12px 0 24px rgba(120,90,40,.12), 0 10px 30px rgba(60,40,10,.15); }
.gx-poignee { position: absolute; left: 10px; top: 18%; width: 10px; height: 64%; border-radius: 6px; background: linear-gradient(90deg, #c9b794, #f3eadb, #c9b794); }
.gx-listings { list-style: none; margin: 0; padding: 0 0 0 1rem; display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 2.2rem 1.6rem; }
.gx-listing { position: relative; background:
    radial-gradient(circle, #e9dfc9 3.2px, transparent 3.6px) left 6px top 6px / 12px 18px repeat-y,
    radial-gradient(circle, #e9dfc9 3.2px, transparent 3.6px) right 6px top 6px / 12px 18px repeat-y,
    repeating-linear-gradient(180deg, #fbfdf7 0 36px, #e4f0df 36px 72px);
  padding: 1.6rem 1.9rem 1.8rem; box-shadow: 0 6px 14px rgba(60,40,10,.18); transform: rotate(var(--r, -1deg));
  clip-path: polygon(0 0, 100% 0, 100% 100%, 92% 98%, 84% 100%, 76% 98%, 68% 100%, 60% 98%, 52% 100%, 44% 98%, 36% 100%, 28% 98%, 20% 100%, 12% 98%, 4% 100%, 0 98%);
  font-size: .95rem; color: #2a2a2a; text-shadow: .3px .3px 0 rgba(0,0,0,.35); }
.gx-listing:nth-child(2n) { --r: 1.2deg; }
.gx-listing:nth-child(3n) { --r: -.4deg; }
.gx-listing::before { content: ""; position: absolute; top: -6px; left: 50%; width: 30px; height: 30px; margin-left: -15px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, rgba(255,255,255,.7), transparent 40%), var(--aimant, #E23B2E); box-shadow: 0 3px 5px rgba(0,0,0,.35); }
.gx-listing h3 { font-family: 'Share Tech Mono', monospace; text-transform: uppercase; font-size: 1.05rem; letter-spacing: .04em; margin-top: .8rem; }
.gx-listing h3 a { text-decoration: none; color: #2a2a2a; }
.gx-listing img { display: block; width: 100%; aspect-ratio: 16/10; object-fit: cover; filter: grayscale(1) contrast(1.3); mix-blend-mode: multiply; margin: .6rem 0; }
.gx-listing .gx-lire { color: #2a2a2a; }

/* Écran d'aide sombre */
.gx-ecran-aide { background: var(--noir); color: #f1e9d2; border-radius: 14px; padding: clamp(1.2rem, 3vw, 2.2rem); border: 8px solid #3a3326; box-shadow: inset 0 0 40px rgba(255,136,0,.08), 0 10px 30px rgba(0,0,0,.25); }
.gx-aide-titre { color: var(--orange); margin-bottom: 1.2rem !important; }
.gx-ecran-aide details { border-top: 1px dashed #4a4232; padding: .8rem 0; }
.gx-ecran-aide summary { cursor: pointer; list-style: none; }
.gx-ecran-aide summary::-webkit-details-marker { display: none; }
.gx-ecran-aide summary::before { content: "> "; color: var(--orange); }
.gx-ecran-aide details[open] summary::before { content: "v "; }
.gx-ecran-aide summary:hover, .gx-ecran-aide summary:focus-visible { color: var(--orange); outline: none; }
.gx-ecran-aide details p { margin: .6rem 0 0 1.4rem; color: #cfc6ad; }
.gx-ecran-aide a { color: var(--orange); }

/* Fiche Oneïa */
.gx-fiche { background: var(--creme); border: 2px solid var(--brun); border-radius: 12px; padding: clamp(1.5rem, 4vw, 3rem); text-align: center; position: relative; }
.gx-fiche::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 8px; background: var(--arc); border-radius: 0 0 10px 10px; }

/* ----- Téléphones et tablettes : la machine reste en haut ----- */
@media (max-width: 860px) {
  .gx-scene { grid-template-columns: 1fr; gap: 0; padding-top: 0; }
  .gx-colonne-machine { grid-column: 1; grid-row: 1; position: sticky; top: 0; z-index: 2; background: var(--beige); padding: .6rem 0 .4rem; }
  .gx-colonne-machine::after { content: ""; position: absolute; left: 0; right: 0; bottom: -18px; height: 18px; background: linear-gradient(var(--beige), transparent); }
  .gx-machine { position: relative; top: auto; max-width: min(100%, 44vh * 1.14); margin: 0 auto; }
  .gx-recit { grid-column: 1; grid-row: 2; }
  .gx-hero { min-height: auto; padding: 2rem 0 1rem; }
  .gx-etape { min-height: 48vh; }
  .gx-ecran-contenu { font-size: clamp(6px, 1.9vw, 11px); }
}

/* ----- Animations réduites ----- */
@media (prefers-reduced-motion: reduce) {
  .gx-ecran-contenu, .gx-ecran.is-allume .gx-ecran-contenu { animation: none; opacity: 1; transform: none; filter: none; }
  .gx-touche, .gx-touche-svg, .gx-etape { transition: none; }
  .gx-sortie .c::after { animation: none; }
}
