/* Default: Hide Menu Toggle on Desktop */
.menu-toggle {
    display: none;
}

/* --- Large Screens (Big Monitors > 1600px) --- */
@media (min-width: 1600px) {
    header, .hero, .about-us, .contact-section, .main-footer, .property-details-container {
        padding-left: 15%;
        padding-right: 15%;
    }
    
    .hero-content h1 {
        font-size: 64px;
    }
}

/* --- Laptop / Tablet Landscape (Max 1200px) --- */
@media (max-width: 1200px) {
    .hero-content h1 {
        font-size: 42px;
    }
    
    .person-img {
        width: 380px;
        height: 380px;
    }
    
    .circle-bg {
        width: 420px;
        height: 420px;
    }
}

/* --- Tablet / Mobile Menu Breakpoint (Max 992px) --- */
@media (max-width: 992px) {
    /* Header & Navigation */
    header {
        padding: 15px 5%;
        justify-content: space-between;
        position: fixed; /* Sticky header for mobile */
        background-color: #fff;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }

    .menu-toggle {
        display: block;
        font-size: 24px;
        cursor: pointer;
        color: #333;
        order: 3;
    }
    
    .logo { order: 1; }
    
    .btn-contact { 
        order: 2; 
        margin-right: 20px; 
        padding: 8px 15px;
        font-size: 12px;
    }
    
    nav {
        display: none; /* Hidden by default on mobile */
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: #fff;
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        padding: 20px 0;
        order: 4;
    }

    nav.active {
        display: block;
        animation: slideDown 0.3s ease forwards;
    }

    nav ul {
        flex-direction: column;
        align-items: center;
    }

    nav ul li {
        margin: 15px 0;
        width: 100%;
        text-align: center;
    }
    
    /* Dropdown in Mobile */
    .dropdown-content {
        position: relative;
        box-shadow: none;
        background-color: #f9f9f9;
        text-align: center;
        padding: 0;
    }
    
    .dropdown:hover .dropdown-content {
        display: block;
    }

    /* Hero Section */
    .hero {
        flex-direction: column;
        padding: 120px 5% 60px; /* Extra top padding for fixed header */
        text-align: center;
    }

    .hero-content {
        margin-bottom: 50px;
        max-width: 100%;
    }

    .sub-heading { justify-content: center; }
    .email-form { margin: 0 auto; }
    .contact-container { flex-direction: column; }
    .form-row { flex-direction: column; }
    .footer-container { grid-template-columns: 1fr 1fr; }

    /* Property Details */
    .property-details-container {
        padding: 100px 5% 60px;
    }
    .details-wrapper {
        flex-direction: column;
        padding: 30px;
        gap: 30px;
    }
    .details-image img { height: auto; max-height: 400px; }

    /* Room Gallery */
    .room-gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

/* --- Small Tablets / Large Phones (Max 768px) --- */
@media (max-width: 768px) {
    .about-container { flex-direction: column; }
    .about-image-wrapper, .about-text { width: 100%; padding: 0; }
    .main-about-img { margin-bottom: 30px; }
    .experience-badge { right: 0; bottom: 10px; }
    
    .stats-bar { flex-wrap: wrap; justify-content: center; gap: 30px; }
    .stat-item { width: 45%; flex-direction: column; text-align: center; }
    .stat-icon { margin-bottom: 10px; }
    
    .footer-container { grid-template-columns: 1fr; text-align: center; }
    .footer-subscribe { justify-content: center; }
    .footer-cta { flex-direction: column; text-align: center; padding: 30px; }
    .cta-button { margin-top: 20px; }

    /* Property Details */
    .details-wrapper { padding: 20px; }
    .details-info h1 { font-size: 26px; }
}

/* --- Small Mobile Phones (Max 480px) --- */
@media (max-width: 480px) {
    .logo { font-size: 20px; }
    .btn-contact { display: none; } /* Hide contact button on very small screens */
    .menu-toggle { margin-left: auto; }
    
    .hero-content h1 { font-size: 32px; }
    .circle-bg { width: 280px; height: 280px; }
    .person-img { width: 260px; height: 260px; }
    
    .email-form { flex-direction: column; }
    .email-form input { border-radius: 5px; margin-bottom: 10px; width: 100%; }
    .btn-get-started { width: 100%; padding: 15px; border-radius: 5px; }
    
    .stat-item { width: 100%; }
    
    .partners-bar .logo-grid { flex-wrap: wrap; gap: 20px; }
    .partners-bar .logo-grid img { height: 20px; }
    
    .contact-section, .about-us, .main-footer {
        padding: 60px 5%;
    }

    /* Property Details */
    .amenities-list { grid-template-columns: 1fr; }
    .action-buttons { flex-direction: column; }
    .btn-inquire, .btn-call { width: 100%; text-align: center; }
    .details-price-badge { 
        font-size: 14px; 
        padding: 8px 15px;
        top: 15px; left: 15px;
    }
    .units-table th, .units-table td { font-size: 12px; padding: 8px; }

    /* Room Gallery */
    .room-gallery-grid { grid-template-columns: 1fr; }
    .room-card { height: 300px; }
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Properties Page Responsive */
@media (max-width: 1200px) {
    .property-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .property-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .property-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    .page-header h1 {
        font-size: 32px;
    }
}

@media (max-width: 480px) {
    .property-grid {
        grid-template-columns: repeat(1, 1fr);
    }
    .property-card {
        aspect-ratio: 4 / 3; /* Less tall on mobile */
    }
    .property-card img { object-position: center; }
}

/* Accessibility: Disable animation if user prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
    .animate-on-scroll, .animate-fade-up, .animate-fade-down, .animate-fade-left, .animate-fade-right, .animate-zoom-in {
        transition: none;
        opacity: 1;
        transform: none;
    }
}

/* Reviews Page Responsive */
@media (max-width: 992px) {
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .reviews-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Dashboard Responsive --- */
@media (max-width: 992px) {
    .dashboard-container {
        position: relative;
        overflow-x: hidden;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: -280px; /* Hide sidebar off-screen */
        height: 100vh;
        z-index: 1000;
        transition: left 0.3s ease;
        width: 260px;
    }

    .sidebar.active {
        left: 0;
        box-shadow: 5px 0 15px rgba(0,0,0,0.1);
    }

    .main-content {
        width: 100%;
        padding: 20px;
    }

    .dashboard-toggle {
        display: block;
    }
    
    .sidebar-overlay.active {
        display: block;
    }
    
    /* Login Page Adjustments */
    .login-page-container {
        padding: 40px 20px;
    }
}

@media (max-width: 768px) {
    /* Admin Table to Card View Transformation */
    .table-controls {
        flex-direction: column;
    }

    .table-container {
        background: transparent !important;
        box-shadow: none !important;
        padding: 0 !important;
    }

    .table-container .units-table thead {
        display: none;
    }

    .table-container .units-table tbody tr {
        display: block;
        background: #fff;
        margin-bottom: 20px;
        border-radius: 10px;
        padding: 20px;
        box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    }

    .table-container .units-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 12px 0;
        border-bottom: 1px solid #eee;
        text-align: right;
        font-size: 14px;
    }

    .table-container .units-table td:last-child {
        border-bottom: none;
        justify-content: flex-end;
    }

    .table-container .units-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #333;
        text-align: left;
        margin-right: 15px;
    }

    /* Specific styling for Image column in Properties */
    .table-container .units-table td[data-label="Image"] {
        justify-content: center;
        background: #f9f9f9;
        border-radius: 8px;
        margin-bottom: 10px;
        padding: 15px;
    }

    .table-container .units-table td[data-label="Image"]::before {
        display: none;
    }

    .table-container .units-table td[data-label="Image"] img {
        width: 100%;
        max-width: 100%;
        height: 200px;
        object-fit: cover;
        border-radius: 5px;
    }
}

@media (max-width: 480px) {
    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .dashboard-header h2 {
        font-size: 20px;
    }
    
    .stats-grid { grid-template-columns: 1fr; }
    .charts-grid { grid-template-columns: 1fr; }
}