:root {
  --ink: #111114;
  --ink-soft: #33403F;
  --grey: #6B7280;
  --grey-light: #9CA8A7;
  --line: #E1E9E7;
  --line-soft: #EDF4F2;
  --bg: #FFFFFF;
  --panel: #F7FAF9;
  --accent: #0F3D3E;
  --accent-mid: #146B65;
  --accent-contrast: #FFFFFF;
  --yellow: #F5C518;
  --yellow-dark: #8A6200;
  --yellow-soft: #FEF7DC;
  --good: #1E7A46;
  --good-soft: #EAF6EF;
  --warn: #8A6200;
  --warn-soft: #FBF3DF;
  --bad: #A32626;
  --bad-soft: #FBEAEA;
  --radius: 10px;
  --radius-sm: 7px;
  --shadow-sm: 0 1px 2px rgba(15, 61, 62, 0.06);
  --shadow-md: 0 2px 10px rgba(15, 61, 62, 0.08);
  --container: 1040px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  max-width: var(--container);
  margin: 0 auto;
  padding: 64px 24px 96px;
}

.hero-section {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
  padding: 40px 0 32px;
}

.brand-mark {
  display: inline-flex;
  margin-bottom: 18px;
}

.hero-section h1 {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--accent);
}

.subtitle {
  color: var(--grey);
  font-size: 14px;
  margin: 8px 0 32px;
  text-align: justify;
  text-align-last: center;
}

.search-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.search-field {
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 3px 6px 3px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.search-field:focus-within {
  border-color: var(--accent-mid);
  box-shadow: 0 0 0 3px rgba(20, 107, 101, 0.12);
}

.search-icon {
  color: var(--grey-light);
  flex-shrink: 0;
}

.search-field input {
  flex: 1;
  border: none;
  outline: none;
  padding: 13px 0;
  font-size: 15px;
  font-family: inherit;
  background: transparent;
  color: var(--ink);
}

.search-field input::placeholder {
  color: var(--grey-light);
}

.search-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-contrast);
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.05s ease;
}

.search-submit:hover {
  opacity: 0.88;
}

.search-submit:active {
  transform: translateY(1px);
}

.mode-toggle {
  display: inline-flex;
  padding: 3px;
  background: var(--panel);
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  gap: 2px;
}

.mode-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mode-toggle label {
  padding: 7px 18px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--grey);
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.mode-toggle input:checked + label {
  background: var(--accent);
  color: #FFFFFF;
  box-shadow: var(--shadow-sm);
}

.back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 32px;
  color: var(--grey);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: color 0.15s ease;
}

.back:hover {
  color: var(--accent);
}

.report {
  max-width: 100%;
}

.report-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.2px;
}

.report-head {
  margin-bottom: 28px;
}

.report-head-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--accent-mid);
}

.status-pill {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2px;
  padding: 3px 10px;
  border-radius: 999px;
}

.status-good { color: var(--good); background: var(--good-soft); }
.status-mid  { color: var(--warn); background: var(--warn-soft); }
.status-low  { color: var(--bad);  background: var(--bad-soft); }

.company-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.company-logo {
  border-radius: 8px;
  border: 1px solid var(--line);
  object-fit: contain;
  background: var(--bg);
  flex-shrink: 0;
}

.report-head h1 {
  font-size: 26px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.3px;
}

.summary-block {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  padding: 24px 0;
  margin-bottom: 8px;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.score-figure {
  display: flex;
  align-items: baseline;
  gap: 3px;
  flex-shrink: 0;
  min-width: 96px;
}

.score-figure-num {
  font-size: 46px;
  font-weight: 800;
  line-height: 1;
  color: var(--accent);
  letter-spacing: -1px;
}

.score-figure-max {
  font-size: 14px;
  color: var(--grey-light);
  font-weight: 500;
}

.summary-body {
  flex: 1;
  padding-top: 4px;
  min-width: 0;
}

.summary-tier {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--tier-color, var(--accent));
}

.summary-insight {
  font-size: 14.5px;
  color: var(--ink-soft);
  line-height: 1.7;
  text-align: justify;
}

.hl {
  background: var(--yellow-soft);
  color: var(--yellow-dark);
  font-weight: 600;
  padding: 0 3px;
  border-radius: 3px;
}

.meta-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin: 20px 0;
}

.meta-strip-item {
  background: var(--bg);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.meta-strip-label {
  font-size: 11px;
  color: var(--grey);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.meta-strip-val {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent);
}

.note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 0 10px 10px 0;
  margin: 14px 0;
  font-size: 13px;
  text-align: justify;
}

.note svg {
  flex-shrink: 0;
  margin-top: 2px;
}

.note-warn {
  color: var(--warn);
  background: var(--warn-soft);
  border-left: 4px solid var(--yellow);
}

.note-bad {
  color: var(--bad);
  background: var(--bad-soft);
  border-left: 4px solid var(--bad);
}

.note-good {
  color: var(--good);
  background: var(--good-soft);
  border-left: 4px solid var(--good);
}

.report-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 40px;
  align-items: start;
  margin-top: 24px;
}

.report-main {
  min-width: 0;
}

.report-side {
  min-width: 0;
  position: sticky;
  top: 24px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.section {
  margin-bottom: 36px;
}

.section:last-child {
  margin-bottom: 0;
}

.section h2 {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1px;
  margin-bottom: 12px;
}

.section-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.section-head-row h2 {
  margin-bottom: 0;
}

.tag {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink-soft);
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  background: var(--bg);
  text-align: justify;
}

.panel-flush {
  padding: 0;
  overflow: hidden;
}

.panel-footnote {
  font-size: 12px;
  color: var(--grey);
  line-height: 1.6;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
  text-align: justify;
}

.panel-footnote-padded {
  margin: 0;
  padding: 14px 20px;
}

.bar-row {
  display: grid;
  grid-template-columns: 170px 1fr 52px;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
}

.bar-row-detailed {
  padding: 10px 0;
}

.bar-row-detailed + .bar-row-detailed {
  border-top: 1px solid var(--line-soft);
}

.bar-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
  padding-left: 182px;
}

.conf-pill {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--accent-mid);
  background: var(--good-soft);
  border: 1px solid #cfe9df;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.weight-pill {
  font-size: 10.5px;
  font-weight: 500;
  color: var(--grey);
  background: transparent;
  border: 1px dashed var(--line);
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.evidence-line {
  font-size: 12px;
  color: var(--grey);
  flex: 1;
  min-width: 200px;
  text-align: justify;
}

.bar-label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-soft);
}

.bar-track {
  background: var(--line-soft);
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
}

.bar-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent) 0%, var(--accent-mid) 100%);
}

.bar-value {
  font-size: 12px;
  color: var(--grey);
  text-align: right;
  font-weight: 600;
}

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  margin-top: 14px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

th, td {
  padding: 11px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line-soft);
  vertical-align: top;
}

td {
  text-align: justify;
}

thead th {
  background: var(--panel);
  color: var(--accent-mid);
  font-weight: 700;
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

tbody tr:last-child td {
  border-bottom: none;
}

tbody tr:hover {
  background: var(--panel);
}

.col-narrow {
  text-align: center;
  width: 56px;
}

.col-criterion {
  min-width: 180px;
}

td.confirm {
  color: var(--warn);
  background: var(--warn-soft);
  font-style: italic;
}

.downloads {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dl {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 14px;
  background: var(--panel);
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.dl:hover {
  border-color: var(--accent-mid);
  background: var(--bg);
  color: var(--accent);
}

.links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.link-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 14px;
  background: var(--panel);
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.link-item:hover {
  border-color: var(--accent-mid);
  background: var(--bg);
}

.link-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.link-relevance {
  font-size: 11.5px;
  color: var(--grey);
}

.meta-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-soft);
}

.meta-row:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.meta-key {
  font-size: 12px;
  color: var(--grey);
}

.meta-val {
  font-size: 12.5px;
  color: var(--accent);
  font-weight: 700;
  text-align: right;
}

.pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-mid);
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 2px 10px;
  border-radius: 999px;
  margin: 2px 3px 2px 0;
}

.pill-green {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: var(--good);
  background: var(--good-soft);
  border: 1px solid #bfe3cd;
  padding: 2px 10px;
  border-radius: 999px;
  margin: 2px 3px 2px 0;
}

.evidence {
  font-size: 12px;
  color: var(--grey);
  margin-top: 4px;
  line-height: 1.5;
  text-align: justify;
}

.cite, .cite-plain {
  font-size: 12px;
  font-weight: 600;
}

.cite {
  color: var(--accent-mid);
}

.cite-plain {
  color: var(--grey);
}

ul {
  list-style: none;
}

ul li {
  padding: 10px 0;
  border-bottom: 1px solid var(--line-soft);
  font-size: 13px;
}

ul li:last-child {
  border-bottom: none;
}

.none {
  color: var(--grey-light);
  font-size: 13px;
  font-style: italic;
}

.footnote {
  font-size: 11.5px;
  color: var(--grey-light);
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px solid var(--line-soft);
  text-align: justify;
  text-align-last: center;
}

.skeleton {
  animation: skeleton-fade-in 0.15s ease;
  margin-top: 24px;
}

.loading-joke {
  margin-bottom: 18px;
  text-align: center;
}

.loading-joke-text {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-mid);
  background: var(--good-soft);
  border: 1px solid #cfe9df;
  padding: 7px 16px;
  border-radius: 999px;
}

.skeleton-box {
  border-radius: 7px;
  background: linear-gradient(
    100deg,
    var(--line-soft) 30%,
    #E2ECE9 45%,
    var(--line-soft) 60%
  );
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.4s ease-in-out infinite;
}

.skeleton-scorecard {
  display: flex;
  gap: 20px;
  align-items: stretch;
  margin-bottom: 32px;
  padding: 20px 0;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.skeleton-scorebox {
  width: 88px;
  min-height: 60px;
  border-radius: var(--radius-sm);
}

.skeleton-lines {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}

.skeleton-line {
  height: 11px;
}

.skeleton-heading {
  height: 14px;
  margin: 28px 0 14px;
}

.skeleton-bars {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 8px;
}

.skeleton-bar {
  display: flex;
  align-items: center;
  gap: 12px;
}

.skeleton-table {
  height: 200px;
  border-radius: var(--radius);
}

.skeleton-hint {
  margin-top: 18px;
  font-size: 13px;
  color: var(--grey);
  text-align: justify;
  text-align-last: center;
}

@keyframes skeleton-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

@keyframes skeleton-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.ff-error {
  border: 1px solid #f3c2c2;
  background: #fdf2f2;
  border-radius: 12px;
  padding: 18px 20px;
  margin-top: 16px;
}

.ff-error strong {
  display: block;
  color: #9c1c1c;
  margin-bottom: 6px;
}

.ff-error p {
  color: #7a2b2b;
  font-size: 13px;
  text-align: justify;
}

#result.is-loading {
  pointer-events: none;
}

.source-link {
  position: relative;
}

.source-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  margin-right: 8px;
  background: var(--line);
  flex-shrink: 0;
}

.source-link-found .source-dot {
  background: var(--good);
}

.source-link-missing .source-dot {
  background: var(--line);
}

.source-link-missing {
  opacity: 0.6;
  pointer-events: none;
}

.topnav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  border-bottom: 1px solid var(--line-soft);
  background: var(--bg);
}

.topnav-brand {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--accent);
  letter-spacing: -0.2px;
}

.topnav-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.topnav-link {
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--grey);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: color 0.15s ease;
}

.topnav-link:hover {
  color: var(--accent);
}

.topnav-signup {
  background: var(--accent);
  color: var(--accent-contrast);
  padding: 7px 14px;
  border-radius: 999px;
}

.topnav-signup:hover {
  color: var(--accent-contrast);
  opacity: 0.88;
}

.topnav-email {
  font-size: 0.85rem;
  color: var(--grey-light);
}

.topnav-logout-form {
  margin: 0;
  display: inline;
}

nav.topnav .topnav-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

nav.topnav a.topnav-brand {
  text-decoration: none;
  border-bottom: none;
}

nav.topnav button.topnav-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  margin: 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink-soft);
  cursor: pointer;
  box-shadow: none;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

nav.topnav button.topnav-back:hover {
  border-color: var(--accent-mid);
  background: var(--bg);
  color: var(--accent);
}

nav.topnav button.topnav-back svg {
  display: block;
}

.suggest-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  z-index: 20;
}

.suggest-dropdown.open {
  display: block;
}

.suggest-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: pointer;
}

.suggest-row:hover,
.suggest-row.active {
  background: var(--panel);
}

.suggest-logo {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  object-fit: contain;
  flex-shrink: 0;
}

.suggest-logo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--panel);
  color: var(--grey);
  font-size: 0.72rem;
  font-weight: 700;
}

.suggest-name {
  flex: 1;
  font-size: 0.9rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
}

.suggest-tier {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--tier-color, var(--accent-mid));
  border: 1px solid var(--tier-color, var(--accent-mid));
  border-radius: 999px;
  padding: 1px 8px;
}

.suggest-score {
  font-size: 0.75rem;
  color: var(--grey);
}

.auth-section {
  max-width: 380px;
  margin: 64px auto;
  padding: 0 20px;
}

.auth-section h1 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--accent);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 20px;
}

.auth-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink-soft);
  margin-top: 10px;
}

.auth-input {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--ink);
  background: var(--bg);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-input:focus {
  outline: none;
  border-color: var(--accent-mid);
  box-shadow: 0 0 0 3px rgba(20, 107, 101, 0.12);
}

.auth-submit {
  margin-top: 18px;
  padding: 12px;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--accent-contrast);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.05s ease;
}

.auth-submit:hover {
  opacity: 0.88;
}

.auth-submit:active {
  transform: translateY(1px);
}

.auth-switch {
  margin-top: 16px;
  font-size: 0.85rem;
  color: var(--grey);
}

.auth-switch a {
  color: var(--accent-mid);
  font-weight: 600;
  text-decoration: none;
}

.auth-switch a:hover {
  text-decoration: underline;
}

.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.auth-card {
  width: 100%;
  max-width: 380px;
  text-align: center;
}

.auth-title {
  font-size: 28px;
  font-weight: 800;
  margin: 0 0 8px;
}

.auth-subtitle {
  color: var(--grey);
  margin: 0 0 24px;
  font-size: 15px;
}

.auth-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px 20px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}

.auth-google-btn:hover {
  background: var(--panel);
  box-shadow: var(--shadow-sm);
}

.auth-google-icon {
  flex-shrink: 0;
}

.history-section {
  max-width: 780px;
  margin: 40px auto;
  padding: 0 20px;
}

.history-section h1 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--accent);
}

.history-search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 9px 14px;
  margin: 18px 0;
  background: var(--bg);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.history-search-field:focus-within {
  border-color: var(--accent-mid);
  box-shadow: 0 0 0 3px rgba(20, 107, 101, 0.12);
}

.history-search-field .search-icon {
  color: var(--grey-light);
  flex-shrink: 0;
}

#history-filter {
  border: none;
  outline: none;
  flex: 1;
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--ink);
  background: transparent;
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.history-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.history-row:hover {
  background: var(--panel);
  border-color: var(--accent-mid);
}

.history-logo {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  object-fit: contain;
  flex-shrink: 0;
}

.history-logo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--panel);
  color: var(--grey);
  font-weight: 700;
  font-size: 0.85rem;
}

.history-row-main {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.history-row-name {
  font-weight: 600;
  font-size: 0.94rem;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-row-meta {
  font-size: 0.78rem;
  color: var(--grey-light);
}

.history-row-tier {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--tier-color, var(--accent-mid));
  border: 1px solid var(--tier-color, var(--accent-mid));
  border-radius: 999px;
  padding: 2px 9px;
  flex-shrink: 0;
}

.history-row-score {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink-soft);
  flex-shrink: 0;
}

.tag-confirmed {
  background: #E6F5F3;
  color: #146B65;
  border: 1px solid #B7E4DF;
}

.tag-probable {
  background: #FEF7DC;
  color: #8A6200;
  border: 1px solid #F1DFA0;
}

.tag-estimate {
  background: #FEF3E7;
  color: #B4530A;
  border: 1px solid #F2CFA6;
  margin-left: 0;
  margin-right: 6px;
}

.panel-footnote-inline {
  font-size: 0.8rem;
  color: var(--grey);
  font-style: italic;
  margin-left: 6px;
}

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

  .report-side {
    position: static;
  }

  .meta-strip {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  main {
    padding: 40px 18px 72px;
  }

  .hero-section {
    padding: 24px 0 28px;
  }

  .hero-section h1 {
    font-size: 22px;
  }

  .report-head h1 {
    font-size: 21px;
  }

  .summary-block {
    flex-direction: column;
    gap: 14px;
  }

  .score-figure-num {
    font-size: 38px;
  }

  .bar-row {
    grid-template-columns: 100px 1fr 44px;
    gap: 8px;
  }

  .bar-meta {
    padding-left: 0;
  }

  th, td {
    padding: 9px 12px;
  }

  .section {
    margin-bottom: 32px;
  }

  .meta-strip {
    grid-template-columns: 1fr;
  }

  .topnav {
    padding: 14px 18px;
  }
}