:root {
  --ink: #12241f;
  --muted: #61746d;
  --line: #dce7e1;
  --paper: #f7faf8;
  --white: #ffffff;
  --green: #0e7350;
  --green-2: #14a36f;
  --green-soft: #dff5ea;
  --mint: #b8ead3;
  --amber: #ca7a12;
  --amber-soft: #fff2d7;
  --red: #a83d3d;
  --red-soft: #fde8e8;
  --shadow: 0 18px 45px rgba(20, 65, 50, 0.08);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 85% 4%, rgba(184, 234, 211, 0.36), transparent 26rem),
    var(--paper);
}

.auth-gate {
  min-height: 100vh;
  padding: 42px 20px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 20% 10%, rgba(70, 213, 154, 0.18), transparent 28rem),
    var(--ink);
}

.auth-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.34;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 58px 58px;
}

.auth-backdrop span {
  position: absolute;
  width: 280px;
  aspect-ratio: 1;
  border: 1px solid rgba(184, 234, 211, 0.22);
  border-radius: 50%;
}

.auth-backdrop span:nth-child(1) {
  top: -120px;
  right: 6vw;
}

.auth-backdrop span:nth-child(2) {
  width: 440px;
  bottom: -250px;
  left: 5vw;
}

.auth-backdrop span:nth-child(3) {
  width: 130px;
  top: 36%;
  left: 14%;
  background: rgba(20, 163, 111, 0.08);
}

.auth-card {
  width: min(480px, 100%);
  position: relative;
  z-index: 1;
  padding: 38px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.28);
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 38px;
}

.auth-brand h1,
.auth-brand p,
.auth-card h2,
.auth-card p {
  margin: 0;
}

.auth-brand h1 {
  font-size: 15px;
}

.auth-card h2 {
  margin-top: 8px;
  font-size: 32px;
  letter-spacing: -0.035em;
}

.auth-copy {
  margin-top: 10px !important;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.auth-form {
  display: grid;
  gap: 16px;
  margin-top: 25px;
}

.auth-form label {
  display: grid;
  gap: 7px;
}

.auth-form label > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.auth-form input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: none;
  color: var(--ink);
  background: #fbfdfc;
}

.auth-form input:focus {
  border-color: var(--green-2);
  box-shadow: 0 0 0 4px rgba(20, 163, 111, 0.1);
}

.auth-submit {
  width: 100%;
  min-height: 48px;
  justify-content: center;
}

.text-button {
  border: 0;
  padding: 8px 10px;
  color: var(--green);
  font-size: 12px;
  font-weight: 750;
  background: transparent;
}

.local-hint {
  margin-top: 18px !important;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--muted);
  background: var(--paper);
  font-size: 10px;
  line-height: 1.45;
}

.auth-error {
  margin-top: 16px !important;
  padding: 11px 13px;
  border: 1px solid #f4c8c8;
  border-radius: 10px;
  color: var(--red);
  background: var(--red-soft);
  font-size: 11px;
}

.auth-security-note {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.auth-security-note span {
  margin-right: 5px;
  color: var(--green-2);
}

.enrollment-box {
  display: grid;
  grid-template-columns: 136px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  margin-top: 20px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
}

.enrollment-box img {
  width: 136px;
  height: 136px;
  border-radius: 8px;
  background: white;
}

.enrollment-box strong,
.enrollment-box p {
  display: block;
  font-size: 11px;
}

.enrollment-box p {
  margin: 6px 0 !important;
  color: var(--muted);
  line-height: 1.4;
}

.enrollment-box code {
  display: block;
  overflow-wrap: anywhere;
  color: var(--green);
  font-size: 11px;
  font-weight: 750;
}

.recovery-codes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 22px 0;
}

.recovery-codes code {
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--paper);
  text-align: center;
  font-size: 12px;
}

.signed-user {
  display: grid;
  gap: 2px;
  text-align: right;
}

.signed-user span {
  color: var(--ink);
  font-size: 12px;
  font-weight: 750;
}

.signed-user small {
  color: var(--muted);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4vw;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand,
.topbar-actions,
.lead-title-row,
.run-heading,
.result-banner,
.feedback-actions {
  display: flex;
  align-items: center;
}

.brand {
  gap: 13px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--ink);
  display: grid;
  place-content: center;
  grid-template-columns: repeat(3, 4px);
  gap: 3px;
  transform: rotate(-5deg);
}

.brand-mark span {
  width: 4px;
  border-radius: 5px;
  background: var(--mint);
}

.brand-mark span:nth-child(1) {
  height: 11px;
}

.brand-mark span:nth-child(2) {
  height: 18px;
}

.brand-mark span:nth-child(3) {
  height: 25px;
}

.brand h1,
.brand p,
.hero h2,
.hero p,
.section-heading h3,
.section-heading p,
.lead-header h3,
.lead-header p,
.run-heading h3,
.run-heading p,
.result-banner h3,
.result-banner p,
.feedback-card h3,
.feedback-card p {
  margin: 0;
}

.brand h1 {
  font-size: 15px;
  letter-spacing: -0.01em;
}

.eyebrow {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.4;
  font-weight: 750;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.eyebrow.accent {
  color: var(--green);
}

.topbar-actions {
  gap: 18px;
}

.system-status {
  color: var(--muted);
  font-size: 12px;
}

.system-status i {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--green-2);
  box-shadow: 0 0 0 5px rgba(20, 163, 111, 0.1);
}

.persona-control {
  display: grid;
  gap: 3px;
}

.persona-control span {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.persona-control select {
  max-width: 260px;
  border: 0;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  background: transparent;
  outline: none;
}

.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  display: grid;
  place-items: center;
  font-weight: 800;
}

main {
  width: min(1460px, 92vw);
  margin: 0 auto;
  padding: 44px 0 70px;
}

.hero {
  min-height: 250px;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(260px, 0.7fr);
  align-items: center;
  overflow: hidden;
  background: var(--ink);
  border-radius: 28px;
  padding: 44px 54px;
  color: var(--white);
  position: relative;
  box-shadow: var(--shadow);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(110deg, transparent 50%, rgba(20, 163, 111, 0.12)),
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent 59px,
      rgba(255, 255, 255, 0.025) 60px
    );
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero h2 {
  max-width: 760px;
  margin-top: 12px;
  font-size: clamp(34px, 4.2vw, 63px);
  line-height: 0.99;
  letter-spacing: -0.045em;
  font-weight: 640;
}

.hero-copy {
  max-width: 650px;
  margin-top: 22px !important;
  color: #c8d7d1;
  font-size: 15px;
  line-height: 1.65;
}

.hero-visual {
  min-height: 190px;
  display: grid;
  place-items: center;
  position: relative;
}

.orb {
  width: 132px;
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-content: center;
  text-align: center;
  background:
    radial-gradient(circle at 35% 25%, #d9fff0, transparent 20%),
    linear-gradient(145deg, #46d59a, #0a8059);
  box-shadow:
    0 0 50px rgba(70, 213, 154, 0.36),
    inset 0 -12px 28px rgba(0, 60, 42, 0.32);
}

.orb span {
  font-size: 34px;
  font-weight: 800;
}

.orb small {
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.pulse {
  position: absolute;
  border: 1px solid rgba(184, 234, 211, 0.22);
  border-radius: 50%;
}

.pulse-a {
  width: 220px;
  height: 220px;
}

.pulse-b {
  width: 310px;
  height: 310px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 18px 0;
}

.metric-card {
  min-height: 126px;
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 22px 24px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
}

.metric-card span,
.metric-card small,
.info-block span,
.next-action-card > span {
  color: var(--muted);
  font-size: 11px;
}

.metric-card strong {
  font-size: 28px;
  line-height: 1;
  letter-spacing: -0.035em;
}

.metric-card small {
  font-size: 10px;
}

.metric-card.highlight {
  background: var(--green-soft);
  border-color: transparent;
}

.metric-card.highlight strong {
  color: var(--green);
  font-size: 16px;
}

.workspace {
  min-height: 680px;
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--white);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.lead-panel {
  padding: 26px 18px;
  border-right: 1px solid var(--line);
  background: #fbfdfc;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px;
}

.section-heading h3 {
  margin-top: 4px;
  font-size: 19px;
}

.section-heading.compact {
  padding: 0;
  margin-bottom: 15px;
}

.icon-button {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--green);
}

.search-wrap {
  height: 42px;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 18px 0;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
}

.search-wrap span {
  color: var(--muted);
  font-size: 20px;
}

.search-wrap input {
  min-width: 0;
  width: 100%;
  border: 0;
  outline: 0;
  font-size: 12px;
  color: var(--ink);
}

.lead-list {
  display: grid;
  gap: 8px;
  max-height: 580px;
  overflow-y: auto;
}

.lead-item {
  width: 100%;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  text-align: left;
  padding: 13px 12px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: transparent;
  color: var(--ink);
}

.lead-item:hover,
.lead-item.active {
  background: var(--white);
  border-color: var(--line);
}

.lead-item.active {
  box-shadow: 0 9px 24px rgba(16, 75, 55, 0.08);
}

.lead-avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 12px;
  font-weight: 800;
}

.lead-meta {
  min-width: 0;
}

.lead-meta strong,
.lead-meta span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lead-meta strong {
  font-size: 12px;
}

.lead-meta span {
  color: var(--muted);
  font-size: 10px;
  margin-top: 4px;
}

.engagement-dot {
  min-width: 32px;
  text-align: right;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.analysis-panel {
  padding: 34px;
  min-width: 0;
}

.empty-state {
  min-height: 570px;
  display: grid;
  place-content: center;
  justify-items: center;
  text-align: center;
  color: var(--muted);
}

.empty-state h3 {
  color: var(--ink);
  margin: 18px 0 8px;
}

.empty-state p {
  max-width: 390px;
  margin: 0;
  line-height: 1.6;
  font-size: 13px;
}

.empty-icon {
  width: 70px;
  height: 70px;
  display: grid;
  place-items: center;
  border-radius: 22px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 30px;
}

.hidden {
  display: none !important;
}

.lead-header {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  padding-bottom: 25px;
  border-bottom: 1px solid var(--line);
}

.lead-title-row {
  gap: 9px;
  margin-bottom: 10px;
}

.stage-pill,
.priority-pill,
.review-badge,
.run-status {
  border-radius: 999px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.stage-pill {
  padding: 6px 9px;
  color: var(--green);
  background: var(--green-soft);
}

.freshness {
  color: var(--muted);
  font-size: 10px;
}

.lead-header h3 {
  font-size: 28px;
  letter-spacing: -0.035em;
}

.lead-header p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.primary-button {
  min-height: 46px;
  padding: 0 20px;
  border: 0;
  border-radius: 13px;
  color: var(--white);
  background: var(--green);
  font-size: 12px;
  font-weight: 750;
  box-shadow: 0 10px 24px rgba(14, 115, 80, 0.2);
}

.primary-button:hover {
  background: #095f41;
}

.primary-button:disabled {
  opacity: 0.55;
  cursor: progress;
}

.button-spark {
  margin-right: 8px;
  color: var(--mint);
}

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

.info-block {
  min-height: 76px;
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 15px;
  border-radius: 13px;
  background: var(--paper);
}

.info-block strong {
  font-size: 13px;
}

.context-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 14px;
}

.context-card,
.guidance-card,
.product-card,
.similar-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
}

.context-card {
  padding: 20px;
}

.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 15px;
}

.card-heading h4 {
  margin: 0;
  font-size: 13px;
}

.card-heading span {
  color: var(--muted);
  font-size: 9px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag {
  padding: 7px 9px;
  border-radius: 8px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 10px;
  font-weight: 700;
}

.activity-list {
  display: grid;
  gap: 13px;
}

.activity-item {
  display: grid;
  grid-template-columns: 8px 1fr;
  gap: 11px;
}

.activity-item i {
  width: 8px;
  height: 8px;
  margin-top: 4px;
  border-radius: 50%;
  background: var(--green-2);
}

.activity-item strong,
.activity-item span {
  display: block;
  font-size: 10px;
}

.activity-item span {
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.45;
}

.run-panel,
.result-panel {
  animation: rise 0.32s ease-out;
}

.run-heading,
.result-banner {
  justify-content: space-between;
  gap: 20px;
}

.run-heading h3 {
  margin-top: 5px;
}

.run-status {
  padding: 8px 11px;
  color: var(--green);
  background: var(--green-soft);
}

.progress-track {
  height: 7px;
  margin: 25px 0 30px;
  border-radius: 20px;
  background: #e8f0ec;
  overflow: hidden;
}

.progress-track span {
  display: block;
  height: 100%;
  width: 7%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), #48d49d);
  transition: width 0.45s ease;
}

.node-timeline {
  display: grid;
  gap: 10px;
}

.node-item {
  display: grid;
  grid-template-columns: 30px 1fr auto;
  gap: 12px;
  align-items: center;
  min-height: 58px;
  padding: 11px 14px;
  border-radius: 13px;
  background: var(--paper);
}

.node-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--white);
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.node-item strong {
  font-size: 12px;
}

.node-item small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
}

.node-state {
  color: var(--green);
  font-size: 9px;
  text-transform: uppercase;
  font-weight: 800;
}

.result-banner {
  padding-bottom: 23px;
  border-bottom: 1px solid var(--line);
}

.result-banner h3 {
  margin-top: 5px;
  font-size: 25px;
}

.result-banner > div > p:last-child {
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
}

.review-badge {
  padding: 9px 12px;
}

.review-badge.review {
  color: var(--amber);
  background: var(--amber-soft);
}

.review-badge.verified {
  color: var(--green);
  background: var(--green-soft);
}

.assessment-layout {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 14px;
  margin: 18px 0;
}

.score-card,
.next-action-card {
  min-height: 160px;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 22px;
  border-radius: 17px;
}

.score-card {
  border: 1px solid var(--line);
}

.score-ring {
  width: 105px;
  height: 105px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--green-2) 0%, #e5eee9 0%);
  position: relative;
}

.score-ring::after {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 50%;
  background: var(--white);
}

.score-ring > div {
  position: relative;
  z-index: 1;
  text-align: center;
}

.score-ring strong {
  display: block;
  font-size: 28px;
  line-height: 0.9;
}

.score-ring span {
  color: var(--muted);
  font-size: 9px;
}

.score-card h4,
.next-action-card h4 {
  margin: 10px 0 5px;
}

.score-card p,
.next-action-card p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}

.priority-pill {
  display: inline-block;
  padding: 6px 9px;
  color: var(--green);
  background: var(--green-soft);
}

.next-action-card {
  display: grid;
  align-content: center;
  gap: 5px;
  color: var(--white);
  background: linear-gradient(135deg, var(--green), #0a5c42);
}

.next-action-card > span,
.next-action-card p {
  color: #c7e4d9;
}

.next-action-card h4 {
  font-size: 18px;
  line-height: 1.35;
}

.warning-box {
  margin: 16px 0;
  padding: 14px 16px;
  border-left: 4px solid var(--amber);
  border-radius: 10px;
  color: #775011;
  background: var(--amber-soft);
  font-size: 11px;
  line-height: 1.6;
}

.result-columns {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 20px;
  margin-top: 28px;
}

.product-list {
  display: grid;
  gap: 10px;
}

.product-card {
  padding: 17px;
}

.product-top {
  display: flex;
  justify-content: space-between;
  gap: 15px;
}

.product-rank {
  display: flex;
  gap: 11px;
}

.rank-number {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 11px;
  font-weight: 800;
}

.product-card h4 {
  margin: 0;
  font-size: 13px;
}

.product-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}

.fit-score {
  color: var(--green);
  font-size: 12px;
  font-weight: 850;
}

.evidence-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.evidence-chip {
  padding: 5px 7px;
  border-radius: 6px;
  background: var(--paper);
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
}

.guidance-card {
  padding: 20px;
}

.guidance-card h4 {
  margin: 0 0 10px;
  font-size: 12px;
}

.guidance-card h4:not(:first-child) {
  margin-top: 20px;
}

.guidance-card ol,
.guidance-card ul {
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}

.similar-section {
  margin-top: 28px;
}

.similar-cases {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.similar-card {
  padding: 15px;
}

.similar-card strong {
  font-size: 11px;
}

.similar-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 9px;
}

.outcome {
  float: right;
  padding: 4px 6px;
  border-radius: 5px;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.outcome.won {
  color: var(--green);
  background: var(--green-soft);
}

.outcome.lost {
  color: var(--red);
  background: var(--red-soft);
}

.feedback-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-top: 28px;
  padding: 22px;
  border-radius: 16px;
  background: var(--paper);
}

.feedback-card h3 {
  margin-top: 4px;
  font-size: 15px;
}

.feedback-card p:last-child {
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
}

.feedback-actions {
  gap: 8px;
}

.feedback-button {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--white);
  color: var(--ink);
  font-size: 10px;
  font-weight: 700;
}

.feedback-button:hover {
  border-color: var(--green);
  color: var(--green);
}

.feedback-card.recorded {
  border: 1px solid var(--mint);
  background: var(--green-soft);
}

.toast {
  position: fixed;
  right: 26px;
  bottom: 26px;
  max-width: 360px;
  padding: 13px 16px;
  border-radius: 11px;
  color: var(--white);
  background: var(--ink);
  box-shadow: var(--shadow);
  font-size: 11px;
  transform: translateY(90px);
  opacity: 0;
  transition: 0.25s ease;
  z-index: 50;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.loading-line {
  height: 56px;
  border-radius: 12px;
  background: linear-gradient(90deg, #edf3f0, #f8faf9, #edf3f0);
  background-size: 200% 100%;
  animation: shimmer 1.2s infinite;
}

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

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

@media (max-width: 1050px) {
  .metrics {
    grid-template-columns: repeat(2, 1fr);
  }

  .workspace {
    grid-template-columns: 270px minmax(0, 1fr);
  }

  .result-columns,
  .context-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .auth-card {
    padding: 28px 22px;
  }

  .enrollment-box {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .signed-user {
    display: none;
  }

  .topbar {
    height: auto;
    padding: 14px 5vw;
  }

  .system-status,
  .persona-control span {
    display: none;
  }

  .persona-control select {
    max-width: 150px;
  }

  main {
    width: 92vw;
    padding-top: 20px;
  }

  .hero {
    min-height: 300px;
    grid-template-columns: 1fr;
    padding: 32px 28px;
  }

  .hero h2 {
    font-size: 38px;
  }

  .hero-visual {
    display: none;
  }

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

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

  .lead-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .lead-list {
    max-height: 250px;
  }

  .analysis-panel {
    padding: 24px 18px;
  }

  .lead-header,
  .feedback-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .assessment-layout,
  .similar-cases {
    grid-template-columns: 1fr;
  }

  .feedback-actions {
    width: 100%;
    flex-wrap: wrap;
  }
}
