/* Configurator Modal Styles - Updated Color Scheme */

/* Main PDF Action Buttons */
.pdf-actions {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    
    border: 2px solid #dd773b;
    box-shadow: 0 4px 15px rgba(221, 119, 59, 0.1);
}

.pdf-btn {
    flex: 1;
    padding: 15px 20px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
}

.pdf-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.pdf-btn:hover::before {
    left: 100%;
}

.pdf-btn i {
    font-size: 18px;
}

#download-pdf-btn {
    background: linear-gradient(135deg, #dd773b 0%, #c96a33 100%);
    color: white;
    border: 2px solid #dd773b;
}

#download-pdf-btn:hover {
    background: linear-gradient(135deg, #c96a33 0%, #b85d2b 100%);
    border-color: #c96a33;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(221, 119, 59, 0.4);
}

#email-pdf-btn {
    background: #ffffff;
    color: #121212;
    border: 2px solid #121212;
}

#email-pdf-btn:hover {
    background: #121212;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(18, 18, 18, 0.3);
}

.pdf-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.pdf-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
    background: #6c757d !important;
    border-color: #6c757d !important;
    color: white !important;
}

/* Order Action Buttons */
.order-actions {
    display: flex;
    gap: 12px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.order-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    min-width: 140px;
    justify-content: center;
}

.order-btn i {
    font-size: 16px;
}

.btn-send-order {
    background: linear-gradient(135deg, #dd773b 0%, #c96a33 100%);
    color: white;
    border: 2px solid #dd773b;
}

.btn-send-order:hover {
    background: linear-gradient(135deg, #c96a33 0%, #b85d2b 100%);
    border-color: #c96a33;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(221, 119, 59, 0.3);
}

.btn-save-order {
    background: #ffffff;
    color: #121212;
    border: 2px solid #121212;
}

.btn-save-order:hover {
    background: #121212;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(18, 18, 18, 0.2);
}

.btn-add-to-cart {
    background: linear-gradient(135deg, #28a745 0%, #20963d 100%);
    color: white;
    border: 2px solid #28a745;
}

.btn-add-to-cart:hover {
    background: linear-gradient(135deg, #20963d 0%, #1e7e34 100%);
    border-color: #20963d;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.3);
}

/* Modal Overlays */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(18, 18, 18, 0.85);
    backdrop-filter: blur(5px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.modal-overlay.show {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Order Modal Styles */
.order-modal {
    background: white;
    border-radius: 15px;
    padding: 0;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 80px rgba(18, 18, 18, 0.4);
    border: 3px solid #dd773b;
    animation: slideInUp 0.4s ease;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.order-modal-header {
    background: linear-gradient(135deg, #dd773b 0%, #c96a33 100%);
    color: white;
    padding: 25px 30px;
    border-radius: 12px 12px 0 0;
    position: relative;
    border-bottom: 4px solid #121212;
}

.order-modal-header h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.order-modal-header h3 i {
    font-size: 24px;
    color: #ffffff;
}

.order-modal-body {
    padding: 30px;
}

/* Form Groups in Modals */
.modal-form-group {
    margin-bottom: 25px;
}

.modal-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #121212;
    font-size: 15px;
}

.modal-form-group label.required::after {
    content: " *";
    color: #dd773b;
    font-weight: bold;
    font-size: 16px;
}

.modal-form-control {
    width: 100%;
    padding: 15px 18px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #121212;
    box-sizing: border-box;
    font-family: inherit;
}

.modal-form-control:focus {
    outline: none;
    border-color: #dd773b;
    box-shadow: 0 0 0 4px rgba(221, 119, 59, 0.15);
    background: #fff;
}

.modal-form-control::placeholder {
    color: #6c757d;
    opacity: 0.8;
}

textarea.modal-form-control {
    resize: vertical;
    min-height: 100px;
    line-height: 1.5;
}

/* Order Summary in Modal */
.order-summary {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #dd773b;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
}

.order-summary h4 {
    margin: 0 0 15px 0;
    color: #121212;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.order-summary h4 i {
    color: #dd773b;
    font-size: 20px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #dee2e6;
}

.summary-item:last-child {
    border-bottom: none;
    font-weight: 700;
    font-size: 16px;
    color: #dd773b;
    margin-top: 10px;
    padding-top: 15px;
    border-top: 2px solid #dd773b;
}

.summary-label {
    color: #121212;
    font-weight: 500;
}

.summary-value {
    color: #121212;
    font-weight: 600;
}

/* Modal Footer Buttons */
.modal-footer {
    padding: 25px 30px;
    border-top: 2px solid #e9ecef;
    background: #f8f9fa;
    border-radius: 0 0 12px 12px;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.modal-btn {
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 140px;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.modal-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.modal-btn:hover::before {
    left: 100%;
}

.modal-btn i {
    font-size: 16px;
}

.modal-btn-primary {
    background: linear-gradient(135deg, #dd773b 0%, #c96a33 100%);
    color: white;
    border: 2px solid #dd773b;
}

.modal-btn-primary:hover {
    background: linear-gradient(135deg, #c96a33 0%, #b85d2b 100%);
    border-color: #c96a33;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(221, 119, 59, 0.4);
}

.modal-btn-secondary {
    background: #ffffff;
    color: #121212;
    border: 2px solid #121212;
}

.modal-btn-secondary:hover {
    background: #121212;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(18, 18, 18, 0.3);
}

.modal-btn:active {
    transform: translateY(0);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.modal-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
    background: #6c757d !important;
    border-color: #6c757d !important;
    color: white !important;
}

/* Close Button */
.modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg) scale(1.1);
}

/* Loading States */
.loading .fa-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Success/Error Messages */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 2px solid;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert i {
    font-size: 18px;
}

.alert-success {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.alert-error {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

.alert-warning {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.alert-info {
    background: #cce7ff;
    border-color: #dd773b;
    color: #0c5460;
}

/* Progress Bar */
.progress-bar {
    width: 100%;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
    margin: 15px 0;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #dd773b, #c96a33);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 3px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .pdf-actions {
        flex-direction: column;
        gap: 12px;
    }
    
    .order-actions {
        flex-direction: column;
    }
    
    .order-btn, .pdf-btn {
        width: 100%;
        justify-content: center;
    }
    
    .order-modal {
        width: 95%;
        margin: 20px;
        max-height: calc(100vh - 40px);
    }
    
    .order-modal-header {
        padding: 20px 25px;
    }
    
    .order-modal-header h3 {
        font-size: 20px;
    }
    
    .order-modal-body {
        padding: 25px;
    }
    
    .modal-footer {
        padding: 20px 25px;
        flex-direction: column;
    }
    
    .modal-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .order-modal {
        width: 100%;
        height: 100%;
        border-radius: 0;
        max-height: 100vh;
    }
    
    .order-modal-header {
        border-radius: 0;
        padding: 15px 20px;
    }
    
    .order-modal-header h3 {
        font-size: 18px;
    }
    
    .order-modal-body {
        padding: 20px;
    }
    
    .modal-footer {
        padding: 15px 20px;
        border-radius: 0;
    }
    
    .modal-close {
        top: 15px;
        right: 20px;
        width: 35px;
        height: 35px;
        font-size: 24px;
    }
}

/* Custom Scrollbar */
.order-modal::-webkit-scrollbar {
    width: 8px;
}

.order-modal::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.order-modal::-webkit-scrollbar-thumb {
    background: #dd773b;
    border-radius: 4px;
}

.order-modal::-webkit-scrollbar-thumb:hover {
    background: #c96a33;
}

/* Hover Effects for Interactive Elements */
.interactive-element {
    transition: all 0.3s ease;
}

.interactive-element:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(221, 119, 59, 0.2);
}

/* Focus States for Accessibility */
.modal-btn:focus,
.pdf-btn:focus,
.order-btn:focus,
.modal-form-control:focus {
    outline: 3px solid rgba(221, 119, 59, 0.5);
    outline-offset: 2px;
}

/* Dark Mode Support (Optional) */
@media (prefers-color-scheme: dark) {
    .order-modal {
        background: #2d3748;
        color: white;
    }
    
    .modal-form-control {
        background: #4a5568;
        color: white;
        border-color: #718096;
    }
    
    .order-summary {
        background: #4a5568;
        border-color: #dd773b;
    }
    
    .summary-label,
    .summary-value {
        color: white;
    }
}
