:root {
  color-scheme: light;
  --ink: #15233f;
  --title: #0e1830;
  --muted: #5f7093;
  --line: rgba(71, 113, 252, 0.14);
  --paper: #ffffff;
  --surface: rgba(248, 250, 255, 0.92);
  --primary: #4771fc;
  --accent: #f87fe6;
  --accent-deep: #3155c9;
  --shadow: 0 24px 70px rgba(64, 88, 150, 0.12);
}

/* Homepage refinement: quieter B2B hierarchy and denser repeated components. */
.home-page {
  background: #f4f6fa;
}

.home-page .site-header {
  border-color: #dde3ef;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 28px rgba(35, 52, 88, 0.08);
}

.home-page .site-nav {
  gap: 20px;
}

.home-page .header-cta,
.home-page .button {
  border-radius: 6px;
}

.home-page .header-cta,
.home-page .button.primary {
  background: var(--primary);
  box-shadow: 0 8px 20px rgba(71, 113, 252, 0.18);
}

.home-page .header-cta:hover,
.home-page .button.primary:hover {
  background: var(--accent-deep);
}

.home-page .hero {
  min-height: 720px;
}

.home-page .hero-overlay {
  background:
    linear-gradient(90deg, rgba(248, 250, 253, 0.99) 0%, rgba(248, 250, 253, 0.92) 46%, rgba(248, 250, 253, 0.3) 100%),
    linear-gradient(0deg, rgba(244, 246, 250, 0.94), rgba(248, 250, 253, 0));
}

.home-page h1 {
  max-width: 720px;
  font-size: 64px;
}

.home-page h2 {
  font-size: 42px;
}

.home-page .hero-copy {
  max-width: 680px;
}

.home-page .hero-metrics div,
.home-page .metric-card,
.home-page .model-panel,
.home-page .process-list,
.home-page .score-summary,
.home-page .score-bars,
.home-page .answer-panel,
.home-page .optimization-grid article,
.home-page .comparison-table,
.home-page .diagnosis-card {
  border-radius: 8px;
}

.home-page .hero-metrics div {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: none;
}

.home-page .section {
  padding-top: 76px;
  padding-bottom: 76px;
}

.home-page .metric-card {
  min-height: 210px;
}

.home-page .model-panel,
.home-page .answer-panel {
  background: #fff;
}

.home-page .score-summary {
  background: var(--primary);
}

.home-page .score-bar::after {
  background: var(--accent-deep);
}

.home-page .live-report-feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: end;
  border-top: 1px solid #dce3f0;
  border-bottom: 1px solid #dce3f0;
}

.home-page .live-report-feature .section-heading {
  margin-bottom: 0;
}

.home-page .report-band {
  background: var(--title);
}

@media (max-width: 920px) {
  .home-page h1 {
    font-size: 52px;
  }

  .home-page .live-report-feature {
    grid-template-columns: 1fr;
    align-items: start;
  }
}

@media (max-width: 620px) {
  .home-page h1 {
    font-size: 40px;
    line-height: 1.08;
  }

  .home-page h2 {
    font-size: 30px;
  }

  .home-page .hero {
    min-height: auto;
  }

  .home-page .section {
    padding-top: 58px;
    padding-bottom: 58px;
  }

  .home-page .metric-card,
  .home-page .model-panel,
  .home-page .optimization-grid article {
    min-height: 0;
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(71, 113, 252, 0.12), transparent 32%),
    radial-gradient(circle at 90% 12%, rgba(248, 127, 230, 0.08), transparent 22%),
    linear-gradient(180deg, #f8fbff 0%, #f4f7ff 48%, #eef4ff 100%);
  font-family:
    "Avenir Next", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(210px, auto) 1fr auto;
  align-items: center;
  gap: 28px;
  width: min(calc(100% - 32px), 1180px);
  min-height: 74px;
  margin: 16px auto 0;
  padding: 0 18px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 999px;
  box-shadow: 0 10px 32px rgba(80, 105, 175, 0.08);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  min-width: 0;
}

.brand-mark {
  display: inline-flex;
  width: 52px;
  height: 38px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.brand-text strong {
  color: var(--title);
  font-size: 15px;
  line-height: 1.2;
  white-space: nowrap;
}

.brand-text span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: 24px;
  color: var(--muted);
  font-size: 14px;
}

.site-nav a:hover {
  color: var(--title);
}

.header-cta,
.button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 700;
  white-space: nowrap;
}

.header-cta,
.button.primary {
  color: white;
  background: linear-gradient(135deg, var(--primary), #6e8dfd 70%);
  box-shadow: 0 12px 28px rgba(71, 113, 252, 0.22);
}

.header-cta:hover,
.button.primary:hover {
  background: linear-gradient(135deg, var(--accent-deep), var(--primary));
}

.button.secondary {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.78);
  border-color: var(--line);
}

.button.dark {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.5);
  color: white;
}

.hero {
  position: relative;
  display: grid;
  min-height: min(760px, 82vh);
  overflow: hidden;
  margin-top: -90px;
  padding-top: 90px;
  background: transparent;
}

.hero-visual {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center right;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(248, 251, 255, 0.98) 0%, rgba(248, 251, 255, 0.9) 44%, rgba(248, 251, 255, 0.42) 100%),
    linear-gradient(0deg, rgba(238, 244, 255, 0.9), rgba(248, 251, 255, 0));
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 86px 0 46px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--primary);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 20px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 1.05;
  letter-spacing: 0;
  color: var(--title);
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.14;
  letter-spacing: 0;
  color: var(--title);
}

h3 {
  margin-bottom: 8px;
  font-size: 21px;
  line-height: 1.25;
}

.hero-copy {
  max-width: 650px;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: 19px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 38px;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 160px));
  gap: 14px;
  margin: 0;
}

.hero-metrics div {
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 18px;
  box-shadow: 0 10px 32px rgba(80, 105, 175, 0.06);
}

.hero-metrics dt {
  font-size: 30px;
  font-weight: 800;
  line-height: 1;
}

.hero-metrics dd {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.section {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 88px 0;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 34px;
}

.section-heading p,
.contact-copy p,
.report-band p {
  color: var(--muted);
  font-size: 18px;
}

.section-heading.compact {
  max-width: 680px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.metric-card,
.model-panel,
.contact-panel {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--paper);
}

.metric-card {
  min-height: 230px;
  padding: 24px;
}

.metric-card p,
.model-panel p,
.process-list p,
.contact-panel p {
  color: var(--muted);
}

.metric-icon {
  display: block;
  width: 42px;
  height: 42px;
  margin-bottom: 18px;
  border-radius: 8px;
}

.metric-icon.visibility {
  background: linear-gradient(135deg, var(--primary), #7f95ff);
}

.metric-icon.ranking {
  background: linear-gradient(135deg, var(--accent), #ffb5f4);
}

.metric-icon.accuracy {
  background: linear-gradient(135deg, #3155c9, #74b3ff);
}

.metric-icon.sentiment {
  background: linear-gradient(135deg, var(--title), var(--accent));
}

.split {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 48px;
  align-items: start;
}

.model-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.model-panel {
  min-height: 310px;
  padding: 28px;
  background: var(--surface);
}

.model-panel ul {
  display: grid;
  gap: 10px;
  margin: 22px 0 0;
  padding-left: 18px;
}

.process {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.process-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
}

.process-list li {
  min-height: 210px;
  padding: 24px;
  background: var(--paper);
}

.process-list li + li {
  border-left: 1px solid var(--line);
}

.process-list span {
  display: inline-block;
  margin-bottom: 22px;
  color: var(--accent-deep);
  font-weight: 800;
}

.process-list strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

.scorecard {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 42px;
  align-items: start;
}

.scorecard .section-heading {
  margin-bottom: 0;
}

.score-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 16px;
}

.score-summary,
.score-bars,
.answer-panel,
.optimization-grid article {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--paper);
}

.score-summary {
  display: grid;
  min-height: 300px;
  align-content: center;
  padding: 28px;
  background:
    linear-gradient(135deg, rgba(71, 113, 252, 0.95), rgba(49, 85, 201, 0.95)),
    var(--primary);
  color: white;
}

.score-summary span {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.score-summary strong {
  display: block;
  margin: 18px 0;
  font-size: 82px;
  line-height: 0.9;
}

.score-summary p {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.82);
}

.score-bars {
  display: grid;
  gap: 16px;
  min-height: 300px;
  padding: 24px;
}

.score-bar {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: end;
  min-height: 54px;
  padding-bottom: 14px;
  color: var(--title);
}

.score-bar::before,
.score-bar::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 8px;
  border-radius: 999px;
  content: "";
}

.score-bar::before {
  background: rgba(71, 113, 252, 0.1);
}

.score-bar::after {
  width: var(--value);
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.score-bar span {
  color: var(--muted);
  font-weight: 700;
}

.score-bar strong {
  font-size: 22px;
}

.comparison-table {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
}

.table-row {
  display: grid;
  grid-template-columns: 1.3fr repeat(3, 1fr);
}

.table-row span {
  min-height: 58px;
  padding: 16px;
  border-top: 1px solid var(--line);
}

.table-row span + span {
  border-left: 1px solid var(--line);
}

.table-head span {
  border-top: 0;
  background: linear-gradient(135deg, var(--title), #213765);
  color: white;
  font-weight: 700;
}

.audit-preview {
  padding-top: 48px;
}

.preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.answer-panel {
  min-height: 360px;
  padding: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 250, 255, 0.9)),
    var(--paper);
}

.answer-panel.domestic {
  border-top: 5px solid var(--primary);
}

.answer-panel.overseas {
  border-top: 5px solid var(--accent);
}

.panel-topline {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 14px;
}

.panel-topline strong {
  color: var(--title);
}

.prompt {
  margin-bottom: 22px;
  color: var(--title);
  font-size: 21px;
  font-weight: 800;
  line-height: 1.35;
}

.answer-panel ul,
.optimization-grid {
  display: grid;
  gap: 14px;
}

.answer-panel li {
  color: var(--muted);
}

.answer-panel li strong {
  color: var(--title);
}

.optimization {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: 48px;
  align-items: start;
}

.optimization .section-heading {
  margin-bottom: 0;
}

.optimization-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.optimization-grid article {
  min-height: 220px;
  padding: 24px;
}

.optimization-grid span {
  color: var(--accent-deep);
  font-weight: 800;
}

.optimization-grid p {
  color: var(--muted);
}

.live-report-feature {
  padding-top: 48px;
}

.live-report-summary {
  display: grid;
  grid-template-columns: 220px minmax(0, 0.9fr) minmax(300px, 1fr);
  gap: 16px;
  align-items: stretch;
}

.live-score-card,
.live-report-stats,
.live-report-copy {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 16px 44px rgba(64, 88, 150, 0.08);
}

.live-score-card {
  display: grid;
  align-content: center;
  padding: 24px;
  color: white;
  background: linear-gradient(135deg, #10213f, #3155c9);
}

.live-score-card span {
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.live-score-card strong {
  margin: 14px 0;
  font-size: 76px;
  line-height: 0.9;
}

.live-score-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
}

.live-report-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  background: var(--line);
}

.live-report-stats div {
  display: grid;
  align-content: center;
  min-height: 112px;
  padding: 18px;
  background: #fff;
}

.live-report-stats strong,
.live-report-stats span {
  display: block;
}

.live-report-stats strong {
  color: var(--primary);
  font-size: 42px;
  line-height: 1;
}

.live-report-stats span {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.live-report-copy {
  display: grid;
  gap: 16px;
  align-content: center;
  padding: 24px;
}

.live-report-copy h3,
.live-report-copy p,
.live-report-copy ul {
  margin: 0;
}

.live-report-copy ul {
  display: grid;
  gap: 8px;
  padding-left: 20px;
  color: var(--muted);
}

.live-report-copy .button {
  justify-self: start;
}

.report-band {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
  width: 100%;
  max-width: none;
  padding: 72px max(24px, calc((100% - 1160px) / 2));
  color: white;
  background: linear-gradient(135deg, var(--title), #213765);
}

.report-band div {
  max-width: 760px;
}

.report-band .eyebrow,
.report-band p {
  color: rgba(255, 255, 255, 0.78);
}

.report-band h2 {
  color: white;
}

.report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.contact {
  display: grid;
  grid-template-columns: 0.72fr 1.28fr;
  gap: 48px;
  align-items: start;
}

.contact-points {
  display: grid;
  gap: 12px;
  margin: 28px 0 0;
  padding-left: 20px;
  color: var(--muted);
}

.diagnosis-card,
.diagnosis-form,
.next-steps article {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
}

.diagnosis-card {
  display: grid;
  gap: 16px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.diagnosis-card strong {
  color: var(--title);
  font-size: 22px;
  line-height: 1.25;
}

.diagnosis-card p {
  margin: 0;
  color: var(--muted);
}

.status-dot {
  width: 10px;
  height: 10px;
  background: var(--primary);
  border-radius: 50%;
}

.diagnosis-page {
  min-height: 100vh;
}

.diagnosis-shell {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  gap: 48px;
  align-items: start;
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 86px 0 96px;
}

.diagnosis-copy {
  position: sticky;
  top: 112px;
}

.diagnosis-copy h1 {
  font-size: clamp(42px, 5vw, 64px);
}

.diagnosis-copy > p {
  color: var(--muted);
  font-size: 18px;
}

.next-steps {
  display: grid;
  gap: 12px;
  margin-top: 28px;
}

.next-steps article {
  padding: 20px;
}

.next-steps span {
  display: block;
  margin-bottom: 10px;
  color: var(--accent-deep);
  font-weight: 800;
}

.next-steps strong {
  display: block;
  margin-bottom: 6px;
  color: var(--title);
}

.next-steps p {
  margin: 0;
  color: var(--muted);
}

.diagnosis-form {
  display: grid;
  gap: 22px;
  padding: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.diagnosis-form fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.diagnosis-form legend {
  margin-bottom: 14px;
  color: var(--title);
  font-size: 18px;
  font-weight: 800;
}

.field-note {
  margin: -6px 0 14px;
  color: var(--muted);
  font-size: 14px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-grid label {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.form-grid label.full {
  grid-column: 1 / -1;
}

.form-grid span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.form-grid span b {
  margin-left: 5px;
  color: var(--primary);
  font-size: 12px;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
  width: 100%;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid rgba(71, 113, 252, 0.18);
  border-radius: 12px;
  outline: 0;
  background: #fbfdff;
  color: var(--title);
  font: inherit;
}

.form-grid textarea {
  resize: vertical;
}

.form-grid input:focus,
.form-grid select:focus,
.form-grid textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(71, 113, 252, 0.1);
}

.form-grid input.is-invalid,
.form-grid select.is-invalid,
.form-grid textarea.is-invalid {
  border-color: #d9363e;
  background: #fffafa;
}

.form-grid input.is-invalid:focus,
.form-grid select.is-invalid:focus,
.form-grid textarea.is-invalid:focus {
  box-shadow: 0 0 0 4px rgba(217, 54, 62, 0.12);
}

.form-grid input::placeholder,
.form-grid textarea::placeholder {
  color: #9aa8c4;
}

.field-error {
  min-height: 17px;
  color: #b4232a;
  font-size: 12px;
  line-height: 1.4;
}

.field-error:empty {
  display: none;
}

.form-alert {
  padding: 12px 14px;
  border: 1px solid rgba(217, 54, 62, 0.22);
  background: #fff5f5;
  color: #9f1f26;
  font-size: 14px;
  font-weight: 700;
}

.form-footer {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding-top: 6px;
  border-top: 1px solid var(--line);
}

.form-footer p {
  max-width: 470px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.admin-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.admin-actions form {
  margin: 0;
}

.secondary-cta {
  border: 1px solid rgba(71, 113, 252, 0.2);
  background: #fff;
  color: var(--primary);
}

.admin-login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 16px;
}

.login-shell {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 0.72fr);
  gap: 42px;
  align-items: center;
  width: min(960px, 100%);
}

.login-copy h1 {
  margin-bottom: 14px;
}

.login-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 17px;
}

.login-form {
  display: grid;
  gap: 16px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.login-form label {
  display: grid;
  gap: 8px;
}

.login-form span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.login-form input {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid rgba(71, 113, 252, 0.18);
  border-radius: 12px;
  outline: 0;
  background: #fbfdff;
  color: var(--title);
  font: inherit;
}

.login-form input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(71, 113, 252, 0.1);
}

.admin-page {
  min-height: 100vh;
}

.admin-shell {
  display: grid;
  gap: 24px;
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 72px 0 88px;
}

.admin-heading {
  max-width: 760px;
}

.admin-heading h1 {
  margin-bottom: 12px;
}

.admin-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 17px;
}

.admin-panel {
  display: grid;
  gap: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.admin-toolbar {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.admin-toolbar strong,
.admin-toolbar span {
  display: block;
}

.admin-toolbar strong {
  color: var(--title);
  font-size: 20px;
}

.admin-toolbar span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.lead-empty {
  padding: 22px;
  border: 1px dashed rgba(71, 113, 252, 0.28);
  border-radius: 16px;
  background: #f8fbff;
  color: var(--muted);
  font-weight: 700;
}

.lead-list {
  display: grid;
  gap: 16px;
}

.lead-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fbfdff;
}

.lead-card-head {
  display: flex;
  gap: 16px;
  align-items: start;
  justify-content: space-between;
}

.lead-card-head > div {
  min-width: 0;
}

.lead-card-head strong,
.lead-card-head span {
  display: block;
}

.lead-card-head strong {
  color: var(--title);
  font-size: 20px;
}

.lead-card-head span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.lead-card-head mark {
  flex: 0 0 auto;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(71, 113, 252, 0.12);
  color: var(--primary);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.lead-card dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.lead-card dl div {
  min-width: 0;
  padding: 12px;
  border-radius: 12px;
  background: #fff;
}

.lead-card dl div.wide {
  grid-column: span 2;
}

.lead-card dt {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.lead-card dd {
  margin: 0;
  color: var(--title);
  font-weight: 700;
  overflow-wrap: anywhere;
}

.report-page {
  min-height: 100vh;
}

.report-hero {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 82px 0 36px;
}

.report-hero h1 {
  max-width: 860px;
  margin-bottom: 18px;
}

.report-hero > p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.report-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  max-width: 760px;
  margin: 30px 0 0;
}

.report-kpis div {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
}

.report-kpis dt {
  color: var(--primary);
  font-size: 42px;
  font-weight: 900;
  line-height: 1;
}

.report-kpis dd {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 700;
}

.report-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 28px;
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  padding: 0 0 92px;
}

.report-toc {
  position: sticky;
  top: 106px;
  display: grid;
  gap: 10px;
  align-self: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
}

.report-toc strong {
  color: var(--title);
}

.report-toc a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.report-document {
  display: grid;
  gap: 22px;
  min-width: 0;
}

.report-document section {
  min-width: 0;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.94);
}

.report-document h2,
.report-document h3 {
  margin-top: 0;
}

.report-document p,
.report-document li {
  color: var(--muted);
}

.report-meta {
  margin-top: 0;
  color: var(--accent-deep);
  font-size: 14px;
  font-weight: 800;
}

.report-table {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.report-table div {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 16px;
  padding: 14px;
  border-radius: 12px;
  background: #f8fbff;
}

.report-table span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.report-table strong {
  color: var(--title);
}

.score-bars {
  display: grid;
  gap: 12px;
}

.score-bars div {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) 58px;
  gap: 12px;
  align-items: center;
}

.score-bars span,
.score-bars strong {
  color: var(--title);
  font-weight: 800;
}

.score-bars meter {
  width: 100%;
  height: 14px;
}

.report-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.report-columns div,
.raw-answer {
  padding: 18px;
  border-radius: 14px;
  background: #f8fbff;
}

.action-list {
  display: grid;
  gap: 12px;
  padding-left: 22px;
}

.raw-answer + .raw-answer {
  margin-top: 14px;
}

.raw-answer blockquote {
  margin: 14px 0;
  padding: 14px 16px;
  border-left: 4px solid var(--primary);
  background: #fff;
  color: var(--title);
}

.premium-report-page {
  background:
    linear-gradient(180deg, rgba(236, 245, 255, 0.92), rgba(255, 255, 255, 0.96) 46%),
    radial-gradient(circle at 80% 8%, rgba(44, 187, 122, 0.16), transparent 32%),
    radial-gradient(circle at 16% 24%, rgba(255, 196, 87, 0.2), transparent 28%);
}

.live-report-page {
  background:
    linear-gradient(180deg, rgba(239, 246, 255, 0.96), rgba(255, 255, 255, 0.98) 48%),
    radial-gradient(circle at 84% 10%, rgba(71, 113, 252, 0.14), transparent 32%),
    radial-gradient(circle at 12% 20%, rgba(34, 168, 111, 0.12), transparent 28%);
}

.live-report-page .report-hero,
.live-report-page .report-layout {
  width: min(1520px, calc(100% - 48px));
}

.premium-report-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 430px);
  gap: 42px;
  align-items: end;
  padding: 88px 0 48px;
}

.premium-report-hero h1 {
  max-width: 760px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.premium-kpis {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-width: none;
  margin: 0;
}

.premium-kpis div {
  border-color: rgba(71, 113, 252, 0.14);
  box-shadow: 0 20px 52px rgba(31, 48, 92, 0.08);
}

.premium-kpis div:nth-child(2) dt {
  color: #159a64;
}

.premium-kpis div:nth-child(3) dt {
  color: #d87418;
}

.premium-report-layout {
  grid-template-columns: 220px minmax(0, 1fr);
}

.premium-toc {
  border-color: rgba(71, 113, 252, 0.14);
  box-shadow: 0 18px 42px rgba(31, 48, 92, 0.08);
}

.collapsible-toc {
  overflow: hidden;
  padding: 0;
}

.collapsible-toc details {
  padding: 16px 18px;
}

.collapsible-toc summary {
  color: var(--title);
  font-weight: 900;
  cursor: pointer;
}

.collapsible-toc nav {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.collapsible-toc details:not([open]) {
  padding: 14px 18px;
}

.premium-report section {
  border-color: rgba(71, 113, 252, 0.12);
  box-shadow: 0 18px 44px rgba(31, 48, 92, 0.06);
}

.premium-summary {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(246, 250, 255, 0.96)),
    linear-gradient(90deg, rgba(71, 113, 252, 0.08), rgba(44, 187, 122, 0.08));
}

.live-score-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 16px;
}

.live-metric-bars,
.compact-metrics {
  display: grid;
  gap: 12px;
}

.live-metric-bars {
  padding: 18px;
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 16px;
  background: #f8fbff;
}

.metric-row {
  position: relative;
  display: grid;
  grid-template-columns: 150px 70px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding-bottom: 12px;
}

.metric-row::before,
.metric-row::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 7px;
  border-radius: 999px;
  content: "";
}

.metric-row::before {
  background: rgba(71, 113, 252, 0.1);
}

.metric-row::after {
  width: var(--value);
  background: linear-gradient(90deg, var(--primary), #22a86f);
}

.metric-row span,
.metric-row strong {
  color: var(--title);
  font-weight: 900;
}

.metric-row p {
  margin: 0;
  font-size: 14px;
}

.entity-score-grid {
  display: grid;
  gap: 16px;
}

.entity-score-grid article {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 16px;
  background: #f8fbff;
}

.entity-score-grid article > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.entity-score-grid article > strong {
  color: var(--title);
  font-size: 22px;
}

.entity-score-grid article > em {
  color: var(--primary);
  font-size: 44px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

.compact-metrics {
  padding-top: 4px;
}

.compact-metrics .metric-row {
  grid-template-columns: 150px 60px minmax(0, 1fr);
}

.compact-metrics .metric-row p {
  font-size: 13px;
}

.final-table-wrap,
.detail-table-wrap {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 18px 0;
  overflow-x: auto;
}

.final-score-table,
.detail-table {
  width: 100%;
  border-collapse: collapse;
}

.final-score-table {
  min-width: 860px;
}

.detail-table {
  min-width: 980px;
}

.final-score-table th,
.final-score-table td,
.detail-table th,
.detail-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  text-align: left;
  vertical-align: top;
}

.final-score-table th,
.detail-table th {
  color: var(--title);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.final-score-table td:first-child strong,
.detail-table td:nth-child(2) strong {
  display: block;
  color: var(--title);
}

.final-score-table td:first-child span,
.detail-table td:nth-child(2) span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.score-pill {
  position: relative;
  display: inline-flex;
  min-width: 46px;
  min-height: 28px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--score-border, rgba(71, 113, 252, 0.16));
  border-radius: 999px;
  background: linear-gradient(90deg, var(--score-fill, rgba(71, 113, 252, 0.16)) var(--value), #fff var(--value));
  color: var(--score-ink, var(--title));
  font-size: 13px;
  font-weight: 900;
}

.score-high {
  --score-border: rgba(26, 127, 86, 0.28);
  --score-fill: rgba(34, 168, 111, 0.24);
  --score-ink: #126b49;
}

.score-medium {
  --score-border: rgba(71, 113, 252, 0.22);
  --score-fill: rgba(71, 113, 252, 0.2);
  --score-ink: #3155c9;
}

.score-low {
  --score-border: rgba(216, 116, 24, 0.26);
  --score-fill: rgba(255, 177, 79, 0.28);
  --score-ink: #a8580f;
}

.score-risk {
  --score-border: rgba(190, 45, 59, 0.26);
  --score-fill: rgba(230, 86, 101, 0.2);
  --score-ink: #a51f32;
}

.score-pill-rough {
  min-width: 62px;
}

.dimension-score-stack {
  display: grid;
  gap: 8px;
}

.dimension-score-stack div {
  display: grid;
  grid-template-columns: 72px auto;
  gap: 8px;
  align-items: center;
}

.dimension-score-stack span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.prompt-question {
  min-width: 320px;
  margin: 0;
  color: var(--title);
  font-weight: 800;
  line-height: 1.55;
}

.prompt-id {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.category-chip {
  display: inline-flex;
  min-width: 76px;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1px solid rgba(71, 113, 252, 0.16);
  border-radius: 999px;
  background: #eef4ff;
  color: var(--accent-deep);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.method-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.method-grid article {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 16px;
  background: #f8fbff;
}

.method-grid span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.method-grid strong {
  color: var(--primary);
  font-size: 42px;
  line-height: 1;
}

.method-grid p {
  margin: 0;
}

.method-grid b {
  color: var(--title);
}

.lead-text {
  color: var(--title);
  font-size: 18px;
  font-weight: 700;
}

.summary-conclusion-list {
  display: grid;
  gap: 12px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.summary-conclusion-list li {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 14px 16px;
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
}

.summary-conclusion-list span {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #eef4ff;
  color: var(--primary);
  font-size: 13px;
  font-weight: 900;
}

.summary-conclusion-list p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.summary-conclusion-list strong {
  color: var(--title);
}

.insight-strip,
.model-score-grid,
.prompt-detail-grid,
.competitor-radar,
.action-cards {
  display: grid;
  gap: 14px;
}

.insight-strip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 22px;
}

.insight-strip a,
.model-score-grid article,
.prompt-card,
.competitor-radar div,
.action-cards article,
.report-cta {
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 16px;
  background: #f8fbff;
}

.insight-strip a {
  display: block;
  padding: 16px;
  text-decoration: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.insight-strip a:hover {
  border-color: rgba(71, 113, 252, 0.32);
  box-shadow: 0 14px 34px rgba(71, 113, 252, 0.1);
  transform: translateY(-1px);
}

.insight-strip strong,
.insight-strip span {
  display: block;
}

.insight-strip strong {
  color: var(--title);
}

.insight-strip span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.model-score-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.model-score-grid article {
  padding: 18px;
}

.model-score-grid span {
  color: var(--muted);
  font-weight: 800;
}

.model-score-grid strong {
  display: block;
  margin: 12px 0 8px;
  color: var(--primary);
  font-size: 52px;
  line-height: 1;
}

.model-score-grid article.risk strong {
  color: #d87418;
}

.model-score-grid p {
  min-height: 66px;
  margin: 0 0 14px;
}

.model-score-grid meter {
  width: 100%;
  height: 12px;
}

.premium-score-bars meter::-webkit-meter-optimum-value,
.model-score-grid meter::-webkit-meter-optimum-value {
  background: linear-gradient(90deg, #4771fc, #22a86f);
}

.prompt-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.prompt-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: #fbfdff;
}

.prompt-card.win {
  border-color: rgba(34, 168, 111, 0.22);
  background: #f5fff9;
}

.prompt-card.loss {
  border-color: rgba(216, 116, 24, 0.24);
  background: #fffaf2;
}

.prompt-card-head {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.prompt-card-head strong {
  color: var(--title);
  font-size: 18px;
}

.prompt-card-head span {
  color: var(--accent-deep);
  font-size: 13px;
  font-weight: 900;
}

.prompt-card .prompt {
  margin: 0;
  color: var(--title);
  font-weight: 800;
}

.prompt-card blockquote {
  margin: 0;
  padding: 14px 16px;
  border-left: 4px solid var(--primary);
  background: #fff;
  color: var(--title);
  line-height: 1.7;
}

.prompt-card dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.prompt-card dl div {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 10px;
}

.prompt-card dt {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.prompt-card dd {
  margin: 0;
  color: var(--title);
  font-weight: 700;
}

.detail-link {
  justify-self: start;
  color: var(--primary);
  font-size: 14px;
  font-weight: 900;
}

.detail-hero {
  padding-bottom: 22px;
}

.request-detail-shell {
  display: grid;
  gap: 18px;
  width: min(960px, calc(100% - 48px));
  margin: 0 auto;
  padding: 0 0 92px;
}

.request-detail-card {
  scroll-margin-top: 110px;
  display: grid;
  gap: 18px;
  padding: 28px;
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 44px rgba(31, 48, 92, 0.06);
}

.request-detail-card.loss {
  border-color: rgba(216, 116, 24, 0.24);
  background: #fffaf2;
}

.request-detail-head {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  justify-content: space-between;
}

.request-detail-head span {
  color: var(--primary);
  font-size: 18px;
  font-weight: 900;
}

.request-detail-head strong {
  color: var(--accent-deep);
  font-size: 14px;
}

.request-detail-card h2 {
  margin: 0;
  font-size: 28px;
}

.request-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.request-detail-grid div {
  padding: 14px;
  border-radius: 14px;
  background: #f8fbff;
}

.request-detail-grid span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.request-detail-grid p {
  margin: 6px 0 0;
  color: var(--title);
  font-weight: 700;
}

.request-detail-card blockquote {
  margin: 0;
  padding: 16px 18px;
  border-left: 4px solid var(--primary);
  background: #fff;
  color: var(--title);
  line-height: 1.75;
}

.competitor-radar {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.competitor-radar div {
  min-height: 128px;
  padding: 16px;
}

.competitor-radar span,
.competitor-radar strong {
  display: block;
}

.competitor-radar span {
  color: var(--title);
  font-weight: 900;
}

.competitor-radar strong {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

.action-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.prioritized-actions {
  margin-top: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.action-cards article {
  padding: 18px;
}

.action-cards span {
  color: var(--accent-deep);
  font-weight: 900;
}

.action-cards strong {
  display: block;
  margin: 8px 0;
  color: var(--title);
  font-size: 18px;
}

.action-cards p {
  margin: 0;
}

.prioritized-actions article:first-child,
.prioritized-actions article:nth-child(2) {
  border-color: rgba(216, 116, 24, 0.24);
  background: #fffaf2;
}

.report-cta {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
  padding: 18px;
  background: linear-gradient(135deg, #10213f, #1f3a6c);
}

.report-cta p,
.report-cta strong {
  margin: 0;
  color: white;
}

.report-cta .button {
  flex: 0 0 auto;
}

.prompt-table-wrap {
  overflow-x: auto;
}

.prompt-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
}

.prompt-table th,
.prompt-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  text-align: left;
  vertical-align: top;
}

.prompt-table th {
  color: var(--title);
  font-size: 13px;
  font-weight: 900;
}

.prompt-table td:first-child,
.prompt-table td:nth-child(4) {
  color: var(--primary);
  font-weight: 900;
  white-space: nowrap;
}

.live-answer-list {
  display: grid;
  gap: 12px;
}

.live-answer-card {
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 16px;
  background: #fbfdff;
}

.live-answer-card summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 16px 18px;
  cursor: pointer;
}

.live-answer-card summary span,
.live-answer-card summary strong {
  color: var(--title);
  font-weight: 900;
}

.live-answer-card summary strong {
  color: var(--accent-deep);
  font-size: 13px;
}

.answer-meta {
  display: grid;
  gap: 10px;
  padding: 0 18px 16px;
}

.answer-meta div {
  padding: 14px;
  border-radius: 14px;
  background: #f8fbff;
}

.answer-meta span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.answer-meta p {
  margin: 6px 0 0;
  color: var(--title);
  font-weight: 700;
}

.raw-answer-pre {
  max-height: 520px;
  margin: 0 18px 18px;
  padding: 16px;
  overflow: auto;
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 14px;
  background: #101827;
  color: #eef4ff;
  font: 14px/1.75 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  white-space: pre-wrap;
}

.detail-table .report-answer-detail {
  min-width: 360px;
}

.report-answer-detail summary {
  line-height: 1.6;
}

.prompt-answer-detail {
  min-width: 420px;
}

.prompt-answer-detail > summary {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(71, 113, 252, 0.18);
  border-radius: 999px;
  background: #fff;
  color: var(--primary);
  font-size: 14px;
  font-weight: 900;
}

.model-answer-grid {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.model-answer-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid rgba(71, 113, 252, 0.12);
  border-radius: 14px;
  background: #fff;
}

.model-tab-panel[hidden] {
  display: none !important;
}

.answer-view-panel[hidden],
.dimension-detail-panel[hidden] {
  display: none !important;
}

.model-answer-head {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.model-answer-head strong {
  color: var(--title);
  font-size: 17px;
}

.model-answer-head span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.compact-answer-meta {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 0;
}

.model-tabs {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 0;
  background: #fbfdff;
}

.model-tab-list {
  display: flex;
  gap: 8px;
  padding: 14px 24px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.model-tab {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border: 1px solid rgba(71, 113, 252, 0.16);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}

.model-tab.active {
  border-color: rgba(71, 113, 252, 0.42);
  background: var(--primary);
  color: #fff;
  box-shadow: 0 10px 22px rgba(71, 113, 252, 0.16);
}

.answer-view-tabs {
  display: grid;
  gap: 14px;
}

.answer-view-tab-list,
.dimension-detail-tab-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.answer-view-tab,
.dimension-detail-tab {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid rgba(71, 113, 252, 0.16);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}

.answer-view-tab.active,
.dimension-detail-tab.active {
  border-color: rgba(71, 113, 252, 0.42);
  background: #eef4ff;
  color: var(--primary);
}

.answer-view-panel {
  display: grid;
  gap: 14px;
}

.model-tab-panels {
  min-height: 0;
  overflow: auto;
  padding: 18px 24px 24px;
}

.model-score-logic {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 12px;
  background: #f8fbff;
}

.model-score-logic .dimension-score-stack {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.model-score-logic p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.dimension-detail-tabs {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 12px;
  background: #fff;
}

.dimension-detail-panel {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 10px;
  background: #f8fbff;
}

.dimension-detail-panel > div {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.dimension-detail-panel span {
  color: var(--title);
  font-weight: 900;
}

.dimension-detail-panel p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.compact-answer-meta a {
  color: var(--primary);
  overflow-wrap: anywhere;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.raw-answer-toggle {
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 12px;
  background: #f8fbff;
}

.raw-answer-toggle summary {
  padding: 12px 14px;
  color: var(--accent-deep);
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

.raw-answer-toggle .raw-answer-pre {
  margin: 0 12px 12px;
}

.citation-section {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 12px;
  background: #f8fbff;
}

.citation-section h4 {
  margin: 0;
  color: var(--title);
  font-size: 14px;
}

.citation-list {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
}

.citation-list a,
.markdown-answer a {
  color: var(--primary);
  overflow-wrap: anywhere;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.citation-empty {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.answer-markdown-section {
  display: grid;
  gap: 10px;
}

.answer-markdown-section h4 {
  margin: 0;
  color: var(--title);
  font-size: 15px;
}

.markdown-answer {
  display: grid;
  gap: 10px;
  max-height: 520px;
  margin: 0;
  padding: 16px;
  overflow: auto;
  border: 1px solid rgba(71, 113, 252, 0.1);
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.75;
}

.markdown-answer h3,
.markdown-answer h4,
.markdown-answer h5,
.markdown-answer p,
.markdown-answer ul,
.markdown-answer ol,
.markdown-answer blockquote {
  margin: 0;
}

.markdown-answer h3,
.markdown-answer h4,
.markdown-answer h5 {
  color: var(--title);
  font-size: 16px;
  line-height: 1.45;
}

.markdown-answer ul,
.markdown-answer ol {
  display: grid;
  gap: 6px;
  padding-left: 20px;
}

.markdown-answer hr {
  width: 100%;
  height: 1px;
  border: 0;
  background: var(--line);
}

.markdown-table-wrap {
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.markdown-table-wrap table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
}

.markdown-table-wrap th,
.markdown-table-wrap td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  text-align: left;
  vertical-align: top;
}

.markdown-table-wrap th {
  color: var(--title);
  font-weight: 900;
  background: #f8fbff;
}

.markdown-table-wrap tr:last-child td {
  border-bottom: 0;
}

.markdown-answer blockquote {
  padding: 10px 12px;
  border-left: 4px solid var(--primary);
  border-radius: 10px;
  background: #f8fbff;
  color: var(--title);
}

.markdown-answer code {
  padding: 2px 5px;
  border-radius: 6px;
  background: #eef4ff;
  color: var(--accent-deep);
}

.target-highlight {
  padding: 1px 4px;
  border-radius: 5px;
  background: rgba(255, 210, 91, 0.45);
  color: var(--title);
  font-weight: 900;
}

.dialog-trigger,
.dialog-close {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(71, 113, 252, 0.18);
  border-radius: 999px;
  background: #fff;
  color: var(--primary);
  font: inherit;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}

.dialog-trigger {
  padding: 0 14px;
}

.dialog-close {
  position: absolute;
  top: 22px;
  right: 24px;
  min-width: 72px;
  padding: 0 16px;
  color: white;
  background: var(--primary);
  box-shadow: 0 10px 22px rgba(71, 113, 252, 0.18);
}

.answer-dialog {
  width: min(1180px, calc(100% - 48px));
  max-height: min(860px, calc(100vh - 48px));
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(71, 113, 252, 0.16);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 34px 90px rgba(18, 32, 64, 0.26);
}

.answer-dialog::backdrop {
  background: rgba(14, 24, 48, 0.42);
  backdrop-filter: blur(5px);
}

.answer-dialog-shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  max-height: min(860px, calc(100vh - 48px));
}

.answer-dialog-head {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 22px 118px 22px 24px;
  border-bottom: 1px solid var(--line);
  background: #f8fbff;
}

.answer-dialog-head h3 {
  margin: 12px 0 8px;
  color: var(--title);
  font-size: 24px;
  line-height: 1.35;
}

.answer-dialog-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.answer-dialog-score {
  padding: 14px 24px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.answer-dialog-score .dimension-score-stack {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.answer-dialog .model-answer-grid {
  max-height: 620px;
  overflow: auto;
  padding: 18px 24px 24px;
  background: #fbfdff;
}

@media (max-width: 920px) {
  .site-header {
    grid-template-columns: 1fr auto;
    padding: 0 24px;
  }

  .site-nav {
    display: none;
  }

  .hero {
    min-height: auto;
  }

  .hero-content {
    width: min(100% - 32px, 720px);
    padding: 62px 0 34px;
  }

  .hero-overlay {
    background:
      linear-gradient(90deg, rgba(248, 251, 255, 0.98), rgba(248, 251, 255, 0.78)),
      linear-gradient(0deg, rgba(238, 244, 255, 0.95), rgba(248, 251, 255, 0.2));
  }

  .hero-metrics,
  .metric-grid,
  .split,
  .model-columns,
  .scorecard,
  .score-layout,
  .process-list,
  .preview-grid,
  .optimization,
  .optimization-grid,
  .live-report-summary,
  .live-report-stats,
  .live-score-layout,
  .contact,
  .diagnosis-shell,
  .form-grid,
  .login-shell,
  .report-layout,
  .premium-report-hero,
  .premium-report-layout,
  .request-detail-grid,
  .report-columns,
  .report-kpis,
  .insight-strip,
  .model-score-grid,
  .method-grid,
  .prompt-detail-grid,
  .competitor-radar,
  .action-cards,
  .lead-card dl,
  .report-band {
    grid-template-columns: 1fr;
  }

  .diagnosis-copy {
    position: static;
  }

  .report-toc {
    position: static;
  }

  .report-actions {
    justify-content: flex-start;
  }

  .report-cta {
    display: grid;
    justify-items: start;
  }

  .form-footer {
    display: grid;
    justify-items: start;
  }

  .admin-actions {
    grid-column: 1 / -1;
    justify-content: start;
  }

  .admin-toolbar {
    display: grid;
    justify-items: start;
  }

  .lead-card dl div.wide {
    grid-column: auto;
  }

  .process-list li + li {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .report-band {
    padding: 56px 24px;
  }

  .metric-row,
  .compact-metrics .metric-row {
    grid-template-columns: 1fr auto;
  }

  .metric-row p {
    grid-column: 1 / -1;
  }

  .summary-conclusion-list li {
    grid-template-columns: 1fr;
  }

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

  .answer-dialog {
    width: calc(100% - 24px);
    max-height: calc(100vh - 24px);
  }

  .answer-dialog-shell {
    max-height: calc(100vh - 24px);
  }

  .answer-dialog-score .dimension-score-stack {
    grid-template-columns: 1fr;
  }

  .live-report-page .report-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .premium-kpis div {
    min-height: 112px;
    padding: 16px;
  }

  .premium-kpis dt {
    font-size: 34px;
  }

  .model-score-logic .dimension-score-stack {
    grid-template-columns: 1fr;
  }

  .model-tab-list,
  .model-tab-panels {
    padding-right: 16px;
    padding-left: 16px;
  }
}

@media (max-width: 620px) {
  .site-header {
    min-height: 62px;
    padding: 0 16px;
  }

  .header-cta {
    min-height: 38px;
    padding: 0 12px;
    font-size: 14px;
  }

  h1 {
    font-size: 38px;
  }

  h2 {
    font-size: 29px;
  }

  .hero-copy,
  .section-heading p,
  .contact-copy p,
  .report-band p {
    font-size: 16px;
  }

  .section {
    width: calc(100% - 32px);
    padding: 62px 0;
  }

  .hero-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-metrics div {
    padding: 12px;
  }

  .hero-metrics dt {
    font-size: 24px;
  }

  .hero-metrics dd {
    font-size: 12px;
  }

  .table-row {
    grid-template-columns: 1fr;
  }

  .table-row span + span {
    border-left: 0;
  }

  .table-head span:not(:first-child) {
    display: none;
  }

  .panel-topline {
    display: grid;
    gap: 4px;
  }

  .score-summary {
    min-height: 240px;
  }

  .score-summary strong {
    font-size: 66px;
  }

  .diagnosis-form {
    padding: 20px;
    border-radius: 18px;
  }

  .diagnosis-shell,
  .report-hero,
  .report-layout {
    width: calc(100% - 32px);
  }

  .report-hero {
    padding: 60px 0 72px;
  }

  .report-document section {
    padding: 20px;
  }

  .report-table div,
  .score-bars div,
  .prompt-card dl div {
    grid-template-columns: 1fr;
  }

  .live-report-stats div {
    min-height: 104px;
  }

  .live-report-page .report-kpis {
    gap: 8px;
  }

  .premium-kpis div {
    min-height: 92px;
    padding: 12px;
  }

  .premium-kpis dt {
    font-size: 25px;
  }

  .premium-kpis dd {
    font-size: 12px;
  }

  .live-answer-card summary {
    grid-template-columns: 1fr;
  }

  .premium-report-hero {
    padding: 56px 0 36px;
  }

  .model-score-grid p {
    min-height: 0;
  }

  .prompt-question {
    min-width: 260px;
  }

  .model-answer-head {
    display: grid;
    justify-items: start;
  }

  .answer-dialog-head,
  .answer-dialog-score,
  .answer-dialog .model-answer-grid {
    padding-right: 16px;
    padding-left: 16px;
  }

  .answer-dialog-head {
    padding-right: 96px;
  }

  .dialog-close {
    right: 16px;
  }

  .answer-dialog-head h3 {
    font-size: 20px;
  }

  .model-tab {
    min-height: 36px;
    padding: 0 12px;
    font-size: 13px;
  }
}
