/* ================================================================
   PUBLISHING PLATFORM — Content-Agnostic CSS
   Used by: publishing_hub.php, publishing_newspaper.php, blog article
   Accent: --org (#F26122) — frontend orange, NOT vendor purple
   ================================================================ */

:root {
    --pub-accent: var(--org, #F26122);
    --pub-text: #333;
    --pub-text-light: #666;
    --pub-text-muted: #888;
    --pub-bg: #f8f9fa;
    --pub-card-bg: #fff;
    --pub-border: #e5e7eb;
    --pub-radius: 10px;
    --pub-font-headline: 'Playfair Display', Georgia, serif;
    --pub-font-ui: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --pub-font-body: Georgia, 'Times New Roman', serif;
}

/* ================================================================
   0. EDITORIAL POLISH — Typography, Animations, Interactions
   ================================================================ */

/* ── Page fade-in (1O) ── */
@keyframes pub-fade-in {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.pub-hub,
.pub-article-container,
.pub-newspaper,
.pub-article-np {
    animation: pub-fade-in 0.4s ease-out both;
}

/* ── Premium badge pulse (1D) ── */
@keyframes pub-premium-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(245,158,11,0.5); }
    50%      { box-shadow: 0 0 12px 4px rgba(245,158,11,0.25); }
}

/* ── Skeleton loading (4D) ── */
@keyframes pub-skeleton-pulse {
    0%   { background-position: -200px 0; }
    100% { background-position: calc(200px + 100%) 0; }
}

/* ── Scroll-triggered card animation (2B) ── */
.pub-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease, box-shadow 0.2s;
}
.pub-card.pub-revealed,
.pub-no-observer .pub-card {
    opacity: 1;
    transform: translateY(0);
}

/* ── Newspaper section reveal (2C) ── */
.np-lead-article,
.np-secondary-article {
    opacity: 0;
    transform: translateX(-16px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.np-lead-article.pub-revealed,
.np-secondary-article.pub-revealed,
.pub-no-observer .np-lead-article,
.pub-no-observer .np-secondary-article {
    opacity: 1;
    transform: translateX(0);
}

/* ── Reading progress bar (2A) ── */
.pub-reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--pub-accent), #ff8a50);
    z-index: 9999;
    transition: width 0.1s linear;
    pointer-events: none;
}

/* ── Back to top button (2E) ── */
.pub-back-to-top {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--pub-border);
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.3s, transform 0.3s, box-shadow 0.2s;
    pointer-events: none;
    z-index: 1000;
    color: var(--pub-text);
    font-size: 18px;
}
.pub-back-to-top.pub-visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
.pub-back-to-top:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    color: var(--pub-accent);
}

/* ── Share bar (3A) ── */
.pub-share-bar {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
    width: 44px;
    z-index: 10;
}
.pub-share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--pub-border);
    background: var(--pub-card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--pub-text-light);
    font-size: 16px;
    text-decoration: none;
}
.pub-share-btn:hover {
    border-color: var(--pub-accent);
    color: var(--pub-accent);
    box-shadow: 0 2px 8px rgba(242,97,34,0.15);
    text-decoration: none;
}
.pub-share-btn.pub-copied {
    background: var(--pub-accent);
    color: #fff;
    border-color: var(--pub-accent);
}
.pub-share-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--pub-text-muted);
    text-align: center;
    margin-bottom: 4px;
    font-family: var(--pub-font-ui);
}

/* ── TOC (3G) ── */
.pub-toc {
    background: var(--pub-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    padding: 20px 24px;
    margin-bottom: 32px;
}
.pub-toc-title {
    font-family: var(--pub-font-ui);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--pub-text-muted);
    margin: 0 0 12px;
}
.pub-toc ol {
    margin: 0;
    padding-left: 20px;
    list-style: decimal;
}
.pub-toc li {
    margin-bottom: 6px;
}
.pub-toc a {
    font-family: var(--pub-font-ui);
    font-size: 14px;
    color: var(--pub-text);
    text-decoration: none;
    transition: color 0.15s;
}
.pub-toc a:hover {
    color: var(--pub-accent);
}
.pub-toc li.pub-toc-h3 {
    margin-left: 16px;
    font-size: 13px;
}
.pub-toc li.pub-toc-h4 {
    margin-left: 32px;
    font-size: 12px;
}

/* ── Author card (3E) ── */
.pub-author-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: var(--pub-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    margin: 32px 0;
}
.pub-author-avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--pub-accent), #ff8a50);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-family: var(--pub-font-headline);
    font-size: 22px;
    font-weight: 700;
    flex-shrink: 0;
}
.pub-author-info {
    flex: 1;
}
.pub-author-name {
    font-family: var(--pub-font-ui);
    font-size: 16px;
    font-weight: 600;
    color: var(--pub-text);
    margin: 0 0 2px;
}
.pub-author-link {
    font-family: var(--pub-font-ui);
    font-size: 13px;
    color: var(--pub-accent);
    text-decoration: none;
}
.pub-author-link:hover { text-decoration: underline; }

/* ── Trending badge (3D) ── */
.pub-trending-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 700;
    font-family: var(--pub-font-ui);
    color: #fff;
    background: linear-gradient(135deg, #f59e0b, var(--pub-accent));
    border-radius: 10px;
    margin-left: 6px;
}

/* ── View/reading time meta icons ── */
.pub-meta-icon {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.pub-meta-icon i {
    font-size: 13px;
    opacity: 0.7;
}

/* ── Search bar (4A) ── */
.pub-search-bar {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}
.pub-search-wrap {
    position: relative;
    width: 100%;
    max-width: 420px;
}
.pub-search-input {
    width: 100%;
    padding: 10px 16px 10px 40px;
    font-family: var(--pub-font-ui);
    font-size: 14px;
    color: var(--pub-text);
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: 30px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.pub-search-input:focus {
    border-color: var(--pub-accent);
    box-shadow: 0 0 0 3px rgba(242,97,34,0.1);
}
.pub-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--pub-text-muted);
    font-size: 15px;
    pointer-events: none;
}

/* ── Grid/List view toggle (4B) ── */
.pub-view-toggle {
    display: flex;
    gap: 4px;
    margin-left: auto;
}
.pub-view-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--pub-border);
    border-radius: 6px;
    background: var(--pub-card-bg);
    color: var(--pub-text-muted);
    cursor: pointer;
    font-size: 16px;
    transition: all 0.15s;
}
.pub-view-btn:hover { color: var(--pub-accent); border-color: var(--pub-accent); }
.pub-view-btn.active {
    background: var(--pub-accent);
    color: #fff;
    border-color: var(--pub-accent);
}

/* ── Load more button (4C) ── */
.pub-load-more-wrap {
    text-align: center;
    margin: 20px 0;
}
.pub-load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 32px;
    font-family: var(--pub-font-ui);
    font-size: 14px;
    font-weight: 600;
    color: var(--pub-accent);
    background: var(--pub-card-bg);
    border: 2px solid var(--pub-accent);
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.2s;
}
.pub-load-more-btn:hover {
    background: var(--pub-accent);
    color: #fff;
}
.pub-load-more-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
.pub-load-more-spinner {
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: pub-spin 0.6s linear infinite;
}
@keyframes pub-spin {
    to { transform: rotate(360deg); }
}

/* ── Skeleton cards (4D) ── */
.pub-skeleton-card {
    background: var(--pub-card-bg);
    border-radius: var(--pub-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.pub-skeleton-thumb {
    aspect-ratio: 16/9;
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200px 100%;
    animation: pub-skeleton-pulse 1.5s ease infinite;
}
.pub-skeleton-body { padding: 16px; }
.pub-skeleton-line {
    height: 14px;
    border-radius: 4px;
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200px 100%;
    animation: pub-skeleton-pulse 1.5s ease infinite;
    margin-bottom: 10px;
}
.pub-skeleton-line:last-child { width: 60%; margin-bottom: 0; }
.pub-skeleton-line.pub-skeleton-title { height: 18px; width: 80%; }

/* ================================================================
   1. HUB LAYOUT
   ================================================================ */

.pub-hub {
    padding: 40px 0 60px;
    background: var(--pub-bg);
    min-height: 70vh;
}
.pub-hub-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header — 1A Typography */
.pub-header {
    text-align: center;
    margin-bottom: 35px;
}
.pub-header h1 {
    font-family: var(--pub-font-headline);
    font-size: 40px;
    font-weight: 900;
    color: #1a1a1a;
    margin: 0 0 8px;
    letter-spacing: -0.5px;
}
.pub-header p {
    font-family: var(--pub-font-ui);
    font-size: 16px;
    color: var(--pub-text-light);
    margin: 0;
}

/* Filter bar */
.pub-filter-bar {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}
.pub-filter-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 20px;
    font-family: var(--pub-font-ui);
    font-size: 14px;
    font-weight: 500;
    color: var(--pub-text-light);
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: 30px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}
.pub-filter-tab::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--pub-accent);
    border-radius: 1px;
    transition: width 0.25s ease, left 0.25s ease;
}
.pub-filter-tab:hover {
    color: var(--pub-accent);
    border-color: var(--pub-accent);
    text-decoration: none;
}
.pub-filter-tab:hover::after {
    width: 60%;
    left: 20%;
}
.pub-filter-tab.active {
    background: var(--pub-accent);
    color: #fff;
    border-color: var(--pub-accent);
}
.pub-filter-tab.active::after { display: none; }
.pub-filter-count {
    font-size: 12px;
    font-weight: 600;
    background: rgba(0,0,0,0.08);
    padding: 1px 8px;
    border-radius: 10px;
}
.pub-filter-tab.active .pub-filter-count {
    background: rgba(255,255,255,0.25);
}

/* ================================================================
   2. HUB CARDS
   ================================================================ */

.pub-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.pub-card {
    background: var(--pub-card-bg);
    border-radius: var(--pub-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}
.pub-card:hover {
    box-shadow: 0 12px 32px rgba(242,97,34,0.15);
    text-decoration: none;
    color: inherit;
}

/* ── Hero card (1B): first card spans 2 columns ── */
.pub-card--hero {
    grid-column: span 2;
    flex-direction: row;
}
.pub-card--hero .pub-card-thumb {
    flex: 0 0 45%;
    aspect-ratio: auto;
    min-height: 260px;
}
.pub-card--hero .pub-card-title {
    font-family: var(--pub-font-headline);
    font-size: 24px;
    font-weight: 700;
    -webkit-line-clamp: 3;
}
.pub-card--hero .pub-card-excerpt {
    -webkit-line-clamp: 4;
}

.pub-card-thumb {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
}
.pub-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}
/* Image zoom on hover (1N) */
.pub-card:hover .pub-card-thumb img {
    transform: scale(1.05);
}
/* Gradient overlay on hover (1N) */
.pub-card-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.25), transparent 50%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}
.pub-card:hover .pub-card-thumb::after {
    opacity: 1;
}
.pub-card-thumb .pub-no-thumb {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: #94a3b8;
}

.pub-type-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 4px;
    color: #fff;
}
.pub-type-badge.badge-blog {
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
}
.pub-type-badge.badge-newspaper {
    background: linear-gradient(135deg, #1a1a1a, #374151);
    font-family: var(--pub-font-headline);
    font-style: italic;
    letter-spacing: 0.3px;
}

/* Quick Ad badge */
.pub-type-badge.badge-quickad {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.pub-premium-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 600;
    background: #f59e0b;
    color: #fff;
    border-radius: 4px;
    animation: pub-premium-pulse 2s ease-in-out infinite;
}

.pub-card-body {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.pub-card-title {
    font-family: var(--pub-font-ui);
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 8px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.pub-card-excerpt {
    font-size: 14px;
    color: var(--pub-text-light);
    line-height: 1.6;
    margin: 0 0 12px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.pub-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--pub-text-muted);
    padding-top: 12px;
    border-top: 1px solid var(--pub-border);
}
.pub-card-author {
    font-weight: 500;
}

/* ================================================================
   3. PAGINATION
   ================================================================ */

.pub-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    margin-top: 10px;
}
.pub-pagination a,
.pub-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 10px;
    font-size: 14px;
    font-weight: 500;
    color: var(--pub-text-light);
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.15s;
}
.pub-pagination a:hover {
    color: var(--pub-accent);
    border-color: var(--pub-accent);
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(242,97,34,0.2);
}
.pub-pagination .active {
    background: var(--pub-accent);
    color: #fff;
    border-color: var(--pub-accent);
}
.pub-pagination .disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* ================================================================
   4. EMPTY STATE
   ================================================================ */

.pub-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--pub-text-muted);
}
@keyframes pub-float {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-8px); }
}
.pub-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
    animation: pub-float 3s ease-in-out infinite;
}
.pub-empty-icon svg {
    width: 72px;
    height: 72px;
}
.pub-empty h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--pub-text-light);
    margin: 0 0 8px;
}
.pub-empty p {
    font-size: 15px;
    margin: 0;
}

/* ================================================================
   5. STANDALONE ARTICLE (blog)
   ================================================================ */

.pub-article-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}

.pub-breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--pub-font-ui);
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--pub-text-muted);
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.pub-breadcrumb a {
    color: var(--pub-accent);
    text-decoration: none;
    transition: color 0.15s;
}
.pub-breadcrumb a:hover {
    color: #d4541e;
    text-decoration: underline;
}
.pub-breadcrumb .sep {
    color: var(--pub-accent);
    opacity: 0.5;
}

.pub-article-hero {
    width: 100%;
    max-height: 420px;
    overflow: hidden;
    border-radius: var(--pub-radius);
    margin-bottom: 28px;
}
.pub-article-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pub-article-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 42px;
    font-weight: 900;
    color: #1a1a1a;
    line-height: 1.15;
    margin: 0 0 16px;
}

.pub-article-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    color: var(--pub-text-muted);
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--pub-border);
    flex-wrap: wrap;
}
.pub-article-meta strong {
    color: var(--pub-text);
}

.pub-article-body {
    font-family: var(--pub-font-body);
    font-size: 18px;
    line-height: 1.8;
    color: var(--pub-text);
}
.pub-article-body p {
    margin-bottom: 1.4em;
}
/* Blog drop cap (1E) */
.pub-article-body > p:first-of-type::first-letter {
    float: left;
    font-family: var(--pub-font-headline);
    font-size: 72px;
    font-weight: 900;
    line-height: 0.8;
    margin: 4px 10px 0 0;
    color: var(--pub-accent);
}
.pub-article-body img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 1em 0;
}
/* Pull quote enhancement (1F) */
.pub-article-body blockquote {
    border-left: 4px solid var(--pub-accent);
    padding: 20px 24px;
    margin: 2em 0;
    background: rgba(242,97,34,0.04);
    position: relative;
    border-radius: 0 var(--pub-radius) var(--pub-radius) 0;
}
.pub-article-body blockquote::before {
    content: '\201C';
    font-family: var(--pub-font-headline);
    font-size: 72px;
    color: var(--pub-accent);
    opacity: 0.15;
    position: absolute;
    top: -8px;
    left: 12px;
    line-height: 1;
    pointer-events: none;
}

.pub-article-footer {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid var(--pub-border);
    text-align: center;
}
.pub-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--pub-accent);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
}
.pub-back-link:hover {
    text-decoration: underline;
}

/* Premium content gate */
.pub-premium-gate {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(to bottom, transparent, #f8f9fa 30%);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    margin-top: 20px;
}
.pub-premium-gate h3 {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 10px;
    color: #1a1a1a;
}
.pub-premium-gate p {
    font-size: 15px;
    color: var(--pub-text-light);
    margin: 0 0 20px;
}
.pub-premium-gate .pub-btn {
    display: inline-block;
    padding: 10px 28px;
    background: var(--pub-accent);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    text-decoration: none;
    transition: opacity 0.2s;
}
.pub-premium-gate .pub-btn:hover {
    opacity: 0.9;
    text-decoration: none;
    color: #fff;
}

/* ================================================================
   6. NEWSPAPER STANDALONE
   Duplicated from newspaper_section.php inline <style> so the
   standalone page works without the BPage renderer.
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,700;0,900;1,400;1,700&family=UnifrakturMaguntia&family=DM+Sans:wght@300;400;700&display=swap');

.pub-newspaper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}

/* Newspaper section wrapper */
.np-section {
    padding: 60px 0;
    background: #faf9f7;
    font-family: Georgia, 'Times New Roman', Times, serif;
    color: #333;
}
.np-section .np-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
}

/* ── Masthead ── */
.np-masthead {
    text-align: center;
    padding: 30px 0 25px;
    border-top: 4px double #1a1a1a;
    border-bottom: 4px double #1a1a1a;
    margin-bottom: 35px;
}
.np-masthead-name {
    margin: 0 0 6px;
    color: #1a1a1a;
    line-height: 1.1;
}
.np-masthead-classic .np-masthead-name {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 56px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 2px;
}
.np-masthead-modern .np-masthead-name {
    font-family: 'DM Sans', Helvetica, Arial, sans-serif;
    font-size: 42px;
    font-weight: 700;
    letter-spacing: 8px;
    text-transform: uppercase;
}
.np-masthead-gothic .np-masthead-name {
    font-family: 'UnifrakturMaguntia', cursive;
    font-size: 56px;
    font-weight: 400;
}
.np-masthead-minimal .np-masthead-name {
    font-family: 'DM Sans', Helvetica, Arial, sans-serif;
    font-size: 36px;
    font-weight: 300;
    letter-spacing: 12px;
    text-transform: uppercase;
}
.np-masthead-tagline {
    font-style: italic;
    font-size: 16px;
    color: #555;
    margin: 0 0 12px;
}
.np-masthead-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #888;
    border-top: 1px solid #ccc;
    margin-top: 12px;
    padding-top: 10px;
}
.np-masthead-meta span { flex: 1; }
.np-masthead-meta span:first-child { text-align: left; }
.np-masthead-meta span:last-child { text-align: right; }

/* ── Section heading ── */
.np-section-heading {
    text-align: center;
    margin-bottom: 30px;
}
.np-section-heading h2 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 8px;
}
.np-section-heading p {
    font-size: 16px;
    color: #888;
    margin: 0;
    font-style: italic;
}

/* ── Category Divider ── */
.np-category-divider {
    text-align: center;
    margin: 35px 0 25px;
    position: relative;
}
.np-category-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #ccc;
}
.np-category-divider h3 {
    display: inline-block;
    background: #faf9f7;
    padding: 0 20px;
    position: relative;
    z-index: 1;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: #888;
    margin: 0;
}
/* Fix divider bg for standalone (white bg, not newspaper cream) */
.pub-newspaper .np-category-divider h3 {
    background: #fff;
}

/* ── Lead Stories ── */
.np-lead-article {
    margin-bottom: 35px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 35px;
}
.np-lead-image {
    width: 100%;
    margin-bottom: 15px;
    position: relative;
}
.np-lead-image img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    display: block;
}
.np-lead-headline {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 42px;
    font-weight: 900;
    color: #1a1a1a;
    line-height: 1.15;
    margin: 0 0 10px;
}
.np-lead-subheadline {
    font-family: Georgia, serif;
    font-size: 20px;
    font-weight: 400;
    color: #555;
    line-height: 1.4;
    margin: 0 0 15px;
    font-style: italic;
}
.np-lead-body {
    font-size: 17px;
    line-height: 1.8;
    color: #333;
}
.np-lead-article .np-lead-body:first-of-type::first-letter {
    float: left;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 72px;
    font-weight: 900;
    line-height: 0.8;
    margin: 4px 10px 0 0;
    color: #1a1a1a;
}

/* ── Byline ── */
.np-byline {
    font-family: 'DM Sans', Helvetica, Arial, sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #888;
    margin-bottom: 12px;
}
.np-byline strong { color: #1a1a1a; }

/* ── Pull Quote ── */
.np-pull-quote {
    border-left: 4px solid #1a1a1a;
    padding: 15px 0 15px 25px;
    margin: 25px 0;
    position: relative;
}
.np-pull-quote::before {
    content: '\201C';
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 60px;
    color: #ccc;
    position: absolute;
    top: -10px;
    left: -5px;
    line-height: 1;
}
.np-pull-quote p {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 24px;
    font-style: italic;
    color: #1a1a1a;
    line-height: 1.4;
    margin: 0;
}

/* ── Captions ── */
.np-caption {
    font-size: 12px;
    font-style: italic;
    color: #888;
    margin-top: 6px;
    line-height: 1.4;
}

/* ── Secondary Stories (2-col) ── */
.np-secondary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 35px;
    padding-bottom: 35px;
    border-bottom: 1px solid #ddd;
}
.np-secondary-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    margin-bottom: 12px;
}
.np-secondary-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.np-secondary-headline {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.25;
    margin: 0 0 8px;
}
.np-secondary-body {
    font-size: 15px;
    line-height: 1.7;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Column Stories (3-col) ── */
.np-columns-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin-bottom: 35px;
    padding-bottom: 35px;
    border-bottom: 1px solid #ddd;
}
.np-column-article {
    padding: 0 20px;
    border-right: 1px solid #ddd;
}
.np-column-article:first-child { padding-left: 0; }
.np-column-article:last-child { border-right: none; padding-right: 0; }
.np-column-image {
    width: 100%;
    height: 150px;
    overflow: hidden;
    margin-bottom: 10px;
}
.np-column-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.np-column-headline {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.25;
    margin: 0 0 6px;
}
.np-column-body {
    font-size: 14px;
    line-height: 1.7;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Brief Stories ── */
.np-briefs {
    margin-bottom: 35px;
}
.np-brief-item {
    display: flex;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    align-items: baseline;
}
.np-brief-item:last-child { border-bottom: none; }
.np-brief-bullet {
    font-size: 8px;
    color: #1a1a1a;
    margin-top: 5px;
    flex-shrink: 0;
}
.np-brief-content { flex: 1; }
.np-brief-headline {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 2px;
    line-height: 1.3;
}
.np-brief-summary {
    font-size: 14px;
    color: #555;
    margin: 0;
    line-height: 1.5;
}

/* ── Footer ── */
.np-footer {
    text-align: center;
    padding: 25px 0 0;
    border-top: 4px double #1a1a1a;
    margin-top: 10px;
}
.np-footer-text {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 5px;
    text-transform: uppercase;
    color: #888;
}

/* ═══════════════════════════════════════
   BLOCK TYPE STYLES
   ═══════════════════════════════════════ */

.np-block-text {
    font-size: 17px;
    line-height: 1.8;
    color: #333;
    margin-bottom: 20px;
}
.np-block-image {
    margin-bottom: 20px;
}
.np-block-image img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    display: block;
    border-radius: 2px;
}
.np-video-responsive {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    margin-bottom: 20px;
    background: #000;
}
.np-video-responsive iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.np-block-bullets {
    font-size: 16px;
    line-height: 1.8;
    color: #333;
    margin: 0 0 20px 0;
    padding-left: 24px;
}
.np-block-bullets li {
    margin-bottom: 6px;
}
.np-block-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}
.np-btn {
    display: inline-block;
    padding: 10px 24px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}
.np-btn-primary {
    background: #1a1a1a;
    color: #fff;
    border: 2px solid #1a1a1a;
}
.np-btn-primary:hover { background: #333; border-color: #333; color: #fff; }
.np-btn-outline {
    background: transparent;
    color: #1a1a1a;
    border: 2px solid #1a1a1a;
}
.np-btn-outline:hover { background: #1a1a1a; color: #fff; }
.np-btn-ghost {
    background: transparent;
    color: #1a1a1a;
    border: 2px solid transparent;
    text-decoration: underline;
}
.np-btn-ghost:hover { color: #555; }

.np-block-quote {
    border-left: 4px solid #1a1a1a;
    padding: 15px 0 15px 25px;
    margin: 25px 0;
    position: relative;
    background: transparent;
}
.np-block-quote::before {
    content: '\201C';
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 60px;
    color: #ddd;
    position: absolute;
    top: -10px;
    left: -5px;
    line-height: 1;
}
.np-block-quote p {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 22px;
    font-style: italic;
    color: #1a1a1a;
    line-height: 1.5;
    margin: 0;
}
.np-quote-attribution {
    display: block;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-style: normal;
    color: #888;
    margin-top: 10px;
}

.np-block-divider {
    margin: 30px 0;
    border: none;
}
hr.np-divider-solid { border-top: 2px solid #1a1a1a; }
hr.np-divider-dashed { border-top: 2px dashed #aaa; }
hr.np-divider-dotted { border-top: 2px dotted #aaa; }
.np-divider-ornament {
    text-align: center;
    margin: 30px 0;
    font-size: 20px;
    letter-spacing: 14px;
    color: #999;
}
.np-divider-ornament span { display: inline-block; }

.np-block-gallery {
    display: grid;
    gap: 8px;
    margin-bottom: 20px;
}
.np-gallery-2 { grid-template-columns: 1fr 1fr; }
.np-gallery-3 { grid-template-columns: repeat(3, 1fr); }
.np-gallery-4 { grid-template-columns: repeat(4, 1fr); }
.np-gallery-fig {
    margin: 0;
    overflow: hidden;
    border-radius: 2px;
}
.np-gallery-fig img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}
.np-gallery-fig:hover img { transform: scale(1.03); }

.np-block-embed {
    margin-bottom: 20px;
}

.np-truncated-fade {
    height: 40px;
    background: linear-gradient(to bottom, transparent, #fff);
    margin-top: -40px;
    position: relative;
    z-index: 1;
    pointer-events: none;
}

.np-lazy-video {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    margin-bottom: 20px;
    background: #000;
    cursor: pointer;
    border-radius: 2px;
}
.np-lazy-video img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    opacity: 0.8;
    transition: opacity 0.2s;
}
.np-lazy-video:hover img { opacity: 1; }
.np-lazy-video .np-lazy-play {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%,-50%);
    width: 68px; height: 48px;
    background: rgba(255,0,0,0.85);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.np-lazy-video .np-lazy-play::after {
    content: '';
    display: block;
    width: 0; height: 0;
    border-style: solid;
    border-width: 10px 0 10px 18px;
    border-color: transparent transparent transparent #fff;
    margin-left: 3px;
}

.np-block-columns {
    display: grid;
    gap: 30px;
    margin-bottom: 20px;
}
.np-block-cols-1 { grid-template-columns: 1fr; }
.np-block-cols-2 { grid-template-columns: 1fr 1fr; }
.np-block-cols-3 { grid-template-columns: 1fr 1fr 1fr; }
.np-block-cols-4 { grid-template-columns: 1fr 1fr 1fr 1fr; }
.np-block-col > *:last-child { margin-bottom: 0; }

/* ================================================================
   7. RESPONSIVE
   ================================================================ */

@media (max-width: 768px) {
    /* Hub */
    .pub-header h1 { font-size: 28px; }
    .pub-grid { grid-template-columns: 1fr; gap: 16px; }

    /* Article */
    .pub-article-title { font-size: 30px; }
    .pub-article-body { font-size: 16px; }

    /* Newspaper */
    .np-section { padding: 40px 0; }
    .np-masthead-classic .np-masthead-name,
    .np-masthead-gothic .np-masthead-name { font-size: 36px; }
    .np-masthead-modern .np-masthead-name { font-size: 28px; }
    .np-masthead-minimal .np-masthead-name { font-size: 24px; }
    .np-masthead-meta { flex-direction: column; gap: 4px; text-align: center !important; }
    .np-masthead-meta span { text-align: center !important; }
    .np-lead-headline { font-size: 30px; }
    .np-lead-article .np-lead-body:first-of-type::first-letter { font-size: 52px; }
    .np-pull-quote p { font-size: 18px; }
    .np-secondary-grid { grid-template-columns: 1fr; }
    .np-columns-grid { grid-template-columns: 1fr; }
    .np-column-article {
        padding: 0 0 15px;
        border-right: none;
        border-bottom: 1px solid #ddd;
        margin-bottom: 15px;
    }
    .np-column-article:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
    .np-block-columns { grid-template-columns: 1fr !important; }
    .np-block-buttons { flex-direction: column; }
    .np-block-gallery { grid-template-columns: 1fr 1fr !important; }
    .np-block-quote p { font-size: 18px; }
    .np-gallery-fig img { height: 150px; }
}

@media (max-width: 480px) {
    .pub-header h1 { font-size: 24px; }
    .pub-filter-bar { gap: 6px; }
    .pub-filter-tab { padding: 6px 14px; font-size: 13px; }
    .pub-article-title { font-size: 26px; }

    .np-masthead-classic .np-masthead-name,
    .np-masthead-gothic .np-masthead-name { font-size: 28px; }
    .np-masthead-modern .np-masthead-name { font-size: 22px; }
    .np-masthead-minimal .np-masthead-name { font-size: 20px; }
    .np-lead-headline { font-size: 24px; }
    .np-lead-article .np-lead-body:first-of-type::first-letter { font-size: 44px; }
    .np-pull-quote p { font-size: 16px; }
}

/* ================================================================
   8. INDIVIDUAL NEWSPAPER ARTICLE
   ================================================================ */

.pub-article-np {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 20px 60px;
    min-height: 70vh;
}

/* Mini masthead — compact banner linking back to full edition */
.pub-np-mini-masthead {
    text-align: center;
    padding: 16px 0;
    margin-bottom: 24px;
    border-bottom: 2px solid var(--pub-border);
}
.pub-np-mini-name {
    display: block;
    text-decoration: none;
    color: var(--pub-text);
    font-weight: 700;
    font-size: 18px;
    letter-spacing: 0.5px;
    transition: color 0.2s;
}
.pub-np-mini-name:hover { color: var(--pub-accent); }
.np-masthead-classic .pub-np-mini-name { font-family: 'Playfair Display', Georgia, serif; font-size: 22px; }
.np-masthead-gothic .pub-np-mini-name { font-family: 'UnifrakturMaguntia', cursive; font-size: 24px; }
.np-masthead-modern .pub-np-mini-name { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; text-transform: uppercase; font-size: 16px; letter-spacing: 3px; }
.np-masthead-minimal .pub-np-mini-name { font-weight: 300; font-size: 20px; }
.pub-np-mini-tagline {
    display: block;
    font-size: 12px;
    color: var(--pub-text-muted);
    margin-top: 4px;
    font-style: italic;
}

/* Article content */
.pub-np-article {
    margin-bottom: 40px;
}
.pub-np-category {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--pub-accent);
    margin-bottom: 12px;
}
.pub-np-headline {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--pub-text);
    margin: 0 0 12px;
}
.pub-np-subheadline {
    font-size: 20px;
    color: var(--pub-text-light);
    line-height: 1.5;
    margin: 0 0 16px;
    font-weight: 400;
}
.pub-np-byline {
    font-size: 14px;
    color: var(--pub-text-muted);
    margin-bottom: 12px;
}
.pub-np-byline strong {
    color: var(--pub-text);
}
.pub-np-rule {
    border: none;
    border-top: 1px solid var(--pub-border);
    margin: 16px 0 24px;
}
.pub-np-body {
    font-size: 17px;
    line-height: 1.8;
    color: var(--pub-text);
}
.pub-np-body .np-block-text,
.pub-np-body .np-lead-body {
    margin-bottom: 20px;
}
.pub-np-body .np-block-image {
    margin: 28px 0;
}
.pub-np-body .np-block-quote {
    margin: 28px 0;
}

/* More from this edition */
.pub-np-siblings {
    padding: 30px 0;
    border-top: 2px solid var(--pub-border);
    margin-top: 40px;
}
.pub-np-siblings-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--pub-text);
    margin: 0 0 20px;
}
.pub-np-siblings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}
.pub-np-sibling-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 16px;
    background: var(--pub-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    text-decoration: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.pub-np-sibling-card:hover {
    border-color: var(--pub-accent);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.pub-np-sibling-headline {
    font-weight: 600;
    font-size: 15px;
    color: var(--pub-text);
    line-height: 1.4;
}
.pub-np-sibling-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 12px;
    color: var(--pub-text-muted);
}
.pub-np-sibling-cat {
    background: #e5e7eb;
    padding: 1px 8px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 11px;
    color: #374151;
}

/* Edition link */
.pub-np-edition-link {
    margin-top: 16px;
    text-align: center;
}
.pub-np-edition-link a {
    color: var(--pub-accent);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}
.pub-np-edition-link a:hover { text-decoration: underline; }

/* Article footer (back link) */
.pub-article-footer {
    padding: 20px 0;
    margin-top: 30px;
    border-top: 1px solid var(--pub-border);
}
.pub-back-link {
    color: var(--pub-accent);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}
.pub-back-link:hover { text-decoration: underline; }

/* ── Responsive ── */
@media (max-width: 768px) {
    .pub-article-np { padding: 20px 16px 40px; }
    .pub-np-headline { font-size: 28px; }
    .pub-np-subheadline { font-size: 17px; }
    .pub-np-body { font-size: 16px; }
    .pub-np-siblings-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .pub-np-headline { font-size: 24px; }
    .pub-np-subheadline { font-size: 15px; }
    .pub-np-mini-masthead { padding: 12px 0; }
}

/* ── Newspaper article separators (1L) ── */
.np-lead-article {
    border-bottom: none;
    position: relative;
}
.np-lead-article::after {
    content: '';
    display: block;
    margin-top: 35px;
    border-top: 1px solid #bbb;
    border-bottom: 1px solid #bbb;
    height: 4px;
}
.np-lead-article:last-child::after { display: none; }

/* ── List view mode (4B) ── */
.pub-view-list .pub-grid {
    grid-template-columns: 1fr;
}
.pub-view-list .pub-card {
    flex-direction: row;
}
.pub-view-list .pub-card--hero {
    grid-column: span 1;
}
.pub-view-list .pub-card-thumb {
    flex: 0 0 200px;
    aspect-ratio: auto;
    min-height: 140px;
}
.pub-view-list .pub-card-body {
    padding: 14px 20px;
}
.pub-view-list .pub-card-title {
    font-size: 17px;
    -webkit-line-clamp: 2;
}

/* ── Share bar mobile layout ── */
@media (max-width: 768px) {
    .pub-share-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        flex-direction: row;
        justify-content: center;
        width: 100%;
        padding: 10px;
        background: rgba(255,255,255,0.95);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        border-top: 1px solid var(--pub-border);
        box-shadow: 0 -2px 10px rgba(0,0,0,0.08);
        z-index: 100;
    }
    .pub-share-label { display: none; }
    .pub-article-container .pub-columns-wrap,
    .pub-article-np .pub-columns-wrap {
        padding-bottom: 60px;
    }
}

/* ── Hero card mobile collapse ── */
@media (max-width: 768px) {
    .pub-card--hero {
        grid-column: span 1;
        flex-direction: column;
    }
    .pub-card--hero .pub-card-thumb {
        flex: none;
        aspect-ratio: 16/9;
        min-height: auto;
    }
    .pub-card--hero .pub-card-title {
        font-size: 18px;
    }
    .pub-view-list .pub-card {
        flex-direction: column;
    }
    .pub-view-list .pub-card-thumb {
        flex: none;
        aspect-ratio: 16/9;
    }
}

/* ================================================================
   9. PRINT
   ================================================================ */

@media print {
    .pub-hub { background: #fff; }
    .pub-filter-bar,
    .pub-pagination,
    .pub-search-bar,
    .pub-view-toggle,
    .pub-load-more-wrap,
    .pub-back-to-top,
    .pub-share-bar,
    .pub-reading-progress { display: none !important; }
    .pub-card { box-shadow: none; border: 1px solid #ddd; opacity: 1 !important; transform: none !important; }

    .np-section { background: #fff; padding: 20px 0; }
    .np-lead-image img,
    .np-secondary-image img,
    .np-column-image img,
    .np-block-image img { max-height: 200px; }
    .np-pull-quote { border-left-width: 2px; }
    .np-video-responsive,
    .np-lazy-video { display: none; }
    .pub-sidebar { display: none; }
    .np-lead-article, .np-secondary-article { opacity: 1 !important; transform: none !important; }
}

/* ================================================================
   10. SIDEBAR LAYOUT SYSTEM — 3-Column & 2-Column
   ================================================================ */

/* ── Flex container ── */
.pub-columns-wrap {
    display: flex;
    gap: 28px;
    align-items: flex-start;
}

/* ── Main column ── */
.pub-main {
    flex: 1;
    min-width: 0;
}

/* ── Sidebars ── */
.pub-sidebar {
    position: sticky;
    top: 80px;
    flex-shrink: 0;
}
.pub-sidebar-left {
    flex: 0 0 260px;
    order: -1;
}
.pub-sidebar-right {
    flex: 0 0 280px;
}

/* Empty sidebar collapses */
.pub-sidebar-empty {
    display: none;
}

/* ── Sidebar inner (bordered card wrapper) ── */
.pub-sidebar-inner {
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    padding: 20px 16px;
}
.pub-sidebar-inner + .pub-sidebar-inner {
    margin-top: 20px;
}

/* ── Sidebar title — glassmorphic sticky (1K) ── */
.pub-sidebar-title {
    font-family: var(--pub-font-ui);
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--pub-text);
    margin: 0 0 14px;
    padding: 10px 0;
    border-bottom: 2px solid var(--pub-accent);
    display: flex;
    align-items: center;
    gap: 8px;
    position: sticky;
    top: 0;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2;
}

/* ── Newspaper sidebar: "In This Edition" — glassmorphic (1K) ── */
.np-sidebar-heading {
    font-family: var(--pub-font-ui);
    font-size: 16px;
    font-weight: 700;
    color: var(--pub-text);
    margin: 0 0 14px;
    padding: 10px 0;
    border-bottom: 2px solid var(--pub-accent);
    position: sticky;
    top: 0;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2;
}
.np-sidebar-category {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--pub-text-muted);
    margin: 18px 0 8px;
    padding-bottom: 4px;
    border-bottom: 1px solid var(--pub-border);
}
.np-sidebar-category:first-child {
    margin-top: 0;
}
.np-sidebar-article-link {
    display: block;
    text-decoration: none;
    padding: 8px 10px;
    margin-bottom: 4px;
    border-radius: 6px;
    border-left: 3px solid transparent;
    transition: background 0.15s, border-color 0.2s;
}
.np-sidebar-article-link:hover {
    background: rgba(242,97,34,0.02);
    border-left-color: var(--pub-accent);
    text-decoration: none;
}
/* Active scroll highlight (2F) */
.np-sidebar-article-link--active {
    border-left-color: var(--pub-accent);
    background: rgba(242,97,34,0.04);
}
.np-sidebar-article-link--active .np-sidebar-article-headline {
    color: var(--pub-accent);
    font-weight: 700;
}
.np-sidebar-article-headline {
    font-size: 14px;
    font-weight: 600;
    color: var(--pub-text);
    line-height: 1.35;
    display: block;
    margin-bottom: 2px;
}
.np-sidebar-article-link:hover .np-sidebar-article-headline {
    color: var(--pub-accent);
}
.np-sidebar-article-byline {
    font-size: 12px;
    color: var(--pub-text-muted);
    display: block;
}

/* ── "View full edition" link ── */
.pub-sidebar-view-all {
    display: block;
    text-align: center;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--pub-border);
    color: var(--pub-accent);
    font-weight: 600;
    font-size: 13px;
    text-decoration: none;
}
.pub-sidebar-view-all:hover {
    text-decoration: underline;
}

/* ── Ad sidebar inner ── */
.pub-ad-sidebar-inner {
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    padding: 16px 14px;
}
.pub-ad-sidebar-inner.pub-sidebar-empty {
    display: none;
}

/* ── Ad sections ── */
.pub-ad-section {
    margin-bottom: 20px;
}
.pub-ad-section:last-child {
    margin-bottom: 0;
}

/* ── Ad badge ── */
.pub-ad-badge {
    font-size: 10px;
    font-weight: 600;
    background: #e5e7eb;
    color: #6b7280;
    padding: 1px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ── Quick Ads cards ── */
.pub-qa-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.pub-qa-card {
    border-bottom: 1px solid var(--pub-border);
    padding-bottom: 12px;
}
.pub-qa-card:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.pub-qa-image {
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
}
.pub-qa-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    max-height: 160px;
}
.pub-qa-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--pub-text);
    margin: 0 0 4px;
    line-height: 1.35;
}
.pub-qa-title a {
    color: inherit;
    text-decoration: none;
}
.pub-qa-title a:hover {
    color: var(--pub-accent);
}
.pub-qa-desc {
    font-size: 13px;
    color: var(--pub-text-muted);
    margin: 0;
    line-height: 1.5;
}

/* ── Directory Ad cards ── */
.pub-da-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.pub-ad-card {
    border: 1px solid var(--pub-border);
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}
.pub-ad-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.pub-ad-card-image {
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #f1f5f9;
}
.pub-ad-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.pub-ad-card-body {
    padding: 10px 12px;
}
.pub-ad-card-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--pub-text);
    margin: 0 0 4px;
    line-height: 1.35;
}
.pub-ad-card-title a {
    color: inherit;
    text-decoration: none;
}
.pub-ad-card-title a:hover {
    color: var(--pub-accent);
}
.pub-ad-card-desc {
    font-size: 12px;
    color: var(--pub-text-muted);
    margin: 0;
    line-height: 1.4;
}

/* ── Sidebar overflow (4+ ad cards) ── */
.pub-da-list:has(.pub-ad-card:nth-child(4)) {
    max-height: 600px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #ccc transparent;
}
.pub-da-list:has(.pub-ad-card:nth-child(4))::-webkit-scrollbar {
    width: 4px;
}
.pub-da-list:has(.pub-ad-card:nth-child(4))::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

/* ── Recent blogs sidebar ── */
.pub-sidebar-blog-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.pub-sidebar-blog-card {
    display: block;
    text-decoration: none;
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid var(--pub-border);
    border-left: 3px solid transparent;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.pub-sidebar-blog-card:hover {
    border-color: var(--pub-accent);
    border-left-color: var(--pub-accent);
    background: rgba(242,97,34,0.02);
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    text-decoration: none;
}
.pub-sidebar-blog-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--pub-text);
    line-height: 1.35;
    display: block;
    margin-bottom: 4px;
}
.pub-sidebar-blog-card:hover .pub-sidebar-blog-title {
    color: var(--pub-accent);
}
.pub-sidebar-blog-meta {
    font-size: 12px;
    color: var(--pub-text-muted);
    display: block;
}

/* ================================================================
   10b. SIDEBAR RESPONSIVE
   ================================================================ */

/* 1024-1200px: Compress sidebars */
@media (max-width: 1200px) and (min-width: 1025px) {
    .pub-sidebar-left { flex: 0 0 220px; }
    .pub-sidebar-right { flex: 0 0 240px; }
    .pub-columns-wrap { gap: 20px; }
}

/* 768-1024px: Stack to single column */
@media (max-width: 1024px) {
    .pub-columns-wrap {
        flex-direction: column;
    }
    .pub-sidebar {
        position: static;
        width: 100%;
    }
    .pub-sidebar-left {
        flex: none;
        order: 3;
    }
    .pub-sidebar-right {
        flex: none;
        order: 2;
    }
    .pub-main {
        order: 1;
    }
}

/* <768px: Compact padding, full-width */
@media (max-width: 768px) {
    .pub-columns-wrap {
        gap: 16px;
    }
    .pub-sidebar-inner {
        padding: 16px 14px;
    }
    .pub-ad-sidebar-inner {
        padding: 14px 12px;
    }
}

/* ================================================================
   11. QUICK AD BUNDLE PAGE
   ================================================================ */

.pub-quickad-page {
    padding: 40px 0 60px;
    background: var(--pub-bg);
    min-height: 70vh;
    animation: pub-fade-in 0.4s ease-out both;
}

.pub-quickad-hero {
    display: flex;
    gap: 24px;
    align-items: center;
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    padding: 28px 32px;
    margin-bottom: 28px;
}
.pub-quickad-logo {
    flex: 0 0 auto;
}
.pub-quickad-logo img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 12px;
    border: 2px solid var(--pub-border);
}
.pub-quickad-hero-info {
    flex: 1;
    min-width: 0;
}
.pub-quickad-title {
    font-family: var(--pub-font-headline);
    font-size: 32px;
    font-weight: 900;
    color: #1a1a1a;
    margin: 8px 0 10px;
    line-height: 1.2;
}
.pub-quickad-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 14px;
    color: var(--pub-text-muted);
}

.pub-quickad-about,
.pub-quickad-achievements,
.pub-quickad-podcasts {
    background: var(--pub-card-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    padding: 28px 32px;
    margin-bottom: 24px;
}
.pub-quickad-about h2,
.pub-quickad-achievements h2,
.pub-quickad-podcasts h2 {
    font-family: var(--pub-font-ui);
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 16px;
}
.pub-quickad-about-body {
    font-family: var(--pub-font-body);
    font-size: 16px;
    line-height: 1.8;
    color: var(--pub-text);
}
.pub-quickad-about-body p {
    margin-bottom: 1em;
}

.pub-quickad-ach-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}
.pub-quickad-ach-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: #f0f9ff;
    border-radius: 10px;
    padding: 20px 16px;
    gap: 8px;
}
.pub-quickad-ach-card i {
    font-size: 28px;
    color: #667eea;
}
.pub-quickad-ach-card span {
    font-weight: 600;
    font-size: 14px;
    color: var(--pub-text);
}

.pub-quickad-podcast-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
}

.pub-podcast-card {
    display: flex;
    flex-direction: column;
    background: var(--pub-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.pub-podcast-card:hover {
    border-color: var(--pub-accent);
    box-shadow: 0 4px 16px rgba(242,97,34,0.12);
    transform: translateY(-2px);
    text-decoration: none;
    color: inherit;
}
.pub-podcast-card-thumb {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
}
.pub-podcast-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.pub-podcast-card-icon {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #94a3b8;
}

.pub-podcast-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    border-radius: 4px;
    color: #fff;
}
.pub-podcast-card-thumb .pub-podcast-type-badge {
    position: absolute;
    top: 8px;
    left: 8px;
}
.pub-podcast-type-audio   { background: linear-gradient(135deg, #7c3aed, #6d28d9); }
.pub-podcast-type-video   { background: linear-gradient(135deg, #dc2626, #b91c1c); }
.pub-podcast-type-youtube { background: linear-gradient(135deg, #ef4444, #dc2626); }

.pub-podcast-card-body {
    padding: 14px 16px;
}
.pub-podcast-card-body h4 {
    font-family: var(--pub-font-ui);
    font-size: 15px;
    font-weight: 600;
    color: var(--pub-text);
    margin: 0 0 4px;
    line-height: 1.35;
}
.pub-podcast-card-author {
    font-size: 13px;
    color: var(--pub-text-muted);
}

.pub-quickad-share {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 0;
    margin-top: 10px;
}

/* ================================================================
   12. PODCAST DETAIL PAGE
   ================================================================ */

.pub-podcast-detail {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 20px 60px;
    min-height: 70vh;
    animation: pub-fade-in 0.4s ease-out both;
}

.pub-podcast-detail-type {
    margin-bottom: 12px;
}

.pub-podcast-detail-title {
    font-family: var(--pub-font-headline);
    font-size: 36px;
    font-weight: 900;
    color: #1a1a1a;
    line-height: 1.15;
    margin: 0 0 12px;
}

.pub-podcast-detail-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    color: var(--pub-text-muted);
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.pub-podcast-detail-meta strong {
    color: var(--pub-text);
}

.pub-podcast-player {
    margin-bottom: 24px;
}
.pub-podcast-player-thumb {
    position: relative;
    border-radius: var(--pub-radius);
    overflow: hidden;
    max-height: 420px;
}
.pub-podcast-player-thumb img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}
.pub-podcast-play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.3);
    color: #fff;
    font-size: 64px;
    text-decoration: none;
    transition: background 0.2s;
}
.pub-podcast-play-overlay:hover {
    background: rgba(0,0,0,0.5);
    color: #fff;
    text-decoration: none;
}

.pub-podcast-player-audio {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px;
    background: var(--pub-bg);
    border: 1px solid var(--pub-border);
    border-radius: var(--pub-radius);
}

.pub-podcast-external-link {
    margin-bottom: 24px;
}
.pub-podcast-listen-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: var(--pub-accent);
    color: #fff;
    font-family: var(--pub-font-ui);
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    transition: opacity 0.2s, box-shadow 0.2s;
}
.pub-podcast-listen-btn:hover {
    opacity: 0.9;
    box-shadow: 0 4px 12px rgba(242,97,34,0.3);
    text-decoration: none;
    color: #fff;
}

/* ── Responsive: Quick Ad + Podcast ── */
@media (max-width: 768px) {
    .pub-quickad-hero {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
    .pub-quickad-title { font-size: 24px; }
    .pub-quickad-meta { justify-content: center; }
    .pub-quickad-about,
    .pub-quickad-achievements,
    .pub-quickad-podcasts {
        padding: 20px;
    }
    .pub-quickad-podcast-grid { grid-template-columns: 1fr; }
    .pub-podcast-detail { padding: 20px 16px 40px; }
    .pub-podcast-detail-title { font-size: 28px; }
}
@media (max-width: 480px) {
    .pub-quickad-title { font-size: 22px; }
    .pub-podcast-detail-title { font-size: 24px; }
}
