/* Reserve Page Specific Styles */

/* International Tel Input CSS Variables Override */
:root {
    --iti-dropdown-bg: #242424;
    --iti-hover-color: rgba(103, 217, 252, 0.2);
    --iti-border-color: rgba(103, 217, 252, 0.3);
    --iti-dialcode-color: rgba(255, 255, 255, 0.7);
    --iti-arrow-color: #67d9fc;
}

.reserve-main {
    padding: 2rem 0 4rem 0;
    min-height: calc(100vh - 200px);
}

.reserve-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.reserve-content {
    display: grid;
    grid-template-columns: 65fr 35fr;
    gap: 1rem;
    align-items: start;
}

/* Left Side - Service Description */
.service-description {
    background: rgba(36, 36, 36, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    padding: 1.5rem;
    height: fit-content;
    position: static;
    opacity: 0.8;
}

.service-description h2 {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 1rem;
    text-align: center;
}

.route-display {
    font-size: 1.3rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 1.5rem;
    text-align: center;
}

.flight-info {
    margin-bottom: 2rem;
}

.airline-date {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
}

.flight-details {
    font-size: 1rem;
    color: #67d9fc;
    font-weight: 600;
}

.passenger-info,
.baggage-info {
    margin-bottom: 2rem;
}

.passenger-info h3,
.baggage-info h3 {
    color: #ffffff;
    font-size: 1rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.passenger-type {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
}

.passenger-count {
    color: #67d9fc;
    font-weight: 600;
    font-size: 1.1rem;
}

.baggage-included,
.baggage-extra,
.baggage-oversized {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.25rem;
}

.price-display {
    background: rgba(103, 217, 252, 0.1);
    border: 2px solid rgba(103, 217, 252, 0.3);
    border-radius: 0.5rem;
    padding: 1rem;
    text-align: center;
    margin-top: 2rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: #67d9fc;
}

.service-description-text {
    margin-bottom: 2rem;
}

.service-description-text p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.process-point {
    margin-bottom: 0.75rem;
}

.process-point:last-child {
    margin-bottom: 0;
}

.service-process h4 {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    font-weight: 500;
    margin: 0 0 0.15rem 0;
}

.service-process h4:first-child {
    margin-top: 0;
}

.service-process p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
    line-height: 1.3;
    margin-bottom: 0;
}

.service-description h3 {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 0.75rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1rem;
}

.pricing-rules-left {
    margin-bottom: 2rem;
}

.rule-item-left {
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.25rem;
    margin-bottom: 0.75rem;
}

.rule-item-left:last-child {
    margin-bottom: 0;
}

.rule-text-left {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    line-height: 1.4;
}

.rule-text-left small {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
}

.rule-text-left strong {
    color: rgba(255, 255, 255, 0.7);
}

/* Right Side - Your Trip */
.pricing-form-container {
    background: rgba(36, 36, 36, 0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 2px solid rgba(103, 217, 252, 0.2);
    border-radius: 0.5rem;
    padding: 1rem;
}

.pricing-form-container h2 {
    color: #67d9fc;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: center;
}

.trip-summary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.trip-route-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.trip-route {
    font-size: 1.2rem;
    font-weight: 600;
    color: #ffffff;
    text-align: center;
    flex: 1;
}

.trip-airline-date {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.trip-flight-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.trip-flight {
    font-size: 1rem;
    color: #67d9fc;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
}

.service-icon {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

/* Edit Buttons */
.edit-btn {
    background: transparent;
    border: 1px solid rgba(103, 217, 252, 0.5);
    color: #67d9fc;
    width: 32px;
    height: 32px;
    border-radius: 0.25rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.edit-btn:hover {
    background: rgba(103, 217, 252, 0.1);
    border-color: #67d9fc;
}

.edit-icon {
    font-size: 0.9rem;
    font-weight: normal;
}

/* Edit Forms */
.edit-forms-container {
    margin: 1rem 0;
}

.edit-form {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    padding: 1.5rem;
}

.edit-form h3 {
    color: #67d9fc;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.edit-form-content {
    margin-bottom: 1.5rem;
}

.edit-form .form-group {
    margin-bottom: 1rem;
}

.edit-form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.edit-btn-primary {
    background: linear-gradient(135deg, #67d9fc 0%, #3fb8e0 100%);
    color: #242424;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 0.25rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(103, 217, 252, 0.3);
}

.edit-btn-secondary {
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.75rem 1.5rem;
    border-radius: 0.25rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Flight Selection */
.flight-selection {
    margin-top: 1rem;
}

.flight-selection h4 {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    margin-bottom: 0.75rem;
    font-weight: 500;
}

.flight-options {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.flight-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.flight-option:hover {
    background: rgba(103, 217, 252, 0.1);
    border-color: rgba(103, 217, 252, 0.3);
}

.flight-option input[type="radio"] {
    margin: 0;
    cursor: pointer;
}

.flight-option-label {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    cursor: pointer;
    flex: 1;
}

.control-section {
    margin-bottom: 0.75rem;
}

.control-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.25rem;
}

.control-label {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    font-size: 0.9rem;
    white-space: nowrap;
}

.pricing-rules {
    margin-bottom: 2rem;
}

.pricing-rules h3 {
    color: #ffffff;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.rule-item {
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 0.25rem;
    margin-bottom: 0.5rem;
}

.rule-item:last-child {
    margin-bottom: 0;
}

.rule-text {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    line-height: 1.4;
}

.rule-text small {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
}

.pricing-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.pricing-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.pricing-section h3 {
    color: #ffffff;
    font-size: 1rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.pricing-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.pricing-item:last-child {
    border-bottom: none;
}

.pricing-item .description {
    flex: 1;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    line-height: 1.3;
}

.pricing-item .price {
    color: #67d9fc;
    font-weight: 600;
    margin-left: 1rem;
    font-size: 0.95rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-left: 0.75rem;
}

.quantity-btn {
    background: rgba(103, 217, 252, 0.2);
    border: 1px solid #67d9fc;
    color: #67d9fc;
    width: 24px;
    height: 24px;
    border-radius: 0.2rem;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.quantity-btn:hover {
    background: rgba(103, 217, 252, 0.3);
}

.quantity-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.quantity-display {
    min-width: 24px;
    text-align: center;
    color: #ffffff;
    font-weight: 600;
    font-size: 0.9rem;
}

.simple-price {
    text-align: center;
    margin: 1rem 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #67d9fc;
}

.surcharge-notice {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 0.25rem;
    padding: 1rem;
    margin: 1rem 0;
    color: #ffc107;
    font-size: 0.9rem;
    text-align: center;
}

.reserve-final-btn {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #67d9fc 0%, #3fb8e0 100%);
    color: #242424;
    border: none;
    border-radius: 0.5rem;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.reserve-final-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(103, 217, 252, 0.4);
}

.reserve-final-btn:disabled {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
}

.reserve-final-btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Total Price Section */
.total-price-section {
    margin: 1.5rem 0;
}

/* Price Breakdown Section - Injected by WooCommerce */
#woocommerce-price-breakdown,
.price-breakdown {
    margin-top: 1.6rem !important;  /* Add space between total box and price breakdown */
}

.total-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: rgba(103, 217, 252, 0.1);
    border: 2px solid rgba(103, 217, 252, 0.3);
    border-radius: 0.25rem;
}

.total-label {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    font-weight: 600;
}

.total-amount {
    color: #67d9fc;
    font-size: 1.5rem;
    font-weight: 700;
}

/* Action Button Section */
.action-section {
    margin: 1.5rem 0;
}

.action-btn {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #67d9fc 0%, #3fb8e0 100%);
    color: #242424;
    border: none;
    border-radius: 0.25rem;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(103, 217, 252, 0.4);
}

.action-btn:disabled {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
}

.action-btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Section Divider */
.section-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 1.5rem 0;
}

/* Collapsed Passenger Summary */
.collapsed-summary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.summary-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.summary-content {
    flex: 1;
}

.summary-header {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.summary-details {
    color: #67d9fc;
    font-size: 1.1rem;
    font-weight: 600;
}

/* Personal Information Container - matches demo exactly */
.personal-info-container {
    overflow: visible;
    position: relative;
}

.personal-info-container .form-group {
    margin-bottom: 1rem;
}

.personal-info-container .form-group.collapsed {
    opacity: 0;
    max-height: 0;
    margin-bottom: 0;
    margin-top: 0;
    padding: 0;
    pointer-events: none;
    transition: all 0.4s ease;
}

.personal-info-container .form-group.expanded {
    opacity: 1;
    max-height: 500px;
    margin-bottom: 1rem;
    pointer-events: auto;
    transition: all 0.4s ease;
}

.personal-info-container .form-group.expanded#commentsGroup {
    max-height: 300px;
}

/* Form input and textarea styles for reserve page - matches demo exactly */
.personal-info-container .form-group input,
.personal-info-container .form-group textarea,
.personal-info-container .form-group .form-input,
.personal-info-container .form-group .input {
    width: 100%;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.08);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-top-color: rgba(255, 255, 255, 0.15);
    border-bottom-color: rgba(63, 63, 63, 0.05);
    color: #fffdfd;
    border-radius: 0.25rem;
    font-size: 0.9rem;
    box-sizing: border-box;
    line-height: 1.4;
    min-height: 38px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    color-scheme: dark;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    font-family: inherit;
}

.personal-info-container .form-group input:focus,
.personal-info-container .form-group textarea:focus,
.personal-info-container .form-group .form-input:focus,
.personal-info-container .form-group .input:focus {
    outline: none;
    border-color: #67d9fc;
    background: rgba(103, 217, 252, 0.1);
}

.personal-info-container .form-group textarea {
    resize: vertical;
    min-height: 80px;
    padding: 15px;
}

.personal-info-container .form-group label {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.95rem;
    transition: all 0.3s ease;
    pointer-events: none;
    background: transparent;
    padding: 0 4px;
}

.personal-info-container .form-group input:focus ~ label,
.personal-info-container .form-group input.has-value ~ label {
    top: 0;
    font-size: 0.75rem;
    color: #67d9fc;
    background: #242424;
}

/* Form validation error states */
.reserve-main .form-group.error input:not(.iti__input) {
    border-color: #ff6b6b !important;
    background: rgba(255, 107, 107, 0.1) !important;
    animation: shake 0.5s ease-in-out;
}

.reserve-main .form-group.error textarea {
    border-color: #ff6b6b !important;
    background: rgba(255, 107, 107, 0.1) !important;
    animation: shake 0.5s ease-in-out;
}

.reserve-main .form-group.error label {
    color: #ff6b6b !important;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-2px); }
    20%, 40%, 60%, 80% { transform: translateX(2px); }
}


/* Responsive Design */
@media (max-width: 900px) {
    .reserve-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .service-description {
        position: static;
        order: 2;
    }

    .pricing-form-container {
        order: 1;
    }

    .reserve-main {
        padding: 1rem 0 2rem 0;
    }

    .service-description,
    .pricing-form-container {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .reserve-container {
        padding: 0 0.5rem;
    }

    .service-description,
    .pricing-form-container {
        padding: 1rem;
    }

    .pricing-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .quantity-controls {
        margin-left: 0;
    }
}

/* Optional Fields Buttons */
.optional-fields-buttons {
    margin: 15px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.add-optional-btn {
    background: transparent;
    border: 1px solid #67d9fc;
    color: #67d9fc;
    padding: 5px 12px;
    border-radius: 0.25rem;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
    width: 100%;
    justify-content: flex-start;
}

.add-optional-btn:hover {
    background: #67d9fc;
    color: #242424;
}

.add-optional-btn.added {
    background: rgba(103, 217, 252, 0.1);
    border-color: rgba(103, 217, 252, 0.5);
    opacity: 0.7;
    cursor: default;
}

.add-optional-btn.added:hover {
    background: rgba(103, 217, 252, 0.1);
    color: #67d9fc;
}

.add-icon {
    font-size: 1rem;
    font-weight: bold;
    min-width: 14px;
}

.optional-fields-container {
    margin-top: 15px;
}


/* Textarea styling - inherits from .form-textarea in styles.css */
.form-group textarea {
    padding: 15px;
    min-height: 80px;
}

/* Field hint styling */
.field-hint {
    display: block;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
    font-weight: 400;
}
