/**
 * detail-modern.css
 * Giao diện Chi tiết tin đăng Bất Động Sản (Luxury Modern Bento UI)
 * Tách biệt 100% CSS khỏi PHP - Tối ưu tốc độ & Trải nghiệm người dùng
 * Version: 20261107_1
 */

:root {
    --bds-dt-emerald: #059669;
    --bds-dt-emerald-dark: #047857;
    --bds-dt-emerald-light: #10B981;
    --bds-dt-emerald-bg: #ECFDF5;
    --bds-dt-emerald-border: #A7F3D0;
    --bds-dt-ruby: #DC2626;
    --bds-dt-ruby-dark: #B91C1C;
    --bds-dt-amber: #D97706;
    --bds-dt-text-main: #0F172A;
    --bds-dt-text-secondary: #334155;
    --bds-dt-text-muted: #64748B;
    --bds-dt-text-light: #94A3B8;
    --bds-dt-bg-page: #F8FAFC;
    --bds-dt-bg-card: #FFFFFF;
    --bds-dt-border: #E2E8F0;
    --bds-dt-border-light: #F1F5F9;
    --bds-dt-radius-sm: 8px;
    --bds-dt-radius-md: 12px;
    --bds-dt-radius-lg: 16px;
    --bds-dt-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.05);
    --bds-dt-shadow-md: 0 4px 20px -2px rgba(15, 23, 42, 0.06);
    --bds-dt-shadow-lg: 0 10px 30px -4px rgba(15, 23, 42, 0.1);
}

.bds-detail-page-wrap {
    background: var(--bds-dt-bg-page);
    padding: 20px 0 48px 0;
    color: var(--bds-dt-text-main);
}

.bds-detail-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 16px;
    box-sizing: border-box;
}

/* ==========================================================================
   1. TOP HEADER: BREADCRUMB, TIÊU ĐỀ VIP, ĐỊA CHỈ & NÚT CÔNG CỤ
   ========================================================================== */
.bds-detail-top-header {
    margin-bottom: 20px;
}

.bds-detail-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 13px;
    color: var(--bds-dt-text-muted);
    margin-bottom: 12px;
}

.bds-detail-breadcrumb a {
    color: var(--bds-dt-text-muted);
    text-decoration: none;
    transition: color 0.15s ease;
}

.bds-detail-breadcrumb a:hover {
    color: var(--bds-dt-emerald);
}

.bds-detail-breadcrumb .sep {
    color: var(--bds-dt-text-light);
    font-size: 11px;
}

.bds-detail-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 8px;
}

.bds-detail-title-left {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    flex: 1;
}

.bds-badge-vip-tag,
.bds-badge-hot-tag,
.bds-badge-tier {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    color: #FFFFFF;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    letter-spacing: 0.3px;
    flex-shrink: 0;
    white-space: nowrap;
    line-height: 1.2;
}

.bds-badge-vip-tag,
.bds-badge-tier.vip-default {
    background: linear-gradient(135deg, #DC2626 0%, #B91C1C 100%);
    box-shadow: 0 2px 6px rgba(220, 38, 38, 0.3);
}

.bds-badge-tier.vip-diamond {
    background: linear-gradient(135deg, #E11D48 0%, #BE123C 100%);
    box-shadow: 0 2px 8px rgba(225, 29, 72, 0.35);
}

.bds-badge-tier.vip-gold {
    background: linear-gradient(135deg, #D97706 0%, #B45309 100%);
    box-shadow: 0 2px 8px rgba(217, 119, 6, 0.35);
}

.bds-badge-tier.vip-silver {
    background: linear-gradient(135deg, #475569 0%, #334155 100%);
    box-shadow: 0 2px 6px rgba(71, 85, 105, 0.3);
}

.bds-badge-tier.vip-bronze {
    background: linear-gradient(135deg, #C2410C 0%, #9A3412 100%);
    box-shadow: 0 2px 6px rgba(194, 65, 12, 0.3);
}

.bds-badge-hot-tag,
.bds-badge-tier.label-hot {
    background: linear-gradient(135deg, #F97316 0%, #EA580C 100%);
    box-shadow: 0 2px 6px rgba(234, 88, 12, 0.3);
}

.bds-badge-tier.label-green {
    background: linear-gradient(135deg, #16A34A 0%, #15803D 100%);
    box-shadow: 0 2px 6px rgba(22, 163, 74, 0.3);
}

.bds-badge-tier.label-blue {
    background: linear-gradient(135deg, #0284C7 0%, #0369A1 100%);
    box-shadow: 0 2px 6px rgba(2, 132, 199, 0.3);
}

.bds-badge-svg-icon {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
}

/* Huy hiệu VIP & Nhãn dán nổi trên góc ảnh chính Bento Gallery */
.bds-gallery-badges-overlay {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: none;
    z-index: 3;
}

.bds-detail-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    line-height: 1.35;
    margin: 0;
}

.bds-detail-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.bds-action-circle-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #FFFFFF;
    border: 1px solid var(--bds-dt-border);
    color: var(--bds-dt-text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 14px;
}

.bds-action-circle-btn:hover {
    border-color: var(--bds-dt-emerald);
    color: var(--bds-dt-emerald);
    background: var(--bds-dt-emerald-bg);
    transform: translateY(-1px);
}

.bds-action-circle-btn.saved {
    color: var(--bds-dt-ruby);
    border-color: #FECACA;
    background: #FEF2F2;
}

.bds-detail-address {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--bds-dt-text-secondary);
    margin: 0;
}

.bds-detail-address i {
    color: var(--bds-dt-emerald);
    font-size: 15px;
}

.bds-detail-address a {
    color: var(--bds-dt-text-secondary);
    text-decoration: none;
}

.bds-detail-address a:hover {
    color: var(--bds-dt-emerald);
    text-decoration: underline;
}

/* ==========================================================================
   2. BỐ CỤC 2 CỘT CHÍNH (68% TRÁI - 32% SIDEBAR PHẢI)
   ========================================================================== */
.bds-detail-grid-2col {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 24px;
    align-items: start;
}

.bds-detail-main-col {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ==========================================================================
   3. BENTO GRID GALLERY (1 ẢNH LỚN + 4 ẢNH NHỎ)
   ========================================================================== */
.bds-bento-gallery {
    display: grid;
    grid-template-columns: 1.85fr 1fr;
    gap: 10px;
    height: 410px;
    border-radius: var(--bds-dt-radius-lg);
    overflow: hidden;
    background: #FFFFFF;
    padding: 8px;
    border: 1px solid var(--bds-dt-border);
    box-shadow: var(--bds-dt-shadow-sm);
}

.bds-gallery-main-hero {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: var(--bds-dt-radius-md);
    overflow: hidden;
    background: #E2E8F0;
    cursor: pointer;
}

.bds-gallery-main-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.bds-gallery-main-hero:hover img {
    transform: scale(1.02);
}

.bds-gallery-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: var(--bds-dt-text-main);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 4;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease;
}

.bds-gallery-nav-btn:hover {
    background: #FFFFFF;
    color: var(--bds-dt-emerald);
    transform: translateY(-50%) scale(1.08);
}

.bds-gallery-nav-btn.prev {
    left: 14px;
}

.bds-gallery-nav-btn.next {
    right: 14px;
}

.bds-gallery-counter-badge {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: rgba(15, 23, 42, 0.75);
    color: #FFFFFF;
    font-size: 12px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    backdrop-filter: blur(4px);
    z-index: 3;
}

.bds-gallery-360-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(15, 23, 42, 0.75);
    color: #FFFFFF;
    font-size: 12px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    backdrop-filter: blur(4px);
    z-index: 3;
    cursor: pointer;
    transition: background 0.2s ease;
}

.bds-gallery-360-badge:hover {
    background: var(--bds-dt-emerald);
}

.bds-gallery-sub-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 8px;
    height: 100%;
}

.bds-gallery-sub-item {
    position: relative;
    border-radius: var(--bds-dt-radius-sm);
    overflow: hidden;
    background: #E2E8F0;
    cursor: pointer;
}

.bds-gallery-sub-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.bds-gallery-sub-item:hover img {
    transform: scale(1.06);
}

.bds-gallery-more-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    backdrop-filter: blur(2px);
    transition: background 0.2s ease;
}

.bds-gallery-sub-item:hover .bds-gallery-more-overlay {
    background: rgba(5, 150, 105, 0.75);
}

/* ==========================================================================
   4. THANH SPECS HIGHLIGHTS (SLIDER TRƯỢT NGANG HIỆN ĐẠI - KHÔNG XUỐNG DÒNG)
   ========================================================================== */
.bds-specs-slider-wrap {
    position: relative;
    background: #FFFFFF;
    border: 1px solid var(--bds-dt-border);
    border-radius: var(--bds-dt-radius-lg);
    padding: 12px 16px;
    box-shadow: var(--bds-dt-shadow-sm);
    display: flex;
    align-items: center;
}

.bds-specs-highlight-bar {
    display: flex;
    align-items: center;
    gap: 0;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    width: 100%;
    cursor: grab;
    user-select: none;
}

.bds-specs-highlight-bar.is-dragging {
    cursor: grabbing;
    scroll-behavior: auto;
    scroll-snap-type: none;
}

.bds-specs-highlight-bar::-webkit-scrollbar {
    display: none;
}

.bds-spec-box {
    flex: 0 0 auto;
    min-width: 154px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 18px;
    border-right: 1px solid var(--bds-dt-border-light);
    scroll-snap-align: start;
    box-sizing: border-box;
}

.bds-spec-box:first-child {
    padding-left: 4px;
}

.bds-spec-box:last-child {
    border-right: none;
    padding-right: 4px;
}

.bds-spec-box-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--bds-dt-emerald-bg);
    color: var(--bds-dt-emerald);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex-shrink: 0;
}

.bds-spec-box-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.bds-spec-box-val {
    font-size: 14px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    white-space: nowrap;
    line-height: 1.3;
}

.bds-spec-box-lbl {
    font-size: 12.5px;
    color: var(--bds-dt-text-muted);
    white-space: nowrap;
    line-height: 1.3;
}

.bds-specs-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #FFFFFF;
    border: 1px solid var(--bds-dt-border);
    color: var(--bds-dt-text-secondary);
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 4;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
    transition: all 0.2s ease;
}

.bds-specs-nav-btn.is-visible {
    display: inline-flex;
}

.bds-specs-nav-btn:hover {
    background: var(--bds-dt-emerald);
    border-color: var(--bds-dt-emerald);
    color: #FFFFFF;
}

.bds-specs-nav-btn.prev {
    left: 6px;
}

.bds-specs-nav-btn.next {
    right: 6px;
}

/* ==========================================================================
   5. KHỐI SECTION NỘI DUNG CHUẨN (MÔ TẢ, CHI TIẾT, BẢN ĐỒ, LÃI VAY)
   ========================================================================== */
.bds-detail-card {
    background: #FFFFFF;
    border: 1px solid var(--bds-dt-border);
    border-radius: var(--bds-dt-radius-lg);
    padding: 22px 24px;
    box-shadow: var(--bds-dt-shadow-sm);
}

.bds-section-heading {
    font-size: 18px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    margin: 0 0 16px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.bds-section-heading::before {
    content: "";
    display: inline-block;
    width: 4px;
    height: 20px;
    background: var(--bds-dt-emerald);
    border-radius: 4px;
}

/* Thông tin mô tả */
.bds-description-body {
    font-size: 15px;
    line-height: 1.7;
    color: var(--bds-dt-text-secondary);
    word-break: break-word;
}

.bds-desc-highlights {
    list-style: none;
    padding: 14px 16px;
    margin: 16px 0 0 0;
    background: #F8FAFC;
    border-radius: var(--bds-dt-radius-md);
    border: 1px solid var(--bds-dt-border-light);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.bds-desc-highlights li {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 14px;
    color: var(--bds-dt-text-secondary);
}

.bds-desc-highlights li i {
    color: var(--bds-dt-emerald);
    margin-top: 4px;
    flex-shrink: 0;
}

/* Bảng Thông tin chi tiết (2 Cột) */
.bds-specs-table-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 32px;
    row-gap: 0;
}

.bds-specs-table-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 0;
    border-bottom: 1px solid var(--bds-dt-border-light);
    font-size: 14px;
}

.bds-specs-table-label {
    color: var(--bds-dt-text-muted);
}

.bds-specs-table-val {
    font-weight: 600;
    color: var(--bds-dt-text-main);
    text-align: right;
}

/* Vị trí & Tiện ích xung quanh */
.bds-location-grid {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 20px;
    align-items: stretch;
}

.bds-map-box {
    position: relative;
    border-radius: var(--bds-dt-radius-md);
    overflow: hidden;
    min-height: 230px;
    background: #E2E8F0;
    border: 1px solid var(--bds-dt-border);
}

.bds-map-canvas {
    width: 100%;
    height: 100%;
    min-height: 230px;
}

.bds-map-btn-large {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: var(--bds-dt-emerald);
    color: #FFFFFF !important;
    font-size: 12px;
    font-weight: 600;
    padding: 7px 14px;
    border-radius: 20px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.35);
    z-index: 5;
    transition: background 0.2s ease;
}

.bds-map-btn-large:hover {
    background: var(--bds-dt-emerald-dark);
}

.bds-nearby-box h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    margin: 0 0 12px 0;
}

.bds-nearby-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bds-nearby-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    padding-bottom: 8px;
    border-bottom: 1px dashed var(--bds-dt-border-light);
}

.bds-nearby-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.bds-nearby-name {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--bds-dt-text-secondary);
    font-weight: 500;
}

.bds-nearby-name i {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--bds-dt-emerald-bg);
    color: var(--bds-dt-emerald);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.bds-nearby-dist {
    font-weight: 600;
    color: var(--bds-dt-text-muted);
}

/* ==========================================================================
   6. BỘ TÍNH KHOẢN VAY MUA NHÀ HIỆN ĐẠI (4 THÔNG SỐ + PILLS LÃI SUẤT)
   ========================================================================== */
.bds-loan-calc-grid {
    display: grid;
    grid-template-columns: 1.38fr 1fr;
    gap: 22px;
    align-items: stretch;
}

.bds-loan-left-col {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 14px;
}

.bds-loan-inputs-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px 14px;
}

.bds-loan-field label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--bds-dt-text-secondary);
    margin-bottom: 6px;
}

.bds-loan-input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.bds-loan-input,
.bds-loan-select {
    width: 100%;
    height: 42px;
    border: 1px solid var(--bds-dt-border);
    border-radius: var(--bds-dt-radius-sm);
    padding: 0 12px;
    font-size: 14px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    background: #F8FAFC;
    font-family: inherit;
    box-sizing: border-box;
    outline: none;
    transition: all 0.2s ease;
}

.bds-loan-input.has-suffix {
    padding-right: 58px;
}

.bds-loan-input:focus,
.bds-loan-select:focus {
    background: #FFFFFF;
    border-color: var(--bds-dt-emerald);
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.12);
}

.bds-loan-input-suffix {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: #E2E8F0;
    color: var(--bds-dt-text-secondary);
    font-size: 11px;
    font-weight: 700;
    padding: 3px 7px;
    border-radius: 5px;
    pointer-events: none;
}

.bds-loan-rate-pills {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 2px;
}

.bds-loan-rate-pills-lbl {
    font-size: 12px;
    color: var(--bds-dt-text-muted);
    margin-right: 4px;
}

.bds-rate-pill-btn {
    border: 1px solid var(--bds-dt-border);
    background: #FFFFFF;
    color: var(--bds-dt-text-secondary);
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.bds-rate-pill-btn:hover {
    border-color: var(--bds-dt-emerald);
    color: var(--bds-dt-emerald);
}

.bds-rate-pill-btn.is-active {
    background: var(--bds-dt-emerald);
    border-color: var(--bds-dt-emerald);
    color: #FFFFFF;
}

.bds-loan-result-card {
    background: linear-gradient(135deg, #ECFDF5 0%, #F0FDF4 100%);
    border: 1px solid var(--bds-dt-emerald-border);
    border-radius: var(--bds-dt-radius-md);
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 8px;
}

.bds-loan-result-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.bds-loan-result-lbl {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--bds-dt-emerald-dark);
}

.bds-loan-rate-badge {
    background: #D1FAE5;
    color: var(--bds-dt-emerald-dark);
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
}

.bds-loan-result-val {
    font-size: 24px;
    font-weight: 800;
    color: var(--bds-dt-emerald-dark);
    line-height: 1.2;
}

.bds-loan-ratio-bar {
    height: 7px;
    width: 100%;
    background: #FDE68A;
    border-radius: 99px;
    overflow: hidden;
    display: flex;
}

.bds-loan-ratio-principal {
    width: 38%;
    height: 100%;
    background: var(--bds-dt-emerald);
    transition: width 0.3s ease;
}

.bds-loan-ratio-interest {
    width: 62%;
    height: 100%;
    background: #F59E0B;
    transition: width 0.3s ease;
}

.bds-loan-result-sub {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12.5px;
    color: var(--bds-dt-text-secondary);
}

.bds-loan-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 4px;
}

.bds-loan-dot.principal {
    background: var(--bds-dt-emerald);
}

.bds-loan-dot.interest {
    background: #F59E0B;
}

.bds-loan-result-meta {
    font-size: 12px;
    color: var(--bds-dt-text-muted);
    padding-top: 6px;
    border-top: 1px dashed #A7F3D0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ==========================================================================
   7. CỘT PHẢI: SIDEBAR GIÁ, MÔI GIỚI, DỊCH VỤ & TIN CÙNG KHU VỰC
   ========================================================================== */
.bds-detail-sidebar-col {
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: sticky;
    top: 80px;
}

.bds-sidebar-card {
    background: #FFFFFF;
    border: 1px solid var(--bds-dt-border);
    border-radius: var(--bds-dt-radius-lg);
    padding: 20px;
    box-shadow: var(--bds-dt-shadow-sm);
}

/* Khung Giá bán */
.bds-price-box-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--bds-dt-border-light);
}

.bds-price-label {
    font-size: 12px;
    color: var(--bds-dt-text-muted);
    display: block;
    margin-bottom: 2px;
}

.bds-price-big {
    font-size: 26px;
    font-weight: 800;
    color: var(--bds-dt-ruby);
    line-height: 1.2;
}

.bds-price-unit {
    font-size: 13px;
    color: var(--bds-dt-text-muted);
    margin-top: 2px;
}

.bds-compare-price-btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 600;
    color: var(--bds-dt-emerald-dark);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: var(--bds-dt-radius-sm);
    background: var(--bds-dt-emerald-bg);
    transition: all 0.2s ease;
}

.bds-compare-price-btn:hover {
    background: #D1FAE5;
    color: var(--bds-dt-emerald-dark);
}

/* Thông tin Môi giới / Chính chủ */
.bds-agent-profile {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}

.bds-agent-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--bds-dt-emerald);
    flex-shrink: 0;
}

.bds-agent-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.bds-agent-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
}

.bds-agent-name i {
    color: var(--bds-dt-emerald);
    font-size: 14px;
}

.bds-agent-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    color: var(--bds-dt-emerald-dark);
    font-weight: 600;
}

.bds-agent-verified-cccd {
    font-size: 12px;
    color: var(--bds-dt-text-muted);
    display: flex;
    align-items: center;
    gap: 5px;
}

.bds-agent-verified-cccd i {
    color: var(--bds-dt-emerald);
}

/* Nút Gọi điện & Zalo */
.bds-btn-call-primary {
    width: 100%;
    height: 46px;
    background: var(--bds-dt-ruby);
    color: #FFFFFF !important;
    border: none;
    border-radius: 24px;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    text-decoration: none !important;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35);
    transition: all 0.2s ease;
    margin-bottom: 10px;
}

.bds-btn-call-primary:hover {
    background: var(--bds-dt-ruby-dark);
    transform: translateY(-1px);
}

.bds-agent-sub-btns {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 14px;
}

.bds-btn-sub-contact {
    height: 38px;
    border-radius: 20px;
    border: 1px solid var(--bds-dt-border);
    background: #FFFFFF;
    color: var(--bds-dt-text-main) !important;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-decoration: none !important;
    transition: all 0.15s ease;
}

.bds-btn-sub-contact:hover {
    border-color: var(--bds-dt-emerald);
    color: var(--bds-dt-emerald) !important;
    background: var(--bds-dt-emerald-bg);
}

.bds-agent-response-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: var(--bds-dt-text-muted);
    padding-top: 12px;
    border-top: 1px dashed var(--bds-dt-border-light);
}

.bds-agent-response-meta strong {
    color: var(--bds-dt-text-main);
}

/* Dịch vụ hỗ trợ */
.bds-support-services-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.bds-support-service-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: #F8FAFC;
    border: 1px solid var(--bds-dt-border-light);
    border-radius: var(--bds-dt-radius-sm);
    color: var(--bds-dt-text-main);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.15s ease;
}

.bds-support-service-item:hover {
    background: var(--bds-dt-emerald-bg);
    border-color: var(--bds-dt-emerald-border);
    color: var(--bds-dt-emerald-dark);
}

.bds-support-service-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bds-support-service-left i {
    color: var(--bds-dt-emerald);
    font-size: 15px;
    width: 20px;
    text-align: center;
}

/* Khám phá dự án lân cận */
.bds-nearby-proj-banner {
    background: linear-gradient(135deg, #ECFDF5 0%, #D1FAE5 100%);
    border: 1px solid var(--bds-dt-emerald-border);
    border-radius: var(--bds-dt-radius-lg);
    padding: 18px;
    position: relative;
    overflow: hidden;
}

.bds-nearby-proj-banner h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--bds-dt-text-main);
    margin: 0 0 4px 0;
}

.bds-nearby-proj-banner p {
    font-size: 12px;
    color: var(--bds-dt-text-secondary);
    margin: 0 0 12px 0;
}

.bds-nearby-proj-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--bds-dt-emerald);
    color: #FFFFFF !important;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 16px;
    text-decoration: none;
}

/* Tin rao cùng khu vực (Sidebar) */
.bds-area-mini-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.bds-area-mini-item {
    display: flex;
    gap: 10px;
    text-decoration: none;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--bds-dt-border-light);
}

.bds-area-mini-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.bds-area-mini-thumb {
    width: 76px;
    height: 56px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    background: #E2E8F0;
}

.bds-area-mini-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bds-area-mini-info {
    flex: 1;
    min-width: 0;
}

.bds-area-mini-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--bds-dt-text-main);
    margin: 0 0 4px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.35;
}

.bds-area-mini-item:hover .bds-area-mini-title {
    color: var(--bds-dt-emerald);
}

.bds-area-mini-price {
    font-size: 13px;
    font-weight: 700;
    color: var(--bds-dt-ruby);
}

/* ==========================================================================
   8. BẤT ĐỘNG SẢN TƯƠNG TỰ (4 CARD GRID FULL WIDTH)
   ========================================================================== */
.bds-detail-bottom-wrap {
    margin-top: 28px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.bds-similar-grid-4col {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.bds-sim-card {
    background: #FFFFFF;
    border: 1px solid var(--bds-dt-border);
    border-radius: var(--bds-dt-radius-md);
    overflow: hidden;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    transition: all 0.25s ease;
    box-shadow: var(--bds-dt-shadow-sm);
}

.bds-sim-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--bds-dt-shadow-md);
    border-color: #CBD5E1;
}

.bds-sim-thumb {
    height: 155px;
    position: relative;
    background: #E2E8F0;
    overflow: hidden;
}

.bds-sim-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.bds-sim-card:hover .bds-sim-thumb img {
    transform: scale(1.05);
}

.bds-sim-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--bds-dt-ruby);
    color: #FFFFFF;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
}

.bds-sim-badge.green {
    background: var(--bds-dt-emerald);
}

.bds-sim-body {
    padding: 12px;
    display: flex;
    flex-direction: column;
    flex: 1;
    justify-content: space-between;
}

.bds-sim-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--bds-dt-text-main);
    margin: 0 0 6px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.bds-sim-loc {
    font-size: 12px;
    color: var(--bds-dt-text-muted);
    margin-bottom: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bds-sim-loc i {
    color: var(--bds-dt-emerald);
}

.bds-sim-specs {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    color: var(--bds-dt-text-secondary);
    margin-bottom: 8px;
}

.bds-sim-price {
    font-size: 16px;
    font-weight: 800;
    color: var(--bds-dt-ruby);
}

/* ==========================================================================
   9. LIGHTBOX MODAL XEM ẢNH TOÀN MÀN HÌNH
   ========================================================================== */
.bds-lightbox-modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.92);
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    backdrop-filter: blur(6px);
}

.bds-lightbox-modal.active,
.bds-lightbox-modal.is-open {
    display: flex;
}

.bds-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    border: none;
    color: #FFFFFF;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    z-index: 10;
}

.bds-lightbox-nav:hover {
    background: var(--bds-dt-emerald);
}

.bds-lightbox-nav.prev {
    left: 28px;
}

.bds-lightbox-nav.next {
    right: 28px;
}

.bds-desc-phone-mask {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--bds-dt-emerald-bg);
    color: var(--bds-dt-emerald-dark);
    font-weight: 700;
    padding: 2px 10px;
    border-radius: 14px;
    border: 1px solid var(--bds-dt-emerald-border);
    cursor: pointer;
    font-size: 14px;
}

.bds-desc-phone-mask:hover {
    background: #D1FAE5;
}

.bds-notice-compact-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding: 14px 18px;
    background: #FFFBEB;
    border: 1px solid #FDE68A;
    border-radius: var(--bds-dt-radius-md);
    font-size: 13px;
    color: #92400E;
}

.bds-notice-compact-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.bds-notice-compact-left i {
    font-size: 18px;
    color: #D97706;
}

.bds-notice-report-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 16px;
    background: #FFFFFF;
    border: 1px solid #FCD34D;
    color: #B45309 !important;
    font-weight: 600;
    font-size: 12px;
    text-decoration: none !important;
    white-space: nowrap;
}

.bds-notice-report-link:hover {
    background: #FEF3C7;
}

.bds-cta-bottom-banner {
    background: linear-gradient(95deg, #ECFDF5 0%, #FFFFFF 55%, #F0FDF4 100%);
    border: 1px solid var(--bds-dt-emerald-border);
    border-radius: var(--bds-dt-radius-lg);
    padding: 22px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    box-shadow: var(--bds-dt-shadow-sm);
}

.bds-cta-bottom-title h3 {
    font-size: 20px;
    font-weight: 800;
    color: var(--bds-dt-text-main);
    margin: 0 0 4px 0;
}

.bds-cta-bottom-title p {
    font-size: 14px;
    color: var(--bds-dt-text-secondary);
    margin: 0;
}

.bds-cta-bottom-perks {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.bds-cta-perk-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--bds-dt-text-main);
}

.bds-cta-perk-item i {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: #D1FAE5;
    color: var(--bds-dt-emerald-dark);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.bds-cta-post-btn {
    background: var(--bds-dt-ruby);
    color: #FFFFFF !important;
    font-size: 14px;
    font-weight: 700;
    padding: 11px 24px;
    border-radius: 24px;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.3);
    transition: all 0.2s ease;
}

.bds-cta-post-btn:hover {
    background: var(--bds-dt-ruby-dark);
    transform: translateY(-1px);
}

.bds-lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #FFFFFF;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bds-lightbox-close:hover {
    background: var(--bds-dt-ruby);
}

.bds-lightbox-img-wrap {
    max-width: 85vw;
    max-height: 80vh;
    position: relative;
}

.bds-lightbox-img-wrap img {
    max-width: 85vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 8px;
}

.bds-lightbox-caption {
    color: #FFFFFF;
    margin-top: 12px;
    font-size: 14px;
    font-weight: 600;
}

/* ==========================================================================
   10. RESPONSIVE DESIGN
   ========================================================================== */
@media (max-width: 1024px) {
    .bds-detail-grid-2col {
        grid-template-columns: 1fr;
    }
    .bds-detail-sidebar-col {
        position: static;
    }
    .bds-similar-grid-4col {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .bds-bento-gallery {
        grid-template-columns: 1fr;
        height: auto;
    }
    .bds-gallery-main-hero {
        height: 260px;
    }
    .bds-gallery-sub-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: 70px;
        height: 70px;
    }
    .bds-specs-table-grid,
    .bds-location-grid,
    .bds-loan-calc-grid {
        grid-template-columns: 1fr;
    }
    .bds-loan-inputs-row {
        grid-template-columns: 1fr;
    }
    .bds-similar-grid-4col {
        grid-template-columns: 1fr;
    }
}
