/**
 * Custom Gigya Modal Styles
 */

/* Backdrop */
.custom-gigya-modal-backdrop {
    overflow: hidden;
}

/* Modal Container */
.custom-gigya-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    background-color: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.custom-gigya-modal--open {
    display: flex;
}

/* Modal Content */
.custom-gigya-modal__content {
    background: #fff;
    border-radius: 8px;
    max-width: 420px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
    animation: customGigyaFadeIn 0.2s ease-out;
}

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

/* Header */
.custom-gigya-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem 0.75rem;
    border-bottom: 1px solid #e9ecef;
}

.custom-gigya-modal__title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #333;
}

.custom-gigya-modal__close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #666;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    line-height: 1;
}

.custom-gigya-modal__close:hover {
    color: #000;
}

/* Body */
.custom-gigya-modal__body {
    padding: 1.5rem;
}

/* Error container */
.custom-gigya-modal__error {
    color: #dc3545;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    min-height: 0;
}

.custom-gigya-modal__error:empty {
    display: none;
}

/* Form */
.custom-gigya-modal__form .form-group {
    margin-bottom: 1rem;
}

.custom-gigya-modal__form .form-label {
    display: block;
    margin-bottom: 0.375rem;
    font-weight: 500;
    font-size: 0.875rem;
    color: #333;
}

.custom-gigya-modal__form .form-control {
    width: 100%;
    padding: 0.625rem 0.75rem;
    font-size: 0.9375rem;
    border: 1px solid #ced4da;
    border-radius: 4px;
    transition: border-color 0.15s ease-in-out;
    box-sizing: border-box;
}

.custom-gigya-modal__form .form-control:focus {
    border-color: #007bff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.custom-gigya-modal__form .form-control.is-invalid {
    border-color: #dc3545;
}

.custom-gigya-modal__form .invalid-feedback {
    display: none;
    font-size: 0.8rem;
    color: #dc3545;
    margin-top: 0.25rem;
}

.custom-gigya-modal__form .form-control.is-invalid ~ .invalid-feedback {
    display: block;
}

/* Checkbox */
.custom-gigya-modal__form .form-check {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.custom-gigya-modal__form .form-check-input {
    margin: 0;
}

.custom-gigya-modal__form .form-check-label {
    font-size: 0.875rem;
    color: #555;
}

/* Submit button */
.custom-gigya-modal__submit {
    width: 100%;
    padding: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    background-color: #007bff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.15s ease-in-out;
}

.custom-gigya-modal__submit:hover {
    background-color: #0056b3;
}

.custom-gigya-modal__submit:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
}

/* Links */
.custom-gigya-modal__links {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.custom-gigya-modal__link {
    font-size: 0.875rem;
    color: #007bff;
    text-decoration: none;
}

.custom-gigya-modal__link:hover {
    text-decoration: underline;
}


/* Password strength indicator (register modal) */
.custom-gigya-modal__password-strength {
    height: 4px;
    margin-top: 0.375rem;
    border-radius: 2px;
    background-color: #e9ecef;
    transition: background-color 0.2s ease-in-out;
}
.custom-gigya-modal__password-strength--level-0,
.custom-gigya-modal__password-strength--level-1 { background-color: #dc3545; }
.custom-gigya-modal__password-strength--level-2 { background-color: #fd7e14; }
.custom-gigya-modal__password-strength--level-3 { background-color: #ffc107; }
.custom-gigya-modal__password-strength--level-4 { background-color: #20c997; }
.custom-gigya-modal__password-strength--level-5 { background-color: #198754; }

/* Form text hint */
.custom-gigya-modal__form .form-text {
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

/* Success message */
.custom-gigya-modal__success {
    color: #198754;
    font-size: 0.9375rem;
    text-align: center;
    margin-bottom: 1rem;
}

/* Verify email landing page */
.custom-gigya-verify {
    padding: 4rem 1rem;
}
.custom-gigya-verify__title {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}
.custom-gigya-verify__message {
    color: #555;
    margin-bottom: 1.5rem;
}
