/* AI Visibility's own pieces, where Polaris has no component: the
   constellation of samples, run strips, the evidence viewer. Charcoal on
   warm paper with saffron for the brand being found. */
:root {
  --av-ink: #1e1d1b;
  --av-ink-soft: #55524c;
  --av-muted: #85807a;
  --av-paper: #faf8f3;
  --av-line: #e6e1d7;
  --av-saffron: #e0a21a;
  --av-saffron-deep: #9c6b05;
  --av-saffron-soft: #fbefd2;
  --av-night: #23211e;
  --av-serif: 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  --av-sans: Inter, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', Roboto, sans-serif;
}

.av-figure { font-family: var(--av-serif); font-variant-numeric: lining-nums tabular-nums; letter-spacing: -0.01em; }
.av-kicker { margin: 0; font: 600 11px/1.4 var(--av-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--av-saffron); }
:where(.av-prompts a, .av-run-tabs button):focus-visible { outline: 2px solid var(--av-saffron); outline-offset: 2px; border-radius: 6px; }

/* Hero: a dark panel, the headline fraction and the constellation. */
.av-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 28px; align-items: center;
  padding: 30px; border-radius: 18px; color: #f5f1e8;
  background: radial-gradient(90% 120% at 85% 20%, #3a342a, var(--av-night) 60%);
}
.av-hero .av-kicker { color: var(--av-saffron); }
.av-display { margin: 10px 0 0; font: 500 30px/1.2 var(--av-serif); letter-spacing: -0.015em; max-inline-size: 24ch; }
.av-display em { font-style: normal; color: var(--av-saffron); }
.av-hero-note { margin: 12px 0 0; color: #c9c2b5; max-inline-size: 52ch; line-height: 1.55; font-size: 14px; }
.av-legend { display: flex; flex-wrap: wrap; gap: 14px; margin: 16px 0 0; padding: 0; list-style: none; font-size: 12px; color: #c9c2b5; }
.av-legend li { display: inline-flex; align-items: center; gap: 6px; }
.av-legend i { inline-size: 9px; block-size: 9px; border-radius: 50%; display: inline-block; }
.av-legend [data-k='cited'] { background: var(--av-saffron); box-shadow: 0 0 0 2px var(--av-night), 0 0 0 3px var(--av-saffron); }
.av-legend [data-k='mentioned'] { background: var(--av-saffron); }
.av-legend [data-k='absent'] { border: 1.5px solid #8d867a; }
@media (max-width: 720px) { .av-hero { grid-template-columns: 1fr; padding: 22px; } .av-display { font-size: 24px; } .av-constellation { max-inline-size: 220px; margin-inline: auto; } }

.av-constellation { inline-size: 100%; block-size: auto; }
.av-orbit { fill: none; stroke: rgba(245, 241, 232, .08); stroke-width: 1; }
.av-dot { stroke-width: 1.5; }
.av-dot-cited, .av-dot-mentioned { fill: var(--av-saffron); stroke: var(--av-saffron); }
.av-dot-absent { fill: transparent; stroke: #8d867a; }
.av-dot-idle { fill: rgba(245, 241, 232, .14); stroke: none; }
.av-dot-ring { fill: none; stroke: var(--av-saffron); stroke-width: 1.2; opacity: .7; }
.av-dot-failed { stroke: #6e675d; stroke-width: 1.6; stroke-linecap: round; }

/* Run strip: one small bar per run. */
.av-strip { display: inline-flex; align-items: flex-end; gap: 3px; block-size: 26px; }
.av-strip > span { inline-size: 7px; block-size: 100%; border-radius: 3px; background: var(--av-line); display: flex; align-items: flex-end; overflow: hidden; }
.av-strip > span > span { inline-size: 100%; background: var(--av-saffron); border-radius: 3px; }
.av-strip > span > span[data-zero] { background: #c9c2b5; block-size: 3px !important; }
.av-strip > span[data-empty] { opacity: .4; }

.av-fraction { display: inline-flex; align-items: baseline; gap: 6px; }
.av-fraction .av-figure { font-size: 22px; color: var(--av-ink); }
.av-of { color: var(--av-muted); font-size: 13px; }
.av-fraction-label { color: var(--av-ink-soft); font-size: 13px; }

/* Prompt list. */
.av-prompts { border-block-start: 1px solid var(--av-line); }
.av-prompt {
  display: grid; grid-template-columns: minmax(0, 1fr) auto 120px 130px; gap: 18px; align-items: center;
  padding: 14px 16px; border-block-end: 1px solid var(--av-line); color: inherit; text-decoration: none;
}
.av-prompt:last-child { border-block-end: 0; }
a.av-prompt:hover { background: var(--av-paper); }
a.av-prompt:hover .av-prompt-text { color: var(--av-saffron-deep); }
.av-prompt-text { font-weight: 600; color: var(--av-ink); overflow-wrap: anywhere; }
.av-prompt-meta { display: block; margin-block-start: 3px; font-size: 12px; color: var(--av-muted); font-weight: 400; }
@media (max-width: 720px) { .av-prompt { grid-template-columns: 1fr auto; } .av-prompt > :nth-child(2) { display: none; } }

/* Figures. */
.av-figures { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0; padding: 0; list-style: none; }
.av-figures li { padding: 18px 20px 20px; display: grid; gap: 4px; align-content: start; }
.av-figures li + li { border-inline-start: 1px solid var(--av-line); }
.av-figures .av-figure { font-size: 32px; line-height: 1.05; color: var(--av-ink); }
.av-figures [data-accent] .av-figure { color: var(--av-saffron-deep); }
.av-figure-label { font: 600 12px/1.4 var(--av-sans); letter-spacing: .06em; text-transform: uppercase; color: var(--av-ink-soft); }
.av-figure-hint { font-size: 13px; color: var(--av-muted); line-height: 1.45; }
@media (max-width: 720px) { .av-figures { grid-template-columns: 1fr; } .av-figures li + li { border-inline-start: 0; border-block-start: 1px solid var(--av-line); } }

/* Competitor bars. */
.av-bars { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.av-bars li { display: grid; grid-template-columns: 160px 1fr 60px; gap: 12px; align-items: center; font-size: 13px; }
.av-bars b { font-weight: 600; color: var(--av-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.av-bars span { block-size: 8px; border-radius: 999px; background: var(--av-line); overflow: hidden; }
.av-bars span > i { display: block; block-size: 100%; background: var(--av-ink-soft); border-radius: inherit; }
.av-bars [data-own] span > i { background: var(--av-saffron); }
.av-bars em { font-style: normal; text-align: end; color: var(--av-muted); font-variant-numeric: tabular-nums; }

/* Evidence viewer. */
.av-run-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.av-run-tabs button { font: 550 12px/1 var(--av-sans); padding: 7px 12px; border-radius: 999px; cursor: pointer; border: 1px solid var(--av-line); background: #fff; color: var(--av-ink-soft); }
.av-run-tabs button[aria-pressed='true'] { background: var(--av-ink); color: var(--av-paper); border-color: var(--av-ink); }
.av-answer { margin: 0; padding: 16px 18px; border-radius: 12px; background: var(--av-paper); border: 1px solid var(--av-line); white-space: pre-wrap; line-height: 1.6; font-size: 14px; color: var(--av-ink); max-block-size: 420px; overflow: auto; }
.av-answer mark { background: var(--av-saffron-soft); color: inherit; border-radius: 3px; padding: 0 2px; box-shadow: inset 0 -2px 0 var(--av-saffron); }
.av-sources { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 13px; }
.av-sources li { display: grid; grid-template-columns: auto 1fr; gap: 8px; align-items: baseline; }
.av-sources small { color: var(--av-muted); }
.av-source-mark { inline-size: 8px; block-size: 8px; border-radius: 2px; background: var(--av-line); }
.av-sources [data-own] .av-source-mark { background: var(--av-saffron); }
.av-sources a { color: var(--av-ink); overflow-wrap: anywhere; }

.av-price { margin: 0; font-size: 34px; line-height: 1; }
.av-tick { inline-size: 16px; block-size: 16px; color: var(--av-saffron-deep); margin-block-start: 2px; }
.av-step { display: grid; place-items: center; inline-size: 28px; block-size: 28px; border-radius: 50%; font: 600 13px var(--av-sans); border: 1.5px solid var(--av-ink); color: var(--av-ink); }
.av-step[data-done] { background: var(--av-ink); color: var(--av-paper); }

.av-lens { inline-size: 120px; block-size: 84px; }
.av-lens-off { fill: var(--av-line); }
.av-lens-on { fill: var(--av-saffron); }
.av-lens-glass { fill: rgba(255, 255, 255, .5); stroke: var(--av-ink); stroke-width: 2.5; }
.av-lens-handle { stroke: var(--av-ink); stroke-width: 4; stroke-linecap: round; }

.av-pulse { display: inline-block; inline-size: 8px; block-size: 8px; border-radius: 50%; background: var(--av-saffron); animation: av-pulse 1.4s ease-in-out infinite; }
@keyframes av-pulse { 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) { .av-pulse { animation: none; } }
