.dh-hidden-settings-button {
    position: absolute !important;
    width: 0 !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    opacity: 0 !important;
    overflow: hidden !important;
    pointer-events: none !important;
}

.dh-model-selector {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.dh-model-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-width: 220px;
    max-width: min(320px, calc(100vw - 120px));
    height: 36px;
    padding: 0 14px;
    border: 1px solid hsl(var(--border));
    border-radius: 999px;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.dh-model-trigger:hover {
    background: hsl(var(--accent));
    border-color: hsl(var(--ring));
}

.dh-model-trigger:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px hsl(var(--ring) / 0.35);
}

.dh-model-trigger[data-open="true"] {
    background: hsl(var(--accent));
    border-color: hsl(var(--ring));
}

.dh-model-trigger-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dh-model-trigger-chevron {
    width: 8px;
    height: 8px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-1px);
    transition: transform 0.15s ease;
}

.dh-model-trigger[data-open="true"] .dh-model-trigger-chevron {
    transform: rotate(-135deg) translateY(-1px);
}

.dh-model-menu {
    position: absolute;
    left: 0;
    bottom: calc(100% + 12px);
    z-index: 40;
    width: min(340px, calc(100vw - 48px));
    padding: 8px;
    border: 1px solid hsl(var(--border));
    border-radius: 18px;
    background: hsl(var(--popover));
    box-shadow: 0 18px 45px hsl(0 0% 0% / 0.35);
}

.dh-model-menu[hidden] {
    display: none;
}

.dh-model-option {
    display: flex;
    width: 100%;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    border: 0;
    border-radius: 14px;
    background: transparent;
    color: hsl(var(--popover-foreground));
    text-align: left;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}

.dh-model-option:hover,
.dh-model-option:focus-visible {
    outline: none;
    background: hsl(var(--accent));
}

.dh-model-option[data-selected="true"] {
    background: hsl(var(--accent));
}

.dh-model-option-marker {
    width: 10px;
    height: 10px;
    margin-top: 7px;
    border-radius: 999px;
    border: 2px solid hsl(var(--muted-foreground));
    flex: 0 0 auto;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.dh-model-option[data-selected="true"] .dh-model-option-marker {
    border-color: hsl(var(--primary));
    background: hsl(var(--primary));
}

.dh-model-option-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.dh-model-option-label {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
}

.dh-model-option-description {
    color: hsl(var(--muted-foreground));
    font-size: 12px;
    line-height: 1.3;
}

body.dh-model-syncing [role="dialog"],
body.dh-model-syncing [role="listbox"] {
    opacity: 0 !important;
    pointer-events: none !important;
}

@media (max-width: 720px) {
    .dh-model-trigger {
        min-width: 0;
        width: min(100%, 260px);
    }

    .dh-model-menu {
        right: 0;
        left: auto;
    }
}

/* ═══════════════════════════════════════════════════
   Login page — "Ice Arena" premium theme
   ═══════════════════════════════════════════════════ */

@keyframes dh-login-shimmer {
    0%   { background-position: -200% center; }
    100% { background-position: 200% center; }
}

@keyframes dh-login-pulse {
    0%, 100% { box-shadow: 0 0 18px 0 rgba(56, 152, 236, 0.25); }
    50%      { box-shadow: 0 0 32px 4px rgba(56, 152, 236, 0.40); }
}

@keyframes dh-login-fadein {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

body.dh-login-enhanced {
    --dh-ice-1: #0b1628;
    --dh-ice-2: #0f2444;
    --dh-ice-3: #132e56;
    --dh-accent: #3898ec;
    --dh-accent-bright: #5cb8ff;
    --dh-glass-bg: rgba(15, 30, 58, 0.65);
    --dh-glass-border: rgba(86, 160, 235, 0.18);
    --dh-text-primary: #e8f0fa;
    --dh-text-secondary: #8dabc8;
}

/* Full-bleed gradient background */
body.dh-login-enhanced,
body.dh-login-enhanced [class*="MuiGrid-root"] {
    background: linear-gradient(160deg,
        var(--dh-ice-1) 0%,
        var(--dh-ice-2) 40%,
        var(--dh-ice-3) 70%,
        #0d1f3e 100%) !important;
    min-height: 100vh;
}

/* Frosted glass card */
body.dh-login-enhanced [class*="MuiPaper-root"] {
    background: var(--dh-glass-bg) !important;
    backdrop-filter: blur(24px) saturate(1.4) !important;
    -webkit-backdrop-filter: blur(24px) saturate(1.4) !important;
    border: 1px solid var(--dh-glass-border) !important;
    border-radius: 24px !important;
    box-shadow:
        0 24px 64px rgba(0, 0, 0, 0.45),
        inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
    color: var(--dh-text-primary) !important;
    animation: dh-login-fadein 0.5s ease-out both;
    animation-delay: 0.15s;
    max-width: 440px !important;
    padding: 40px 36px !important;
}

/* ── Logo ─────────────────────────────── */
body.dh-login-enhanced img[src*="deep_hockey_logo"] {
    width: min(320px, 72%) !important;
    max-height: 160px !important;
    object-fit: contain !important;
    object-position: center center !important;
    filter: drop-shadow(0 4px 20px rgba(56, 152, 236, 0.25)) !important;
    margin-bottom: 8px !important;
}

/* ── Brand pill ───────────────────────── */
body.dh-login-enhanced .dh-login-brand-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 14px;
    margin-bottom: 18px;
    border-radius: 999px;
    border: 1px solid rgba(56, 152, 236, 0.25);
    background: rgba(56, 152, 236, 0.08);
    color: var(--dh-accent-bright);
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

body.dh-login-enhanced .dh-login-brand-dot {
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: var(--dh-accent);
    box-shadow: 0 0 0 4px rgba(56, 152, 236, 0.15);
}

/* ── Headings & copy ──────────────────── */
body.dh-login-enhanced h1,
body.dh-login-enhanced h2,
body.dh-login-enhanced h3 {
    color: var(--dh-text-primary) !important;
    font-weight: 700 !important;
}

body.dh-login-enhanced .dh-login-subcopy {
    margin-top: 6px;
    margin-bottom: 20px;
    color: var(--dh-text-secondary);
    font-size: 14px;
    line-height: 1.55;
    max-width: 36ch;
}

/* ── Feature highlights row ───────────── */
body.dh-login-enhanced .dh-features-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 24px;
    animation: dh-login-fadein 0.5s ease-out both;
    animation-delay: 0.35s;
}

body.dh-login-enhanced .dh-feature-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid rgba(86, 160, 235, 0.12);
    background: rgba(56, 152, 236, 0.06);
    color: var(--dh-text-secondary);
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    transition: border-color 0.2s, background 0.2s;
}

body.dh-login-enhanced .dh-feature-chip:hover {
    border-color: rgba(86, 160, 235, 0.28);
    background: rgba(56, 152, 236, 0.12);
}

body.dh-login-enhanced .dh-feature-icon {
    font-size: 14px;
    line-height: 1;
}

/* ── OAuth / sign-in buttons ──────────── */
body.dh-login-enhanced button,
body.dh-login-enhanced [role="button"] {
    border-radius: 14px !important;
    font-weight: 600 !important;
    transition: all 0.2s ease !important;
}

body.dh-login-enhanced button[class*="MuiButton"],
body.dh-login-enhanced a[class*="MuiButton"] {
    background: linear-gradient(135deg, #2b7de9 0%, #1a5bb8 100%) !important;
    color: #fff !important;
    border: 1px solid rgba(56, 152, 236, 0.3) !important;
    padding: 11px 24px !important;
    font-size: 14px !important;
    letter-spacing: 0.01em !important;
    animation: dh-login-pulse 3s ease-in-out infinite;
}

body.dh-login-enhanced button[class*="MuiButton"]:hover,
body.dh-login-enhanced a[class*="MuiButton"]:hover {
    background: linear-gradient(135deg, #3898ec 0%, #2271d4 100%) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 8px 28px rgba(56, 152, 236, 0.4) !important;
}

body.dh-login-enhanced button[class*="MuiButton"]:active,
body.dh-login-enhanced a[class*="MuiButton"]:active {
    transform: translateY(0) !important;
}

/* ── Divider / "OR" text ──────────────── */
body.dh-login-enhanced hr,
body.dh-login-enhanced [class*="MuiDivider"] {
    border-color: rgba(86, 160, 235, 0.12) !important;
}

/* ── Form inputs (if password login) ──── */
body.dh-login-enhanced input[class*="MuiInput"],
body.dh-login-enhanced input[class*="MuiOutlinedInput"],
body.dh-login-enhanced [class*="MuiOutlinedInput-root"] {
    background: rgba(15, 30, 58, 0.5) !important;
    border-color: var(--dh-glass-border) !important;
    color: var(--dh-text-primary) !important;
    border-radius: 12px !important;
}

body.dh-login-enhanced label,
body.dh-login-enhanced [class*="MuiFormLabel"] {
    color: var(--dh-text-secondary) !important;
}

/* ── Trust footer ─────────────────────── */
body.dh-login-enhanced .dh-trust-footer {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(86, 160, 235, 0.10);
    text-align: center;
    color: rgba(141, 171, 200, 0.55);
    font-size: 11px;
    line-height: 1.5;
    animation: dh-login-fadein 0.5s ease-out both;
    animation-delay: 0.5s;
}

body.dh-login-enhanced .dh-trust-footer span {
    margin: 0 6px;
}

/* ── Scrollbar in login ───────────────── */
body.dh-login-enhanced ::-webkit-scrollbar {
    width: 6px;
}
body.dh-login-enhanced ::-webkit-scrollbar-track {
    background: transparent;
}
body.dh-login-enhanced ::-webkit-scrollbar-thumb {
    background: rgba(56, 152, 236, 0.2);
    border-radius: 3px;
}

/* ── Responsive ───────────────────────── */
@media (max-width: 600px) {
    body.dh-login-enhanced [class*="MuiPaper-root"] {
        padding: 28px 20px !important;
        border-radius: 18px !important;
        margin: 12px !important;
    }

    body.dh-login-enhanced .dh-login-subcopy {
        max-width: 100%;
        font-size: 13px;
    }

    body.dh-login-enhanced .dh-features-row {
        gap: 8px;
    }

    body.dh-login-enhanced .dh-feature-chip {
        font-size: 11px;
        padding: 5px 10px;
    }

    body.dh-login-enhanced img[src*="deep_hockey_logo"] {
        width: min(260px, 70%) !important;
    }
}
