/* Тёмная тема для встроенных стилей небольших страниц аккаунта: register_success.php, restore.php,
   reset_password.php, link_account.php, confirm_email_link.php, signup_choice.php, password_reset_success/error.php, verification_success/error.php,
   login_error.php. Классы сообщений там повторяются, поэтому правила собраны в один файл. */

html[data-theme="dark"] .error-message,
html[data-theme="dark"] .error-details {
    color: var(--c-danger);
}

html[data-theme="dark"] .success-message {
    color: #8fe3a3;
}

/* сообщения-плашки на формах (restore, reset_password, link_account) */
html[data-theme="dark"] .restore-form .error-message,
html[data-theme="dark"] .reset-form .error-message,
html[data-theme="dark"] .link-account-form .error-message,
html[data-theme="dark"] .message.error-message {
    background-color: #3a1d20;
    border-color: #6b2f33;
}

html[data-theme="dark"] .restore-form .success-message,
html[data-theme="dark"] .reset-form .success-message,
html[data-theme="dark"] .link-account-form .success-message,
html[data-theme="dark"] .message.success-message {
    background-color: #17331f;
    border-color: #2b5a37;
}

html[data-theme="dark"] .error-details {
    background-color: #3a1d20;
    border-color: #6b2f33;
}

html[data-theme="dark"] .error-icon,
html[data-theme="dark"] .error-title {
    color: var(--c-danger);
}

html[data-theme="dark"] .success-icon,
html[data-theme="dark"] .success-title {
    color: #6fd68a;
}

html[data-theme="dark"] .status-box,
html[data-theme="dark"] .error-container,
html[data-theme="dark"] .success-container {
    background-color: var(--c-surface);
    border: 1px solid var(--c-border);
    color: var(--c-text);
}

html[data-theme="dark"] .error-container .error-message,
html[data-theme="dark"] .success-container .success-message,
html[data-theme="dark"] .redirect-message,
html[data-theme="dark"] .password-requirements,
html[data-theme="dark"] .link-account-divider {
    color: var(--c-muted);
}

/* на странице login_error.php контейнер сам красный */
html[data-theme="dark"] .error-container:has(.error-title):not(:has(.error-details)) {
    background-color: #3a1d20;
    border-color: #6b2f33;
}

html[data-theme="dark"] .link-account-google-btn {
    background: var(--c-surface-2);
    border-color: var(--c-border);
    color: var(--c-text);
}

html[data-theme="dark"] .login-button,
html[data-theme="dark"] .success-button {
    background-color: var(--c-accent);
    color: var(--c-on-accent);
}

/* signup_choice.php: вторая кнопка «Создать новый аккаунт» — контурная */
html[data-theme="dark"] .signup-choice-create {
    border-color: var(--c-accent);
    color: var(--c-accent-text);
}

html[data-theme="dark"] .signup-choice-or {
    color: var(--c-muted);
}

html[data-theme="dark"] .signup-choice-consent a {
    color: var(--c-accent-text);
}
