:root {
    --bg: #030712;
    --surface: #070d1a;
    --border: #1e293b;
    --text: #f3f4f6;
    --text-muted: #9ca3af;
    --accent: #34d399;
    --accent-hover: #6ee7b7;
    --accent-glow: rgba(52, 211, 153, 0.15);
    --code-bg: #0c1222;
    --code-border: #1e293b;
    --green: #34d399;
    --sidebar-width: 220px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

/* ── Header ── */
header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 0;
    background: rgba(3, 7, 18, 0.6);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    z-index: 100;
}

header .header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1152px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    line-height: 1.4;
    font-weight: 600;
    letter-spacing: -0.025em;
    color: var(--text);
}

.logo:hover { opacity: 0.8; text-decoration: none; }

.logo img { height: 32px; width: 32px; }

.logo .brand-prompt {
    color: #22d3ee;
    -webkit-text-fill-color: #22d3ee;
}

.logo .brand-ship {
    color: #a78bfa;
    -webkit-text-fill-color: #a78bfa;
}

.logo .brand-docs {
    color: var(--text-muted);
    -webkit-text-fill-color: var(--text-muted);
    font-weight: 400;
    margin-left: 2px;
}

.header-links { display: flex; gap: 1.5rem; align-items: center; }
.header-links a { color: var(--text-muted); font-size: 0.875rem; line-height: 1.4286; transition: color 0.2s; }
.header-links a:hover { color: var(--text); text-decoration: none; }

.hamburger {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    font-size: 24px;
    cursor: pointer;
    padding: 4px;
}

/* ── Sidebar layout ── */
.page-layout {
    display: flex;
    max-width: 1152px;
    margin: 0 auto;
}

.sidebar {
    width: var(--sidebar-width);
    flex-shrink: 0;
    border-right: 1px solid var(--border);
    padding: 24px 16px;
    position: sticky;
    top: 61px;
    height: calc(100vh - 61px);
    overflow-y: auto;
}

.sidebar-group { margin-bottom: 24px; }

.sidebar-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 8px;
    padding-left: 12px;
}

.sidebar a {
    display: block;
    padding: 6px 12px;
    font-size: 14px;
    color: var(--text-muted);
    border-radius: 6px;
    transition: background 0.15s, color 0.15s;
}

.sidebar a:hover {
    color: var(--text);
    background: var(--surface);
    text-decoration: none;
}

.sidebar a.active {
    color: var(--accent);
    background: var(--accent-glow);
}

.page-content {
    flex: 1;
    min-width: 0;
    padding: 48px 48px 80px;
    max-width: 800px;
}

/* ── Container (for full-width pages like index) ── */
.container-wide {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ── Typography ── */
h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

h2 {
    font-size: 22px;
    font-weight: 600;
    margin-top: 48px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

h3 {
    font-size: 17px;
    font-weight: 600;
    margin-top: 32px;
    margin-bottom: 12px;
}

p { margin-bottom: 16px; color: var(--text-muted); }
p strong { color: var(--text); }

.subtitle {
    font-size: 18px;
    color: var(--text-muted);
    margin-bottom: 40px;
}

/* ── Code ── */
code {
    font-family: 'JetBrains Mono', 'SF Mono', 'Fira Code', 'Consolas', monospace;
    background: var(--code-bg);
    border: 1px solid var(--code-border);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 14px;
    color: var(--text);
}

pre {
    background: var(--code-bg);
    border: 1px solid var(--code-border);
    border-radius: 8px;
    padding: 20px;
    overflow-x: auto;
    margin-bottom: 24px;
    position: relative;
}

pre code {
    background: none;
    border: none;
    padding: 0;
    font-size: 13px;
    line-height: 1.6;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* ── Lists ── */
ol, ul {
    margin-bottom: 16px;
    padding-left: 24px;
    color: var(--text-muted);
}

li { margin-bottom: 8px; }
li strong { color: var(--text); }
li code { font-size: 13px; }

/* ── Tables ── */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}

th, td {
    text-align: left;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}

th {
    color: var(--text);
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

td { color: var(--text-muted); }
td code { font-size: 12px; }

/* ── Cards ── */
.cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 32px;
}

.cards-3 {
    grid-template-columns: repeat(3, 1fr);
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 24px;
    transition: border-color 0.2s;
}

.card:hover { border-color: var(--accent); text-decoration: none; }
.card h3 { margin-top: 0; margin-bottom: 8px; color: var(--text); }
.card p { margin-bottom: 0; font-size: 14px; }

.card-icon {
    font-size: 28px;
    margin-bottom: 12px;
    display: block;
}

.card-time {
    display: inline-block;
    font-size: 12px;
    color: var(--green);
    margin-top: 8px;
}

/* ── Callout ── */
.callout {
    background: var(--surface);
    border-left: 3px solid var(--accent);
    padding: 16px 20px;
    margin-bottom: 24px;
    border-radius: 0 8px 8px 0;
}

.callout p { margin-bottom: 0; font-size: 14px; }

/* ── Steps ── */
.step {
    margin-bottom: 32px;
    padding-left: 20px;
    border-left: 2px solid var(--border);
}

.step-number {
    display: inline-block;
    background: var(--accent);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    line-height: 24px;
    margin-right: 8px;
    margin-left: -31px;
}

/* ── Hero (index page) ── */
.hero {
    text-align: center;
    padding: 80px 24px 60px;
}

.hero h1 {
    font-size: 48px;
    font-weight: 800;
    letter-spacing: -1.5px;
    line-height: 1.1;
    margin-bottom: 20px;
}

.gradient-text {
    background: linear-gradient(135deg, #34d399, #38bdf8, #a78bfa, #34d399);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 6s ease infinite;
}

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

.hero .subtitle {
    font-size: 20px;
    max-width: 600px;
    margin: 0 auto 36px;
}

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

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.btn-primary {
    background: linear-gradient(90deg, #34d399 0%, #6ee7b7 40%, #34d399 80%);
    background-size: 200% 100%;
    color: var(--bg);
}

.btn-primary:hover {
    text-decoration: none;
    color: var(--bg);
}

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

.btn-secondary:hover {
    border-color: var(--accent);
    text-decoration: none;
    color: var(--text);
}

/* ── Terminal mockup ── */
.terminal {
    background: var(--code-bg);
    border: 1px solid var(--code-border);
    border-radius: 12px;
    max-width: 600px;
    margin: 0 auto 60px;
    text-align: left;
    overflow: hidden;
}

.terminal-header {
    display: flex;
    gap: 6px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--code-border);
}

.terminal-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
}

.terminal-body {
    padding: 20px;
    font-family: 'JetBrains Mono', 'SF Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 13px;
    line-height: 1.8;
}

.terminal-body .prompt { color: var(--green); }
.terminal-body .cmd { color: var(--text); }
.terminal-body .output { color: var(--text-muted); }
.terminal-body .url { color: var(--accent); }

/* ── How it works (3-step) ── */
.steps-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin: 32px 0 48px;
}

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

.step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent-glow);
    color: var(--accent);
    font-weight: 700;
    font-size: 16px;
    margin-bottom: 16px;
    border: 1px solid var(--accent);
}

.step-card h3 {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 16px;
}

.step-card p {
    font-size: 14px;
    margin-bottom: 0;
}

/* ── Framework row ── */
.frameworks {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 32px 0;
}

.framework-tag {
    display: inline-block;
    padding: 8px 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    font-size: 13px;
    color: var(--text-muted);
    transition: border-color 0.2s, color 0.2s;
}

.framework-tag:hover {
    border-color: var(--accent);
    color: var(--text);
    text-decoration: none;
}

/* ── Section headings (for landing page) ── */
.section {
    padding: 48px 0;
}

.section-title {
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
    border-bottom: none;
    margin-top: 0;
}

.section-subtitle {
    text-align: center;
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 40px;
}

/* ── Badge ── */
.badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 8px;
    border-radius: 4px;
    margin-left: 8px;
}

.badge-soon {
    background: rgba(234, 179, 8, 0.15);
    color: #eab308;
    border: 1px solid rgba(234, 179, 8, 0.3);
}

/* ── Bottom CTA ── */
.bottom-cta {
    text-align: center;
    padding: 60px 24px;
    border-top: 1px solid var(--border);
    margin-top: 48px;
}

.bottom-cta p {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

/* ── Tier table (pricing) ── */
.tier-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 32px;
}

.tier-table th {
    background: var(--surface);
    padding: 14px 16px;
}

.tier-table td {
    padding: 12px 16px;
}

/* ── Footer ── */
footer {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 2.5rem 1.5rem;
    font-size: 0.875rem;
    line-height: 1.4286;
    color: var(--text-muted);
}

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

footer .footer-links {
    display: flex;
    gap: 1.5rem;
}

footer a {
    color: var(--text-muted);
    transition: color 0.2s;
}

footer a:hover {
    color: var(--accent);
    text-decoration: none;
}

/* ── Responsive ── */
@media (max-width: 900px) {
    .cards-3 { grid-template-columns: 1fr 1fr; }
    .steps-row { grid-template-columns: 1fr; gap: 16px; }

    .hero h1 { font-size: 36px; }
    .hero .subtitle { font-size: 17px; }
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
        position: fixed;
        top: 61px;
        left: 0;
        width: 260px;
        height: calc(100vh - 61px);
        background: var(--bg);
        z-index: 99;
        border-right: 1px solid var(--border);
    }

    .sidebar.open { display: block; }

    .hamburger { display: block; }

    .page-content {
        padding: 32px 24px 60px;
    }

    .header-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 61px;
        right: 0;
        background: var(--bg);
        border: 1px solid var(--border);
        border-radius: 0 0 8px 8px;
        padding: 12px 16px;
        gap: 8px;
        z-index: 99;
    }

    .header-links.open { display: flex; }
}

@media (max-width: 600px) {
    .cards { grid-template-columns: 1fr; }
    .cards-3 { grid-template-columns: 1fr; }
    h1 { font-size: 26px; }
    .hero h1 { font-size: 28px; }
    .hero-ctas { flex-direction: column; align-items: center; }
    .hero { padding: 48px 16px 40px; }
}
