:root {
    --bg-dark: #070a13;
    --bg-surface: #0e1526;
    --bg-surface-elevated: #141f36;
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --primary: #38bdf8;
    --primary-glow: rgba(56, 189, 248, 0.18);
    --accent: #818cf8;
    --danger: #f43f5e;
    --danger-bg: rgba(244, 63, 94, 0.12);
    --danger-border: rgba(244, 63, 94, 0.4);
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.12);
    --warning-border: rgba(245, 158, 11, 0.4);
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.12);
    --success-border: rgba(16, 185, 129, 0.4);
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Inter", sans-serif;
    --font-mono: "JetBrains Mono", SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-image: 
        radial-gradient(circle at 15% 15%, rgba(56, 189, 248, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 85% 65%, rgba(129, 140, 248, 0.04) 0%, transparent 45%);
}

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1.5rem;
    width: 100%;
}

/* Header & Navbar */
.site-header {
    background: rgba(7, 10, 19, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-subtle);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
}

.nav-brand-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text-primary);
}

.brand-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #0284c7, #6366f1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.1rem;
    color: #fff;
    box-shadow: 0 0 16px rgba(56, 189, 248, 0.3);
}

.brand-text {
    font-weight: 700;
    letter-spacing: -0.02em;
    font-size: 1.1rem;
}

.brand-badge {
    font-size: 0.68rem;
    font-family: var(--font-mono);
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: var(--primary);
    text-transform: uppercase;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
    line-height: 1.2;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.75rem;
    list-style: none;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
}

.nav-link.active {
    color: var(--primary);
    font-weight: 600;
}

.live-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.85); }
}

/* Hero Section */
.hero {
    padding: 4rem 0 3rem;
    border-bottom: 1px solid var(--border-subtle);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.cve-chip {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.25rem 0.7rem;
    border-radius: 6px;
    background: rgba(244, 63, 94, 0.15);
    border: 1px solid var(--danger-border);
    color: #fda4af;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.cve-chip:hover {
    background: rgba(244, 63, 94, 0.25);
}

.cvss-badge {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.25rem 0.65rem;
    border-radius: 6px;
    background: #e11d48;
    color: #fff;
    text-transform: uppercase;
}

.hero-title {
    font-size: 2.75rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 1rem;
    background: linear-gradient(180deg, #ffffff 30%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 820px;
    margin-bottom: 2rem;
    line-height: 1.7;
}

/* Cards & Grid */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    padding: 1.25rem 1.35rem;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.card:hover {
    border-color: var(--border-strong);
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.card-header-flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.card-label {
    font-size: 0.72rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-value {
    font-size: 1.75rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: #fff;
    margin-bottom: 0.4rem;
    line-height: 1.15;
}

.card-subtext {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin-top: auto;
    word-break: break-word;
}

/* Banners */
.banner {
    padding: 1.25rem 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.banner-vuln {
    background: var(--danger-bg);
    border: 1px solid var(--danger-border);
}

.banner-mitigated {
    background: var(--warning-bg);
    border: 1px solid var(--warning-border);
}

.banner-safe {
    background: var(--success-bg);
    border: 1px solid var(--success-border);
}

.banner-content strong {
    color: #fff;
    display: block;
    margin-bottom: 0.25rem;
}

/* Sections */
.section-head {
    margin-bottom: 1.5rem;
}

.section-head h2 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.section-head p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Tables */
.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.92rem;
}

th {
    padding: 0.85rem 1rem;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    text-transform: uppercase;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-subtle);
    background: rgba(255, 255, 255, 0.02);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-secondary);
}

tr:hover td {
    background: rgba(255, 255, 255, 0.02);
    color: var(--text-primary);
}

code {
    font-family: var(--font-mono);
    font-size: 0.88rem;
    background: rgba(255, 255, 255, 0.06);
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    color: #e2e8f0;
}

pre {
    background: #04060c;
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 1.25rem;
    font-family: var(--font-mono);
    font-size: 0.88rem;
    color: #cbd5e1;
    overflow-x: auto;
    line-height: 1.6;
}

/* Buttons and Inputs */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: #070a13;
}

.btn-primary:hover {
    background: #7dd3fc;
    box-shadow: 0 0 16px var(--primary-glow);
}

.btn-outline {
    background: transparent;
    border-color: var(--border-strong);
    color: var(--text-primary);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

input[type="file"], input[type="text"], textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    background: #050811;
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    transition: border-color 0.2s;
}

input[type="file"]:focus, input[type="text"]:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
}

/* Footer & Profile */
.site-footer {
    margin-top: auto;
    border-top: 1px solid var(--border-subtle);
    background: #04060b;
    padding: 3.5rem 0 2rem;
}

.footer-profile {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 2.5rem;
}

.profile-card {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profile-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.verified-badge {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #34d399;
    font-size: 0.72rem;
    font-family: var(--font-mono);
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
    font-weight: 600;
}

.profile-bio {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.6;
}

.profile-pgp {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.03);
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    border: 1px solid var(--border-subtle);
    word-break: break-all;
}

.footer-col-title {
    font-size: 0.82rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.footer-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.footer-link:hover {
    color: var(--primary);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    flex-wrap: wrap;
    gap: 1rem;
}

@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .footer-profile { grid-template-columns: 1fr; gap: 2rem; }
}

@media (max-width: 768px) {
    .site-header {
        position: static;
    }
    .nav-wrap {
        flex-direction: column;
        align-items: stretch;
        min-height: auto;
        padding: 0.85rem 0;
        gap: 0.75rem;
    }
    .nav-brand-row {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
    }
    .nav-menu {
        width: 100%;
    }
    .nav-links {
        display: flex;
        overflow-x: auto;
        white-space: nowrap;
        gap: 0.5rem;
        padding: 0.2rem 0.2rem 0.4rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .nav-links::-webkit-scrollbar {
        display: none;
    }
    .nav-link {
        font-size: 0.82rem;
        padding: 0.4rem 0.75rem;
        background: rgba(255, 255, 255, 0.04);
        border: 1px solid var(--border-subtle);
        border-radius: 6px;
    }
    .nav-link.active {
        background: rgba(56, 189, 248, 0.15);
        border-color: rgba(56, 189, 248, 0.4);
    }
    .hero {
        padding: 2.25rem 0 1.75rem;
    }
    .hero-title {
        font-size: 1.75rem;
        line-height: 1.2;
    }
    .hero-desc {
        font-size: 0.95rem;
        line-height: 1.6;
    }
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    .hero-buttons .btn {
        width: 100%;
        justify-content: center;
        min-height: 44px;
    }
    .container {
        padding: 0 1rem;
    }
    .grid-2, .grid-3 {
        grid-template-columns: 1fr;
    }
    .card {
        padding: 1.1rem 1.15rem;
    }
    .banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        padding: 1rem;
    }
    .banner span.brand-badge {
        align-self: flex-start;
    }
    .table-wrap {
        border-radius: 8px;
        border: 1px solid var(--border-subtle);
        -webkit-overflow-scrolling: touch;
    }
    table {
        min-width: 540px;
    }
    input[type="file"], input[type="text"], textarea {
        font-size: 16px; /* Prevents auto zoom in iOS Safari */
        min-height: 44px;
    }
    .btn {
        min-height: 44px;
        padding: 0.75rem 1.25rem;
    }
    .footer-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
}

@media (max-width: 580px) {
    .grid-4 {
        grid-template-columns: 1fr;
    }
    .brand-text {
        font-size: 1rem;
    }
    .brand-icon {
        width: 32px;
        height: 32px;
    }
}
