/**
 * Стили для плагина checkoutauth
 * Формы авторизации/регистрации/восстановления пароля
 */

/* ========== СКРЫТИЕ ВСТРОЕННЫХ ССЫЛОК WEBASYST ========== */
.checkoutauth-wrapper .wa-login-forgotpassword-url,
.checkoutauth-wrapper .wa-login-url {
    display: none !important;
}

/* ========== УТИЛИТЫ ========== */
.hidden {
    display: none !important;
}

/* ========== ОСНОВНОЙ КОНТЕЙНЕР ========== */
.checkoutauth-wrapper {
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid oklch(92.8% 0.006 264.531);
}

/* ========== ТАБЫ ПЕРЕКЛЮЧЕНИЯ ========== */
.checkoutauth-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    padding: 4px;
    background: #f5f5f5;
    border-radius: 8px;
}

.checkoutauth-tab {
    flex: 1;
    padding: 10px 16px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    transition: all 0.2s ease;
    outline: none;
    border-radius: 6px;
}

.checkoutauth-tab:hover {
    color: #333;
    background: rgba(0, 0, 0, 0.05);
}

.checkoutauth-tab.active {
    color: #335eea;
    background: #fff;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* ========== КОНТЕЙНЕР ФОРМ ========== */
.checkoutauth-forms-container {
    position: relative;
    min-height: 300px;
}

/* ========== ИНДИКАТОР ЗАГРУЗКИ ========== */
.checkoutauth-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.checkoutauth-loader-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #335eea;
    border-radius: 50%;
    animation: checkoutauth-spin 1s linear infinite;
}

@keyframes checkoutauth-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.checkoutauth-loader-text {
    font-size: 14px;
    color: #666;
}

/* ========== КОНТЕНТ ФОРМЫ ========== */
.checkoutauth-form-content {
    transition: opacity 0.3s ease;
}

/* ========== ОБЕРТКА ФОРМЫ ========== */
.checkoutauth-form-wrapper {
    padding: 20px 0;
}

/* ========== ЗАГОЛОВОК ФОРМЫ ========== */
.checkoutauth-form-header {
    margin-bottom: 30px;
    text-align: center;
}

.checkoutauth-form-title {
    margin: 0 0 10px 0;
    font-size: 20px;
    font-weight: 500;
    color: #333;
}

.checkoutauth-form-description {
    margin: 0;
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* ========== ФУТЕР ФОРМЫ ========== */
.checkoutauth-form-footer {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkoutauth-form-links {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* ========== КНОПКИ-ССЫЛКИ ========== */
.checkoutauth-link-btn {
    background: none;
    border: none;
    color: #335eea;
    cursor: pointer;
    text-decoration: none;
    font-size: inherit;
    padding: 0;
    font-family: inherit;
    outline: none;
    transition: opacity 0.2s ease;
}

.checkoutauth-link-btn:hover {
    opacity: 0.7;
}

.checkoutauth-link-btn:focus {
    outline: 2px solid #335eea;
    outline-offset: 2px;
}

/* Кнопка "Назад" */
.checkoutauth-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: none;
    color: #666;
    font-size: 14px;
    cursor: pointer;
    padding: 0;
    transition: opacity 0.2s ease;
}

.checkoutauth-back-btn:hover {
    opacity: 0.7;
}

.checkoutauth-back-icon {
    width: 16px;
    height: 16px;
    display: inline-block;
}

.checkoutauth-back-icon::before {
    content: '';
    display: block;
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23666' viewBox='0 0 16 16'%3E%3Cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

/* ========== СООБЩЕНИЕ ОБ ОШИБКЕ ========== */
.checkoutauth-error {
    padding: 30px 20px;
    text-align: center;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
}

.checkoutauth-error-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.checkoutauth-error-message {
    margin-bottom: 20px;
    font-size: 16px;
    color: #856404;
    font-weight: 500;
}

.checkoutauth-error-btn {
    padding: 10px 20px;
    background: #335eea;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.2s ease;
}

.checkoutauth-error-btn:hover {
    background: #2648c9;
}

/* ========== OAUTH АДАПТЕРЫ ========== */
.checkoutauth-adapters {
    margin-bottom: 20px;
}

.checkoutauth-adapters-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.checkoutauth-oauth-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 333px;
    overflow-y: auto;
}

.checkoutauth-oauth-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
}

.checkoutauth-oauth-btn:hover {
    background: #f8f8f8;
    border-color: #ccc;
    opacity: 0.8;
}

.checkoutauth-oauth-icon {
    position: absolute;
    top: 50%;
    left: 8px;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.checkoutauth-oauth-icon img {
    width: 20px;
    height: 20px;
}

.checkoutauth-oauth-text {
    width: 100%;
    text-align: center;
}

/* Email section */
.checkoutauth-email-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.checkoutauth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    font-size: 12px;
    color: #666;
    text-transform: uppercase;
}

.checkoutauth-divider::before,
.checkoutauth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #ddd;
}

.checkoutauth-divider span {
    padding: 0 24px;
}

.checkoutauth-email-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 16px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    color: #333;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.checkoutauth-email-toggle:hover {
    background: #f8f8f8;
    border-color: #ccc;
}

.checkoutauth-email-icon {
    position: absolute;
    top: 50%;
    left: 8px;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
}

/* ========== СТИЛИ ДЛЯ ВСТРОЕННЫХ ФОРМ WEBASYST ========== */

/* Общие стили для декораторов форм */
.login-form-decorator,
.signup-form-decorator,
.forgot-password-form-decorator {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.login-form-decorator > div,
.signup-form-decorator > form,
.forgot-password-form-decorator > form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Принудительно показываем wrapper форм Webasyst */
.checkoutauth-form-content .wa-signup-form-wrapper,
.checkoutauth-form-content .wa-login-form-wrapper,
.checkoutauth-form-content .wa-password-form-wrapper {
    visibility: visible !important;
    display: block !important;
}

/* Убираем лишние отступы у встроенных форм */
.checkoutauth-form-content form {
    margin: 0;
}

.checkoutauth-form-content .wa-form {
    margin: 0;
}

/* Поля форм */
.wa-login-form-fields,
.wa-signup-form-fields,
.wa-forgotpassword-form-fields {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Labels */
.wa-login-form-fields .wa-name,
.wa-signup-form-fields .wa-name,
.wa-forgotpassword-form-fields .wa-name {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

/* Inputs, selects, textareas */
.wa-login-form-fields .wa-value input[type="text"],
.wa-login-form-fields .wa-value input[type="email"],
.wa-login-form-fields .wa-value input[type="password"],
.wa-login-form-fields .wa-value select,
.wa-login-form-fields .wa-value textarea,
.wa-signup-form-fields .wa-value input[type="text"],
.wa-signup-form-fields .wa-value input[type="email"],
.wa-signup-form-fields .wa-value input[type="password"],
.wa-signup-form-fields .wa-value select,
.wa-signup-form-fields .wa-value textarea,
.wa-forgotpassword-form-fields .wa-value input[type="text"],
.wa-forgotpassword-form-fields .wa-value input[type="email"],
.wa-forgotpassword-form-fields .wa-value input[type="password"],
.wa-forgotpassword-form-fields .wa-value select,
.wa-forgotpassword-form-fields .wa-value textarea {
    width: 100%;
    padding: 10px 12px;
    font-size: 14px;
    color: #333;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Select custom arrow */
.wa-login-form-fields .wa-value select,
.wa-signup-form-fields .wa-value select,
.wa-forgotpassword-form-fields .wa-value select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding-right: 40px;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
}

.wa-login-form-fields .wa-value input[type="text"]:focus,
.wa-login-form-fields .wa-value input[type="email"]:focus,
.wa-login-form-fields .wa-value input[type="password"]:focus,
.wa-signup-form-fields .wa-value input[type="text"]:focus,
.wa-signup-form-fields .wa-value input[type="email"]:focus,
.wa-signup-form-fields .wa-value input[type="password"]:focus,
.wa-forgotpassword-form-fields .wa-value input[type="text"]:focus,
.wa-forgotpassword-form-fields .wa-value input[type="email"]:focus,
.wa-forgotpassword-form-fields .wa-value input[type="password"]:focus,
.wa-login-form-fields .wa-value select:focus,
.wa-signup-form-fields .wa-value select:focus,
.wa-forgotpassword-form-fields .wa-value select:focus,
.wa-login-form-fields .wa-value textarea:focus,
.wa-signup-form-fields .wa-value textarea:focus,
.wa-forgotpassword-form-fields .wa-value textarea:focus {
    outline: none !important;
    border-color: #335eea;
    box-shadow: none;
}

/* Error inputs */
.wa-login-form-fields .wa-value input.wa-error,
.wa-signup-form-fields .wa-value input.wa-error,
.wa-forgotpassword-form-fields .wa-value input.wa-error {
    border-color: #dc3545;
}

/* Checkboxes */
.wa-login-form-fields .wa-value input[type="checkbox"],
.wa-signup-form-fields .wa-value input[type="checkbox"],
.wa-forgotpassword-form-fields .wa-value input[type="checkbox"] {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    min-width: 20px;
    height: 20px;
    min-height: 20px;
    margin-right: 8px;
    cursor: pointer;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.2s ease-in-out;
}

.wa-login-form-fields .wa-value input[type="checkbox"]:hover,
.wa-signup-form-fields .wa-value input[type="checkbox"]:hover,
.wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:hover {
    border-color: #335eea;
    box-shadow: 0 0 0 1px inset #335eea;
}

.wa-login-form-fields .wa-value input[type="checkbox"]:checked,
.wa-signup-form-fields .wa-value input[type="checkbox"]:checked,
.wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:checked {
    background-color: #335eea;
    border-color: #335eea;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
}

/* Radio buttons */
.wa-login-form-fields .wa-value input[type="radio"],
.wa-signup-form-fields .wa-value input[type="radio"],
.wa-forgotpassword-form-fields .wa-value input[type="radio"] {
    margin-right: 8px;
    cursor: pointer;
}

/* Remember me field */
.wa-field-remember-me .wa-value label {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Terms accepted field */
.wa-field-terms-accepted .wa-value label {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Checkbox/radio labels */
.wa-login-form-fields .wa-value > p,
.wa-signup-form-fields .wa-value > p,
.wa-forgotpassword-form-fields .wa-value > p {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.wa-login-form-fields .wa-value > p > label,
.wa-signup-form-fields .wa-value > p > label,
.wa-forgotpassword-form-fields .wa-value > p > label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #666;
    cursor: pointer;
}

/* Birthday field */
.wa-field-birthday .wa-value {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

@media (min-width: 640px) {
    .wa-field-birthday .wa-value {
        flex-direction: row;
    }

    .wa-field-birthday .wa-value input {
        width: auto !important;
    }
}

/* Password forgot link */
.wa-login-forgotpassword-url {
    display: block;
    margin-top: 8px;
    font-size: 14px;
    color: #666;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* Error messages */
.wa-login-form-fields .wa-value .wa-error-msg,
.wa-signup-form-fields .wa-value .wa-error-msg,
.wa-forgotpassword-form-fields .wa-value .wa-error-msg {
    display: block;
    font-size: 14px;
    color: #dc3545;
}

.wa-login-form-fields .wa-value > .wa-error-msg,
.wa-signup-form-fields .wa-value > .wa-error-msg,
.wa-forgotpassword-form-fields .wa-value > .wa-error-msg {
    margin-top: 8px;
}

/* One-time password links */
.wa-send-again-onetime-password-link,
.wa-send-onetime-password-edit-link,
.wa-onetime-password-input-message .wa-info-msg {
    display: block;
    margin-top: 8px;
    font-size: 14px;
    color: #666;
}

.wa-send-again-onetime-password-link,
.wa-send-onetime-password-edit-link {
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* Form actions */
.wa-login-form-actions,
.wa-signup-form-actions,
.wa-forgotpassword-form-actions {
    margin-top: 16px;
}

/* Submit buttons */
.wa-login-form-actions .wa-request-onetime-password-button,
.wa-login-form-actions .wa-buttons-wrapper input[type="submit"],
.wa-signup-form-actions .wa-buttons-wrapper input[type="submit"],
.wa-forgotpassword-button input[type="submit"] {
    width: 100%;
    padding: 12px;
    background: #335eea;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.wa-login-form-actions .wa-request-onetime-password-button:hover,
.wa-login-form-actions .wa-buttons-wrapper input[type="submit"]:hover,
.wa-signup-form-actions .wa-buttons-wrapper input[type="submit"]:hover,
.wa-forgotpassword-button input[type="submit"]:hover {
    background: #2648c9;
}

.wa-forgotpassword-button input[type="submit"] {
    margin-top: 16px;
}

/* Hide default signup/login urls */
.wa-login-form-actions .wa-signup-url,
.wa-signup-form-actions .wa-login-url,
.wa-forgotpassword-form-decorator .wa-login-url {
    display: none !important;
}

/* Uncaught errors */
.wa-login-form-actions .wa-uncaught-errors .wa-error-msg,
.wa-signup-form-actions .wa-uncaught-errors .wa-error-msg {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: #dc3545;
}

/* Info messages */
.wa-forgotpassword-form-decorator .wa-info-msg {
    text-align: center;
}

/* ========== АДАПТИВНОСТЬ ========== */
@media (max-width: 576px) {
    .checkoutauth-wrapper {
        padding: 15px;
        border-radius: 0;
        box-shadow: none;
    }

    .checkoutauth-tab {
        padding: 10px 8px;
        font-size: 12px;
    }

    .checkoutauth-form-title {
        font-size: 18px;
    }

    .checkoutauth-form-links {
        font-size: 13px;
    }

    .checkoutauth-link-btn {
        font-size: 13px;
    }
}

@media (max-width: 400px) {
    .checkoutauth-wrapper {
        padding: 10px;
    }

    .checkoutauth-tabs {
        gap: 5px;
    }

    .checkoutauth-tab {
        padding: 8px 6px;
        font-size: 11px;
    }

    .checkoutauth-form-title {
        font-size: 16px;
    }
}

/* ========== ТЕМНАЯ ТЕМА ========== */
html.dark .checkoutauth-wrapper,
html[data-theme="dark"] .checkoutauth-wrapper,
html[data-bs-theme="dark"] .checkoutauth-wrapper {
    background: #212121;
    color: #e5e7eb;
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

html.dark .checkoutauth-tabs,
html[data-theme="dark"] .checkoutauth-tabs,
html[data-bs-theme="dark"] .checkoutauth-tabs {
    background: #2a2a2a;
}

html.dark .checkoutauth-tab,
html[data-theme="dark"] .checkoutauth-tab,
html[data-bs-theme="dark"] .checkoutauth-tab {
    color: #bdbdbd;
}

html.dark .checkoutauth-tab:hover,
html[data-theme="dark"] .checkoutauth-tab:hover,
html[data-bs-theme="dark"] .checkoutauth-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

html.dark .checkoutauth-tab.active,
html[data-theme="dark"] .checkoutauth-tab.active,
html[data-bs-theme="dark"] .checkoutauth-tab.active {
    color: #fff;
    background: #212121;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

html.dark .checkoutauth-form-title,
html[data-theme="dark"] .checkoutauth-form-title,
html[data-bs-theme="dark"] .checkoutauth-form-title {
    color: #e5e7eb;
}

html.dark .checkoutauth-form-description,
html[data-theme="dark"] .checkoutauth-form-description,
html[data-bs-theme="dark"] .checkoutauth-form-description,
html.dark .checkoutauth-form-links,
html[data-theme="dark"] .checkoutauth-form-links,
html[data-bs-theme="dark"] .checkoutauth-form-links {
    color: #bdbdbd;
}

html.dark .checkoutauth-link-btn,
html[data-theme="dark"] .checkoutauth-link-btn,
html[data-bs-theme="dark"] .checkoutauth-link-btn {
    color: #335eea;
}

html.dark .checkoutauth-link-btn:hover,
html[data-theme="dark"] .checkoutauth-link-btn:hover,
html[data-bs-theme="dark"] .checkoutauth-link-btn:hover {
    color: #93c5fd;
}

html.dark .checkoutauth-back-btn,
html[data-theme="dark"] .checkoutauth-back-btn,
html[data-bs-theme="dark"] .checkoutauth-back-btn {
    color: #bdbdbd;
}

html.dark .checkoutauth-back-icon::before,
html[data-theme="dark"] .checkoutauth-back-icon::before,
html[data-bs-theme="dark"] .checkoutauth-back-icon::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
}

html.dark .checkoutauth-oauth-btn,
html[data-theme="dark"] .checkoutauth-oauth-btn,
html[data-bs-theme="dark"] .checkoutauth-oauth-btn,
html.dark .checkoutauth-email-toggle,
html[data-theme="dark"] .checkoutauth-email-toggle,
html[data-bs-theme="dark"] .checkoutauth-email-toggle {
    color: #F5F5F5;
    background-color: #2a2a2a;
    border: 1px solid #616161;
}

html.dark .checkoutauth-oauth-btn:hover,
html[data-theme="dark"] .checkoutauth-btn:hover,
html[data-bs-theme="dark"] .checkoutauth-oauth-btn:hover,
html.dark .checkoutauth-email-toggle:hover,
html[data-theme="dark"] .checkoutauth-email-toggle:hover,
html[data-bs-theme="dark"] .checkoutauth-email-toggle:hover {
    background: #3a3a3a;
    border-color: #757575;
}

html.dark .checkoutauth-divider,
html[data-theme="dark"] .checkoutauth-divider,
html[data-bs-theme="dark"] .checkoutauth-divider {
    color: #bdbdbd;
}

html.dark .checkoutauth-divider::before,
html[data-theme="dark"] .checkoutauth-divider::before,
html[data-bs-theme="dark"] .checkoutauth-divider::before,
html.dark .checkoutauth-divider::after,
html[data-theme="dark"] .checkoutauth-divider::after,
html[data-bs-theme="dark"] .checkoutauth-divider::after {
    border-bottom-color: #4b5563;
}

/* Темная тема для полей форм */
html.dark .wa-login-form-fields .wa-name,
html[data-theme="dark"] .wa-login-form-fields .wa-name,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-name,
html.dark .wa-signup-form-fields .wa-name,
html[data-theme="dark"] .wa-signup-form-fields .wa-name,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-name,
html.dark .wa-forgotpassword-form-fields .wa-name,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-name,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-name {
    color: #e5e7eb;
}

html.dark .wa-login-form-fields .wa-value input[type="text"],
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="text"],
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="text"],
html.dark .wa-login-form-fields .wa-value input[type="email"],
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="email"],
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="email"],
html.dark .wa-login-form-fields .wa-value input[type="password"],
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="password"],
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="password"],
html.dark .wa-signup-form-fields .wa-value input[type="text"],
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="text"],
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="text"],
html.dark .wa-signup-form-fields .wa-value input[type="email"],
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="email"],
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="email"],
html.dark .wa-signup-form-fields .wa-value input[type="password"],
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="password"],
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="password"],
html.dark .wa-forgotpassword-form-fields .wa-value input[type="text"],
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="text"],
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="text"],
html.dark .wa-forgotpassword-form-fields .wa-value input[type="email"],
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="email"],
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="email"],
html.dark .wa-forgotpassword-form-fields .wa-value input[type="password"],
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="password"],
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="password"],
html.dark .wa-login-form-fields .wa-value select,
html[data-theme="dark"] .wa-login-form-fields .wa-value select,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value select,
html.dark .wa-signup-form-fields .wa-value select,
html[data-theme="dark"] .wa-signup-form-fields .wa-value select,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value select,
html.dark .wa-forgotpassword-form-fields .wa-value select,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value select,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value select,
html.dark .wa-login-form-fields .wa-value textarea,
html[data-theme="dark"] .wa-login-form-fields .wa-value textarea,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value textarea,
html.dark .wa-signup-form-fields .wa-value textarea,
html[data-theme="dark"] .wa-signup-form-fields .wa-value textarea,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value textarea,
html.dark .wa-forgotpassword-form-fields .wa-value textarea,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value textarea,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value textarea {
    color: #F5F5F5;
    background-color: #2a2a2a;
    border: 1px solid #616161;
}

/* Dark theme select custom arrow */
html.dark .wa-login-form-fields .wa-value select,
html[data-theme="dark"] .wa-login-form-fields .wa-value select,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value select,
html.dark .wa-signup-form-fields .wa-value select,
html[data-theme="dark"] .wa-signup-form-fields .wa-value select,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value select,
html.dark .wa-forgotpassword-form-fields .wa-value select,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value select,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23F5F5F5' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}

html.dark .wa-login-form-fields .wa-value input[type="text"]:focus,
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="text"]:focus,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="text"]:focus,
html.dark .wa-login-form-fields .wa-value input[type="email"]:focus,
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="email"]:focus,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="email"]:focus,
html.dark .wa-login-form-fields .wa-value input[type="password"]:focus,
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="password"]:focus,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="password"]:focus,
html.dark .wa-signup-form-fields .wa-value input[type="text"]:focus,
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="text"]:focus,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="text"]:focus,
html.dark .wa-signup-form-fields .wa-value input[type="email"]:focus,
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="email"]:focus,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="email"]:focus,
html.dark .wa-signup-form-fields .wa-value input[type="password"]:focus,
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="password"]:focus,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="password"]:focus,
html.dark .wa-forgotpassword-form-fields .wa-value input[type="text"]:focus,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="text"]:focus,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="text"]:focus,
html.dark .wa-forgotpassword-form-fields .wa-value input[type="email"]:focus,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="email"]:focus,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="email"]:focus,
html.dark .wa-forgotpassword-form-fields .wa-value input[type="password"]:focus,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="password"]:focus,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="password"]:focus {
    outline: none;
    border-color: #616161;
    box-shadow: none;
}

html.dark .wa-login-form-fields .wa-value > p > label,
html[data-theme="dark"] .wa-login-form-fields .wa-value > p > label,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value > p > label,
html.dark .wa-signup-form-fields .wa-value > p > label,
html[data-theme="dark"] .wa-signup-form-fields .wa-value > p > label,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value > p > label,
html.dark .wa-forgotpassword-form-fields .wa-value > p > label,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value > p > label,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value > p > label {
    color: #bdbdbd;
}

/* Dark theme checkboxes */
html.dark .wa-login-form-fields .wa-value input[type="checkbox"],
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="checkbox"],
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="checkbox"],
html.dark .wa-signup-form-fields .wa-value input[type="checkbox"],
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="checkbox"],
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="checkbox"],
html.dark .wa-forgotpassword-form-fields .wa-value input[type="checkbox"],
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="checkbox"],
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="checkbox"] {
    border-color: #616161;
    background-color: #212121;
}

html.dark .wa-login-form-fields .wa-value input[type="checkbox"]:hover,
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="checkbox"]:hover,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="checkbox"]:hover,
html.dark .wa-signup-form-fields .wa-value input[type="checkbox"]:hover,
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="checkbox"]:hover,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="checkbox"]:hover,
html.dark .wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:hover,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:hover,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:hover {
    border-color: #335eea;
    box-shadow: 0 0 0 1px inset #335eea;
}

html.dark .wa-login-form-fields .wa-value input[type="checkbox"]:checked,
html[data-theme="dark"] .wa-login-form-fields .wa-value input[type="checkbox"]:checked,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value input[type="checkbox"]:checked,
html.dark .wa-signup-form-fields .wa-value input[type="checkbox"]:checked,
html[data-theme="dark"] .wa-signup-form-fields .wa-value input[type="checkbox"]:checked,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value input[type="checkbox"]:checked,
html.dark .wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:checked,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:checked,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value input[type="checkbox"]:checked {
    background-color: #335eea;
    border-color: #335eea;
}

html.dark .wa-login-forgotpassword-url,
html[data-theme="dark"] .wa-login-forgotpassword-url,
html[data-bs-theme="dark"] .wa-login-forgotpassword-url,
html.dark .wa-send-again-onetime-password-link,
html[data-theme="dark"] .wa-send-again-onetime-password-link,
html[data-bs-theme="dark"] .wa-send-again-onetime-password-link,
html.dark .wa-send-onetime-password-edit-link,
html[data-theme="dark"] .wa-send-onetime-password-edit-link,
html[data-bs-theme="dark"] .wa-send-onetime-password-edit-link,
html.dark .wa-onetime-password-input-message .wa-info-msg,
html[data-theme="dark"] .wa-onetime-password-input-message .wa-info-msg,
html[data-bs-theme="dark"] .wa-onetime-password-input-message .wa-info-msg {
    color: #bdbdbd;
}

html.dark .wa-login-form-fields .wa-value .wa-error-msg,
html[data-theme="dark"] .wa-login-form-fields .wa-value .wa-error-msg,
html[data-bs-theme="dark"] .wa-login-form-fields .wa-value .wa-error-msg,
html.dark .wa-signup-form-fields .wa-value .wa-error-msg,
html[data-theme="dark"] .wa-signup-form-fields .wa-value .wa-error-msg,
html[data-bs-theme="dark"] .wa-signup-form-fields .wa-value .wa-error-msg,
html.dark .wa-forgotpassword-form-fields .wa-value .wa-error-msg,
html[data-theme="dark"] .wa-forgotpassword-form-fields .wa-value .wa-error-msg,
html[data-bs-theme="dark"] .wa-forgotpassword-form-fields .wa-value .wa-error-msg,
html.dark .wa-login-form-actions .wa-uncaught-errors .wa-error-msg,
html[data-theme="dark"] .wa-login-form-actions .wa-uncaught-errors .wa-error-msg,
html[data-bs-theme="dark"] .wa-login-form-actions .wa-uncaught-errors .wa-error-msg,
html.dark .wa-signup-form-actions .wa-uncaught-errors .wa-error-msg,
html[data-theme="dark"] .wa-signup-form-actions .wa-uncaught-errors .wa-error-msg,
html[data-bs-theme="dark"] .wa-signup-form-actions .wa-uncaught-errors .wa-error-msg {
    color: #f87171;
}
