body {
    background: url('images/logo/hero-bg2.png') no-repeat center center fixed;
    background-size: cover;
}

.calendar-container {
    max-width: 900px;
    margin: 120px auto 40px; /* Increased to 120px for desktop fixed navbar */
    padding: 0 20px;
}
.calendar-header {
    text-align: center;
    margin-bottom: 40px;
    padding-top: 40px; /* Reduced since clock is now above it */
}

.realtime-clock {
    background: rgba(44, 85, 48, 0.95);
    color: white;
    padding: 15px 20px;
    font-family: 'Open Sans', sans-serif;
    border-radius: 12px 12px 0 0;
    margin: -15px -20px 20px -20px; /* Offset to align with parent padding */
    border-bottom: 2px solid #36673a;
    display: flex;
    flex-direction: column;
}

@media (max-width: 768px) {
    .realtime-clock {
        margin: -15px -15px 15px -15px;
        padding: 10px 15px;
    }
}
.calendar-header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: #ffffff;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}
.calendar-header p {
    color: #f0f0f0;
    font-size: 1.1rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

/* Custom Calendar Styles */
.custom-calendar {
    background: #2c5530eb;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.calendar-controls button {
    background: #2c5530;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    transition: background 0.3s;
}
.calendar-controls button:hover {
    background: #1e3b21;
}
#current-month-year {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    color: #ffffff;
    font-weight: 600;
}
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}
.calendar-day-header {
    text-align: center;
    font-weight: 600;
    color: #f97803;
    padding: 10px 0;
}
.calendar-day {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    padding: 5px;
    font-size: 1.1rem;
    position: relative;
    background: #2c5530; /* Theme Green */
    color: white; /* White numbers */
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    z-index: 1;
}

.calendar-day:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    z-index: 10;
    border-color: #f97803;
}
.calendar-day.active-month {
    background: #2c5530;
}
.calendar-day.today {
    border: 3px solid #f97803;
    background: #36673a;
    box-shadow: 0 0 15px rgba(249, 120, 3, 0.4);
    z-index: 5;
}
.calendar-day.past-day {
    opacity: 0.5;
    background: #1e3b21; /* Muted darker green */
    color: rgba(255, 255, 255, 0.6);
    cursor: default;
    border-color: rgba(255, 255, 255, 0.05);
}
.calendar-day.past-day:hover {
    transform: none;
    box-shadow: none;
    background: #1e3b21;
    z-index: 1;
}
.calendar-day.padding-day {
    background: transparent;
    border-color: transparent;
    pointer-events: none;
}

/* Booking Status Styles */
.status-badge {
    margin-top: auto;
    margin-bottom: 2px;
    font-size: 0.65rem;
    padding: 4px 8px;
    border-radius: 4px;
    width: 92%;
    text-align: center;
    font-weight: 800;
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.1;
    background: white; /* Consistently white background */
    color: #2c5530;    /* Green font */
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.status-available {
    background: white;
    color: #2e7d32;
}

.status-booked, .status-partial {
    background: white !important;
    color: #2c5530 !important;
}

.loading-data {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

@media (max-width: 768px) {
    .calendar-container {
        padding: 0 10px;
        margin-top: 110px; /* Specific offset for mobile navbar */
    }
    .custom-calendar {
        padding: 15px;
        border-radius: 10px;
    }
    .calendar-controls {
        flex-direction: row;
        gap: 10px;
    }
    .calendar-controls button {
        padding: 8px 12px;
        font-size: 0.85rem;
    }
    #current-month-year {
        font-size: 1.25rem;
    }
    .calendar-header h1 {
        font-size: 2rem;
    }
    .calendar-grid {
        gap: 4px;
    }
    .calendar-day-header {
        font-size: 0.85rem;
        padding: 5px 0;
    }
    .calendar-day {
        font-size: 0.9rem;
        padding: 2px;
        border-radius: 4px;
        aspect-ratio: auto;
        min-height: 65px; 
    }
    .status-badge {
        font-size: 0.50rem;
        padding: 2px;
        width: 100%;
    }
    .modal-content {
        margin-top: 15vh !important;
        margin-bottom: 15vh !important;
    }
}

/* Accommodation Cards in Modal */
.accom-cards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 20px;
    margin-bottom: 25px;
}
@keyframes cardEntrance {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.accom-card {
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    border: none;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
    color: white !important;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    
    /* Entrance Animation */
    animation: cardEntrance 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

/* Staggered delays for cards */
.accom-card:nth-child(1) { animation-delay: 0.1s; }
.accom-card:nth-child(2) { animation-delay: 0.2s; }
.accom-card:nth-child(3) { animation-delay: 0.3s; }
.accom-card:nth-child(4) { animation-delay: 0.4s; }
.accom-card:nth-child(5) { animation-delay: 0.5s; }
.accom-card.tv-card {
    grid-column: 1 / -1;
    min-height: 200px;
}
.accom-card.dome-card {
    aspect-ratio: 1 / 1.5;
}
.accom-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: var(--bg-img);
    background-size: cover;
    background-position: center;
    z-index: 0;
    transition: filter 0.3s ease;
}
.accom-card::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.4);
    z-index: 1;
    transition: background 0.3s ease;
}
.accom-card .accom-name, .accom-card .accom-status {
    position: relative;
    z-index: 2;
}
.accom-card.available {
    background-color: transparent;
    cursor: pointer;
}
.accom-card.available:hover {
    transform: scale(1.02);
}
.accom-card.unavailable {
    background-color: transparent;
    cursor: not-allowed;
}
.accom-card.unavailable::before {
    filter: grayscale(100%);
}
.accom-card.unavailable::after {
    background: rgba(0,0,0,0.6);
}
.accom-card .accom-name {
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 5px;
    font-family: 'Playfair Display', serif;
    color: white !important;
}
.accom-card.unavailable .accom-name {
    color: white !important;
}
.accom-card.available .accom-name {
    color: white !important;
}
.accom-card .accom-status {
    font-size: 0.95rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 4px;
    margin-top: 5px;
    text-shadow: none;
}
.accom-card.available .accom-status {
    background: #e8f5e9;
    color: #2e7d32;
}
.accom-card.unavailable .accom-status {
    color: #e65100;
    background-color: #fff3e0;
}

/* Details Modal */
.details-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.details-modal.active {
    display: flex;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
}

.modal-container {
    position: relative;
    background: white;
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px rgba(0,0,0,0.3);
    animation: modalScale 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalScale {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
    color: #2c5530;
}

.modal-close:hover {
    transform: rotate(90deg);
    background: #2c5530;
    color: white;
}

.modal-body {
    overflow-y: auto;
    flex-grow: 1;
}

.modal-carousel {
    position: relative;
    height: 450px;
    background: #eee;
}

.modal-carousel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-carousel-nav {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    transform: translateY(-50%);
    pointer-events: none;
}

.modal-carousel-btn {
    width: 45px;
    height: 45px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    pointer-events: auto;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
    color: #2c5530;
    border: none;
}

.modal-carousel-btn:hover {
    background: #2c5530;
    color: white;
}

.modal-info {
    padding: 40px;
}

.modal-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: #2c5530;
    margin-bottom: 20px;
}

.modal-description {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #555;
    margin-bottom: 30px;
}

.modal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.modal-amenities-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.modal-amenities-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: #666;
}

.modal-amenities-list i {
    color: #2c5530;
    width: 20px;
    text-align: center;
}

@media (max-width: 768px) {
    .modal-carousel {
        height: 250px;
    }
    .modal-info {
        padding: 25px;
    }
    .modal-title {
        font-size: 1.8rem;
    }
    .modal-amenities-list {
        grid-template-columns: 1fr;
    }

    .details-modal {
        align-items: flex-start;
        padding-top: 100px; /* Push below fixed navbar */
        padding-bottom: 40px;
    }

    .modal-container {
        max-height: calc(100vh - 140px);
    }

    .modal-close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
    }
}

/* Modal Booking Bar Refinement */
.modal-booking-bar {
    display: flex;
    flex-direction: column;
    background: #2c5530;
    border-radius: 8px;
    padding: 0;
    width: 100%;
    max-width: 100%;
    margin: 20px 0;
    position: relative;
    z-index: 10;
    /* Removed overflow: hidden to prevent clipping guest dropdown */
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.modal-booking-bar .booking-main-row {
    flex-direction: column;
    padding: 0;
}

.modal-booking-bar .booking-item {
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    width: 100%;
    align-items: flex-start;
    padding: 15px 20px;
}

.modal-booking-bar .booking-label {
    text-align: left;
    font-size: 0.7rem;
    color: #ccc;
}

.modal-booking-bar .booking-value {
    justify-content: space-between;
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 1rem;
    color: #fff;
}

.modal-booking-bar .book-now-btn {
    width: 100%;
    border-radius: 0 0 8px 8px;
    padding: 15px;
    font-size: 1.1rem;
    text-align: center;
    background: #f97803;
    color: white;
    text-decoration: none;
    font-weight: 700;
}

/* Fix for guest dropdown clipping */
.modal-booking-bar .guest-dropdown {
    position: relative;
    top: 0;
    margin-top: 10px;
    box-shadow: none;
    border: none;
    background: rgba(255,255,255,0.05); /* Subtle background instead of white */
    border-radius: 4px;
    padding: 10px 15px;
}

.modal-booking-bar .guest-type, 
.modal-booking-bar .guest-count {
    color: white !important;
}

.modal-booking-bar .guest-row {
    border-bottom-color: rgba(255,255,255,0.1);
}

@media (max-width: 768px) {
    .modal-booking-bar .booking-item {
        padding: 12px 15px;
    }
    
    .modal-booking-bar .booking-value {
        font-size: 0.95rem;
    }
}
