:root {
  color-scheme: light;
  --bg: #fff9fd;
  --bg-deep: #f8edff;
  --surface: rgba(255, 255, 255, 0.78);
  --surface-solid: #ffffff;
  --ink: #2b003d;
  --muted: #765684;
  --faint: #a997b1;
  --line: rgba(82, 38, 96, 0.12);
  --line-strong: rgba(82, 38, 96, 0.2);
  --purple: #5b356b;
  --purple-dark: #2b003d;
  --purple-soft: #f2dcff;
  --pink-soft: #fff0fb;
  --good: #147a57;
  --good-soft: #e2fbef;
  --warn: #a35b00;
  --warn-soft: #fff2d7;
  --shadow: 0 22px 54px rgba(43, 0, 61, 0.12);
  --page-gradient:
    linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.9)),
    linear-gradient(135deg, rgba(245, 207, 255, 0.65), rgba(220, 195, 255, 0.78));
  --page-gradient-soft:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.92)),
    linear-gradient(135deg, rgba(245, 207, 255, 0.5), rgba(220, 195, 255, 0.58));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 50% 18%, rgba(215, 170, 255, 0.24), transparent 30rem),
    linear-gradient(180deg, #fff9fd 0%, #fff7fd 48%, #fbf1ff 100%);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  letter-spacing: 0;
}

button,
select {
  font: inherit;
}

button {
  border: 0;
  background: none;
}

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

a:hover {
  color: var(--purple);
}

.app {
  min-height: 100vh;
}

.hero {
  position: relative;
  overflow: visible;
  padding: 24px 38px 34px;
}

.hero::before {
  content: "T";
  position: absolute;
  top: 122px;
  left: 50%;
  z-index: -1;
  transform: translateX(-50%);
  color: rgba(91, 53, 107, 0.045);
  font-size: 420px;
  font-weight: 900;
  line-height: 0.8;
}

.topbar {
  position: relative;
  z-index: 60;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  max-width: 1180px;
  margin: 0 auto 70px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--ink);
  font-weight: 750;
  cursor: pointer;
  transition:
    color 180ms ease,
    transform 180ms ease;
}

.brand:hover {
  color: var(--purple);
  transform: translateY(-1px);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 5px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 12px;
  font-weight: 900;
  transition:
    background 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.brand:hover .brand-mark {
  background: var(--purple);
  box-shadow: 0 10px 20px rgba(43, 0, 61, 0.18);
  transform: scale(1.08);
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 34px;
  color: var(--ink);
  font-size: 14px;
}

.nav-links button {
  position: relative;
  color: var(--ink);
  cursor: pointer;
  padding: 8px 0;
  transition:
    color 180ms ease,
    transform 180ms ease;
}

.nav-links button::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 2px;
  border-radius: 999px;
  background: var(--purple);
  opacity: 0;
  transform: scaleX(0.5);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.nav-links button:hover {
  color: var(--purple);
  transform: translateY(-1px);
}

.nav-links button:hover::after,
.nav-links button.active::after {
  opacity: 1;
  transform: scaleX(1);
}

.nav-links button.active {
  color: var(--purple);
  font-weight: 780;
}

.controls {
  position: relative;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}

.controls button {
  min-height: 42px;
  border: 0;
  border-radius: 999px;
  color: var(--ink);
}

.controls button {
  padding: 0 18px;
  color: #fff;
  background: var(--purple);
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(91, 53, 107, 0.22);
}

.controls button:hover {
  background: var(--purple-dark);
}

.controls .feedback-nav-button {
  min-height: 34px;
  padding: 0 13px;
  border-radius: 999px;
  background: var(--purple-dark);
  box-shadow: 0 10px 22px rgba(43, 0, 61, 0.16);
  font-size: 12px;
  font-weight: 760;
}

.controls .feedback-nav-button:hover {
  background: var(--purple);
}

.calendar-control {
  position: relative;
  z-index: 80;
}

.controls .calendar-toggle {
  display: grid;
  place-items: center;
  width: 42px;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.controls .calendar-toggle:hover {
  background: transparent;
}

.calendar-mark {
  position: relative;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: var(--purple-dark);
  box-shadow: 0 10px 20px rgba(43, 0, 61, 0.18);
}

.calendar-mark::before {
  content: "";
  position: absolute;
  top: 5px;
  left: 5px;
  right: 5px;
  height: 3px;
  border-radius: 2px;
  background: #fff;
  opacity: 0.95;
}

.calendar-mark::after {
  content: "";
  position: absolute;
  left: 5px;
  right: 5px;
  bottom: 5px;
  height: 7px;
  border: 1.5px solid #fff;
  border-top: 0;
  border-radius: 0 0 2px 2px;
  opacity: 0.95;
}

.calendar-mark span {
  position: absolute;
  top: 12px;
  left: 8px;
  width: 2px;
  height: 2px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 4px 0 0 #fff;
  opacity: 0.95;
}

.calendar-popover {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 1000;
  width: 292px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 24px 56px rgba(43, 0, 61, 0.16);
  backdrop-filter: blur(14px);
}

.calendar-head {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.calendar-head strong {
  color: var(--ink);
  font-size: 15px;
  text-align: center;
}

.controls .calendar-head button {
  display: grid;
  place-items: center;
  min-height: 34px;
  padding: 0;
  color: var(--purple);
  background: rgba(91, 53, 107, 0.08);
  box-shadow: none;
  font-size: 20px;
}

.controls .calendar-head button:hover {
  background: rgba(91, 53, 107, 0.14);
}

.calendar-weekdays,
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.calendar-weekdays {
  margin-bottom: 7px;
}

.calendar-weekdays span {
  color: var(--faint);
  font-size: 11px;
  font-weight: 760;
  text-align: center;
}

.calendar-grid button,
.calendar-empty {
  display: grid;
  place-items: center;
  min-height: 32px;
  border-radius: 10px;
}

.controls .calendar-grid button {
  padding: 0;
  color: var(--faint);
  background: transparent;
  box-shadow: none;
  font-size: 13px;
}

.controls .calendar-grid button.available {
  color: var(--ink);
  background: rgba(91, 53, 107, 0.08);
}

.controls .calendar-grid button.available:hover {
  color: #fff;
  background: var(--purple);
}

.controls .calendar-grid button.selected {
  color: #fff;
  background: var(--purple-dark);
}

.controls .calendar-grid button:disabled {
  cursor: default;
  opacity: 0.36;
}

.calendar-note {
  margin-top: 12px;
  color: var(--faint);
  font-size: 11px;
  line-height: 1.45;
  text-align: center;
}

.hero-grid {
  display: grid;
  gap: 28px;
  max-width: 1180px;
  margin: 0 auto;
}

.hero-meta {
  margin-top: -12px;
  color: var(--faint);
  font-size: 13px;
}

.hero-copy {
  display: grid;
  justify-items: center;
  text-align: center;
}

.eyebrow {
  color: var(--purple);
  font-size: 11px;
  font-weight: 780;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy h1 {
  max-width: 820px;
  margin: 12px 0 14px;
  color: var(--ink);
  font-size: 88px;
  line-height: 1.08;
  font-weight: 830;
}

.hero-copy > p {
  max-width: 610px;
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 20px;
  line-height: 1.55;
}

.home-page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 38px 52px;
}

.keyword-showcase {
  position: relative;
  overflow: visible;
  min-height: 440px;
  padding: 72px clamp(18px, 4vw, 72px);
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 16px;
  background: var(--page-gradient);
  box-shadow: var(--shadow);
}

.keyword-showcase::before {
  content: "";
  position: absolute;
  inset: 28px 14% auto;
  height: 160px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.52);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.9);
}

.preview-label {
  position: relative;
  z-index: 1;
  margin-bottom: 26px;
  color: var(--purple);
  font-size: 20px;
  line-height: 1.18;
  font-weight: 850;
  letter-spacing: 0;
  text-align: center;
}

.keyword-card-list {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 14px;
  max-width: 860px;
  margin: 0 auto;
}

.keyword-card {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr) 170px;
  gap: 18px;
  align-items: center;
  padding: 18px;
  border: 1px solid rgba(82, 38, 96, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 16px 36px rgba(43, 0, 61, 0.08);
}

.keyword-rank {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 16px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 19px;
  font-weight: 880;
}

.keyword-main h3 {
  margin: 0;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.25;
}

.keyword-main p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.keyword-main p a,
.category-trend-card p a,
.representative a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: rgba(91, 53, 107, 0.24);
  text-underline-offset: 3px;
}

.keyword-main p a:hover,
.category-trend-card p a:hover,
.representative a:hover {
  color: var(--purple-dark);
  text-decoration-color: var(--purple-dark);
}

.rank-sparkline {
  display: grid;
  gap: 6px;
  justify-items: end;
  min-width: 168px;
  color: var(--muted);
  cursor: pointer;
  border: 0;
  background: transparent;
  font: inherit;
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.rank-sparkline:hover {
  opacity: 0.82;
  transform: translateY(-1px);
}

.rank-sparkline svg {
  width: 168px;
  height: 58px;
  overflow: visible;
}

.rank-sparkline-grid {
  fill: none;
  stroke: rgba(82, 38, 96, 0.1);
  stroke-width: 1;
}

.rank-sparkline-line {
  fill: none;
  stroke: var(--purple);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.8;
}

.rank-sparkline-dot {
  fill: #fff;
  stroke: var(--purple);
  stroke-width: 1.8;
}

.rank-sparkline-dot.current {
  fill: var(--purple-dark);
  stroke: var(--purple-dark);
}

.rank-sparkline small {
  max-width: 168px;
  color: var(--faint);
  font-size: 11px;
  line-height: 1.25;
  text-align: right;
}

.rank-sparkline.empty {
  align-content: center;
  min-height: 68px;
}

.rank-history-slot {
  max-height: 1800px;
  animation: rankHistorySlotOpen 440ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.rank-history-slot.closing {
  animation: rankHistorySlotClose 360ms cubic-bezier(0.4, 0, 0.2, 1) 220ms both;
}

.rank-history-panel {
  position: relative;
  z-index: 20;
  display: grid;
  gap: 18px;
  margin-top: 4px;
  padding: 24px;
  border: 1px solid rgba(82, 38, 96, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 42px rgba(43, 0, 61, 0.08);
  transform-origin: top center;
  animation: rankHistorySlideDown 360ms cubic-bezier(0.2, 0.8, 0.2, 1) 170ms both;
}

.rank-history-panel.closing {
  animation: rankHistorySlideUp 220ms cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes rankHistorySlotOpen {
  from {
    max-height: 0;
  }

  to {
    max-height: 1800px;
  }
}

@keyframes rankHistorySlotClose {
  from {
    max-height: 1800px;
  }

  to {
    max-height: 0;
  }
}

@keyframes rankHistorySlideDown {
  from {
    opacity: 0;
    clip-path: inset(0 0 100% 0 round 16px);
    transform: translateY(-22px);
  }

  to {
    opacity: 1;
    clip-path: inset(0 0 0 0 round 16px);
    transform: translateY(0);
  }
}

@keyframes rankHistorySlideUp {
  from {
    opacity: 1;
    clip-path: inset(0 0 0 0 round 16px);
    transform: translateY(0);
  }

  to {
    opacity: 0;
    clip-path: inset(0 0 100% 0 round 16px);
    transform: translateY(-22px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .rank-history-slot,
  .rank-history-panel {
    animation: none;
  }
}

.rank-history-close {
  position: absolute;
  top: 16px;
  right: 16px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 10px;
  color: var(--muted);
  background: rgba(82, 38, 96, 0.06);
  cursor: pointer;
  transition:
    background 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.rank-history-close:hover {
  color: var(--purple-dark);
  background: rgba(82, 38, 96, 0.1);
  transform: translateY(-1px);
}

.rank-history-close-icon {
  display: block;
  width: 9px;
  height: 9px;
  border-top: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: translateY(2px) rotate(45deg);
}

.rank-history-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding-right: 44px;
}

.rank-history-head span {
  color: var(--faint);
  font-size: 11px;
  font-weight: 820;
  letter-spacing: 0.12em;
}

.rank-history-head h2 {
  margin: 5px 0 0;
  color: var(--ink);
  font-size: 26px;
  line-height: 1.2;
}

.rank-history-summary {
  display: grid;
  gap: 4px;
  justify-items: end;
  color: var(--muted);
}

.rank-history-summary strong {
  color: var(--purple-dark);
  font-size: 30px;
  line-height: 1;
}

.rank-history-summary small {
  color: var(--muted);
  font-size: 12px;
}

.rank-history-chart {
  position: relative;
  overflow: visible;
  padding: 6px 0 2px;
}

.rank-history-chart svg {
  display: block;
  min-width: 680px;
  width: 100%;
  height: auto;
}

.rank-history-grid {
  stroke: rgba(82, 38, 96, 0.12);
  stroke-width: 1;
}

.rank-history-line {
  fill: none;
  stroke: var(--purple);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4;
}

.rank-history-dot {
  fill: #fff;
  stroke: var(--purple);
  stroke-width: 2;
  cursor: pointer;
  transition:
    r 140ms ease,
    fill 140ms ease,
    stroke 140ms ease;
}

.rank-history-dot.current {
  fill: var(--purple-dark);
  stroke: var(--purple-dark);
}

.rank-history-dot:hover {
  fill: var(--purple-soft);
  stroke: var(--purple-dark);
}

.rank-history-axis-label {
  fill: var(--faint);
  font-size: 10px;
  font-weight: 720;
  letter-spacing: 0;
  pointer-events: none;
}

.rank-history-tooltip {
  position: absolute;
  z-index: 100;
  display: grid;
  gap: 3px;
  min-width: 128px;
  padding: 10px 11px;
  border: 1px solid rgba(82, 38, 96, 0.14);
  border-radius: 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 16px 34px rgba(43, 0, 61, 0.14);
  pointer-events: none;
  transform: translate(-50%, calc(-100% - 12px));
  backdrop-filter: blur(10px);
}

.rank-history-tooltip strong {
  color: var(--ink);
  font-size: 13px;
}

.rank-history-tooltip span {
  font-size: 12px;
}

.rank-history-table {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.62);
}

.rank-history-table > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 90px 100px;
  gap: 12px;
  align-items: center;
  padding: 11px 14px;
  border-bottom: 1px solid rgba(82, 38, 96, 0.08);
  color: var(--muted);
  font-size: 13px;
}

.rank-history-table > div:last-child {
  border-bottom: 0;
}

.rank-history-table-head {
  background: rgba(91, 53, 107, 0.06);
  color: var(--purple);
  font-size: 12px;
  font-weight: 820;
}

.rank-history-table strong {
  color: var(--ink);
}

.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.48fr);
  gap: 22px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 38px 52px;
}

.articles-layout {
  align-items: start;
}

.page-layout.single {
  display: block;
}

.lead-issue {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px;
  gap: 22px;
  width: min(960px, 100%);
  margin-top: 18px;
  padding: 26px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 14px;
  background: var(--page-gradient-soft);
  box-shadow: var(--shadow);
  text-align: left;
}

.lead-issue::before {
  content: "";
  position: absolute;
  inset: 10px;
  z-index: -1;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(250, 211, 255, 0.8), rgba(206, 176, 255, 0.6));
  filter: blur(18px);
}

.lead-kicker {
  margin-bottom: 8px;
  color: var(--faint);
  font-size: 12px;
  font-weight: 720;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lead-copy h2 {
  margin: 0;
  color: var(--ink);
  font-size: 30px;
  line-height: 1.15;
}

.lead-copy p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.lead-score {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 160px;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(145deg, var(--purple), var(--purple-dark));
  box-shadow: 0 20px 38px rgba(43, 0, 61, 0.22);
}

.lead-score span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
}

.lead-score strong {
  margin: 5px 0;
  font-size: 44px;
  line-height: 1;
}

.lead-score small {
  color: rgba(255, 255, 255, 0.74);
  font-size: 12px;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  width: min(980px, 100%);
  margin: 4px auto 0;
}

.stat-card {
  min-height: 118px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 14px 34px rgba(43, 0, 61, 0.06);
  text-align: left;
}

.stat-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 680;
}

.stat-value {
  margin-top: 12px;
  color: var(--ink);
  font-size: 33px;
  font-weight: 840;
}

.stat-hint {
  margin-top: 5px;
  color: var(--faint);
  font-size: 12px;
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1.42fr) minmax(340px, 0.58fr);
  gap: 22px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 28px 38px 46px;
}

.main,
.side {
  display: grid;
  gap: 22px;
  align-content: start;
}

.section {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--page-gradient-soft);
  box-shadow: 0 18px 42px rgba(43, 0, 61, 0.07);
  backdrop-filter: blur(10px);
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 22px 16px;
  border-bottom: 1px solid var(--line);
}

.section-title {
  margin: 5px 0 0;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.2;
}

.section-action {
  color: var(--muted);
  font-size: 12px;
}

.trend-list {
  display: grid;
}

.trend-row {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  padding: 19px 22px;
  border-bottom: 1px solid var(--line);
}

.trend-row:last-child {
  border-bottom: 0;
}

.trend-row.compact {
  padding: 13px 0;
  border-bottom-color: rgba(82, 38, 96, 0.1);
}

.rank {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  color: #fff;
  background: var(--purple);
  font-weight: 820;
  box-shadow: 0 10px 20px rgba(91, 53, 107, 0.18);
}

.trend-headline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.trend-headline h3 {
  margin: 0;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.35;
}

.trend-score-inline {
  color: var(--purple);
  font-size: 18px;
  font-weight: 830;
  white-space: nowrap;
}

.representative {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 11px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  white-space: nowrap;
}

.pill.good {
  color: var(--good);
  border-color: rgba(20, 122, 87, 0.24);
  background: var(--good-soft);
}

.pill.warn {
  color: var(--warn);
  border-color: rgba(163, 91, 0, 0.24);
  background: var(--warn-soft);
}

.reason-list {
  display: grid;
  gap: 5px;
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.group-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  padding: 20px;
}

.group-card {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--page-gradient-soft);
  box-shadow: 0 12px 28px rgba(43, 0, 61, 0.06);
}

.group-title {
  margin-bottom: 14px;
  color: var(--purple);
  font-size: 17px;
  font-weight: 820;
}

.group-trends {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.category-trend-card {
  min-width: 0;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 24px rgba(43, 0, 61, 0.05);
}

.category-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 13px;
}

.category-rank {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 17px;
  font-weight: 880;
}

.category-score {
  color: var(--purple);
  font-size: 13px;
  font-weight: 780;
}

.category-trend-card h3 {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.25;
}

.category-trend-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.bar-list {
  display: grid;
  gap: 10px;
  padding: 19px 22px 22px;
}

.volume-map-layer {
  position: sticky;
  top: 18px;
  align-self: start;
  max-height: calc(100vh - 36px);
  overflow: hidden;
}

.smooth-volume-map-layer {
  position: relative;
  top: auto;
  will-change: transform;
}

.volume-map-list {
  max-height: calc(100vh - 116px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(91, 53, 107, 0.35) transparent;
}

.volume-map-list::-webkit-scrollbar {
  width: 7px;
}

.volume-map-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(91, 53, 107, 0.3);
}

.bar-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) 44px;
  gap: 10px;
  align-items: center;
  min-height: 28px;
  font-size: 13px;
}

.bar-label {
  overflow: hidden;
  color: var(--ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bar-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(82, 38, 96, 0.1);
}

.bar-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--purple), #ca8cff);
}

.bar-value {
  color: var(--muted);
  text-align: right;
}

.article-list {
  display: grid;
}

.article {
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}

.article:last-child {
  border-bottom: 0;
}

.article-source {
  margin-bottom: 6px;
  color: var(--faint);
  font-size: 12px;
  font-weight: 680;
}

.article h3 {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.45;
}

.article p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.report-text {
  max-height: 520px;
  margin: 0;
  padding: 19px 22px 24px;
  overflow: auto;
  color: var(--muted);
  white-space: pre-wrap;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.58;
}

.report-document {
  display: grid;
  gap: 0;
  padding: 34px clamp(20px, 4vw, 52px) 44px;
  color: var(--muted);
}

.report-document.compact {
  max-height: 640px;
  overflow: auto;
}

.selected-report-document {
  max-height: none;
  overflow: visible;
}

.report-page {
  display: grid;
  gap: 22px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 38px 52px;
}

.guide-page {
  display: grid;
  gap: 22px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 38px 52px;
}

.feedback-page {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 38px 52px;
}

.feedback-panel {
  padding: 30px;
}

.feedback-panel h2 {
  margin: 7px 0 10px;
  color: var(--ink);
  font-size: 32px;
  line-height: 1.18;
}

.feedback-panel > p {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.feedback-form {
  display: grid;
  gap: 16px;
}

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

.feedback-form label span {
  color: var(--purple);
  font-size: 12px;
  font-weight: 820;
  letter-spacing: 0.08em;
}

.feedback-form input,
.feedback-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.38);
  font: inherit;
}

.feedback-form input {
  min-height: 46px;
  padding: 0 14px;
}

.feedback-form textarea {
  resize: vertical;
  min-height: 170px;
  padding: 13px 14px;
  line-height: 1.6;
}

.feedback-form input:focus,
.feedback-form textarea:focus {
  outline: 2px solid rgba(91, 53, 107, 0.18);
  border-color: var(--line-strong);
}

.feedback-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 4px;
}

.feedback-actions button {
  min-height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  color: #fff;
  background: var(--purple-dark);
  cursor: pointer;
  box-shadow: 0 12px 26px rgba(43, 0, 61, 0.16);
}

.feedback-actions button:disabled {
  cursor: wait;
  opacity: 0.68;
}

.feedback-actions .success,
.feedback-actions .error-text {
  margin: 0;
  font-size: 13px;
}

.feedback-actions .success {
  color: var(--good);
}

.feedback-actions .error-text {
  color: #b42318;
}

.info-page {
  max-width: 940px;
  margin: 0 auto;
  padding: 0 38px 52px;
}

.info-panel {
  padding: 36px clamp(24px, 4vw, 52px) 44px;
}

.info-panel h2 {
  max-width: 760px;
  margin: 8px 0 14px;
  color: var(--ink);
  font-size: 34px;
  line-height: 1.18;
}

.info-intro {
  max-width: 780px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.75;
}

.info-section-list {
  display: grid;
  gap: 24px;
  margin-top: 34px;
}

.info-section {
  max-width: 820px;
}

.info-section h3 {
  margin: 0 0 8px;
  color: var(--purple-dark);
  font-size: 20px;
  line-height: 1.3;
}

.info-section p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 38px 34px;
  color: var(--faint);
  font-size: 13px;
}

.site-footer > span {
  color: var(--purple);
  font-weight: 820;
}

.site-footer div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.site-footer button {
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
  transition:
    color 160ms ease,
    transform 160ms ease;
}

.site-footer button:hover {
  color: var(--purple-dark);
  transform: translateY(-1px);
}

.guided-surface {
  position: relative;
}

.section.guided-surface {
  overflow: visible;
}

.guide-callout {
  position: absolute;
  z-index: 5;
  width: 210px;
  padding: 12px 13px;
  border: 1px solid rgba(91, 53, 107, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 34px rgba(43, 0, 61, 0.12);
  backdrop-filter: blur(10px);
}

.guide-callout strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.3;
}

.guide-callout p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.home-page .guide-callout,
.page-layout .guide-callout,
.report-page .guide-callout {
  display: none;
}

.guide-callout::after {
  content: "";
  position: absolute;
  background: rgba(91, 53, 107, 0.38);
}

.guide-callout::before {
  content: "";
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--purple);
  box-shadow: 0 0 0 5px rgba(91, 53, 107, 0.08);
}

.guide-callout.line-right::after {
  top: 50%;
  right: -64px;
  width: 64px;
  height: 1px;
}

.guide-callout.line-right::before {
  top: calc(50% - 3px);
  right: -70px;
}

.guide-callout.line-left::after {
  top: 50%;
  left: -64px;
  width: 64px;
  height: 1px;
}

.guide-callout.line-left::before {
  top: calc(50% - 3px);
  left: -70px;
}

.guide-callout.line-down::after {
  left: 50%;
  bottom: -58px;
  width: 1px;
  height: 58px;
}

.guide-callout.line-down::before {
  left: calc(50% - 3px);
  bottom: -66px;
}

.guide-callout.line-up::after {
  left: 50%;
  top: -58px;
  width: 1px;
  height: 58px;
}

.guide-callout.line-up::before {
  left: calc(50% - 3px);
  top: -66px;
}

.home-rank-guide {
  top: 118px;
  left: -22px;
}

.home-keyword-guide {
  top: -22px;
  left: 50%;
  transform: translateX(-50%);
}

.home-score-guide {
  top: 118px;
  right: -22px;
}

.home-color-guide {
  right: 110px;
  bottom: 18px;
}

.category-box-guide {
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
}

.category-card-guide {
  top: 110px;
  right: -18px;
}

.article-source-guide {
  top: -28px;
  left: 50%;
  transform: translateX(-50%);
}

.volume-bar-guide {
  top: 76px;
  right: -18px;
}

.report-rising-guide {
  top: -26px;
  left: 50%;
  transform: translateX(-50%);
}

.report-panel-guide {
  top: -28px;
  left: 42px;
}

.report-nav-guide {
  top: 96px;
  right: -18px;
}

.guide-hero {
  padding: 34px;
  background: var(--page-gradient-soft);
}

.guide-hero h2,
.guide-score h2 {
  max-width: 780px;
  margin: 7px 0 12px;
  color: var(--ink);
  font-size: 34px;
  line-height: 1.18;
}

.guide-hero p {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.guide-highlight {
  display: inline-grid;
  grid-template-columns: auto auto auto;
  gap: 10px;
  align-items: center;
  margin-top: 22px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
}

.guide-highlight span,
.guide-highlight small {
  color: var(--faint);
  font-size: 12px;
  font-weight: 720;
}

.guide-highlight strong {
  color: var(--ink);
  font-size: 14px;
}

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

.guide-grid,
.guide-page-map,
.guide-score {
  display: none;
}

.guide-card {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 16px 36px rgba(43, 0, 61, 0.06);
}

.guide-card h3 {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.25;
}

.guide-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.guide-card ul {
  display: grid;
  gap: 7px;
  margin: 15px 0 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.guide-card strong {
  color: var(--ink);
}

.guide-color-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.guide-color-list > div {
  display: grid;
  grid-template-columns: 22px 84px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.guide-color-list p {
  font-size: 13px;
}

.color-chip {
  display: block;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  box-shadow: 0 0 0 4px rgba(82, 38, 96, 0.08);
}

.color-chip.purple {
  background: var(--purple);
}

.color-chip.green {
  background: var(--good);
}

.color-chip.amber {
  background: var(--warn);
}

.color-chip.pale {
  background: var(--purple-soft);
}

.guide-score {
  padding: 28px;
}

.guide-page-map {
  padding: 28px;
}

.guide-page-map h2 {
  margin: 7px 0 18px;
  color: var(--ink);
  font-size: 28px;
  line-height: 1.2;
}

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

.page-guide-grid article {
  min-width: 0;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
}

.page-guide-grid strong {
  display: block;
  color: var(--purple);
  font-size: 15px;
}

.page-guide-grid p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.guide-annotated-section {
  overflow: visible;
  padding: 28px;
}

.guide-annotated-section h2 {
  margin: 7px 0 22px;
  color: var(--ink);
  font-size: 28px;
  line-height: 1.2;
}

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

.annotated-screen {
  min-height: 260px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--page-gradient-soft);
  box-shadow: 0 14px 32px rgba(43, 0, 61, 0.06);
}

.annotated-screen-title {
  margin-bottom: 36px;
  color: var(--purple);
  font-size: 15px;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.mock-keyword-card,
.mock-category-box,
.mock-article-row,
.mock-report-box {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.86);
}

.mock-keyword-card {
  grid-template-columns: 52px minmax(0, 1fr) auto;
  align-items: center;
}

.mock-rank {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 18px;
  font-weight: 880;
}

.mock-keyword-card strong,
.mock-category-box strong,
.mock-article-row strong,
.mock-report-box strong {
  color: var(--ink);
  font-size: 17px;
}

.mock-keyword-card p,
.mock-category-box p,
.mock-article-row p,
.mock-report-box p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.mock-keyword-card b {
  color: var(--ink);
  font-size: 26px;
}

.mock-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mock-pills span {
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  font-size: 11px;
}

.mock-pills span.good {
  color: var(--good);
  border-color: rgba(20, 122, 87, 0.24);
  background: var(--good-soft);
}

.mock-category-box small,
.mock-report-box small,
.mock-article-row small {
  color: var(--faint);
  font-size: 12px;
}

.mock-rank-guide {
  top: 98px;
  left: 8px;
}

.mock-score-guide {
  top: 98px;
  right: 8px;
}

.mock-category-guide {
  top: 70px;
  left: 50%;
  transform: translateX(-50%);
}

.mock-article-guide {
  top: 112px;
  left: 10px;
}

.mock-report-guide {
  top: 112px;
  right: 10px;
}

.annotated-screen-list {
  display: grid;
  gap: 22px;
}

.annotated-wide-card {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--page-gradient-soft);
  box-shadow: 0 14px 32px rgba(43, 0, 61, 0.06);
}

.annotated-layout {
  display: grid;
  grid-template-columns: minmax(170px, 0.32fr) minmax(0, 1fr) minmax(170px, 0.32fr);
  gap: 28px;
  align-items: center;
}

.annotated-preview {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
}

.annotated-notes {
  display: grid;
  gap: 14px;
}

.annotated-note {
  position: relative;
  padding: 13px 14px;
  border: 1px solid rgba(91, 53, 107, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 28px rgba(43, 0, 61, 0.09);
}

.annotated-note strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
}

.annotated-note p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.annotated-note::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 26px;
  height: 1px;
  background: rgba(91, 53, 107, 0.34);
}

.annotated-note::before {
  content: "";
  position: absolute;
  top: calc(50% - 3px);
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--purple);
  box-shadow: 0 0 0 5px rgba(91, 53, 107, 0.08);
}

.annotated-note.right::after {
  right: -26px;
}

.annotated-note.right::before {
  right: -34px;
}

.annotated-note.left::after {
  left: -26px;
}

.annotated-note.left::before {
  left: -34px;
}

.home-preview {
  display: grid;
  gap: 12px;
}

.home-preview .keyword-card {
  grid-template-columns: 58px minmax(0, 1fr) 132px;
  padding: 14px;
}

.home-preview .rank-sparkline {
  min-width: 132px;
}

.home-preview .rank-sparkline svg {
  width: 132px;
}

.home-preview .keyword-rank {
  width: 48px;
  height: 48px;
}

.home-preview .keyword-main h3 {
  font-size: 20px;
}

.home-annotated-card {
  overflow: visible;
  padding: 22px 26px 28px;
}

.home-annotated-card .annotated-layout {
  position: relative;
  display: block;
  min-height: 430px;
  padding: 26px 0;
}

.home-annotated-card .annotated-preview {
  width: min(860px, 100%);
  margin: 0 auto;
}

.home-annotated-card .home-preview {
  gap: 14px;
  padding: 20px;
}

.home-annotated-card .home-preview .keyword-card {
  grid-template-columns: 68px minmax(0, 1fr) 170px;
  gap: 18px;
  padding: 18px;
}

.home-annotated-card .home-preview .keyword-rank {
  width: 54px;
  height: 54px;
}

.home-annotated-card .home-preview .keyword-main h3 {
  font-size: 24px;
}

.home-annotated-card .home-preview .rank-sparkline {
  min-width: 170px;
}

.home-annotated-card .home-preview .rank-sparkline svg {
  width: 168px;
  height: 58px;
}

.home-annotated-card .annotated-notes {
  position: absolute;
  top: 108px;
  z-index: 3;
  width: 184px;
}

.home-annotated-card .annotated-notes.left {
  left: -118px;
}

.home-annotated-card .annotated-notes.right {
  right: -118px;
}

.category-preview .group-card {
  box-shadow: none;
}

.category-preview .group-trends {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.category-preview .category-trend-card {
  min-height: 260px;
  padding: 16px;
}

.category-preview .category-trend-card h3 {
  font-size: 18px;
}

.category-preview .category-trend-card p {
  font-size: 12px;
}

.articles-preview {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 16px;
  align-items: stretch;
}

.articles-preview .article {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.86);
}

.preview-volume-map {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
}

.preview-volume-list {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.preview-volume-row {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) 28px;
  gap: 8px;
  align-items: center;
}

.preview-volume-row span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-volume-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(91, 53, 107, 0.1);
}

.preview-volume-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--purple);
}

.preview-volume-row strong {
  color: var(--muted);
  font-size: 11px;
  font-weight: 720;
  text-align: right;
}

.report-preview .report-lead-card.primary {
  grid-row: auto;
  min-height: 230px;
  box-shadow: 0 14px 28px rgba(43, 0, 61, 0.08);
}

.report-preview::before {
  content: "Today Rising Issues";
  display: block;
  margin-bottom: 12px;
  color: var(--purple);
  font-size: 11px;
  font-weight: 780;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.score-breakdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 20px;
}

.score-breakdown > div {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
}

.score-breakdown span {
  display: block;
  color: var(--purple);
  font-size: 34px;
  line-height: 1;
  font-weight: 850;
}

.score-breakdown strong {
  display: block;
  margin-top: 10px;
  color: var(--ink);
  font-size: 15px;
}

.score-breakdown p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.report-lead-section {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--page-gradient-soft);
  box-shadow: var(--shadow);
}

.report-lead-section h2 {
  margin: 6px 0 20px;
  color: var(--ink);
  font-size: 30px;
  line-height: 1.18;
}

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

.report-lead-card {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 12px 30px rgba(43, 0, 61, 0.06);
  width: 100%;
  color: inherit;
  cursor: pointer;
  font: inherit;
  text-align: left;
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease,
    background 180ms ease;
}

.report-lead-card:hover,
.report-lead-card.active {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 40px rgba(43, 0, 61, 0.11);
  transform: translateY(-2px);
}

.report-lead-card.active {
  outline: 2px solid rgba(91, 53, 107, 0.18);
  outline-offset: 3px;
}

.report-lead-card.primary {
  grid-row: span 2;
  display: grid;
  align-content: center;
  min-height: 220px;
  background: var(--page-gradient);
}

.lead-rank {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 18px;
  border-radius: 14px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 19px;
  font-weight: 880;
}

.report-lead-card h3 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.25;
}

.report-lead-card.primary h3 {
  font-size: 32px;
}

.report-lead-card p {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.report-drawer {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 42px rgba(43, 0, 61, 0.08);
  animation: reportDrawerFade 180ms ease both;
  transform-origin: top center;
}

.report-drawer-header {
  padding: 22px 24px 16px;
  border-bottom: 1px solid var(--line);
}

.report-drawer-header h2 {
  margin: 6px 0 0;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.22;
}

.report-drawer-document {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

@keyframes reportDrawerFade {
  from {
    opacity: 0;
    transform: translateY(4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.report-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 22px;
  align-items: start;
}

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

.category-report-list {
  display: grid;
  gap: 16px;
  padding: 20px;
}

.trend-report-card {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 12px 28px rgba(43, 0, 61, 0.05);
}

.trend-report-head {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 13px;
  align-items: start;
}

.trend-report-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: 21px;
  line-height: 1.25;
}

.report-summary {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.report-summary strong {
  color: var(--ink);
}

.report-summary a {
  color: var(--purple);
  font-weight: 720;
  text-decoration: underline;
  text-decoration-color: rgba(91, 53, 107, 0.28);
  text-underline-offset: 3px;
}

.report-reason-list {
  display: grid;
  gap: 6px;
  margin: 14px 0 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.report-article-links {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.mini-label {
  color: var(--faint);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.report-article-links a {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.68);
}

.report-article-links a:hover {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.92);
}

.report-article-links span {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  color: #fff;
  background: var(--purple);
  font-size: 12px;
  font-weight: 800;
}

.report-article-links strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.report-article-links small {
  color: var(--faint);
  font-size: 12px;
}

.category-report-nav {
  position: sticky;
  top: 18px;
}

.category-nav-list {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.category-nav-list button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 12px 13px;
  border: 1px solid transparent;
  border-radius: 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.54);
  cursor: pointer;
  text-align: left;
}

.category-nav-list button:hover,
.category-nav-list button.active {
  color: var(--ink);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.92);
}

.category-nav-list button.active {
  box-shadow: 0 10px 22px rgba(43, 0, 61, 0.06);
}

.category-nav-list span {
  font-size: 14px;
  font-weight: 760;
}

.category-nav-list small {
  color: var(--faint);
  font-size: 11px;
  font-weight: 800;
}

.report-title {
  max-width: 860px;
  margin: 0 0 24px;
  color: var(--purple-dark);
  font-size: 36px;
  line-height: 1.16;
  font-weight: 850;
}

.report-heading {
  margin: 34px 0 18px;
  padding: 20px 0 0;
  border-top: 1px solid rgba(82, 38, 96, 0.14);
  color: var(--purple-dark);
  font-size: 24px;
  line-height: 1.28;
  font-weight: 860;
}

.report-heading:first-child,
.report-title + .report-heading {
  margin-top: 8px;
  padding-top: 0;
  border-top: 0;
}

.report-subheading {
  margin: 30px 0 16px;
  padding: 0 0 0 14px;
  border-left: 5px solid var(--purple-dark);
  color: var(--ink);
  font-size: 23px;
  line-height: 1.32;
  font-weight: 870;
}

.report-minor-heading {
  margin: 22px 0 12px;
  color: var(--purple);
  font-size: 17px;
  line-height: 1.42;
  font-weight: 840;
}

.report-item-title {
  display: flex;
  align-items: center;
  gap: 13px;
  margin: 18px 0 11px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--page-gradient-soft);
  box-shadow: 0 10px 24px rgba(43, 0, 61, 0.05);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.35;
}

.report-item-number {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 17px;
  font-weight: 880;
}

.report-numbered-line {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 14px;
  max-width: 920px;
  margin: 9px 0 9px 16px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
}

.report-numbered-marker {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  color: #fff;
  background: var(--purple-dark);
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
}

.report-numbered-line p {
  margin: 1px 0 0;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.7;
}

.report-numbered-line strong {
  color: var(--ink);
  font-weight: 800;
}

.report-bullet {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 12px;
  max-width: 940px;
  margin: 10px 0;
  color: var(--muted);
}

.report-bullet p {
  margin: 0;
  font-size: 15px;
  line-height: 1.72;
}

.report-bullet strong {
  display: inline-block;
  margin-right: 4px;
  color: var(--ink);
  font-size: 15.5px;
  font-weight: 860;
}

.report-dot {
  width: 7px;
  height: 7px;
  margin-top: 10px;
  border-radius: 999px;
  background: var(--purple);
  box-shadow: 0 0 0 4px rgba(91, 53, 107, 0.08);
}

.report-paragraph {
  max-width: 920px;
  margin: 10px 0;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.78;
}

.report-link {
  color: var(--purple);
  font-weight: 720;
  text-decoration: underline;
  text-decoration-color: rgba(91, 53, 107, 0.32);
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.report-link:hover {
  color: var(--purple-dark);
  text-decoration-color: var(--purple-dark);
}

.report-space {
  height: 8px;
}

.empty,
.error {
  padding: 30px;
  color: var(--muted);
}

.error {
  color: #b42318;
}

.page-state {
  min-height: 100vh;
  display: grid;
  place-items: center;
}

@media (max-width: 1060px) {
  .topbar {
    grid-template-columns: 1fr;
    justify-items: center;
    margin-bottom: 48px;
  }

  .controls {
    justify-content: center;
  }

  .hero-grid,
  .layout,
  .page-layout,
  .report-shell {
    grid-template-columns: 1fr;
  }

  .category-report-nav {
    position: static;
    order: -1;
  }

  .volume-map-layer {
    position: static;
    max-height: none;
  }

  .volume-map-list {
    max-height: 420px;
  }

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

  .report-lead-card.primary {
    grid-column: 1 / -1;
    grid-row: auto;
  }

  .group-grid {
    grid-template-columns: 1fr;
  }

  .guide-grid,
  .score-breakdown,
  .page-guide-grid,
  .annotated-screen-grid {
    grid-template-columns: 1fr 1fr;
  }

  .guide-callout {
    position: relative;
    inset: auto;
    width: auto;
    margin: 0 0 12px;
    transform: none;
  }

  .guide-callout::before,
  .guide-callout::after {
    display: none;
  }

  .annotated-layout {
    grid-template-columns: 1fr;
  }

  .home-annotated-card .annotated-layout {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 0;
  }

  .home-annotated-card .annotated-notes {
    position: static;
    width: auto;
  }

  .annotated-notes.left,
  .annotated-notes.right {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .annotated-note::before,
  .annotated-note::after {
    display: none;
  }

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

  .articles-preview {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .hero {
    padding: 18px 16px 28px;
  }

  .nav-links {
    gap: 18px;
    flex-wrap: wrap;
    font-size: 13px;
  }

  .hero-copy h1 {
    font-size: 38px;
  }

  .hero-copy > p {
    font-size: 15px;
  }

  .lead-issue {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .stat-grid {
    grid-template-columns: 1fr 1fr;
  }

  .layout {
    padding: 18px 16px 34px;
  }

  .home-page,
  .page-layout,
  .report-page,
  .guide-page,
  .info-page {
    padding: 0 16px 34px;
  }

  .info-panel {
    padding: 24px 20px 30px;
  }

  .info-panel h2 {
    font-size: 26px;
  }

  .site-footer {
    display: grid;
    justify-items: center;
    padding: 0 16px 28px;
    text-align: center;
  }

  .site-footer div {
    justify-content: center;
  }

  .hero-copy h1 {
    font-size: 56px;
  }

  .preview-label {
    font-size: 28px;
  }

  .keyword-showcase {
    padding: 42px 16px;
  }

  .keyword-card {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .home-annotated-card .home-preview .keyword-card {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .keyword-card .rank-sparkline {
    grid-column: 2;
    justify-items: start;
    margin-top: 4px;
  }

  .home-annotated-card .home-preview .rank-sparkline {
    grid-column: 2;
    justify-items: start;
  }

  .keyword-card .rank-sparkline-top {
    justify-content: flex-start;
  }

  .keyword-card .rank-sparkline small {
    text-align: left;
  }

  .rank-history-panel {
    padding: 20px;
  }

  .rank-history-head {
    display: grid;
    gap: 12px;
    padding-right: 36px;
  }

  .rank-history-summary {
    justify-items: start;
  }

  .rank-history-chart svg {
    min-width: 620px;
  }

  .rank-history-table > div {
    grid-template-columns: minmax(0, 1fr) 62px 72px;
    gap: 8px;
    padding: 10px 12px;
    font-size: 12px;
  }

  .keyword-rank {
    width: 48px;
    height: 48px;
  }

  .group-grid {
    padding: 14px;
  }

  .group-trends {
    grid-template-columns: 1fr;
  }

  .trend-headline {
    display: grid;
  }

  .bar-row {
    grid-template-columns: 82px minmax(0, 1fr) 36px;
  }

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

  .guide-hero,
  .guide-score {
    padding: 22px;
  }

  .guide-hero h2,
  .guide-score h2 {
    font-size: 26px;
  }

  .guide-grid,
  .score-breakdown,
  .page-guide-grid,
  .annotated-screen-grid {
    grid-template-columns: 1fr;
  }

  .guide-annotated-section {
    padding: 22px;
  }

  .guide-annotated-section h2 {
    font-size: 24px;
    line-height: 1.25;
  }

  .annotated-screen-list {
    gap: 16px;
  }

  .mock-keyword-card {
    grid-template-columns: 52px minmax(0, 1fr);
  }

  .mock-keyword-card b {
    grid-column: 2;
    font-size: 22px;
  }

  .annotated-wide-card {
    padding: 16px;
    border-radius: 14px;
  }

  .annotated-notes.left,
  .annotated-notes.right {
    grid-template-columns: 1fr;
  }

  .annotated-layout {
    gap: 14px;
  }

  .annotated-preview {
    padding: 12px;
    border-radius: 13px;
  }

  .annotated-note {
    padding: 11px 12px;
    box-shadow: none;
  }

  .annotated-screen-title {
    margin-bottom: 14px;
    font-size: 13px;
  }

  .home-annotated-card {
    padding: 16px;
  }

  .home-annotated-card .annotated-layout {
    min-height: 0;
    padding: 0;
  }

  .home-annotated-card .annotated-preview {
    width: 100%;
  }

  .home-annotated-card .home-preview {
    gap: 10px;
    padding: 12px;
  }

  .home-annotated-card .home-preview .keyword-card {
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 12px;
    padding: 13px;
    border-radius: 12px;
  }

  .home-annotated-card .home-preview .keyword-rank {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 16px;
  }

  .home-annotated-card .home-preview .keyword-main h3 {
    font-size: 20px;
  }

  .home-annotated-card .home-preview .keyword-main p {
    font-size: 12px;
  }

  .home-annotated-card .home-preview .rank-sparkline {
    display: none;
  }

  .category-preview .group-card {
    padding: 14px;
  }

  .category-preview .group-trends {
    grid-template-columns: 1fr;
  }

  .category-preview .category-trend-card {
    min-height: 0;
    padding: 14px;
  }

  .category-preview .category-trend-card:nth-child(n + 3) {
    display: none;
  }

  .articles-preview {
    gap: 12px;
  }

  .preview-volume-map {
    padding: 14px;
  }

  .preview-volume-list {
    margin-top: 12px;
  }

  .report-preview::before {
    margin-bottom: 8px;
    font-size: 10px;
  }

  .report-preview .report-lead-card.primary {
    min-height: 0;
    padding: 16px;
  }

  .home-preview .keyword-card {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .guide-highlight {
    grid-template-columns: 1fr;
    border-radius: 14px;
  }

  .guide-color-list > div {
    grid-template-columns: 22px minmax(0, 1fr);
  }

  .guide-color-list p {
    grid-column: 2;
  }

  .report-lead-grid {
    grid-template-columns: 1fr;
  }

  .report-lead-card.primary h3 {
    font-size: 24px;
  }

  .report-article-links a {
    grid-template-columns: 26px minmax(0, 1fr);
  }

  .report-article-links small {
    grid-column: 2;
  }

  .report-document {
    padding: 22px 16px 28px;
  }

  .report-title {
    font-size: 26px;
  }

  .report-heading {
    font-size: 19px;
  }

  .report-item-title {
    align-items: flex-start;
    font-size: 15px;
  }
}
