/* ============================================
   VIRTUAL TRY-ON - Jane Kendryk
   Fashn.ai Integration
   Style: Minimalist, Elegant (Pronovias-inspired)
   ============================================ */

/* Virtual Try-On Button */
.try-on-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: #000000;
    color: white;
    padding: 15px 40px;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 1px;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    font-family: 'Open Sans', sans-serif;
}

.try-on-btn:hover {
    background: #666666;
}

.try-on-btn svg {
    width: 18px;
    height: 18px;
}

/* Modal Overlay */
.tryon-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.tryon-modal.active {
    display: flex;
}

.tryon-modal-content {
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    background: white;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Header */
.tryon-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 40px;
    border-bottom: 1px solid #e5e5e5;
    background: #000000;
    color: white;
}

.tryon-header h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-family: 'Open Sans', sans-serif;
}

.tryon-close {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: white;
    font-size: 32px;
    cursor: pointer;
    transition: opacity 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.tryon-close:hover {
    opacity: 0.7;
}

/* Body */
.tryon-body {
    flex: 1;
    overflow-y: auto;
    padding: 40px;
    background: #ffffff;
}

/* Steps */
.tryon-step {
    display: none;
}

.tryon-step.active {
    display: block;
}

.tryon-step-content {
    max-width: 600px;
    margin: 0 auto;
}

.tryon-step-content.center {
    text-align: center;
}

/* Instructions */
.tryon-instructions {
    margin-bottom: 40px;
}

.tryon-instructions h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #000000;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.tryon-instructions p {
    color: #666666;
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 1.8;
}

.tryon-instructions ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tryon-instructions li {
    padding: 10px 0 10px 30px;
    position: relative;
    color: #666666;
    font-size: 14px;
    line-height: 1.6;
}

.tryon-instructions li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #000000;
    font-weight: bold;
}

/* Upload Area */
.tryon-upload-area {
    margin-bottom: 40px;
}

.tryon-upload-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 40px;
    border: 2px dashed #e5e5e5;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f9f9f9;
}

.tryon-upload-label:hover {
    border-color: #000000;
    background: #ffffff;
}

.tryon-upload-label svg {
    margin-bottom: 20px;
    color: #666666;
}

.upload-text {
    font-size: 14px;
    font-weight: 600;
    color: #000000;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.upload-hint {
    font-size: 12px;
    color: #999999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Photo Preview */
.photo-preview {
    text-align: center;
}

.photo-preview img {
    max-width: 100%;
    max-height: 400px;
    margin: 0 auto 20px;
    border: 1px solid #e5e5e5;
}

/* Form */
.tryon-form {
    margin-bottom: 40px;
}

.tryon-form label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: #000000;
    margin-bottom: 10px;
    margin-top: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.tryon-form label .required {
    color: #000000;
    font-weight: bold;
    margin-left: 3px;
}

.tryon-form input {
    width: 100%;
    padding: 15px 20px;
    border: 1px solid #e5e5e5;
    font-size: 14px;
    font-family: 'Open Sans', sans-serif;
    transition: border-color 0.3s;
    background: #ffffff;
}

.tryon-form input:focus {
    outline: none;
    border-color: #000000;
}

.tryon-form .field-hint {
    font-size: 12px;
    color: #999999;
    margin-top: 10px;
    margin-bottom: 0;
    line-height: 1.6;
}

/* Step Navigation */
.step-navigation {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.step-navigation .btn {
    flex: 1;
}

.step-navigation .btn-secondary {
    flex: 0 0 auto;
    min-width: 120px;
}

.step-navigation .btn-primary {
    flex: 1;
}

/* Buttons */
.btn {
    padding: 15px 40px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Open Sans', sans-serif;
}

.btn-primary {
    background: #000000;
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: #666666;
}

.btn-primary:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-secondary {
    background: #f9f9f9;
    color: #000000;
    border: 1px solid #e5e5e5;
}

.btn-secondary:hover {
    background: #000000;
    color: white;
    border-color: #000000;
}

.btn-outline {
    background: transparent;
    color: #000000;
    border: 2px solid #000000;
}

.btn-outline:hover {
    background: #000000;
    color: white;
}

.btn-lg {
    width: 100%;
    padding: 18px 40px;
    font-size: 13px;
}

.btn-sm {
    padding: 10px 25px;
    font-size: 11px;
}

/* Processing Step */
.tryon-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid #e5e5e5;
    border-top-color: #000000;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 30px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.progress-bar {
    width: 100%;
    max-width: 400px;
    height: 4px;
    background: #e5e5e5;
    overflow: hidden;
    margin: 30px auto 20px;
}

.progress-fill {
    height: 100%;
    background: #000000;
    width: 0%;
    transition: width 0.5s ease;
}

.progress-text {
    font-size: 32px;
    font-weight: 300;
    color: #000000;
    margin: 20px 0 0 0;
    letter-spacing: 2px;
}

.processing-status {
    color: #666666;
    font-size: 13px;
    margin: 20px 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.processing-time {
    color: #999999;
    font-size: 12px;
    margin-top: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Result Step */
.result-container {
    text-align: center;
}

.result-container h3 {
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 30px;
}

.result-image-wrapper {
    margin-bottom: 30px;
}

.result-image-wrapper img {
    max-width: 100%;
    max-height: 600px;
    margin: 0 auto;
    border: 1px solid #e5e5e5;
}

.result-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.result-info {
    padding: 30px;
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    margin-top: 20px;
}

.result-info h4 {
    margin: 0 0 10px 0;
    font-size: 14px;
    color: #000000;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.result-info p {
    margin: 0 0 20px 0;
    color: #666666;
    font-size: 12px;
    letter-spacing: 0.5px;
}

/* Error Step */
#step-error svg {
    margin-bottom: 30px;
}

#step-error h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #000000;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

#error-message {
    color: #666666;
    margin-bottom: 30px;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .tryon-modal {
        padding: 0;
    }

    .tryon-modal-content {
        max-width: 100%;
        max-height: 100vh;
    }

    .tryon-header {
        padding: 20px 25px;
    }

    .tryon-header h2 {
        font-size: 14px;
    }

    .tryon-body {
        padding: 30px 20px;
    }

    .tryon-upload-label {
        padding: 60px 30px;
    }

    .result-actions {
        flex-direction: column;
    }

    .result-actions .btn {
        width: 100%;
    }

    .btn {
        padding: 15px 30px;
    }
}

/* Smooth animations */
.tryon-modal.active {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.tryon-modal-content {
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}
