/* ================================================================
   Asobi — Marketing Site
   Dark theme, game-backend aesthetic
   ================================================================ */

:root {
    --bg:         #0a0e17;
    --bg-surface: #111827;
    --bg-card:    #1a2332;
    --bg-code:    #0d1117;
    --text:       #e2e8f0;
    --text-muted: #94a3b8;
    --accent:     #6366f1;
    --accent-hover: #818cf8;
    --accent-glow: rgba(99, 102, 241, 0.15);
    --green:      #34d399;
    --border:     #1e293b;
    --radius:     8px;
    --max-width:  1120px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 16px;
}

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

code {
    font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
    background: var(--bg-code);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
}

/* ---- Navigation ---- */

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

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

.nav-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
}

.brand-icon {
    font-size: 1.5rem;
}

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

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

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

.nav-github {
    padding: 6px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: border-color 0.2s, color 0.2s;
}

.nav-github:hover {
    border-color: var(--accent);
    color: var(--accent) !important;
}

/* ---- Hero ---- */

.hero {
    padding: 160px 24px 100px;
    text-align: center;
    background:
        radial-gradient(ellipse at 50% 0%, var(--accent-glow) 0%, transparent 60%),
        var(--bg);
}

.hero-inner {
    max-width: 720px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    padding: 4px 14px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.12);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 20px;
    margin-bottom: 20px;
}

.hero-notice {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 28px;
    padding: 12px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-surface);
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.hero-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 16px;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto 36px;
    line-height: 1.7;
}

/* ---- Buttons ---- */

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

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.2s;
    cursor: pointer;
}

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

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

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

.btn-secondary:hover {
    border-color: var(--text-muted);
    color: var(--text);
}

/* ---- Sections ---- */

.section {
    padding: 96px 24px;
}

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

.section-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 56px;
    font-size: 1.05rem;
}

/* ---- BEAM Grid ---- */

.beam-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.beam-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: border-color 0.2s;
}

.beam-card:hover {
    border-color: var(--accent);
}

.beam-card-icon {
    font-size: 1.75rem;
    margin-bottom: 12px;
}

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

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

/* ---- Feature Grid ---- */

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

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

.feature-card:hover {
    border-color: var(--accent);
    box-shadow: 0 0 20px var(--accent-glow);
}

.feature-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--green);
}

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

/* ---- SDK Grid ---- */

.sdk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.sdk-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: border-color 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.sdk-card:hover {
    border-color: var(--accent);
    box-shadow: 0 0 20px var(--accent-glow);
}

.sdk-card h3 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.sdk-lang {
    font-size: 0.8rem;
    color: var(--green);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.sdk-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
    flex: 1;
}

.sdk-link {
    display: inline-block;
    margin-top: 16px;
    font-size: 0.9rem;
    font-weight: 600;
}

.sdk-card-link {
    color: inherit;
    text-decoration: none;
}

.sdk-card-link:hover {
    color: inherit;
}

.sdk-note {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 32px;
}

/* ---- Code Block ---- */

.code-block {
    background: var(--bg-code);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    overflow-x: auto;
    max-width: 700px;
    margin: 0 auto;
}

.code-block pre {
    margin: 0;
}

.code-block code {
    background: none;
    padding: 0;
    font-size: 0.88rem;
    line-height: 1.7;
    color: #c9d1d9;
}

/* ---- Comparison Table ---- */

.comparison-table-wrap {
    overflow-x: auto;
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.comparison-table th,
.comparison-table td {
    padding: 14px 20px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.comparison-table thead th {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.comparison-table .highlight {
    background: var(--accent-glow);
    color: var(--accent-hover);
    font-weight: 600;
}

.comparison-table thead .highlight {
    color: var(--accent);
    font-size: 1rem;
    text-transform: none;
    letter-spacing: 0;
}

.row-label {
    font-weight: 600;
    color: var(--text);
}

.comparison-table td {
    color: var(--text-muted);
}

/* ---- Getting Started Steps ---- */

.steps {
    max-width: 640px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.step {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.step-number {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
}

.step-content h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.step-content p {
    color: var(--text-muted);
    font-size: 0.92rem;
}

.step-content code {
    color: var(--green);
}

.steps-cta {
    text-align: center;
    margin-top: 48px;
}

/* ---- Footer ---- */

.site-footer {
    border-top: 1px solid var(--border);
    padding: 64px 24px 32px;
    background: var(--bg);
}

.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 48px;
    flex-wrap: wrap;
}

.footer-brand {
    font-size: 1.25rem;
    font-weight: 700;
}

.footer-tagline {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 400;
    margin-top: 8px;
}

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

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-col h4 {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 4px;
}

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

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

.footer-bottom {
    max-width: var(--max-width);
    margin: 48px auto 0;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    text-align: center;
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* ---- Community ---- */

.community-section {
    text-align: center;
}

.btn-lg {
    padding: 16px 40px;
    font-size: 1.1rem;
}

.nav-link-btn {
    color: var(--text-muted) !important;
}

/* ---- Guide Pages ---- */

.guide-page {
    padding: 96px 24px 64px;
    max-width: var(--max-width);
    margin: 0 auto;
}

.guide-back {
    display: inline-block;
    margin-bottom: 32px;
    font-size: 0.9rem;
    font-weight: 500;
}

.guide-header {
    margin-bottom: 48px;
}

.guide-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 12px;
}

.guide-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 640px;
}

.guide-section {
    margin-bottom: 48px;
}

.guide-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.guide-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 24px 0 12px;
    color: var(--green);
}

.guide-section p {
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.7;
}

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

.guide-code pre {
    margin: 0;
}

.guide-code code {
    background: none;
    padding: 0;
    font-size: 0.88rem;
    line-height: 1.7;
    color: #c9d1d9;
}

.guide-github {
    display: inline-block;
    margin-top: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 8px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: border-color 0.2s;
}

.guide-github:hover {
    border-color: var(--accent);
}

/* ---- Responsive ---- */

@media (max-width: 768px) {
    .nav-links { gap: 20px; }
    .hero { padding: 120px 20px 72px; }
    .section { padding: 64px 20px; }
    .beam-grid { grid-template-columns: 1fr; }
    .feature-grid { grid-template-columns: 1fr 1fr; }
    .footer-inner { flex-direction: column; gap: 32px; }
    .footer-links { gap: 32px; }
}

@media (max-width: 480px) {
    .feature-grid { grid-template-columns: 1fr; }
    .nav-links a:not(.nav-github) { display: none; }
    .comparison-table { font-size: 0.8rem; }
    .comparison-table th,
    .comparison-table td { padding: 10px 12px; }
}
