        :root {
            --primary: #ff8200;
            --bg-dark: #0a0a0a;
            --btn-dark: #1a1a1a;
            --text-gold: #fde68a;
        }

        *,
        *::before,
        *::after {
            box-sizing: border-box;
        }

        body {
            font-family: 'Inter', sans-serif;
            background-color: #050505;
            color: #fff;
            min-height: 100vh;
            margin: 0;
            -webkit-font-smoothing: antialiased;
        }

        /* Ambient glow background */
        .auth-bg {
            position: fixed;
            inset: 0;
            z-index: 0;
            background:
                radial-gradient(ellipse 70% 55% at 15% 50%, rgba(255, 130, 0, 0.10) 0%, transparent 65%),
                radial-gradient(ellipse 50% 40% at 85% 20%, rgba(253, 230, 138, 0.05) 0%, transparent 60%),
                #050505;
        }

        /* Subtle noise overlay */
        .noise-overlay {
            position: fixed;
            inset: 0;
            pointer-events: none;
            z-index: 1;
            opacity: 0.025;
            background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
        }

        .auth-card {
            background: rgba(20, 20, 20, 0.85);
            border: 1px solid rgba(255, 130, 0, 0.12);
            backdrop-filter: blur(24px);
            -webkit-backdrop-filter: blur(24px);
            border-radius: 1.5rem;
            box-shadow: 0 0 60px rgba(255, 130, 0, 0.06), 0 25px 60px rgba(0, 0, 0, 0.6);
        }

        .nav-glass {
            background: rgba(10, 10, 10, 0.9);
            backdrop-filter: blur(20px);
            -webkit-backdrop-filter: blur(20px);
            /* Jelly-like elastic transition */
            transition: all 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
            will-change: background-color, backdrop-filter, padding, border-radius, border-color;
            border: 1px solid rgba(255, 255, 255, 0);
        }

        .pill-nav {
            margin: 0.5rem auto;
            padding-left: 1.5rem;
            padding-right: 1.5rem;
            border-radius: 9999px;
            max-width: 95%;
            background: rgba(10, 10, 10, 0.9);
            /* More visible "white line" border */
            border-color: rgba(255, 255, 255, 0.4);
            box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5), 0 0 1px 1px rgba(255, 255, 255, 0.1);
        }

        @media (min-width: 768px) {
            .pill-nav {
                max-width: 80%;
            }
        }

        .form-input {
            width: 100%;
            background: rgba(255, 255, 255, 0.04);
            border: 1px solid rgba(255, 255, 255, 0.08);
            border-radius: 0.625rem;
            color: #fff;
            padding: 0.75rem 1rem;
            font-size: 0.95rem;
            font-family: 'Inter', sans-serif;
            transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
            outline: none;
        }

        .form-input::placeholder {
            color: rgba(255, 255, 255, 0.25);
        }

        .form-input:focus {
            border-color: rgba(255, 130, 0, 0.5);
            box-shadow: 0 0 0 3px rgba(255, 130, 0, 0.08);
            background: rgba(255, 255, 255, 0.06);
        }

        .form-input option {
            background: #1a1a1a;
            color: #fff;
        }

        .form-label {
            display: block;
            font-size: 0.8rem;
            font-weight: 500;
            letter-spacing: 0.05em;
            color: rgba(255, 255, 255, 0.5);
            text-transform: uppercase;
            margin-bottom: 0.4rem;
        }

        .btn-primary {
            display: block;
            width: 100%;
            background: linear-gradient(135deg, #ff8200, #ffab61);
            color: #0a0a0a;
            font-weight: 700;
            font-size: 0.95rem;
            letter-spacing: 0.05em;
            padding: 0.85rem 1.5rem;
            border-radius: 0.625rem;
            border: none;
            cursor: pointer;
            transition: opacity 0.2s, transform 0.2s, box-shadow 0.2s;
            box-shadow: 0 8px 24px rgba(255, 130, 0, 0.22);
        }

        .btn-primary:hover {
            opacity: 1;
            transform: none;
            box-shadow: none;
        }

        .btn-primary:active {
            transform: translateY(0);
        }

        .btn-primary.is-loading {
            pointer-events: none;
            opacity: 0.92;
        }

        body.auth-loading-active {
            overflow: hidden;
        }

        .auth-submit-spinner {
            width: 1rem;
            height: 1rem;
            border: 2px solid rgba(10, 10, 10, 0.22);
            border-top-color: #0a0a0a;
            border-radius: 9999px;
            animation: authSpin 0.75s linear infinite;
        }

        .auth-submit-spinner.hidden {
            display: none;
        }

        .auth-loading-overlay {
            position: fixed;
            inset: 0;
            z-index: 80;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 1.5rem;
            background:
                radial-gradient(circle at top left, rgba(255, 130, 0, 0.14), transparent 36%),
                radial-gradient(circle at bottom right, rgba(253, 230, 138, 0.08), transparent 34%),
                rgba(4, 4, 4, 0.82);
            backdrop-filter: blur(18px);
            -webkit-backdrop-filter: blur(18px);
        }

        .auth-loading-overlay.hidden {
            display: none;
        }

        .auth-loading-backdrop-glow {
            position: absolute;
            width: 18rem;
            height: 18rem;
            border-radius: 9999px;
            filter: blur(80px);
            opacity: 0.5;
            pointer-events: none;
        }

        .auth-loading-backdrop-glow-left {
            left: -4rem;
            top: 8%;
            background: rgba(255, 130, 0, 0.22);
        }

        .auth-loading-backdrop-glow-right {
            right: -4rem;
            bottom: 8%;
            background: rgba(253, 230, 138, 0.16);
        }

        .auth-loading-panel {
            position: relative;
            width: min(100%, 26rem);
            padding: 2rem 1.5rem 1.75rem;
            text-align: center;
            border-radius: 1.75rem;
            border: 1px solid rgba(255, 255, 255, 0.08);
            background: linear-gradient(180deg, rgba(24, 24, 24, 0.94), rgba(14, 14, 14, 0.96));
            box-shadow: 0 20px 70px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 130, 0, 0.06);
        }

        .auth-loading-badge {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            margin-bottom: 1rem;
            padding: 0.45rem 0.8rem;
            border-radius: 9999px;
            background: rgba(255, 255, 255, 0.05);
            border: 1px solid rgba(255, 255, 255, 0.08);
            color: rgba(255, 255, 255, 0.72);
            font-size: 0.68rem;
            font-weight: 700;
            letter-spacing: 0.12em;
            text-transform: uppercase;
        }

        .auth-loading-spinner-shell {
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
            width: 5.5rem;
            height: 5.5rem;
            margin: 0 auto 1.25rem;
        }

        .auth-loading-spinner-ring {
            position: absolute;
            inset: 0;
            border-radius: 9999px;
            border: 3px solid rgba(255, 255, 255, 0.08);
            border-top-color: var(--primary);
            border-right-color: rgba(255, 171, 97, 0.78);
            animation: authSpin 0.95s linear infinite;
        }

        .auth-loading-spinner-core {
            width: 3.2rem;
            height: 3.2rem;
            border-radius: 9999px;
            background:
                radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.34), transparent 36%),
                linear-gradient(135deg, rgba(255, 130, 0, 0.4), rgba(255, 171, 97, 0.12));
            box-shadow: inset 0 0 20px rgba(255, 130, 0, 0.22), 0 0 28px rgba(255, 130, 0, 0.16);
        }

        .auth-loading-spinner-core-icon {
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .auth-loading-title {
            margin: 0;
            color: #ffffff;
            font-size: 1.55rem;
            font-weight: 700;
            letter-spacing: 0.02em;
        }

        .auth-loading-copy {
            margin: 0.75rem auto 0;
            max-width: 22rem;
            color: rgba(255, 255, 255, 0.62);
            font-size: 0.95rem;
            line-height: 1.65;
        }

        .auth-loading-email {
            margin: 1rem auto 0;
            max-width: 100%;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 0.6rem;
            padding: 0.7rem 0.95rem;
            border-radius: 1rem;
            background: rgba(255, 255, 255, 0.04);
            border: 1px solid rgba(255, 255, 255, 0.08);
            color: rgba(255, 255, 255, 0.82);
            font-size: 0.85rem;
            word-break: break-word;
        }

        .auth-loading-email.hidden {
            display: none;
        }

        .auth-loading-progress {
            margin: 1.2rem auto 0;
            width: min(100%, 20rem);
            display: grid;
            gap: 0.72rem;
            text-align: left;
        }

        .auth-loading-progress-item {
            display: flex;
            align-items: center;
            gap: 0.7rem;
            color: rgba(255, 255, 255, 0.38);
            font-size: 0.83rem;
            line-height: 1.35;
        }

        .auth-loading-progress-dot {
            width: 0.7rem;
            height: 0.7rem;
            border-radius: 9999px;
            border: 1px solid rgba(255, 255, 255, 0.18);
            background: rgba(255, 255, 255, 0.06);
            box-shadow: inset 0 0 0 2px rgba(10, 10, 10, 0.55);
            flex-shrink: 0;
        }

        .auth-loading-progress-complete,
        .auth-loading-progress-active {
            color: rgba(255, 255, 255, 0.84);
        }

        .auth-loading-progress-complete .auth-loading-progress-dot {
            background: linear-gradient(135deg, #ff8200, #ffab61);
            border-color: rgba(255, 171, 97, 0.65);
            box-shadow: 0 0 0 4px rgba(255, 130, 0, 0.08);
        }

        .auth-loading-progress-active .auth-loading-progress-dot {
            background: linear-gradient(135deg, rgba(255, 130, 0, 0.95), rgba(255, 171, 97, 0.95));
            border-color: rgba(255, 171, 97, 0.75);
            box-shadow: 0 0 0 5px rgba(255, 130, 0, 0.1);
            animation: authPulse 1.1s ease-in-out infinite alternate;
        }

        .auth-loading-progress-label {
            display: block;
        }

        .auth-loading-steps {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.55rem;
            margin-top: 1.25rem;
        }

        .auth-loading-step {
            width: 0.55rem;
            height: 0.55rem;
            border-radius: 9999px;
            background: rgba(255, 255, 255, 0.12);
        }

        .auth-loading-step-active {
            background: linear-gradient(135deg, #ff8200, #ffab61);
            box-shadow: 0 0 0 5px rgba(255, 130, 0, 0.08);
        }

        .auth-loading-footnote {
            margin: 1rem 0 0;
            color: rgba(255, 255, 255, 0.38);
            font-size: 0.72rem;
            letter-spacing: 0.08em;
            text-transform: uppercase;
        }

        .auth-loading-spinner {
            width: 2.5rem;
            height: 2.5rem;
            border: 3px solid rgba(255, 255, 255, 0.14);
            border-top-color: var(--primary);
            border-radius: 9999px;
            animation: authSpin 0.75s linear infinite;
            margin-bottom: 1rem;
        }

        .btn-no-shadow,
        .btn-no-shadow:hover,
        .btn-no-shadow:active {
            box-shadow: none !important;
        }

        .btn-theme-hover {
            transition: background 0.2s ease;
        }

        .btn-theme-hover:hover {
            background: linear-gradient(135deg, #ff9a2f, #ffc07a);
        }

        .btn-ghost {
            display: inline-block;
            background: transparent;
            border: 1px solid rgba(255, 130, 0, 0.35);
            color: var(--primary);
            font-weight: 500;
            font-size: 0.875rem;
            padding: 0.6rem 1.25rem;
            border-radius: 0.5rem;
            cursor: pointer;
            transition: background 0.2s, color 0.2s;
            text-decoration: none;
        }

        .btn-ghost:hover {
            background: rgba(255, 130, 0, 0.08);
        }

        .btn-ghost.is-loading {
            pointer-events: none;
            opacity: 0.88;
        }

        .auth-ghost-spinner {
            width: 0.95rem;
            height: 0.95rem;
            border: 2px solid rgba(255, 130, 0, 0.22);
            border-top-color: var(--primary);
            border-radius: 9999px;
            animation: authSpin 0.75s linear infinite;
        }

        .auth-ghost-spinner.hidden {
            display: none;
        }

        .password-field {
            position: relative;
        }

        .password-field .form-input {
            padding-right: 3rem;
        }

        .password-toggle {
            position: absolute;
            right: 0.75rem;
            top: 50%;
            transform: translateY(-50%);
            display: inline-flex;
            align-items: center;
            justify-content: center;
            color: rgba(255, 255, 255, 0.6);
            background: transparent;
            border: none;
            padding: 0;
            z-index: 2;
            cursor: pointer;
            transition: color 0.2s ease;
        }

        .password-toggle:hover {
            color: #ffffff;
        }

        .error-msg {
            color: #fca5a5;
            font-size: 0.8rem;
            margin-top: 0.3rem;
        }

        .success-msg {
            color: #86efac;
            font-size: 0.85rem;
        }

        .divider {
            height: 1px;
            background: rgba(255, 255, 255, 0.06);
            margin: 1.5rem 0;
        }

        .logo-text {
            font-family: 'Cinzel', serif;
            font-weight: 700;
            background: linear-gradient(90deg, #ffd27f, #ffab61);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            letter-spacing: 0.1em;
        }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(18px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @keyframes authSpin {
            to {
                transform: rotate(360deg);
            }
        }

        @keyframes authPulse {
            from {
                transform: scale(0.95);
            }

            to {
                transform: scale(1.08);
            }
        }

        .fade-in-up {
            animation: fadeInUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
        }

        @media (max-width: 640px) {
            .auth-loading-panel {
                padding: 1.75rem 1.15rem;
                border-radius: 1.4rem;
            }

            .auth-loading-title {
                font-size: 1.35rem;
            }

            .auth-loading-copy {
                font-size: 0.88rem;
            }

            .auth-loading-email {
                font-size: 0.78rem;
            }

            .auth-loading-progress {
                width: 100%;
            }

            .auth-loading-progress-item {
                font-size: 0.78rem;
            }
        }
    
