/* Responsive Styles - Bangladesh Political Campaign */

/* Extra small devices (phones, less than 576px) */
@media (max-width: 575.98px) {
    /* Top Announcement */
    .top-announcement {
        font-size: 0.8rem;
    }
    
    .top-announcement .col-md-6:first-child {
        margin-bottom: 10px;
    }
    
    /* Hero Section */
    .hero-banner {
        padding: 80px 0 30px;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero-content h3 {
        font-size: 1.2rem;
    }
    
    .hero-image img {
        max-width: 100%;
        margin-top: 30px;
    }
    
    /* Navigation */
    .navbar-brand h4 {
        font-size: 1rem;
    }
    
    .navbar-brand small {
        font-size: 1.rem;
    }
    
    /* Section Titles */
    .section-title {
        font-size: 1.5rem;
    }
    
    /* Counters */
    .counter-item h3 {
        font-size: 2rem;
    }
    
    /* Footer */
    .footer .row > div {
        margin-bottom: 30px;
    }
    
    /* Forms */
    .contact-form {
        padding: 20px;
    }
    
    /* Gallery */
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    .hero-content h1 {
        font-size: 2.2rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .counter-item h3 {
        font-size: 2.5rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .hero-content h1 {
        font-size: 3rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .gallery-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Specific Component Responsiveness */

/* Navigation */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: white;
        padding: 20px;
        border-radius: 10px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        margin-top: 15px;
    }
    
    .navbar-nav .nav-link {
        padding: 10px 0 !important;
    }
    
    .navbar-nav .nav-link::after {
        display: none;
    }
}

/* Table of Contents */
@media (max-width: 991.98px) {
    .toc-card {
        position: static !important;
        margin-bottom: 30px;
    }
    
    .toc-card .nav {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .toc-card .nav-link {
        padding: 8px 15px !important;
        border-left: none !important;
        border-bottom: 3px solid transparent;
    }
    
    .toc-card .nav-link:hover,
    .toc-card .nav-link.active {
        border-left: none !important;
        border-bottom-color: var(--bd-green);
        padding-left: 15px !important;
    }
}

/* Timeline */
@media (max-width: 767.98px) {
    .timeline {
        padding-left: 20px;
    }
    
    .timeline-item::before {
        left: -26px;
    }
    
    .timeline-date {
        position: static;
        width: auto;
        text-align: left;
        margin-bottom: 5px;
        font-weight: 600;
    }
}

/* Event Items */
@media (max-width: 575.98px) {
    .event-item {
        flex-direction: column;
    }
    
    .event-date {
        margin-right: 0;
        margin-bottom: 10px;
    }
}

/* Counter Animation Fix */
@media (prefers-reduced-motion: reduce) {
    .counter {
        transition: none;
    }
}

/* Print Styles */
@media print {
    .top-announcement,
    .navbar,
    .hero-buttons,
    .back-to-top,
    .footer,
    .social-links,
    .newsletter-form {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        color: black;
    }
    
    .container {
        width: 100%;
        max-width: none;
    }
    
    a {
        color: black !important;
        text-decoration: underline;
    }
    
    .hero-banner {
        background: none !important;
        padding: 20px 0 !important;
    }
    
    .hero-content h1 {
        color: black !important;
    }
}