/**
 * ============================================================
 * PYROSHIELD FIRE SAFETY & ENGINEERING
 * RESPONSIVE ADAPTATIONS & VIEWPORT SYSTEM
 * ============================================================
 */

/* Extra Large Screens (>= 1400px) */
@media (min-width: 1400px) {
    .container {
        max-width: 1240px;
    }
}

/* Desktop & Laptop (<= 1199.98px) */
@media (max-width: 1199.98px) {
    .section-pad {
        padding: 4.5rem 0;
    }

    .brand-title {
        font-size: 1.2rem;
    }

    .site-navbar .nav-link {
        padding: 0.5rem 0.65rem !important;
        font-size: 0.9rem;
    }
}

/* Tablet (<= 991.98px) */
@media (max-width: 991.98px) {
    .site-navbar {
        min-height: 62px;
        padding: 0.35rem 0;
    }

    .navbar-brand-card {
        padding: 4px 10px;
        border-radius: 8px;
    }

    .navbar-brand-card .site-logo-img,
    .navbar-brand img,
    .navbar-brand .site-logo-img,
    .logo img {
        height: 36px;
    }

    body.site-body {
        padding-bottom: 64px; /* Space for mobile bottom action bar */
    }

    .section-pad {
        padding: 4.25rem 0; /* 68px */
    }

    .section-pad-sm {
        padding: 3rem 0;
    }

    .sec-heading,
    .section-title {
        font-size: 2rem;
    }

    .counter-section {
        padding: 2.75rem 0;
    }

    .home-enquiry-cta-section {
        padding: 3.75rem 0;
    }

    .industry-card-clean {
        height: 300px;
    }

    .mobile-nav-offcanvas {
        width: 320px;
        background-color: var(--color-white) !important;
        border-left: 1px solid var(--color-border) !important;
    }

    .mobile-nav-list .nav-link {
        font-size: 1rem;
        font-weight: 600;
        color: #344054;
        padding: 0.75rem 0;
        border-bottom: 1px solid var(--color-border);
    }
    .mobile-nav-list .nav-link:hover,
    .mobile-nav-list .nav-link.active {
        color: var(--color-primary);
    }

    .mobile-contact-card {
        background-color: var(--color-bg-alt);
        border: 1px solid var(--color-border);
    }
}

/* Mobile Devices (<= 767.98px) */
@media (max-width: 767.98px) {
    html {
        font-size: 16px;
    }

    body.site-body {
        font-size: 1rem;
        line-height: 1.62;
        padding-bottom: 64px;
    }

    .section-pad {
        padding: 3.25rem 0; /* 52px */
    }

    .sec-heading,
    .section-title {
        font-size: 1.75rem;
    }

    .sec-lead {
        font-size: 1rem;
    }

    .service-card-clean,
    .testimonial-card-clean,
    .blog-card-clean,
    .consult-form-card,
    .brand-card {
        padding: 1.25rem;
    }

    .industry-card-clean {
        height: 300px;
    }

    .about-intro-img {
        height: 300px;
    }

    .about-intro-badge {
        position: relative;
        bottom: auto;
        left: auto;
        max-width: 100%;
        margin-top: 1rem;
    }

    /* Rich text & article content responsiveness */
    .prose-readable img,
    .article-body img,
    .page-content-body img,
    .industry-full-body img,
    .project-body img {
        max-width: 100% !important;
        height: auto !important;
        border-radius: var(--radius-sm, 6px);
    }

    .prose-readable table,
    .article-body table,
    .page-content-body table {
        display: block;
        width: 100%;
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 1.5rem;
    }

    .btn-danger,
    .btn-outline-danger,
    .btn-outline-light,
    .btn-outline-dark,
    .btn-primary-eng,
    .btn-secondary-custom,
    .btn-primary-corporate:not(.gallery-filter-btn),
    .btn-secondary-corporate:not(.gallery-filter-btn),
    .btn-secondary-dark,
    .btn-whatsapp-corporate {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .home-enquiry-actions {
        flex-direction: column;
        width: 100%;
    }
    .home-enquiry-actions .btn {
        width: 100%;
    }

    .hero-actions-group {
        display: flex;
        flex-direction: row;
        align-items: center;
        width: 100%;
        gap: 0.65rem;
    }
    .hero-actions-group .btn {
        flex: 1 1 0;
        width: auto;
        padding: 0.65rem 0.75rem;
        font-size: 0.88rem;
        justify-content: center;
        white-space: nowrap;
    }

    /* Streamlined Mobile Bottom Action Bar */
    .mobile-sticky-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #FFFFFF;
        border-top: 1px solid var(--color-border);
        z-index: 1040;
        box-shadow: 0 -4px 16px rgba(16, 24, 40, 0.08);
    }

    .mobile-bar-action {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        height: 54px;
        font-weight: 600;
        font-size: 0.92rem;
        text-decoration: none;
    }

    .mobile-bar-action.btn-call {
        background-color: var(--color-white);
        color: var(--color-heading);
    }
    .mobile-bar-action.btn-call i {
        color: var(--color-primary);
    }

    .mobile-bar-action.btn-quote {
        background-color: var(--color-primary);
        color: #FFFFFF;
    }

    /* Floating buttons placement on mobile */
    .floating-whatsapp-btn {
        bottom: 74px;
        right: 16px;
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
        display: flex !important;
        z-index: 1060;
    }

    .floating-back-to-top {
        bottom: 130px;
        right: 18px;
        width: 42px;
        height: 42px;
        font-size: 1.1rem;
    }
}

/* Small Smart Phones (<= 480px) */
@media (max-width: 480px) {
    .brand-title {
        font-size: 1.15rem;
    }

    .brand-subtitle {
        display: none;
    }

    .sec-heading {
        font-size: 1.6rem;
    }

    .industry-card-clean {
        height: 240px;
    }

    .consult-form-card {
        padding: 1.25rem 1rem;
    }
}

/* Extra Small Phones (<= 360px) */
@media (max-width: 360px) {
    .hero-actions-group {
        flex-direction: column;
    }
    .hero-actions-group .btn {
        width: 100%;
        flex: none;
    }
}
