/* ==========================================================================
   GTA CHARACTER PORTFOLIO DOSSIER - CINEMATIC WORKSPACE STYLESHEET (characters.css)
   Author: AD Studio
   ========================================================================== */

/* Custom Game-Specific Wiki Fonts */
@font-face {
    font-family: 'ViceCityFont';
    src: url('./font/vicectiy.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'GTASA1';
    src: url('./font/gtasa1.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'GTASA2';
    src: url('./font/gtasa2.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Pricedown';
    src: url('./font/Pricedown Bl.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

:root {
    --accent-bright: #e6001a;
    --char-theme: #ff3399;
    --char-theme-rgb: 255, 51, 153;
    --char-theme-glow: rgba(255, 51, 153, 0.45);
    --char-theme-soft: rgba(255, 51, 153, 0.08);
    --char-vibe-color: #ff3399;
    --char-vibe-color-secondary: #ff6600;
    
    --transition-panel: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.8s ease;
    --border-color: rgba(255, 255, 255, 0.08);
    --panel-bg: rgba(7, 6, 10, 0.82);
}

* {
    box-sizing: border-box;
}

.dossier-body {
    background-color: #030206;
    height: 100vh;
    height: 100dvh;
    width: 100vw;
    overflow: hidden;
    position: relative;
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 400;
    color: #fff;
    margin: 0;
}



/* ==========================================================================
   FULLSCREEN INTRO LOADER
   ========================================================================== */
.gta-intro-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background-color: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999999;
    opacity: 1;
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), visibility 1s;
}

.loader-content-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 30px;
    width: 100%;
    max-width: 380px;
}

.logo-container {
    width: 160px;
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 0 30px rgba(230, 0, 26, 0.65));
    animation: loaderLogoPulse 2.2s infinite ease-in-out;
}

.gta-logo-svg {
    width: 100%;
    height: 100%;
}

@keyframes loaderLogoPulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 30px rgba(230, 0, 26, 0.65)); }
    50% { transform: scale(1.05); filter: drop-shadow(0 0 45px rgba(255, 26, 53, 0.85)); }
}

/* Comic Book Halftone Screen Transition Overlay */
.comic-halftone-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background-color: #fff;
    mix-blend-mode: difference;
    opacity: 0;
    z-index: 99990;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.comic-halftone-overlay.flash {
    animation: halftoneFlashTransition 0.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

@keyframes halftoneFlashTransition {
    0% { opacity: 0; }
    15% { opacity: 0.95; background-image: radial-gradient(rgba(0,0,0,0.95) 15%, transparent 20%); background-size: 12px 12px; }
    30% { opacity: 0.85; background-image: radial-gradient(rgba(0,0,0,0.95) 25%, transparent 30%); background-size: 16px 16px; }
    100% { opacity: 0; }
}

/* Lens flare sweep background overlay */
.hud-lens-flare {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at 10% 20%, var(--char-theme-glow) 0%, transparent 65%);
    mix-blend-mode: screen;
    pointer-events: none;
    z-index: 2;
    opacity: 0.45;
    animation: flareFloatSweep 20s infinite alternate ease-in-out;
    transition: background 0.8s ease;
}

@keyframes flareFloatSweep {
    0% { background-position: 0% 0%; }
    50% { background-position: 80% 30%; }
    100% { background-position: 20% 90%; }
}

/* ==========================================================================
   CINEMATIC BACKGROUND & CHARACTER SWAY LAYER
   ========================================================================== */
.dossier-parallax-container {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1;
    overflow: hidden;
}

/* Full-screen panning background */
.dossier-bg-layer {
    position: absolute;
    top: -5%; left: -5%; width: 110%; height: 110%;
    background-size: cover;
    background-position: center;
    filter: brightness(0.25) contrast(1.05) blur(1.5px);
    transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1.2s cubic-bezier(0.16, 1, 0.3, 1), background-image 0.8s ease;
}

/* Ambient color grading overlay blend */
.dossier-bg-layer::after {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at center, var(--char-vibe-color) 0%, var(--char-vibe-color-secondary) 100%);
    mix-blend-mode: color;
    opacity: 0.35;
    transition: background 0.8s ease;
}

/* Giant Watermark Name behind character */
.bg-watermark-name {
    position: absolute;
    top: 48%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 14vw;
    font-weight: 800;
    color: transparent;
    -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.02);
    letter-spacing: 20px;
    z-index: 2;
    pointer-events: none;
    text-align: center;
    width: 100%;
    transition: -webkit-text-stroke 0.8s ease, text-content 0.8s ease, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.8s ease;
}

/* Character Portrait anchored to bottom */
.dossier-char-layer {
    position: absolute;
    bottom: 0; /* sit at the bottom of the screen */
    left: 50%;
    transform: translateX(-50%);
    transform-origin: bottom center;
    width: 45%;
    height: 92%;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    z-index: 3;
    pointer-events: none;
    transition: left 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.6s ease;
}

.dossier-char-img {
    height: 88%;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    object-position: bottom center;
    filter: drop-shadow(0 20px 45px rgba(0,0,0,0.95));
    transform-origin: bottom center;
    animation: characterAmbientSway 22s infinite alternate ease-in-out;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s ease;
}

/* Slow, natural, alive swaying animation */
@keyframes characterAmbientSway {
    0% { transform: translateX(-22px) rotate(-0.8deg); }
    100% { transform: translateX(22px) rotate(0.8deg); }
}

.dossier-char-img.fallback-logo-img {
    height: 38% !important;
    opacity: 0.15;
    filter: drop-shadow(0 0 25px rgba(var(--char-theme-rgb), 0.45)) grayscale(1) brightness(1.5);
    align-self: center;
    margin-bottom: 15%;
    animation: none;
}

/* ==========================================================================
   CINEMATIC FULL-WIDTH FLOOR FADE (Masks bottom edges across screen width)
   ========================================================================== */
.cinematic-floor-fade {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100vw;
    height: 140px;
    background: linear-gradient(to top, #030206 0%, rgba(3, 2, 6, 0.85) 45%, transparent 100%);
    z-index: 6; /* Above character portrait & weather overlay */
    pointer-events: none;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.8s ease;
}

/* ==========================================================================
   SATELLITE SKY ZOOM SWAP EFFECTS
   ========================================================================== */
/* Satellite grid scan overlay */
.satellite-scan-grid {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: 
        linear-gradient(rgba(0, 255, 127, 0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 127, 0.015) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: 99;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Active zoom states */
body.satellite-swapping .dossier-bg-layer {
    transform: scale(3.2) rotate(4deg);
    filter: brightness(0.08) contrast(1.2) blur(10px);
}

body.satellite-swapping .dossier-char-layer {
    opacity: 0;
    transform: translateX(-50%) translateY(40px) scale(0.92);
}

body.satellite-swapping .bg-watermark-name {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
}

body.satellite-swapping .satellite-scan-grid {
    opacity: 1;
    animation: satPulse 0.4s steps(2, start) infinite;
}

@keyframes satPulse {
    0%, 100% { background-color: rgba(var(--char-theme-rgb), 0.02); }
    50% { background-color: rgba(255, 255, 255, 0.01); }
}

/* ==========================================================================
   WEATHER CANVAS LAYER (Flys directly in front of the character portrait)
   ========================================================================== */
.weather-canvas-layer {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none;
    z-index: 4; /* Layered directly OVER the character (z-index 3) and behind panels */
}

/* ==========================================================================
   TOP BAR HUD HEADER
   ========================================================================== */
.hud-navigation {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 65px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 45px;
    z-index: 100;
    box-sizing: border-box;
    background: rgba(7, 6, 10, 0.65);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: var(--transition-panel);
}

.hud-brand {
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 700;
    letter-spacing: 2px;
    font-size: 1.15rem;
}

.hud-logo-text {
    text-decoration: none;
    color: #fff;
}

.brand-ad {
    color: #ffffff;
    text-shadow: 0 0 12px rgba(255, 255, 255, 0.25);
}

.brand-studio {
    transition: color 0.8s ease, text-shadow 0.8s ease;
    color: var(--char-theme);
    text-shadow: 0 0 12px var(--char-theme-glow);
}

.hud-center-title-dossier {
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 500;
    font-size: 0.7rem;
    letter-spacing: 4px;
    color: #6c7080;
    text-transform: uppercase;
}

/* Atmosphere state indicator */
#weatherOverlayStatus {
    font-family: monospace;
    font-size: 0.58rem;
    color: var(--char-theme);
    background: rgba(var(--char-theme-rgb), 0.05);
    border: 1px solid rgba(var(--char-theme-rgb), 0.2);
    padding: 5px 12px;
    border-radius: 4px;
    letter-spacing: 1px;
    transition: color 0.8s ease, border-color 0.8s ease, background-color 0.8s ease, text-shadow 0.8s ease;
}

.hud-action-btn.elite-cta {
    background: rgba(var(--char-theme-rgb), 0.05);
    border: 1px solid rgba(var(--char-theme-rgb), 0.25);
    color: var(--char-theme) !important;
    padding: 6px 14px;
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 700;
    font-size: 0.6rem;
    letter-spacing: 1.5px;
    border-radius: 4px;
    box-shadow: none;
    cursor: pointer;
    transition: color 0.8s ease, border-color 0.8s ease, background-color 0.8s ease, box-shadow 0.8s ease;
}

.hud-action-btn.elite-cta:hover {
    background: var(--char-theme) !important;
    color: #030206 !important;
    border-color: var(--char-theme) !important;
    box-shadow: 0 0 15px var(--char-theme-glow) !important;
    transition: all 0.3s ease;
}

/* ==========================================================================
   BALANCED FLOATING HUD WORKSPACE (Grid Layout)
   ========================================================================== */
.hud-workspace-container {
    position: absolute;
    top: 65px;
    left: 0;
    width: 100vw;
    height: calc(100vh - 65px - 95px); /* Offset top and bottom trigger spaces */
    height: calc(100dvh - 65px - 95px);
    display: grid;
    grid-template-columns: 28% 44% 28%;
    padding: 20px 45px;
    box-sizing: border-box;
    z-index: 10;
    pointer-events: none;
}

/* COLUMN 1: LEFT HUD PANEL */
.hud-left-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 15px;
    pointer-events: auto;
    transition: var(--transition-panel);
    max-height: 100%;
    overflow-y: auto;
    scrollbar-width: none;
}
.hud-left-panel::-webkit-scrollbar { display: none; }

.hud-id-header {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.game-origin-stamp {
    font-size: 0.8rem;
    margin-bottom: 2px;
    transition: all 0.5s ease;
}
.stamp-vc { font-family: 'ViceCityFont', cursive; font-size: 1.7rem; color: #ff3399; text-transform: none; text-shadow: 0 0 10px rgba(255, 51, 153, 0.4); }
.stamp-sa { font-family: 'GTASA2', serif; font-size: 1.25rem; color: #fbc02d; text-transform: none; text-shadow: 0 0 8px rgba(251, 192, 45, 0.4); }
.stamp-iv { font-family: 'Pricedown', sans-serif; font-size: 1.25rem; color: #9e9e9e; }
.stamp-v { font-family: 'Pricedown', sans-serif; font-size: 1.45rem; color: #2e7d32; text-transform: lowercase; text-shadow: 0 0 8px rgba(46, 125, 50, 0.5); }
.stamp-default { font-family: 'GTAArtDeco', sans-serif; font-weight: 700; font-size: 1rem; color: var(--char-theme); }

.char-main-name {
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 800;
    font-size: 2.5rem;
    line-height: 0.95;
    color: #fff;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.char-kicker-badge {
    font-family: monospace;
    font-size: 0.6rem;
    letter-spacing: 2px;
    color: var(--char-theme);
    text-transform: uppercase;
    margin-top: 4px;
    font-weight: bold;
    transition: color 0.8s ease;
}

.char-quote-text {
    border-left: 2px solid var(--char-theme);
    padding-left: 15px;
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 400;
    font-style: italic;
    font-size: 0.9rem;
    line-height: 1.45;
    color: #d1d5db;
    margin: 5px 0 0 0;
    transition: border-color 0.8s ease;
}

.action-read-dossier {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: #fff;
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 2px;
    padding: 10px 18px;
    border-radius: 4px;
    cursor: pointer;
    outline: none;
    width: fit-content;
    margin-top: 5px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.action-read-dossier:hover {
    background: var(--char-theme);
    border-color: var(--char-theme);
    box-shadow: 0 0 15px rgba(var(--char-theme-rgb), 0.4);
    color: #030206;
    transform: translateY(-2px);
}

/* Minimalist Audio wiretap player */
.voice-playback-box {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 5px;
}

.voice-circle-trigger {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--char-theme-soft);
    border: 1px solid var(--char-theme);
    color: var(--char-theme);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    outline: none;
    font-size: 0.65rem;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.voice-circle-trigger:hover {
    background: var(--char-theme);
    color: #030206;
    box-shadow: 0 0 10px var(--char-theme-glow);
}

.voice-circle-trigger.playing {
    background: var(--accent-bright);
    border-color: var(--accent-bright);
    color: #fff;
    box-shadow: 0 0 10px rgba(230, 0, 26, 0.4);
}

.voice-meta-stack {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.voice-stack-lbl {
    font-family: monospace;
    font-size: 0.5rem;
    color: #6c7080;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.voice-stack-title {
    font-size: 0.7rem;
    color: #e2e5f0;
}

/* Soundwave line animations */
.voice-wave-anim {
    display: flex;
    gap: 2.5px;
    height: 10px;
    align-items: center;
}

.voice-wave-anim span {
    width: 2px;
    height: 100%;
    background: var(--char-theme);
    opacity: 0.25;
    transform: scaleY(0.2);
    transform-origin: center;
    transition: background-color 0.8s ease;
}

.voice-wave-anim.playing span {
    opacity: 0.9;
    animation: voiceWavePulse 0.7s infinite alternate ease-in-out;
}
.voice-wave-anim.playing span:nth-child(1) { animation-delay: 0.1s; }
.voice-wave-anim.playing span:nth-child(2) { animation-delay: 0.25s; }
.voice-wave-anim.playing span:nth-child(3) { animation-delay: 0.4s; }
.voice-wave-anim.playing span:nth-child(4) { animation-delay: 0.15s; }
.voice-wave-anim.playing span:nth-child(5) { animation-delay: 0.3s; }

@keyframes voiceWavePulse {
    0% { transform: scaleY(0.2); }
    100% { transform: scaleY(1.0); }
}

/* COLUMN 2: SPACER */
.hud-center-spacer {
    position: relative;
}

/* COLUMN 3: RIGHT HUD PANEL */
.hud-right-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 18px;
    pointer-events: auto;
    transition: var(--transition-panel);
    max-height: 100%;
    overflow-y: auto;
    scrollbar-width: none;
}
.hud-right-panel::-webkit-scrollbar { display: none; }

.profile-specs-list {
    display: flex;
    flex-direction: column;
    gap: 7px;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 10px;
}

.profile-spec-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.68rem;
}

.profile-spec-lbl {
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.55rem;
    letter-spacing: 1.2px;
    color: #636675;
    text-transform: uppercase;
    font-weight: 500;
}

.profile-spec-val {
    font-weight: 500;
    color: #e2e5f0;
}

.profile-spec-val.active-status {
    color: var(--char-theme);
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 700;
    letter-spacing: 1px;
    font-size: 0.68rem;
    transition: color 0.8s ease;
}

/* Threat Index flasher */
.threat-intel-warning-badge {
    background: rgba(var(--char-theme-rgb), 0.12);
    border: 1px solid var(--char-theme);
    color: #fff;
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 2px;
    padding: 6px 12px;
    text-transform: uppercase;
    width: fit-content;
    margin-top: 5px;
    box-shadow: 0 0 10px rgba(var(--char-theme-rgb), 0.2);
    cursor: pointer;
    transition: border-color 0.8s ease, background 0.8s ease, box-shadow 0.8s ease;
    animation: threatAlertPulse 1.8s infinite;
}

@keyframes threatAlertPulse {
    0%, 100% { box-shadow: 0 0 4px rgba(var(--char-theme-rgb), 0.2); }
    50% { box-shadow: 0 0 15px rgba(var(--char-theme-rgb), 0.45); background: rgba(var(--char-theme-rgb), 0.22); }
}

.attributes-grid-hud {
    display: flex;
    flex-direction: column;
    gap: 8px;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 10px;
}

.attr-bar-row {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.attr-row-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.55rem;
    color: #6c7080;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.attr-row-labels span:nth-child(1) { font-family: 'GTAArtDeco', sans-serif; font-weight: 500; }
.attr-row-labels span:nth-child(2) {
    font-family: monospace;
    color: var(--char-theme);
    font-size: 0.58rem;
    transition: color 0.8s ease;
}

.attr-bar-track {
    height: 4px;
    background: rgba(255,255,255,0.02);
    border-radius: 1px;
    overflow: hidden;
}

.attr-bar-fill {
    height: 100%;
    width: 0%;
    background-color: var(--char-theme);
    box-shadow: 0 0 6px var(--char-theme-glow);
    transition: width 1.2s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.8s ease;
}

.inventory-arsenal-section {
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 10px;
}

.inv-arsenal-hdr {
    display: flex;
    justify-content: space-between;
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.58rem;
    letter-spacing: 1px;
    color: #6c7080;
    text-transform: uppercase;
}
.inv-arsenal-hdr span:nth-child(2) {
    color: var(--char-theme);
    transition: color 0.8s ease;
}

.inv-arsenal-rack {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
}

.inv-wep-slot {
    height: 32px;
    border: 1px solid rgba(255, 255, 255, 0.04);
    background: rgba(255, 255, 255, 0.005);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 3px;
    transition: all 0.3s ease;
}

.inv-wep-slot img {
    max-height: 85%;
    max-width: 85%;
    object-fit: contain;
    filter: drop-shadow(0 0 2px rgba(0,0,0,0.5));
}

.inv-wep-slot svg {
    max-height: 80%;
    max-width: 80%;
    color: rgba(255,255,255,0.15);
    transition: all 0.3s ease;
}

.inv-wep-slot:hover {
    border-color: var(--char-theme);
    background: var(--char-theme-soft);
}

.inv-wep-slot:hover svg {
    color: #fff;
    transform: scale(1.06);
}

/* ==========================================================================
   THE USER'S INTERACTIVE STORY FOCUS VIEWPORT (Read mode details)
   ========================================================================== */
.story-focus-container {
    position: absolute;
    top: 65px;
    right: 10%;
    width: 38%;
    height: calc(100vh - 65px - 95px);
    height: calc(100dvh - 65px - 95px);
    z-index: 50;
    display: flex;
    flex-direction: column;
    justify-content: center;
    pointer-events: none;
    opacity: 0;
    transform: translateX(80px);
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.8s ease;
}

.story-focus-container.focus-active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.story-game-stamp {
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.72rem;
    letter-spacing: 4px;
    color: var(--char-theme);
    text-transform: uppercase;
    margin-bottom: 10px;
    transition: color 0.8s ease;
}

.story-character-name {
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 3.5rem;
    line-height: 1.05;
    font-weight: 800;
    color: #fff;
    margin: 0 0 20px 0;
}

.story-full-bio {
    font-size: 0.85rem;
    line-height: 1.7;
    color: #b3b7c6;
    text-align: justify;
    margin-bottom: 30px;
    max-height: 50%;
    overflow-y: auto;
    padding-right: 10px;
}

.action-exit-focus {
    background: none;
    border: 1px solid var(--char-theme);
    color: var(--char-theme);
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 2px;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    outline: none;
    width: fit-content;
    transition: all 0.3s ease;
}

.action-exit-focus:hover {
    background: var(--char-theme);
    color: #030206;
    box-shadow: 0 0 12px var(--char-theme-glow);
}

/* ==========================================================================
   UNCONVENTIONAL COMPACT SWAP TRIGGER (Bottom Right)
   ========================================================================== */
.hud-switcher-trigger-wrap {
    position: absolute;
    bottom: 45px;
    right: 45px;
    z-index: 100;
    pointer-events: auto;
    transition: var(--transition-panel);
}

.hud-switcher-btn {
    background: var(--panel-bg);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-left: 3px solid var(--char-theme);
    padding: 10px 18px;
    border-radius: 4px;
    cursor: pointer;
    color: #fff;
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.hud-switcher-btn:hover {
    border-color: var(--char-theme);
    box-shadow: 0 0 15px rgba(var(--char-theme-rgb), 0.25);
    transform: translateY(-2px);
}

.switcher-avatar-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1px solid var(--char-theme);
    background: #000;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.8s ease;
}

.switcher-avatar-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ==========================================================================
   EXPANDABLE HEIST PLANNING BOARD (Fullscreen Overlay)
   ========================================================================== */
.heist-board-overlay {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background: rgba(3, 2, 6, 0.85);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    z-index: 999990;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.5s;
}

.heist-board-overlay.board-active {
    opacity: 1;
    visibility: visible;
}

.heist-board-container {
    width: 90%;
    max-width: 1100px;
    height: 80%;
    max-height: 650px;
    display: flex;
    flex-direction: column;
    gap: 25px;
    transform: scale(0.95);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.heist-board-overlay.board-active .heist-board-container {
    transform: scale(1);
}

.heist-board-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 15px;
}

.heist-board-header h2 {
    font-family: 'GTAArtDeco', sans-serif;
    font-weight: 700;
    font-size: 1.35rem;
    letter-spacing: 2px;
    color: #fff;
    margin: 0;
}
.heist-board-header h2 span {
    color: var(--char-theme);
    transition: color 0.8s ease;
}

.board-close-btn {
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #8b8e9c;
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 2px;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    outline: none;
    transition: all 0.3s ease;
}

.board-close-btn:hover {
    border-color: #fff;
    color: #fff;
}

.heist-board-tabs {
    display: flex;
    gap: 12px;
}

.board-tab-btn {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #8b8e9c;
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.6rem;
    font-weight: 500;
    letter-spacing: 1.5px;
    padding: 8px 16px;
    border-radius: 3px;
    cursor: pointer;
    outline: none;
    transition: all 0.3s ease;
}

.board-tab-btn:hover {
    border-color: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.board-tab-btn.active-tab {
    background: var(--char-theme);
    border-color: var(--char-theme);
    color: #030206;
    font-weight: bold;
    box-shadow: 0 0 10px var(--char-theme-glow);
}

.heist-board-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    overflow-y: auto;
    padding-right: 5px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.05) transparent;
}

.heist-board-grid::-webkit-scrollbar { width: 4px; }
.heist-board-grid::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
}

.board-character-card {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-left: 3px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    height: 100px;
    display: flex;
    align-items: center;
    padding: 0 20px;
    gap: 18px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.1);
    overflow: hidden;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.card-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.card-name {
    font-family: 'GTAArtDeco', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    color: #d1d4df;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.card-game {
    font-family: monospace;
    font-size: 0.52rem;
    color: #6c7080;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.card-status {
    font-size: 0.52rem;
    font-weight: 700;
    color: var(--accent-bright);
    letter-spacing: 0.5px;
    margin-top: 3px;
}

.board-character-card:hover {
    border-color: var(--card-theme);
    background: rgba(var(--card-theme-rgb), 0.03);
    transform: translateY(-2px);
}

.board-character-card:hover .card-avatar {
    border-color: var(--card-theme);
    box-shadow: 0 0 10px rgba(var(--card-theme-rgb), 0.3);
}

.board-character-card:hover .card-name {
    color: #ffffff;
    text-shadow: 0 0 8px rgba(var(--card-theme-rgb), 0.3);
}

.board-character-card.active-card {
    border-color: var(--card-theme);
    background: rgba(var(--card-theme-rgb), 0.06);
    box-shadow: inset 0 0 15px rgba(var(--card-theme-rgb), 0.12);
}

.board-character-card.active-card .card-avatar {
    border-color: var(--card-theme);
    box-shadow: 0 0 10px rgba(var(--card-theme-rgb), 0.4);
}

.board-character-card.active-card .card-name {
    color: #ffffff;
    font-weight: 900;
}

/* Help hotkeys tooltip */
.hud-hotkey-tooltip-badge {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    font-family: monospace;
    font-size: 0.55rem;
    color: rgba(255,255,255,0.18);
    letter-spacing: 1.2px;
    z-index: 100;
    transition: var(--transition-panel);
    text-transform: uppercase;
}

/* Empty footer carousel height offset */
.hud-bottom-carousel {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100vw;
    height: 95px;
    z-index: 100;
    transition: var(--transition-panel);
}

/* ==========================================================================
   CINEMATIC FOCUS READ MODE PAGE SHIFTS
   ========================================================================== */
body.mode-reading .hud-left-panel {
    transform: translateX(-120%);
    opacity: 0;
    pointer-events: none;
}

body.mode-reading .hud-right-panel {
    transform: translateX(120%);
    opacity: 0;
    pointer-events: none;
}

body.mode-reading .hud-navigation {
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
}

body.mode-reading .hud-switcher-trigger-wrap {
    transform: scale(0.6) translate(80px, 80px);
    opacity: 0;
    pointer-events: none;
}

body.mode-reading .hud-hotkey-tooltip-badge {
    transform: translateY(50px);
    opacity: 0;
}

body.mode-reading .dossier-char-layer {
    left: 28%; /* Smoothly drifts portrait to left center */
    transform: translateX(-50%) scale(1.08); /* Scales up slightly for a dramatic zoom-in */
}

body.mode-reading .bg-watermark-name {
    transform: translate(-70%, -50%) scale(0.95);
}

body.mode-reading .cinematic-floor-fade {
    transform: none;
    opacity: 0.95;
}

/* ==========================================================================
   EASTER EGGS & INTERACTIVE GAME FX STYLING
   ========================================================================== */


/* 2. CCTV Screen Glitch overlay */
.cctv-glitch-overlay {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background: #040306;
    z-index: 999997;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease;
}

.cctv-glitch-overlay.active {
    opacity: 1;
    visibility: visible;
    animation: cctvShake 0.4s infinite;
}

.cctv-static {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: repeating-linear-gradient(0deg, rgba(255,255,255,0.015), rgba(255,255,255,0.015) 1px, transparent 1px, transparent 2px);
    opacity: 0.85;
    animation: staticDrift 0.2s linear infinite;
}

.cctv-scanline {
    position: absolute;
    top: -10%; left: 0; width: 100%; height: 10px;
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 0 12px rgba(255, 255, 255, 0.08);
    animation: cctvScanlineMove 3s linear infinite;
}

.cctv-text-wrapper {
    text-align: center;
    z-index: 10;
    font-family: monospace;
    letter-spacing: 3px;
    color: #fff;
    padding: 20px;
}

.cctv-warning {
    font-size: 0.85rem;
    color: #ff3333;
    text-shadow: 0 0 8px rgba(255, 51, 51, 0.6);
    margin-bottom: 8px;
    animation: flashAlert 0.5s steps(2, start) infinite;
}

.cctv-status {
    font-size: 0.6rem;
    color: #8b8e9c;
}

@keyframes cctvShake {
    0%, 100% { transform: translate(0, 0); }
    20% { transform: translate(-3px, 2px); }
    40% { transform: translate(2px, -2px); }
    60% { transform: translate(-1px, -1px); }
    80% { transform: translate(2px, 1px); }
}

@keyframes staticDrift {
    0% { background-position: 0 0; }
    100% { background-position: 0 40px; }
}

@keyframes cctvScanlineMove {
    0% { top: -10%; }
    100% { top: 110%; }
}

@keyframes flashAlert {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.2; }
}

/* 3. GTA Cheat Console Command overlay */
.cheat-console-wrap {
    position: fixed;
    top: -160px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    max-width: 600px;
    background: rgba(3, 2, 6, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-bottom: 2px solid var(--char-theme);
    border-radius: 0 0 8px 8px;
    padding: 12px 18px;
    z-index: 999998;
    box-shadow: 0 15px 35px rgba(0,0,0,0.85);
    transition: top 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: auto;
}

.cheat-console-wrap.active {
    top: 0; /* Drops flush to top edge */
}

.console-hdr {
    font-family: monospace;
    font-size: 0.52rem;
    letter-spacing: 1.5px;
    color: #6c7080;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.console-input-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.console-prompt {
    font-family: monospace;
    font-size: 0.95rem;
    color: var(--char-theme);
    text-shadow: 0 0 5px var(--char-theme-glow);
    transition: color 0.8s ease;
}

#cheatInput {
    flex-grow: 1;
    background: none;
    border: none;
    outline: none;
    color: #fff;
    font-family: monospace;
    font-size: 0.9rem;
    letter-spacing: 1px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.15);
    padding-bottom: 3px;
}

.console-response {
    margin-top: 8px;
    font-family: monospace;
    font-size: 0.58rem;
    color: var(--char-theme);
    opacity: 0.8;
    transition: color 0.8s ease;
}

/* 4. WASTED Death Screen overlay */
.wasted-screen-overlay {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: 999999;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1.8s ease;
}

.wasted-screen-overlay.active {
    opacity: 1;
    visibility: visible;
}

.wasted-vignette {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    box-shadow: inset 0 0 150px rgba(0, 0, 0, 0.95);
    background: radial-gradient(circle, transparent 20%, rgba(0,0,0,0.8) 100%);
}

.wasted-text-wrap {
    z-index: 10;
    transform: scale(1.4);
    opacity: 0;
    transition: transform 3.5s cubic-bezier(0.1, 0.8, 0.2, 1), opacity 1.5s ease;
}

.wasted-screen-overlay.active .wasted-text-wrap {
    transform: scale(1);
    opacity: 1;
}

.wasted-title {
    font-family: 'Pricedown', 'Space Grotesk', sans-serif;
    font-size: 6.5vw;
    color: #b01b1b;
    text-shadow: 2px 2px 0px #000, 0 0 25px rgba(176, 27, 27, 0.6);
    letter-spacing: 6px;
    text-transform: uppercase;
    font-weight: normal;
    margin: 0;
}

/* Body modifications during Wasted event */
body.wasted-effect-active #parallaxContainer {
    filter: grayscale(1) contrast(1.15) brightness(0.35) !important;
    transition: filter 2.5s ease !important;
}

body.wasted-effect-active .hud-workspace-container,
body.wasted-effect-active .hud-navigation,
body.wasted-effect-active .hud-switcher-trigger-wrap,
body.wasted-effect-active .hud-hotkey-tooltip-badge {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    transition: opacity 1.5s ease, transform 1.5s ease;
}

/* 5. Police Sirens vignettes */
.hud-wanted-alert-vignette {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: 999990;
    pointer-events: none;
    display: none;
    box-shadow: inset 0 0 110px rgba(0,0,0,0.9);
}

.hud-wanted-alert-vignette.active {
    display: block;
    animation: policeSirensFlash 0.6s steps(2, start) infinite;
}

@keyframes policeSirensFlash {
    0%, 100% { box-shadow: inset 0 0 120px rgba(230, 0, 26, 0.45); }
    50% { box-shadow: inset 0 0 120px rgba(0, 136, 255, 0.45); }
}

/* 6. Audio-Reactive Watermark pulse */
.bg-watermark-name.pulse-active {
    animation: watermarkAudioPulse 1.2s infinite ease-in-out;
}

@keyframes watermarkAudioPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    50% { transform: translate(-50%, -50%) scale(1.05); opacity: 0.15; }
}

/* Blinking REC node styling */
#weatherOverlayStatus.rec-active {
    color: #ff3333 !important;
    background: rgba(255, 51, 51, 0.06) !important;
    border-color: rgba(255, 51, 51, 0.25) !important;
    text-shadow: 0 0 8px rgba(255, 51, 51, 0.6) !important;
    animation: blinkRecText 1s infinite;
}

@keyframes blinkRecText {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* 7. Easter Egg cheat code graphic overlays */
.panzer-tank-vector {
    position: absolute;
    bottom: -100px;
    right: -100px;
    width: 350px;
    height: auto;
    opacity: 0;
    z-index: 2;
    color: rgba(var(--char-theme-rgb), 0.15);
    pointer-events: none;
    transform: rotate(-10deg) scale(0.6);
    transition: all 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.panzer-tank-vector.spawned {
    opacity: 1;
    bottom: 50px;
    right: 50px;
    transform: rotate(0deg) scale(1);
}

.seaways-ripples-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: radial-gradient(circle, rgba(0, 229, 255, 0.02) 20%, transparent 60%);
    z-index: 2;
    pointer-events: none;
    opacity: 0;
    transition: opacity 1.5s ease;
}

.seaways-ripples-overlay.active {
    opacity: 1;
    animation: rippleWaveMotion 8s linear infinite;
}

/* ==========================================================================
   IPHONE & TOUCH RESPONSIVE DOSSIER
   ========================================================================== */
html {
    min-height: 100%;
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

button,
a,
input {
    touch-action: manipulation;
}

@media (max-width: 900px) {
    .dossier-body {
        width: 100%;
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .dossier-parallax-container,
    .dossier-char-layer,
    .cinematic-floor-fade {
        position: fixed;
    }

    .dossier-char-layer {
        width: 100%;
        height: 68vh;
        height: 68svh;
        opacity: 0.7;
    }

    .dossier-char-img {
        height: 82%;
        max-width: 92vw;
    }

    .bg-watermark-name {
        position: fixed;
        top: 42%;
        font-size: 24vw;
        letter-spacing: 8px;
    }

    .hud-navigation {
        position: fixed;
        width: 100%;
        height: auto;
        min-height: 64px;
        padding:
            max(10px, env(safe-area-inset-top))
            max(16px, env(safe-area-inset-right))
            10px
            max(16px, env(safe-area-inset-left));
        gap: 12px;
    }

    .hud-center-title-dossier,
    .hud-status-node {
        display: none;
    }

    .hud-brand {
        font-size: 1rem;
        white-space: nowrap;
    }

    .hud-action-btn.elite-cta {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        padding: 8px 12px;
    }

    .hud-workspace-container {
        position: relative;
        top: 0;
        width: 100%;
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
        display: flex;
        flex-direction: column;
        gap: 18px;
        padding:
            calc(86px + env(safe-area-inset-top))
            max(16px, env(safe-area-inset-right))
            calc(120px + env(safe-area-inset-bottom))
            max(16px, env(safe-area-inset-left));
        pointer-events: auto;
    }

    .hud-left-panel,
    .hud-right-panel {
        width: 100%;
        max-height: none;
        justify-content: flex-start;
        overflow: visible;
        padding: 20px;
        background: rgba(7, 6, 10, 0.78);
        border: 1px solid rgba(255, 255, 255, 0.08);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
    }

    .char-main-name {
        font-size: clamp(2rem, 11vw, 3rem);
        overflow-wrap: anywhere;
    }

    .char-quote-text {
        max-width: none;
    }

    .action-read-dossier {
        min-height: 44px;
        width: 100%;
        justify-content: space-between;
    }

    .voice-playback-box {
        min-height: 48px;
    }

    .voice-circle-trigger {
        width: 44px;
        height: 44px;
    }

    .hud-center-spacer {
        order: 2;
        width: 100%;
        height: 46vh;
        height: 46svh;
        flex: 0 0 auto;
        pointer-events: none;
    }

    .hud-left-panel {
        order: 1;
    }

    .hud-right-panel {
        order: 3;
    }

    .profile-spec-row {
        min-height: 34px;
        gap: 16px;
    }

    .profile-spec-val {
        text-align: right;
        overflow-wrap: anywhere;
    }

    .inv-arsenal-rack {
        grid-template-columns: repeat(4, minmax(52px, 1fr));
    }

    .inv-wep-slot {
        height: 52px;
    }

    .hud-hotkey-tooltip-badge,
    .hud-bottom-carousel {
        display: none;
    }

    .hud-switcher-trigger-wrap {
        position: fixed;
        right: max(14px, env(safe-area-inset-right));
        bottom: max(14px, env(safe-area-inset-bottom));
        z-index: 200;
    }

    .hud-switcher-btn {
        min-height: 52px;
        padding: 9px 12px;
    }

    .story-focus-container {
        position: fixed;
        inset:
            calc(64px + env(safe-area-inset-top))
            0
            0
            0;
        width: auto;
        height: auto;
        padding:
            32px
            max(22px, env(safe-area-inset-right))
            max(32px, env(safe-area-inset-bottom))
            max(22px, env(safe-area-inset-left));
        justify-content: flex-start;
        overflow-y: auto;
        background: rgba(3, 2, 6, 0.96);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
    }

    .story-character-name {
        font-size: clamp(2.3rem, 12vw, 3.5rem);
        overflow-wrap: anywhere;
    }

    .story-full-bio {
        max-height: none;
        text-align: left;
        overflow: visible;
        padding-right: 0;
    }

    .action-exit-focus {
        width: 100%;
        min-height: 48px;
    }

    .heist-board-overlay {
        width: 100%;
        height: 100vh;
        height: 100dvh;
        align-items: stretch;
        padding:
            max(18px, env(safe-area-inset-top))
            max(14px, env(safe-area-inset-right))
            max(18px, env(safe-area-inset-bottom))
            max(14px, env(safe-area-inset-left));
    }

    .heist-board-container {
        width: 100%;
        height: 100%;
        max-height: none;
        gap: 16px;
    }

    .heist-board-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 14px;
    }

    .heist-board-header h2 {
        font-size: 1.05rem;
        line-height: 1.45;
    }

    .board-close-btn {
        width: 100%;
        min-height: 44px;
    }

    .heist-board-tabs {
        overflow-x: auto;
        padding-bottom: 6px;
        -webkit-overflow-scrolling: touch;
    }

    .board-tab-btn {
        min-height: 44px;
        flex: 0 0 auto;
    }

    .heist-board-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
    }

    .board-character-card {
        min-height: 92px;
        height: auto;
        padding: 14px 16px;
    }

    .cheat-console-wrap {
        left: max(12px, env(safe-area-inset-left));
        right: max(12px, env(safe-area-inset-right));
        width: auto;
        max-width: none;
    }

    body.mode-reading .dossier-char-layer {
        left: 50%;
        opacity: 0.18;
        transform: translateX(-50%) scale(1);
    }
}

@media (max-width: 430px) {
    .hud-navigation {
        min-height: 60px;
    }

    .hud-action-btn.elite-cta {
        font-size: 0.52rem;
        letter-spacing: 0.8px;
    }

    .hud-workspace-container {
        padding-top: calc(80px + env(safe-area-inset-top));
    }

    .hud-left-panel,
    .hud-right-panel {
        padding: 18px 15px;
    }

    .hud-center-spacer {
        height: 42svh;
    }

    .inv-arsenal-rack {
        grid-template-columns: repeat(3, minmax(52px, 1fr));
    }

    .hud-switcher-btn > div:nth-child(2),
    .hud-switcher-btn > span:last-child {
        display: none !important;
    }
}

@media (orientation: landscape) and (max-height: 520px) and (max-width: 900px) {
    .hud-center-spacer {
        height: 65svh;
    }

    .dossier-char-layer {
        height: 92svh;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

@keyframes rippleWaveMotion {
    0%, 100% { background-position: 0% 0%; }
    50% { background-position: 10% 5%; }
}
