/* ========== Responsive Design ========== */

/* Tablet: 768px - 1200px */
@media (max-width: 1200px) {
    :root {
        --sidebar-width: 280px;
    }

    .footer-widgets {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-bg .windmill-1 {
        width: 200px;
        height: 200px;
    }

    .hero-bg .windmill-2 {
        width: 280px;
        height: 280px;
    }

    .value-modules {
        grid-template-columns: repeat(2, 1fr);
    }

    .featured-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile: < 768px */
@media (max-width: 768px) {
    :root {
        --content-gap: 20px;
    }

    /* Navigation */
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        flex-direction: column;
        background: var(--color-bg-darker);
        border-left: 1px solid var(--color-border);
        padding: 80px 20px 20px;
        transition: right var(--transition-normal);
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
        z-index: 1001;
        gap: 0;
        overflow-y: auto;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu li a {
        padding: 12px 16px;
        border-bottom: 1px solid var(--color-border);
        border-radius: 0;
        font-size: 1rem;
    }

    .nav-menu li a.current-menu-item::after,
    .nav-menu li a:hover::after {
        bottom: auto;
        left: 0;
        top: 50%;
        transform: translateY(-50%);
        width: 3px;
        height: 20px;
        border-radius: 0 2px 2px 0;
    }

    /* Mobile overlay */
    .nav-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1000;
    }

    .nav-overlay.active {
        display: block;
    }

    /* Search */
    .top-bar {
        display: none;
    }

    .search-form input[type="search"] {
        width: 120px;
    }

    /* Hero */
    .hero-section {
        min-height: 280px;
    }

    .hero-content {
        padding: 40px 16px;
    }

    .hero-content h1 {
        font-size: 1.4rem;
    }

    .hero-content p {
        font-size: 0.95rem;
    }

    .hero-btns {
        flex-direction: column;
        align-items: center;
    }

    .hero-btns .btn {
        width: 100%;
        max-width: 240px;
    }

    /* Hide windmills on mobile */
    .hero-bg .windmill {
        display: none;
    }

    .hero-bg .windmill-3 {
        display: block;
        width: 120px;
        height: 120px;
        opacity: 0.04;
    }

    /* Main Content */
    .main-content {
        grid-template-columns: 1fr;
    }

    /* Posts Grid */
    .posts-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .post-card.featured .post-card-inner {
        grid-template-columns: 1fr;
    }

    .post-card.featured .post-card-thumbnail {
        aspect-ratio: 16 / 9;
        height: auto;
    }

    /* Category Tabs */
    .category-tabs {
        gap: 6px;
        padding: 14px 0;
    }

    .category-tab {
        padding: 6px 14px;
        font-size: 0.8rem;
    }

    /* Footer */
    .footer-widgets {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    /* Single Post */
    .single-post-content {
        padding: 20px;
    }

    .single-post-content h1 {
        font-size: 1.3rem;
    }

    .single-post-thumbnail {
        aspect-ratio: 16 / 9;
    }

    .single-post-meta {
        flex-wrap: wrap;
        gap: 12px;
    }

    /* Author Box */
    .author-box {
        flex-direction: column;
        text-align: center;
    }

    /* Back to top */
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
    }

    /* Related Posts */
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Post CTA */
    .post-cta-content {
        flex-direction: column;
        text-align: center;
    }

    .post-cta-actions {
        width: 100%;
        justify-content: center;
    }

    .post-cta-actions .btn {
        flex: 1;
        max-width: 180px;
    }

    /* Pagination */
    .pagination a,
    .pagination span {
        min-width: 34px;
        height: 34px;
        font-size: 0.85rem;
    }

    .value-modules {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .value-module {
        padding: 16px 12px;
    }

    .value-module-icon {
        width: 44px;
        height: 44px;
    }

    .featured-posts-grid {
        grid-template-columns: 1fr;
    }
}

/* Small Mobile: < 480px */
@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.3rem;
    }

    .hero-content p {
        font-size: 0.85rem;
    }

    .post-card-body {
        padding: 14px 16px;
    }

    .post-card-title {
        font-size: 1rem;
    }

    h1 { font-size: 1.5rem; }
    h2 { font-size: 1.3rem; }
    h3 { font-size: 1.15rem; }

    .sidebar-widget {
        padding: 16px;
    }

    .value-modules {
        grid-template-columns: 1fr;
    }
}
