/* City Cell ordering tool, AM Phone. Mobile first, RTL. */
:root {
  --accent: #12595E;
  --accent-soft: #DDECED;
  --ink: #14262A;
  --rule: #D8E0E1;
  --bg: #FFFFFF;
  --muted: #5B6B6E;
  --promo: #F58720;

  --page: #F3F6F6;
  --accent-deep: #0C4246;
  --field: #F6F9F9;
  --danger: #B42318;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(20, 38, 42, .05), 0 4px 14px rgba(20, 38, 42, .05);
  --tap: 44px;
  --font: "Assistant", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink);
  background: var(--page);
  -webkit-tap-highlight-color: transparent;
  overflow-wrap: anywhere;
}
body.has-bar { padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
body.no-scroll { overflow: hidden; }
img { display: block; max-width: 100%; }
/* html2canvas finds the text baseline with a 1x1 inline image it adds to <body>; the block rule above pushed every PDF text line ~7px down */
img[width="1"][height="1"] { display: inline; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--promo); outline-offset: 2px; }
.ltr { direction: ltr; unicode-bidi: isolate; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: 16px; }
.wrap--narrow { max-width: 820px; }

/* ---------- boot / errors ---------- */
.boot { min-height: 70vh; display: grid; place-content: center; justify-items: center; gap: 14px; color: var(--muted); text-align: center; padding: 24px; }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--accent-soft); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- buttons ---------- */
.btn {
  min-height: var(--tap);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 700; font-size: 16px; line-height: 1.15;
  text-decoration: none;
  transition: background-color .15s, transform .08s;
  user-select: none;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-deep); }
.btn-soft { background: var(--accent-soft); color: var(--accent-deep); }
.btn-soft:hover { background: #cfe3e4; }
.btn-line { background: var(--bg); color: var(--ink); border-color: var(--rule); }
.btn-line:hover { border-color: #b9c6c8; }
.btn-danger-line { background: var(--bg); color: var(--danger); border-color: #EBC5C1; }
.btn-danger { background: var(--danger); color: #fff; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.btn .ico { width: 20px; height: 20px; flex: none; }
.btn-2l { flex-direction: column; gap: 0; padding-block: 6px; }
.btn-2l small { font-weight: 600; font-size: 12.5px; opacity: .85; }

.icon-btn {
  width: var(--tap); height: var(--tap); flex: none;
  display: inline-grid; place-items: center;
  border: 0; border-radius: 12px; background: transparent; color: inherit;
}
.icon-btn:hover { background: rgba(20, 38, 42, .06); }
.icon-btn svg { width: 24px; height: 24px; }

/* ---------- top bars ---------- */
.hero { background: var(--accent); color: #fff; padding: 18px 0 6px; }
.hero-row { display: flex; align-items: center; gap: 12px; }
.hero-logo { width: 42px; height: 42px; border-radius: 12px; background: rgba(255, 255, 255, .14); display: grid; place-items: center; flex: none; }
.hero-logo svg { width: 26px; height: 26px; }
.hero h1 { font-size: 23px; font-weight: 800; line-height: 1.15; }
.hero p { font-size: 14px; opacity: .85; margin-top: 2px; }
.search-band { position: sticky; top: 0; z-index: 30; background: var(--accent); padding: 10px 0 14px; }
.search {
  position: relative; display: flex; align-items: center;
  background: var(--bg); border-radius: 14px; height: 50px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .12);
}
.search svg { position: absolute; inset-inline-start: 14px; width: 20px; height: 20px; color: var(--muted); pointer-events: none; }
.search input {
  flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; outline: none;
  padding-inline: 44px 8px; font-size: 16px; color: var(--ink);
  -webkit-appearance: none; appearance: none;
}
.search input::placeholder { color: #8a989b; }
.search input::-webkit-search-cancel-button { display: none; }
.search .icon-btn { color: var(--muted); margin-inline-end: 3px; }

.topbar { position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .97); border-bottom: 1px solid var(--rule); backdrop-filter: saturate(1.4) blur(8px); -webkit-backdrop-filter: saturate(1.4) blur(8px); }
.topbar-row { display: flex; align-items: center; gap: 10px; min-height: 60px; padding-block: 8px; }
.topbar-row .icon-btn { margin-inline-start: -8px; color: var(--accent); }
.topbar-title { min-width: 0; flex: 1; }
.topbar-title h1 { font-size: 19px; font-weight: 800; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-title p { font-size: 13.5px; color: var(--muted); }

/* ---------- category chip ---------- */
.chip {
  --c: var(--accent);
  flex: none; display: inline-grid; place-items: center;
  min-width: 36px; height: 36px; padding: 0 6px; border-radius: 10px;
  background: var(--c); color: #fff;
  font-weight: 800; font-size: 15px; line-height: 1;
  font-variant-numeric: tabular-nums;
}
.chip.light { color: var(--ink); }
.chip.sm { min-width: 28px; height: 28px; border-radius: 8px; font-size: 13px; }

/* ---------- home ---------- */
.sec-title { font-size: 15px; font-weight: 700; color: var(--muted); margin: 18px 2px 10px; }
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.tile {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  min-height: 112px; padding: 12px; border-radius: var(--radius);
  background: var(--bg); border: 1px solid var(--rule); box-shadow: var(--shadow);
  color: var(--ink); text-decoration: none;
}
.tile:hover { border-color: #b9c6c8; }
.tile:active { transform: scale(.99); }
.tile-name { font-weight: 700; font-size: 15.5px; line-height: 1.25; }
.tile-count { margin-top: auto; font-size: 13px; color: var(--muted); }
.tile-badge {
  position: absolute; top: 12px; inset-inline-end: 12px;
  font-size: 12px; font-weight: 700; color: var(--accent-deep);
  background: var(--accent-soft); border-radius: 999px; padding: 2px 8px;
}
.tile.empty .tile-count { color: #8a989b; }
.results-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin: 16px 2px 10px; }
.results-head h2 { font-size: 16px; font-weight: 700; }
.results-head span { font-size: 13.5px; color: var(--muted); }
.empty-state { text-align: center; color: var(--muted); padding: 36px 16px; background: var(--bg); border: 1px dashed var(--rule); border-radius: var(--radius); }
.empty-state strong { display: block; color: var(--ink); font-size: 17px; margin-bottom: 4px; }
.empty-state .btn { margin-top: 14px; }
.foot-note { text-align: center; font-size: 12.5px; color: #8a989b; padding: 22px 0 8px; }

/* ---------- product cards ---------- */
.filter { margin: 14px 0 2px; }
.filter .search { box-shadow: none; border: 1px solid var(--rule); height: 46px; }
.brand-head { display: flex; align-items: center; gap: 10px; margin: 20px 2px 10px; font-weight: 800; font-size: 14px; color: var(--muted); }
.brand-head::after { content: ""; flex: 1; height: 1px; background: var(--rule); }
.cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 12px; }
.brand-head + .cards { margin-top: 0; }
.card {
  background: var(--bg); border: 1px solid var(--rule); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 14px; min-width: 0;
  display: flex; flex-direction: column;
}
.card.flash { animation: flash 1s ease-out; }
@keyframes flash { 0% { box-shadow: 0 0 0 3px var(--accent); } 100% { box-shadow: var(--shadow); } }
.card-head { display: flex; gap: 12px; align-items: flex-start; }
.thumb {
  position: relative; flex: none; width: 104px; height: 104px; padding: 6px;
  border-radius: var(--radius-sm); border: 1px solid #E7EDEE; background: var(--field);
  display: grid; place-items: center; overflow: hidden;
}
.thumb img { width: 100%; height: 100%; object-fit: contain; }
.thumb-more {
  position: absolute; bottom: 5px; inset-inline-start: 5px;
  font-size: 12px; font-weight: 800; color: #fff; background: rgba(20, 38, 42, .72);
  border-radius: 999px; padding: 1px 7px; direction: ltr;
}
.noimg { color: #9aa8aa; display: grid; place-items: center; }
.noimg svg { width: 34px; height: 34px; }
.card-info { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.eyebrow { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: none; }
.catpill { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 2px; }
.catpill i { width: 10px; height: 10px; border-radius: 3px; background: var(--c); }
.model { font-size: 18px; font-weight: 800; line-height: 1.2; }
.name { font-size: 15px; line-height: 1.35; }
.barcode { font-size: 13px; color: var(--muted); margin-top: 3px; }
.barcode .ltr { font-variant-numeric: tabular-nums; }
.barcodes { font-size: 12.5px; line-height: 1.4; }
.desc { list-style: none; margin: 12px 0 0; padding: 0; font-size: 14.5px; color: #2d4246; }
.desc li { position: relative; padding-inline-start: 14px; margin-top: 3px; }
.desc li::before { content: ""; position: absolute; inset-inline-start: 2px; top: .62em; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); opacity: .55; }
.desc li.extra { display: none; }
.desc.open li.extra { display: list-item; }
.more { align-self: flex-start; border: 0; background: none; color: var(--accent); font-weight: 700; font-size: 14.5px; min-height: 36px; padding: 4px 0; margin-top: 2px; }

/* add form */
.form { margin-top: 12px; padding-top: 12px; border-top: 1px solid #E7EDEE; display: flex; flex-direction: column; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.flabel { font-size: 13.5px; font-weight: 700; color: var(--muted); }
.flabel small { font-weight: 600; font-size: 12.5px; opacity: .85; }
.flabel b { color: var(--danger); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.opt {
  min-height: var(--tap); max-width: 100%;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: 999px;
  border: 1.5px solid var(--rule); background: var(--bg); color: var(--ink);
  font-size: 15px; font-weight: 600; line-height: 1.2; text-align: start;
}
.opt:hover { border-color: #b9c6c8; }
.opt[aria-checked="true"], .opt[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-deep); box-shadow: inset 0 0 0 1px var(--accent); }
.opt small { display: block; font-size: 12px; font-weight: 600; color: var(--muted); }
.opt.sm { min-height: 40px; padding: 4px 12px; font-size: 14px; }
.opt.more-opt { border-style: dashed; color: var(--accent); }
.dot { width: 16px; height: 16px; border-radius: 50%; flex: none; background: var(--d); border: 1px solid rgba(20, 38, 42, .25); }
.dot.clear { background: repeating-conic-gradient(#e3e8e9 0 25%, #fff 0 50%) 50% / 8px 8px; }
.field.invalid .chips .opt { border-color: #e6a29b; }
.photos { display: flex; flex-wrap: wrap; gap: 8px; }
.ph { width: 56px; height: 64px; padding: 4px; border-radius: 12px; border: 1.5px solid var(--rule); background: var(--field); display: grid; place-items: center; }
.ph img { width: 100%; height: 100%; object-fit: contain; }
.ph[aria-checked="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 3px var(--accent-soft); background: #fff; }
.inp {
  width: 100%; min-width: 0; height: var(--tap);
  border: 1px solid var(--rule); border-radius: 12px; background: var(--field);
  padding: 0 12px; font-size: 16px; outline: none; color: var(--ink);
}
.inp:focus { border-color: var(--accent); background: #fff; box-shadow: 0 0 0 3px var(--accent-soft); }
.inp::placeholder { color: #8a989b; }
textarea.inp { height: auto; min-height: 76px; padding: 10px 12px; resize: vertical; line-height: 1.4; }
.addrow { display: flex; gap: 10px; align-items: stretch; }
.addrow .btn { flex: 1; min-width: 0; min-height: 48px; }
.stepper { display: inline-flex; align-items: stretch; flex: none; border: 1px solid var(--rule); border-radius: 12px; background: var(--bg); overflow: hidden; height: 48px; }
.stepper button { width: 44px; border: 0; background: var(--field); color: var(--accent); font-size: 22px; font-weight: 700; line-height: 1; display: grid; place-items: center; }
.stepper button:hover { background: var(--accent-soft); }
.stepper input { width: 52px; border: 0; border-inline: 1px solid var(--rule); text-align: center; font-weight: 800; font-size: 17px; outline: none; background: var(--bg); font-variant-numeric: tabular-nums; padding: 0; }
.stepper input:focus { background: #fff; box-shadow: inset 0 0 0 2px var(--accent-soft); }
.stepper.sm { height: 44px; }
.stepper.sm button { width: 42px; font-size: 20px; }
.stepper.sm input { width: 46px; font-size: 16px; }
.ferr { color: var(--danger); font-size: 14px; font-weight: 700; margin-top: -4px; }

/* lines inside a card */
.clines { margin-top: 12px; border-radius: 12px; background: #F1F7F7; border: 1px solid #D5E6E7; padding: 4px 12px; }
.clines-title { font-size: 13px; font-weight: 800; color: var(--accent-deep); padding: 8px 0 2px; }
.cline { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 9px 0; border-top: 1px solid #DCE9EA; }
.clines-title + .cline { border-top: 0; }
.cline-text { flex: 1 1 150px; min-width: 0; font-size: 14.5px; line-height: 1.35; display: flex; align-items: center; gap: 8px; }
.cline-text img { width: 34px; height: 40px; object-fit: contain; border-radius: 6px; background: #fff; flex: none; }
.cline-text .muted { color: var(--muted); }
.cline-ctl { display: flex; align-items: center; gap: 6px; margin-inline-start: auto; }
.x-btn { width: var(--tap); height: var(--tap); border: 0; border-radius: 12px; background: transparent; color: var(--muted); display: grid; place-items: center; }
.x-btn:hover { background: rgba(180, 35, 24, .08); color: var(--danger); }
.x-btn svg { width: 20px; height: 20px; }

/* ---------- bottom bars ---------- */
#bar { position: fixed; inset-inline: 0; bottom: 0; z-index: 40; }
.bar { background: rgba(255, 255, 255, .98); border-top: 1px solid var(--rule); box-shadow: 0 -6px 20px rgba(20, 38, 42, .08); padding: 10px 0 calc(10px + env(safe-area-inset-bottom)); }
.bar-row { display: flex; align-items: center; gap: 12px; }
.bar-sum { flex: 1; min-width: 0; font-size: 15px; line-height: 1.25; }
.bar-sum b { font-size: 17px; font-variant-numeric: tabular-nums; }
.bar-sum small { display: block; color: var(--muted); font-size: 12.5px; }
.bar .btn { min-height: 50px; padding-inline: 22px; }
.bar .btn svg { width: 18px; height: 18px; }
.bar-actions { display: flex; gap: 10px; width: 100%; }
.bar-actions .btn { flex: 1; min-width: 0; }
body.typing .bar { display: none; }

/* ---------- order page ---------- */
.panel { background: var(--bg); border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin-top: 14px; }
.panel h2 { font-size: 16px; font-weight: 800; margin-bottom: 10px; }
.fields { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.fields label { display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; font-weight: 700; color: var(--muted); }
.fields input[type="date"] { -webkit-appearance: none; appearance: none; text-align: start; display: flex; align-items: center; }
.fields input[type="date"]::-webkit-date-and-time-value { text-align: start; }
.totals { display: flex; gap: 10px; margin-top: 14px; }
.total-box { flex: 1; background: var(--bg); border: 1px solid var(--rule); border-radius: var(--radius); padding: 10px 14px; }
.total-box b { display: block; font-size: 24px; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; color: var(--accent-deep); }
.total-box span { font-size: 13.5px; color: var(--muted); }
.group { margin-top: 18px; }
.group-title { display: flex; align-items: center; gap: 10px; font-size: 16.5px; font-weight: 800; margin: 0 2px 10px; }
.group-title span.count { margin-inline-start: auto; font-size: 13px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.olines { background: var(--bg); border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.oline { padding: 12px 14px; display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 4px 12px; align-items: start; }
.oline + .oline { border-top: 1px solid #E7EDEE; }
.oline .thumb { width: 64px; height: 64px; padding: 4px; grid-row: span 2; }
.oline-main { min-width: 0; }
.oline-main .model { font-size: 16.5px; }
.oline-main .name { font-size: 14px; color: #2d4246; }
.oline-main .barcode { font-size: 12.5px; margin-top: 2px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.tag { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; background: var(--field); border: 1px solid #E2E9EA; border-radius: 8px; padding: 2px 8px; }
.tag span { font-weight: 600; color: var(--muted); }
.tag .dot { width: 12px; height: 12px; }
.oline .x-btn { margin-top: -6px; margin-inline-end: -8px; }
.oline-edit { grid-column: 2 / -1; display: flex; gap: 10px; align-items: center; margin-top: 6px; }
.oline-edit .inp { flex: 1; height: 44px; }
.danger-zone { margin: 26px 0 6px; padding: 16px; border: 1px dashed #E5C1BC; border-radius: var(--radius); display: flex; align-items: center; gap: 14px; flex-wrap: wrap; background: #FFFBFA; }
.danger-zone p { flex: 1 1 200px; font-size: 13.5px; color: var(--muted); }

/* ---------- lightbox ---------- */
.lb { position: fixed; inset: 0; z-index: 100; background: rgba(8, 20, 22, .94); color: #fff; display: flex; flex-direction: column; }
.lb-top { display: flex; align-items: center; gap: 10px; padding: calc(8px + env(safe-area-inset-top)) 12px 8px; }
.lb-title { flex: 1; min-width: 0; font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb-count { font-size: 14px; opacity: .8; font-variant-numeric: tabular-nums; }
.lb .icon-btn { color: #fff; }
.lb .icon-btn:hover { background: rgba(255, 255, 255, .12); }
.lb-track { flex: 1; min-height: 0; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior: contain; }
.lb-track::-webkit-scrollbar { display: none; }
.lb-slide { flex: 0 0 100%; scroll-snap-align: center; display: grid; place-items: center; padding: 8px 16px 16px; margin: 0; }
.lb-slide img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 12px; background: #fff; padding: 10px; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .16); color: #fff; display: none; place-items: center; }
.lb-nav svg { width: 24px; height: 24px; }
.lb-nav.prev { inset-inline-start: 18px; }
.lb-nav.next { inset-inline-end: 18px; }
@media (hover: hover) and (pointer: fine) { .lb-nav { display: grid; } }
.lb-foot { text-align: center; font-size: 13.5px; opacity: .8; padding: 0 16px calc(14px + env(safe-area-inset-bottom)); }

/* ---------- modal, toast, busy ---------- */
.modal-back { position: fixed; inset: 0; z-index: 110; background: rgba(8, 20, 22, .45); display: grid; align-items: end; justify-items: center; padding: 16px; }
.modal { width: 100%; max-width: 420px; background: var(--bg); border-radius: 20px; padding: 20px; box-shadow: 0 20px 60px rgba(0, 0, 0, .25); margin-bottom: env(safe-area-inset-bottom); }
.modal h2 { font-size: 19px; font-weight: 800; }
.modal p { color: var(--muted); margin-top: 6px; }
.modal-actions { display: flex; gap: 10px; margin-top: 18px; }
.modal-actions .btn { flex: 1; min-height: 48px; }
#toast { position: fixed; z-index: 120; inset-inline: 16px; bottom: calc(96px + env(safe-area-inset-bottom)); display: flex; justify-content: center; pointer-events: none; }
#toast div { background: var(--ink); color: #fff; font-weight: 700; font-size: 15px; padding: 10px 16px; border-radius: 12px; box-shadow: 0 8px 24px rgba(0, 0, 0, .2); max-width: 520px; text-align: center; animation: toast .2s ease-out; }
#toast div.err { background: var(--danger); }
@keyframes toast { from { transform: translateY(8px); opacity: 0; } }
.busy { position: fixed; inset: 0; z-index: 1000; background: rgba(255, 255, 255, .97); display: grid; place-content: center; justify-items: center; gap: 14px; text-align: center; padding: 24px; }
.busy strong { font-size: 18px; }
.busy p { color: var(--muted); font-size: 14.5px; }
.share-ready { display: flex; flex-direction: column; gap: 10px; align-items: stretch; width: min(320px, 100%); }

/* ---------- PDF sheet (rendered off-screen by html2canvas; px only, no letter-spacing) ---------- */
.pdf-host { position: fixed; top: 0; left: 0; width: 794px; height: 1123px; z-index: 900; pointer-events: none; }
.sheet {
  position: absolute; top: 0; left: 0; width: 794px; height: 1123px; overflow: hidden;
  background: #fff; color: #14262A; direction: rtl; text-align: right;
  font-family: "Assistant", Arial, sans-serif; font-size: 12px; line-height: 1.35;
  letter-spacing: 0; word-spacing: 0; overflow-wrap: anywhere;
  padding: 34px 36px 0;
}
.sheet-main { height: 1023px; overflow: hidden; }
.sh-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; padding-bottom: 14px; border-bottom: 3px solid #12595E; margin-bottom: 14px; }
.sh-title { font-size: 27px; font-weight: 800; color: #12595E; line-height: 1.1; }
.sh-sub { font-size: 13px; color: #5B6B6E; margin-top: 6px; }
.sh-meta { text-align: right; font-size: 13px; line-height: 1.6; min-width: 230px; background: #F3F8F8; border: 1px solid #D8E0E1; border-radius: 10px; padding: 8px 14px; }
.sh-meta div { display: flex; justify-content: space-between; gap: 16px; }
.sh-meta span { color: #5B6B6E; }
.sh-meta b { font-weight: 800; }
.sh-cont { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 8px; border-bottom: 2px solid #12595E; margin-bottom: 12px; font-size: 13px; color: #5B6B6E; }
.sh-cont b { font-size: 17px; color: #12595E; font-weight: 800; }
.pt { width: 100%; border-collapse: collapse; table-layout: fixed; }
.pt th { background: #12595E; color: #fff; font-weight: 700; font-size: 11.5px; text-align: right; padding: 7px 5px; vertical-align: middle; line-height: 1.2; }
.pt td { padding: 6px 5px; border-bottom: 1px solid #D8E0E1; vertical-align: middle; text-align: right; }
.pt tr.it:nth-child(even) td { background: #F8FBFB; }
.pt .c-n { text-align: center; color: #5B6B6E; }
.pt th.c-n, .pt th.c-q { text-align: center; }
.pt th { white-space: nowrap; }
.pt th.c-q { font-size: 11.5px; font-weight: 700; }
.pt .c-q { text-align: center; font-size: 16px; font-weight: 800; }
.pt .c-m { font-weight: 800; font-size: 12.5px; }
.pt .c-b { font-size: 11.5px; }
.pt .c-b span { direction: ltr; unicode-bidi: isolate; }
.pt .c-x { font-size: 11.5px; color: #2d4246; }
.pt .nm { font-weight: 600; }
.pt .br { display: block; font-size: 10.5px; color: #5B6B6E; margin-top: 1px; }
.pimg { width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; margin: 0 auto; }
.pimg img { display: block; max-width: 46px; max-height: 46px; width: auto; height: auto; }
.pt tr.grp td { font-weight: 800; font-size: 12.5px; padding: 6px 8px; border-bottom: 0; }
.pt tr.sum td { border-bottom: 0; border-top: 2px solid #12595E; font-weight: 800; font-size: 13px; padding-top: 8px; }
.sh-notes { margin-top: 16px; border: 1px solid #D8E0E1; border-radius: 10px; padding: 10px 14px; }
.sh-notes h3 { font-size: 13px; font-weight: 800; color: #12595E; margin: 0 0 4px; }
.sh-notes p { white-space: pre-wrap; font-size: 12.5px; }
.sheet-foot { position: absolute; left: 36px; right: 36px; bottom: 24px; display: flex; justify-content: space-between; font-size: 10.5px; color: #5B6B6E; border-top: 1px solid #D8E0E1; padding-top: 7px; }

/* ---------- wider screens ---------- */
@media (min-width: 640px) {
  .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fields label.full { grid-column: 1 / -1; }
  .modal-back { align-items: center; }
}
@media (min-width: 900px) {
  .hero { padding-top: 26px; }
  .hero h1 { font-size: 28px; }
  .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
  .cards { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px; }
  .bar-row { justify-content: flex-end; }
  .bar-sum { flex: 0 1 auto; text-align: start; margin-inline-end: 8px; }
  .bar-actions { width: auto; }
  .bar-actions .btn { flex: 0 0 auto; min-width: 200px; }
  .oline { grid-template-columns: 72px minmax(0, 1fr) auto; }
  .oline .thumb { width: 72px; height: 72px; }
}
@media (min-width: 1100px) {
  .tiles { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition: none !important; }
}
