/* =========================================================
   COSMOVERSE 3.0
   STYLE.CSS — PART 1
   Global Theme • Background • Navigation • Hero • Cards
========================================================= */


/* =========================================================
   1. CSS VARIABLES
========================================================= */

:root {
    --bg-main: #030712;
    --bg-secondary: #07101f;
    --bg-card: rgba(10, 20, 40, 0.72);
    --bg-card-solid: #0b1629;
    --bg-glass: rgba(8, 18, 38, 0.72);

    --text-main: #f4f8ff;
    --text-secondary: #aebbd0;
    --text-muted: #74839b;

    --blue: #4da3ff;
    --blue-bright: #6ec8ff;
    --cyan: #42e8ff;
    --purple: #9b6cff;
    --pink: #e66cff;
    --green: #55e6a5;
    --yellow: #ffd166;
    --red: #ff647c;

    --border: rgba(150, 190, 255, 0.15);
    --border-bright: rgba(105, 200, 255, 0.42);

    --shadow-small:
        0 8px 30px rgba(0, 0, 0, 0.25);

    --shadow-large:
        0 25px 80px rgba(0, 0, 0, 0.45);

    --glow-blue:
        0 0 20px rgba(77, 163, 255, 0.35);

    --glow-cyan:
        0 0 30px rgba(66, 232, 255, 0.3);

    --radius-small: 12px;
    --radius-medium: 20px;
    --radius-large: 30px;

    --max-width: 1400px;

    --transition:
        0.25s ease;
}


/* =========================================================
   2. RESET
========================================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}


body {
    min-height: 100vh;

    background:
        radial-gradient(
            circle at 20% 20%,
            rgba(37, 80, 180, 0.12),
            transparent 35%
        ),
        radial-gradient(
            circle at 80% 30%,
            rgba(132, 70, 220, 0.1),
            transparent 35%
        ),
        var(--bg-main);

    color: var(--text-main);

    font-family:
        Inter,
        "Segoe UI",
        Arial,
        sans-serif;

    line-height: 1.6;

    overflow-x: hidden;
}


body.menu-open {
    overflow: hidden;
}


button,
input,
select,
textarea {
    font: inherit;
}


button,
a {
    -webkit-tap-highlight-color: transparent;
}


button {
    color: inherit;
}


a {
    color: inherit;
    text-decoration: none;
}


img {
    display: block;
    max-width: 100%;
}


::selection {
    background: rgba(77, 163, 255, 0.35);
    color: white;
}


/* =========================================================
   3. SCROLLBAR
========================================================= */

::-webkit-scrollbar {
    width: 10px;
}


::-webkit-scrollbar-track {
    background: #02050b;
}


::-webkit-scrollbar-thumb {
    background:
        linear-gradient(
            var(--blue),
            var(--purple)
        );

    border-radius: 999px;
}


::-webkit-scrollbar-thumb:hover {
    background:
        linear-gradient(
            var(--cyan),
            var(--purple)
        );
}


/* =========================================================
   4. LOADING SCREEN
========================================================= */

.loading-screen {
    position: fixed;
    inset: 0;

    z-index: 99999;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 18px;

    background:
        radial-gradient(
            circle at center,
            #0d2045 0%,
            #050b18 45%,
            #01030a 100%
        );

    transition:
        opacity 0.7s ease,
        visibility 0.7s ease;
}


.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}


.loading-screen h1 {
    font-size: clamp(2rem, 6vw, 4rem);

    letter-spacing: 0.25em;

    background:
        linear-gradient(
            90deg,
            white,
            var(--cyan),
            var(--purple)
        );

    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}


.loading-screen p {
    color: var(--text-secondary);
}


.loading-space {
    position: relative;

    width: 140px;
    height: 140px;

    display: grid;
    place-items: center;
}


.loading-planet {
    font-size: 58px;

    animation:
        loadingPlanetFloat
        2.5s ease-in-out infinite;
}


.loading-orbit {
    position: absolute;
    inset: 5px;

    border:
        1px solid
        rgba(110, 200, 255, 0.3);

    border-radius: 50%;

    animation:
        loadingOrbit
        3s linear infinite;
}


.loading-spacecraft {
    position: absolute;

    top: -15px;
    left: 50%;

    font-size: 24px;

    transform:
        translateX(-50%)
        rotate(90deg);
}


.loading-bar {
    width: min(300px, 75vw);
    height: 6px;

    overflow: hidden;

    border-radius: 999px;

    background:
        rgba(255, 255, 255, 0.08);
}


.loading-progress {
    width: 45%;
    height: 100%;

    border-radius: inherit;

    background:
        linear-gradient(
            90deg,
            var(--blue),
            var(--cyan),
            var(--purple)
        );

    animation:
        loadingProgress
        1.5s ease-in-out infinite;
}


/* =========================================================
   5. SPACE BACKGROUND
========================================================= */

.space-background {
    position: fixed;
    inset: 0;

    z-index: -10;

    overflow: hidden;

    pointer-events: none;

    background:
        linear-gradient(
            180deg,
            #02040a 0%,
            #040817 45%,
            #02040b 100%
        );
}


.stars {
    position: absolute;
    inset: -50%;

    background-repeat: repeat;

    transform-origin: center;

    pointer-events: none;
}


.stars-small {
    background-image:
        radial-gradient(
            circle,
            rgba(255,255,255,0.9) 1px,
            transparent 1.5px
        );

    background-size:
        55px 55px;

    opacity: 0.35;

    animation:
        starDrift
        150s linear infinite;
}


.stars-medium {
    background-image:
        radial-gradient(
            circle,
            rgba(135,205,255,0.9) 1.2px,
            transparent 2px
        );

    background-size:
        100px 100px;

    opacity: 0.3;

    animation:
        starDriftReverse
        210s linear infinite;
}


.stars-large {
    background-image:
        radial-gradient(
            circle,
            rgba(255,255,255,1) 1.6px,
            transparent 2.5px
        );

    background-size:
        180px 180px;

    opacity: 0.22;

    animation:
        starPulse
        5s ease-in-out infinite;
}


.space-nebula {
    position: absolute;

    width: 700px;
    height: 700px;

    border-radius: 50%;

    filter: blur(120px);

    opacity: 0.12;
}


.nebula-one {
    top: -300px;
    left: -250px;

    background:
        var(--blue);
}


.nebula-two {
    right: -350px;
    top: 35%;

    background:
        var(--purple);
}


/* =========================================================
   6. MAIN PAGE LAYOUT
========================================================= */

main {
    position: relative;
    z-index: 1;
}


section {
    position: relative;

    width: min(
        calc(100% - 40px),
        var(--max-width)
    );

    margin-inline: auto;

    padding:
        100px 0;
}


.section-heading {
    max-width: 800px;

    margin:
        0 auto 55px;

    text-align: center;
}


.section-label {
    display: inline-block;

    margin-bottom: 12px;

    color: var(--cyan);

    font-size: 0.78rem;
    font-weight: 800;

    letter-spacing: 0.18em;

    text-transform: uppercase;
}


.section-heading h2 {
    margin-bottom: 16px;

    font-size:
        clamp(
            2rem,
            5vw,
            3.5rem
        );

    line-height: 1.1;

    letter-spacing: -0.04em;
}


.section-heading p {
    color: var(--text-secondary);

    font-size: 1.05rem;
}


.subsection-heading {
    margin-bottom: 28px;
}


.subsection-heading span {
    color: var(--cyan);

    font-size: 0.78rem;
    font-weight: 800;

    letter-spacing: 0.15em;
}


.subsection-heading h3 {
    margin-top: 8px;

    font-size:
        clamp(
            1.6rem,
            3vw,
            2.3rem
        );
}


/* =========================================================
   7. HEADER
========================================================= */

.main-header {
    position: fixed;

    top: 0;
    left: 0;
    right: 0;

    z-index: 5000;

    padding:
        12px 20px;

    pointer-events: none;
}


.navbar {
    width: min(
        100%,
        1500px
    );

    min-height: 68px;

    margin-inline: auto;

    padding:
        10px 14px 10px 20px;

    display: flex;
    align-items: center;

    gap: 24px;

    border:
        1px solid
        rgba(145, 190, 255, 0.14);

    border-radius: 22px;

    background:
        rgba(4, 10, 24, 0.72);

    backdrop-filter:
        blur(22px);

    -webkit-backdrop-filter:
        blur(22px);

    box-shadow:
        0 12px 40px
        rgba(0, 0, 0, 0.25);

    pointer-events: auto;
}


.logo {
    display: flex;
    align-items: center;

    gap: 9px;

    flex-shrink: 0;

    font-size: 1.15rem;
    font-weight: 800;

    letter-spacing: -0.03em;
}


.logo-icon {
    font-size: 1.6rem;

    filter:
        drop-shadow(
            0 0 12px
            rgba(100, 180, 255, 0.55)
        );
}


.nav-links {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 4px;

    margin-inline: auto;
}


.nav-links a {
    padding:
        9px 11px;

    border-radius: 10px;

    color: var(--text-secondary);

    font-size: 0.88rem;
    font-weight: 600;

    transition:
        color var(--transition),
        background var(--transition),
        transform var(--transition);
}


.nav-links a:hover {
    color: white;

    background:
        rgba(255, 255, 255, 0.07);

    transform:
        translateY(-1px);
}


.nav-actions {
    display: flex;
    align-items: center;

    gap: 7px;
}


.nav-icon-button,
.mobile-menu-button {
    width: 42px;
    height: 42px;

    display: grid;
    place-items: center;

    border:
        1px solid
        var(--border);

    border-radius: 12px;

    background:
        rgba(255, 255, 255, 0.04);

    cursor: pointer;

    transition:
        transform var(--transition),
        border-color var(--transition),
        background var(--transition);
}


.nav-icon-button:hover,
.mobile-menu-button:hover {
    transform:
        translateY(-2px);

    border-color:
        var(--border-bright);

    background:
        rgba(90, 170, 255, 0.1);
}


.mobile-menu-button {
    display: none;
}


.ai-nav-button {
    min-height: 42px;

    padding:
        0 16px;

    border:
        1px solid
        rgba(99, 208, 255, 0.3);

    border-radius: 12px;

    background:
        linear-gradient(
            135deg,
            rgba(50, 125, 255, 0.2),
            rgba(145, 80, 255, 0.18)
        );

    color: white;

    font-weight: 700;

    cursor: pointer;

    transition:
        transform var(--transition),
        box-shadow var(--transition),
        border-color var(--transition);
}


.ai-nav-button:hover {
    transform:
        translateY(-2px);

    border-color:
        rgba(99, 208, 255, 0.65);

    box-shadow:
        var(--glow-blue);
}


/* =========================================================
   8. BUTTONS
========================================================= */

.primary-button,
.secondary-button,
.mission-details-button {
    min-height: 48px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    padding:
        12px 20px;

    border-radius:
        14px;

    font-weight: 750;

    cursor: pointer;

    transition:
        transform var(--transition),
        box-shadow var(--transition),
        border-color var(--transition),
        background var(--transition);
}


.primary-button {
    border:
        1px solid
        rgba(100, 210, 255, 0.55);

    background:
        linear-gradient(
            135deg,
            #1878ff,
            #7857ff
        );

    color: white;

    box-shadow:
        0 10px 35px
        rgba(50, 100, 255, 0.24);
}


.primary-button:hover {
    transform:
        translateY(-3px);

    box-shadow:
        0 15px 45px
        rgba(70, 125, 255, 0.38);
}


.secondary-button {
    border:
        1px solid
        var(--border-bright);

    background:
        rgba(255, 255, 255, 0.045);

    color: white;
}


.secondary-button:hover {
    transform:
        translateY(-3px);

    background:
        rgba(80, 170, 255, 0.1);

    box-shadow:
        var(--glow-blue);
}


/* =========================================================
   9. HERO
========================================================= */

.hero-section {
    min-height: 100vh;

    padding-top:
        150px;

    display: grid;

    grid-template-columns:
        minmax(0, 1.05fr)
        minmax(420px, 0.95fr);

    align-items: center;

    gap: 70px;
}


.hero-content {
    position: relative;

    z-index: 5;
}


.hero-badge {
    width: fit-content;

    margin-bottom: 24px;

    padding:
        8px 13px;

    border:
        1px solid
        rgba(70, 220, 255, 0.25);

    border-radius:
        999px;

    background:
        rgba(60, 180, 255, 0.07);

    color: var(--cyan);

    font-size: 0.75rem;
    font-weight: 800;

    letter-spacing:
        0.14em;
}


.hero-content h1 {
    max-width: 800px;

    font-size:
        clamp(
            4rem,
            8vw,
            7.8rem
        );

    line-height:
        0.92;

    letter-spacing:
        -0.07em;
}


.hero-content h1 span {
    display: block;

    margin-top: 8px;

    background:
        linear-gradient(
            90deg,
            #63d8ff,
            #698cff,
            #b576ff,
            #ff80d5
        );

    -webkit-background-clip: text;
    background-clip: text;

    color: transparent;

    filter:
        drop-shadow(
            0 0 24px
            rgba(90, 150, 255, 0.22)
        );
}


.hero-description {
    max-width: 680px;

    margin-top: 28px;

    color:
        var(--text-secondary);

    font-size:
        clamp(
            1rem,
            2vw,
            1.2rem
        );
}


.hero-buttons {
    display: flex;
    flex-wrap: wrap;

    gap: 12px;

    margin-top: 32px;
}


.hero-stats {
    display: flex;
    flex-wrap: wrap;

    gap: 15px;

    margin-top: 48px;
}


.hero-stat {
    min-width: 135px;

    padding:
        16px 20px;

    border:
        1px solid
        var(--border);

    border-radius:
        16px;

    background:
        rgba(255, 255, 255, 0.035);

    backdrop-filter:
        blur(10px);
}


.hero-stat strong {
    display: block;

    color:
        var(--blue-bright);

    font-size:
        1.55rem;
}


.hero-stat span {
    color:
        var(--text-secondary);

    font-size:
        0.8rem;
}


/* =========================================================
   10. HERO UNIVERSE
========================================================= */

.hero-universe {
    position: relative;

    width: min(
        620px,
        100%
    );

    aspect-ratio:
        1 / 1;

    margin-inline:
        auto;

    border-radius:
        50%;

    background:
        radial-gradient(
            circle,
            rgba(70, 130, 255, 0.09),
            transparent 65%
        );

    perspective:
        900px;
}


.hero-universe::before,
.hero-universe::after {
    content: "";

    position: absolute;

    border:
        1px solid
        rgba(100, 180, 255, 0.12);

    border-radius:
        50%;

    transform:
        rotateX(68deg);
}


.hero-universe::before {
    inset: 10%;
}


.hero-universe::after {
    inset: 25%;
}


.hero-sun {
    position: absolute;

    top: 50%;
    left: 50%;

    z-index: 3;

    font-size:
        clamp(
            75px,
            10vw,
            125px
        );

    transform:
        translate(-50%, -50%);

    filter:
        drop-shadow(
            0 0 25px
            rgba(255, 190, 60, 0.8)
        )
        drop-shadow(
            0 0 70px
            rgba(255, 120, 30, 0.35)
        );

    animation:
        sunPulse
        4s ease-in-out infinite;
}


.hero-earth-orbit {
    position: absolute;

    inset: 15%;

    border-radius:
        50%;

    animation:
        heroOrbit
        18s linear infinite;
}


.hero-earth {
    position: absolute;

    top: 50%;
    left: -18px;

    font-size:
        50px;

    transform:
        translateY(-50%);

    filter:
        drop-shadow(
            0 0 16px
            rgba(80, 170, 255, 0.55)
        );

    animation:
        planetFloat
        3s ease-in-out infinite;
}


.hero-saturn {
    position: absolute;

    right: 0;
    top: 15%;

    font-size:
        70px;

    filter:
        drop-shadow(
            0 0 15px
            rgba(255, 205, 120, 0.25)
        );

    animation:
        planetFloat
        4.5s ease-in-out infinite;
}


.floating-astronaut {
    position: absolute;

    left: 10%;
    bottom: 12%;

    font-size:
        55px;

    animation:
        astronautFloat
        6s ease-in-out infinite;
}


/* =========================================================
   11. EXPLORE SECTION
========================================================= */

.explore-section {
    padding-top:
        70px;
}


.explore-grid {
    display: grid;

    grid-template-columns:
        repeat(
            5,
            minmax(0, 1fr)
        );

    gap: 16px;
}


.explore-card {
    position: relative;

    min-height: 225px;

    overflow: hidden;

    padding:
        25px;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-medium);

    background:
        linear-gradient(
            145deg,
            rgba(15, 29, 55, 0.82),
            rgba(6, 14, 29, 0.82)
        );

    box-shadow:
        var(--shadow-small);

    transition:
        transform var(--transition),
        border-color var(--transition),
        box-shadow var(--transition);
}


.explore-card::before {
    content: "";

    position: absolute;

    width: 140px;
    height: 140px;

    right: -60px;
    top: -70px;

    border-radius:
        50%;

    background:
        var(--blue);

    opacity:
        0.06;

    filter:
        blur(20px);

    transition:
        opacity var(--transition),
        transform var(--transition);
}


.explore-card:hover {
    transform:
        translateY(-7px);

    border-color:
        rgba(100, 195, 255, 0.45);

    box-shadow:
        0 20px 50px
        rgba(0, 0, 0, 0.35),
        0 0 25px
        rgba(60, 150, 255, 0.08);
}


.explore-card:hover::before {
    opacity:
        0.16;

    transform:
        scale(1.3);
}


.explore-icon {
    position: relative;

    z-index: 2;

    margin-bottom:
        20px;

    font-size:
        42px;

    transition:
        transform var(--transition);
}


.explore-card:hover
.explore-icon {
    transform:
        translateY(-4px)
        scale(1.08);
}


.explore-card h3 {
    position: relative;

    z-index: 2;

    margin-bottom:
        8px;

    font-size:
        1.08rem;
}


.explore-card p {
    position: relative;

    z-index: 2;

    color:
        var(--text-secondary);

    font-size:
        0.9rem;
}


/* =========================================================
   12. COMMON GLASS CARDS
========================================================= */

.real-data-badge {
    display: inline-block;

    margin-bottom:
        10px;

    padding:
        5px 9px;

    border:
        1px solid
        rgba(70, 220, 255, 0.2);

    border-radius:
        7px;

    background:
        rgba(40, 190, 255, 0.07);

    color:
        var(--cyan);

    font-size:
        0.68rem;

    font-weight:
        800;

    letter-spacing:
        0.12em;
}


.real-fact-box {
    margin-top:
        25px;

    padding:
        18px;

    border:
        1px solid
        rgba(70, 220, 255, 0.16);

    border-radius:
        14px;

    background:
        rgba(50, 175, 255, 0.055);
}


.real-fact-box span {
    color:
        var(--cyan);

    font-size:
        0.72rem;

    font-weight:
        800;

    letter-spacing:
        0.12em;
}


.real-fact-box p {
    margin-top:
        7px;

    color:
        var(--text-secondary);
}


.fact-stat-grid {
    display: grid;

    grid-template-columns:
        repeat(
            3,
            minmax(0, 1fr)
        );

    gap:
        10px;

    margin-top:
        25px;
}


.fact-stat-grid > div {
    padding:
        16px;

    border:
        1px solid
        var(--border);

    border-radius:
        13px;

    background:
        rgba(255, 255, 255, 0.025);
}


.fact-stat-grid span {
    display:
        block;

    margin-bottom:
        4px;

    color:
        var(--text-muted);

    font-size:
        0.72rem;

    text-transform:
        uppercase;

    letter-spacing:
        0.08em;
}


.fact-stat-grid strong {
    color:
        var(--text-main);

    font-size:
        0.95rem;
}


/* =========================================================
   13. BASIC FORM ELEMENTS
========================================================= */

select,
input {
    border:
        1px solid
        var(--border);

    border-radius:
        12px;

    outline:
        none;

    background:
        rgba(3, 10, 23, 0.85);

    color:
        var(--text-main);

    transition:
        border-color var(--transition),
        box-shadow var(--transition);
}


select {
    min-height:
        48px;

    padding:
        0 14px;
}


input {
    min-height:
        48px;

    padding:
        0 15px;
}


select:focus,
input:focus {
    border-color:
        var(--blue-bright);

    box-shadow:
        0 0 0 3px
        rgba(80, 170, 255, 0.12);
}


/* =========================================================
   14. KEYFRAMES
========================================================= */

@keyframes loadingPlanetFloat {

    0%,
    100% {
        transform:
            translateY(0)
            rotate(-3deg);
    }

    50% {
        transform:
            translateY(-10px)
            rotate(3deg);
    }
}


@keyframes loadingOrbit {

    from {
        transform:
            rotate(0deg);
    }

    to {
        transform:
            rotate(360deg);
    }
}


@keyframes loadingProgress {

    0% {
        transform:
            translateX(-120%);
    }

    100% {
        transform:
            translateX(250%);
    }
}


@keyframes starDrift {

    from {
        transform:
            translate3d(0, 0, 0);
    }

    to {
        transform:
            translate3d(
                250px,
                150px,
                0
            );
    }
}


@keyframes starDriftReverse {

    from {
        transform:
            translate3d(0, 0, 0);
    }

    to {
        transform:
            translate3d(
                -200px,
                120px,
                0
            );
    }
}


@keyframes starPulse {

    0%,
    100% {
        opacity:
            0.15;
    }

    50% {
        opacity:
            0.32;
    }
}


@keyframes sunPulse {

    0%,
    100% {
        transform:
            translate(-50%, -50%)
            scale(1);
    }

    50% {
        transform:
            translate(-50%, -50%)
            scale(1.06);
    }
}


@keyframes heroOrbit {

    from {
        transform:
            rotate(0deg);
    }

    to {
        transform:
            rotate(360deg);
    }
}


@keyframes planetFloat {

    0%,
    100% {
        transform:
            translateY(-50%)
            rotate(-3deg);
    }

    50% {
        transform:
            translateY(
                calc(-50% - 10px)
            )
            rotate(3deg);
    }
}


@keyframes astronautFloat {

    0%,
    100% {
        transform:
            translate(0, 0)
            rotate(-8deg);
    }

    50% {
        transform:
            translate(18px, -22px)
            rotate(8deg);
    }
}


/* =========================================================
   15. RESPONSIVE — PART 1
========================================================= */

@media
(max-width: 1200px) {

    .nav-links {
        gap:
            0;
    }

    .nav-links a {
        padding:
            8px;
    }


    .hero-section {
        grid-template-columns:
            1fr 0.8fr;

        gap:
            30px;
    }


    .explore-grid {
        grid-template-columns:
            repeat(
                3,
                minmax(0, 1fr)
            );
    }
}


@media
(max-width: 950px) {

    .mobile-menu-button {
        display:
            grid;

        margin-left:
            auto;
    }


    .nav-links {
        position:
            fixed;

        top:
            94px;

        left:
            20px;

        right:
            20px;

        display:
            none;

        flex-direction:
            column;

        align-items:
            stretch;

        padding:
            14px;

        border:
            1px solid
            var(--border);

        border-radius:
            18px;

        background:
            rgba(4, 10, 24, 0.96);

        backdrop-filter:
            blur(25px);

        box-shadow:
            var(--shadow-large);
    }


    .nav-links.open {
        display:
            flex;
    }


    .nav-links a {
        padding:
            13px 15px;
    }


    .nav-actions {
        display:
            none;
    }


    .hero-section {
        min-height:
            auto;

        grid-template-columns:
            1fr;

        padding-top:
            160px;

        text-align:
            center;
    }


    .hero-badge {
        margin-inline:
            auto;
    }


    .hero-description {
        margin-inline:
            auto;
    }


    .hero-buttons,
    .hero-stats {
        justify-content:
            center;
    }


    .hero-universe {
        width:
            min(
                500px,
                90vw
            );
    }


    .explore-grid {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }
}


@media
(max-width: 600px) {

    section {
        width:
            min(
                calc(100% - 28px),
                var(--max-width)
            );

        padding:
            75px 0;
    }


    .main-header {
        padding:
            9px 10px;
    }


    .navbar {
        min-height:
            60px;

        padding:
            8px 10px 8px 14px;

        border-radius:
            17px;
    }


    .logo {
        font-size:
            1rem;
    }


    .hero-section {
        padding-top:
            130px;
    }


    .hero-content h1 {
        font-size:
            clamp(
                3.5rem,
                18vw,
                5.5rem
            );
    }


    .hero-buttons {
        flex-direction:
            column;
    }


    .hero-buttons a {
        width:
            100%;
    }


    .hero-stats {
        display:
            grid;

        grid-template-columns:
            1fr 1fr;
    }


    .hero-stat:last-child {
        grid-column:
            1 / -1;
    }


    .hero-universe {
        width:
            min(
                390px,
                92vw
            );
    }


    .explore-grid {
        grid-template-columns:
            1fr;
    }


    .explore-card {
        min-height:
            auto;
    }


    .fact-stat-grid {
        grid-template-columns:
            1fr;
    }
}


/* =========================================================
   16. REDUCED MOTION ACCESSIBILITY
========================================================= */

@media
(prefers-reduced-motion: reduce) {

    html {
        scroll-behavior:
            auto;
    }


    *,
    *::before,
    *::after {
        animation-duration:
            0.01ms !important;

        animation-iteration-count:
            1 !important;

        transition-duration:
            0.01ms !important;
    }
}

/* =========================================================
   COSMOVERSE 3.0
   STYLE.CSS — PART 2
   Solar System • Planets • Observatory • Comparison Lab
========================================================= */


/* =========================================================
   17. SOLAR SYSTEM SECTION
========================================================= */

.solar-system-section {
    width: min(calc(100% - 30px), 1550px);
}


.solar-controls {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;

    gap: 10px;

    margin-bottom: 30px;
}


.solar-controls button {
    min-height: 44px;

    padding: 10px 17px;

    border: 1px solid var(--border);
    border-radius: 12px;

    background: rgba(255, 255, 255, 0.04);

    color: var(--text-secondary);

    font-weight: 700;

    cursor: pointer;

    transition:
        transform var(--transition),
        background var(--transition),
        border-color var(--transition),
        color var(--transition);
}


.solar-controls button:hover {
    transform: translateY(-2px);

    border-color: var(--border-bright);

    background: rgba(60, 150, 255, 0.1);

    color: white;
}


/* =========================================================
   18. SOLAR SYSTEM VIEW
========================================================= */

.solar-system-view {
    position: relative;

    width: min(100%, 1100px);
    aspect-ratio: 1 / 1;

    margin: 0 auto 45px;

    overflow: hidden;

    border: 1px solid rgba(100, 180, 255, 0.12);
    border-radius: 50%;

    background:
        radial-gradient(
            circle at center,
            rgba(255, 180, 55, 0.1) 0%,
            rgba(25, 55, 115, 0.08) 20%,
            rgba(8, 18, 45, 0.5) 52%,
            rgba(2, 6, 16, 0.95) 100%
        );

    box-shadow:
        inset 0 0 120px rgba(0, 0, 0, 0.7),
        0 30px 100px rgba(0, 0, 0, 0.35);

    isolation: isolate;
}


.solar-system-view::before {
    content: "";

    position: absolute;
    inset: 0;

    z-index: -2;

    background-image:
        radial-gradient(
            circle,
            rgba(255, 255, 255, 0.8) 1px,
            transparent 1.4px
        );

    background-size: 70px 70px;

    opacity: 0.25;
}


.solar-system-view::after {
    content: "";

    position: absolute;

    inset: 37%;

    z-index: -1;

    border-radius: 50%;

    background: rgba(255, 165, 40, 0.12);

    filter: blur(45px);

    animation: solarGlow 4s ease-in-out infinite;
}


/* =========================================================
   19. SPACE OBJECTS
========================================================= */

.space-object {
    position: absolute;

    z-index: 20;

    display: flex;
    flex-direction: column;
    align-items: center;

    gap: 5px;

    padding: 0;

    border: none;

    background: transparent;

    cursor: pointer;

    transform: translate(-50%, -50%);

    transition:
        filter var(--transition);
}


.space-object:hover {
    filter: brightness(1.3);
}


.planet-emoji {
    display: block;

    line-height: 1;

    transition:
        transform 0.3s ease,
        filter 0.3s ease;
}


.space-object:hover .planet-emoji {
    transform: scale(1.2);

    filter:
        drop-shadow(
            0 0 15px
            rgba(120, 200, 255, 0.8)
        );
}


.planet-label {
    padding: 3px 7px;

    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 7px;

    background: rgba(3, 8, 20, 0.75);

    color: var(--text-secondary);

    font-size: 0.65rem;
    font-weight: 700;

    white-space: nowrap;

    backdrop-filter: blur(8px);
}


/* =========================================================
   20. SUN
========================================================= */

.sun-object {
    top: 50%;
    left: 50%;

    z-index: 50;
}


.sun-object .planet-emoji {
    font-size: clamp(70px, 10vw, 125px);

    filter:
        drop-shadow(
            0 0 12px
            rgba(255, 240, 130, 0.95)
        )
        drop-shadow(
            0 0 30px
            rgba(255, 175, 40, 0.85)
        )
        drop-shadow(
            0 0 70px
            rgba(255, 100, 20, 0.5)
        );

    animation:
        solarSunPulse
        3.5s ease-in-out infinite;
}


/* =========================================================
   21. ORBITS
========================================================= */

.orbit {
    position: absolute;

    top: 50%;
    left: 50%;

    border:
        1px solid
        rgba(130, 185, 255, 0.15);

    border-radius: 50%;

    transform:
        translate(-50%, -50%);

    pointer-events: none;
}


.orbit .space-object {
    top: 50%;
    left: 100%;

    pointer-events: auto;
}


.orbit-mercury {
    width: 20%;
    height: 20%;

    animation:
        orbitSpin
        8s linear infinite;
}


.orbit-venus {
    width: 30%;
    height: 30%;

    animation:
        orbitSpin
        12s linear infinite;
}


.orbit-earth {
    width: 41%;
    height: 41%;

    animation:
        orbitSpin
        16s linear infinite;
}


.orbit-mars {
    width: 52%;
    height: 52%;

    animation:
        orbitSpin
        21s linear infinite;
}


.orbit-jupiter {
    width: 65%;
    height: 65%;

    animation:
        orbitSpin
        30s linear infinite;
}


.orbit-saturn {
    width: 76%;
    height: 76%;

    animation:
        orbitSpin
        38s linear infinite;
}


.orbit-uranus {
    width: 87%;
    height: 87%;

    animation:
        orbitSpin
        47s linear infinite;
}


.orbit-neptune {
    width: 97%;
    height: 97%;

    animation:
        orbitSpin
        56s linear infinite;
}


/* =========================================================
   22. PLANET SIZES
========================================================= */

.mercury-object .planet-emoji {
    font-size: 18px;
}


.venus-object .planet-emoji {
    font-size: 25px;
}


.earth-object .planet-emoji {
    font-size: 28px;

    filter:
        drop-shadow(
            0 0 8px
            rgba(70, 160, 255, 0.65)
        );
}


.mars-object .planet-emoji {
    font-size: 23px;

    filter:
        drop-shadow(
            0 0 7px
            rgba(255, 80, 50, 0.4)
        );
}


.jupiter-object .planet-emoji {
    font-size: 43px;
}


.saturn-object .planet-emoji {
    font-size: 52px;
}


.uranus-object .planet-emoji {
    font-size: 33px;

    filter:
        drop-shadow(
            0 0 8px
            rgba(90, 230, 255, 0.45)
        );
}


.neptune-object .planet-emoji {
    font-size: 32px;

    filter:
        drop-shadow(
            0 0 8px
            rgba(70, 100, 255, 0.55)
        );
}


/* =========================================================
   23. PAUSED ORBITS
========================================================= */

.solar-system-view.orbits-paused
.orbit {
    animation-play-state: paused;
}


.solar-system-view.labels-hidden
.planet-label {
    opacity: 0;
}


/* =========================================================
   24. SOLAR INFORMATION PANEL
========================================================= */

.solar-information-panel {
    width: min(100%, 1050px);

    margin-inline: auto;

    display: grid;

    grid-template-columns:
        220px 1fr;

    gap: 35px;

    align-items: center;

    padding: 35px;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        linear-gradient(
            145deg,
            rgba(14, 28, 54, 0.85),
            rgba(5, 12, 27, 0.88)
        );

    backdrop-filter: blur(18px);

    box-shadow: var(--shadow-large);
}


.selected-object-emoji {
    position: relative;

    display: grid;
    place-items: center;

    width: 190px;
    height: 190px;

    margin-inline: auto;

    border:
        1px solid
        rgba(100, 190, 255, 0.15);

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            rgba(75, 155, 255, 0.15),
            rgba(20, 50, 100, 0.04) 55%,
            transparent 70%
        );

    font-size: 105px;

    filter:
        drop-shadow(
            0 0 22px
            rgba(70, 160, 255, 0.25)
        );

    animation:
        selectedPlanetFloat
        5s ease-in-out infinite;
}


.selected-object-emoji::after {
    content: "";

    position: absolute;

    inset: -10px;

    border:
        1px solid
        rgba(100, 200, 255, 0.1);

    border-radius: 50%;

    animation:
        scannerRing
        4s linear infinite;
}


.selected-object-content h3 {
    margin-bottom: 10px;

    font-size: clamp(2rem, 4vw, 3rem);
}


.selected-object-content > p {
    color: var(--text-secondary);
}


.object-stat-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 10px;

    margin-top: 25px;
}


.object-stat-grid > div {
    min-height: 82px;

    padding: 14px;

    border:
        1px solid
        var(--border);

    border-radius: 12px;

    background:
        rgba(255, 255, 255, 0.025);
}


.object-stat-grid span {
    display: block;

    margin-bottom: 4px;

    color: var(--text-muted);

    font-size: 0.68rem;
    font-weight: 700;

    letter-spacing: 0.08em;

    text-transform: uppercase;
}


.object-stat-grid strong {
    font-size: 0.9rem;
}


/* =========================================================
   25. PLANET OBSERVATORY
========================================================= */

.planet-observatory-section {
    width: min(calc(100% - 30px), 1450px);
}


.planet-selector {
    display: flex;

    gap: 8px;

    margin-bottom: 28px;

    padding: 8px;

    overflow-x: auto;

    border:
        1px solid
        var(--border);

    border-radius: 16px;

    background:
        rgba(4, 12, 28, 0.65);
}


.planet-selector::-webkit-scrollbar {
    height: 4px;
}


.planet-select-button {
    min-width: 115px;
    min-height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    padding: 8px 12px;

    border: 1px solid transparent;
    border-radius: 11px;

    background: transparent;

    color: var(--text-secondary);

    font-weight: 700;

    cursor: pointer;

    transition:
        background var(--transition),
        border-color var(--transition),
        transform var(--transition),
        color var(--transition);
}


.planet-select-button span {
    font-size: 21px;
}


.planet-select-button:hover {
    color: white;

    background:
        rgba(255, 255, 255, 0.05);
}


.planet-select-button.active {
    border-color:
        rgba(90, 190, 255, 0.35);

    background:
        linear-gradient(
            135deg,
            rgba(50, 140, 255, 0.18),
            rgba(125, 80, 255, 0.12)
        );

    color: white;

    box-shadow:
        inset 0 0 25px
        rgba(70, 150, 255, 0.05);
}


/* =========================================================
   26. PLANET OBSERVATORY DISPLAY
========================================================= */

.planet-observatory-display {
    display: grid;

    grid-template-columns:
        minmax(380px, 0.9fr)
        minmax(0, 1.1fr);

    min-height: 620px;

    overflow: hidden;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(7, 18, 39, 0.92),
            rgba(4, 10, 24, 0.9)
        );

    box-shadow:
        var(--shadow-large);
}


.planet-visual-area {
    position: relative;

    display: grid;
    place-items: center;

    overflow: hidden;

    min-height: 600px;

    background:
        radial-gradient(
            circle at center,
            rgba(50, 120, 255, 0.16),
            transparent 42%
        ),
        linear-gradient(
            145deg,
            rgba(10, 30, 65, 0.45),
            rgba(2, 7, 18, 0.7)
        );
}


.planet-visual-area::before {
    content: "";

    position: absolute;
    inset: 0;

    background-image:
        linear-gradient(
            rgba(80, 160, 255, 0.035) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(80, 160, 255, 0.035) 1px,
            transparent 1px
        );

    background-size: 40px 40px;

    mask-image:
        radial-gradient(
            circle,
            black,
            transparent 70%
        );
}


.observatory-planet {
    position: relative;

    z-index: 5;

    width: 270px;
    height: 270px;

    display: grid;
    place-items: center;

    border-radius: 50%;

    font-size: 190px;

    filter:
        drop-shadow(
            0 0 30px
            rgba(80, 160, 255, 0.25)
        );

    animation:
        observatoryPlanetFloat
        6s ease-in-out infinite;
}


/* =========================================================
   27. OBSERVATORY SCANNERS
========================================================= */

.planet-scan-ring {
    position: absolute;

    z-index: 3;

    width: 350px;
    height: 350px;

    border:
        1px solid
        rgba(70, 210, 255, 0.18);

    border-radius: 50%;

    animation:
        scanRingPulse
        3s ease-in-out infinite;
}


.planet-scan-ring::before,
.planet-scan-ring::after {
    content: "";

    position: absolute;

    width: 7px;
    height: 7px;

    border-radius: 50%;

    background: var(--cyan);

    box-shadow:
        0 0 15px
        var(--cyan);
}


.planet-scan-ring::before {
    top: 15%;
    left: 14%;
}


.planet-scan-ring::after {
    right: 9%;
    bottom: 25%;
}


.planet-scan-ring.ring-two {
    width: 430px;
    height: 430px;

    border-style: dashed;

    opacity: 0.45;

    animation:
        scannerRotate
        18s linear infinite;
}


.planet-scan-line {
    position: absolute;

    z-index: 6;

    width: 70%;
    height: 2px;

    background:
        linear-gradient(
            90deg,
            transparent,
            rgba(80, 230, 255, 0.75),
            transparent
        );

    box-shadow:
        0 0 12px
        rgba(80, 220, 255, 0.4);

    animation:
        scanLine
        4s ease-in-out infinite;
}


.planet-distance-label {
    position: absolute;

    left: 25px;
    bottom: 22px;

    color:
        rgba(120, 220, 255, 0.7);

    font-size: 0.65rem;
    font-weight: 800;

    letter-spacing: 0.18em;
}


/* =========================================================
   28. PLANET DATA AREA
========================================================= */

.planet-data-area {
    padding:
        55px 45px;
}


.planet-data-area h3 {
    margin-bottom: 10px;

    font-size:
        clamp(2.5rem, 5vw, 4.5rem);

    letter-spacing: -0.05em;
}


.planet-data-area > p {
    max-width: 650px;

    color: var(--text-secondary);

    font-size: 1.05rem;
}


.planet-data-tabs {
    display: flex;
    flex-wrap: wrap;

    gap: 7px;

    margin-top: 30px;
}


.planet-tab {
    padding:
        10px 13px;

    border:
        1px solid
        var(--border);

    border-radius:
        10px;

    background:
        rgba(255, 255, 255, 0.025);

    color:
        var(--text-secondary);

    font-weight: 700;

    cursor: pointer;

    transition:
        background var(--transition),
        color var(--transition),
        border-color var(--transition);
}


.planet-tab:hover {
    color: white;

    border-color:
        rgba(100, 190, 255, 0.35);
}


.planet-tab.active {
    color: white;

    border-color:
        rgba(80, 200, 255, 0.4);

    background:
        rgba(50, 150, 255, 0.12);
}


.planet-tab-content {
    min-height: 190px;

    margin-top: 18px;

    padding: 25px;

    border:
        1px solid
        var(--border);

    border-radius: 16px;

    background:
        rgba(255, 255, 255, 0.025);
}


.planet-tab-content h4 {
    margin-bottom: 10px;

    color: var(--blue-bright);

    font-size: 1.15rem;
}


.planet-tab-content p {
    color: var(--text-secondary);
}


/* =========================================================
   29. COMPARISON LAB
========================================================= */

.planet-comparison-lab {
    margin-top: 35px;

    padding: 35px;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-large);

    background:
        linear-gradient(
            145deg,
            rgba(13, 26, 52, 0.8),
            rgba(5, 12, 28, 0.85)
        );

    box-shadow:
        var(--shadow-small);
}


.comparison-controls {
    display: grid;

    grid-template-columns:
        1fr auto 1fr auto;

    gap: 12px;

    align-items: center;
}


.comparison-vs {
    width: 45px;
    height: 45px;

    display: grid;
    place-items: center;

    border:
        1px solid
        rgba(120, 180, 255, 0.2);

    border-radius: 50%;

    background:
        rgba(90, 130, 255, 0.08);

    color: var(--cyan);

    font-size: 0.75rem;
    font-weight: 900;
}


.comparison-results {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    gap: 15px;

    margin-top: 25px;
}


.comparison-world {
    padding: 30px;

    border:
        1px solid
        var(--border);

    border-radius: 18px;

    background:
        rgba(255, 255, 255, 0.025);

    text-align: center;
}


.comparison-world-emoji {
    min-height: 90px;

    display: grid;
    place-items: center;

    font-size: 70px;

    filter:
        drop-shadow(
            0 0 15px
            rgba(100, 180, 255, 0.25)
        );
}


.comparison-world h4 {
    margin:
        10px 0 20px;

    font-size: 1.6rem;
}


.comparison-world
.compare-stat {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;

    padding:
        11px 0;

    border-bottom:
        1px solid
        rgba(255, 255, 255, 0.06);

    text-align: left;
}


.comparison-world
.compare-stat:last-child {
    border-bottom: none;
}


.compare-stat span {
    color:
        var(--text-muted);

    font-size:
        0.82rem;
}


.compare-stat strong {
    color:
        var(--text-main);

    font-size:
        0.88rem;

    text-align: right;
}


/* =========================================================
   30. SOLAR / PLANET ANIMATIONS
========================================================= */

@keyframes orbitSpin {

    from {
        transform:
            translate(-50%, -50%)
            rotate(0deg);
    }

    to {
        transform:
            translate(-50%, -50%)
            rotate(360deg);
    }
}


@keyframes solarGlow {

    0%,
    100% {
        transform: scale(0.9);
        opacity: 0.55;
    }

    50% {
        transform: scale(1.15);
        opacity: 1;
    }
}


@keyframes solarSunPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }
}


@keyframes selectedPlanetFloat {

    0%,
    100% {
        transform:
            translateY(0)
            rotate(-2deg);
    }

    50% {
        transform:
            translateY(-10px)
            rotate(2deg);
    }
}


@keyframes scannerRing {

    from {
        transform:
            rotate(0deg);
    }

    to {
        transform:
            rotate(360deg);
    }
}


@keyframes observatoryPlanetFloat {

    0%,
    100% {
        transform:
            translateY(0)
            rotate(-2deg);
    }

    50% {
        transform:
            translateY(-15px)
            rotate(2deg);
    }
}


@keyframes scanRingPulse {

    0%,
    100% {
        opacity: 0.35;
        transform: scale(0.96);
    }

    50% {
        opacity: 0.85;
        transform: scale(1.03);
    }
}


@keyframes scannerRotate {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}


@keyframes scanLine {

    0% {
        transform:
            translateY(-170px);

        opacity: 0;
    }

    15% {
        opacity: 0.8;
    }

    85% {
        opacity: 0.8;
    }

    100% {
        transform:
            translateY(170px);

        opacity: 0;
    }
}


/* =========================================================
   31. RESPONSIVE SOLAR SYSTEM
========================================================= */

@media
(max-width: 1000px) {

    .solar-system-view {
        width:
            min(100%, 850px);
    }


    .solar-information-panel {
        grid-template-columns:
            180px 1fr;

        padding:
            28px;
    }


    .selected-object-emoji {
        width: 160px;
        height: 160px;

        font-size: 85px;
    }


    .planet-observatory-display {
        grid-template-columns: 1fr;
    }


    .planet-visual-area {
        min-height: 500px;
    }


    .comparison-controls {
        grid-template-columns:
            1fr auto 1fr;
    }


    .comparison-controls
    .primary-button {
        grid-column:
            1 / -1;
    }
}


@media
(max-width: 700px) {

    .solar-system-section,
    .planet-observatory-section {
        width:
            min(
                calc(100% - 20px),
                1450px
            );
    }


    .solar-system-view {
        width: 100%;
    }


    .planet-label {
        display: none;
    }


    .solar-system-view.labels-visible
    .planet-label {
        display: block;
    }


    .sun-object .planet-emoji {
        font-size: 55px;
    }


    .mercury-object .planet-emoji {
        font-size: 12px;
    }


    .venus-object .planet-emoji {
        font-size: 16px;
    }


    .earth-object .planet-emoji {
        font-size: 19px;
    }


    .mars-object .planet-emoji {
        font-size: 16px;
    }


    .jupiter-object .planet-emoji {
        font-size: 28px;
    }


    .saturn-object .planet-emoji {
        font-size: 33px;
    }


    .uranus-object .planet-emoji,
    .neptune-object .planet-emoji {
        font-size: 21px;
    }


    .solar-information-panel {
        grid-template-columns: 1fr;

        text-align: center;
    }


    .selected-object-emoji {
        width: 135px;
        height: 135px;

        font-size: 75px;
    }


    .object-stat-grid {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );

        text-align: left;
    }


    .planet-visual-area {
        min-height: 400px;
    }


    .observatory-planet {
        width: 190px;
        height: 190px;

        font-size: 135px;
    }


    .planet-scan-ring {
        width: 250px;
        height: 250px;
    }


    .planet-scan-ring.ring-two {
        width: 320px;
        height: 320px;
    }


    .planet-data-area {
        padding: 30px 22px;
    }


    .planet-data-tabs {
        display: grid;

        grid-template-columns:
            1fr 1fr;
    }


    .comparison-controls {
        grid-template-columns: 1fr;
    }


    .comparison-vs {
        margin-inline: auto;
    }


    .comparison-results {
        grid-template-columns: 1fr;
    }

}


@media
(max-width: 450px) {

    .solar-controls {
        display: grid;

        grid-template-columns:
            1fr 1fr;
    }


    .solar-controls button {
        width: 100%;
    }


    .object-stat-grid {
        grid-template-columns: 1fr;
    }


    .planet-comparison-lab {
        padding: 22px 15px;
    }

}

/* =========================================================
   COSMOVERSE 3.0
   STYLE.CSS — PART 3
   Moons • Small Bodies • Stars • Galaxies • Exoplanets
   Black Hole Laboratory
========================================================= */


/* =========================================================
   32. MOON CENTER
========================================================= */

.moon-feature {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    align-items: center;

    min-height: 500px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(11, 24, 48, 0.9),
            rgba(4, 10, 23, 0.92)
        );

    box-shadow: var(--shadow-large);
}


.moon-visual {
    position: relative;

    min-height: 500px;

    display: grid;
    place-items: center;

    overflow: hidden;

    background:
        radial-gradient(
            circle at center,
            rgba(190, 210, 235, 0.13),
            transparent 45%
        );
}


.moon-visual::before {
    content: "";

    position: absolute;
    inset: 0;

    background-image:
        radial-gradient(
            circle,
            white 1px,
            transparent 1.5px
        );

    background-size: 65px 65px;

    opacity: 0.18;
}


.large-moon {
    position: relative;

    z-index: 5;

    font-size: clamp(130px, 20vw, 230px);

    filter:
        drop-shadow(
            0 0 30px
            rgba(210, 225, 255, 0.25)
        );

    animation:
        moonFloat
        6s ease-in-out infinite;
}


.moon-orbit-line {
    position: absolute;

    width: 380px;
    height: 190px;

    border:
        1px solid
        rgba(130, 190, 255, 0.18);

    border-radius: 50%;

    transform: rotate(-15deg);
}


.moon-spacecraft {
    position: absolute;

    z-index: 7;

    top: 27%;
    right: 18%;

    font-size: 38px;

    animation:
        spacecraftFloat
        5s ease-in-out infinite;
}


.moon-feature-content {
    padding: 50px;
}


.moon-feature-content h3 {
    margin-bottom: 12px;

    font-size: clamp(2.2rem, 5vw, 4rem);
}


.moon-feature-content > p {
    color: var(--text-secondary);
}


.moon-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 16px;

    margin-top: 25px;
}


.moon-card {
    padding: 26px;

    border: 1px solid var(--border);
    border-radius: 18px;

    background:
        linear-gradient(
            145deg,
            rgba(14, 27, 51, 0.72),
            rgba(5, 12, 26, 0.82)
        );

    transition:
        transform var(--transition),
        border-color var(--transition);
}


.moon-card:hover {
    transform: translateY(-6px);

    border-color:
        rgba(110, 195, 255, 0.38);
}


.moon-card-icon {
    margin-bottom: 16px;

    font-size: 48px;
}


.moon-card h3 {
    margin-bottom: 8px;
}


.moon-card p {
    color: var(--text-secondary);

    font-size: 0.9rem;
}


/* =========================================================
   33. DWARF PLANETS
========================================================= */

.dwarf-grid {
    display: grid;

    grid-template-columns:
        repeat(5, minmax(0, 1fr));

    gap: 14px;
}


.dwarf-card {
    position: relative;

    min-height: 240px;

    padding: 25px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: 18px;

    background:
        linear-gradient(
            145deg,
            rgba(14, 28, 53, 0.75),
            rgba(5, 11, 24, 0.82)
        );

    text-align: center;

    transition:
        transform var(--transition),
        border-color var(--transition);
}


.dwarf-card:hover {
    transform:
        translateY(-7px)
        scale(1.02);

    border-color:
        rgba(120, 195, 255, 0.4);
}


.dwarf-card > div {
    margin-bottom: 18px;

    font-size: 62px;

    filter:
        drop-shadow(
            0 0 15px
            rgba(100, 170, 255, 0.2)
        );
}


.dwarf-card h3 {
    margin-bottom: 8px;
}


.dwarf-card p {
    color: var(--text-secondary);

    font-size: 0.88rem;
}


/* =========================================================
   34. ASTEROIDS AND COMETS
========================================================= */

.small-body-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 18px;
}


.space-info-card {
    position: relative;

    min-height: 310px;

    padding: 35px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: 22px;

    background:
        radial-gradient(
            circle at top right,
            rgba(80, 140, 255, 0.09),
            transparent 40%
        ),
        rgba(8, 17, 34, 0.8);

    transition:
        transform var(--transition),
        border-color var(--transition);
}


.space-info-card:hover {
    transform: translateY(-7px);

    border-color:
        rgba(110, 200, 255, 0.38);
}


.large-card-icon {
    margin-bottom: 25px;

    font-size: 65px;
}


.space-info-card h3 {
    margin-bottom: 10px;

    font-size: 1.5rem;
}


.space-info-card p {
    color: var(--text-secondary);
}


/* =========================================================
   35. STAR OBSERVATORY
========================================================= */

.sun-feature {
    display: grid;

    grid-template-columns:
        0.9fr 1.1fr;

    min-height: 550px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(55, 24, 5, 0.25),
            rgba(6, 13, 29, 0.92)
        );

    box-shadow: var(--shadow-large);
}


.sun-visual {
    position: relative;

    display: grid;
    place-items: center;

    min-height: 550px;

    overflow: hidden;

    background:
        radial-gradient(
            circle,
            rgba(255, 155, 40, 0.17),
            transparent 48%
        );
}


.realistic-sun {
    position: relative;

    z-index: 5;

    font-size: clamp(150px, 23vw, 280px);

    filter:
        drop-shadow(
            0 0 20px
            rgba(255, 225, 100, 0.95)
        )
        drop-shadow(
            0 0 60px
            rgba(255, 135, 30, 0.7)
        )
        drop-shadow(
            0 0 120px
            rgba(255, 70, 10, 0.32)
        );

    animation:
        giantSunPulse
        4s ease-in-out infinite;
}


.solar-flare {
    position: absolute;

    z-index: 2;

    width: 150px;
    height: 150px;

    border:
        7px solid
        rgba(255, 125, 30, 0.55);

    border-left-color: transparent;
    border-bottom-color: transparent;

    border-radius: 50%;

    filter: blur(3px);

    animation:
        solarFlare
        4s ease-in-out infinite;
}


.flare-one {
    top: 20%;
    right: 19%;
}


.flare-two {
    left: 16%;
    bottom: 17%;

    transform: rotate(180deg);

    animation-delay: -2s;
}


.sun-information {
    align-self: center;

    padding: 50px;
}


.sun-information h3 {
    margin-bottom: 12px;

    font-size: clamp(2.5rem, 5vw, 4.5rem);
}


.sun-information > p {
    color: var(--text-secondary);
}


/* =========================================================
   36. STAR LIFE CYCLE
========================================================= */

.star-life-cycle {
    margin-top: 28px;

    padding: 35px;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        rgba(7, 15, 31, 0.76);
}


.star-life-cycle h3 {
    margin-bottom: 30px;

    text-align: center;

    font-size: 1.7rem;
}


.star-life-track {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 15px;
}


.life-stage {
    min-width: 150px;

    padding: 22px;

    border: 1px solid var(--border);
    border-radius: 16px;

    background:
        rgba(255, 255, 255, 0.025);

    text-align: center;
}


.life-stage span {
    display: block;

    margin-bottom: 8px;

    font-size: 48px;
}


.life-stage strong {
    font-size: 0.9rem;
}


.life-arrow {
    color: var(--cyan);

    font-size: 1.8rem;
}


.science-note {
    max-width: 800px;

    margin: 28px auto 0;

    color: var(--text-secondary);

    text-align: center;
}


/* =========================================================
   37. GALAXY EXPLORER
========================================================= */

.galaxy-feature {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    min-height: 570px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(26, 16, 55, 0.48),
            rgba(4, 10, 24, 0.92)
        );

    box-shadow: var(--shadow-large);
}


.milky-way-visual {
    position: relative;

    min-height: 570px;

    display: grid;
    place-items: center;

    overflow: hidden;

    perspective: 900px;
}


.milky-way-visual::before {
    content: "";

    position: absolute;
    inset: 0;

    background-image:
        radial-gradient(
            circle,
            white 1px,
            transparent 1.5px
        );

    background-size: 45px 45px;

    opacity: 0.2;
}


.galaxy-core {
    position: absolute;

    z-index: 5;

    width: 95px;
    height: 95px;

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            #fff9d8 0%,
            #ffe08a 25%,
            rgba(180, 120, 255, 0.55) 55%,
            transparent 75%
        );

    box-shadow:
        0 0 30px
        rgba(255, 220, 150, 0.6),
        0 0 100px
        rgba(145, 90, 255, 0.35);
}


.galaxy-arm {
    position: absolute;

    width: 360px;
    height: 180px;

    border-radius: 50%;

    border:
        25px solid
        rgba(120, 150, 255, 0.12);

    border-left-color:
        rgba(220, 180, 255, 0.45);

    border-right-color:
        rgba(90, 150, 255, 0.4);

    filter: blur(5px);

    animation:
        galaxySpin
        18s linear infinite;
}


.arm-two {
    transform: rotate(90deg);

    animation:
        galaxySpinTwo
        18s linear infinite;
}


.galaxy-star-field {
    position: absolute;

    width: 420px;
    height: 420px;

    border-radius: 50%;

    background-image:
        radial-gradient(
            circle,
            rgba(255,255,255,0.8) 1px,
            transparent 1.5px
        );

    background-size: 22px 22px;

    opacity: 0.25;

    animation:
        galaxyStarsSpin
        30s linear infinite;
}


.galaxy-information {
    align-self: center;

    padding: 50px;
}


.galaxy-information h3 {
    margin-bottom: 12px;

    font-size: clamp(2.5rem, 5vw, 4rem);
}


.galaxy-information > p {
    color: var(--text-secondary);
}


.galaxy-types {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 15px;

    margin-top: 25px;
}


.galaxy-types article {
    padding: 28px;

    border: 1px solid var(--border);
    border-radius: 18px;

    background:
        rgba(255, 255, 255, 0.025);
}


.galaxy-types span {
    display: block;

    margin-bottom: 12px;

    font-size: 48px;
}


.galaxy-types p {
    margin-top: 7px;

    color: var(--text-secondary);

    font-size: 0.9rem;
}


/* =========================================================
   38. EXOPLANET EXPLORER
========================================================= */

.exoplanet-display {
    display: grid;

    grid-template-columns:
        0.9fr 1.1fr;

    min-height: 520px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(25, 15, 60, 0.48),
            rgba(4, 11, 25, 0.92)
        );
}


.alien-star-system {
    position: relative;

    min-height: 520px;

    display: grid;
    place-items: center;

    overflow: hidden;
}


.alien-star {
    position: relative;

    z-index: 4;

    font-size: 115px;

    filter:
        drop-shadow(
            0 0 30px
            rgba(255, 220, 100, 0.7)
        );

    animation:
        alienStarPulse
        3s ease-in-out infinite;
}


.alien-orbit {
    position: absolute;

    width: 350px;
    height: 350px;

    border:
        1px solid
        rgba(130, 190, 255, 0.2);

    border-radius: 50%;

    animation:
        alienOrbit
        12s linear infinite;
}


.alien-world {
    position: absolute;

    top: 50%;
    left: -22px;

    font-size: 45px;

    transform:
        translateY(-50%);

    filter:
        drop-shadow(
            0 0 12px
            rgba(70, 140, 255, 0.6)
        );
}


.exoplanet-information {
    align-self: center;

    padding: 50px;
}


.exoplanet-information h3 {
    margin-bottom: 12px;

    font-size: clamp(2.2rem, 5vw, 4rem);
}


.exoplanet-information > p {
    color: var(--text-secondary);
}


.exoplanet-information
.secondary-button {
    margin-top: 25px;
}


.exoplanet-result {
    min-height: 110px;

    margin-top: 20px;

    padding: 20px;

    border:
        1px solid
        var(--border);

    border-radius: 15px;

    background:
        rgba(255, 255, 255, 0.025);

    color:
        var(--text-secondary);
}


/* =========================================================
   39. BLACK HOLE LAB
========================================================= */

.black-hole-lab {
    display: grid;

    grid-template-columns:
        minmax(500px, 1fr)
        minmax(0, 1fr);

    min-height: 650px;

    overflow: hidden;

    border:
        1px solid
        rgba(160, 120, 255, 0.18);

    border-radius:
        var(--radius-large);

    background:
        radial-gradient(
            circle at 25% 50%,
            rgba(85, 45, 150, 0.16),
            transparent 40%
        ),
        #02040b;

    box-shadow:
        0 35px 120px
        rgba(0, 0, 0, 0.6);
}


/* =========================================================
   40. BLACK HOLE VISUALIZATION
========================================================= */

.black-hole-visualization {
    position: relative;

    min-height: 650px;

    display: grid;
    place-items: center;

    overflow: hidden;

    isolation: isolate;

    perspective: 1000px;
}


.black-hole-stars {
    position: absolute;

    inset: -20%;

    z-index: -5;

    background-image:
        radial-gradient(
            circle,
            rgba(255,255,255,0.85) 1px,
            transparent 1.5px
        );

    background-size:
        40px 40px;

    opacity: 0.25;

    animation:
        blackHoleStars
        30s linear infinite;
}


.black-hole-shadow {
    position: absolute;

    z-index: 10;

    width: 210px;
    height: 210px;

    display: grid;
    place-items: center;

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            #000 0%,
            #000 68%,
            rgba(0,0,0,0.95) 75%,
            transparent 76%
        );

    box-shadow:
        0 0 20px
        rgba(0, 0, 0, 1),
        0 0 55px
        rgba(160, 80, 255, 0.22);

    animation:
        blackHoleBreathe
        5s ease-in-out infinite;
}


.event-horizon {
    width: 190px;
    height: 190px;

    border-radius: 50%;

    background: black;

    box-shadow:
        inset 0 0 35px black,
        0 0 10px black;
}


/* =========================================================
   41. ACCRETION DISK
========================================================= */

.accretion-disk {
    position: absolute;

    left: 50%;
    top: 50%;

    width: 480px;
    height: 145px;

    border-radius: 50%;

    transform:
        translate(-50%, -50%)
        rotate(-8deg);

    background:
        radial-gradient(
            ellipse at center,
            transparent 0%,
            transparent 25%,
            rgba(255, 255, 230, 0.95) 31%,
            rgba(255, 205, 90, 0.95) 37%,
            rgba(255, 115, 35, 0.85) 46%,
            rgba(180, 55, 255, 0.55) 58%,
            transparent 72%
        );

    filter:
        blur(2px)
        drop-shadow(
            0 0 16px
            rgba(255, 150, 50, 0.7)
        )
        drop-shadow(
            0 0 40px
            rgba(170, 70, 255, 0.35)
        );
}


.disk-back {
    z-index: 4;

    opacity: 0.8;

    animation:
        accretionPulse
        3s ease-in-out infinite;
}


.disk-front {
    z-index: 20;

    clip-path:
        inset(
            50% 0 0 0
        );

    animation:
        accretionPulse
        3s ease-in-out infinite reverse;
}


.gravity-glow {
    position: absolute;

    z-index: 2;

    width: 420px;
    height: 420px;

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            transparent 35%,
            rgba(255, 160, 70, 0.05) 44%,
            rgba(150, 80, 255, 0.09) 53%,
            transparent 70%
        );

    filter: blur(10px);

    animation:
        gravityGlow
        5s ease-in-out infinite;
}


/* =========================================================
   42. BLACK HOLE INFO
========================================================= */

.black-hole-information {
    align-self: center;

    padding: 50px;
}


.black-hole-information h3 {
    margin-bottom: 12px;

    font-size: clamp(2.4rem, 5vw, 4rem);
}


.black-hole-information > p {
    color: var(--text-secondary);

    font-size: 1.02rem;
}


.black-hole-facts {
    display: grid;

    gap: 10px;

    margin-top: 28px;
}


.black-hole-facts article {
    padding: 17px;

    border:
        1px solid
        rgba(160, 130, 255, 0.13);

    border-radius: 13px;

    background:
        rgba(130, 80, 255, 0.035);
}


.black-hole-facts strong {
    color:
        #c8b3ff;
}


.black-hole-facts p {
    margin-top: 5px;

    color:
        var(--text-secondary);

    font-size: 0.88rem;
}


.real-black-hole-feature {
    margin-top: 25px;

    padding: 35px;

    border:
        1px solid
        rgba(170, 120, 255, 0.18);

    border-radius: 20px;

    background:
        linear-gradient(
            135deg,
            rgba(90, 45, 150, 0.12),
            rgba(7, 13, 28, 0.8)
        );
}


.real-black-hole-feature h3 {
    margin: 7px 0 10px;

    font-size: 2rem;
}


.real-black-hole-feature p {
    color:
        var(--text-secondary);
}


/* =========================================================
   43. PART 3 ANIMATIONS
========================================================= */

@keyframes moonFloat {

    0%,
    100% {
        transform:
            translateY(0)
            rotate(-2deg);
    }

    50% {
        transform:
            translateY(-12px)
            rotate(2deg);
    }
}


@keyframes spacecraftFloat {

    0%,
    100% {
        transform:
            translate(0, 0)
            rotate(-15deg);
    }

    50% {
        transform:
            translate(20px, -15px)
            rotate(5deg);
    }
}


@keyframes giantSunPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.06);
    }
}


@keyframes solarFlare {

    0%,
    100% {
        opacity: 0.25;
        scale: 0.8;
    }

    50% {
        opacity: 0.9;
        scale: 1.15;
    }
}


@keyframes galaxySpin {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}


@keyframes galaxySpinTwo {

    from {
        transform: rotate(90deg);
    }

    to {
        transform: rotate(450deg);
    }
}


@keyframes galaxyStarsSpin {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(-360deg);
    }
}


@keyframes alienStarPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }
}


@keyframes alienOrbit {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}


@keyframes blackHoleStars {

    from {
        transform:
            rotate(0deg)
            scale(1);
    }

    to {
        transform:
            rotate(360deg)
            scale(1.15);
    }
}


@keyframes blackHoleBreathe {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.035);
    }
}


@keyframes accretionPulse {

    0%,
    100% {
        filter:
            blur(2px)
            brightness(0.9)
            drop-shadow(
                0 0 15px
                rgba(255, 130, 40, 0.65)
            );
    }

    50% {
        filter:
            blur(1px)
            brightness(1.35)
            drop-shadow(
                0 0 30px
                rgba(255, 175, 70, 0.9)
            );
    }
}


@keyframes gravityGlow {

    0%,
    100% {
        transform: scale(0.92);
        opacity: 0.55;
    }

    50% {
        transform: scale(1.08);
        opacity: 1;
    }
}


/* =========================================================
   44. RESPONSIVE — PART 3
========================================================= */

@media
(max-width: 1100px) {

    .dwarf-grid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }


    .black-hole-lab {
        grid-template-columns: 1fr;
    }


    .black-hole-visualization {
        min-height: 550px;
    }

}


@media
(max-width: 850px) {

    .moon-feature,
    .sun-feature,
    .galaxy-feature,
    .exoplanet-display {
        grid-template-columns: 1fr;
    }


    .moon-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }


    .small-body-grid {
        grid-template-columns: 1fr;
    }


    .star-life-track {
        flex-direction: column;
    }


    .life-arrow {
        transform: rotate(90deg);
    }


    .galaxy-types {
        grid-template-columns: 1fr;
    }

}


@media
(max-width: 600px) {

    .moon-grid,
    .dwarf-grid {
        grid-template-columns: 1fr;
    }


    .moon-feature-content,
    .sun-information,
    .galaxy-information,
    .exoplanet-information,
    .black-hole-information {
        padding: 30px 22px;
    }


    .moon-visual,
    .sun-visual,
    .milky-way-visual,
    .alien-star-system {
        min-height: 400px;
    }


    .black-hole-visualization {
        min-height: 450px;
    }


    .black-hole-shadow {
        width: 145px;
        height: 145px;
    }


    .event-horizon {
        width: 130px;
        height: 130px;
    }


    .accretion-disk {
        width: 320px;
        height: 100px;
    }


    .gravity-glow {
        width: 290px;
        height: 290px;
    }


    .galaxy-arm {
        width: 280px;
        height: 140px;
    }


    .galaxy-star-field {
        width: 330px;
        height: 330px;
    }


    .alien-orbit {
        width: 270px;
        height: 270px;
    }

}

/* =========================================================
   COSMOVERSE 3.0
   STYLE.CSS — PART 4
   Observatory • Missions • ISS • Videos • Quiz • AI
========================================================= */


/* =========================================================
   45. DEEP SPACE OBSERVATORY
========================================================= */

.observatory-dashboard {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;

    min-height: 600px;

    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(7, 20, 42, 0.92),
            rgba(3, 8, 20, 0.96)
        );

    box-shadow: var(--shadow-large);
}


.telescope-view {
    position: relative;

    min-height: 600px;

    display: flex;
    flex-direction: column;

    overflow: hidden;

    background:
        radial-gradient(
            circle at center,
            rgba(60, 110, 220, 0.12),
            transparent 45%
        ),
        #02050d;
}


.telescope-hud {
    position: relative;

    z-index: 20;

    display: flex;
    justify-content: space-between;

    padding: 18px 22px;

    color: var(--cyan);

    font-size: 0.7rem;
    font-weight: 800;

    letter-spacing: 0.13em;

    border-bottom:
        1px solid
        rgba(100, 200, 255, 0.1);
}


.telescope-screen {
    position: relative;

    flex: 1;

    display: grid;
    place-items: center;

    overflow: hidden;

    background-image:
        radial-gradient(
            circle,
            rgba(255,255,255,0.85) 1px,
            transparent 1.5px
        );

    background-size: 55px 55px;
}


.telescope-screen::after {
    content: "";

    position: absolute;

    width: 85%;
    height: 85%;

    border:
        1px solid
        rgba(80, 220, 255, 0.12);

    border-radius: 50%;

    box-shadow:
        inset 0 0 80px
        rgba(0, 0, 0, 0.8);
}


.scope-ring {
    position: absolute;

    border:
        1px solid
        rgba(70, 220, 255, 0.25);

    border-radius: 50%;

    pointer-events: none;
}


.ring-a {
    width: 70%;
    aspect-ratio: 1;

    animation:
        scopeRotate
        18s linear infinite;
}


.ring-b {
    width: 45%;
    aspect-ratio: 1;

    border-style: dashed;

    animation:
        scopeRotateReverse
        13s linear infinite;
}


.scope-crosshair::before,
.scope-crosshair::after {
    content: "";

    position: absolute;

    z-index: 3;

    background:
        linear-gradient(
            transparent,
            rgba(80, 220, 255, 0.25),
            transparent
        );
}


.scope-crosshair::before {
    top: 10%;
    bottom: 10%;

    left: 50%;

    width: 1px;
}


.scope-crosshair::after {
    left: 10%;
    right: 10%;

    top: 50%;

    height: 1px;
}


.target-visual {
    position: relative;

    z-index: 10;

    font-size:
        clamp(
            100px,
            15vw,
            180px
        );

    filter:
        drop-shadow(
            0 0 30px
            rgba(100, 180, 255, 0.4)
        );

    animation:
        targetFloat
        5s ease-in-out infinite;
}


.observatory-controls {
    align-self: center;

    padding: 45px;
}


.observatory-controls h3 {
    margin-bottom: 10px;

    font-size:
        clamp(
            2rem,
            4vw,
            3.2rem
        );
}


.observatory-controls p {
    margin-bottom: 25px;

    color: var(--text-secondary);
}


.observatory-controls label {
    display: block;

    margin-bottom: 8px;

    color: var(--text-muted);

    font-size: 0.8rem;
    font-weight: 700;
}


.observatory-controls select {
    width: 100%;
}


.observatory-controls
.primary-button {
    width: 100%;

    margin-top: 12px;
}


.observation-data {
    min-height: 120px;

    margin-top: 20px;

    padding: 18px;

    border:
        1px solid
        var(--border);

    border-radius: 14px;

    background:
        rgba(255,255,255,0.025);

    color:
        var(--text-secondary);
}


/* =========================================================
   46. SOURCE NOTICES
========================================================= */

.source-notice,
.company-source-warning {
    max-width: 850px;

    margin:
        -25px auto 35px;

    padding: 16px 20px;

    display: flex;
    align-items: center;

    gap: 16px;

    border:
        1px solid
        rgba(80, 210, 255, 0.16);

    border-radius: 14px;

    background:
        rgba(40, 160, 255, 0.045);
}


.source-notice span,
.company-source-warning strong {
    flex-shrink: 0;

    color: var(--cyan);

    font-size: 0.72rem;

    letter-spacing: 0.1em;
}


.source-notice p,
.company-source-warning p {
    color: var(--text-secondary);

    font-size: 0.85rem;
}


/* =========================================================
   47. NASA MISSIONS
========================================================= */

.mission-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 16px;
}


.mission-card {
    position: relative;

    min-height: 340px;

    display: flex;
    flex-direction: column;

    padding: 28px;

    overflow: hidden;

    border:
        1px solid
        var(--border);

    border-radius: 20px;

    background:
        radial-gradient(
            circle at top right,
            rgba(60, 130, 255, 0.1),
            transparent 42%
        ),
        linear-gradient(
            145deg,
            rgba(12, 25, 50, 0.8),
            rgba(5, 12, 26, 0.86)
        );

    transition:
        transform var(--transition),
        border-color var(--transition),
        box-shadow var(--transition);
}


.mission-card:hover {
    transform: translateY(-7px);

    border-color:
        rgba(100, 190, 255, 0.4);

    box-shadow:
        0 20px 50px
        rgba(0, 0, 0, 0.35);
}


.mission-icon {
    margin-bottom: 20px;

    font-size: 58px;
}


.mission-status {
    width: fit-content;

    margin-bottom: 10px;

    padding: 5px 8px;

    border:
        1px solid
        rgba(70, 220, 255, 0.15);

    border-radius: 7px;

    color: var(--cyan);

    font-size: 0.62rem;
    font-weight: 800;

    letter-spacing: 0.1em;
}


.mission-card h3 {
    margin-bottom: 10px;

    font-size: 1.4rem;
}


.mission-card p {
    margin-bottom: 25px;

    color: var(--text-secondary);

    font-size: 0.9rem;
}


.mission-details-button {
    width: 100%;

    margin-top: auto;

    border:
        1px solid
        var(--border-bright);

    background:
        rgba(60, 140, 255, 0.08);

    color: white;
}


.mission-details-button:hover {
    transform: translateY(-2px);

    background:
        rgba(60, 150, 255, 0.15);
}


.official-source-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;

    gap: 10px;

    margin-top: 30px;
}


/* =========================================================
   48. SPACEX CENTER
========================================================= */

.spacex-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 15px;
}


.spacecraft-card {
    min-height: 300px;

    padding: 28px;

    border:
        1px solid
        var(--border);

    border-radius: 20px;

    background:
        linear-gradient(
            145deg,
            rgba(13, 26, 49, 0.75),
            rgba(5, 11, 24, 0.86)
        );

    text-align: center;

    transition:
        transform var(--transition),
        border-color var(--transition);
}


.spacecraft-card:hover {
    transform: translateY(-7px);

    border-color:
        rgba(100, 190, 255, 0.4);
}


.spacecraft-visual {
    min-height: 110px;

    display: grid;
    place-items: center;

    font-size: 75px;

    animation:
        rocketHover
        5s ease-in-out infinite;
}


.spacecraft-card h3 {
    margin-bottom: 10px;

    font-size: 1.4rem;
}


.spacecraft-card p {
    color: var(--text-secondary);

    font-size: 0.9rem;
}


/* =========================================================
   49. ISS CENTER
========================================================= */

.iss-dashboard {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    min-height: 570px;

    overflow: hidden;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-large);

    background:
        linear-gradient(
            135deg,
            rgba(8, 23, 48, 0.88),
            rgba(3, 9, 22, 0.94)
        );

    box-shadow:
        var(--shadow-large);
}


.iss-orbit-visual {
    position: relative;

    min-height: 570px;

    display: grid;
    place-items: center;

    overflow: hidden;

    background:
        radial-gradient(
            circle,
            rgba(50, 120, 255, 0.14),
            transparent 50%
        );
}


.iss-orbit-visual::before {
    content: "ORBIT SIMULATION — NOT LIVE";

    position: absolute;

    top: 20px;
    left: 20px;

    color: var(--cyan);

    font-size: 0.65rem;
    font-weight: 800;

    letter-spacing: 0.13em;
}


.iss-earth {
    position: relative;

    z-index: 5;

    font-size:
        clamp(
            120px,
            20vw,
            220px
        );

    filter:
        drop-shadow(
            0 0 30px
            rgba(70, 150, 255, 0.5)
        );

    animation:
        earthFloat
        5s ease-in-out infinite;
}


.iss-orbit-ring {
    position: absolute;

    z-index: 10;

    width: 390px;
    height: 390px;

    border:
        1px solid
        rgba(100, 210, 255, 0.3);

    border-radius: 50%;

    animation:
        issOrbit
        10s linear infinite;
}


.iss-space-station {
    position: absolute;

    top: 50%;
    left: -25px;

    font-size: 50px;

    transform:
        translateY(-50%);

    filter:
        drop-shadow(
            0 0 12px
            rgba(200, 230, 255, 0.5)
        );
}


.iss-information {
    align-self: center;

    padding: 45px;
}


.iss-information h3 {
    margin-bottom: 12px;

    font-size:
        clamp(
            2rem,
            4vw,
            3.5rem
        );
}


.iss-information > p {
    color: var(--text-secondary);
}


.iss-stat-grid {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    gap: 10px;

    margin: 25px 0;
}


.iss-stat-grid > div {
    padding: 16px;

    border:
        1px solid
        var(--border);

    border-radius: 12px;

    background:
        rgba(255,255,255,0.025);
}


.iss-stat-grid span {
    display: block;

    margin-bottom: 5px;

    color: var(--text-muted);

    font-size: 0.7rem;

    text-transform: uppercase;
}


.iss-stat-grid strong {
    font-size: 0.9rem;
}


/* =========================================================
   50. VIDEO CENTER
========================================================= */

.video-feature {
    display: grid;

    grid-template-columns:
        1.1fr 0.9fr;

    overflow: hidden;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-large);

    background:
        rgba(7, 16, 33, 0.84);
}


.video-placeholder {
    position: relative;

    min-height: 430px;

    display: grid;
    place-items: center;

    overflow: hidden;

    background:
        radial-gradient(
            circle,
            rgba(70, 130, 255, 0.15),
            transparent 45%
        ),
        #020611;

    font-size: 160px;
}


.video-play-symbol {
    position: absolute;

    width: 80px;
    height: 80px;

    display: grid;
    place-items: center;

    border:
        1px solid
        rgba(255,255,255,0.3);

    border-radius: 50%;

    background:
        rgba(3, 8, 20, 0.75);

    font-size: 30px;

    backdrop-filter: blur(12px);
}


.video-feature-info {
    align-self: center;

    padding: 45px;
}


.video-feature-info h3 {
    margin-bottom: 12px;

    font-size:
        clamp(
            2.2rem,
            5vw,
            4rem
        );
}


.video-feature-info p {
    margin-bottom: 25px;

    color: var(--text-secondary);
}


.video-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 15px;

    margin-top: 20px;
}


.video-card {
    padding: 20px;

    border:
        1px solid
        var(--border);

    border-radius: 18px;

    background:
        rgba(255,255,255,0.025);

    transition:
        transform var(--transition),
        border-color var(--transition);
}


.video-card:hover {
    transform: translateY(-6px);

    border-color:
        rgba(100, 190, 255, 0.4);
}


.video-thumbnail {
    min-height: 130px;

    display: grid;
    place-items: center;

    margin-bottom: 18px;

    border-radius: 13px;

    background:
        radial-gradient(
            circle,
            rgba(70, 130, 255, 0.15),
            #030814
        );

    font-size: 70px;
}


.video-card > span {
    color: var(--cyan);

    font-size: 0.65rem;
    font-weight: 800;

    letter-spacing: 0.1em;
}


.video-card h3 {
    margin: 7px 0;
}


.video-card p {
    color: var(--text-secondary);

    font-size: 0.86rem;
}


/* =========================================================
   51. SPACE ACADEMY / XP
========================================================= */

.academy-dashboard {
    max-width: 900px;

    margin:
        0 auto 30px;

    padding: 25px;

    border:
        1px solid
        var(--border);

    border-radius: 20px;

    background:
        linear-gradient(
            135deg,
            rgba(18, 37, 70, 0.75),
            rgba(5, 12, 27, 0.85)
        );
}


.explorer-profile {
    display: flex;
    align-items: center;

    gap: 16px;
}


.rank-icon {
    width: 65px;
    height: 65px;

    display: grid;
    place-items: center;

    border:
        1px solid
        rgba(100, 200, 255, 0.25);

    border-radius: 18px;

    background:
        rgba(70, 150, 255, 0.08);

    font-size: 35px;
}


.explorer-profile span {
    color: var(--text-muted);

    font-size: 0.7rem;
    font-weight: 800;

    letter-spacing: 0.1em;
}


.explorer-profile h3 {
    font-size: 1.4rem;
}


.xp-number {
    margin-left: auto;

    text-align: right;
}


.xp-number strong {
    display: block;

    color: var(--cyan);

    font-size: 1.8rem;
}


.xp-bar-container {
    height: 10px;

    margin-top: 20px;

    overflow: hidden;

    border-radius: 999px;

    background:
        rgba(255,255,255,0.07);
}


.xp-bar {
    width: 0%;
    height: 100%;

    border-radius: inherit;

    background:
        linear-gradient(
            90deg,
            var(--blue),
            var(--cyan),
            var(--purple)
        );

    box-shadow:
        0 0 16px
        rgba(80, 190, 255, 0.5);

    transition:
        width 0.5s ease;
}


#xpProgress {
    margin-top: 8px;

    color: var(--text-muted);

    font-size: 0.78rem;

    text-align: right;
}


/* =========================================================
   52. QUIZ CATEGORIES
========================================================= */

.quiz-category-grid {
    max-width: 1000px;

    margin:
        0 auto 25px;

    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 10px;
}


.quiz-category {
    min-height: 135px;

    padding: 18px;

    border:
        1px solid
        var(--border);

    border-radius: 16px;

    background:
        rgba(255,255,255,0.025);

    cursor: pointer;

    transition:
        transform var(--transition),
        border-color var(--transition),
        background var(--transition);
}


.quiz-category:hover {
    transform: translateY(-5px);

    border-color:
        rgba(100, 190, 255, 0.4);
}


.quiz-category.active {
    border-color:
        rgba(80, 210, 255, 0.5);

    background:
        rgba(60, 150, 255, 0.1);

    box-shadow:
        var(--glow-blue);
}


.quiz-category span {
    display: block;

    margin-bottom: 8px;

    font-size: 32px;
}


.quiz-category strong {
    display: block;
}


.quiz-category small {
    color: var(--text-muted);
}


/* =========================================================
   53. QUIZ PLAYER
========================================================= */

.quiz-player {
    max-width: 900px;

    margin-inline: auto;

    padding: 35px;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-large);

    background:
        linear-gradient(
            145deg,
            rgba(12, 26, 51, 0.85),
            rgba(5, 11, 25, 0.9)
        );

    box-shadow:
        var(--shadow-large);
}


.quiz-header {
    display: flex;
    justify-content: space-between;

    gap: 20px;

    color: var(--cyan);

    font-size: 0.72rem;
    font-weight: 800;

    letter-spacing: 0.1em;
}


.quiz-progress {
    height: 5px;

    margin: 14px 0 30px;

    overflow: hidden;

    border-radius: 999px;

    background:
        rgba(255,255,255,0.06);
}


#quizProgressBar {
    width: 20%;
    height: 100%;

    background:
        linear-gradient(
            90deg,
            var(--blue),
            var(--cyan)
        );

    transition:
        width 0.4s ease;
}


#quizQuestion {
    margin-bottom: 25px;

    font-size:
        clamp(
            1.5rem,
            4vw,
            2.3rem
        );
}


.quiz-answers {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    gap: 10px;
}


.quiz-answer {
    min-height: 70px;

    padding: 15px 18px;

    border:
        1px solid
        var(--border);

    border-radius: 13px;

    background:
        rgba(255,255,255,0.03);

    color: var(--text-main);

    text-align: left;

    cursor: pointer;

    transition:
        transform var(--transition),
        border-color var(--transition),
        background var(--transition);
}


.quiz-answer:hover:not(:disabled) {
    transform: translateY(-2px);

    border-color:
        rgba(100, 190, 255, 0.45);

    background:
        rgba(60, 150, 255, 0.08);
}


.quiz-answer.correct {
    border-color:
        rgba(85, 230, 165, 0.6);

    background:
        rgba(85, 230, 165, 0.1);
}


.quiz-answer.incorrect {
    border-color:
        rgba(255, 100, 124, 0.6);

    background:
        rgba(255, 100, 124, 0.09);
}


.quiz-feedback {
    min-height: 50px;

    margin-top: 18px;

    color: var(--text-secondary);
}


#nextQuizQuestion {
    margin-top: 12px;
}


#nextQuizQuestion:disabled {
    opacity: 0.45;

    cursor: not-allowed;

    transform: none;
}


/* =========================================================
   54. ACHIEVEMENTS
========================================================= */

.achievement-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 14px;
}


.achievement-card {
    padding: 25px;

    border:
        1px solid
        rgba(255, 210, 90, 0.25);

    border-radius: 18px;

    background:
        rgba(255, 200, 70, 0.04);

    text-align: center;

    transition:
        transform var(--transition),
        opacity var(--transition);
}


.achievement-card span {
    display: block;

    margin-bottom: 10px;

    font-size: 45px;
}


.achievement-card p {
    margin-top: 5px;

    color: var(--text-secondary);

    font-size: 0.85rem;
}


.achievement-card.locked {
    opacity: 0.38;

    filter: grayscale(0.75);
}


.achievement-card.unlocked {
    opacity: 1;

    box-shadow:
        0 0 30px
        rgba(255, 205, 80, 0.08);
}


/* =========================================================
   55. COSMO AI
========================================================= */

.ai-console {
    display: grid;

    grid-template-columns:
        280px 1fr;

    min-height: 650px;

    overflow: hidden;

    border:
        1px solid
        rgba(100, 190, 255, 0.2);

    border-radius:
        var(--radius-large);

    background:
        rgba(5, 12, 27, 0.9);

    box-shadow:
        var(--shadow-large);
}


.ai-sidebar {
    padding: 30px 20px;

    border-right:
        1px solid
        var(--border);

    background:
        linear-gradient(
            180deg,
            rgba(15, 34, 65, 0.85),
            rgba(6, 15, 32, 0.9)
        );
}


.ai-avatar {
    width: 85px;
    height: 85px;

    display: grid;
    place-items: center;

    margin:
        0 auto 15px;

    border:
        1px solid
        rgba(80, 220, 255, 0.3);

    border-radius: 24px;

    background:
        linear-gradient(
            135deg,
            rgba(50, 150, 255, 0.15),
            rgba(150, 80, 255, 0.15)
        );

    font-size: 48px;

    box-shadow:
        var(--glow-blue);

    animation:
        aiFloat
        4s ease-in-out infinite;
}


.ai-sidebar h3 {
    text-align: center;

    font-size: 1.5rem;
}


.ai-status {
    display: block;

    margin-bottom: 25px;

    color: var(--green);

    font-size: 0.75rem;

    text-align: center;
}


.ai-suggestion {
    width: 100%;

    margin-bottom: 8px;

    padding: 13px;

    border:
        1px solid
        var(--border);

    border-radius: 11px;

    background:
        rgba(255,255,255,0.025);

    color: var(--text-secondary);

    text-align: left;

    cursor: pointer;

    transition:
        background var(--transition),
        color var(--transition),
        border-color var(--transition);
}


.ai-suggestion:hover {
    color: white;

    border-color:
        rgba(100, 190, 255, 0.35);

    background:
        rgba(60, 150, 255, 0.08);
}


.ai-chat {
    display: flex;
    flex-direction: column;

    min-width: 0;
}


.ai-messages {
    flex: 1;

    min-height: 500px;
    max-height: 600px;

    overflow-y: auto;

    padding: 30px;
}


.ai-message {
    display: flex;

    gap: 12px;

    max-width: 750px;

    margin-bottom: 20px;
}


.message-avatar {
    flex-shrink: 0;

    width: 38px;
    height: 38px;

    display: grid;
    place-items: center;

    border-radius: 11px;

    background:
        rgba(70, 150, 255, 0.1);
}


.ai-message > div:last-child {
    padding: 14px 17px;

    border:
        1px solid
        var(--border);

    border-radius:
        4px 15px 15px 15px;

    background:
        rgba(255,255,255,0.035);
}


.ai-message p {
    margin-top: 5px;

    color: var(--text-secondary);
}


.user-message {
    margin-left: auto;

    flex-direction: row-reverse;
}


.user-message > div:last-child {
    border-radius:
        15px 4px 15px 15px;

    background:
        rgba(55, 135, 255, 0.11);
}


.ai-input-area {
    display: grid;

    grid-template-columns:
        1fr auto;

    gap: 8px;

    padding: 15px;

    border-top:
        1px solid
        var(--border);
}


.ai-input-area input {
    width: 100%;
}


.ai-input-area button {
    padding:
        0 22px;

    border:
        1px solid
        rgba(80, 210, 255, 0.4);

    border-radius: 12px;

    background:
        linear-gradient(
            135deg,
            #1878ff,
            #7655ff
        );

    color: white;

    font-weight: 800;

    cursor: pointer;
}


.ai-disclaimer {
    padding:
        0 20px 15px;

    color: var(--text-muted);

    font-size: 0.72rem;

    text-align: center;
}


/* =========================================================
   56. OVERLAYS
========================================================= */

.overlay {
    position: fixed;
    inset: 0;

    z-index: 9000;

    display: none;
    align-items: center;
    justify-content: center;

    padding: 20px;

    background:
        rgba(0, 3, 10, 0.78);

    backdrop-filter: blur(14px);
}


.overlay.open {
    display: flex;
}


.search-panel,
.favorites-panel,
.information-modal {
    position: relative;

    width: min(700px, 100%);
    max-height: 85vh;

    overflow-y: auto;

    padding: 35px;

    border:
        1px solid
        var(--border-bright);

    border-radius:
        var(--radius-large);

    background:
        linear-gradient(
            145deg,
            #0b1930,
            #050c1b
        );

    box-shadow:
        0 30px 100px
        rgba(0,0,0,0.65);
}


.search-panel h2,
.favorites-panel h2 {
    margin-bottom: 20px;
}


#universalSearch {
    width: 100%;
}


#searchResults,
#favoritesList {
    display: grid;

    gap: 8px;

    margin-top: 18px;
}


.search-result-item,
.favorite-item {
    padding: 15px;

    border:
        1px solid
        var(--border);

    border-radius: 12px;

    background:
        rgba(255,255,255,0.025);
}


.close-overlay {
    position: absolute;

    top: 15px;
    right: 15px;

    width: 40px;
    height: 40px;

    display: grid;
    place-items: center;

    border:
        1px solid
        var(--border);

    border-radius: 11px;

    background:
        rgba(255,255,255,0.04);

    cursor: pointer;
}


/* =========================================================
   57. FOOTER
========================================================= */

.main-footer {
    width:
        min(
            calc(100% - 40px),
            var(--max-width)
        );

    margin:
        80px auto 25px;

    padding: 40px;

    display: grid;

    grid-template-columns:
        1fr 1fr 1fr;

    gap: 35px;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius-large);

    background:
        rgba(6, 14, 29, 0.78);
}


.footer-brand h2 {
    margin-bottom: 7px;
}


.footer-brand p,
.footer-note p {
    color: var(--text-secondary);

    font-size: 0.88rem;
}


.footer-links {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    gap: 8px;
}


.footer-links a {
    color: var(--text-secondary);

    font-size: 0.86rem;

    transition:
        color var(--transition);
}


.footer-links a:hover {
    color: var(--cyan);
}


/* =========================================================
   58. BACK TO TOP
========================================================= */

.back-to-top {
    position: fixed;

    right: 20px;
    bottom: 20px;

    z-index: 4000;

    width: 48px;
    height: 48px;

    display: grid;
    place-items: center;

    border:
        1px solid
        var(--border-bright);

    border-radius: 14px;

    background:
        rgba(8, 20, 40, 0.85);

    color: white;

    font-size: 1.2rem;

    cursor: pointer;

    backdrop-filter: blur(12px);

    opacity: 0;
    visibility: hidden;

    transform:
        translateY(15px);

    transition:
        opacity var(--transition),
        transform var(--transition),
        visibility var(--transition);
}


.back-to-top.visible {
    opacity: 1;
    visibility: visible;

    transform:
        translateY(0);
}


/* =========================================================
   59. FINAL ANIMATIONS
========================================================= */

@keyframes scopeRotate {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}


@keyframes scopeRotateReverse {

    from {
        transform: rotate(360deg);
    }

    to {
        transform: rotate(0deg);
    }
}


@keyframes targetFloat {

    0%,
    100% {
        transform:
            translateY(0)
            scale(1);
    }

    50% {
        transform:
            translateY(-12px)
            scale(1.03);
    }
}


@keyframes rocketHover {

    0%,
    100% {
        transform:
            translateY(0)
            rotate(-3deg);
    }

    50% {
        transform:
            translateY(-12px)
            rotate(3deg);
    }
}


@keyframes earthFloat {

    0%,
    100% {
        transform:
            translateY(0)
            rotate(-2deg);
    }

    50% {
        transform:
            translateY(-8px)
            rotate(2deg);
    }
}


@keyframes issOrbit {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}


@keyframes aiFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-7px);
    }
}


/* =========================================================
   60. FINAL RESPONSIVE DESIGN
========================================================= */

@media
(max-width: 1100px) {

    .observatory-dashboard {
        grid-template-columns: 1fr;
    }


    .mission-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }


    .spacex-grid,
    .video-grid,
    .achievement-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }


    .iss-dashboard {
        grid-template-columns: 1fr;
    }


    .video-feature {
        grid-template-columns: 1fr;
    }

}


@media
(max-width: 800px) {

    .ai-console {
        grid-template-columns: 1fr;
    }


    .ai-sidebar {
        border-right: none;

        border-bottom:
            1px solid
            var(--border);
    }


    .quiz-category-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }


    .main-footer {
        grid-template-columns: 1fr;
    }

}


@media
(max-width: 600px) {

    .observatory-controls,
    .iss-information,
    .video-feature-info {
        padding: 30px 22px;
    }


    .telescope-view {
        min-height: 430px;
    }


    .mission-grid,
    .spacex-grid,
    .video-grid,
    .achievement-grid,
    .quiz-category-grid {
        grid-template-columns: 1fr;
    }


    .iss-orbit-visual {
        min-height: 430px;
    }


    .iss-orbit-ring {
        width: 290px;
        height: 290px;
    }


    .iss-space-station {
        font-size: 38px;
    }


    .iss-stat-grid {
        grid-template-columns: 1fr;
    }


    .video-placeholder {
        min-height: 320px;

        font-size: 110px;
    }


    .explorer-profile {
        align-items: flex-start;
    }


    .rank-icon {
        width: 52px;
        height: 52px;

        font-size: 28px;
    }


    .quiz-player {
        padding: 25px 18px;
    }


    .quiz-answers {
        grid-template-columns: 1fr;
    }


    .quiz-header {
        flex-direction: column;

        gap: 5px;
    }


    .ai-messages {
        padding: 18px;
    }


    .ai-input-area {
        grid-template-columns: 1fr;
    }


    .ai-input-area button {
        min-height: 48px;
    }


    .source-notice,
    .company-source-warning {
        align-items: flex-start;
        flex-direction: column;

        gap: 5px;
    }


    .main-footer {
        width:
            calc(100% - 28px);

        padding: 28px 22px;
    }

}


/* =========================================================
   61. ACCESSIBILITY FOCUS
========================================================= */

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
    outline:
        3px solid
        rgba(80, 210, 255, 0.55);

    outline-offset: 3px;
}


/* =========================================================
   END OF COSMOVERSE 3.0 CSS
========================================================= */

/* =========================================================
   FINAL ACCOUNT PANEL LAYOUT
========================================================= */

#accountOverlay {
    position: fixed;
    inset: 0;
    z-index: 10000;

    display: none;
    align-items: center;
    justify-content: center;

    padding: 24px;

    background: rgba(2, 6, 18, 0.82);

    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

#accountOverlay.open {
    display: flex;
}


/* ACCOUNT CARD */

#accountOverlay .account-panel {
    position: relative;

    width: min(560px, 100%);
    max-height: calc(100vh - 48px);

    overflow-y: auto;

    padding: 34px;

    border: 1px solid rgba(87, 211, 255, 0.22);
    border-radius: 24px;

    background:
        linear-gradient(
            145deg,
            rgba(10, 18, 40, 0.98),
            rgba(15, 11, 38, 0.98)
        );

    box-shadow:
        0 30px 100px rgba(0, 0, 0, 0.65),
        0 0 60px rgba(70, 120, 255, 0.12);
}


/* CLOSE BUTTON */

#accountOverlay .close-overlay {
    position: absolute;
    top: 16px;
    right: 16px;

    width: 42px;
    height: 42px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 12px;

    background: rgba(255,255,255,0.04);

    color: white;

    font-size: 1.4rem;
    cursor: pointer;
}


/* HEADER */

#accountOverlay .account-header {
    display: flex;
    align-items: center;
    gap: 18px;

    padding-right: 45px;
    margin-bottom: 26px;
}


/* TABS */

#accountOverlay .account-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;

    gap: 6px;

    padding: 5px;
    margin-bottom: 24px;

    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 14px;

    background: rgba(255,255,255,0.025);
}


#accountOverlay .account-tab {
    appearance: none;

    padding: 12px;

    border: none;
    border-radius: 10px;

    background: transparent;

    color: var(--text-secondary);

    font: inherit;
    font-weight: 700;

    cursor: pointer;
}


#accountOverlay .account-tab.active {
    color: white;

    background:
        linear-gradient(
            135deg,
            #278dff,
            #744cff
        );

    box-shadow:
        0 6px 25px rgba(74, 104, 255, 0.25);
}


/* VERY IMPORTANT:
   ONLY ONE FORM IS VISIBLE
*/

#accountOverlay .account-form {
    display: none !important;
}


#accountOverlay .account-form.active {
    display: block !important;
}


/* FORM FIELDS */

#accountOverlay .form-group {
    display: block;
    margin-bottom: 18px;
}


#accountOverlay .form-group label {
    display: block;

    margin-bottom: 8px;

    color: var(--text-secondary);
    font-weight: 700;
}


#accountOverlay .form-group input {
    display: block;

    width: 100%;

    padding: 14px 15px;

    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;

    background: rgba(255,255,255,0.035);

    color: white;

    font: inherit;

    outline: none;
}


#accountOverlay .form-group input:focus {
    border-color: #55d5ff;

    box-shadow:
        0 0 0 3px rgba(85, 213, 255, 0.12);
}


/* SUBMIT BUTTON */

#accountOverlay .account-submit {
    display: flex;
    justify-content: center;

    width: 100%;

    margin-top: 8px;
}


/* PROFILE */

#accountOverlay .account-profile[hidden] {
    display: none !important;
}


/* MOBILE */

@media (max-width: 600px) {

    #accountOverlay {
        padding: 12px;
    }

    #accountOverlay .account-panel {
        padding: 26px 18px;

        max-height:
            calc(100vh - 24px);
    }

    #accountOverlay .account-header {
        align-items: flex-start;
    }

}

/* =========================================================
   ACCOUNT NAV BUTTON FINAL FIX
========================================================= */

#accountButton {
    appearance: none !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;

    width: auto !important;
    min-width: max-content !important;
    height: 44px !important;

    padding: 0 15px !important;

    border: 1px solid rgba(91, 173, 255, 0.35) !important;
    border-radius: 12px !important;

    background:
        linear-gradient(
            135deg,
            rgba(43, 111, 255, 0.20),
            rgba(118, 70, 255, 0.20)
        ) !important;

    color: #ffffff !important;

    font: inherit !important;
    font-weight: 700 !important;

    cursor: pointer !important;

    box-shadow: none !important;

    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        background 0.2s ease,
        box-shadow 0.2s ease !important;
}


#accountButton:hover {
    transform: translateY(-2px) !important;

    border-color:
        rgba(90, 215, 255, 0.8) !important;

    background:
        linear-gradient(
            135deg,
            rgba(43, 111, 255, 0.35),
            rgba(118, 70, 255, 0.32)
        ) !important;

    box-shadow:
        0 0 20px
        rgba(65, 160, 255, 0.18) !important;
}


#accountButton .account-icon {
    color: inherit !important;
    font-size: 1.1rem !important;
}


#accountButtonText {
    color: #ffffff !important;
    white-space: nowrap !important;
}

/* =========================================================
   COSMOVERSE RESPONSIVE DESIGN
   PART 1 — NAVBAR + HEADER
========================================================= */

/* ---------- TABLETS ---------- */

@media (max-width: 1024px) {

    .site-header {
        padding-left: 20px;
        padding-right: 20px;
    }

    .main-nav {
        gap: 12px;
    }

    .nav-links {
        gap: 8px;
    }

    .nav-links a {
        font-size: 0.9rem;
    }

    .nav-actions {
        gap: 8px;
    }

}


/* ---------- PHONES ---------- */

@media (max-width: 768px) {

    body {
        overflow-x: hidden;
    }

    .site-header {
        padding: 10px 14px;
    }

    .main-nav {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }


    /* LOGO */

    .logo {
        position: relative;
        z-index: 1002;
    }

    .logo-text {
        font-size: 1.05rem;
    }


    /* MOBILE MENU BUTTON */

    #mobileMenuButton {
        display: flex;
        align-items: center;
        justify-content: center;

        width: 44px;
        height: 44px;

        padding: 0;

        border: 1px solid rgba(100, 190, 255, 0.25);
        border-radius: 12px;

        background:
            linear-gradient(
                135deg,
                rgba(36, 105, 255, 0.18),
                rgba(117, 65, 255, 0.18)
            );

        color: white;

        font-size: 1.4rem;

        cursor: pointer;

        position: relative;
        z-index: 1002;
    }


    /* MOBILE NAVIGATION */

    .nav-links {
        position: fixed;

        top: 0;
        right: -100%;

        width: min(320px, 85vw);
        height: 100dvh;

        padding:
            90px
            22px
            30px;

        display: flex;
        flex-direction: column;
        align-items: stretch;

        gap: 8px;

        overflow-y: auto;

        background:
            linear-gradient(
                180deg,
                rgba(6, 12, 31, 0.99),
                rgba(12, 8, 32, 0.99)
            );

        border-left:
            1px solid
            rgba(90, 190, 255, 0.18);

        box-shadow:
            -30px 0 80px
            rgba(0, 0, 0, 0.55);

        transition:
            right 0.3s ease;

        z-index: 1001;
    }


    .nav-links.open {
        right: 0;
    }


    .nav-links a {
        width: 100%;

        padding: 13px 14px;

        border-radius: 10px;

        font-size: 1rem;

        text-align: left;
    }


    .nav-links a:hover,
    .nav-links a.active {
        background:
            rgba(74, 134, 255, 0.12);
    }


    /* HEADER BUTTONS */

    .nav-actions {
        margin-left: auto;
        margin-right: 8px;

        gap: 5px;
    }


    .nav-actions button {
        min-width: 42px;
        height: 42px;
    }


    /* ACCOUNT BUTTON */

    #accountButton {
        min-width: 42px !important;
        width: 42px !important;
        height: 42px !important;

        padding: 0 !important;
    }


    #accountButtonText {
        display: none !important;
    }


    /* HERO */

    .hero {
        min-height: auto;

        padding:
            125px
            18px
            70px;
    }


    .hero-content {
        width: 100%;
        max-width: 680px;

        margin: 0 auto;

        text-align: center;
    }


    .hero h1 {
        font-size:
            clamp(
                2.3rem,
                11vw,
                4rem
            );

        line-height: 1.02;
    }


    .hero p {
        max-width: 540px;

        margin-left: auto;
        margin-right: auto;

        font-size: 1rem;
        line-height: 1.7;
    }


    .hero-actions {
        display: flex;
        flex-direction: column;

        width: 100%;

        gap: 12px;
    }


    .hero-actions button,
    .hero-actions a {
        width: 100%;

        justify-content: center;
    }

}


/* ---------- SMALL PHONES ---------- */

@media (max-width: 480px) {

    .site-header {
        padding-left: 10px;
        padding-right: 10px;
    }


    .logo-text {
        font-size: 0.95rem;
    }


    .nav-actions {
        gap: 4px;
    }


    .hero {
        padding-left: 14px;
        padding-right: 14px;
    }


    .hero h1 {
        font-size:
            clamp(
                2rem,
                12vw,
                3rem
            );
    }

}


/* ---------- REDUCED MOTION ---------- */

@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;
    }

}

/* =========================================================
   COSMOVERSE RESPONSIVE DESIGN
   PART 2 — SECTIONS + CARDS + GRIDS
========================================================= */

/* ---------- TABLETS ---------- */

@media (max-width: 1024px) {

    section {
        scroll-margin-top: 85px;
    }

    .section-container,
    .container {
        width: min(100% - 36px, 1200px);
        margin-inline: auto;
    }

    /* Turn large 3/4-column grids into 2 columns */

    .planet-grid,
    .moon-grid,
    .dwarf-grid,
    .star-grid,
    .galaxy-grid,
    .mission-grid,
    .video-grid,
    .feature-grid,
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}


/* ---------- PHONES ---------- */

@media (max-width: 768px) {

    /* GENERAL SECTION SPACING */

    section {
        padding-left: 16px;
        padding-right: 16px;
    }

    .section-container,
    .container {
        width: 100%;
        max-width: 100%;
    }


    /* SECTION HEADINGS */

    .section-header {
        text-align: center;
        margin-bottom: 30px;
    }

    .section-header h2 {
        font-size: clamp(1.8rem, 8vw, 2.6rem);
        line-height: 1.1;
    }

    .section-header p {
        font-size: 0.96rem;
        line-height: 1.65;
    }


    /* ALL MAIN CONTENT GRIDS */

    .planet-grid,
    .moon-grid,
    .dwarf-grid,
    .star-grid,
    .galaxy-grid,
    .mission-grid,
    .video-grid,
    .feature-grid,
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }


    /* CARDS */

    .planet-card,
    .moon-card,
    .dwarf-card,
    .star-card,
    .galaxy-card,
    .mission-card,
    .video-card,
    .feature-card {
        width: 100%;
        min-width: 0;
    }


    /* PREVENT LONG TEXT FROM BREAKING SCREEN */

    p,
    h1,
    h2,
    h3,
    h4,
    span,
    strong {
        overflow-wrap: break-word;
    }


    /* BUTTON GROUPS */

    .button-group,
    .section-actions,
    .observatory-controls,
    .solar-controls {
        display: flex;
        flex-wrap: wrap;
        gap: 9px;
    }

    .button-group button,
    .section-actions button {
        flex: 1 1 150px;
    }


    /* FORM CONTROLS */

    input,
    select,
    textarea {
        max-width: 100%;
        font-size: 16px;
    }


    /* MODALS / OVERLAYS */

    .overlay {
        padding: 12px;
    }

    .search-panel,
    .favorites-panel,
    .modal-panel {
        width: 100%;
        max-height: calc(100dvh - 24px);
        overflow-y: auto;
    }


    /* ACCOUNT WINDOW */

    #accountOverlay {
        padding: 12px;
    }

    #accountOverlay .account-panel {
        width: 100%;
        max-height: calc(100dvh - 24px);
        padding: 26px 18px;
    }

    #accountOverlay .profile-stat-grid {
        grid-template-columns: 1fr 1fr;
    }

}


/* ---------- SMALL PHONES ---------- */

@media (max-width: 480px) {

    section {
        padding-left: 12px;
        padding-right: 12px;
    }

    .section-header h2 {
        font-size: 1.8rem;
    }


    /* ONE COLUMN PROFILE STATS ON VERY SMALL PHONES */

    #accountOverlay .profile-stat-grid {
        grid-template-columns: 1fr;
    }


    /* BUTTONS GET MORE ROOM */

    .solar-controls button,
    .observatory-controls button {
        flex: 1 1 calc(50% - 8px);
    }


    /* SEARCH */

    #universalSearch {
        width: 100%;
    }

}


/* ---------- SAFE MOBILE MEDIA ---------- */

img,
video,
canvas,
svg {
    max-width: 100%;
}

img,
video {
    height: auto;
}

/* =========================================================
   COSMOVERSE RESPONSIVE DESIGN
   PART 3 — SOLAR SYSTEM + PLANET OBSERVATORY
========================================================= */

@media (max-width: 768px) {

    /* =====================================================
       SOLAR SYSTEM CONTROLS
    ===================================================== */

    .solar-controls {
        width: 100%;
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin-bottom: 22px;
    }

    .solar-controls button {
        width: 100% !important;
        min-width: 0 !important;
        margin: 0 !important;
        padding: 13px 8px !important;
        font-size: 0.95rem;
    }


    /* =====================================================
       SOLAR SYSTEM VIEW
    ===================================================== */

    #solarSystemView {
        position: relative;

        width: 100% !important;
        max-width: 100% !important;

        aspect-ratio: 1 / 1;

        min-height: 0 !important;
        height: auto !important;

        margin: 0 auto;

        overflow: hidden;

        border-radius: 22px;
    }


    /*
       Scale the solar system slightly so Neptune's
       outer orbit stays inside the phone screen.
    */

    #solarSystemView .solar-system-scene,
    #solarSystemView .orbit-system {
        transform: scale(0.88);
        transform-origin: center;
    }


    /* PLANETS MUST REMAIN VISIBLE */

    #solarSystemView .space-object {
        cursor: pointer;
        touch-action: manipulation;
    }


    /* MAKE SMALL PLANETS EASIER TO TAP */

    #solarSystemView .space-object::after {
        content: "";
        position: absolute;

        width: 38px;
        height: 38px;

        left: 50%;
        top: 50%;

        transform: translate(-50%, -50%);

        border-radius: 50%;
    }


    /* =====================================================
       SOLAR INFORMATION PANEL
    ===================================================== */

    #solarInformationPanel {
        width: 100%;
        margin-top: 18px;
    }

    #solarInformationPanel .stats-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }


    /* =====================================================
       PLANET OBSERVATORY
    ===================================================== */

    .planet-selector {
        display: flex;
        gap: 8px;

        width: 100%;

        padding-bottom: 8px;

        overflow-x: auto;
        overscroll-behavior-inline: contain;

        scrollbar-width: thin;
    }


    .planet-select-button {
        flex: 0 0 auto;

        min-width: 105px;

        padding: 11px 13px;

        white-space: nowrap;

        touch-action: manipulation;
    }


    /* MAIN PLANET DISPLAY */

    .planet-observatory-layout,
    .planet-observatory-main {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 20px;
    }


    #observatoryPlanet {
        width: min(230px, 65vw) !important;
        height: min(230px, 65vw) !important;

        margin: 10px auto 20px;
    }


    #planetObservatoryName,
    #planetObservatoryDescription {
        text-align: center;
    }


    /* =====================================================
       PLANET TABS
    ===================================================== */

    .planet-tabs {
        display: flex;

        width: 100%;

        gap: 7px;

        padding-bottom: 7px;

        overflow-x: auto;
    }


    .planet-tab {
        flex: 0 0 auto;
        white-space: nowrap;
    }


    #planetTabContent {
        width: 100%;
        overflow-wrap: anywhere;
    }


    /* =====================================================
       PLANET COMPARISON
    ===================================================== */

    .comparison-controls {
        display: grid !important;
        grid-template-columns: 1fr;
        gap: 10px;
    }


    #comparePlanetOne,
    #comparePlanetTwo,
    #compareWorldsButton {
        width: 100%;
    }


    .comparison-results,
    .comparison-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 14px;
    }


    /* =====================================================
       MOBILE NAVIGATION IMPROVEMENTS
    ===================================================== */

    .nav-links {
        width: min(300px, 82vw);
    }


    .nav-links a {
        min-height: 48px;

        display: flex;
        align-items: center;
    }

}


/* =========================================================
   SMALL PHONES
========================================================= */

@media (max-width: 480px) {

    #solarSystemView {
        border-radius: 18px;
    }


    #solarSystemView .solar-system-scene,
    #solarSystemView .orbit-system {
        transform: scale(0.82);
    }


    #solarInformationPanel .stats-grid {
        grid-template-columns: 1fr;
    }


    .planet-select-button {
        min-width: 95px;
    }


    #observatoryPlanet {
        width: min(200px, 62vw) !important;
        height: min(200px, 62vw) !important;
    }

}

/* =========================================================
   MOBILE MENU — FINAL OPEN/CLOSE FIX
========================================================= */

@media (max-width: 768px) {

    #navLinks {
        position: fixed !important;
        top: 0 !important;
        right: -100% !important;

        width: min(300px, 82vw) !important;
        height: 100dvh !important;

        transition: right 0.3s ease !important;

        visibility: hidden;
        pointer-events: none;
    }

    #navLinks.open {
        right: 0 !important;

        visibility: visible;
        pointer-events: auto;
    }

}

/* =========================================================
   COSMOVERSE RESPONSIVE DESIGN
   PART 4 — LABS + QUIZ + VIDEOS + COSMO AI
========================================================= */


/* =========================================================
   TABLETS
========================================================= */

@media (max-width: 1024px) {

    /* BLACK HOLE */

    #blackHoleVisualization {
        width: min(100%, 700px);
        margin-inline: auto;
        overflow: hidden;
    }


    /* TELESCOPE OBSERVATORY */

    .observatory-layout,
    .telescope-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }


    /* QUIZ */

    .quiz-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }


    /* COSMO AI */

    .ai-layout,
    .cosmo-ai-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

}


/* =========================================================
   PHONES
========================================================= */

@media (max-width: 768px) {

    /* =====================================================
       BLACK HOLE LAB
    ===================================================== */

    #blackHoleVisualization {
        position: relative;

        width: 100% !important;
        max-width: 100% !important;

        min-height: 340px;
        height: auto;

        aspect-ratio: 1 / 1;

        margin-inline: auto;

        overflow: hidden;

        border-radius: 22px;
    }


    #blackHoleVisualization canvas,
    #blackHoleVisualization svg {
        width: 100% !important;
        height: 100% !important;
    }


    /* =====================================================
       TELESCOPE OBSERVATORY
    ===================================================== */

    .observatory-layout,
    .telescope-layout,
    .observatory-content {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 18px;
    }


    #telescopeScreen {
        width: 100% !important;

        min-height: 300px;
        height: auto;

        aspect-ratio: 4 / 3;

        overflow: hidden;

        border-radius: 20px;
    }


    #observatoryTargetVisual {
        max-width: 80%;
        max-height: 80%;
        margin: auto;
    }


    #observatoryTarget {
        width: 100%;
        min-height: 48px;
    }


    #observeTargetButton {
        width: 100%;
        min-height: 48px;
    }


    #observationData {
        width: 100%;
        overflow-wrap: anywhere;
    }


    /* =====================================================
       VIDEOS
    ===================================================== */

    .video-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 18px;
    }


    .video-card {
        width: 100% !important;
        overflow: hidden;
    }


    .video-card iframe,
    .video-card video {
        display: block;

        width: 100% !important;
        height: auto !important;

        aspect-ratio: 16 / 9;

        border: 0;
        border-radius: 14px;
    }


    /* =====================================================
       QUIZ
    ===================================================== */

    .quiz-layout,
    .quiz-container {
        width: 100%;
        max-width: 100%;
    }


    .quiz-category-list,
    .quiz-categories {
        display: flex;

        gap: 8px;

        width: 100%;

        padding-bottom: 8px;

        overflow-x: auto;

        overscroll-behavior-inline: contain;
    }


    .quiz-category {
        flex: 0 0 auto;
        white-space: nowrap;

        min-height: 44px;
    }


    #quizQuestion {
        font-size: clamp(1.2rem, 5vw, 1.55rem);
        line-height: 1.4;
    }


    #quizAnswers {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px;
    }


    #quizAnswers button {
        width: 100%;
        min-height: 52px;

        padding: 13px 15px;

        text-align: left;
    }


    #nextQuizQuestion {
        width: 100%;
        min-height: 48px;
    }


    /* XP */

    #xpBar {
        width: 100%;
        overflow: hidden;
    }


    /* ACHIEVEMENTS */

    .achievement-grid,
    .achievements-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }


    /* =====================================================
       COSMO AI CHAT
    ===================================================== */

    #cosmo-ai {
        overflow: hidden;
    }


    .ai-layout,
    .cosmo-ai-layout,
    .ai-container {
        width: 100%;
        max-width: 100%;
    }


    #aiMessages {
        width: 100%;

        min-height: 320px;
        max-height: 55vh;

        overflow-y: auto;
        overflow-x: hidden;

        scroll-behavior: smooth;
    }


    .ai-message,
    .message {
        max-width: 88%;
        overflow-wrap: anywhere;
    }


    #cosmoAIForm {
        display: grid !important;

        grid-template-columns:
            minmax(0, 1fr)
            auto;

        gap: 8px;

        width: 100%;
    }


    #cosmoAIInput {
        width: 100%;
        min-width: 0;

        min-height: 48px;

        font-size: 16px;
    }


    #cosmoAISendButton {
        min-width: 52px;
        min-height: 48px;

        padding-inline: 14px;
    }


    /* AI SUGGESTIONS */

    .ai-suggestions {
        display: flex;

        gap: 8px;

        width: 100%;

        padding-bottom: 8px;

        overflow-x: auto;
    }


    .ai-suggestion {
        flex: 0 0 auto;

        white-space: nowrap;
    }


    /* =====================================================
       INFORMATION MODAL
    ===================================================== */

    #informationModal {
        padding: 12px;
    }


    #informationModalContent {
        width: 100%;
        max-width: 100%;

        max-height: calc(100dvh - 24px);

        overflow-y: auto;
    }

}


/* =========================================================
   SMALL PHONES
========================================================= */

@media (max-width: 480px) {

    #blackHoleVisualization {
        min-height: 290px;
    }


    #telescopeScreen {
        min-height: 250px;
    }


    #aiMessages {
        min-height: 280px;
        max-height: 50vh;
    }


    .ai-message,
    .message {
        max-width: 94%;
    }


    .achievement-grid,
    .achievements-grid {
        grid-template-columns: 1fr;
    }


    #cosmoAIForm {
        grid-template-columns: 1fr;
    }


    #cosmoAISendButton {
        width: 100%;
    }

}


/* =========================================================
   TOUCHSCREEN IMPROVEMENTS
========================================================= */

@media (hover: none) and (pointer: coarse) {

    button,
    a,
    select,
    input {
        touch-action: manipulation;
    }


    button,
    .nav-links a,
    .planet-select-button,
    .planet-tab,
    .quiz-category,
    .ai-suggestion {
        min-height: 44px;
    }


    /*
       Desktop hover effects shouldn't be required
       to understand controls on a touchscreen.
    */

    .planet-card:hover,
    .mission-card:hover,
    .feature-card:hover {
        transform: none;
    }

}

/* =========================================================
   COSMOVERSE BLACK HOLE 2.0
   ADVANCED EDUCATIONAL VISUALIZATION
========================================================= */

.advanced-black-hole {
    position: relative;
    width: 100%;
    min-height: 560px;
    overflow: hidden;
    isolation: isolate;

    border-radius: 28px;
    border: 1px solid rgba(120, 155, 255, 0.16);

    background:
        radial-gradient(
            circle at 50% 50%,
            rgba(50, 25, 100, 0.18),
            transparent 35%
        ),
        radial-gradient(
            circle at 50% 50%,
            #080b18 0%,
            #03050d 58%,
            #010207 100%
        );

    box-shadow:
        inset 0 0 80px rgba(0, 0, 0, 0.9),
        0 25px 80px rgba(0, 0, 0, 0.35);
}


/* =========================================================
   STAR FIELD
========================================================= */

.advanced-black-hole .black-hole-stars {
    position: absolute;
    inset: 0;
    z-index: 1;

    opacity: 0.8;

    background-image:
        radial-gradient(circle, white 0 1px, transparent 1.5px),
        radial-gradient(circle, rgba(150, 190, 255, 0.9) 0 1px, transparent 1.5px),
        radial-gradient(circle, rgba(255, 220, 180, 0.8) 0 1px, transparent 1.5px);

    background-size:
        91px 91px,
        137px 137px,
        173px 173px;

    background-position:
        10px 20px,
        50px 80px,
        120px 30px;

    animation:
        blackHoleStarsDrift 35s linear infinite;
}


@keyframes blackHoleStarsDrift {

    from {
        background-position:
            10px 20px,
            50px 80px,
            120px 30px;
    }

    to {
        background-position:
            100px 110px,
            -87px 217px,
            293px -143px;
    }

}


/* =========================================================
   GRAVITATIONAL LENSING FIELD
========================================================= */

.lensing-field {
    position: absolute;

    left: 50%;
    top: 50%;

    border-radius: 50%;

    pointer-events: none;
}


.lensing-outer {
    width: 470px;
    height: 470px;

    z-index: 2;

    transform:
        translate(-50%, -50%);

    border:
        1px solid
        rgba(135, 175, 255, 0.16);

    box-shadow:
        0 0 40px rgba(90, 110, 255, 0.15),
        inset 0 0 55px rgba(105, 75, 255, 0.12);

    animation:
        lensingPulse 5s ease-in-out infinite;
}


.lensing-inner {
    width: 350px;
    height: 350px;

    z-index: 3;

    transform:
        translate(-50%, -50%);

    border:
        2px solid
        rgba(170, 195, 255, 0.16);

    box-shadow:
        0 0 35px rgba(125, 90, 255, 0.18),
        inset 0 0 35px rgba(100, 150, 255, 0.1);

    animation:
        lensingPulse 3.5s ease-in-out infinite reverse;
}


@keyframes lensingPulse {

    0%,
    100% {
        opacity: 0.45;
        filter: blur(0px);
    }

    50% {
        opacity: 0.9;
        filter: blur(1.5px);
    }

}


/* =========================================================
   ACCRETION SYSTEM
========================================================= */

.accretion-layer {
    position: absolute;

    left: 50%;
    top: 50%;

    width: 520px;
    height: 190px;

    transform:
        translate(-50%, -50%)
        rotate(-7deg);

    z-index: 5;

    pointer-events: none;
}


.accretion-ring {
    position: absolute;
    inset: 0;

    border-radius: 50%;

    animation:
        accretionRotate 7s linear infinite;
}


.ring-one {
    background:
        radial-gradient(
            ellipse at center,
            transparent 0%,
            transparent 36%,
            rgba(255, 90, 15, 0.08) 39%,
            rgba(255, 150, 35, 0.9) 48%,
            rgba(255, 225, 130, 0.95) 52%,
            rgba(255, 100, 20, 0.7) 59%,
            transparent 67%
        );

    filter:
        blur(2px)
        drop-shadow(0 0 15px rgba(255, 110, 20, 0.8));
}


.ring-two {
    inset: 14px 25px;

    background:
        radial-gradient(
            ellipse at center,
            transparent 0%,
            transparent 37%,
            rgba(255, 210, 100, 0.9) 46%,
            rgba(255, 110, 20, 0.85) 55%,
            transparent 66%
        );

    filter: blur(4px);

    animation-duration: 4.5s;
    animation-direction: reverse;
}


.ring-three {
    inset: 30px 55px;

    background:
        radial-gradient(
            ellipse at center,
            transparent 0%,
            transparent 34%,
            rgba(255, 245, 210, 0.95) 44%,
            rgba(255, 175, 50, 0.9) 53%,
            transparent 65%
        );

    filter:
        blur(2px)
        drop-shadow(0 0 12px rgba(255, 220, 120, 0.75));

    animation-duration: 3s;
}


@keyframes accretionRotate {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }

}


/* =========================================================
   BACK / FRONT DEPTH
========================================================= */

.accretion-back {
    z-index: 5;
    opacity: 0.68;

    clip-path:
        inset(0 0 50% 0);
}


.accretion-front {
    z-index: 11;

    clip-path:
        inset(50% 0 0 0);
}


/* =========================================================
   BLACK HOLE CORE
========================================================= */

.black-hole-core {
    position: absolute;

    left: 50%;
    top: 50%;

    width: 185px;
    height: 185px;

    transform:
        translate(-50%, -50%);

    z-index: 9;

    display: grid;
    place-items: center;

    border-radius: 50%;
}


.advanced-black-hole .black-hole-shadow {
    position: absolute;

    width: 165px;
    height: 165px;

    left: 50%;
    top: 50%;

    transform:
        translate(-50%, -50%);

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            #000 0%,
            #000 67%,
            #010104 78%,
            rgba(0, 0, 0, 0.98) 100%
        );

    box-shadow:
        0 0 15px #000,
        0 0 35px rgba(0, 0, 0, 1),
        0 0 65px rgba(30, 5, 65, 0.55);

    z-index: 10;
}


.advanced-black-hole .event-horizon {
    position: absolute;

    inset: 10px;

    border-radius: 50%;

    background: #000;

    box-shadow:
        inset 0 0 30px #000,
        0 0 18px rgba(255, 150, 55, 0.18);
}


/* =========================================================
   PHOTON RINGS
========================================================= */

.photon-ring {
    position: absolute;

    left: 50%;
    top: 50%;

    width: 195px;
    height: 195px;

    transform:
        translate(-50%, -50%);

    border-radius: 50%;

    pointer-events: none;
}


.photon-ring-back {
    z-index: 8;

    border:
        5px solid
        rgba(255, 185, 70, 0.55);

    filter: blur(5px);

    box-shadow:
        0 0 28px rgba(255, 135, 30, 0.65);
}


.photon-ring-front {
    z-index: 12;

    border:
        2px solid
        rgba(255, 235, 185, 0.95);

    box-shadow:
        0 0 10px rgba(255, 240, 195, 0.95),
        0 0 25px rgba(255, 150, 35, 0.8),
        0 0 50px rgba(255, 90, 20, 0.35);

    animation:
        photonPulse 2.3s ease-in-out infinite;
}


@keyframes photonPulse {

    0%,
    100% {
        opacity: 0.75;
    }

    50% {
        opacity: 1;
    }

}


/* =========================================================
   DOPPLER / LIGHT EFFECT
========================================================= */

.doppler-glow {
    position: absolute;

    left: 50%;
    top: 50%;

    width: 250px;
    height: 65px;

    border-radius: 50%;

    pointer-events: none;

    z-index: 13;

    mix-blend-mode: screen;
}


.doppler-left {
    transform:
        translate(-93%, -50%)
        rotate(-7deg);

    background:
        radial-gradient(
            ellipse,
            rgba(170, 210, 255, 0.5),
            rgba(90, 135, 255, 0.16) 45%,
            transparent 72%
        );

    filter: blur(13px);
}


.doppler-right {
    transform:
        translate(-7%, -50%)
        rotate(-7deg);

    background:
        radial-gradient(
            ellipse,
            rgba(255, 185, 75, 0.55),
            rgba(255, 70, 20, 0.15) 45%,
            transparent 72%
        );

    filter: blur(13px);
}


/* =========================================================
   GRAVITY GLOW
========================================================= */

.advanced-black-hole .gravity-glow {
    position: absolute;

    left: 50%;
    top: 50%;

    width: 310px;
    height: 310px;

    transform:
        translate(-50%, -50%);

    border-radius: 50%;

    z-index: 4;

    pointer-events: none;

    background:
        radial-gradient(
            circle,
            transparent 32%,
            rgba(255, 120, 30, 0.05) 45%,
            rgba(110, 60, 255, 0.08) 60%,
            transparent 72%
        );

    animation:
        gravityBreathing 4s ease-in-out infinite;
}


@keyframes gravityBreathing {

    0%,
    100% {
        transform:
            translate(-50%, -50%)
            scale(0.96);
    }

    50% {
        transform:
            translate(-50%, -50%)
            scale(1.05);
    }

}


/* =========================================================
   SIMULATION BADGE
========================================================= */

.black-hole-simulation-badge {
    position: absolute;

    left: 18px;
    bottom: 18px;

    z-index: 20;

    display: flex;
    align-items: center;
    gap: 8px;

    padding: 8px 11px;

    border:
        1px solid
        rgba(130, 175, 255, 0.18);

    border-radius: 999px;

    background:
        rgba(5, 10, 25, 0.72);

    backdrop-filter: blur(10px);

    color:
        rgba(220, 230, 255, 0.78);

    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}


.simulation-dot {
    width: 7px;
    height: 7px;

    border-radius: 50%;

    background: #ff9c3b;

    box-shadow:
        0 0 9px rgba(255, 150, 50, 0.9);

    animation:
        simulationDotPulse 1.7s ease-in-out infinite;
}


@keyframes simulationDotPulse {

    50% {
        opacity: 0.35;
    }

}


/* =========================================================
   PHONE / TABLET BLACK HOLE
========================================================= */

@media (max-width: 768px) {

    .advanced-black-hole {
        min-height: 390px !important;
        aspect-ratio: 1 / 1;
    }

    .accretion-layer {
        width: min(480px, 115vw);
        height: min(175px, 42vw);
    }

    .lensing-outer {
        width: min(410px, 90vw);
        height: min(410px, 90vw);
    }

    .lensing-inner {
        width: min(310px, 70vw);
        height: min(310px, 70vw);
    }

    .black-hole-core {
        width: min(170px, 39vw);
        height: min(170px, 39vw);
    }

    .advanced-black-hole .black-hole-shadow {
        width: min(155px, 35vw);
        height: min(155px, 35vw);
    }

    .photon-ring {
        width: min(185px, 42vw);
        height: min(185px, 42vw);
    }

}


@media (max-width: 480px) {

    .advanced-black-hole {
        min-height: 330px !important;
    }

    .black-hole-simulation-badge {
        left: 10px;
        bottom: 10px;

        font-size: 0.58rem;
    }

}


/* =========================================================
   ACCESSIBILITY — REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .advanced-black-hole *,
    .advanced-black-hole *::before,
    .advanced-black-hole *::after {
        animation: none !important;
    }

}

/* =========================================================
   BLACK HOLE 2.0 — MATTER PARTICLES
========================================================= */

.black-hole-particles {
    position: absolute;

    inset: 0;

    z-index: 14;

    overflow: hidden;

    pointer-events: none;
}


.black-hole-matter-particle {
    position: absolute;

    left: 50%;
    top: 50%;

    width: var(--particle-size);
    height: var(--particle-size);

    border-radius: 50%;

    opacity: var(--particle-opacity);

    background:
        radial-gradient(
            circle,
            #ffffff 0%,
            #ffe6a0 30%,
            #ff9a32 65%,
            transparent 100%
        );

    box-shadow:
        0 0 5px rgba(255, 220, 150, 0.9),
        0 0 12px rgba(255, 120, 30, 0.55);

    animation:
        blackHoleMatterOrbit
        var(--particle-duration)
        linear
        var(--particle-delay)
        infinite;

    transform-origin: center;
}


.reverse-particle {
    animation-direction: reverse;
}


@keyframes blackHoleMatterOrbit {

    0% {
        transform:
            translate(-50%, -50%)
            rotate(var(--start-angle))
            translateX(var(--orbit-x))
            scale(1);

        opacity:
            var(--particle-opacity);
    }


    45% {
        transform:
            translate(-50%, -50%)
            rotate(
                calc(
                    var(--start-angle)
                    + 170deg
                )
            )
            translateX(
                calc(
                    var(--orbit-x)
                    * 0.78
                )
            )
            scale(0.9);
    }


    78% {
        transform:
            translate(-50%, -50%)
            rotate(
                calc(
                    var(--start-angle)
                    + 285deg
                )
            )
            translateX(
                calc(
                    var(--orbit-x)
                    * 0.48
                )
            )
            scale(0.65);

        opacity:
            calc(
                var(--particle-opacity)
                * 0.8
            );
    }


    100% {
        transform:
            translate(-50%, -50%)
            rotate(
                calc(
                    var(--start-angle)
                    + 360deg
                )
            )
            translateX(
                calc(
                    var(--orbit-x)
                    * 0.22
                )
            )
            scale(0.15);

        opacity: 0;
    }

}


/* PHONE PERFORMANCE */

@media (max-width: 768px) {

    .black-hole-matter-particle:nth-child(2n) {
        display: none;
    }

}


/* REDUCED MOTION */

@media (prefers-reduced-motion: reduce) {

    .black-hole-matter-particle {
        animation: none !important;
    }

}

/* =========================================================
   BLACK HOLE 2.0 — INTERACTIVE CONTROLS
========================================================= */

.black-hole-controls {
    width: 100%;
    margin-top: 18px;
    padding: 22px;

    border: 1px solid rgba(105, 165, 255, 0.18);
    border-radius: 20px;

    background:
        linear-gradient(
            145deg,
            rgba(12, 20, 45, 0.92),
            rgba(16, 10, 38, 0.92)
        );

    box-shadow:
        0 18px 50px rgba(0, 0, 0, 0.25);
}


/* START + PAUSE */

.black-hole-control-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;

    margin-bottom: 22px;
}

.black-hole-control-buttons button {
    flex: 1 1 150px;
    min-height: 46px;
}


/* INDIVIDUAL CONTROL */

.black-hole-control {
    display: grid;

    grid-template-columns:
        minmax(150px, 0.8fr)
        minmax(180px, 1.5fr)
        auto;

    align-items: center;

    gap: 14px;

    margin-top: 16px;
}

.black-hole-control label {
    color: var(--text-secondary);
    font-weight: 700;
}


/* SPEED SLIDER */

#blackHoleSpeed {
    width: 100%;
    cursor: pointer;
}

#blackHoleSpeedValue {
    min-width: 46px;

    color: #ffffff;

    font-weight: 800;
    text-align: right;
}


/* BLACK HOLE TYPE */

#blackHoleMass {
    width: 100%;

    padding: 12px 14px;

    border:
        1px solid
        rgba(120, 170, 255, 0.2);

    border-radius: 11px;

    background: rgba(5, 10, 27, 0.9);

    color: white;

    font: inherit;

    outline: none;
}


/* EDUCATIONAL INFORMATION */

.black-hole-mass-information {
    margin-top: 20px;
    padding: 18px;

    border:
        1px solid
        rgba(255, 170, 70, 0.15);

    border-radius: 15px;

    background:
        radial-gradient(
            circle at top left,
            rgba(255, 130, 30, 0.08),
            transparent 45%
        ),
        rgba(5, 9, 23, 0.65);
}

.black-hole-mass-information strong {
    display: block;

    margin-bottom: 8px;

    color: #ffffff;

    font-size: 1.05rem;
}

.black-hole-mass-information p {
    margin: 0 0 10px;

    color: var(--text-secondary);

    line-height: 1.65;
}

.black-hole-mass-information small {
    color: rgba(200, 215, 245, 0.65);
}


/* =========================================================
   PHONE
========================================================= */

@media (max-width: 768px) {

    .black-hole-controls {
        padding: 16px;
    }

    .black-hole-control {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    #blackHoleSpeedValue {
        text-align: left;
    }

    #blackHoleMass {
        min-height: 48px;
    }

}

@media (max-width: 480px) {

    .black-hole-control-buttons {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .black-hole-control-buttons button {
        min-width: 0;
    }

}

/* =========================================================
   BLACK HOLE 2.0 — CONTROL STATES
========================================================= */

.advanced-black-hole {
    --black-hole-speed: 1;
}


/* PAUSE EVERYTHING INSIDE THE SIMULATION */

.advanced-black-hole.black-hole-paused *,
.advanced-black-hole.black-hole-paused *::before,
.advanced-black-hole.black-hole-paused *::after {
    animation-play-state: paused !important;
}


/* SPEED CONTROL */

.advanced-black-hole .accretion-ring {
    animation-duration:
        calc(
            7s /
            var(--black-hole-speed)
        );
}


.advanced-black-hole .ring-two {
    animation-duration:
        calc(
            4.5s /
            var(--black-hole-speed)
        );
}


.advanced-black-hole .ring-three {
    animation-duration:
        calc(
            3s /
            var(--black-hole-speed)
        );
}


.advanced-black-hole .black-hole-matter-particle {
    animation-duration:
        calc(
            var(--particle-duration) /
            var(--black-hole-speed)
        );
}


.advanced-black-hole .photon-ring-front {
    animation-duration:
        calc(
            2.3s /
            var(--black-hole-speed)
        );
}


.advanced-black-hole .gravity-glow {
    animation-duration:
        calc(
            4s /
            var(--black-hole-speed)
        );
}