/* NSE Epe Branch - Responsive Design */
/* Comprehensive mobile-first responsive overrides */

/* =========================================
   GLOBAL MOBILE SAFETY
   Prevent horizontal overflow everywhere
   ========================================= */
html {
    overflow-x: hidden;
}

body {
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
}

/* Prevent long words/URLs/emails from breaking layout */
p, li, a, span, td, th, h1, h2, h3, h4, h5, h6, label, .breadcrumb {
    overflow-wrap: break-word;
    word-wrap: break-word;
}

a, .footer-contact-item p, .info-item p, .branch-info p, .department-card p {
    word-break: break-word;
}

img, video, iframe, embed, object {
    max-width: 100%;
    height: auto;
}

/* Ensure inputs never overflow their containers */
input, textarea, select, button {
    max-width: 100%;
}

/* =========================================
   LARGE TABLETS / SMALL DESKTOPS (1024px)
   ========================================= */
@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-content {
        max-width: 100%;
    }

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

    .nav-link {
        padding: 24px 12px;
        font-size: 0.9rem;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }

    /* News Page */
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .event-item {
        grid-template-columns: 80px 1fr;
        gap: 1.5rem;
    }

    .category-buttons {
        justify-content: center;
    }

    /* Grid collapses to 2 columns */
    .resources-grid,
    .programs-grid,
    .divisions-grid,
    .activities-grid,
    .discipline-cards,
    .branches-grid,
    .benefits-grid,
    .reasons-grid,
    .values-grid,
    .departments-grid,
    .explore-cards,
    .offer-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    /* 4-col grids to 2-col */
    .branches-contact-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    /* News detail sidebar stack */
    .news-detail .container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .news-article {
        padding: 1.5rem;
    }

    .article-header h1 {
        font-size: 1.75rem;
    }

    .share-btn {
        display: flex;
        width: 100%;
        margin-bottom: 0.75rem;
        margin-right: 0;
    }

    .steps-container,
    .registration-steps {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    /* Header contact wrap on narrower tablets */
    .header-contact {
        flex-wrap: wrap;
        justify-content: flex-end;
    }

    /* Section grid gap */
    .section-grid {
        gap: 2.5rem;
    }

    /* Explore cards gap */
    .explore-cards {
        gap: 1.5rem;
    }
}

/* =========================================
   TABLETS (768px and below)
   ========================================= */
@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }

    /* Top Bar */
    .top-bar {
        font-size: 0.8rem;
        padding: 8px 0;
    }

    /* Header Contact */
    .header-contact {
        gap: 0.75rem 1.5rem;
        font-size: 0.8rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    /* ===== NAVIGATION - MOBILE MENU ===== */
    .menu-toggle {
        display: flex;
        order: 3;
    }

    /* Hide the CTA button in navbar on mobile */
    .nav-wrapper > .cta-button {
        display: none;
    }

    .nav-wrapper {
        gap: 1rem;
        min-height: 60px;
        position: relative;
    }

    /* Break menu out of container to span full viewport width */
    .nav-menu {
        position: absolute;
        top: 100%;
        left: 50%;
        right: auto;
        width: 100vw;
        transform: translateX(-50%);
        background-color: #fff;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 12px 32px rgba(0,0,0,0.1), 0 2px 6px rgba(0,0,0,0.06);
        z-index: 1000;
        overflow-y: auto;
        border-top: 2px solid var(--accent);
    }

    .nav-menu.active {
        max-height: 85vh;
    }

    .nav-menu > li {
        border-bottom: 1px solid rgba(0,0,0,0.06);
    }

    .nav-menu > li:last-child {
        border-bottom: none;
    }

    /* Nav links - left aligned, full width */
    .nav-link {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        padding: 0 24px;
        height: 52px;
        width: 100%;
        border-bottom: none !important;
        font-size: 0.95rem;
        font-weight: 500;
        color: #1a1a1a;
        text-align: left;
        transition: background-color 0.15s ease, color 0.15s ease;
    }

    .nav-link:hover {
        background-color: #f5f5f5;
        color: var(--accent);
        border-bottom: none !important;
    }

    .nav-menu > li.active > .nav-link {
        border-bottom: none !important;
        color: var(--accent);
        background-color: transparent;
    }

    /* Dropdown chevron - pushed to the right edge */
    .dropdown > .nav-link::after {
        content: '';
        display: inline-block;
        width: 0;
        height: 0;
        border-left: 5px solid transparent;
        border-right: 5px solid transparent;
        border-top: 5px solid currentColor;
        float: none;
        margin-left: auto;
        margin-top: 0;
        transition: transform 0.25s ease;
        flex-shrink: 0;
    }

    .dropdown.active > .nav-link {
        color: var(--accent);
        background-color: #f5f5f5;
    }

    .dropdown.active > .nav-link::after {
        transform: rotate(180deg);
    }

    /* Dropdown menu - full width, accordion style */
    .dropdown-menu {
        position: static !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        box-shadow: none !important;
        border: none !important;
        border-top: none !important;
        border-radius: 0 !important;
        background-color: #f5f6f8;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        padding: 0;
        min-width: 0;
        width: 100%;
    }

    /* Override desktop hover open */
    .dropdown:hover .dropdown-menu {
        max-height: 0;
    }

    /* Only open when JS adds .active */
    .dropdown.active .dropdown-menu {
        max-height: 500px;
    }

    .dropdown-menu li {
        width: 100%;
    }

    .dropdown-menu li a {
        padding: 0 24px 0 48px;
        height: 46px;
        width: 100%;
        display: flex;
        align-items: center;
        font-size: 0.9rem;
        font-weight: 400;
        color: #444;
        border-left: none;
        transition: background-color 0.15s ease, color 0.15s ease;
        position: relative;
    }

    /* Subtle dot indicator for submenu items */
    .dropdown-menu li a::before {
        content: '';
        display: inline-block;
        width: 5px;
        height: 5px;
        border-radius: 50%;
        background-color: #ccc;
        margin-right: 12px;
        flex-shrink: 0;
        transition: background-color 0.15s ease;
    }

    .dropdown-menu li a:hover {
        background-color: #ecedef;
        color: var(--accent);
    }

    .dropdown-menu li a:hover::before {
        background-color: var(--accent);
    }

    .dropdown-menu li:first-child a {
        padding-top: 4px;
    }

    .dropdown-menu li:last-child a {
        padding-bottom: 4px;
    }

    /* ===== HERO ===== */
    .hero {
        min-height: auto;
        padding: 0;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 3rem 0;
    }

    .hero-content {
        max-width: 100%;
    }

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

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

    .hero-buttons {
        flex-direction: column;
        gap: 0.75rem;
    }

    .hero-buttons .btn {
        min-width: auto;
        width: 100%;
        text-align: center;
    }

    .hero-visual {
        display: none;
    }

    /* ===== CORE GRID COLLAPSES ===== */
    .section-grid,
    .grid-2,
    .membership-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

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

    .stat-card::after {
        display: none;
    }

    .offer-cards {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .explore-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .explore-card {
        padding: 1.5rem 1rem;
    }

    .explore-section .section-header p {
        font-size: 0.95rem;
        margin-top: 1rem;
    }

    /* ===== NEWS CARDS ===== */
    .news-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .news-card {
        padding: 0;
    }

    .news-card-body {
        padding: 1.25rem;
    }

    .event-item {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1.25rem;
    }

    .event-date {
        min-height: auto;
        padding: 0.75rem;
        flex-direction: row;
        gap: 0.5rem;
    }

    .category-buttons {
        gap: 0.75rem;
    }

    .category-btn {
        padding: 0.65rem 1.25rem;
        font-size: 0.9rem;
    }

    .section-header {
        margin-bottom: 2rem;
    }

    .section-header h2 {
        font-size: 1.5rem;
    }

    .filter-header h2 {
        font-size: 1.5rem;
    }

    .partners-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    /* All multi-column grids collapse to 1 column */
    .resources-grid,
    .programs-grid,
    .categories-grid,
    .formats-grid,
    .pricing-cards,
    .divisions-grid,
    .activities-grid,
    .discipline-cards,
    .branches-grid,
    .diaspora-grid,
    .involvement-options,
    .search-results-grid,
    .benefits-grid,
    .categories-container,
    .steps-container,
    .registration-steps,
    .benefits-list,
    .reasons-grid,
    .values-grid {
        grid-template-columns: 1fr;
    }

    /* Contact page grids */
    .departments-grid,
    .branches-contact-grid {
        grid-template-columns: 1fr;
    }

    /* ===== FOOTER ===== */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    /* ===== SECTION SPACING ===== */
    .welcome-section,
    .what-we-offer,
    .explore-section,
    .recent-news,
    .partners,
    .leadership {
        padding: 3rem 0;
    }

    .statistics {
        padding: 3rem 0;
    }

    .cta-section {
        padding: 2.5rem 0;
    }

    .page-header {
        padding: 2.5rem 0;
    }

    /* CTA content */
    .cta-content h2 {
        font-size: 1.5rem;
    }

    .cta-content p {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }

    .cta-content .btn-dark,
    .cta-content .btn-lg {
        min-width: auto;
        width: 100%;
        max-width: 320px;
    }

    /* ===== FORMS ===== */
    .form-row {
        grid-template-columns: 1fr;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions button {
        width: 100%;
    }

    .form-group.checkbox {
        flex-wrap: wrap;
    }

    .form-group.checkbox label {
        flex: 1;
        min-width: 0;
    }

    .form-group input[type="file"] {
        font-size: 0.85rem;
        padding: 10px;
    }

    /* ===== CARDS ===== */
    .offer-card,
    .membership-card,
    .stat-card {
        padding: 1.5rem;
    }

    .leader-card {
        padding: 2.5rem 1.5rem;
    }

    /* Table-like layouts */
    .resource-list {
        grid-template-columns: 1fr;
    }

    .resource-item {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .resource-item a {
        width: 100%;
    }

    /* Timeline */
    .timeline-item {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .timeline-date {
        font-size: 0.9rem;
    }

    /* Logo */
    .logo-text {
        font-size: 1.15rem;
    }

    .logo-tagline {
        font-size: 0.6rem;
    }

    .logo-emblem {
        width: 42px;
        height: 42px;
        font-size: 0.9rem;
    }

    /* Benefits List */
    .benefits-list {
        grid-template-columns: 1fr;
    }

    /* ===== BANNER ===== */
    .banner-alert {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
        padding: 12px 0;
    }

    .banner-link {
        margin-left: 0;
    }

    /* ===== NEWSLETTER ===== */
    .newsletter-form {
        flex-direction: column;
        gap: 8px;
    }

    .newsletter-form input {
        border-right: 1px solid rgba(255,255,255,0.2);
        border-radius: var(--radius);
        width: 100%;
    }

    .newsletter-form button {
        border-radius: var(--radius);
        width: 100%;
    }

    /* Search forms */
    .search-form,
    .resource-search,
    .branch-search {
        flex-direction: column;
        align-items: stretch;
    }

    .search-form input,
    .resource-search input,
    .resource-search select,
    .branch-search input,
    .search-form button,
    .resource-search button {
        width: 100%;
    }

    .resource-search-input-wrap {
        min-width: 100% !important;
    }

    .search-resources--prominent .resource-search select {
        min-width: 100%;
    }

    /* Filter category section */
    .filter-category-flex {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .filter-category-flex .search-form {
        min-width: 0;
    }

    .filter-category-flex .category-buttons {
        flex-direction: column;
        gap: 0.5rem;
    }

    .category-btn {
        width: 100%;
        justify-content: center;
    }

    /* ===== TABS AND PRESIDENT ===== */
    .tabs-nav {
        flex-wrap: nowrap;
        gap: 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tab-btn {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
        flex: 1 0 auto;
        min-width: 0;
        text-align: center;
        white-space: nowrap;
    }

    .president-card {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
        padding: 1.5rem;
    }

    .president-image img {
        width: 140px;
        height: 140px;
        margin: 0 auto;
    }

    .president-name {
        font-size: 1.25rem;
    }

    /* Breadcrumb overflow */
    .breadcrumb {
        white-space: normal;
        line-height: 1.6;
    }

    /* FAQ Responsive */
    .faq-items {
        max-width: 100%;
    }

    .faq-item {
        margin-bottom: 1rem;
    }

    .faq-question {
        padding: 1.25rem;
        font-size: 1rem;
        min-height: 48px;
    }

    .faq-answer {
        font-size: 0.9rem;
    }

    /* Error Pages */
    .error-code {
        font-size: 5rem;
    }

    .error-container h1 {
        font-size: 1.5rem;
    }

    .error-actions {
        flex-direction: column;
    }

    .error-actions .btn {
        width: 100%;
    }

    .error-suggestions {
        width: 100%;
    }

    /* Touch targets for links */
    .footer-section ul li a {
        display: block;
        padding-top: 6px;
        padding-bottom: 6px;
    }

    /* Social links - larger tap targets */
    .social-links a {
        width: 40px;
        height: 40px;
        font-size: 0.9rem;
    }

    /* Details/Requirement content */
    .details-content,
    .requirement-content,
    .form-wrapper {
        padding: 1.5rem;
    }

    /* Branch listing */
    .branch-listing {
        padding: 1.5rem;
    }

    /* Notice box */
    .notice-box {
        padding: 1rem;
    }

    /* Partner logos */
    .partner-logo {
        padding: 1.25rem 1rem;
        min-height: 90px;
    }

    /* Section header underline */
    .section-header h2::after {
        width: 60px;
    }

    /* News footer button */
    .news-footer .btn {
        width: 100%;
        max-width: 300px;
    }

    /* Vision/mission boxes */
    .vision-box,
    .mission-box {
        padding: 1.25rem;
    }
}

/* =========================================
   MOBILE PHONES (480px and below)
   ========================================= */
@media (max-width: 480px) {
    h1 { font-size: 1.5rem; }
    h2 { font-size: 1.25rem; }
    h3 { font-size: 1.1rem; }
    h4 { font-size: 1rem; }

    .container {
        padding: 0 16px;
    }

    body {
        font-size: 0.95rem;
    }

    /* Top Bar */
    .top-bar {
        font-size: 0.75rem;
        padding: 6px 0;
    }

    .top-bar a {
        display: block;
        margin-left: 0;
        margin-top: 2px;
    }

    /* Header Contact - hide on very small screens or stack */
    .header-contact {
        gap: 0.5rem;
        font-size: 0.75rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    .header-contact span {
        font-size: 0.72rem;
    }

    /* Navigation */
    .nav-wrapper {
        gap: 0.5rem;
    }

    .cta-button {
        padding: 6px 12px;
        font-size: 0.8rem;
    }

    /* Hero */
    .hero-inner {
        padding: 2.5rem 0;
    }

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

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

    .hero-badge {
        font-size: 0.7rem;
        padding: 4px 12px;
    }

    /* Buttons */
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .btn-lg {
        padding: 12px 24px;
        font-size: 0.95rem;
    }

    /* Statistics */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .stat-card {
        padding: 1.25rem 1rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .stat-label {
        font-size: 0.8rem;
    }

    /* Icons */
    .explore-icon,
    .offer-icon {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }

    .category-icon,
    .activity-icon,
    .resource-icon {
        width: 48px;
        height: 48px;
        font-size: 1.2rem;
    }

    /* Section Spacing */
    .welcome-section,
    .what-we-offer,
    .explore-section,
    .recent-news,
    .partners,
    .leadership {
        padding: 2.5rem 0;
    }

    .section-header {
        margin-bottom: 1.25rem;
    }

    /* News cards */
    .news-card-body {
        padding: 1rem;
    }

    .news-card h3 {
        font-size: 1.05rem;
    }

    .event-item {
        padding: 1rem;
    }

    .event-details h3 {
        font-size: 1.05rem;
    }

    .event-details p {
        font-size: 0.88rem;
    }

    .category-buttons {
        gap: 0.5rem;
        flex-direction: column;
    }

    .category-btn {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
        width: 100%;
        justify-content: center;
    }

    /* Explore cards: 2-col compact grid on phones */
    .explore-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .explore-card {
        padding: 1.25rem 0.75rem;
    }

    .explore-card .explore-icon {
        width: 46px;
        height: 46px;
        font-size: 1.2rem;
        margin-bottom: 0.75rem;
    }

    .explore-card h3 {
        font-size: 0.88rem;
        margin-bottom: 0.25rem;
    }

    .explore-card p {
        font-size: 0.78rem;
        line-height: 1.4;
    }

    .explore-section .section-header p {
        font-size: 0.88rem;
    }

    .explore-section {
        padding: 2.5rem 0;
    }

    .section-header h2 {
        font-size: 1.35rem;
        padding-bottom: 0.75rem;
    }

    .section-subtitle {
        font-size: 0.9rem;
    }

    .filter-header h2 {
        font-size: 1.3rem;
    }

    .filter-subtitle {
        font-size: 0.9rem;
    }

    /* Footer */
    .footer-section h3 {
        font-size: 1rem;
    }

    .footer {
        padding: 3rem 0 0;
    }

    /* Page Header */
    .page-header h1 {
        font-size: 1.5rem;
    }

    .page-header p {
        font-size: 0.9rem;
    }

    /* Article header for news detail */
    .article-header h1 {
        font-size: 1.4rem;
        line-height: 1.35;
    }

    /* Forms */
    .form-section-title h2 {
        font-size: 1.2rem;
    }

    .form-wrapper {
        padding: 1.25rem;
    }

    .form-info {
        padding: 1rem;
    }

    /* Search */
    .search-form,
    .newsletter-form {
        flex-direction: column;
    }

    .search-form input,
    .search-form select,
    .search-form button {
        width: 100%;
        margin-bottom: 0.5rem;
    }

    /* Contact Info */
    .contact-info {
        grid-template-columns: 1fr;
    }

    /* Card Grids */
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    /* Leader Card */
    .leader-card {
        padding: 2rem 1.25rem;
    }

    .leader-card h3 {
        font-size: 1.15rem;
    }

    .leader-message {
        font-size: 0.95rem;
    }

    /* CTA Section */
    .cta-section {
        padding: 2.5rem 0;
    }

    .cta-content h2 {
        font-size: 1.3rem;
    }

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

    /* Steps */
    .steps-container {
        grid-template-columns: 1fr;
    }

    .step {
        text-align: left;
    }

    .step-circle,
    .step-number {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }

    .step {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    /* Resource Cards */
    .resource-card {
        padding: 1rem;
    }

    .resources-grid--cards {
        grid-template-columns: 1fr;
    }

    /* Benefits */
    .benefits-grid,
    .values-grid,
    .reasons-grid {
        grid-template-columns: 1fr;
    }

    .benefit-item {
        text-align: center;
    }

    .benefit {
        gap: 0.75rem;
    }

    .benefit-icon {
        min-width: 30px;
    }

    /* Value and Reason Cards */
    .value-card,
    .reason-item {
        padding: 1.5rem;
    }

    /* Dropdown - tighter on small screens */
    .dropdown-menu li a {
        padding: 0 16px 0 32px;
        height: 42px;
        font-size: 0.85rem;
    }

    .nav-link {
        padding: 0 16px;
        height: 48px;
        font-size: 0.9rem;
    }

    /* Logo */
    .logo-emblem {
        width: 38px;
        height: 38px;
        font-size: 0.8rem;
    }

    .logo-img {
        width: 38px;
        height: 38px;
    }

    .logo a {
        gap: 8px;
    }

    /* FAQ */
    .faq-items {
        max-width: 100%;
    }

    .faq-item {
        margin-bottom: 0.75rem;
    }

    .faq-question {
        padding: 1rem;
        font-size: 0.95rem;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .faq-question span {
        gap: 0.5rem;
    }

    .faq-question > i:last-of-type {
        order: -1;
    }

    .faq-answer {
        padding: 0 1rem !important;
        font-size: 0.9rem;
    }

    .faq-item.active .faq-answer {
        padding: 0 1rem 1rem !important;
    }

    /* Error pages */
    .error-code {
        font-size: 4rem;
    }

    .error-section {
        padding: 3rem 0;
        min-height: auto;
    }

    /* President card - smaller image */
    .president-image img {
        width: 120px;
        height: 120px;
    }

    /* Membership cards */
    .membership-card {
        padding: 1.25rem;
    }

    .membership-card .benefits {
        padding: 1rem;
    }

    /* Info items on contact page */
    .info-item {
        padding: 1.25rem;
    }

    /* Department/Branch cards */
    .department-card,
    .branch-contact-card {
        padding: 1.25rem;
    }

    /* Share buttons */
    .share-btn {
        display: flex;
        width: 100%;
        margin-right: 0;
        margin-bottom: 0.5rem;
        justify-content: center;
    }

    /* No results/Popular searches */
    .no-results-suggestions,
    .popular-searches {
        max-width: 100%;
    }

    /* Pricing cards */
    .pricing-card {
        padding: 1.25rem;
    }

    /* Program cards */
    .program-card {
        padding: 1.25rem;
    }

    /* Division/Activity cards */
    .division-card,
    .activity,
    .discipline-card,
    .branch-card,
    .diaspora-card,
    .option {
        padding: 1.25rem;
    }

    /* Details content */
    .details-content,
    .requirement-content {
        padding: 1.25rem;
    }

    /* Article sidebar widgets */
    .article-sidebar .sidebar-widget {
        padding: 1.25rem;
    }
}

/* =========================================
   EXTRA SMALL DEVICES (360px and below)
   ========================================= */
@media (max-width: 360px) {
    h1 { font-size: 1.3rem; }
    h2 { font-size: 1.1rem; }
    h3 { font-size: 1rem; }

    .container {
        padding: 0 12px;
    }

    .logo-text {
        font-size: 1rem;
    }

    .logo-tagline {
        font-size: 0.55rem;
    }

    .logo-emblem {
        width: 34px;
        height: 34px;
    }

    .logo-img {
        width: 34px;
        height: 34px;
        font-size: 0.7rem;
    }

    .cta-button {
        padding: 5px 10px;
        font-size: 0.75rem;
    }

    .btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-number {
        font-size: 1.75rem;
    }

    .hero-inner {
        padding: 2rem 0;
    }

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

    /* Hide header contact entirely on very small screens */
    .header-top {
        padding: 4px 0;
    }

    .header-contact {
        font-size: 0.68rem;
        gap: 0.35rem;
    }

    /* President card - even smaller image */
    .president-image img {
        width: 100px;
        height: 100px;
    }

    /* Tabs go full width */
    .tab-btn {
        flex: 1 1 100%;
        text-align: center;
        padding: 0.5rem 0.75rem;
        font-size: 0.8rem;
    }

    /* Explore cards: single column on very small screens */
    .explore-cards {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    .explore-card {
        display: flex;
        flex-direction: row;
        align-items: center;
        text-align: left;
        padding: 0.85rem 1rem;
        gap: 0.85rem;
    }

    .explore-card .explore-icon {
        margin: 0;
        flex-shrink: 0;
        width: 42px;
        height: 42px;
        font-size: 1.1rem;
    }

    .explore-card h3 {
        font-size: 0.88rem;
        margin-bottom: 0.15rem;
    }

    .explore-card p {
        font-size: 0.76rem;
    }

    /* Partners grid to single column */
    .partners-grid {
        grid-template-columns: 1fr;
    }

    /* Footer contact - smaller text */
    .footer-section p,
    .footer-section a {
        font-size: 0.82rem;
    }

    /* Smaller news meta */
    .news-meta {
        flex-wrap: wrap;
    }

    /* Breadcrumb smaller */
    .breadcrumb {
        font-size: 0.8rem;
    }

    /* Even smaller article header */
    .article-header h1 {
        font-size: 1.25rem;
    }

    /* Help section contact info */
    .help-section .contact-info {
        padding: 1rem;
    }

    /* Social links */
    .social-links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* =========================================
   PRINT STYLES
   ========================================= */
@media print {
    body {
        background-color: white;
        color: black;
    }

    .top-bar,
    .navbar,
    .footer,
    .cta-section,
    .banner-alert,
    .menu-toggle,
    .cta-button,
    .scroll-top,
    .progress-bar {
        display: none;
    }

    .hero {
        background: #f5f5f5;
        color: black;
        padding: 2rem 0;
    }

    .hero-content h1,
    .hero-content p {
        color: black;
    }

    a {
        text-decoration: underline;
    }
}
