/* ============================================
   AgentSec Landing Page — CSS
   ============================================ */

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #111118;
    --bg-card: #181825;
    --bg-terminal: #0d0d14;
    --border: #2a2a3e;
    --border-hover: #3a3a5e;
    --text-primary: #e4e4ef;
    --text-secondary: #9898b8;
    --text-muted: #686888;
    --accent: #6c5ce7;
    --accent-hover: #7f70f5;
    --accent-glow: rgba(108, 92, 231, 0.3);
    --color-critical: #ff4757;
    --color-high: #ffa502;
    --color-medium: #eccc68;
    --color-low: #7bed9f;
    --color-agentic: #70a1ff;
    --color-owasp: #a29bfe;
    --terminal-green: #2ed573;
    --font-mono: 'JetBrains Mono', monospace;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-sans);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    width: 100%;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.2s;
}
a:hover { color: var(--accent-hover); }

code {
    font-family: var(--font-mono);
    background: rgba(108, 92, 231, 0.15);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    max-width: 100%;
    word-wrap: break-word;
}

svg {
    max-width: 100%;
    flex-shrink: 0;
}

img {
    max-width: 100%;
    height: auto;
}

pre {
    max-width: 100%;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================
   Navigation
   ============================================ */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.nav__inner {
    display: flex;
    align-items: center;
    height: 64px;
    gap: 32px;
}

.nav__logo {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}
.nav__logo:hover { color: var(--accent); }

.nav__links {
    display: flex;
    gap: 24px;
    flex: 1;
}
.nav__links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}
.nav__links a:hover { color: var(--text-primary); }

.nav__github {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
}
.nav__github:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* ============================================
   Hero
   ============================================ */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    overflow: hidden;
}

#matrixCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.04;
    pointer-events: none;
}

.hero__inner {
    position: relative;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero__badge {
    display: inline-block;
    padding: 6px 16px;
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 24px;
    font-family: var(--font-mono);
    letter-spacing: 0.5px;
}

.hero__title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -2px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent), #e84393, var(--accent));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 4s ease-in-out infinite;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.hero__subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.hero__subtitle strong {
    color: var(--text-primary);
}

.hero__actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 12px;
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.2s;
    cursor: pointer;
    text-decoration: none;
}

.btn--primary {
    background: var(--accent);
    color: white;
    border: none;
    box-shadow: 0 4px 20px var(--accent-glow);
}
.btn--primary:hover {
    background: var(--accent-hover);
    box-shadow: 0 6px 30px var(--accent-glow);
    transform: translateY(-2px);
    color: white;
}

.btn--secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border);
}
.btn--secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px);
}

.btn--outline {
    background: transparent;
    color: var(--accent);
    border: 1px solid var(--accent);
    padding: 12px 28px;
}
.btn--outline:hover {
    background: var(--accent);
    color: white;
}

/* Terminal */
.hero__terminal {
    max-width: 750px;
    margin: 0 auto;
    text-align: left;
}

.terminal-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--bg-terminal);
    border: 1px solid var(--border);
    border-bottom: none;
    border-radius: 12px 12px 0 0;
}

.terminal-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.terminal-dot--red { background: #ff5f57; }
.terminal-dot--yellow { background: #ffbd2e; }
.terminal-dot--green { background: #28c840; }

.terminal-title {
    flex: 1;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.terminal-body {
    background: var(--bg-terminal);
    border: 1px solid var(--border);
    border-radius: 0 0 12px 12px;
    padding: 20px 24px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.terminal-body pre {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

.prompt { color: var(--terminal-green); }
.flag { color: var(--accent); }

.scan-line { color: var(--text-muted); }
.owasp-note { color: var(--accent); font-size: 0.8rem; }

.finding { font-weight: 500; }
.finding--critical { color: var(--color-critical); }
.finding--high { color: var(--color-high); }
.finding--medium { color: var(--color-medium); }
.finding--low { color: var(--color-low); }

.owasp { color: var(--color-owasp); font-size: 0.8rem; }

.scan-summary {
    color: var(--text-muted);
    border-top: 1px solid var(--border);
    padding-top: 12px;
    margin-top: 12px;
    font-weight: 500;
}

/* ============================================
   Stats
   ============================================ */

.stats {
    padding: 64px 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stats__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
}

.stat-card {
    text-align: center;
    padding: 24px;
}

.stat-card__number {
    display: block;
    font-family: var(--font-mono);
    font-size: 3rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.stat-card__number--danger {
    background: linear-gradient(135deg, var(--color-critical), #ff6b81);
    -webkit-background-clip: text;
    background-clip: text;
}

.stat-card__label {
    display: block;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 8px;
}

/* ============================================
   Sections
   ============================================ */

.section {
    padding: 100px 0;
}

.section--dark {
    background: var(--bg-secondary);
}

.section__title {
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 800;
    text-align: center;
    margin-bottom: 16px;
    letter-spacing: -1px;
}

.section__subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 650px;
    margin: 0 auto 64px;
    line-height: 1.7;
}

/* Features Grid */
.features__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s;
}

.feature-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 40px rgba(108, 92, 231, 0.1);
}

.feature-card__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 12px;
    margin-bottom: 20px;
    color: var(--accent);
}

.feature-card__title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.feature-card__desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* OWASP Grid */
.owasp-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.owasp-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    transition: all 0.2s;
}
.owasp-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.owasp-card--all {
    grid-column: 1 / -1;
    text-align: center;
}

.owasp-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.owasp-id {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--accent);
}

.owasp-severity {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 100px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.owasp-severity--critical { background: rgba(255, 71, 87, 0.15); color: var(--color-critical); }
.owasp-severity--high { background: rgba(255, 165, 2, 0.15); color: var(--color-high); }
.owasp-severity--agentic { background: rgba(112, 161, 255, 0.15); color: var(--color-agentic); }

.owasp-card h4 {
    font-size: 1rem;
    margin-bottom: 8px;
}

.owasp-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.owasp-full {
    text-align: center;
}

/* Demo Bars */
.demo__grid {
    max-width: 600px;
    margin: 0 auto 32px;
}

.demo-row {
    display: grid;
    grid-template-columns: 120px 1fr 60px;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.demo-row__label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-align: right;
}

.demo-row__bar {
    height: 32px;
    background: var(--bg-card);
    border-radius: 8px;
    overflow: hidden;
}

.demo-row__fill {
    height: 100%;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 700;
    color: black;
    width: var(--pct);
    min-width: 50px;
    transition: width 1s ease-out;
}

.demo-row__count {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
}

.demo__note {
    text-align: center;
    margin-bottom: 48px;
    color: var(--text-muted);
}

.demo__findings h3 {
    text-align: center;
    margin-bottom: 24px;
    font-size: 1.2rem;
}

.findings-list {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.finding-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    transition: border-color 0.2s;
}
.finding-item:hover {
    border-color: var(--border-hover);
}

.finding-item__severity {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 65px;
    text-align: center;
}
.finding-item__severity--critical { background: rgba(255, 71, 87, 0.15); color: var(--color-critical); }
.finding-item__severity--high { background: rgba(255, 165, 2, 0.15); color: var(--color-high); }
.finding-item__severity--low { background: rgba(123, 237, 159, 0.15); color: var(--color-low); }

.finding-item__rule {
    flex: 1;
    font-weight: 500;
}

.finding-item__count {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Install */
.install__tabs {
    max-width: 700px;
    margin: 0 auto 48px;
}

.install__tabs-nav {
    display: flex;
    gap: 4px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 4px;
    margin-bottom: 16px;
}

.install__tab {
    flex: 1;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--text-secondary);
    font-family: var(--font-sans);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}
.install__tab.active {
    background: var(--accent);
    color: white;
}
.install__tab:hover:not(.active) {
    color: var(--text-primary);
}

.install__tab-content {
    display: none;
}
.install__tab-content.active {
    display: block;
}

.install__code {
    background: var(--bg-terminal);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px 24px;
}
.install__code pre {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    line-height: 2;
    color: var(--text-secondary);
}

.install__quick h3 {
    text-align: center;
    margin-bottom: 24px;
    font-size: 1.2rem;
}

.quick-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    max-width: 900px;
    margin: 0 auto;
}

.quick-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 16px 20px;
    text-align: center;
    transition: border-color 0.2s;
}
.quick-card:hover {
    border-color: var(--accent);
}
.quick-card code {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 6px;
}
.quick-card span {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* CI/CD */
.cicd__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.cicd-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 28px;
    text-align: center;
    transition: all 0.2s;
}
.cicd-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.cicd-card__icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 12px;
    color: var(--accent);
    font-size: 1.2rem;
    font-weight: 700;
}

.cicd-card h4 {
    margin-bottom: 12px;
    font-size: 1.05rem;
}

.cicd-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.7;
}

/* Footer */
.footer {
    padding: 48px 0;
    border-top: 1px solid var(--border);
}

.footer__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer__brand {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.footer__brand strong {
    font-family: var(--font-mono);
    color: var(--text-primary);
}
.footer__brand span {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer__links {
    display: flex;
    gap: 24px;
}
.footer__links a {
    color: var(--text-muted);
    font-size: 0.9rem;
}
.footer__links a:hover { color: var(--accent); }

.footer__copy {
    width: 100%;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

/* ============================================
   Mobile Navigation
   ============================================ */

.nav__toggle {
    display: none !important;
    width: 44px;
    height: 44px;
    margin-left: auto;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    background: rgba(108, 92, 231, 0.12);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    cursor: pointer;
    padding: 0;
    z-index: 200;
    transition: border-color 0.2s, background 0.2s, transform 0.2s;
}

.nav__toggle:hover {
    border-color: var(--accent);
    background: rgba(108, 92, 231, 0.2);
}

.nav__toggle:active {
    transform: scale(0.96);
}

.nav__toggle-line {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 999px;
    transform-origin: center;
    transition: transform 0.25s ease, opacity 0.2s ease, background 0.2s ease;
}

.nav__toggle.open .nav__toggle-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav__toggle.open .nav__toggle-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.nav__toggle.open .nav__toggle-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.nav__overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 150;
    opacity: 0;
    transition: opacity 0.3s;
}

.nav__overlay.open {
    display: block;
    opacity: 1;
}

.nav__mobile-menu {
    display: flex;
    position: fixed;
    top: 0;
    right: 0;
    width: min(300px, calc(100vw - 32px));
    height: 100%;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border);
    z-index: 200;
    padding: 80px 32px 32px;
    flex-direction: column;
    gap: 8px;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    will-change: transform;
}

.nav__mobile-menu.open {
    transform: translateX(0);
}

.nav__mobile-menu a {
    display: block;
    padding: 12px 16px;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 1.05rem;
    font-weight: 500;
    transition: all 0.2s;
}

.nav__mobile-menu a:hover {
    background: var(--bg-card);
    color: var(--text-primary);
}

.nav__mobile-menu .nav__github-mobile {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.2s;
}

.nav__mobile-menu .nav__github-mobile:hover {
    border-color: var(--accent);
    color: var(--accent);
}

body.menu-open {
    overflow: hidden;
}

/* ============================================
   Responsive — Mobile First
   Breakpoints: 360px, 480px, 640px, 768px, 1024px
   ============================================ */

/* Tablet: 768px and below */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden;
        width: 100%;
    }

    /* Hide desktop nav, show hamburger */
    .nav__links { display: none; }
    .nav__github { display: none; }
    .nav__toggle { display: inline-flex !important; }

    /* ── Hero ── */
    .hero {
        padding: 90px 0 50px;
        min-height: auto;
    }
    .hero__inner {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
    .hero__title {
        font-size: 1.75rem;
        letter-spacing: -1px;
    }
    .hero__subtitle {
        font-size: 0.9rem;
        margin-bottom: 28px;
    }
    .hero__badge {
        margin-bottom: 16px;
    }
    .hero__actions {
        flex-direction: column;
        align-items: stretch;
        margin-bottom: 32px;
    }
    .hero__actions .btn {
        justify-content: center;
    }

    /* Terminal — fit within viewport, internal scroll */
    .hero__terminal {
        margin: 0;
    }
    .terminal-body {
        padding: 14px 16px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .terminal-body pre {
        font-size: 0.75rem;
    }

    /* ── Stats ── */
    .stats {
        padding: 40px 0;
    }
    .stats__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .stat-card {
        padding: 16px;
    }
    .stat-card__number {
        font-size: 2rem;
    }
    .stat-card__label {
        font-size: 0.8rem;
    }

    /* ── Sections ── */
    .section {
        padding: 50px 0;
    }
    .section__title {
        font-size: 1.6rem;
    }
    .section__subtitle {
        font-size: 0.95rem;
        margin-bottom: 36px;
    }

    /* ── Feature cards ── */
    .features__grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .feature-card {
        padding: 24px;
    }

    /* ── OWASP ── */
    .owasp-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .owasp-card {
        padding: 18px;
    }

    /* ── Demo bars ── */
    .demo-row {
        grid-template-columns: 90px 1fr 45px;
        gap: 8px;
    }
    .demo-row__label {
        font-size: 0.75rem;
        text-align: left;
    }
    .demo-row__bar {
        height: 24px;
    }
    .demo-row__fill {
        font-size: 0.65rem;
        min-width: 36px;
        padding-right: 6px;
    }
    .demo-row__count {
        font-size: 0.85rem;
    }

    /* ── Finding items ── */
    .finding-item {
        flex-wrap: wrap;
        gap: 8px;
        padding: 12px 14px;
    }
    .finding-item__severity {
        min-width: 55px;
        font-size: 0.65rem;
    }
    .finding-item__rule {
        width: 100%;
        order: 2;
        font-size: 0.9rem;
    }
    .finding-item__count {
        order: 3;
        font-size: 0.8rem;
    }

    /* ── Install tabs ── */
    .install__tabs-nav {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .install__tab {
        flex: 1;
        white-space: nowrap;
        padding: 10px 12px;
        font-size: 0.85rem;
    }
    .install__code {
        padding: 14px 16px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .install__code pre {
        font-size: 0.8rem;
    }

    /* ── Quick commands ── */
    .quick-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .quick-card {
        padding: 14px 16px;
    }

    /* ── CI/CD ── */
    .cicd__grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .cicd-card {
        padding: 22px;
    }

    /* ── Buttons ── */
    .btn {
        padding: 12px 24px;
        font-size: 0.95rem;
    }

    /* ── Footer ── */
    .footer {
        padding: 32px 0;
    }
    .footer__inner {
        flex-direction: column;
        text-align: center;
    }
    .footer__links {
        flex-wrap: wrap;
        justify-content: center;
    }

    /* ── Matrix canvas (performance) ── */
    #matrixCanvas {
        display: none;
    }
}

/* Small tablet / large phone: 640px and below */
@media (max-width: 640px) {
    .container {
        padding: 0 20px;
    }

    .hero__title {
        font-size: 1.6rem;
    }
    .hero__subtitle {
        font-size: 0.88rem;
    }
}

/* Phone landscape: 480px and below */
@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero {
        padding: 80px 0 40px;
    }
    .hero__title {
        font-size: 1.5rem;
        letter-spacing: -0.5px;
    }
    .hero__badge {
        font-size: 0.7rem;
        padding: 4px 12px;
    }
    .hero__subtitle {
        font-size: 0.85rem;
        margin-bottom: 24px;
    }
    .hero__actions {
        margin-bottom: 24px;
    }
    .hero__actions .btn {
        padding: 13px 20px;
    }

    .terminal-body {
        padding: 12px 14px;
    }
    .terminal-body pre {
        font-size: 0.7rem;
        line-height: 1.6;
    }

    .section {
        padding: 40px 0;
    }
    .section__title {
        font-size: 1.4rem;
    }
    .section__subtitle {
        font-size: 0.9rem;
        margin-bottom: 28px;
    }

    .stats {
        padding: 32px 0;
    }
    .stat-card__number {
        font-size: 1.8rem;
    }
    .stat-card__label {
        font-size: 0.75rem;
    }

    .feature-card {
        padding: 20px;
    }

    .demo-row {
        grid-template-columns: 1fr;
        gap: 4px;
        margin-bottom: 14px;
    }
    .demo-row__label {
        font-size: 0.85rem;
        text-align: left;
    }
    .demo-row__bar {
        height: 22px;
    }
    .demo-row__count {
        font-size: 0.8rem;
    }

    .finding-item {
        padding: 10px 12px;
    }
    .finding-item__rule {
        font-size: 0.85rem;
    }

    .install__code pre {
        font-size: 0.75rem;
    }
    .install__tab {
        font-size: 0.8rem;
        padding: 8px 10px;
    }

    .quick-card code {
        font-size: 0.75rem;
        word-break: break-all;
    }

    .cicd-card {
        padding: 18px;
    }

    .owasp-severity {
        font-size: 0.65rem;
        padding: 2px 8px;
    }
    .owasp-id {
        font-size: 0.95rem;
    }

    .btn {
        font-size: 0.9rem;
        padding: 11px 20px;
    }

    .footer {
        padding: 28px 0;
    }
}

/* Small phone: 360px and below */
@media (max-width: 360px) {
    .container {
        padding: 0 12px;
    }

    .nav__inner {
        height: 56px;
        gap: 16px;
    }
    .nav__logo {
        font-size: 1.1rem;
    }

    .hero {
        padding: 70px 0 32px;
    }
    .hero__title {
        font-size: 1.3rem;
    }
    .hero__subtitle {
        font-size: 0.8rem;
    }
    .hero__badge {
        font-size: 0.65rem;
        padding: 3px 10px;
    }
    .hero__actions .btn {
        padding: 11px 16px;
        font-size: 0.85rem;
    }

    .terminal-body pre {
        font-size: 0.65rem;
    }

    .section__title {
        font-size: 1.25rem;
    }

    .stat-card__number {
        font-size: 1.5rem;
    }

    .finding-item__severity {
        min-width: 48px;
        font-size: 0.6rem;
        padding: 2px 6px;
    }

    .install__code pre {
        font-size: 0.7rem;
    }
}

/* ============================================
   Animations
   ============================================ */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero__badge,
.hero__title,
.hero__subtitle,
.hero__actions,
.hero__terminal {
    animation: fadeInUp 0.8s ease-out forwards;
    opacity: 0;
}

.hero__badge { animation-delay: 0.1s; }
.hero__title { animation-delay: 0.2s; }
.hero__subtitle { animation-delay: 0.3s; }
.hero__actions { animation-delay: 0.4s; }
.hero__terminal { animation-delay: 0.5s; }
