.theme-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border-radius: 0.5rem;
    border: 1px solid var(--border-soft, var(--portal-border, rgba(0, 0, 0, 0.15)));
    background: var(--bg-card, var(--portal-surface, #fff));
    color: var(--text-secondary, var(--portal-muted, #4b5563));
    cursor: pointer;
    line-height: 1;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.theme-toggle-btn:hover,
.theme-toggle-btn:focus-visible {
    color: var(--text-primary, var(--portal-text, #111827));
    border-color: var(--brand-primary, var(--portal-accent, #b57e1f));
    outline: none;
}

.theme-toggle-btn .theme-icon-sun,
.theme-toggle-btn .theme-icon-moon {
    font-size: 1rem;
    width: 1.125rem;
    height: 1.125rem;
    display: block;
    flex-shrink: 0;
}

.theme-toggle-btn .theme-icon-sun[hidden],
.theme-toggle-btn .theme-icon-moon[hidden] {
    display: none !important;
}

.theme-toggle-btn.btn {
    width: auto;
    min-width: 2.25rem;
    height: auto;
    min-height: 2rem;
    padding: 0.25rem 0.5rem;
}
