/* CSS Variables */
:root {
    --primary-purple: rgb(49, 19, 93);
    --secondary-purple: rgb(109, 49, 194);
    --accent-purple: rgb(140, 104, 238);
    --selected-purple: rgb(79, 48, 151);
    --text-purple: rgb(82, 31, 147);
    --chat-purple: rgb(75, 71, 206);
    --white: rgb(255, 255, 255);
    --off-white: rgb(252, 250, 255);
    --black: rgb(0, 0, 0);
    --border-gray: rgba(107, 107, 107, 0.7);
    --font-primary: 'Helvetica', Arial, sans-serif;
    --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Lucide Icons Global Styling */
svg[data-lucide],
i[data-lucide] {
    color: #2F145B;
    stroke: #2F145B;
}

body {
    font-family: var(--font-primary);
    font-size: 16px;
    line-height: 1.5;
    color: var(--black);
    background-color: var(--white);
    padding-top: 70px; /* Account for fixed header */
}

/* Main Content Layout */
.main-content {
    width: 100%;
    background-color: var(--white);
}

.content-wrapper {
    max-width: 1280px;
    margin: 0 auto;
    padding: 2rem 3rem;
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 2.5rem;
}

/* Left Column */
.left-column {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

/* Property Header */
.property-header {
    padding: 0;
    border: none;
}

/* Image Gallery - 1-2-1 Pattern Layout */
.image-gallery {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 0;
    height: 486px;
    width: 100%;
    max-width: 100%;
}

.main-image {
    grid-column: 1;
    grid-row: 1 / 4;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    width: 100%;
    height: 100%;
}

.main-image img {
    width: 100%;
    height: 100%;
    max-height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease, filter 0.3s ease;
    display: block;
}

.main-image img:hover {
    transform: scale(1.03);
    filter: brightness(1.05);
}

.thumbnail-grid {
    display: contents;
}

.thumbnail-grid > img,
.thumbnail-grid > .more-images {
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: 100%;
    object-fit: cover;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.4s ease, filter 0.3s ease, box-shadow 0.3s ease;
    display: block;
    overflow: hidden;
}

.thumbnail-grid img:hover,
.thumbnail-grid .more-images:hover img {
    transform: scale(1.03);
    filter: brightness(1.05);
    box-shadow: 0 4px 12px rgba(47, 20, 91, 0.15);
}

.more-images {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    cursor: pointer;
    overflow: hidden;
}

.more-images img {
    width: 100%;
    height: 100%;
    max-height: 100%;
    object-fit: cover;
    display: block;
}

.more-images .overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(47, 20, 91, 0.85), rgba(109, 49, 194, 0.75));
    backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 32px;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.more-images:hover .overlay {
    background: linear-gradient(135deg, rgba(47, 20, 91, 0.9), rgba(109, 49, 194, 0.8));
    transform: scale(0.98);
}

/* Property Details */
.property-details {
    padding: 0;
    padding-top: 2rem;
    margin-top: -3rem;
}

.property-title {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 700;
    color: var(--black);
    margin-bottom: 1.5rem;
}

.property-pills {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 0;
    padding-bottom: 2.5rem;
    border-bottom: 1px solid #E5E7EB;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    width: fit-content;
}

.location-pill {
    background: rgba(47, 20, 91, 0.1);
    color: #2F145B;
    border: 1.5px solid rgba(47, 20, 91, 0.25);
}

.location-pill:hover {
    background: rgba(47, 20, 91, 0.15);
    border-color: rgba(47, 20, 91, 0.35);
    transform: translateX(4px);
}

.capacity-pill {
    background: rgba(47, 20, 91, 0.1);
    color: #2F145B;
    border: 1.5px solid rgba(47, 20, 91, 0.25);
}

.capacity-pill:hover {
    background: rgba(47, 20, 91, 0.15);
    border-color: rgba(47, 20, 91, 0.35);
    transform: translateX(4px);
}

.pill i {
    color: #2F145B;
    stroke: #2F145B;
    flex-shrink: 0;
}

/* Feature Icons */
.feature-icons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-top: 2.5rem;
    padding: 0;
}

.feature-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    text-align: left;
}

.feature-icon {
    width: 30px;
    height: 30px;
    color: #2F145B;
    stroke: #2F145B;
    flex-shrink: 0;
}

/* Section Styles */
section {
    padding: 2.5rem 0;
    border-top: 1px solid #E5E7EB;
}

section:first-of-type {
    padding-top: 0;
    border-top: none;
}

section h2 {
    font-size: 20px;
    font-weight: 700;
    color: var(--black);
    margin-top: 0;
    margin-bottom: 8px;
}

section h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 0.75rem;
}

/* Description Section */
.description-text {
    font-size: 14px;
    line-height: 1.6;
    color: #374151;
    margin-bottom: 0.5rem;
}

.read-more {
    color: #6366F1;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
}

.read-more:hover {
    text-decoration: underline;
}

/* Commute Section */
.commute-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-top: 12px;
}

.commute-item h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.commute-item p {
    font-size: 14px;
    color: #666;
}

/* Amenities Section */
.amenities-subheading {
    font-size: 16px;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

.amenities-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 16px;
    margin-bottom: 2rem;
}

.safety-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 16px;
}

.amenity-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
}

.amenity-item svg,
.amenity-item i {
    width: 32px;
    height: 32px;
    color: #2F145B;
    stroke: #2F145B;
}

.amenity-item span {
    font-size: 12px;
    color: #374151;
}

/* House Rules */
.rule-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Map Section */
.map-container {
    width: 100%;
    height: 400px;
    border-radius: 12px;
    overflow: hidden;
}

.map-container iframe {
    border-radius: 12px;
}

/* Host Section */
.host-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 16px;
    background: #F9FAFB;
    border: 1px solid #E5E7EB;
    border-radius: 12px;
}

.host-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.host-avatar svg {
    display: block;
}

.host-info h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.host-contact {
    display: flex;
    gap: 0.75rem;
}

.contact-icon {
    background: var(--secondary-purple);
    color: var(--white);
    border: none;
    padding: 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-icon:hover {
    background: var(--accent-purple);
    transform: translateY(-2px);
}

.contact-icon svg,
.contact-icon i {
    display: block;
    color: var(--white);
    stroke: var(--white);
}

/* Cancellation Section */
.cancellation-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.policy-link {
    color: #6366F1;
    text-decoration: none;
    cursor: pointer;
}

.policy-link:hover {
    text-decoration: underline;
}

/* Right Column - Booking Card */
.right-column {
    position: relative;
}

.booking-card {
    position: sticky;
    top: 90px;
    width: 100%;
    max-width: 100%;
    background: var(--white);
    border: 1px solid rgba(47, 20, 91, 0.12);
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 4px 20px rgba(47, 20, 91, 0.08), 0 2px 8px rgba(47, 20, 91, 0.04);
}

/* Price Display */
.price-display {
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(47, 20, 91, 0.1);
}

.price {
    font-size: 36px;
    font-weight: 700;
    color: #2F145B;
}

.per-night {
    font-size: 16px;
    font-weight: 400;
    color: #6B7280;
}

/* Form Groups */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    color: #2F145B;
}

.info-icon {
    color: var(--accent-purple);
    cursor: help;
    margin-left: 0.25rem;
}

.date-input,
.reservation-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    font-size: 14px;
    font-family: var(--font-primary);
}

.date-input:focus,
.reservation-select:focus {
    outline: none;
    border-color: var(--secondary-purple);
}

/* Checkbox */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Day Selector */
.day-selector {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    justify-content: space-between;
}

.day-btn {
    flex: 1;
    height: 40px;
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    background: var(--white);
    color: #6B7280;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.day-btn.selected {
    background: #2F145B;
    color: var(--white);
    border-color: #2F145B;
}

.day-btn:hover {
    border-color: #2F145B;
    background: rgba(47, 20, 91, 0.05);
}

.day-btn.selected:hover {
    background: #4A1F87;
    border-color: #4A1F87;
}

.schedule-summary {
    font-size: 13px;
    font-weight: 600;
    color: #2F145B;
    margin-bottom: 6px;
    margin-top: 8px;
}

.schedule-info {
    font-size: 13px;
    color: #6B7280;
    margin-bottom: 4px;
}

/* Pricing Summary */
.pricing-summary {
    border-top: 1px solid rgba(47, 20, 91, 0.1);
    padding-top: 20px;
    margin-top: 20px;
    margin-bottom: 24px;
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    margin-bottom: 12px;
    color: #374151;
}

.pricing-row.total {
    font-weight: 700;
    font-size: 16px;
    color: #2F145B;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 2px solid rgba(47, 20, 91, 0.15);
}

/* CTA Button */
.cta-button {
    width: 100%;
    height: 52px;
    background: linear-gradient(135deg, #6D31C2 0%, #7C3AED 100%);
    color: rgb(255, 255, 255);
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(109, 49, 194, 0.2);
}

.cta-button:hover {
    background: linear-gradient(135deg, #5B2AA5 0%, #6D28D9 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(109, 49, 194, 0.35);
}

.cta-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(82, 31, 147, 0.2);
}

/* Fixed Chat Button */
.chat-button {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    background: #2D1B4E;
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* Responsive Design */
@media (max-width: 1280px) and (min-width: 1201px) {
    .right-column {
        max-width: 380px;
        width: 100%;
        padding: 0 1rem;
    }

    .booking-card {
        max-width: 350px;
        padding: 1.5rem;
    }

    .amenities-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }

    .footer-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1200px) {
    .content-wrapper {
        grid-template-columns: 1fr;
        max-width: 900px;
    }

    .right-column {
        order: -1;
        max-width: 100%;
        padding: 0;
    }

    .booking-card {
        position: static;
    }

    .image-gallery {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .main-image {
        width: 100%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 4/3;
        grid-row: auto;
    }

    .thumbnail-grid {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: auto;
        gap: 0.5rem;
    }

    .thumbnail-grid img,
    .more-images {
        width: 100%;
        height: auto;
        aspect-ratio: 4/3;
    }
}

@media (max-width: 1080px) {
    /* Base mobile typography */
    body {
        font-size: 16px;
        line-height: 1.6;
        overflow-x: hidden;
    }

    /* Touch targets - CRITICAL for mobile usability */
    a, button, .amenity-item {
        min-height: 44px;
        padding: 12px 16px;
        display: inline-flex;
        align-items: center;
    }

    .nav-link {
        min-height: 44px;
        padding: 10px 12px;
    }

    /* Amenities grid - 2 columns for mobile */
    .amenities-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .amenity-item {
        padding: 16px;
        min-height: 60px;
    }

    /* Form inputs - larger for mobile */
    .date-input,
    .reservation-select,
    input[type="text"],
    input[type="email"],
    select,
    textarea {
        height: 48px;
        font-size: 16px;
        padding: 12px 16px;
    }

    /* Checkboxes - larger touch targets */
    input[type="checkbox"],
    input[type="radio"] {
        width: 24px;
        height: 24px;
        margin: 10px;
    }

    .checkbox-label {
        min-height: 44px;
        padding: 8px 0;
    }

    /* Footer stacking */
    .footer-container {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 32px 16px;
    }

    /* Touch feedback */
    button:active, .btn:active, a:active {
        transform: scale(0.98);
        opacity: 0.8;
        transition: all 0.1s ease;
    }
}

/* Remove hover effects on touch devices */
@media (hover: none) {
    .main-image img:hover,
    .thumbnail-grid img:hover,
    .day-btn:hover {
        transform: none;
    }
}

@media (max-width: 768px) {
    .content-wrapper {
        padding: 1rem;
        gap: 1.5rem;
    }

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

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

    .safety-grid,
    .commute-grid {
        grid-template-columns: 1fr;
    }

    .booking-card {
        padding: 1.5rem;
    }

    .chat-button {
        width: 56px;
        height: 56px;
        font-size: 24px;
        bottom: 1rem;
        right: 1rem;
    }

    /* Typography adjustments */
    .property-title {
        font-size: 24px;
    }

    section h2 {
        font-size: 20px;
    }
}

/* Small phones */
@media (max-width: 600px) {
    .amenities-grid,
    .feature-icons {
        grid-template-columns: 1fr;
    }

    .property-title {
        font-size: 22px;
    }

    section h2 {
        font-size: 18px;
    }
}
