/* ============================================
   DeepThreat Guard — Product Page
   Matches main site design system
   ============================================ */

:root {
    --bg: #06060b;
    --bg2: #0c0c14;
    --bg3: #13131f;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-border: rgba(255, 255, 255, 0.06);
    --surface-hover: rgba(255, 255, 255, 0.05);
    --text: #eeeef0;
    --text-secondary: #8b8ba0;
    --text-tertiary: #55556a;
    --accent: #ff2d55;
    --accent-light: #ff4d6d;
    --accent-dark: #cc1a40;
    --accent-glow: rgba(255, 45, 85, 0.15);
    --accent-glow-strong: rgba(255, 45, 85, 0.3);
    --gradient: linear-gradient(135deg, #ff2d55, #ff6b6b, #ff2d55);
    --green: #00ff88;
    --yellow: #ffcc00;
    --red: #ff4444;
    --radius: 12px;
    --radius-lg: 20px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
    --mono: 'JetBrains Mono', 'Fira Code', monospace;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; }
h1, h2, h3, h4 { letter-spacing: -0.035em; line-height: 1.1; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.accent { color: var(--accent); }

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes glow {
    0%, 100% { box-shadow: 0 0 20px var(--accent-glow), 0 0 60px rgba(255, 45, 85, 0.05); }
    50% { box-shadow: 0 0 30px var(--accent-glow-strong), 0 0 80px rgba(255, 45, 85, 0.1); }
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ============================================
   Navigation
   ============================================ */
.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: rgba(6, 6, 11, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid transparent;
    transition: all var(--transition);
}
.nav.scrolled {
    background: rgba(6, 6, 11, 0.92);
    border-bottom-color: var(--surface-border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.logo {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; color: var(--text);
    font-weight: 700; font-size: 1.15rem;
}
.logo-svg { flex-shrink: 0; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a {
    color: var(--text-secondary); font-size: 0.9rem; font-weight: 500;
    transition: color var(--transition);
}
.nav-links a:hover, .nav-links a.active { color: var(--text); }

/* Mobile menu */
.mobile-menu-btn {
    display: none; background: none; border: none; cursor: pointer;
    width: 28px; height: 20px; position: relative; z-index: 1001;
}
.mobile-menu-btn span {
    display: block; width: 100%; height: 2px; background: var(--text);
    position: absolute; left: 0; transition: all 0.3s ease;
}
.mobile-menu-btn span:nth-child(1) { top: 0; }
.mobile-menu-btn span:nth-child(2) { top: 9px; }
.mobile-menu-btn span:nth-child(3) { top: 18px; }
.mobile-menu-btn.open span:nth-child(1) { transform: rotate(45deg); top: 9px; }
.mobile-menu-btn.open span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.open span:nth-child(3) { transform: rotate(-45deg); top: 9px; }

@media (max-width: 768px) {
    .mobile-menu-btn { display: block; }
    .nav-links {
        display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0;
        background: rgba(6, 6, 11, 0.98); flex-direction: column;
        justify-content: center; align-items: center; gap: 24px;
    }
    .nav-links.open { display: flex; }
    .nav-links a { font-size: 1.2rem; }
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex; align-items: center; gap: 6px;
    font-family: var(--font); font-weight: 600; font-size: 0.95rem;
    padding: 12px 24px; border-radius: 10px; border: none;
    cursor: pointer; transition: all var(--transition); text-decoration: none;
}
.btn-sm { padding: 8px 16px; font-size: 0.85rem; border-radius: 8px; }
.btn-lg { padding: 16px 32px; font-size: 1.05rem; }
.btn-primary {
    background: var(--accent); color: white;
}
.btn-primary:hover { background: var(--accent-light); transform: translateY(-1px); }
.btn-glow { animation: glow 3s infinite; }
.btn-ghost {
    background: transparent; color: var(--text-secondary);
    border: 1px solid var(--surface-border);
}
.btn-ghost:hover { color: var(--text); border-color: var(--text-tertiary); }

/* ============================================
   Hero
   ============================================ */
.hero {
    padding: 160px 0 80px;
    text-align: center;
}
.hero-badge {
    display: inline-block;
    padding: 6px 16px; margin-bottom: 24px;
    background: var(--accent-glow); border: 1px solid rgba(255, 45, 85, 0.2);
    border-radius: 100px; font-size: 0.8rem; font-weight: 600;
    color: var(--accent-light); letter-spacing: 0.05em; text-transform: uppercase;
}
.hero h1 {
    font-size: clamp(2.8rem, 7vw, 4.5rem);
    font-weight: 900; margin-bottom: 16px;
}
.hero-tagline {
    font-size: clamp(1.2rem, 3vw, 1.6rem);
    color: var(--text-secondary); margin-bottom: 12px;
    font-weight: 500;
}
.hero-sub {
    max-width: 640px; margin: 0 auto 36px;
    color: var(--text-tertiary); font-size: 1.05rem; line-height: 1.7;
}
.cta-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ============================================
   Pipeline
   ============================================ */
.pipeline-section { padding: 80px 0; }
.section-title {
    text-align: center; font-size: clamp(1.6rem, 4vw, 2.2rem);
    font-weight: 800; margin-bottom: 48px;
}
.pipeline {
    display: flex; align-items: center; justify-content: center;
    gap: 8px; flex-wrap: wrap;
    padding: 40px 24px;
    background: var(--bg2); border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg);
}
.step {
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    padding: 16px 20px; border-radius: var(--radius);
    background: var(--surface); border: 1px solid var(--surface-border);
    min-width: 80px;
}
.step-icon { font-size: 1.6rem; }
.step-label { font-size: 0.85rem; font-weight: 600; color: var(--text-secondary); }
.step-guard {
    border-color: var(--accent);
    background: var(--accent-glow);
    position: relative;
}
.step-guard .step-label { color: var(--accent-light); }
.step-status { display: flex; flex-direction: column; align-items: center; gap: 4px; margin-top: 4px; }
.blocked-badge {
    background: var(--red); color: white; font-size: 0.65rem;
    padding: 2px 8px; border-radius: 4px; font-weight: 700;
    letter-spacing: 0.05em; animation: pulse 2s infinite;
}
.finding-count { font-size: 0.7rem; color: var(--red); font-family: var(--mono); }
.step-deploy-blocked { opacity: 0.3; }
.prevented { font-size: 0.7rem; color: var(--text-tertiary); font-style: italic; }
.arrow { font-size: 1.2rem; color: var(--text-tertiary); font-weight: 700; }
.arrow-blocked { color: var(--red); font-size: 1.4rem; }
.pipeline-caption {
    text-align: center; margin-top: 24px;
    color: var(--text-tertiary); font-size: 0.9rem; font-style: italic;
}

@media (max-width: 600px) {
    .pipeline { gap: 4px; padding: 24px 16px; }
    .step { padding: 10px 12px; min-width: 60px; }
    .step-icon { font-size: 1.2rem; }
    .step-label { font-size: 0.75rem; }
    .arrow { font-size: 0.9rem; }
}

/* ============================================
   GitHub PR Mockup
   ============================================ */
.gh-section { padding: 80px 0; }
.gh-card {
    max-width: 800px; margin: 0 auto;
    background: #0d1117; border: 1px solid #30363d; border-radius: 8px;
    overflow: hidden; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    font-size: 14px; color: #e6edf3;
}
.gh-header {
    padding: 16px 20px; border-bottom: 1px solid #30363d;
}
.gh-pr-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.gh-icon { color: #3fb950; font-size: 16px; }
.gh-pr-label {
    background: #238636; color: white; padding: 2px 8px;
    border-radius: 12px; font-size: 12px; font-weight: 600;
}
.gh-pr-num { color: #8b949e; }
.gh-checks { padding: 16px 20px; border-bottom: 1px solid #30363d; }
.gh-checks-header {
    display: flex; align-items: center; gap: 8px; margin-bottom: 4px;
}
.gh-x { color: #f85149; font-weight: 700; }
.gh-checks-sub { color: #8b949e; font-size: 12px; margin-bottom: 12px; }
.gh-check-list { display: flex; flex-direction: column; gap: 1px; }
.gh-check {
    display: flex; align-items: center; gap: 10px; padding: 10px 12px;
    background: rgba(255,255,255, 0.02); border-radius: 6px;
}
.gh-check.fail { border-left: 3px solid #f85149; }
.gh-check.pass { border-left: 3px solid #3fb950; }
.gh-check-icon { font-weight: 700; font-size: 14px; flex-shrink: 0; }
.gh-check.fail .gh-check-icon { color: #f85149; }
.gh-check.pass .gh-check-icon { color: #3fb950; }
.gh-check-info { flex: 1; }
.gh-check-info strong { display: block; font-size: 13px; }
.gh-check-detail { display: block; color: #8b949e; font-size: 12px; }
.gh-details-btn {
    background: #21262d; border: 1px solid #30363d; color: #e6edf3;
    padding: 4px 12px; border-radius: 6px; font-size: 12px;
    cursor: pointer; transition: background 0.2s;
}
.gh-details-btn:hover { background: #30363d; }

.gh-check-expanded {
    max-height: 0; overflow: hidden; transition: max-height 0.4s ease;
    padding: 0 12px;
}
.gh-check-expanded.expanded {
    max-height: 600px;
    padding: 12px;
}
.gh-finding {
    padding: 12px; margin-bottom: 8px;
    background: rgba(255,255,255, 0.02); border-radius: 6px;
    border-left: 3px solid #8b949e;
}
.gh-finding.critical { border-left-color: #f85149; }
.gh-finding.high { border-left-color: #d29922; }
.gh-finding .severity {
    display: inline-block; font-size: 10px; font-weight: 700;
    padding: 2px 6px; border-radius: 3px; margin-right: 8px;
    letter-spacing: 0.05em;
}
.gh-finding.critical .severity { background: rgba(248, 81, 73, 0.2); color: #f85149; }
.gh-finding.high .severity { background: rgba(210, 153, 34, 0.2); color: #d29922; }
.gh-finding .file {
    font-family: var(--mono); font-size: 12px; color: #8b949e;
}
.gh-finding p { margin-top: 6px; font-size: 13px; color: #c9d1d9; }
.gh-finding code {
    background: rgba(255,255,255, 0.06); padding: 1px 5px;
    border-radius: 3px; font-family: var(--mono); font-size: 12px;
}
.gh-suggestion {
    margin-top: 12px;
    border: 1px solid #30363d;
    border-radius: 6px;
    overflow: hidden;
    background: #0d1117;
}
.gh-suggestion-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid #30363d;
    font-size: 12px; color: #8b949e; font-weight: 600;
}
.gh-btn-commit {
    background: #238636; color: white;
    border: 1px solid rgba(240, 246, 252, 0.1);
    padding: 4px 10px; border-radius: 5px; font-size: 11px; font-weight: 600;
    cursor: pointer; transition: background 0.2s;
}
.gh-btn-commit:hover { background: #2ea043; }
.gh-diff {
    font-family: var(--mono); font-size: 11px; line-height: 1.5;
}
.diff-line { display: flex; padding: 2px 12px; }
.diff-sign { width: 16px; flex-shrink: 0; user-select: none; opacity: 0.5; }
.diff-rem { background: rgba(248, 81, 73, 0.15); color: #ff7b72; }
.diff-add { background: rgba(63, 185, 80, 0.15); color: #7ee787; }
.gh-merge-blocked {
    padding: 16px 20px; background: rgba(248, 81, 73, 0.05);
    display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap;
}
.gh-merge-blocked strong { flex: 1 1 auto; }
.gh-merge-blocked p {
    width: 100%; margin-top: 4px; font-size: 13px; color: #8b949e;
}

@media (max-width: 600px) {
    .gh-card { font-size: 12px; }
    .gh-header, .gh-checks, .gh-merge-blocked { padding: 12px 14px; }
    .gh-pr-title { font-size: 13px; }
}

/* ============================================
   Comparison Timeline
   ============================================ */
.comparison-section { padding: 80px 0; }
.comparison {
    display: grid; grid-template-columns: 1fr 1fr; gap: 24px;
}
.col {
    background: var(--bg2); border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg); overflow: hidden;
    transition: all var(--transition);
}
.col-without {
    opacity: 0.85;
}
.col-without:hover {
    opacity: 1;
}
.col-with {
    background: linear-gradient(180deg, rgba(0, 255, 136, 0.03) 0%, var(--bg2) 100%);
    border-color: rgba(0, 255, 136, 0.15);
    box-shadow: 0 0 30px rgba(0, 255, 136, 0.03);
}
.col-with:hover {
    box-shadow: 0 0 40px rgba(0, 255, 136, 0.08);
    transform: translateY(-2px);
}
.col-header {
    padding: 24px; text-align: center;
    border-bottom: 1px solid var(--surface-border);
}
.col-with .col-header {
    background: rgba(0, 255, 136, 0.05);
    border-bottom-color: rgba(0, 255, 136, 0.2);
}
.col-header h3 { font-size: 1.2rem; font-weight: 700; margin-bottom: 8px; }
.outcome {
    display: inline-block; padding: 4px 12px; border-radius: 6px;
    font-size: 0.8rem; font-weight: 700; letter-spacing: 0.02em;
}
.outcome.bad { background: rgba(255, 68, 68, 0.15); color: var(--red); }
.outcome.good { background: rgba(0, 255, 136, 0.15); color: var(--green); box-shadow: 0 0 10px rgba(0, 255, 136, 0.2); }
.col-without .col-header { border-bottom-color: rgba(255, 68, 68, 0.2); }

.timeline { padding: 24px; }
.tl-item {
    padding: 12px 10px 12px 20px;
    border-left: 2px solid var(--surface-border);
    position: relative;
    border-radius: 4px;
    transition: all var(--transition);
}
.tl-item:hover {
    background: rgba(255, 255, 255, 0.02);
    transform: translateX(4px);
}
.tl-item::before {
    content: ''; position: absolute; left: -5px; top: 16px;
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--text-tertiary);
}
.tl-time { font-size: 0.75rem; color: var(--text-tertiary); font-family: var(--mono); margin-bottom: 4px; }
.tl-content strong { display: block; font-size: 0.9rem; margin-bottom: 2px; }
.tl-content p { font-size: 0.8rem; color: var(--text-secondary); line-height: 1.5; }

.tl-item.disaster { border-left-color: var(--red); }
.tl-item.disaster::before { background: var(--red); }
.tl-item.disaster strong { color: var(--red); }

.tl-item.guard-step::before { background: var(--accent); }
.tl-item.guard-step { border-left-color: var(--accent); }

.tl-item.blocked-step::before { background: var(--yellow); }
.tl-item.blocked-step { border-left-color: var(--yellow); }
.tl-item.blocked-step strong { color: var(--yellow); }

.tl-item.success-step::before { background: var(--green); }
.tl-item.success-step { border-left-color: var(--green); }
.tl-item.success-step strong { color: var(--green); }

@media (max-width: 768px) {
    .comparison { grid-template-columns: 1fr; }
}

/* ============================================
   Features
   ============================================ */
.features-section { padding: 80px 0; }
.features-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.feature-card {
    padding: 28px; border-radius: var(--radius);
    background: var(--bg2); border: 1px solid var(--surface-border);
    transition: all var(--transition);
}
.feature-card:hover {
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}
.feature-icon { font-size: 1.6rem; margin-bottom: 14px; }
.feature-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 8px; }
.feature-card p { font-size: 0.88rem; color: var(--text-secondary); line-height: 1.6; }

@media (max-width: 768px) { .features-grid { grid-template-columns: 1fr; } }
@media (min-width: 769px) and (max-width: 1024px) { .features-grid { grid-template-columns: repeat(2, 1fr); } }

/* ============================================
   Stats
   ============================================ */
.stats-section { padding: 60px 0; }
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
    text-align: center;
}
.stat {
    padding: 28px 16px;
    background: var(--bg2); border: 1px solid var(--surface-border);
    border-radius: var(--radius);
}
.stat-value {
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    font-weight: 900; color: var(--accent);
    letter-spacing: -0.03em; margin-bottom: 6px;
}
.stat-label { font-size: 0.8rem; color: var(--text-secondary); }

@media (max-width: 768px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 400px) { .stats-grid { grid-template-columns: 1fr; } }

/* ============================================
   Final CTA
   ============================================ */
.final-cta {
    padding: 100px 0; text-align: center;
}
.final-cta h2 {
    font-size: clamp(1.8rem, 5vw, 2.8rem);
    font-weight: 900; margin-bottom: 16px;
}
.cta-sub {
    color: var(--text-secondary); font-size: 1.05rem;
    max-width: 560px; margin: 0 auto 32px; line-height: 1.7;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    padding: 64px 0 32px;
    border-top: 1px solid var(--surface-border);
}
.footer-grid {
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px; margin-bottom: 40px;
}
.footer-logo {
    display: flex; align-items: center; gap: 8px;
    text-decoration: none; color: var(--text);
    font-weight: 700; font-size: 1rem; margin-bottom: 8px;
}
.footer-tagline { color: var(--text-tertiary); font-size: 0.85rem; }
.footer-col h4 {
    font-size: 0.8rem; color: var(--text-tertiary);
    text-transform: uppercase; letter-spacing: 0.08em;
    margin-bottom: 12px;
}
.footer-col a {
    display: block; color: var(--text-secondary); font-size: 0.88rem;
    padding: 4px 0; transition: color var(--transition);
}
.footer-col a:hover { color: var(--text); }
.footer-bottom {
    padding-top: 24px; border-top: 1px solid var(--surface-border);
}
.footer-bottom p { color: var(--text-tertiary); font-size: 0.8rem; }

@media (max-width: 768px) {
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 480px) {
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
}
