/* HPA MASTER STYLESHEET */
:root {
    --bg-color: #b8bcbf;      /* Cold blueprint gray-blue */
    --ink-color: #121521;     /* Deep inky blue-black */
    --bleed-color: rgba(18, 21, 33, 0.45);
    --scanline: rgba(0, 0, 0, 0.05);
}

body {
    background-color: var(--bg-color);
    background-image:
        linear-gradient(rgba(0,0,0,0.035) 50%, transparent 50%),
        radial-gradient(var(--ink-color) 0.5px, transparent 0.5px);
    background-size: 100% 4px, 3px 3px;
    color: var(--ink-color);
    font-family: "Courier New", Courier, monospace;
    margin: 0; padding: 0;
    line-height: 1.4;
    text-transform: uppercase;
    overflow-x: hidden;
}

/* INK BLEED — limited to text-bearing elements for performance */
h1, h2, h3, p, a, .ticker-title, footer {
    text-shadow: 0 0 2px var(--bleed-color);
}

.container {
    width: 95%; max-width: 900px;
    margin: 30px auto;
    background: rgba(184, 188, 191, 0.85);
    border: 2px solid var(--ink-color);
    padding: 40px;
    box-shadow: 0 0 25px var(--bleed-color);
    position: relative; z-index: 1;
}

header {
    text-align: center;
    border-bottom: 5px double var(--ink-color);
    margin-bottom: 30px; padding-bottom: 20px;
}

/* REDACTED (Inverted) */
.redacted {
    background: var(--ink-color);
    color: var(--ink-color);
    box-shadow: 0 0 6px var(--ink-color);
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
    padding: 0 3px;
}
.redacted:hover { background: transparent; }

/* NEWS TICKER (Offset from top) */
.ticker-wrap {
    width: 100%; overflow: hidden; background: var(--ink-color);
    color: var(--bg-color); height: 35px; display: flex; 
    align-items: center; z-index: 1000; 
    position: sticky; top: 8px; /* Offset from screen edge */
    margin-bottom: 10px;
    box-shadow: 0 5px 15px var(--bleed-color);
}
.ticker-title { 
    background: var(--bg-color); color: var(--ink-color); 
    padding: 0 20px; font-weight: bold; height: 100%;
    display: flex; align-items: center; z-index: 1001;
    box-shadow: 8px 0 15px var(--bleed-color);
}
.ticker {
    display: inline-flex;
    width: max-content;
    white-space: nowrap;
    animation: ticker-scroll 140s linear infinite;
    will-change: transform;
    transform: translate3d(0,0,0);
}
.ticker__item { 
    padding: 0 50px; font-size: 0.85rem; color: var(--bg-color);
    text-decoration: none; text-transform: none;
}
.ticker__item:hover { color: #fff; text-shadow: 0 0 8px #fff; }

@keyframes ticker-scroll { 0% { transform: translate3d(0,0,0); } 100% { transform: translate3d(-50%,0,0); } }

/* DOSSIER LINKS */
.dossier-link {
    display: block; border: 1px solid var(--ink-color);
    padding: 20px; text-decoration: none; color: var(--ink-color);
    margin-bottom: 15px; background: rgba(255,255,255,0.05);
    transition: 0.3s;
}
.dossier-link:hover { background: var(--ink-color); color: var(--bg-color); box-shadow: 0 0 20px var(--ink-color); }

footer { text-align: center; margin-top: 40px; border-top: 1px solid var(--ink-color); padding: 20px; }

/* PERFORMANCE + RESPONSIVE PATCH */
*, *::before, *::after { box-sizing: border-box; }

@media (max-width: 760px) {
    .container {
        width: calc(100% - 20px);
        margin: 18px auto;
        padding: 20px;
    }

    .ticker-wrap {
        top: 0;
        height: 34px;
    }

    .ticker-title {
        padding: 0 10px;
        flex: 0 0 auto;
    }

    .ticker__item {
        padding: 0 24px;
    }

    h1 {
        font-size: clamp(1.35rem, 7vw, 2rem);
        overflow-wrap: anywhere;
    }
}

/* Avoid expensive animation work when the tab is not being actively viewed,
   and respect OS accessibility settings. */
@media (prefers-reduced-motion: reduce) {
    .ticker { animation: none; }
    .boot-complete, .trigger-sync { animation-duration: 0.01ms !important; }
}




/* INTERACTION-SAFE DEPLOYMENT */
html, body {
    position: relative;
    min-height: 100%;
}

body {
    pointer-events: auto !important;
}

.container,
.ticker-wrap,
header,
main,
section,
footer,
a,
button,
input,
textarea,
select {
    pointer-events: auto !important;
}

.container {
    isolation: isolate;
}
