/* ============================================================
   NOTORIOUS ROB — Ghost Theme
   Option B Revised: Clean Magazine + Editorial Headers
   ============================================================ */

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

:root {
    /* Brand colors */
    --navy: #00356b;
    --orange: #f56733;
    --orange-light: #fff4f0;

    /* Backgrounds */
    --bg: #ffffff;
    --bg-alt: #f5f7fa;

    /* Borders */
    --border: #e5e7eb;

    /* Text */
    --text: #1f2937;
    --text-light: #6b7280;
    --text-faint: #9ca3af;

    /* Fonts */
    --font-serif: 'Libre Baskerville', Georgia, serif;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    /* Spacing */
    --pad-x: 48px;
}

body {
    font-family: var(--font-sans);
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px var(--pad-x);
    background: var(--navy);
    border-bottom: none;
    position: sticky;
    top: 0;
    z-index: 100;
    transition: transform 0.3s ease;
}
.site-header.is-hidden {
    transform: translateY(-100%);
}

.site-logo {
    font-family: var(--font-sans);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--navy);
    text-decoration: none;
}
.site-logo img {
    height: 32px;
    width: auto;
}
.site-logo .logo-accent {
    color: var(--orange);
    font-weight: 800;
}

.site-nav {
    display: flex;
    align-items: center;
}
.site-nav ul {
    display: flex;
    gap: 28px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-nav li {
    list-style: none;
}
.site-nav a {
    text-decoration: none;
    color: rgba(255,255,255,0.85);
    font-size: 0.88rem;
    font-weight: 500;
}
.site-nav a:hover { color: white; }

.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.btn-outline {
    border: 1.5px solid rgba(255,255,255,0.7);
    color: white;
    padding: 8px 20px;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    background: transparent;
    cursor: pointer;
    font-family: var(--font-sans);
}
.btn-outline:hover {
    background: rgba(255,255,255,0.15);
    color: white;
}

.btn-fill {
    background: var(--orange);
    color: white;
    padding: 8px 20px;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-sans);
}
.btn-fill:hover {
    background: #e05525;
}

.search-btn {
    background: none;
    border: none;
    padding: 6px;
    cursor: pointer;
    color: rgba(255,255,255,0.85);
    display: flex;
    align-items: center;
}
.search-btn:hover { color: var(--navy); }

.menu-toggle {
    display: none;
    background: none;
    border: none;
    padding: 6px;
    cursor: pointer;
    color: white;
}


/* ============================================================
   HERO CARD (Featured Post)
   ============================================================ */
.hero-section {
    margin: 32px var(--pad-x);
    padding: 48px 56px;
    background: var(--navy);
    border-radius: 16px;
    color: white;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 48px;
    align-items: center;
}
.hero-section a { color: white; text-decoration: none; }

.hero-label {
    display: inline-block;
    background: var(--orange);
    color: white;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
    text-decoration: none;
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 16px;
}
.hero-title a { color: white; text-decoration: none; }
.hero-title a:hover { opacity: 0.9; }

.hero-excerpt {
    font-size: 1rem;
    line-height: 1.7;
    color: rgba(255,255,255,0.75);
    max-width: 500px;
}

.hero-meta {
    margin-top: 20px;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
    display: flex;
    gap: 16px;
    align-items: center;
}
.hero-meta .separator {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
}
.hero-meta .paid-badge {
    background: var(--orange);
    padding: 2px 8px;
    border-radius: 3px;
    font-weight: 600;
    color: white;
    font-size: 0.68rem;
}

.hero-image {
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 4/3;
}
.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.hero-no-image {
    background: rgba(255,255,255,0.08);
    border-radius: 12px;
    aspect-ratio: 4/3;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.1);
    font-size: 3rem;
    font-family: var(--font-serif);
}


/* ============================================================
   SECTION HEADERS (Editorial style from Option A)
   ============================================================ */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 28px;
    border-bottom: 2px solid var(--navy);
    padding-bottom: 10px;
}
.section-title {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
}
.section-link {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--orange);
    text-decoration: none;
    font-weight: 600;
}
.section-link:hover { color: var(--navy); }


/* ============================================================
   CONTENT AREA (Latest + Sidebar)
   ============================================================ */
.content-area {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 48px;
    padding: 48px var(--pad-x) 32px;
}


/* ============================================================
   POST LIST (Latest posts)
   ============================================================ */
.post-list { display: flex; flex-direction: column; }

.post-item {
    display: grid;
    grid-template-columns: 1fr 180px;
    gap: 24px;
    align-items: start;
    padding: 28px 0;
    border-bottom: 1px solid var(--border);
}
.post-item:first-child { padding-top: 0; }

.post-item-tag {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--orange);
    margin-bottom: 6px;
}
.post-item-tag a {
    color: var(--orange);
    text-decoration: none;
}
.post-item-tag a:hover { color: var(--navy); }

.post-item h3 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 8px;
    color: var(--text);
}
.post-item h3 a {
    color: inherit;
    text-decoration: none;
}
.post-item h3 a:hover { color: var(--navy); }

.post-item p {
    font-size: 0.88rem;
    color: var(--text-light);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-item-meta {
    font-size: 0.75rem;
    color: var(--text-faint);
    margin-top: 8px;
    display: flex;
    gap: 8px;
    align-items: center;
}
.post-item-meta .paid-badge {
    background: var(--navy);
    color: white;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 600;
}

.post-item-image {
    width: 100%;
    aspect-ratio: 4/3;
    background: var(--bg-alt);
    border-radius: 8px;
    overflow: hidden;
}
.post-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}


/* ============================================================
   SIDEBAR
   ============================================================ */
.sidebar-card {
    background: var(--bg-alt);
    border-radius: 12px;
    padding: 28px;
    margin-bottom: 24px;
}
.sidebar-card h3 {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--navy);
}
.sidebar-card p {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 16px;
}

.sidebar-input {
    display: flex;
    gap: 8px;
}
.sidebar-input input {
    flex: 1;
    padding: 10px 14px;
    border: 1.5px solid var(--border);
    border-radius: 6px;
    font-size: 0.85rem;
    font-family: var(--font-sans);
    outline: none;
}
.sidebar-input input:focus {
    border-color: var(--navy);
}
.sidebar-input button {
    background: var(--orange);
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.82rem;
    cursor: pointer;
    font-family: var(--font-sans);
}
.sidebar-input button:hover {
    background: #e05525;
}

.sidebar-card .message-success {
    color: #16a34a;
    font-size: 0.85rem;
    font-weight: 500;
}
.sidebar-card .message-error {
    color: #dc2626;
    font-size: 0.85rem;
    font-weight: 500;
}

.sidebar-topics-card {
    background: transparent;
    padding: 0;
}
.sidebar-topics-card h3 {
    padding: 0 0 12px;
}
.sidebar-topics { list-style: none; }
.sidebar-topics li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.88rem;
}
.sidebar-topics li:last-child { border-bottom: none; }
.sidebar-topics a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
}
.sidebar-topics a:hover { color: var(--navy); }
.sidebar-topics .count {
    background: var(--bg-alt);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.72rem;
    color: var(--text-faint);
    font-weight: 600;
}


/* ============================================================
   TRENDING SECTION
   ============================================================ */
.trending-section {
    padding: 0 var(--pad-x) 64px;
}

.trending-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.trending-card {
    background: var(--bg-alt);
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}
.trending-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.trending-card-image {
    display: block;
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--bg-alt);
}
.trending-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.trending-card-body {
    padding: 24px 28px 28px;
    position: relative;
}

.trending-rank {
    position: absolute;
    top: -18px;
    right: 20px;
    background: var(--orange);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.82rem;
    font-weight: 700;
    font-family: var(--font-sans);
}

.trending-card-tag {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--orange);
    margin-bottom: 10px;
}

.trending-card h3 {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.35;
    color: var(--text);
    margin-bottom: 12px;
}

.trending-stats {
    display: flex;
    gap: 16px;
    font-size: 0.72rem;
    color: var(--text-faint);
    font-weight: 500;
}
.trending-stats svg {
    width: 13px;
    height: 13px;
    vertical-align: -2px;
    margin-right: 3px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.trending-card-meta {
    margin-top: 12px;
    font-size: 0.72rem;
    color: var(--text-faint);
    padding-top: 12px;
    border-top: 1px solid var(--border);
}


/* ============================================================
   CATEGORIES SECTION
   ============================================================ */
.categories-section {
    padding: 0 var(--pad-x) 64px;
}

.categories-columns {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.category-column-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--navy);
}
.category-column-title {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--navy);
}
.category-column-link {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--orange);
    text-decoration: none;
    font-weight: 600;
}
.category-column-link:hover { color: var(--navy); }

.category-post {
    padding: 18px 0;
    border-bottom: 1px solid var(--border);
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 14px;
    align-items: start;
}
.category-post:last-child { border-bottom: none; }

.category-post-thumb {
    width: 72px;
    height: 54px;
    border-radius: 6px;
    overflow: hidden;
    background: var(--bg-alt);
    flex-shrink: 0;
}
.category-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-post h4 {
    font-family: var(--font-serif);
    font-size: 0.92rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text);
    margin-bottom: 4px;
}
.category-post h4 a {
    color: inherit;
    text-decoration: none;
}
.category-post h4 a:hover { color: var(--navy); }

.category-post-meta {
    font-size: 0.7rem;
    color: var(--text-faint);
}


/* ============================================================
   ARTICLE PAGE
   ============================================================ */
.article-feature-image {
    max-width: 960px;
    margin: 0 auto;
    padding: 24px var(--pad-x) 0;
}
.article-feature-image img {
    width: 100%;
    border-radius: 12px;
}
.article-feature-image figcaption {
    font-size: 0.8rem;
    color: var(--text-faint);
    margin-top: 10px;
    text-align: center;
}

.article-header {
    padding: 40px var(--pad-x);
    max-width: 960px;
    margin: 0 auto;
}

.article-tag {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--orange);
    margin-bottom: 12px;
    display: inline-block;
    text-decoration: none;
}
.article-tag:hover { color: var(--navy); }

.article-title {
    font-family: var(--font-serif);
    font-size: 2.4rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text);
    margin-bottom: 16px;
}

.article-subtitle {
    font-size: 1.1rem;
    color: var(--text-light);
    line-height: 1.65;
    margin-bottom: 24px;
}

.article-byline {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    margin-bottom: 32px;
}

.article-author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}
.article-author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.article-author-initials {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--navy);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    flex-shrink: 0;
}

.article-author-name {
    font-weight: 600;
    font-size: 0.9rem;
}
.article-author-name a {
    color: inherit;
    text-decoration: none;
}
.article-author-detail {
    font-size: 0.8rem;
    color: var(--text-faint);
}

.article-body {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 var(--pad-x) 48px;
    font-family: var(--font-serif);
    font-size: 1.12rem;
    line-height: 1.85;
}
.article-body p { margin-bottom: 1.5em; }
.article-body h2 {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text);
    margin: 2em 0 0.8em;
    line-height: 1.3;
}
.article-body h3 {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text);
    margin: 1.8em 0 0.6em;
    line-height: 1.35;
}
.article-body a {
    color: var(--orange);
    text-decoration: underline;
    text-underline-offset: 2px;
}
.article-body a:hover { color: var(--navy); }
.article-body blockquote {
    border-left: 3px solid var(--orange);
    padding-left: 20px;
    margin: 1.5em 0;
    color: var(--text-light);
}
.article-body ul, .article-body ol {
    margin: 1.5em 0;
    padding-left: 2.5em;
}
.article-body li { margin-bottom: 0.3em; line-height: 1.6; }
.article-body img { border-radius: 8px; margin: 1.5em 0; }
.article-body figure { margin: 2em 0; }
.article-body figcaption {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    color: var(--text-faint);
    margin-top: 8px;
    text-align: center;
}
.article-body hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2.5em 0;
}

/* Ghost card styles */
.article-body .kg-card { margin: 2em 0; }
.article-body .kg-width-wide {
    /* body is already 960px wide, no offset needed */
}
.article-body .kg-width-full {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    max-width: 100vw;
}
.article-body .kg-image { width: 100%; border-radius: 8px; }
.article-body .kg-bookmark-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
}
.article-body .kg-gallery-image img { border-radius: 4px; }

.article-footer {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 var(--pad-x) 32px;
}
.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.article-tags a {
    display: inline-block;
    background: var(--bg-alt);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.78rem;
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
}
.article-tags a:hover {
    background: var(--navy);
    color: white;
}

.article-comments {
    max-width: 960px;
    margin: 0 auto;
    padding: 32px var(--pad-x) 64px;
    border-top: 1px solid var(--border);
}

/* Premium label in byline */
.paid-label {
    color: var(--orange);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ============================================================
   PAYWALL GATE
   ============================================================ */
.paywall-gate {
    position: relative;
    max-width: 960px;
    margin: -120px auto 0;
    padding: 0 var(--pad-x);
}
.paywall-fade {
    height: 120px;
    background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, rgba(255,255,255,1) 100%);
}
.paywall-cta {
    text-align: center;
    padding: 48px 32px 64px;
    border: 2px solid var(--border);
    border-radius: 12px;
    background: var(--bg-alt);
    margin-bottom: 64px;
}
.paywall-cta h2 {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 12px;
}
.paywall-cta p {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 24px;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}
.paywall-btn {
    display: inline-block;
    padding: 14px 36px;
    font-size: 0.95rem;
}
.paywall-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}
.paywall-signin {
    font-size: 0.85rem;
    color: var(--text-faint);
}
.paywall-signin a {
    color: var(--orange);
    text-decoration: underline;
    text-underline-offset: 2px;
}
.paywall-signin a:hover { color: var(--navy); }

/* Hide Ghost's native upgrade CTA -- we use our own .paywall-gate instead */
.gh-post-upgrade-cta { display: none !important; }


/* ============================================================
   PAGINATION
   ============================================================ */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 40px 0 16px;
    font-size: 0.85rem;
}
.pagination a {
    color: var(--orange);
    text-decoration: none;
    font-weight: 600;
}
.pagination a:hover { color: var(--navy); }
.page-number {
    color: var(--text-faint);
    font-size: 0.82rem;
}


/* ============================================================
   TAG / AUTHOR ARCHIVE PAGES
   ============================================================ */
.archive-header {
    padding: 48px var(--pad-x);
    border-bottom: 2px solid var(--navy);
    margin: 0 var(--pad-x);
}
.archive-title {
    font-family: var(--font-serif);
    font-size: 2rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
}
.archive-description {
    font-size: 1rem;
    color: var(--text-light);
    max-width: 600px;
    line-height: 1.6;
}
.archive-count {
    font-size: 0.85rem;
    color: var(--text-faint);
    margin-top: 8px;
}

.archive-feed {
    padding: 48px var(--pad-x) 64px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}


/* ============================================================
   POST CARD (reusable for archives, related posts)
   ============================================================ */
.post-card {
    background: var(--bg-alt);
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}
.post-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.post-card-image {
    display: block;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--bg-alt);
    text-decoration: none;
}
.post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.post-card:hover .post-card-image img {
    transform: scale(1.03);
}

.post-card-content {
    padding: 24px 28px 28px;
}

.post-card-tag {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--orange);
    margin-bottom: 8px;
    display: block;
    text-decoration: none;
}

.post-card-title {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 8px;
    color: var(--text);
}
.post-card-title a {
    color: inherit;
    text-decoration: none;
}
.post-card-title a:hover { color: var(--navy); }

.post-card-excerpt {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card-meta {
    margin-top: 12px;
    font-size: 0.72rem;
    color: var(--text-faint);
    display: flex;
    gap: 8px;
    align-items: center;
}
.post-card-meta .paid-badge {
    background: var(--navy);
    color: white;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 600;
}


/* ============================================================
   NEWSLETTER CTA
   ============================================================ */
.cta-section {
    padding: 64px var(--pad-x);
    background: var(--bg-alt);
    border-top: 1px solid var(--border);
    text-align: center;
}
.cta-section h2 {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    color: var(--navy);
    margin-bottom: 12px;
}
.cta-section p {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 24px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}
.cta-form {
    display: flex;
    gap: 8px;
    max-width: 400px;
    margin: 0 auto;
}
.cta-form input {
    flex: 1;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: 6px;
    font-size: 0.88rem;
    font-family: var(--font-sans);
    outline: none;
}
.cta-form input:focus { border-color: var(--navy); }
.cta-form button {
    background: var(--navy);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    font-family: var(--font-sans);
}
.cta-form button:hover { background: #002a55; }


/* ============================================================
   STATIC PAGES
   ============================================================ */
.page-content {
    max-width: 680px;
    margin: 0 auto;
    padding: 48px 24px 64px;
}
.page-content h1 {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 24px;
    line-height: 1.25;
}

.about-header {
    text-align: center;
    padding: 48px var(--pad-x);
}
.about-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin: 0 auto 24px;
    overflow: hidden;
}
.about-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.about-content {
    max-width: 680px;
    margin: 0 auto;
    padding: 0 24px 64px;
    font-family: var(--font-serif);
    font-size: 1.1rem;
    line-height: 1.85;
}

.membership-header {
    text-align: center;
    padding: 64px var(--pad-x) 48px;
}
.membership-header h1 {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    color: var(--navy);
    margin-bottom: 12px;
}
.membership-header p {
    font-size: 1rem;
    color: var(--text-light);
    max-width: 560px;
    margin: 0 auto;
}
.membership-tiers {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    max-width: 700px;
    margin: 0 auto;
    padding: 0 var(--pad-x) 64px;
}
.tier-card {
    border: 1.5px solid var(--border);
    border-radius: 12px;
    padding: 32px;
    text-align: center;
}
.tier-card.featured {
    border-color: var(--navy);
    background: var(--bg-alt);
}
.tier-name {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
}
.tier-price {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text);
}
.tier-price span {
    font-size: 0.85rem;
    color: var(--text-faint);
    font-weight: 400;
}


/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
    background: var(--navy);
    color: rgba(255,255,255,0.6);
    padding: 48px var(--pad-x);
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.footer-logo {
    font-family: var(--font-sans);
    font-weight: 700;
    color: white;
    font-size: 1.1rem;
    text-decoration: none;
}
.footer-logo img {
    height: 28px;
    width: auto;
}
.footer-logo .logo-accent { color: var(--orange); }

.footer-links {
    display: flex;
    gap: 24px;
}
.footer-links a {
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    font-size: 0.82rem;
}
.footer-links a:hover { color: white; }

.footer-copy {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.3);
    margin-top: 24px;
    text-align: center;
}


/* ============================================================
   READING PROGRESS BAR
   ============================================================ */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--orange);
    z-index: 200;
    transition: width 50ms linear;
}


/* ============================================================
   MOBILE NAV
   ============================================================ */
.mobile-nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 199;
}
.mobile-nav-overlay.is-active { display: block; }

.mobile-nav {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100%;
    background: white;
    z-index: 200;
    padding: 24px;
    transition: right 0.3s ease;
    overflow-y: auto;
}
.mobile-nav.is-active { right: 0; }
.mobile-nav a {
    display: block;
    padding: 12px 0;
    color: var(--text);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    border-bottom: 1px solid var(--border);
}
.mobile-nav-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-faint);
    padding: 8px;
    position: absolute;
    top: 12px;
    right: 12px;
}


/* ============================================================
   LEADERBOARD PAGE
   ============================================================ */
.leaderboard-page {
    max-width: 680px;
    margin: 0 auto;
    padding: 60px var(--pad-x) 80px;
}

/* Referral Hero */
.referral-hero {
    text-align: center;
    padding-bottom: 48px;
    border-bottom: 1px solid var(--border);
}

.referral-logo {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin: 0 auto 24px;
    border-radius: 12px;
}

.referral-title {
    font-family: var(--font-serif);
    font-size: 2rem;
    color: var(--navy);
    line-height: 1.3;
    margin-bottom: 12px;
}

.referral-subtitle {
    color: var(--text-light);
    font-size: 0.95rem;
    max-width: 420px;
    margin: 0 auto;
}

.referral-share {
    margin-top: 32px;
}

.referral-link-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 16px;
}

.referral-link-text {
    font-size: 0.9rem;
    color: var(--text-light);
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 10px 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 300px;
}

.referral-copy-btn {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 10px 16px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    color: var(--text);
    transition: background 0.15s;
}

.referral-copy-btn:hover {
    background: var(--border);
}

.referral-share-buttons {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    border: 1px solid var(--border);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    background: var(--bg);
    transition: background 0.15s;
}

.share-btn:hover {
    background: var(--bg-alt);
}

/* Rewards Section */
.rewards-section {
    padding: 48px 0;
    border-bottom: 1px solid var(--border);
}

.rewards-title {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    color: var(--text);
    margin-bottom: 24px;
}

.rewards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.reward-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px 16px;
    text-align: center;
}

.reward-stars {
    margin-bottom: 12px;
}

.reward-stars .star {
    color: var(--orange);
    font-size: 1.4rem;
    margin: 0 2px;
}

.reward-name {
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 1rem;
    color: var(--text);
    margin-bottom: 8px;
}

.reward-threshold {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
}

/* Leaderboard Section */
.leaderboard-section {
    padding: 48px 0 0;
}

.leaderboard-title {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    color: var(--text);
    margin-bottom: 16px;
}

.leaderboard-header-row {
    display: flex;
    justify-content: space-between;
    padding: 0 16px 12px;
}

.leaderboard-col-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
    font-weight: 600;
}

.leaderboard-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.leaderboard-entry {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    background: var(--bg-alt);
    border-radius: 8px;
    gap: 12px;
}

.lb-rank {
    font-size: 0.9rem;
    color: var(--text-light);
    min-width: 24px;
}

.lb-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--navy);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
    overflow: hidden;
}

.lb-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.lb-name {
    flex: 1;
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text);
}

.lb-count {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
}


/* ============================================================
   MEMBERSHIP / PRICING
   ============================================================ */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    max-width: 800px;
    margin: 48px auto;
    padding: 0 var(--pad-x);
}

.pricing-card {
    background: white;
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 36px 28px;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.pricing-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}
.pricing-card.featured {
    border-color: var(--orange);
    position: relative;
}
.pricing-card.featured::before {
    content: "Most Popular";
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--orange);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 16px;
    border-radius: 20px;
    font-family: var(--font-sans);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pricing-card h3 {
    font-size: 1.4rem;
    color: var(--navy);
    margin-bottom: 8px;
}

.pricing-amount {
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 24px;
    font-family: var(--font-sans);
}
.pricing-amount span {
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-light);
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 0 0 28px 0;
    text-align: left;
}
.pricing-features li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
    color: var(--text);
    padding-left: 24px;
    position: relative;
}
.pricing-features li::before {
    content: "\2713";
    position: absolute;
    left: 0;
    color: var(--orange);
    font-weight: 700;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
    .archive-feed { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
    :root { --pad-x: 24px; }

    .hero-section {
        grid-template-columns: 1fr;
        margin: 16px var(--pad-x);
        padding: 32px;
    }
    .hero-image, .hero-no-image { display: none; }
    .hero-title { font-size: 1.8rem; }

    .content-area {
        grid-template-columns: 1fr;
    }

    .post-item { grid-template-columns: 1fr; }
    .post-item-image { display: none; }

    .trending-grid { grid-template-columns: 1fr; }
    .categories-columns { grid-template-columns: 1fr; gap: 32px; }
    .archive-feed { grid-template-columns: 1fr; }

    .article-title { font-size: 1.8rem; }
    .article-body .kg-width-wide {
        margin-left: 0;
        margin-right: 0;
        max-width: 100%;
    }

    .site-nav { display: none; }
    .menu-toggle { display: block; }

    .footer-inner { flex-direction: column; gap: 16px; text-align: center; }
    .footer-links { flex-wrap: wrap; justify-content: center; }

    .archive-header { margin: 0; }
}

@media (max-width: 600px) {
    .header-actions .btn-outline { display: none; }
    .cta-form { flex-direction: column; }
    .sidebar-input { flex-direction: column; }
    .membership-tiers { grid-template-columns: 1fr; }

    .referral-title { font-size: 1.5rem; }
    .referral-share-buttons { flex-direction: column; align-items: center; }
    .share-btn { width: 100%; justify-content: center; }
    .rewards-grid { grid-template-columns: 1fr; }
}
