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

        :root {
            --bg: #0f0f10;
            --bg2: #161618;
            --bg3: #1e1e21;
            --bg4: #27272b;
            --border: rgba(255, 255, 255, 0.07);
            --border2: rgba(255, 255, 255, 0.13);
            --text: #f0efe8;
            --text2: #9e9d96;
            --text3: #5c5b57;
            --accent: #c9a96e;
            --accent2: #e8c98a;
            --accent-bg: rgba(201, 169, 110, 0.1);
            --green: #5db87c;
            --red: #e07070;
            --blue: #6fa8d8;
            --font-display: 'DM Serif Display', Georgia, serif;
            --font-body: 'DM Sans', system-ui, sans-serif;
            --font-mono: 'JetBrains Mono', monospace;
        }

        html,
        body {
            height: 100%;
            font-family: var(--font-body);
            background: var(--bg);
            color: var(--text);
            font-size: 15px;
            line-height: 1.6;
            overflow: hidden;
        }

        /* ── Background grid + glow ── */
        .bg-layer {
            position: fixed;
            inset: 0;
            z-index: 0;
            overflow: hidden;
        }

        /* fine dot grid */
        .bg-layer::before {
            content: '';
            position: absolute;
            inset: 0;
            background-image:
                radial-gradient(circle, rgba(255, 255, 255, 0.055) 1px, transparent 1px);
            background-size: 28px 28px;
            mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 30%, transparent 100%);
        }

        /* ambient gold glow top-right */
        .bg-layer::after {
            content: '';
            position: absolute;
            width: 600px;
            height: 600px;
            top: -180px;
            right: -140px;
            background: radial-gradient(circle, rgba(201, 169, 110, 0.10) 0%, transparent 65%);
            pointer-events: none;
        }

        .bg-glow-blue {
            position: absolute;
            width: 500px;
            height: 500px;
            bottom: -160px;
            left: -100px;
            background: radial-gradient(circle, rgba(111, 168, 216, 0.07) 0%, transparent 65%);
            pointer-events: none;
        }

        /* ── Layout ── */
        .page {
            position: relative;
            z-index: 1;
            min-height: 100vh;
            display: grid;
            grid-template-columns: 1fr 1fr;
        }

        /* ── Left panel — brand ── */
        .brand-panel {
            display: flex;
            flex-direction: column;
            justify-content: space-between;
            padding: 44px 52px;
            border-right: 1px solid var(--border);
            position: relative;
            overflow: hidden;
        }

        .brand-panel::before {
            content: '';
            position: absolute;
            inset: 0;
            background:
                repeating-linear-gradient(-45deg,
                    transparent,
                    transparent 38px,
                    rgba(255, 255, 255, 0.018) 38px,
                    rgba(255, 255, 255, 0.018) 39px);
            pointer-events: none;
        }

        .brand-top {
            position: relative;
        }

        .logo {
            display: flex;
            align-items: center;
            gap: 11px;
            margin-bottom: 64px;
        }

        .logo-mark {
            width: 36px;
            height: 36px;
            background: linear-gradient(135deg, var(--accent), #8b6d3e);
            border-radius: 9px;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
        }

        .logo-mark svg {
            width: 18px;
            height: 18px;
            color: #1a1200;
        }

        .logo-text {
            font-family: var(--font-display);
            font-size: 20px;
            font-style: italic;
            color: var(--text);
            letter-spacing: 0.01em;
        }

        .logo-text span {
            color: var(--accent);
        }

        .brand-headline {
            font-family: var(--font-display);
            font-size: clamp(32px, 4vw, 46px);
            font-style: italic;
            line-height: 1.18;
            color: var(--text);
            margin-bottom: 20px;
        }

        .brand-headline em {
            color: var(--accent);
            font-style: italic;
        }

        .brand-body {
            font-size: 14px;
            color: var(--text2);
            line-height: 1.75;
            max-width: 360px;
            margin-bottom: 44px;
        }

        /* Feature pills */
        .feature-list {
            display: flex;
            flex-direction: column;
            gap: 12px;
        }

        .feature-item {
            display: flex;
            align-items: center;
            gap: 12px;
        }

        .feature-icon {
            width: 32px;
            height: 32px;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
            border: 1px solid var(--border2);
            background: var(--bg3);
        }

        .feature-icon svg {
            width: 15px;
            height: 15px;
        }

        .feature-text {
            font-size: 13px;
            color: var(--text2);
        }

        .feature-text strong {
            color: var(--text);
            font-weight: 500;
        }

        /* Testimonial */
        .brand-bottom {
            position: relative;
        }

        .testimonial {
            padding: 20px 22px;
            background: var(--bg2);
            border: 1px solid var(--border2);
            border-radius: 12px;
            position: relative;
            overflow: hidden;
        }

        .testimonial::before {
            content: '\201C';
            position: absolute;
            top: -10px;
            left: 14px;
            font-family: var(--font-display);
            font-size: 72px;
            color: var(--accent);
            opacity: 0.18;
            line-height: 1;
            pointer-events: none;
        }

        .testimonial-text {
            font-size: 13.5px;
            color: var(--text2);
            font-style: italic;
            line-height: 1.7;
            margin-bottom: 14px;
        }

        .testimonial-author {
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .testimonial-avatar {
            width: 30px;
            height: 30px;
            border-radius: 50%;
            background: linear-gradient(135deg, #2a3a55, #1d2535);
            border: 1px solid rgba(100, 140, 220, 0.25);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 11px;
            font-weight: 600;
            color: #8aaad6;
            flex-shrink: 0;
        }

        .testimonial-name {
            font-size: 12.5px;
            font-weight: 600;
            color: var(--text);
        }

        .testimonial-role {
            font-size: 11.5px;
            color: var(--text3);
        }

        /* ── Right panel — form ── */
        .form-panel {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            padding: 44px 52px;
            position: relative;
        }

        .form-card {
            width: 100%;
            max-width: 400px;
            animation: fadeUp 0.35s ease-out;
        }

        @keyframes fadeUp {
            from {
                opacity: 0;
                transform: translateY(14px);
            }

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

        .form-eyebrow {
            font-size: 11px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.12em;
            color: var(--accent);
            margin-bottom: 8px;
        }

        .form-heading {
            font-family: var(--font-display);
            font-size: 28px;
            font-style: italic;
            color: var(--text);
            margin-bottom: 6px;
        }

        .form-subheading {
            font-size: 13.5px;
            color: var(--text2);
            margin-bottom: 34px;
        }

        .form-subheading a {
            color: var(--accent);
            text-decoration: none;
        }

        .form-subheading a:hover {
            text-decoration: underline;
        }

        /* ── Form fields ── */
        .field {
            display: flex;
            flex-direction: column;
            gap: 6px;
            margin-bottom: 16px;
        }

        .field-label {
            font-size: 11.5px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.07em;
            color: var(--text3);
            display: flex;
            align-items: center;
            justify-content: space-between;
        }

        .field-label a {
            color: var(--accent);
            text-decoration: none;
            font-weight: 400;
            text-transform: none;
            letter-spacing: 0;
            font-size: 12px;
        }

        .field-label a:hover {
            text-decoration: underline;
        }

        .input-wrap {
            position: relative;
        }

        .field-input {
            width: 100%;
            background: var(--bg3);
            border: 1px solid var(--border2);
            border-radius: 10px;
            padding: 11px 14px 11px 42px;
            color: var(--text);
            font-family: var(--font-body);
            font-size: 14px;
            outline: none;
            transition: border-color 0.16s, box-shadow 0.16s;
        }

        .field-input::placeholder {
            color: var(--text3);
        }

        .field-input:focus {
            border-color: rgba(201, 169, 110, 0.45);
            box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.08);
        }

        .field-input.error {
            border-color: rgba(224, 112, 112, 0.55);
            box-shadow: 0 0 0 3px rgba(224, 112, 112, 0.07);
        }

        .input-icon {
            position: absolute;
            left: 13px;
            top: 50%;
            transform: translateY(-50%);
            color: var(--text3);
            pointer-events: none;
            display: flex;
            transition: color 0.16s;
        }

        .input-wrap:focus-within .input-icon {
            color: var(--accent);
        }

        .input-icon svg {
            width: 15px;
            height: 15px;
        }

        .pw-reveal {
            position: absolute;
            right: 11px;
            top: 50%;
            transform: translateY(-50%);
            background: none;
            border: none;
            color: var(--text3);
            cursor: pointer;
            display: flex;
            padding: 3px;
            border-radius: 5px;
            transition: color 0.12s, background 0.12s;
        }

        .pw-reveal:hover {
            color: var(--text2);
            background: var(--bg4);
        }

        .pw-reveal svg {
            width: 14px;
            height: 14px;
        }

        .field-input.has-reveal {
            padding-right: 40px;
        }

        /* Error message */
        .field-error {
            font-size: 12px;
            color: var(--red);
            display: flex;
            align-items: center;
            gap: 5px;
            min-height: 0;
            max-height: 0;
            overflow: hidden;
            opacity: 0;
            transition: max-height 0.2s ease, opacity 0.2s ease;
        }

        .field-error.visible {
            max-height: 30px;
            opacity: 1;
        }

        .field-error svg {
            width: 12px;
            height: 12px;
            flex-shrink: 0;
        }

        /* Remember me */
        .remember-row {
            display: flex;
            align-items: center;
            gap: 9px;
            margin-bottom: 24px;
            cursor: pointer;
            user-select: none;
        }

        .custom-check {
            width: 17px;
            height: 17px;
            background: var(--bg3);
            border: 1px solid var(--border2);
            border-radius: 4px;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
            transition: background 0.15s, border-color 0.15s;
        }

        .custom-check svg {
            width: 10px;
            height: 10px;
            color: #1a1200;
            opacity: 0;
            transition: opacity 0.15s;
        }

        #remember-cb:checked~.remember-row .custom-check,
        .remember-row.checked .custom-check {
            background: var(--accent);
            border-color: var(--accent);
        }

        .remember-row.checked .custom-check svg {
            opacity: 1;
        }

        #remember-cb {
            display: none;
        }

        .remember-label {
            font-size: 13px;
            color: var(--text2);
        }

        /* Submit button */
        .btn-signin {
            width: 100%;
            padding: 12px 20px;
            background: var(--accent);
            border: none;
            border-radius: 10px;
            color: #1a1200;
            font-family: var(--font-body);
            font-size: 14.5px;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 9px;
            transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
            letter-spacing: 0.01em;
            position: relative;
            overflow: hidden;
        }

        .btn-signin:hover {
            background: var(--accent2);
            box-shadow: 0 4px 20px rgba(201, 169, 110, 0.22);
        }

        .btn-signin:active {
            transform: scale(0.98);
        }

        .btn-signin:disabled {
            background: var(--bg4);
            color: var(--text3);
            cursor: not-allowed;
            box-shadow: none;
        }

        .btn-signin svg {
            width: 16px;
            height: 16px;
        }

        /* Shimmer on button */
        .btn-signin::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 60%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.14), transparent);
            transform: skewX(-20deg);
            transition: left 0s;
        }

        .btn-signin:hover::before {
            left: 160%;
            transition: left 0.5s ease;
        }

        /* Spinner */
        .spinner {
            width: 16px;
            height: 16px;
            border: 2px solid rgba(26, 18, 0, 0.3);
            border-top-color: #1a1200;
            border-radius: 50%;
            animation: spin 0.7s linear infinite;
            display: none;
        }

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

        /* Divider */
        .divider {
            display: flex;
            align-items: center;
            gap: 12px;
            margin: 22px 0;
        }

        .divider-line {
            flex: 1;
            height: 1px;
            background: var(--border2);
        }

        .divider-text {
            font-size: 12px;
            color: var(--text3);
            white-space: nowrap;
        }

        /* SSO buttons */
        .sso-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
        }

        .sso-btn {
            padding: 10px 14px;
            background: var(--bg3);
            border: 1px solid var(--border2);
            border-radius: 9px;
            color: var(--text2);
            font-family: var(--font-body);
            font-size: 13px;
            font-weight: 500;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            transition: background 0.12s, color 0.12s, border-color 0.12s;
        }

        .sso-btn:hover {
            background: var(--bg4);
            color: var(--text);
            border-color: var(--border2);
        }

        .sso-btn svg {
            width: 16px;
            height: 16px;
            flex-shrink: 0;
        }

        /* Footer */
        .form-footer {
            margin-top: 28px;
            text-align: center;
            font-size: 12px;
            color: var(--text3);
        }

        .form-footer a {
            color: var(--text3);
            text-decoration: underline;
            text-underline-offset: 2px;
        }

        .form-footer a:hover {
            color: var(--text2);
        }

        /* Version badge */
        .version-badge {
            position: absolute;
            bottom: 22px;
            right: 28px;
            font-family: var(--font-mono);
            font-size: 10.5px;
            color: var(--text3);
            display: flex;
            align-items: center;
            gap: 6px;
        }

        .version-dot {
            width: 5px;
            height: 5px;
            border-radius: 50%;
            background: var(--green);
            animation: pulse-v 2.4s infinite ease-in-out;
        }

        @keyframes pulse-v {

            0%,
            100% {
                opacity: 1
            }

            50% {
                opacity: 0.35
            }
        }

        /* Toast */
        .toast {
            position: fixed;
            bottom: 28px;
            left: 50%;
            transform: translateX(-50%) translateY(12px);
            background: var(--bg3);
            border: 1px solid rgba(93, 184, 124, 0.35);
            border-radius: 10px;
            padding: 11px 18px;
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 13.5px;
            color: var(--text);
            box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.25s, transform 0.25s;
            z-index: 999;
            white-space: nowrap;
        }

        .toast.show {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }

        .toast-icon {
            width: 18px;
            height: 18px;
            color: var(--green);
            flex-shrink: 0;
        }

        /* Responsive */
        @media (max-width: 820px) {
            .page {
                grid-template-columns: 1fr;
            }

            .brand-panel {
                display: none;
            }

            .form-panel {
                padding: 40px 28px;
            }
        }

        ::-webkit-scrollbar {
            width: 4px;
        }

        ::-webkit-scrollbar-thumb {
            background: var(--bg4);
            border-radius: 8px;
        }