/*
 * Rev Property Group - Mobile-First Responsive Breakpoints
 * Strict responsive rules for 320px, 375px, 390px, 414px, 768px, 1024px, 1440px.
 */

/* 1. Large Screens & Laptops (max-width: 1200px) */
@media (max-width: 1200px) {
    .rpg-grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
    .rpg-type-cards-grid,
    .rpg-services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .rpg-footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }
}

/* 2. Tablet & Medium Screens (max-width: 991px) */
@media (max-width: 991px) {
    .rpg-top-bar {
        display: none; /* Hide top bar on mobile/tablet to save vertical real estate */
    }

    .rpg-main-navigation {
        display: none; /* Hidden on tablet/mobile; mobile drawer handles navigation */
    }

    .rpg-mobile-toggle {
        display: block;
    }

    .rpg-hero-title {
        font-size: 2.2rem;
    }

    .rpg-single-layout {
        grid-template-columns: 1fr;
    }

    .rpg-single-sidebar-col {
        order: -1; /* Place contact panel right above full descriptions for high conversion */
        margin-bottom: 24px;
    }

    .rpg-single-title-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .rpg-single-price-col {
        text-align: left;
        margin-top: 10px;
    }

    .rpg-gallery-main {
        height: 380px;
    }

    .rpg-grid-2 {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    .rpg-loc-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 16px !important;
    }
}

/* 3. Small Tablets & Phablets (max-width: 767px) */
@media (max-width: 767px) {
    .rpg-container {
        padding-left: 18px;
        padding-right: 18px;
    }

    .rpg-section {
        padding-top: 40px;
        padding-bottom: 40px;
    }

    .rpg-hero-section {
        padding: 50px 0 70px 0;
    }

    .rpg-hero-title {
        font-size: 1.85rem;
    }

    .rpg-hero-subtitle {
        font-size: 0.95rem;
        margin-bottom: 24px;
    }

    .rpg-grid-3 {
        grid-template-columns: 1fr;
    }

    .rpg-type-cards-grid,
    .rpg-services-grid,
    .rpg-loc-grid {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

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

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

    .rpg-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .rpg-cta-box {
        padding: 34px 20px;
    }

    .rpg-cta-title {
        font-size: 1.6rem;
    }

    .rpg-cta-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .rpg-cta-buttons .rpg-btn {
        width: 100%;
        justify-content: center;
    }

    .rpg-gallery-main {
        height: 280px;
    }
}

/* 4. Standard Mobile Screens (375px - 414px: iPhone, Pixel, Galaxy) */
@media (max-width: 480px) {
    .rpg-container {
        padding-left: 14px;
        padding-right: 14px;
    }

    .rpg-header-btn span {
        display: none; /* Keep header compact on small screens */
    }

    .rpg-header-btn {
        padding: 8px 12px;
    }

    .rpg-logo-main {
        font-size: 1.05rem;
    }

    .rpg-hero-title {
        font-size: 1.55rem;
        letter-spacing: -0.3px;
    }

    .rpg-section-title {
        font-size: 1.5rem;
    }

    .rpg-single-title {
        font-size: 1.5rem;
    }

    .rpg-single-price {
        font-size: 1.7rem;
    }

    .rpg-pcard-body {
        padding: 16px;
    }

    .rpg-pcard-price {
        font-size: 1.25rem;
    }

    .rpg-pcard-specs {
        padding: 8px 10px;
        gap: 6px;
    }

    .rpg-spec-val {
        font-size: 0.8rem;
    }

    .rpg-spec-lbl {
        font-size: 0.72rem;
    }

    .rpg-facts-grid {
        grid-template-columns: 1fr 1fr;
    }

    .rpg-gallery-main {
        height: 230px;
    }

    .rpg-stat-banner {
        padding: 24px;
    }

    .rpg-stat-num {
        font-size: 1.8rem;
    }

    .rpg-modal-box {
        padding: 0;
        margin: 10px;
    }

    .rpg-modal-body {
        padding: 16px;
    }
}

/* 5. Ultra Compact Mobile Screens (320px - 360px: iPhone SE, older compact phones) */
@media (max-width: 360px) {
    .rpg-container {
        padding-left: 10px;
        padding-right: 10px;
    }

    .rpg-logo-main {
        font-size: 0.95rem;
    }

    .rpg-hero-title {
        font-size: 1.35rem;
    }

    .rpg-facts-grid {
        grid-template-columns: 1fr;
    }

    .rpg-pcard-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
    }

    .rpg-pcard-btn-view,
    .rpg-pcard-btn-wa {
        width: 100%;
        justify-content: center;
    }

    .rpg-pcard-specs {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }
}

/* ==========================================================================
   Mobile Phone Devices Only: Brand & Contact Column Footer
   ========================================================================== */
@media (max-width: 768px) {
    .site-footer .footer-grid,
    .rpg-site-footer .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }

    .site-footer .footer-col:not(.footer-col--brand),
    .rpg-site-footer .footer-col:not(.footer-col--brand) {
        display: none !important;
    }

    .site-footer .footer-col--brand,
    .rpg-site-footer .footer-col--brand {
        display: block !important;
        width: 100% !important;
        padding-right: 0 !important;
        margin: 0 auto !important;
    }

    .site-footer .footer-main,
    .rpg-site-footer .footer-main {
        padding: 44px 0 28px 0 !important;
    }

    .site-footer .footer-legal,
    .rpg-site-footer .footer-legal {
        display: none !important;
    }

    .site-footer .footer-bottom__inner,
    .rpg-site-footer .footer-bottom__inner {
        justify-content: center !important;
        text-align: center !important;
    }

    .site-footer .footer-bottom__copy,
    .rpg-site-footer .footer-bottom__copy {
        text-align: center !important;
        width: 100% !important;
        margin: 0 !important;
        font-size: 0.8rem !important;
    }
}
