/*
Theme Name: THG Dark
Description: Dark three-column layout inspired by stfn.news
Version: 1.0
*/

/* ===== RESET & BASE ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg-primary: #000000;
    --bg-secondary: #0a0a0a;
    --bg-card: #111111;
    --text-primary: #ffffff;
    --text-secondary: #aaaaaa;
    --accent-gold: #EDB500;
    --accent-red: #e52e2e;
    --accent-blue: #0088cc;
    --btn-gradient-start: #2b5cce;
    --btn-gradient-end: #1a3a8a;
    --border-color: #222222;
    --font-primary: 'Open Sans', sans-serif;
    --font-heading: 'Roboto', sans-serif;
    --font-accent: 'Gantari', sans-serif;
    --font-serif: 'PT Serif', serif;
}

html, body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 14px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--accent-blue);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ===== HEADER ===== */
.site-header {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-logo {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 900;
    letter-spacing: -0.5px;
    color: var(--text-primary);
    text-transform: uppercase;
}

.site-logo a {
    color: inherit;
}

.site-nav {
    display: flex;
    gap: 20px;
    align-items: center;
}

.site-nav a {
    font-family: var(--font-primary);
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 8px 0;
}

.site-nav a:hover {
    color: var(--accent-blue);
}

/* ===== CONTAINER ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* ===== THREE COLUMN LAYOUT ===== */
.three-col-wrap {
    display: flex;
    gap: 30px;
    padding: 30px 0;
    align-items: flex-start;
}

.col-left {
    flex: 0 0 23%;
    max-width: 23%;
    position: sticky;
    top: 80px;
}

.col-center {
    flex: 0 0 50%;
    max-width: 50%;
}

.col-right {
    flex: 0 0 23%;
    max-width: 23%;
    position: sticky;
    top: 80px;
}

/* ===== SIDEBAR WIDGETS ===== */
.sidebar-widget {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 2px;
}

.sidebar-widget h3 {
    font-family: var(--font-heading);
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-red);
    text-transform: uppercase;
}

.sidebar-widget ul {
    list-style: none;
}

.sidebar-widget ul li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 13px;
}

.sidebar-widget ul li:last-child {
    border-bottom: none;
}

.sidebar-widget ul li a:hover {
    color: var(--accent-blue);
}

/* ===== POST CARDS ===== */
.alm-listing {
    list-style: none;
}

.alm-listing .alm-item,
.post-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    margin-bottom: 20px;
    border-radius: 2px;
    overflow: hidden;
    transition: border-color 0.2s ease;
}

.post-card:hover {
    border-color: #333;
}

.post-card .post-thumb {
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #0a0a0a;
}

.post-card .post-thumb img,
.post-card .post-thumb video,
.post-card .post-thumb iframe {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-card .post-content {
    padding: 18px;
}

.post-card .post-category {
    display: inline-block;
    font-family: var(--font-accent);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-gold);
    margin-bottom: 8px;
}

.post-card .post-title {
    font-family: var(--font-heading);
    font-size: 21px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.post-card .post-title a {
    color: inherit;
}

.post-card .post-title a:hover {
    color: var(--accent-blue);
}

.post-card .post-meta {
    font-size: 11px;
    color: var(--text-secondary);
    font-family: var(--font-primary);
}

.post-card .post-meta .author {
    color: var(--text-primary);
    font-weight: 600;
}

.post-card .post-meta .date {
    margin-left: 8px;
}

.post-card .post-excerpt {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-top: 10px;
}

/* ===== SMALL POST CARD (sidebar) ===== */
.post-card-small {
    display: flex;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.post-card-small:last-child {
    border-bottom: none;
}

.post-card-small .thumb-small {
    flex: 0 0 80px;
    height: 60px;
    overflow: hidden;
    border-radius: 2px;
    background: #0a0a0a;
}

.post-card-small .thumb-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-card-small .post-info {
    flex: 1;
    min-width: 0;
}

.post-card-small .post-info h4 {
    font-family: var(--font-heading);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 4px;
}

.post-card-small .post-info .date {
    font-size: 11px;
    color: var(--text-secondary);
}

/* ===== CTA BUTTON ===== */
.cta-button {
    display: block;
    width: 100%;
    padding: 16px 20px;
    background: linear-gradient(135deg, var(--btn-gradient-start), var(--btn-gradient-end));
    color: #ffffff;
    font-family: var(--font-accent);
    font-size: 18px;
    font-weight: 700;
    text-align: center;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: opacity 0.2s ease;
    text-decoration: none;
}

.cta-button:hover {
    opacity: 0.9;
    color: #ffffff;
}

.cta-button-wrap {
    margin-bottom: 20px;
}

/* ===== ALM LOAD MORE ===== */
.alm-btn-wrap {
    text-align: center;
    margin: 20px 0;
}

.alm-btn-wrap .alm-load-more-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-family: var(--font-accent);
    font-size: 14px;
    font-weight: 600;
    padding: 12px 30px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.alm-btn-wrap .alm-load-more-btn:hover {
    background: var(--border-color);
}

/* ===== FOOTER ===== */
.site-footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 30px 0;
    margin-top: 40px;
    text-align: center;
    font-size: 12px;
    color: var(--text-secondary);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .three-col-wrap {
        flex-wrap: wrap;
    }
    .col-left {
        flex: 0 0 100%;
        max-width: 100%;
        position: static;
        order: 2;
    }
    .col-center {
        flex: 0 0 100%;
        max-width: 100%;
        order: 1;
    }
    .col-right {
        flex: 0 0 100%;
        max-width: 100%;
        position: static;
        order: 3;
    }
}

@media (max-width: 768px) {
    .site-header .container {
        flex-direction: column;
        gap: 10px;
    }
    .site-nav {
        flex-wrap: wrap;
        justify-content: center;
    }
    .post-card .post-title {
        font-size: 18px;
    }
}

/* ===== WP CORE OVERRIDES ===== */
.wp-block-post-content,
.entry-content {
    color: var(--text-primary);
}

body.page, body.single, body.archive, body.home {
    background: var(--bg-primary);
}

.ajax-load-more-wrap {
    margin: 0;
    padding: 0;
}

.ajax-load-more-wrap .alm-listing {
    margin: 0;
    padding: 0;
}

.alm-loading {
    text-align: center;
    padding: 20px;
}
