/* moving.lphg.au - packing UI.
   Built for a phone held in one hand in a half-packed office. Everything is
   thumb-sized, high contrast, and works in bright light. */

:root {
  --bg: #0f172a;
  --panel: #1e293b;
  --panel2: #273449;
  --line: #334155;
  --ink: #f1f5f9;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --go: #22c55e;
  --warn: #f59e0b;
  --bad: #ef4444;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
  padding-bottom: 40px;
}

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 10px 14px;
  background: #0b1220; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
}
.topbar .who { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.topbar nav { display: flex; gap: 14px; }
.topbar a { color: var(--accent); text-decoration: none; font-size: 14px; }

.dot { width: 9px; height: 9px; border-radius: 50%; background: #475569; display: inline-block; }
.dot.busy { background: var(--warn); animation: pulse 1s infinite; }
@keyframes pulse { 50% { opacity: .35; } }

/* ---- current box ---- */
.current {
  display: flex; gap: 14px; align-items: center;
  padding: 16px 14px; background: var(--panel); border-bottom: 1px solid var(--line);
}
.boxcode {
  flex: 0 0 auto; min-width: 112px; min-height: 92px;
  background: var(--panel2); color: var(--ink);
  border: 2px solid var(--accent); border-radius: 14px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  cursor: pointer;
}
.boxcode span { font-size: 42px; font-weight: 800; line-height: 1; letter-spacing: 1px; }
.boxcode small { font-size: 10px; color: var(--muted); margin-top: 6px; }
.curmeta { min-width: 0; }
.curloc { font-size: 19px; font-weight: 600; }
.curcontents { font-size: 14px; color: var(--muted); margin-top: 4px; word-break: break-word; }
.curcount { font-size: 12px; color: var(--muted); margin-top: 6px; }

/* ---- picker ---- */
.picker { padding: 14px; background: #16233b; border-bottom: 1px solid var(--line); }
.picker h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .09em; color: var(--muted); margin: 14px 0 8px; }
.picker h2:first-child { margin-top: 0; }

.letters { display: flex; flex-wrap: wrap; gap: 8px; }
.letter {
  width: 54px; height: 54px; font-size: 22px; font-weight: 700;
  background: var(--panel2); color: var(--ink);
  border: 1px solid var(--line); border-radius: 12px; cursor: pointer;
}
.letter.on { background: var(--accent); color: #06263a; border-color: var(--accent); }

.numbers { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-top: 10px; }
.num {
  height: 52px; font-size: 19px; font-weight: 600;
  background: var(--panel2); color: var(--ink);
  border: 1px solid var(--line); border-radius: 12px; cursor: pointer;
}
.num:active { background: var(--accent); color: #06263a; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 13px 16px; font-size: 15px;
  background: var(--panel2); color: var(--ink);
  border: 1px solid var(--line); border-radius: 999px; cursor: pointer;
}
.chip.on { background: var(--go); color: #052e14; border-color: var(--go); font-weight: 700; }
.chips.recent .chip { border-radius: 12px; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; }
.chips.recent .chip strong { font-size: 17px; }
.chips.recent .chip span { font-size: 11px; color: var(--muted); }

/* ---- voice ---- */
.voice { padding: 14px; }
.mic {
  width: 100%; min-height: 68px; font-size: 17px; font-weight: 600;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--panel2); color: var(--ink);
  border: 2px solid var(--line); border-radius: 14px;
  cursor: pointer; user-select: none; -webkit-user-select: none; touch-action: none;
}
.mic.recording { background: var(--bad); border-color: var(--bad); color: #fff; }
.micicon { font-size: 22px; }
.stt-status { font-size: 13px; color: var(--muted); margin-top: 8px; min-height: 18px; }

/* ---- shoot ---- */
.shoot { padding: 0 14px 8px; }
.shootbtn {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  width: 100%; min-height: 92px; font-size: 22px; font-weight: 800;
  background: var(--go); color: #052e14;
  border-radius: 16px; cursor: pointer;
}
.shootbtn.disabled { background: #475569; color: #cbd5e1; }
.cam { font-size: 28px; }
.queue { font-size: 13px; color: var(--warn); margin-top: 8px; min-height: 18px; }

/* ---- thumbs ---- */
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; padding: 8px 14px; }
.thumb { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 10px; border: 2px solid var(--line); }
.thumb.read { border-color: var(--go); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- finish ---- */
.finish { padding: 14px; }
.btn {
  width: 100%; min-height: 60px; font-size: 17px; font-weight: 700;
  background: var(--panel2); color: var(--ink);
  border: 1px solid var(--line); border-radius: 14px; cursor: pointer;
}
.btn.wide { margin-top: 16px; }
.btn.done { background: var(--accent); color: #06263a; border-color: var(--accent); }
.btn:disabled { opacity: .55; }
.finishmsg { font-size: 14px; color: var(--muted); margin-top: 10px; min-height: 20px; }

/* ---- login ---- */
.loginwrap { max-width: 400px; margin: 8vh auto; padding: 24px; }
.loginwrap h1 { font-size: 22px; margin: 0 0 4px; }
.loginwrap p.sub { color: var(--muted); font-size: 14px; margin: 0 0 22px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.field input {
  width: 100%; padding: 15px; font-size: 16px;
  background: var(--panel2); color: var(--ink);
  border: 1px solid var(--line); border-radius: 12px;
}
.pwwrap { position: relative; }
.pwwrap input { padding-right: 54px; }
.eye {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 19px;
}
.err { background: #7f1d1d; color: #fecaca; padding: 12px 14px; border-radius: 10px; font-size: 14px; margin-bottom: 16px; }

/* ---- generic pages ---- */
.page { max-width: 940px; margin: 0 auto; padding: 16px; }
.page h1 { font-size: 21px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 14px; margin-bottom: 12px; }
.card h2 { margin: 0 0 6px; font-size: 19px; }
.meta { color: var(--muted); font-size: 13px; }
.badge { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 11px; background: var(--panel2); color: var(--muted); }
.badge.packed { background: #14532d; color: #bbf7d0; }
.badge.open { background: #422006; color: #fde68a; }
a.plain { color: var(--accent); text-decoration: none; }
.searchbar { display: flex; gap: 8px; margin-bottom: 16px; }
.searchbar input { flex: 1; padding: 15px; font-size: 16px; background: var(--panel2); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; }
.searchbar button { padding: 0 22px; font-size: 16px; font-weight: 700; background: var(--accent); color: #06263a; border: 0; border-radius: 12px; cursor: pointer; }
.ocrtext { font-size: 12px; color: var(--muted); white-space: pre-wrap; max-height: 130px; overflow: auto; background: #0b1220; padding: 10px; border-radius: 8px; margin-top: 8px; }

@media (min-width: 720px) {
  .numbers { grid-template-columns: repeat(12, 1fr); }
}
