/* ================= AUTH TOAST COMPONENT ================= */
.auth-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 300px;
    width: min(300px, calc(100vw - 40px));
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border-left: 4px solid;
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.3s ease;
}

.auth-toast.auth-toast-success {
    border-left-color: #10b981;
}

.auth-toast.auth-toast-error {
    border-left-color: #ef4444;
}

.auth-toast.auth-toast-warning {
    border-left-color: #f59e0b;
}

.auth-toast.auth-toast-info {
    border-left-color: #3b82f6;
}

.auth-toast-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
}

.auth-toast-icon {
    width: 30px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
    font-size: 16px;
}

.auth-toast-success .auth-toast-icon {
    background: #10b981;
    color: #ffffff;
}

.auth-toast-error .auth-toast-icon {
    background: #ef4444;
    color: #ffffff;
}

.auth-toast-warning .auth-toast-icon {
    background: #f59e0b;
    color: #ffffff;
}

.auth-toast-info .auth-toast-icon {
    background: #3b82f6;
    color: #ffffff;
}

.auth-toast-message {
    flex: 1;
    font-size: 16px;
    font-weight: 500;
    color: #1f2937;
    line-height: 1.5;
}

/* ================= MESSAGE TYPE MODIFIERS ================= */

.auth-toast-password {
    max-width: 320px;
    width: min(320px, calc(400vw - 200px));
}

.auth-toast-password .auth-toast-message {
    font-size: 16px;
    line-height: 1.4;
    white-space: normal;
}

.auth-toast-password .auth-toast-icon {
    width: 32px;
    height: 32px;
    font-size: 15px;
}

.auth-toast-password-regex {
    max-width: 450px;
     width: min(440px, calc(400vw - 200px));
     height: 80px;
}

.auth-toast-password-regex .auth-toast-message {
    font-size: 16px;
    line-height: 25px;
    white-space: normal;
    text-align: justify;
}

.auth-toast-password-regex .auth-toast-icon {
    width: 32px;
    height: 32px;
    font-size: 15px;
}

.auth-toast-password-min {
    max-width: 400px;
    width: min(400px, calc(400vw - 200px));
}

.auth-toast-password-min .auth-toast-message {
    font-size: 16px;
    line-height: 1.4;
    white-space: nowrap;
}

.auth-toast-password-min .auth-toast-icon {
    width: 30px;
    height: 30px;
    font-size: 14px;
}

.auth-toast-username {
    max-width: 300px;
}

.auth-toast-username .auth-toast-message {
    font-size: 17px;
    white-space: nowrap;
}

.auth-toast-username .auth-toast-icon {
    width: 30px;
    height: 30px;
    font-size: 14px;
}

.auth-toast-email {
    max-width: 300px;
}

.auth-toast-email .auth-toast-message {
    font-size: 17px;
    white-space: nowrap;
}

.auth-toast-email .auth-toast-icon {
    width: 30px;
    height: 30px;
    font-size: 16px;
}

.auth-toast-generic {
    max-width: 340px;
}

.auth-toast-generic .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
}

.auth-toast-multiple-errors {
    max-width: 360px;
}

.auth-toast-multiple-errors .auth-toast-message {
    font-size: 16px;
    line-height: 20px;
    white-space: normal;
    text-align: justify;
}

.auth-toast-otp {
    max-width: 320px;
}

.auth-toast-otp .auth-toast-message {
    font-size: 15px;
}

.auth-toast-otp-invalid {
    max-width: 180px;
    width: min(180px, calc(40vw - 20px));
}

.auth-toast-otp-invalid .auth-toast-message {
    font-size: 15px;
    white-space: nowrap;
}

.auth-toast-otp-expired {
    max-width: 400px;
    width: min(400px, calc(400vw - 200px));
}

.auth-toast-otp-expired .auth-toast-message {
    font-size: 16px;
    line-height: 20px;
    white-space: normal;
    text-align: justify;
}

.auth-toast-otp-resend {
    max-width: 380px;
    width: min(380px, calc(400vw - 200px));
}

.auth-toast-otp-resend .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
}

.auth-toast-success-action {
    max-width: 360px;
}

.auth-toast-success-action .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
}

.auth-toast-referral {
    max-width: 360px;
    width: min(360px, calc(100vw - 40px));
}

.auth-toast-referral .auth-toast-message {
    font-size: 16px;
}

.auth-toast-login-username {
    max-width: 290px;
    width: min(290px, calc(400vw - 200px));
}

.auth-toast-login-username .auth-toast-message {
    font-size: 16px;
    white-space: nowrap;
}

.auth-toast-login-password {
    max-width: 250px;
    width: min(250px, calc(400vw - 200px));
}

.auth-toast-login-password .auth-toast-message {
    font-size: 16px;
    white-space: nowrap;
}

/* ================= PASSWORD RESET SPECIFIC MESSAGES ================= */

.auth-toast-email-not-found {
    max-width: 390px;
    width: min(390px, calc(100vw - 40px));
}

.auth-toast-email-not-found .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
    text-align: justify;
}

.auth-toast-email-not-verified {
    max-width: 320px;
    width: min(320px, calc(100vw - 40px));
}

.auth-toast-email-not-verified .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
    text-align: justify;
}

.auth-toast-verification-sent {
    max-width: 380px;
    width: min(380px, calc(100vw - 40px));
}

.auth-toast-verification-sent .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

/* ================= VERIFY RESET SPECIFIC MESSAGES ================= */

.auth-reset-otp-invalid {
    max-width: 270px;
    width: min(270px, calc(100vw - 40px));
}

.auth-reset-otp-invalid .auth-toast-message {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
    white-space: nowrap;
}

.auth-reset-otp-expired {
    max-width: 400px;
    width: min(400px, calc(100vw - 40px));
}

.auth-reset-otp-expired .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
    text-align: justify;
}

.auth-reset-otp-resend {
    max-width: 370px;
    width: min(370px, calc(100vw - 40px));
}

.auth-reset-otp-resend .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

.auth-reset-verify-success {
    max-width: 360px;
    width: min(360px, calc(100vw - 40px));
}

.auth-reset-verify-success .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

.auth-reset-network-error {
    max-width: 340px;
    width: min(340px, calc(100vw - 40px));
}

.auth-reset-network-error .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

/* ================= RESET PASSWORD SPECIFIC MESSAGES ================= */

.auth-reset-password-match {
    max-width: 300px;
    width: min(300px, calc(100vw - 40px));
}

.auth-reset-password-match .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

.auth-reset-password-regex {
    max-width: 440px;
    width: min(440px, calc(100vw - 40px));
}

.auth-reset-password-regex .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
    text-align: justify;
}

.auth-reset-password-min {
    max-width: 340px;
    width: min(340px, calc(100vw - 40px));
}

.auth-reset-password-min .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

.auth-reset-password-success {
    max-width: 400px;
    width: min(400px, calc(100vw - 40px));
}

.auth-reset-password-success .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
    text-align: justify;
}

.auth-reset-password-error {
    max-width: 350px;
    width: min(350px, calc(100vw - 40px));
}

.auth-reset-password-error .auth-toast-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    white-space: normal;
}

.auth-toast-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px;
    border-radius: 6px;
    color: #6b7280;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.auth-toast-close:hover {
    color: #374151;
    background: #f3f4f6;
}

/* Show animation */
.auth-toast:not(.auth-toast-exit) {
    transform: translateX(0);
    opacity: 1;
}

/* Exit animation */
.auth-toast.auth-toast-exit {
    transform: translateX(100%);
    opacity: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .auth-toast {
        top: 20px;
        right: 20px;
        max-width: 260px;
    }

    .auth-toast-content {
        padding: 12px;
        gap: 8px;
    }

    .auth-toast-icon {
        width: 26px;
        height: 26px;
        font-size: 13px;
    }

    .auth-toast-message {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .auth-toast {
        top: 15px;
        right: 12px;
        max-width: 240px;
    }

    .auth-toast-content {
        padding: 10px 12px;
        gap: 6px;
    }

    .auth-toast-close {
        display: none;
    }
}
