/* ============================================
   THE CLIMATE LEDGER — ARTICLES V3 STYLES
   Trainline Group News & Executive Briefings Theme
   ============================================ */

.articles-page {
    padding-top: 140px;
    padding-bottom: 80px;
    background-color: #ffffff;
    min-height: 100vh;
}

.articles-page .section-header h1 {
    font-size: clamp(2.5rem, 4.5vw, 3.8rem);
    color: var(--text-heading) !important;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.articles-page .section-header p {
    color: #4b5563 !important;
    font-size: 1.2rem;
}

/* --- CONTROLS BAR: TABS & LIVE SEARCH --- */
.articles-controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-top: 2rem;
    margin-bottom: 2.5rem;
}

.articles-search-box {
    position: relative;
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 1.5px solid #d1d5db;
    border-radius: var(--radius-sm);
    padding: 0.75rem 1.25rem;
    gap: 0.75rem;
    min-width: 320px;
    box-shadow: 0 2px 8px rgba(0, 35, 38, 0.05);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.articles-search-box:focus-within {
    border-color: var(--accent-main);
    box-shadow: 0 0 0 3px rgba(0, 168, 143, 0.2);
}

.articles-search-box svg {
    color: var(--accent-main);
    flex-shrink: 0;
}

.articles-search-box input {
    background: transparent;
    border: none;
    outline: none;
    color: #111827;
    font-size: 0.95rem;
    font-weight: 600;
    font-family: inherit;
    width: 100%;
}

.articles-search-box input::placeholder {
    color: #9ca3af;
    font-weight: 450;
}

/* --- SPOTLIGHT INTELLIGENCE HERO --- */
.articles-spotlight-section {
    margin-bottom: 3.5rem;
}

.spotlight-card {
    position: relative;
    border-radius: 20px !important;
    background: #ffffff !important;
    border: 1.5px solid var(--accent-main) !important;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0, 35, 38, 0.08) !important;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease !important;
}

.spotlight-card:hover {
    transform: translateY(-6px) !important;
    border-color: var(--bg-mint-hover) !important;
    box-shadow: 0 18px 45px rgba(0, 35, 38, 0.14) !important;
}

.spotlight-banner-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.45rem 1.1rem;
    background: #e6faf6;
    border-bottom: 1px solid rgba(0, 168, 143, 0.25);
    border-right: 1px solid rgba(0, 168, 143, 0.25);
    border-radius: 0 0 12px 0;
    color: var(--accent-main);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.spotlight-pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-main);
    box-shadow: 0 0 8px var(--accent-main);
    animation: pulse 2s infinite;
}

.spotlight-content-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 2.5rem;
    padding: 2.25rem 2.5rem 2.5rem;
    align-items: center;
}

.spotlight-meta-top {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.85rem;
}

.spotlight-cat-badge {
    background: #e6faf6;
    border: 1px solid rgba(0, 168, 143, 0.3);
    color: var(--accent-main);
    font-size: 0.78rem;
    font-weight: 800;
    padding: 0.3rem 0.85rem;
    border-radius: 9999px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.spotlight-read-time {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.85rem;
    color: #6b7280;
    font-weight: 600;
}

.spotlight-title {
    font-size: clamp(1.6rem, 2.4vw, 2.2rem);
    font-weight: 800;
    line-height: 1.25;
    color: var(--text-heading) !important;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.spotlight-excerpt {
    font-size: 1.05rem;
    color: #4b5563 !important;
    line-height: 1.7;
    margin-bottom: 1.75rem;
}

.spotlight-action-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.btn-spotlight-read {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 1.85rem;
    background: var(--accent-main);
    color: #ffffff !important;
    font-weight: 700;
    font-size: 0.98rem;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 168, 143, 0.25);
    transition: all 0.2s ease;
}

.btn-spotlight-read:hover {
    background: var(--bg-mint-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 168, 143, 0.38);
}

.spotlight-author-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: #6b7280;
}

.spotlight-image-col {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    height: 260px;
    border: 1px solid #e5e7eb;
}

.spotlight-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.spotlight-card:hover .spotlight-thumb {
    transform: scale(1.04);
}

/* --- TRENDING FOCUS CHIPS --- */
.trending-topics-bar {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
    margin: 1.5rem 0 2rem;
    padding: 0.85rem 1.25rem;
    background: #f8faf9;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
}

.trending-label {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-heading);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.trending-chips-list {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.trending-chip {
    padding: 0.35rem 0.85rem;
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
}

.trending-chip:hover {
    border-color: var(--accent-main);
    color: var(--accent-main);
    background: #e6faf6;
}

/* --- ARTICLES GRID --- */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    padding: 1.5rem 0;
    align-items: stretch;
}

/* --- ARTICLE CARD (Trainline style) --- */
.article-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: #ffffff !important;
    border: 1.5px solid var(--accent-main) !important;
    border-radius: 16px !important;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 35, 38, 0.05) !important;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease !important;
}

.article-card:hover {
    border-color: var(--bg-mint-hover) !important;
    transform: translateY(-6px) !important;
    box-shadow: 0 16px 36px rgba(0, 35, 38, 0.12) !important;
}

.article-card-image {
    height: 190px;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid #e5e7eb;
    background: #f0fbf9;
}

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

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

.premium-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    background: #002326;
    color: #2dd4bf;
    font-size: 0.74rem;
    font-weight: 800;
    padding: 0.28rem 0.75rem;
    border-radius: var(--radius-full);
    letter-spacing: 0.03em;
}

.article-card-category {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 0.28rem 0.75rem;
    border-radius: var(--radius-full);
    background: #ffffff;
    border: 1px solid rgba(0, 168, 143, 0.3);
    color: var(--accent-main);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.article-card-body {
    padding: 1.75rem 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    background: #ffffff !important;
}

.article-tags-row {
    display: flex;
    gap: 0.45rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.article-tag-chip {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--accent-main);
    background: #e6faf6;
    border: 1px solid rgba(0, 168, 143, 0.25);
    padding: 0.2rem 0.55rem;
    border-radius: 6px;
    font-family: var(--font-mono, monospace);
}

.article-title {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.35;
    color: var(--text-heading) !important;
    margin-bottom: 0.85rem;
    transition: color 0.2s ease;
}

.article-card:hover .article-title {
    color: var(--accent-main) !important;
}

.article-card-body .excerpt-text {
    font-size: 0.98rem;
    color: #4b5563 !important;
    line-height: 1.65;
    margin-bottom: auto;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.btn-read-more,
.btn-show-less {
    color: var(--accent-main) !important;
    font-size: 0.95rem;
    font-weight: 700;
    margin-top: 1.25rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: gap 0.2s ease;
    align-self: flex-start;
}

.btn-read-more:hover {
    gap: 10px;
    color: var(--bg-mint-hover) !important;
}

.article-card-meta {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.88rem;
    color: #6b7280 !important;
    font-weight: 600;
}

.article-read-time {
    color: #6b7280 !important;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ============================================
   EXECUTIVE BRIEFING READER MODAL
   ============================================ */
.briefing-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 35, 38, 0.65);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    animation: fadeIn 0.25s ease;
}

.briefing-modal-card {
    position: relative;
    max-width: 860px;
    width: 100%;
    max-height: 88vh;
    overflow-y: auto;
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 20px;
    box-shadow: 0 25px 60px rgba(0, 35, 38, 0.25);
    animation: modalScaleUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.briefing-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 10;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #ffffff;
    border: 1px solid #d1d5db;
    color: #111827;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
}

.briefing-modal-close:hover {
    background: #fee2e2;
    border-color: #ef4444;
    color: #ef4444;
    transform: rotate(90deg);
}

.briefing-modal-banner {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: #f0fbf9;
}

.briefing-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.briefing-modal-body {
    padding: 2.5rem;
}

.briefing-modal-title {
    font-size: clamp(1.8rem, 2.5vw, 2.25rem);
    font-weight: 800;
    line-height: 1.25;
    color: var(--text-heading) !important;
    margin-bottom: 1.25rem;
}

.briefing-meta-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-bottom: 1.25rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.briefing-meta-info {
    flex-grow: 1;
}

.briefing-meta-title {
    color: #111827;
    font-weight: 700;
    font-size: 0.95rem;
}

.briefing-meta-sub {
    color: #6b7280;
    font-size: 0.85rem;
}

.briefing-takeaways-box {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f0fbf9 !important;
    border: 1.5px solid rgba(0, 168, 143, 0.3) !important;
    border-radius: 12px;
}

.takeaways-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--accent-main);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.takeaways-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.takeaways-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.95rem;
    color: #374151;
    line-height: 1.6;
}

.takeaway-bullet {
    color: var(--accent-main);
    font-weight: 800;
}

.briefing-p {
    font-size: 1.05rem;
    color: #374151 !important;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.briefing-cta-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.75rem;
    background: #f8faf9;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.cta-box-text h4 {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-heading) !important;
    margin-bottom: 0.35rem;
}

.cta-box-text p {
    font-size: 0.95rem;
    color: #4b5563 !important;
    margin: 0;
}

.btn-briefing-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.85rem 1.65rem;
    background: var(--accent-main);
    color: #ffffff !important;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0, 168, 143, 0.25);
    transition: all 0.2s ease;
}

.btn-briefing-cta:hover {
    background: var(--bg-mint-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 168, 143, 0.38);
}

@media (max-width: 1024px) {
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    .spotlight-content-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }
    .articles-page {
        padding-top: 120px;
    }
}
