/*
 * Stories Page Styles — New Hope to Asia
 * NHTA Design System v2 — dark hero banner + warm magazine grid + filter pills
 */

/* ===== GP OVERRIDES ===== */
.nhta-story-card .featured-image-caption,
.nhta-story-caption {
    display: none !important;
}
.blog .site-content {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}
.blog .inside-article {
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    max-width: 100% !important;
}
.blog .entry-header {
    display: none;
}
.blog .entry-content {
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
.blog .site-main {
    max-width: 100% !important;
    margin: 0 !important;
}
.blog .content-area {
    width: 100% !important;
    float: none !important;
}
.blog #right-sidebar,
.blog .widget-area {
    display: none !important;
}
.blog .separate-containers .inside-article {
    max-width: 100% !important;
}

/* ===== HERO: SLIM DARK BANNER ===== */
.nhta-stories-hero {
    background: var(--nhta-charcoal);
    position: relative;
    overflow: hidden;
    padding: 72px 40px 56px;
    text-align: center;
}
/* Grain texture */
.nhta-stories-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.06'/%3E%3C/svg%3E");
    background-size: 180px;
    pointer-events: none;
    z-index: 1;
}
/* Amber glow */
.nhta-stories-hero::after {
    content: '';
    position: absolute;
    bottom: -60%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(212,133,74,.12) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}
.nhta-stories-hero-inner {
    position: relative;
    z-index: 2;
    max-width: 700px;
    margin: 0 auto;
}
.nhta-stories-hero .nhta-rule.center {
    margin: 12px auto 18px;
}
.nhta-stories-hero-h1 {
    font-family: var(--nhta-display) !important;
    font-size: clamp(32px, 4vw, 48px) !important;
    font-weight: 900 !important;
    color: white !important;
    line-height: 1.1 !important;
    letter-spacing: -.02em;
    margin: 0 !important;
}
.nhta-stories-hero-h1::after {
    display: none !important;
}
.nhta-stories-hero-h1 em {
    font-style: italic;
    font-weight: 400;
    color: var(--nhta-amber-light);
}
.nhta-stories-hero-sub {
    font-family: var(--nhta-sans);
    font-size: 15px;
    font-weight: 300;
    color: rgba(255,255,255,.7);
    line-height: 1.7;
    margin: 14px auto 0;
    max-width: 520px;
}

/* ===== STORIES FEED: WARM SECTION ===== */
.nhta-stories-feed {
    background: var(--nhta-cream);
    padding: 56px 0 72px;
}
.nhta-stories-feed-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* ===== FILTER PILLS ===== */
.nhta-story-filter {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 32px;
}
.nhta-story-filter-btn {
    font-family: var(--nhta-sans);
    font-size: 11px;
    font-weight: 500;
    padding: 7px 16px;
    border-radius: 20px;
    cursor: pointer;
    border: 1.5px solid var(--nhta-cream-3);
    background: white;
    color: var(--nhta-muted);
    transition: all var(--nhta-t);
}
.nhta-story-filter-btn.active {
    background: var(--nhta-amber);
    color: white;
    border-color: var(--nhta-amber);
    box-shadow: 0 2px 10px rgba(212,133,74,.3);
}
.nhta-story-filter-btn:hover:not(.active) {
    border-color: var(--nhta-amber);
    color: var(--nhta-amber);
}

/* ===== MAGAZINE GRID ===== */
.nhta-stories-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 18px;
}

/* ===== STORY CARDS ===== */
.nhta-story-card {
    background: white;
    border: 1px solid var(--nhta-cream-3);
    border-radius: var(--nhta-r-md);
    overflow: hidden;
    box-shadow: var(--nhta-shadow-sm);
    transition: box-shadow var(--nhta-t), transform var(--nhta-t);
    text-decoration: none !important;
    display: flex;
    flex-direction: column;
}
.nhta-story-card:hover {
    box-shadow: var(--nhta-shadow-md);
    transform: translateY(-2px);
}

/* Featured card spans 2 rows */
.nhta-story-card.featured {
    grid-row: span 2;
}

/* ===== STORY IMAGE ===== */
.nhta-story-img {
    position: relative;
    overflow: hidden;
    background: var(--nhta-cream-2);
}
.nhta-story-card.featured .nhta-story-img {
    height: 240px;
}
.nhta-story-card:not(.featured) .nhta-story-img {
    height: 150px;
}
.nhta-story-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .5s ease;
}
.nhta-story-card:hover .nhta-story-img img {
    transform: scale(1.04);
}
.nhta-story-img-placeholder {
    width: 100%;
    height: 100%;
    background: var(--nhta-cream-2);
}

/* Caption overlay on image */
.nhta-story-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.5) 0%, transparent 50%);
    pointer-events: none;
    z-index: 1;
}
.nhta-story-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    font-family: var(--nhta-sans);
    font-size: 10.5px;
    font-weight: 400;
    color: white;
    letter-spacing: .02em;
    padding: 24px 14px 10px;
    z-index: 2;
}
.nhta-story-card.featured .nhta-story-caption {
    font-size: 11.5px;
}

/* ===== STORY BODY ===== */
.nhta-story-body {
    padding: 18px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.nhta-story-cat {
    font-family: var(--nhta-sans);
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: .13em;
    text-transform: uppercase;
    color: var(--nhta-amber);
    margin-bottom: 8px;
}
.nhta-story-title {
    font-family: var(--nhta-display) !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    color: var(--nhta-ink) !important;
    line-height: 1.25 !important;
    margin: 0 0 8px !important;
}
.nhta-story-title::after {
    display: none !important;
}
.nhta-story-card:not(.featured) .nhta-story-title {
    font-size: 14.5px !important;
}
.nhta-story-excerpt {
    font-family: var(--nhta-sans);
    font-size: 12.5px;
    color: var(--nhta-muted);
    line-height: 1.65;
    flex: 1;
    margin-bottom: 14px;
    font-weight: 300;
}
.nhta-story-meta {
    font-family: var(--nhta-sans);
    font-size: 10.5px;
    color: #c0b9b0;
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 6px;
}
.nhta-story-meta::before {
    content: '';
    width: 18px;
    height: 1px;
    background: #e0d9ce;
}

/* ===== NO POSTS ===== */
.nhta-stories-none {
    font-family: var(--nhta-sans);
    font-size: 15px;
    color: var(--nhta-muted);
    text-align: center;
    padding: 48px 0;
}

/* ===== PAGINATION ===== */
.nhta-stories-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 48px;
}
.nhta-stories-page-link a,
.nhta-stories-page-link span {
    display: inline-block;
    font-family: var(--nhta-sans);
    font-size: 13px;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 8px;
    text-decoration: none;
    transition: all var(--nhta-t);
}
.nhta-stories-page-link a {
    color: var(--nhta-ink);
    border: 1px solid var(--nhta-cream-3);
    background: white;
}
.nhta-stories-page-link a:hover {
    border-color: var(--nhta-amber);
    color: var(--nhta-amber);
}
.nhta-stories-page-link span.current {
    background: var(--nhta-amber);
    color: white;
    border: 1px solid var(--nhta-amber);
}
.nhta-stories-page-link .prev,
.nhta-stories-page-link .next {
    font-weight: 400;
    letter-spacing: .02em;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .nhta-stories-grid {
        grid-template-columns: 1fr 1fr;
    }
    .nhta-story-card.featured {
        grid-row: auto;
        grid-column: span 2;
    }
    .nhta-story-card.featured .nhta-story-img {
        height: 200px;
    }
}

@media (max-width: 768px) {
    .nhta-stories-hero {
        padding: 56px 24px 40px;
    }
    .nhta-stories-feed-inner {
        padding: 0 20px;
    }
    .nhta-stories-grid {
        grid-template-columns: 1fr;
    }
    .nhta-story-card.featured {
        grid-column: auto;
    }
    .nhta-story-card.featured .nhta-story-img {
        height: 180px;
    }
    .nhta-story-card:not(.featured) .nhta-story-img {
        height: 140px;
    }
    .nhta-stories-pagination {
        flex-wrap: wrap;
    }
}
