:root {
    --brand-primary: #D36135;      /* Terracotta */
    --brand-primary-dark: #b8532c; /* darker shade for hover states */
    --brand-secondary: #1A3A2B;    /* Deep Forest */
    --brand-accent: #F4F0EA;       /* Warm Sand */
    --brand-dark: #2B2D2F;         /* Charcoal */
}

body {
    background-color: var(--brand-accent);
    color: var(--brand-dark);
    font-family: 'Segoe UI', Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--brand-secondary);
    font-weight: 700;
}

/* ---------- Navbar ---------- */
.site-navbar {
    background-color: var(--brand-secondary) !important;
}
.site-navbar .nav-link,
.site-navbar .navbar-toggler-icon {
    color: #fff !important;
}
.site-navbar .nav-link:hover {
    color: var(--brand-primary) !important;
}
.brand-logo {
    height: 38px;
    width: auto;
}

/* ---------- Buttons ---------- */
.btn-danger {
    background-color: var(--brand-primary);
    border-color: var(--brand-primary);
}
.btn-danger:hover,
.btn-danger:focus,
.btn-danger:active {
    background-color: var(--brand-primary-dark) !important;
    border-color: var(--brand-primary-dark) !important;
}

.btn-outline-danger {
    color: var(--brand-primary);
    border-color: var(--brand-primary);
}
.btn-outline-danger:hover {
    background-color: var(--brand-primary);
    border-color: var(--brand-primary);
    color: #fff;
}

.text-danger {
    color: var(--brand-primary) !important;
}

/* ---------- Cards & surfaces ---------- */
.card {
    border-radius: 12px;
    border: none;
    background-color: #ffffff;
}

.hero-banner {
    background-color: #ffffff;
    border-radius: 16px;
    border: 1px solid rgba(0,0,0,0.05);
}

/* ---------- Footer ---------- */
footer {
    background-color: #ffffff !important;
    color: var(--brand-dark);
}

/* ---------- Badges ---------- */
.badge.bg-success { background-color: var(--brand-secondary) !important; }
.badge.bg-secondary { background-color: #8a8f8c !important; }

/* ---------- Alerts ---------- */
.alert-success {
    background-color: #e5efe9;
    border-color: var(--brand-secondary);
    color: var(--brand-secondary);
}
.alert-danger {
    background-color: #fbe9e4;
    border-color: var(--brand-primary);
    color: var(--brand-primary-dark);
}

/* ---------- City autocomplete ---------- */
.city-suggestions {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 1000;
    max-height: 220px;
    overflow-y: auto;
    text-align: left;
}
.city-suggestion-item {
    padding: 8px 12px;
    cursor: pointer;
}
.city-suggestion-item:hover {
    background-color: var(--brand-accent);
}

/* ---------- Airbnb-style search pill ---------- */
.search-pill {
    display: flex;
    align-items: stretch;
    background: #fff;
    border-radius: 999px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.12);
    border: 1px solid #e5e0d8;
    max-width: 850px;
    margin: 0 auto;
    position: relative;
}
.search-segment {
    flex: 1;
    padding: 10px 24px;
    cursor: pointer;
    text-align: left;
    border-radius: 999px;
    transition: background 0.15s;
    min-width: 0;
}
.search-segment:hover {
    background: #f2ede4;
}
.search-segment.active {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.search-segment label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: var(--brand-secondary);
    margin-bottom: 2px;
}
.search-value, .search-segment input {
    border: none;
    outline: none;
    background: transparent;
    font-size: 14px;
    color: var(--brand-dark);
    width: 100%;
    padding: 0;
}
.search-value.search-placeholder { color: #888; }
.search-divider {
    width: 1px;
    background: #ddd;
    margin: 10px 0;
}
.search-submit-btn {
    background: var(--brand-primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    margin: 6px 8px 6px 0;
    flex-shrink: 0;
    align-self: center;
    font-size: 18px;
    cursor: pointer;
}
.search-submit-btn:hover { background: var(--brand-primary-dark); }

.search-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 12px);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 28px rgba(0,0,0,0.18);
    z-index: 1000;
    padding: 20px;
    text-align: left;
}
.search-dropdown.show { display: block; }
#home_when_dropdown { left: 50%; transform: translateX(-50%); }
#home_who_dropdown { right: 0; width: 320px; }

/* Calendar */
.cal-months { display: flex; gap: 32px; }
.cal-month-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; font-weight: 700; }
.cal-nav-btn { background: none; border: 1px solid #ddd; border-radius: 50%; width: 28px; height: 28px; cursor: pointer; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 32px); gap: 2px; }
.cal-dow { font-size: 11px; color: #888; text-align: center; padding-bottom: 4px; }
.cal-day {
    width: 32px; height: 32px; display: flex; align-items: center; justify-content: center;
    border-radius: 50%; cursor: pointer; font-size: 13px;
}
.cal-day:hover:not(.disabled) { background: #f2ede4; }
.cal-day.disabled { color: #ccc; cursor: not-allowed; }
.cal-day.empty { visibility: hidden; }
.cal-day.selected { background: var(--brand-primary); color: #fff; }
.cal-day.in-range { background: #f7ded3; border-radius: 0; }

/* Guest counter */
.counter-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid #eee; }
.counter-row:last-child { border-bottom: none; }
.counter-row strong { display: block; font-size: 14px; }
.counter-row span.sub { font-size: 12px; color: #888; }
.counter-btn {
    width: 30px; height: 30px; border-radius: 50%; border: 1px solid #bbb; background: #fff;
    font-size: 16px; cursor: pointer; color: var(--brand-dark);
}
.counter-btn:disabled { opacity: 0.3; cursor: not-allowed; }
.counter-value { width: 24px; text-align: center; display: inline-block; }

@media (max-width: 767px) {
    .search-pill { flex-direction: column; border-radius: 20px; }
    .search-segment { border-radius: 12px; }
    .search-divider { display: none; }
    .search-submit-btn { width: 100%; border-radius: 12px; margin: 8px 0 0; }
    #dropdown-when, #dropdown-who { left: 0; right: 0; transform: none; width: auto; }
    .cal-months { flex-direction: column; gap: 12px; }
}

/* ---------- Hero headline badge + highlight ---------- */
.hero-badge {
    display: inline-block;
    background: #fff;
    border: 1px solid #e5e0d8;
    border-radius: 999px;
    padding: 6px 18px;
    font-size: 13px;
    color: var(--brand-secondary);
    margin-bottom: 20px;
}
.hero-headline {
    font-size: 2.6rem;
    line-height: 1.25;
    max-width: 780px;
    margin: 0 auto 12px;
}
.text-brand-highlight {
    color: var(--brand-primary);
}
@media (max-width: 767px) {
    .hero-headline { font-size: 1.8rem; }
}

/* ---------- Compact search fields (filter sidebar / booking widget) ---------- */
.search-field-wrap { position: relative; }
.search-value-box {
    border: 1px solid #ced4da;
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    background: #fff;
    font-size: 14px;
    color: var(--brand-dark);
}
.search-value-box.search-placeholder { color: #6c757d; }
.search-dropdown-block {
    left: 0;
    right: 0;
    width: auto;
    min-width: 280px;
}

/* ---------- Listing page: stats row, amenities grid, phone reveal ---------- */
.listing-stats-row {
    color: var(--brand-dark);
    font-size: 15px;
}
.property-type-pill {
    background: #e5efe9;
    color: var(--brand-secondary);
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 999px;
}
.amenities-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 24px;
}
.amenity-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--brand-dark);
}
.amenity-icon {
    font-size: 18px;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
}
.reveal-phone-btn {
    background: var(--brand-secondary);
    color: #fff;
    border-radius: 999px;
    padding: 8px 18px;
    font-weight: 600;
    border: none;
}
.reveal-phone-btn:hover {
    background: #12281d;
    color: #fff;
}
@media (max-width: 575px) {
    .amenities-grid { grid-template-columns: 1fr; }
}

/* ---------- Split-screen auth pages (login/register) ---------- */
.full-bleed-body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
.full-bleed-body > .container-fluid {
    flex: 1;
    display: flex;
    flex-direction: column;
}
.auth-split-wrapper {
    display: flex;
    flex: 1;
}
.auth-image-panel {
    flex: 1 1 50%;
    position: relative;
    background-size: cover;
    background-position: center;
    background-color: var(--brand-secondary); /* fallback tint base if no photo yet */
}
.auth-image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(211,97,53,0.80), rgba(26,58,43,0.85));
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 40px;
    color: #fff;
}
.auth-panel-logo {
    height: 34px;
    filter: drop-shadow(0 1px 4px rgba(0,0,0,0.45));
}
.auth-tagline h2 {
    color: #fff;
    font-size: 2rem;
    font-weight: 700;
}
.auth-tagline p {
    color: rgba(255,255,255,0.9);
    font-size: 1rem;
    max-width: 380px;
}
.auth-form-panel {
    flex: 1 1 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 24px;
    background: var(--brand-accent);
}
.auth-form-inner {
    max-width: 400px;
    width: 100%;
}
.auth-submit-btn {
    border-radius: 999px;
    padding: 10px;
    font-weight: 600;
}
@media (max-width: 767px) {
    .full-bleed-body { display: block; min-height: auto; }
    .full-bleed-body > .container-fluid { display: block; }
    .auth-split-wrapper { flex: none; }
    .auth-form-panel { padding: 32px 20px; }
}

/* ---------- Guest/Host role toggle (signup page) ---------- */
.role-toggle {
    display: flex;
    gap: 10px;
}
.role-toggle-btn {
    flex: 1;
    padding: 10px 16px;
    border: 1px solid #ced4da;
    border-radius: 10px;
    background: #fff;
    color: var(--brand-dark);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}
.role-toggle-btn.active {
    border-color: var(--brand-primary);
    background: #fbe9e4;
    color: var(--brand-primary);
}
