/**
 * Container Reservation Module Styles
 * @package mod_container_reservation
 */

/* Base Module Styles */
.container-reservation-module {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.module-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e9ecef;
}

.module-title {
    font-size: 28px;
    font-weight: bold;
    color: #2c3e50;
    margin: 0 0 10px 0;
    background: linear-gradient(135deg, #007cba 0%, #0056b3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.module-subtitle {
    font-size: 16px;
    color: #6c757d;
    margin: 0;
    font-weight: normal;
}

/* Step Navigation */
.reservation-step {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

.reservation-step.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.step-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 25px;
    border-left: 5px solid #007cba;
}

.step-header h3 {
    margin: 0;
    color: #2c3e50;
    font-size: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.step-number {
    background: #007cba;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
}

.step-content {
    padding: 0 10px;
}

/* Form Styles */
.lookup-form, .reservation-form {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    border: 1px solid #e9ecef;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #495057;
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    background: white;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #007cba;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.1);
}

.help-text {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: #6c757d;
    font-style: italic;
}

/* Customer Information Display */
.customer-info {
    background: white;
    padding: 20px;
    border-radius: 10px;
    border: 2px solid #28a745;
    margin-top: 20px;
}

.customer-info h4 {
    color: #28a745;
    margin: 0 0 15px 0;
    font-size: 18px;
}

.info-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #e9ecef;
}

.info-row:last-child {
    border-bottom: none;
}

.info-row strong {
    color: #495057;
    flex-shrink: 0;
    width: 120px;
}

.info-row span {
    text-align: right;
    color: #2c3e50;
    font-weight: 500;
}

/* Container Grid */
.containers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.container-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.container-card:hover {
    border-color: #007cba;
    box-shadow: 0 5px 15px rgba(0, 124, 186, 0.2);
    transform: translateY(-2px);
}

.container-card.selected {
    border-color: #28a745;
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
}

.container-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #007cba 0%, #0056b3 100%);
}

.container-card.selected::before {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.container-name {
    font-size: 18px;
    font-weight: bold;
    color: #2c3e50;
    margin: 0 0 10px 0;
}

.container-details {
    font-size: 14px;
    color: #6c757d;
    line-height: 1.5;
}

.container-details strong {
    color: #495057;
}

.availability-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e9ecef;
}

.availability-bar {
    flex: 1;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.availability-fill {
    height: 100%;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    transition: width 0.3s ease;
}

.availability-text {
    font-size: 12px;
    font-weight: bold;
    color: #495057;
    white-space: nowrap;
}

/* Selected Container Info */
.selected-container-info {
    background: #e7f3ff;
    padding: 20px;
    border-radius: 10px;
    border-left: 5px solid #007cba;
    margin-bottom: 25px;
}

.selected-container-info h4 {
    color: #007cba;
    margin: 0 0 15px 0;
    font-size: 16px;
}

/* Buttons */
.btn {
    padding: 12px 25px;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 120px;
}

.btn-primary {
    background: linear-gradient(135deg, #007cba 0%, #0056b3 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0056b3 0%, #004085 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.3);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.3);
}

.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, #218838 0%, #1e7e34 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.btn-large {
    padding: 15px 35px;
    font-size: 16px;
    min-width: 180px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* Navigation Buttons */
.navigation-buttons {
    display: flex;
    gap: 15px;
    justify-content: space-between;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

/* Success Message */
.success-message {
    text-align: center;
    padding: 40px;
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border-radius: 15px;
    border: 2px solid #28a745;
}

.success-icon {
    width: 80px;
    height: 80px;
    background: #28a745;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    font-weight: bold;
    margin: 0 auto 20px;
}

.success-message h4 {
    color: #155724;
    font-size: 24px;
    margin: 0 0 15px 0;
}

.success-message p {
    color: #155724;
    font-size: 16px;
    margin: 0 0 30px 0;
}

.reservation-summary {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0 30px;
    text-align: left;
}

.reservation-summary h5 {
    color: #28a745;
    margin: 0 0 15px 0;
    font-size: 16px;
}

/* Loading Indicator */
.loading-indicator {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #e9ecef;
    border-left: 5px solid #007cba;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-indicator p {
    margin: 15px 0 0 0;
    color: #6c757d;
    font-size: 16px;
}

/* Alert Messages */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin: 15px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.alert-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    color: inherit;
    opacity: 0.7;
}

.close-btn:hover {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container-reservation-module {
        padding: 15px;
        margin: 10px;
    }
    
    .module-title {
        font-size: 24px;
    }
    
    .module-subtitle {
        font-size: 14px;
    }
    
    .step-header {
        padding: 15px;
    }
    
    .step-header h3 {
        font-size: 18px;
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .lookup-form, .reservation-form {
        padding: 20px;
    }
    
    .containers-grid {
        grid-template-columns: 1fr;
    }
    
    .info-row {
        flex-direction: column;
        text-align: left;
    }
    
    .info-row strong {
        width: auto;
        margin-bottom: 5px;
    }
    
    .info-row span {
        text-align: left;
    }
    
    .navigation-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .success-message {
        padding: 30px 20px;
    }
    
    .success-icon {
        width: 60px;
        height: 60px;
        font-size: 30px;
    }
}

@media (max-width: 480px) {
    .container-reservation-module {
        padding: 10px;
        margin: 5px;
    }
    
    .module-title {
        font-size: 20px;
    }
    
    .step-header {
        padding: 12px;
    }
    
    .lookup-form, .reservation-form {
        padding: 15px;
    }
    
    .form-group input,
    .form-group textarea,
    .form-group select {
        padding: 10px 12px;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 13px;
    }
    
    .btn-large {
        padding: 12px 25px;
        font-size: 14px;
    }
}

/* Print Styles */
@media print {
    .container-reservation-module {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .btn, .navigation-buttons {
        display: none;
    }
    
    .loading-indicator {
        display: none !important;
    }
}