:root {
  color-scheme: dark;
  --bg: #0d1117;
  --panel: #111820;
  --panel-2: #151e27;
  --text: #e6edf3;
  --muted: #8b949e;
  --line: #2d3742;
  --green: #7ee787;
  --blue: #79c0ff;
  --orange: #ffa657;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.shell {
  width: min(1080px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 56px 0;
}

.doc-page {
  display: grid;
  gap: 20px;
}

.doc-page h1,
.doc-page .panel {
  max-width: 860px;
}

.hero {
  max-width: 760px;
  margin-bottom: 32px;
}

.eyebrow,
pre,
button,
input {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.eyebrow {
  color: var(--green);
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 0;
}

h1 {
  margin: 0;
  font-size: clamp(40px, 6vw, 76px);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  font-size: 18px;
  margin: 0 0 12px;
}

.subhead {
  color: var(--muted);
  font-size: 22px;
  line-height: 1.4;
}

.trust {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  padding: 0;
  list-style: none;
  color: var(--muted);
}

.proof {
  display: grid;
  gap: 8px;
  margin: 24px 0;
  padding-left: 20px;
  color: var(--text);
}

.trust li {
  border-left: 2px solid var(--line);
  padding-left: 12px;
}

.trust-links {
  display: flex;
  gap: 16px;
  margin: 16px 0 0;
}

.trust-links a {
  color: var(--green);
}

.panel,
.report {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 8px;
  padding: 20px;
}

form {
  display: grid;
  gap: 12px;
}

label {
  color: var(--muted);
}

input {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel-2);
  color: var(--text);
}

input[type="checkbox"] {
  width: auto;
  margin-top: 4px;
}

button {
  justify-self: start;
  padding: 12px 16px;
  border: 1px solid var(--green);
  border-radius: 6px;
  background: transparent;
  color: var(--green);
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.command-panel {
  margin-top: 16px;
}

.status-line {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.status-line a {
  color: var(--green);
}

.panel-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.panel-heading h2 {
  margin: 2px 0 0;
}

.panel-heading button {
  flex: 0 0 auto;
}

pre {
  overflow: auto;
  padding: 12px;
  border-radius: 6px;
  background: #080b10;
  color: var(--muted);
}

.command-panel pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

#ecosystem,
#receipt {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.report {
  margin-top: 24px;
  display: grid;
  grid-template-columns: minmax(180px, 240px) 1fr;
  gap: 20px;
}

.expiry {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--green);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.score {
  min-height: 160px;
  display: grid;
  place-items: center;
  align-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0a0f14;
}

.score span {
  font-size: 72px;
  color: var(--orange);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.score small {
  color: var(--muted);
}

#findings {
  display: grid;
  gap: 12px;
  padding-left: 20px;
}

#findings li strong {
  display: block;
}

#findings li span {
  display: inline-block;
  margin: 6px 0;
  color: var(--orange);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

#findings li p {
  margin: 4px 0;
  color: var(--muted);
}

.timeline-caption {
  margin: -4px 0 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.4;
}

.timeline-frame {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 10px;
  align-items: stretch;
}

.timeline-y-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: end;
  padding: 12px 0;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  text-align: right;
}

.timeline {
  position: relative;
  height: 160px;
  display: flex;
  align-items: end;
  gap: 3px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #080b10;
}

.timeline-bar {
  position: relative;
  flex: 1;
  min-width: 3px;
  background: linear-gradient(to top, var(--orange), var(--blue));
  border: 0;
  outline: 0;
}

.timeline-bar:hover,
.timeline-bar:focus {
  background: linear-gradient(to top, #ffbf7a, #9ad0ff);
}

.timeline-bar:focus {
  box-shadow: 0 0 0 2px #080b10, 0 0 0 4px var(--green);
}

.timeline-bar:hover::after,
.timeline-bar:focus::after {
  content: attr(data-tooltip);
  position: absolute;
  z-index: 2;
  left: 50%;
  top: 8px;
  width: max-content;
  max-width: min(360px, calc(100vw - 48px));
  transform: translateX(-50%);
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #d8dee4;
  color: #24292f;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  line-height: 1.35;
  white-space: normal;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.timeline-bar:first-child::after {
  left: 0;
  transform: none;
}

.timeline-bar:last-child::after {
  right: 0;
  left: auto;
  transform: none;
}

.timeline-x-axis {
  display: flex;
  justify-content: space-between;
  margin: 6px 0 0 74px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
}

.timeline-tick-middle {
  text-align: center;
}

.timeline-tick-last {
  text-align: right;
}

.upsell {
  grid-column: 1 / -1;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}

.upsell p {
  max-width: 720px;
  color: var(--muted);
}

.waiver {
  max-width: 820px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  margin: 16px 0;
  color: var(--muted);
  line-height: 1.45;
}

@media (max-width: 720px) {
  .report {
    grid-template-columns: 1fr;
  }

  .panel-heading {
    display: grid;
  }
}

/* Report Intelligence UX sections — kitty-specs/report-intelligence-ux-01KS070G */

.intel-section {
  grid-column: 1 / -1;
  margin: 1.5rem 0;
}
.intel-section[hidden] {
  display: none;
}

/* Workflow Fingerprints */
#workflow-fingerprints-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.fingerprint-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--rule, rgba(255, 255, 255, 0.08));
  font-family: inherit;
}
.fingerprint-confidence {
  font-size: 0.85em;
  padding: 0.05em 0.4em;
  border-radius: 3px;
}
.confidence-high {
  background: rgba(80, 200, 120, 0.18);
}
.confidence-medium {
  background: rgba(240, 200, 80, 0.18);
}
.confidence-low {
  background: rgba(200, 200, 200, 0.18);
}
.fingerprint-sources {
  list-style: none;
  padding: 0;
  margin: 0;
  display: inline-flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}
.fingerprint-sources li {
  font-size: 0.8em;
  padding: 0.05em 0.4em;
  border-radius: 3px;
  background: rgba(120, 160, 255, 0.16);
}
.fingerprint-evidence,
.fingerprint-version {
  font-size: 0.85em;
  opacity: 0.85;
}
.fingerprint-active,
.fingerprint-installed {
  font-size: 0.8em;
  padding: 0.05em 0.4em;
  border-radius: 3px;
  background: rgba(80, 200, 120, 0.18);
}

/* Tooling Utilization */
#tooling-utilization-rows {
  display: grid;
  gap: 0.75rem;
}
.utilization-row {
  display: grid;
  grid-template-columns: minmax(6rem, max-content) 1fr;
  gap: 0.5rem 1rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--rule, rgba(255, 255, 255, 0.08));
}
.utilization-row .surface-header {
  font-weight: 600;
}
.utilization-row .surface-body {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
  align-items: center;
  font-size: 0.9em;
}
.band-chip {
  font-size: 0.8em;
  padding: 0.05em 0.4em;
  border-radius: 3px;
  text-transform: lowercase;
}
.band-severe {
  background: rgba(220, 80, 80, 0.22);
}
.band-high {
  background: rgba(220, 140, 60, 0.22);
}
.band-watch {
  background: rgba(240, 200, 80, 0.22);
}
.band-normal {
  background: rgba(80, 200, 120, 0.18);
}
.band-unknown {
  background: rgba(180, 180, 180, 0.18);
}
.band-advice {
  grid-column: 1 / -1;
  margin-top: 0.4rem;
  padding: 0.5rem 0.75rem;
  background: rgba(220, 140, 60, 0.1);
  border-left: 2px solid rgba(220, 140, 60, 0.55);
  font-size: 0.9em;
}

/* Token-saving recommendation panel — kitty-specs/token-saving-recommendation-phase-b-01KS0JZ4 */
#recommendation-section {
  display: grid;
  gap: 0.75rem;
}
.recommendation-card {
  display: grid;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel-2);
}
.recommendation-tool {
  font-weight: 600;
  font-size: 1.05em;
}
.recommendation-savings-bucket {
  justify-self: start;
  font-size: 0.8em;
  padding: 0.05em 0.5em;
  border-radius: 3px;
  background: rgba(120, 160, 255, 0.18);
  color: var(--blue);
}
.recommendation-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
  align-items: center;
  font-size: 0.9em;
  color: var(--muted);
}
.recommendation-reason,
.recommendation-confidence,
.recommendation-risk,
.recommendation-policy {
  font-size: 0.85em;
  padding: 0.05em 0.4em;
  border-radius: 3px;
  background: rgba(180, 180, 180, 0.12);
}
.recommendation-signals {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.recommendation-signal {
  font-size: 0.8em;
  padding: 0.05em 0.4em;
  border-radius: 3px;
  background: rgba(80, 200, 120, 0.16);
}
#recommendation-empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.9em;
}
