:root {
  --pink: #f4a3bf;        /* Pantone 223 C, brand accent */
  --pink-deep: #d9537f;
  --ink: #1c1c22;
  --muted: #6b6b76;
  --line: #ececf1;
  --bg: #f7f7fa;
  --card: #ffffff;
  --ok: #1f9d55;
  --warn: #c2410c;
  --bad: #b91c1c;
  --radius: 16px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: -apple-system, "SF Arabic", "Geeza Pro", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;
  background: var(--bg); color: var(--ink); line-height: 1.6;
  -webkit-text-size-adjust: 100%;
  padding-bottom: env(safe-area-inset-bottom);
}
.top { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 2; }
.brand { font-weight: 800; font-size: 22px; letter-spacing: -0.5px; }
.brand::after { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--pink-deep); margin-inline-start: 4px; vertical-align: middle; }
.store { color: var(--muted); text-decoration: none; font-size: 14px; }
main { max-width: 520px; margin: 0 auto; padding: 16px; }
.card { background: var(--card); border-radius: var(--radius); padding: 18px 16px; margin-bottom: 12px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
h1 { font-size: 24px; margin: 0 0 4px; }
h2 { font-size: 16px; margin: 0 0 12px; }
.sub { color: var(--muted); margin: 0 0 16px; font-size: 15px; }
label { display: block; font-size: 14px; font-weight: 600; margin: 12px 0 6px; }
input {
  width: 100%; font-size: 18px; padding: 14px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink);
  text-align: right; font-family: inherit;
}
input:focus { outline: none; border-color: var(--pink-deep); box-shadow: 0 0 0 3px rgba(244,163,191,.35); }
button { font-family: inherit; }
#go, .secondary {
  width: 100%; margin-top: 18px; font-size: 17px; font-weight: 700; padding: 15px; border: 0; border-radius: 12px; cursor: pointer;
  background: var(--ink); color: #fff;
}
#go[disabled] { opacity: .6; }
.secondary { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.hint { color: var(--muted); font-size: 13px; margin: 12px 0 0; }
.error { color: var(--bad); background: #fef2f2; border-radius: 10px; padding: 10px 12px; font-size: 14px; margin: 12px 0 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.big { font-size: 22px; font-weight: 800; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.pill { font-size: 14px; font-weight: 700; padding: 6px 12px; border-radius: 999px; background: #fdf0f5; color: var(--pink-deep); white-space: nowrap; }
.pill.ok { background: #e8f7ee; color: var(--ok); }
.pill.warn { background: #fff4ec; color: var(--warn); }
.pill.bad { background: #fef2f2; color: var(--bad); }
.note { margin: 12px 0 4px; font-size: 15px; }
.steps { list-style: none; margin: 0; padding: 0; }
.steps li { position: relative; padding: 0 30px 18px 0; color: var(--muted); }
.steps li:last-child { padding-bottom: 0; }
.steps li::before { content: ""; position: absolute; right: 6px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--line); }
.steps li::after { content: ""; position: absolute; right: 11px; top: 20px; bottom: -2px; width: 2px; background: var(--line); }
.steps li:last-child::after { display: none; }
.steps li.done { color: var(--ink); }
.steps li.done::before { background: var(--ink); }
.steps li.done::after { background: var(--ink); }
.steps li.current::before { background: var(--pink-deep); box-shadow: 0 0 0 4px rgba(244,163,191,.45); }
.steps li.current { font-weight: 700; }
.steps .when { display: block; font-size: 12px; color: var(--muted); font-weight: 400; }
.kv { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 15px; }
.kv:first-of-type { border-top: 0; }
.kv span { color: var(--muted); flex: 1; }
.kv.total { font-size: 17px; }
.link { background: none; border: 0; color: var(--pink-deep); font-weight: 700; padding: 4px 6px; cursor: pointer; font-size: 14px; }
.items { list-style: none; margin: 0 0 4px; padding: 0; }
.items li { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.items img, .items .ph { width: 52px; height: 52px; border-radius: 10px; object-fit: cover; background: var(--bg); flex: none; }
.items .name { flex: 1; font-size: 15px; }
.items .qty { color: var(--muted); font-size: 14px; white-space: nowrap; }
.actions { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; margin-top: 8px; }
.actions button { font-size: 13px; padding: 10px 4px; border-radius: 10px; border: 1.5px dashed var(--line); background: #fff; color: var(--muted); }
.contact { display: block; text-align: center; margin-top: 14px; padding: 13px; border-radius: 12px; background: #e8f7ee; color: var(--ok); font-weight: 700; text-decoration: none; }
.foot { text-align: center; color: var(--muted); font-size: 12px; padding: 8px 16px 28px; }
@media (min-width: 600px) { main { padding-top: 32px; } }
