:root {
    --bg: #080b14;
    --bg-deep: #05070c;
    --surface: rgba(18, 24, 39, 0.64);
    --surface-strong: rgba(18, 24, 39, 0.84);
    --surface-soft: rgba(255, 255, 255, 0.055);
    --border: rgba(255, 255, 255, 0.15);
    --border-strong: rgba(255, 255, 255, 0.27);
    --text: #f4f7ff;
    --muted: #a9b4cc;
    --subtle: #717c94;
    --blue: #72a8ff;
    --cyan: #69e8ff;
    --violet: #b795ff;
    --green: #61e4ac;
    --orange: #ffbc70;
    --red: #ff799b;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
    --container: min(1440px, calc(100% - 40px));
    --radius-xl: 30px;
    --radius-lg: 22px;
    --radius-md: 16px;
}

:root[data-theme="light"] {
    --bg: #eef4ff;
    --bg-deep: #e6edff;
    --surface: rgba(255, 255, 255, 0.58);
    --surface-strong: rgba(255, 255, 255, 0.82);
    --surface-soft: rgba(255, 255, 255, 0.42);
    --border: rgba(255, 255, 255, 0.72);
    --border-strong: rgba(96, 116, 168, 0.22);
    --text: #11182b;
    --muted: #53617d;
    --subtle: #71809c;
    --blue: #246dde;
    --cyan: #007fa8;
    --violet: #6840c7;
    --green: #16865d;
    --orange: #b86700;
    --red: #c12e5e;
    --shadow: 0 22px 60px rgba(40, 59, 108, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    scroll-behavior: smooth;
}

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    background: var(--bg);
    color: var(--text);
    font-family: "Manrope", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
}

button,
input,
select {
    font: inherit;
}

button {
    color: inherit;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

.site-background {
    position: fixed;
    z-index: -2;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    background:
        radial-gradient(circle at 10% -5%, rgba(78, 128, 255, 0.19), transparent 32rem),
        radial-gradient(circle at 90% 8%, rgba(175, 104, 255, 0.15), transparent 30rem),
        radial-gradient(circle at 48% 108%, rgba(42, 216, 186, 0.10), transparent 32rem),
        var(--bg);
}

.ambient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(72px);
    opacity: 0.42;
    animation: drift 20s ease-in-out infinite alternate;
}

.ambient-orb--one {
    top: 9%;
    left: -10rem;
    width: 28rem;
    height: 28rem;
    background: #3a85ff;
}

.ambient-orb--two {
    top: 31%;
    right: -12rem;
    width: 31rem;
    height: 31rem;
    background: #9b63ff;
    animation-delay: -7s;
}

.ambient-orb--three {
    bottom: -14rem;
    left: 28%;
    width: 32rem;
    height: 32rem;
    background: #27d5bb;
    opacity: 0.20;
    animation-delay: -13s;
}

.grid-noise {
    position: absolute;
    inset: 0;
    opacity: 0.13;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent 72%);
}

.site-header {
    position: sticky;
    z-index: 100;
    top: 18px;
    width: var(--container);
    margin: 18px auto 0;
}

.site-nav {
    display: flex;
    align-items: center;
    min-height: 64px;
    gap: 20px;
    padding: 8px 10px 8px 16px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.brand-mark {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.27);
    border-radius: 12px;
    background: linear-gradient(145deg, rgba(106, 171, 255, 0.92), rgba(155, 97, 255, 0.88));
    box-shadow: 0 8px 20px rgba(87, 126, 255, 0.28), inset 0 1px 1px rgba(255, 255, 255, 0.52);
    color: #fff;
    font-family: "DM Mono", monospace;
    font-size: 15px;
}

.nav-links {
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: center;
    gap: 4px;
    min-width: 0;
}

.nav-links a,
.mobile-nav a {
    padding: 8px 11px;
    border-radius: 12px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
    transition: color 180ms ease, background 180ms ease, transform 180ms ease;
}

.nav-links a:hover,
.nav-links a[aria-current="page"],
.mobile-nav a:hover {
    background: rgba(128, 170, 255, 0.13);
    color: var(--text);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
}

.theme-toggle,
.menu-toggle {
    display: inline-grid;
    width: 38px;
    height: 38px;
    place-items: center;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.06);
    cursor: pointer;
    transition: transform 180ms ease, background 180ms ease;
}

.theme-toggle:hover,
.menu-toggle:hover {
    background: rgba(255, 255, 255, 0.14);
    transform: translateY(-1px);
}

.theme-toggle span {
    font-size: 18px;
    line-height: 1;
}

.nav-cta,
.button {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 15px;
    border: 1px solid rgba(157, 203, 255, 0.40);
    border-radius: 13px;
    background: linear-gradient(135deg, rgba(67, 133, 255, 0.94), rgba(142, 84, 243, 0.94));
    box-shadow: 0 10px 25px rgba(77, 120, 255, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.35);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    transition: transform 180ms ease, filter 180ms ease, box-shadow 180ms ease;
}

.nav-cta:hover,
.button:hover {
    box-shadow: 0 14px 34px rgba(77, 120, 255, 0.38), inset 0 1px 1px rgba(255, 255, 255, 0.38);
    filter: brightness(1.08);
    transform: translateY(-2px);
}

.button--secondary {
    border-color: var(--border);
    background: rgba(255, 255, 255, 0.075);
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.15);
    color: var(--text);
}

.button--secondary:hover {
    background: rgba(255, 255, 255, 0.14);
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.18);
}

.button:disabled {
    cursor: not-allowed;
    filter: grayscale(0.5);
    opacity: 0.5;
    transform: none;
}

.menu-toggle {
    display: none;
}

.menu-toggle span {
    display: block;
    width: 17px;
    height: 2px;
    border-radius: 5px;
    background: currentColor;
    transition: transform 180ms ease, opacity 180ms ease;
}

.menu-toggle {
    gap: 4px;
    align-content: center;
}

.menu-toggle.is-open span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.menu-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-open span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

.mobile-nav {
    display: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    margin-top: 10px;
    padding: 10px;
}

.mobile-nav.is-open {
    display: grid;
}

.site-main {
    width: 100%;
    min-height: calc(100vh - 260px);
    padding: 72px 0 84px;
}

.page-shell,
.hero,
.section {
    width: var(--container);
    margin: 0 auto;
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
    align-items: center;
    gap: 28px;
    padding: 56px 0 36px;
}

.hero--single {
    display: block;
    padding-bottom: 20px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 16px;
    color: var(--cyan);
    font-family: "DM Mono", monospace;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.eyebrow::before {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 16px currentColor;
    content: "";
}

.hero h1,
.page-title {
    max-width: 820px;
    margin: 0;
    font-size: clamp(42px, 7vw, 78px);
    font-weight: 800;
    letter-spacing: -0.075em;
    line-height: 0.98;
}

.hero h1 span,
.gradient-text {
    background: linear-gradient(110deg, var(--text) 12%, var(--blue) 58%, var(--violet) 94%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-copy,
.page-lead {
    max-width: 650px;
    margin: 22px 0 0;
    color: var(--muted);
    font-size: clamp(16px, 2vw, 19px);
    line-height: 1.75;
}

.hero-actions,
.button-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.hero-panel,
.featured-card,
.content-panel,
.list-card,
.detail-sidebar,
.ad-slot {
    border-radius: var(--radius-xl);
}

.hero-panel {
    min-height: 390px;
    padding: 28px;
    overflow: hidden;
}

.hero-panel__glow {
    position: absolute;
    width: 15rem;
    height: 15rem;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(115, 195, 255, 0.55), transparent 66%);
    filter: blur(10px);
    pointer-events: none;
}

.hero-panel__content {
    position: relative;
    z-index: 1;
    display: flex;
    min-height: 332px;
    flex-direction: column;
    justify-content: flex-end;
}

.hero-panel__meta,
.chips,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pill,
.hero-panel__meta span,
.card-meta span {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    background: rgba(7, 10, 19, 0.30);
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.hero-panel h2 {
    margin: 15px 0 8px;
    font-size: clamp(26px, 3vw, 34px);
    letter-spacing: -0.055em;
    line-height: 1.05;
}

.hero-panel p {
    max-width: 430px;
    margin: 0;
    color: var(--muted);
}

.section {
    padding-top: 72px;
}

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 26px;
}

.section-heading h2 {
    max-width: 700px;
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    letter-spacing: -0.06em;
    line-height: 1.08;
}

.section-heading p {
    max-width: 560px;
    margin: 10px 0 0;
    color: var(--muted);
}

.text-link {
    flex-shrink: 0;
    color: var(--blue);
    font-size: 13px;
    font-weight: 800;
}

.text-link:hover {
    color: var(--cyan);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.card-grid--two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.list-card {
    position: relative;
    display: flex;
    min-width: 0;
    flex-direction: column;
    overflow: hidden;
    transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.list-card:hover {
    border-color: rgba(139, 190, 255, 0.42);
    box-shadow: 0 28px 68px rgba(0, 0, 0, 0.28);
    transform: translateY(-6px);
}

.card-image {
    position: relative;
    min-height: 180px;
    overflow: hidden;
    background:
        linear-gradient(145deg, rgba(72, 131, 255, 0.54), rgba(143, 74, 255, 0.34)),
        #111827;
}

.card-image img {
    width: 100%;
    height: 100%;
    min-height: 180px;
    object-fit: cover;
    transition: transform 420ms ease;
}

.list-card:hover .card-image img {
    transform: scale(1.06);
}

.card-image__fallback {
    display: grid;
    min-height: 180px;
    place-items: center;
    color: rgba(255, 255, 255, 0.82);
    font-family: "DM Mono", monospace;
    font-size: 36px;
}

.card-body {
    display: flex;
    flex: 1;
    min-width: 0;
    flex-direction: column;
    padding: 20px;
}

.card-body h3 {
    margin: 12px 0 8px;
    font-size: 19px;
    letter-spacing: -0.04em;
    line-height: 1.25;
}

.card-body p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    padding-top: 20px;
}

.status {
    display: inline-flex;
    width: max-content;
    align-items: center;
    padding: 5px 9px;
    border: 1px solid currentColor;
    border-radius: 999px;
    background: color-mix(in srgb, currentColor 10%, transparent);
    color: var(--blue);
    font-family: "DM Mono", monospace;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.status--stable,
.status--released {
    color: var(--green);
}

.status--beta,
.status--in-development {
    color: var(--orange);
}

.status--experimental,
.status--prototype {
    color: var(--violet);
}

.filters {
    display: grid;
    grid-template-columns: 1.8fr repeat(3, minmax(120px, 1fr));
    gap: 10px;
    margin-bottom: 22px;
    padding: 12px;
    border-radius: 20px;
}

.field {
    width: 100%;
    min-height: 44px;
    padding: 0 13px;
    border: 1px solid var(--border);
    border-radius: 13px;
    outline: none;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
    font-size: 13px;
}

.field:focus {
    border-color: rgba(111, 176, 255, 0.72);
    box-shadow: 0 0 0 4px rgba(101, 159, 255, 0.12);
}

select.field option {
    background: #121926;
    color: #fff;
}

.empty-state,
.loading-state,
.error-state {
    grid-column: 1 / -1;
    padding: 56px 20px;
    border: 1px dashed var(--border);
    border-radius: var(--radius-lg);
    color: var(--muted);
    text-align: center;
}

.site-footer {
    width: var(--container);
    margin: 0 auto;
    padding: 0 0 28px;
}

.footer-inner {
    display: grid;
    grid-template-columns: 1.3fr auto;
    gap: 24px;
    padding: 26px;
}

.footer-inner p {
    max-width: 470px;
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 13px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-content: start;
    gap: 8px 16px;
}

.footer-links a {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.footer-links a:hover {
    color: var(--text);
}

.footer-copy {
    grid-column: 1 / -1;
    margin-top: 4px !important;
    padding-top: 17px;
    border-top: 1px solid var(--border);
    font-size: 12px !important;
}

.prose {
    color: var(--muted);
    font-size: 16px;
    line-height: 1.82;
}

.prose> :first-child {
    margin-top: 0;
}

.prose h1,
.prose h2,
.prose h3,
.prose h4 {
    color: var(--text);
    letter-spacing: -0.04em;
    line-height: 1.2;
}

.prose h1 {
    font-size: 34px;
}

.prose h2 {
    margin-top: 42px;
    font-size: 25px;
}

.prose h3 {
    margin-top: 28px;
    font-size: 20px;
}

.prose a {
    color: var(--blue);
    text-decoration: underline;
    text-decoration-color: rgba(114, 168, 255, 0.35);
    text-underline-offset: 3px;
}

.prose code {
    padding: 2px 6px;
    border: 1px solid rgba(124, 168, 255, 0.20);
    border-radius: 6px;
    background: rgba(113, 158, 255, 0.10);
    color: var(--cyan);
    font-family: "DM Mono", monospace;
    font-size: 0.84em;
}

.prose pre {
    position: relative;
    overflow-x: auto;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 16px;
    background: #080c15;
}

.prose pre code {
    padding: 0;
    border: 0;
    background: transparent;
    color: #dce8ff;
}

.prose blockquote {
    margin: 24px 0;
    padding: 12px 18px;
    border-left: 3px solid var(--cyan);
    border-radius: 0 12px 12px 0;
    background: rgba(105, 232, 255, 0.07);
    color: var(--text);
}

.prose table {
    display: block;
    overflow-x: auto;
    width: 100%;
    border-collapse: collapse;
    margin: 22px 0;
    font-size: 14px;
}

.prose th,
.prose td {
    min-width: 120px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    text-align: left;
}

.prose th {
    background: rgba(255, 255, 255, 0.07);
    color: var(--text);
}

.prose img {
    margin: 24px 0;
    border-radius: 18px;
}

.copy-code {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 6px 9px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.08);
    color: #d5e3ff;
    cursor: pointer;
    font-size: 11px;
    font-weight: 800;
}

.copy-code:hover {
    background: rgba(255, 255, 255, 0.16);
}

@keyframes drift {
    from {
        transform: translate3d(0, 0, 0) scale(0.96);
    }

    to {
        transform: translate3d(44px, -30px, 0) scale(1.08);
    }
}

@media (max-width: 980px) {

    .nav-links,
    .nav-cta {
        display: none;
    }

    .menu-toggle {
        display: grid;
    }

    .hero {
        grid-template-columns: 1fr;
        padding-top: 38px;
    }

    .hero-panel {
        min-height: 300px;
    }

    .hero-panel__content {
        min-height: 242px;
    }

    .card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filters .field:first-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 620px) {
    :root {
        --container: min(100% - 24px);
    }

    .site-header {
        top: 10px;
        margin-top: 10px;
    }

    .site-nav {
        min-height: 58px;
        padding-left: 12px;
    }

    .brand {
        font-size: 14px;
    }

    .brand-mark {
        width: 31px;
        height: 31px;
        border-radius: 10px;
    }

    .site-main {
        padding-top: 38px;
    }

    .hero {
        gap: 20px;
        padding-top: 28px;
    }

    .hero h1,
    .page-title {
        font-size: clamp(40px, 13vw, 59px);
    }

    .hero-panel {
        min-height: 270px;
        padding: 20px;
    }

    .section {
        padding-top: 50px;
    }

    .section-heading {
        align-items: start;
        flex-direction: column;
        gap: 12px;
    }

    .card-grid,
    .card-grid--two,
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .filters {
        grid-template-columns: 1fr;
    }

    .filters .field:first-child {
        grid-column: auto;
    }

    .footer-links {
        justify-content: flex-start;
    }

    .footer-copy {
        grid-column: auto;
    }

    .mobile-nav {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Global visual consistency: shared rounded surfaces */
.site-nav,
.mobile-nav,
.footer-inner,
.page-header__inner,
.hero-panel,
.content-panel,
.list-card,
.filters,
.source-note,
.reader-content,
.reader-aside,
.access-panel,
.ad-slot,
.detail-main,
.detail-sidebar,
.oc-sidebar,
.oc-content,
.guide-library-card,
.playlist-card {
    border-radius: var(--radius-xl);
    overflow: hidden;
}

/* Keep internal content panels rounded without clipping scrolling content */
.reader-content,
.oc-content {
    overflow-x: hidden;
    overflow-y: auto;
}

/* Uniform rounded media corners */
.card-image,
.card-image img,
.card-image__fallback,
.detail-hero-image,
.detail-hero-image img,
.guide-library-card__visual,
.video-card .card-image,
.video-card .card-image img {
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

/* Media fills the card while the outer card owns the final clipping */
.list-card .card-image,
.list-card .card-image img {
    border-radius: 0;
}

/* Inputs and interactive controls */
.field,
.button,
.nav-cta,
.theme-toggle,
.menu-toggle,
.copy-code,
.oc-nav-btn,
.oc-source,
.status,
.tag,
.pill,
.card-meta span,
.hero-panel__meta span {
    border-radius: 14px;
}

/* Pills remain fully pill-shaped */
.status,
.tag,
.pill,
.card-meta span,
.hero-panel__meta span,
.oc-source {
    border-radius: 999px;
}

/* Consistent border/color on all primary glass surfaces */
:root[data-theme="light"] .liquid-glass,
:root[data-theme="light"] .source-note,
:root[data-theme="light"] .filters {
    border-color: rgba(126, 148, 202, 0.18);
}

:root[data-theme="dark"] .liquid-glass,
:root[data-theme="dark"] .source-note,
:root[data-theme="dark"] .filters {
    border-color: rgba(255, 255, 255, 0.13);
}

.page-header__inner {
    border-radius: var(--radius-xl) !important;
    overflow: hidden;
}

.page-header__inner::before,
.page-header__inner::after {
    border-radius: inherit;
}

/* =========================================================
   Global scrollbar hiding
   Keeps mouse wheel, trackpad, keyboard, and touch scrolling.
   ========================================================= */

html,
body {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

