/* ============================================
   FAST BREAKING NEWS — Satirical News Outlet
   CNN parody meets The Onion
   ============================================ */

:root {
    --bg: #0d1117;
    --surface: #161b22;
    --surface2: #1c2128;
    --border: #2d333b;
    --red: #ef4444;
    --red-dark: #b91c1c;
    --red-glow: rgba(239, 68, 68, 0.4);
    --gold: #c9a84c;
    --gold-dim: rgba(201, 168, 76, 0.3);
    --white: #f0f0f0;
    --text: #c9d1d9;
    --text-dim: #6e7681;
    --text-bright: #ffffff;
    --yellow: #f59e0b;
    --blue: #3b82f6;
    --purple: #a855f7;
    --cyan: #06b6d4;
    --green: #22c55e;
    --orange: #f97316;
    --font-display: 'Cinzel', serif;
    --font-body: 'Cormorant Garamond', Georgia, serif;
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

/* ---- RESET ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 18px;
    font-weight: 400;
    line-height: 1.6;
    min-height: 100vh;
}
a { color: var(--gold); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--white); }
img { max-width: 100%; height: auto; display: block; }

/* ---- TOP RED BANNER ---- */
.top-banner {
    background: linear-gradient(135deg, var(--red-dark), var(--red));
    padding: 12px 24px;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-bottom: 3px solid var(--gold);
    box-shadow: 0 4px 20px var(--red-glow);
}
.top-banner::before {
    content: '';
    position: absolute;
    top: 0; left: -100%; right: -100%; bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.08), transparent);
    animation: banner-shine 4s ease-in-out infinite;
}
@keyframes banner-shine {
    0%, 100% { transform: translateX(-100%); }
    50% { transform: translateX(100%); }
}
.top-banner h1 {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-bright);
    letter-spacing: 4px;
    text-transform: uppercase;
    position: relative;
    text-shadow: 0 0 20px var(--red-glow);
}
.top-banner h1 span.fast {
    color: var(--gold);
}
.top-banner .subtitle {
    font-family: var(--font-sans);
    font-size: 0.7rem;
    color: rgba(255,255,255,0.7);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-top: 2px;
}

/* ---- TICKER ---- */
.ticker-wrap {
    background: #000;
    border-bottom: 2px solid var(--red);
    overflow: hidden;
    display: flex;
    align-items: center;
    height: 40px;
}
.ticker-label {
    background: var(--red);
    color: white;
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 2px;
    padding: 0 16px;
    height: 100%;
    display: flex;
    align-items: center;
    white-space: nowrap;
    text-transform: uppercase;
    position: relative;
    z-index: 2;
    animation: label-pulse 2s ease-in-out infinite;
}
.ticker-label::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 0;
    border-left: 8px solid var(--red);
    border-top: 20px solid transparent;
    border-bottom: 20px solid transparent;
}
@keyframes label-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}
.ticker-track {
    display: flex;
    animation: ticker-scroll 60s linear infinite;
    padding-left: 16px;
}
.ticker-track:hover { animation-play-state: paused; }
.ticker-item {
    white-space: nowrap;
    padding: 0 32px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--gold);
}
.ticker-item::before {
    content: '\25CF';
    color: var(--red);
    margin-right: 10px;
}
@keyframes ticker-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ---- NAV ---- */
.nav-bar {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 0;
    overflow-x: auto;
}
.nav-bar a {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 14px 18px;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
    white-space: nowrap;
}
.nav-bar a:hover,
.nav-bar a.active {
    color: var(--red);
    border-bottom-color: var(--red);
}

/* ---- MAIN LAYOUT ---- */
.main-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 24px;
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 32px;
}

/* ---- SECTION HEADERS ---- */
.section-header {
    font-family: var(--font-display);
    font-size: 1rem;
    color: var(--text-bright);
    text-transform: uppercase;
    letter-spacing: 2px;
    padding-bottom: 8px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--red);
    display: flex;
    align-items: center;
    gap: 8px;
}
.section-header .dot {
    width: 8px;
    height: 8px;
    background: var(--red);
    border-radius: 50%;
    animation: dot-pulse 1.5s ease-in-out infinite;
}
@keyframes dot-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.8); }
}

/* ---- ARTICLE CARDS ---- */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}
.article-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
}
.article-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}
.article-card .card-thumb {
    width: 100%;
    height: 180px;
    background: var(--surface2);
    position: relative;
    overflow: hidden;
}
.article-card .card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.article-card .card-thumb .placeholder-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--border);
}
.article-card .card-body {
    padding: 16px;
}
.article-card .card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}
.article-card .card-headline {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-bright);
    line-height: 1.3;
    margin-bottom: 8px;
}
.article-card .card-headline a {
    color: inherit;
}
.article-card .card-headline a:hover {
    color: var(--gold);
}
.article-card .card-excerpt {
    font-size: 0.95rem;
    color: var(--text);
    line-height: 1.5;
    margin-bottom: 10px;
}
.article-card .card-footer {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    color: var(--text-dim);
    display: flex;
    justify-content: space-between;
}

/* ---- FEATURED CARD (first article, full width) ---- */
.article-card.featured {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
}
.article-card.featured .card-thumb {
    height: 100%;
    min-height: 280px;
}
.article-card.featured .card-headline {
    font-size: 1.6rem;
}

/* ---- BADGES ---- */
.badge {
    font-family: var(--font-sans);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 3px;
    display: inline-block;
}
.badge-category {
    color: var(--bg);
    font-weight: 800;
}
.badge-breaking {
    background: var(--red);
    color: white;
    animation: badge-flash 1.5s ease-in-out infinite;
}
@keyframes badge-flash {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}
.badge-developing {
    background: var(--yellow);
    color: #000;
}
.badge-just-in {
    background: var(--blue);
    color: white;
}

/* ---- SIDEBAR ---- */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Trending box */
.trending-box {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 16px;
}
.trending-box ol {
    list-style: none;
    counter-reset: trending;
}
.trending-box li {
    counter-increment: trending;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
}
.trending-box li:last-child { border-bottom: none; }
.trending-box li::before {
    content: counter(trending);
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--red);
    margin-right: 12px;
}
.trending-box li a {
    color: var(--text);
    font-family: var(--font-display);
    font-size: 0.85rem;
}
.trending-box li a:hover { color: var(--gold); }

/* ---- FAKE ADS ---- */
.fake-ad {
    background: var(--surface2);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 20px;
    text-align: center;
    position: relative;
}
.fake-ad .ad-label {
    position: absolute;
    top: 6px;
    right: 10px;
    font-family: var(--font-sans);
    font-size: 0.55rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.fake-ad .ad-icon {
    font-size: 2.5rem;
    margin-bottom: 8px;
}
.fake-ad .ad-name {
    font-family: var(--font-display);
    font-size: 1rem;
    color: var(--gold);
    margin-bottom: 6px;
}
.fake-ad .ad-tagline {
    font-size: 0.85rem;
    color: var(--text);
    font-style: italic;
    margin-bottom: 10px;
    line-height: 1.4;
}
.fake-ad .ad-price {
    font-family: var(--font-sans);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 12px;
}
.fake-ad .ad-cta {
    display: inline-block;
    background: var(--red);
    color: white;
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 8px 24px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}
.fake-ad .ad-cta:hover {
    background: var(--red-dark);
    transform: scale(1.05);
}

/* ---- SINGLE ARTICLE VIEW ---- */
.article-view {
    max-width: 780px;
}
.article-view .article-header {
    margin-bottom: 32px;
}
.article-view .article-header h1 {
    font-family: var(--font-display);
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text-bright);
    line-height: 1.2;
    margin: 12px 0;
}
.article-view .article-byline {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-top: 8px;
}
.article-view .article-body {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text);
}
.article-view .article-body p { margin-bottom: 1.2em; }
.article-view .article-body strong { color: var(--text-bright); }
.article-view .article-body blockquote {
    border-left: 3px solid var(--gold);
    padding-left: 20px;
    margin: 20px 0;
    font-style: italic;
    color: var(--text-dim);
}
.article-view .article-body h2,
.article-view .article-body h3 {
    font-family: var(--font-display);
    color: var(--text-bright);
    margin: 1.5em 0 0.5em;
}

/* More headlines (at bottom of article) */
.more-headlines {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 2px solid var(--border);
}
.more-headlines .mini-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 16px;
}
.more-headlines .mini-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 14px;
}
.more-headlines .mini-card .mini-cat {
    font-family: var(--font-sans);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}
.more-headlines .mini-card .mini-title {
    font-family: var(--font-display);
    font-size: 0.85rem;
    color: var(--text-bright);
    line-height: 1.3;
}
.more-headlines .mini-card .mini-title a { color: inherit; }
.more-headlines .mini-card .mini-title a:hover { color: var(--gold); }

/* ---- FOOTER ---- */
.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 32px 24px;
    text-align: center;
    margin-top: 48px;
}
.site-footer .disclaimer {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    color: var(--text-dim);
    max-width: 640px;
    margin: 0 auto 12px;
    line-height: 1.5;
    font-style: italic;
}
.site-footer .copyright {
    font-family: var(--font-sans);
    font-size: 0.7rem;
    color: var(--text-dim);
}

/* ---- 404 ---- */
.not-found {
    text-align: center;
    padding: 80px 24px;
}
.not-found h2 {
    font-family: var(--font-display);
    font-size: 3rem;
    color: var(--red);
    margin-bottom: 12px;
}
.not-found p {
    font-size: 1.1rem;
    color: var(--text-dim);
}

/* ---- RESPONSIVE ---- */
@media (max-width: 900px) {
    .main-wrap {
        grid-template-columns: 1fr;
    }
    .article-card.featured {
        grid-template-columns: 1fr;
    }
    .article-card.featured .card-thumb {
        min-height: 200px;
    }
}
@media (max-width: 600px) {
    .top-banner h1 {
        font-size: 1.3rem;
        letter-spacing: 2px;
    }
    .nav-bar { padding: 0 12px; }
    .nav-bar a { padding: 10px 12px; font-size: 0.7rem; }
    .main-wrap { padding: 16px; }
    .article-grid {
        grid-template-columns: 1fr;
    }
    .article-view .article-header h1 {
        font-size: 1.5rem;
    }
}
