:root {
  --ink: #232323;
  --ink-2: #3A3F46;
  --muted: #5B6068;
  --bg: #F4F6F8;
  --card: #FFFFFF;
  --line: #E1E5EA;
  --line-2: #E9EDF1;
  --field: #CBD2D9;
  --soft: #F7F9FB;
  --blue: #38B6FF;
  --blue-ink: #0A6BA8;
  --blue-soft: #EAF6FF;
  --ok-bg: #E3F1EC; --ok: #0B5E4A;
  --warn-bg: #FCEBD7; --warn: #7C2D12;
  --bad-bg: #F8E0DE; --bad: #9B1C1C;
  --info-bg: #E1E9F7; --info: #1E429F;
  --mute-bg: #EDF0F3; --mute: #4B4F56;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: 'Cairo', system-ui, sans-serif; background: var(--bg); color: var(--ink); font-size: 16px; line-height: 1.6; }
a { color: var(--blue-ink); }
a:hover { color: #08507E; }
h1, h2, h3 { margin: 0; line-height: 1.3; }
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
[hidden] { display: none !important; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 10px; border: 1px solid var(--field); background: #fff; color: var(--ink); font-weight: 700; font-size: 15px; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--soft); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-dark:hover { background: #000; }
.btn-blue { background: var(--blue); border-color: var(--blue); color: var(--ink); }
.btn-blue:hover { background: #22A6F2; }
.btn-lg { min-height: 64px; font-size: 22px; border-radius: 12px; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 14px; }

.field { width: 100%; min-height: 48px; border: 1px solid var(--field); border-radius: 10px; padding: 8px 14px; background: #fff; font-size: 17px; }
.field:focus, .btn:focus-visible { outline: 3px solid var(--blue); outline-offset: 1px; }
textarea.field { min-height: 110px; resize: vertical; }
label.lbl { display: block; font-size: 14px; font-weight: 700; color: var(--ink-2); margin-bottom: 6px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; }
.pill { display: inline-flex; align-items: center; padding: 2px 10px; border-radius: 999px; font-size: 13px; font-weight: 700; white-space: nowrap; }
.ok { background: var(--ok-bg); color: var(--ok); }
.warn { background: var(--warn-bg); color: var(--warn); }
.bad { background: var(--bad-bg); color: var(--bad); }
.info { background: var(--info-bg); color: var(--info); }
.mute { background: var(--mute-bg); color: var(--mute); }
.blue { background: var(--blue-soft); color: #0A5A8C; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.row { display: flex; align-items: center; gap: 12px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.spread { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }

table.tbl { width: 100%; border-collapse: collapse; }
.tbl th { font-size: 13px; color: var(--muted); font-weight: 700; text-align: right; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--soft); white-space: nowrap; }
.tbl td { padding: 12px 14px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.tbl tr:last-child td { border-bottom: none; }
.table-wrap { overflow-x: auto; }

.banner { padding: 12px 16px; border-radius: 12px; font-size: 15px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 20px; border-radius: 12px; font-weight: 700; z-index: 100; max-width: 90vw; }
.toast.err { background: var(--bad); }

.modal-back { position: fixed; inset: 0; background: rgba(35, 35, 35, .55); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 50; }
.modal { background: #fff; border-radius: 20px; padding: 28px; width: 100%; max-width: 680px; max-height: 94vh; overflow: auto; display: flex; flex-direction: column; gap: 18px; }

.cam { position: relative; background: #2E2E2E; border-radius: 16px; overflow: hidden; aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; }
.cam video, .cam img { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.cam .guide { position: absolute; inset: 8% 25%; border: 3px dashed var(--blue); border-radius: 50%; pointer-events: none; }
.cam .count { position: absolute; top: 16px; left: 16px; width: 88px; height: 88px; border-radius: 50%; background: var(--blue); color: var(--ink); display: flex; align-items: center; justify-content: center; font-size: 52px; font-weight: 800; }
.cam .tag { position: absolute; top: 14px; right: 14px; }
.cam .hint { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: #fff; font-size: 16px; text-shadow: 0 1px 3px #000; }

.logo-mark { height: 56px; width: auto; }
.logo-word { height: 20px; width: auto; }
