:root {
  /* Foremost Leads brand */
  --fl-green: #16a34a;
  --fl-green-2: #4eb52b;
  --fl-lime: #a7d92a;
  --fl-grad: linear-gradient(120deg, #15a34a 0%, #5cb82b 55%, #a7d92a 100%);
  --fl-grad-soft: linear-gradient(120deg, rgba(21,163,74,0.16), rgba(167,217,42,0.10));

  --bg: #07090a;
  --bg-2: #0c0f10;
  --panel: rgba(22, 27, 26, 0.72);
  --panel-solid: #141917;
  --panel-2: rgba(255, 255, 255, 0.035);
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #eef3ee;
  --muted: #97a59c;
  --faint: #6b776f;

  --green: #2ecc71;
  --green-bg: rgba(34, 197, 94, 0.10);
  --red: #ff6b6b;
  --red-bg: rgba(255, 90, 90, 0.10);
  --yellow: #ffd24d;
  --yellow-bg: rgba(255, 200, 60, 0.10);

  --radius: 16px;
  --radius-sm: 11px;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.75);
  --glow: 0 14px 40px -12px rgba(34, 160, 64, 0.45);
}

* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body {
  margin: 0; color: var(--text); font-family: var(--sans); line-height: 1.55; font-size: 15px;
  background:
    radial-gradient(900px 520px at 50% -8%, rgba(34, 160, 64, 0.16), transparent 60%),
    radial-gradient(700px 480px at 100% 0%, rgba(167, 217, 42, 0.08), transparent 55%),
    var(--bg);
  background-attachment: fixed;
  min-height: 100vh;
}
a { color: var(--fl-lime); }
.wrap { max-width: 940px; margin: 0 auto; padding: 40px 22px 96px; }

/* ---------- brand header ---------- */
.brand { display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 30px; }
.brand .logo { width: 76px; height: 76px; border-radius: 20px; box-shadow: var(--glow); }
.brand .wordmark { margin-top: 14px; font-size: 15px; font-weight: 700; letter-spacing: 0.34em;
  text-transform: uppercase; color: var(--text); padding-left: 0.34em; }
.brand .wordmark b { background: var(--fl-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.brand .rule { width: 54px; height: 3px; border-radius: 3px; background: var(--fl-grad); margin: 16px 0 18px; opacity: 0.95; }
.brand h1 { font-size: 25px; font-weight: 650; margin: 0; letter-spacing: -0.02em; }
.brand .sub { color: var(--muted); margin: 7px 0 0; font-size: 14.5px; max-width: 560px; }

/* ---------- step cards ---------- */
.step { position: relative; background: var(--panel); backdrop-filter: blur(18px) saturate(120%);
  -webkit-backdrop-filter: blur(18px) saturate(120%); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px 26px; margin-bottom: 20px; box-shadow: var(--shadow);
  transition: opacity 0.25s, transform 0.25s; }
.step::before { content: ""; position: absolute; inset: 0; border-radius: var(--radius); padding: 1px;
  background: linear-gradient(160deg, rgba(167,217,42,0.22), rgba(255,255,255,0.02) 40%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none; }
.step.disabled { opacity: 0.4; pointer-events: none; filter: grayscale(0.3); }
.step h2 { font-size: 15px; margin: 0 0 18px; display: flex; align-items: center; gap: 12px; letter-spacing: -0.01em; font-weight: 600; }
.step .num { width: 27px; height: 27px; border-radius: 50%; display: inline-flex; align-items: center;
  justify-content: center; font-size: 13px; font-weight: 700; color: #06210f;
  background: var(--fl-grad); box-shadow: 0 4px 14px -4px rgba(34,160,64,0.6); }

/* ---------- dropzone ---------- */
.drop { position: relative; border: 1.5px dashed var(--line-2); border-radius: var(--radius);
  padding: 40px 22px; text-align: center; color: var(--muted); cursor: pointer; transition: 0.18s;
  background: var(--panel-2); }
.drop:hover, .drop.over { border-color: var(--fl-green-2); color: var(--text); background: var(--fl-grad-soft); }
.drop .dropicon { font-size: 26px; color: var(--fl-lime); margin-bottom: 8px; display: block; }
.drop strong { color: var(--text); }
.hint { font-size: 12.5px; color: var(--faint); margin-top: 9px; }

.files { margin-top: 18px; display: flex; flex-direction: column; gap: 13px; }
.fcard { background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 16px 18px; transition: border-color 0.18s; }
.fcard:hover { border-color: var(--line-2); }
.fcard .top { display: flex; align-items: center; gap: 13px; flex-wrap: wrap; }
.fcard .fname { font-weight: 600; font-size: 14px; word-break: break-all; flex: 1 1 190px; }
.fcard .fname .ti { color: var(--fl-lime); margin-right: 7px; vertical-align: -2px; }
.fcard .meta { color: var(--faint); font-size: 12px; }
.fcard .err { color: var(--red); font-size: 13px; margin-top: 7px; }

.role { display: flex; gap: 7px; flex-wrap: wrap; }
.role button { background: rgba(255,255,255,0.04); border: 1px solid var(--line); color: var(--muted);
  padding: 6px 13px; border-radius: 9px; font-size: 12px; font-weight: 500; cursor: pointer; transition: 0.15s; }
.role button.active { background: var(--fl-grad); border-color: transparent; color: #06210f; font-weight: 700;
  box-shadow: 0 4px 14px -5px rgba(34,160,64,0.7); }
.role button:hover:not(.active) { color: var(--text); border-color: var(--line-2); }

.adv { margin-top: 14px; }
.adv summary { cursor: pointer; color: var(--muted); font-size: 12.5px; user-select: none; list-style: none; display: inline-flex; align-items: center; gap: 6px; }
.adv summary::-webkit-details-marker { display: none; }
.adv summary .ti { display: inline-flex; transition: transform 0.2s; color: var(--faint); }
.adv summary .ti svg { width: 14px; height: 14px; }
.adv[open] summary .ti { transform: rotate(90deg); }
.adv summary:hover { color: var(--text); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px 16px; margin-top: 14px; }
.field { display: flex; flex-direction: column; gap: 5px; }
.field label { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.07em; font-weight: 600; }
input, select {
  background: rgba(0,0,0,0.28); border: 1px solid var(--line); color: var(--text);
  border-radius: 10px; padding: 10px 12px; font-size: 13.5px; font-family: var(--sans); width: 100%; transition: 0.15s;
}
input:hover, select:hover { border-color: var(--line-2); }
input:focus, select:focus { outline: none; border-color: var(--fl-green-2); box-shadow: 0 0 0 3px rgba(34,160,64,0.18); }
input::placeholder { color: var(--faint); }
.detected { font-size: 11px; color: var(--fl-lime); margin-top: 2px; opacity: 0.85; }

.btn { background: rgba(255,255,255,0.05); color: var(--text); border: 1px solid var(--line-2);
  border-radius: 12px; padding: 12px 22px; font-size: 14px; font-weight: 600; cursor: pointer; transition: 0.16s; font-family: var(--sans); }
.btn:hover { border-color: var(--fl-green-2); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn.primary { background: var(--fl-grad); color: #06210f; border: none; box-shadow: var(--glow); }
.btn.primary:hover { filter: brightness(1.06); transform: translateY(-1px); }
.btn.big { width: 100%; padding: 16px; font-size: 15.5px; letter-spacing: 0.01em; }
.btn-row { display: flex; gap: 12px; margin-top: 22px; }

.note { font-size: 12.5px; color: var(--faint); margin-top: 10px; line-height: 1.6; }
.warn { background: var(--yellow-bg); border: 1px solid rgba(255,200,60,0.28); color: var(--yellow);
  border-radius: 11px; padding: 11px 14px; font-size: 13px; margin-top: 14px; }

.inspect-status { font-size: 13px; color: var(--muted); margin-top: 14px; }

/* ---------- results ---------- */
.verdict { display: flex; align-items: center; gap: 16px; padding: 20px 22px; border-radius: 14px; margin-bottom: 18px; }
.verdict.ok { background: var(--fl-grad-soft); border: 1px solid rgba(167,217,42,0.30); }
.verdict.bad { background: var(--red-bg); border: 1px solid rgba(255,90,90,0.30); }
.verdict .big-icon { width: 46px; height: 46px; border-radius: 13px; display: flex; align-items: center; justify-content: center; font-size: 24px; flex-shrink: 0; }
.verdict.ok .big-icon { background: var(--fl-grad); color: #06210f; box-shadow: var(--glow); }
.verdict.bad .big-icon { background: rgba(255,90,90,0.16); color: var(--red); }
.verdict h3 { margin: 0 0 3px; font-size: 17px; font-weight: 650; letter-spacing: -0.01em; }
.verdict p { margin: 0; color: var(--muted); font-size: 13.5px; }

.dlbtn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%;
  padding: 16px; font-size: 15.5px; font-weight: 700; text-decoration: none; border-radius: 13px;
  background: var(--fl-grad); color: #06210f; box-shadow: var(--glow); margin-bottom: 18px; transition: 0.16s; }
.dlbtn:hover { filter: brightness(1.06); transform: translateY(-1px); }
.dlbtn .ti { font-size: 19px; }

.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 11px; margin: 18px 0; }
.stat { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.stat .v { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.stat .k { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.06em; margin-top: 3px; font-weight: 600; }
.stat.warno .v { color: var(--yellow); }

.mix { font-size: 12.5px; color: var(--muted); margin-top: 6px; line-height: 1.8; }
.mix b { color: var(--text); font-weight: 600; }

.checks { display: flex; flex-direction: column; gap: 9px; margin-top: 18px; }
.check { display: flex; align-items: flex-start; gap: 13px; padding: 13px 16px; border-radius: 12px;
  background: var(--panel-2); border: 1px solid var(--line); }
.check .badge { font-size: 10.5px; font-weight: 700; padding: 4px 9px; border-radius: 7px; white-space: nowrap; letter-spacing: 0.04em; }
.check.pass { border-color: rgba(34,197,94,0.22); }
.check.pass .badge { background: var(--green-bg); color: var(--green); }
.check.fail { border-color: rgba(255,90,90,0.30); }
.check.fail .badge { background: var(--red-bg); color: var(--red); }
.check.flag { border-color: rgba(255,200,60,0.28); }
.check.flag .badge { background: var(--yellow-bg); color: var(--yellow); }
.check .body { flex: 1; }
.check .cname { font-size: 13.5px; font-weight: 600; }
.check .cdetail { font-size: 12px; color: var(--muted); margin-top: 3px; font-family: var(--mono); }

.spinner { display: inline-block; width: 15px; height: 15px; border: 2px solid rgba(255,255,255,0.25);
  border-top-color: var(--fl-lime); border-radius: 50%; animation: spin 0.7s linear infinite; vertical-align: -3px; margin-right: 6px; }
@keyframes spin { to { transform: rotate(360deg); } }

.footer { text-align: center; margin-top: 38px; color: var(--faint); font-size: 12px; }
.footer .fl { color: var(--muted); font-weight: 600; letter-spacing: 0.04em; }
.footer .lock { color: var(--fl-green-2); }

.hidden { display: none !important; }
