:root {
    --bg: #fff4f2;
    --bg-soft: #fff8f7;
    --surface: #ffffff;
    --surface-strong: #fffdfd;
    --surface-muted: #fff0eb;
    --text: #111111;
    --text-muted: #5f6368;
    --line: rgba(17, 17, 17, 0.08);
    --accent: #ff4500;
    --accent-strong: #d83700;
    --accent-soft: rgba(255, 69, 0, 0.1);
    --gold: #b7791f;
    --red: #c2410c;
    --white: #ffffff;
    --shadow: 0 18px 40px rgba(0, 0, 0, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background:
        radial-gradient(circle at top left, rgba(255, 69, 0, 0.08), transparent 28%),
        linear-gradient(180deg, var(--bg-soft) 0%, var(--bg) 100%);
    color: var(--text);
}

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

img,
iframe {
    max-width: 100%;
}

.container {
    width: min(1120px, calc(100% - 2rem));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(14px);
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.04);
}

.header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 76px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--accent-soft), rgba(255, 255, 255, 0.7));
    border: 1px solid rgba(255, 69, 0, 0.18);
    color: var(--accent);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.nav-links a {
    color: var(--text-muted);
    padding: 0.65rem 0.9rem;
    border-radius: 999px;
    transition: 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
    background: rgba(255, 69, 0, 0.08);
}

.hero {
    padding: 4.8rem 0 3rem;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    gap: 1.5rem;
    align-items: stretch;
}

.hero-panel,
.panel,
.card,
.code-card,
.video-card {
    background: linear-gradient(180deg, var(--surface-strong), var(--surface));
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.hero-copy {
    padding: 2.4rem;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--accent);
    margin-bottom: 1rem;
}

h1,
h2,
h3 {
    margin: 0;
    line-height: 1.08;
}

h1 {
    font-size: clamp(2.3rem, 5vw, 4.6rem);
    letter-spacing: -0.03em;
}

h2 {
    font-size: clamp(1.8rem, 3.8vw, 2.8rem);
    letter-spacing: -0.02em;
}

h3 {
    font-size: 1.3rem;
}

.lead {
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.8;
    margin-top: 1rem;
}

.badge-row,
.button-row,
.meta-row {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.badge-row {
    margin-top: 1.4rem;
}

.button-row {
    margin-top: 1.7rem;
}

.meta-row {
    margin-top: 1rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    font-size: 0.86rem;
    border: 1px solid transparent;
}

.badge.available {
    background: rgba(34, 197, 94, 0.1);
    color: #166534;
    border-color: rgba(34, 197, 94, 0.18);
}

.badge.soon {
    background: rgba(255, 69, 0, 0.1);
    color: var(--accent-strong);
    border-color: rgba(255, 69, 0, 0.16);
}

.badge.reference {
    background: rgba(17, 17, 17, 0.05);
    color: #374151;
    border-color: rgba(17, 17, 17, 0.08);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.95rem 1.35rem;
    border-radius: 14px;
    border: 1px solid transparent;
    font-weight: 600;
    transition: 0.2s ease;
}

.button.primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: var(--white);
}

.button.primary:hover {
    transform: translateY(-1px);
}

.button.secondary {
    background: rgba(255, 69, 0, 0.04);
    border-color: var(--line);
    color: var(--text);
}

.button.secondary:hover {
    background: rgba(255, 69, 0, 0.08);
}

.button.disabled {
    background: rgba(17, 17, 17, 0.04);
    color: var(--text-muted);
    border-color: var(--line);
    cursor: not-allowed;
}

.hero-side {
    padding: 1.5rem;
    display: grid;
    gap: 1rem;
}

.stat-block {
    padding: 1.25rem;
    border-radius: 18px;
    background: var(--surface-muted);
    border: 1px solid rgba(255, 69, 0, 0.1);
}

.stat-block strong {
    display: block;
    font-size: 1.05rem;
}

.stat-block span {
    display: block;
    margin-top: 0.35rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.section {
    padding: 1rem 0 4rem;
}

.section-header {
    margin-bottom: 1.6rem;
}

.section-header p {
    color: var(--text-muted);
    line-height: 1.75;
    max-width: 760px;
}

.grid-3,
.grid-2,
.tutorial-grid,
.resource-grid {
    display: grid;
    gap: 1.1rem;
}

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

.grid-2,
.resource-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.card {
    padding: 1.4rem;
}

.card p,
.panel p,
.list li,
.timeline li,
.content p {
    color: var(--text-muted);
    line-height: 1.75;
}

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

.card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.card h3 {
    margin-bottom: 0.35rem;
}

.list,
.timeline,
.anchor-list {
    padding-left: 1.1rem;
    margin: 0.9rem 0 0;
}

.timeline li,
.list li,
.anchor-list li {
    margin-bottom: 0.75rem;
}

.panel {
    padding: 1.6rem;
}

.panel + .panel {
    margin-top: 1rem;
}

.anchor-nav {
    position: sticky;
    top: 92px;
    align-self: start;
}

.anchor-nav .panel {
    padding: 1.25rem;
}

.anchor-list {
    list-style: none;
    padding: 0;
    margin-top: 1rem;
}

.anchor-list a {
    display: block;
    padding: 0.65rem 0.8rem;
    border-radius: 12px;
    color: var(--text-muted);
    transition: 0.2s ease;
}

.anchor-list a:hover {
    color: var(--accent);
    background: rgba(255, 69, 0, 0.08);
}

.content-layout {
    display: grid;
    grid-template-columns: 0.72fr 0.28fr;
    gap: 1.2rem;
}

.content section {
    scroll-margin-top: 120px;
}

.content .panel h2,
.content .panel h3 {
    margin-bottom: 0.8rem;
}

.video-embed {
    position: relative;
    padding-top: 56.25%;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid rgba(255, 69, 0, 0.12);
}

.video-embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.code-card {
    overflow: hidden;
}

.code-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.95rem 1.1rem;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 69, 0, 0.05);
}

.code-header strong {
    display: block;
    font-size: 0.98rem;
}

.code-header span {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.copy-btn {
    appearance: none;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.9);
    color: var(--text);
    border-radius: 10px;
    padding: 0.55rem 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s ease;
}

.copy-btn:hover {
    background: rgba(255, 69, 0, 0.08);
    border-color: rgba(255, 69, 0, 0.2);
}

pre {
    margin: 0;
    padding: 1.1rem;
    overflow-x: auto;
    background: #161616;
    color: #f5f5f5;
    font-size: 0.92rem;
    line-height: 1.7;
}

code {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}

.callout {
    padding: 1rem 1.1rem;
    border-radius: 16px;
    background: rgba(255, 69, 0, 0.06);
    border: 1px solid rgba(255, 69, 0, 0.14);
}

.callout.warning {
    background: rgba(183, 121, 31, 0.08);
    border-color: rgba(183, 121, 31, 0.16);
}

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

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    text-align: left;
    padding: 0.95rem 0.9rem;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

th {
    color: var(--text);
    font-size: 0.94rem;
}

td {
    color: var(--text-muted);
    line-height: 1.65;
}

.footer {
    padding: 2rem 0 3rem;
    color: var(--text-muted);
}

.footer-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
    border-top: 1px solid var(--line);
    padding-top: 1.2rem;
}

@media (max-width: 980px) {
    .hero-grid,
    .content-layout,
    .grid-3,
    .grid-2,
    .tutorial-grid,
    .resource-grid {
        grid-template-columns: 1fr;
    }

    .anchor-nav {
        position: static;
    }
}

@media (max-width: 720px) {
    .header-row {
        align-items: flex-start;
        padding: 1rem 0;
        flex-direction: column;
    }

    .nav-links {
        justify-content: flex-start;
    }

    .hero {
        padding-top: 4.2rem;
    }

    .hero-copy,
    .hero-side,
    .panel,
    .card {
        padding: 1.2rem;
    }
}
