/* --- VARIABLES --- */
:root {
    --bg-dark: #0b0c10;
    --bg-panel: #14161b;
    --accent-yellow: #facc15; /* Safety Yellow */
    --accent-orange: #f97316; /* Tactical Orange */
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    --border-color: #334155;
    
    --font-head: 'Rajdhani', sans-serif;
    --font-body: 'JetBrains Mono', monospace;
    
    --glow: 0 0 10px rgba(250, 204, 21, 0.3);
}

/* --- RESET & GLOBAL --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* --- BACKGROUND FX --- */
.noise-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: url('data:image/svg+xml;utf8,%3Csvg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noiseFilter"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noiseFilter)" opacity="0.05"/%3E%3C/svg%3E');
    pointer-events: none;
    z-index: 999;
}

.grid-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: 
        linear-gradient(rgba(51, 65, 85, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(51, 65, 85, 0.1) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
    z-index: -1;
}

/* --- TYPOGRAPHY --- */
h1, h2, h3, h4, h5 {
    font-family: var(--font-head);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
}

h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.highlight { color: var(--accent-yellow); }
.outlined-text {
    -webkit-text-stroke: 1px var(--text-main);
    color: transparent;
}

/* --- HEADER --- */
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border-color);
    background: rgba(11, 12, 16, 0.9);
    backdrop-filter: blur(5px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo-area {
    font-family: var(--font-head);
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.hud-nav ul {
    display: flex;
    gap: 2rem;
}

.hud-nav a {
    font-size: 0.9rem;
    color: var(--text-muted);
    position: relative;
}

.hud-nav a:hover, .hud-nav a.active {
    color: var(--accent-yellow);
    text-shadow: var(--glow);
}

.status-indicator {
    font-size: 0.8rem;
    color: #22c55e;
    display: flex;
    align-items: center;
    gap: 5px;
}
.dot {
    width: 8px; height: 8px; background: #22c55e; border-radius: 50%;
    box-shadow: 0 0 5px #22c55e;
}
.mobile-menu-btn { display: none; cursor: pointer; }

/* --- HERO SECTION --- */
.hero-section {
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
}

.tech-badge {
    display: inline-block;
    padding: 5px 10px;
    border: 1px solid var(--accent-orange);
    color: var(--accent-orange);
    font-size: 0.8rem;
    margin-bottom: 1rem;
    background: rgba(249, 115, 22, 0.1);
}

.hero-desc {
    max-width: 600px;
    margin-bottom: 2rem;
    color: var(--text-muted);
}

/* --- ACCESS BLOCK (CTA) --- */
.access-block {
    background: rgba(20, 22, 27, 0.8);
    border: 1px solid var(--border-color);
    padding: 2rem;
    max-width: 500px;
    position: relative;
    clip-path: polygon(0 0, 100% 0, 100% 85%, 95% 100%, 0 100%);
}

.access-block::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 4px; height: 100%;
    background: var(--accent-yellow);
}

.access-warning {
    color: var(--accent-yellow);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.btn-primary {
    display: flex;
    justify-content: space-between;
    background: var(--accent-yellow);
    color: #000;
    padding: 1rem 1.5rem;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.2rem;
    clip-path: polygon(0 0, 95% 0, 100% 100%, 5% 100%);
    transition: 0.2s;
}

.btn-primary:hover {
    background: #fff;
    transform: translateX(5px);
    box-shadow: 0 0 15px var(--accent-yellow);
}

.small-info {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 10px;
    text-align: center;
}

/* --- SECTIONS COMMON --- */
.content-section, .features-section, .preview-section, .faq-section {
    padding: 4rem 0;
    border-top: 1px solid rgba(51, 65, 85, 0.3);
}

.panel-header {
    display: flex;
    align-items: center;
    margin-bottom: 2rem;
    gap: 1rem;
}

.line-decor {
    flex-grow: 1;
    height: 1px;
    background: var(--border-color);
    position: relative;
}
.line-decor::after {
    content: '';
    position: absolute;
    right: 0; top: -2px;
    width: 5px; height: 5px; background: var(--accent-yellow);
}

/* --- FEATURES GRID --- */
.grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.hud-card {
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    padding: 2rem;
    position: relative;
    transition: 0.3s;
}

.hud-card:hover {
    border-color: var(--accent-orange);
    transform: translateY(-5px);
}

.card-corner {
    position: absolute;
    top: 0; right: 0;
    width: 20px; height: 20px;
    border-top: 2px solid var(--accent-yellow);
    border-right: 2px solid var(--accent-yellow);
}

.icon-box {
    font-size: 2rem;
    color: var(--accent-yellow);
    margin-bottom: 1rem;
}

/* --- PREVIEW SECTION --- */
.split-view {
    display: flex;
    gap: 4rem;
    align-items: center;
}

.visual-side {
    flex: 1;
    height: 300px;
    background: #111;
    border: 1px dashed var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 3rem;
}

.check-list li {
    margin-bottom: 10px;
    color: var(--text-muted);
}
.check-list i { color: var(--accent-yellow); margin-right: 10px; }

.btn-secondary {
    display: inline-block;
    margin-top: 1rem;
    padding: 10px 20px;
    border: 1px solid var(--text-main);
    font-family: var(--font-head);
    font-weight: 700;
}
.btn-secondary:hover {
    background: var(--text-main);
    color: #000;
}

/* --- FAQ --- */
.faq-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}
.faq-item {
    background: rgba(255,255,255,0.03);
    padding: 1.5rem;
    border-left: 2px solid var(--accent-orange);
}
.question {
    font-weight: bold;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}
.question span { color: var(--accent-orange); }

/* --- FOOTER --- */
.tech-footer {
    background: #050505;
    padding-top: 4rem;
    border-top: 2px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-grid h4, .footer-grid h5 {
    color: var(--text-main);
    margin-bottom: 1rem;
}

.footer-grid ul li { margin-bottom: 0.5rem; }
.footer-grid a:hover { color: var(--accent-yellow); text-decoration: underline; }

.server-stats {
    margin-top: 1rem;
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: var(--accent-orange);
    border: 1px solid var(--border-color);
    padding: 10px;
    display: inline-block;
}

.disclaimer { font-size: 0.8rem; color: #555; }
.copyright-bar {
    text-align: center;
    padding: 1rem;
    border-top: 1px solid #222;
    color: #444;
    font-size: 0.8rem;
}

/* --- MOBILE --- */
@media (max-width: 768px) {
    .hud-nav { display: none; }
    .mobile-menu-btn { display: block; font-size: 1.5rem; }
    h1 { font-size: 2.5rem; }
    .split-view { flex-direction: column; }
    .faq-grid, .footer-grid { grid-template-columns: 1fr; }
    .hero-section { padding-top: 3rem; }
}
/* --- LINKS PAGE SPECIFIC STYLES --- */

/* Table of Contents (TOC) */
.toc-box {
    background: rgba(20, 22, 27, 0.6);
    border: 1px solid var(--border-color);
    padding: 2rem;
    margin-bottom: 3rem;
    position: relative;
}
.toc-box h3 { color: var(--accent-orange); margin-bottom: 1rem; }
.toc-list li { margin-bottom: 0.5rem; border-bottom: 1px solid rgba(255,255,255,0.05); padding-bottom: 5px; }
.toc-list a:hover { color: var(--accent-yellow); padding-left: 10px; }

/* HUD Tables */
.table-container {
    overflow-x: auto;
    margin-bottom: 3rem;
    border: 1px solid var(--border-color);
    background: var(--bg-panel);
}
.hud-table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--font-body);
    font-size: 0.9rem;
}
.hud-table th {
    background: rgba(255, 255, 255, 0.05);
    color: var(--accent-yellow);
    text-align: left;
    padding: 1rem;
    border-bottom: 2px solid var(--border-color);
}
.hud-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(51, 65, 85, 0.3);
    color: var(--text-muted);
}
.hud-table tr:hover td {
    background: rgba(250, 204, 21, 0.02);
    color: var(--text-main);
}

/* Status Indicators in Table */
.status-badge {
    padding: 2px 8px;
    font-size: 0.7rem;
    font-weight: bold;
    border-radius: 2px;
}
.st-online { background: rgba(34, 197, 94, 0.2); color: #22c55e; border: 1px solid #22c55e; }
.st-unstable { background: rgba(249, 115, 22, 0.2); color: #f97316; border: 1px solid #f97316; }
.st-offline { background: rgba(239, 68, 68, 0.2); color: #ef4444; border: 1px solid #ef4444; }

/* Copy Button */
.copy-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    cursor: pointer;
    padding: 5px 10px;
    transition: 0.2s;
}
.copy-btn:hover { border-color: var(--accent-yellow); color: var(--accent-yellow); }

/* PGP/Code Blocks */
.code-terminal {
    background: #000;
    border: 1px solid #333;
    padding: 1.5rem;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    color: #0f0; /* Matrix Green for contrast in code */
    overflow-x: auto;
    margin: 1.5rem 0;
    position: relative;
}
.code-terminal::before {
    content: "PGP SIGNATURE BLOCK";
    position: absolute;
    top: 0; right: 0;
    background: #333;
    color: #fff;
    padding: 2px 5px;
    font-size: 0.7rem;
}

/* Long Read Typography */
.article-body h2 { color: var(--text-main); margin-top: 3rem; margin-bottom: 1.5rem; border-left: 4px solid var(--accent-yellow); padding-left: 1rem; }
.article-body h3 { color: var(--accent-orange); margin-top: 2rem; margin-bottom: 1rem; }
.article-body p { margin-bottom: 1.5rem; text-align: justify; }
.article-body strong { color: var(--text-main); }
.warning-box {
    border: 1px solid #ef4444;
    background: rgba(239, 68, 68, 0.05);
    padding: 1.5rem;
    margin: 2rem 0;
    display: flex;
    gap: 1rem;
}
.warning-icon { font-size: 2rem; color: #ef4444; }
/* --- GUIDE PAGE SPECIFIC STYLES --- */

/* Timeline Construction */
.timeline-section {
    position: relative;
    padding: 4rem 0;
}

/* The vertical line */
.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, transparent, var(--border-color) 10%, var(--border-color) 90%, transparent);
    transform: translateX(-50%);
}

.timeline-step {
    position: relative;
    margin-bottom: 4rem;
    width: 100%;
    display: flex;
    justify-content: center;
}

/* Alternating layout for desktop */
.timeline-step:nth-child(odd) .step-content { margin-left: auto; margin-right: 50px; }
.timeline-step:nth-child(even) .step-content { margin-right: auto; margin-left: 50px; }
/* Revert to single column on mobile inside media query later */

.step-marker {
    position: absolute;
    left: 50%;
    top: 20px;
    transform: translateX(-50%);
    width: 40px; height: 40px;
    background: var(--bg-dark);
    border: 2px solid var(--accent-yellow);
    color: var(--accent-yellow);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-family: var(--font-head);
    z-index: 2;
    box-shadow: 0 0 15px rgba(0,0,0,0.8);
}

.step-content {
    width: 45%;
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    padding: 2rem;
    position: relative;
}

.step-content::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 2px;
    background: linear-gradient(90deg, var(--accent-orange), transparent);
}

.step-title {
    color: var(--accent-yellow);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Info Alerts within text */
.info-alert {
    background: rgba(56, 189, 248, 0.05);
    border-left: 3px solid #38bdf8; /* Blue for info */
    padding: 1rem;
    margin: 1rem 0;
    font-size: 0.9rem;
    color: #e0f2fe;
}

.crypto-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.1);
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-right: 5px;
}

/* Mobile Responsiveness for Timeline */
@media (max-width: 768px) {
    .timeline-line { left: 20px; }
    .step-marker { left: 20px; }
    .timeline-step { flex-direction: column; padding-left: 60px; }
    .timeline-step:nth-child(odd) .step-content, 
    .timeline-step:nth-child(even) .step-content { 
        margin: 0; width: 100%; 
    }
}
/* --- WIKI / DOCS LAYOUT --- */

.wiki-container {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 3rem;
    padding-bottom: 4rem;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

/* Sticky Sidebar */
.wiki-sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
}

.wiki-nav-title {
    color: var(--accent-orange);
    font-family: var(--font-head);
    font-weight: 700;
    margin-bottom: 1rem;
    font-size: 1.1rem;
    text-transform: uppercase;
}

.wiki-nav ul {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.wiki-nav a {
    color: var(--text-muted);
    font-size: 0.9rem;
    display: block;
    padding: 5px 0;
    border-left: 2px solid transparent;
    padding-left: 10px;
}

.wiki-nav a:hover, .wiki-nav a.current {
    color: var(--text-main);
    border-left-color: var(--accent-yellow);
    background: linear-gradient(90deg, rgba(255,255,255,0.05), transparent);
}

/* Wiki Content Area */
.wiki-content {
    background: rgba(20, 22, 27, 0.4);
    border: 1px solid transparent;
}

.wiki-block {
    margin-bottom: 4rem;
    scroll-margin-top: 120px; /* Offset for sticky header */
}

.wiki-block h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.wiki-block h3 {
    color: var(--accent-yellow);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.data-card {
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    text-align: center;
}
.data-card .big-num {
    font-size: 2.5rem;
    font-family: var(--font-head);
    color: var(--accent-yellow);
    font-weight: bold;
}
.data-card span {
    display: block;
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
}

/* Definition List for Glossary */
dl.tech-list dt {
    color: var(--text-main);
    font-weight: bold;
    margin-top: 1.5rem;
    font-family: var(--font-head);
    font-size: 1.1rem;
}
dl.tech-list dd {
    margin-left: 0;
    margin-top: 0.5rem;
    color: var(--text-muted);
    padding-left: 1rem;
    border-left: 1px solid var(--accent-orange);
}

/* Responsive Wiki */
@media (max-width: 900px) {
    .wiki-container { grid-template-columns: 1fr; }
    .wiki-sidebar { display: none; /* Hide sidebar on mobile or make it a dropdown */ }
}
/* --- SECURITY PAGE STYLES --- */

/* Threat Monitor Header */
.threat-monitor {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(20, 22, 27, 0.8);
    border: 1px solid var(--border-color);
    padding: 1rem 2rem;
    margin-bottom: 3rem;
    border-left: 5px solid var(--accent-orange);
}
.threat-level {
    font-family: var(--font-head);
    font-weight: bold;
    color: #ef4444; /* Red */
    display: flex;
    align-items: center;
    gap: 10px;
}
.pulse-circle {
    width: 12px; height: 12px;
    background: #ef4444;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7);
    animation: pulse-red 2s infinite;
}
@keyframes pulse-red {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

/* OpSec Checklist */
.security-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}
.sec-card {
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    padding: 2rem;
    transition: 0.3s;
}
.sec-card:hover { border-color: var(--accent-yellow); transform: translateY(-5px); }
.sec-icon {
    font-size: 2rem;
    color: var(--accent-yellow);
    margin-bottom: 1rem;
}
.sec-card h3 { margin-bottom: 1rem; color: var(--text-main); }
.sec-card p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

/* Warrant Canary Block */
.canary-box {
    border: 1px solid var(--text-muted);
    padding: 2rem;
    font-family: 'Courier New', monospace;
    background: #000;
    margin-top: 2rem;
    position: relative;
}
.canary-box h3 { color: #fff; margin-bottom: 1rem; border-bottom: 1px dashed #555; padding-bottom: 10px; }
.canary-text { color: #aaa; font-size: 0.8rem; white-space: pre-wrap; }

/* Accordion for PGP Guide */
.pgp-details summary {
    cursor: pointer;
    padding: 1rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border-color);
    margin-bottom: 0.5rem;
    font-family: var(--font-head);
    color: var(--accent-orange);
    list-style: none; /* Hide default triangle */
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.pgp-details summary::after { content: '+'; font-size: 1.2rem; }
.pgp-details[open] summary::after { content: '-'; }
.pgp-details[open] summary { border-bottom: none; background: rgba(255,255,255,0.1); }
.pgp-content {
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    border-top: none;
    margin-bottom: 1rem;
    background: rgba(0,0,0,0.2);
}

/* --- FAQ & SEARCH STYLES --- */

/* Search Bar */
.faq-search-box {
    max-width: 600px;
    margin: 0 auto 3rem auto;
    position: relative;
}

.search-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid var(--border-color);
    padding: 1rem 1rem 1rem 3rem;
    color: var(--text-main);
    font-family: var(--font-main);
    font-size: 1.1rem;
    transition: 0.3s;
}

.search-input:focus {
    outline: none;
    border-color: var(--accent-yellow);
    box-shadow: 0 0 15px rgba(234, 179, 8, 0.1);
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

/* FAQ Categories */
.faq-category-title {
    color: var(--accent-orange);
    font-family: var(--font-head);
    font-size: 1.2rem;
    margin: 2rem 0 1rem 0;
    border-bottom: 1px dashed var(--border-color);
    padding-bottom: 0.5rem;
    display: inline-block;
}

/* HUD Accordion Items */
.faq-item {
    margin-bottom: 1rem;
    border: 1px solid var(--border-color);
    background: var(--bg-panel);
    transition: 0.3s;
}

.faq-item:hover {
    border-color: rgba(255, 255, 255, 0.3);
}

.faq-question {
    padding: 1.2rem;
    cursor: pointer;
    position: relative;
    font-weight: 600;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question::-webkit-details-marker { display: none; }

.faq-question::after {
    content: '+';
    font-family: var(--font-head);
    font-size: 1.5rem;
    color: var(--accent-yellow);
    transition: 0.3s;
}

.faq-item[open] .faq-question::after {
    content: '-';
    transform: rotate(180deg);
}

.faq-item[open] {
    border-color: var(--accent-yellow);
    background: rgba(234, 179, 8, 0.05);
}

.faq-answer {
    padding: 0 1.2rem 1.2rem 1.2rem;
    color: var(--text-muted);
    line-height: 1.6;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 0.5rem;
    padding-top: 1rem;
}

/* No results message */
.no-results {
    text-align: center;
    padding: 2rem;
    color: var(--text-muted);
    display: none; /* Hidden by default */
}
