
/* ===================== Mécaniques des niveaux 9 à 18 ===================== */
/* Replay de visio */
.rp { position: absolute; inset: 0; display: flex; flex-direction: column; background: #0f1115; }
.rp-head { padding: .5em 1em; color: #ff6b6b; font-weight: 600; font-size: .9em; }
.rp-screen { position: relative; flex: 1; margin: 0 1em; background: #fff; border-radius: 4px; overflow: hidden; color: #222; }
.rp-layer { position: absolute; inset: 0; }
.rp-slide { padding: 6% 8%; height: 100%; background: linear-gradient(135deg, #fff, #eef3fa); }
.rp-slide h1 { color: #1d4f91; font-size: 2.4em; margin-bottom: .5em; }
.rp-slide li { font-size: 1.4em; margin: .4em 0 .4em 1.2em; }
.rp-pop { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); width: 46%; background: #fff; border: 1px solid #999;
  border-radius: 8px; box-shadow: 0 10px 40px #0006; padding: 1em; font-size: 1.1em; }
.rp-pop b { color: #1d4f91; }
.rp-notif { position: absolute; right: 2%; bottom: 4%; width: 32%; background: #2b2f36; color: #fff; border-radius: 6px; padding: .7em; font-size: .95em; }
.rp-chat { position: absolute; right: 2%; top: 4%; width: 30%; background: #f3f2f1; border: 1px solid #ccc; border-radius: 6px; padding: .6em; font-size: .95em; }
.rp-bar { display: flex; align-items: center; gap: .8em; padding: .6em 1em; color: #ddd; }
.rp-btn { background: #30363d; color: #fff; border: 0; border-radius: 6px; padding: .4em .8em; cursor: pointer; font-size: 1.1em; }
.rp-btn.small { font-size: .9em; }
.rp-slider { flex: 1; accent-color: #ff4d4d; }
.rp-time { font-family: Consolas, monospace; font-size: .9em; }

/* Observer la frappe */
.ty { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .9em;
  background: radial-gradient(ellipse, #3a3f47, #1a1d22); color: #ddd; }
.ty-head { max-width: 70%; text-align: center; font-size: .95em; color: #aab; }
.ty-screen { background: #f4f6f9; color: #222; border-radius: 6px; padding: .8em 1.4em; min-width: 40%; box-shadow: 0 6px 20px #0008; }
.ty-site { font-weight: 700; color: #1d4f91; margin-bottom: .4em; }
.ty-field { border: 1px solid #aaa; border-radius: 4px; padding: .35em .6em; font-family: Consolas, monospace; background: #fff; min-height: 1.6em; }
.ty-caret { animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.ty-kbwrap { position: relative; }
.ty-kb { background: #202328; padding: .6em; border-radius: 8px; display: flex; flex-direction: column; gap: .3em; }
.ty-row { display: flex; gap: .3em; justify-content: center; }
.ty-key { width: 2.6em; height: 2.6em; background: #3a3e45; border-radius: 5px; display: flex; flex-direction: column; align-items: center;
  justify-content: center; font-size: .85em; color: #eee; box-shadow: 0 3px 0 #15171a; line-height: 1; transition: background .05s; }
.ty-key small { font-size: .75em; opacity: .7; }
.ty-key.shift { width: 4.2em; }
.ty-key.space { width: 18em; }
.ty-key.down { background: #ffd34d; color: #222; transform: translateY(2px); box-shadow: 0 1px 0 #15171a; }
.ty-hand { position: absolute; display: flex; align-items: center; justify-content: center; line-height: 1; pointer-events: none;
  filter: drop-shadow(0 6px 8px #000a); }
.ty-ctrl { display: flex; align-items: center; gap: 1em; }
.ty-slow { font-size: .9em; } .ty-info { font-size: .85em; color: #f0b429; }

/* Reflet */
.mi { position: absolute; inset: 0; background: linear-gradient(#0b1020, #1b2540); }
.mi-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mi-bg.missing { display: none; }
.mi-refl { position: absolute; left: 28%; top: 22%; width: 44%; padding: 1.2em; background: #9fc3ff22; border-radius: 4px;
  color: #e8f0ff; font-family: Consolas, monospace; font-size: 1.25em; line-height: 1.6;
  transform: scaleX(-1) skewY(-3deg); opacity: .5; filter: blur(1.3px); text-shadow: 0 0 6px #9fc3ff; transition: all .5s; }
.mi-refl.flipped { transform: none; opacity: .95; filter: none; }
.mi-tools { position: absolute; left: 0; right: 0; bottom: 4%; text-align: center; }
.mi-tip { color: #aab; font-size: .9em; background: #0008; padding: .4em .8em; border-radius: 6px; }

/* Digicode */
.kp { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .8em;
  background: radial-gradient(ellipse, #8a8f96, #4b5057); }
.kp-box { background: linear-gradient(#c9ccd0, #9a9ea4); border-radius: 12px; padding: 1.2em; box-shadow: 0 12px 30px #0009, inset 0 2px 0 #fff8;
  display: flex; flex-direction: column; align-items: center; gap: .6em; }
.kp-brand { font-size: .7em; letter-spacing: .2em; color: #444; font-weight: 700; }
.kp-led { width: .8em; height: .8em; border-radius: 50%; background: #551111; box-shadow: inset 0 0 3px #000; }
.kp-led.ok { background: #3fdc5a; box-shadow: 0 0 10px #3fdc5a; } .kp-led.ko { background: #ff3b3b; box-shadow: 0 0 10px #ff3b3b; }
.kp-disp { background: #1e2b1e; color: #8cff8c; font-family: Consolas, monospace; padding: .4em 1em; border-radius: 4px; min-width: 8em; text-align: center; letter-spacing: .1em; }
.kp-grid { display: grid; grid-template-columns: repeat(3, 3.2em); gap: .45em; }
.kp-key { height: 3.2em; border: 0; border-radius: 8px; font-size: 1.1em; font-weight: 700; cursor: pointer; color: #222;
  background: linear-gradient(#f4f4f4, #c9c9c9); box-shadow: 0 3px 0 #777; }
.kp-key:active { transform: translateY(2px); box-shadow: 0 1px 0 #777; }
.kp-key.worn { background: linear-gradient(#f6f1e4, #ded4bd); color: #8f877a; box-shadow: 0 3px 0 #777, inset 0 0 10px #a08c6a55; }
.kp-tip { color: #eee; font-size: .85em; text-shadow: 0 1px 2px #000; }

/* Messagerie vocale */
.vm { position: absolute; inset: 0; display: flex; gap: 1.5em; align-items: center; justify-content: center; background: radial-gradient(ellipse, #3b4048, #1c1f24); }
.vm-lcd { width: 55%; height: 75%; background: #c8d6b0; color: #1e2a12; border-radius: 6px; padding: 1em; font-family: Consolas, monospace;
  box-shadow: inset 0 0 20px #6b7a50; display: flex; flex-direction: column; gap: .5em; overflow: auto; }
.vm-title { font-weight: 700; }
.vm-pin { font-size: 1.6em; letter-spacing: .2em; min-height: 1.3em; }
.vm-msg { display: block; width: 100%; text-align: left; background: #b4c49a; border: 0; border-radius: 4px; padding: .35em .6em; margin-bottom: .25em;
  font-family: inherit; cursor: pointer; color: inherit; }
.vm-msg.on { background: #8ea468; } .vm-msg small { opacity: .7; margin-left: .4em; }
.vm-text { white-space: pre-wrap; line-height: 1.45; border-top: 1px dashed #6b7a50; padding-top: .5em; }
.vm-side { display: flex; align-items: center; justify-content: center; }
.vm-wave { display: flex; gap: .3em; align-items: center; height: 5em; }
.vm-wave span { width: .5em; height: 1em; background: #5a6470; border-radius: 3px; }
.vm-side.talking .vm-wave span { background: #3fb950; animation: wave .6s ease-in-out infinite; }
.vm-side.talking .vm-wave span:nth-child(2n) { animation-delay: .15s; } .vm-side.talking .vm-wave span:nth-child(3n) { animation-delay: .3s; }
@keyframes wave { 50% { height: 4.5em; } }

/* Réseau social */
.so { position: absolute; inset: 0; background: #eef1f5; color: #1c1e21; display: flex; flex-direction: column; }
.so-top { display: flex; justify-content: space-between; padding: .6em 1.2em; background: #0a66c2; color: #fff; }
.so-feed { flex: 1; overflow-y: auto; padding: 1em 18%; display: flex; flex-direction: column; gap: 1em; }
.so-post { background: #fff; border-radius: 8px; padding: .9em 1.1em; box-shadow: 0 1px 3px #0002; }
.so-author { display: flex; gap: .6em; align-items: center; margin-bottom: .5em; }
.so-author small { display: block; color: #666; font-size: .8em; }
.so-av { font-size: 1.8em; }
.so-photo { margin-top: .6em; cursor: zoom-in; border-radius: 6px; overflow: hidden; aspect-ratio: 16 / 9; position: relative; }
.so-pic { position: relative; width: 100%; height: 100%; transform-origin: 0 0; background: linear-gradient(135deg, #c9d6e3, #9fb3c8); }
.so-pic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.so-pic img.missing { display: none; }
.so-ph-label { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); font-size: 1.3em; color: #fff; text-shadow: 0 1px 3px #0008; display: none; }
.so-pic.ph-missing .so-ph-label { display: block; }
.so-ov { position: absolute; font-family: "Segoe Print", "Comic Sans MS", cursive; white-space: pre; line-height: 1.15; }
.so-react { color: #666; font-size: .85em; margin: .5em 0 .3em; }
.so-com { font-size: .88em; background: #f2f3f5; border-radius: 8px; padding: .35em .6em; margin-top: .3em; }
.so-zoom { position: absolute; inset: 0; background: #000e; display: flex; flex-direction: column; }
.so-view { flex: 1; overflow: hidden; position: relative; cursor: grab; touch-action: none; }
.so-view .so-pic { position: absolute; inset: 0; }
.so-zctl { display: flex; align-items: center; gap: 1em; padding: .6em 1em; color: #ddd; }
.so-zctl input { width: 30%; } .so-zhint { flex: 1; font-size: .85em; color: #aaa; }

/* Keylogger */
.kl { position: absolute; inset: 0; display: flex; gap: 1em; padding: 1em; background: #111; }
.kl-term { flex: 2; background: #000; color: #39ff6a; font-family: Consolas, monospace; padding: 1em; border-radius: 6px; overflow: auto;
  line-height: 1.7; font-size: .95em; box-shadow: inset 0 0 30px #0f3; }
.kl-head { color: #9cff9c; border-bottom: 1px solid #1f5f2f; margin-bottom: .6em; padding-bottom: .3em; }
.kl-ts { color: #2f9f4f; } .kl-app { color: #ffd166; }
.kl-legend { margin-top: 1em; color: #7fbf8f; font-size: .85em; border-top: 1px solid #1f5f2f; padding-top: .5em; white-space: pre-line; }
.kl-note { flex: 1; background: #fff9c4; border: 0; border-radius: 4px; padding: 1em; font-family: "Segoe Print", "Comic Sans MS", cursive; font-size: 1em; resize: none; }

/* Navigateur */
.br { position: absolute; inset: 0; background: #fff; color: #222; display: flex; flex-direction: column; }
.br-tabs { background: #dee1e6; padding: .4em .6em 0; }
.br-tab { display: inline-block; background: #fff; padding: .4em 1.2em; border-radius: 8px 8px 0 0; font-size: .85em; }
.br-nav { display: flex; gap: 1em; align-items: center; padding: .4em .8em; border-bottom: 1px solid #ddd; color: #666; }
.br-addr { flex: 1; background: #f1f3f4; border-radius: 16px; padding: .3em 1em; font-size: .9em; color: #333; }
.br-marks { display: flex; gap: .3em; padding: .3em .8em; border-bottom: 1px solid #eee; }
.br-mark { background: none; border: 0; padding: .3em .6em; border-radius: 4px; cursor: pointer; font-size: .85em; }
.br-mark:hover { background: #eee; }
.br-page { flex: 1; overflow: auto; padding: 1.5em 2.5em; }
.br-page h2 { margin-bottom: .6em; color: #1d4f91; }
.br-page p { margin: .5em 0; } .br-muted { color: #777; font-size: .9em; }
.br-page a, .br-page [data-go] { color: #1a73e8; cursor: pointer; text-decoration: underline; }
.br-tbl { width: 100%; border-collapse: collapse; margin-top: .8em; }
.br-tbl td, .br-tbl th { border-bottom: 1px solid #eee; padding: .55em .6em; text-align: left; }
.br-tbl .pw { font-family: Consolas, monospace; }
.br-eye { background: none; border: 0; cursor: pointer; font-size: 1.1em; }
.br-login { max-width: 22em; border: 1px solid #ddd; border-radius: 8px; padding: 1.2em; }
.br-login input { display: block; width: 100%; margin: .3em 0 .8em; padding: .4em; }
.br-modal { position: absolute; inset: 0; background: #0006; display: flex; align-items: center; justify-content: center; }
.br-dlg { background: #fff; border-radius: 6px; padding: 1.2em 1.5em; width: 22em; box-shadow: 0 10px 40px #0008; }
.br-pin { width: 100%; font-size: 1.3em; letter-spacing: .4em; padding: .3em; margin: .3em 0; }
.br-err { color: #c62828; font-size: .85em; min-height: 1.2em; }
.br-row { display: flex; justify-content: flex-end; gap: .5em; }

/* Tableur */
.sh { position: absolute; inset: 0; background: #fff; color: #222; display: flex; flex-direction: column; font-family: Calibri, "Segoe UI", sans-serif; }
.sh-title { background: #217346; color: #fff; padding: .4em 1em; font-size: .9em; }
.sh-fbar { display: flex; gap: .8em; align-items: center; padding: .3em .6em; border-bottom: 1px solid #ccc; font-size: .9em; }
.sh-ref { width: 4em; border: 1px solid #ccc; padding: .1em .3em; } .sh-fx { color: #888; font-style: italic; }
.sh-val { flex: 1; border: 1px solid #ccc; padding: .1em .4em; min-height: 1.3em; font-family: Consolas, monospace; }
.sh-grid { flex: 1; overflow: auto; }
.sh-grid table { border-collapse: collapse; font-size: .85em; }
.sh-grid th { background: #f3f3f3; border: 1px solid #d4d4d4; font-weight: normal; color: #555; padding: .15em .4em; min-width: 2.5em; }
.sh-grid td { border: 1px solid #e3e3e3; padding: .2em .5em; min-width: 9em; height: 1.5em; cursor: cell; white-space: nowrap; }
.sh-grid td.sh-head { font-weight: 700; background: #e8f1ea; }
.sh-grid td.sel { outline: 2px solid #217346; outline-offset: -2px; }
.sh-grid td.sh-white { color: #fff; }
.sh-grid th.sh-hid { min-width: 0; width: 6px; padding: 0; cursor: col-resize; background: #c9c9c9; font-size: .6em; }
.sh-grid th.sh-hid:hover { background: #217346; color: #fff; }
.sh-grid td.sh-hidc { min-width: 0; width: 6px; padding: 0; background: #ececec; }
.sh-tabs { display: flex; gap: 2px; background: #f3f3f3; border-top: 1px solid #ccc; padding: 0 .5em; }
.sh-tab { border: 0; background: none; padding: .35em 1em; cursor: pointer; font-size: .85em; }
.sh-tab.on { background: #fff; border-bottom: 2px solid #217346; font-weight: 700; color: #217346; }

/* Livre */
.bk { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .8em;
  background: radial-gradient(ellipse, #5a3d28, #2b1c12); }
.bk-pages { display: flex; width: 82%; height: 82%; box-shadow: 0 20px 50px #000a; }
.bk-page { flex: 1; background: #f3e9d2; position: relative; padding: 2em 2.2em 2.5em; color: #3a2e22;
  font-family: Georgia, "Times New Roman", serif; font-size: 1.02em; line-height: 1.65; text-align: justify; }
.bk-page.left { box-shadow: inset -20px 0 30px -18px #6b5332; border-radius: 4px 0 0 4px; }
.bk-page.right { box-shadow: inset 20px 0 30px -18px #6b5332; border-radius: 0 4px 4px 0; }
.bk-page.empty { background: #e8dcc0; }
.bk-text::first-letter { font-size: 1.6em; }
.bk-num { position: absolute; bottom: .8em; left: 50%; transform: translateX(-50%); font-size: .9em; padding: .1em .45em; }
.bk-num.circled { border: 1.5px solid #666; border-radius: 50%; }
.bk-pencil { text-decoration: none; border-bottom: 1.5px solid #6b6b6b; }
.bk-red { border: 1.5px solid #c62828; border-radius: 50%; padding: 0 .1em; }
.bk-ctl { display: flex; gap: 1.5em; align-items: center; color: #e8dcc0; }
.br-hintbtn { background: none; border: 0; color: #1a73e8; text-decoration: underline; cursor: pointer; font-size: .85em; padding: 0; margin-bottom: .6em; }
.br-hint { background: #fff8e1; border: 1px solid #f0d58a; border-radius: 4px; padding: .4em .6em; font-size: .9em; margin-bottom: .6em; }
