:root {
  --atlas-ask-bg: #f8fcff;
  --atlas-ask-panel: #ffffff;
  --atlas-ask-panel-2: #edf7fb;
  --atlas-ask-ink: #0b1824;
  --atlas-ask-muted: #50677a;
  --atlas-ask-line: rgba(7, 118, 155, 0.24);
  --atlas-ask-cyan: #08789c;
  --atlas-ask-green: #08785d;
  --atlas-ask-gold: #9a6900;
}

html[data-theme="dark"] {
  --atlas-ask-bg: #031019;
  --atlas-ask-panel: #061925;
  --atlas-ask-panel-2: #092332;
  --atlas-ask-ink: #f4fbff;
  --atlas-ask-muted: #a8bfcc;
  --atlas-ask-line: rgba(86, 222, 237, 0.25);
  --atlas-ask-cyan: #62e6f4;
  --atlas-ask-green: #43dda9;
  --atlas-ask-gold: #f0bd55;
}

.atlas-ask-trigger {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 48px;
  min-height: 48px;
  margin: 0;
  padding: 10px 14px;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--atlas-ask-cyan) 10%, var(--atlas-ask-panel));
  color: var(--atlas-ask-cyan);
  cursor: pointer;
  font: 800 11px/1.1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  transition: transform 100ms ease, border-color 180ms ease, background 180ms ease;
}

.atlas-ask-trigger:hover,
.atlas-ask-trigger:focus-visible {
  border-color: color-mix(in srgb, var(--atlas-ask-cyan) 72%, transparent);
  background: color-mix(in srgb, var(--atlas-ask-cyan) 17%, var(--atlas-ask-panel));
  outline: 2px solid color-mix(in srgb, var(--atlas-ask-cyan) 45%, transparent);
  outline-offset: 2px;
}

.atlas-ask-trigger:active { transform: scale(0.97); }
.atlas-ask-trigger svg { width: 20px; height: 20px; flex: 0 0 auto; }
.atlas-ask-trigger > b[data-atlas-ask-memory-count-label] {
  flex: 0 0 auto;
  margin-left: auto;
  padding: 4px 6px;
  border: 1px solid color-mix(in srgb, var(--atlas-ask-green) 46%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--atlas-ask-green) 9%, var(--atlas-ask-panel));
  color: var(--atlas-ask-green);
  font: 900 8px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .06em;
  white-space: nowrap;
}
.atlas-ask-trigger > b[hidden] { display: none; }
.atlas-ask-trigger--desk { align-self: stretch; margin-inline: auto 0; }
.atlas-reader-command__actions .atlas-ask-trigger--reader { min-width: 58px; }
.atlas-ask-trigger--context {
  width: 100%;
  min-width: 0;
  min-height: 52px;
  justify-content: flex-start;
  overflow: hidden;
  border-left: 3px solid var(--atlas-ask-cyan);
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--atlas-ask-cyan) 16%, var(--atlas-ask-panel)), var(--atlas-ask-panel));
  box-shadow: inset 0 -1px 0 color-mix(in srgb, var(--atlas-ask-cyan) 18%, transparent);
}

.atlas-ask-trigger--context::after {
  content: "Evidence copilot";
  margin-left: auto;
  color: var(--atlas-ask-muted);
  font-size: 8px;
  letter-spacing: .08em;
}
.atlas-ask-trigger--context:not([data-atlas-ask-memory-count="0"])[data-atlas-ask-memory-count]::after { display: none; }

.atlas-ask-scope {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--atlas-ask-line);
  border-left: 3px solid var(--atlas-ask-green);
  border-radius: 8px;
  background: linear-gradient(120deg, color-mix(in srgb, var(--atlas-ask-green) 10%, var(--atlas-ask-panel)), var(--atlas-ask-panel));
}

.atlas-ask-scope header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.atlas-ask-scope header span,
.atlas-ask-scope header b,
.atlas-ask-scope footer { font: 900 8px/1.35 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; text-transform: uppercase; }
.atlas-ask-scope header span { color: var(--atlas-ask-cyan); }
.atlas-ask-scope header b { color: var(--atlas-ask-green); }
.atlas-ask-scope h3 { margin: 0; color: var(--atlas-ask-ink); font-size: 17px; line-height: 1.25; }
.atlas-ask-scope p { margin: 0; color: var(--atlas-ask-ink); font-size: 14px; line-height: 1.55; }
.atlas-ask-scope footer { color: var(--atlas-ask-muted); }

@media (min-width: 1920px) {
  .atlas-ask-scope { padding: 18px; }
  .atlas-ask-scope h3 { font-size: 19px; }
  .atlas-ask-scope p { font-size: 16px; }
}

html[data-theme] body[data-site="atlas"] .atlas-today-actions > button.atlas-ask-trigger--context,
html[data-theme] body[data-site="atlas"] .atlas-watchlist-v1__card > nav > button.atlas-ask-trigger--context,
html[data-theme] body[data-site="atlas"] #atlas-command-archive .atlas-command-run > nav > button.atlas-ask-trigger--context {
  grid-column: 1 / -1;
  border-color: var(--atlas-ask-line) !important;
  border-left: 3px solid var(--atlas-ask-cyan) !important;
  background: linear-gradient(90deg, color-mix(in srgb, var(--atlas-ask-cyan) 16%, var(--atlas-ask-panel)), var(--atlas-ask-panel)) !important;
  color: var(--atlas-ask-cyan) !important;
}

.atlas-ask-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10080;
  border: 0;
  background: rgba(0, 8, 14, 0.68);
  opacity: 0;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: opacity 240ms ease;
}

.atlas-ask-backdrop.is-open { opacity: 1; }

.atlas-ask-drawer {
  position: fixed;
  z-index: 10081;
  top: 12px;
  right: 12px;
  bottom: 12px;
  width: min(780px, calc(100vw - 24px));
  display: grid;
  grid-template-rows: auto auto auto auto auto minmax(0, 1fr) auto;
  overflow: hidden;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background:
    linear-gradient(rgba(8, 120, 156, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(8, 120, 156, 0.055) 1px, transparent 1px),
    var(--atlas-ask-bg);
  background-size: 36px 36px, 36px 36px, auto;
  color: var(--atlas-ask-ink);
  box-shadow: -24px 0 80px rgba(0, 8, 14, 0.42);
  transform: translateX(calc(100% + 32px));
  opacity: 0;
  transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1), opacity 180ms ease;
}

.atlas-ask-drawer.is-open { transform: translateX(0); opacity: 1; }

/* A true 4K desktop needs a wider research surface, not a 780px sliver. */
@media (min-width: 2560px) {
  .atlas-ask-drawer {
    width: min(1120px, calc(100vw - 64px));
  }
}
body.atlas-ask-open { overflow: hidden !important; }

.atlas-ask-head {
  position: relative;
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr) auto 48px;
  align-items: center;
  gap: 16px;
  min-height: 116px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--atlas-ask-line);
  background:
    linear-gradient(110deg, color-mix(in srgb, var(--atlas-ask-cyan) 10%, var(--atlas-ask-panel)), color-mix(in srgb, var(--atlas-ask-panel) 92%, transparent));
}

.atlas-ask-head::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  width: 42%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--atlas-ask-green));
}

.atlas-ask-core {
  position: relative;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  perspective: 360px;
  transform-style: preserve-3d;
}

.atlas-ask-core img {
  position: relative;
  z-index: 3;
  width: 48px;
  height: 48px;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background: #031019;
  object-fit: contain;
  box-shadow: 0 0 24px color-mix(in srgb, var(--atlas-ask-cyan) 15%, transparent);
}
html[data-theme="light"] .atlas-ask-core img { content: url("/img/brand/atlas-pro-full-day-ui.webp"); background: #ffffff; }

.atlas-ask-core__orbit {
  position: absolute;
  border: 1px solid color-mix(in srgb, var(--atlas-ask-cyan) 52%, transparent);
  border-radius: 50%;
  pointer-events: none;
  transform-style: preserve-3d;
}

.atlas-ask-core__orbit--one {
  inset: 5px;
  border-right-color: var(--atlas-ask-green);
  transform: rotateX(64deg) rotateZ(8deg);
  animation: atlasAskOrbitOne 7s linear infinite;
}

.atlas-ask-core__orbit--two {
  inset: 13px 1px;
  border-left-color: var(--atlas-ask-gold);
  transform: rotateY(62deg) rotateZ(-10deg);
  animation: atlasAskOrbitTwo 9s linear infinite;
}

@keyframes atlasAskOrbitOne { to { transform: rotateX(64deg) rotateZ(368deg); } }
@keyframes atlasAskOrbitTwo { to { transform: rotateY(62deg) rotateZ(-370deg); } }

.atlas-ask-head__copy { min-width: 0; }

.atlas-ask-head span,
.atlas-ask-welcome > span,
.atlas-ask-empty > span,
.atlas-ask-answer > header span,
.atlas-ask-gaps h3 {
  display: block;
  color: var(--atlas-ask-cyan);
  font: 900 10px/1.3 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.atlas-ask-head h1 {
  margin: 6px 0 5px;
  color: var(--atlas-ask-ink);
  font: 800 clamp(22px, 3vw, 34px)/1.08 Inter, Arial, sans-serif;
  letter-spacing: 0;
}

.atlas-ask-head p { margin: 0; color: var(--atlas-ask-muted); font-size: 14px; line-height: 1.45; }
.atlas-ask-file-id {
  min-width: 92px;
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 7px;
  background: color-mix(in srgb, var(--atlas-ask-panel-2) 86%, transparent);
}
.atlas-ask-file-id span { color: var(--atlas-ask-muted); font: 800 8px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .1em; text-transform: uppercase; }
.atlas-ask-file-id strong { color: var(--atlas-ask-cyan); font: 900 14px/1.1 ui-monospace, SFMono-Regular, Menlo, monospace; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.atlas-ask-head button {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background: var(--atlas-ask-panel-2);
  color: var(--atlas-ask-ink);
  cursor: pointer;
  display: grid;
  place-items: center;
}
.atlas-ask-head button svg { width: 22px; height: 22px; }

.atlas-ask-mode {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  min-height: 58px;
  margin: 0;
  padding: 0;
  border-bottom: 1px solid var(--atlas-ask-line);
  background: var(--atlas-ask-line);
}
.atlas-ask-mode > div { min-width: 0; display: grid; align-content: center; gap: 4px; padding: 9px 14px; background: color-mix(in srgb, var(--atlas-ask-panel) 96%, transparent); }
.atlas-ask-mode dt { display: flex; align-items: center; gap: 7px; color: var(--atlas-ask-muted); font: 800 8px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; text-transform: uppercase; }
.atlas-ask-mode dd { min-width: 0; margin: 0; color: var(--atlas-ask-cyan); font: 900 11px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; overflow: hidden; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.atlas-ask-mode i { width: 7px; height: 7px; border-radius: 50%; background: var(--atlas-ask-green); box-shadow: 0 0 14px color-mix(in srgb, var(--atlas-ask-green) 65%, transparent); }

.atlas-ask-phase {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 24px;
  border-bottom: 1px solid var(--atlas-ask-line);
  background: color-mix(in srgb, var(--atlas-ask-panel-2) 58%, var(--atlas-ask-panel));
}
.atlas-ask-phase > span { min-width: 0; display: flex; align-items: center; gap: 9px; }
.atlas-ask-phase > span i {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--atlas-ask-cyan);
  box-shadow: 0 0 14px color-mix(in srgb, var(--atlas-ask-cyan) 50%, transparent);
}
.atlas-ask-phase b {
  min-width: 0;
  color: var(--atlas-ask-muted);
  font: 900 9px/1.25 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .08em;
  overflow: hidden;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}
.atlas-ask-phase button,
.atlas-ask-empty button[data-atlas-ask-retry] {
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--atlas-ask-cyan);
  border-radius: 8px;
  background: transparent;
  color: var(--atlas-ask-cyan);
  cursor: pointer;
  font: 900 9px/1.15 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.atlas-ask-phase button[hidden] { display: none; }
.atlas-ask-drawer[data-atlas-ask-phase="completed"] .atlas-ask-phase > span i { background: var(--atlas-ask-green); box-shadow: 0 0 14px color-mix(in srgb, var(--atlas-ask-green) 56%, transparent); }
.atlas-ask-drawer[data-atlas-ask-phase="held"] .atlas-ask-phase > span i,
.atlas-ask-drawer[data-atlas-ask-phase="failed"] .atlas-ask-phase > span i { background: var(--atlas-ask-gold); box-shadow: none; }
.atlas-ask-drawer[data-atlas-ask-phase="connecting"] .atlas-ask-phase > span i,
.atlas-ask-drawer[data-atlas-ask-phase="reviewing"] .atlas-ask-phase > span i { animation: atlasAskPhasePulse 1100ms ease-in-out infinite alternate; }
@keyframes atlasAskPhasePulse { to { opacity: .45; transform: scale(.72); } }

.atlas-ask-prompts {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 14px 24px 8px;
  scrollbar-width: thin;
  scroll-snap-type: x proximity;
}

.atlas-ask-prompts button {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 999px;
  background: var(--atlas-ask-panel);
  color: var(--atlas-ask-muted);
  cursor: pointer;
  font: 800 10px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.06em;
  scroll-snap-align: start;
}

.atlas-ask-prompts button:hover,
.atlas-ask-prompts button:focus-visible { border-color: var(--atlas-ask-cyan); color: var(--atlas-ask-cyan); outline: none; }
.atlas-ask-prompts button[hidden] { display: none !important; }

.atlas-ask-form { padding: 10px 24px 16px; }
.atlas-ask-form label { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 7px; color: var(--atlas-ask-muted); font: 800 10px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.11em; text-transform: uppercase; }
.atlas-ask-form label small { color: var(--atlas-ask-green); font: inherit; font-size: 8px; letter-spacing: 0.06em; text-align: right; }
.atlas-ask-form label small[hidden] { display: none; }
.atlas-ask-form > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.atlas-ask-form textarea {
  width: 100%;
  min-height: 54px;
  resize: vertical;
  padding: 13px 14px;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background: var(--atlas-ask-panel);
  color: var(--atlas-ask-ink);
  font: 500 15px/1.45 Inter, Arial, sans-serif;
}
.atlas-ask-form textarea:focus { border-color: var(--atlas-ask-cyan); outline: 2px solid color-mix(in srgb, var(--atlas-ask-cyan) 25%, transparent); }
.atlas-ask-form button {
  min-width: 92px;
  min-height: 54px;
  padding: 10px 16px;
  border: 1px solid var(--atlas-ask-cyan);
  border-radius: 8px;
  background: var(--atlas-ask-cyan);
  color: var(--atlas-ask-bg);
  cursor: pointer;
  font: 900 11px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.atlas-ask-form button:disabled { opacity: 0.55; cursor: wait; }

.atlas-ask-output { min-height: 0; overflow-y: auto; padding: 0 24px 20px; overscroll-behavior: contain; }
.atlas-ask-output > * + * { margin-top: 12px; }
.atlas-ask-welcome,
.atlas-ask-empty,
.atlas-ask-answer {
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--atlas-ask-panel) 94%, transparent);
}
.atlas-ask-welcome,
.atlas-ask-empty { padding: 28px; }
.atlas-ask-welcome {
  display: grid;
  grid-template-columns: minmax(210px, .8fr) minmax(0, 1.2fr);
  gap: 22px;
  align-items: center;
  padding: 18px;
  overflow: hidden;
}
.atlas-ask-welcome__copy { min-width: 0; }
.atlas-ask-evidence-field {
  min-height: 178px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--atlas-ask-line);
  border-radius: 8px;
  background:
    linear-gradient(rgba(8, 120, 156, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(8, 120, 156, .055) 1px, transparent 1px),
    color-mix(in srgb, var(--atlas-ask-panel-2) 74%, transparent);
  background-size: 28px 28px, 28px 28px, auto;
}
.atlas-ask-evidence-field__head { display: flex; justify-content: space-between; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--atlas-ask-line); }
.atlas-ask-evidence-field__head span,
.atlas-ask-evidence-field__head b { font: 900 8px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; text-transform: uppercase; }
.atlas-ask-evidence-field__head span { color: var(--atlas-ask-cyan); }
.atlas-ask-evidence-field__head b { color: var(--atlas-ask-green); }
.atlas-ask-evidence-field__map { position: relative; min-height: 132px; display: grid; place-items: center; perspective: 380px; }
.atlas-ask-evidence-field__map::before,
.atlas-ask-evidence-field__map::after { content: ""; position: absolute; left: 50%; top: 50%; background: var(--atlas-ask-line); transform: translate(-50%, -50%); }
.atlas-ask-evidence-field__map::before { width: 76%; height: 1px; }
.atlas-ask-evidence-field__map::after { width: 1px; height: 72%; }
.atlas-ask-evidence-field__map > strong { position: relative; z-index: 4; width: 54px; height: 54px; display: grid; place-items: center; border: 1px solid var(--atlas-ask-cyan); border-radius: 8px; background: var(--atlas-ask-panel); color: var(--atlas-ask-ink); font: 900 11px/1 ui-monospace, monospace; box-shadow: 0 0 24px color-mix(in srgb, var(--atlas-ask-cyan) 12%, transparent); }
.atlas-ask-evidence-field__orbit { position: absolute; width: 128px; height: 78px; border: 1px solid var(--atlas-ask-line); border-radius: 50%; transform-style: preserve-3d; }
.atlas-ask-evidence-field__orbit--one { transform: rotate(-18deg) rotateX(58deg); }
.atlas-ask-evidence-field__orbit--two { border-color: color-mix(in srgb, var(--atlas-ask-green) 38%, transparent); transform: rotate(64deg) rotateX(60deg); }
.atlas-ask-evidence-node { position: absolute; z-index: 5; min-width: 48px; min-height: 30px; display: grid; place-items: center; padding: 5px 8px; border: 1px solid var(--atlas-ask-line); border-radius: 999px; background: var(--atlas-ask-panel); color: var(--atlas-ask-muted); font: 800 7px/1 ui-monospace, monospace; letter-spacing: .06em; text-transform: uppercase; }
.atlas-ask-evidence-node--claims { left: 9%; top: 18%; color: var(--atlas-ask-cyan); }
.atlas-ask-evidence-node--sources { right: 7%; top: 24%; border-color: color-mix(in srgb, var(--atlas-ask-gold) 50%, transparent); color: var(--atlas-ask-gold); }
.atlas-ask-evidence-node--gaps { right: 18%; bottom: 8%; color: var(--atlas-ask-green); }
.atlas-ask-welcome h2,
.atlas-ask-empty h2 { margin: 8px 0 10px; color: var(--atlas-ask-ink); font: 800 clamp(20px, 3vw, 28px)/1.15 Inter, Arial, sans-serif; letter-spacing: 0; }
.atlas-ask-welcome p,
.atlas-ask-empty p { margin: 0; color: var(--atlas-ask-muted); font-size: 15px; line-height: 1.6; }
.atlas-ask-empty a { display: inline-flex; min-height: 46px; align-items: center; margin-top: 18px; padding: 10px 14px; border: 1px solid var(--atlas-ask-cyan); border-radius: 8px; color: var(--atlas-ask-cyan); font: 900 10px/1 ui-monospace, monospace; letter-spacing: 0.1em; text-decoration: none; text-transform: uppercase; }
.atlas-ask-empty button[data-atlas-ask-retry] { margin-top: 18px; background: var(--atlas-ask-cyan); color: var(--atlas-ask-bg); }

.atlas-ask-memory {
  overflow: hidden;
  border: 1px solid var(--atlas-ask-line);
  border-left: 3px solid var(--atlas-ask-green);
  border-radius: 8px;
  background: color-mix(in srgb, var(--atlas-ask-panel) 94%, transparent);
}
.atlas-ask-memory > header { display: flex; align-items: end; justify-content: space-between; gap: 14px; padding: 14px 16px; border-bottom: 1px solid var(--atlas-ask-line); }
.atlas-ask-memory > header span { color: var(--atlas-ask-green); font: 900 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .11em; text-transform: uppercase; }
.atlas-ask-memory > header h3 { margin: 5px 0 0; color: var(--atlas-ask-ink); font: 800 17px/1.2 Inter, Arial, sans-serif; letter-spacing: 0; }
.atlas-ask-memory > header b { flex: 0 0 auto; color: var(--atlas-ask-green); font: 900 9px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; text-transform: uppercase; }
.atlas-ask-memory__items { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--atlas-ask-line); }
.atlas-ask-memory__items button {
  min-width: 0;
  min-height: 68px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 3px 9px;
  align-content: center;
  padding: 11px 13px;
  border: 0;
  background: var(--atlas-ask-panel);
  color: var(--atlas-ask-ink);
  cursor: pointer;
  text-align: left;
}
.atlas-ask-memory__items button:hover,
.atlas-ask-memory__items button:focus-visible { background: color-mix(in srgb, var(--atlas-ask-cyan) 8%, var(--atlas-ask-panel)); outline: 2px solid var(--atlas-ask-cyan); outline-offset: -2px; }
.atlas-ask-memory__items button > span { grid-row: 1 / span 2; color: var(--atlas-ask-cyan); font: 900 10px/1.3 ui-monospace, monospace; }
.atlas-ask-memory__items button > strong { min-width: 0; color: var(--atlas-ask-ink); font: 750 12px/1.35 Inter, Arial, sans-serif; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.atlas-ask-memory__items button > small { min-width: 0; color: var(--atlas-ask-muted); font: 800 8px/1.25 ui-monospace, monospace; letter-spacing: .05em; overflow: hidden; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.atlas-ask-memory > footer { padding: 9px 14px; color: var(--atlas-ask-muted); font: 800 8px/1.35 ui-monospace, monospace; letter-spacing: .07em; text-transform: uppercase; }

.atlas-ask-answer { position: relative; overflow: hidden; animation: atlasAskAnswerIn 420ms cubic-bezier(.16, 1, .3, 1) both; }
.atlas-ask-answer::before { content: ""; position: absolute; z-index: 4; top: 0; left: -35%; width: 34%; height: 2px; background: linear-gradient(90deg, transparent, var(--atlas-ask-green), transparent); animation: atlasAskAnswerSweep 820ms cubic-bezier(.16, 1, .3, 1) both; pointer-events: none; }
@keyframes atlasAskAnswerIn { from { opacity: 0; transform: translateY(10px); } }
@keyframes atlasAskAnswerSweep { to { left: 101%; } }
.atlas-ask-answer > header { display: flex; justify-content: space-between; gap: 12px; padding: 16px 18px 0; }
.atlas-ask-answer > header b { color: var(--atlas-ask-green); font: 800 9px/1.3 ui-monospace, monospace; letter-spacing: 0.09em; text-transform: uppercase; }
.atlas-ask-answer > h2 { margin: 10px 18px 8px; color: var(--atlas-ask-ink); font: 800 clamp(19px, 3vw, 26px)/1.2 Inter, Arial, sans-serif; letter-spacing: 0; overflow-wrap: anywhere; }
.atlas-ask-summary { margin: 0 18px 16px; color: var(--atlas-ask-muted); font-size: 15px; line-height: 1.58; }
.atlas-ask-ledger { display: grid; grid-template-columns: 0.65fr 1fr 0.85fr; margin: 0; border-top: 1px solid var(--atlas-ask-line); border-bottom: 1px solid var(--atlas-ask-line); }
.atlas-ask-ledger div { min-width: 0; padding: 12px 14px; border-right: 1px solid var(--atlas-ask-line); }
.atlas-ask-ledger div:last-child { border-right: 0; }
.atlas-ask-ledger dt { color: var(--atlas-ask-muted); font: 800 8px/1.3 ui-monospace, monospace; letter-spacing: 0.1em; text-transform: uppercase; }
.atlas-ask-ledger dd { margin: 4px 0 0; color: var(--atlas-ask-ink); font: 800 12px/1.3 ui-monospace, monospace; overflow-wrap: anywhere; }
.atlas-ask-claims { display: grid; gap: 10px; padding: 14px; }
.atlas-ask-claim { overflow: hidden; border: 1px solid var(--atlas-ask-line); border-radius: 8px; background: var(--atlas-ask-panel-2); }
.atlas-ask-claim > header { display: flex; justify-content: space-between; gap: 10px; padding: 11px 12px; border-bottom: 1px solid var(--atlas-ask-line); }
.atlas-ask-claim > header span { color: var(--atlas-ask-cyan); font: 900 9px/1.35 ui-monospace, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.atlas-ask-claim > header b { color: var(--atlas-ask-green); font: 800 8px/1.35 ui-monospace, monospace; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.atlas-ask-claim > p { margin: 0; padding: 13px 14px; color: var(--atlas-ask-ink); font-size: 14px; line-height: 1.56; }
.atlas-ask-sources { display: grid; gap: 7px; margin: 0; padding: 0 14px 14px; list-style: none; }
.atlas-ask-sources li { display: grid; gap: 3px; padding: 9px 10px; border-left: 2px solid var(--atlas-ask-gold); background: color-mix(in srgb, var(--atlas-ask-gold) 6%, var(--atlas-ask-panel)); }
.atlas-ask-sources a,
.atlas-ask-sources strong { color: var(--atlas-ask-gold); font: 800 10px/1.35 ui-monospace, monospace; text-decoration: none; overflow-wrap: anywhere; }
.atlas-ask-sources a:hover { text-decoration: underline; }
.atlas-ask-sources span { color: var(--atlas-ask-muted); font-size: 11px; line-height: 1.4; overflow-wrap: anywhere; }
.atlas-ask-gap-note,
.atlas-ask-no-match { margin: 12px 14px !important; padding: 11px 12px !important; border-left: 2px solid var(--atlas-ask-gold); background: color-mix(in srgb, var(--atlas-ask-gold) 7%, transparent); color: var(--atlas-ask-muted) !important; }
.atlas-ask-gaps { display: grid; gap: 8px; padding: 4px 14px 14px; }
.atlas-ask-gaps h3 { margin: 4px 0 0; color: var(--atlas-ask-gold); }
.atlas-ask-gap { padding: 11px 12px; border: 1px solid color-mix(in srgb, var(--atlas-ask-gold) 45%, transparent); border-radius: 8px; background: color-mix(in srgb, var(--atlas-ask-gold) 6%, var(--atlas-ask-panel)); }
.atlas-ask-gap span { color: var(--atlas-ask-gold); font: 800 9px/1.3 ui-monospace, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.atlas-ask-gap p { margin: 6px 0 0; color: var(--atlas-ask-muted); font-size: 13px; line-height: 1.5; }
.atlas-ask-compare-claim[data-change-state="added"] { border-left: 3px solid var(--atlas-ask-green); }
.atlas-ask-compare-claim[data-change-state="changed"] { border-left: 3px solid var(--atlas-ask-cyan); }
.atlas-ask-compare-claim[data-change-state="removed"] { border-left: 3px solid var(--atlas-ask-gold); }
.atlas-ask-compare-before,
.atlas-ask-compare-after { padding: 12px 14px; }
.atlas-ask-compare-before { background: color-mix(in srgb, var(--atlas-ask-muted) 7%, var(--atlas-ask-panel)); }
.atlas-ask-compare-after { border-top: 1px solid var(--atlas-ask-line); background: var(--atlas-ask-panel); }
.atlas-ask-compare-before span,
.atlas-ask-compare-after span,
.atlas-ask-source-deltas h3,
.atlas-ask-source-deltas li > span {
  color: var(--atlas-ask-cyan);
  font: 900 9px/1.35 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.atlas-ask-compare-before p,
.atlas-ask-compare-after p { margin: 6px 0 0; color: var(--atlas-ask-ink); font-size: 14px; line-height: 1.56; }
.atlas-ask-compare-before p { color: var(--atlas-ask-muted); }
.atlas-ask-source-deltas { padding: 0 14px 14px; }
.atlas-ask-source-deltas h3 { margin: 2px 0 9px; color: var(--atlas-ask-gold); }
.atlas-ask-source-deltas ol { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.atlas-ask-source-deltas li {
  display: grid;
  gap: 4px;
  padding: 10px 11px;
  border: 1px solid var(--atlas-ask-line);
  border-left: 3px solid var(--atlas-ask-cyan);
  border-radius: 6px;
  background: var(--atlas-ask-panel-2);
}
.atlas-ask-source-deltas li[data-change-state="added"] { border-left-color: var(--atlas-ask-green); }
.atlas-ask-source-deltas li[data-change-state="removed"] { border-left-color: var(--atlas-ask-gold); }
.atlas-ask-source-deltas li a,
.atlas-ask-source-deltas li strong { color: var(--atlas-ask-ink); font: 800 11px/1.4 ui-monospace, monospace; overflow-wrap: anywhere; text-decoration: none; }
.atlas-ask-source-deltas li a:hover { color: var(--atlas-ask-cyan); text-decoration: underline; }
.atlas-ask-source-deltas li small { color: var(--atlas-ask-muted); font-size: 11px; line-height: 1.4; }
.atlas-ask-answer > footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 14px; border-top: 1px solid var(--atlas-ask-line); }
.atlas-ask-answer > footer span { color: var(--atlas-ask-muted); font: 700 8px/1.4 ui-monospace, monospace; letter-spacing: 0.07em; text-transform: uppercase; }
.atlas-ask-answer > footer button { min-height: 44px; padding: 8px 11px; border: 1px solid var(--atlas-ask-line); border-radius: 8px; background: var(--atlas-ask-panel-2); color: var(--atlas-ask-cyan); cursor: pointer; font: 800 9px/1.2 ui-monospace, monospace; letter-spacing: 0.07em; text-transform: uppercase; }

.atlas-ask-thinking { display: grid; grid-template-columns: 148px minmax(0, 1fr); gap: 20px; align-items: center; min-height: 196px; padding: 22px; border: 1px solid var(--atlas-ask-line); border-radius: 8px; background: var(--atlas-ask-panel); color: var(--atlas-ask-muted); }
.atlas-ask-thinking__core { position: relative; width: 128px; height: 128px; display: grid; place-items: center; border: 1px solid var(--atlas-ask-line); border-radius: 50%; color: var(--atlas-ask-cyan); font: 900 10px/1 ui-monospace, monospace; letter-spacing: .1em; }
.atlas-ask-thinking__core i { position: absolute; width: 104px; height: 62px; border: 1px solid color-mix(in srgb, var(--atlas-ask-cyan) 46%, transparent); border-radius: 50%; background: transparent; }
.atlas-ask-thinking__core i:first-child { transform: rotate(24deg); animation: atlasAskThinkOrbit 2.8s linear infinite; }
.atlas-ask-thinking__core i:nth-child(2) { border-color: color-mix(in srgb, var(--atlas-ask-green) 50%, transparent); transform: rotate(92deg); animation: atlasAskThinkOrbitReverse 3.6s linear infinite; }
.atlas-ask-thinking ol { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.atlas-ask-thinking li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; align-items: center; padding: 10px 12px; border-left: 2px solid var(--atlas-ask-line); background: color-mix(in srgb, var(--atlas-ask-panel-2) 74%, transparent); }
.atlas-ask-thinking li span { color: var(--atlas-ask-cyan); font: 900 9px/1 ui-monospace, monospace; }
.atlas-ask-thinking li b { color: var(--atlas-ask-ink); font: 800 10px/1.2 ui-monospace, monospace; letter-spacing: .04em; text-transform: uppercase; }
.atlas-ask-thinking li i { grid-column: 1 / -1; width: 22%; height: 3px; border: 0; border-radius: 99px; background: var(--atlas-ask-cyan); animation: atlasAskLane 1.6s ease-in-out infinite alternate; }
.atlas-ask-thinking li:nth-child(2) i { animation-delay: 140ms; }
.atlas-ask-thinking li:nth-child(3) i { animation-delay: 280ms; }
@keyframes atlasAskStep { to { background: var(--atlas-ask-cyan); box-shadow: 0 0 18px color-mix(in srgb, var(--atlas-ask-cyan) 55%, transparent); } }
@keyframes atlasAskThinkOrbit { to { transform: rotate(384deg); } }
@keyframes atlasAskThinkOrbitReverse { to { transform: rotate(-268deg); } }
@keyframes atlasAskLane { to { width: 100%; background: var(--atlas-ask-green); } }

.atlas-ask-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 14px 24px calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid var(--atlas-ask-line); background: var(--atlas-ask-panel); }
.atlas-ask-actions button { min-height: 48px; border: 1px solid var(--atlas-ask-line); border-radius: 8px; background: var(--atlas-ask-panel-2); color: var(--atlas-ask-cyan); cursor: pointer; font: 900 10px/1.2 ui-monospace, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.atlas-ask-actions button:last-child { border-color: var(--atlas-ask-cyan); background: var(--atlas-ask-cyan); color: var(--atlas-ask-bg); }

@media (max-width: 820px) {
  .atlas-desk-v4-toolbar .atlas-ask-trigger--desk { grid-column: 1 / -1; width: 100%; margin: 0; }
  .atlas-ask-drawer { top: max(8px, env(safe-area-inset-top)); right: 8px; bottom: 8px; left: 8px; width: auto; transform: translateY(calc(100% + 24px)); }
  .atlas-ask-drawer.is-open { transform: translateY(0); }
  .atlas-ask-head { grid-template-columns: 64px minmax(0, 1fr) 48px; gap: 12px; min-height: 106px; padding: 14px 16px; }
  .atlas-ask-core { grid-column: 1; grid-row: 1; width: 62px; height: 62px; }
  .atlas-ask-core img { width: 42px; height: 42px; }
  .atlas-ask-head__copy { grid-column: 2; grid-row: 1; }
  .atlas-ask-file-id { display: none; }
  .atlas-ask-head > button { grid-column: 3; grid-row: 1; }
  .atlas-ask-mode > div { padding-inline: 10px; }
  .atlas-ask-phase { padding-inline: 16px; }
  .atlas-ask-prompts { padding-inline: 16px; }
  .atlas-ask-form { padding-inline: 16px; }
  .atlas-ask-output {
    padding-right: 16px;
    padding-bottom: 92px;
    padding-left: 16px;
    scroll-padding-bottom: 92px;
  }
  .atlas-ask-actions { padding-inline: 16px; }
  .atlas-ask-memory__items { grid-template-columns: minmax(0, 1fr); }
  .atlas-ask-welcome { grid-template-columns: 138px minmax(0, 1fr); gap: 15px; padding: 14px; }
  .atlas-ask-evidence-field { min-height: 158px; }
  .atlas-ask-evidence-field__head { display: grid; gap: 3px; }
  .atlas-ask-evidence-field__map { min-height: 116px; }
  .atlas-ask-evidence-field__orbit { width: 100px; height: 62px; }
  .atlas-ask-evidence-node { min-width: 38px; min-height: 26px; padding: 4px 6px; font-size: 6px; }
  .atlas-ask-evidence-node--claims { left: 3%; }
  .atlas-ask-evidence-node--sources { right: 2%; }
  .atlas-ask-thinking { grid-template-columns: 112px minmax(0, 1fr); gap: 14px; padding: 18px; }
  .atlas-ask-thinking__core { width: 104px; height: 104px; }
  .atlas-ask-thinking__core i { width: 84px; height: 52px; }
}

@media (max-width: 430px) {
  .atlas-ask-head h1 { font-size: 20px; }
  .atlas-ask-head p { font-size: 12px; }
  .atlas-ask-mode dt { font-size: 7px; }
  .atlas-ask-mode dd { font-size: 9px; }
  .atlas-ask-form > div { grid-template-columns: minmax(0, 1fr) 76px; }
  .atlas-ask-form button { min-width: 0; padding-inline: 8px; }
  .atlas-ask-form button { min-height: 48px; }
  .atlas-ask-phase b { font-size: 8px; }
  .atlas-ask-phase button { padding-inline: 8px; font-size: 8px; }
  .atlas-ask-ledger { grid-template-columns: 0.55fr 1fr; }
  .atlas-ask-ledger div:nth-child(3) { display: none; }
  .atlas-ask-ledger div:nth-child(2) { border-right: 0; }
  .atlas-ask-answer > footer { align-items: stretch; flex-direction: column; }
  .atlas-ask-answer > footer button { width: 100%; }
  .atlas-ask-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .atlas-ask-actions button { padding-inline: 8px; font-size: 8px; }
  .atlas-ask-memory > header { align-items: start; }
}

@media (max-width: 370px) {
  .atlas-ask-welcome { grid-template-columns: minmax(0, 1fr); }
  .atlas-ask-evidence-field { min-height: 142px; }
  .atlas-ask-thinking { grid-template-columns: minmax(0, 1fr); }
  .atlas-ask-thinking__core { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .atlas-ask-trigger,
  .atlas-ask-backdrop,
  .atlas-ask-drawer { transition: none !important; }
  .atlas-ask-core__orbit,
  .atlas-ask-thinking i,
  .atlas-ask-phase > span i,
  .atlas-ask-answer,
  .atlas-ask-answer::before { animation: none !important; }
}
