/* ===== RESET & BASE ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #09090b;
    --bg-subtle: #0f0f12;
    --bg-card: #141418;
    --bg-card-hover: #1a1a1f;
    
    --border: rgba(255,255,255,0.08);
    --border-light: rgba(255,255,255,0.12);
    
    --text: #fafafa;
    --text-secondary: rgba(255,255,255,0.7);
    --text-muted: rgba(255,255,255,0.5);
    
    --accent: #10b981;
    --accent-light: #34d399;
    --accent-dim: rgba(16,185,129,0.15);
    
    --danger: #ef4444;
    --warning: #f59e0b;
    --success: #10b981;
    
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); }
h3 { font-size: 1.125rem; }

.gradient-text {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== LAYOUT ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

section {
    padding: 100px 0;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 0.9375rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: var(--bg);
}

.btn-primary:hover {
    background: var(--accent-light);
    transform: translateY(-1px);
    box-shadow: 0 8px 30px rgba(16,185,129,0.25);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: rgba(255,255,255,0.2);
}

.btn-white {
    background: white;
    color: var(--bg);
}

.btn-white:hover {
    background: #f0f0f0;
    transform: translateY(-1px);
}

.btn-outline-light {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border-light);
}

.btn-outline-light:hover {
    background: rgba(255,255,255,0.05);
    border-color: rgba(255,255,255,0.25);
}

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
}

.btn-ghost:hover {
    color: var(--text);
}

.btn-lg {
    padding: 14px 28px;
    font-size: 1rem;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.875rem;
}

/* ===== NAVIGATION ===== */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 24px;
    background: rgba(9,9,11,0.85);
    backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border);
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-mark {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    border-radius: var(--radius-sm);
    display: grid;
    place-items: center;
}

.logo-mark svg {
    width: 18px;
    height: 18px;
    color: var(--bg);
}

.logo-text {
    font-weight: 600;
    font-size: 1.125rem;
    letter-spacing: -0.02em;
}

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

.nav-links a {
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--text);
}

.nav-cta {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ===== HERO ===== */
.hero {
    padding-top: 140px;
    padding-bottom: 80px;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 60px;
    align-items: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--accent-dim);
    border: 1px solid rgba(16,185,129,0.25);
    border-radius: 100px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--accent-light);
    margin-bottom: 24px;
}

.hero-badge svg {
    width: 16px;
    height: 16px;
}

.hero h1 {
    margin-bottom: 20px;
}

.hero-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
    max-width: 480px;
    line-height: 1.7;
}

.hero-ctas {
    display: flex;
    gap: 12px;
    margin-bottom: 48px;
}

.hero-metrics {
    display: flex;
    gap: 40px;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}

.hero-metric {
    display: flex;
    flex-direction: column;
}

.hero-metric-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
    line-height: 1;
}

.hero-metric-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: 4px;
}

/* Hero Visual */
.hero-visual {
    position: relative;
}

.hero-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 
        0 0 0 1px var(--border),
        0 25px 50px -12px rgba(0,0,0,0.5);
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
}

.hero-image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(9,9,11,0.3) 0%,
        transparent 30%,
        transparent 60%,
        rgba(9,9,11,0.8) 100%
    );
    pointer-events: none;
}

/* Risk Indicators */
.risk-indicator {
    position: absolute;
    z-index: 10;
}

.risk-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid var(--bg);
    cursor: pointer;
    position: relative;
}

.risk-dot::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 2px solid;
    animation: ping 2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

.risk-dot.critical { background: var(--danger); }
.risk-dot.critical::before { border-color: var(--danger); }

.risk-dot.warning { background: var(--warning); }
.risk-dot.warning::before { border-color: var(--warning); }

.risk-dot.safe { background: var(--success); }
.risk-dot.safe::before { border-color: var(--success); }

@keyframes ping {
    75%, 100% {
        transform: scale(2);
        opacity: 0;
    }
}

.risk-tooltip {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(9,9,11,0.95);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s;
    z-index: 20;
}

.risk-indicator:hover .risk-tooltip {
    opacity: 1;
    visibility: visible;
}

.risk-tooltip strong {
    display: block;
    font-size: 0.8125rem;
    margin-bottom: 4px;
}

.risk-tooltip span {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Stats Overlay */
.hero-stats-overlay {
    position: absolute;
    bottom: 16px;
    left: 16px;
    right: 16px;
    background: rgba(9,9,11,0.9);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 32px;
}

.stats-overlay-item {
    text-align: center;
}

.stats-overlay-value {
    font-size: 1.5rem;
    font-weight: 700;
    display: block;
}

.stats-overlay-value.critical { color: var(--danger); }
.stats-overlay-value.warning { color: var(--warning); }

.stats-overlay-label {
    font-size: 0.6875rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.stats-overlay-divider {
    width: 1px;
    height: 32px;
    background: var(--border);
}

/* ===== LOGOS BAR ===== */
.logos-bar {
    padding: 48px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: var(--bg-subtle);
}

.logos-label {
    text-align: center;
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.logos-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 48px;
    flex-wrap: wrap;
}

.logo-item {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-muted);
    opacity: 0.6;
}

/* ===== SECTION STYLES ===== */
.section-label {
    display: inline-block;
    padding: 6px 12px;
    background: var(--accent-dim);
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 64px;
}

.section-header p {
    font-size: 1.0625rem;
    color: var(--text-secondary);
    margin-top: 12px;
}

/* ===== PROBLEM SECTION ===== */
.problem {
    background: var(--bg-subtle);
}

.problem-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.problem-content h2 {
    margin-bottom: 16px;
}

.problem-content > p {
    color: var(--text-secondary);
    font-size: 1.0625rem;
    line-height: 1.7;
    margin-bottom: 32px;
}

.problem-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.problem-stat {
    padding: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.problem-stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--danger);
    line-height: 1;
    margin-bottom: 8px;
}

.problem-stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.problem-visual {
    position: relative;
}

.problem-image {
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
}

/* ===== FEATURES SECTION ===== */
.features {
    background: var(--bg);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

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

.feature-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-light);
    transform: translateY(-4px);
}

.feature-icon {
    width: 48px;
    height: 48px;
    background: var(--accent-dim);
    border-radius: var(--radius);
    display: grid;
    place-items: center;
    margin-bottom: 20px;
}

.feature-icon svg {
    width: 24px;
    height: 24px;
    color: var(--accent);
}

.feature-card h3 {
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.features-cta {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 48px;
}

/* ===== HOW IT WORKS ===== */
.how-it-works {
    background: var(--bg-subtle);
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.process-step {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.process-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--accent);
    opacity: 0.3;
    line-height: 1;
}

.process-content h3 {
    margin-bottom: 8px;
}

.process-content p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== INDUSTRIES ===== */
.industries {
    background: var(--bg);
}

.industries-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.industry-card {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
}

.industry-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.industry-card:hover img {
    transform: scale(1.05);
}

.industry-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 30%, rgba(9,9,11,0.95) 100%);
}

.industry-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
}

.industry-icon {
    width: 36px;
    height: 36px;
    background: var(--accent-dim);
    border-radius: var(--radius-sm);
    display: grid;
    place-items: center;
    margin-bottom: 12px;
}

.industry-icon svg {
    width: 18px;
    height: 18px;
    color: var(--accent);
}

.industry-card h3 {
    font-size: 1rem;
    margin-bottom: 4px;
}

.industry-card p {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.5;
    opacity: 0;
    transform: translateY(8px);
    transition: all 0.3s ease;
}

.industry-card:hover p {
    opacity: 1;
    transform: translateY(0);
}

/* ===== CASE STUDY PREVIEW ===== */
.case-study-preview {
    background: var(--bg-subtle);
}

.case-study-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
    padding: 64px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.case-study-content h2 {
    font-size: 1.75rem;
    margin-bottom: 16px;
    font-style: italic;
}

.case-study-content > p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 32px;
}

.case-study-stats {
    display: flex;
    gap: 40px;
    margin-bottom: 32px;
}

.case-study-stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
    display: block;
}

.case-study-stat-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.case-study-image {
    border-radius: var(--radius);
    overflow: hidden;
}

.case-study-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== CTA SECTION ===== */
.cta {
    background: linear-gradient(180deg, var(--bg) 0%, #0a1f15 100%);
    text-align: center;
    padding: 120px 0;
}

.cta-content {
    max-width: 600px;
    margin: 0 auto;
}

.cta h2 {
    margin-bottom: 16px;
}

.cta > .container p,
.cta-content > p {
    font-size: 1.0625rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.cta-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}

/* ===== FOOTER ===== */
footer {
    background: var(--bg);
    border-top: 1px solid var(--border);
    padding: 64px 0 32px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(4, 1fr);
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand p {
    margin-top: 16px;
    font-size: 0.875rem;
    color: var(--text-muted);
    max-width: 260px;
}

.footer-social {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.footer-social a {
    width: 36px;
    height: 36px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    display: grid;
    place-items: center;
    transition: all 0.2s;
}

.footer-social a:hover {
    background: var(--accent-dim);
}

.footer-social svg {
    width: 18px;
    height: 18px;
    color: var(--text-muted);
}

.footer-social a:hover svg {
    color: var(--accent);
}

.footer-col h4 {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 10px;
}

.footer-col a {
    font-size: 0.875rem;
    color: var(--text-muted);
    transition: color 0.2s;
}

.footer-col a:hover {
    color: var(--text);
}

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

.footer-legal a {
    color: var(--text-muted);
    margin-left: 24px;
    transition: color 0.2s;
}

.footer-legal a:hover {
    color: var(--text);
}

/* ===== PAGE HEADERS ===== */
.page-header {
    padding: 160px 0 80px;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-subtle) 0%, var(--bg) 100%);
    border-bottom: 1px solid var(--border);
}

.page-header h1 {
    margin-bottom: 16px;
}

.page-header p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* ===== FORMS ===== */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 8px;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 12px 16px;
    font-size: 0.9375rem;
    font-family: inherit;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    transition: all 0.2s;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-dim);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--text-muted);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* ===== CARDS ===== */
.card {
    padding: 32px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.card-sm {
    padding: 24px;
}

/* ===== DOC/API STYLES ===== */
.doc-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 48px;
    padding-top: 48px;
}

.doc-sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.doc-nav-section {
    margin-bottom: 24px;
}

.doc-nav-title {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.doc-nav-links {
    list-style: none;
}

.doc-nav-links li {
    margin-bottom: 4px;
}

.doc-nav-links a {
    display: block;
    padding: 8px 12px;
    font-size: 0.875rem;
    color: var(--text-secondary);
    border-radius: 6px;
    transition: all 0.15s;
}

.doc-nav-links a:hover,
.doc-nav-links a.active {
    background: var(--bg-card);
    color: var(--text);
}

.doc-content {
    max-width: 800px;
}

.doc-content h2 {
    margin-top: 48px;
    margin-bottom: 16px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.doc-content h2:first-child {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.doc-content h3 {
    margin-top: 32px;
    margin-bottom: 12px;
}

.doc-content p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.7;
}

.doc-content ul,
.doc-content ol {
    margin-bottom: 16px;
    padding-left: 24px;
    color: var(--text-secondary);
}

.doc-content li {
    margin-bottom: 8px;
}

.doc-content code {
    padding: 2px 6px;
    background: var(--bg-card);
    border-radius: 4px;
    font-size: 0.875em;
    color: var(--accent-light);
}

.code-block {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    overflow-x: auto;
    margin-bottom: 24px;
}

.code-block code {
    background: none;
    padding: 0;
    font-size: 0.875rem;
    line-height: 1.6;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1100px) {
    .hero-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-visual {
        margin-top: 48px;
    }
    
    .problem-grid,
    .case-study-card {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .features-grid,
    .process-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .industries-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .doc-layout {
        grid-template-columns: 1fr;
    }
    
    .doc-sidebar {
        position: static;
        display: flex;
        gap: 32px;
        overflow-x: auto;
        padding-bottom: 16px;
        border-bottom: 1px solid var(--border);
        margin-bottom: 32px;
    }
    
    .doc-nav-section {
        margin-bottom: 0;
        flex-shrink: 0;
    }
}

@media (max-width: 768px) {
    section {
        padding: 72px 0;
    }
    
    .nav-links {
        display: none;
    }
    
    .hero {
        padding-top: 100px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero-ctas {
        flex-direction: column;
    }
    
    .hero-metrics {
        flex-wrap: wrap;
        gap: 24px;
    }
    
    .hero-stats-overlay {
        flex-wrap: wrap;
        gap: 16px;
    }
    
    .stats-overlay-divider {
        display: none;
    }
    
    .problem-stats,
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .features-grid,
    .process-grid,
    .industries-grid {
        grid-template-columns: 1fr;
    }
    
    .case-study-card {
        padding: 32px;
    }
    
    .case-study-stats {
        flex-wrap: wrap;
        gap: 24px;
    }
    
    .cta-buttons {
        flex-direction: column;
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .footer-legal a {
        margin: 0 12px;
    }
}
