/**
 * Hotel Booking Frontend Styles
 * استخدام خطوط النظام
 */

/* خطوط النظام */
.hotel-search-wrapper,
.hotel-favorites-wrapper,
.latest-hotels-wrapper,
.hotel-single-wrapper,
.hotels-grid {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", Arial, sans-serif;
}

/* ===== Search Form ===== */
.hotel-search-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.hotel-search-form {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.3);
    margin-bottom: 40px;
}

.search-fields {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: flex-end;
}

.field-group {
    flex: 1;
    min-width: 200px;
}

.field-group label {
    display: block;
    color: #fff;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
}

.field-group select,
.field-group input[type="date"] {
    width: 100%;
    padding: 14px 16px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.field-group select:focus,
.field-group input[type="date"]:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.search-btn {
    width: 100%;
    padding: 14px 40px;
    background: #fff;
    color: #667eea;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

/* ===== Hotels Grid ===== */
.hotels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

/* شبكة 3 أعمدة ثابتة */
.hotels-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

/* شبكة 2 أعمدة */
.hotels-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

/* شبكة 4 أعمدة */
.hotels-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1024px) {
    .hotels-grid-3,
    .hotels-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 680px) {
    .hotels-grid-2,
    .hotels-grid-3,
    .hotels-grid-4 {
        grid-template-columns: 1fr;
    }
}

/* عناوين الأقسام */
.section-title {
    font-size: 26px;
    color: #1a1a2e;
    margin: 0 0 25px 0;
    font-weight: 700;
    padding-bottom: 12px;
    border-bottom: 3px solid #667eea;
    display: inline-block;
}

.section-title .hotel-stars {
    color: #f1c40f;
    margin-right: 10px;
}

/* أغلفة الأقسام */
.hotels-by-city-wrapper,
.hotels-by-rating-wrapper,
.featured-hotels-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* شارة الفندق المثبت */
.hotel-card.is-featured .hotel-image::after {
    content: '★ مميز';
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #f1c40f 0%, #f39c12 100%);
    color: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
}

.hotel-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.hotel-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
}

.hotel-image {
    position: relative;
    height: 220px;
    overflow: hidden;
    background: #f0f0f0;
}

.hotel-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.hotel-card:hover .hotel-image img {
    transform: scale(1.1);
}

.no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #999;
    font-size: 14px;
}

/* ===== Favorite Button ===== */
.favorite-btn {
    position: absolute;
    top: 15px;
    left: 15px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.favorite-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.favorite-icon {
    font-size: 22px;
    color: #e0e0e0;
    transition: all 0.3s ease;
}

.favorite-btn.active .favorite-icon,
.favorite-btn:hover .favorite-icon {
    color: #e74c3c;
}

/* ===== Hotel Info ===== */
.hotel-info {
    padding: 24px;
}

.hotel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.hotel-title {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1.3;
}

.hotel-stars {
    color: #f1c40f;
    font-size: 14px;
    letter-spacing: 1px;
    flex-shrink: 0;
    margin-right: 10px;
}

.hotel-city {
    color: #7f8c8d;
    font-size: 14px;
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 5px;
}

.location-icon {
    font-style: normal;
}

.hotel-description {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 20px 0;
}

/* ===== Price Section ===== */
.hotel-price {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 16px;
    text-align: center;
}

.price-amount {
    font-size: 26px;
    font-weight: 800;
    color: #667eea;
}

.price-currency {
    font-size: 14px;
    color: #667eea;
    margin-right: 4px;
}

.price-period {
    font-size: 13px;
    color: #7f8c8d;
}

.price-na {
    color: #95a5a6;
    font-size: 14px;
}

.total-price {
    text-align: center;
    font-size: 13px;
    color: #27ae60;
    font-weight: 600;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #ddd;
}

/* ===== View Button ===== */
.view-hotel-btn {
    display: block;
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    text-align: center;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.view-hotel-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
    color: #fff;
}

/* ===== Loading State ===== */
.loading {
    text-align: center;
    padding: 60px 20px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e0e0e0;
    border-top-color: #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading p {
    color: #7f8c8d;
    font-size: 16px;
}

/* ===== No Results ===== */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: #7f8c8d;
    font-size: 18px;
    background: #f8f9fa;
    border-radius: 16px;
}

/* ===== Notification ===== */
.hotel-notification {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: #2c3e50;
    color: #fff;
    padding: 16px 32px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    opacity: 0;
    transition: all 0.3s ease;
}

.hotel-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ===== Latest Hotels Section ===== */
.latest-hotels-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.latest-hotels-title {
    font-size: 28px;
    color: #1a1a2e;
    margin: 0 0 30px 0;
    text-align: center;
    font-weight: 700;
}

/* ===== Favorites Page ===== */
.hotel-favorites-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.hotel-favorites-wrapper h2 {
    font-size: 28px;
    color: #2c3e50;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 3px solid #667eea;
    display: inline-block;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .search-fields {
        flex-direction: column;
    }
    
    .field-group {
        width: 100%;
    }
    
    .hotels-grid {
        grid-template-columns: 1fr;
    }
    
    .hotel-search-form {
        padding: 20px;
    }
    
    .hotel-info {
        padding: 20px;
    }
    
    .price-amount {
        font-size: 24px;
    }
    
    .latest-hotels-title {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    .hotel-header {
        flex-direction: column;
        gap: 8px;
    }
    
    .hotel-stars {
        margin-right: 0;
    }
    
    .hotel-notification {
        left: 20px;
        right: 20px;
        transform: translateY(100px);
    }
    
    .hotel-notification.show {
        transform: translateY(0);
    }
}

/* ===== RTL Support ===== */
[dir="rtl"] .favorite-btn {
    left: auto;
    right: 15px;
}

[dir="rtl"] .price-currency {
    margin-right: 0;
    margin-left: 4px;
}

[dir="rtl"] .hotel-stars {
    margin-right: 0;
    margin-left: 10px;
}
