/* Clean, light-lavender theme. Font: Geist (falls back to the system font if offline). */
:root {
  --ink: #17151f; --text: #2b2838; --muted: #8a8698; --line: #ece9f5; --line-2: #e2ddf0;
  --bg: #f3f0fb; --card: #ffffff; --soft: #f7f5fd;
  --purple: #8b5cf6; --purple-d: #6d3fe0; --purple-l: #ede7fe; --purple-xl: #f6f2ff;
  --red: #e5484d; --red-l: #ffe9ea; --orange: #f5890b; --orange-l: #fff1e0;
  --green: #2fa36b; --green-l: #e3f6ec; --gray: #9a97a8; --gray-l: #f0eff4;
  --radius: 20px; --radius-sm: 12px; --tabbar-h: 66px;
  --shadow: 0 1px 2px rgba(40, 20, 90, .04), 0 8px 24px rgba(60, 30, 130, .06);
  font-family: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text); background: var(--bg);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0; min-height: 100vh; padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); -webkit-text-size-adjust: 100%;
  background: radial-gradient(1200px 600px at 100% -10%, #e6dcff 0%, transparent 60%),
              radial-gradient(900px 500px at -10% 110%, #ebe4ff 0%, transparent 55%), var(--bg);
  background-attachment: fixed;
}
a { color: var(--purple-d); }
h1 { font-size: 1.6rem; font-weight: 600; letter-spacing: -.01em; color: var(--ink); margin: .2rem 0 1rem; }
h2 { font-size: 1.05rem; font-weight: 600; color: var(--ink); margin: 1.6rem 0 .7rem; padding-bottom: .5rem; border-bottom: 1px solid var(--line); }
h3 { font-size: 1rem; font-weight: 600; color: var(--ink); margin: .2rem 0 .7rem; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.container { max-width: 1040px; margin: 0 auto; padding: 1.2rem 1rem 2rem; }
code { background: var(--purple-l); padding: .05rem .35rem; border-radius: 6px; font-size: .85em; }

/* ---- Header ---- */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 1rem; padding: .75rem 1rem;
  background: rgba(255, 255, 255, .78); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: .6rem; color: var(--ink); font-weight: 500; font-size: 1.1rem; text-decoration: none; white-space: nowrap; }
.logo { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #a78bfa, var(--purple-d)); box-shadow: 0 4px 12px rgba(139, 92, 246, .35); }
.whoami { margin-left: auto; display: flex; gap: .55rem; align-items: center; white-space: nowrap; }
.whoami .who { display: flex; flex-direction: column; line-height: 1.15; font-size: .85rem; }
.whoami .who small { color: var(--muted); font-size: .75rem; }
.whoami button { background: transparent; color: var(--muted); border: 1px solid var(--line-2); padding: .3rem .75rem; min-height: 0; font-size: .8rem; font-weight: 500; }
.whoami button:hover { background: var(--purple-xl); color: var(--ink); }
@media (max-width: 420px) { .whoami .who { display: none; } }

.avatar { flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center;
  background: linear-gradient(135deg, #ddd0ff, #c4b0fb); color: var(--purple-d); font-size: .72rem; font-weight: 600; }
.assignee { display: inline-flex; align-items: center; gap: .35rem; color: var(--text); }
.assignee .avatar { width: 22px; height: 22px; font-size: .6rem; }
.icon { flex-shrink: 0; }

/* ---- Side rail (desktop) ---- */
.sidebar { display: none; }
@media (min-width: 900px) {
  body.has-nav .topbar { display: none; }
  body.has-nav .shell { display: grid; grid-template-columns: 96px minmax(0, 1fr); }
  body.has-nav .sidebar { display: flex; flex-direction: column; align-items: center; gap: 1.1rem; position: sticky; top: 0; align-self: start;
    height: 100vh; padding: 1rem .5rem 1.1rem; background: rgba(250, 249, 254, .85); border-right: 1px solid var(--line);
    border-radius: 0 22px 22px 0; z-index: 25; }
  body.has-nav .container { margin: 0; max-width: 1100px; padding: 1.6rem 2rem 2.5rem; }
}
.rail-logo { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; color: #fff; flex-shrink: 0;
  background: linear-gradient(135deg, #a78bfa, var(--purple-d)); box-shadow: 0 6px 16px rgba(139, 92, 246, .3); }
.sidenav { display: flex; flex-direction: column; align-items: center; gap: .35rem; width: 100%; }
#railbottom { margin-top: auto; }
.sidenav a { width: 80px; display: flex; flex-direction: column; align-items: center; gap: .3rem; padding: .65rem .2rem; border-radius: 16px;
  color: #5b5869; text-decoration: none; font-size: .78rem; text-align: center; line-height: 1.15; transition: background .15s, color .15s; }
.sidenav a .ic { display: grid; place-items: center; }
.sidenav a:hover { background: var(--purple-xl); color: var(--ink); }
.sidenav a.active { background: var(--purple-l); color: var(--purple-d); font-weight: 600; }
.railme { width: 64px; padding-top: 1rem; border-top: 1px solid var(--line-2); display: flex; justify-content: center; position: relative; }
.railme summary { list-style: none; cursor: pointer; }
.railme summary::-webkit-details-marker { display: none; }
.railme .avatar { width: 46px; height: 46px; font-size: .9rem; background: linear-gradient(135deg, #a78bfa, var(--purple-d)); color: #fff; }
.railmenu { position: absolute; left: calc(100% + 18px); bottom: 0; z-index: 30; min-width: 190px; display: flex; flex-direction: column; gap: .15rem;
  background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: .9rem; box-shadow: 0 12px 32px rgba(60, 30, 130, .16); }
.railmenu small { color: var(--muted); margin-bottom: .6rem; }

/* ---- Bottom tab bar (phones) ---- */
.tabbar { position: fixed; bottom: 0; left: 0; right: 0; z-index: 20; display: flex; background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line);
  height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding: 0 .3rem env(safe-area-inset-bottom); }
.tabbar a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  text-decoration: none; color: var(--muted); font-size: .7rem; font-weight: 500; }
.tabbar a .ic { display: grid; place-items: center; width: 44px; height: 30px; border-radius: 999px; transition: background .15s; }
.tabbar a.active { color: var(--ink); }
.tabbar a.active .ic { background: var(--ink); color: #fff; }
.tabbar:empty { display: none; }
@media (min-width: 900px) { .tabbar { display: none; } body { padding-bottom: 0; } }

/* ---- Cards & layout ---- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.15rem 1.2rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.row { display: flex; gap: .7rem; flex-wrap: wrap; align-items: center; }
.grid2 { display: grid; grid-template-columns: 1fr; gap: .1rem 1.1rem; }
@media (min-width: 640px) { .grid2 { grid-template-columns: 1fr 1fr; } }
.spacer { flex: 1; }

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: .7rem; margin-bottom: 1rem; }
@media (min-width: 640px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; box-shadow: var(--shadow); }
.stat .n { font-size: 1.75rem; font-weight: 500; color: var(--ink); line-height: 1.1; }
.stat .l { font-size: .82rem; color: var(--muted); margin-top: .15rem; }
.stat.st-new { background: linear-gradient(135deg, #a78bfa, var(--purple-d)); border-color: transparent; }
.stat.st-new .n, .stat.st-new .l { color: #fff; }
.stat.st-urgent .n { color: var(--red); }

/* ---- Forms ---- */
label { display: block; font-size: .78rem; font-weight: 500; color: var(--muted); margin: .8rem 0 .3rem; }
label.req::after { content: " *"; color: var(--red); }
input, select, textarea, button { font: inherit; font-size: 16px; } /* 16px stops iOS zoom on focus */
input[type=text], input[type=password], input[type=tel], input[type=email], input[type=number], input[type=date], input:not([type]), select, textarea {
  width: 100%; padding: .7rem .85rem; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--soft);
  color: var(--ink); min-height: 46px; transition: border-color .15s, box-shadow .15s, background .15s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--purple); background: #fff; box-shadow: 0 0 0 4px rgba(139, 92, 246, .15); }
select { appearance: none; -webkit-appearance: none; padding-right: 2.2rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238a8698' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .9rem center; }
textarea { min-height: 110px; resize: vertical; }
input:disabled, select:disabled, input[readonly] { background-color: var(--gray-l); color: #5d5a6b; }
input[type=file] { font-size: .9rem; color: var(--muted); }
input[type=file]::file-selector-button { font: inherit; border: 1px solid var(--line-2); background: var(--purple-xl); color: var(--purple-d);
  border-radius: 999px; padding: .45rem 1rem; margin-right: .7rem; cursor: pointer; font-weight: 500; }
.check { display: flex; align-items: center; gap: .55rem; font-size: .95rem; color: var(--text); margin: .55rem 0; font-weight: 400; }
.check input { width: 20px; height: 20px; accent-color: var(--purple); }

button, .btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; min-height: 44px; padding: .55rem 1.2rem;
  border-radius: 999px; border: 1px solid var(--ink); background: var(--ink); color: #fff; cursor: pointer; text-decoration: none;
  font-weight: 500; transition: transform .05s, background .15s, box-shadow .15s; }
button:active, .btn:active { transform: translateY(1px); }
button:hover, .btn:hover { box-shadow: 0 4px 14px rgba(23, 21, 31, .15); }
button.secondary, .btn.secondary { background: #fff; color: var(--ink); border-color: var(--line-2); }
button.secondary:hover, .btn.secondary:hover { background: var(--purple-xl); box-shadow: none; }
button.danger { background: var(--purple-d); border-color: var(--purple-d); }
button.good { background: var(--purple); border-color: var(--purple); }
button.block { width: 100%; }
button.big { min-height: 60px; font-size: 1.1rem; }
button:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }

/* ---- Work order list ---- */
.list { display: flex; flex-direction: column; gap: .65rem; }
.wo { position: relative; display: flex; gap: .9rem; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: .9rem 1rem; text-decoration: none; color: var(--text); box-shadow: var(--shadow); transition: transform .12s, box-shadow .12s, border-color .12s; }
.wo:hover { transform: translateY(-1px); border-color: var(--line-2); box-shadow: 0 10px 28px rgba(60, 30, 130, .1); }
.wo::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 4px; border-radius: 0 4px 4px 0; background: transparent; }
.wo.p-Emergency::before { background: var(--red); } .wo.p-High::before { background: var(--orange); }
.wo.p-Routine::before { background: var(--purple); } .wo.p-Low::before { background: var(--green); }
.wo img { width: 64px; height: 64px; object-fit: cover; border-radius: 14px; flex-shrink: 0; }
.wo .t { font-weight: 500; color: var(--ink); }
.wo .meta { font-size: .82rem; color: var(--muted); margin-top: .2rem; }
.menu-item { padding: 1rem 1.1rem; }
.menu-ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--purple-l); color: var(--purple-d); }

.badge { display: inline-block; padding: .18rem .65rem; border-radius: 999px; font-size: .74rem; font-weight: 500; white-space: nowrap; line-height: 1.35; }
.b-Emergency { background: var(--red); color: #fff; } .b-High { background: var(--orange); color: #fff; }
.b-Routine { background: var(--purple); color: #fff; } .b-Low { background: var(--green); color: #fff; }
.s-new { background: var(--purple-l); color: var(--purple-d); } .s-assigned { background: #e8efff; color: #3d5fd1; }
.s-in_progress { background: var(--orange-l); color: #b8610a; } .s-completed { background: var(--green-l); color: #1f7a4f; }
.s-cancelled { background: var(--gray-l); color: var(--gray); }

.tabs { display: flex; gap: .4rem; overflow-x: auto; margin-bottom: .9rem; padding-bottom: 2px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { padding: .5rem 1rem; border-radius: 999px; background: #fff; border: 1px solid var(--line-2); text-decoration: none; color: var(--text); white-space: nowrap; font-size: .9rem; }
.tabs a.active { background: var(--ink); color: #fff; border-color: var(--ink); }

.notice { padding: .85rem 1rem; border-radius: var(--radius-sm); background: var(--purple-xl); border: 1px solid #e0d5fd; margin-bottom: 1rem; font-size: .92rem; color: var(--text); }
.notice.err { background: var(--red-l); border-color: #ffc9cc; color: #a3262b; }
.notice.ok { background: var(--green-l); border-color: #bfe8d3; }
.dev { background: #fff7ea; border: 1.5px dashed var(--orange); padding: .7rem .9rem; border-radius: var(--radius-sm); margin: .9rem 0; }
.dev b { color: #b8610a; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--gray); margin-right: .5rem; vertical-align: middle; }
.dot.on { background: var(--green); box-shadow: 0 0 0 4px var(--green-l); }

.photo-preview { max-width: 100%; max-height: 320px; border-radius: 16px; margin-top: .5rem; display: block; }
.timeline { list-style: none; padding: 0; margin: 0; font-size: .88rem; }
.timeline li { padding: .6rem 0; border-bottom: 1px solid var(--line); }

table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: .65rem .5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .75rem; color: var(--muted); font-weight: 500; }
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .3rem .7rem; box-shadow: var(--shadow); }

.clock { text-align: center; padding: 1.6rem 1.2rem; }
.clock .status { font-size: 1.1rem; margin-bottom: 1rem; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 18px); transform: translateX(-50%); background: var(--ink); color: #fff;
  padding: .75rem 1.2rem; border-radius: 999px; opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 50; max-width: 92vw; text-align: center; font-size: .92rem; }
.toast.show { opacity: 1; }
.toast.err { background: var(--red); }

/* ---- Sign-off sheet (mirrors "Work order sign-off sheet.pdf") ---- */
.sheet { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.sheet-head { display: flex; flex-wrap: wrap; gap: .8rem; align-items: flex-end; border-bottom: 1px solid var(--line); padding-bottom: .9rem; }
.sheet-head h1 { margin: 0; font-size: 1.5rem; flex: 1 1 220px; }
.sheet-head .won { flex: 1 1 200px; } .sheet-head .won label { margin-top: 0; }
.pill-toggle { display: inline-flex; background: var(--gray-l); border-radius: 999px; padding: 3px; }
.pill-toggle button { border: 0; border-radius: 999px; min-height: 36px; background: transparent; color: var(--muted); font-size: .85rem; padding: .3rem 1rem; box-shadow: none; }
.pill-toggle button.on { background: var(--ink); color: #fff; }
.pill { display: inline-block; border-radius: 999px; padding: .3rem 1rem; font-size: .85rem; font-weight: 500; background: var(--purple-l); color: var(--purple-d); }
.sheet h2 .sub { font-size: .78rem; font-weight: 400; color: var(--muted); }
.req-time label { color: var(--purple-d); }
.parts { width: 100%; }
.parts td { padding: .25rem; border: 0; }
.parts input { min-height: 42px; }
.parts .qty { width: 70px; } .parts .pn { width: 30%; }
.insp { display: flex; flex-direction: column; gap: .55rem; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.insp .item { font-size: .95rem; color: var(--ink); }
.insp .controls { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }
.insp .controls input { flex: 1 1 200px; }
.seg { display: inline-flex; background: var(--gray-l); border-radius: 999px; padding: 3px; flex-shrink: 0; }
.seg button { border: 0; border-radius: 999px; background: transparent; color: var(--muted); min-width: 64px; min-height: 40px; padding: .3rem .8rem; font-size: .9rem; box-shadow: none; }
.seg button.on.r-Pass { background: var(--green); color: #fff; }
.seg button.on.r-Fail { background: var(--red); color: #fff; }
.seg button.on.r-NA { background: var(--gray); color: #fff; }
.signs { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 700px) { .signs { grid-template-columns: 1fr 1fr; } }
.signbox { border: 1px solid var(--line-2); border-radius: 16px; padding: .9rem; background: var(--soft); }
.signbox h3 { margin: 0; } .signbox .desc { font-size: .78rem; color: var(--muted); margin-bottom: .45rem; }
.pad-wrap { position: relative; margin-top: .55rem; border: 1.5px dashed #cfc4f2; border-radius: 12px; background: #fff; touch-action: none; overflow: hidden; }
.pad-wrap canvas { display: block; width: 100%; height: 160px; touch-action: none; }
.pad-wrap .clear { position: absolute; left: 8px; bottom: 8px; min-height: 30px; padding: .1rem .6rem; background: #fff; color: var(--muted); border: 1px solid var(--line-2); font-weight: 400; }
.pad-wrap .hint { position: absolute; right: 10px; bottom: 8px; color: #c3b9e6; font-size: .75rem; pointer-events: none; }
.sig-img { max-width: 100%; height: 120px; object-fit: contain; border-bottom: 1px solid var(--ink); display: block; background: #fff; }
.kv { font-size: .95rem; color: var(--ink); padding: .35rem 0 .55rem; border-bottom: 1px solid var(--line); min-height: 1.6rem; }

/* ---- Ranked work queue ---- */
.rank { flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  font-size: 1.15rem; font-weight: 600; color: #fff; background: var(--gray); }
.rk-Emergency { background: var(--red); } .rk-High { background: var(--orange); } .rk-Routine { background: var(--purple); } .rk-Low { background: var(--green); }
.wo.next { border-color: #d8cbfd; box-shadow: 0 0 0 4px var(--purple-xl), 0 12px 30px rgba(109, 63, 224, .14); }
.wo.next .rank { width: 54px; height: 54px; font-size: 1.4rem; }
.next-label { font-size: .7rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--purple-d); margin-bottom: .15rem; }
.qgroup { margin-bottom: 1.3rem; }
.qhead { display: flex; align-items: center; gap: .1rem; margin: 1.1rem 0 .6rem; border-bottom: 0; padding-bottom: 0; font-size: .95rem; }
.qh-Emergency .dot { background: var(--red); } .qh-High .dot { background: var(--orange); }
.qh-Routine .dot { background: var(--purple); } .qh-Low .dot { background: var(--green); }
.qcount { margin-left: .45rem; font-size: .75rem; font-weight: 500; border-radius: 999px; padding: .05rem .55rem; background: var(--purple-l); color: var(--purple-d); }

@media print {
  .topbar, .tabbar, .no-print, .toast { display: none !important; }
  body { background: #fff; padding: 0; }
  .container { max-width: none; padding: 0; }
  .sheet { border: 0; box-shadow: none; }
}

/* ---- Public request page ---- */
.narrow { max-width: 560px; margin: 0 auto; }
.card.done { background: var(--green-l); border-color: #bfe8d3; }

/* Inbox */
.ic { position: relative; }
.unread { position: absolute; top: -4px; right: -8px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--red);
  color: #fff; font-size: .68rem; font-weight: 600; line-height: 18px; text-align: center; box-shadow: 0 0 0 2px #fff; }
.tabbar a .ic .unread { top: -2px; right: 0; }
h3.day { font-size: .82rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: .8rem 0 .1rem; font-weight: 500; }
.list h3.day:first-child { margin-top: 0; }
.wo.note { align-items: flex-start; }
.wo.note .note-body { font-size: .92rem; margin-top: .15rem; overflow-wrap: anywhere; }
.wo.unread-item { background: var(--purple-xl); border-color: #d8cbfd; }
.wo.unread-item .t::after { content: ""; display: inline-block; width: 8px; height: 8px; margin-left: .45rem; border-radius: 50%; background: var(--purple); vertical-align: middle; }
.note-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; background: var(--purple-l); color: var(--purple-d); }
.note-ic.k-reminder { background: #fff1e0; color: var(--orange); }
.note-ic.k-assignment { background: var(--green-l); color: var(--green); }

/* Reports */
table.report td, table.report th { white-space: nowrap; }
table.report td .small { white-space: normal; }
table.report td.bad { color: var(--red); font-weight: 600; }

/* Photos: up to 5 per order */
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: .5rem; margin: .35rem 0 .6rem; }
.thumb { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--gray-l); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .rm { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; min-height: 0; padding: 0; border-radius: 50%; border: 0;
  background: rgba(20, 16, 40, .72); color: #fff; font-size: 1.1rem; line-height: 28px; text-align: center; cursor: pointer; }
.add-photo { display: inline-flex; align-items: center; gap: .4rem; cursor: pointer; margin-top: .2rem; }
.add-photo[hidden] { display: none !important; }
.photo-note { margin-top: .35rem; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .55rem; margin-bottom: 1rem; }
.gallery a { display: block; aspect-ratio: 4 / 3; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); }
.gallery img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery:has(a:only-child) { grid-template-columns: 1fr; }
.gallery a:only-child { aspect-ratio: auto; max-height: 360px; }
.gallery a:only-child img { object-fit: contain; background: var(--gray-l); max-height: 360px; }
.wo-img { position: relative; flex-shrink: 0; }
.wo-img .more-n { position: absolute; right: 4px; bottom: 4px; background: rgba(20, 16, 40, .75); color: #fff; font-size: .7rem; font-weight: 600;
  padding: .05rem .4rem; border-radius: 999px; }

/* Day plan (route view of the queue) */
.plan-sum { background: var(--purple-xl); border-color: #e2d8fd; }
.stop { margin-bottom: 1.3rem; }
.stop-head { display: flex; align-items: center; gap: .7rem; font-size: 1.05rem; margin: 1.1rem 0 .6rem; }
.stop-n { flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--purple-d); color: #fff; font-size: .9rem; }
.stop-name { display: block; }
.stop-meta { display: block; font-size: .78rem; font-weight: 400; color: var(--muted); margin-top: .1rem; }
.later { display: flex; justify-content: space-between; align-items: baseline; gap: .6rem; margin: .4rem 0; padding: .55rem .8rem;
  border-top: 2px dashed #d8cbfd; color: var(--purple-d); font-weight: 600; font-size: .85rem; }
