/* ===== Variables ===== */
:root {
    --bg-main: #0B0F14;
    --bg-section: #121821;
    --bg-card: #161D28;

    --primary: #5E3A6E;
    --primary-light: #6F5A7E;
    --primary-glow: rgba(94, 58, 110, 0.3);

    --text-main: #E6EAF0;
    --text-secondary: #AAB2C0;
    --text-muted: #6B7280;

    --border: #2A3340;

    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: var(--font);
    background: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ===== Grid Background ===== */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.3;
    pointer-events: none;
    z-index: 0;
}

/* ===== Layout ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

.section {
    padding: 100px 0;
    position: relative;
}

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

.section-label {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--primary-light);
    margin-bottom: 12px;
}

.section h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.section-intro {
    max-width: 640px;
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 48px;
}

/* ===== Navigation ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transition: background 0.3s, backdrop-filter 0.3s;
}

.nav.scrolled {
    background: rgba(11, 15, 20, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-main);
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
}

.nav-logo-img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

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

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

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

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-main);
    transition: transform 0.3s, opacity 0.3s;
}

.nav-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ===== Hero ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 24px 80px;
    position: relative;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero-logo {
    width: 120px;
    height: auto;
    margin-bottom: 32px;
    opacity: 0.9;
}

.hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 24px;
}

.highlight {
    color: var(--primary-light);
}

.hero-sub {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

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

.btn-primary {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 0 20px var(--primary-glow);
}

.btn-primary:hover {
    background: var(--primary-light);
    box-shadow: 0 0 30px var(--primary-glow);
}

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

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

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

/* ===== About Grid ===== */
.about-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.about-card {
    background: var(--bg-section);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 32px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.about-card:hover {
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.about-icon {
    color: var(--primary-light);
    margin-bottom: 16px;
}

.about-card h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 8px;
}

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

/* ===== Capabilities Grid ===== */
.capabilities-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.cap-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 32px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.cap-card:hover {
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.cap-icon {
    color: var(--primary-light);
    margin-bottom: 16px;
}

.cap-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

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

/* ===== Workflow ===== */
.workflow {
    display: flex;
    align-items: flex-start;
    gap: 0;
    flex-wrap: wrap;
    justify-content: center;
}

.workflow-step {
    background: var(--bg-section);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 28px 24px;
    text-align: center;
    width: 170px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.workflow-step:hover {
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.workflow-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-light);
    margin-bottom: 12px;
    font-variant-numeric: tabular-nums;
}

.workflow-content h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.workflow-content p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.workflow-connector {
    display: flex;
    align-items: center;
    padding-top: 36px;
    color: var(--primary-light);
    flex-shrink: 0;
}

/* ===== Value Grid ===== */
.value-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.value-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 32px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.value-card:hover {
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.value-icon {
    color: var(--primary-light);
    flex-shrink: 0;
    margin-top: 2px;
}

.value-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 6px;
}

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

/* ===== Use Cases Grid ===== */
.usecases-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.usecase-card {
    background: var(--bg-section);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 36px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.usecase-card:hover {
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.usecase-icon {
    color: var(--primary-light);
    margin-bottom: 16px;
}

.usecase-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

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

/* ===== Platform ===== */
.platform-block {
    text-align: center;
    max-width: 640px;
    margin: 0 auto;
}

.platform-block p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
}

/* ===== Contact / CTA ===== */
.section-cta {
    text-align: center;
    padding: 80px 0;
}

.section-cta h2 {
    font-size: 2rem;
    margin-bottom: 12px;
}

.section-cta p {
    color: var(--text-secondary);
    max-width: 540px;
    margin: 0 auto 32px;
    font-size: 1rem;
    line-height: 1.7;
}

.cta-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.cta-email {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ===== Footer ===== */
.footer {
    border-top: 1px solid var(--border);
    padding: 32px 0;
    position: relative;
    z-index: 1;
}

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

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
}

.footer-logo-img {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s;
}

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

.footer-copy {
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* ===== Legal Pages ===== */
.legal-page {
    padding-top: 100px;
    padding-bottom: 80px;
    min-height: 100vh;
}

.legal-page .container {
    max-width: 800px;
}

.legal-page h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.legal-page .legal-subtitle {
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-size: 0.95rem;
}

.legal-page h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-top: 36px;
    margin-bottom: 12px;
    color: var(--text-main);
}

.legal-page h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-top: 24px;
    margin-bottom: 8px;
    color: var(--text-main);
}

.legal-page p,
.legal-page li {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 12px;
}

.legal-page ul {
    padding-left: 20px;
    margin-bottom: 12px;
}

.legal-page a {
    color: var(--primary-light);
    text-decoration: none;
}

.legal-page a:hover {
    text-decoration: underline;
}

.legal-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    margin-bottom: 32px;
    transition: color 0.2s;
}

.legal-back:hover {
    color: var(--text-main);
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .about-grid,
    .capabilities-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .workflow {
        flex-direction: column;
        align-items: center;
    }

    .workflow-connector {
        transform: rotate(90deg);
        padding-top: 0;
        margin: -4px 0;
    }

    .workflow-step {
        width: 220px;
    }
}

@media (max-width: 640px) {
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        background: rgba(11, 15, 20, 0.97);
        backdrop-filter: blur(12px);
        flex-direction: column;
        padding: 24px;
        gap: 16px;
        border-bottom: 1px solid var(--border);
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.3s, opacity 0.3s;
    }

    .nav-links.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .section {
        padding: 64px 0;
    }

    .section h2 {
        font-size: 1.6rem;
    }

    .about-grid,
    .capabilities-grid,
    .value-grid,
    .usecases-grid {
        grid-template-columns: 1fr;
    }

    .value-card {
        flex-direction: column;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .hero {
        padding: 100px 20px 60px;
    }

    .hero h1 {
        font-size: 1.8rem;
    }
}
