/* ══════════════════════════════════════════════════════════
   GLOBAL VARIABLES & BASE STYLES
   ══════════════════════════════════════════════════════════ */
:root {
  --bg: #060610; --surface: #0d0d1f; --card: #111128; --border: #1e1e3a; --border2: #2a2a50;
  --accent: #6c47ff; --accent2: #00e5ff; --text: #e8e8f8; --muted: #5c5c80; --muted2: #6a6a90;
  --red: #ff4560; --green: #00e996; --warn: #ffbe0b;
  --font: 'Space Grotesk', sans-serif; --mono: 'JetBrains Mono', monospace;
  --bg-role: #0b0d1a; --card-bg-role: rgba(255,255,255,0.04); --card-border-role: rgba(255,255,255,0.08); --muted-role: rgba(205,214,244,0.45);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg); color: var(--text); font-family: var(--font); margin: 0; height: 100vh; width: 100vw; overflow: hidden; }

/* ══════════════════════════════════════════════════════════
   STRUCTURE PRINCIPALE
   ══════════════════════════════════════════════════════════ */
#app-container { width: 100%; height: 100%; display: none; }

.sidebar { width: 220px; min-width: 220px; background: var(--surface); display: flex; flex-direction: column; padding: 24px 16px; border-right: 1px solid var(--border); position: relative; z-index: 10; }
.logo { display: flex; align-items: center; gap: 10px; padding: 0 8px; margin-bottom: 36px; }
.logo img { height: 34px; width: auto; border-radius: 6px; }
.logo-text { font-size: 17px; font-weight: 800; letter-spacing: -.4px; font-family: 'Syne', sans-serif; }
.logo-text span { color: var(--accent); }
.nav-section { font-size: 10px; font-weight: 700; color: var(--muted); letter-spacing: 1.2px; padding: 0 8px; margin-bottom: 8px; font-family: var(--mono); }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; color: var(--muted); cursor: pointer; font-size: 14px; font-weight: 600; transition: .15s; margin-bottom: 2px; border-left: 2px solid transparent; }
.nav-item:hover { background: var(--card); color: white; }
.nav-item.active { background: rgba(108,71,255,.15); color: var(--accent); border-left-color: var(--accent); }
.sidebar-bottom { margin-top: auto; border-top: 1px solid var(--border); padding-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.btn-side { background: var(--card); border: 1px solid var(--border); color: var(--text); padding: 10px 14px; border-radius: 8px; cursor: pointer; font-family: var(--font); font-size: 13px; font-weight: 600; transition: .15s; display: flex; align-items: center; gap: 8px; width: 100%; justify-content: center;}
.btn-side:hover { background: var(--border); }
.btn-side.danger { color: var(--red); }
.btn-side.danger:hover { border-color: var(--red); background: rgba(255,69,96,.08); }

.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; position: relative; z-index: 5; }
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 18px 32px; border-bottom: 1px solid var(--border); background: rgba(6,6,16,.8); backdrop-filter: blur(12px); gap: 16px; }
.search-wrap { position: relative; flex: 1; max-width: 380px; }
.search-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-size: 15px; color: var(--muted); pointer-events: none; }
.search-input { width: 100%; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px 10px 40px; color: var(--text); font-family: var(--font); font-size: 14px; outline: none; transition: .2s; }
.search-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(108,71,255,.12); }
.search-input::placeholder { color: var(--muted); }

.discord-btn { display: flex; align-items: center; gap: 6px; background: #5865F2; color: white; padding: 8px 16px; border-radius: 99px; font-family: var(--font); font-size: 12px; font-weight: 700; text-decoration: none; transition: .2s; border: none; }
.discord-btn:hover { filter: brightness(1.1); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(88,101,242,.3); }

.btn-dev-mini { background: rgba(108,71,255,.1); border: 1px solid rgba(108,71,255,.2); color: var(--accent); width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: .2s; font-size: 14px; }
.btn-dev-mini:hover { background: rgba(108,71,255,.2); transform: rotate(45deg); box-shadow: 0 4px 12px rgba(108,71,255,.3); }

.status-pill { display: flex; align-items: center; gap: 8px; border-radius: 99px; padding: 8px 16px; font-size: 12px; font-weight: 700; letter-spacing: .8px; transition: background .5s, border-color .5s, color .5s; border: 1px solid var(--border); background: var(--surface); color: var(--muted); font-family: var(--mono); }
.status-pill.offline { color: var(--red); border-color: rgba(255,69,96,.3); background: rgba(255,69,96,.05); }
.status-pill.online { color: var(--green); border-color: rgba(0,233,150,.3); background: rgba(0,233,150,.06); }
.dot { width: 7px; height: 7px; border-radius: 50%; transition: background .5s, box-shadow .5s; background: var(--muted); }
.status-pill.offline .dot { background: var(--red); }
.status-pill.online .dot { background: var(--green); box-shadow: 0 0 8px var(--green), 0 0 20px rgba(0,233,150,.3); animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .55; } }
#dev-badge-inside { display: none; align-items: center; gap: 6px; background: rgba(0,233,150,.08); border: 1px solid rgba(0,233,150,.25); border-radius: 99px; padding: 6px 12px 6px 8px; font-family: var(--mono); font-size: 11px; font-weight: 500; color: var(--green); letter-spacing: .5px; }
#dev-badge-inside span { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 6px var(--green); animation: pulse 2s infinite; }

.content { flex: 1; overflow-y: auto; padding: 28px 32px; scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
.content::-webkit-scrollbar { width: 5px; }
.content::-webkit-scrollbar-thumb { background: var(--border); border-radius: 99px; }
.page-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 28px; }
.page-title { font-size: 24px; font-weight: 800; letter-spacing: -.5px; font-family: 'Syne', sans-serif;}
.page-sub { color: var(--muted); font-size: 14px; margin-top: 4px; }
.btn-refresh { background: var(--card); border: 1px solid var(--border); color: var(--muted); padding: 8px 14px; border-radius: 8px; cursor: pointer; font-family: var(--font); font-size: 13px; font-weight: 600; transition: .15s; display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.btn-refresh:hover { background: var(--border); color: var(--text); }
.btn-refresh.spinning svg { animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; }
.game-card { position: relative; background: var(--card); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; transition: transform .25s, border-color .25s, box-shadow .25s; animation: cardIn .3s both; }
@keyframes cardIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.game-card:hover { transform: translateY(-4px); border-color: var(--border2); box-shadow: 0 16px 40px rgba(0,0,0,.4); }
.game-card img { width: 100%; aspect-ratio: 460/215; object-fit: cover; display: block; background: var(--surface); }
.game-card-body { padding: 14px; }
.game-card-name { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 3px; }
.game-card-id { font-size: 11px; color: var(--muted); font-family: var(--mono); margin-bottom: 12px; }
.game-card-actions { display: flex; gap: 7px; }
.btn-sm { flex: 1; border: none; border-radius: 7px; padding: 8px 0; font-family: var(--font); font-size: 12px; font-weight: 700; cursor: pointer; transition: .15s; text-align: center; }
.btn-manifest { background: rgba(0,229,255,.1); border: 1px solid rgba(0,229,255,.25)!important; color: var(--accent2); }
.btn-manifest:hover { background: rgba(0,229,255,.18); }
.btn-manifest:disabled { opacity: .5; cursor: not-allowed; }
.protected-badge { position: absolute; top: 10px; right: 10px; background: rgba(255,190,11,.15); border: 1px solid rgba(255,190,11,.4); color: var(--warn); font-size: 10px; font-weight: 700; padding: 4px 8px; border-radius: 6px; font-family: var(--mono); text-transform: uppercase; letter-spacing: 1px; backdrop-filter: blur(4px); z-index: 2; }
.library-badge { position: absolute; top: 10px; left: 10px; background: rgba(0,233,150,.15); border: 1px solid rgba(0,233,150,.4); color: var(--green); font-size: 10px; font-weight: 700; padding: 4px 8px; border-radius: 6px; font-family: var(--mono); text-transform: uppercase; letter-spacing: 1px; backdrop-filter: blur(4px); z-index: 2; }

.empty-state { grid-column: 1/-1; display: flex; flex-direction: column; align-items: center; padding: 80px 20px; color: var(--muted); text-align: center; animation: fadeIn .3s ease both; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.empty-icon { font-size: 52px; margin-bottom: 18px; opacity: .4; }
.empty-title { font-size: 18px; font-weight: 700; color: var(--text); margin-bottom: 8px; opacity: .6; }
.empty-text { font-size: 14px; max-width: 300px; line-height: 1.6; }

.soon-page { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 60%; gap: 16px; text-align: center; }
.soon-badge { background: rgba(108,71,255,.12); border: 1px solid rgba(108,71,255,.3); color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: 2px; padding: 6px 16px; border-radius: 99px; text-transform: uppercase; }
.soon-title { font-size: 32px; font-weight: 800; letter-spacing: -1px; font-family: 'Syne', sans-serif;}
.soon-sub { color: var(--muted); font-size: 14px; max-width: 280px; line-height: 1.6; }

.terminal { height: 145px; min-height: 145px; background: #04040e; border-top: 1px solid var(--border); padding: 12px 20px; display: flex; flex-direction: column; }
.term-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.term-dots { display: flex; gap: 6px; }
.term-dot { width: 11px; height: 11px; border-radius: 50%; }
.term-dot.close-btn { cursor: pointer; position: relative; }
.term-dot.close-btn:hover::after { content: '✕'; position: absolute; font-size: 8px; color: #400; top: 50%; left: 50%; transform: translate(-50%, -50%); font-weight: bold; }
.term-dot:nth-child(1) { background: #ff5f57; } .term-dot:nth-child(2) { background: #febc2e; } .term-dot:nth-child(3) { background: #28c840; }
.term-label { font-size: 11px; color: var(--muted); font-family: var(--mono); }
.term-actions { display: flex; align-items: center; gap: 8px; }
.btn-clear-log { background: transparent; border: none; color: var(--muted); font-size: 11px; font-family: var(--mono); cursor: pointer; padding: 2px 6px; border-radius: 4px; transition: .15s; }
.btn-clear-log:hover { background: var(--border); color: var(--text); }
.term-logs { flex: 1; overflow-y: auto; font-family: var(--mono); font-size: 12px; scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
.term-logs::-webkit-scrollbar { width: 3px; }
.term-logs::-webkit-scrollbar-thumb { background: var(--border); }
.log-line { display: flex; gap: 10px; margin-bottom: 3px; line-height: 1.5; }
.log-ts { color: #5c5cff; flex-shrink: 0; }
.log-msg { color: #a0a0c0; word-break: break-all; }
.log-msg.ok { color: var(--green); } .log-msg.err { color: var(--red); } .log-msg.warn { color: var(--warn); }
.spinner-icon { display: inline-block; width: 13px; height: 13px; border: 2px solid rgba(255,255,255,.15); border-top-color: var(--accent2); border-radius: 50%; animation: spin .6s linear infinite; }

#toast-container { position: fixed; bottom: 170px; right: 24px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; }
.toast { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 12px 18px; font-size: 13px; font-weight: 500; box-shadow: 0 8px 24px rgba(0,0,0,.4); display: flex; align-items: center; gap: 10px; animation: tIn .3s cubic-bezier(.16,1,.3,1); max-width: 340px; }
.toast.success { border-color: rgba(0,233,150,.3); } .toast.error { border-color: rgba(255,69,96,.3); } .toast.info { border-color: rgba(108,71,255,.3); } .toast.warn { border-color: rgba(255,190,11,.3); }
.toast-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.toast.success .toast-dot { background: var(--green); } .toast.error .toast-dot { background: var(--red); } .toast.info .toast-dot { background: var(--accent); } .toast.warn .toast-dot { background: var(--warn); }

.modal-backdrop { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; background: rgba(5,5,15,.85); backdrop-filter: blur(16px); opacity: 0; visibility: hidden; transition: all .25s; }
.modal-backdrop.show { opacity: 1; visibility: visible; }
.modal-box, .confirm-box, .role-wrapper, .auth-modal { transform: translateY(16px) scale(.97); transition: transform .25s cubic-bezier(.16,1,.3,1); }
.modal-backdrop.show .modal-box, .modal-backdrop.show .confirm-box, .modal-backdrop.show .role-wrapper, .modal-backdrop.show .auth-modal { transform: none; }

/* Modal Agent */
.modal-box { background: linear-gradient(145deg,#10102a,#0b0b20); border: 1px solid var(--border2); border-radius: 20px; padding: 40px; width: 540px; text-align: center; box-shadow: 0 40px 80px rgba(0,0,0,.6), 0 0 0 1px rgba(108,71,255,.15); }
.modal-icon { width: 54px; height: 54px; border-radius: 16px; background: linear-gradient(135deg,var(--accent),var(--accent2)); margin: 0 auto 20px; display: flex; align-items: center; justify-content: center; font-size: 24px; box-shadow: 0 8px 32px rgba(108,71,255,.4); }
.modal-box h2 { font-size: 24px; font-weight: 800; margin-bottom: 12px; letter-spacing: -.5px; font-family: 'Syne', sans-serif; }
.modal-box > p { color: var(--muted); font-size: 13px; line-height: 1.6; margin-bottom: 20px; }
.safe-info-box { background: rgba(0, 233, 150, 0.05); border: 1px solid rgba(0, 233, 150, 0.2); border-radius: 12px; padding: 18px 20px; margin-bottom: 24px; text-align: left; }
.safe-info-title { color: var(--green); font-weight: 700; font-size: 14px; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.safe-info-list { font-size: 12px; color: #a0a0c0; padding-left: 18px; margin: 0; line-height: 1.7; }
.safe-info-list li { margin-bottom: 6px; }
.safe-info-list code { background: rgba(255,255,255,0.05); padding: 2px 6px; border-radius: 4px; color: var(--text); font-family: var(--mono); font-size: 11px; }
.code-row { background: #06060f; border: 1px solid var(--border2); border-radius: 10px; padding: 13px 16px; display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; gap: 12px; }
.code-row code { font-family: var(--mono); color: var(--accent2); font-size: 13px; font-weight: 500; }
.btn-copy { background: var(--border); border: 1px solid var(--border2); color: var(--muted); padding: 6px 12px; border-radius: 7px; cursor: pointer; font-size: 12px; font-family: var(--font); font-weight: 600; transition: .2s; white-space: nowrap; }
.btn-copy:hover { background: var(--border2); color: white; }
.btn-retry { width: 100%; background: linear-gradient(135deg,var(--accent),#8b65ff); border: none; color: white; padding: 13px; border-radius: 10px; cursor: pointer; font-family: var(--font); font-size: 15px; font-weight: 700; transition: .2s; }
.btn-retry:hover { filter: brightness(1.12); transform: translateY(-1px); }
.modal-hint { font-size: 12px; color: var(--muted); margin-top: 12px; }

/* ==========================================================
   NOUVEAU: FAKE TERMINAL DOWNLOAD GUI (Dans le Modal Agent)
   ========================================================== */
.f-term-wrap { display: none; background: #090912; border: 1px solid var(--border2); border-radius: 12px; overflow: hidden; text-align: left; font-family: var(--mono); font-size: 12px; animation: fadeIn .3s ease; }
.f-titlebar { background: #121226; padding: 10px 16px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--border2); }
.f-title { font-size: 11px; color: #888; margin: 0 auto; letter-spacing: 0.05em; font-weight: 600;}
.f-body { padding: 20px 24px; min-height: 220px;}
.f-line { line-height: 2; color: #888; white-space: pre; transition: opacity 0.2s;}
.f-line.dim { color: #444; }
.f-line.bright { color: #fff; font-weight: 600; }
.f-line.ok { color: var(--green); }
.f-line.info { color: var(--accent2); }
.f-line.err { color: var(--red); }
.f-prog-row { display: flex; align-items: center; gap: 10px; line-height: 2; white-space: pre; transition: opacity 0.2s;}
.f-bar-wrap { display: inline-block; letter-spacing: 1px; }
.f-pct { color: #fff; min-width: 42px; text-align: right; }
.btn-f-action { background: transparent; border: 1px solid var(--border2); color: #888; padding: 6px 16px; border-radius: 6px; font-family: var(--mono); font-size: 11px; cursor: pointer; transition: .2s; margin-top: 15px; margin-right: 8px;}
.btn-f-action:hover { border-color: white; color: white; }

.confirm-box { background: linear-gradient(145deg,#12122a,#0d0d20); border: 1px solid rgba(255,69,96,.25); border-radius: 16px; padding: 32px 36px; width: 380px; text-align: center; box-shadow: 0 24px 60px rgba(0,0,0,.6); }
.confirm-icon { font-size: 36px; margin-bottom: 14px; }
.confirm-box h3 { font-size: 18px; font-weight: 800; margin-bottom: 8px; }
.confirm-box p { color: var(--muted); font-size: 13px; line-height: 1.6; margin-bottom: 22px; }
.confirm-actions { display: flex; gap: 10px; }
.btn-cancel, .btn-delete { flex: 1; padding: 11px; border-radius: 9px; cursor: pointer; font-family: var(--font); font-size: 14px; font-weight: 600; transition: .15s; }
.btn-cancel { background: var(--card); border: 1px solid var(--border); color: var(--muted); }
.btn-cancel:hover { background: var(--border); color: var(--text); }
.btn-delete { background: rgba(255,69,96,.15); border: 1px solid rgba(255,69,96,.35); color: var(--red); font-weight: 700; }
.btn-delete:hover { background: rgba(255,69,96,.25); border-color: var(--red); }

.role-wrapper { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.role-header { text-align: center; }
.role-badge { display: inline-flex; align-items: center; gap: 7px; padding: 5px 14px; border: 1px solid rgba(108,92,231,0.5); border-radius: 100px; font-size: 10px; letter-spacing: .15em; color: #a29bfe; margin-bottom: 14px; font-family: 'DM Mono', monospace; }
.role-badge span { width: 6px; height: 6px; border-radius: 50%; background: #6c5ce7; animation: blink 1.4s infinite; }
.role-title { font-family: 'Syne', sans-serif; font-size: 26px; font-weight: 800; color: #fff; }
.role-sub { font-size: 11px; color: var(--muted-role); margin-top: 5px; font-family: 'DM Mono', monospace;}
.role-cards { display: flex; flex-direction: column; gap: 10px; width: 320px; }
.role-card { display: flex; align-items: center; gap: 14px; padding: 15px 16px; background: var(--card-bg-role); border: 1px solid var(--card-border-role); border-radius: 14px; cursor: pointer; transition: .2s; font-family: 'DM Mono', monospace;}
.role-card:hover { transform: translateX(4px); }
.role-card.dev:hover { border-color: #6c5ce7; box-shadow: 0 0 22px rgba(108,92,231,0.25); }
.role-card.vip:hover { border-color: #f9ca24; box-shadow: 0 0 22px rgba(249,202,36,0.2); }
.role-card.mem:hover { border-color: #00cec9; box-shadow: 0 0 22px rgba(0,206,201,0.2); }
.role-icon { width: 42px; height: 42px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.role-card.dev .role-icon { background: rgba(108,92,231,0.15); }
.role-card.vip .role-icon { background: rgba(249,202,36,0.12); }
.role-card.mem .role-icon { background: rgba(0,206,201,0.1); }
.role-info { flex: 1; }
.role-name { font-family: 'Syne', sans-serif; font-size: 14px; font-weight: 800; color: #fff; }
.role-desc { font-size: 10.5px; color: var(--muted-role); margin-top: 3px; line-height: 1.5; }
.role-tag { font-size: 9.5px; letter-spacing: .1em; padding: 3px 9px; border-radius: 6px; flex-shrink: 0; }
.role-card.dev .role-tag { background: rgba(108,92,231,0.2); color: #a29bfe; border: 1px solid rgba(108,92,231,0.3); }
.role-card.vip .role-tag { background: rgba(249,202,36,0.15); color: #f9ca24; border: 1px solid rgba(249,202,36,0.3); }
.role-card.mem .role-tag { background: rgba(0,206,201,0.1); color: #00cec9; border: 1px solid rgba(0,206,201,0.25); }
.role-arrow { font-size: 16px; color: var(--muted-role); transition: .2s; }
.role-card.dev:hover .role-arrow { color: #a29bfe; transform: translateX(2px); }
.role-card.vip:hover .role-arrow { color: #f9ca24; transform: translateX(2px); }
.role-card.mem:hover .role-arrow { color: #00cec9; transform: translateX(2px); }
.role-footer { font-size: 10px; letter-spacing: .12em; color: rgba(205,214,244,0.2); font-family: 'DM Mono', monospace; margin-top:10px; cursor: pointer;}
.role-footer:hover { color: rgba(205,214,244,0.5); }

.auth-modal { background: linear-gradient(160deg, #141430, #0d0d22); border: 1px solid var(--border2); border-radius: 20px; padding: 36px 32px; width: 360px; text-align: center; box-shadow: 0 40px 80px rgba(0,0,0,.7), 0 0 0 1px rgba(108,71,255,.1); font-family: 'Syne', sans-serif;}
.auth-icon { width: 52px; height: 52px; border-radius: 16px; background: rgba(108,71,255,.12); border: 1px solid rgba(108,71,255,.25); margin: 0 auto 20px; display: flex; align-items: center; justify-content: center; font-size: 22px; }
.auth-modal h3 { font-size: 20px; font-weight: 800; margin-bottom: 8px; color: var(--text); }
.auth-modal p { font-size: 13px; color: var(--muted2); margin-bottom: 22px; line-height: 1.6; }
.auth-input { width: 100%; background: #08081a; border: 1px solid var(--border2); border-radius: 10px; padding: 12px 16px; color: var(--text); font-family: var(--mono); font-size: 14px; outline: none; transition: .2s; letter-spacing: 1px; margin-bottom: 14px; text-align: center; }
.auth-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(108,71,255,.12); }
.auth-input.error { border-color: var(--red); box-shadow: 0 0 0 3px rgba(255,69,96,.1); animation: shake .3s; }
.auth-input.success { border-color: var(--green); box-shadow: 0 0 0 3px rgba(0,233,150,.1); }
.auth-hint { font-size: 11px; color: var(--muted); margin-bottom: 16px; font-family: var(--mono); }
.auth-hint.err { color: var(--red); }
.auth-hint.ok { color: var(--green); }
.btn-auth-action { width: 100%; background: linear-gradient(135deg, var(--accent), #8b65ff); border: none; color: white; padding: 12px; border-radius: 10px; cursor: pointer; font-family: 'Syne', sans-serif; font-size: 14px; font-weight: 700; transition: .2s; letter-spacing: .3px; }
.btn-auth-action:hover:not(:disabled) { filter: brightness(1.1); transform: translateY(-1px); }
.btn-auth-action:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-auth-cancel { margin-top: 12px; width: 100%; background: transparent; border: 1px solid var(--border); color: var(--muted2); padding: 10px; border-radius: 10px; cursor: pointer; font-family: 'Syne', sans-serif; font-size: 13px; font-weight: 600; transition: .15s; }
.btn-auth-cancel:hover { background: var(--border); color: var(--text); }
.lockout-msg { color: var(--red); font-size: 12px; margin-top: 10px; font-weight: 600; display: none;}
@keyframes shake { 0%,100%{transform:translateX(0)} 25%{transform:translateX(-6px)} 75%{transform:translateX(6px)} }

#page-faq { position: relative; min-height: 100%; display: flex; align-items: center; justify-content: center; margin: -28px -32px; overflow: hidden; font-family: 'Rajdhani', sans-serif; }
#page-faq .faq-bg { position: absolute; inset: 0; background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(80,40,160,0.35) 0%, transparent 70%), radial-gradient(ellipse 60% 50% at 80% 100%, rgba(30,80,180,0.25) 0%, transparent 70%), #0a0b14; z-index: 0; }
#page-faq .faq-stars { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
#page-faq .star { position: absolute; width: 2px; height: 2px; background: white; border-radius: 50%; opacity: 0; animation: twinkle var(--d, 3s) var(--delay, 0s) infinite; }
@keyframes twinkle { 0%, 100% { opacity: 0; } 50% { opacity: var(--op, 0.6); } }
#page-faq .faq-card { position: relative; z-index: 1; background: rgba(15, 16, 30, 0.85); border: 1px solid rgba(120, 80, 255, 0.25); border-radius: 24px; padding: 52px 48px 44px; width: 520px; box-shadow: 0 0 80px rgba(80,40,200,0.2), inset 0 1px 0 rgba(255,255,255,0.05); backdrop-filter: blur(20px); animation: fadeIn 0.6s ease both; }
#page-faq .faq-badge { display: inline-flex; align-items: center; gap: 7px; background: rgba(120,80,255,0.15); border: 1px solid rgba(120,80,255,0.4); border-radius: 999px; padding: 5px 18px; font-family: 'Space Mono', monospace; font-size: 13px; letter-spacing: 0.14em; color: #a88fff; margin-bottom: 26px; }
#page-faq .faq-badge::before { content: ''; width: 7px; height: 7px; background: #a88fff; border-radius: 50%; box-shadow: 0 0 7px #a88fff; animation: pulseFAQ 2s infinite; }
@keyframes pulseFAQ { 0%,100% { opacity:1; } 50% { opacity:0.3; } }
#page-faq .faq-title { font-size: 58px; font-weight: 700; color: #fff; line-height: 1.05; letter-spacing: -0.01em; margin-bottom: 10px; font-family: 'Syne', sans-serif;}
#page-faq .faq-subtitle { font-family: var(--mono); font-size: 13px; color: rgba(180,160,255,0.55); letter-spacing: 0.05em; margin-bottom: 38px; }
#page-faq .faq-item { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.07); border-radius: 16px; padding: 26px 26px; display: flex; align-items: center; justify-content: space-between; gap: 20px; transition: border-color 0.25s, background 0.25s; }
#page-faq .faq-item:hover { background: rgba(120,80,255,0.07); border-color: rgba(120,80,255,0.3); }
#page-faq .faq-left { display: flex; align-items: center; gap: 18px; }
#page-faq .faq-icon { width: 52px; height: 52px; background: rgba(255,180,50,0.12); border: 1px solid rgba(255,180,50,0.25); border-radius: 13px; display: flex; align-items: center; justify-content: center; font-size: 26px; flex-shrink: 0; }
#page-faq .faq-text-title { font-size: 22px; font-weight: 700; color: #fff; letter-spacing: 0.01em; font-family: var(--font);}
#page-faq .faq-text-sub { font-family: var(--mono); font-size: 12px; color: rgba(180,160,255,0.5); margin-top: 3px; letter-spacing: 0.03em; }

#page-faq .fix-btn { position: relative; background: linear-gradient(135deg, #6c3fff 0%, #a855f7 100%); border: none; border-radius: 12px; padding: 14px 24px; font-family: var(--font); font-size: 17px; font-weight: 800; color: #fff; letter-spacing: 0.08em; cursor: pointer; white-space: nowrap; transition: transform 0.18s, box-shadow 0.18s; box-shadow: 0 4px 22px rgba(108,63,255,0.45); text-transform: uppercase; flex-shrink: 0; }
#page-faq .fix-btn:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 8px 32px rgba(108,63,255,0.65); }
#page-faq .fix-btn:active { transform: scale(0.97); }
#page-faq .fix-btn.running { background: linear-gradient(135deg, #1a1040 0%, #3b1f7a 100%); box-shadow: 0 4px 20px rgba(108,63,255,0.2); cursor: not-allowed; }
#page-faq .fix-btn .btn-content { display: flex; align-items: center; gap: 9px; }
#page-faq .fix-btn.running .spinner-faq { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.2); border-top-color: #fff; border-radius: 50%; animation: spin 0.7s linear infinite; }
#page-faq .fix-btn.running .btn-label { opacity: 0.6; }
#page-faq .faq-divider { height: 1px; background: linear-gradient(90deg, transparent, rgba(120,80,255,0.2), transparent); margin: 36px 0 30px; }
#page-faq .help-section { text-align: center; }
#page-faq .help-title { font-size: 22px; font-weight: 700; color: #fff; letter-spacing: 0.02em; margin-bottom: 14px; font-family: var(--font);}
#page-faq .discord-btn { display: inline-flex; align-items: center; gap: 8px; background: #5865F2; border: none; border-radius: 10px; padding: 10px 20px; font-family: 'Rajdhani', sans-serif; font-size: 15px; font-weight: 700; color: #fff; letter-spacing: 0.05em; cursor: pointer; text-decoration: none; transition: transform 0.18s, box-shadow 0.18s, background 0.18s; box-shadow: 0 4px 15px rgba(88,101,242,0.4); position: relative; overflow: hidden; margin-top: 5px; }
#page-faq .discord-btn::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(255,255,255,0.12), transparent); pointer-events: none; }
#page-faq .discord-btn:hover { background: #4752c4; transform: translateY(-2px) scale(1.02); box-shadow: 0 8px 24px rgba(88,101,242,0.6); }
#page-faq .discord-btn:active { transform: scale(0.97); }
#page-faq .discord-icon { width: 20px; height: 20px; flex-shrink: 0; }

/* --- CSS ROGUE MODAL --- */
.rogue-trigger { color: #ff2244; font-family: 'Share Tech Mono', monospace; font-size: 13px; text-decoration: none; border-bottom: 1px dashed #ff2244; transition: 0.3s; cursor: pointer; }
.rogue-trigger:hover { opacity: 0.7; box-shadow: 0 0 10px rgba(255, 34, 68, 0.4); }
.rogue-overlay { display: none; position: fixed; inset: 0; background: rgba(7, 10, 26, 0.9); backdrop-filter: blur(8px); z-index: 10000; align-items: center; justify-content: center; }
.rogue-card { background: linear-gradient(160deg, #111a3e 0%, #0c1228 100%); border: 1px solid rgba(255, 34, 68, 0.3); border-radius: 20px; width: 380px; padding: 30px; display: flex; flex-direction: column; align-items: center; gap: 15px; box-shadow: 0 0 50px rgba(255, 34, 68, 0.15); font-family: 'Share Tech Mono', monospace; }
.rogue-app-icon { font-size: 30px; background: #ff2244; width: 50px; height: 50px; display: flex; align-items: center; justify-content: center; border-radius: 12px; box-shadow: 0 0 20px rgba(255, 34, 68, 0.5); }
.rogue-error-block { width: 100%; background: rgba(255, 34, 68, 0.05); border: 1px solid rgba(255, 34, 68, 0.2); padding: 15px; border-radius: 8px; text-align: center; }
.rogue-error-title { color: #ff2244; font-size: 11px; font-weight: bold; margin-bottom: 10px; }
.rogue-error-code { font-size: 32px; font-weight: 900; color: #ff2244; opacity: 0.8; }
.rogue-error-msg { color: #7080b8; font-size: 12px; }
.rogue-error-msg span { color: #ff2244; }
.rogue-error-bar { width: 100%; background: #ff2244; color: white; padding: 8px; font-size: 10px; text-align: center; font-weight: bold; border-radius: 4px; }
.rogue-retry-btn { width: 100%; background: #3d5aff; color: white; border: none; padding: 12px; border-radius: 8px; cursor: pointer; font-weight: bold; transition: 0.3s; }
.rogue-retry-btn:hover { background: #5b7fff; transform: translateY(-2px); }
.rogue-retry-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.rogue-why-btn { background: none; border: 1px solid #ff2244; color: #ff2244; padding: 5px 10px; border-radius: 4px; cursor: pointer; margin-top: 10px; font-size: 10px; }
.rogue-close-text { background: none; border: none; color: #3a4470; cursor: pointer; font-size: 11px; margin-top: 10px; }
.step-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.8); z-index: 10001; align-items: center; justify-content: center; }
.step-content { background: #0e1330; padding: 20px; border-radius: 15px; border: 1px solid #3d5aff; text-align: center; max-width: 90%; }
.step-content img { width: 100%; max-width: 300px; border-radius: 10px; border: 1px solid #3d5aff; }
.step-content p { color: white; margin-top: 15px; font-size: 13px; }
.step-header { color: #3d5aff; font-size: 10px; margin-bottom: 10px; font-weight: bold; }