/* ==============================================
   B2B Coffee Quote Wizard - Styles
   ============================================== */

/* Container */
.b2b-quote-wizard-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* Messages */
#wizard-messages {
    margin-bottom: 20px;
}

.wizard-message {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 16px;
    border: 1px solid;
    animation: slideDown 0.3s ease-out;
}

.wizard-message.success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.wizard-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Progress Bar */
.wizard-progress {
    margin-bottom: 40px;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background-color: #e9ecef;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 30px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #8D6E63 0%, #6D4C41 100%);
    width: 20%;
    transition: width 0.4s ease;
    border-radius: 10px;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.step-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
    cursor: pointer;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e9ecef;
    color: #6c757d;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
    border: 2px solid #e9ecef;
}

.step-label {
    font-size: 13px;
    color: #6c757d;
    font-weight: 500;
    transition: color 0.3s ease;
}

.step-indicator.active .step-number {
    background-color: #8D6E63;
    color: white;
    border-color: #8D6E63;
    transform: scale(1.1);
}

.step-indicator.active .step-label {
    color: #8D6E63;
    font-weight: 600;
}

.step-indicator.completed .step-number {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.step-indicator.completed .step-number::after {
    content: "✓";
    font-size: 18px;
}

/* Form Container */
.wizard-form {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
}

/* Wizard Steps */
.wizard-step {
    display: none;
    animation: fadeIn 0.4s ease-out;
}

.wizard-step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.wizard-step h2 {
    color: #2c3e50;
    font-size: 28px;
    margin-bottom: 10px;
    font-weight: 600;
}

.step-description {
    color: #6c757d;
    font-size: 16px;
    margin-bottom: 30px;
}

/* Form Groups */
.form-group {
    margin-bottom: 25px;
}

/* Input Box Styling */
.input-box {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 25px;
}

margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: #333;
    font-size: 15px;
}

.form-hint {
    display: block;
    font-size: 13px;
    color: #6c757d;
    margin-top: 6px;
    font-style: italic;
}

/* Form Inputs */
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #8D6E63;
    box-shadow: 0 0 0 3px rgba(141, 110, 99, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Form Rows */
.form-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.form-half {
    flex: 1;
    min-width: 250px;
}

/* Radio Groups */
.radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.radio-card {
    position: relative;
    display: block;
    cursor: pointer;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.radio-label {
    display: block;
    padding: 14px 20px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
    background-color: #fff;
    color: #333;
}

.radio-card input[type="radio"]:checked+.radio-label {
    background-color: #8D6E63;
    color: white;
    border-color: #8D6E63;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(141, 110, 99, 0.25);
}

.radio-card:hover .radio-label {
    border-color: #8D6E63;
    transform: translateY(-1px);
}

/* Percentage Sliders */
.slider-group {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 15px 0;
}

.slider-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.slider-item label {
    font-weight: 600;
    color: #333;
    font-size: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.slider-item label span {
    font-size: 18px;
    color: #8D6E63;
    font-weight: 700;
    min-width: 50px;
    text-align: right;
}

/* Range Input Styling */
input[type="range"].percentage-slider {
    -webkit-appearance: none;
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: linear-gradient(90deg, #e9ecef 0%, #e9ecef 100%);
    outline: none;
    transition: all 0.3s ease;
}

input[type="range"].percentage-slider:focus {
    box-shadow: 0 0 0 3px rgba(141, 110, 99, 0.1);
}

/* Webkit Browsers (Chrome, Safari, Edge) */
input[type="range"].percentage-slider::-webkit-slider-track {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: linear-gradient(90deg, #8D6E63 0%, #d4a59a 100%);
}

input[type="range"].percentage-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #8D6E63;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

input[type="range"].percentage-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 3px 12px rgba(141, 110, 99, 0.4);
}

/* Firefox */
input[type="range"].percentage-slider::-moz-range-track {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: linear-gradient(90deg, #8D6E63 0%, #d4a59a 100%);
}

input[type="range"].percentage-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #8D6E63;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

input[type="range"].percentage-slider::-moz-range-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 3px 12px rgba(141, 110, 99, 0.4);
}

/* IE/Edge */
input[type="range"].percentage-slider::-ms-track {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: transparent;
    border-color: transparent;
    color: transparent;
}

input[type="range"].percentage-slider::-ms-fill-lower {
    background: #8D6E63;
    border-radius: 5px;
}

input[type="range"].percentage-slider::-ms-fill-upper {
    background: #d4a59a;
    border-radius: 5px;
}

input[type="range"].percentage-slider::-ms-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #8D6E63;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Checkbox Group */
.checkbox-group label {
    display: flex;
    align-items: flex-start;
    font-weight: normal;
    cursor: pointer;
    line-height: 1.6;
}

.checkbox-group input[type="checkbox"] {
    margin-right: 12px;
    margin-top: 3px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    flex-shrink: 0;
}

.privacy-consent {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    margin-top: 20px;
}

/* Review Summary */
#review-summary {
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 25px;
    border: 1px solid #e9ecef;
}

.review-section {
    margin-bottom: 25px;
}

.review-section:last-child {
    margin-bottom: 0;
}

.review-section h3 {
    color: #2c3e50;
    font-size: 18px;
    margin-bottom: 12px;
    font-weight: 600;
    border-bottom: 2px solid #8D6E63;
    padding-bottom: 8px;
}

.review-item {
    display: flex;
    padding: 8px 0;
    border-bottom: 1px solid #e9ecef;
}

.review-item:last-child {
    border-bottom: none;
}

.review-label {
    font-weight: 600;
    color: #495057;
    min-width: 180px;
    flex-shrink: 0;
}

.review-value {
    color: #333;
    flex: 1;
}

/* Navigation Buttons */
.wizard-navigation {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    margin-top: 35px;
    padding-top: 25px;
    border-top: 1px solid #e9ecef;
}

.btn {
    padding: 14px 32px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: inherit;
}

.btn-primary {
    background-color: #8D6E63;
    color: white;
    margin-left: auto;
}

.btn-primary:hover {
    background-color: #6D4C41;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(141, 110, 99, 0.3);
}

.btn-secondary {
    background-color: #e9ecef;
    color: #495057;
}

.btn-secondary:hover {
    background-color: #d3d9df;
}

.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    margin-left: auto;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Loading State */
.btn.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.btn.loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Validation States */
input.invalid,
select.invalid,
textarea.invalid {
    border-color: #dc3545;
}

input.invalid:focus,
select.invalid:focus,
textarea.invalid:focus {
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}

.error-message {
    color: #dc3545;
    font-size: 13px;
    margin-top: 6px;
    display: block;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .b2b-quote-wizard-container {
        padding: 0 15px;
        margin: 20px auto;
    }

    .wizard-form {
        padding: 25px 20px;
    }

    .wizard-step h2 {
        font-size: 24px;
    }

    .step-description {
        font-size: 14px;
    }

    .progress-steps {
        gap: 8px;
    }

    .step-number {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }

    .step-label {
        font-size: 11px;
    }

    .radio-group {
        grid-template-columns: 1fr;
    }

    .form-row {
        flex-direction: column;
        gap: 0;
    }

    .form-half {
        min-width: 100%;
    }

    .wizard-navigation {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .btn-primary,
    .btn-success {
        margin-left: 0;
        order: -1;
    }

    .review-item {
        flex-direction: column;
        gap: 4px;
    }

    .review-label {
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .step-label {
        display: none;
    }

    .wizard-form {
        padding: 20px 15px;
    }
}

/* Conditional Fields Animation */
.conditional-field {
    animation: slideDown 0.3s ease-out;
    overflow: hidden;
}

/* Print Styles */
@media print {

    .wizard-progress,
    .wizard-navigation {
        display: none;
    }

    .wizard-step {
        display: block !important;
        page-break-after: always;
    }
}