:root {
    --primary-color: #0A2540;
    --secondary-color: #A9C2EB;
    --bg-color: #F8FAFC;
    --text-color: #333333;
    --white: #FFFFFF;
    --border-radius: 12px;
    --transition-speed: 0.3s;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body { 
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 
    background-color: var(--bg-color); 
    color: var(--text-color); 
    overflow-x: hidden; 
}

a { text-decoration: none; color: inherit; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

.header { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 20px 50px; 
    background-color: rgba(255, 255, 255, 0.9); 
    backdrop-filter: blur(12px); 
    -webkit-backdrop-filter: blur(12px); 
    position: sticky; 
    top: 0; 
    z-index: 1000; 
    border-bottom: 1px solid rgba(169, 194, 235, 0.2); 
    transition: all var(--transition-speed) ease; 
}

.header.scrolled { 
    padding: 12px 50px; 
    box-shadow: 0 10px 30px rgba(10, 37, 64, 0.08); 
    background-color: rgba(255, 255, 255, 0.98); 
}

.logo img { height: 45px; border-radius: 8px; transition: 0.3s; }
.logo a:hover img { transform: scale(1.05); }

.nav-links { display: flex; align-items: center; gap: 25px; }
.nav-item { position: relative; color: var(--text-color); font-weight: 500; font-size: 1.05em; transition: 0.3s; }
.nav-item:hover { color: var(--primary-color); }
.nav-item::after { content: ''; position: absolute; width: 0; height: 2px; bottom: -5px; left: 0; background-color: var(--primary-color); transition: 0.3s; }
.nav-item:hover::after { width: 100%; }

.btn-secondary, .btn-primary { padding: 10px 22px; border-radius: 30px; font-weight: bold; border: none; cursor: pointer; transition: 0.3s; display: inline-block; }
.btn-secondary { background-color: #EBF3FF; color: var(--primary-color); }
.btn-secondary:hover { background-color: #D6E6FE; transform: translateY(-2px); }
.btn-primary { background: linear-gradient(135deg, var(--primary-color), #174276); color: var(--white); box-shadow: 0 4px 15px rgba(10, 37, 64, 0.2); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(10, 37, 64, 0.3); }

.hero-modern { 
    position: relative; 
    padding: 100px 20px 140px 20px; 
    background: linear-gradient(180deg, #0A2540 0%, #174276 70%, var(--bg-color) 100%); 
    color: var(--white); 
    text-align: center; 
}

.hero-content { position: relative; z-index: 2; margin-bottom: 35px; }

.hero-modern h1 { 
    font-size: 3em; 
    font-weight: 800; 
    margin-bottom: 15px; 
    line-height: 1.2; 
    background: linear-gradient(to right, #ffffff, #A9C2EB); 
    -webkit-background-clip: text; 
    -webkit-text-fill-color: transparent; 
}

.hero-modern p { font-size: 1.15em; color: #E2E8F0; max-width: 650px; margin: 0 auto; }

.floating-search { 
    position: relative; 
    z-index: 10; 
    max-width: 850px; 
    margin: 0 auto 30px auto; 
    background: rgba(255, 255, 255, 0.98); 
    padding: 18px; 
    border-radius: 24px; 
    box-shadow: 0 20px 40px rgba(10, 37, 64, 0.15); 
    display: flex; 
    flex-direction: column; 
    gap: 12px; 
    border: 1px solid rgba(255, 255, 255, 0.8); 
}

.floating-search select { 
    border: 1px solid #CBD5E1; 
    padding: 14px 18px; 
    background: #F8FAFC; 
    border-radius: 14px; 
    flex: 1; 
    font-size: 0.95em; 
    color: var(--primary-color); 
    font-weight: 500; 
    outline: none; 
    cursor: pointer; 
    transition: 0.3s; 
}
.floating-search select:hover { background: #E2E8F0; }

.floating-search button { 
    background: linear-gradient(135deg, var(--primary-color), #174276); 
    color: var(--white); 
    border: none; 
    padding: 15px; 
    border-radius: 14px; 
    font-weight: bold; 
    font-size: 1.05em; 
    cursor: pointer; 
    transition: 0.3s; 
    box-shadow: 0 10px 20px rgba(10,37,64,0.2); 
}
.floating-search button:hover { transform: translateY(-2px); background: #174276; }

.section-tag { 
    display: inline-block; 
    background: #EBF3FF; 
    color: var(--primary-color); 
    padding: 6px 18px; 
    border-radius: 20px; 
    font-size: 0.9em; 
    font-weight: 700; 
    margin-bottom: 15px; 
    text-transform: uppercase; 
}

.category-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 25px; margin-top: 50px; }
.category-header h2 { color: var(--primary-color); font-size: 1.8em; }

.view-all { color: var(--primary-color); font-weight: bold; font-size: 1.05em; transition: 0.3s; }
.view-all:hover { color: #174276; transform: translateX(5px); }

/* --- ROOM GRID & CARD --- */
.room-grid { 
    display: grid; 
    grid-template-columns: repeat(4, minmax(0, 1fr)); 
    gap: 25px; 
}

.room-card { 
    background: var(--white); 
    border-radius: 16px; 
    overflow: hidden; 
    box-shadow: 0 8px 25px rgba(10, 37, 64, 0.06); 
    transition: all 0.35s cubic-bezier(0.165, 0.84, 0.44, 1); 
    border: 1px solid rgba(169, 194, 235, 0.2); 
    display: flex; 
    flex-direction: column; 
}

.room-card:hover { 
    transform: translateY(-6px); 
    box-shadow: 0 15px 35px rgba(10, 37, 64, 0.12); 
    border-color: rgba(10, 37, 64, 0.2); 
}

.image-wrapper { position: relative; overflow: hidden; height: 180px; }

.room-card img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1); 
}
.room-card:hover img { transform: scale(1.08); }

.district-badge { 
    position: absolute; 
    top: 12px; 
    right: 12px; 
    background: rgba(10, 37, 64, 0.85); 
    backdrop-filter: blur(6px); 
    color: var(--white); 
    padding: 5px 12px; 
    border-radius: 20px; 
    font-size: 0.8em; 
    font-weight: 700; 
    z-index: 2; 
}

.room-info { padding: 18px; display: flex; flex-direction: column; flex: 1; }

.room-info h3 { 
    font-size: 1.1em; 
    margin-bottom: 8px; 
    color: var(--primary-color); 
    font-weight: 700; 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    transition: color 0.2s ease; 
}
.room-card:hover .room-info h3 { color: #174276; }

.room-meta { 
    font-size: 0.85em; 
    color: #64748B; 
    margin-bottom: 15px; 
    display: flex; 
    align-items: center; 
    gap: 6px; 
}

.room-price-wrapper { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    border-top: 1px solid #F1F5F9; 
    padding-top: 12px; 
    margin-top: auto; 
}

.room-price { color: var(--primary-color); font-weight: 800; font-size: 1.2em; }
.room-price span { font-size: 0.55em; color: #64748B; font-weight: normal; }

.btn-view-room { 
    background: #EBF3FF; 
    color: var(--primary-color); 
    padding: 8px 14px; 
    border-radius: 20px; 
    font-weight: 700; 
    font-size: 0.85em; 
    transition: all 0.3s ease; 
    display: inline-flex; 
    align-items: center; 
    gap: 4px; 
}
.room-card:hover .btn-view-room { background: var(--primary-color); color: white; transform: translateX(2px); }

.cta-container { 
    max-width: 1100px; 
    margin: 80px auto; 
    background: linear-gradient(135deg, var(--primary-color), #174276); 
    color: var(--white); 
    border-radius: 20px; 
    padding: 40px 50px; 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    box-shadow: 0 15px 35px rgba(10,37,64,0.2); 
}

.btn-cta { 
    background: var(--white); 
    color: var(--primary-color); 
    padding: 14px 30px; 
    border-radius: 25px; 
    font-weight: bold; 
    font-size: 1.05em; 
    transition: all 0.3s ease; 
    box-shadow: 0 5px 15px rgba(0,0,0,0.1); 
}
.btn-cta:hover { transform: translateY(-3px); background: #F8FAFC; }

.footer { 
    background: #0A2540; 
    color: #A9C2EB; 
    padding: 60px 20px 40px 20px; 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
    gap: 40px; 
}
.footer h4 { color: var(--white); margin-bottom: 20px; }
.footer a { color: #A9C2EB; display: block; margin-bottom: 10px; transition: 0.3s; }
.footer a:hover { color: var(--white); transform: translateX(5px); }

.search-page-container { display: flex; height: calc(100vh - 85px); overflow: hidden; }
.search-sidebar { width: 400px; background: var(--white); border-right: 1px solid #E2E8F0; display: flex; flex-direction: column; z-index: 10; }
.search-filters { padding: 20px; border-bottom: 1px solid #E2E8F0; background: #F8FAFC; }
.search-filters select { width: 100%; padding: 12px 15px; border: 1px solid #CBD5E1; border-radius: 8px; margin-bottom: 15px; outline: none; }
.btn-filter-submit { width: 100%; background: var(--primary-color); color: var(--white); border: none; padding: 12px; border-radius: 8px; font-weight: bold; cursor: pointer; transition: 0.3s; }
.search-results-list { flex: 1; overflow-y: auto; padding: 20px; }
.search-map-area { flex: 1; position: relative; padding: 20px; background: var(--bg-color); }
#searchMap { width: 100%; height: 100%; border-radius: 12px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
.empty-msg { padding: 20px; color: #94a3b8; font-style: italic; text-align: center; }

/* --- RESPONSIVE MOBILE & TABLET (HIỂN THỊ 2 CỘT NGANG TRÊN ĐIỆN THOẠI) --- */
@media (max-width: 992px) {
    .header { padding: 15px 20px; flex-wrap: wrap; justify-content: center; gap: 15px; }
    .nav-links { flex-wrap: wrap; justify-content: center; gap: 10px; }
    .hero-modern h1 { font-size: 2.2em; }
    .floating-search { flex-direction: column; border-radius: 20px; padding: 15px; }
    .floating-search select, .floating-search button { width: 100%; border-radius: 12px; }
    .search-page-container { flex-direction: column; height: auto; overflow: visible; }
    .search-sidebar { width: 100%; border-right: none; height: auto; }
    .search-results-list { max-height: 500px; }
    .search-map-area { height: 400px; padding: 10px 20px; }
    .cta-container { flex-direction: column; text-align: center; gap: 20px; padding: 30px 20px; margin: 40px 20px; }
}

@media (max-width: 768px) {
    .room-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 10px !important;
    }
    .room-card .room-info {
        padding: 10px !important;
    }
    .room-card .image-wrapper {
        height: 120px !important;
    }
    .room-card .room-info h3 {
        font-size: 0.9em !important;
        margin-bottom: 4px !important;
    }
    .room-card .room-meta {
        font-size: 0.75em !important;
        margin-bottom: 8px !important;
    }
    .room-card .room-price {
        font-size: 1em !important;
    }
    .btn-view-room {
        padding: 4px 8px !important;
        font-size: 0.75em !important;
    }
    .district-badge {
        top: 6px !important;
        right: 6px !important;
        padding: 2px 6px !important;
        font-size: 0.65em !important;
    }
}
@media (max-width: 768px) {
    .header {
        padding: 10px 15px !important;
    }
    .logo img {
        height: 35px !important;
    }
    .nav-links {
        gap: 12px !important;
        font-size: 0.9em !important;
    }
    .floating-search select, 
    .floating-search input, 
    .floating-search button {
        padding: 10px 12px !important;
        font-size: 0.85em !important;
        border-radius: 10px !important;
    }
}
/* --- TỐI ƯU LOGO FOOTER --- */
.footer .footer-brand img {
    height: 40px !important; /* Thu nhỏ logo lại vừa vặn */
    width: auto !important;
    border-radius: 6px;
    margin-bottom: 15px;
    object-fit: contain;
}