/* Add Font Awesome */
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css');

/* Modern Color Scheme */
:root {
    --primary: #2c5282;
    --primary-light: #3182ce;
    --secondary: #718096;
    --accent: #f6ad55;
    --success: #48bb78;
    --danger: #f56565;
    --background: #f7fafc;
    --card-bg: #ffffff;
    --text: #2d3748;
    --text-light: #718096;
    --border: #e2e8f0;
    --shadow: rgba(0, 0, 0, 0.1);
    --font-arabic: 'Cairo', sans-serif;
}

.navbar{
    background: linear-gradient(135deg, var(--primary), var(--secondary)) !important;
    /* height: 80px; */
}

.navbar .btn-book{
    display: none;  
}
.loader{
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    width: 100%;
    z-index: 9999;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    font-size: 48px;
    background: rgba(255, 255, 255, 1);
    color: var(--primary);
}
/* Main Container Styles */
.reservation-container {
    margin-top: 2.5cm;
    max-width: 1200px;
    padding: 2rem;
    background: var(--background);
    border-radius: 16px;
    box-shadow: 0 4px 6px var(--shadow);
}

/* Header Styles */
.reservation-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 12px;
    color: white;
}

.reservation-header h1 {
    color: white;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.reservation-header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Form Sections */
.form-sections {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.form-section {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 4px var(--shadow);
    transition: transform 0.3s ease;
}

.form-section:hover {
    transform: translateY(-2px);
}

.form-section h2 {
    color: var(--primary);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Grid Layout */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 5px;
    direction: ltr;
}
html[lang="ar"] .form-grid {
    direction: rtl;
}
/* Guest Information Grid */
.guest-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.guest-info-grid .full-width {
    grid-column: 1 / -1;
}

/* Form Groups */
.form-group {
    margin-bottom: 1.5rem;
}
html[lang="ar"] .form-group label {
    direction: rtl;
}
.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text);
    font-weight: 500;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.1);
    outline: none;
}

.form-group input[readonly] {
    background-color: #f8f9fa;
    cursor: not-allowed;
}

/* Rooms Table Styles */
.rooms-section {
    margin-top: 1rem;
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.rooms-section h3, .rooms-section h4 {
    color: #2c3e50;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}

.rooms-table-wrapper {
    margin-bottom: 2rem;
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.rooms-table table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.rooms-table th,
.rooms-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
}

.rooms-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
    white-space: nowrap;
}

.rooms-table tbody tr:hover {
    background-color: #f8f9fa;
}

.rooms-table tfoot {
    background-color: #f8f9fa;
    font-weight: bold;
}

.rooms-table tfoot td {
    border-top: 2px solid #dee2e6;
}

.text-right {
    text-align: right;
}

.add-room-section {
    background: #f8fafc;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1.5rem 0;
    border: 2px dashed var(--border);
}

.input-with-info {
    position: relative;
}

.max-rooms-info {
    position: absolute;
    right: 0;
    top: -20px;
    font-size: 0.8rem;
    color: #666;
}

/* Button Styles */
.btn-submit {
    background: var(--success);
    color: white;
    padding: 1rem 3rem;
    border-radius: 50px;
    border: none;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(72, 187, 120, 0.2);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(72, 187, 120, 0.3);
}

.btn-submit i {
    margin-inline: 0.5rem;
}

.btn-add-room {
    background: var(--primary);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-add-room:hover:not(:disabled) {
    background: var(--primary-light);
    transform: translateY(-2px);
}

.btn-remove-room {
    color: var(--danger);
    background: none;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-remove-room:hover {
    transform: scale(1.2);
}

/* Form Actions */
.form-actions {
    text-align: center;
    margin-top: 3rem;
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-section {
    animation: fadeIn 0.5s ease-out;
}

/* Custom Select Styling */
select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
}

/* Error States */
.form-group input:invalid,
.form-group select:invalid {
    border-color: #e74c3c;
}

/* Success States */
.form-group.success input,
.form-group.success select {
    border-color: #2ecc71;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .reservation-container {
        margin-top: 3rem;
    }
    
    .form-section {
        padding: 1.5rem;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
        padding: 5px;
    }
    
    .guest-info-grid {
        grid-template-columns: 1fr;
    }
    
    .guest-info-grid .full-width {
        grid-column: auto;
    }
    
    .reservation-header h1 {
        font-size: 2rem;
        margin-top: 0;
    }
    
    .modern-table td:last-child {
        border: none;
        background: #f8f9fa;
        justify-content: flex-end;
        padding: 0.8rem 1rem;
    }
    
    html[lang="ar"] .modern-table td:last-child {
        justify-content: flex-start;
    }
}

/* Modern Table Styles */
.rooms-table-container {
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 6px var(--shadow);
    margin: 2rem 0;
}

.modern-table {
    width: 100%;
    background: white;
}

.modern-table thead {
    background: var(--primary);
    color: white;
}

.modern-table th {
    padding: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modern-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

/* Mobile Table Styles */
@media (max-width: 768px) {
    .modern-table thead {
        display: none;
    }
    
    .modern-table tbody tr {
        display: flex;
        flex-direction: row-reverse;
        width: 100%;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 1rem;
        background: white;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        overflow: hidden;
    }
    
    .modern-table td {
        display: flex;
        padding: 0.8rem 1rem;
        border-bottom: 1px solid #eee;
        align-items: center;
    }
    
    .modern-table td::before {
        content: attr(data-label);
        font-weight: 600;
        min-width: 40%;
        padding-right: 1rem;
    }
    
    .modern-table td:last-child {
        border: none;
        background: #f8f9fa;
        justify-content: flex-end;
        padding: 0.5rem;
    }
    
    .modern-table td:last-child::before {
        display: none;
    }
    
    /* Empty state in mobile */
    .modern-table td[colspan="5"] {
        display: block;
        text-align: center;
        padding: 2rem 1rem;
    }
    
    .modern-table td[colspan="5"] i {
        display: block;
        margin-bottom: 0.5rem;
    }
}

/* Remove the maximum available info */
.max-rooms-info {
    display: none;
}

/* Price Card Styles */
.total-price-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: 0 4px 6px var(--shadow);
}

.price-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    font-size: 1.1rem;
}

.price-row span:first-child {
    color: var(--text-light);
}

.amount {
    font-family: 'Courier New', monospace;
    color: var(--text);
    font-weight: 600;
}

.price-row.total {
    border-top: 2px solid var(--border);
    margin-top: 1rem;
    padding-top: 1.5rem;
}

.price-row.total span {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary);
}

/* Icon Styles */
.form-group label i {
    margin-right: 0.5rem;
    color: #3498db;
}

.rooms-section h3 i {
    margin-right: 0.5rem;
    color: #3498db;
}

/* Add Room Section Improvements */
.add-room-section:hover {
    border-color: #3498db;
}

/* RTL Support */
html[lang="ar"] .modal-header .close {
    margin: -1rem -1rem auto; 
}
html[lang="ar"] *{
    text-align: right;
}
html[lang="en"] *{
    text-align: left;
}

html[lang="ar"] .form-group label i,
html[lang="ar"] .rooms-section h3 i,
html[lang="ar"] .policy-item i {
    margin-right: 0;
    margin-left: 0.5rem;
}

html[lang="ar"] .max-rooms-info {
    right: auto;
    left: 0;
}

html[lang="ar"] .modern-table th,
html[lang="ar"] .modern-table td {
    text-align: right;
}

/* Booking Policies Styles */
.policies-section {
    background: linear-gradient(135deg, #f6f6f6, #ffffff);
}

.policies-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 1.5rem;
}

.policy-item {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    justify-content: space-between;
    box-shadow: 0 2px 4px var(--shadow);
    transition: transform 0.3s ease;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #004085;
}

.policy-item:hover {
    transform: translateY(-3px);
}

.policy-item i {
    background: var(--primary);
    color: white;
    padding: 1rem;
    border-radius: 50%;
    font-size: 1.5rem;
}

.policy-details h4 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    margin-top: 0;
}

.policy-details p {
    color: #7f8c8d;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

/* Disabled Select Option Styling */
select option[value=""][disabled] {
    display: none;
}

select:required:invalid {
    color: #7f8c8d;
}

/* RTL specific adjustments for policies */
html[lang="ar"] .policy-item {
    text-align: right;
}

html[lang="ar"] .price-row {
    flex-direction: row-reverse;
}

.btn-submit {
    text-align: center;

    i {
        margin-inline: 0.5rem;
    }
}

/* Improve mobile responsiveness for other elements */
@media (max-width: 768px) {
    .reservation-container {
        padding: 1rem;
        margin: 0;
        margin-top: 3rem;
        border-radius: 0;
        box-shadow: none;
    }

    .nav-logo{
        span{
            font-size: 1rem !important;
        }
        img{
            margin: 0 !important;
            height: 24px !important;
        }
    }
    
    .form-section {
        padding: 1rem;
    }
    
    .total-price-card {
        margin: 1rem -1rem -1rem;
        border-radius: 0;
    }
    
    .policies-content {
        grid-template-columns: 1fr;
    }
    
    .policy-item {
        padding: 1rem;
    }
    
    .add-room-section {
        padding: 1rem;
    }
    
    .price-row {
        padding: 0.75rem 0;
    }
    
    .form-actions {
        position: sticky;
        bottom: 0;
        background: white;
        padding: 1rem;
        margin: 1rem -1rem -1rem;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    }
    
    .btn-submit {
        width: 100%;
    }
    
    html[lang="ar"] .footer *{
        text-align: center;
    }
    html[lang="ar"] .footer-info p{
        text-align: center !important;
        color: white;
    }
    .btn-submit {
        text-align: center !important;
    
        i {
            margin-inline: 0.5rem;
        }
    }
}

.footer-bottom p{
    text-align: center;
}
/* Update the select styling for RTL */
html[lang="ar"] select {
    background-position: left 1rem center;
    padding-right: 0.8rem;
    padding-left: 2rem;
}

/* Disabled state styling */
select:disabled,
input:disabled,
button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #f8f9fa;
}

.btn-add-room:disabled {
    background-color: #95a5a6;
    transform: none;
}

.btn-add-room:disabled:hover {
    background-color: #95a5a6;
    transform: none;
}

/* Update room card styling */
.room-type-card {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.room-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.room-info h3 {
    margin: 0;
    color: #2d3748;
    font-size: 1.25rem;
}

.price-info {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.total-price {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c5282;
}

.price-label {
    color: #718096;
    font-size: 0.9rem;
}

.not-available {
    color: #e53e3e;
    font-weight: 500;
    text-align: center;
    padding: 8px;
    background: #fff5f5;
    border-radius: 4px;
}

/* RTL support for price card */
html[lang="ar"] .price-row {
    flex-direction: row-reverse;
}


/* navbar override */
.nav-container{
    width: 100%;
}

html[lang="ar"] a, span, p, input, textarea, button, select, table, th, td {
    font-family: var(--font-arabic);
}
html[lang="ar"] .hero h1 {
    font-family: var(--font-arabic);
}
html[lang="ar"] .section-header h2 {
    font-family: var(--font-arabic);
}
html[lang="ar"] .section-header2 h2 {
    font-family: var(--font-arabic);
}
html[lang="ar"] .feature-card h3 {
    font-family: var(--font-arabic);
}
html[lang="ar"] .contact-card h3 {
    font-family: var(--font-arabic);
}
html[lang="ar"] h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-arabic) !important;
}