:root {
  font-family: "Segoe UI", "Microsoft YaHei UI", sans-serif;
  color: #162a3e;
  background: #edf3f7;
  font-synthesis: none;
  --navy: #101f31;
  --muted: #516778;
  --line: #dbe5ec;
  --accent: #08768c;
  --accent-light: #e0f4f7;
  --confirmed: #087b63;
  --review: #9b6104;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input, select, textarea { font: inherit; }
button, a, input, textarea, select { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .6; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid #198ba1;
  outline-offset: 3px;
}
a { color: var(--accent); text-underline-offset: 3px; }
[hidden] { display: none !important; }
.symbols { position: absolute; width: 0; height: 0; overflow: hidden; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.app-shell { display: grid; grid-template-columns: 220px minmax(0,1fr); min-height: 100vh; }
.sidebar {
  color: #e7f3f8; background: linear-gradient(153deg,#162a41,#101d2e 68%);
  padding: 30px 17px 18px; display: flex; flex-direction: column; gap: 27px;
  position: sticky; top: 0; height: 100vh; overflow: auto;
}
.brand { display: flex; gap: 11px; align-items: center; padding: 0 4px; }
.brand-mark { display: grid; place-items: center; width: 43px; height: 43px; color: #a8f0fc; background: #254760; border: 1px solid #416078; border-radius: 13px; }
.brand-mark svg { width: 24px; height: 24px; }
.brand strong { display: block; font-size: 19px; letter-spacing: .04em; }
.brand small { display: block; color: #adc3d0; margin-top: 3px; font-size: 12px; }
.nav-label { color: #9fb6c9; font-size: 13px; margin: 0 8px 9px; }
.nav-item {
  display: flex; gap: 11px; align-items: center; padding: 10px 11px; width: 100%;
  border: 1px solid transparent; border-radius: 9px; color: #c5d8e5; background: transparent;
  text-align: left; margin: 2px 0; min-height: 42px; font-size: 14px;
}
.nav-item:hover { background: #213950; }
.nav-item.current { background: #233f59; color: #edfcff; border-color: #385870; }
.nav-item.current svg, .nav-item.current .shelf-code { color: #9fe9f8; }
.shelf-label { display: flex; align-items: center; justify-content: space-between; margin-bottom: 3px; }
.icon-btn { display: inline-grid; place-items: center; width: 33px; min-height: 33px; padding: 0; border: 0; border-radius: 8px; color: inherit; background: transparent; }
.icon-btn:hover { background: #cbdde788; }
.sidebar .icon-btn:hover { background: #2d465c; }
.shelf-code { font: 600 12px Consolas, monospace; color: #a7c3d3; background: #09152560; padding: 3px 5px; border-radius: 4px; }
.side-bottom { margin-top: auto; border-top: 1px solid #3f5667; padding: 13px 6px 0; }
.demo-link { display:block; margin: 1px 0 13px; font-size: 13px; color: #a7e7f4; }
.local { display: flex; align-items: center; gap: 7px; color: #b7cad6; font-size: 12px; }
.local span, .eyebrow span { width: 7px; height: 7px; background: #45bcac; border-radius: 50%; }
.local span { box-shadow: 0 0 0 3px #46c4aa26; }
.main { min-width: 0; }
.topbar { min-height: 68px; padding: 12px clamp(18px,3vw,40px); display: flex; align-items: center; gap: 13px; background: #fff; border-bottom: 1px solid var(--line); }
.crumb { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 14px; flex: 1; }
.crumb svg { color: var(--accent); }
.crumb strong { color: #1c3549; overflow-wrap: anywhere; }
.global-search { display: flex; gap: 8px; align-items: center; width: min(310px, 40%); min-width: 150px; border-radius: 9px; border: 1px solid var(--line); padding: 7px 9px; color: #526f83; background: #f5f8fb; }
.global-search input { flex: 1; min-width: 0; width: 100%; border: 0; outline: none; padding: 2px 0; background: transparent; color: #20394d; font-size: 14px; }
.global-search:focus-within { outline: 2px solid #198ba1; }
kbd { padding: 1px 5px; border: 1px solid #d7e3eb; border-radius: 3px; background: white; font-size: 12px; }
.button {
  display: inline-flex; justify-content: center; align-items: center; gap: 7px; min-height: 39px; padding: 7px 12px;
  border-radius: 8px; border: 1px solid #bfcfd9; background: #fff; color: #244158; font-size: 14px;
  font-weight: 600; text-decoration: none; text-align: center;
}
.button:hover { background: #edf5f8; border-color: #88a9bc; }
.button svg { width: 17px; height: 17px; }
.button.primary, .scan-button { background: #0c5669; color: #fff; border-color: #0c5669; }
.button.primary:hover, .scan-button:hover { background: #084253; }
.button.quiet { background: #f6fafc; }
.button.danger { color: #98433e; border-color: #ecc9c4; }
.button.small { min-height: 34px; font-size: 13px; padding: 5px 8px; }
.page { max-width: 1620px; padding: 27px clamp(18px,3vw,40px) 35px; margin: auto; }
.page-heading, .section-heading { display: flex; align-items: end; justify-content: space-between; gap: 12px; }
.page-heading > .button { margin-bottom: 3px; }
.eyebrow { display: flex; gap: 6px; align-items: center; font-size: 13px; color: #146d7d; font-weight: 700; letter-spacing: .08em; }
.eyebrow span { background: #19859c; }
h1, h2, h3, p { margin: 0; }
h1 { margin: 3px 0 5px; font-size: clamp(32px,4vw,44px); line-height: 1.24; overflow-wrap: anywhere; }
h2 { font-size: 20px; line-height: 1.35; }
h3 { font-size: 16px; }
p { color: var(--muted); line-height: 1.55; }
.section-heading p { font-size: 13px; margin-top: 2px; }
.stats { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; margin: 20px 0 24px; }
.stat { background: white; border: 1px solid var(--line); border-radius: 12px; display: flex; align-items: center; gap: 11px; padding: 11px 14px; min-width: 0; }
.stat-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 9px; background: #e4f3f8; color: #08758c; flex: 0 0 auto; }
.stat.warning .stat-icon { background: #fff0d8; color: #9a5a05; }
.stat label { display: block; color: var(--muted); font-size: 13px; }
.stat strong { display: block; font-size: 22px; line-height: 1.12; font-variant-numeric: tabular-nums; }
.stat small { font-size: 12px; color: var(--muted); font-weight: 400; }
.section-tag, .pill { display: inline-flex; color: #3c5e76; font-size: 13px; font-weight: 600; border-radius: 20px; background: #e4edf3; padding: 4px 9px; white-space: nowrap; }
.racks { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; margin: 9px 0 15px; }
.rack-card {
  position: relative; text-align: left; padding: 11px 12px 9px; border: 1px solid #cedce5; border-radius: 11px;
  background: linear-gradient(145deg,#fcfeff,#f0f6f9); color: #21394d; min-width: 0; transition: border-color .18s, box-shadow .18s;
}
.rack-card:hover { border-color: #789caf; }
.rack-card[aria-pressed=true] { border-color: #258ca0; box-shadow: inset 0 0 0 1px #258ca0,0 3px 10px #13607419; background: #f0fcfe; }
.rack-card-title { display: flex; justify-content: space-between; gap: 4px; align-items: center; font-weight: 750; font-size: 15px; }
.rack-card-title b { font: 700 12px Consolas, monospace; color: #406476; }
.rack-face { display: grid; grid-template-columns: minmax(0,1fr) auto; margin: 8px 0 5px; }
.rack-art {
  display: grid; grid-template-columns: repeat(4,1fr); grid-template-rows: repeat(4,7px); gap: 3px;
  align-content: center; padding: 4px; border: 1px solid #aebecb; border-radius: 5px 0 0 5px;
  background: linear-gradient(185deg,#eff5f9,#a5bbc9); box-shadow: inset 0 1px 0 white;
}
.rack-art span { border: 1px solid #a5b6c2; border-radius: 2px; background: #ebf1f5; box-shadow: inset 0 1px 2px #16263a22; }
.rack-art .filled { background: #70c6d6; border-color: #4a9cae; }
.rack-art .empty { background: #e3eff2; border-color: #87aebb; box-shadow: none; }
.rack-map { display: grid; grid-template-columns: auto minmax(0,1fr) auto; }
.rack-door, .rack-back { writing-mode: vertical-rl; white-space: nowrap; font-size: 12px; line-height: 1.2; }
.rack-door { display: flex; align-items: center; justify-content: center; gap: 4px; padding: 3px;
  border-left: 2px solid #147586; border-radius: 0 4px 4px 0; background: #e1f3f5; color: #075767; font-weight: 700; }
.rack-door i { width: 6px; height: 12px; flex: 0 0 auto; border: 1.5px solid currentColor; border-left: 0; border-radius: 0 3px 3px 0; }
.rack-back { display: flex; align-items: center; justify-content: center; padding: 3px; color: var(--muted); }
.rack-card-foot { display:flex; justify-content: space-between; align-items: center; color: #4e697b; font-size: 12px; }
.rack-chosen { color: #006b7e; font-weight: 650; }
.work-grid { display: grid; grid-template-columns: minmax(205px,.93fr) minmax(350px,1.82fr) minmax(209px,.92fr); align-items: start; gap: 13px; }
.panel { border: 1px solid var(--line); border-radius: 13px; padding: 15px; background: white; min-width: 0; min-height: 302px; }
.panel-head { display: flex; gap: 6px; align-items: start; justify-content: space-between; margin-bottom: 12px; }
.panel-head h2 { font-size: 17px; overflow-wrap: anywhere; }
.panel-head p { margin-top: 2px; font-size: 13px; }
.box-intake { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; padding: 9px 10px;
  margin: 0 0 12px; border: 1px solid #c0e2e8; border-radius: 8px; background: #eef9fa; }
.box-intake span { color: var(--muted); font-size: 13px; }
.guide-link, .guide-sheet a { color: #086679; text-decoration: underline; text-underline-offset: .2em; }
.guide-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 5px; font-weight: 600; }
.guide-page { display: block; padding: clamp(10px, 3vw, 28px); }
.guide-sheet { max-width: 44rem; margin: 0 auto; padding: clamp(16px, 4vw, 38px); border-radius: 14px; background: white; overflow-wrap: anywhere; }
.guide-sheet h1 { font-size: clamp(28px, 5vw, 40px); margin: 14px 0 6px; }
.guide-sheet h2 { font-size: 1.35rem; margin: 0 0 .65rem; }
.guide-sheet section { margin: 1.75rem 0; scroll-margin-top: 1rem; }
.guide-sheet p, .guide-sheet li, .guide-sheet dd, .guide-sheet td { line-height: 1.65; color: #334e60; }
.guide-sheet p { margin: .45rem 0; }
.guide-sheet ol { padding-left: 1.5rem; }
.guide-sheet li + li { margin-top: .5rem; }
.guide-links, .guide-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 0 16px; }
.guide-links { justify-content: space-between; }
.guide-links a, .guide-nav a { display: inline-flex; align-items: center; min-height: 44px; }
.guide-nav { border-block: 1px solid var(--line); margin: 1.1rem 0; }
.guide-sheet dl { margin: .85rem 0; }
.guide-sheet dt { margin: .85rem 0 .15rem; font-weight: 700; color: #075f70; }
.guide-sheet dd { margin: 0; }
.guide-sheet table { width: 100%; table-layout: fixed; border-collapse: collapse; margin: .8rem 0; }
.guide-sheet caption { text-align: left; color: var(--muted); padding-bottom: .3rem; }
.guide-sheet th, .guide-sheet td { text-align: left; vertical-align: top; padding: .55rem; border-bottom: 1px solid var(--line); }
.guide-sheet thead { background: var(--accent-light); }
.guide-sheet thead th:first-child { width: 37%; }
.well-scroll { max-width: 100%; overflow: auto; padding: 4px; margin: -4px; }
.well-grid {
  --well-cut: 16px;
  position: relative; isolation: isolate; display: grid; gap: 4px; align-items: center;
  min-width: calc(33px + var(--cols) * 25px); padding: 8px;
}
.well-grid::before, .well-grid::after { content: ""; position: absolute; z-index: -1; pointer-events: none; }
.well-grid::before {
  inset: 0; border-radius: 0 7px 7px 7px;
  background: linear-gradient(135deg, #00728a 0 15px, #d4e3eb 15px);
  clip-path: polygon(var(--well-cut) 0, 100% 0, 100% 100%, 0 100%, 0 var(--well-cut));
}
.well-grid::after {
  inset: 1px; border-radius: 0 6px 6px 6px; background: #fcfdfe;
  clip-path: polygon(calc(var(--well-cut) - 1px) 0, 100% 0, 100% 100%, 0 100%, 0 calc(var(--well-cut) - 1px));
}
.axis { text-align: center; font: 600 12px Consolas,monospace; color: #4d687c; }
.well {
  width: 100%; padding: 0; display: grid; place-items: center; aspect-ratio: 1; max-height: 38px;
  border: 1px dashed #bdcbd5; border-radius: 50%; background: #f4f7fa; color: #657b8d; position: relative;
}
.well:hover { border-color: #007f97; background: #e9f8fb; }
.well.empty { border-style: solid; background: #fff; }
.well.confirmed { border: 1px solid #73baab; background: #dbf4ed; color: #08624f; }
.well.review { border: 1px solid #ebc87c; background: #fff1d4; color: #874e00; }
.well[aria-pressed=true], .slot[aria-pressed=true] { outline: 2px solid #09718a; outline-offset: 1px; }
.well svg { width: min(70%,17px); height: auto; aspect-ratio: 1; }
.well.empty svg { width: min(60%,14px); }
.slots { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 4px; padding: 4px; border-radius: 5px 0 0 5px; background: #e9f0f5; border: 1px solid #d9e5eb; }
.slot { padding: 5px 1px; min-height: 39px; border: 1px dashed #aabeca; border-radius: 6px; background: #f5f8fb; color: #4d667a; font: 650 12px Consolas,monospace; }
.slot.registered { border: 1px solid #8cbbca; background: #dff1f6; color: #075f75; }
.slot-owner { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  margin-top: 3px; font: 600 10px/1.2 "Microsoft YaHei UI",sans-serif; }
.slot.empty { border: 1px solid #9bbbc4; background: #fff; }
.slot:hover { border-color: #147d94; }
.legend { display: flex; flex-wrap: wrap; gap: 5px 10px; margin-top: 10px; color: var(--muted); font-size: 12px; }
.legend > span { display: flex; gap: 4px; align-items: center; }
.swatch { display: inline-block; width: 10px; height: 10px; border: 1px dashed #a5b9c8; border-radius: 3px; background: #f4f7fa; }
.swatch.registered { background: #dff1f6; border: 1px solid #8cbbca; }
.swatch.empty { background: white; border: 1px solid #9bbbc4; }
.swatch.confirmed { background: #dbf4ed; border: 1px solid #73baab; }
.swatch.review { background: #fff1d4; border: 1px solid #ebc87c; }
.panel-actions { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 0; }
.placeholder { display: grid; align-content: center; justify-items: center; gap: 8px; min-height: 200px; text-align: center; }
.placeholder > span { border: 1px solid #d3e8ef; background: #edf8fb; color: #26809a; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; }
.placeholder > span svg { width: 24px; height: 24px; }
.placeholder p { font-size: 14px; max-width: 34ch; }
.placeholder .panel-actions { justify-content: center; margin-top: 3px; }
.tube-head { background: linear-gradient(120deg,#eaf7fa,#f4fafc); border: 1px solid #dceaf0; border-radius: 10px; padding: 10px; margin: 0 0 11px; overflow-wrap: anywhere; }
.tube-head h3 { margin: 4px 0 1px; }
.tube-head code, code { color: #345872; font: 650 12px Consolas,monospace; overflow-wrap: anywhere; }
.pill.confirmed { color: #075e4c; background: #dff3ec; }
.pill.review { color: #814b00; background: #fff0d4; }
.tube-fields { display: grid; grid-template-columns: auto minmax(0,1fr); gap: 7px 10px; margin: 0; font-size: 13px; }
.tube-fields dt { color: var(--muted); }
.tube-fields dd { margin: 0; text-align: right; overflow-wrap: anywhere; white-space: pre-wrap; }
.demo-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 7px 14px; color: #6e530d; background: #fff5dc; border: 1px solid #eed99d; border-radius: 9px; padding: 8px 12px; margin-bottom: 12px; font-size: 13px; }
.demo-banner #refresh-inventory { margin-inline-start: auto; }
.logout-button { background: none; color: #a7e7f4; border: 0; padding: 0; text-decoration: underline; }
.signin-page { min-height: 100vh; display: grid; align-items: center; justify-items: center; padding: 20px; }
.signin-panel { width: min(100%, 390px); padding: 23px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.signin-panel h1 { font-size: 32px; }
.signin-form { display: grid; gap: 12px; margin: 18px 0 12px; }
.signin-message:not(:target) { display: none; }
.signin-success { color: #075f53; background: #e6f5ef; padding: 8px 10px; border-radius: 7px; font-size: 14px; }
.signin-option { margin: 11px 0; border: 1px solid var(--line); border-radius: 8px; padding: 9px 11px; }
.signin-option summary { cursor: pointer; color: var(--accent); font-weight: 650; }
.signin-option .signin-form { margin: 12px 0 4px; }
dialog { border: 1px solid #c6d8e3; border-radius: 16px; background: #fff; color: #172d43; width: min(660px, calc(100vw - 26px)); max-height: calc(100dvh - 32px); padding: 0; box-shadow: 0 20px 70px #10233750; overflow: auto; }
dialog::backdrop { background: #11253786; backdrop-filter: blur(2px); }
.dialog-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 17px; border-bottom: 1px solid var(--line); background: #f7fafc; position: sticky; top: 0; z-index: 1; }
#dialog-body { padding: 17px; }
.form-grid { display: grid; gap: 11px; grid-template-columns: repeat(2,minmax(0,1fr)); }
.form-grid > .full { grid-column: 1/-1; }
.field { display: flex; flex-direction: column; gap: 5px; color: #345165; font-size: 14px; font-weight: 650; min-width: 0; }
.field input, .field select, .field textarea { min-width: 0; width: 100%; border: 1px solid #bfcfd9; border-radius: 8px; padding: 8px 9px; background: white; color: #172e42; font-weight: 400; }
.field textarea { resize: vertical; min-height: 64px; }
.dialog-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; margin-top: 15px; gap: 7px; }
.dialog-intro, .hint { color: var(--muted); font-size: 14px; margin: 0 0 11px; }
.batch-setup { min-width: 0; border: 0; padding: 0; margin: 0; }
.batch-common { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px 12px; }
[data-draft] { margin:8px 0 14px; }
[data-paste] { font:14px Consolas,monospace; white-space:pre; overflow:auto; min-height:66px; }
[data-back] { margin-bottom:8px; }
.paper-preview,.paper-source { display:block; max-width:100%; margin:8px auto; }
.paper-preview { max-height:180px; }
.paper-review details { margin:8px 0; color:var(--accent); }
.paper-review ul { padding-inline-start:22px; margin:6px 0 12px; }
.paper-confirm { display:flex; align-items:center; gap:8px; padding:8px 0; font-weight:600; }
.batch-buttons .field { flex:1; }
.batch-setup .hint { margin: 8px 0 10px; }
.batch-range { margin: 12px 0; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }
.batch-range summary { font-size: 14px; font-weight: 650; cursor: pointer; color: var(--accent); }
.batch-range-fields { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; margin-top: 10px; }
.batch-instruction { color: #154f68; font-weight: 650; }
.batch-photo-frame { position: relative; width: 100%; overflow: hidden; border-radius: 9px; line-height: 0; }
.batch-photo-frame img { width: 100%; height: auto; display: block; cursor: crosshair; }
.batch-markers { inset: 0; position: absolute; pointer-events: none; }
.batch-markers span {
  position: absolute; transform: translate(-50%, -50%); display: grid; place-items: center;
  padding: 3px; min-width: 24px; height: 24px; border: 1.5px solid #fff; border-radius: 18px;
  color: #fff; background: #066e86; font: bold 10px Consolas, monospace;
}
.batch-buttons { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 9px 0; }
.batch-review { scroll-margin-top: 60px; }
.batch-progress { margin: 0 0 10px; font-size: 14px; color: #154f68; font-weight: 650; }
.batch-entries { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; margin-bottom: 12px; }
.batch-entry {
  display: grid; grid-template-columns: auto minmax(0,1fr); align-items: center; column-gap: 8px;
  min-width: 0; padding: 5px 8px; border: 1px solid var(--line); border-radius: 8px;
}
.batch-entry strong { color: #1a5066; font: 700 14px Consolas, monospace; }
.batch-entry:has(img) { grid-template-columns: 66px minmax(0,1fr); }
.batch-entry img { grid-row: span 2; display: block; width: 66px; height: 66px; border-radius: 4px; }
.batch-entry input { min-width: 0; width: 100%; padding: 6px; border: 1px solid #aac0cb; border-radius: 6px; font-size: 16px; }
.batch-save { position: sticky; bottom: 0; padding-block: 8px; background: #fff; }
@media (max-width: 530px) {
  .batch-entries { grid-template-columns: minmax(0,1fr); }
  .batch-range-fields { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
.hint { margin: 7px 0 0; }
.form-error, .photo-error { color: #9f2b24; background: #fff0ee; border-radius: 6px; padding: 6px 9px; font-size: 14px; margin: 8px 0 0; }
.scan-form { display: grid; gap: 10px; }
.scan-row { display: flex; align-items: end; gap: 8px; flex-wrap: wrap; }
.scan-row .field { flex: 1; min-width: 115px; }
.scan-row .language { flex: 0 1 auto; }
.ocr-result { display: grid; gap: 5px; }
.ocr-lines { display: flex; flex-wrap: wrap; gap: 6px; }
.file-input { max-width: 100%; }
.results { display: grid; gap: 6px; margin-top: 12px; }
.result-row { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; overflow-wrap: anywhere; }
.result-row p { font-size: 13px; }
.result-row strong { font-size: 14px; }
.team-list { display: grid; gap: 7px; margin-top: 9px; }
.team-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 5px; }
.team-code { color: #17485f; background: #eaf6f8; border-radius: 8px; padding: 10px; margin-top: 8px; }
.team-code .field { margin: 7px 0; }
.data-section { border-top: 1px solid var(--line); padding: 12px 0 0; margin-top: 12px; }
.data-section p { font-size: 14px; margin: 3px 0 7px; }
.photo-scan { display: grid; gap: 8px; margin-top: 10px; }
.photo-preview { max-width: 100%; width: auto; max-height: 160px; object-fit: contain; justify-self: start; border: 1px solid var(--line); border-radius: 8px; }
.photo-review { background: #f5fafb; border: 1px solid var(--line); border-radius: 9px; padding: 10px; }
.scan-transcript { white-space: pre-wrap; overflow-wrap: anywhere; }
.photo-scan [role=status]:empty { display: none; }
.audit { display: grid; gap: 7px; list-style: none; padding: 0; margin: 0; }
.audit li { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; overflow-wrap: anywhere; }
.audit li span { font-size: 13px; color: var(--muted); }
.audit p { font-size: 14px; }
.notice { position: fixed; left: 50%; bottom: 20px; z-index: 100; transform: translateX(-50%); max-width: min(94vw,560px); padding: 10px 15px; border-radius: 9px; background: #123c4a; color: #fff; box-shadow: 0 6px 20px #16324b33; font-size: 14px; }
.notice.error { background: #8d352f; }
@media (max-width: 1170px) {
  .work-grid { grid-template-columns: minmax(185px,.85fr) minmax(320px,1.7fr); }
  .details-panel { grid-column: 1/-1; min-height: 0; }
  .details-panel .placeholder { min-height: 122px; }
}
@media (max-width: 790px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; padding: 11px 14px; gap: 6px; overflow: visible; }
  .sidebar nav { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; }
  .sidebar nav > .nav-label:not(.shelf-label) { display: none; }
  .brand strong { font-size: 17px; }
  .brand-mark { width: 35px; height: 35px; }
  .nav-item { width: auto; margin: 0; min-height: 36px; gap: 5px; padding: 5px 7px; }
  .nav-item svg { width: 16px; height: 16px; }
  .shelf-label { margin: 0 3px; }
  #shelves { display: flex; gap: 4px; flex-wrap: wrap; }
  .side-bottom { display: flex; align-items: center; gap: 16px; padding: 5px 2px 0; flex-wrap: wrap; }
  .demo-link { margin: 0; }
  .topbar { padding: 8px 14px; min-height: 54px; }
  .page { padding: 16px 14px 28px; }
}
@media (max-width: 560px) {
  .topbar { flex-wrap: wrap; gap: 7px; }
  .crumb { flex-basis: 100%; }
  .global-search { flex: 1; }
  .stats { gap: 5px; margin: 13px 0 15px; }
  .stat { padding: 7px 6px; gap: 5px; }
  .stat-icon { width: 25px; height: 25px; }
  .stat-icon svg { width: 15px; height: 15px; }
  .stat label { font-size: 11px; }
  .stat strong { font-size: 17px; }
  .racks { gap: 5px; }
  .rack-card { padding: 7px 5px 5px; }
  .rack-card-title { font-size: 12px; }
  .rack-card-title b { display: none; }
  .rack-card-foot { font-size: 10px; gap: 2px; }
  .rack-art { gap: 2px; padding: 3px; }
  .rack-card .rack-door { font-size: 11px; }
  .rack-card .rack-door i { display: none; }
  .rack-chosen { display: none; }
  .work-grid { grid-template-columns: minmax(0,1fr); gap: 9px; }
  .panel { padding: 10px; min-height: 0; }
  .placeholder { min-height: 140px; }
  .well-grid { min-width: calc(33px + var(--cols) * 24px); gap: 3px; }
}
