:root {
  --bg: #f4f7f6;
  --surface: #ffffff;
  --surface-2: #eef3f1;
  --text: #17221f;
  --muted: #697975;
  --line: #dde6e3;
  --primary: #176b57;
  --primary-2: #0e5342;
  --primary-soft: #dff1eb;
  --danger: #bd3f4a;
  --danger-soft: #fbe7e9;
  --warning: #a86813;
  --warning-soft: #fff1d7;
  --shadow: 0 10px 32px rgba(21, 51, 43, .08);
  --radius: 18px;
  --nav-height: 76px;
  --tg-safe-top: 0px;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; max-width: 100%; overflow-x: hidden; background: var(--bg); color: var(--text); }
body { overscroll-behavior: none; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
.app-icon { display: inline-block; width: 1em; height: 1em; background: currentColor; -webkit-mask: var(--icon) center / contain no-repeat; mask: var(--icon) center / contain no-repeat; }
.shell { min-height: 100vh; padding-bottom: calc(var(--nav-height) + env(safe-area-inset-bottom)); }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; padding: calc(14px + max(env(safe-area-inset-top), var(--tg-safe-top))) 18px 12px; background: rgba(244,247,246,.88); backdrop-filter: blur(18px); }
.topbar,.content,.fab { transition: opacity .18s ease, transform .18s ease; }
.view-leaving { opacity: 0; transform: translateY(5px); }
.view-enter { opacity: 0; transform: translateY(5px); }
.eyebrow { color: var(--muted); font-size: 12px; font-weight: 600; letter-spacing: .02em; }
.topbar h1 { margin: 3px 0 0; font-size: 22px; letter-spacing: -.025em; }
.avatar { display: grid; place-items: center; width: 42px; height: 42px; border: 0; border-radius: 50%; background: var(--primary); color: white; font-size: 22px; }
.content { width: min(100%, 960px); margin: 0 auto; padding: 6px 16px calc(var(--nav-height) + env(safe-area-inset-bottom) + 36px); }
.hero { color: white; border-radius: 24px; padding: 22px; background: linear-gradient(145deg,#176b57,#0d493b); box-shadow: 0 14px 32px rgba(23,107,87,.22); overflow: hidden; position: relative; }
.hero:after { content: ''; position: absolute; width: 180px; height: 180px; border: 32px solid rgba(255,255,255,.08); border-radius: 50%; right: -72px; top: -78px; }
.hero small { opacity: .75; }
.hero h2 { margin: 8px 0 4px; font-size: 30px; letter-spacing: -.04em; }
.hero p { margin: 0; opacity: .85; font-size: 14px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin: 24px 2px 12px; }
.section-head h2 { margin: 0; font-size: 18px; letter-spacing: -.02em; }
.section-head button { border: 0; background: transparent; color: var(--primary); font-weight: 650; padding: 6px; }
.quick-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; }
.quick { min-height: 105px; padding: 16px; border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); text-align: left; box-shadow: 0 4px 15px rgba(21,51,43,.035); }
.quick:active { transform: scale(.98); }
.quick-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--primary-soft); color: var(--primary); font-size: 20px; margin-bottom: 14px; }
.quick strong { display: block; font-size: 15px; }
.quick span { color: var(--muted); font-size: 12px; }
.stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 9px; margin-top: 14px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 15px; padding: 14px 12px; }
.stat strong { display: block; font-size: 22px; letter-spacing: -.04em; }
.stat span { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
.section-count { display: grid; place-items: center; min-width: 25px; height: 25px; padding: 0 7px; border-radius: 999px; background: var(--danger-soft); color: var(--danger); font-size: 12px; font-weight: 800; }
.attention-list { overflow: hidden; }
.attention-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 72px; padding: 13px 14px; border: 0; border-bottom: 1px solid var(--line); background: var(--surface); text-align: left; }
.attention-row:last-child { border-bottom: 0; }
.attention-icon { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 12px; background: var(--primary-soft); color: var(--primary); font-size: 18px; font-weight: 850; }
.attention-row.danger .attention-icon { background: var(--danger-soft); color: var(--danger); }
.attention-row.warning .attention-icon { background: var(--warning-soft); color: var(--warning); }
.attention-row.info .attention-icon { background: #e5efff; color: #3465a4; }
.attention-row strong,.home-primary strong,.location-summary strong { display: block; font-size: 14px; }
.chevron { flex: none; color: #9aa8a4; font-size: 24px; line-height: 1; }
.empty.compact { padding: 24px 18px; }
.home-primary-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.home-primary { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; min-height: 118px; padding: 15px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); text-align: left; box-shadow: 0 4px 15px rgba(21,51,43,.035); }
.home-primary:active { transform: scale(.98); }
.home-primary-icon { display: grid; place-items: center; width: 36px; height: 36px; margin-bottom: 13px; border-radius: 12px; background: var(--primary-soft); color: var(--primary); font-size: 19px; font-weight: 800; }
.home-primary small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.35; }
.location-summary-list { display: grid; gap: 9px; }
.location-summary { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 68px; padding: 12px 13px; text-align: left; }
.location-symbol { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 12px; background: var(--surface-2); color: var(--primary); font-size: 14px; font-weight: 800; }
.location-alert,.location-ok { display: grid; place-items: center; min-width: 26px; height: 26px; padding: 0 7px; border-radius: 999px; font-size: 12px; font-weight: 800; }
.location-alert { background: var(--danger-soft); color: var(--danger); }
.location-ok { background: var(--primary-soft); color: var(--primary); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 4px 15px rgba(21,51,43,.03); }
.list { overflow: hidden; }
.list-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 66px; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.list-row:last-child { border-bottom: 0; }
.thumb { flex: none; display: grid; place-items: center; width: 44px; height: 44px; overflow: hidden; border-radius: 12px; background: var(--surface-2); color: var(--primary); font-size: 20px; font-weight: 750; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.grow { flex: 1; min-width: 0; }
.grow strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.meta { color: var(--muted); font-size: 12px; margin-top: 4px; }
.qty { font-size: 14px; font-weight: 700; white-space: nowrap; }
.qty.low { color: var(--danger); }
.stock-qty { flex: none; min-width: 46px; text-align: right; white-space: nowrap; }
.stock-qty b { display: block; font-size: 17px; }
.stock-qty small { display: block; margin-top: 2px; color: var(--muted); font-size: 10px; font-weight: 550; }
.stock-qty.low b { color: var(--danger); }
.badge { display: inline-flex; align-items: center; border-radius: 999px; padding: 5px 9px; font-size: 11px; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.badge.draft { background: var(--warning-soft); color: var(--warning); }
.badge.approved { background: #e5efff; color: #3465a4; }
.badge.ordered { background: #eee8ff; color: #6951a8; }
.badge.prepared { background: #e5efff; color: #3465a4; }
.badge.partial { background: var(--warning-soft); color: var(--warning); }
.badge.received { background: var(--primary-soft); color: var(--primary); }
.badge.cancelled { background: var(--danger-soft); color: var(--danger); }
.search { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 0 13px; margin-bottom: 12px; }
.search input { width: 100%; height: 46px; border: 0; outline: 0; background: transparent; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px 14px; padding: 0 16px; }
.subcategory-chips { margin-top: -6px; padding-bottom: 2px; }
.subcategory-chips .chip { font-size: 12px; padding: 7px 11px; }
.chip { flex: none; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 8px 13px; color: var(--muted); font-size: 13px; }
.chip.active { background: var(--primary); border-color: var(--primary); color: white; }
.inventory-content { padding-top: 2px; }
.location-tabs { display: flex; gap: 7px; overflow-x: auto; margin: 0 -16px 12px; padding: 0 16px 2px; scrollbar-width: none; }
.location-chip { flex: none; min-height: 38px; padding: 8px 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 650; }
.location-chip.active { border-color: var(--primary); background: var(--primary); color: #fff; }
.inventory-search { margin-bottom: 14px; }
.search-clear { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border: 0; border-radius: 9px; background: var(--surface-2); color: var(--muted); font-size: 18px; }
.inventory-breadcrumbs { display: flex; align-items: center; gap: 7px; min-width: 0; margin: 2px 1px 15px; overflow: hidden; color: var(--muted); font-size: 12px; }
.inventory-breadcrumbs button { flex: none; padding: 0; border: 0; background: transparent; color: var(--primary); font-weight: 650; }
.inventory-breadcrumbs b { overflow: hidden; color: var(--text); text-overflow: ellipsis; white-space: nowrap; }
.inventory-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 4px 2px 12px; }
.inventory-heading h2 { margin: 3px 0 0; font-size: 20px; letter-spacing: -.025em; }
.inventory-heading > span { display: grid; place-items: center; min-width: 28px; height: 28px; padding: 0 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 12px; font-weight: 750; }
.category-grid { display: grid; gap: 10px; }
.category-card { display: flex; align-items: center; gap: 13px; width: 100%; min-height: 78px; padding: 14px; text-align: left; }
.category-card:active { transform: scale(.985); }
.category-symbol { display: grid; place-items: center; flex: none; width: 48px; height: 48px; border-radius: 15px; background: linear-gradient(145deg,var(--primary-soft),#edf6f3); color: var(--primary); font-size: 18px; font-weight: 850; }
.category-card strong { display: block; font-size: 15px; }
.category-low { display: grid; place-items: center; min-width: 27px; height: 27px; padding: 0 8px; border-radius: 999px; background: var(--danger-soft); color: var(--danger); font-size: 12px; font-weight: 800; }
.inventory-materials { margin-top: 2px; }
.fab { position: fixed; right: 18px; bottom: calc(var(--nav-height) + env(safe-area-inset-bottom) + 28px); z-index: 15; width: 56px; height: 56px; border-radius: 18px; border: 0; background: var(--primary); color: #fff; font-size: 28px; box-shadow: 0 10px 24px rgba(23,107,87,.3); }
.bottom-nav { position: fixed; z-index: 30; left: 50%; bottom: calc(10px + env(safe-area-inset-bottom)); width: min(calc(100% - 24px),720px); height: var(--nav-height); padding: 7px 6px 6px; display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); background: #101412; border: 1px solid rgba(255,255,255,.06); border-radius: 22px; box-shadow: 0 13px 34px rgba(13,25,21,.24); transform: translateX(-50%); overflow: visible; }
.nav-btn,.nav-action { position: relative; z-index: 1; min-width: 0; border: 0; background: transparent; color: #7c8582; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; padding: 3px 1px; font-size: 10px; transition: color .2s ease,transform .2s ease; }
.nav-icon-wrap { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 9px; transition: background .2s ease,color .2s ease,transform .2s ease; }
.nav-icon { width: 22px; height: 22px; }
.nav-label { overflow: hidden; max-width: 100%; text-overflow: ellipsis; white-space: nowrap; }
.nav-btn.active { color: #fff; font-weight: 750; }
.nav-btn.active .nav-icon-wrap { color: #fff; background: rgba(255,255,255,.11); transform: translateY(-1px); }
.nav-action { color: #d5ddda; justify-content: flex-end; }
.nav-action-circle { display: grid; place-items: center; width: 56px; height: 56px; margin-top: -30px; border: 6px solid var(--bg); border-radius: 50%; background: var(--primary); color: #fff; box-shadow: 0 8px 22px rgba(23,107,87,.34); font-size: 29px; font-weight: 350; line-height: 1; transition: transform .2s ease,background .2s ease; }
.nav-action:active .nav-action-circle { transform: scale(.94); }
.nav-action.active .nav-action-circle { background: #0d493b; }
.nav-action .nav-label { margin-top: -1px; font-weight: 700; }
.empty { padding: 32px 18px; text-align: center; color: var(--muted); }
.empty b { display: block; color: var(--text); margin-bottom: 6px; }
.modal-backdrop { position: fixed; z-index: 100; inset: 0; background: rgba(16,31,27,.42); display: flex; align-items: flex-end; animation: fade .18s ease; }
.modal { width: 100%; max-width: 100%; min-width: 0; max-height: 92vh; overflow-x: hidden; overflow-y: auto; background: var(--bg); border-radius: 26px 26px 0 0; padding: 12px 18px calc(24px + env(safe-area-inset-bottom)); animation: rise .22s ease; }
.modal-handle { width: 38px; height: 4px; border-radius: 4px; background: #c6cfcc; margin: 0 auto 14px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.modal-head h2 { margin: 0; font-size: 21px; }
.action-menu-intro { margin: -7px 0 15px; color: var(--muted); font-size: 13px; }
.action-menu-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.action-menu-item { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; min-height: 112px; padding: 14px; border: 1px solid var(--line); border-radius: 17px; background: var(--surface); text-align: left; }
.action-menu-item:active { transform: scale(.98); }
.action-menu-item b,.action-menu-item small { display: block; }
.action-menu-item b { margin-top: 11px; font-size: 14px; }
.action-menu-item small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.action-menu-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; background: var(--primary-soft); color: var(--primary); font-size: 19px; font-weight: 800; }
.action-menu-icon.danger { background: var(--danger-soft); color: var(--danger); }
.action-menu-icon.warning { background: var(--warning-soft); color: var(--warning); }
.action-menu-icon.success { background: var(--primary-soft); color: var(--primary); }
.action-history-link { display: flex; align-items: center; gap: 12px; width: 100%; margin-top: 12px; padding: 13px 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); color: var(--primary); text-align: left; }
.action-history-link > .app-icon { flex: none; width: 24px; height: 24px; }
.action-history-link span:nth-child(2) { flex: 1; min-width: 0; }
.action-history-link b,.action-history-link small { display: block; }
.action-history-link b { color: var(--text); font-size: 14px; }
.action-history-link small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.icon-btn { border: 0; background: var(--surface-2); width: 36px; height: 36px; border-radius: 11px; }
.form-grid { display: grid; gap: 14px; }
#check-items { width: 100%; min-width: 0; overflow: hidden; }
#check-items .list-row { min-width: 0; overflow: hidden; }
#check-items [data-check-material] { flex: 0 0 70px; width: 70px; min-width: 0; max-width: 70px; padding: 8px 5px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); text-align: center; }
.field label { display: block; margin: 0 0 7px 2px; color: var(--muted); font-size: 12px; font-weight: 650; }
.field input,.field select,.field textarea { width: 100%; border: 1px solid var(--line); outline: 0; background: var(--surface); border-radius: 13px; padding: 12px 13px; color: var(--text); }
.field textarea { min-height: 80px; resize: vertical; }
.field input:focus,.field select:focus,.field textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.two { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 10px; }
.btn { width: 100%; min-height: 48px; border: 0; border-radius: 14px; padding: 12px 16px; font-weight: 700; }
.btn.primary { background: var(--primary); color: white; }
.btn.secondary { background: var(--surface-2); color: var(--primary); }
.btn.danger { background: var(--danger-soft); color: var(--danger); }
.btn:disabled { opacity: .5; }
.actions { display: grid; gap: 10px; margin-top: 18px; }
.photo-pick { min-height: 130px; border: 1.5px dashed #b7c8c3; border-radius: 16px; background: var(--surface); display: grid; place-items: center; text-align: center; color: var(--muted); overflow: hidden; }
.photo-pick img { width: 100%; max-height: 220px; object-fit: contain; }
.detail-photo { width: 100%; max-height: 260px; object-fit: contain; background: white; border-radius: 18px; margin-bottom: 14px; }
.stock-grid { display: grid; gap: 8px; margin-top: 14px; }
.stock-line { display: flex; justify-content: space-between; padding: 12px 13px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
.stock-line span,.stock-line small { display: block; min-width: 0; }
.stock-line small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.segmented { display: grid; grid-template-columns: repeat(2,1fr); gap: 6px; padding: 5px; background: var(--surface-2); border-radius: 14px; margin-bottom: 16px; }
.segment { border: 0; border-radius: 10px; padding: 9px; background: transparent; color: var(--muted); }
.segment.active { background: white; color: var(--text); box-shadow: 0 2px 8px rgba(21,51,43,.08); font-weight: 700; }
.request-item { padding: 14px; border-bottom: 1px solid var(--line); }
.request-item:last-child { border-bottom: 0; }
.request-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.request-heading { display: flex; align-items: center; gap: 10px; min-width: 0; }
.request-heading > span { min-width: 0; }
.request-heading .meta { display: block; }
.request-heading input,.receipt-row input { flex: 0 0 auto; width: 19px; height: 19px; accent-color: var(--primary); }
.request-items { margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line); }
.request-material { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; font-size: 13px; }
.request-material span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.request-material b,.request-material small { display: block; }
.request-material small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.request-material > strong { flex: none; white-space: nowrap; }
.order-builder { position: sticky; z-index: 12; top: calc(78px + var(--tg-safe-top)); display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.94); box-shadow: var(--shadow); backdrop-filter: blur(15px); }
.order-builder span { min-width: 0; }
.order-builder b,.order-builder small { display: block; }
.order-builder small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.order-builder .btn { flex: 0 0 auto; width: auto; min-height: 42px; }
.text-danger { margin-top: 10px; padding: 5px 0; border: 0; background: transparent; color: var(--danger); font-size: 12px; }
.supplier-order .request-title { align-items: flex-start; }
.order-material { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; padding: 10px 0; border-bottom: 1px solid var(--line); }
.order-material:last-child { border-bottom: 0; }
.order-material b,.order-material small { display: block; }
.order-material small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.order-material > strong { flex: none; white-space: nowrap; font-size: 13px; }
.order-preview,.receipt-picker { min-width: 0; overflow: hidden; padding: 0 13px; }
.receipt-row { justify-content: flex-start; }
.order-actions { grid-template-columns: repeat(2,minmax(0,1fr)); }
.receipt-history { margin-top: 10px; padding: 10px; border-radius: 12px; background: var(--surface-2); font-size: 11px; }
.receipt-history > b { display: block; margin-bottom: 5px; }
.receipt-history > div { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 3px 0; color: var(--muted); }
.receipt-history button { flex: none; border: 0; background: transparent; color: var(--primary); font-weight: 700; }
.event-log { margin-top: 10px; color: var(--muted); font-size: 11px; }
.event-log summary { color: var(--primary); cursor: pointer; font-weight: 700; }
.event-log div { padding: 4px 0 0 3px; }
.receipt-document { max-height: 70vh; margin: 0; }
.receipt-allocation { min-width: 0; padding: 12px 0; border-bottom: 1px solid var(--line); }
.receipt-allocation:last-child { border-bottom: 0; }
.setting-toggle { display: flex; align-items: center; gap: 10px; min-width: 0; }
.setting-toggle input { flex: 0 0 auto; width: 19px; height: 19px; accent-color: var(--primary); }
.setting-toggle span,.setting-toggle b,.setting-toggle small { display: block; min-width: 0; }
.setting-toggle small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.receipt-fields { margin: 10px 0 0 29px; }
.location-settings-list { display: grid; gap: 10px; }
.location-setting { display: grid; gap: 12px; padding: 14px; }
.direct-toggle { padding-top: 10px; border-top: 1px dashed var(--line); }
.muted-row:not(:has(input:checked)) { opacity: .7; }
.request-form { min-width: 0; }
.request-picker { width: 100%; min-width: 0; overflow: hidden; }
.request-row { min-width: 0; overflow: hidden; gap: 9px; padding: 10px 11px; }
.request-row input[type="checkbox"] { flex: 0 0 auto; width: 18px; height: 18px; accent-color: var(--primary); }
.request-row [data-qty] { flex: 0 0 68px; width: 68px; min-width: 0; max-width: 68px; padding: 8px 4px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); text-align: center; }
.request-submit-bar { position: sticky; z-index: 5; bottom: 0; margin-top: 2px; padding: 10px 0 2px; background: linear-gradient(to bottom,rgba(244,247,246,0),var(--bg) 22%); }
.pagination { display: flex; align-items: center; justify-content: center; gap: 7px; margin: 18px 0 0; }
.page-btn { min-width: 38px; height: 38px; padding: 0 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); color: var(--muted); font-weight: 700; }
.page-btn.active { color: white; background: var(--primary); border-color: var(--primary); }
.page-btn:disabled { opacity: .35; }
.page-btn.arrow { font-size: 21px; line-height: 1; }
.page-gap { color: var(--muted); }
.page-caption { margin-top: 8px; color: var(--muted); font-size: 11px; text-align: center; }
.more-grid { display: grid; gap: 10px; }
.profile-card { display: flex; align-items: center; gap: 13px; width: 100%; margin-bottom: 16px; padding: 15px 16px; border-color: var(--line); text-align: left; color: var(--text); }
.profile-card strong { display: block; margin: 5px 0 1px; font-size: 18px; }
.profile-avatar { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 15px; background: var(--primary); color: white; font-size: 19px; font-weight: 800; }
.profile-arrow { flex: none; color: var(--muted); font-size: 28px; line-height: 1; }
.more-btn { display: flex; align-items: center; gap: 13px; width: 100%; min-height: 62px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); padding: 12px 14px; text-align: left; }
.more-btn i { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--primary-soft); font-style: normal; }
.more-btn i .app-icon { width: 21px; height: 21px; color: var(--primary); }
.more-btn b { display: block; }
.more-btn small { color: var(--muted); }
.analytics-period { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 9px; margin-bottom: 14px; }
.analytics-period .btn { grid-column: 1 / -1; }
.finance-stats { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
.finance-stat { min-width: 0; padding: 13px; border: 1px solid var(--line); border-radius: 15px; background: var(--surface); }
.finance-stat span,.finance-stat b { display: block; }
.finance-stat span { color: var(--muted); font-size: 11px; }
.finance-stat b { margin-top: 5px; overflow-wrap: anywhere; font-size: 17px; }
.analytics-section { margin-top: 20px; }
.analytics-section h3 { margin: 0 2px 10px; font-size: 16px; }
.analytics-section > .card { padding: 13px; }
.chart-list { display: grid; gap: 13px; }
.chart-row > div { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; }
.chart-row > div span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chart-row > div b { flex: none; }
.chart-track { display: block; height: 8px; margin-top: 6px; overflow: hidden; border-radius: 999px; background: var(--surface-2); }
.chart-track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,var(--primary),#43a589); }
.room-chart small { display: block; margin-top: 5px; color: var(--muted); font-size: 10px; }
.top-materials { padding: 7px 13px !important; }
.toast { position: fixed; z-index: 200; left: 50%; bottom: calc(var(--nav-height) + env(safe-area-inset-bottom) + 34px); max-width: calc(100% - 32px); transform: translate(-50%,20px); padding: 12px 16px; border-radius: 13px; background: #17221f; color: white; opacity: 0; pointer-events: none; transition: .2s; box-shadow: var(--shadow); font-size: 13px; }
.toast.show { opacity: 1; transform: translate(-50%,0); }
.toast.error { background: var(--danger); }
.splash { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 9px; color: var(--muted); }
.splash strong { color: var(--text); font-size: 20px; }
.splash span { font-size: 13px; }
.brand-mark { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 22px; background: var(--primary); color: white; font-size: 28px; font-weight: 800; box-shadow: 0 12px 30px rgba(23,107,87,.25); }
.error-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; text-align: center; }
.error-page .card { max-width: 420px; padding: 28px; }
.error-page h1 { font-size: 22px; }
.error-page p { color: var(--muted); line-height: 1.5; }
.loading { opacity: .65; pointer-events: none; }
@keyframes fade { from { opacity: 0; } }
@keyframes rise { from { transform: translateY(30px); } }
@media (min-width: 720px) {
  .quick-grid { grid-template-columns: repeat(4,1fr); }
  .modal-backdrop { align-items: center; justify-content: center; padding: 24px; }
  .modal { max-width: 620px; border-radius: 26px; max-height: 88vh; }
  .fab { right: calc((100vw - 960px)/2 + 24px); }
}
