
/* ═══════════════════════════════════════════════════════════════════
   HTML MANTENIMIENTO V2 — ENHANCEMENT STYLES
   All new components added in version 2
   ═══════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────────────
   SPLASH SCREEN
   ───────────────────────────────────────────────────────────────── */
#splash-screen {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: #020c15;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}
#splash-screen.fade-out {
    animation: splashFadeOut 0.6s ease-out forwards;
}
@keyframes splashFadeOut {
    to { opacity: 0; pointer-events: none; }
}

.splash-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    width: min(480px, 90vw);
}

.splash-logo {
    position: relative;
    width: 90px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
}
.splash-logo-text {
    font-family: var(--font-display);
    font-size: 2.2rem;
    font-weight: 900;
    color: #6abdbc;
    text-shadow: 0 0 30px rgba(106,189,188,0.8);
    position: relative;
    z-index: 2;
}
.splash-logo-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 2px solid rgba(106,189,188,0.4);
    box-shadow: 0 0 20px rgba(106,189,188,0.3), inset 0 0 20px rgba(106,189,188,0.1);
    animation: splashRingPulse 1.5s ease-in-out infinite;
}
@keyframes splashRingPulse {
    0%,100% { transform: scale(1); opacity: 0.6; }
    50%      { transform: scale(1.12); opacity: 1; }
}

.splash-log-wrap {
    width: 100%;
    height: 120px;
    overflow: hidden;
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.72rem;
}
#splash-log {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.splash-log-line {
    color: rgba(255,255,255,0.55);
    animation: logLineIn 0.2s ease-out both;
}
.splash-log-line.ok   { color: #6abdbc; }
.splash-log-line.warn { color: #d7de4f; }
.splash-log-line.err  { color: #da4357; }
@keyframes logLineIn {
    from { opacity: 0; transform: translateX(-8px); }
    to   { opacity: 1; transform: translateX(0); }
}

.splash-progress-track {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    overflow: hidden;
}
.splash-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #6abdbc, #d7de4f);
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(106,189,188,0.6);
    transition: width 0.1s linear;
}
.splash-pct {
    font-family: var(--font-display);
    font-size: 0.7rem;
    color: rgba(106,189,188,0.7);
    letter-spacing: 0.1em;
}


/* ─────────────────────────────────────────────────────────────────
   CUSTOM CURSOR
   ───────────────────────────────────────────────────────────────── */
body.custom-cursor-active,
body.custom-cursor-active * {
    cursor: none !important;
}

#cursor-dot {
    position: fixed;
    top: 0; left: 0;
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #6abdbc;
    box-shadow: 0 0 8px #6abdbc, 0 0 16px rgba(106,189,188,0.5);
    pointer-events: none;
    z-index: 99998;
    transform: translate(-50%, -50%);
    will-change: transform;
}

#cursor-ring {
    position: fixed;
    top: 0; left: 0;
    width: 30px; height: 30px;
    border-radius: 50%;
    border: 1.5px solid rgba(106,189,188,0.6);
    pointer-events: none;
    z-index: 99997;
    transform: translate(-50%, -50%);
    will-change: transform;
    transition: width 0.15s ease, height 0.15s ease, border-color 0.15s ease;
}
#cursor-ring.cursor-hover {
    width: 44px; height: 44px;
    border-color: #d7de4f;
    background: rgba(215,222,79,0.06);
}
#cursor-ring.cursor-click {
    width: 50px; height: 50px;
    opacity: 0.5;
    transition: width 0.08s ease, height 0.08s ease, opacity 0.08s ease;
}

#cursor-canvas {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 99996;
}

/* Hide on touch devices */
@media (hover: none) {
    #cursor-dot, #cursor-ring, #cursor-canvas { display: none !important; }
}


/* ─────────────────────────────────────────────────────────────────
   TOAST NOTIFICATIONS
   ───────────────────────────────────────────────────────────────── */
#toast-container {
    position: fixed;
    top: 5.2rem;
    right: 1rem;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: min(340px, calc(100vw - 2rem));
    pointer-events: none;
}

.toast {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.75rem;
    border-radius: var(--r-md);
    background: rgba(2,12,21,0.94);
    border: 1px solid currentColor;
    box-shadow: 0 4px 18px rgba(0,0,0,0.45), 0 0 12px rgba(106,189,188,0.06);
    backdrop-filter: blur(16px);
    pointer-events: all;
    position: relative;
    overflow: hidden;
    animation: toastSlideIn 0.38s cubic-bezier(0.22,1,0.36,1) both;
}
.toast.toast-dismiss {
    animation: toastSlideOut 0.3s ease-in forwards;
}

@keyframes toastSlideIn {
    from { transform: translateX(110%); opacity: 0; }
    to   { transform: translateX(0);    opacity: 1; }
}
@keyframes toastSlideOut {
    to { transform: translateX(120%); opacity: 0; }
}

.toast-error   { color: #da4357; border-color: rgba(218,67,87,0.35); }
.toast-warning { color: #d7de4f; border-color: rgba(215,222,79,0.35); }
.toast-success { color: #6abdbc; border-color: rgba(106,189,188,0.35); }
.toast-info    { color: rgba(255,255,255,0.7); border-color: rgba(255,255,255,0.15); }

.toast-icon {
    font-size: 0.85rem;
    line-height: 1.4;
    flex-shrink: 0;
}
.toast-msg {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.63rem;
    line-height: 1.4;
    color: rgba(255,255,255,0.82);
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.toast-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.4);
    cursor: pointer;
    padding: 0;
    font-size: 0.75rem;
    line-height: 1;
    transition: color 0.2s;
    flex-shrink: 0;
}
.toast-close:hover { color: rgba(255,255,255,0.8); }

.toast-timer-bar {
    position: absolute;
    bottom: 0; left: 0;
    height: 2px;
    background: currentColor;
    opacity: 0.5;
    transform-origin: left;
    animation: toastTimer linear forwards;
}


/* ─────────────────────────────────────────────────────────────────
   HUD METRICS PANEL
   ───────────────────────────────────────────────────────────────── */
#hud-panel {
    position: fixed;
    bottom: 1.5rem;
    left: 1.5rem;
    z-index: 8000;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.hud-toggle {
    width: 36px; height: 36px;
    border-radius: 50%;
    background: rgba(2,12,21,0.88);
    border: 1px solid rgba(106,189,188,0.35);
    color: #6abdbc;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s, box-shadow 0.2s;
    margin-bottom: 0.4rem;
    align-self: flex-start;
}
.hud-toggle:hover {
    border-color: #6abdbc;
    box-shadow: 0 0 10px rgba(106,189,188,0.4);
}

.hud-body {
    background: rgba(2,12,21,0.88);
    border: 1px solid rgba(106,189,188,0.2);
    border-radius: var(--r-md);
    padding: 0.85rem 1rem;
    min-width: 200px;
    backdrop-filter: blur(16px);
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
    transition: opacity 0.25s, transform 0.25s;
}
.hud-body.hud-collapsed {
    opacity: 0;
    transform: translateY(8px);
    pointer-events: none;
}

.hud-title {
    font-family: var(--font-display);
    font-size: 0.58rem;
    letter-spacing: 0.14em;
    color: rgba(106,189,188,0.7);
    margin-bottom: 0.7rem;
    border-bottom: 1px solid rgba(106,189,188,0.12);
    padding-bottom: 0.4rem;
}

.hud-metric {
    margin-bottom: 0.55rem;
}
.hud-metric-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3px;
}
.hud-metric-name {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.62rem;
    color: rgba(255,255,255,0.55);
    letter-spacing: 0.05em;
}
.hud-metric-val {
    font-family: var(--font-display);
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}
.hud-metric-bar-track {
    width: 100%;
    height: 3px;
    background: rgba(255,255,255,0.06);
    border-radius: 3px;
    overflow: hidden;
}
.hud-metric-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.8s cubic-bezier(0.4,0,0.2,1), background-color 0.5s;
}
/* Color states */
.hud-metric-bar-fill.normal   { background: #6abdbc; }
.hud-metric-bar-fill.degraded { background: #d7de4f; }
.hud-metric-bar-fill.critical { background: #da4357; animation: hudCriticalFlash 0.6s ease-in-out infinite; }
@keyframes hudCriticalFlash { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

.hud-metric-val.normal   { color: #6abdbc; }
.hud-metric-val.degraded { color: #d7de4f; }
.hud-metric-val.critical { color: #da4357; }

.hud-uptime-row {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    padding-top: 0.4rem;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.hud-uptime-label {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.6rem;
    color: rgba(255,255,255,0.4);
}
.hud-uptime-val {
    font-family: var(--font-display);
    font-size: 0.62rem;
    color: rgba(106,189,188,0.7);
}

/* ─────────────────────────────────────────────────────────────────
   AUDIO TOGGLE BUTTON
   ───────────────────────────────────────────────────────────────── */
#audio-toggle {
    position: fixed;
    bottom: 5.5rem;
    right: 1.5rem;
    width: 44px; height: 44px;
    border-radius: 50%;
    background: rgba(2,12,21,0.88);
    border: 1px solid rgba(106,189,188,0.3);
    color: rgba(255,255,255,0.6);
    font-size: 1.1rem;
    cursor: pointer;
    z-index: 8000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
    backdrop-filter: blur(10px);
}
#audio-toggle:hover {
    border-color: #6abdbc;
    box-shadow: 0 0 14px rgba(106,189,188,0.35);
    transform: scale(1.08);
}
#audio-toggle.audio-active {
    border-color: #d7de4f;
    box-shadow: 0 0 12px rgba(215,222,79,0.4);
    animation: audioGlow 2s ease-in-out infinite;
}
@keyframes audioGlow {
    0%,100% { box-shadow: 0 0 10px rgba(215,222,79,0.3); }
    50%      { box-shadow: 0 0 22px rgba(215,222,79,0.6); }
}





/* ─────────────────────────────────────────────────────────────────
   NEURAL NETWORK CANVAS
   ───────────────────────────────────────────────────────────────── */
#neural-canvas {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    pointer-events: none;
}


/* ─────────────────────────────────────────────────────────────────
   LIVE TERMINAL
   ───────────────────────────────────────────────────────────────── */
.terminal-section {
    padding: 3rem 0 4rem;
}
.terminal-inner {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto 1fr;
    gap: 1.5rem 2rem;
    align-items: start;
}
.section-label {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-family: var(--font-display);
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    color: rgba(106,189,188,0.6);
    font-weight: 600;
    white-space: nowrap;
}
.section-label-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(106,189,188,0.25), transparent);
}

.terminal-window {
    background: rgba(0,0,0,0.72);
    border: 1px solid rgba(106,189,188,0.22);
    border-radius: var(--r-md);
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.5), 0 0 0 1px rgba(106,189,188,0.06) inset;
    position: relative;
}
/* Scanline effect */
.terminal-window::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0,0,0,0.08) 2px,
        rgba(0,0,0,0.08) 4px
    );
    pointer-events: none;
    z-index: 2;
}

.terminal-titlebar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: rgba(255,255,255,0.04);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.terminal-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}
.td-red    { background: #da4357; }
.td-yellow { background: #d7de4f; }
.td-green  { background: #6abdbc; }
.terminal-title-text {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.65rem;
    color: rgba(255,255,255,0.4);
    margin-left: 0.5rem;
}

.terminal-body {
    padding: 1rem;
    height: 280px;
    overflow-y: auto;
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.68rem;
    line-height: 1.7;
    color: rgba(255,255,255,0.72);
    scrollbar-width: thin;
    scrollbar-color: rgba(106,189,188,0.3) transparent;
}
.terminal-body::-webkit-scrollbar { width: 4px; }
.terminal-body::-webkit-scrollbar-thumb { background: rgba(106,189,188,0.3); border-radius: 4px; }

.term-line { display: block; animation: termLineIn 0.12s ease-out both; }
.term-line.ok   { color: #6abdbc; }
.term-line.err  { color: #da4357; }
.term-line.warn { color: #d7de4f; }
.term-line.cmd  { color: #ffffff; }
.term-line.dim  { color: rgba(255,255,255,0.4); }
.term-cursor {
    display: inline-block;
    width: 7px; height: 0.9em;
    background: #6abdbc;
    vertical-align: text-bottom;
    animation: termCursorBlink 1s step-end infinite;
}
@keyframes termLineIn {
    from { opacity: 0; transform: translateX(-4px); }
    to   { opacity: 1; transform: none; }
}
@keyframes termCursorBlink {
    0%,100% { opacity: 1; }
    50%      { opacity: 0; }
}


/* ─────────────────────────────────────────────────────────────────
   RADAR WIDGET
   ───────────────────────────────────────────────────────────────── */
.radar-widget {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    padding: 1rem;
    background: rgba(0,0,0,0.55);
    border: 1px solid rgba(106,189,188,0.2);
    border-radius: var(--r-md);
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
    backdrop-filter: blur(10px);
}
.radar-title {
    font-family: var(--font-display);
    font-size: 0.58rem;
    letter-spacing: 0.15em;
    color: rgba(106,189,188,0.65);
}
#radar-canvas {
    border-radius: 50%;
    display: block;
}
.radar-scan-label {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.55rem;
    color: rgba(106,189,188,0.45);
    letter-spacing: 0.08em;
    animation: radarLabelBlink 2s ease-in-out infinite;
}
@keyframes radarLabelBlink {
    0%,100% { opacity: 0.45; }
    50%      { opacity: 0.9; }
}

/* Terminal section responsive */
@media (max-width: 700px) {
    .terminal-inner {
        grid-template-columns: 1fr;
    }
    .radar-widget { display: none; }
}


/* ─────────────────────────────────────────────────────────────────
   TILT CARD (3D hover effect)
   ───────────────────────────────────────────────────────────────── */
.tilt-card {
    transform-style: preserve-3d;
    transition: transform 0.12s ease, box-shadow 0.25s ease;
    will-change: transform;
    position: relative;
    overflow: hidden;
}
.tilt-gloss {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(circle at 50% 50%, rgba(255,255,255,0.12), transparent 60%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s ease;
    z-index: 5;
}
.tilt-card:hover .tilt-gloss { opacity: 1; }


/* glitch-title: v1 style preserved in style.css — no override needed */


/* ─────────────────────────────────────────────────────────────────
   DAY / NIGHT THEME (applied via JS class on body)
   ───────────────────────────────────────────────────────────────── */
body.theme-day {
    --color-primary: hsl(178, 44%, 50%);     /* slightly warmer teal */
    --color-accent:  hsl(57,  70%, 65%);     /* softer lime */
}
body.theme-night {
    --color-primary: hsl(193, 70%, 50%);     /* cooler blue-teal */
    --color-accent:  hsl(55,  95%, 65%);     /* bright lime */
}


/* ─────────────────────────────────────────────────────────────────
   INFO CARDS — tilt-card class applied via JS
   ───────────────────────────────────────────────────────────────── */
/* Add perspective to info-grid for tilt to work */
.info-grid { perspective: 900px; }


/* ─────────────────────────────────────────────────────────────────
   HERO TERMINAL — inline terminal in hero section
   ───────────────────────────────────────────────────────────────── */
.hero-terminal-wrap {
    width: 100%;
    max-width: 900px;
    margin: 0.5rem auto 0;
}

.hero-terminal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    padding: 0 0.25rem;
}

.hero-terminal-label {
    font-family: var(--font-display);
    font-size: 0.65rem;
    letter-spacing: 0.18em;
    color: rgba(106,189,188,0.65);
    text-transform: uppercase;
}

.hero-terminal-status {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.14em;
    color: rgba(106,189,188,0.55);
}

.hero-terminal-led {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #6abdbc;
    box-shadow: 0 0 6px #6abdbc;
    animation: ledBlink 1s ease-in-out infinite;
}

.hero-terminal-row {
    display: flex;
    gap: 1rem;
    align-items: stretch;
    min-height: 220px;
}

.hero-terminal-row .terminal-window {
    flex: 1;
    min-width: 0;
    height: 220px;
}

.hero-terminal-row .terminal-body {
    height: calc(220px - 36px); /* minus titlebar */
}

.hero-terminal-row .radar-widget {
    flex-shrink: 0;
    width: 160px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

@media (max-width: 640px) {
    .hero-terminal-row {
        flex-direction: column;
    }
    .hero-terminal-row .radar-widget {
        width: 100%;
        flex-direction: row;
        justify-content: center;
        gap: 1rem;
        padding: 0.5rem;
    }
    .hero-terminal-row .terminal-window,
    .hero-terminal-row .terminal-body {
        height: 180px;
    }
}


/* ─────────────────────────────────────────────────────────────────
   GAME SELECTOR & HACKING GAME V3
   ───────────────────────────────────────────────────────────────── */
.terminal-cli-line {
    display: none;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(106,189,188,0.06);
    border-top: 1px dashed rgba(106,189,188,0.18);
    position: relative;
    z-index: 10;
}
.terminal-cli-prompt {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: var(--uc-teal, #6abdbc);
    font-weight: bold;
    user-select: none;
}
.terminal-input {
    background: transparent !important;
    border: none !important;
    color: #ffffff !important;
    font-family: 'JetBrains Mono', monospace !important;
    font-size: 0.7rem !important;
    outline: none !important;
    flex: 1;
    caret-color: var(--uc-teal, #6abdbc);
}

.game-selector-screen {
    padding: var(--sp-xl) var(--sp-md);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.selector-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
    width: 100%;
    max-width: 600px;
    margin-top: 0.5rem;
}
.selector-card {
    background: rgba(10,30,46,0.65);
    border: 1px solid rgba(106,189,188,0.2);
    border-radius: var(--r-md, 8px);
    padding: 1.5rem 1rem;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.22,1,0.36,1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    outline: none;
}
.selector-card:hover {
    background: rgba(106,189,188,0.12);
    border-color: var(--uc-teal, #6abdbc);
    box-shadow: 0 0 16px rgba(106,189,188,0.3);
    transform: translateY(-4px);
}
.sel-icon {
    font-size: 2.2rem;
}
.sel-name {
    font-family: var(--font-display, "Orbitron", sans-serif);
    font-size: 0.78rem;
    font-weight: bold;
    color: #ffffff;
    letter-spacing: 0.1em;
}
.sel-desc {
    font-family: var(--font-ui, "Inter", sans-serif);
    font-size: 0.62rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.45;
}

/* Hacking Workspace styles */
.hacking-info-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 1.5rem;
    border-bottom: 1px solid rgba(106,189,188,0.15);
    background: rgba(4,12,22,0.45);
}
.hack-info-block {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.hack-info-label, .hack-timer-label, .hack-target-label {
    font-family: var(--font-display, "Orbitron", sans-serif);
    font-size: 0.52rem;
    letter-spacing: 0.1em;
    color: rgba(106,189,188,0.55);
    margin-bottom: 2px;
}
.hack-info-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: bold;
    color: var(--uc-lime, #d7de4f);
    text-shadow: 0 0 8px rgba(215,222,79,0.3);
}
.hack-timer-block {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    width: 140px;
}
.hack-timer-track {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.06);
    border-radius: 3px;
    overflow: hidden;
    border: 1px solid rgba(106,189,188,0.15);
}
.hack-timer-fill {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #d7de4f, #da4357);
}

.hacking-target-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 1rem;
    background: rgba(10,30,46,0.35);
    border-bottom: 1px dashed rgba(106,189,188,0.15);
}
.hack-target-seq {
    display: flex;
    gap: 0.5rem;
    margin-top: 5px;
}
.hack-byte {
    display: inline-block;
    padding: 3px 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    font-weight: bold;
    color: #ffffff;
    transition: all 0.25s ease;
}
.hack-byte.active {
    background: rgba(215,222,79,0.12);
    border-color: #d7de4f;
    color: #d7de4f;
    box-shadow: 0 0 10px rgba(215,222,79,0.3);
}
.hack-byte.completed {
    background: rgba(106,189,188,0.12);
    border-color: #6abdbc;
    color: #6abdbc;
    box-shadow: 0 0 10px rgba(106,189,188,0.3);
}

.hacking-grid-wrap {
    position: relative;
    padding: 1rem;
    background: rgba(3,8,15,0.6);
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hacking-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    justify-items: center;
    max-width: 280px;
    width: 100%;
    margin: 0.2rem auto;
}
.hack-grid-btn {
    width: 44px;
    height: 44px;
    background: rgba(10,30,46,0.7);
    border: 1px solid rgba(106,189,188,0.25);
    border-radius: 6px;
    color: rgba(255,255,255,0.85);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.18s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    outline: none;
}
.hack-grid-btn:hover {
    background: rgba(106,189,188,0.15);
    border-color: #6abdbc;
    box-shadow: 0 0 10px rgba(106,189,188,0.3);
    color: #ffffff;
}
.hack-grid-btn.success-flash {
    background: rgba(106,189,188,0.85) !important;
    border-color: #ffffff !important;
    color: #ffffff !important;
    box-shadow: 0 0 20px rgba(106,189,188,0.8);
}
.hack-grid-btn.error-flash {
    background: rgba(218,67,87,0.85) !important;
    border-color: #ffffff !important;
    color: #ffffff !important;
    box-shadow: 0 0 20px rgba(218,67,87,0.8);
}
.back-selector-btn {
    background: none;
    border: 1px solid rgba(106,189,188,0.35);
    color: #6abdbc;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 0.62rem;
    font-family: 'JetBrains Mono', monospace;
    cursor: pointer;
    transition: all 0.2s;
}
.back-selector-btn:hover {
    background: rgba(106,189,188,0.1);
    border-color: #6abdbc;
    color: #ffffff;
}

@media (max-width: 600px) {
    .selector-grid {
        grid-template-columns: 1fr;
        gap: 0.8rem;
    }

    .selector-card {
        padding: 1rem 0.85rem;
    }

    .hacking-info-bar {
        padding: 0.5rem 0.8rem;
    }

    .hack-timer-block {
        width: 110px;
    }

    .hacking-grid {
        max-width: 240px;
        gap: 0.4rem;
    }

    .hack-grid-btn {
        width: 40px;
        height: 40px;
        font-size: 0.72rem;
    }

    .hacking-grid-wrap {
        min-height: 250px;
        padding: 0.75rem;
    }
}

@media (max-width: 380px) {
    .hacking-grid {
        max-width: 210px;
        gap: 0.3rem;
    }

    .hack-grid-btn {
        width: 34px;
        height: 34px;
        font-size: 0.64rem;
    }

    .hacking-grid-wrap {
        min-height: 220px;
    }
}
