:root {
  color-scheme: light;
  --ink: #13231d;
  --muted: #64756e;
  --line: #d9e5df;
  --line-strong: #bdcec6;
  --surface: #ffffff;
  --surface-soft: #f3f8f5;
  --brand: #14845a;
  --brand-dark: #086b47;
  --brand-soft: #e7f5ee;
  --danger: #b42318;
  --shadow: 0 20px 55px rgba(26, 59, 45, 0.1);
  --radius: 18px;
}

* { box-sizing: border-box; }

html { min-height: 100%; background: #eef5f1; }

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 0%, rgba(20, 132, 90, 0.13), transparent 34rem),
    radial-gradient(circle at 92% 12%, rgba(218, 168, 63, 0.09), transparent 30rem),
    linear-gradient(180deg, #fbfdfc 0%, #edf4f0 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input, select { font: inherit; }
button, select { cursor: pointer; }
[hidden] { display: none !important; }

.shell { width: min(1180px, calc(100% - 32px)); margin: 0 auto; padding: 24px 0 64px; }

.site-header {
  display: flex;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: clamp(32px, 7vw, 76px);
}

.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; }
.brand-mark {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(145deg, #23a971, #08744d);
  box-shadow: 0 9px 20px rgba(20, 132, 90, 0.25);
  font-size: 19px;
  font-weight: 850;
}
.brand-name { font-size: 1.2rem; font-weight: 820; letter-spacing: -0.035em; }
.brand-name span { color: var(--brand); }

h1, h2 { margin-top: 0; color: #0d1f18; letter-spacing: -0.035em; }
h1 { margin-bottom: 14px; font-size: clamp(2.15rem, 5.2vw, 4.4rem); line-height: 1.02; }
h2 { margin-bottom: 18px; font-size: 1.25rem; }
p { line-height: 1.6; }

.eyebrow {
  margin: 0 0 12px;
  color: var(--brand);
  font-size: 0.77rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.lead { max-width: 62ch; margin: 0; color: var(--muted); font-size: 1.05rem; line-height: 1.72; }
.muted { margin: 0; color: var(--muted); font-size: 0.9rem; }

.auth-layout { display: grid; grid-template-columns: 1.18fr 0.82fr; gap: clamp(36px, 8vw, 100px); align-items: center; }
.hero-copy { padding: 14px 0; }
.feature-list { display: grid; gap: 13px; margin: 30px 0 0; padding: 0; list-style: none; color: #344b41; }
.feature-list li { position: relative; padding-left: 30px; line-height: 1.5; }
.feature-list li::before {
  position: absolute;
  top: 1px;
  left: 0;
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  color: var(--brand);
  background: var(--brand-soft);
  content: "✓";
  font-size: 0.76rem;
  font-weight: 900;
}

.auth-card, .panel {
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid rgba(210, 225, 217, 0.95);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow);
}
.tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin-bottom: 28px; padding: 5px; border-radius: 12px; background: var(--surface-soft); }
.tab { min-height: 42px; color: var(--muted); background: transparent; border: 0; border-radius: 9px; font-weight: 760; }
.tab.active { color: var(--ink); background: #fff; box-shadow: 0 3px 12px rgba(24, 55, 42, 0.09); }

form { display: grid; gap: 8px; }
label { margin-top: 8px; color: #2a4036; font-size: 0.88rem; font-weight: 730; }
.optional { color: var(--muted); font-weight: 550; }
.field-hint { margin: -2px 0 4px; color: var(--muted); font-size: 0.8rem; line-height: 1.45; }

input, select {
  width: 100%;
  min-height: 48px;
  padding: 11px 13px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}
input:hover, select:hover { border-color: #93aa9f; }
input:focus, select:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(20, 132, 90, 0.1); outline: 0; }

button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  color: #fff;
  background: var(--brand);
  border: 1px solid var(--brand);
  border-radius: 10px;
  font-weight: 760;
  transition: transform 150ms ease, background 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}
form > button[type="submit"] { width: 100%; margin-top: 14px; }
button:hover:not(:disabled) { background: var(--brand-dark); border-color: var(--brand-dark); box-shadow: 0 7px 16px rgba(20, 132, 90, 0.18); transform: translateY(-1px); }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid rgba(20, 132, 90, 0.22); outline-offset: 2px; }
button:disabled { opacity: 0.55; cursor: not-allowed; }
button.secondary { color: #34483f; background: #fff; border-color: var(--line-strong); }
button.secondary:hover:not(:disabled) { color: var(--ink); background: var(--surface-soft); border-color: #93aa9f; box-shadow: none; }
button.compact { min-height: 38px; padding: 8px 13px; font-size: 0.86rem; }
button.danger { color: var(--danger); background: #fff; border-color: #ecc7c2; }
button.danger:hover:not(:disabled) { color: #fff; background: var(--danger); border-color: var(--danger); }
.text-button { min-height: auto; margin: 17px 0 0; padding: 2px 0; color: var(--brand); background: transparent; border: 0; font-size: 0.88rem; }
.text-button:hover:not(:disabled) { color: var(--brand-dark); background: transparent; border: 0; box-shadow: none; transform: none; text-decoration: underline; }
.status { min-height: 24px; margin: 16px 0 0; color: var(--muted); font-size: 0.87rem; }
.status.error { color: var(--danger); }
.status.success { color: var(--brand-dark); }

.app-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.app-heading h1 { font-size: clamp(2rem, 4vw, 3.25rem); }
.app-grid { display: grid; grid-template-columns: minmax(300px, 0.85fr) minmax(390px, 1.15fr); gap: 22px; align-items: start; }
.panel { padding: clamp(22px, 3vw, 30px); box-shadow: 0 12px 38px rgba(26, 59, 45, 0.07); }
.two-column { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.two-column > div { display: grid; gap: 8px; }
.check-row { display: flex; align-items: center; gap: 10px; margin: 10px 0 3px; }
.check-row input { width: 18px; min-height: 18px; margin: 0; accent-color: var(--brand); }
.button-row { display: flex; gap: 10px; margin-top: 8px; }
.button-row button { flex: 1; }
.panel-heading { display: flex; align-items: start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.panel-heading h2 { margin-bottom: 5px; }

.name-list { display: grid; gap: 12px; }
.name-card { padding: 16px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface-soft); }
.name-card.disabled { opacity: 0.64; }
.name-card-top { display: flex; align-items: start; justify-content: space-between; gap: 14px; }
.name-card h3 { margin: 0 0 5px; font-size: 1rem; letter-spacing: -0.015em; }
.name-meta { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.pill { display: inline-flex; align-items: center; padding: 4px 8px; border-radius: 999px; color: #3e594d; background: #fff; border: 1px solid var(--line); font-size: 0.74rem; font-weight: 700; }
.pill.mode { color: var(--brand-dark); background: var(--brand-soft); border-color: #c9e9da; }
.card-actions { display: flex; gap: 7px; }
.card-actions button { min-height: 34px; padding: 6px 10px; font-size: 0.78rem; }
.empty-state { padding: 26px; color: var(--muted); background: var(--surface-soft); border: 1px dashed var(--line-strong); border-radius: 12px; line-height: 1.65; text-align: center; }
.matches-panel { margin-top: 22px; }
.scan-status {
  margin-bottom: 22px;
  padding: 20px 24px;
  border: 1px solid #c9e9da;
  border-radius: 14px;
  background: rgba(231, 245, 238, 0.82);
}
.scan-status-heading { display: flex; align-items: start; justify-content: space-between; gap: 16px; }
.scan-status h2 { margin-bottom: 6px; }
.scan-status .status { min-height: 0; margin-bottom: 0; }
.match-list { display: grid; gap: 14px; }
.match-card { padding: 19px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-soft); }
.match-heading { display: flex; align-items: start; justify-content: space-between; gap: 18px; }
.match-heading h3 { margin: 0 0 5px; font-size: 1.08rem; }
.score-badge {
  display: grid;
  min-width: 64px;
  min-height: 54px;
  place-items: center;
  padding: 8px;
  color: var(--brand-dark);
  background: #fff;
  border: 1px solid #b9dfcd;
  border-radius: 12px;
  font-size: 1.03rem;
  font-weight: 850;
}
.match-details { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 15px; }
.match-detail { padding: 11px 12px; border-radius: 10px; background: #fff; border: 1px solid var(--line); }
.match-detail strong { display: block; margin-bottom: 3px; color: #52675e; font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase; }
.match-detail span { font-size: 0.86rem; line-height: 1.45; }
.match-reasons { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 13px; }
.claim-link { display: inline-block; margin-top: 14px; color: var(--brand-dark); font-size: 0.85rem; font-weight: 750; }

@media (max-width: 840px) {
  .auth-layout, .app-grid { grid-template-columns: 1fr; }
  .hero-copy { max-width: 680px; }
  .app-heading { align-items: start; flex-direction: column; }
}

@media (max-width: 560px) {
  .shell { width: min(100% - 22px, 1180px); padding-top: 14px; }
  .site-header { margin-bottom: 28px; }
  .brand-name { font-size: 1.02rem; }
  .two-column { grid-template-columns: 1fr; }
  .name-card-top { flex-direction: column; }
  .card-actions { width: 100%; }
  .card-actions button { flex: 1; }
  .match-heading { flex-direction: column; }
  .match-details { grid-template-columns: 1fr; }
}
