/* =================================================================
   RAXE — Advisory Report Page Styles
   /labs/advisories/RAXE-2026-NNN
   Consumes tokens.css directly. No scoped variables.
   ================================================================= */


/* =================================================================
   PAGE SCOPE
   ================================================================= */
.advisory-report-page {
    background: var(--surface-base);
    color: var(--text-primary);
    font-family: var(--font-body);
}


/* =================================================================
   ADVISORY SUB-NAV (sticky bar below main nav)
   ================================================================= */
.adv-nav {
    position: sticky;
    top: var(--nav-height);
    z-index: calc(var(--z-nav) - 1);
    background: var(--surface-nav);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-default);
    height: var(--adv-nav-height);
}

.adv-nav .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.adv-nav-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: var(--fs-body-sm);
    font-weight: var(--weight-medium);
    transition: color var(--duration-fast) var(--ease-default);
}

.adv-nav-back:hover {
    color: var(--text-brand);
}

.adv-nav-back:focus-visible {
    outline: 2px solid var(--border-focus);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

.adv-nav-back svg { flex-shrink: 0; }

.adv-nav-id {
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    color: var(--text-muted);
    letter-spacing: var(--tracking-wide);
}


/* =================================================================
   TLP BAND
   ================================================================= */
.adv-tlp-band {
    height: 3px;
    width: 100%;
    background: var(--tlp-white-bar);
}

.adv-tlp-green { background: var(--tlp-green-bar); }
.adv-tlp-amber { background: var(--tlp-amber-bar); }
.adv-tlp-red   { background: var(--tlp-red-bar); }
.adv-tlp-white { background: var(--tlp-white-bar); }


/* =================================================================
   HEADER
   ================================================================= */
.adv-header {
    padding: var(--space-12) 0 var(--space-10);
    background: var(--surface-base);
    border-bottom: 1px solid var(--border-default);
}

.adv-header-badges {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    flex-wrap: wrap;
    margin-bottom: var(--space-4);
}

.adv-title {
    font-family: var(--font-head);
    font-size: var(--fs-h2);
    font-weight: var(--weight-extrabold);
    line-height: var(--leading-snug);
    color: var(--text-primary);
    margin: 0 0 var(--space-5) 0;
    max-width: 800px;
}

.adv-header-meta {
    display: flex;
    align-items: center;
    gap: var(--space-5);
    flex-wrap: wrap;
}

.adv-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: var(--fs-body-sm);
    color: var(--text-muted);
}

.adv-meta-item svg {
    color: var(--text-dim);
    flex-shrink: 0;
}

.adv-meta-atlas {
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    font-weight: var(--weight-semibold);
    letter-spacing: var(--tracking-wide);
    color: var(--text-brand);
}

.adv-header-cves {
    display: flex;
    gap: var(--space-2);
    flex-wrap: wrap;
    margin-top: var(--space-4);
}

.adv-cve-pill {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    font-weight: var(--weight-semibold);
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    background: var(--sev-critical-bg);
    color: var(--sev-critical-text);
    text-decoration: none;
    border: 1px solid var(--sev-critical-border);
    transition: all var(--duration-fast) var(--ease-default);
    letter-spacing: 0.02em;
}

.adv-cve-pill:hover {
    background: rgba(248, 113, 113, 0.22);
    border-color: rgba(248, 113, 113, 0.4);
}


/* =================================================================
   BADGES (advisory-specific — extend base .badge pattern)
   ================================================================= */
.adv-badge {
    display: inline-flex;
    align-items: center;
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    font-weight: var(--weight-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    white-space: nowrap;
}

.adv-badge-id {
    background: rgba(56, 189, 248, 0.12);
    color: var(--text-brand);
    border-color: rgba(56, 189, 248, 0.22);
}

.adv-badge-severity { color: #ffffff; }

.adv-severity-critical { background: var(--sev-critical-text); }
.adv-severity-high     { background: var(--sev-high-text); }
.adv-severity-medium   { background: var(--sev-medium-text); color: var(--surface-base); }
.adv-severity-low      { background: var(--sev-low-text); color: var(--surface-base); }

.adv-badge-cvss {
    background: var(--surface-overlay);
    color: var(--text-primary);
    border-color: var(--border-default);
}

.adv-badge-cvss-ver {
    color: var(--text-dim);
    font-weight: var(--weight-medium);
}

.adv-badge-stream {
    background: rgba(56, 189, 248, 0.10);
    color: var(--text-brand);
    font-weight: var(--weight-semibold);
}


/* =================================================================
   LAYOUT — Sidebar + Content
   ================================================================= */
.adv-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: var(--space-12);
    padding-top: var(--space-12);
    padding-bottom: var(--space-16);
    align-items: start;
}

.adv-sidebar {
    position: sticky;
    top: calc(var(--nav-height) + var(--adv-nav-height) + var(--space-6));
    max-height: calc(100vh - var(--nav-height) - var(--adv-nav-height) - var(--space-12));
    overflow-y: auto;
}


/* =================================================================
   SIDEBAR TOC
   ================================================================= */
.adv-toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.adv-toc-item { margin-bottom: 2px; }

.adv-toc-link {
    display: block;
    font-size: var(--fs-caption);
    color: var(--text-muted);
    text-decoration: none;
    padding: 6px var(--space-3);
    border-left: 2px solid transparent;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    transition: all var(--duration-fast) var(--ease-default);
    line-height: 1.4;
}

.adv-toc-link:hover {
    color: var(--text-primary);
    background: var(--surface-overlay);
    border-left-color: var(--border-strong);
}

.adv-toc-link.active {
    color: var(--text-primary);
    border-left-color: var(--text-brand);
    background: rgba(56, 189, 248, 0.06);
    font-weight: var(--weight-semibold);
}

.adv-toc-sub .adv-toc-link {
    padding-left: var(--space-6);
    font-size: var(--fs-label);
}


/* =================================================================
   CONTENT — Article body
   ================================================================= */
.adv-content {
    min-width: 0;
    font-size: var(--fs-body);
    line-height: var(--leading-relaxed);
    color: var(--text-body);
}

/* Sections */
.adv-section {
    padding-bottom: var(--space-10);
    margin-bottom: var(--space-10);
    border-bottom: 1px solid var(--border-subtle);
}

.adv-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

/* Headings */
.adv-content h2 {
    font-family: var(--font-head);
    font-size: var(--fs-h3);
    font-weight: var(--weight-bold);
    color: var(--text-primary);
    margin: 0 0 var(--space-5) 0;
    padding-top: var(--space-2);
    line-height: var(--leading-snug);
    border-bottom: 2px solid var(--border-strong);
    padding-bottom: var(--space-3);
}

.adv-content h3 {
    font-family: var(--font-head);
    font-size: var(--fs-h4);
    font-weight: var(--weight-semibold);
    color: var(--text-primary);
    margin: var(--space-8) 0 var(--space-3) 0;
    line-height: var(--leading-snug);
}

.adv-content h4 {
    font-size: var(--fs-body);
    font-weight: var(--weight-bold);
    color: var(--text-primary);
    margin: var(--space-6) 0 var(--space-2) 0;
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
}

/* Paragraphs */
.adv-content p {
    margin: 0 0 var(--space-4) 0;
    line-height: var(--leading-relaxed);
}

.adv-content strong {
    color: var(--text-primary);
    font-weight: var(--weight-semibold);
}

.adv-content em {
    color: var(--text-body);
}

/* Links */
.adv-content a {
    color: var(--text-brand);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color var(--duration-fast) var(--ease-default);
}

.adv-content a:hover {
    color: var(--teal);
}

/* Lists */
.adv-content ul,
.adv-content ol {
    margin: 0 0 var(--space-4) 0;
    padding-left: var(--space-6);
}

.adv-content li {
    margin-bottom: 6px;
    line-height: 1.6;
}

.adv-content li strong {
    color: var(--text-primary);
}

/* Blockquotes */
.adv-content blockquote {
    margin: var(--space-4) 0;
    padding: var(--space-3) var(--space-5);
    border-left: 3px solid var(--text-brand);
    background: var(--surface-overlay);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    color: var(--text-primary);
    font-size: var(--fs-body);
    line-height: 1.65;
}

.adv-content blockquote p { margin-bottom: var(--space-2); }
.adv-content blockquote p:last-child { margin-bottom: 0; }

/* Horizontal rules */
.adv-content hr {
    border: none;
    height: 1px;
    background: var(--border-default);
    margin: var(--space-8) 0;
}


/* =================================================================
   REFERENCES — Clean card-style rows
   Target: ol inside a section whose id contains "references"
   ================================================================= */
[id*="references"] ol {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
    counter-reset: ref;
}

[id*="references"] ol > li {
    counter-increment: ref;
    display: flex;
    align-items: baseline;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    border-radius: var(--radius-sm);
    border-left: 2px solid transparent;
    transition: all var(--duration-fast) var(--ease-default);
    font-size: var(--fs-body-sm);
    line-height: 1.5;
    margin: 0;
}

[id*="references"] ol > li::before {
    content: counter(ref);
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    font-weight: var(--weight-bold);
    color: var(--text-dim);
    background: var(--surface-overlay);
    border-radius: var(--radius-sm);
}

[id*="references"] ol > li:hover {
    background: var(--surface-overlay);
    border-left-color: var(--text-brand);
}

[id*="references"] ol > li a {
    color: var(--text-brand);
    font-weight: var(--weight-medium);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color var(--duration-fast) var(--ease-default);
}

[id*="references"] ol > li a:hover {
    border-bottom-color: var(--text-brand);
}

/* External link indicator on reference links */
[id*="references"] ol > li a[href^="http"]::after {
    content: " ↗";
    font-size: 0.75em;
    opacity: 0.5;
}


/* =================================================================
   TABLES
   ================================================================= */
.adv-content table,
.adv-content .adv-table {
    width: 100%;
    border-collapse: collapse;
    margin: var(--space-4) 0 var(--space-6) 0;
    font-size: var(--fs-body-sm);
}

.adv-content table thead th,
.adv-content .adv-table thead th {
    background: var(--surface-overlay);
    color: var(--text-primary);
    font-weight: var(--weight-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    font-size: var(--fs-label);
    padding: 10px var(--space-4);
    text-align: left;
    border-bottom: 2px solid var(--border-strong);
    white-space: nowrap;
}

.adv-content table tbody td,
.adv-content .adv-table tbody td {
    padding: 10px var(--space-4);
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-body);
    vertical-align: top;
}

.adv-content table tbody tr:nth-child(even),
.adv-content .adv-table tbody tr:nth-child(even) {
    background: rgba(56, 189, 248, 0.02);
}

.adv-content table tbody tr:hover,
.adv-content .adv-table tbody tr:hover {
    background: rgba(56, 189, 248, 0.05);
}

/* Mono font for data-heavy columns */
.adv-content table td code,
.adv-content .adv-table td code {
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    background: var(--surface-base);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    color: var(--teal);
}


/* =================================================================
   CODE BLOCKS
   ================================================================= */
.adv-code-wrapper {
    position: relative;
    margin: var(--space-4) 0 var(--space-6) 0;
}

.adv-content pre {
    background: var(--surface-base);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: var(--space-4) var(--space-5);
    overflow-x: auto;
    font-family: var(--font-mono);
    font-size: var(--fs-body-sm);
    line-height: 1.55;
    color: var(--text-primary);
    margin: 0;
    -webkit-overflow-scrolling: touch;
}

.adv-content pre code {
    background: transparent;
    padding: 0;
    border-radius: 0;
    font-size: inherit;
    color: inherit;
}

/* Inline code — function/variable references */
.adv-content code {
    font-family: var(--font-mono);
    font-size: 0.85em;
    background: var(--surface-overlay);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    color: var(--teal);
    word-break: break-word;
}

/* Data tokens — machine-readable identifiers (CVEs, IPs, versions, scores)
   More subtle than code refs: no background, lighter weight, just mono + color shift */
.adv-content code.data {
    background: none;
    padding: 0;
    border-radius: 0;
    color: var(--text-primary);
    font-weight: var(--weight-medium);
    font-size: 0.88em;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

/* CVE/CWE/finding IDs get brand accent to stand out as linkable identifiers */
.adv-content code.data-cve,
.adv-content code.data-cwe,
.adv-content code.data-finding {
    color: var(--text-brand);
}

/* MITRE technique IDs */
.adv-content code.data-mitre {
    color: var(--text-brand);
}

/* CVSS metrics — subtle warm highlight */
.adv-content code.data-cvss-metric {
    color: var(--sev-high-text);
}

/* IP addresses — cool neutral */
.adv-content code.data-ip {
    color: var(--teal);
}


/* =================================================================
   SEVERITY/CONFIDENCE LABELS (inline badges in table cells)
   ================================================================= */
.adv-sev-label {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    font-weight: var(--weight-bold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    padding: 2px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    white-space: nowrap;
}

.adv-sev-label.sev-critical {
    background: var(--sev-critical-bg);
    color: var(--sev-critical-text);
    border-color: var(--sev-critical-border);
}

.adv-sev-label.sev-high {
    background: var(--sev-high-bg);
    color: var(--sev-high-text);
    border-color: var(--sev-high-border);
}

.adv-sev-label.sev-medium {
    background: var(--sev-medium-bg);
    color: var(--sev-medium-text);
    border-color: var(--sev-medium-border);
}

.adv-sev-label.sev-low {
    background: var(--sev-low-bg);
    color: var(--sev-low-text);
    border-color: var(--sev-low-border);
}

.adv-sev-label.sev-contested {
    background: var(--surface-overlay);
    color: var(--sev-medium-text);
    border-color: var(--border-strong);
}

/* Copy button */
.adv-code-copy {
    position: absolute;
    top: var(--space-2);
    right: var(--space-2);
    background: var(--surface-overlay);
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    padding: var(--space-1) 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--duration-fast) var(--ease-default);
    z-index: 1;
    opacity: 0;
}

.adv-code-wrapper:hover .adv-code-copy { opacity: 1; }

.adv-code-copy:hover {
    background: var(--surface-raised);
    color: var(--text-primary);
    border-color: var(--border-strong);
}

.adv-code-copy.copied {
    color: var(--teal);
    border-color: rgba(0, 229, 192, 0.3);
    opacity: 1;
}

.adv-code-copy:focus-visible {
    opacity: 1;
    outline: 2px solid var(--border-focus);
    outline-offset: 2px;
}


/* =================================================================
   ATTACK FLOW (ASCII art blocks)
   ================================================================= */
.adv-attack-flow {
    background: var(--surface-base);
    border: 1px solid var(--border-default);
    border-left: 3px solid var(--text-brand);
    border-radius: var(--radius-md);
    padding: var(--space-5) var(--space-6);
    overflow-x: auto;
    font-family: var(--font-mono);
    font-size: var(--fs-body-sm);
    line-height: 1.5;
    color: var(--teal);
    white-space: pre;
    margin: var(--space-4) 0 var(--space-6) 0;
    -webkit-overflow-scrolling: touch;
}


/* =================================================================
   DETECTION SIGNATURES — Sigma Rule Cards
   ================================================================= */
.adv-sigma-card {
    background: var(--surface-overlay);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    margin: var(--space-3) 0;
    overflow: hidden;
    transition: border-color var(--duration-fast) var(--ease-default);
}

.adv-sigma-card:hover {
    border-color: var(--border-strong);
}

.adv-sigma-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    cursor: pointer;
    user-select: none;
    transition: background var(--duration-fast) var(--ease-default);
}

.adv-sigma-header:hover {
    background: var(--surface-raised);
}

.adv-sigma-header::after {
    content: '';
    width: 8px;
    height: 8px;
    border-right: 2px solid var(--text-dim);
    border-bottom: 2px solid var(--text-dim);
    transform: rotate(45deg);
    transition: transform var(--duration-fast) var(--ease-default);
    flex-shrink: 0;
}

.adv-sigma-card.collapsed .adv-sigma-header::after {
    transform: rotate(-45deg);
}

.adv-sigma-title {
    font-family: var(--font-mono);
    font-size: var(--fs-body-sm);
    font-weight: var(--weight-semibold);
    color: var(--text-primary);
}

.adv-sigma-meta {
    display: flex;
    gap: var(--space-2);
    align-items: center;
}

.adv-sigma-type {
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    background: rgba(56, 189, 248, 0.10);
    color: var(--text-brand);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    font-weight: var(--weight-semibold);
}

.adv-sigma-body {
    border-top: 1px solid var(--border-subtle);
    transition: max-height 0.3s ease;
}

.adv-sigma-body pre {
    margin: 0;
    border: none;
    border-radius: 0;
    background: var(--surface-base);
}


/* =================================================================
   FOOTER
   ================================================================= */
.adv-footer {
    padding: var(--space-8) 0;
    border-top: 2px solid var(--border-strong);
    background: var(--surface-raised);
}

.adv-footer .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: var(--space-3);
}

.adv-footer-tlp {
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    font-weight: var(--weight-semibold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    color: var(--text-muted);
}

.adv-footer-attribution {
    font-size: var(--fs-body-sm);
    color: var(--text-body);
    font-weight: var(--weight-medium);
}

.adv-footer-classification {
    font-family: var(--font-mono);
    font-size: var(--fs-label);
    color: var(--text-dim);
    letter-spacing: var(--tracking-wide);
}


/* =================================================================
   PYGMENTS MONOKAI — Syntax highlighting
   ================================================================= */
.adv-content .codehilite pre,
.adv-content pre.codehilite {
    background: var(--surface-base);
}

/* Monokai-compatible token colors */
.adv-content .codehilite .hll { background-color: #49483e; }
.adv-content .codehilite .c   { color: #75715e; font-style: italic; }
.adv-content .codehilite .err { color: #f92672; }
.adv-content .codehilite .k   { color: #66d9ef; font-weight: bold; }
.adv-content .codehilite .l   { color: #ae81ff; }
.adv-content .codehilite .n   { color: #f8f8f2; }
.adv-content .codehilite .o   { color: #f92672; }
.adv-content .codehilite .p   { color: #f8f8f2; }
.adv-content .codehilite .ch  { color: #75715e; font-style: italic; }
.adv-content .codehilite .cm  { color: #75715e; font-style: italic; }
.adv-content .codehilite .cp  { color: #75715e; }
.adv-content .codehilite .cpf { color: #75715e; font-style: italic; }
.adv-content .codehilite .c1  { color: #75715e; font-style: italic; }
.adv-content .codehilite .cs  { color: #75715e; font-style: italic; }
.adv-content .codehilite .gd  { color: #f92672; }
.adv-content .codehilite .ge  { font-style: italic; }
.adv-content .codehilite .gi  { color: #a6e22e; }
.adv-content .codehilite .gs  { font-weight: bold; }
.adv-content .codehilite .gu  { color: #75715e; }
.adv-content .codehilite .kc  { color: #66d9ef; font-weight: bold; }
.adv-content .codehilite .kd  { color: #66d9ef; font-weight: bold; }
.adv-content .codehilite .kn  { color: #f92672; }
.adv-content .codehilite .kp  { color: #66d9ef; }
.adv-content .codehilite .kr  { color: #66d9ef; font-weight: bold; }
.adv-content .codehilite .kt  { color: #66d9ef; }
.adv-content .codehilite .ld  { color: #e6db74; }
.adv-content .codehilite .m   { color: #ae81ff; }
.adv-content .codehilite .s   { color: #e6db74; }
.adv-content .codehilite .na  { color: #a6e22e; }
.adv-content .codehilite .nb  { color: #f8f8f2; }
.adv-content .codehilite .nc  { color: #a6e22e; font-weight: bold; }
.adv-content .codehilite .no  { color: #66d9ef; }
.adv-content .codehilite .nd  { color: #a6e22e; }
.adv-content .codehilite .ni  { color: #f8f8f2; }
.adv-content .codehilite .ne  { color: #a6e22e; font-weight: bold; }
.adv-content .codehilite .nf  { color: #a6e22e; }
.adv-content .codehilite .nl  { color: #f8f8f2; }
.adv-content .codehilite .nn  { color: #f8f8f2; }
.adv-content .codehilite .nx  { color: #a6e22e; }
.adv-content .codehilite .py  { color: #f8f8f2; }
.adv-content .codehilite .nt  { color: #f92672; }
.adv-content .codehilite .nv  { color: #f8f8f2; }
.adv-content .codehilite .ow  { color: #f92672; }
.adv-content .codehilite .w   { color: #f8f8f2; }
.adv-content .codehilite .mb  { color: #ae81ff; }
.adv-content .codehilite .mf  { color: #ae81ff; }
.adv-content .codehilite .mh  { color: #ae81ff; }
.adv-content .codehilite .mi  { color: #ae81ff; }
.adv-content .codehilite .mo  { color: #ae81ff; }
.adv-content .codehilite .sa  { color: #e6db74; }
.adv-content .codehilite .sb  { color: #e6db74; }
.adv-content .codehilite .sc  { color: #e6db74; }
.adv-content .codehilite .dl  { color: #e6db74; }
.adv-content .codehilite .sd  { color: #e6db74; }
.adv-content .codehilite .s2  { color: #e6db74; }
.adv-content .codehilite .se  { color: #ae81ff; }
.adv-content .codehilite .sh  { color: #e6db74; }
.adv-content .codehilite .si  { color: #e6db74; }
.adv-content .codehilite .sx  { color: #e6db74; }
.adv-content .codehilite .sr  { color: #e6db74; }
.adv-content .codehilite .s1  { color: #e6db74; }
.adv-content .codehilite .ss  { color: #e6db74; }
.adv-content .codehilite .il  { color: #ae81ff; }


/* =================================================================
   ACCESSIBILITY
   ================================================================= */
.adv-nav-back:focus-visible,
.adv-toc-link:focus-visible,
.adv-cve-pill:focus-visible {
    outline: 2px solid var(--border-focus);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    .advisory-report-page * {
        animation: none !important;
        transition-duration: 0.01ms !important;
    }
}


/* =================================================================
   PRINT STYLES
   ================================================================= */
@media print {
    .advisory-report-page {
        background: white !important;
        color: #1a1a1a !important;
    }

    .advisory-report-page .adv-content {
        color: #334155;
    }

    .advisory-report-page .adv-content h2,
    .advisory-report-page .adv-content h3,
    .advisory-report-page .adv-content h4,
    .advisory-report-page .adv-content strong {
        color: #0f172a;
    }

    .adv-nav,
    .adv-sidebar,
    .adv-code-copy {
        display: none !important;
    }

    .adv-layout { display: block; }

    .adv-section {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .adv-tlp-band,
    .adv-badge {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}


/* =================================================================
   RESPONSIVE — Tablet (< 1024px)
   ================================================================= */
@media (max-width: 1024px) {
    .adv-layout {
        grid-template-columns: 180px 1fr;
        gap: var(--space-8);
    }
}


/* =================================================================
   RESPONSIVE — Mobile (< 768px)
   ================================================================= */
@media (max-width: 768px) {
    .adv-layout { display: block; }
    .adv-sidebar { display: none; }

    .adv-header { padding: var(--space-8) 0; }

    .adv-title { font-size: clamp(20px, 4vw, 28px); }

    .adv-header-meta { gap: var(--space-3); }

    .adv-meta-item { font-size: var(--fs-caption); }

    .adv-content h2 { font-size: var(--fs-h4); }
    .adv-content h3 { font-size: var(--fs-body); }

    /* Horizontal scroll for tables */
    .adv-content table,
    .adv-content .adv-table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .adv-content table thead,
    .adv-content table tbody,
    .adv-content table tr,
    .adv-content .adv-table thead,
    .adv-content .adv-table tbody,
    .adv-content .adv-table tr {
        display: table;
        width: 100%;
        table-layout: auto;
    }

    .adv-content pre {
        font-size: var(--fs-label);
        padding: var(--space-3) var(--space-4);
    }

    .adv-footer .container {
        flex-direction: column;
        text-align: center;
    }

    .adv-sigma-header { flex-wrap: wrap; gap: var(--space-2); }
    .adv-sigma-title { font-size: var(--fs-label); }
    .adv-code-copy { opacity: 1; }
}


/* =================================================================
   RESPONSIVE — Small mobile (< 480px)
   ================================================================= */
@media (max-width: 480px) {
    .adv-title { font-size: 1.25rem; }

    .adv-header-badges { gap: 6px; }

    .adv-badge {
        font-size: var(--fs-micro);
        padding: 2px 7px;
    }

    .adv-header-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-2);
    }

    .adv-nav .container {
        padding: 0 var(--space-4);
    }

    .adv-attack-flow {
        font-size: var(--fs-label);
        padding: var(--space-3) var(--space-4);
    }
}
