:root {
  --bg: #0c0e11; --panel: #13161b; --card: #191d24; --card2: #20252e; --line: #2a303b;
  --text: #e9ecf1; --muted: #8a93a3; --accent: #19c3ff; --accent2: #7c5cff;
  --ok: #2fd27a; --warn: #ffb020; --bad: #ff5a5f; --tg: #2aabee; --r: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; }
.task__car { color: var(--accent); text-decoration: none; font-weight: 600; }
.task__car:hover { text-decoration: underline; }
.skip { position: absolute; left: -999px; top: 0; background: var(--card2); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; top: 8px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1:focus { outline: 0; }
button { font: inherit; cursor: pointer; color: inherit; }
input, select, textarea { font: inherit; background: var(--panel); border: 1px solid var(--line); color: var(--text); border-radius: 10px; padding: 9px 12px; width: 100%; }
input:focus, select:focus, textarea:focus { outline: 0; border-color: var(--accent); }
label { display: block; color: var(--muted); font-size: 13px; margin-bottom: 6px; }
h1, h2, h3 { margin: 0; line-height: 1.2; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.stack > * + * { margin-top: 16px; }
.warn-t { color: var(--warn); }
.ok-t { color: var(--ok); }
.mono { font-variant-numeric: tabular-nums; }

.top { position: sticky; top: 0; z-index: 30; background: rgba(12, 14, 17, .92); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.top__in { max-width: 1280px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 14px; }
.logo { font-weight: 800; letter-spacing: .05em; white-space: nowrap; font-size: 17px; }
.logo b { color: var(--accent); }
.tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; flex: 1; }
.tabs::-webkit-scrollbar { display: none; }
.tab { background: none; border: 0; color: var(--muted); padding: 8px 14px; border-radius: 10px; white-space: nowrap; }
.tab.is-on { background: var(--card2); color: var(--text); }
.tab i { font-style: normal; margin-right: 6px; }
.logout { background: none; border: 1px solid var(--line); color: var(--muted); border-radius: 10px; padding: 7px 12px; white-space: nowrap; font-size: 14px; }
main { max-width: 1280px; margin: 0 auto; padding: 20px 16px 60px; }
.screen { display: none; }
.screen.is-on { display: block; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.head h1 { font-size: 24px; }
.head p { margin: 4px 0 0; color: var(--muted); }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; }
.card h3 { font-size: 15px; margin-bottom: 12px; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.btn { border: 0; border-radius: 10px; padding: 10px 16px; background: var(--card2); border: 1px solid var(--line); }
.btn--main { background: linear-gradient(135deg, var(--accent), var(--accent2)); border: 0; color: #fff; font-weight: 600; }
.btn--more { width: 100%; margin-top: 12px; }
.btn--ok { background: var(--ok); border: 0; color: #08140d; font-weight: 600; }
.btn--danger { background: var(--bad); border: 0; color: #fff; font-weight: 600; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 99px; font-size: 12px; background: var(--card2); color: var(--muted); white-space: nowrap; }
.pill--work { background: rgba(25, 195, 255, .14); color: var(--accent); }
.pill--wait { background: rgba(255, 176, 32, .14); color: var(--warn); }
.pill--done { background: rgba(47, 210, 122, .14); color: var(--ok); }
.pill--cancel { background: rgba(255, 90, 95, .16); color: var(--bad); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }
.pill--work .dot { animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .25; } }
.plate { display: inline-block; font-weight: 700; letter-spacing: .04em; background: #fff; color: #111; border-radius: 5px; padding: 1px 6px; font-size: 13px; border: 1px solid #000; white-space: nowrap; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { background: var(--card2); border: 1px solid var(--line); border-radius: 99px; padding: 6px 12px; font-size: 13px; cursor: pointer; }
.chip.is-on { border-color: var(--accent); color: var(--accent); }

.orders { display: grid; gap: 12px; }
.order { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.order:hover { border-color: var(--accent); }
.order__left { flex: 1; }
.order__title { font-weight: 600; margin-bottom: 4px; }
.order__meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }

.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin-top: 16px; }
.photo { position: relative; aspect-ratio: 4/3; background: var(--panel); border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo__label { position: absolute; bottom: 8px; left: 8px; background: rgba(12, 14, 17, .85); padding: 4px 10px; border-radius: 99px; font-size: 12px; backdrop-filter: blur(6px); }

.tasks { display: grid; gap: 10px; }
.task { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.task__left { flex: 1; }
.task__title { font-weight: 600; font-size: 14px; margin-bottom: 3px; }
.task__meta { font-size: 13px; color: var(--muted); }
.task__actions { display: flex; gap: 6px; }

.form-row { margin-bottom: 16px; }
.form-actions { display: flex; gap: 10px; margin-top: 20px; }
.error { background: rgba(255, 90, 95, .12); border: 1px solid var(--bad); color: var(--bad); border-radius: var(--r); padding: 12px 14px; margin-bottom: 16px; }
.notice { background: rgba(25, 195, 255, .12); border: 1px solid var(--accent); color: var(--accent); border-radius: var(--r); padding: 12px 14px; margin-bottom: 16px; font-size: 14px; }

@media (max-width: 640px) {
  .head { flex-direction: column; align-items: flex-start; }
  .order { flex-direction: column; align-items: flex-start; }
  .task { flex-direction: column; align-items: flex-start; }
  .task__actions { width: 100%; }
  .task__actions button { flex: 1; }
}

.zones { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 12px; }
.zone { background: var(--panel); border: 1px dashed var(--line); border-radius: var(--r); padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.zone.is-done { border-style: solid; border-color: var(--ok); }
.zone__name { font-size: 13px; }
.zone__mark { color: var(--muted); font-weight: 700; }
.zone.is-done .zone__mark { color: var(--ok); }
.zone__thumb { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 8px; }
.task--block { flex-direction: column; align-items: stretch; }
.task__row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.helpers { margin-top: 8px; display: grid; gap: 6px; font-size: 13px; }
.helper { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.helper-form { display: grid; grid-template-columns: 1fr 90px 100px auto; gap: 6px; }
.subcard { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.link-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.link-row code { background: var(--panel); border-radius: 8px; padding: 4px 8px; font-size: 12px; word-break: break-all; }
.qr-card { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin-top: 12px; }
.qr { width: 220px; height: 220px; border-radius: 8px; background: #fff; }
.qr-card__caption { margin: 0; color: var(--muted); font-size: 13px; }
@media (max-width: 640px) { input, select, textarea { font-size: 16px; } }
@media print {
  body.print-qr * { visibility: hidden; }
  body.print-qr .qr-card, body.print-qr .qr-card * { visibility: visible; }
  body.print-qr .qr-card button { display: none; }
  body.print-qr .qr-card { position: absolute; left: 0; top: 0; color: #000; }
  body.print-qr .qr { width: 9cm; height: 9cm; }
  body.print-qr .qr-card__caption { color: #000; font-size: 16pt; }
}
.link-row__label { min-width: 150px; color: var(--muted); font-size: 13px; }
@media (max-width: 640px) { .helper-form { grid-template-columns: 1fr 1fr; } }

.plan-line { display: grid; gap: 8px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
.plan-line.is-review { border-color: var(--warn); }
.plan-line__pick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.plan-line input[type="checkbox"] { width: auto; }
@media (max-width: 640px) { .plan-line__pick { grid-template-columns: 1fr; } }
