:root {
  --blue: #38b6ff;
  --blue-soft: #eaf7ff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e5e7eb;
  --green: #16a34a;
  --red: #dc2626;
  --amber: #d97706;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #fff;
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}

.wrap { max-width: 480px; margin: 0 auto; padding: 20px 16px 40px; }

/* header */
.topbar {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  background: #fff; border-bottom: 1px solid var(--line);
  padding: 14px 16px;
}
.brand { font-weight: 800; font-size: 18px; color: var(--blue); }
.linkbtn { background: none; border: none; color: var(--muted); font-size: 14px; font-weight: 600; cursor: pointer; }

/* headings */
h1 { font-size: 22px; font-weight: 800; margin-bottom: 4px; }
.sub { color: var(--muted); font-size: 14px; margin-bottom: 18px; }
h2 { font-size: 15px; font-weight: 700; margin: 22px 0 10px; }

/* cards */
.card {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 12px;
  background: #fff;
}

/* stat grid */
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.stat { border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.stat.accent { border-color: var(--blue); background: var(--blue-soft); }
.stat .label { font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 600; }
.stat .value { font-size: 22px; font-weight: 800; margin-top: 4px; }

/* forms */
label { display: block; font-size: 13px; font-weight: 600; color: #334155; margin: 12px 0 6px; }
input, select, textarea {
  width: 100%; font: inherit; font-size: 16px;
  border: 1px solid var(--line); border-radius: 12px;
  padding: 12px 14px; background: #fff; outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(56,182,255,.18); }
textarea { min-height: 70px; resize: vertical; }

/* buttons */
.btn {
  display: block; width: 100%; text-align: center;
  background: var(--blue); color: #fff; border: none;
  font-size: 16px; font-weight: 700;
  padding: 14px; border-radius: 14px; cursor: pointer;
  text-decoration: none;
}
.btn:active { transform: scale(.99); }
.btn.secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn.ghost { background: var(--blue-soft); color: var(--blue); }
.btn.green { background: var(--green); }
.btn.disabled { opacity: .5; pointer-events: none; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* badges */
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.badge.blue { background: var(--blue-soft); color: var(--blue); }
.badge.green { background: #dcfce7; color: var(--green); }
.badge.amber { background: #fef3c7; color: var(--amber); }
.badge.gray { background: #f1f5f9; color: var(--muted); }

/* partner/job card bits */
.job-title { font-size: 17px; font-weight: 800; }
.muted { color: var(--muted); font-size: 14px; }
.line { display: flex; justify-content: space-between; padding: 6px 0; font-size: 14px; border-top: 1px dashed var(--line); }
.line:first-of-type { border-top: none; }
.line .k { color: var(--muted); }
.line .v { font-weight: 600; }
.net { font-size: 20px; font-weight: 800; color: var(--blue); }
.timer { font-variant-numeric: tabular-nums; font-size: 28px; font-weight: 800; text-align: center; padding: 8px 0; }

.avatar { width: 44px; height: 44px; border-radius: 999px; background: var(--blue-soft); color: var(--blue); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 18px; }
.flex { display: flex; align-items: center; gap: 12px; }
.spacer { height: 8px; }
.empty { text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: 16px; padding: 28px 16px; }
.dot { width: 9px; height: 9px; border-radius: 999px; display: inline-block; }
.dot.on { background: var(--green); }
.dot.off { background: #cbd5e1; }

/* login screen */
.center { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; }
.err { color: var(--red); font-size: 14px; margin-top: 10px; }
.hint { color: var(--muted); font-size: 12px; margin-top: 14px; text-align: center; }
