/**
 * Responsive Styles
 * Test resolutions:
 * 1920px desktop, 1536px desktop (reference), 1366px laptop, 1024px tablet, 768px tablet, 430px mobile, 375px mobile
 */

/* 1366px - 1440px */
@media (max-width: 1440px) {
    :root {
        --container-max-width: 1280px;
    }
    .masthead-container {
        grid-template-columns: 340px 1fr 300px;
        gap: 16px;
    }
}

/* 1024px - Tablet Landscape / Small Laptop */
@media (max-width: 1024px) {
    .masthead-container {
        grid-template-columns: 1fr auto;
    }
    .masthead-center-art {
        display: none; /* Hide middle scenery card on tablet */
    }
    .hero-container {
        grid-template-columns: 1.5fr 1fr;
    }
    .hero-editors-picks {
        grid-column: span 2;
        display: grid;
        grid-template-columns: 1fr;
    }
    .latest-news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .kerala-ad-banner {
        grid-template-columns: 1fr;
    }
    .ad-banner-visual {
        min-height: 200px;
        max-height: 240px;
    }
    .trending-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .sections-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .video-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 768px - Tablet Portrait */
@media (max-width: 768px) {
    .topbar-wrapper {
        display: none; /* Consolidated or hidden on small screens */
    }
    .masthead-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .brand-link {
        justify-content: center;
    }
    .masthead-ad-slot {
        justify-content: center;
    }
    .mobile-nav-toggle {
        display: flex;
    }
    .nav-menu {
        position: absolute;
        top: 52px;
        left: 0;
        right: 0;
        background-color: var(--color-dark);
        flex-direction: column;
        align-items: stretch;
        height: auto;
        padding: 10px 0;
        display: none;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    }
    .nav-menu.is-active {
        display: flex;
    }
    .nav-item {
        height: 42px;
    }
    .nav-link {
        padding: 0 20px;
        width: 100%;
    }
    .search-box-inline {
        display: none;
    }
    .search-icon-btn {
        display: block;
    }
    .hero-container {
        grid-template-columns: 1fr;
    }
    .hero-editors-picks {
        grid-column: span 1;
    }
    .trending-grid {
        grid-template-columns: 1fr;
    }
    .sections-grid {
        grid-template-columns: 1fr;
    }
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    .video-grid {
        grid-template-columns: 1fr;
    }
    .footer-grid {
        grid-template-columns: 1fr;
    }
    .footer-strip-container {
        flex-direction: column;
        align-items: stretch;
    }
    .footer-newsletter-form {
        flex-direction: column;
        width: 100%;
    }
    .footer-newsletter-form input {
        width: 100%;
    }
    .footer-bottom-inner {
        flex-direction: column;
        text-align: center;
    }
}

/* 430px & 375px - Mobile Devices */
@media (max-width: 480px) {
    :root {
        --site-padding: 14px;
    }
    .brand-title {
        font-size: 1.45rem;
    }
    .brand-logo-mark {
        width: 40px;
        height: 40px;
    }
    .hero-title {
        font-size: 1.25rem;
    }
    .breaking-label-wrap {
        padding: 0 10px;
        font-size: 0.72rem;
    }
    .breaking-title-ml {
        display: none;
    }
    .latest-news-grid {
        grid-template-columns: 1fr;
    }
    .ad-banner-title {
        font-size: 1.35rem;
    }
    .ad-banner-phone {
        margin-left: 0;
        width: 100%;
    }
}
