:root {
    --bg: #f3f6fb;
    --surface: #ffffff;
    --text: #1f2937;
    --muted: #6b7280;
    --primary: #0f766e;
    --primary-strong: #115e59;
    --accent: #d97706;
    --line: #e5e7eb;
    --shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: radial-gradient(circle at top, #e7f6f4 0%, var(--bg) 35%);
    color: var(--text);
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(1200px, 92%);
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 9999;
    background: #ffffff;
    border-bottom: 1px solid #e7e9f2;
    box-shadow: 0 2px 10px rgba(20, 24, 40, 0.08);
}

.topbar {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) auto auto;
    align-items: center;
    gap: 18px;
    min-height: 82px;
    padding: 12px 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    font-weight: 800;
    font-size: 17px;
    line-height: 1.2;
    color: #1f2937;
}

.brand span:last-child,
.brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.2;
}

.brand strong {
    font-size: 17px;
    line-height: 1.2;
    white-space: normal;
}

.brand small {
    margin-top: 4px;
    color: #6b7280;
    font-size: 13px;
    font-weight: 600;
}

.brand-logo {
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    border-radius: 8px;
    object-fit: contain;
    border: 0;
    background: #fff;
}

.brand-logo-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    font-size: 20px;
    font-weight: 800;
}

.menu {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid #d7dbea;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.menu-toggle span {
    width: 18px;
    height: 2px;
    background: var(--text);
    display: block;
    border-radius: 2px;
}

.menu a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 8px 12px;
    border-radius: 8px;
    color: #4b5563;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

.menu a:hover,
.menu a.active {
    color: #4f46e5;
    background: #eef2ff;
}

.btn {
    border: none;
    border-radius: 10px;
    padding: 11px 18px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-strong);
}

.btn-outline {
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
}

.hero-panel .btn-outline {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.32);
}

.hero {
    padding: 60px 0 30px;
}

.hero-panel {
    background: linear-gradient(135deg, #0f766e 0%, #164e63 100%);
    color: #fff;
    border-radius: 18px;
    padding: 40px;
    box-shadow: var(--shadow);
}

.hero h1 {
    margin: 0 0 10px;
    font-size: clamp(28px, 5vw, 46px);
}

.hero p {
    margin: 0 0 24px;
    color: #d9f5f1;
    font-size: 18px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.quick-search {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;
    padding: 14px;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr auto;
    gap: 10px;
}

.quick-search input,
.quick-search select,
.filter-grid input,
.filter-grid select,
.contact-form input,
.contact-form textarea {
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 11px 12px;
    width: 100%;
    font: inherit;
}

.section {
    padding: 28px 0;
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.section h2 {
    margin: 0;
    font-size: clamp(22px, 3vw, 30px);
}

.muted {
    color: var(--muted);
}

.grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.property-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform .2s ease, box-shadow .2s ease;
}

.property-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 35px rgba(15, 23, 42, 0.12);
}

.property-image {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: #dbeafe;
}

.property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.badge {
    position: absolute;
    left: 10px;
    top: 10px;
    background: rgba(0, 0, 0, 0.72);
    color: #fff;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 12px;
}

.property-body {
    padding: 14px;
}

.property-title {
    margin: 0 0 8px;
    font-size: 18px;
}

.property-meta {
    font-size: 14px;
    color: var(--muted);
    margin-bottom: 12px;
}

.property-price {
    font-size: 24px;
    color: var(--primary-strong);
    font-weight: 800;
    margin-bottom: 10px;
}

.filters-panel,
.white-panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 16px;
    box-shadow: var(--shadow);
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.filter-actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}

.pagination a,
.pagination span {
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 10px;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.pagination .active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.property-detail {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 18px;
}

.gallery-main {
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid var(--line);
    margin-bottom: 10px;
}

.gallery-main img {
    width: 100%;
    max-height: 520px;
    object-fit: cover;
}

.gallery-thumbs {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 8px;
}

.gallery-thumbs img {
    width: 100%;
    border-radius: 10px;
    border: 1px solid var(--line);
    cursor: pointer;
    height: 80px;
    object-fit: cover;
}

.detail-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 14px;
}

.detail-item {
    background: #f9fafb;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 10px;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    gap: 18px;
}

.contact-form textarea {
    min-height: 140px;
    resize: vertical;
}

.alert {
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 12px;
    font-weight: 600;
}

.alert.success {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.alert.error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.site-footer {
    margin-top: 28px;
    border-top: 1px solid var(--line);
    background: #fff;
}

.site-footer .container {
    padding: 24px 0;
    display: grid;
    grid-template-columns: 1.2fr .9fr .9fr;
    gap: 18px;
}

.copyright {
    border-top: 1px solid var(--line);
    padding: 12px 0 20px;
    font-size: 14px;
    color: var(--muted);
    text-align: center;
}

@media (max-width: 980px) {
    .quick-search {
        grid-template-columns: 1fr;
    }

    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .property-detail {
        grid-template-columns: 1fr;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .site-footer .container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .topbar {
        grid-template-columns: minmax(0, 1fr) auto;
        min-height: 74px;
        align-items: center;
        position: relative;
        gap: 10px;
        padding: 10px 0;
    }

    .brand {
        gap: 10px;
        font-size: 14px;
    }

    .brand strong {
        font-size: 14px;
    }

    .brand small {
        font-size: 12px;
    }

    .brand-logo {
        width: 42px;
        height: 42px;
        flex-basis: 42px;
    }

    .menu-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .menu {
        display: none;
        grid-column: 1 / -1;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
        padding-top: 10px;
    }

    .menu.menu-open {
        display: flex;
    }

    .menu a {
        width: 100%;
        text-align: center;
    }

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

    .detail-list {
        grid-template-columns: 1fr;
    }
}
