/*
Theme Name: HealthyDaily Life WP by nilo by Antigravity Gemini
Theme URI: https://github.com/healthydaily-life-wp
Author: Antigravity
Author URI: https://deepmind.google/
Description: A lightweight, fast-loading, SEO-optimized, and accessibility-compliant (WCAG 2.1 AA) WordPress theme for Personal Health, Family Wellness, and Life Coaching blogs. Features sticky headers, customizer settings, native lazy loading, dynamic TOC, ad placements, and a persistent dark mode toggle.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: healthydaily-life-wp
Tags: blog, one-column, two-columns, right-sidebar, custom-logo, custom-menu, featured-images, footer-widgets, accessibility-ready, translation-ready, block-styles
Requires at least: 6.0
Requires PHP: 8.2
*/

/* ==========================================================================
   1. Design System & CSS Custom Properties
   ========================================================================== */
:root {
    /* Fonts */
    --font-heading: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    
    /* Light Mode Palette */
    --primary: #7BC67B;
    --secondary: #DFF5E1;
    --accent: #3E7C3E;
    --bg-body: #FFFFFF;
    --bg-card: #FFFFFF;
    --bg-muted: #F8F9F8;
    --text-primary: #333333;
    --text-muted: #666666;
    --border-color: #EAEAEA;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
    
    /* Layout Constants */
    --max-content-width: 800px;
    --max-container-width: 1200px;
    --border-radius-sm: 4px;
    --border-radius-md: 8px;
    --border-radius-lg: 16px;
    
    /* Accessibility Outline */
    --focus-outline: 3px solid var(--accent);
    --focus-offset: 2px;
}

/* Dark Mode Overrides */
[data-theme="dark"] {
    --primary: #7BC67B;
    --secondary: #1E3A1E;
    --accent: #7BC67B;
    --bg-body: #121212;
    --bg-card: #1E1E1E;
    --bg-muted: #1A1A1A;
    --text-primary: #F5F5F5;
    --text-muted: #A5A5A5;
    --border-color: #2D2D2D;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.4);
}

/* ==========================================================================
   2. Reset & Core Typography
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    background-color: var(--bg-body);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.3;
    margin-top: 1.5em;
    margin-bottom: 0.5em;
}

h1 { font-size: 2.25rem; margin-top: 0; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.4rem; }
h4 { font-size: 1.2rem; }

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

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

p {
    margin-top: 0;
    margin-bottom: 1.5rem;
}

/* Skip Link for Accessibility */
.skip-link {
    position: absolute;
    top: -100px;
    left: 20px;
    background: var(--accent);
    color: #FFF;
    padding: 10px 20px;
    z-index: 99999;
    border-radius: var(--border-radius-sm);
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 20px;
    outline: var(--focus-outline);
    outline-offset: var(--focus-offset);
}

/* Focus Indicator styling */
a:focus, button:focus, input:focus, select:focus, textarea:focus {
    outline: var(--focus-outline);
    outline-offset: var(--focus-offset);
}

/* Screen Reader Text helper */
.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;
}

/* ==========================================================================
   3. Base Layout Container
   ========================================================================== */
.site {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    width: 90%;
    max-width: var(--max-container-width);
    margin: 0 auto;
    padding: 0 15px;
}

.site-content {
    flex-grow: 1;
    padding: 40px 0;
}

/* ==========================================================================
   4. Sticky Header
   ========================================================================== */
.site-header {
    background-color: var(--bg-body);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
    transition: background-color 0.3s ease, border-bottom 0.3s ease, box-shadow 0.3s ease;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    position: relative;
}

.site-branding {
    display: flex;
    align-items: center;
}

.site-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

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

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

/* Main Navigation */
.main-navigation {
    display: none; /* Mobile first hidden */
}

.main-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 24px;
}

.main-navigation a {
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.95rem;
}

.main-navigation a:hover,
.main-navigation .current-menu-item > a {
    color: var(--accent);
}

/* Header Right Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-btn {
    background-color: var(--accent);
    color: #FFFFFF !important;
    padding: 8px 18px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.header-btn:hover {
    background-color: var(--primary);
    color: var(--text-primary) !important;
    transform: translateY(-1px);
}

.search-toggle,
.dark-mode-toggle,
.menu-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.search-toggle:hover,
.dark-mode-toggle:hover,
.menu-toggle:hover {
    background-color: var(--bg-muted);
}

.search-toggle svg,
.dark-mode-toggle svg,
.menu-toggle svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Search Dropdown Panel */
.search-dropdown {
    position: absolute;
    top: 70px;
    right: 15px;
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    padding: 15px;
    border-radius: var(--border-radius-md);
    width: 300px;
    display: none;
    z-index: 1001;
    transform-origin: top right;
    animation: fadeInScale 0.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.search-dropdown.active {
    display: block;
}

.search-dropdown form {
    display: flex;
    gap: 8px;
}

.search-dropdown input[type="search"] {
    flex-grow: 1;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-body);
    color: var(--text-primary);
    border-radius: var(--border-radius-sm);
}

.search-dropdown button[type="submit"] {
    background-color: var(--accent);
    color: #FFF;
    border: none;
    padding: 8px 16px;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    font-weight: 500;
}

.search-dropdown button[type="submit"]:hover {
    background-color: var(--primary);
}

/* Mobile Hamburger Menu Drawers */
.mobile-menu-drawer {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100%;
    background-color: var(--bg-card);
    z-index: 1002;
    padding: 30px 20px;
    box-shadow: var(--shadow-lg);
    transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    overflow-y: auto;
}

.mobile-menu-drawer.open {
    left: 0;
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    z-index: 1001;
    display: none;
}

.mobile-menu-overlay.open {
    display: block;
}

.mobile-menu-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-primary);
    cursor: pointer;
    position: absolute;
    top: 15px;
    right: 15px;
}

.mobile-navigation ul {
    list-style: none;
    padding: 0;
    margin: 40px 0 0 0;
}

.mobile-navigation li {
    margin-bottom: 20px;
}

.mobile-navigation a {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
    display: block;
}

/* ==========================================================================
   5. Homepage Layout (Hero, Grid, Sections)
   ========================================================================== */
.hero-section {
    margin-bottom: 50px;
}

.hero-card {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    background-color: var(--bg-card);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.hero-image-wrapper {
    position: relative;
    aspect-ratio: 16/9;
}

.hero-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.category-badge {
    display: inline-block;
    background-color: var(--secondary);
    color: var(--accent);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: var(--border-radius-sm);
    width: fit-content;
    margin-bottom: 12px;
    letter-spacing: 0.05em;
}

[data-theme="dark"] .category-badge {
    color: var(--primary);
}

.hero-title {
    font-size: 1.8rem;
    margin-top: 0;
    margin-bottom: 12px;
}

.hero-title a {
    color: var(--text-primary);
}

.hero-title a:hover {
    color: var(--accent);
}

.post-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.post-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.post-meta svg {
    width: 14px;
    height: 14px;
    fill: currentColor;
}

.hero-excerpt {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 24px;
}

.read-more-btn {
    display: inline-block;
    font-weight: 600;
    color: var(--accent);
    position: relative;
    width: fit-content;
}

.read-more-btn::after {
    content: " →";
    transition: transform 0.2s ease;
    display: inline-block;
}

.read-more-btn:hover::after {
    transform: translateX(4px);
}

/* Category Grid Section */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
}

.section-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    position: relative;
}

.section-title::after {
    content: "";
    position: absolute;
    bottom: -12px;
    left: 0;
    width: 60px;
    height: 2px;
    background-color: var(--accent);
}

.featured-categories-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 50px;
}

.category-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.category-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent);
}

.category-card-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    color: var(--accent);
}

.category-card h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.category-card h3 a {
    color: var(--text-primary);
}

/* 3-Column Magazine / Article Grid */
.articles-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.post-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.post-card-image {
    aspect-ratio: 16/10;
    overflow: hidden;
}

.post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.post-card-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.post-card-title {
    font-size: 1.25rem;
    margin-top: 0;
    margin-bottom: 10px;
    line-height: 1.4;
}

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

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

.post-card-excerpt {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 16px;
    flex-grow: 1;
}

/* Sidebar & Layout splits */
.content-area-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

/* Dynamic layouts on homepage */
.trending-popular-section {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 50px;
}

.trending-list,
.popular-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.trending-item,
.popular-item {
    display: flex;
    gap: 16px;
    align-items: center;
}

.trending-num {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: var(--secondary);
    line-height: 1;
    min-width: 40px;
}

[data-theme="dark"] .trending-num {
    color: #333333;
}

.trending-item-content h4,
.popular-item-content h4 {
    margin: 0 0 4px 0;
    font-size: 0.95rem;
    line-height: 1.4;
}

.trending-item-content h4 a,
.popular-item-content h4 a {
    color: var(--text-primary);
}

.trending-item-content .post-meta,
.popular-item-content .post-meta {
    margin-bottom: 0;
}

/* Author Introduction section */
.author-intro-card {
    background-color: var(--bg-muted);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    text-align: center;
    margin-bottom: 50px;
}

.author-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
}

.author-intro-details h3 {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 1.3rem;
}

.author-intro-bio {
    color: var(--text-muted);
    font-size: 0.95rem;
    max-width: 600px;
    margin-bottom: 16px;
}

.author-socials {
    display: flex;
    gap: 12px;
}

.author-socials a {
    color: var(--text-muted);
}

.author-socials a:hover {
    color: var(--accent);
}

/* Newsletter Section */
.newsletter-signup-box {
    background-color: var(--secondary);
    border-radius: var(--border-radius-lg);
    padding: 40px 30px;
    text-align: center;
    margin-bottom: 50px;
}

[data-theme="dark"] .newsletter-signup-box {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
}

.newsletter-title {
    font-size: 1.6rem;
    margin-top: 0;
    margin-bottom: 8px;
}

.newsletter-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 24px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input[type="email"] {
    padding: 12px 20px;
    border: 1px solid var(--border-color);
    border-radius: 50px;
    font-size: 0.95rem;
    width: 100%;
}

.newsletter-form button {
    background-color: var(--accent);
    color: #FFFFFF;
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

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

/* Pagination */
.navigation.pagination {
    margin: 40px 0;
}

.pagination .nav-links {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.pagination .page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    font-weight: 600;
    color: var(--text-primary);
}

.pagination .page-numbers.current,
.pagination .page-numbers:hover {
    background-color: var(--accent);
    color: #FFF;
    border-color: var(--accent);
}

/* ==========================================================================
   6. Sidebar Widgets
   ========================================================================== */
.widget-area {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.widget {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    padding: 24px;
}

.widget-title {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.15rem;
    font-weight: 700;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 8px;
    position: relative;
}

.widget-title::after {
    content: "";
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--accent);
}

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

.widget li {
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

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

.widget a {
    color: var(--text-primary);
    font-weight: 500;
}

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

/* Category widget */
.widget_categories li {
    display: flex;
    justify-content: space-between;
}

.widget_categories .count {
    background-color: var(--secondary);
    color: var(--accent);
    font-size: 0.8rem;
    padding: 2px 8px;
    border-radius: 10px;
}

/* ==========================================================================
   7. Single Post Details (Readability First)
   ========================================================================== */
.single-post-container {
    max-width: var(--max-container-width);
    margin: 0 auto;
}

.post-header {
    margin-bottom: 30px;
}

.breadcrumbs {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 16px;
}

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

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

.single-post-title {
    font-size: 2.25rem;
    line-height: 1.3;
    margin-top: 0;
    margin-bottom: 20px;
}

.post-featured-image {
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    margin-bottom: 40px;
    aspect-ratio: 16/9;
}

.post-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Article Split Layout */
.article-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

/* Social Share Row */
.social-share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #FFF !important;
}

.share-btn.fb { background-color: #3b5998; }
.share-btn.tw { background-color: #1da1f2; }
.share-btn.pin { background-color: #bd081c; }
.share-btn.email { background-color: #7f8c8d; }

.share-btn svg {
    width: 14px;
    height: 14px;
    fill: currentColor;
}

/* Sticky Table of Contents */
.toc-container {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    padding: 20px;
    margin-bottom: 30px;
}

.toc-title {
    margin-top: 0;
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 12px;
}

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

.toc-item {
    font-size: 0.9rem;
    margin-bottom: 8px;
    line-height: 1.4;
}

.toc-item.level-3 {
    padding-left: 15px;
}

.toc-item a {
    color: var(--text-muted);
}

.toc-item.active a,
.toc-item a:hover {
    color: var(--accent);
    font-weight: 600;
}

/* Main Readability Blog Body Content */
.post-content-body {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--text-primary);
}

.post-content-body p {
    margin-bottom: 1.8rem;
}

.post-content-body blockquote {
    border-left: 4px solid var(--accent);
    padding-left: 20px;
    margin: 30px 0;
    font-style: italic;
    color: var(--text-muted);
}

.post-content-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius-md);
    margin: 20px 0;
}

/* Author Bio Card */
.author-bio-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 30px;
    background-color: var(--bg-muted);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    margin: 40px 0;
    text-align: center;
}

/* Previous/Next Navigation */
.post-navigation {
    display: flex;
    flex-direction: column;
    gap: 16px;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 24px 0;
    margin-bottom: 40px;
}

.post-nav-link {
    flex: 1;
}

.post-nav-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.post-nav-title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
    margin-top: 4px;
}

.post-nav-link:hover .post-nav-title {
    color: var(--accent);
}

/* Related Posts */
.related-posts-section {
    margin-bottom: 50px;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

/* ==========================================================================
   8. Accessibility & Forms (Comment System)
   ========================================================================== */
.comments-title {
    font-size: 1.5rem;
    margin-bottom: 30px;
}

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

.comment-body {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.comment-meta {
    display: flex;
    flex-direction: column;
    font-size: 0.85rem;
}

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

.comment-metadata a {
    color: var(--text-muted);
}

.comment-content {
    font-size: 0.95rem;
    margin-top: 8px;
}

.reply {
    margin-top: 8px;
}

.comment-reply-link {
    font-size: 0.8rem;
    font-weight: 700;
    background-color: var(--bg-muted);
    padding: 4px 12px;
    border-radius: 20px;
    color: var(--text-primary);
}

.comment-reply-link:hover {
    background-color: var(--accent);
    color: #FFF;
}

.comment-respond {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    padding: 30px;
}

.comment-reply-title {
    margin-top: 0;
    font-size: 1.25rem;
    margin-bottom: 20px;
}

.comment-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.comment-form input,
.comment-form textarea {
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-body);
    color: var(--text-primary);
    border-radius: var(--border-radius-sm);
    width: 100%;
}

.comment-form-cookies-consent {
    display: flex;
    align-items: center;
    gap: 8px;
}

.comment-form-cookies-consent input {
    width: auto;
}

.comment-form-cookies-consent label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.form-submit input[type="submit"] {
    background-color: var(--accent);
    color: #FFF;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    border-radius: 50px;
    padding: 12px 30px;
    width: fit-content;
}

.form-submit input[type="submit"]:hover {
    background-color: var(--primary);
    color: var(--text-primary);
}

/* ==========================================================================
   9. Footer Structure (4 Columns)
   ========================================================================== */
.site-footer {
    background-color: var(--bg-muted);
    border-top: 1px solid var(--border-color);
    padding: 60px 0 20px 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.footer-widgets {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-widget-title {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 20px;
}

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

.footer-widget-content a:hover {
    color: var(--accent);
}

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

.footer-widget-content li {
    margin-bottom: 10px;
}

.site-info-bar {
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    text-align: center;
}

.footer-bottom-menu {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-bottom-menu a {
    color: var(--text-muted);
}

.footer-bottom-menu a:hover {
    color: var(--accent);
}

/* ==========================================================================
   10. Advertisements Support Grid
   ========================================================================== */
.ad-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 30px auto;
    text-align: center;
    max-width: 100%;
}

.ad-label {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.ad-content {
    background-color: var(--bg-muted);
    border: 1px dotted var(--border-color);
    padding: 15px;
    width: 100%;
    min-height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ad-slot.header-ad { margin: 15px auto; max-width: 728px; }
.ad-slot.sidebar-ad { max-width: 300px; }
.ad-slot.in-article-ad { max-width: 728px; margin: 35px auto; }
.ad-slot.footer-ad { max-width: 728px; margin: 30px auto; }

/* ==========================================================================
   11. Animations
   ========================================================================== */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ==========================================================================
   12. Responsive Media Queries
   ========================================================================== */
@media (min-width: 600px) {
    .featured-categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .trending-popular-section {
        grid-template-columns: repeat(2, 1fr);
    }
    .post-navigation {
        flex-direction: row;
    }
    .post-nav-link.next {
        text-align: right;
    }
    .author-intro-card {
        flex-direction: row;
        text-align: left;
        padding: 40px;
    }
    .author-avatar {
        width: 120px;
        height: 120px;
    }
    .author-bio-card {
        flex-direction: row;
        text-align: left;
    }
}

@media (min-width: 900px) {
    /* Main Navigation visible */
    .main-navigation {
        display: block;
    }
    .menu-toggle {
        display: none;
    }
    
    /* Homepage Hero Split */
    .hero-card {
        grid-template-columns: 1.2fr 1fr;
    }
    .hero-content {
        padding: 40px;
    }
    .hero-title {
        font-size: 2.2rem;
    }
    
    /* Grid layout */
    .articles-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .featured-categories-grid {
        grid-template-columns: repeat(6, 1fr);
    }
    
    /* Sidebar split layout */
    .content-area-split {
        grid-template-columns: 1fr 300px;
        align-items: start;
    }
    
    /* Single post layout */
    .article-split {
        grid-template-columns: 240px 1fr;
        align-items: start;
    }
    
    .toc-sticky-wrapper {
        position: sticky;
        top: 100px;
    }
    
    .related-posts-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* Footer layout */
    .footer-widgets {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .site-info-bar {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
    .newsletter-form {
        flex-direction: row;
    }
    .newsletter-form input[type="email"] {
        width: auto;
        flex-grow: 1;
    }
}
