/* Modal styles - scoped to avoid conflicts with main page */
/* Removed global reset and body styles to prevent conflicts */

/* Info Button */
.info-button {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: #3590ff;
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    z-index: 1000;
}

.info-button:hover {
    background-color: #2d7ae6;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.info-button:active {
    transform: scale(0.95);
}

/* Modal Overlay */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.active {
    display: flex;
}

/* Modal Container */
.modal-container {
    background-color: #ffffff;
    border-radius: 12px;
    width: 800px;
    min-width: 800px;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    position: relative;
    align-items: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    margin: 0 auto;
    box-sizing: border-box;
}

/* Modal Header */
.modal-header {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 40px 16px 40px;
    position: relative;
    width: 100%;
    box-sizing: border-box;
    flex-shrink: 0;
}

/* Progress Bar - scoped to modal to avoid conflicts */
.modal-overlay .progress-container {
    width: 400px;
    max-width: 60%;
    height: 8px;
    background-color: #E5E5E5;
    border-radius: 4px;
    position: relative;
    overflow: hidden;
}

.modal-overlay .progress-container .progress-bar {
    height: 100%;
    background-color: #3590ff;
    transition: width 0.3s ease;
    width: 14.28%; /* 1/7 of 100% */
    border-radius: 4px;
}

/* Close Button */
.close-button {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #E5E5E5;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.close-button:hover {
    background-color: #D0D0D0;
    color: #333;
}

/* Modal Content */
.modal-content {
    flex: 1;
    padding: 20px 25px 10px 25px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 0;
    width: 100%;
    box-sizing: border-box;
    box-shadow: none !important;
}

.step-content {
    /*width: 750px;
    max-width: 750px;
    min-width: 750px; */
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    min-height: 0;
    box-sizing: border-box;
    margin: 0 auto;
    padding: 0;
    position: relative;
}

.step-image-container {
    width: 100%;
    max-width: 100%;
    max-height: 300px;
    height: 300px;
    background-color: #F5F5F5;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    padding: 20px;
    overflow: hidden;
    flex-shrink: 0;
    box-sizing: border-box;
    position: relative;
}

.step-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
    display: block;
}

.step-image.step-image-small {
    max-width: 70%;
    max-height: 70%;
    width: auto;
    height: auto;
}

.step-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin: 0 auto 20px auto;
    flex-shrink: 0;
    width: 100%;
    max-width: 100%;
    text-align: center;
    padding: 0;
    box-sizing: border-box;
}

.step-description {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    text-align: center;
    box-sizing: border-box;
    padding: 0;
}

/* Modal Footer */
.modal-footer {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    padding: 20px 40px;
    background-color: #ffffff;
    flex-shrink: 0;
    width: 100%;
    box-sizing: border-box;
}

/* Button styles - scoped to modal footer */
.modal-footer .btn {
    padding: 12px 32px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
}

.modal-footer .btn-back {
    background-color: #E5E5E5;
    color: #666;
}

.modal-footer .btn-back:hover:not(:disabled) {
    background-color: #D0D0D0;
    color: #333;
}

.modal-footer .btn-back:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.modal-footer .btn-next {
    background-color: #3590ff;
    color: white;
}

.modal-footer .btn-next:hover {
    background-color: #2d7ae6;
}

.modal-footer .btn-close {
    background-color: #3590ff;
    color: white;
}

.modal-footer .btn-close:hover {
    background-color: #2d7ae6;
}

/* Responsive Design */
@media (max-width: 768px) {
    .info-button {
        top: 16px;
        right: 16px;
        width: 44px;
        height: 44px;
    }

    .modal-overlay {
        padding: 10px;
    }

    .modal-container {
        width: 90vw !important;
        min-width: 90vw !important;
        max-width: 90vw !important;
        max-height: 95vh;
        border-radius: 8px;
    }

    .step-image-container {
        width: 100% !important;
        max-width: 100% !important;
        min-width: auto !important;
        height: 250px !important;
        max-height: 250px !important;
    }

    .step-description {
        width: 100% !important;
        max-width: 100% !important;
        min-width: auto !important;
    }

    .modal-header {
        padding: 20px 20px 12px 20px;
    }

    .modal-overlay .progress-container {
        width: 300px;
        max-width: 50%;
        height: 6px;
    }

    .close-button {
        top: 12px;
        right: 12px;
    }

    .modal-content {
        padding: 24px 20px;
    }

    .step-content {
        width: 100% !important;
        max-width: 100% !important;
        min-width: auto !important;
    }

    .step-image-container {
        width: 100%;
        max-height: 250px;
        height: 250px;
        margin-bottom: 20px;
        padding: 16px;
    }

    .step-title {
        font-size: 20px;
        margin-bottom: 12px;
    }

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

    .modal-footer {
        padding: 16px 20px;
        flex-direction: column;
        gap: 12px;
    }

    .modal-footer .btn {
        width: 100%;
        padding: 14px 32px;
    }

}

@media (max-width: 480px) {
    .modal-container {
        width: 95vw !important;
        min-width: 95vw !important;
        max-width: 95vw !important;
    }

    .modal-header {
        padding: 18px 16px 12px 16px;
    }

    .modal-overlay .progress-container {
        width: 250px;
        max-width: 55%;
        height: 6px;
    }

    .close-button {
        top: 12px;
        right: 12px;
    }

    .modal-content {
        padding: 20px 16px;
    }

    .step-content {
        width: 100% !important;
        max-width: 100% !important;
        min-width: auto !important;
    }

    .step-image-container {
        width: 100%;
        max-height: 200px;
        height: 200px;
        padding: 12px;
    }

    .step-title {
        font-size: 18px;
    }

    .step-description {
        font-size: 13px;
        min-height: 60px;
    }

    .modal-footer {
        padding: 12px 16px;
    }
}
