﻿/* ==========================================================
   AIRBNB CURRENT DESIGN SYSTEM (Global Design Tokens)
   ========================================================== */

:root {
    /* === 1. FONT FAMILY === */
    --ff-primary: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    /* === 2. FONT SIZES (PX to REM) === */
    --fs-2xs: 0.625rem;  /* 10px */
    --fs-xs: 0.75rem;    /* 12px */
    --fs-sm: 0.875rem;   /* 14px */
    --fs-base: 1rem;     /* 16px */
    --fs-md: 1.125rem;   /* 18px */
    --fs-lg: 1.25rem;    /* 20px */
    --fs-xl: 1.5rem;     /* 24px */

    /* === 3. FONT WEIGHTS === */
    --fw-normal: 400;
    --fw-medium: 500;
    --fw-semibold: 600;
    --fw-bold: 700;

    /* === 4. LINE HEIGHTS === */
    --lh-tight: 1.2;
    --lh-base: 1.5;
    --lh-relaxed: 1.6;

    /* === 5. COLORS (Exact Airbnb Palette) === */
    --color-brand: #FF385C;         /* Primary Red */
    --color-bg-white: #FFFFFF;
    --color-bg-gray: #F7F7F7;       /* Page Background */
    --color-text-primary: #222222;  /* Almost Black */
    --color-text-secondary: #717171; /* Muted Gray */
    --color-border: #DDDDDD;        /* Light Border */

    /* === 6. BORDER RADIUS (All buttons fully rounded now) === */
    --radius-pill: 32px;
    --radius-card: 16px;    /* Rounded Cards */
    --radius-btn: 32px;     /* Fully rounded buttons */

    /* === 7. SHADOWS === */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 6px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 6px 20px rgba(0, 0, 0, 0.2);

    /* === 8. SPACING SCALE (Multiples of 4px) === */
    --spacing-1: 4px;
    --spacing-2: 8px;
    --spacing-3: 12px;
    --spacing-4: 16px;
    --spacing-5: 20px;
    --spacing-6: 24px;
    --spacing-8: 32px;
    --spacing-10: 40px;
}

/* ==========================================================
   GLOBAL RESETS & TYPOGRAPHY
   ========================================================== */
html, body {
    font-family: var(--ff-primary);
    color: var(--color-text-primary);
    background-color: var(--color-bg-gray) !important; /* Match Airbnb bg */
    margin: 0;
    padding: 0;
}

/* Utility Typography */
.fs-xs { font-size: var(--fs-xs) !important; line-height: var(--lh-tight) !important; }
.fs-sm { font-size: var(--fs-sm) !important; line-height: var(--lh-base) !important; }
.fs-base { font-size: var(--fs-base) !important; line-height: var(--lh-relaxed); }
.fw-bold { font-weight: var(--fw-bold) !important; }

/* ==========================================================
   BOOTSTRAP OVERRIDES (All buttons & inputs fully rounded)
   ========================================================== */
.form-control, .form-select, .btn {
    border-radius: var(--radius-btn) !important;
}

.pagination .page-link {
    color: var(--color-text-primary);
    border: none;
    border-radius: var(--radius-pill) !important; /* Fully rounded pagination */
    font-size: var(--fs-sm);
    padding: var(--spacing-2) var(--spacing-3);
    background: transparent;
}
.pagination .page-item.active .page-link {
    background-color: var(--color-text-primary);
    border-color: var(--color-text-primary);
    color: var(--color-bg-white);
}

/* ==========================================================
   APPLICATION CONTAINERS
   ========================================================== */

.hero-wrapper {
    padding-top: 4rem;
    padding-bottom: 3rem;
    background-color: var(--color-bg-white);
    /* Removed container constraints, letting it span full width */
    width: 100%;
    overflow-x: hidden;
}

.airbnb-full-width-container {
    width: 100%;
    max-width: 1760px;
    margin-inline: auto;
    padding-inline: 40px;
    box-sizing: border-box;
}

/* --- Airbnb Search Bar --- */
.airbnb-search-container {
    max-width: 850px;
    margin: 0 auto;
    background: var(--color-bg-white);
    border-radius: var(--radius-pill);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-border);
    padding: var(--spacing-2);
    display: flex;
    align-items: center;
}

.search-segment {
    flex: 1;
    padding: var(--spacing-3) var(--spacing-6);
    position: relative;
}

.search-segment:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 20%;
    height: 60%;
    width: 1px;
    background: var(--color-border);
}

.search-label {
    display: block;
    font-size: var(--fs-xs) !important;
    font-weight: var(--fw-bold) !important; /* add !important here */
    color: var(--color-text-primary);
}

.search-value {
    display: block;
    font-size: var(--fs-sm) !important;
    font-weight: var(--fw-medium);
    color: var(--color-text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-btn-wrapper {
    margin-left: auto;
    padding-left: var(--spacing-2);
}

.airbnb-search-btn {
    background: var(--color-brand);
    color: var(--color-bg-white);
    border: none;
    border-radius: 50%; /* Always a perfect circle */
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.airbnb-search-btn i {
    font-size: var(--fs-md) !important;
}

/* --- Airbnb Grid Layout --- */
.airbnb-row-container {
    display: grid;
    grid-template-columns: repeat(6,minmax(0,1fr));
    gap: 24px;
}

@media (max-width:1700px) {
    .airbnb-row-container {
        grid-template-columns: repeat(5,1fr);
    }
}

@media (max-width:1400px) {
    .airbnb-row-container {
        grid-template-columns: repeat(4,1fr);
    }
}

@media (max-width:1120px) {
    .airbnb-row-container {
        grid-template-columns: repeat(3,1fr);
    }
}

@media (max-width:768px) {
    .airbnb-row-container {
        grid-template-columns: repeat(2,1fr);
    }
}

@media (max-width:576px) {
    .airbnb-row-container {
        grid-template-columns: 1fr;
    }
}

.airbnb-col {
    min-width: 0;
}

/* --- Airbnb Card System --- */
.airbnb-listing-card {
    border-radius: var(--radius-card);
    overflow: hidden;
    background: var(--color-bg-white);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.airbnb-card-image-wrapper {
    aspect-ratio: 1/1;
    padding-top: 0;
    overflow: hidden;
    border-radius: 16px;
}

.airbnb-card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.airbnb-card-content {
    padding: var(--spacing-3) 0;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.airbnb-title {
    font-size: var(--fs-base) !important;
    font-weight: var(--fw-semibold);
    color: var(--color-text-primary);
    line-height: var(--lh-tight);
    margin-bottom: var(--spacing-1);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.airbnb-subtitle {
    font-size: var(--fs-sm) !important;
    color: var(--color-text-secondary);
    line-height: var(--lh-base);
    margin-bottom: var(--spacing-1);
}

.airbnb-price-wrapper {
    display: flex;
    align-items: baseline;
    gap: var(--spacing-1);
    margin-top: auto;
    padding-top: var(--spacing-2);
}

.airbnb-price {
    font-size: var(--fs-base) !important;
    font-weight: var(--fw-normal);
    color: var(--color-text-primary);
}

.airbnb-price-label {
    font-size: var(--fs-sm) !important;
    color: var(--color-text-secondary);
}

.airbnb-action-btn {
    background: var(--color-text-primary);
    color: var(--color-bg-white);
    border-radius: var(--radius-btn) !important; /* Fully rounded button */
    font-size: var(--fs-sm) !important;
    font-weight: var(--fw-medium);
    padding: var(--spacing-2) var(--spacing-3);
    border: none;
    width: 100%;
    margin-top: var(--spacing-3);
    text-align: center;
    display: block;
    text-decoration: none;
}

.airbnb-action-btn:disabled {
    background: var(--color-border);
    color: var(--color-text-secondary);
    cursor: not-allowed;
}

/* Mobile Search Bar Collapse */
@media (max-width: 768px) {
    .airbnb-search-container {
        flex-direction: column;
        padding: 0;
        border: none;
        box-shadow: none;
        border-radius: 0;
        background: transparent;
    }
    .search-segment {
        background: var(--color-bg-white);
        border: 1px solid var(--color-border);
        border-radius: var(--radius-btn);
        margin-bottom: var(--spacing-2);
        width: 100%;
    }
    .search-segment:not(:last-child)::after { display: none; }
    .search-btn-wrapper {
        margin: var(--spacing-2) auto 0;
        width: 100%;
    }
}

