/*
 * Canonical Chrome v1 — reference system (scoped to .aa-chrome-page).
 * Standalone: does not depend on portal-shell or First Bay route CSS.
 */

/* ---- Root tokens ---- */

.aa-chrome-page {
  --aa-chrome-rail-max: 1120px;
  --aa-chrome-rail-pad: clamp(20px, 4vw, 56px);
  --aa-chrome-body-rail-max: var(--aa-chrome-rail-max);
  --aa-chrome-fixture-panel-max: min(100%, 760px);
  --aa-chrome-glass-bar-gap: 10px;
  --aa-chrome-top-bar-min-height: 72px;
  --aa-chrome-top-bar-pad-y: 12px;
  --aa-chrome-top-bar-pad-x: 20px;
  --aa-chrome-controls-bar-height: 42px;
  --aa-chrome-controls-track-height: 34px;
  --aa-chrome-slot-width: 44px;
  --aa-chrome-control-visual: 32px;
  --aa-chrome-control-hit: 44px;
  --aa-chrome-control-hit-pad: 6px;
  --aa-chrome-start-gap: 8px;
  --aa-chrome-theme-gap: clamp(8px, 1.2vw, 12px);
  --aa-chrome-menu-width: clamp(260px, 38vw, 360px);
  --aa-chrome-drawer-max-height: min(72vh, 640px);
  --aa-chrome-drawer-edge-margin: 12px;
  --aa-chrome-cobrand-gap: clamp(12px, 2vw, 20px);
  --aa-chrome-theme-cell: 48px;
  --aa-chrome-axis-x: 50%;
  --aa-chrome-home-text-left: 0px;
  --aa-chrome-drawer-text-left: 20px;
  --aa-chrome-cobrand-mark-h: clamp(32px, 4vw, 44px);
  --aa-chrome-control-font-size: calc(var(--aa-theme-btn-font-size, 8px) * 1.15);
  --aa-chrome-control-font-weight: 650;
  --aa-chrome-control-letter-spacing: 0.055em;
  --aa-chrome-control-text-transform: uppercase;
  --aa-chrome-control-line-height: 1.1;
  --aa-chrome-z-header: 30;
  --aa-chrome-z-backdrop: 28;
  --aa-chrome-z-drawer: 29;
  --aa-chrome-z-polaris: 31;
  --aa-chrome-z-flash: 25;
  --radius-rail: 12px;
  --aa-theme-btn-font-size: 8px;
  --aa-theme-btn-letter-spacing: 0.055em;
  --aa-theme-btn-line-height: 1.1;
  --header-lockup-height: 56px;
  /* Deterministic header height (10 + 72 + 10 + 42 + 16 = 150) used by the flow
     spacer as a STATIC token — no JS measurement, nothing that can oscillate. */
  --aa-chrome-header-height: 150px;
  /* Glass fills are intentionally opaque enough to read as frosted glass WITHOUT a
     live backdrop-filter. Live backdrop blur over scrolling content "swims" (re-samples
     each frame) and made the fixed top brand bar appear to jitter on single wheel ticks.
     Static fills paint once and never re-sample, so the chrome is physically stable. */
  --aa-chrome-dark-glass-bg: linear-gradient(
    168deg,
    rgba(38, 44, 52, 0.90) 0%,
    rgba(24, 28, 34, 0.94) 48%,
    rgba(18, 22, 28, 0.96) 100%
  );
  --aa-chrome-dark-glass-highlight: inset 0 1px 0 rgba(255, 255, 255, 0.07);
  --aa-chrome-dark-glass-shadow: 0 12px 40px rgba(0, 0, 0, 0.38);
  --aa-chrome-dark-glass-border: 1px solid rgba(255, 255, 255, 0.025);
  --aa-chrome-stellar-glass-bg: linear-gradient(
    160deg,
    rgba(22, 27, 52, 0.88) 0%,
    rgba(15, 18, 40, 0.92) 46%,
    rgba(11, 13, 33, 0.95) 100%
  );
  --aa-chrome-stellar-glass-highlight: inset 0 1px 0 rgba(180, 210, 255, 0.07);
  --aa-chrome-stellar-glass-shadow:
    0 0 30px rgba(96, 150, 255, 0.12),
    0 18px 52px rgba(8, 12, 32, 0.30);
  --aa-chrome-light-bg: #b4b6ba;
  --aa-chrome-light-surface: rgba(186, 188, 192, 0.78);
  --aa-chrome-light-surface-strong: rgba(176, 178, 182, 0.86);
  --aa-chrome-light-text: #181a1e;
  --aa-chrome-light-muted: #4e5258;
  --aa-chrome-light-glass-bg: linear-gradient(
    166deg,
    rgba(194, 196, 200, 0.93) 0%,
    rgba(182, 184, 188, 0.90) 52%,
    rgba(172, 174, 178, 0.93) 100%
  );
  --aa-chrome-light-glass-highlight: inset 0 1px 0 rgba(255, 255, 255, 0.28);
  --aa-chrome-light-glass-shadow: 0 14px 38px rgba(22, 24, 28, 0.18);
  --aa-chrome-light-glass-border: 1px solid rgba(255, 255, 255, 0.22);
  margin: 0;
  min-height: 100vh;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

html:has(body.aa-chrome-page) {
  overflow-y: scroll;
  scrollbar-gutter: stable;
  /* Prevent elastic/rubber-band overscroll from visually pulling sticky header */
  overscroll-behavior-y: none;
}

html[data-theme="dark"] .aa-chrome-page {
  color: rgba(230, 234, 240, 0.92);
  background: #1b1f24;
}

html[data-theme="light"] .aa-chrome-page {
  color: var(--aa-chrome-light-text);
  background:
    radial-gradient(ellipse 120% 80% at 18% 0%, rgba(186, 188, 192, 0.40) 0%, transparent 60%),
    radial-gradient(ellipse 100% 90% at 92% 8%, rgba(180, 182, 186, 0.28) 0%, transparent 58%),
    var(--aa-chrome-light-bg);
}

html[data-theme="stellar"] .aa-chrome-page {
  color: rgba(210, 228, 255, 0.94);
  background: #12122e;
}

.aa-chrome-page[data-show-home="true"] {
  --aa-chrome-slot-width: 96px;
}

/* ---- Stellar ambience + ignition (lab-scoped) ---- */

html[data-theme="stellar"] .aa-chrome-page::before,
html[data-theme="stellar"] .aa-chrome-page::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.8s ease;
}

html.stellar-effects-ready[data-theme="stellar"] .aa-chrome-page::before {
  opacity: 1;
  animation: aa-chrome-stellar-starfield 32s ease-in-out infinite alternate;
  background:
    radial-gradient(circle at 12% 18%, rgba(244, 248, 252, 0.92) 0, transparent 1.5px),
    radial-gradient(circle at 28% 32%, rgba(238, 244, 252, 0.85) 0, transparent 1.4px),
    radial-gradient(circle at 44% 20%, rgba(244, 248, 255, 0.88) 0, transparent 1.4px),
    radial-gradient(circle at 62% 28%, rgba(232, 238, 246, 0.82) 0, transparent 1.2px),
    radial-gradient(circle at 78% 36%, rgba(238, 244, 252, 0.84) 0, transparent 1.3px),
    radial-gradient(circle at 18% 58%, rgba(230, 236, 246, 0.78) 0, transparent 1.1px),
    radial-gradient(circle at 48% 68%, rgba(242, 246, 252, 0.86) 0, transparent 1.3px),
    radial-gradient(circle at 72% 74%, rgba(230, 236, 246, 0.76) 0, transparent 1.1px),
    radial-gradient(ellipse 120% 100% at 8% 16%, rgba(26, 26, 74, 0.03) 0%, transparent 52%);
  background-repeat: no-repeat;
}

html.stellar-effects-ready[data-theme="stellar"] .aa-chrome-page::after {
  opacity: 0.11;
  background-image:
    repeating-linear-gradient(0deg, rgba(215, 225, 250, 1) 0 1px, transparent 1px 64px),
    repeating-linear-gradient(90deg, rgba(215, 225, 250, 1) 0 1px, transparent 1px 64px),
    repeating-linear-gradient(72deg, rgba(195, 210, 248, 1) 0 1px, transparent 1px 112px);
  background-size: 100% 100%;
}

html.stellar-igniting[data-theme="stellar"] .aa-chrome-page::after {
  animation: aa-chrome-stellar-grid-ignite 1.1s ease-out;
}

@keyframes aa-chrome-stellar-grid-ignite {
  0% { opacity: 0; }
  30% { opacity: 0.28; }
  100% { opacity: 0.11; }
}

.aa-chrome-page .aa-chrome-stellar-flash {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: var(--aa-chrome-z-flash);
  opacity: 0;
  background:
    radial-gradient(circle at 50% 38%, rgba(200, 235, 255, 0.55) 0%, rgba(90, 150, 255, 0.14) 38%, transparent 68%);
}

.aa-chrome-page .aa-chrome-stellar-flash.is-active {
  animation: aa-chrome-stellar-flash 0.9s ease-out forwards;
}

@keyframes aa-chrome-stellar-starfield {
  0%, 100% { opacity: 0.92; transform: translate3d(0, 0, 0); }
  50% { opacity: 1; transform: translate3d(2px, -2px, 0); }
}

@keyframes aa-chrome-stellar-flash {
  0% { opacity: 0; }
  18% { opacity: 0.9; }
  100% { opacity: 0; }
}

/* ---- Header shell ---- */

.aa-chrome-page .aa-chrome-header.site-header {
  /* Fixed (viewport-anchored) so the document's top-boundary elastic rubber-band
     cannot translate the chrome. Immune by construction; does not depend on
     overscroll-behavior being honored by the browser/OS. */
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--aa-chrome-z-header);
  padding: 10px 0 16px;
  background: transparent;
  overflow-x: clip;
  width: 100%;
  /* contain: style (not layout) to avoid splitting child blades into separate
     layout contexts while still limiting scope. Backdrop children must share
     unified positioning so one wheel tick cannot shift only the top bar. */
  contain: style;
}

/* Flow spacer reserving the fixed header's height so main content does not slide
   underneath. Height is mirrored from the live header via JS on load + resize only
   (never on scroll), defaulting to the deterministic 150px stack. */
.aa-chrome-page .aa-chrome-header-spacer {
  width: 100%;
  height: var(--aa-chrome-header-height, 150px);
  flex: 0 0 auto;
  pointer-events: none;
}

.aa-chrome-page .header-inner {
  width: 100%;
  max-width: none;
  margin-inline: 0;
  padding-inline: 0;
}

.aa-chrome-page .header-bars {
  display: grid;
  gap: var(--aa-chrome-glass-bar-gap);
  align-items: center;
  /* Bleed applied once to the container holding BOTH bars. This unifies the
     two glass blades into one positioning/compositing unit. Previously each
     .glass-bar did its own 100vw + calc independently, allowing the top bar
     (first grid item, more internal content) to jitter on a single wheel tick
     while the controls bar stayed put. */
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
}

.aa-chrome-page .glass-bar {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: none;
  margin-left: 0;
  border-radius: var(--radius-rail);
  border: var(--aa-chrome-light-glass-border);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.10) 0%, transparent 40%),
    linear-gradient(100deg, transparent 0%, rgba(168, 170, 174, 0.09) 60%, transparent 100%),
    var(--aa-chrome-light-glass-bg);
  /* No live backdrop-filter: static frosted fill (see token note) for scroll stability. */
  box-shadow:
    var(--aa-chrome-light-glass-highlight),
    inset 0 -1px 0 rgba(28, 30, 34, 0.06),
    var(--aa-chrome-light-glass-shadow);
}

html[data-theme="dark"] .aa-chrome-page .glass-bar {
  border: var(--aa-chrome-dark-glass-border);
  background: var(--aa-chrome-dark-glass-bg);
  box-shadow:
    var(--aa-chrome-dark-glass-highlight),
    var(--aa-chrome-dark-glass-shadow);
}

html[data-theme="dark"] .aa-chrome-page .glass-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0.035;
  background-image: repeating-conic-gradient(
    from 0deg at 50% 50%,
    rgba(255, 255, 255, 0.14) 0deg 1deg,
    transparent 1deg 3deg
  );
}

html[data-theme="stellar"] .aa-chrome-page .glass-bar {
  border: 1px solid transparent;
  border-radius: calc(var(--radius-rail) + 2px);
  background:
    linear-gradient(180deg, rgba(180, 210, 255, 0.06) 0%, transparent 34%),
    radial-gradient(ellipse 80% 140% at 84% 0%, rgba(120, 168, 255, 0.05) 0%, transparent 60%),
    var(--aa-chrome-stellar-glass-bg);
  box-shadow:
    var(--aa-chrome-stellar-glass-highlight),
    var(--aa-chrome-stellar-glass-shadow);
}

@media (max-width: 520px) {
  .aa-chrome-page .header-bars {
    width: 100vw;
    margin-left: calc(50% - 50vw);
  }
  .aa-chrome-page .glass-bar,
  .aa-chrome-page .glass-bar.top-bar,
  .aa-chrome-page .glass-bar.controls-bar {
    width: 100%;
    margin-left: 0;
    border-radius: 0;
  }
}

.aa-chrome-page .glass-bar.top-bar {
  min-height: var(--aa-chrome-top-bar-min-height);
  padding: var(--aa-chrome-top-bar-pad-y) 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.aa-chrome-page .glass-bar.controls-bar {
  min-height: var(--aa-chrome-controls-bar-height);
  max-height: var(--aa-chrome-controls-bar-height);
  height: var(--aa-chrome-controls-bar-height);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

/* ---- Brand axis (viewport center locked) ---- */

.aa-chrome-page .aa-chrome-brand {
  position: absolute;
  inset: 0;
  display: block;
  width: auto;
  min-width: 0;
}

.aa-chrome-page .aa-chrome-brand--public {
  position: absolute;
  inset: 0;
  width: auto;
  min-height: 0;
}

.aa-chrome-page .aa-chrome-brand--public .aa-chrome-brand-lockup-img {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate3d(-50%, -50%, 0);
  margin: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.aa-chrome-page .aa-chrome-brand-cobrand-layout {
  position: absolute;
  inset: 0;
  width: auto;
  min-height: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.aa-chrome-page .aa-chrome-brand-cobrand-layout .aa-chrome-brand-cross {
  position: absolute;
  left: var(--aa-chrome-axis-x);
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  pointer-events: none;
}

.aa-chrome-page .aa-chrome-brand-cobrand-layout .aa-chrome-brand-zone--left {
  grid-column: 1;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding-right: var(--aa-chrome-cobrand-gap);
  min-width: 0;
}

.aa-chrome-page .aa-chrome-brand-cobrand-layout .aa-chrome-brand-zone--right {
  grid-column: 2;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  padding-left: var(--aa-chrome-cobrand-gap);
  min-width: 0;
}

.aa-chrome-page .aa-chrome-brand-admin-layout {
  position: absolute;
  inset: 0;
  width: auto;
  min-height: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.aa-chrome-page .aa-chrome-brand-admin-layout .aa-chrome-brand-cross {
  position: absolute;
  left: var(--aa-chrome-axis-x);
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  pointer-events: none;
}

.aa-chrome-page .aa-chrome-brand-admin-layout .aa-chrome-brand-zone--left {
  grid-column: 1;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding-right: var(--aa-chrome-cobrand-gap);
  min-width: 0;
}

.aa-chrome-page .aa-chrome-brand-admin-layout .aa-chrome-brand-zone--right {
  grid-column: 2;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  padding-left: var(--aa-chrome-cobrand-gap);
  min-width: 0;
}

.aa-chrome-page .aa-chrome-brand-admin-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.aa-chrome-page .aa-chrome-brand-admin-title {
  font-size: calc(var(--aa-chrome-control-font-size) * 1.28);
  letter-spacing: 0.12em;
  opacity: 0.88;
}

.aa-chrome-page .aa-chrome-brand-admin-kicker {
  display: block;
  font-size: calc(var(--aa-chrome-control-font-size) * 0.88);
  letter-spacing: 0.16em;
  opacity: 0.58;
  margin-bottom: 2px;
}

.aa-chrome-page .aa-chrome-brand-lockup-img {
  display: block;
  height: var(--header-lockup-height);
  width: auto;
  max-width: min(42vw, 320px);
  transition: none;
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-brand-lockup-img,
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-brand-lockup-img {
  filter: brightness(0) saturate(100%) invert(92%) sepia(8%) saturate(280%) hue-rotate(346deg) brightness(103%) contrast(92%);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-brand-lockup-img {
  filter: none;
  opacity: 0.96;
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-brand-mark,
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-brand-mark {
  filter: brightness(0) saturate(100%) invert(90%) sepia(6%) saturate(260%) hue-rotate(346deg) brightness(102%) contrast(90%);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-brand-mark {
  filter: none;
  opacity: 0.94;
}

.aa-chrome-page .aa-chrome-brand-mark {
  display: block;
  height: var(--aa-chrome-cobrand-mark-h);
  width: auto;
  max-width: 100%;
}

.aa-chrome-page .aa-chrome-brand-cross {
  display: block;
  font-size: clamp(15px, 2vw, 18px);
  font-weight: 400;
  line-height: 1;
  opacity: 0.55;
  user-select: none;
}

.aa-chrome-page .aa-chrome-brand-partner {
  display: block;
  max-width: 100%;
  padding: 2px 0;
  font-size: calc(var(--aa-chrome-control-font-size) * 0.92);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0.72;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-brand-partner {
  color: rgba(58, 60, 64, 0.78);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-brand-partner,
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-brand-partner {
  color: rgba(215, 220, 228, 0.72);
}

.aa-chrome-page .aa-chrome-brand-admin-label {
  opacity: 0.72;
}

.aa-chrome-page .aa-chrome-brand[data-brand-mode="public"] .aa-chrome-brand--cobrand,
.aa-chrome-page .aa-chrome-brand[data-brand-mode="public"] .aa-chrome-brand--admin,
.aa-chrome-page .aa-chrome-brand[data-brand-mode="cobrand"] .aa-chrome-brand--public,
.aa-chrome-page .aa-chrome-brand[data-brand-mode="cobrand"] .aa-chrome-brand--admin,
.aa-chrome-page .aa-chrome-brand[data-brand-mode="admin"] .aa-chrome-brand--public,
.aa-chrome-page .aa-chrome-brand[data-brand-mode="admin"] .aa-chrome-brand--cobrand {
  display: none;
}

.aa-chrome-page .aa-chrome-brand[data-brand-mode="public"] .aa-chrome-brand--public {
  display: block;
}

.aa-chrome-page .aa-chrome-brand[data-brand-mode="cobrand"] .aa-chrome-brand--cobrand {
  display: grid;
}

.aa-chrome-page .aa-chrome-brand[data-brand-mode="admin"] .aa-chrome-brand--admin {
  display: grid;
}

/* ---- Controls rail (balanced slots) ---- */

.aa-chrome-page .aa-chrome-controls.header-controls {
  width: 100%;
  max-width: none;
  margin-left: 0;
  padding-left: 0;
  padding-right: 0;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: var(--aa-chrome-slot-width) 1fr var(--aa-chrome-slot-width);
  align-items: center;
  gap: 0;
  height: var(--aa-chrome-controls-bar-height);
  min-height: var(--aa-chrome-controls-bar-height);
  max-height: var(--aa-chrome-controls-bar-height);
  position: relative;
}

.aa-chrome-page .aa-chrome-controls-start {
  grid-column: 1;
  grid-row: 1;
  width: var(--aa-chrome-slot-width);
  min-width: var(--aa-chrome-slot-width);
  max-width: var(--aa-chrome-slot-width);
  height: 100%;
  display: flex;
  align-items: center;
  gap: var(--aa-chrome-start-gap);
  justify-content: flex-start;
  z-index: 2;
  box-sizing: border-box;
}

.aa-chrome-page .aa-chrome-controls-end {
  grid-column: 3;
  grid-row: 1;
  width: var(--aa-chrome-slot-width);
  min-width: var(--aa-chrome-slot-width);
  max-width: var(--aa-chrome-slot-width);
  height: 100%;
  pointer-events: none;
  visibility: hidden;
  z-index: 2;
  box-sizing: border-box;
}

.aa-chrome-page .glass-bar.controls-bar .public-theme-cluster {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.aa-chrome-page .mode-rail--theme-only {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.aa-chrome-page .mode-rail--theme-only > .mode-option {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--aa-chrome-theme-cell);
  min-width: var(--aa-chrome-theme-cell);
  max-width: var(--aa-chrome-theme-cell);
  height: 28px;
  min-height: 28px;
  max-height: 28px;
  padding: 0;
  border: none;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  touch-action: manipulation;
  pointer-events: auto;
  contain: layout style paint;
  isolation: isolate;
  transition: color 0.22s ease;
}

.aa-chrome-page .mode-rail--theme-only > .mode-option[data-mode="light"] {
  left: var(--aa-chrome-axis-x);
}

.aa-chrome-page .mode-rail--theme-only > .mode-option[data-mode="dark"] {
  left: calc(var(--aa-chrome-axis-x) - var(--aa-chrome-theme-cell) - var(--aa-chrome-theme-gap));
}

.aa-chrome-page .mode-rail--theme-only > .mode-option[data-mode="stellar"] {
  left: calc(var(--aa-chrome-axis-x) + var(--aa-chrome-theme-cell) + var(--aa-chrome-theme-gap));
}

/* ---- Shared chrome text controls (HOME, theme rail, drawer links) ---- */

.aa-chrome-page .aa-chrome-text-control {
  font-family: inherit;
  font-size: var(--aa-chrome-control-font-size);
  font-weight: var(--aa-chrome-control-font-weight);
  letter-spacing: var(--aa-chrome-control-letter-spacing);
  line-height: var(--aa-chrome-control-line-height);
  text-transform: var(--aa-chrome-control-text-transform);
  white-space: nowrap;
  transition: color 0.22s ease, text-shadow 0.30s ease, opacity 0.22s ease;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-text-control:not(.is-theme-active):not(.is-home-active) {
  color: rgba(72, 74, 78, 0.58);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.72),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.16);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-text-control:not(.is-theme-active):not(.is-home-active) {
  color: rgba(210, 216, 224, 0.46);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.14),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.38);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-text-control:not(.is-theme-active):not(.is-home-active) {
  color: rgba(185, 210, 240, 0.50);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.22),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.34);
}

html[data-theme="light"] .aa-chrome-page .mode-rail--theme-only > .mode-option.is-theme-active,
html[data-theme="light"] .aa-chrome-page .aa-chrome-home-slot.is-home-active {
  color: #1f2227;
  animation: aa-chrome-etch-light 3.5s ease-in-out infinite;
}

html[data-theme="dark"] .aa-chrome-page .mode-rail--theme-only > .mode-option.is-theme-active,
html[data-theme="dark"] .aa-chrome-page .aa-chrome-home-slot.is-home-active {
  color: rgba(238, 232, 222, 0.96);
  animation: aa-chrome-etch-dark 3.5s ease-in-out infinite;
}

html[data-theme="stellar"] .aa-chrome-page .mode-rail--theme-only > .mode-option.is-theme-active,
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-home-slot.is-home-active {
  color: rgba(210, 232, 255, 0.98);
  animation: aa-chrome-etch-stellar 3s ease-in-out infinite;
}

.aa-chrome-page .aa-chrome-text-control:hover:not(.is-theme-active):not(.is-home-active):not(.mode-option) {
  opacity: 0.92;
}

html[data-theme="light"] .aa-chrome-page .mode-rail--theme-only > .mode-option:not(.is-theme-active):hover {
  color: rgba(40, 42, 46, 0.82);
}

html[data-theme="dark"] .aa-chrome-page .mode-rail--theme-only > .mode-option:not(.is-theme-active):hover {
  color: rgba(228, 232, 238, 0.72);
}

html[data-theme="stellar"] .aa-chrome-page .mode-rail--theme-only > .mode-option:not(.is-theme-active):hover {
  color: rgba(210, 232, 255, 0.72);
}

.aa-chrome-page .aa-chrome-text-control:focus-visible {
  outline: 1.5px solid rgba(90, 92, 96, 0.55);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---- Hit target helper ---- */

.aa-chrome-page .aa-chrome-nav-toggle,
.aa-chrome-page .aa-chrome-home-slot {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: var(--aa-chrome-control-visual);
  padding: var(--aa-chrome-control-hit-pad);
  margin: calc(var(--aa-chrome-control-hit-pad) * -1);
  box-sizing: content-box;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  touch-action: manipulation;
  flex: none;
  text-decoration: none;
}

.aa-chrome-page .aa-chrome-nav-toggle {
  width: var(--aa-chrome-control-visual);
}

.aa-chrome-page .aa-chrome-home-slot[hidden] {
  display: none !important;
}

.aa-chrome-page .aa-chrome-home-slot {
  width: auto;
  min-width: var(--aa-chrome-control-visual);
  justify-content: flex-start;
  text-align: left;
  align-self: center;
}

.aa-chrome-page .aa-chrome-nav-toggle:hover,
.aa-chrome-page .aa-chrome-home-slot:hover {
  background: transparent;
}

.aa-chrome-page .aa-chrome-nav-toggle:focus-visible {
  outline: 1.5px solid rgba(77, 107, 122, 0.55);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---- Hamburger ---- */

.aa-chrome-page .public-nav-toggle__bars,
.aa-chrome-page .public-nav-toggle__bars::before,
.aa-chrome-page .public-nav-toggle__bars::after {
  display: block;
  width: 14px;
  height: 1.25px;
  border-radius: 1px;
  background: currentColor;
  transition: transform 0.22s ease, opacity 0.18s ease, box-shadow 0.22s ease;
}

.aa-chrome-page .public-nav-toggle__bars {
  position: relative;
  color: rgba(215, 220, 228, 0.88);
}

.aa-chrome-page .public-nav-toggle__bars::before,
.aa-chrome-page .public-nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
}

html[data-theme="light"] .aa-chrome-page .public-nav-toggle__bars,
html[data-theme="light"] .aa-chrome-page .public-nav-toggle__bars::before,
html[data-theme="light"] .aa-chrome-page .public-nav-toggle__bars::after {
  color: rgba(60, 66, 75, 0.88);
  box-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.78),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.18);
}

html[data-theme="dark"] .aa-chrome-page .public-nav-toggle__bars,
html[data-theme="dark"] .aa-chrome-page .public-nav-toggle__bars::before,
html[data-theme="dark"] .aa-chrome-page .public-nav-toggle__bars::after {
  color: rgba(215, 220, 228, 0.82);
  box-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.16),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.40);
}

html[data-theme="stellar"] .aa-chrome-page .public-nav-toggle__bars,
html[data-theme="stellar"] .aa-chrome-page .public-nav-toggle__bars::before,
html[data-theme="stellar"] .aa-chrome-page .public-nav-toggle__bars::after {
  color: rgba(190, 215, 245, 0.86);
  box-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.26),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.36);
}

.aa-chrome-page .public-nav-toggle__bars::before { top: -4px; }
.aa-chrome-page .public-nav-toggle__bars::after  { top:  4px; }

.aa-chrome-page .aa-chrome-nav-toggle[aria-expanded="true"] .public-nav-toggle__bars {
  background: transparent;
  box-shadow: none;
}

.aa-chrome-page .aa-chrome-nav-toggle[aria-expanded="true"] .public-nav-toggle__bars::before {
  top: 0;
  transform: rotate(45deg);
}

.aa-chrome-page .aa-chrome-nav-toggle[aria-expanded="true"] .public-nav-toggle__bars::after {
  top: 0;
  transform: rotate(-45deg);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-nav-toggle[aria-expanded="true"] .public-nav-toggle__bars {
  box-shadow: none;
}

/* ---- Theme rail layout (LIGHT locked to viewport axis) ---- */

@keyframes aa-chrome-etch-light {
  0%, 100% { text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.72), -0.5px -0.5px 0 rgba(0,0,0,0.18), 0 0 6px rgba(72, 76, 82, 0.32); }
  50% { text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.92), -0.5px -0.5px 0 rgba(0,0,0,0.18), 0 0 16px rgba(72, 76, 82, 0.58); }
}

@keyframes aa-chrome-etch-dark {
  0%, 100% { text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.24), -0.5px -0.5px 0 rgba(0,0,0,0.38), 0 0 8px rgba(130,175,210,0.48); }
  50% { text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.38), -0.5px -0.5px 0 rgba(0,0,0,0.38), 0 0 18px rgba(130,175,210,0.88); }
}

@keyframes aa-chrome-etch-stellar {
  0%, 100% { text-shadow: 0.5px 0.5px 0 rgba(200,235,255,0.36), -0.5px -0.5px 0 rgba(0,0,0,0.34), 0 0 10px rgba(109,210,255,0.55); }
  50% { text-shadow: 0.5px 0.5px 0 rgba(230,248,255,0.52), -0.5px -0.5px 0 rgba(0,0,0,0.34), 0 0 20px rgba(109,210,255,0.92); }
}

@media (max-width: 400px) {
  .aa-chrome-page {
    --aa-chrome-theme-cell: 42px;
  }

  .aa-chrome-page .glass-bar.controls-bar .public-theme-cluster {
    max-width: none;
  }

  .aa-chrome-page .aa-chrome-brand-partner {
    font-size: calc(var(--aa-chrome-control-font-size) * 0.85);
    letter-spacing: 0.08em;
  }
}

/* ---- Backdrop ---- */

.aa-chrome-page .aa-chrome-backdrop {
  position: fixed;
  inset: 0;
  z-index: var(--aa-chrome-z-backdrop);
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

/* ---- Drawer ---- */

.aa-chrome-page .aa-chrome-drawer {
  position: fixed;
  z-index: var(--aa-chrome-z-drawer);
  top: 0;
  left: 0;
  width: var(--aa-chrome-menu-width);
  max-height: var(--aa-chrome-drawer-max-height);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 16px 20px 18px var(--aa-chrome-drawer-text-left);
  margin: 0;
  border-radius: 0;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
  isolation: isolate;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer {
  border: var(--aa-chrome-light-glass-border);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.22) 0%, transparent 30%),
    linear-gradient(120deg, transparent 0%, rgba(188, 190, 194, 0.14) 70%, transparent 100%),
    var(--aa-chrome-light-glass-bg);
  /* No live backdrop-filter: matches the static frosted blades for scroll stability. */
  box-shadow:
    var(--aa-chrome-light-glass-highlight),
    inset 0 -1px 0 rgba(28, 30, 34, 0.05),
    var(--aa-chrome-light-glass-shadow);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer {
  border: var(--aa-chrome-dark-glass-border);
  background: var(--aa-chrome-dark-glass-bg);
  box-shadow:
    var(--aa-chrome-dark-glass-highlight),
    var(--aa-chrome-dark-glass-shadow);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0.035;
  background-image: repeating-conic-gradient(
    from 0deg at 50% 50%,
    rgba(255, 255, 255, 0.14) 0deg 1deg,
    transparent 1deg 3deg
  );
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer {
  border: 1px solid transparent;
  border-radius: calc(var(--radius-rail) + 4px);
  background:
    linear-gradient(180deg, rgba(180, 210, 255, 0.10) 0%, transparent 30%),
    radial-gradient(ellipse 90% 120% at 82% 0%, rgba(120, 168, 255, 0.10) 0%, transparent 60%),
    var(--aa-chrome-stellar-glass-bg);
  /* No live backdrop-filter: matches the static frosted blades for scroll stability. */
  box-shadow:
    var(--aa-chrome-stellar-glass-highlight),
    var(--aa-chrome-stellar-glass-shadow);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="default"],
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="context"],
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__logout a.aa-chrome-nav-logout {
  color: rgba(215, 232, 255, 0.78);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.28),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.30);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__logout-sep {
  border: none;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(170, 210, 255, 0.18) 20%,
    rgba(170, 210, 255, 0.18) 80%,
    transparent
  );
  opacity: 0.75;
}

.aa-chrome-page .aa-chrome-drawer__section-label {
  margin: 14px 0 8px;
  padding: 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.92;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__section-label {
  color: #565a60;
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__section-label,
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__section-label {
  color: rgba(147, 175, 194, 0.88);
}

.aa-chrome-page .aa-chrome-drawer__links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.aa-chrome-page .aa-chrome-drawer__links a,
.aa-chrome-page .aa-chrome-drawer__logout a {
  position: relative;
  display: block;
  padding: 4px 0;
  border: none;
  border-radius: 0;
  background: transparent;
  text-decoration: none;
  cursor: pointer;
}

.aa-chrome-page .aa-chrome-drawer__upcoming {
  position: relative;
  display: block;
  padding: 4px 0;
  border: none;
  border-radius: 0;
  background: transparent;
  font-family: inherit;
  font-size: var(--aa-chrome-control-font-size);
  font-weight: var(--aa-chrome-control-font-weight);
  letter-spacing: var(--aa-chrome-control-letter-spacing);
  line-height: var(--aa-chrome-control-line-height);
  text-transform: var(--aa-chrome-control-text-transform);
  text-decoration: none;
}

.aa-chrome-page .aa-chrome-drawer__links a:focus-visible,
.aa-chrome-page .aa-chrome-drawer__logout a:focus-visible {
  outline: 1.5px solid rgba(77, 107, 122, 0.45);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---- Drawer nav state hierarchy ---- */

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="default"] {
  color: rgba(72, 74, 78, 0.58);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.72),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.16);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="default"] {
  color: rgba(210, 216, 224, 0.46);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.14),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.38);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="default"] {
  color: rgba(185, 210, 240, 0.50);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.22),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.34);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="context"] {
  color: rgba(54, 56, 60, 0.82);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.78),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.14);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="context"] {
  color: rgba(225, 230, 238, 0.72);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.18),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.34);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="context"] {
  color: rgba(205, 228, 255, 0.82);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.26),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.30);
}

.aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="context"]::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: calc(var(--aa-chrome-control-font-size) * 1.35);
  border-radius: 1px;
  background: currentColor;
  opacity: 0.40;
}

.aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"]::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 2px;
  height: calc(var(--aa-chrome-control-font-size) * 1.45);
  border-radius: 1px;
  background: currentColor;
  opacity: 0.82;
  box-shadow: 0 0 8px currentColor;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"] {
  animation: aa-chrome-menu-active-light 2.8s ease-in-out infinite;
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"] {
  animation: aa-chrome-menu-active-dark 2.8s ease-in-out infinite;
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"] {
  animation: aa-chrome-menu-active-stellar 2.6s ease-in-out infinite;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"]::before {
  animation: aa-chrome-location-glint-light 2.2s ease-in-out infinite;
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"]::before {
  animation: aa-chrome-location-glint-dark 2.2s ease-in-out infinite;
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"]::before {
  animation: aa-chrome-location-glint-stellar 2.2s ease-in-out infinite;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__logout a.aa-chrome-nav-logout {
  color: rgba(72, 74, 78, 0.68);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.72),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.16);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__logout a.aa-chrome-nav-logout {
  color: rgba(210, 216, 224, 0.58);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.14),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.38);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__logout a.aa-chrome-nav-logout {
  color: rgba(215, 232, 255, 0.72);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.28),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.30);
}

.aa-chrome-page .aa-chrome-drawer__upcoming[data-nav-state="disabled"] {
  cursor: default;
  pointer-events: none;
  opacity: 0.42;
  text-shadow: none;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__upcoming[data-nav-state="disabled"] {
  color: rgba(72, 74, 78, 0.42);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-drawer__upcoming[data-nav-state="disabled"],
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-drawer__upcoming[data-nav-state="disabled"] {
  color: rgba(210, 216, 224, 0.38);
}

@keyframes aa-chrome-menu-active-light {
  0%, 100% { color: #1e2024; text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.72), -0.5px -0.5px 0 rgba(0,0,0,0.16), 0 0 8px rgba(72, 76, 82, 0.32); }
  50% { color: #16181c; text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.92), -0.5px -0.5px 0 rgba(0,0,0,0.16), 0 0 18px rgba(72, 76, 82, 0.58); }
}

@keyframes aa-chrome-menu-active-dark {
  0%, 100% { color: rgba(242, 238, 230, 0.98); text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.26), -0.5px -0.5px 0 rgba(0,0,0,0.38), 0 0 10px rgba(130,175,210,0.52); }
  50% { color: rgba(255, 252, 246, 1); text-shadow: 0.5px 0.5px 0 rgba(255,255,255,0.38), -0.5px -0.5px 0 rgba(0,0,0,0.38), 0 0 20px rgba(130,175,210,0.92); }
}

@keyframes aa-chrome-menu-active-stellar {
  0%, 100% { color: rgba(228, 244, 255, 0.99); text-shadow: 0.5px 0.5px 0 rgba(210,235,255,0.38), -0.5px -0.5px 0 rgba(0,0,0,0.32), 0 0 12px rgba(109,210,255,0.58); }
  50% { color: rgba(245, 252, 255, 1); text-shadow: 0.5px 0.5px 0 rgba(230,248,255,0.52), -0.5px -0.5px 0 rgba(0,0,0,0.32), 0 0 22px rgba(109,210,255,0.95); }
}

@keyframes aa-chrome-location-glint-light {
  0%, 100% { opacity: 0.62; box-shadow: 0 0 6px rgba(72, 76, 82, 0.38); transform: translateY(-50%) scaleY(0.92); }
  50% { opacity: 1; box-shadow: 0 0 16px rgba(72, 76, 82, 0.62); transform: translateY(-50%) scaleY(1.08); }
}

@keyframes aa-chrome-location-glint-dark {
  0%, 100% { opacity: 0.58; box-shadow: 0 0 8px rgba(130,175,210,0.52); transform: translateY(-50%) scaleY(0.92); }
  50% { opacity: 1; box-shadow: 0 0 18px rgba(130,175,210,0.92); transform: translateY(-50%) scaleY(1.08); }
}

@keyframes aa-chrome-location-glint-stellar {
  0%, 100% { opacity: 0.65; box-shadow: 0 0 10px rgba(109,210,255,0.58); transform: translateY(-50%) scaleY(0.92); }
  50% { opacity: 1; box-shadow: 0 0 20px rgba(109,210,255,0.95); transform: translateY(-50%) scaleY(1.08); }
}

.aa-chrome-page .aa-chrome-drawer__logout-sep {
  margin: 16px 0 0;
  padding: 0;
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  opacity: 0.55;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-drawer__logout-sep {
  border-top-color: rgba(24, 26, 30, 0.10);
}

.aa-chrome-page .aa-chrome-drawer__logout-sep[hidden],
.aa-chrome-page .aa-chrome-drawer__logout[hidden] {
  display: none !important;
}

.aa-chrome-page .aa-chrome-drawer__logout {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

@media (max-width: 390px) {
  .aa-chrome-page .aa-chrome-drawer {
    width: min(calc(100vw - 24px), var(--aa-chrome-menu-width));
  }
}

@media (prefers-reduced-motion: reduce) {
  .aa-chrome-page .public-nav-toggle__bars,
  .aa-chrome-page .public-nav-toggle__bars::before,
  .aa-chrome-page .public-nav-toggle__bars::after {
    transition: none;
  }

  .aa-chrome-page .mode-rail--theme-only > .mode-option.is-theme-active,
  .aa-chrome-page .aa-chrome-home-slot.is-home-active {
    animation: none;
  }

  .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"],
  .aa-chrome-page .aa-chrome-drawer__links a.aa-chrome-nav-link[data-nav-state="current"]::before {
    animation: none;
  }

  html.stellar-effects-ready[data-theme="stellar"] .aa-chrome-page::before {
    animation: none;
    transform: none;
    transition: none;
    opacity: 1;
  }

  html[data-theme="stellar"] .aa-chrome-page::before,
  html[data-theme="stellar"] .aa-chrome-page::after {
    transition: none;
  }

  .aa-chrome-page .aa-chrome-stellar-flash.is-active {
    animation: none;
    opacity: 0;
  }

  .aa-chrome-page .aa-chrome-polaris-visual::after {
    animation: none;
  }
}

/* ---- Lab page content ---- */

.aa-chrome-page .aa-chrome-lab-wrap {
  position: relative;
  z-index: 1;
  max-width: var(--aa-chrome-body-rail-max);
  margin: 0 auto;
  padding: 28px var(--aa-chrome-rail-pad) 88px;
}

.aa-chrome-page .aa-chrome-lab-rail-label {
  display: block;
  margin: 0 0 10px;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.58;
}

.aa-chrome-page .aa-chrome-lab-rail-label--body {
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(127, 140, 155, 0.22);
}

.aa-chrome-page .aa-chrome-lab-rail-label--inner {
  margin-bottom: 14px;
  opacity: 0.52;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-lab-rail-label--body {
  border-bottom-color: rgba(152, 154, 158, 0.36);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-lab-rail-label--body {
  border-bottom-color: rgba(120, 168, 255, 0.18);
}

.aa-chrome-page .aa-chrome-lab-banner {
  margin: 0 0 24px;
  padding: 16px 18px;
  border: 1px solid rgba(127, 140, 155, 0.30);
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.6;
  background: rgba(127, 140, 155, 0.11);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.aa-chrome-page .aa-chrome-lab-banner strong {
  display: block;
  margin-bottom: 6px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.aa-chrome-page .aa-chrome-lab-panel {
  max-width: var(--aa-chrome-fixture-panel-max);
  margin: 0 auto 32px;
  padding: 22px 22px 20px;
  border-radius: 14px;
  border: 1px solid rgba(127, 140, 155, 0.22);
  background: rgba(127, 140, 155, 0.13);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 10px 30px rgba(10, 14, 20, 0.08);
}

.aa-chrome-page .aa-chrome-lab-panel h2 {
  margin: 0 0 16px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.9;
}

.aa-chrome-page .aa-chrome-lab-grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 640px) {
  .aa-chrome-page .aa-chrome-lab-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.aa-chrome-page .aa-chrome-lab-field label {
  display: block;
  margin-bottom: 6px;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.72;
}

.aa-chrome-page .aa-chrome-lab-field select {
  font: inherit;
  width: 100%;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid rgba(127, 140, 155, 0.30);
  background: rgba(127, 140, 155, 0.08);
  color: inherit;
}

.aa-chrome-page .aa-chrome-lab-field label:has(input[type="checkbox"]) {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 0;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(127, 140, 155, 0.10);
  text-transform: none;
  letter-spacing: 0.02em;
  font-size: 12px;
  opacity: 0.9;
}

.aa-chrome-page .aa-chrome-lab-field input[type="checkbox"] {
  font: inherit;
  flex: none;
}

.aa-chrome-page .aa-chrome-lab-metrics {
  margin-top: 16px;
  padding: 14px 16px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  line-height: 1.6;
  border-radius: 10px;
  border: 1px solid rgba(127, 140, 155, 0.18);
  background: rgba(0, 0, 0, 0.22);
  max-width: 100%;
  box-sizing: border-box;
  overflow-x: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-lab-banner {
  background: rgba(188, 190, 194, 0.72);
  border-color: rgba(142, 144, 148, 0.46);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-lab-panel {
  background: rgba(192, 194, 198, 0.78);
  border-color: rgba(142, 144, 148, 0.42);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-lab-field select,
html[data-theme="light"] .aa-chrome-page .aa-chrome-lab-field label:has(input[type="checkbox"]) {
  background: rgba(255, 255, 255, 0.52);
  border-color: rgba(172, 174, 178, 0.42);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-lab-metrics {
  background: rgba(28, 30, 34, 0.06);
  color: #2a2c30;
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-lab-banner,
html[data-theme="stellar"] .aa-chrome-page .aa-chrome-lab-panel {
  border-color: rgba(120, 168, 255, 0.22);
  background: rgba(22, 27, 52, 0.46);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-lab-metrics {
  background: rgba(8, 12, 32, 0.48);
}

.aa-chrome-page .aa-chrome-lab-section {
  margin: 0 0 48px;
  padding-top: 8px;
}

.aa-chrome-page .aa-chrome-lab-section h2 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 500;
}

.aa-chrome-page .aa-chrome-lab-section p {
  margin: 0 0 12px;
  max-width: 68ch;
  line-height: 1.6;
  opacity: 0.88;
}

.aa-chrome-page .aa-chrome-lab-section--tall {
  min-height: 55vh;
}

.aa-chrome-page .aa-chrome-skip {
  position: absolute;
  left: -9999px;
  top: auto;
}

.aa-chrome-page .aa-chrome-skip:focus {
  left: 12px;
  top: 12px;
  z-index: 100;
  padding: 8px 12px;
  background: #fff;
  color: #111;
}

/* ---- Canonical Polaris (lab reference) ---- */

.aa-chrome-page .aa-chrome-polaris-link,
.aa-chrome-page .aa-chrome-polaris-visual {
  display: none;
}

html[data-theme="stellar"] .aa-chrome-page[data-polaris-enabled="true"] .aa-chrome-polaris-link,
html[data-theme="stellar"] .aa-chrome-page[data-polaris-enabled="true"] .aa-chrome-polaris-visual {
  display: block;
}

.aa-chrome-page .aa-chrome-polaris-link {
  position: fixed;
  --aa-chrome-polaris-top: max(calc(env(safe-area-inset-top, 0px) + 132px), 144px);
  --aa-chrome-polaris-right: max(calc(env(safe-area-inset-right, 0px) + clamp(20px, 4vw, 48px)), 20px);
  top: var(--aa-chrome-polaris-top);
  right: var(--aa-chrome-polaris-right);
  width: 44px;
  height: 44px;
  z-index: var(--aa-chrome-z-polaris);
  padding: 0;
  margin: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.aa-chrome-page .aa-chrome-polaris-visual {
  position: fixed;
  pointer-events: none;
  z-index: 1;
  top: var(--aa-chrome-polaris-top, max(calc(env(safe-area-inset-top, 0px) + 132px), 144px));
  right: var(--aa-chrome-polaris-right, max(calc(env(safe-area-inset-right, 0px) + clamp(20px, 4vw, 48px)), 20px));
  width: 44px;
  height: 44px;
}

.aa-chrome-page .aa-chrome-polaris-visual::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 22px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 1) 0, rgba(255, 255, 255, 1) 1.5px, transparent 2.8px),
    radial-gradient(circle at 50% 50%, rgba(248, 252, 255, 0.58) 0, rgba(210, 224, 248, 0.28) 46%, transparent 64%);
  animation: aa-chrome-polaris-pulse 5s ease-in-out infinite;
}

@keyframes aa-chrome-polaris-pulse {
  0%, 100% { opacity: 0.88; transform: translate(-50%, -50%) scale(1); filter: drop-shadow(0 0 2px rgba(255,255,255,0.6)); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.16); filter: drop-shadow(0 0 12px rgba(180,210,255,0.55)); }
}

.aa-chrome-page .aa-chrome-polaris-visual.is-supernova::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 22px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.95) 0%, rgba(190, 220, 255, 0.6) 30%, rgba(120, 168, 255, 0.18) 58%, transparent 74%);
  animation: aa-chrome-polaris-supernova 1.2s ease-out forwards;
}

@keyframes aa-chrome-polaris-supernova {
  0% { opacity: 0.2; transform: translate(-50%, -50%) scale(0.4); filter: drop-shadow(0 0 4px rgba(200, 230, 255, 0.8)); }
  35% { opacity: 1; transform: translate(-50%, -50%) scale(3.6); filter: drop-shadow(0 0 26px rgba(150, 195, 255, 0.85)); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(5.4); filter: drop-shadow(0 0 8px rgba(150, 195, 255, 0.2)); }
}

@media (prefers-reduced-motion: reduce) {
  .aa-chrome-page .aa-chrome-polaris-visual.is-supernova::before {
    animation: none;
    opacity: 0.5;
  }

  html.stellar-igniting[data-theme="stellar"] .aa-chrome-page::after {
    animation: none;
  }
}

.aa-chrome-page .aa-chrome-polaris-link:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(102, 194, 255, 0.35);
}

.aa-chrome-page .aa-chrome-origin-panel {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 188px);
  right: max(calc(env(safe-area-inset-right, 0px) + 20px), 20px);
  width: min(360px, calc(100vw - 40px));
  padding: 14px 16px;
  border-radius: calc(var(--radius-rail) + 6px);
  border: 1px solid rgba(121, 214, 255, 0.28);
  background:
    linear-gradient(160deg, rgba(0, 210, 255, 0.12), rgba(84, 126, 255, 0.14)),
    rgba(6, 10, 26, 0.88);
  color: rgba(232, 240, 255, 0.94);
  z-index: var(--aa-chrome-z-polaris);
  box-shadow: 0 16px 34px rgba(10, 14, 42, 0.44);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-6px) scale(0.98);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s linear 0.22s;
}

.aa-chrome-page .aa-chrome-origin-panel.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  transition-delay: 0s;
}

.aa-chrome-page .aa-chrome-origin-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.aa-chrome-page .aa-chrome-origin-panel h3 {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
}

.aa-chrome-page .aa-chrome-origin-panel p {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  opacity: 0.9;
}

.aa-chrome-page .aa-chrome-origin-close {
  font: inherit;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 8px;
  border: 1px solid rgba(143, 201, 255, 0.32);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: inherit;
  cursor: pointer;
}

/* ---- Public footer fixture (lab candidate) ---- */

.aa-chrome-page .aa-chrome-footer-fixture {
  position: relative;
  z-index: 1;
  margin-top: 24px;
  border-top: 1px solid rgba(127, 140, 155, 0.22);
}

.aa-chrome-page .aa-chrome-footer-fixture__inner {
  max-width: var(--aa-chrome-body-rail-max);
  margin: 0 auto;
  padding: 36px var(--aa-chrome-rail-pad) 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  overflow-x: clip;
}

.aa-chrome-page .aa-chrome-footer-fixture__nav-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
}

.aa-chrome-page .aa-chrome-footer-fixture__nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 18px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.aa-chrome-page .aa-chrome-footer-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: inherit;
  transition: color 0.22s ease;
}

.aa-chrome-page .aa-chrome-footer-link:hover:not([aria-current="page"]) {
  opacity: 1;
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-footer-link:not([aria-current="page"]) {
  color: rgba(72, 74, 78, 0.58);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.72),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.16);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-footer-link:not([aria-current="page"]) {
  color: rgba(210, 216, 224, 0.46);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.14),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.38);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-footer-link:not([aria-current="page"]) {
  color: rgba(185, 210, 240, 0.50);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.22),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.34);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-footer-link:not([aria-current="page"]):hover {
  color: rgba(40, 42, 46, 0.82);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-footer-link:not([aria-current="page"]):hover {
  color: rgba(228, 232, 238, 0.72);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-footer-link:not([aria-current="page"]):hover {
  color: rgba(210, 232, 255, 0.72);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-footer-link[aria-current="page"] {
  color: #1f2227;
  animation: aa-chrome-etch-light 3.5s ease-in-out infinite;
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-footer-link[aria-current="page"] {
  color: rgba(238, 232, 222, 0.96);
  animation: aa-chrome-etch-dark 3.5s ease-in-out infinite;
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-footer-link[aria-current="page"] {
  color: rgba(210, 232, 255, 0.98);
  animation: aa-chrome-etch-stellar 3s ease-in-out infinite;
}

.aa-chrome-page .aa-chrome-footer-mission-clock {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 8px;
  max-width: 100%;
  margin: 0 0 14px;
  font-size: var(--aa-chrome-control-font-size);
  font-weight: var(--aa-chrome-control-font-weight);
  letter-spacing: var(--aa-chrome-control-letter-spacing);
  line-height: var(--aa-chrome-control-line-height);
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}

.aa-chrome-page .aa-chrome-footer-mission-clock__segment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 4.5em;
  padding: 5px 9px;
  border-radius: 5px;
  border: 1px solid rgba(127, 140, 155, 0.28);
  background: rgba(127, 140, 155, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.aa-chrome-page .aa-chrome-footer-mission-clock__segment[data-part="time"] {
  min-width: 5.5em;
}

.aa-chrome-page .aa-chrome-footer-mission-clock__sep {
  opacity: 0.42;
  user-select: none;
}

.aa-chrome-page .aa-chrome-footer-mission-clock__zone {
  opacity: 0.52;
  font-size: calc(var(--aa-chrome-control-font-size) * 0.92);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-footer-mission-clock__segment {
  border-color: rgba(156, 158, 162, 0.40);
  background: rgba(255, 255, 255, 0.40);
  color: rgba(40, 42, 46, 0.82);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.72),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.12);
}

html[data-theme="dark"] .aa-chrome-page .aa-chrome-footer-mission-clock__segment {
  border-color: rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(228, 232, 238, 0.84);
  text-shadow:
    0.5px 0.5px 0 rgba(255, 255, 255, 0.12),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.34);
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-footer-mission-clock__segment {
  border-color: rgba(120, 168, 255, 0.18);
  background: rgba(22, 27, 52, 0.34);
  color: rgba(210, 232, 255, 0.88);
  text-shadow:
    0.5px 0.5px 0 rgba(190, 230, 255, 0.18),
    -0.5px -0.5px 0 rgba(0, 0, 0, 0.32);
}

.aa-chrome-page .aa-chrome-footer-fixture__meta {
  margin: 0 0 10px;
  max-width: 36em;
  opacity: 0.72;
}

.aa-chrome-page .aa-chrome-footer-fixture__company,
.aa-chrome-page .aa-chrome-footer-fixture__loc {
  display: block;
}

.aa-chrome-page .aa-chrome-footer-fixture__loc {
  margin-top: 4px;
  opacity: 0.82;
}

.aa-chrome-page .aa-chrome-footer-fixture__label {
  margin: 0;
  max-width: 100%;
  opacity: 0.48;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.aa-chrome-page .aa-chrome-footer-fixture__label code {
  white-space: normal;
  word-break: break-word;
}

html[data-theme="stellar"] .aa-chrome-page .aa-chrome-footer-fixture {
  border-top-color: rgba(120, 168, 255, 0.20);
}

html[data-theme="light"] .aa-chrome-page .aa-chrome-footer-fixture {
  border-top-color: rgba(172, 174, 178, 0.42);
}

@media (prefers-reduced-motion: reduce) {
  .aa-chrome-page .aa-chrome-footer-link[aria-current="page"] {
    animation: none;
  }
}

@media (max-width: 520px) {
  .aa-chrome-page .aa-chrome-polaris-link,
  .aa-chrome-page .aa-chrome-polaris-visual {
    --aa-chrome-polaris-top: max(calc(env(safe-area-inset-top, 0px) + 176px), 192px);
    --aa-chrome-polaris-right: max(calc(env(safe-area-inset-right, 0px) + 16px), 16px);
  }

  .aa-chrome-page .aa-chrome-origin-panel {
    left: max(16px, env(safe-area-inset-left, 0px));
    right: max(16px, env(safe-area-inset-right, 0px));
    width: auto;
  }
}
