.auth-page {
  --auth-bg: #f3f6fa;
  --auth-fg: #101828;
  --auth-muted: #5a6b7d;
  --auth-hint: #6b7c8f;
  --auth-lead: #2f4054;
  --auth-card-bg: #ffffff;
  --auth-card-border: rgba(16, 56, 96, 0.14);
  --auth-card-fg: #101828;
  --auth-card-shadow: 0 16px 40px rgba(16, 56, 96, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.85);
  --auth-label: #2f4054;
  --auth-input-bg: #ffffff;
  --auth-input-border: #c5d0dc;
  --auth-input-fg: #101828;
  --auth-input-ph: #8a9bb0;
  --auth-h1: var(--navy-800);
  --auth-kicker: var(--navy-700);
  --auth-link: var(--navy-700);
  --auth-link-hover: var(--navy-800);
  --auth-alt: #5a6b7d;
  --auth-aside-fg: #101828;
  --auth-aside-muted: #2f4054;
  --auth-aside-sub: #5a6b7d;
  --auth-aside-strong: var(--navy-800);
  --auth-toggle-bg: #ffffff;
  --auth-toggle-border: #c5d0dc;
  --auth-toggle-fg: #2f4054;
  --auth-scene-grid: rgba(16, 56, 96, 0.14);
  --auth-scene-hex: 0.22;
  --auth-scene-opacity: 0.72;
  --auth-vignette: radial-gradient(ellipse at center, transparent 55%, rgba(243, 246, 250, 0.55) 100%);
  --auth-copy: rgba(47, 64, 84, 0.72);
  --auth-pill-bg: rgba(16, 56, 96, 0.06);
  --auth-pill-border: rgba(16, 56, 96, 0.18);
  --auth-pill-fg: var(--navy-800);
  --auth-step-bg: rgba(16, 56, 96, 0.08);
  --auth-step-border: rgba(16, 56, 96, 0.2);
  --auth-contact: var(--navy-700);
  --auth-signin-border: rgba(16, 56, 96, 0.22);
  --auth-signin-fg: var(--navy-800);
  --auth-brand-strong: var(--navy-800);
  --auth-brand-tag: var(--navy-700);
  --auth-ticket-no: var(--navy-800);
  --auth-file-btn-bg: var(--navy-800);
  --auth-file-btn-fg: #fff;
  --auth-accent: #9a7a18;
  --auth-accent-soft: rgba(154, 122, 24, 0.16);
  --auth-accent-border: #b8922a;
  --auth-icon: #9a7a18;
  --auth-checked-bg: rgba(154, 122, 24, 0.18);
  --auth-checked-fg: #103860;
  min-height: 100vh;
  margin: 0;
  color: var(--auth-fg);
  background: var(--auth-bg);
  overflow-x: hidden;
  font-family: var(--font);
}
.auth-page.theme-dark {
  --auth-bg: #050b14;
  --auth-fg: #e8eef5;
  --auth-muted: #8fa0b3;
  --auth-hint: #8fa0b3;
  --auth-lead: #9db0c4;
  --auth-card-bg: rgba(16, 24, 34, 0.78);
  --auth-card-border: rgba(200, 168, 80, 0.28);
  --auth-card-fg: #fff;
  --auth-card-shadow: 0 24px 60px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  --auth-label: #c5d0dc;
  --auth-input-bg: rgba(8, 14, 22, 0.72);
  --auth-input-border: #334155;
  --auth-input-fg: #fff;
  --auth-input-ph: #6d7f93;
  --auth-h1: var(--gold-400);
  --auth-kicker: var(--gold-400);
  --auth-link: #d4bc6a;
  --auth-link-hover: #e8d48a;
  --auth-alt: #9db0c4;
  --auth-aside-fg: #f4f7fb;
  --auth-aside-muted: #b7c6d6;
  --auth-aside-sub: #9db0c4;
  --auth-aside-strong: #fff;
  --auth-toggle-bg: rgba(8, 14, 22, 0.72);
  --auth-toggle-border: #334155;
  --auth-toggle-fg: #c5d0dc;
  --auth-scene-grid: rgba(80, 170, 255, 0.07);
  --auth-scene-hex: 0.16;
  --auth-scene-opacity: 0.55;
  --auth-vignette: radial-gradient(ellipse at center, transparent 40%, rgba(5, 11, 20, 0.78) 100%);
  --auth-copy: rgba(197, 208, 220, 0.72);
  --auth-pill-bg: rgba(16, 56, 96, 0.35);
  --auth-pill-border: rgba(200, 168, 80, 0.35);
  --auth-pill-fg: #e8d9a8;
  --auth-step-bg: rgba(16, 56, 96, 0.7);
  --auth-step-border: rgba(200, 168, 80, 0.4);
  --auth-contact: #e8d9a8;
  --auth-signin-border: rgba(255, 255, 255, 0.28);
  --auth-signin-fg: #d5e4f2;
  --auth-brand-strong: #fff;
  --auth-brand-tag: var(--gold-400);
  --auth-ticket-no: var(--gold-400);
  --auth-file-btn-bg: var(--navy-800);
  --auth-file-btn-fg: var(--gold-400);
  --auth-accent: var(--gold-400);
  --auth-accent-soft: rgba(232, 200, 92, 0.12);
  --auth-accent-border: var(--gold-500);
  --auth-icon: var(--gold-400);
  --auth-checked-bg: rgba(232, 200, 92, 0.12);
  --auth-checked-fg: #fff;
  color-scheme: dark;
}
.auth-page .text-muted,
.auth-page .form-label .text-muted {
  color: var(--auth-muted) !important;
}
.auth-page:not(.theme-dark) .auth-glow-a {
  opacity: 0.85;
  background: radial-gradient(circle, rgba(32, 120, 168, 0.32), transparent 68%);
}
.auth-page:not(.theme-dark) .auth-glow-b {
  opacity: 0.9;
  background: radial-gradient(circle, rgba(232, 200, 92, 0.38), transparent 68%);
}
.auth-page:not(.theme-dark) .auth-glow-c {
  opacity: 0.75;
  background: radial-gradient(circle, rgba(16, 56, 96, 0.18), transparent 70%);
}
.auth-page:not(.theme-dark) .auth-circuit {
  opacity: 0.42;
}
.auth-page:not(.theme-dark) .auth-trace {
  stroke: rgba(16, 56, 96, 0.4);
}
.auth-page:not(.theme-dark) .auth-trace-b {
  stroke: rgba(184, 148, 40, 0.55);
}
.auth-page:not(.theme-dark) .auth-trace-c {
  stroke: rgba(32, 120, 168, 0.35);
}
.auth-page:not(.theme-dark) .auth-node {
  fill: #c9a22e;
  opacity: 0.9;
}
.auth-page:not(.theme-dark) .auth-scan {
  background: linear-gradient(180deg, transparent, rgba(16, 56, 96, 0.08), transparent);
}
.auth-page:not(.theme-dark) .auth-hex {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='98' viewBox='0 0 56 98'%3E%3Cpath fill='none' stroke='%23103860' stroke-width='0.9' d='M28 2l26 15v30L28 62 2 47V17z'/%3E%3C/svg%3E");
}

.auth-page .app-dialog-card {
  color: var(--text);
}

.auth-scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  contain: paint;
}
.auth-grid {
  position: absolute;
  inset: -10%;
  background-image:
    linear-gradient(var(--auth-scene-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--auth-scene-grid) 1px, transparent 1px);
  background-size: 48px 48px;
  transform: perspective(700px) rotateX(58deg) scale(1.35);
  transform-origin: center 120%;
  animation: authGrid 28s linear infinite;
  opacity: var(--auth-scene-opacity);
}
.auth-hex {
  position: absolute;
  inset: 0;
  opacity: var(--auth-scene-hex);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='98' viewBox='0 0 56 98'%3E%3Cpath fill='none' stroke='%23c8a850' stroke-width='0.7' d='M28 2l26 15v30L28 62 2 47V17z'/%3E%3C/svg%3E");
  animation: authDrift 48s linear infinite;
}
.auth-glow {
  position: absolute;
  border-radius: 50%;
  will-change: transform;
}
.auth-glow-a {
  width: 42vw;
  height: 42vw;
  max-width: 480px;
  max-height: 480px;
  left: -8%;
  top: -12%;
  background: radial-gradient(circle, rgba(32, 120, 168, 0.45), transparent 68%);
  animation: authOrb 18s ease-in-out infinite;
}
.auth-glow-b {
  width: 36vw;
  height: 36vw;
  max-width: 420px;
  max-height: 420px;
  right: -6%;
  bottom: -8%;
  background: radial-gradient(circle, rgba(232, 200, 92, 0.38), transparent 68%);
  animation: authOrb 22s ease-in-out infinite reverse;
}
.auth-glow-c {
  width: 24vw;
  height: 24vw;
  max-width: 280px;
  max-height: 280px;
  left: 42%;
  top: 18%;
  background: radial-gradient(circle, rgba(90, 220, 255, 0.18), transparent 70%);
  animation: authOrb 16s ease-in-out infinite 1s;
}
.auth-circuit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.35;
}
.auth-trace {
  fill: none;
  stroke: rgba(90, 200, 255, 0.55);
  stroke-width: 1.2;
  stroke-linecap: round;
  stroke-dasharray: 12 18;
  animation: authTrace 18s linear infinite;
}
.auth-trace-b {
  stroke: rgba(200, 168, 80, 0.5);
  animation-duration: 24s;
  animation-direction: reverse;
}
.auth-trace-c {
  stroke: rgba(140, 220, 255, 0.4);
  animation-duration: 20s;
}
.auth-node {
  fill: var(--gold-500);
  opacity: 0.85;
  animation: authPulse 2.8s ease-in-out infinite;
}
.auth-node:nth-child(odd) { animation-delay: 0.6s; }
#authNet {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.auth-scan {
  position: absolute;
  left: 0;
  right: 0;
  height: 18%;
  background: linear-gradient(180deg, transparent, rgba(90, 200, 255, 0.06), transparent);
  animation: authScan 9s linear infinite;
}
.auth-vignette {
  position: absolute;
  inset: 0;
  background: var(--auth-vignette);
}

.auth-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: max(28px, env(safe-area-inset-top, 0px)) max(18px, env(safe-area-inset-right, 0px)) max(28px, env(safe-area-inset-bottom, 0px)) max(18px, env(safe-area-inset-left, 0px));
}
.auth-shell.has-hero {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 440px);
  align-items: center;
  gap: 48px;
  max-width: 1080px;
  margin: 0 auto;
}

.auth-hero {
  color: var(--auth-aside-fg);
  padding: 8px 8px 8px 12px;
}
.auth-kicker {
  margin: 0 0 12px;
  color: var(--auth-kicker);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.auth-hero h2 {
  margin: 0 0 12px;
  font-size: clamp(1.7rem, 3.2vw, 2.55rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.15;
  color: var(--auth-aside-strong);
  text-shadow: none;
}
.auth-page.theme-dark .auth-hero h2 {
  color: #fff;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}
.auth-hero > p {
  margin: 0 0 22px;
  max-width: 36rem;
  color: var(--auth-aside-muted);
  font-size: 1.02rem;
  line-height: 1.55;
}
.auth-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.auth-pills li {
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--auth-pill-border);
  background: var(--auth-pill-bg);
  color: var(--auth-pill-fg);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--auth-card-bg);
  border: 1px solid var(--auth-card-border);
  border-radius: 20px;
  padding: 32px 28px 28px;
  color: var(--auth-card-fg);
  box-shadow: var(--auth-card-shadow);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  animation: authCardIn 0.45s ease-out;
}
.auth-page:not(.theme-dark) .auth-card {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.auth-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 4px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
.auth-brand:hover .brand-mark {
  box-shadow: 0 0 0 1px rgba(200, 168, 80, 0.7), 0 0 32px rgba(200, 168, 80, 0.28);
}
.auth-brand:hover strong {
  color: var(--auth-accent);
}
.auth-brand .brand-mark {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: #fff;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  box-shadow: 0 0 0 1px rgba(200, 168, 80, 0.45), 0 0 28px rgba(200, 168, 80, 0.18);
}
.auth-brand .brand-mark img {
  width: 42px;
  height: 42px;
  object-fit: contain;
}
.auth-brand strong {
  display: block;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--auth-brand-strong);
}
.auth-brand span {
  display: block;
  margin-top: 4px;
  color: var(--auth-brand-tag);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.auth-card h1 {
  font-size: 1.4rem;
  margin: 18px 0 4px;
  color: var(--auth-h1);
  font-weight: 800;
}
.auth-lead {
  color: var(--auth-lead);
  font-size: 0.92rem;
  margin: 0 0 22px;
}
.auth-interest {
  margin: -6px 0 20px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--auth-pill-bg);
  border: 1px solid var(--auth-pill-border);
  color: var(--auth-pill-fg);
  line-height: 1.4;
}
.auth-interest__label {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 2px;
  opacity: 0.72;
}
.auth-interest strong {
  font-weight: 700;
}
.auth-customer-hint {
  margin: 0 0 18px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--auth-pill-bg);
  border: 1px solid var(--auth-pill-border);
  color: var(--auth-pill-fg);
  line-height: 1.4;
}
.auth-customer-hint__label {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 2px;
  opacity: 0.72;
}
.auth-customer-hint strong {
  display: block;
  font-weight: 700;
}
.auth-customer-hint__who {
  display: block;
  margin-top: 2px;
  font-size: 0.88rem;
  color: var(--auth-muted);
}
.auth-customer-hint__ok,
.auth-customer-hint__ask {
  margin: 8px 0 0;
  font-size: 0.82rem;
  color: var(--auth-muted);
}
.auth-customer-hint__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
  align-items: center;
}
.auth-customer-hint__actions .auth-customer-hint__ask {
  flex: 1 1 100%;
  margin: 0 0 2px;
}
.auth-customer-hint__use,
.auth-customer-hint__keep {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}
.auth-customer-hint__use {
  border: 1px solid var(--auth-accent-border);
  background: var(--auth-accent-soft);
  color: var(--auth-checked-fg);
}
.auth-customer-hint__keep {
  border: 1px solid var(--auth-input-border);
  background: transparent;
  color: var(--auth-pill-fg);
}
.auth-customer-hint__use:hover,
.auth-customer-hint__keep:hover {
  filter: brightness(0.97);
}
.auth-customer-hint__use.is-picked,
.auth-customer-hint__keep.is-picked {
  box-shadow: 0 0 0 2px var(--auth-accent-border);
}
.theme-dark .auth-customer-hint__use {
  color: #f4e7b0;
}
.theme-dark .auth-customer-hint__keep {
  color: #e8eef5;
}
.auth-field { margin-bottom: 14px; }
.auth-card .form-label {
  color: var(--auth-label);
  font-weight: 600;
  margin-bottom: 6px;
}
.auth-input { position: relative; }
.auth-input > i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--auth-icon);
  font-size: 1rem;
  pointer-events: none;
  z-index: 1;
}
.auth-card .form-control {
  background: var(--auth-input-bg);
  border-color: var(--auth-input-border);
  color: var(--auth-input-fg);
  border-radius: 11px;
  min-height: 46px;
  padding-left: 40px;
}
.auth-card .form-control::placeholder { color: var(--auth-input-ph); }
.auth-card .form-control:focus {
  border-color: var(--auth-accent-border);
  box-shadow: 0 0 0 3px var(--auth-accent-soft);
  background: var(--auth-input-bg);
  color: var(--auth-input-fg);
}
.auth-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 4px 0 18px;
  font-size: 0.9rem;
}
.auth-row .form-check-label {
  color: var(--auth-label);
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}
.auth-card a:not(.btn) {
  color: var(--auth-link);
  text-decoration: none;
  font-weight: 600;
}
.auth-card a:not(.btn):hover { color: var(--auth-link-hover); }
.auth-card .btn-gold,
.auth-card a.btn-gold {
  min-height: 46px;
  border-radius: 11px;
  box-shadow: none;
  color: #103860;
}
.auth-card .btn-gold:hover,
.auth-card .btn-gold:focus,
.auth-card a.btn-gold:hover,
.auth-card a.btn-gold:focus {
  color: #103860;
}
.auth-card .btn-navy,
.auth-card a.btn-navy {
  color: #fff;
}
.auth-card .btn-navy:hover,
.auth-card .btn-navy:focus,
.auth-card a.btn-navy:hover,
.auth-card a.btn-navy:focus {
  color: #fff;
}

.auth-shell.is-wide .auth-card { max-width: 560px; }
.auth-pair {
  display: flex;
  flex-wrap: nowrap;
  gap: 12px;
  align-items: start;
  width: 100%;
}
.auth-pair > .auth-field {
  flex: 1 1 0;
  min-width: 0;
  width: auto;
  max-width: none;
}
.auth-pair-single > .auth-field {
  flex: 0 0 calc(50% - 6px);
  max-width: calc(50% - 6px);
}
.auth-type-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 4px;
}
.auth-type-option {
  margin: 0;
  cursor: pointer;
}
.auth-type-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.auth-type-option span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 8px 12px;
  border-radius: 11px;
  border: 1px solid var(--auth-toggle-border);
  background: var(--auth-toggle-bg);
  color: var(--auth-toggle-fg);
  font-weight: 600;
  font-size: 0.92rem;
  transition: border-color .15s ease, background .15s ease, color .15s ease, box-shadow .15s ease;
}
.auth-type-option span i { color: var(--auth-icon); }
.auth-type-option:hover span {
  border-color: var(--auth-accent-border);
  color: var(--auth-input-fg);
}
.auth-type-option input:checked + span {
  border-color: var(--auth-accent-border);
  background: var(--auth-checked-bg);
  color: var(--auth-checked-fg);
  box-shadow: 0 0 0 3px var(--auth-accent-soft);
  font-weight: 700;
}
.auth-type-option input:focus-visible + span {
  outline: 2px solid var(--auth-accent-border);
  outline-offset: 2px;
}
.auth-hint {
  margin: 8px 0 0;
  color: var(--auth-hint);
  font-size: 0.82rem;
  line-height: 1.4;
}
.auth-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.auth-card .form-select {
  background-color: var(--auth-input-bg);
  border-color: var(--auth-input-border);
  color: var(--auth-input-fg);
  border-radius: 11px;
  min-height: 46px;
  padding-left: 40px;
  padding-right: 2.2rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23103860' viewBox='0 0 16 16'%3E%3Cpath d='M1.5 5.5l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 12px;
}
.auth-card .form-select:focus {
  border-color: var(--auth-accent-border);
  box-shadow: 0 0 0 3px var(--auth-accent-soft);
  background-color: var(--auth-input-bg);
  color: var(--auth-input-fg);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23103860' viewBox='0 0 16 16'%3E%3Cpath d='M1.5 5.5l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 12px;
}
.auth-page.theme-dark .auth-card .form-select,
.auth-page.theme-dark .auth-card .form-select:focus {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23c8a850' viewBox='0 0 16 16'%3E%3Cpath d='M1.5 5.5l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 12px;
}
.auth-card textarea.form-control {
  min-height: 120px;
  padding-top: 12px;
  padding-bottom: 12px;
  resize: vertical;
  line-height: 1.5;
  vertical-align: top;
  /* Keep typed text / placeholder on the first line, not vertically centered */
  display: block;
}
.auth-input-top {
  align-items: flex-start;
}
.auth-input-top > i {
  top: 14px;
  transform: none;
  line-height: 1;
}
.auth-input:has(> textarea) > i,
.auth-input-top:has(> textarea) > i {
  top: 14px;
  transform: none;
}
.auth-alt {
  margin: 16px 0 0;
  text-align: center;
  color: var(--auth-alt);
  font-size: 0.9rem;
}
.auth-ticket-no {
  color: var(--auth-ticket-no);
  font-weight: 800;
  letter-spacing: 0.02em;
}
.auth-hint {
  margin: 6px 0 0;
  color: var(--auth-hint);
  font-size: 12px;
  font-weight: 600;
}
.auth-file {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 46px;
  padding: 0 14px 0 40px;
  border: 1px solid var(--auth-input-border);
  border-radius: 11px;
  background: var(--auth-input-bg);
  color: var(--auth-label);
  cursor: pointer;
  overflow: hidden;
}
.auth-file:hover {
  border-color: var(--auth-accent-border);
}
.auth-file:focus-within {
  border-color: var(--auth-accent-border);
  box-shadow: 0 0 0 3px var(--auth-accent-soft);
}
.auth-file > i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--auth-icon);
  font-size: 1rem;
  pointer-events: none;
  z-index: 1;
  line-height: 1;
}
.auth-file-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 8px;
  background: var(--auth-file-btn-bg);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1;
  pointer-events: none;
}
.auth-page:not(.theme-dark) .auth-file-btn {
  background: var(--navy-800);
  color: #fff;
}
.auth-file-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.9rem;
  line-height: 1.2;
  pointer-events: none;
}
.auth-file-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  font-size: 0;
}

@keyframes authGrid {
  from { background-position: 0 0; }
  to { background-position: 0 48px; }
}
@keyframes authDrift {
  from { background-position: 0 0; }
  to { background-position: 56px 98px; }
}
@keyframes authOrb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(4%, 6%) scale(1.08); }
}
@keyframes authTrace {
  to { stroke-dashoffset: -240; }
}
@keyframes authPulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}
@keyframes authScan {
  0% { top: -20%; }
  100% { top: 110%; }
}
@keyframes authCardIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

@media (max-width: 991px) {
  .auth-shell.has-hero {
    grid-template-columns: 1fr;
    gap: 18px;
    max-width: 460px;
  }
  .auth-hero {
    text-align: center;
    padding: 4px 4px 0;
  }
  .auth-hero > p { margin-left: auto; margin-right: auto; }
  .auth-pills { justify-content: center; }
  .auth-hero h2 { font-size: 1.45rem; }
  .auth-grid { opacity: 0.32; }
}
@media (max-width: 575px) {
  .auth-hero { display: none; }
  .auth-card { padding: 26px 20px 22px; }
  .auth-pair,
  .auth-type-toggle { flex-wrap: wrap; }
  .auth-pair { display: flex; }
  .auth-pair > .auth-field,
  .auth-pair-single > .auth-field {
    flex: 1 1 100%;
    max-width: 100%;
  }
  .auth-type-toggle { grid-template-columns: 1fr; }
  .auth-glow-c,
  .auth-scan,
  .auth-hex { display: none; }
  .auth-grid {
    transform: none;
    opacity: 0.22;
    inset: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-grid,
  .auth-hex,
  .auth-glow,
  .auth-trace,
  .auth-node,
  .auth-scan {
    animation: none !important;
  }
  .auth-grid { transform: none; }
  #authNet { display: none; }
  .auth-card { animation: none; }
}

.auth-copy {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 12px;
  z-index: 2;
  margin: 0;
  text-align: center;
  color: var(--auth-copy);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  pointer-events: none;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .auth-page.theme-dark .auth-card { background: #151c26; }
  .auth-page:not(.theme-dark) .auth-card { background: #fff; }
}

.auth-page.is-support {
  overflow-x: clip;
  overflow-y: auto;
  min-height: 100dvh;
  height: auto;
  display: flex;
  flex-direction: column;
}
.support-top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px 8px;
  width: min(1120px, calc(100% - 28px));
  margin: 0 auto;
}
.support-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--auth-aside-strong);
}
.support-brand:hover strong {
  color: var(--auth-accent);
}
.support-brand .brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 0 0 1px rgba(200, 168, 80, 0.45);
}
.support-brand .brand-mark img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}
.support-brand strong {
  display: block;
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--auth-aside-strong);
}
.support-brand small {
  display: block;
  margin-top: 2px;
  color: var(--auth-kicker);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.support-signin {
  color: var(--auth-signin-fg);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  border: 1px solid var(--auth-signin-border);
  border-radius: 999px;
  padding: 7px 14px;
  white-space: nowrap;
}
.support-signin-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
}
.support-signin:hover { color: var(--auth-aside-strong); border-color: var(--auth-accent-border); }
.support-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(240px, 320px) minmax(0, 1fr);
  gap: 32px;
  align-items: start;
  width: min(1120px, calc(100% - 28px));
  margin: 12px auto 24px;
  flex: 1;
}
.support-aside {
  color: var(--auth-aside-fg);
  padding: 12px 4px 0;
}
.support-aside h2 {
  margin: 0 0 10px;
  font-size: clamp(1.55rem, 2.4vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.15;
  color: var(--auth-aside-strong);
}
.support-aside > p {
  margin: 0 0 22px;
  color: var(--auth-aside-muted);
  font-size: 0.98rem;
  line-height: 1.55;
}
.support-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.support-steps li {
  padding-left: 36px;
  position: relative;
}
.support-steps li::before {
  counter-increment: support-step;
  content: counter(support-step);
  position: absolute;
  left: 0;
  top: 1px;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  background: var(--auth-step-bg);
  border: 1px solid var(--auth-step-border);
  color: var(--auth-kicker);
  font-size: 12px;
  font-weight: 800;
  display: grid;
  place-items: center;
}
.support-steps { counter-reset: support-step; }
.support-steps strong {
  display: block;
  color: var(--auth-aside-strong);
  font-size: 0.95rem;
  margin-bottom: 2px;
}
.support-steps span {
  display: block;
  color: var(--auth-aside-sub);
  font-size: 0.86rem;
  line-height: 1.45;
}
.support-contact {
  margin-top: 22px;
  display: grid;
  gap: 8px;
}
.support-contact a {
  color: var(--auth-contact);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
}
.support-contact a:hover { color: var(--auth-aside-strong); }
.support-contact i { margin-right: 8px; color: var(--auth-icon); }
.support-panel.auth-card {
  max-width: none;
  padding: 26px 28px 24px;
  overflow: visible;
}
.support-panel h1 {
  margin-top: 0;
  font-size: 1.55rem;
}
.support-ticket-head { margin-bottom: 18px; }
.support-ticket-head h1 { margin-bottom: 8px; }
.support-ticket-head .badge { vertical-align: middle; }
.is-support .ticket-thread { margin-top: 4px; }
.is-support .ticket-msg.is-customer { align-self: flex-end; }
.is-support .ticket-msg.is-staff { align-self: flex-start; }
.is-support .ticket-msg-bubble {
  background: rgba(255,255,255,0.06);
  border-color: rgba(200, 168, 80, 0.22);
  color: #eef3f8;
}
.is-support .ticket-msg.is-staff .ticket-msg-bubble {
  background: rgba(16, 56, 96, 0.85);
  border-color: rgba(200, 168, 80, 0.35);
}
.is-support .ticket-msg.is-customer .ticket-msg-bubble {
  background: rgba(232, 200, 92, 0.12);
  border-color: rgba(232, 200, 92, 0.35);
}
.is-support .ticket-msg-meta span,
.is-support .ticket-msg-meta time { color: rgba(197, 208, 220, 0.82); }
.is-support .ticket-msg-meta strong,
.is-support .ticket-msg-body,
.is-support .ticket-msg-body p,
.is-support .ticket-msg .record-prose {
  color: #eef3f8;
}
.is-support .ticket-msg .text-muted {
  color: rgba(197, 208, 220, 0.8) !important;
}
.is-support .ticket-msg-body a { color: #f0d36a; }
.is-support .ticket-msg-file {
  background: rgba(255,255,255,0.08);
  border-color: rgba(200, 168, 80, 0.3);
  color: #fff;
}
.is-support .ticket-msg-file-icon {
  background: rgba(255,255,255,0.12);
  color: #f0d36a;
}
.is-support .ticket-msg-file-meta small { color: rgba(197, 208, 220, 0.75); }
.is-support .ticket-msg-file-actions .btn-view,
.is-support .ticket-msg-file-actions .btn-edit {
  background: #fff !important;
  color: #103860 !important;
  border-color: #fff !important;
}
.is-support .ticket-composer {
  border-top-color: rgba(200, 168, 80, 0.22);
}
.is-support .ticket-composer .form-label { color: #d5e0ea; }
.support-panel .auth-field { margin-bottom: 12px; }
.support-panel textarea.form-control { min-height: 96px; }
.support-submit {
  min-width: 200px;
  margin-top: 6px;
}
.support-copy {
  position: relative;
  z-index: 2;
  margin: 0;
  padding: 8px 16px 18px;
  text-align: center;
  color: var(--auth-copy);
  font-size: 12px;
  font-weight: 600;
}
.support-copy a {
  color: var(--auth-kicker);
  text-decoration: none;
}
.support-copy a:hover {
  text-decoration: underline;
}

.public-theme-toggle {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid var(--auth-signin-border);
  background: var(--auth-toggle-bg);
  color: var(--auth-kicker);
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.public-theme-toggle:hover,
.public-theme-toggle:focus-visible {
  border-color: var(--auth-accent-border);
  color: var(--auth-accent);
  outline: none;
}
.portal-page .public-theme-toggle {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}
.portal-page.theme-dark .public-theme-toggle {
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.06);
  color: var(--gold-400);
}
.auth-page:not(.theme-dark) .is-support .ticket-msg-bubble,
.auth-page:not(.theme-dark) .is-support .ticket-msg.is-staff .ticket-msg-bubble,
.auth-page:not(.theme-dark) .is-support .ticket-msg.is-customer .ticket-msg-bubble {
  background: var(--card);
  border-color: var(--border);
  color: var(--text);
}
.auth-page:not(.theme-dark) .is-support .ticket-msg-meta span,
.auth-page:not(.theme-dark) .is-support .ticket-msg-meta time,
.auth-page:not(.theme-dark) .is-support .ticket-msg-meta strong,
.auth-page:not(.theme-dark) .is-support .ticket-msg-body,
.auth-page:not(.theme-dark) .is-support .ticket-msg-body p {
  color: var(--text);
}
.auth-page:not(.theme-dark) .is-support .ticket-msg .text-muted {
  color: var(--muted) !important;
}
.auth-page:not(.theme-dark) .is-support .ticket-msg-file {
  background: #f7fafc;
  border-color: var(--border);
  color: var(--text);
}
.auth-page:not(.theme-dark) .is-support .ticket-composer .form-label {
  color: var(--text);
}
@media (max-width: 991px) {
  .support-shell {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .support-aside { padding-top: 4px; }
  .support-aside h2 { font-size: 1.45rem; }
  .support-submit { width: 100%; }
}
@media (max-width: 575px) {
  .support-top { padding: 14px 14px 4px; width: calc(100% - 16px); }
  .support-shell { width: calc(100% - 16px); margin-bottom: 16px; }
  .support-panel.auth-card { padding: 20px 16px 18px; }
}
