/* Wallet top-up CTA: scoped to avoid changing other theme buttons. */
.uh-wallet .uh-wallet-form > button[type="submit"] {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 12px 24px;
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 14px;
    background: var(--uh-primary, #4f46e5);
    background: linear-gradient(135deg, var(--uh-primary, #4f46e5), #3730a3);
    color: #fff;
    box-shadow: 0 5px 14px rgba(79, 70, 229, .24);
    font: inherit;
    font-weight: 700;
    line-height: 1.5;
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.uh-wallet .uh-wallet-form > button[type="submit"]::before {
    content: "+";
    display: inline-grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 8px;
    background: rgba(255, 255, 255, .16);
    font-size: 20px;
    line-height: 1;
}
.uh-wallet .uh-wallet-form > button[type="submit"]:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(79, 70, 229, .32);
    filter: brightness(1.08);
}
.uh-wallet .uh-wallet-form > button[type="submit"]:active:not(:disabled) {
    transform: translateY(0);
}
.uh-wallet .uh-wallet-form > button[type="submit"]:focus-visible {
    outline: 3px solid var(--uh-accent, #0ea5e9);
    outline-offset: 3px;
}
.uh-wallet .uh-wallet-form > button[type="submit"]:disabled {
    opacity: .65;
    cursor: wait;
    box-shadow: none;
}
@media (max-width: 600px) {
    .uh-wallet .uh-wallet-form > button[type="submit"] {
        width: 100%;
        margin-top: 12px;
        box-sizing: border-box;
    }
}
@media (prefers-reduced-motion: reduce) {
    .uh-wallet .uh-wallet-form > button[type="submit"] {
        transition: none;
        transform: none !important;
    }
}

.uh-dashboard {
    color: var(--uh-ink);
    color-scheme: light;
}

/* Strict inverse text contrast for the two dashboard themes. */
.uh-dashboard[data-uh-theme="light"] {
    --uh-ink: #000;
    --uh-muted: #000;
    --uh-bg: #fff;
    --uh-surface: #fff;
    background: #fff;
    color: #000;
}

.uh-dashboard[data-uh-theme="light"] .uh-card,
.uh-dashboard[data-uh-theme="light"] .uh-welcome,
.uh-dashboard[data-uh-theme="light"] .uh-referral-card,
.uh-dashboard[data-uh-theme="light"] .uh-notifications-card,
.uh-dashboard[data-uh-theme="light"] .uh-browser-push,
.uh-dashboard[data-uh-theme="light"] .uh-points-redeem-card,
.uh-dashboard[data-uh-theme="light"] .uh-benefits-card,
.uh-dashboard[data-uh-theme="light"] .uh-onboarding-card,
.uh-dashboard[data-uh-theme="light"] .uh-cashback-banner,
.uh-dashboard[data-uh-theme="light"] .uh-native-form,
.uh-dashboard[data-uh-theme="light"] .uh-address-card,
.uh-dashboard[data-uh-theme="light"] .uh-native-product,
.uh-dashboard[data-uh-theme="light"] .woocommerce-MyAccount-content,
.uh-dashboard[data-uh-theme="light"] .woocommerce form,
.uh-dashboard[data-uh-theme="light"] .woocommerce table.shop_table {
    background: #fff;
    color: #000;
}

.uh-dashboard[data-uh-theme="light"] :where(h1,h2,h3,h4,h5,h6,p,label,small,strong,li,th,td),
.uh-dashboard[data-uh-theme="light"] .uh-muted,
.uh-dashboard[data-uh-theme="light"] .uh-empty,
.uh-dashboard[data-uh-theme="light"] .uh-dashboard-nav a,
.uh-dashboard[data-uh-theme="light"] .uh-section-heading a,
.uh-dashboard[data-uh-theme="light"] a:not(.uh-button):not(.button),
.uh-dashboard[data-uh-theme="light"] input,
.uh-dashboard[data-uh-theme="light"] select,
.uh-dashboard[data-uh-theme="light"] textarea {
    color: #000;
}

.uh-dashboard[data-uh-theme="light"] input,
.uh-dashboard[data-uh-theme="light"] select,
.uh-dashboard[data-uh-theme="light"] textarea,
.uh-dashboard[data-uh-theme="light"] .uh-product-tool {
    background: #fff;
}

.uh-dashboard[data-uh-theme="light"] .uh-button,
.uh-dashboard[data-uh-theme="light"] .uh-button *,
.uh-dashboard[data-uh-theme="light"] button[type="submit"] {
    color: #fff;
}

.uh-dashboard[data-uh-theme="light"] .uh-notification-item.is-unread {
    background: #000;
    border-color: #1f2937;
    color: #fff;
    box-shadow: inset 3px 0 0 #6366f1;
}

.uh-dashboard[data-uh-theme="light"] .uh-notification-item.is-unread .uh-notification-content strong,
.uh-dashboard[data-uh-theme="light"] .uh-notification-item.is-unread .uh-notification-content p,
.uh-dashboard[data-uh-theme="light"] .uh-notification-item.is-unread .uh-notification-content small {
    color: #fff;
}

.uh-dashboard[data-uh-theme="light"] .uh-notification-item.is-unread .uh-notification-link {
    color: #c7d2fe;
}

.uh-dashboard[data-uh-theme="light"] .uh-notification-item.is-unread .uh-notification-read {
    color: #86efac;
}

.uh-dashboard,
.uh-dashboard .uh-card,
.uh-dashboard input,
.uh-dashboard select,
.uh-dashboard textarea,
.uh-dashboard button,
.uh-dashboard table,
.uh-dashboard th,
.uh-dashboard td {
    transition: background-color .22s ease, border-color .22s ease, color .22s ease, box-shadow .22s ease;
}

.uh-theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    border: 1px solid var(--uh-line);
    border-radius: 11px;
    padding: 10px 12px;
    background: var(--uh-bg);
    color: var(--uh-ink);
    font: inherit;
    cursor: pointer;
}

.uh-theme-toggle:hover {
    border-color: var(--uh-primary);
    color: var(--uh-primary);
}

.uh-theme-toggle:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--uh-accent) 42%, transparent);
    outline-offset: 2px;
}

.uh-dashboard[data-uh-theme="dark"] {
    --uh-ink: #fff;
    --uh-muted: #fff;
    --uh-line: #334155;
    --uh-bg: #000;
    --uh-surface: #000;
    background: #000;
    color: #fff;
    color-scheme: dark;
}

.uh-dashboard[data-uh-theme="dark"] .uh-card,
.uh-dashboard[data-uh-theme="dark"] .woocommerce-MyAccount-content,
.uh-dashboard[data-uh-theme="dark"] .woocommerce table.shop_table,
.uh-dashboard[data-uh-theme="dark"] .woocommerce form {
    background: #000;
    border-color: var(--uh-line);
    color: #fff;
    box-shadow: 0 12px 35px rgba(0, 0, 0, .28);
}

.uh-dashboard[data-uh-theme="dark"] :where(h1,h2,h3,h4,h5,h6,p,label,small,strong,li,th,td),
.uh-dashboard[data-uh-theme="dark"] .uh-muted,
.uh-dashboard[data-uh-theme="dark"] .uh-empty,
.uh-dashboard[data-uh-theme="dark"] .uh-dashboard-nav a,
.uh-dashboard[data-uh-theme="dark"] .uh-section-heading a,
.uh-dashboard[data-uh-theme="dark"] a:not(.uh-button):not(.button),
.uh-dashboard[data-uh-theme="dark"] input,
.uh-dashboard[data-uh-theme="dark"] select,
.uh-dashboard[data-uh-theme="dark"] textarea {
    color: #fff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-dashboard-nav a,
.uh-dashboard[data-uh-theme="dark"] .uh-onboarding-list a,
.uh-dashboard[data-uh-theme="dark"] .uh-section-heading a,
.uh-dashboard[data-uh-theme="dark"] a:not(.uh-button):not(.button) {
    color: #cbd5e1;
}

.uh-dashboard[data-uh-theme="dark"] .uh-dashboard-nav a.active,
.uh-dashboard[data-uh-theme="dark"] .uh-dashboard-nav a:hover {
    background: #312e81;
    color: #eef2ff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-dashboard-nav a em {
    background: #3730a3;
    color: #eef2ff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-welcome,
.uh-dashboard[data-uh-theme="dark"] .uh-referral-card,
.uh-dashboard[data-uh-theme="dark"] .uh-onboarding-card,
.uh-dashboard[data-uh-theme="dark"] .uh-notifications-card,
.uh-dashboard[data-uh-theme="dark"] .uh-browser-push,
.uh-dashboard[data-uh-theme="dark"] .uh-points-redeem-card,
.uh-dashboard[data-uh-theme="dark"] .uh-benefits-card,
.uh-dashboard[data-uh-theme="dark"] .uh-cashback-banner {
    background: #000;
}

.uh-dashboard[data-uh-theme="dark"] .uh-browser-push {
    background: #000;
    border-color: #334155;
}

.uh-dashboard[data-uh-theme="dark"] .uh-announcement {
    background: #082f49;
    color: #bae6fd;
}

.uh-dashboard[data-uh-theme="dark"] .uh-onboarding-list a,
.uh-dashboard[data-uh-theme="dark"] input,
.uh-dashboard[data-uh-theme="dark"] select,
.uh-dashboard[data-uh-theme="dark"] textarea,
.uh-dashboard[data-uh-theme="dark"] .uh-profile-form input,
.uh-dashboard[data-uh-theme="dark"] .uh-wallet-withdraw-form input,
.uh-dashboard[data-uh-theme="dark"] .uh-wallet-withdraw-form select {
    background: #0f172a;
    border-color: #475569;
    color: var(--uh-ink);
}

.uh-dashboard[data-uh-theme="dark"] input::placeholder,
.uh-dashboard[data-uh-theme="dark"] textarea::placeholder {
    color: #64748b;
}

.uh-dashboard[data-uh-theme="dark"] input[readonly],
.uh-dashboard[data-uh-theme="dark"] .uh-profile-form input[readonly] {
    background: #1e293b;
    color: var(--uh-muted);
}

.uh-dashboard[data-uh-theme="dark"] .uh-theme-toggle {
    background: #1e293b;
    border-color: #475569;
    color: #f8fafc;
}

.uh-dashboard[data-uh-theme="dark"] .uh-progress,
.uh-dashboard[data-uh-theme="dark"] .uh-status,
.uh-dashboard[data-uh-theme="dark"] .woocommerce table.shop_table th,
.uh-dashboard[data-uh-theme="dark"] .woocommerce table.shop_table td {
    background-color: #1e293b;
    border-color: #334155;
    color: var(--uh-ink);
}

.uh-dashboard[data-uh-theme="dark"] .uh-wallet-history > div,
.uh-dashboard[data-uh-theme="dark"] .uh-wallet-withdrawal-row,
.uh-dashboard[data-uh-theme="dark"] .uh-order-row,
.uh-dashboard[data-uh-theme="dark"] .uh-notification-item {
    border-color: #334155;
}

.uh-dashboard[data-uh-theme="dark"] .uh-notification-item,
.uh-dashboard[data-uh-theme="dark"] .uh-notification-item.is-unread {
    background: #000;
    border-color: #334155;
    color: #fff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-notification-item.is-unread {
    box-shadow: inset 3px 0 0 #6366f1;
}

.uh-dashboard[data-uh-theme="dark"] .uh-notification-content strong,
.uh-dashboard[data-uh-theme="dark"] .uh-notification-content p,
.uh-dashboard[data-uh-theme="dark"] .uh-notification-content small {
    color: #fff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-notification-link {
    color: #c7d2fe;
}

.uh-dashboard[data-uh-theme="dark"] .uh-notification-read {
    color: #86efac;
}

.uh-dashboard[data-uh-theme="dark"] .uh-native-form,
.uh-dashboard[data-uh-theme="dark"] .uh-address-card,
.uh-dashboard[data-uh-theme="dark"] .uh-native-product,
.uh-dashboard[data-uh-theme="dark"] .uh-product-tool {
    background: #000;
    border-color: #334155;
    color: #fff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-native-empty,
.uh-dashboard[data-uh-theme="dark"] .uh-compare-table th,
.uh-dashboard[data-uh-theme="dark"] .uh-compare-table td {
    border-color: #334155;
}

.uh-dashboard[data-uh-theme="dark"] .uh-button,
.uh-dashboard[data-uh-theme="dark"] .uh-button *,
.uh-dashboard[data-uh-theme="dark"] button[type="submit"] {
    color: #fff;
}

.uh-dashboard[data-uh-theme="dark"] .uh-referral-card code {
    background: #082f49;
    border-color: #0ea5e9;
    color: #bae6fd;
}

.uh-dashboard[data-uh-theme="dark"] .uh-logout-link {
    color: #fca5a5;
}

@media (prefers-reduced-motion: reduce) {
    .uh-dashboard,
    .uh-dashboard * {
        transition: none !important;
    }
}
