/* ==========================================================================
   Vice Wire /blog index + category archives (Redesign Phase 3, specs 03/04)
   Page-layout styles only — card/chip/search visuals come from blog.css.
   NOTE (spec 03 §5 gotcha): blog.css USES the --gta-* tokens but does not
   define them; they live in landing.css. This file re-declares the token
   block itself instead of linking the whole landing stylesheet.
   ========================================================================== */

:root {
    --gta-pink: #ff50c5;
    --gta-cyan: #00de85;
    --gta-orange: #ff9f43;
    --gta-purple: #9b51e0;
    --gta-bg-dark: #07070f;
    --gta-surface: #0e0f1c;
    --gta-surface-card: rgba(18, 20, 36, 0.85);
    --gta-border: rgba(255, 80, 197, 0.22);
    --gta-border-subtle: rgba(255, 255, 255, 0.08);
    --gta-text-main: #f5f6fa;
    --gta-text-muted: #9aa0b4;
    /* Category accents (spec 04 §6) */
    --bp-guides: #ff2e9e;
    --bp-updates: #ff7a18;
    --bp-qa: #00e5ff;
    --bp-deep: #b537f2;
}

* { box-sizing: border-box; }

body.bp-page {
    margin: 0;
    background: #090a16;
    color: #e5e7eb;
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.bp-wrap {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 1.5rem 4rem;
}

/* ------------------------------------------------------------- top bar */
.bp-topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0 1.5rem;
    background: rgba(6, 7, 16, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.bp-wordmark {
    color: #fff;
    text-decoration: none;
    font-weight: 900;
    font-size: 1.25rem;
    letter-spacing: 0.06em;
}

.bp-wordmark span { color: var(--gta-pink); }

.bp-topnav { display: flex; align-items: center; gap: 0.6rem; }

.bp-topbtn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #e5e7eb;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    transition: border-color 0.2s ease, background 0.2s ease;
}

.bp-topbtn:hover { border-color: rgba(255, 80, 197, 0.55); }

.bp-topbtn--discord {
    background: #5865F2;
    border-color: #5865F2;
    color: #fff;
}

.bp-topbtn--discord:hover { background: #4752c4; border-color: #4752c4; }

/* ---------------------------------------------------------------- hero */
.bp-hero {
    position: relative;
    margin: 1.5rem 0 2.5rem;
    border-radius: 20px;
    overflow: hidden;
    background: #0a0b18 url('assets/photos/screenshots/vice_city/Vice_City_05.jpg') center 30% / cover no-repeat;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.bp-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(8, 9, 20, 0.96), rgba(8, 9, 20, 0.45) 60%, rgba(8, 9, 20, 0.25));
}

.bp-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(255, 80, 197, 0.14), rgba(123, 47, 255, 0.10) 55%, transparent 75%);
    pointer-events: none;
}

.bp-hero-inner {
    position: relative;
    z-index: 1;
    padding: 3rem 2.5rem 2.75rem;
    max-width: 820px;
}

.bp-hero .blog-kicker { text-align: left; }
.bp-hero .blog-kicker::before, .bp-hero .blog-kicker::after { display: none; }

.bp-hero-title {
    margin: 0.75rem 0 1rem;
    font-size: clamp(1.7rem, 6vw, 3rem);
    line-height: 1.12;
    font-weight: 900;
    color: #fff;
}

.bp-grad {
    background: linear-gradient(135deg, var(--gta-pink), #c026d3);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.bp-hero-sub {
    margin: 0 0 1.75rem;
    color: #c3c9dc;
    font-size: 1.02rem;
    line-height: 1.65;
    max-width: 640px;
}

.bp-hero-sub strong { color: #fff; }

.bp-hero-ctas { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 0; }

.bp-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 48px;
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.95rem;
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.bp-btn--primary {
    background: linear-gradient(135deg, var(--gta-pink), #c026d3);
    color: #fff;
    box-shadow: 0 8px 24px rgba(255, 80, 197, 0.28);
}

.bp-btn--primary:hover { transform: translateY(-1px); box-shadow: 0 12px 30px rgba(255, 80, 197, 0.38); }

.bp-btn--ghost {
    background: rgba(10, 11, 24, 0.55);
    border-color: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.bp-btn--discord { background: #5865F2; color: #fff; }
.bp-btn--discord:hover { background: #4752c4; }

/* ------------------------------------------------------- popular strip */
.bp-popular { margin-bottom: 2.25rem; }

.bp-popular-head {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.bp-popular-label {
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    color: #ffb1e3;
    white-space: nowrap;
}

.bp-popular-label i { color: var(--gta-orange); margin-right: 0.35rem; }

.bp-popular-rule {
    flex-grow: 1;
    height: 2px;
    background: linear-gradient(90deg, rgba(255, 80, 197, 0.6), rgba(255, 80, 197, 0));
    border-radius: 2px;
}

.bp-pop-rail {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 0.5rem;
    scrollbar-width: none;
}

.bp-pop-rail::-webkit-scrollbar { display: none; }

.bp-pop-card {
    flex: 0 0 300px;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    background: rgba(13, 15, 30, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    transition: border-color 0.25s ease, transform 0.25s ease;
}

.bp-pop-card:hover { border-color: rgba(255, 80, 197, 0.45); transform: translateY(-3px); }

.bp-pop-rank {
    position: absolute;
    font-size: 2rem;
    font-weight: 900;
    line-height: 1;
    padding: 0.6rem 0.8rem;
    background: linear-gradient(135deg, var(--gta-pink), #c026d3);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    z-index: 2;
    text-shadow: none;
}

.bp-pop-card { position: relative; }

.bp-pop-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #090a16; }
.bp-pop-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

.bp-pop-body { display: block; padding: 0.9rem 1rem 1.1rem; }

.bp-pop-meta {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #9ba3be;
    margin-bottom: 0.4rem;
}

.bp-pop-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-weight: 800;
    font-size: 0.98rem;
    line-height: 1.4;
    color: #fff;
}

/* ------------------------------------------------------------- toolbar */
.bp-toolbar {
    position: sticky;
    top: 60px;
    z-index: 40;
    background: rgba(6, 7, 16, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 0.75rem 0;
    margin-bottom: 0.5rem;
}

.bp-controls { margin-bottom: 0; align-items: center; }

.bp-toolbar-tools {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-grow: 1;
    justify-content: flex-end;
}

.chip-count {
    font-size: 0.72rem;
    font-weight: 700;
    color: #9ba3be;
    background: rgba(255, 255, 255, 0.06);
    padding: 0.08rem 0.45rem;
    border-radius: 999px;
    margin-left: 0.3rem;
}

.blog-filter-btn { text-decoration: none; display: inline-flex; align-items: center; min-height: 40px; }

.bp-search-clear {
    position: absolute;
    right: 0.55rem;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.08);
    border: none;
    color: #c3c9dc;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.75rem;
    line-height: 1;
}

.bp-search-clear:hover { background: rgba(255, 80, 197, 0.35); color: #fff; }

.bp-sort-label { font-size: 0.82rem; font-weight: 700; color: #9ba3be; }

.bp-sort {
    background: rgba(6, 7, 16, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    color: #fff;
    font-size: 0.88rem;
    font-weight: 600;
    padding: 0.6rem 0.7rem;
    min-height: 42px;
    outline: none;
    cursor: pointer;
}

.bp-sort:focus { border-color: var(--gta-pink); }

/* ----------------------------------------------------------- meta line */
.bp-meta-line {
    color: #9ba3be;
    font-size: 0.85rem;
    margin: 0.75rem 0 1.5rem;
    min-height: 1.3em;
}

.bp-clear-filters {
    background: none;
    border: none;
    color: var(--gta-pink);
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    padding: 0.2rem 0.4rem;
}

.bp-clear-filters:hover { color: #fff; }

/* ------------------------------------------------- grid/card overrides */
.bp-page .blog-grid {
    grid-template-columns: repeat(auto-fill, minmax(min(340px, 100%), 1fr));
}

.bp-page .blog-card-media { height: auto; aspect-ratio: 16 / 9; }

.bp-page .blog-card-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Category badge variants (spec 04 §6) — base pill is .blog-card-badge */
.bp-badge--guides { background: var(--bp-guides); color: #fff; border-color: transparent; }
.bp-badge--gta-6-updates { background: var(--bp-updates); color: #14100a; border-color: transparent; }
.bp-badge--qa { background: var(--bp-qa); color: #06121a; border-color: transparent; }
.bp-badge--deep-dives { background: rgba(24, 8, 40, 0.85); color: #d9a8ff; border-color: rgba(181, 55, 242, 0.6); }

/* ------------------------------------------------------------ load more */
.bp-loadmore { margin-top: 2.75rem; text-align: center; }

.bp-progress-text { color: #9ba3be; font-size: 0.85rem; margin: 0 0 0.6rem; }

.bp-progress {
    height: 3px;
    max-width: 520px;
    margin: 0 auto 1.25rem;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    overflow: hidden;
}

.bp-progress-bar {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--gta-pink), #c026d3);
    border-radius: 3px;
    transition: width 0.4s ease;
}

.bp-loadmore-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 52px;
    padding: 0.85rem 2.5rem;
    border: none;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--gta-pink), #c026d3);
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(255, 80, 197, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.bp-loadmore-btn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 12px 30px rgba(255, 80, 197, 0.35); }
.bp-loadmore-btn:disabled { opacity: 0.65; cursor: wait; }
.bp-loadmore-end { background: rgba(88, 101, 242, 0.9); box-shadow: 0 8px 24px rgba(88, 101, 242, 0.25); }

/* --------------------------------------------------------------- states */
.bp-skeleton {
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(13, 15, 30, 0.55);
    padding-bottom: 1.2rem;
    overflow: hidden;
    animation: bp-pulse 1.4s ease-in-out infinite;
}

.bp-sk-media { height: 0; padding-top: 56.25%; background: rgba(255, 255, 255, 0.05); margin-bottom: 1rem; }
.bp-sk-line { height: 12px; border-radius: 6px; background: rgba(255, 255, 255, 0.06); margin: 0 1.2rem 0.7rem; }
.bp-sk-line--short { width: 45%; }

@keyframes bp-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.55; } }

.bp-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 1.5rem;
    background: rgba(13, 15, 30, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 16px;
}

.bp-state-icon { font-size: 2.4rem; color: var(--gta-pink); margin-bottom: 1rem; }
.bp-state-title { color: #fff; font-size: 1.35rem; margin: 0 0 0.6rem; }
.bp-state-copy { color: #9ba3be; margin: 0 0 1.6rem; }

/* -------------------------------------------------------------- footer */
.bp-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    padding: 2.5rem 1.5rem 2.75rem;
    text-align: center;
    background: rgba(6, 7, 16, 0.6);
}

.bp-footer-line { color: #c3c9dc; font-weight: 700; margin: 0 0 1.25rem; }
.bp-footer-ctas { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.75rem; margin: 0 0 1.5rem; }
.bp-footer-copy { color: #6f7690; font-size: 0.8rem; margin: 0; }

/* ------------------------------------------------------ noscript block */
.bp-noscript {
    margin-top: 2.5rem;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    background: rgba(13, 15, 30, 0.7);
}

.bp-noscript h2 { color: #fff; margin-top: 0; }
.bp-noscript ul { columns: 2; line-height: 1.9; padding-left: 1.2rem; }
.bp-noscript a { color: #ff9ee2; }

/* -------------------------------------------------- category archives */
.bp-crumb { color: #9ba3be; font-size: 0.85rem; margin: 1.75rem 0 1rem; }
.bp-crumb a { color: #c3c9dc; text-decoration: none; font-weight: 600; }
.bp-crumb a:hover { color: #fff; }

.bp-archive-head { margin-bottom: 2.25rem; max-width: 860px; }
.bp-archive-head .blog-kicker { text-align: left; }
.bp-archive-head .blog-kicker::before, .bp-archive-head .blog-kicker::after { display: none; }

.bp-archive-title {
    color: #fff;
    font-size: clamp(1.8rem, 5vw, 2.7rem);
    font-weight: 900;
    margin: 0.6rem 0 0.9rem;
    line-height: 1.15;
}

.bp-archive-desc { color: #c3c9dc; line-height: 1.7; margin: 0 0 0.9rem; font-size: 1rem; }
.bp-archive-count { color: #9ba3be; font-size: 0.88rem; font-weight: 700; margin: 0; }

.bp-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 3rem;
    color: #9ba3be;
    font-weight: 600;
}

.bp-page-link {
    color: #fff;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 0.6rem 1.2rem;
    border-radius: 999px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.bp-page-link:hover { border-color: rgba(255, 80, 197, 0.6); }

.bp-archive-all { margin-top: 2rem; }
.bp-archive-all a { color: #ff9ee2; text-decoration: none; font-weight: 700; }
.bp-archive-all a:hover { color: #fff; }

/* --------------------------------------------------------------- mobile */
@media (max-width: 900px) {
    .bp-controls { flex-direction: column; align-items: stretch; }
    .bp-toolbar-tools { justify-content: flex-start; flex-wrap: wrap; }
    .bp-toolbar-tools .blog-search-box { flex-grow: 1; max-width: none; }
    .bp-hero-inner { padding: 2.25rem 1.5rem 2rem; }
    .bp-hero-ctas .bp-btn { flex-grow: 1; justify-content: center; }
}

@media (max-width: 768px) {
    .bp-wrap { padding: 0 1rem 3rem; }
    .bp-page .blog-grid { grid-template-columns: 1fr; }
    .bp-pop-card { flex-basis: 78vw; }
    .bp-topbar { position: static; }
    .bp-toolbar { top: 0; }
    .bp-noscript ul { columns: 1; }
}

@media (max-width: 480px) {
    .bp-topbtn span { display: none; }
    .bp-topbtn { padding: 0.5rem 0.65rem; }
    .bp-hero { margin-top: 1rem; }
}

a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible {
    outline: 2px solid var(--bp-qa);
    outline-offset: 2px;
}
