/*
Theme Name: Speeed
Theme URI: https://nnn.ng
Author: Speeed Team
Author URI: https://nnn.ng
Description: A lightning-fast, SEO-optimized, mobile-first WordPress newspaper theme. Built for speed, readability, and accessibility with a clean, modern design. Scores 95+ on Google PageSpeed Insights.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: speeed
Tags: news, blog, newspaper, one-column, two-columns, right-sidebar, left-sidebar, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, block-styles, editor-style, accessibility-ready, fast, seo-friendly, mobile-first, minimalist

Speeed WordPress Theme, (C) 2026 Speeed Team.
Speeed is distributed under the terms of the GNU GPL v2 or later.
*/

/* ==========================================================================
   CSS Custom Properties (Design Tokens)
   All design tokens are defined here and controlled via the Customizer.
   ========================================================================== */

:root {
    /* --- Colors --- */
    --color-primary: #c62828;
    --color-primary-hover: #b71c1c;
    --color-accent: #1565c0;
    --color-accent-hover: #0d47a1;
    --color-text: #1a1a1a;
    --color-text-light: #555555;
    --color-text-muted: #767676;
    --color-bg: #ffffff;
    --color-bg-alt: #f5f5f5;
    --color-bg-dark: #1a1a1a;
    --color-border: #e0e0e0;
    --color-border-light: #eeeeee;
    --color-success: #2e7d32;
    --color-warning: #f57f17;
    --color-error: #c62828;

    /* --- Typography --- */
    --font-heading: Georgia, 'Times New Roman', 'Noto Serif', 'Liberation Serif', serif;
    --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', Consolas, Monaco, monospace;

    /* Fluid type scale — min at 320px, max at 1280px */
    --text-xs: clamp(0.6875rem, 0.65rem + 0.18vw, 0.8125rem);
    --text-sm: clamp(0.8125rem, 0.76rem + 0.25vw, 1rem);
    --text-base: clamp(1rem, 0.94rem + 0.29vw, 1.1875rem);
    --text-md: clamp(1.125rem, 1.04rem + 0.42vw, 1.4375rem);
    --text-lg: clamp(1.3125rem, 1.18rem + 0.63vw, 1.75rem);
    --text-xl: clamp(1.625rem, 1.41rem + 1.07vw, 2.375rem);
    --text-2xl: clamp(1.9375rem, 1.58rem + 1.79vw, 3.125rem);
    --text-3xl: clamp(2.375rem, 1.83rem + 2.72vw, 4.1875rem);

    /* --- Spacing --- */
    --space-xs: clamp(0.25rem, 0.21rem + 0.18vw, 0.375rem);
    --space-sm: clamp(0.5rem, 0.43rem + 0.36vw, 0.75rem);
    --space-md: clamp(0.75rem, 0.64rem + 0.54vw, 1.125rem);
    --space-lg: clamp(1rem, 0.82rem + 0.89vw, 1.625rem);
    --space-xl: clamp(1.5rem, 1.18rem + 1.61vw, 2.625rem);
    --space-2xl: clamp(2rem, 1.5rem + 2.5vw, 3.75rem);
    --space-3xl: clamp(3rem, 2.14rem + 4.29vw, 6rem);

    /* --- Layout --- */
    --content-width: 1280px;
    --content-narrow: 780px;
    --sidebar-width: 340px;
    --grid-gap: var(--space-lg);
    --border-radius: 6px;
    --border-radius-lg: 12px;

    /* --- Shadows --- */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);

    /* --- Transitions --- */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms ease;

    /* --- Dark mode support --- */
    --color-scheme: light;
}

/* ==========================================================================
   Reset & Base
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--color-text);
    background-color: var(--color-bg);
    overflow-x: hidden;
    color-scheme: var(--color-scheme);
}

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.25;
    color: var(--color-text);
    margin-bottom: var(--space-sm);
}

h1 { font-size: var(--text-2xl); }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); }
h4 { font-size: var(--text-md); }
h5 { font-size: var(--text-base); }
h6 { font-size: var(--text-sm); }

p {
    margin-bottom: var(--space-md);
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-primary-hover);
}

ul, ol {
    margin-bottom: var(--space-md);
    padding-left: var(--space-lg);
}

li {
    margin-bottom: var(--space-xs);
}

blockquote {
    border-left: 4px solid var(--color-primary);
    margin: var(--space-lg) 0;
    padding: var(--space-md) var(--space-lg);
    background: var(--color-bg-alt);
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
    font-style: italic;
    color: var(--color-text-light);
}

blockquote cite {
    display: block;
    margin-top: var(--space-sm);
    font-size: var(--text-sm);
    font-style: normal;
    color: var(--color-text-muted);
}

code, kbd, pre, samp {
    font-family: var(--font-mono);
    font-size: 0.9em;
}

pre {
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--space-md);
    overflow-x: auto;
    margin-bottom: var(--space-md);
}

code {
    background: var(--color-bg-alt);
    padding: 0.15em 0.4em;
    border-radius: 3px;
}

pre code {
    background: none;
    padding: 0;
}

hr {
    border: 0;
    border-top: 1px solid var(--color-border);
    margin: var(--space-xl) 0;
}

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

figure {
    margin: var(--space-lg) 0;
}

figcaption {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
    text-align: center;
    margin-top: var(--space-xs);
}

/* ==========================================================================
   Accessibility — Screen Reader
   ========================================================================== */

.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: var(--color-bg);
    border-radius: var(--border-radius);
    box-shadow: 0 0 0 3px var(--color-accent);
    clip: auto !important;
    clip-path: none;
    color: var(--color-text);
    display: block;
    font-size: var(--text-base);
    font-weight: 700;
    height: auto;
    left: var(--space-sm);
    line-height: normal;
    padding: var(--space-md) var(--space-lg);
    text-decoration: none;
    top: var(--space-sm);
    width: auto;
    z-index: 100000;
}

.skip-link {
    position: absolute;
    top: -100%;
    left: var(--space-sm);
    z-index: 100001;
}

.skip-link:focus {
    top: var(--space-sm);
}

/* ==========================================================================
   Layout — Container & Grid
   ========================================================================== */

.container {
    width: 100%;
    max-width: var(--content-width);
    margin-inline: auto;
    padding-inline: var(--space-md);
}

.content-area {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--grid-gap);
    padding-block: var(--space-xl);
}

@media (min-width: 768px) {
    .has-sidebar .content-area {
        grid-template-columns: 1fr var(--sidebar-width);
    }

    .has-sidebar-left .content-area {
        grid-template-columns: var(--sidebar-width) 1fr;
    }
}

.site-main {
    min-width: 0; /* Prevent grid blowout */
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    padding-block: var(--space-sm);
    min-height: 60px;
}

.site-branding {
    flex-shrink: 0;
}

.site-title {
    font-family: var(--font-heading);
    font-size: var(--text-lg);
    font-weight: 900;
    margin: 0;
    line-height: 1.2;
}

.site-title a {
    color: var(--color-text);
    text-decoration: none;
}

.site-title a:hover {
    color: var(--color-primary);
}

.site-description {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    margin: 0;
    line-height: 1.3;
}

.custom-logo-link {
    display: block;
    line-height: 1;
}

.custom-logo {
    max-height: 50px;
    width: auto;
    height: auto;
}

/* --- Navigation --- */

.main-navigation {
    font-size: var(--text-sm);
    font-weight: 600;
}

.main-navigation ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}

.main-navigation li {
    margin: 0;
    position: relative;
}

.main-navigation a {
    display: block;
    padding: var(--space-xs) var(--space-sm);
    color: var(--color-text);
    border-radius: var(--border-radius);
    white-space: nowrap;
}

.main-navigation a:hover,
.main-navigation .current-menu-item > a {
    color: var(--color-primary);
    background: var(--color-bg-alt);
}

/* Dropdown */
.main-navigation .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    min-width: 200px;
    padding: var(--space-xs);
    z-index: 100;
    flex-direction: column;
}

.main-navigation li:hover > .sub-menu,
.main-navigation li:focus-within > .sub-menu {
    display: flex;
}

.main-navigation .sub-menu .sub-menu {
    top: calc(-1 * var(--space-xs));
    left: 100%;
}

/* --- Mobile Menu Toggle --- */

.menu-toggle {
    display: none;
    background: none;
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--space-xs) var(--space-sm);
    cursor: pointer;
    font-size: var(--text-lg);
    line-height: 1;
    color: var(--color-text);
}

.menu-toggle[aria-expanded="true"] {
    background: var(--color-bg-alt);
    border-color: var(--color-primary);
}

@media (max-width: 767px) {
    .menu-toggle {
        display: block;
    }

    .main-navigation {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--color-bg);
        border-bottom: 2px solid var(--color-border);
        padding: var(--space-md);
        box-shadow: var(--shadow-md);
    }

    .main-navigation.toggled {
        display: block;
    }

    .main-navigation ul {
        flex-direction: column;
        align-items: stretch;
    }

    .main-navigation .sub-menu {
        position: static;
        box-shadow: none;
        border: none;
        padding-left: var(--space-md);
        display: none;
    }

    .main-navigation .sub-menu.toggled {
        display: flex;
    }

    .main-navigation li.menu-item-has-children > a::after {
        content: ' +';
        font-size: var(--text-xs);
    }
}

/* --- Search Form --- */

.search-form {
    display: flex;
    gap: 0;
    max-width: 400px;
}

.search-form label {
    flex: 1;
}

.search-form input[type="search"] {
    width: 100%;
    border: 1px solid var(--color-border);
    border-right: none;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
    padding: var(--space-sm) var(--space-md);
    font-family: inherit;
    font-size: var(--text-sm);
    background: var(--color-bg);
}

.search-form input[type="search"]:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: inset 0 0 0 1px var(--color-primary);
}

.search-form button {
    border: 1px solid var(--color-primary);
    background: var(--color-primary);
    color: #fff;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
    padding: var(--space-sm) var(--space-md);
    cursor: pointer;
    font-family: inherit;
    font-size: var(--text-sm);
    font-weight: 600;
    transition: background var(--transition-fast);
}

.search-form button:hover {
    background: var(--color-primary-hover);
}

/* ==========================================================================
   Breaking News Bar
   ========================================================================== */

.breaking-news {
    background: var(--color-primary);
    color: #fff;
    padding: var(--space-xs) 0;
    overflow: hidden;
}

.breaking-news-inner {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.breaking-news-label {
    font-weight: 700;
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 10px;
    border-radius: 3px;
    flex-shrink: 0;
    white-space: nowrap;
}

.breaking-news-content {
    white-space: nowrap;
    overflow: hidden;
}

.breaking-news-content a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: var(--text-sm);
}

.breaking-news-content a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   Hero / Featured Posts
   ========================================================================== */

.featured-posts {
    padding-block: var(--space-xl);
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
}

.featured-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--grid-gap);
}

@media (min-width: 600px) {
    .featured-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 1024px) {
    .featured-grid {
        grid-template-columns: 2fr 1fr 1fr;
    }

    .featured-grid .featured-post:first-child {
        grid-row: span 2;
    }
}

.featured-post {
    position: relative;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    background: var(--color-bg);
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.featured-post:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.featured-post-image {
    aspect-ratio: 16/10;
    overflow: hidden;
    background: var(--color-bg-alt);
}

.featured-post:first-child .featured-post-image {
    aspect-ratio: 16/9;
}

.featured-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.featured-post:hover .featured-post-image img {
    transform: scale(1.03);
}

.featured-post-content {
    padding: var(--space-md);
}

.featured-post .entry-category {
    display: inline-block;
    font-size: var(--text-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-primary);
    margin-bottom: var(--space-xs);
}

.featured-post .entry-title {
    font-size: var(--text-md);
    margin: 0 0 var(--space-xs);
    line-height: 1.3;
}

.featured-post:first-child .entry-title {
    font-size: var(--text-xl);
}

.featured-post .entry-title a {
    color: var(--color-text);
}

.featured-post .entry-title a:hover {
    color: var(--color-primary);
}

.featured-post .entry-meta {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

/* ==========================================================================
   Post Cards (Grid Layout)
   ========================================================================== */

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
    gap: var(--grid-gap);
}

.post-card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.post-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.post-card-image {
    aspect-ratio: 16/10;
    overflow: hidden;
    background: var(--color-bg-alt);
}

.post-card-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.post-card:hover .post-card-image img {
    transform: scale(1.03);
}

.post-card-body {
    padding: var(--space-md);
}

.post-card .entry-category {
    display: inline-block;
    font-size: var(--text-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-primary);
    margin-bottom: var(--space-xs);
}

.post-card .entry-title {
    font-size: var(--text-md);
    line-height: 1.3;
    margin: 0 0 var(--space-xs);
}

.post-card .entry-title a {
    color: var(--color-text);
}

.post-card .entry-title a:hover {
    color: var(--color-primary);
}

.post-card .entry-excerpt {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    line-height: 1.6;
    margin: 0;
}

.post-card .entry-meta {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    margin-top: var(--space-sm);
}

/* ==========================================================================
   Single Post
   ========================================================================== */

.single-post .entry-header {
    margin-bottom: var(--space-xl);
    text-align: center;
}

.single-post .entry-title {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-sm);
}

.single-post .entry-meta {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-sm);
}

.single-post .entry-meta > * {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}

.entry-meta a {
    color: var(--color-text-muted);
    font-weight: 600;
}

.entry-meta a:hover {
    color: var(--color-primary);
}

.entry-featured-image {
    margin-bottom: var(--space-xl);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
}

.entry-featured-image img {
    width: 100%;
    height: auto;
}

.entry-content {
    font-size: var(--text-base);
    line-height: 1.8;
    color: var(--color-text);
}

/* Gutenberg block spacing */
.entry-content > *,
.wp-block-post-content > * {
    max-width: var(--content-narrow);
    margin-inline: auto;
}

.entry-content > .alignwide,
.wp-block-post-content > .alignwide {
    max-width: calc(var(--content-width) - 2 * var(--space-md));
}

.entry-content > .alignfull,
.wp-block-post-content > .alignfull {
    max-width: none;
    margin-inline: calc(-1 * var(--space-md));
}

.entry-content > *:first-child {
    margin-top: 0;
}

.entry-content > *:last-child {
    margin-bottom: 0;
}

/* --- Article Tags & Categories --- */

.entry-footer {
    margin-top: var(--space-xl);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--color-border);
}

.entry-tags,
.entry-categories-list {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--space-xs);
    font-size: var(--text-sm);
}

.entry-tags-label,
.entry-categories-label {
    font-weight: 700;
    color: var(--color-text);
    margin-right: var(--space-xs);
}

.entry-tags a,
.entry-categories-list a {
    display: inline-block;
    padding: 2px 10px;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    color: var(--color-text-light);
    font-weight: 500;
    transition: all var(--transition-fast);
}

.entry-tags a:hover,
.entry-categories-list a:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

/* --- Author Box --- */

.author-box {
    display: flex;
    gap: var(--space-md);
    margin-top: var(--space-xl);
    padding: var(--space-lg);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    align-items: center;
}

.author-box-avatar {
    flex-shrink: 0;
}

.author-box-avatar img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
}

.author-box-name {
    font-family: var(--font-heading);
    font-size: var(--text-md);
    margin-bottom: var(--space-xs);
}

.author-box-bio {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    margin: 0;
}

/* --- Related Posts --- */

.related-posts {
    margin-top: var(--space-2xl);
}

.related-posts-title {
    font-size: var(--text-lg);
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-sm);
    border-bottom: 3px solid var(--color-primary);
    display: inline-block;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr));
    gap: var(--grid-gap);
}

/* --- Post Navigation --- */

.post-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: var(--space-xl);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--color-border);
    gap: var(--space-md);
}

.post-navigation .nav-previous,
.post-navigation .nav-next {
    flex: 1;
    max-width: 48%;
}

.post-navigation a {
    display: block;
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
    padding: var(--space-md);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    transition: all var(--transition-fast);
}

.post-navigation a:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.post-navigation .nav-subtitle {
    display: block;
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-xs);
}

/* ==========================================================================
   Comments
   ========================================================================== */

.comments-area {
    margin-top: var(--space-2xl);
}

.comments-title {
    font-size: var(--text-lg);
    margin-bottom: var(--space-lg);
}

.comment-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.comment {
    margin-bottom: var(--space-lg);
}

.comment-body {
    padding: var(--space-lg);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
}

.comment-meta {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-sm);
    font-size: var(--text-sm);
}

.comment-author {
    font-weight: 700;
}

.comment-author img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.comment-metadata {
    color: var(--color-text-muted);
    font-size: var(--text-xs);
}

.comment-content {
    font-size: var(--text-base);
}

.comment-content p:last-child {
    margin-bottom: 0;
}

.comment-reply-link {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-accent);
}

.children {
    list-style: none;
    padding-left: var(--space-xl);
    margin-top: var(--space-md);
}

/* --- Comment Form --- */

.comment-respond {
    margin-top: var(--space-xl);
    padding: var(--space-lg);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
}

.comment-form {
    display: grid;
    gap: var(--space-md);
}

.comment-form label {
    font-size: var(--text-sm);
    font-weight: 600;
    display: block;
    margin-bottom: var(--space-xs);
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--space-sm) var(--space-md);
    font-family: inherit;
    font-size: var(--text-base);
    background: var(--color-bg);
    transition: border-color var(--transition-fast);
}

.comment-form input:focus,
.comment-form textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.1);
}

.comment-form textarea {
    min-height: 150px;
    resize: vertical;
}

.comment-form .submit {
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: var(--border-radius);
    padding: var(--space-sm) var(--space-lg);
    font-family: inherit;
    font-size: var(--text-base);
    font-weight: 700;
    cursor: pointer;
    transition: background var(--transition-fast);
    justify-self: start;
}

.comment-form .submit:hover {
    background: var(--color-primary-hover);
}

/* ==========================================================================
   Sidebar & Widgets
   ========================================================================== */

.sidebar {
    font-size: var(--text-sm);
}

.widget {
    margin-bottom: var(--space-xl);
    padding: var(--space-lg);
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
}

.widget:last-child {
    margin-bottom: 0;
}

.widget-title {
    font-size: var(--text-md);
    margin-bottom: var(--space-md);
    padding-bottom: var(--space-sm);
    border-bottom: 2px solid var(--color-primary);
}

.widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.widget li {
    padding: var(--space-xs) 0;
    border-bottom: 1px solid var(--color-border-light);
}

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

.widget a {
    color: var(--color-text);
}

.widget a:hover {
    color: var(--color-primary);
}

/* --- Widget: Recent Posts with thumbnails --- */

.widget_recent_entries li {
    display: flex;
    gap: var(--space-sm);
    align-items: flex-start;
}

.widget_recent_entries .post-thumb {
    width: 60px;
    height: 60px;
    border-radius: var(--border-radius);
    overflow: hidden;
    flex-shrink: 0;
}

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

/* ==========================================================================
   Pagination
   ========================================================================== */

.pagination {
    display: flex;
    justify-content: center;
    gap: var(--space-xs);
    margin-top: var(--space-xl);
}

.pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 var(--space-sm);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-bg);
    transition: all var(--transition-fast);
}

.pagination .page-numbers.current {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

.pagination .page-numbers:hover:not(.current):not(.dots) {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.pagination .page-numbers.dots {
    border-color: transparent;
}

/* ==========================================================================
   Page Template
   ========================================================================== */

.page-header {
    text-align: center;
    padding-block: var(--space-xl);
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
    margin-bottom: var(--space-xl);
}

.page-title {
    font-size: var(--text-2xl);
    margin: 0;
}

.archive-description {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
    margin-top: var(--space-sm);
}

/* ==========================================================================
   404 Page
   ========================================================================== */

.error-404 {
    text-align: center;
    padding-block: var(--space-3xl);
}

.error-404 .error-code {
    font-family: var(--font-heading);
    font-size: var(--text-3xl);
    font-weight: 900;
    color: var(--color-primary);
    line-height: 1;
    margin-bottom: var(--space-md);
}

.error-404 .error-title {
    font-size: var(--text-xl);
    margin-bottom: var(--space-md);
}

.error-404 .error-message {
    font-size: var(--text-base);
    color: var(--color-text-light);
    margin-bottom: var(--space-xl);
}

.error-404 .search-form {
    margin-inline: auto;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
    background: var(--color-bg-dark);
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--text-sm);
    margin-top: var(--space-2xl);
}

.footer-widgets {
    padding-block: var(--space-2xl);
}

.footer-widgets-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--grid-gap);
}

@media (min-width: 600px) {
    .footer-widgets-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .footer-widgets-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.footer-widgets .widget {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.footer-widgets .widget-title {
    color: #fff;
    border-bottom-color: var(--color-primary);
}

.footer-widgets a {
    color: rgba(255, 255, 255, 0.8);
}

.footer-widgets a:hover {
    color: #fff;
}

.footer-widgets .widget li {
    border-bottom-color: rgba(255, 255, 255, 0.08);
}

.footer-bottom {
    padding-block: var(--space-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-md);
}

.footer-bottom a {
    color: rgba(255, 255, 255, 0.8);
}

.footer-bottom a:hover {
    color: #fff;
}

/* ==========================================================================
   Gutenberg Blocks — Theme Overrides
   ========================================================================== */

/* Buttons */
.wp-block-button__link {
    border-radius: var(--border-radius);
    font-family: var(--font-body);
    font-weight: 700;
    font-size: var(--text-sm);
    padding: var(--space-sm) var(--space-lg);
    transition: all var(--transition-fast);
}

.wp-block-button__link:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Tables */
.wp-block-table table {
    border-collapse: collapse;
    width: 100%;
}

.wp-block-table th,
.wp-block-table td {
    border: 1px solid var(--color-border);
    padding: var(--space-sm) var(--space-md);
    text-align: left;
}

.wp-block-table th {
    background: var(--color-bg-alt);
    font-weight: 700;
}

.wp-block-table tr:nth-child(even) td {
    background: var(--color-bg-alt);
}

/* Pullquote */
.wp-block-pullquote {
    border-top: 4px solid var(--color-primary);
    border-bottom: 4px solid var(--color-primary);
    padding: var(--space-xl) 0;
    margin: var(--space-xl) auto;
    text-align: center;
}

.wp-block-pullquote blockquote {
    border: none;
    background: none;
    padding: 0;
    margin: 0;
}

/* Cover */
.wp-block-cover {
    border-radius: var(--border-radius-lg);
    overflow: hidden;
}

/* Gallery */
.wp-block-gallery {
    gap: var(--space-sm);
}

/* Separator */
.wp-block-separator {
    border: none;
    border-top: 1px solid var(--color-border);
}

.wp-block-separator.is-style-wide {
    border-top-width: 1px;
}

/* Group */
.wp-block-group {
    border-radius: var(--border-radius-lg);
}

.wp-block-group.has-background {
    padding: var(--space-lg);
}

/* Latest Posts */
.wp-block-latest-posts {
    list-style: none;
    padding: 0;
}

.wp-block-latest-posts li {
    margin-bottom: var(--space-md);
}

.wp-block-latest-posts__post-title {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* Search (block) */
.wp-block-search__input {
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    padding: var(--space-sm) var(--space-md);
    font-family: inherit;
}

.wp-block-search__button {
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: var(--border-radius);
    padding: var(--space-sm) var(--space-md);
    font-family: inherit;
    font-weight: 700;
    cursor: pointer;
}

/* ==========================================================================
   Back to Top
   ========================================================================== */

.back-to-top {
    position: fixed;
    bottom: var(--space-lg);
    right: var(--space-lg);
    width: 44px;
    height: 44px;
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: var(--text-lg);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--transition-base);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.hidden { display: none !important; }

.clearfix::after {
    content: '';
    display: table;
    clear: both;
}

/* Sticky posts */
.sticky {
    border-left: 4px solid var(--color-primary);
}

/* Byline separator */
.byline-sep {
    color: var(--color-border);
    margin: 0 var(--space-xs);
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    .site-header,
    .site-footer,
    .sidebar,
    .comments-area,
    .back-to-top,
    .breaking-news,
    .related-posts,
    .post-navigation,
    .menu-toggle {
        display: none !important;
    }

    body {
        font-size: 12pt;
        line-height: 1.6;
        color: #000;
        background: #fff;
    }

    a {
        color: #000;
        text-decoration: underline;
    }

    .entry-content a[href]::after {
        content: ' (' attr(href) ')';
        font-size: 0.8em;
        color: #666;
    }

    .container {
        max-width: 100%;
        padding: 0;
    }
}

/* ==========================================================================
   Reduced Motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
