/*
Theme Name: Kadence Child - The Wayland Post
Template: kadence
Description: Custom newspaper homepage for The Wayland Post
Version: 1.1
*/

/* ===== BASE RESET & TYPOGRAPHY ===== */
body.home {
    font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    color: #292929;
    background: #fff;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.home *,
body.home *::before,
body.home *::after {
    box-sizing: border-box;
}

body.home a {
    color: inherit;
    text-decoration: none;
    transition: color 0.15s ease;
}

/* Hide Kadence header/footer on homepage */
body.home .site-header,
body.home .site-footer,
body.home .site-main > .entry-content-wrap,
body.home #wrapper { display: none !important; }
body.home { margin: 0; padding: 0; }

/* ===== HEADER ===== */
.twp-header {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

.twp-utility-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.8rem;
    color: #777;
    letter-spacing: 0.01em;
}

.twp-utility-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.twp-donate-link {
    color: #c0392b;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.72rem;
    letter-spacing: 0.08em;
}

.twp-donate-link:hover { color: #922b21; }

.twp-social-icons {
    display: flex;
    gap: 10px;
}

.twp-social-icons a {
    color: #999;
    font-size: 0.95rem;
}

.twp-social-icons a:hover { color: #333; }

/* ===== MASTHEAD ===== */
.twp-masthead {
    text-align: center;
    padding: 18px 0 16px;
    border-top: 1px solid #e8e8e8;
    border-bottom: 1px solid #e8e8e8;
}

.twp-logo {
    max-width: 520px;
    width: 100%;
    height: auto;
    display: inline-block;
}

/* ===== NAV ===== */
.twp-main-nav {
    border-bottom: 3px solid #1a1a1a;
    padding: 0;
}

.twp-main-nav ul {
    display: flex;
    justify-content: center;
    gap: 0;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.twp-main-nav li {
    border-right: 1px solid #e0e0e0;
}

.twp-main-nav li:last-child { border-right: none; }

.twp-main-nav a {
    display: block;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #292929;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 10px 18px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    transition: background 0.15s, color 0.15s;
}

.twp-main-nav a:hover {
    background: #f5f5f0;
    color: #c0392b;
}

/* ===== HOMEPAGE BODY ===== */
.twp-homepage {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== HERO ===== */
.twp-hero {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 0;
    padding: 28px 0 32px;
    border-bottom: 1px solid #ddd;
}

.twp-hero-main {
    padding-right: 32px;
    border-right: 1px solid #e0e0e0;
}

.twp-hero-category {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #c0392b;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.twp-hero-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2.6rem;
    font-weight: 900;
    line-height: 1.08;
    margin: 10px 0 14px;
    color: #1a1a1a;
    letter-spacing: -0.02em;
}

.twp-hero-title a:hover { color: #333; }

.twp-hero-excerpt {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #555;
    margin-bottom: 8px;
}

.twp-hero-meta {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.78rem;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.twp-hero-meta strong {
    color: #555;
    font-weight: 600;
}

.twp-hero-image {
    margin-top: 16px;
    overflow: hidden;
}

.twp-hero-image img {
    width: 100%;
    height: auto;
    display: block;
}

.twp-hero-image-placeholder {
    background: #f0efe8;
    min-height: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #bbb;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

/* Trending sidebar */
.twp-hero-sidebar {
    padding-left: 28px;
}

.twp-trending-item {
    padding: 14px 0;
    border-bottom: 1px solid #e8e8e8;
}

.twp-trending-item:last-child { border-bottom: none; }

.twp-trending-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 6px 0 4px;
}

.twp-trending-title a:hover { color: #555; }

.twp-trending-meta {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.72rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* ===== VIEW BADGE ===== */
.twp-view-badge {
    display: inline-block;
    background: #1a1a1a;
    color: #fff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 1px;
    line-height: 1.4;
    letter-spacing: 0.02em;
    text-transform: lowercase;
}

/* ===== SECTION ===== */
.twp-section {
    margin: 0;
    padding: 36px 0;
    border-bottom: 1px solid #ddd;
}

.twp-section-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.65rem;
    font-weight: 900;
    margin: 0;
    padding-bottom: 10px;
    border-bottom: 3px solid #1a1a1a;
    color: #1a1a1a;
    letter-spacing: -0.01em;
}

.twp-section-divider {
    display: none;
}

/* ===== 3-COLUMN CARDS ===== */
.twp-cards-3col {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin-top: 20px;
}

.twp-card {
    padding: 0 24px 20px 0;
    border-right: 1px solid #e8e8e8;
}

.twp-card:last-child {
    border-right: none;
    padding-right: 0;
}

.twp-card:first-child { padding-left: 0; }
.twp-card:nth-child(2) { padding-left: 24px; }
.twp-card:nth-child(3) { padding-left: 24px; }

.twp-card-category {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #c0392b;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 8px;
}

.twp-card-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.25;
    margin: 6px 0 8px;
    color: #1a1a1a;
}

.twp-card-title a:hover { color: #555; }

.twp-card-meta {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.72rem;
    color: #aaa;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.twp-card-excerpt {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #555;
}

.twp-card-readmore {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.75rem;
    color: #c0392b;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    display: inline-block;
    margin-top: 8px;
}

.twp-card-readmore:hover { color: #922b21; }

/* ===== SECTION WITH SIDEBAR ===== */
.twp-with-sidebar {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 0;
    margin-top: 20px;
}

.twp-with-sidebar > div:first-child {
    padding-right: 32px;
    border-right: 1px solid #e8e8e8;
}

.twp-with-sidebar > div:last-child {
    padding-left: 28px;
}

/* ===== LIST ITEMS ===== */
.twp-list-item {
    padding: 14px 0;
    border-bottom: 1px solid #e8e8e8;
}

.twp-list-item:first-child { padding-top: 0; }

.twp-list-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 5px 0 4px;
    line-height: 1.28;
}

.twp-list-title a:hover { color: #555; }

.twp-list-excerpt {
    font-size: 0.88rem;
    color: #666;
    line-height: 1.55;
}

.twp-list-meta {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.72rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* ===== MOST READ ===== */
.twp-most-read {
    background: #f9f8f4;
    padding: 20px 22px;
    border: 1px solid #e8e8e8;
}

.twp-most-read h3 {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.75rem;
    font-weight: 800;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 2px solid #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #1a1a1a;
}

.twp-most-read-item {
    display: flex;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid #e2e1da;
    align-items: flex-start;
}

.twp-most-read-item:last-child { border-bottom: none; }

.twp-most-read-num {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.4rem;
    font-weight: 900;
    color: #d5d3ca;
    min-width: 20px;
    line-height: 1.1;
}

.twp-most-read-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.3;
}

.twp-most-read-title a:hover { color: #555; }

/* ===== HEADLINE LIST ===== */
.twp-headline-item {
    padding: 12px 0;
    border-bottom: 1px solid #e8e8e8;
}

.twp-headline-item:first-child { padding-top: 0; }

.twp-headline-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 2px;
}

.twp-headline-title a:hover { color: #555; }

.twp-headline-meta {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.72rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* ===== AD PLACEHOLDER ===== */
.twp-ad {
    border: 1px solid #e2e1da;
    padding: 50px 20px;
    text-align: center;
    color: #c0bdb2;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #faf9f5;
}

.twp-ad + .twp-ad { margin-top: 18px; }

/* ===== PUBLIC SAFETY TABLE ===== */
.twp-safety-table {
    width: 100%;
    border-collapse: collapse;
}

.twp-safety-table tr { border-bottom: 1px solid #e8e8e8; }

.twp-safety-table td {
    padding: 12px 16px 12px 0;
    vertical-align: top;
    font-size: 0.88rem;
    line-height: 1.55;
    color: #555;
}

.twp-safety-date {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    white-space: nowrap;
    color: #999;
    font-size: 0.75rem;
    min-width: 75px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.twp-sidebar-link {
    padding: 12px 0;
    border-bottom: 1px solid #e8e8e8;
}

.twp-sidebar-link:first-child { padding-top: 0; }

.twp-sidebar-link-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
    font-size: 0.92rem;
    line-height: 1.3;
}

.twp-sidebar-link-title a:hover { color: #555; }

.twp-sidebar-link-views {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.7rem;
    color: #aaa;
}

/* ===== OBITUARIES ===== */
.twp-obit-name {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.02rem;
    font-weight: 700;
    margin-bottom: 3px;
}

.twp-obit-name a:hover { color: #555; }

.twp-obit-detail {
    font-size: 0.85rem;
    color: #777;
    line-height: 1.55;
}

/* ===== FOOTER ===== */
.twp-footer {
    border-top: 3px solid #1a1a1a;
    background: #f9f8f4;
    padding: 36px 0 30px;
    margin-top: 0;
}

.twp-footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

.twp-footer-brand h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.25rem;
    font-weight: 900;
    margin: 0 0 6px;
}

.twp-footer-brand p {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #999;
    font-size: 0.82rem;
    line-height: 1.5;
    margin: 2px 0;
}

.twp-footer-social {
    display: flex;
    gap: 12px;
    margin-top: 10px;
}

.twp-footer-social a {
    color: #888;
    font-size: 1rem;
}

.twp-footer-social a:hover { color: #333; }

.twp-footer-col h4 {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.72rem;
    font-weight: 800;
    margin: 0 0 12px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #555;
}

.twp-footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.twp-footer-col li {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 0.82rem;
    color: #999;
    line-height: 1.9;
}

.twp-footer-col a:hover { color: #333; }

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
    .twp-hero {
        grid-template-columns: 1fr;
    }
    .twp-hero-main {
        padding-right: 0;
        border-right: none;
    }
    .twp-hero-sidebar {
        padding-left: 0;
        padding-top: 20px;
        border-top: 1px solid #e8e8e8;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0 24px;
    }
    .twp-with-sidebar {
        grid-template-columns: 1fr;
    }
    .twp-with-sidebar > div:first-child {
        padding-right: 0;
        border-right: none;
    }
    .twp-with-sidebar > div:last-child {
        padding-left: 0;
        padding-top: 20px;
    }
}

@media (max-width: 720px) {
    .twp-cards-3col {
        grid-template-columns: 1fr;
    }
    .twp-card {
        padding: 16px 0;
        border-right: none;
        border-bottom: 1px solid #e8e8e8;
    }
    .twp-card:nth-child(2),
    .twp-card:nth-child(3) { padding-left: 0; }
    .twp-hero-title { font-size: 2rem; }
    .twp-section-title { font-size: 1.3rem; }
    .twp-logo { max-width: 320px; }
    .twp-hero-sidebar {
        grid-template-columns: 1fr;
    }
    .twp-footer-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    .twp-main-nav a {
        font-size: 0.72rem;
        padding: 8px 10px;
    }
    .twp-utility-bar {
        flex-direction: column;
        gap: 4px;
        text-align: center;
    }
}
