:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ink: #f3f7f2;
  --muted: #9eaa9f;
  --faint: #6f7a70;
  --canvas: #090d0b;
  --surface: rgba(18, 25, 20, 0.82);
  --surface-raised: rgba(26, 35, 29, 0.94);
  --line: rgba(183, 246, 58, 0.15);
  --line-strong: rgba(183, 246, 58, 0.34);
  --lime: #b7f43a;
  --lime-bright: #d5ff70;
  --lime-dark: #283712;
  --red: #ff4a4e;
  --red-bright: #ff7674;
  --red-dark: #421d20;
  --amber: #ffc45c;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
}

* { box-sizing: border-box; }

html { background: var(--canvas); }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 2%, rgba(183, 244, 58, 0.15), transparent 24rem),
    radial-gradient(circle at 95% 8%, rgba(255, 74, 78, 0.18), transparent 27rem),
    radial-gradient(circle at 50% 110%, rgba(94, 171, 76, 0.11), transparent 34rem),
    var(--canvas);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  opacity: 0.14;
  background-image: linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, black, transparent 72%);
}

.page-shell {
  width: min(100% - 2rem, 900px);
  margin: 0 auto;
  padding: clamp(2.5rem, 7vw, 6.2rem) 0 3.5rem;
}

.hero {
  position: relative;
  margin-bottom: 2.4rem;
  padding: 0.25rem 0 0;
}

.brand-strip,
.hero-meta,
.button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}

.brand-strip { margin-bottom: 1.35rem; }

.brand-mark {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0.3rem 0.62rem;
  border: 1px solid rgba(255, 74, 78, 0.65);
  border-radius: 6px;
  color: #fff6f5;
  background: linear-gradient(135deg, rgba(255, 74, 78, 0.34), rgba(255, 74, 78, 0.1));
  box-shadow: inset 0 0 20px rgba(255, 74, 78, 0.12), 0 0 22px rgba(255, 74, 78, 0.09);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.14em;
}

.brand-caption {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.local-pill {
  margin-left: auto;
  padding: 0.3rem 0.55rem;
  border: 1px solid rgba(183, 244, 58, 0.34);
  border-radius: 999px;
  color: var(--lime-bright);
  background: rgba(183, 244, 58, 0.08);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.eyebrow {
  margin: 0 0 0.72rem;
  color: var(--lime);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.18em;
}

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

h1 {
  max-width: 760px;
  margin-bottom: 1rem;
  color: #f7fbf5;
  font-size: clamp(2.4rem, 6.3vw, 4.5rem);
  line-height: 0.96;
  letter-spacing: -0.065em;
  text-wrap: balance;
}

h2 {
  display: flex;
  align-items: center;
  gap: 0.62rem;
  margin-bottom: 1.35rem;
  color: #f5f9f4;
  font-size: 1.04rem;
  letter-spacing: -0.015em;
}

.card h2::before,
.notice h2::before {
  display: grid;
  width: 1.7rem;
  height: 1.7rem;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  color: var(--lime);
  background: rgba(183, 244, 58, 0.06);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.card:nth-of-type(2) h2::before { content: "01"; }
#details-card h2::before { content: "02"; }
#convert-card h2::before { content: "03"; }
#report-card h2::before { content: "R"; }
.notice h2::before { content: "!"; color: var(--amber); border-color: rgba(255, 196, 92, 0.35); background: rgba(255, 196, 92, 0.08); }

.lede {
  max-width: 620px;
  margin-bottom: 1.25rem;
  color: #bdc8bf;
  font-size: clamp(1rem, 2vw, 1.13rem);
  line-height: 1.68;
}

.hero-meta span {
  padding: 0.42rem 0.68rem;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 999px;
  color: #bdc8bf;
  background: rgba(255, 255, 255, 0.035);
  font-size: 0.76rem;
}

.hero-meta span::before {
  display: inline-block;
  width: 0.42rem;
  height: 0.42rem;
  margin-right: 0.42rem;
  border-radius: 999px;
  background: var(--lime);
  content: "";
  box-shadow: 0 0 12px rgba(183, 244, 58, 0.8);
}

.card,
.notice {
  position: relative;
  overflow: hidden;
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(31, 41, 34, 0.88), rgba(13, 18, 15, 0.9));
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.card::after {
  position: absolute;
  top: 0;
  right: 9%;
  left: 9%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(183, 244, 58, 0.65), transparent);
  content: "";
}

.card { padding: clamp(1.2rem, 4vw, 1.8rem); }

.drop-zone {
  display: grid;
  min-height: 185px;
  place-content: center;
  justify-items: center;
  gap: 0.38rem;
  padding: 2rem 1rem;
  border: 1.5px dashed rgba(183, 244, 58, 0.5);
  border-radius: 14px;
  color: #edf9e8;
  cursor: pointer;
  background: radial-gradient(circle at 50% 15%, rgba(183, 244, 58, 0.13), transparent 55%), rgba(10, 15, 11, 0.58);
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.drop-zone:hover,
.drop-zone.is-dragging {
  border-color: var(--lime-bright);
  background: radial-gradient(circle at 50% 15%, rgba(183, 244, 58, 0.24), transparent 55%), rgba(18, 28, 18, 0.78);
  transform: translateY(-2px);
}

.drop-zone input { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; opacity: 0; }
.drop-icon { color: var(--red-bright); font-size: 2.3rem; line-height: 1; text-shadow: 0 0 24px rgba(255, 74, 78, 0.48); }
.drop-title { font-weight: 800; }
.drop-subtitle, .status, .hint { color: var(--muted); font-size: 0.88rem; }
.status { min-height: 1.25rem; margin: 0.95rem 0 0; }

.metadata-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(155px, 1fr));
  gap: 0.72rem;
  margin: 0;
}

.metadata-grid div {
  min-width: 0;
  padding: 0.88rem;
  border: 1px solid rgba(255, 255, 255, 0.055);
  border-radius: 12px;
  background: rgba(5, 9, 7, 0.48);
}

dt { color: var(--faint); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.035em; text-transform: uppercase; }
dd { margin: 0.45rem 0 0; overflow-wrap: anywhere; color: #e7f0e5; font-size: 0.96rem; font-weight: 750; }
.hint { margin: 1rem 0 0; line-height: 1.6; }

.form-row {
  display: grid;
  max-width: 480px;
  gap: 0.45rem;
  margin-top: 1rem;
}

.form-row:first-of-type { margin-top: 0; }
.form-row label { color: #e9f0e7; font-size: 0.9rem; font-weight: 800; }

input[type="number"],
select {
  width: 100%;
  border: 1px solid rgba(183, 244, 58, 0.23);
  border-radius: 10px;
  padding: 0.78rem 0.85rem;
  color: var(--ink);
  background: rgba(6, 10, 7, 0.76);
  font: inherit;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input[type="number"]:hover,
select:hover { border-color: rgba(183, 244, 58, 0.52); }
input[type="number"]:focus,
select:focus,
button:focus-visible,
.drop-zone:focus-within { outline: 2px solid var(--lime); outline-offset: 3px; }
input[type="number"]:focus,
select:focus { border-color: var(--lime); background: rgba(13, 21, 14, 0.96); box-shadow: 0 0 0 4px rgba(183, 244, 58, 0.1); }
.field-note { color: var(--faint); font-size: 0.8rem; line-height: 1.48; }

.compatibility-warning {
  margin: 1.4rem 0;
  padding: 1rem 1.05rem;
  border: 1px solid rgba(255, 74, 78, 0.38);
  border-radius: 13px;
  color: #ffd9d8;
  background: linear-gradient(110deg, rgba(255, 74, 78, 0.14), rgba(65, 25, 26, 0.3));
}

.compatibility-warning h3 { margin: 0 0 0.45rem; color: #fff1f0; font-size: 0.95rem; }
.compatibility-warning p { margin: 0; line-height: 1.55; }
.compatibility-warning ul { margin: 0.8rem 0 0; padding-left: 1.2rem; }
.compatibility-warning li { margin: 0.42rem 0; line-height: 1.48; }
.compatibility-warning.is-safe { border-color: rgba(183, 244, 58, 0.38); color: #dcf7b1; background: linear-gradient(110deg, rgba(183, 244, 58, 0.13), rgba(34, 56, 15, 0.3)); }
.compatibility-footnote { margin-top: 0.85rem !important; color: #d6a7a6; font-size: 0.8rem; }
.compatibility-warning.is-safe .compatibility-footnote { color: #bad391; }
.detected-risk { color: #fff1a8; font-weight: 850; }

.export-preview {
  margin: 1.4rem 0;
  padding: 1rem 1.05rem;
  border: 1px solid rgba(183, 244, 58, 0.24);
  border-radius: 13px;
  background: rgba(5, 9, 7, 0.48);
}
.export-preview h3 { margin-bottom: 0.8rem; font-size: 0.95rem; }
.preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.65rem; margin: 0; }
.preview-grid div { min-width: 0; padding: 0.72rem; border: 1px solid rgba(255, 255, 255, 0.055); border-radius: 9px; }
.preview-grid dd { font-size: 0.86rem; }

.check-row {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  margin: 1.25rem 0;
  color: #c9d1c8;
  line-height: 1.45;
  cursor: pointer;
}

.check-row input { margin-top: 0.22rem; accent-color: var(--lime); }
.button-row { gap: 0.7rem; }

.primary-button,
.secondary-button {
  min-height: 46px;
  border-radius: 10px;
  padding: 0.78rem 1rem;
  font: inherit;
  font-weight: 850;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease, background 160ms ease;
}

.primary-button {
  border: 1px solid transparent;
  color: #fff9f8;
  background: linear-gradient(135deg, #dc313b, #ff5b55);
  box-shadow: 0 10px 24px rgba(255, 74, 78, 0.22);
}

.primary-button:hover:not(:disabled) { transform: translateY(-1px); background: linear-gradient(135deg, #ef3c46, #ff7770); box-shadow: 0 13px 30px rgba(255, 74, 78, 0.32); }
.secondary-button { border: 1px solid rgba(183, 244, 58, 0.32); color: var(--lime-bright); background: rgba(183, 244, 58, 0.06); }
.secondary-button:hover:not(:disabled) { transform: translateY(-1px); border-color: var(--lime); background: rgba(183, 244, 58, 0.13); }
.primary-button:disabled,
.secondary-button:disabled { opacity: 0.42; cursor: not-allowed; }
.drop-zone.is-disabled { cursor: not-allowed; opacity: 0.55; }

.notice {
  padding: 1.2rem 1.35rem;
  border-color: rgba(255, 196, 92, 0.25);
  color: #d5d2be;
  background: linear-gradient(135deg, rgba(74, 51, 20, 0.62), rgba(26, 28, 18, 0.88));
}

.notice h2 { margin-bottom: 0.62rem; color: #ffdda2; }
.notice p { margin: 0; line-height: 1.62; font-size: 0.9rem; }

.report-findings { display: grid; gap: 0.72rem; margin: 1rem 0 0; padding: 0; list-style: none; }
.report-findings li { padding: 0.9rem; border: 1px solid rgba(255, 255, 255, 0.055); border-radius: 11px; background: rgba(5, 9, 7, 0.43); line-height: 1.5; }
.report-findings strong { display: block; margin-bottom: 0.25rem; }
.report-findings a { color: var(--lime-bright); }
.report-findings a:hover { color: #f3ffcb; }
.finding-meta { color: var(--muted); font-size: 0.8rem; }
.privacy-note { margin: 0.8rem 0 0; color: var(--amber); font-size: 0.8rem; line-height: 1.5; }
.finding-critical { border-left: 3px solid var(--red) !important; }
.finding-warning { border-left: 3px solid var(--amber) !important; }
.finding-info { border-left: 3px solid var(--lime) !important; }

.app-footer {
  width: min(900px, calc(100% - 2rem));
  margin: 0 auto 28px;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(183, 244, 58, 0.13);
  color: var(--faint);
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  text-align: center;
}

.app-footer p { margin: 0; }
.is-hidden { display: none; }
code { padding: 0.12rem 0.32rem; border: 1px solid rgba(183, 244, 58, 0.18); border-radius: 5px; color: var(--lime-bright); background: rgba(183, 244, 58, 0.08); }

@media (max-width: 600px) {
  .page-shell { width: min(100% - 1.2rem, 900px); padding-top: 2.25rem; }
  .brand-strip { gap: 0.45rem; }
  .brand-caption { flex-basis: 100%; order: 3; }
  .local-pill { margin-left: 0; }
  .hero-meta { gap: 0.45rem; }
  .hero-meta span { font-size: 0.7rem; }
  .metadata-grid { grid-template-columns: 1fr; }
  .preview-grid { grid-template-columns: 1fr; }
  .button-row > button { width: 100%; }
}
