:root {
  --bg: #ffffff;
  --ink: #111111;
  --ink-soft: #5c5c5c;
  --line: #e6e6e6;
  --line-strong: #111111;
  --fill: #f6f6f6;
  --radius: 14px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* ---- Top bar ---- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1060px;
  margin: 0 auto;
  padding: 26px 24px;
}
.wordmark {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}
/* ---- Layout ---- */
main {
  max-width: 1060px;
  margin: 0 auto;
  padding: 8px 24px 56px;
}
.screen { margin-bottom: 48px; }

/* Reading-width screen (everything except the landing hero) */
#tool { max-width: 640px; }

/* ---- Landing hero ---- */
/* Band grounds the hero instead of floating in white space; spans the same
   width as the topbar/content column (cancels main's padding, then re-adds
   it so inner content still aligns). */
.hero-band {
  margin: 0 -24px;
  padding: 0 24px;
  background: var(--fill);
  border-bottom: 1px solid var(--line);
}
.hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 64px;
  align-items: center;
  padding: 56px 0 64px;
}
.hero-copy { min-width: 0; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-soft);
  margin: 0 0 16px;
}
h1 {
  font-size: 40px;
  line-height: 1.08;
  letter-spacing: -0.035em;
  margin: 0 0 18px;
  font-weight: 700;
  text-wrap: balance;
}
.landing-lead {
  font-size: 17px;
  color: var(--ink-soft);
  margin: 0 0 30px;
  max-width: 32em;
}

/* CTA */
.cta { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }

/* Meta strip */
.landing-meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
  margin: 32px 0 32px;
  padding: 0 0 24px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--ink-soft);
}
.landing-meta li { position: relative; padding-left: 15px; }
.landing-meta li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--ink);
}

/* ---- Example result panel ---- */
.demo {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 12px 32px rgba(0, 0, 0, .05);
}
.demo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}
.demo-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.demo-tag {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 9px;
}
.demo-thumb {
  border-radius: 12px;
  overflow: hidden;
  line-height: 0;
  margin-bottom: 18px;
}
.demo-thumb svg { width: 100%; height: 128px; display: block; }
.demo-scores { display: flex; flex-direction: column; gap: 16px; }
.demo-score-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 8px;
  font-size: 13.5px;
}
.demo-pct { font-weight: 700; font-variant-numeric: tabular-nums; font-size: 15px; }
.demo-meter {
  height: 8px;
  background: var(--fill);
  border-radius: 999px;
  overflow: hidden;
}
.demo-bar { height: 100%; background: var(--ink); border-radius: 999px; }
.demo-foot {
  margin: 16px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--ink-soft);
}

/* Hero collapses to one column on narrow screens */
@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 36px;
    padding-top: 24px;
  }
  .demo { max-width: 460px; }
  h1 { font-size: 34px; }
}

/* ---- Buttons ---- */
.btn {
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: opacity .15s, background .15s, border-color .15s;
}
.btn-dark {
  background: var(--ink);
  color: #fff;
}
.btn-dark:hover { opacity: 0.85; }
.btn-plain {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-plain:hover { background: var(--fill); }
.btn-lg { padding: 15px 28px; font-size: 16px; border-radius: 12px; }

.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.btn-row .btn-dark { flex: 1; min-width: 180px; }

/* ---- Tool views ---- */
.view-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 18px;
}
.view-sub {
  font-size: 15px;
  color: var(--ink-soft);
  margin: -8px 0 18px;
  max-width: 40em;
}
.view-center { text-align: center; padding: 48px 0; }

/* Dropzone */
.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-align: center;
  padding: 54px 20px;
  border: 1.5px dashed var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.dropzone:hover { border-color: var(--ink); }
.dropzone.dragover { border-color: var(--ink); background: var(--fill); }
.dz-title { font-weight: 600; font-size: 16px; }
.dz-sub { font-size: 14px; color: var(--ink-soft); }

.file-error {
  margin: 14px 0 0;
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
}

/* Preview */
.preview-wrap {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
  display: grid;
  place-items: center;
  max-height: 420px;
}
#preview-img { max-width: 100%; max-height: 420px; display: block; object-fit: contain; }

/* Loading */
.spinner {
  width: 34px; height: 34px;
  margin: 0 auto 18px;
  border: 2px solid var(--line);
  border-top-color: var(--ink);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { font-weight: 600; margin: 0; font-size: 16px; }
.loading-sub { color: var(--ink-soft); font-size: 14px; margin: 6px 0 0; }

/* Results */
.verdict {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 22px;
}
.verdict-label { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.verdict-tag { font-size: 13px; color: var(--ink-soft); }
.verdict.is-uncertain { border-style: dashed; }

.scores { display: flex; flex-direction: column; gap: 18px; }
.score-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.score-name { font-weight: 600; font-size: 15px; }
.score-val { font-weight: 700; font-size: 17px; font-variant-numeric: tabular-nums; }
.meter {
  height: 10px;
  background: var(--fill);
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
}
.bar {
  height: 100%;
  width: 0;
  background: var(--ink);
  border-radius: 999px;
  transition: width .7s cubic-bezier(.16,1,.3,1);
}

.score-explainer {
  margin: 22px 0 0;
  font-size: 14px;
  color: var(--ink-soft);
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

/* Disclaimer */
.disclaimer {
  max-width: 640px;
  background: var(--fill);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-top: 8px;
}
.disclaimer p { margin: 0; font-size: 13.5px; color: var(--ink-soft); }
.disclaimer p + p { margin-top: 10px; }
.disclaimer strong { color: var(--ink); }

/* Footer */
.site-footer {
  max-width: 1060px;
  margin: 0 auto;
  padding: 28px 24px 56px;
  color: var(--ink-soft);
  font-size: 12.5px;
}
.site-footer p { margin: 0; }
.footer-credit {
  margin: 0 0 6px !important;
  font-size: 14px;
  color: var(--ink);
  font-weight: 600;
}
.footer-credit a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.footer-credit a:hover { opacity: 0.7; }

/* Responsive */
@media (max-width: 540px) {
  h1 { font-size: 29px; }
  .landing-lead { font-size: 16px; }
  .btn-row .btn-dark { min-width: 0; }
  .cta { gap: 10px; }
  .cta .btn-lg { width: 100%; }
  .landing-meta { gap: 8px; flex-direction: column; }
}
