/* ==========================================
   Hotel Booking Manager - Main Stylesheet
   Version: 1.8.0
   ========================================== */

/* ---------- Hotel Listing Grid ---------- */
.dghb-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
    margin: 20px 0;
}

@media (max-width: 1024px) {
    .dghb-cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .dghb-cards-grid {
        grid-template-columns: 1fr;
    }
}

/* ---------- Card Styles ---------- */
.dghb-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s;
}

.dghb-card:hover {
    transform: translateY(-4px);
}

.dghb-card-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.dghb-card-content {
    padding: 15px;
}

/* Status badge */
.dghb-status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 10px;
}

.dghb-status-badge.available {
    background: #10b981;
    color: white;
}

.dghb-status-badge.fully_booked {
    background: #ef4444;
    color: white;
}

.dghb-status-badge.temporarily_closed {
    background: #f59e0b;
    color: white;
}

/* Rating stars on cards */
.dghb-rating {
    margin: 5px 0;
    color: #f68511;
}

.dghb-rating .dghb-review-count {
    font-size: 0.8rem;
    color: #666;
}

.dghb-specs {
    display: flex;
    gap: 15px;
    margin: 8px 0;
    font-size: 0.85rem;
    color: #666;
}

.dghb-location {
    font-size: 0.85rem;
    color: #666;
    margin: 5px 0;
}

.dghb-price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #f68511;
    margin: 10px 0;
}

.dghb-price span {
    font-size: 0.8rem;
    font-weight: normal;
}

.dghb-buttons {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

/* Buttons */
.dghb-btn {
    padding: 8px 15px;
    border-radius: 30px;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    display: inline-block;
    background: #f68511;
    color: white;
}

.dghb-btn-outline {
    background: transparent;
    border: 1px solid #f68511;
    color: #f68511;
}

.dghb-btn-outline:hover {
    background: #f68511;
    color: white;
}

/* ---------- Pagination ---------- */
.dghb-pagination {
    text-align: center;
    margin: 30px 0;
}

.dghb-pagination a,
.dghb-pagination span {
    display: inline-block;
    margin: 0 5px;
    padding: 8px 12px;
    background: #f1f1f1;
    border-radius: 5px;
    text-decoration: none;
}

.dghb-pagination .current {
    background: #0048a5;
    color: white;
}

/* ---------- Search Form ---------- */
/* ------------------------------
   New Search Form Layout
------------------------------- */
.dghb-search-wrapper {
    margin-bottom: 30px;
}

.dghb-advanced-search {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    align-items: flex-end;
}

.dghb-search-field {
    flex: 1;
    min-width: 180px;
}

.dghb-field-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.85rem;
    color: #333;
}

.dghb-field-label .dghb-icon {
    margin-right: 5px;
    font-size: 1rem;
}

.dghb-search-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.95rem;
    background: #fff;
    transition: border 0.2s;
}

.dghb-search-input:focus {
    border-color: #f68511;
    outline: none;
}

/* Occupancy group */
.dghb-occupancy-group {
    min-width: 240px;
}

.dghb-occupancy-inputs {
    display: flex;
    gap: 12px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 5px 10px;
}

.dghb-occupancy-item {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 6px;
}

.dghb-occupancy-item input {
    width: 60px;
    padding: 6px;
    border: 1px solid #ccc;
    border-radius: 6px;
    text-align: center;
}

.dghb-occupancy-item span {
    font-size: 0.8rem;
    color: #555;
}

/* Search button */
.dghb-search-button {
    flex: 0 0 auto;
}

.dghb-btn-search {
    width: 100%;
    background: #034aa6;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s;
}

.dghb-btn-search:hover {
    background: #023580;
}

/* Responsive */
@media (max-width: 768px) {
    .dghb-advanced-search {
        flex-direction: column;
        align-items: stretch;
    }
    .dghb-occupancy-inputs {
        flex-wrap: wrap;
    }
}

/* ---------- Gallery Slider (Single Hotel) ---------- */
.dghb-gallery-slider {
    position: relative;
    margin: 20px 0;
}

.dghb-slider-container {
    overflow: hidden;
}

.dghb-slide {
    display: none;
    text-align: center;
}

.dghb-slide img {
    max-height: 500px;
    width: auto;
    margin: auto;
    border-radius: 12px;
}

.dghb-slider-prev,
.dghb-slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 10;
}

.dghb-slider-prev {
    left: 10px;
}

.dghb-slider-next {
    right: 10px;
}

/* ---------- Single Hotel Page Layout ---------- */
.dghb-single-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

.dghb-single-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin: 30px 0;
}

.dghb-single-left,
.dghb-single-right {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.dghb-map-container {
    margin: 20px 0;
}

.dghb-booking-widget {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 12px;
    margin: 20px 0;
}

@media (max-width: 768px) {
    .dghb-single-grid {
        grid-template-columns: 1fr;
    }
}

/* ---------- Reviews Section ---------- */
.dghb-reviews-section {
    margin-top: 40px;
}

.dghb-average-rating {
    font-size: 1.2rem;
    margin: 15px 0;
}

.dghb-stars {
    color: #f68511;
    letter-spacing: 2px;
}

.dghb-review {
    border-bottom: 1px solid #eee;
    padding: 15px 0;
}

.dghb-review-rating {
    color: #f68511;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.dghb-reviewer {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.dghb-submit-review {
    margin-top: 30px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 12px;
}

.dghb-rating-stars span {
    font-size: 1.8rem;
    cursor: pointer;
    margin-right: 5px;
    color: #ddd;
    transition: color 0.2s;
}

.dghb-rating-stars span.active,
.dghb-rating-stars span:hover {
    color: #f68511;
}

/* Hotel Listings Carousel (new shortcode) */
.dghb-hotels-carousel {
    margin: 30px 0;
}
.dghb-carousel-item {
    text-align: center;
    padding: 10px;
}
.dghb-carousel-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
}
.dghb-carousel-item h3 {
    margin: 10px 0;
    font-size: 1rem;
}
.slick-prev:before, .slick-next:before {
    color: #034aa6;
}

/* Slick Carousel overrides */
.slick-prev,
.slick-next {
    z-index: 1;
}

.slick-prev:before,
.slick-next:before {
    color: #034aa6;
}

/* ---------- Flatpickr (Date Picker) ---------- */
.flatpickr-calendar {
    font-family: inherit;
}

/* ---------- Booking Modal ---------- */
#dghb-booking-modal label {
    font-weight: 600;
    margin-bottom: 5px;
    display: block;
}

/* ---------- Admin Bookings Modal ---------- */
#dghb-booking-details-modal p {
    margin: 8px 0;
}

/* ---------- Miscellaneous ---------- */
.dghb-map-link {
    display: inline-block;
    background: #4285f4;
    color: white;
    padding: 8px 15px;
    border-radius: 30px;
    text-decoration: none;
}

/* Occupancy Popup Styles */
.dghb-occupancy-wrapper {
    position: relative;
}

.dghb-occupancy-trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px 12px;
    cursor: pointer;
    font-size: 0.95rem;
}

.dghb-chevron {
    font-size: 0.8rem;
    color: #666;
}

.dghb-popup {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1000;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    width: 320px;
    margin-top: 5px;
}

.dghb-popup-content {
    padding: 15px;
}

.dghb-popup-row {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.dghb-popup-label {
    width: 70px;
    font-weight: 600;
}

.dghb-popup-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f7f7f7;
    border-radius: 30px;
    padding: 4px 10px;
}

.dghb-popup-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    width: 28px;
    height: 28px;
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.2s;
}

.dghb-popup-btn:hover {
    background: #e0e0e0;
}

.dghb-popup-value {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
}

.dghb-popup-slider {
    flex: 1;
    min-width: 150px;
}

.dghb-popup-checkbox-row {
    margin: 10px 0;
}

.dghb-popup-note {
    font-size: 0.75rem;
    color: #666;
    margin: 10px 0;
}

.dghb-popup-done {
    width: 100%;
    background: #034aa6;
    color: white;
    border: none;
    padding: 8px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .dghb-popup {
        width: 100%;
        left: 0;
        right: 0;
    }
}