:root {
    --bg: #101010;
    --surface: #191919;
    --surface2: #222222;
    --text: #f4f4f4;
    --muted: #a5a5a5;
    --accent: #f5d328;
    --border: #303030;
    --max-width: 1200px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    line-height: 1.7;
}

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

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

img {
    display: block;
    max-width: 100%;
}

button,
input {
    font: inherit;
}

/* Header */

.topbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(16, 16, 16, .97);
    border-bottom: 1px solid var(--border);
}

.header-inner {
    max-width: var(--max-width);
    min-height: 76px;
    margin: auto;
    padding: 12px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.wordmark {
    flex-shrink: 0;
    color: #fff;
    font-size: 23px;
    font-weight: 900;
    letter-spacing: -1px;
    line-height: 1.2;
}

.wordmark b {
    color: var(--accent);
}

.main-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.main-nav a {
    color: #dedede;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.main-nav a:hover {
    color: var(--accent);
}

.header-search {
    display: flex;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 5px;
    overflow: hidden;
    min-width: 155px;
}

.header-search input {
    width: 120px;
    min-width: 0;
    padding: 8px 9px;
    color: #fff;
    background: transparent;
    border: 0;
    outline: none;
    font-size: 12px;
}

.header-search button {
    padding: 5px 10px;
    color: var(--accent);
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 20px;
}

.menu-toggle {
    display: none;
    color: var(--accent);
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 5px 10px;
    font-size: 22px;
    cursor: pointer;
}

/* Main layout */

.container {
    width: min(100% - 44px, var(--max-width));
    margin: 0 auto;
}

.page-content {
    min-height: 55vh;
    padding-top: 35px;
    padding-bottom: 65px;
}

.section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin: 0 0 22px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.section-heading h2 {
    margin: 0;
    font-size: 23px;
    line-height: 1.3;
    font-weight: 800;
}

.section-heading h2:before {
    content: "";
    display: inline-block;
    width: 5px;
    height: 21px;
    margin-right: 11px;
    vertical-align: -3px;
    background: var(--accent);
}

.section-heading a,
.read-more {
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}

/* Article cards */

.article-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 26px 22px;
}

.article-card {
    min-width: 0;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 7px;
    transition: transform .2s ease, border-color .2s ease;
}

.article-card:hover {
    transform: translateY(-3px);
    border-color: #62591e;
}

.article-card-image {
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--surface2);
}

.article-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s ease;
}

.article-card:hover .article-card-image img {
    transform: scale(1.04);
}

.article-card-body {
    padding: 17px;
}

.category-label {
    display: inline-block;
    margin-bottom: 8px;
    color: var(--accent);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .8px;
    text-transform: uppercase;
}

.article-card h3 {
    margin: 0 0 10px;
    font-size: 18px;
    line-height: 1.4;
    font-weight: 800;
}

.article-card p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.65;
}

.article-meta {
    margin-top: 13px;
    color: var(--muted);
    font-size: 11px;
}

/* Featured area */

.featured-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 22px;
    margin-bottom: 45px;
}

.featured-main {
    position: relative;
    min-height: 360px;
    overflow: hidden;
    background: var(--surface);
    border-radius: 7px;
}

.featured-main img {
    width: 100%;
    height: 100%;
    min-height: 360px;
    object-fit: cover;
}

.featured-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 28px;
    background: linear-gradient(transparent 15%, rgba(0,0,0,.9));
}

.featured-overlay h2 {
    max-width: 700px;
    margin: 5px 0;
    font-size: clamp(23px, 3vw, 36px);
    line-height: 1.25;
}

.featured-overlay p {
    max-width: 650px;
    margin: 5px 0;
    color: #ddd;
    font-size: 14px;
}

.featured-side {
    display: grid;
    gap: 14px;
}

.featured-small {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 13px;
    align-items: center;
    padding: 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
}

.featured-small img {
    width: 120px;
    height: 85px;
    object-fit: cover;
    border-radius: 4px;
}

.featured-small h3 {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
}

/* Article page */

.article-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 40px;
}

.article-header {
    margin-bottom: 25px;
}

.article-header h1 {
    margin: 8px 0 15px;
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.2;
    letter-spacing: -.7px;
}

.article-subtitle {
    color: var(--muted);
    font-size: 17px;
}

.article-featured-image {
    width: 100%;
    max-height: 540px;
    margin: 25px 0;
    object-fit: cover;
    border-radius: 7px;
}

.article-content {
    color: #dedede;
    font-size: 17px;
    line-height: 1.85;
    overflow-wrap: anywhere;
}

.article-content h2,
.article-content h3,
.article-content h4 {
    margin-top: 35px;
    color: #fff;
    line-height: 1.35;
}

.article-content h2 {
    font-size: 27px;
}

.article-content h3 {
    font-size: 22px;
}

.article-content a {
    color: var(--accent);
    text-decoration: underline;
}

.article-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 28px auto;
    object-fit: contain;
    border-radius: 5px;
}

.article-content figure {
    max-width: 100%;
    margin: 28px auto;
    text-align: center;
}

.article-content figure img {
    margin: 0 auto;
}

.article-content figcaption {
    margin: 10px auto 0;
    color: #aaa;
    font-size: 14px;
    line-height: 1.6;
    text-align: center;
}

.article-content p img {
    max-width: 100%;
}

@media (max-width: 768px) {
    .article-content img {
        max-width: 100%;
        height: auto;
        margin: 20px auto;
    }

    .article-content figure {
        margin: 22px auto;
    }
}

.article-content blockquote {
    margin: 25px 0;
    padding: 15px 22px;
    border-left: 4px solid var(--accent);
    background: var(--surface);
    color: #ddd;
}

.article-sidebar {
    min-width: 0;
}

/* Search, category and pagination */

.page-title {
    margin: 0 0 25px;
    font-size: 32px;
    line-height: 1.3;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 40px;
}

.pagination a,
.pagination span {
    min-width: 40px;
    padding: 8px 12px;
    text-align: center;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-size: 13px;
}

.pagination .current {
    color: #111;
    background: var(--accent);
    border-color: var(--accent);
    font-weight: 800;
}

.empty-state {
    padding: 35px;
    color: var(--muted);
    text-align: center;
    background: var(--surface);
    border-radius: 6px;
}

/* Footer */

.site-footer {
    padding: 45px 22px 25px;
    background: #090909;
    border-top: 1px solid var(--border);
}

.footer-inner {
    max-width: var(--max-width);
    margin: auto;
    text-align: center;
}

.footer-brand {
    display: inline-block;
    margin-bottom: 12px;
}

.footer-inner > p {
    color: var(--muted);
    font-size: 13px;
}

.footer-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 25px;
    margin: 22px 0;
}

.footer-nav a {
    color: #ccc;
    font-size: 12px;
}

.copyright {
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

/* Responsive */

@media (max-width: 1050px) {
    .header-inner {
        gap: 14px;
    }

    .main-nav {
        gap: 12px;
    }

    .main-nav a {
        font-size: 12px;
    }

    .wordmark {
        font-size: 20px;
    }
}

@media (max-width: 850px) {
    .header-inner {
        min-height: 66px;
        flex-wrap: wrap;
    }

    .menu-toggle {
        display: block;
        order: 3;
    }

    .header-search {
        margin-left: auto;
        order: 2;
    }

    .main-nav {
        display: none;
        order: 4;
        flex: 0 0 100%;
        align-items: stretch;
        flex-direction: column;
        gap: 0;
        padding: 8px 0;
        border-top: 1px solid var(--border);
    }

    .main-nav.is-open {
        display: flex;
    }

    .main-nav a {
        padding: 12px 5px;
        border-bottom: 1px solid var(--border);
        font-size: 14px;
    }

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

    .article-layout {
        grid-template-columns: 1fr;
    }

    .article-sidebar {
        display: none;
    }
}

@media (max-width: 600px) {
    body {
        font-size: 15px;
    }

    .header-inner {
        padding: 11px 15px;
        gap: 10px;
    }

    .wordmark {
        font-size: 19px;
    }

    .header-search {
        min-width: 0;
    }

    .header-search input {
        width: 95px;
    }

    .container {
        width: calc(100% - 30px);
    }

    .page-content {
        padding-top: 25px;
        padding-bottom: 45px;
    }

    .article-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .article-card {
        display: grid;
        grid-template-columns: 125px minmax(0, 1fr);
    }

    .article-card-image {
        height: 100%;
        min-height: 125px;
        aspect-ratio: auto;
    }

    .article-card-body {
        padding: 12px;
    }

    .article-card h3 {
        font-size: 15px;
        line-height: 1.35;
    }

    .article-card p {
        display: none;
    }

    .article-meta {
        margin-top: 8px;
    }

    .section-heading h2 {
        font-size: 19px;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .featured-main,
    .featured-main img {
        min-height: 280px;
    }

    .featured-overlay {
        padding: 18px;
    }

    .featured-overlay h2 {
        font-size: 24px;
    }

    .featured-side {
        gap: 10px;
    }

    .article-header h1 {
        font-size: 29px;
    }

    .article-content {
        font-size: 16px;
    }

    .page-title {
        font-size: 26px;
    }
}

/* Official What If Science branding */
.logo-link {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    line-height: 0;
}

.logo-link img {
    display: block;
    width: 225px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.footer-brand {
    justify-content: center;
    margin-bottom: 18px;
}

.footer-brand img {
    width: 300px;
}

/* Improved mobile header: branding row and full-width search row */
@media (max-width: 850px) {
    .header-inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        gap: 14px;
        padding: 14px 20px;
    }

    .wordmark.logo-link {
        grid-column: 1;
        grid-row: 1;
        min-width: 0;
    }

    .wordmark.logo-link img {
        width: min(260px, 100%);
    }

    .menu-toggle {
        grid-column: 2;
        grid-row: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 54px;
        height: 54px;
        padding: 0;
        font-size: 27px;
    }

    .header-search {
        grid-column: 1 / -1;
        grid-row: 2;
        display: flex;
        width: 100%;
        min-width: 0;
        min-height: 48px;
        margin: 0;
        border-radius: 8px;
        background: #171717;
    }

    .header-search input {
        flex: 1;
        width: 100%;
        min-width: 0;
        padding: 12px 15px;
        font-size: 15px;
    }

    .header-search button {
        min-width: 48px;
        font-size: 23px;
    }

    .main-nav {
        grid-column: 1 / -1;
        grid-row: 3;
        width: 100%;
    }

    .main-nav.is-open {
        display: flex;
    }
}

@media (max-width: 600px) {
    .header-inner {
        padding: 12px 15px;
        gap: 12px;
    }

    .wordmark.logo-link img {
        width: min(245px, 100%);
    }

    .footer-brand img {
        width: min(280px, 85vw);
    }
}

/* Category-based homepage layout */
.home-section {
    margin-top: 58px;
}

.category-home-section {
    padding-top: 8px;
}

.home-section .section-heading {
    display: block;
    margin: 0 0 28px;
    padding: 0 0 16px;
}

.home-section .section-heading h2 {
    font-size: 27px;
    line-height: 1.35;
    letter-spacing: .1px;
}

.section-more {
    display: flex;
    justify-content: center;
    margin-top: 28px;
}

.section-more .view-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-width: 150px;
    padding: 11px 24px;
    border: 1px solid var(--accent);
    border-radius: 5px;
    color: var(--accent);
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
    transition: background .2s ease, color .2s ease;
}

.section-more .view-more:hover {
    background: var(--accent);
    color: #111;
}

.latest-home-section {
    margin-top: 70px;
    padding-top: 30px;
    border-top: 1px solid var(--border);
}

.latest-home-section .pagination {
    margin-top: 32px;
}

@media (max-width: 850px) {
    .home-section {
        margin-top: 45px;
    }

    .home-section .section-heading h2 {
        font-size: 24px;
    }
}

@media (max-width: 600px) {
    .home-section {
        margin-top: 38px;
    }

    .home-section .section-heading {
        margin-bottom: 20px;
        padding-bottom: 13px;
    }

    .home-section .section-heading h2 {
        font-size: 20px;
        line-height: 1.4;
    }

    .home-section .article-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px 12px;
    }

    .home-section .article-card {
        display: block;
        min-width: 0;
    }

    .home-section .article-card-image {
        width: 100%;
        height: auto;
        min-height: 0;
        aspect-ratio: 16 / 9;
    }

    .home-section .article-card-body {
        padding: 10px;
    }

    .home-section .article-card h3 {
        font-size: 13px;
        line-height: 1.4;
        margin-bottom: 7px;
    }

    .home-section .article-card p {
        display: none;
    }

    .home-section .category-label {
        font-size: 9px;
        letter-spacing: .4px;
        margin-bottom: 5px;
    }

    .home-section .article-meta {
        font-size: 10px;
        margin-top: 7px;
    }

    .section-more {
        margin-top: 22px;
    }

    .section-more .view-more {
        min-width: 140px;
        padding: 10px 20px;
        font-size: 13px;
    }

    .latest-home-section {
        margin-top: 48px;
        padding-top: 24px;
    }

    .latest-home-section .pagination {
        flex-wrap: wrap;
        gap: 8px;
    }
}

/* Mobile magazine layout: one large card, followed by two compact cards */
@media (max-width: 600px) {
    .home-section .article-grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 22px 12px;
    }

    /* Large card: first in every group of three */
    .home-section .article-card:nth-child(3n + 1) {
        grid-column: 1 / -1;
        display: grid;
        grid-template-columns: 42% minmax(0, 1fr);
        align-items: stretch;
    }

    .home-section .article-card:nth-child(3n + 1) .article-card-image {
        height: 100%;
        min-height: 145px;
        aspect-ratio: auto;
    }

    .home-section .article-card:nth-child(3n + 1) .article-card-body {
        padding: 13px;
    }

    .home-section .article-card:nth-child(3n + 1) h3 {
        font-size: 15px;
        line-height: 1.4;
    }

    /* Two smaller cards side by side */
    .home-section .article-card:not(:nth-child(3n + 1)) {
        display: block;
        min-width: 0;
    }

    .home-section .article-card:not(:nth-child(3n + 1)) .article-card-image {
        width: 100%;
        height: auto;
        min-height: 0;
        aspect-ratio: 16 / 9;
    }

    .home-section .article-card:not(:nth-child(3n + 1)) .article-card-body {
        padding: 9px;
    }

    .home-section .article-card:not(:nth-child(3n + 1)) h3 {
        font-size: 12px;
        line-height: 1.4;
    }

    /* Extra separation between category sections */
    .category-home-section {
        margin-bottom: 25px;
    }

    .section-more {
        margin-top: 26px;
        margin-bottom: 42px;
    }

    .latest-home-section {
        margin-top: 55px;
    }

    /* Pagination spacing */
    .pagination {
        display: flex;
        justify-content: center;
        align-items: center;
        flex-wrap: wrap;
        gap: 7px;
    }

    .pagination-dots {
        padding: 7px 2px;
        color: var(--muted);
    }
}

/* Compact pagination on desktop and mobile */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;
}

.pagination-dots {
    color: var(--muted);
}

/* Search page visual improvements */
.search-page-form {
    display: flex;
    align-items: stretch;
    gap: 10px;
    width: 100%;
    max-width: 650px;
    margin: 25px 0 30px;
}

.search-page-form input {
    flex: 1;
    min-width: 0;
    padding: 13px 15px;
    color: #f5f5f5;
    background: #171717;
    border: 1px solid var(--border);
    border-radius: 6px;
    font: inherit;
}

.search-page-form input:focus {
    outline: none;
    border-color: var(--accent);
}

.search-page-form button {
    padding: 12px 22px;
    color: #111;
    background: var(--accent);
    border: 1px solid var(--accent);
    border-radius: 6px;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.search-page-form button:hover {
    filter: brightness(1.08);
}

.search-results-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin: 0 0 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.search-results-heading h2 {
    min-width: 0;
    margin: 0;
    font-size: 23px;
    line-height: 1.4;
}

.search-results-heading > span {
    flex-shrink: 0;
    color: var(--muted);
    font-size: 14px;
}

@media (max-width: 600px) {
    .search-page-form {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 9px;
        margin: 22px 0 28px;
    }

    .search-page-form input {
        width: 100%;
        min-height: 50px;
        padding: 12px;
        font-size: 15px;
    }

    .search-page-form button {
        min-height: 50px;
        padding: 10px 15px;
        font-size: 14px;
    }

    .search-results-heading {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 7px;
        margin-bottom: 24px;
        padding-bottom: 15px;
    }

    .search-results-heading h2 {
        font-size: 19px;
        line-height: 1.4;
        overflow-wrap: anywhere;
    }

    .search-results-heading > span {
        font-size: 13px;
    }
}

/* Search page form: match the compact header search box */
.search-page-form {
    display: flex;
    align-items: center;
    width: fit-content;
    max-width: 100%;
    min-width: 155px;
    margin: 25px 0 30px;
    padding: 0;
    gap: 0;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 5px;
    overflow: hidden;
}

.search-page-form input {
    flex: 1;
    width: 120px;
    min-width: 0;
    min-height: 0;
    padding: 8px 9px;
    color: #fff;
    background: transparent;
    border: 0;
    border-radius: 0;
    outline: none;
    font-size: 12px;
}

.search-page-form input:focus {
    border: 0;
    outline: none;
}

.search-page-form button {
    min-height: 0;
    padding: 5px 10px;
    color: var(--accent);
    background: transparent;
    border: 0;
    border-radius: 0;
    cursor: pointer;
    font-size: 20px;
    font-weight: 400;
}

.search-page-form button:hover {
    background: transparent;
    filter: brightness(1.15);
}

@media (max-width: 600px) {
    .search-page-form {
        width: 100%;
        max-width: 100%;
        margin: 22px 0 28px;
    }

    .search-page-form input {
        width: auto;
        font-size: 13px;
        padding: 10px 12px;
    }

    .search-page-form button {
        padding: 5px 12px;
        font-size: 20px;
    }
}

/* Stronger separation between homepage category sections */
.category-home-section {
    padding-bottom: 28px;
    margin-bottom: 0;
}

.category-home-section .section-more {
    margin-bottom: 0;
}

@media (max-width: 600px) {
    .category-home-section {
        padding-bottom: 24px;
    }

    .category-home-section + .category-home-section,
    .category-home-section + .latest-home-section {
        margin-top: 42px;
    }
}

/* Mobile article reading: header scrolls away naturally */
@media (max-width: 850px) {
    .topbar {
        position: relative;
        top: auto;
    }
}

/* Back to Top button */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 1500;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--accent);
    border-radius: 50%;
    background: var(--accent);
    color: #111;
    font-size: 25px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity .25s ease, transform .25s ease, visibility .25s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,.35);
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #fff;
    color: #111;
}

@media (max-width: 600px) {
    .back-to-top {
        right: 17px;
        bottom: 22px;
        width: 44px;
        height: 44px;
        font-size: 23px;
    }
}



/* Article reading progress */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1100;
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,.12);
    pointer-events: none;
}

.reading-progress-fill {
    display: block;
    width: 0;
    height: 100%;
    background: var(--accent);
    transition: width .08s linear;
}

/* Back to Top */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 1500;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid var(--accent);
    border-radius: 50%;
    background: var(--accent);
    color: #111;
    font-size: 27px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity .25s ease, transform .25s ease, visibility .25s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,.35);
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #fff;
    color: #111;
}



@media (max-width: 600px) {
    .back-to-top {
        right: 17px;
        bottom: 22px;
        width: 44px;
        height: 44px;
        font-size: 24px;
    }
}



/* Compact single-row homepage pagination on mobile */
@media (max-width: 600px) {
    .pagination-home {
        display: flex;
        flex-wrap: nowrap;
        justify-content: center;
        align-items: center;
        gap: 5px;
        width: 100%;
        white-space: nowrap;
    }

    .pagination-home > a,
    .pagination-home > span:not(.pagination-dots) {
        box-sizing: border-box;
        min-width: 34px;
        min-height: 40px;
        padding: 8px 9px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 auto;
        font-size: 14px;
    }

    .pagination-home > .pagination-prev,
    .pagination-home > .pagination-next {
        width: 36px;
        min-width: 36px;
        padding: 8px 4px;
        font-size: 0;
    }

    .pagination-home > .pagination-prev::after {
        content: "‹";
        font-size: 23px;
        line-height: 1;
    }

    .pagination-home > .pagination-next::after {
        content: "›";
        font-size: 23px;
        line-height: 1;
    }

    .pagination-home > .pagination-dots {
        padding: 6px 1px;
        font-size: 13px;
    }
}



/* Gold icons in desktop and mobile navigation */
.main-nav a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.main-nav .nav-icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    fill: none;
    stroke: var(--accent);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.main-nav a:hover .nav-icon {
    stroke: #fff;
}

@media (max-width: 850px) {
    .main-nav a {
        display: flex;
        align-items: center;
        gap: 14px;
        padding: 15px 12px;
        font-size: 15px;
    }

    .main-nav .nav-icon {
        width: 21px;
        height: 21px;
        flex-basis: 21px;
    }

    .main-nav a::after {
        content: "";
        width: 8px;
        height: 8px;
        margin-left: auto;
        border-top: 1.5px solid #777;
        border-right: 1.5px solid #777;
        transform: rotate(45deg);
    }

    .main-nav a:hover {
        background: rgba(246, 211, 45, .07);
    }

    .main-nav a:hover::after {
        border-color: var(--accent);
    }
}

/* ==========================================================
   WHAT IF SCIENCE — COSMIC DESIGN FOUNDATION
   Version 1: Global visual theme
   ========================================================== */

:root {
    --bg: #070b1b;
    --surface: #10172d;
    --surface2: #18223d;
    --text: #f2f4ff;
    --muted: #a6b0ca;
    --accent: #f5d328;
    --border: rgba(133, 158, 220, .19);
    --max-width: 1240px;
    --cosmic-blue: #526dff;
    --cosmic-purple: #9b62ed;
}

html {
    background: #070b1b;
}

body {
    background:
        radial-gradient(ellipse at 12% 8%, rgba(55, 76, 160, .17), transparent 35%),
        radial-gradient(ellipse at 88% 35%, rgba(102, 51, 153, .12), transparent 34%),
        #070b1b;
    color: var(--text);
}

.topbar {
    background: rgba(7, 11, 27, .94);
    border-bottom: 1px solid rgba(135, 158, 230, .2);
    box-shadow: 0 8px 30px rgba(0, 0, 0, .24);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.main-nav a {
    color: #dce4ff;
    transition: color .2s ease;
}

.main-nav a:hover {
    color: #fff;
}

.main-nav .nav-icon {
    stroke: var(--accent);
}

.header-search {
    background: rgba(20, 29, 56, .8);
    border-color: rgba(139, 160, 225, .27);
    border-radius: 8px;
}

.header-search input {
    color: #fff;
}

.header-search input::placeholder {
    color: #9ba8c9;
}

.header-search button {
    color: var(--accent);
}

.menu-toggle {
    border-color: rgba(139, 160, 225, .3);
    border-radius: 8px;
    background: rgba(30, 43, 78, .55);
}

.page-content {
    background: transparent;
}

.section-heading {
    border-bottom-color: rgba(135, 158, 230, .23);
}

.section-heading h2:before {
    background: linear-gradient(180deg, #f7df65, #d9a82c);
    border-radius: 4px;
}

.category-label {
    color: #f1d66b;
}

.article-card {
    background: linear-gradient(145deg, rgba(20, 29, 55, .98), rgba(12, 19, 39, .98));
    border-color: rgba(132, 155, 218, .19);
    border-radius: 11px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .16);
}

.article-card:hover {
    border-color: rgba(137, 119, 255, .7);
    box-shadow: 0 12px 30px rgba(36, 49, 115, .25);
}

.article-card-image {
    background: #111a35;
}

.featured-main {
    border: 1px solid rgba(139, 160, 225, .2);
    border-radius: 13px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, .25);
}

.featured-overlay {
    background: linear-gradient(
        180deg,
        rgba(5, 9, 25, .02) 10%,
        rgba(5, 9, 25, .48) 48%,
        rgba(5, 9, 25, .96) 100%
    );
}

.featured-small {
    background: linear-gradient(145deg, #151f3c, #0e162e);
    border-color: rgba(132, 155, 218, .2);
    border-radius: 10px;
}

.featured-small:hover {
    border-color: rgba(137, 119, 255, .7);
}

.article-content {
    color: #dce3f6;
}

.article-content h2,
.article-content h3,
.article-content h4 {
    color: #fff;
}

.article-content blockquote {
    background: #131e3a;
    border-left-color: var(--cosmic-purple);
    border-radius: 0 8px 8px 0;
}

.article-content a {
    color: #a9baff;
}

.article-content a:hover {
    color: var(--accent);
}

.page-title {
    color: #fff;
}

.pagination a,
.pagination span {
    background: #111a34;
    border-color: rgba(132, 155, 218, .22);
    border-radius: 7px;
}

.pagination .current {
    color: #101426;
    background: var(--accent);
    border-color: var(--accent);
}

.search-page-form {
    background: rgba(17, 26, 52, .85);
    border-color: rgba(139, 160, 225, .28);
    border-radius: 8px;
}

.search-page-form input {
    color: #fff;
}

.search-page-form input::placeholder {
    color: #9ba8c9;
}

.site-footer {
    background:
        radial-gradient(ellipse at 50% 0%, rgba(67, 69, 160, .2), transparent 65%),
        #050817;
    border-top: 1px solid rgba(135, 158, 230, .22);
}

.footer-nav a {
    color: #c5cde4;
}

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

.copyright {
    border-top-color: rgba(135, 158, 230, .2);
}

.empty-state {
    background: #111a34;
    border: 1px solid var(--border);
    border-radius: 10px;
}

.back-to-top {
    box-shadow: 0 5px 24px rgba(81, 99, 210, .35);
}

@media (max-width: 850px) {
    .main-nav {
        background: #0c142c;
        border-color: rgba(135, 158, 230, .2);
    }

    .main-nav a {
        border-bottom-color: rgba(135, 158, 230, .14);
    }

    .main-nav a:hover {
        background: rgba(92, 105, 207, .13);
    }
}

/* End cosmic foundation */



/* ==========================================================
   COSMIC HOMEPAGE HERO
   ========================================================== */

.home-hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 560px;
    margin: 0 0 48px;
    padding: 65px 55px;
    overflow: hidden;
    isolation: isolate;
    background-color: #050817;
    background-image:
        linear-gradient(90deg,
            rgba(5, 8, 23, .96) 0%,
            rgba(5, 8, 23, .82) 36%,
            rgba(5, 8, 23, .28) 66%,
            rgba(5, 8, 23, .04) 100%),
        url('/assets/images/cosmic-astronaut-earth.webp');
    background-size: cover;
    background-position: center 43%;
    border: 1px solid rgba(139, 160, 225, .22);
    border-radius: 16px;
    box-shadow: 0 22px 55px rgba(0, 0, 0, .32);
}

.home-hero-content {
    position: relative;
    z-index: 2;
    width: min(100%, 650px);
}

.hero-eyebrow {
    display: inline-block;
    margin-bottom: 20px;
    color: #f5d86b;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
}

.home-hero h1 {
    max-width: 650px;
    margin: 0 0 20px;
    color: #fff;
    font-size: clamp(38px, 5vw, 64px);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -1.5px;
    text-shadow: 0 3px 22px rgba(0, 0, 0, .45);
}

.home-hero-content > p {
    max-width: 540px;
    margin: 0;
    color: #d4def5;
    font-size: 17px;
    line-height: 1.75;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    margin-top: 30px;
}

.hero-button,
.hero-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 12px 21px;
    border-radius: 7px;
    font-size: 14px;
    font-weight: 800;
    transition: .2s ease;
}

.hero-button {
    color: #101426;
    background: #f5d328;
    border: 1px solid #f5d328;
}

.hero-button:hover {
    color: #101426;
    background: #ffe77b;
    transform: translateY(-2px);
}

.hero-secondary {
    color: #fff;
    background: rgba(18, 29, 59, .65);
    border: 1px solid rgba(190, 204, 255, .48);
}

.hero-secondary:hover {
    color: #fff;
    background: rgba(75, 88, 157, .55);
    border-color: #a9baff;
}

.hero-scroll-indicator {
    position: absolute;
    z-index: 2;
    right: 28px;
    bottom: 23px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(225, 232, 255, .72);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.hero-scroll-indicator span {
    color: #f5d328;
    font-size: 19px;
}

@media (max-width: 850px) {
    .home-hero {
        min-height: 500px;
        padding: 45px 32px;
        background-position: 59% center;
    }

    .home-hero-content {
        width: min(100%, 560px);
    }

    .home-hero h1 {
        font-size: clamp(35px, 6vw, 50px);
    }
}

@media (max-width: 600px) {
    .home-hero {
        min-height: 560px;
        margin-bottom: 35px;
        padding: 35px 22px 65px;
        align-items: flex-end;
        background-image:
            linear-gradient(0deg,
                rgba(5, 8, 23, .98) 0%,
                rgba(5, 8, 23, .88) 38%,
                rgba(5, 8, 23, .18) 100%),
            url('/assets/images/cosmic-astronaut-earth.webp');
        background-size: cover;
        background-position: 62% center;
        border-radius: 11px;
    }

    .hero-eyebrow {
        margin-bottom: 13px;
        font-size: 10px;
        letter-spacing: 1.3px;
    }

    .home-hero h1 {
        margin-bottom: 13px;
        font-size: 36px;
        line-height: 1.12;
        letter-spacing: -.7px;
    }

    .home-hero-content > p {
        font-size: 14px;
        line-height: 1.6;
    }

    .hero-actions {
        gap: 10px;
        margin-top: 21px;
    }

    .hero-button,
    .hero-secondary {
        min-height: 44px;
        padding: 10px 13px;
        font-size: 12px;
    }

    .hero-scroll-indicator {
        right: 17px;
        bottom: 13px;
        font-size: 9px;
    }
}

/* End cosmic homepage hero */

/* Cosmic hero: refined mobile composition */
@media (max-width: 600px) {
    .home-hero {
        min-height: 480px;
        padding: 30px 19px 55px;
        background-position: 48% center;
    }

    .home-hero h1 {
        font-size: 32px;
        line-height: 1.14;
    }

    .home-hero-content > p {
        font-size: 13px;
    }

    .hero-actions {
        gap: 9px;
        margin-top: 18px;
    }

    .hero-button,
    .hero-secondary {
        min-height: 42px;
        padding: 9px 12px;
        font-size: 11px;
    }
}


/* Mobile hero: move astronaut towards the centre */
@media (max-width: 600px) {
    .home-hero {
        background-size: auto 120%;
        background-position: 78% center;
    }
}


/* Compact mobile featured supporting stories */
@media (max-width: 600px) {
    .featured-side {
        gap: 12px;
    }

    .featured-small {
        display: grid;
        grid-template-columns: 105px minmax(0, 1fr);
        gap: 12px;
        align-items: center;
        padding: 10px;
        border-radius: 10px;
    }

    .featured-small img {
        width: 105px;
        height: 78px;
        object-fit: cover;
        border-radius: 6px;
    }

    .featured-small .category-label {
        margin-bottom: 5px;
        font-size: 9px;
        letter-spacing: .5px;
        line-height: 1.3;
    }

    .featured-small h3 {
        font-size: 13px;
        line-height: 1.4;
        font-weight: 750;
    }
}

/* End compact mobile featured stories */


/* HOMEPAGE CATEGORY SECTIONS — COSMIC MAGAZINE DESIGN */

.category-home-section {
    position: relative;
    padding: 24px 22px 30px;
    margin-top: 42px;
    background: linear-gradient(
        135deg,
        rgba(22, 31, 63, .42),
        rgba(9, 15, 34, .18)
    );
    border: 1px solid rgba(112, 133, 205, .12);
    border-radius: 14px;
}

.category-home-section .section-heading {
    position: relative;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(133, 158, 220, .2);
}

.category-home-section .section-heading h2 {
    color: #f4f5ff;
    font-size: 26px;
    font-weight: 850;
    letter-spacing: -.35px;
}

.category-home-section .section-heading h2::before {
    width: 5px;
    height: 25px;
    margin-right: 13px;
    background: linear-gradient(180deg, #f5d328, #9474ff);
    border-radius: 5px;
}

.category-home-section .article-grid {
    gap: 22px;
}

.category-home-section .article-card {
    background: linear-gradient(150deg, #172342, #0d152d);
    border: 1px solid rgba(130, 151, 218, .2);
    border-radius: 11px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
}

.category-home-section .article-card:hover {
    transform: translateY(-4px);
    border-color: rgba(151, 126, 255, .65);
    box-shadow: 0 13px 28px rgba(49, 57, 135, .25);
}

.category-home-section .article-card-image {
    background: #111b37;
    overflow: hidden;
}

.category-home-section .article-card-image img {
    transition: transform .4s ease;
}

.category-home-section .article-card-body {
    padding: 17px;
}

.category-home-section .article-card h3 {
    color: #f3f5ff;
    font-size: 17px;
    line-height: 1.45;
    font-weight: 800;
}

.category-home-section .article-card h3 a:hover {
    color: #c2c8ff;
}

.category-home-section .article-meta {
    color: #9eafd6;
}

.category-home-section .section-more .view-more {
    border-color: rgba(157, 143, 255, .7);
    color: #d4ccff;
    background: rgba(73, 72, 145, .13);
    border-radius: 7px;
}

.category-home-section .section-more .view-more:hover {
    color: #fff;
    background: #6555b8;
    border-color: #8d7aff;
}

@media (max-width: 850px) {
    .category-home-section {
        padding: 20px 16px 25px;
    }
}

@media (max-width: 600px) {
    .category-home-section {
        padding: 16px 10px 22px;
        border-radius: 11px;
    }

    .category-home-section .section-heading {
        margin-bottom: 18px;
    }

    .category-home-section .section-heading h2 {
        font-size: 19px;
        line-height: 1.4;
    }

    .category-home-section .article-grid {
        gap: 19px 10px;
    }

    .category-home-section .article-card {
        border-radius: 8px;
    }

    .category-home-section .article-card:nth-child(3n + 1) h3 {
        font-size: 13px;
        line-height: 1.35;
    }

    .category-home-section .article-card:not(:nth-child(3n + 1)) h3 {
        font-size: 11.5px;
        line-height: 1.35;
    }

    .category-home-section .article-card-body {
        padding: 9px;
    }

    .category-home-section .section-more {
        margin-top: 20px;
        margin-bottom: 8px;
    }
}

/* END HOMEPAGE CATEGORY REDESIGN */


/* ==========================================================
   COSMIC CATEGORY ARCHIVE DESIGN
   ========================================================== */

.category-hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 330px;
    margin: 30px 0 28px;
    padding: 42px 48px;
    overflow: hidden;
    isolation: isolate;
    background:
        radial-gradient(ellipse at 75% 20%, rgba(105, 77, 210, .32), transparent 45%),
        linear-gradient(120deg, #111b3b, #080d20 75%);
    border: 1px solid rgba(139, 160, 225, .22);
    border-radius: 15px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, .25);
}

.category-hero.has-category-background {
    background-image:
        linear-gradient(90deg,
            rgba(5, 8, 23, .96) 0%,
            rgba(5, 8, 23, .84) 43%,
            rgba(5, 8, 23, .35) 100%),
        var(--category-hero-image);
    background-size: cover;
    background-position: center 48%;
}

.category-hero-content {
    position: relative;
    z-index: 1;
    max-width: 760px;
}

.category-hero-eyebrow {
    display: block;
    margin-bottom: 15px;
    color: #f5d86b;
    font-size: 12px;
    font-weight: 850;
    letter-spacing: 2px;
}

.category-hero h1 {
    margin: 0 0 17px;
    color: #fff;
    font-size: clamp(34px, 4vw, 52px);
    font-weight: 900;
    line-height: 1.12;
    letter-spacing: -.8px;
    text-shadow: 0 3px 20px rgba(0, 0, 0, .5);
}

.category-hero-content > p {
    max-width: 700px;
    margin: 0;
    color: #d5def4;
    font-size: 16px;
    line-height: 1.7;
}

.category-hero-caption {
    display: inline-block;
    margin-top: 22px;
    color: #e9d477;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2px;
}

.category-featured-story {
    position: relative;
    display: block;
    min-height: 350px;
    margin: 0 0 30px;
    overflow: hidden;
    background: #101a35;
    border: 1px solid rgba(139, 160, 225, .22);
    border-radius: 13px;
    box-shadow: 0 14px 35px rgba(0, 0, 0, .23);
}

.category-featured-story > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .45s ease;
}

.category-featured-story:hover > img {
    transform: scale(1.025);
}

.category-featured-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-start;
    padding: 35px 40px;
    background: linear-gradient(
        180deg,
        rgba(5, 8, 23, .02) 10%,
        rgba(5, 8, 23, .4) 48%,
        rgba(5, 8, 23, .96) 100%
    );
}

.category-featured-overlay h2 {
    max-width: 850px;
    margin: 10px 0;
    color: #fff;
    font-size: clamp(25px, 3.2vw, 39px);
    font-weight: 900;
    line-height: 1.2;
    text-shadow: 0 2px 16px rgba(0, 0, 0, .5);
}

.category-featured-overlay > p {
    max-width: 760px;
    margin: 0;
    color: #dce4f8;
    font-size: 14px;
    line-height: 1.6;
}

.category-featured-cta {
    margin-top: 17px;
    color: #f5d328;
    font-size: 11px;
    font-weight: 850;
    letter-spacing: 1.3px;
}

.category-archive-grid {
    margin-top: 0;
}

.category-archive-grid .article-card {
    background: linear-gradient(150deg, #172342, #0d152d);
    border-color: rgba(130, 151, 218, .2);
    border-radius: 11px;
}

.category-archive-grid .article-card:hover {
    border-color: rgba(151, 126, 255, .65);
    transform: translateY(-3px);
}

.category-archive-grid .article-card-body {
    padding: 16px;
}

.category-archive-grid .article-card h3 {
    color: #f3f5ff;
    font-size: 17px;
    line-height: 1.45;
}

.category-archive-grid .article-meta {
    color: #9eafd6;
}

@media (max-width: 850px) {
    .category-hero {
        min-height: 290px;
        padding: 32px;
    }

    .category-featured-story {
        min-height: 310px;
    }
}

@media (max-width: 600px) {
    .category-hero {
        min-height: 270px;
        margin: 20px 0 20px;
        padding: 25px 20px;
        border-radius: 11px;
    }

    .category-hero.has-category-background {
        background-image:
            linear-gradient(0deg,
                rgba(5, 8, 23, .97) 0%,
                rgba(5, 8, 23, .82) 55%,
                rgba(5, 8, 23, .35) 100%),
            var(--category-hero-image);
        background-position: center center;
    }

    .category-hero-eyebrow {
        margin-bottom: 10px;
        font-size: 10px;
        letter-spacing: 1.4px;
    }

    .category-hero h1 {
        margin-bottom: 12px;
        font-size: 30px;
        line-height: 1.15;
    }

    .category-hero-content > p {
        font-size: 13px;
        line-height: 1.55;
    }

    .category-hero-caption {
        margin-top: 15px;
        font-size: 9px;
        letter-spacing: 1.2px;
    }

    .category-featured-story {
        min-height: 340px;
        margin-bottom: 20px;
        border-radius: 11px;
    }

    .category-featured-overlay {
        padding: 20px;
    }

    .category-featured-overlay h2 {
        margin: 8px 0;
        font-size: 23px;
        line-height: 1.25;
    }

    .category-featured-overlay > p {
        font-size: 12px;
        line-height: 1.5;
    }

    .category-featured-cta {
        margin-top: 12px;
        font-size: 10px;
    }

    .category-archive-grid {
        gap: 17px 10px;
    }

    .category-archive-grid .article-card {
        border-radius: 8px;
    }

    .category-archive-grid .article-card-body {
        padding: 9px;
    }

    .category-archive-grid .article-card h3 {
        font-size: 13px;
        line-height: 1.4;
    }
}

/* End cosmic category archive design */


/* ==========================================================
   CATEGORY PAGE — FEATURED STORY AND HORIZONTAL STORY LIST
   ========================================================== */

.category-header {
    margin-bottom: 30px;
    padding: 34px 0 12px;
}

.category-header > .category-label {
    color: #f1d66b;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.category-header .page-title {
    margin: 12px 0 18px;
    font-size: clamp(32px, 4vw, 46px);
}

.category-header .article-subtitle {
    max-width: 1050px;
    color: #b9c5e2;
    font-size: 17px;
    line-height: 1.8;
}

.category-tagline {
    margin-top: 22px;
    color: #f1d66b;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
}

.category-featured-story {
    position: relative;
    overflow: hidden;
    min-height: 430px;
    margin: 18px 0 42px;
    border: 1px solid rgba(139, 160, 225, .25);
    border-radius: 14px;
    background: #080e20;
    box-shadow: 0 16px 42px rgba(0, 0, 0, .3);
}

.category-featured-story > a {
    position: relative;
    display: flex;
    min-height: 430px;
    align-items: flex-end;
    color: #fff;
    text-decoration: none;
}

.category-featured-story img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s ease;
}

.category-featured-story:hover img {
    transform: scale(1.025);
}

.category-featured-overlay {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 38px;
    background: linear-gradient(
        180deg,
        rgba(5, 9, 25, 0) 0%,
        rgba(5, 9, 25, .55) 42%,
        rgba(5, 9, 25, .96) 100%
    );
}

.category-featured-overlay .category-label {
    display: inline-block;
    margin-bottom: 12px;
    color: #f5d76b;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 1px;
}

.category-featured-overlay h2 {
    max-width: 850px;
    margin: 0 0 12px;
    color: #fff;
    font-size: clamp(27px, 3.5vw, 42px);
    line-height: 1.2;
}

.category-featured-overlay p {
    max-width: 800px;
    margin: 0 0 12px;
    color: #e0e7fa;
    font-size: 15px;
    line-height: 1.6;
}

.category-featured-overlay .article-meta {
    color: #c2cce5;
}

.category-story-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin: 0 0 42px;
}

.category-story-row {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 24px;
    overflow: hidden;
    min-height: 190px;
    padding: 14px;
    border: 1px solid rgba(132, 155, 218, .2);
    border-radius: 12px;
    background: linear-gradient(145deg, #151f3c, #0e162e);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .15);
}

.category-story-image {
    display: block;
    overflow: hidden;
    min-height: 170px;
    border-radius: 8px;
    background: #0a1228;
}

.category-story-image img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 170px;
    object-fit: cover;
    transition: transform .35s ease;
}

.category-story-row:hover .category-story-image img {
    transform: scale(1.04);
}

.category-story-body {
    align-self: center;
    padding: 8px 8px 8px 0;
}

.category-story-body .category-label {
    display: block;
    margin-bottom: 9px;
    color: #f1d66b;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1px;
}

.category-story-body h2 {
    margin: 0 0 10px;
    font-size: 22px;
    line-height: 1.35;
}

.category-story-body h2 a {
    color: #f4f6ff;
    text-decoration: none;
}

.category-story-body h2 a:hover {
    color: #f5d328;
}

.category-story-body p {
    margin: 0 0 10px;
    color: #aebbd8;
    font-size: 14px;
    line-height: 1.6;
}

.category-story-body .article-meta {
    color: #9eafd2;
    font-size: 12px;
}

@media (max-width: 700px) {
    .category-header {
        padding-top: 26px;
        margin-bottom: 22px;
    }

    .category-header .page-title {
        font-size: 34px;
    }

    .category-header .article-subtitle {
        font-size: 16px;
        line-height: 1.65;
    }

    .category-tagline {
        font-size: 11px;
        letter-spacing: 1.4px;
    }

    .category-featured-story,
    .category-featured-story > a {
        min-height: 390px;
    }

    .category-featured-overlay {
        padding: 22px 20px;
    }

    .category-featured-overlay h2 {
        font-size: 27px;
        line-height: 1.25;
    }

    .category-featured-overlay p {
        font-size: 14px;
    }

    .category-story-list {
        gap: 14px;
    }

    .category-story-row {
        grid-template-columns: 36% minmax(0, 1fr);
        gap: 14px;
        min-height: 155px;
        padding: 10px;
    }

    .category-story-image,
    .category-story-image img {
        min-height: 135px;
    }

    .category-story-body {
        padding: 4px 2px 4px 0;
    }

    .category-story-body .category-label {
        font-size: 10px;
        letter-spacing: .5px;
        margin-bottom: 6px;
    }

    .category-story-body h2 {
        font-size: 16px;
        line-height: 1.35;
        margin-bottom: 7px;
    }

    .category-story-body p {
        font-size: 12px;
        line-height: 1.45;
    }
}

@media (max-width: 380px) {
    .category-story-row {
        grid-template-columns: 34% minmax(0, 1fr);
        gap: 10px;
    }

    .category-story-body h2 {
        font-size: 14px;
    }
}

/* End category page styling */


/* Final mobile Back to Top adjustment */
@media (max-width: 600px) {
    .back-to-top {
        width: 30px;
        height: 30px;
        right: 10px;
        bottom: 12px;
        font-size: 17px;
        opacity: 0;
    }

    .back-to-top.is-visible {
        opacity: 1;
    }
}

/* =========================================
   COSMIC ARTICLE PAGE REDESIGN
========================================= */

.article-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 42px;
    align-items: start;
}

.article-layout > article {
    min-width: 0;
}

.article-header {
    margin-bottom: 28px;
    padding: 28px 30px;
    background: linear-gradient(145deg, rgba(23, 34, 68, .92), rgba(12, 19, 42, .96));
    border: 1px solid rgba(133, 158, 220, .2);
    border-radius: 14px;
}

.article-header .category-label {
    display: inline-block;
    margin-bottom: 12px;
    color: #f5d328;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.article-header h1 {
    margin: 0 0 16px;
    color: #fff;
    font-size: clamp(32px, 3.5vw, 46px);
    line-height: 1.16;
    letter-spacing: -.9px;
}

.article-subtitle {
    margin: 0 0 20px;
    color: #bdc8e4;
    font-size: 18px;
    line-height: 1.65;
}

.article-header .article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #929fbe;
    font-size: 13px;
}

.article-featured-image {
    display: block;
    width: 100%;
    max-height: 560px;
    margin: 0 0 34px;
    object-fit: cover;
    border: 1px solid rgba(133, 158, 220, .2);
    border-radius: 13px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, .28);
}

.article-content {
    max-width: 790px;
    margin: 0 auto;
    color: #dce3f6;
    font-size: 18px;
    line-height: 1.9;
    overflow-wrap: anywhere;
}

.article-content p {
    margin: 0 0 25px;
}

.article-content h2 {
    margin: 48px 0 19px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(133, 158, 220, .2);
    color: #fff;
    font-size: 30px;
    line-height: 1.3;
}

.article-content h3 {
    margin: 36px 0 15px;
    color: #e6eaff;
    font-size: 23px;
    line-height: 1.4;
}

.article-content h4 {
    margin: 30px 0 12px;
    color: #e6eaff;
    font-size: 19px;
}

.article-content ul,
.article-content ol {
    margin: 0 0 26px;
    padding-left: 28px;
}

.article-content li {
    margin-bottom: 10px;
    padding-left: 5px;
}

.article-content blockquote {
    margin: 32px 0;
    padding: 22px 26px;
    background: linear-gradient(135deg, #172442, #111b36);
    border-left: 4px solid var(--cosmic-purple);
    border-radius: 0 12px 12px 0;
    color: #e5eaff;
    font-size: 19px;
}

.article-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 32px auto;
    border: 1px solid rgba(133, 158, 220, .18);
    border-radius: 12px;
}

.article-sidebar {
    position: sticky;
    top: 105px;
    padding: 20px;
    background: linear-gradient(155deg, #121d3a, #0c142b);
    border: 1px solid rgba(133, 158, 220, .2);
    border-radius: 14px;
}

.article-sidebar .section-heading {
    margin-bottom: 18px;
}

.article-sidebar .section-heading h2 {
    color: #fff;
}

.article-sidebar .featured-small {
    margin-bottom: 12px;
}

/* Mobile article layout */
@media (max-width: 850px) {
    .article-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
    }

    .article-sidebar {
        display: block;
        position: static;
        padding: 18px;
    }

    .article-sidebar > a {
        display: grid;
        grid-template-columns: 110px minmax(0, 1fr);
        align-items: center;
        gap: 13px;
        min-height: 90px;
    }

    .article-sidebar .featured-small img {
        width: 110px;
        height: 78px;
        object-fit: cover;
    }
}

@media (max-width: 600px) {
    .article-header {
        padding: 21px 18px;
        margin-bottom: 20px;
        border-radius: 11px;
    }

    .article-header h1 {
        font-size: clamp(27px, 7vw, 34px);
        line-height: 1.2;
        letter-spacing: -.5px;
    }

    .article-subtitle {
        font-size: 15px;
        line-height: 1.65;
    }

    .article-featured-image {
        margin-bottom: 26px;
        border-radius: 10px;
    }

    .article-content {
        font-size: 16px;
        line-height: 1.85;
    }

    .article-content p {
        margin-bottom: 21px;
    }

    .article-content h2 {
        margin-top: 37px;
        font-size: 24px;
    }

    .article-content h3 {
        margin-top: 29px;
        font-size: 20px;
    }

    .article-content blockquote {
        padding: 17px 19px;
        font-size: 16px;
    }

    .article-sidebar {
        padding: 14px;
    }

    .article-sidebar > a {
        grid-template-columns: 96px minmax(0, 1fr);
        gap: 11px;
        padding: 8px;
    }

    .article-sidebar .featured-small img {
        width: 96px;
        height: 72px;
    }

    .article-sidebar .featured-small h3 {
        font-size: 12px;
    }
}


/* Align article text with featured image */
.article-content {
    width: 100%;
    max-width: none;
    margin-left: 0;
    margin-right: 0;
}


/* Article social sharing bar */
.article-share {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
    margin-top: 19px;
}

.article-share-label {
    margin-right: 4px;
    color: #929fbe;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.3px;
}

.share-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 12px;
    border: 1px solid rgba(133, 158, 220, .25);
    border-radius: 7px;
    background: #172442;
    color: #e8edff;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: .2s ease;
}

.share-button:hover {
    border-color: #9b62ed;
    background: #24345d;
    color: #fff;
}

.share-copy-status {
    color: #8de0b2;
    font-size: 11px;
}

@media(max-width:600px) {
    .article-share {
        gap: 7px;
    }

    .share-button {
        min-height: 32px;
        padding: 6px 9px;
        font-size: 11px;
    }

    .article-share-label {
        width: 100%;
    }
}


/* Circular social sharing icons */
.article-share {
    gap: 10px;
}

.share-button {
    width: 40px;
    height: 40px;
    min-height: 40px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,.18);
    color: #fff;
    transition: transform .2s ease, box-shadow .2s ease;
}

.share-button svg {
    width: 19px;
    height: 19px;
    display: block;
    fill: currentColor;
}

.share-whatsapp {
    background: #25D366;
    border-color: #25D366;
}

.share-facebook {
    background: #1877F2;
    border-color: #1877F2;
}

.share-x {
    background: #080808;
    border-color: #555;
}

.share-copy {
    background: #34415f;
    border-color: #526487;
}

.share-button:hover {
    transform: translateY(-3px);
    color: #fff;
    box-shadow: 0 5px 16px rgba(0,0,0,.3);
}

.article-share-label {
    margin-right: 5px;
}

@media(max-width:600px) {
    .article-share {
        gap: 9px;
    }

    .share-button {
        width: 37px;
        height: 37px;
        min-height: 37px;
    }

    .share-button svg {
        width: 18px;
        height: 18px;
    }
}


/* Author information card */
.article-author-card {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-top: 45px;
    padding: 24px;
    background: linear-gradient(145deg, #172442, #0e172f);
    border: 1px solid rgba(133, 158, 220, .22);
    border-radius: 13px;
}

.author-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 58px;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: linear-gradient(135deg, #526dff, #9b62ed);
    color: #fff;
    font-size: 25px;
    font-weight: 800;
}

.author-details {
    min-width: 0;
}

.author-card-label,
.more-stories-eyebrow {
    color: #a99aff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
}

.author-details h3 {
    margin: 5px 0;
    color: #fff;
    font-size: 19px;
}

.author-details p {
    margin: 0;
    color: #aebbd7;
    font-size: 13px;
    line-height: 1.6;
}

/* More stories section */
.article-more-stories {
    margin-top: 65px;
    padding-top: 32px;
    border-top: 1px solid rgba(133, 158, 220, .2);
}

.more-stories-heading {
    margin-bottom: 24px;
}

.more-stories-heading h2 {
    margin: 7px 0 0;
    color: #fff;
    font-size: 27px;
}

.more-stories-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.more-story-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: linear-gradient(145deg, #172442, #0e172f);
    border: 1px solid rgba(133, 158, 220, .2);
    border-radius: 12px;
    color: #fff;
    text-decoration: none;
    transition: transform .2s ease, border-color .2s ease;
}

.more-story-card:hover {
    transform: translateY(-4px);
    border-color: #9b62ed;
}

.more-story-card img {
    display: block;
    width: 100%;
    height: 175px;
    object-fit: cover;
}

.more-story-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: flex-start;
    padding: 16px;
}

.more-story-category {
    margin-bottom: 8px;
    color: #a99aff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .8px;
    text-transform: uppercase;
}

.more-story-body h3 {
    margin: 0 0 15px;
    color: #f2f4ff;
    font-size: 16px;
    line-height: 1.45;
}

.more-story-read {
    margin-top: auto;
    color: #f5d328;
    font-size: 12px;
    font-weight: 700;
}

@media(max-width:850px) {
    .more-stories-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media(max-width:600px) {
    .article-author-card {
        align-items: flex-start;
        gap: 13px;
        margin-top: 32px;
        padding: 17px;
    }

    .author-avatar {
        flex-basis: 46px;
        width: 46px;
        height: 46px;
        font-size: 20px;
    }

    .author-details h3 {
        font-size: 16px;
    }

    .author-details p {
        font-size: 12px;
    }

    .article-more-stories {
        margin-top: 42px;
        padding-top: 25px;
    }

    .more-stories-heading h2 {
        font-size: 22px;
    }

    .more-stories-grid {
        grid-template-columns: 1fr;
        gap: 13px;
    }

    .more-story-card {
        display: grid;
        grid-template-columns: 115px minmax(0, 1fr);
    }

    .more-story-card img {
        width: 115px;
        height: 100%;
        min-height: 125px;
    }

    .more-story-body {
        padding: 12px;
    }

    .more-story-body h3 {
        font-size: 13px;
        margin-bottom: 9px;
    }
}


/* Homepage desktop width refinement */
@media (min-width: 1200px) {
    body:has(.home-hero) .page-content > .container {
        width: min(100% - 60px, 1320px);
    }
}


/* ==========================================================
   COSMIC FOOTER REDESIGN
   ========================================================== */

.site-footer {
    padding: 55px 30px 22px;
    background:
        radial-gradient(ellipse at 50% 0%, rgba(67, 69, 160, .22), transparent 65%),
        linear-gradient(180deg, #090f25, #050817);
    border-top: 1px solid rgba(135, 158, 230, .22);
}

.footer-inner {
    max-width: 1320px;
    margin: 0 auto;
    text-align: left;
}

.footer-main {
    display: grid;
    grid-template-columns: 1.25fr 1fr 1.2fr .7fr;
    gap: 42px;
    align-items: start;
    padding-bottom: 38px;
}

.footer-about .footer-brand {
    display: inline-block;
    margin-bottom: 14px;
}

.footer-about .footer-brand img {
    display: block;
    width: 210px;
    height: auto;
}

.footer-about > p {
    max-width: 290px;
    color: #a6b0ca;
    font-size: 14px;
    line-height: 1.8;
}

.footer-links-group h3,
.footer-standards h3 {
    margin: 7px 0 20px;
    color: #f5d328;
    font-size: 15px;
    font-weight: 800;
}

.footer-nav {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    margin: 0;
}

.footer-nav a {
    color: #b9c4df;
    font-size: 13px;
    line-height: 1.5;
    text-decoration: none;
    transition: color .2s ease, transform .2s ease;
}

.footer-nav a:hover {
    color: #f5d328;
    transform: translateX(3px);
}

.footer-standards img {
    display: block;
    width: 145px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.footer-bottom {
    padding-top: 20px;
    border-top: 1px solid rgba(135, 158, 230, .2);
    text-align: center;
}

.footer-bottom .copyright {
    margin: 0;
    padding: 0;
    border: 0;
    color: #8794b5;
    font-size: 12px;
}

@media (max-width: 1000px) {
    .footer-main {
        grid-template-columns: 1fr 1fr;
        gap: 38px 30px;
    }

    .footer-standards img {
        width: 125px;
    }
}

@media (max-width: 600px) {
    .site-footer {
        padding: 38px 22px 20px;
    }

    .footer-main {
        grid-template-columns: 1fr 1fr;
        gap: 30px 18px;
    }

    .footer-about {
        grid-column: 1 / -1;
    }

    .footer-about .footer-brand img {
        width: 185px;
    }

    .footer-links-group h3,
    .footer-standards h3 {
        font-size: 13px;
        margin-bottom: 15px;
    }

    .footer-nav {
        gap: 10px;
    }

    .footer-nav a {
        font-size: 12px;
        overflow-wrap: anywhere;
    }

    .footer-standards img {
        width: 105px;
    }

    .footer-bottom {
        margin-top: 8px;
    }
}

@media (max-width: 380px) {
    .footer-main {
        grid-template-columns: 1fr;
    }

    .footer-about,
    .footer-standards {
        grid-column: auto;
    }
}

/* End cosmic footer redesign */

/* Compact mobile footer refinement */
@media (max-width: 600px) {
    .footer-nav {
        gap: 8px;
    }

    .footer-nav a {
        font-size: 11px;
        line-height: 1.45;
    }

    .footer-links-group h3,
    .footer-standards h3 {
        margin-bottom: 12px;
    }

    .footer-standards img {
        width: 80px;
    }
}


/* Editorial homepage sections */
.editorial-ticker {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 48px;
    margin: 22px 0;
    padding: 0 16px;
    overflow: hidden;
    border-radius: 8px;
    background: #171b22;
    color: #fff;
}
.editorial-ticker > strong {
    flex: 0 0 auto;
    padding: 7px 10px;
    border-radius: 4px;
    background: #d92d36;
    color: #fff;
    font-size: 11px;
    letter-spacing: .08em;
}
.trending-ticker > strong { background: #6b5bc5; }
.editorial-ticker-window { min-width: 0; flex: 1; overflow: hidden; }
.editorial-ticker-track {
    display: flex;
    width: max-content;
    align-items: center;
    gap: 34px;
    white-space: nowrap;
    animation: wisTickerScroll 34s linear infinite;
}
.editorial-ticker:hover .editorial-ticker-track { animation-play-state: paused; }
.editorial-ticker-track a {
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}
.editorial-ticker-track a::before {
    content: "•";
    margin-right: 12px;
    color: #f0bd4e;
}
@keyframes wisTickerScroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}
.editorial-exclusive .section-heading,
.editorial-slider-section .section-heading,
.editorial-recommended .section-heading { margin-bottom: 20px; }
.exclusive-story-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 28px;
    border-top: 1px solid var(--border-color, #e3e6ec);
}
.exclusive-story {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 14px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-color, #e3e6ec);
}
.exclusive-story-number {
    color: #8172ce;
    font-size: 23px;
    font-weight: 800;
}
.exclusive-story h3 { margin: 5px 0 7px; font-size: 17px; line-height: 1.35; }
.exclusive-story h3 a { color: inherit; text-decoration: none; }
.exclusive-story h3 a:hover { color: #6b5bc5; }
.exclusive-story p {
    margin: 0;
    color: var(--muted-text, #687386);
    font-size: 13px;
    line-height: 1.55;
}
.slider-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.editorial-slider-controls { display: flex; gap: 8px; }
.editorial-slider-controls button {
    width: 38px;
    height: 38px;
    border: 1px solid var(--border-color, #dfe3ea);
    border-radius: 50%;
    background: #fff;
    color: #202938;
    font-size: 25px;
    line-height: 1;
    cursor: pointer;
}
.editorial-slider-controls button:hover { background: #6b5bc5; color: #fff; }
.editorial-slider { overflow: hidden; }
.editorial-slider-track {
    display: grid;
    grid-auto-columns: minmax(250px, 31.5%);
    grid-auto-flow: column;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    scroll-snap-type: x mandatory;
}
.editorial-slider-track::-webkit-scrollbar { display: none; }
.editorial-slide {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--border-color, #e4e7ed);
    border-radius: 10px;
    background: #fff;
    scroll-snap-align: start;
}
.editorial-slide > a { display: block; height: 100%; color: inherit; text-decoration: none; }
.editorial-slide-image { aspect-ratio: 16 / 9; overflow: hidden; background: #edf0f4; }
.editorial-slide-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.editorial-slide:hover img { transform: scale(1.04); }
.editorial-slide-body { padding: 16px; }
.editorial-slide-body h3 { margin: 8px 0; font-size: 17px; line-height: 1.35; }
.editorial-slide-body p { margin: 0; color: var(--muted-text, #687386); font-size: 13px; line-height: 1.5; }
@media (max-width: 760px) {
    .editorial-ticker { gap: 10px; min-height: 44px; margin: 16px 0; padding: 0 10px; }
    .editorial-ticker > strong { padding: 6px 7px; font-size: 9px; }
    .editorial-ticker-track { gap: 22px; }
    .editorial-ticker-track a { font-size: 12px; }
    .exclusive-story-list { grid-template-columns: 1fr; }
    .exclusive-story { padding: 16px 0; }
    .editorial-slider-track { grid-auto-columns: minmax(78%, 78%); gap: 12px; }
    .editorial-slide-body { padding: 13px; }
    .editorial-slide-body h3 { font-size: 15px; }
}



/* =========================================================
   HOMEPAGE COSMIC VISUAL LAYER — targeted homepage sections
   ========================================================= */
.page-content {
    position: relative;
    isolation: isolate;
}
.page-content > .container {
    position: relative;
    z-index: 1;
}
.category-home-section,
.latest-home-section,
.editorial-exclusive,
.editorial-slider-section,
.editorial-recommended {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 30px 28px 32px;
    border: 1px solid rgba(143, 169, 226, .22);
    border-radius: 16px;
    background-color: #091329;
    box-shadow: 0 18px 42px rgba(0, 0, 0, .24);
}
.category-home-section::before,
.latest-home-section::before,
.editorial-exclusive::before,
.editorial-slider-section::before,
.editorial-recommended::before {
    position: absolute;
    z-index: -2;
    inset: 0;
    content: "";
    background-image:
        linear-gradient(115deg, rgba(4, 10, 27, .94) 0%, rgba(5, 12, 31, .82) 48%, rgba(5, 10, 25, .72) 100%),
        url('/assets/images/cosmic-earth-sunrise.webp');
    background-size: cover;
    background-position: center 48%;
    opacity: 1;
}
.category-home-section::after,
.latest-home-section::after,
.editorial-exclusive::after,
.editorial-slider-section::after,
.editorial-recommended::after {
    position: absolute;
    z-index: -1;
    inset: 0;
    content: "";
    pointer-events: none;
    background: radial-gradient(ellipse at 82% 10%, rgba(69, 115, 190, .16), transparent 48%);
}
.category-home-section:nth-of-type(even)::before,
.editorial-recommended::before {
    background-image:
        linear-gradient(115deg, rgba(4, 10, 27, .95) 0%, rgba(5, 12, 31, .84) 55%, rgba(5, 10, 25, .75) 100%),
        url('/assets/images/cosmic-asteroid-earth.webp');
    background-position: center 42%;
}
.latest-home-section::before {
    background-image:
        linear-gradient(115deg, rgba(4, 10, 27, .94) 0%, rgba(5, 12, 31, .78) 52%, rgba(5, 10, 25, .68) 100%),
        url('/assets/images/cosmic-asteroid-earth.webp');
    background-position: center 46%;
}
.editorial-exclusive::before {
    background-image:
        linear-gradient(115deg, rgba(4, 10, 27, .95), rgba(5, 12, 31, .78)),
        url('/assets/images/cosmic-earth-sunrise.webp');
}
.editorial-slider-section::before {
    background-image:
        linear-gradient(115deg, rgba(4, 10, 27, .94), rgba(5, 12, 31, .78)),
        url('/assets/images/cosmic-astronaut-earth.webp');
}
.category-home-section .section-heading,
.latest-home-section .section-heading,
.editorial-exclusive .section-heading,
.editorial-slider-section .section-heading,
.editorial-recommended .section-heading,
.category-home-section .article-grid,
.latest-home-section .article-grid,
.editorial-recommended .article-grid,
.category-home-section .section-more,
.latest-home-section .pagination {
    position: relative;
    z-index: 1;
}
.category-home-section .section-heading,
.latest-home-section .section-heading,
.editorial-exclusive .section-heading,
.editorial-slider-section .section-heading,
.editorial-recommended .section-heading {
    border-bottom: 1px solid rgba(210, 224, 255, .22);
}
.category-home-section .section-heading h2,
.latest-home-section .section-heading h2,
.editorial-exclusive .section-heading h2,
.editorial-slider-section .section-heading h2,
.editorial-recommended .section-heading h2 {
    color: #fff;
    text-shadow: 0 2px 12px rgba(0, 0, 0, .45);
}
.category-home-section .article-card,
.latest-home-section .article-card,
.editorial-recommended .article-card {
    overflow: hidden;
    border: 1px solid rgba(164, 186, 231, .18);
    border-radius: 11px;
    background: rgba(7, 15, 35, .82);
    box-shadow: 0 10px 26px rgba(0, 0, 0, .2);
    backdrop-filter: blur(5px);
}
.category-home-section .article-card-body,
.latest-home-section .article-card-body,
.editorial-recommended .article-card-body {
    background: transparent;
}
.category-home-section .article-card h3 a,
.latest-home-section .article-card h3 a,
.editorial-recommended .article-card h3 a {
    color: #fff;
}
.category-home-section .article-card p,
.latest-home-section .article-card p,
.editorial-recommended .article-card p {
    color: rgba(232, 239, 255, .78);
}
.category-home-section .article-meta,
.latest-home-section .article-meta,
.editorial-recommended .article-meta {
    color: rgba(210, 222, 246, .65);
}
.latest-home-section {
    margin-top: 58px;
    padding-top: 30px;
    border-top: 1px solid rgba(143, 169, 226, .22);
}

/* Refined editorial ticker: duplicated track content creates a seamless loop. */
.editorial-ticker {
    position: relative;
    display: flex;
    align-items: stretch;
    gap: 0;
    min-height: 56px;
    margin: 18px 0 26px;
    padding: 0;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 9px;
    background: linear-gradient(100deg, #101a32, #080f20 72%);
    box-shadow: 0 9px 24px rgba(0, 0, 0, .24);
}
.editorial-ticker > strong {
    position: relative;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 142px;
    padding: 0 18px;
    border-radius: 0;
    background: linear-gradient(135deg, #d83b42, #a91f32);
    color: #fff;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 1.2px;
    white-space: nowrap;
}
.trending-ticker > strong {
    min-width: 158px;
    background: linear-gradient(135deg, #f4c84b, #e59a21);
    color: #151a27;
}
.editorial-ticker-window {
    position: relative;
    display: flex;
    min-width: 0;
    flex: 1;
    align-items: center;
    overflow: hidden;
}
.editorial-ticker-window::before,
.editorial-ticker-window::after {
    position: absolute;
    z-index: 1;
    top: 0;
    bottom: 0;
    width: 34px;
    content: "";
    pointer-events: none;
}
.editorial-ticker-window::before {
    left: 0;
    background: linear-gradient(90deg, #0e1830, transparent);
}
.editorial-ticker-window::after {
    right: 0;
    background: linear-gradient(270deg, #0a1226, transparent);
}
.editorial-ticker-track {
    display: flex;
    width: max-content;
    min-width: max-content;
    align-items: center;
    gap: 0;
    padding-left: 24px;
    white-space: nowrap;
    will-change: transform;
    animation: wisTickerScroll 42s linear infinite;
}
.editorial-ticker:hover .editorial-ticker-track,
.editorial-ticker:focus-within .editorial-ticker-track {
    animation-play-state: paused;
}
.editorial-ticker-track a {
    display: inline-flex;
    align-items: center;
    min-height: 56px;
    padding: 0 28px;
    border-right: 1px solid rgba(210, 224, 255, .16);
    color: #f5f7ff;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: color .2s ease;
}
.editorial-ticker-track a:hover {
    color: #ffd76a;
}
.editorial-ticker-track a::before {
    content: "◆";
    margin-right: 13px;
    color: #f2c34c;
    font-size: 8px;
}
.breaking-ticker .editorial-ticker-track a::before {
    color: #ff656d;
}
@keyframes wisTickerScroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@media (max-width: 700px) {
    .category-home-section,
    .latest-home-section,
    .editorial-exclusive,
    .editorial-slider-section,
    .editorial-recommended {
        padding: 22px 14px 24px;
        border-radius: 12px;
    }
    .editorial-ticker {
        min-height: 48px;
        margin: 14px 0 20px;
        border-radius: 7px;
    }
    .editorial-ticker > strong,
    .trending-ticker > strong {
        min-width: 104px;
        padding: 0 9px;
        font-size: 9px;
        letter-spacing: .7px;
    }
    .editorial-ticker-track {
        animation-duration: 32s;
        padding-left: 12px;
    }
    .editorial-ticker-track a {
        min-height: 48px;
        padding: 0 17px;
        font-size: 11px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .editorial-ticker-track {
        animation: none;
    }
}

/* =========================================================
   HOMEPAGE FULL-WIDTH CONTINUOUS COSMIC BACKGROUND
   ========================================================= */
.page-content {
    background:
        linear-gradient(
            180deg,
            rgba(3, 8, 22, .48) 0%,
            rgba(3, 8, 22, .62) 48%,
            rgba(3, 8, 22, .78) 100%
        ),
        url('/assets/images/cosmic-astronaut-earth.webp');
    background-position: center top;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* Remove individual section background panels */
.page-content .category-home-section,
.page-content .latest-home-section,
.page-content .editorial-exclusive,
.page-content .editorial-slider-section,
.page-content .editorial-recommended {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
    border-radius: 0;
}

/* Disable individual section background images */
.page-content .category-home-section::before,
.page-content .latest-home-section::before,
.page-content .editorial-exclusive::before,
.page-content .editorial-slider-section::before,
.page-content .editorial-recommended::before,
.page-content .category-home-section::after,
.page-content .latest-home-section::after,
.page-content .editorial-exclusive::after,
.page-content .editorial-slider-section::after,
.page-content .editorial-recommended::after {
    display: none;
}

/* Keep the background scrolling naturally on mobile */
@media (max-width: 760px) {
    .page-content {
        background-attachment: scroll;
        background-position: center top;
    }
}

/* Featured story expands when no side stories are assigned */
.featured-grid.featured-grid--solo {
    grid-template-columns: minmax(0, 1fr);
}

.featured-grid.featured-grid--solo .featured-main {
    min-height: 440px;
}

@media (max-width: 760px) {
    .featured-grid.featured-grid--solo .featured-main,
    .featured-grid.featured-grid--solo .featured-main img {
        min-height: 280px;
    }
}

/* Prevent featured supporting stories from stretching vertically */
.featured-side {
    align-content: start;
    grid-auto-rows: max-content;
}

.featured-side .featured-small {
    align-self: start;
}

/* =========================================================
   WHATIFSCIENCE — COSMIC CATEGORY PAGE REFINEMENT
   ========================================================= */

.page-content:has(.category-header) {
    background:
        linear-gradient(
            180deg,
            rgba(3, 8, 22, .48),
            rgba(3, 8, 22, .68) 55%,
            rgba(3, 8, 22, .82)
        ),
        url('/assets/images/cosmic-astronaut-earth.webp') center top / cover no-repeat;
    background-attachment: fixed;
}

.category-header {
    position: relative;
    margin-bottom: 32px;
    padding: 48px 34px 32px;
    border: 1px solid rgba(143, 169, 226, .18);
    border-radius: 15px;
    background: linear-gradient(115deg, rgba(8, 18, 43, .82), rgba(8, 18, 43, .38));
    backdrop-filter: blur(8px);
}

.category-header > .category-label {
    display: inline-block;
    padding: 7px 12px;
    border-radius: 4px;
    background: rgba(241, 214, 107, .12);
    color: #f5d76b;
    font-size: 11px;
}

.category-header .page-title {
    color: #fff;
    font-size: clamp(36px, 5vw, 54px);
    letter-spacing: -.8px;
    text-shadow: 0 3px 20px rgba(0, 0, 0, .4);
}

.category-header .article-subtitle {
    color: rgba(229, 237, 255, .85);
}

.category-tagline {
    color: #f5d76b;
}

.category-featured-story {
    border-color: rgba(170, 192, 242, .3);
    box-shadow: 0 22px 55px rgba(0, 0, 0, .4);
}

.category-featured-overlay {
    padding: 42px;
}

.category-story-row {
    border-color: rgba(155, 180, 234, .23);
    background: linear-gradient(115deg, rgba(13, 27, 57, .94), rgba(7, 17, 39, .88));
    box-shadow: 0 12px 30px rgba(0, 0, 0, .22);
    transition: transform .25s ease, border-color .25s ease;
}

.category-story-row:hover {
    transform: translateY(-3px);
    border-color: rgba(245, 215, 107, .48);
}

.category-story-image {
    background: #101b35;
}

.category-story-body h2 a {
    color: #fff;
}

.category-story-body p {
    color: rgba(225, 234, 255, .76);
}

.category-story-body .article-meta {
    color: rgba(205, 219, 249, .65);
}

.page-content:has(.category-header) .pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 9px;
    margin: 32px 0 55px;
}

.page-content:has(.category-header) .pagination a,
.page-content:has(.category-header) .pagination .current {
    display: inline-flex;
    min-width: 42px;
    min-height: 42px;
    justify-content: center;
    align-items: center;
    padding: 0 13px;
    border: 1px solid rgba(164, 188, 239, .3);
    border-radius: 7px;
    background: rgba(10, 23, 49, .88);
    color: #fff;
    text-decoration: none;
}

.page-content:has(.category-header) .pagination .current {
    border-color: #f1d66b;
    background: #f1d66b;
    color: #10172a;
    font-weight: 800;
}

.page-content:has(.category-header) .pagination a:hover {
    border-color: #f1d66b;
    color: #f1d66b;
}

@media (max-width: 700px) {
    .page-content:has(.category-header) {
        background-attachment: scroll;
    }

    .category-header {
        padding: 30px 20px 24px;
        border-radius: 11px;
    }

    .category-header .page-title {
        font-size: 34px;
    }

    .category-featured-overlay {
        padding: 22px 20px;
    }

    .category-story-row:hover {
        transform: none;
    }
}

/* =========================================================
   WHATIFSCIENCE — FINAL COSMIC ARTICLE PAGE REFINEMENT
   ========================================================= */

.page-content:has(.article-layout) {
    background:
        linear-gradient(
            180deg,
            rgba(3, 8, 22, .48),
            rgba(3, 8, 22, .65) 55%,
            rgba(3, 8, 22, .82)
        ),
        url('/assets/images/cosmic-astronaut-earth.webp') center top / cover no-repeat;
    background-attachment: fixed;
}

.article-header {
    background: linear-gradient(
        125deg,
        rgba(18, 31, 63, .91),
        rgba(7, 15, 35, .88)
    );
    border-color: rgba(155, 180, 234, .28);
    box-shadow: 0 16px 42px rgba(0, 0, 0, .22);
    backdrop-filter: blur(8px);
}

.article-header .category-label {
    padding: 7px 11px;
    border-radius: 4px;
    background: rgba(245, 211, 40, .12);
}

.article-header h1 {
    text-shadow: 0 3px 20px rgba(0, 0, 0, .3);
}

.article-header .article-meta {
    color: #b9c7e6;
}

.article-featured-image {
    aspect-ratio: 16 / 9;
    width: 100%;
    height: auto;
    max-height: 560px;
    object-fit: cover;
    border-color: rgba(155, 180, 234, .3);
    box-shadow: 0 22px 55px rgba(0, 0, 0, .35);
}

.article-content {
    color: #e0e7f8;
}

.article-content h2 {
    border-bottom-color: rgba(155, 180, 234, .25);
}

.article-content blockquote {
    border-left-color: #f1d66b;
    background: linear-gradient(
        135deg,
        rgba(25, 39, 75, .96),
        rgba(12, 23, 48, .96)
    );
}

.article-sidebar {
    background: linear-gradient(
        155deg,
        rgba(19, 32, 65, .96),
        rgba(8, 17, 39, .96)
    );
    border-color: rgba(155, 180, 234, .26);
    box-shadow: 0 14px 35px rgba(0, 0, 0, .22);
}

.article-author-card,
.more-story-card {
    border-color: rgba(155, 180, 234, .25);
    background: linear-gradient(
        145deg,
        rgba(23, 37, 72, .96),
        rgba(9, 19, 43, .96)
    );
}

.article-more-stories {
    border-top-color: rgba(155, 180, 234, .28);
}

.more-story-category {
    color: #f1d66b;
}

.more-story-card:hover {
    border-color: #f1d66b;
}

@media (max-width: 850px) {
    .page-content:has(.article-layout) {
        background-attachment: scroll;
    }
}

@media (max-width: 600px) {
    .article-header {
        padding: 23px 18px;
    }

    .article-featured-image {
        box-shadow: 0 12px 28px rgba(0, 0, 0, .3);
    }
}



/* Article mobile refinement - November 2026 */
@media (max-width: 600px) {
    .article-header {
        padding: 19px 16px;
    }

    .article-header h1 {
        font-size: clamp(25px, 6.5vw, 31px);
        line-height: 1.19;
    }

    .article-content {
        font-size: 15px;
        line-height: 1.78;
    }

    .article-content p {
        margin-bottom: 19px;
    }

    .article-content h2 {
        margin-top: 33px;
        font-size: 22px;
        line-height: 1.32;
    }

    .article-content h3 {
        margin-top: 27px;
        font-size: 19px;
    }

    .article-sidebar {
        padding: 12px;
    }

    .article-sidebar .section-heading h2 {
        font-size: 20px;
    }

    .article-sidebar > a {
        grid-template-columns: 84px minmax(0, 1fr);
        gap: 10px;
        min-height: 76px;
        padding: 7px;
    }

    .article-sidebar .featured-small img {
        width: 84px;
        height: 64px;
    }

    .article-sidebar .featured-small h3 {
        font-size: 12px;
        line-height: 1.4;
    }

    .article-more-stories {
        margin-top: 36px;
        padding-top: 22px;
    }

    .more-stories-grid {
        gap: 11px;
    }

    .more-story-card {
        grid-template-columns: 100px minmax(0, 1fr);
    }

    .more-story-card img {
        width: 100px;
        min-height: 112px;
    }

    .more-story-body {
        padding: 10px;
    }

    .more-story-body h3 {
        font-size: 12.5px;
        line-height: 1.4;
    }
}



/* ==========================================================
   M15 — HEADER AND NAVIGATION REDESIGN
   November 2026
   ========================================================== */

.header-inner {
    gap: 20px;
}

.main-nav {
    gap: 19px;
}

.main-nav a {
    font-size: 14px;
    font-weight: 700;
    gap: 8px;
}

.main-nav .nav-icon {
    width: 20px;
    height: 20px;
    flex-basis: 20px;
    stroke-width: 1.9;
}

.header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 17px;
    flex-shrink: 0;
}

.header-search-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.search-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 9px;
    color: var(--accent);
    background: rgba(20, 29, 56, .8);
    border: 1px solid rgba(139, 160, 225, .27);
    border-radius: 9px;
    cursor: pointer;
    transition: background .2s ease, border-color .2s ease;
}

.search-toggle:hover,
.search-toggle[aria-expanded="true"] {
    background: rgba(65, 79, 130, .55);
    border-color: var(--accent);
}

.search-toggle svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.header-search[hidden] {
    display: none !important;
}

.header-search-wrap .header-search:not([hidden]) {
    position: absolute;
    top: calc(100% + 13px);
    right: 0;
    z-index: 1100;
    display: flex;
    width: 320px;
    min-width: 0;
    padding: 7px;
    background: #111a32;
    border: 1px solid rgba(245, 211, 40, .45);
    border-radius: 10px;
    box-shadow: 0 12px 35px rgba(0, 0, 0, .45);
}

.header-search-wrap .header-search input {
    flex: 1;
    width: auto;
    min-width: 0;
    padding: 11px 12px;
    font-size: 14px;
}

.header-search-wrap .header-search button {
    padding: 8px 13px;
    color: #101010;
    background: var(--accent);
    border: 0;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 800;
}

.header-socials {
    display: flex;
    align-items: center;
    gap: 9px;
}

.header-socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: var(--accent);
    background: rgba(20, 29, 56, .55);
    border: 1px solid rgba(139, 160, 225, .17);
    border-radius: 50%;
    transition: color .2s ease, background .2s ease, border-color .2s ease, transform .2s ease;
}

.header-socials a:hover {
    color: var(--accent);
    background: rgba(65, 79, 130, .55);
    border-color: var(--accent);
    transform: translateY(-2px);
}

.header-socials svg {
    width: 17px;
    height: 17px;
    fill: currentColor;
}

/* Keep the desktop header balanced on narrower laptops */
@media (min-width: 851px) and (max-width: 1150px) {
    .header-inner {
        gap: 12px;
        padding-left: 16px;
        padding-right: 16px;
    }

    .main-nav {
        gap: 11px;
    }

    .main-nav a {
        font-size: 12px;
        gap: 5px;
    }

    .main-nav .nav-icon {
        width: 17px;
        height: 17px;
        flex-basis: 17px;
    }

    .header-actions {
        gap: 9px;
    }

    .header-socials {
        gap: 5px;
    }

    .header-socials a {
        width: 28px;
        height: 28px;
    }
}

/* Mobile header: logo, search and menu on first row */
@media (max-width: 850px) {
    .header-inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto auto;
        align-items: center;
        gap: 10px;
        padding: 12px 20px;
    }

    .wordmark.logo-link {
        grid-column: 1;
        grid-row: 1;
    }

    .header-actions {
        grid-column: 2;
        grid-row: 1;
        gap: 0;
    }

    .search-toggle {
        width: 46px;
        height: 46px;
    }

    .header-socials {
        display: none;
    }

    .menu-toggle {
        grid-column: 3;
        grid-row: 1;
        width: 46px;
        height: 46px;
        font-size: 24px;
    }

    .header-search-wrap .header-search:not([hidden]) {
        top: calc(100% + 12px);
        right: -56px;
        width: min(320px, calc(100vw - 30px));
    }

    .main-nav {
        grid-column: 1 / -1;
        grid-row: 2;
    }

    .main-nav a {
        font-size: 15px;
    }
}

@media (max-width: 600px) {
    .header-inner {
        padding: 11px 15px;
        gap: 8px;
    }

    .wordmark.logo-link img {
        width: min(220px, 100%);
    }

    .search-toggle,
    .menu-toggle {
        width: 42px;
        height: 42px;
    }
}


/* M15 mobile social links inside expanded navigation */
@media (max-width: 850px) {
    .header-actions {
        display: contents;
    }

    .header-search-wrap {
        grid-column: 2;
        grid-row: 1;
    }

    .header-inner:has(.main-nav.is-open) .header-socials {
        display: flex;
        grid-column: 1 / -1;
        grid-row: 3;
        justify-content: center;
        align-items: center;
        gap: 16px;
        width: 100%;
        padding: 16px 0 12px;
        border-top: 1px solid rgba(139, 160, 225, .2);
    }

    .header-socials a {
        width: 42px;
        height: 42px;
    }

    .header-socials svg {
        width: 20px;
        height: 20px;
    }
}


/* M19.3 - Homepage advertising placements */
.home-ad-slot {
    width: 100%;
    max-width: 100%;
    margin: 28px auto;
    text-align: center;
    box-sizing: border-box;
    overflow: hidden;
}

.home-ad-label {
    display: block;
    margin-bottom: 8px;
    color: #9299a8;
    font-size: 10px;
    line-height: 1.4;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.home-ad-content {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    text-align: center;
    overflow: hidden;
}

.home-ad-content img {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    margin: 0 auto;
    object-fit: contain;
}

.home-ad-content iframe {
    max-width: 100%;
}

.home-ad-slot--home-mid,
.home-ad-slot--home-feed {
    margin-top: 32px;
    margin-bottom: 32px;
}

.home-ad-slot--home-bottom {
    margin-top: 40px;
    margin-bottom: 20px;
}

@media (max-width: 600px) {
    .home-ad-slot {
        margin-top: 20px;
        margin-bottom: 20px;
        padding-left: 0;
        padding-right: 0;
    }

    .home-ad-content {
        max-width: 100%;
    }
}


/* M19.4 - In-article advertising placements */
.article-ad-slot {
    width: 100%;
    max-width: 100%;
    margin: 30px auto;
    padding: 16px 0;
    text-align: center;
    box-sizing: border-box;
    overflow: hidden;
    clear: both;
}

.article-ad-label {
    display: block;
    margin-bottom: 8px;
    color: #9299a8;
    font-size: 10px;
    line-height: 1.4;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.article-ad-content {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    text-align: center;
    overflow: hidden;
}

.article-ad-content img {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    margin: 0 auto;
    object-fit: contain;
}

.article-ad-content iframe,
.article-ad-content ins {
    max-width: 100%;
}

.article-ad-slot--desktop-only {
    display: block;
}

.article-ad-slot--mobile-only {
    display: none;
}

@media (max-width: 768px) {
    .article-ad-slot {
        margin: 22px auto;
        padding: 12px 0;
    }

    .article-ad-slot--desktop-only {
        display: none;
    }

    .article-ad-slot--mobile-only {
        display: block;
    }

    .article-ad-content {
        max-width: 100%;
    }
}


/* HTML Sitemap */
.html-sitemap {
    color: #e9edff;
}

.sitemap-hero {
    position: relative;
    overflow: hidden;
    padding: 55px 45px;
    margin-bottom: 38px;
    border: 1px solid rgba(135, 158, 230, .22);
    border-radius: 20px;
    background:
        radial-gradient(ellipse at 85% 15%, rgba(93, 105, 225, .25), transparent 42%),
        radial-gradient(ellipse at 10% 100%, rgba(35, 145, 190, .13), transparent 45%),
        #0c1530;
}

.sitemap-eyebrow {
    display: inline-block;
    margin-bottom: 14px;
    color: #9eafff;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
}

.sitemap-hero h1 {
    margin: 0 0 14px;
    color: #fff;
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.15;
}

.sitemap-hero > p {
    max-width: 720px;
    margin: 0;
    color: #bac6e6;
    font-size: 16px;
    line-height: 1.8;
}

.sitemap-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 35px;
    margin-top: 32px;
    padding-top: 25px;
    border-top: 1px solid rgba(160, 177, 230, .18);
}

.sitemap-stats div {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.sitemap-stats strong {
    color: #fff;
    font-size: 27px;
}

.sitemap-stats span {
    color: #9eadd0;
    font-size: 12px;
}

.sitemap-search-section {
    margin: 0 0 45px;
    padding: 25px;
    border: 1px solid rgba(135, 158, 230, .2);
    border-radius: 14px;
    background: #101a35;
}

.sitemap-search-section label {
    display: block;
    margin-bottom: 11px;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
}

.sitemap-search-section input {
    box-sizing: border-box;
    width: 100%;
    padding: 15px 17px;
    color: #fff;
    background: #080f22;
    border: 1px solid #35466e;
    border-radius: 9px;
    outline: none;
    font: inherit;
}

.sitemap-search-section input:focus {
    border-color: #899bff;
    box-shadow: 0 0 0 3px rgba(137, 155, 255, .13);
}

.sitemap-search-section input::placeholder {
    color: #8795b7;
}

.sitemap-search-section p {
    margin: 10px 0 0;
    color: #9eadd0;
    font-size: 12px;
}

.sitemap-block {
    margin: 0 0 48px;
}

.sitemap-heading {
    display: flex;
    align-items: center;
    gap: 17px;
    margin-bottom: 23px;
    padding-bottom: 17px;
    border-bottom: 1px solid rgba(135, 158, 230, .2);
}

.sitemap-heading > span {
    display: grid;
    place-items: center;
    flex: 0 0 43px;
    height: 43px;
    color: #aebaff;
    background: #17264d;
    border: 1px solid rgba(135, 158, 230, .25);
    border-radius: 12px;
    font-size: 13px;
    font-weight: 800;
}

.sitemap-heading h2 {
    margin: 0 0 5px;
    color: #fff;
    font-size: 23px;
}

.sitemap-heading p {
    margin: 0;
    color: #9eadd0;
    font-size: 13px;
}

.sitemap-category-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 19px;
}

.sitemap-category {
    min-width: 0;
    padding: 23px;
    border: 1px solid rgba(135, 158, 230, .19);
    border-radius: 14px;
    background: linear-gradient(145deg, #111d3b, #0c142b);
}

.sitemap-category-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(135, 158, 230, .15);
}

.sitemap-category-heading h3 {
    margin: 0;
    font-size: 17px;
    line-height: 1.4;
}

.sitemap-category-heading h3 a {
    color: #fff;
    text-decoration: none;
}

.sitemap-category-heading h3 a:hover {
    color: #aebaff;
}

.sitemap-category-heading > span {
    flex-shrink: 0;
    padding: 5px 9px;
    color: #b7c4ff;
    background: #1b2a53;
    border-radius: 20px;
    font-size: 10px;
    white-space: nowrap;
}

.sitemap-article-list {
    display: grid;
    gap: 0;
    margin: 12px 0 17px;
    padding: 0;
    list-style: none;
}

.sitemap-article-list li {
    padding: 9px 0;
    border-bottom: 1px solid rgba(135, 158, 230, .09);
}

.sitemap-article-list li[hidden],
.sitemap-category[hidden] {
    display: none !important;
}

.sitemap-article-list a {
    color: #bdc9e6;
    font-size: 13px;
    line-height: 1.55;
    text-decoration: none;
}

.sitemap-article-list a:hover {
    color: #aebaff;
}

.sitemap-category-more {
    color: #9eafff;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
}

.sitemap-category-more span {
    margin-left: 5px;
}

.sitemap-pages-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.sitemap-pages-grid a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 15px 17px;
    color: #d5def5;
    background: #111d3b;
    border: 1px solid rgba(135, 158, 230, .17);
    border-radius: 10px;
    font-size: 13px;
    text-decoration: none;
}

.sitemap-pages-grid a:hover {
    color: #fff;
    border-color: #7588e8;
    background: #17264d;
}

.sitemap-pages-grid a span {
    color: #9eafff;
}

@media (max-width: 760px) {
    .sitemap-hero {
        padding: 35px 24px;
    }

    .sitemap-category-grid {
        grid-template-columns: 1fr;
    }

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

    .sitemap-stats {
        gap: 22px;
    }
}

@media (max-width: 420px) {
    .sitemap-hero {
        padding: 29px 19px;
    }

    .sitemap-search-section,
    .sitemap-category {
        padding: 18px;
    }

    .sitemap-pages-grid {
        grid-template-columns: 1fr;
    }

    .sitemap-stats {
        gap: 17px;
    }
}
