:root {
  --ink: #241a14;
  --muted: #7b7068;
  --line: #e9e2dc;
  --paper: #fffdf9;
  --canvas: #f5f2ed;
  --brand: #b54a2b;
  --brand-dark: #8e351e;
  --espresso: #281910;
  --green: #397461;
  --green-soft: #e7f1ed;
  --orange-soft: #f8ece6;
  --yellow-soft: #fbf3dd;
  --danger: #b83d3d;
  --shadow: 0 16px 40px rgba(55, 38, 26, .08);
  --radius: 18px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; min-height: 100%; background: var(--canvas); color: var(--ink); font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
button, input { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible { outline: 3px solid rgba(181, 74, 43, .22); outline-offset: 2px; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 104px minmax(0, 1fr); }
.sidebar { position: fixed; z-index: 20; inset: 0 auto 0 0; width: 104px; padding: 22px 12px 14px; background: var(--espresso); color: white; display: flex; flex-direction: column; align-items: stretch; }
.brand { border: 0; background: none; color: #f9efe4; display: flex; flex-direction: column; align-items: center; gap: 7px; cursor: pointer; padding: 0 4px 26px; }
.brand-mark { width: 42px; height: 42px; display: grid; place-items: center; color: #dc6c46; }
.brand-mark svg { width: 36px; height: 36px; }
.brand strong { display: block; font-size: 11px; letter-spacing: .18em; line-height: 1.1; }
.brand small { display: block; margin-top: 2px; color: #a99c92; font-size: 7px; letter-spacing: .24em; }
.nav-list { display: grid; gap: 8px; }
.nav-item { position: relative; min-height: 66px; border: 0; border-radius: 15px; color: #b9aca2; background: transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; cursor: pointer; font-size: 10px; font-weight: 650; }
.nav-item:hover { color: white; background: rgba(255,255,255,.05); }
.nav-item.active { color: #fff; background: var(--brand); box-shadow: 0 9px 22px rgba(181, 74, 43, .25); }
.nav-icon { font-size: 23px; line-height: 1; font-family: Georgia, serif; }
.nav-item em { position: absolute; top: 7px; right: 10px; min-width: 18px; height: 18px; border-radius: 9px; padding: 0 4px; display: grid; place-items: center; background: #f7d56d; color: #34271c; font-style: normal; font-size: 9px; }
.sidebar-foot { margin-top: auto; display: grid; gap: 10px; }
.sync-card { min-height: 58px; border-radius: 14px; padding: 9px 7px; background: rgba(255,255,255,.05); text-align: center; display: grid; place-items: center; }
.sync-card > div, .sync-card > button { display: none; }
.status-dot { width: 9px; height: 9px; border-radius: 50%; background: #63c69f; box-shadow: 0 0 0 4px rgba(99,198,159,.1); }
.sync-card.offline .status-dot { background: #f1b84b; box-shadow: 0 0 0 4px rgba(241,184,75,.1); }
.profile-card { border: 0; background: none; color: white; padding: 4px 0; display: flex; justify-content: center; cursor: pointer; }
.profile-card > span:not(.avatar) { display: none; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: #f4ded0; color: var(--brand-dark); font-weight: 800; font-size: 12px; }

.main-area { grid-column: 2; min-width: 0; }
.topbar { height: 86px; padding: 0 28px; background: rgba(255,253,249,.95); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 10; backdrop-filter: blur(14px); }
.eyebrow { margin: 0 0 2px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.topbar h1 { margin: 0; font-family: Georgia, serif; font-size: 26px; font-weight: 700; }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.store-state { display: flex; align-items: center; gap: 10px; padding-right: 16px; border-right: 1px solid var(--line); }
.store-state > span { width: 8px; height: 8px; border-radius: 50%; background: #5ea987; }
.store-state small, .store-state strong { display: block; }
.store-state small { font-size: 9px; color: var(--muted); letter-spacing: .1em; }
.store-state strong { margin-top: 2px; font-size: 12px; }
.icon-button { position: relative; width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 12px; background: white; cursor: pointer; font-size: 21px; }
.icon-button i { position: absolute; top: -3px; right: -3px; width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: white; font-style: normal; font-size: 8px; border: 2px solid white; }
.shift-pill { border: 1px solid #cfe0d8; background: var(--green-soft); border-radius: 12px; padding: 7px 12px; text-align: left; cursor: pointer; }
.shift-pill span, .shift-pill strong { display: block; }
.shift-pill span { color: var(--green); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.shift-pill strong { margin-top: 2px; font-size: 12px; font-variant-numeric: tabular-nums; }
.mobile-menu { display: none; }

.view { display: none; min-height: calc(100vh - 86px); padding: 24px 28px 32px; }
.view.active { display: block; }
#view-pos { padding: 0; }
.pos-layout { display: grid; grid-template-columns: minmax(0, 1fr) 382px; min-height: calc(100vh - 86px); }
.catalog-panel { padding: 22px 24px 34px; min-width: 0; }
.cart-panel { background: var(--paper); border-left: 1px solid var(--line); display: flex; flex-direction: column; min-height: calc(100vh - 86px); position: sticky; top: 86px; max-height: calc(100vh - 86px); }
.search-row { display: grid; grid-template-columns: 1fr 48px; gap: 10px; }
.search-box { height: 48px; border: 1px solid var(--line); border-radius: 14px; background: white; display: flex; align-items: center; gap: 10px; padding: 0 15px; }
.search-box span { color: var(--muted); font-size: 22px; }
.search-box input { width: 100%; border: 0; outline: 0; background: transparent; font-size: 13px; }
.scan-button { border: 1px solid var(--line); border-radius: 14px; background: white; cursor: pointer; font-size: 21px; }
.category-tabs { display: flex; gap: 8px; overflow: auto; padding: 18px 0 5px; scrollbar-width: none; }
.category-tabs::-webkit-scrollbar { display: none; }
.category-tab { white-space: nowrap; border: 1px solid var(--line); background: white; border-radius: 999px; padding: 9px 15px; cursor: pointer; color: var(--muted); font-size: 12px; font-weight: 700; }
.category-tab.active { background: var(--espresso); border-color: var(--espresso); color: white; }
.catalog-meta { margin: 17px 2px 14px; display: flex; align-items: flex-end; justify-content: space-between; }
.catalog-meta h2 { margin: 0; font-family: Georgia, serif; font-size: 20px; }
.catalog-meta p { margin: 4px 0 0; color: var(--muted); font-size: 11px; }
.catalog-meta button, .date-button { border: 1px solid var(--line); background: white; border-radius: 10px; padding: 8px 11px; font-size: 11px; color: var(--muted); cursor: pointer; }
.catalog-actions { display: flex; gap: 8px; }
.product-grid { display: grid; grid-template-columns: repeat(4, minmax(145px, 1fr)); gap: 12px; }
.product-card { position: relative; min-height: 175px; border: 1px solid var(--line); border-radius: 17px; padding: 10px; background: var(--paper); text-align: left; cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; overflow: hidden; }
.product-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #d8ccc3; }
.product-card:active { transform: translateY(0); }
.product-art { height: 92px; border-radius: 12px; display: grid; place-items: center; overflow: hidden; position: relative; }
.product-art::before { content: ""; position: absolute; width: 76px; height: 76px; border-radius: 50%; background: rgba(255,255,255,.36); }
.cup { position: relative; z-index: 1; width: 45px; height: 62px; border-radius: 5px 5px 14px 14px; background: linear-gradient(to bottom, #f8f3eb 0 15%, var(--drink) 16% 100%); box-shadow: 0 8px 18px rgba(61,39,24,.15); border: 2px solid rgba(255,255,255,.65); }
.cup::before { content: ""; position: absolute; top: -4px; left: -4px; width: 49px; height: 7px; border-radius: 5px; background: #e9e0d5; }
.cup::after { content: "RS"; position: absolute; inset: 23px 0 auto; color: rgba(255,255,255,.86); font-size: 8px; font-weight: 900; letter-spacing: .12em; text-align: center; }
.product-card h3 { margin: 10px 0 3px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.product-card p { margin: 0; color: var(--brand); font-size: 12px; font-weight: 800; }
.product-badge { position: absolute; top: 17px; left: 17px; z-index: 2; border-radius: 6px; padding: 4px 6px; background: var(--espresso); color: white; font-size: 7px; font-weight: 800; letter-spacing: .08em; }
.product-card.sold-out { opacity: .55; cursor: not-allowed; }
.product-card.sold-out::after { content: "HABIS"; position: absolute; top: 48px; right: -24px; width: 106px; padding: 5px; background: #8b8179; color: white; text-align: center; transform: rotate(45deg); font-size: 8px; font-weight: 800; }

.cart-head { padding: 22px 20px 14px; display: flex; align-items: center; justify-content: space-between; }
.order-label { color: var(--muted); font-size: 9px; letter-spacing: .13em; font-weight: 800; }
.cart-head h2 { margin: 2px 0 0; font-family: Georgia, serif; font-size: 22px; }
.more-button { width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 10px; background: white; cursor: pointer; }
.customer-trigger { margin: 0 20px; border: 1px dashed #d8c8bd; background: #fcf7f3; border-radius: 13px; padding: 10px 12px; display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 10px; text-align: left; cursor: pointer; }
.customer-icon { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #f0dacf; color: var(--brand); }
.customer-trigger strong, .customer-trigger small { display: block; }
.customer-trigger strong { font-size: 11px; }
.customer-trigger small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.customer-trigger:disabled, .promo-row:disabled { opacity: .5; cursor: not-allowed; }
.cart-items { flex: 1; min-height: 100px; overflow: auto; padding: 14px 20px; }
.empty-cart { height: 100%; min-height: 230px; display: grid; place-items: center; text-align: center; color: var(--muted); }
.empty-cart-visual { width: 82px; height: 82px; margin: 0 auto 12px; border-radius: 50%; background: #f3ede7; display: grid; place-items: center; font-size: 33px; color: #b8aaa0; }
.empty-cart h3 { margin: 0; color: var(--ink); font-size: 14px; }
.empty-cart p { margin: 5px 0 0; max-width: 210px; font-size: 10px; line-height: 1.5; }
.cart-item { padding: 13px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 48px 1fr auto; gap: 10px; }
.cart-thumb { width: 48px; height: 48px; border-radius: 11px; display: grid; place-items: center; font-size: 21px; }
.cart-item h4 { margin: 1px 0 3px; font-size: 11px; }
.cart-item p { margin: 0; color: var(--muted); font-size: 9px; line-height: 1.4; }
.cart-item-price { font-size: 11px; font-weight: 800; text-align: right; }
.qty-control { margin-top: 7px; display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.qty-control button { width: 25px; height: 23px; border: 0; background: white; cursor: pointer; }
.qty-control span { width: 24px; text-align: center; font-size: 10px; font-weight: 800; }
.cart-summary { border-top: 1px solid var(--line); padding: 10px 20px 16px; background: var(--paper); }
.promo-row { width: 100%; margin-bottom: 9px; padding: 10px 0; border: 0; border-bottom: 1px solid var(--line); background: none; display: flex; justify-content: space-between; cursor: pointer; color: var(--brand); font-size: 10px; }
.promo-row strong { color: var(--muted); }
.summary-line, .total-line { display: flex; justify-content: space-between; padding: 4px 0; font-size: 10px; }
.discount-line { color: var(--green); }
.total-line { margin-top: 5px; padding-top: 10px; border-top: 1px solid var(--line); align-items: center; font-size: 12px; }
.total-line strong { font-family: Georgia, serif; font-size: 19px; }
.pay-button { width: 100%; height: 48px; margin-top: 12px; padding: 0 16px; border: 0; border-radius: 13px; background: var(--brand); color: white; display: flex; align-items: center; justify-content: space-between; cursor: pointer; font-size: 11px; font-weight: 800; box-shadow: 0 10px 22px rgba(181,74,43,.2); }
.pay-button:disabled { background: #d4cec8; box-shadow: none; cursor: not-allowed; }
.shortcut-hint { padding-top: 9px; color: #9b918a; text-align: center; font-size: 8px; }
.shortcut-hint kbd { padding: 2px 4px; border: 1px solid #ddd3ca; border-radius: 4px; background: #f8f5f1; font-size: 7px; }

.section-toolbar { margin-bottom: 20px; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.section-toolbar h2 { margin: 0; font-family: Georgia, serif; font-size: 24px; }
.section-toolbar p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.toolbar-group { display: flex; flex-wrap: wrap; gap: 9px; }
.secondary-button, .primary-small { min-height: 39px; padding: 0 15px; border-radius: 11px; cursor: pointer; font-size: 11px; font-weight: 750; }
.secondary-button { border: 1px solid var(--line); background: white; }
.primary-small { border: 0; background: var(--brand); color: white; }
.kds-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 18px; }
.mini-stat { border: 1px solid var(--line); border-radius: 15px; background: var(--paper); padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; }
.mini-stat small, .mini-stat strong { display: block; }
.mini-stat small { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.mini-stat strong { margin-top: 4px; font-family: Georgia, serif; font-size: 20px; }
.mini-stat i { width: 10px; height: 10px; border-radius: 50%; background: var(--dot, #aaa); box-shadow: 0 0 0 6px color-mix(in srgb, var(--dot, #aaa) 14%, transparent); }
.kanban { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; align-items: start; }
.kanban-column { min-width: 0; border-radius: 17px; background: #ebe7e1; padding: 11px; }
.kanban-head { padding: 5px 5px 12px; display: flex; align-items: center; justify-content: space-between; }
.kanban-head h3 { margin: 0; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.kanban-head span { width: 23px; height: 23px; border-radius: 8px; display: grid; place-items: center; background: white; font-size: 9px; font-weight: 800; }
.ticket { margin-bottom: 9px; border-radius: 14px; padding: 14px; background: var(--paper); border: 1px solid var(--line); box-shadow: 0 6px 15px rgba(48,37,29,.05); }
.ticket.urgent { border-color: #e3a792; }
.ticket-top { display: flex; align-items: flex-start; justify-content: space-between; }
.queue-number { font-family: Georgia, serif; font-size: 22px; font-weight: 700; }
.timer { padding: 4px 6px; border-radius: 6px; background: #f2eee9; font-size: 9px; font-weight: 800; font-variant-numeric: tabular-nums; }
.ticket.urgent .timer { color: var(--danger); background: #fbe8e5; }
.ticket-name { margin: 2px 0 10px; color: var(--muted); font-size: 9px; }
.ticket-items { border-top: 1px solid var(--line); padding-top: 8px; }
.ticket-item { margin: 6px 0; display: grid; grid-template-columns: 18px 1fr; gap: 5px; font-size: 10px; line-height: 1.4; }
.ticket-item strong { color: var(--brand); }
.ticket-item small { display: block; color: var(--muted); font-size: 8px; }
.ticket-action { width: 100%; margin-top: 9px; height: 34px; border: 1px solid var(--brand); border-radius: 9px; background: white; color: var(--brand); font-size: 10px; font-weight: 800; cursor: pointer; }
.ticket-action.filled { background: var(--brand); color: white; }
.column-empty { padding: 40px 12px; text-align: center; color: #968b83; font-size: 10px; }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 13px; margin-bottom: 18px; }
.metric-card { min-height: 112px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); padding: 16px; box-shadow: 0 5px 16px rgba(49,35,25,.03); }
.metric-top { display: flex; align-items: center; justify-content: space-between; }
.metric-card .metric-icon { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: var(--tone, #eee); color: var(--accent, var(--ink)); }
.metric-delta { color: var(--green); font-size: 9px; font-weight: 800; }
.metric-card h3 { margin: 11px 0 2px; font-family: Georgia, serif; font-size: 23px; }
.metric-card p { margin: 0; color: var(--muted); font-size: 9px; }
.content-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: 0 7px 22px rgba(49,35,25,.035); overflow: hidden; }
.card-header { min-height: 68px; padding: 15px 18px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.card-header h3 { margin: 0; font-family: Georgia, serif; font-size: 17px; }
.card-header p { margin: 4px 0 0; color: var(--muted); font-size: 9px; }
.small-search { height: 36px; min-width: 230px; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; }
.small-search input { width: 100%; border: 0; outline: 0; background: none; font-size: 10px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { padding: 11px 16px; background: #faf8f5; color: var(--muted); text-align: left; font-size: 8px; text-transform: uppercase; letter-spacing: .08em; }
td { padding: 12px 16px; border-top: 1px solid var(--line); font-size: 10px; }
td strong, td small { display: block; }
td small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.ingredient-cell, .person-cell { display: flex; align-items: center; gap: 9px; }
.table-icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: #f3ece5; font-size: 15px; }
.stock-bar { width: 120px; height: 5px; margin-top: 5px; background: #ece7e1; border-radius: 99px; overflow: hidden; }
.stock-bar i { display: block; height: 100%; background: var(--bar, var(--green)); border-radius: inherit; }
.status-badge { display: inline-flex; align-items: center; gap: 5px; padding: 5px 8px; border-radius: 99px; background: var(--green-soft); color: var(--green); font-size: 8px; font-weight: 800; }
.status-badge.warning { background: var(--yellow-soft); color: #9a6b10; }
.status-badge.danger { background: #f8e5e3; color: var(--danger); }
.row-action { border: 0; background: none; color: var(--muted); cursor: pointer; }
.inventory-actions { display: flex; gap: 5px; white-space: nowrap; }
.inventory-actions button { padding: 6px 8px; border: 1px solid var(--ink); background: var(--paper); cursor: pointer; font-size: 8px; font-weight: 800; }
.stock-preview { margin-top: 14px; padding: 13px; border: 1px solid var(--ink); background: var(--green-soft); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; text-align: center; font-size: 9px; }
.stock-preview span, .stock-preview strong { display: block; }
.stock-preview strong { margin-top: 4px; color: var(--green); font-size: 13px; }
.stock-preview b { font-size: 18px; }
.danger-button { color: var(--danger); }
.muted-cell { color: var(--muted); font-size: 8px; }
.hpp-list { display: grid; gap: 9px; }
.hpp-card { padding: 13px; border: 1px solid var(--ink); background: white; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 16px; }
.hpp-card.missing { background: var(--yellow-soft); }
.hpp-card h3 { margin: 5px 0 3px; font-size: 13px; }
.hpp-card p { margin: 0; color: var(--muted); font-size: 9px; }
.hpp-status { color: var(--brand); font-size: 7px; font-weight: 900; letter-spacing: .12em; }
.hpp-card-value { min-width: 125px; text-align: right; }
.hpp-card-value strong, .hpp-card-value small { display: block; }
.hpp-card-value strong { font-size: 13px; }
.hpp-card-value small { margin: 2px 0 7px; color: var(--muted); font-size: 7px; }
.hpp-card-value button, .add-recipe-row { border: 1px solid var(--ink); background: var(--paper); padding: 7px 9px; cursor: pointer; font-size: 8px; font-weight: 800; }
.recipe-columns, .recipe-component-row { display: grid; grid-template-columns: 1.45fr 1.35fr .62fr .62fr .85fr .72fr 28px; gap: 6px; align-items: end; }
.recipe-columns { padding: 0 4px 5px; color: var(--muted); font-size: 7px; font-weight: 900; letter-spacing: .05em; }
#recipe-components { display: grid; gap: 7px; }
.recipe-component-row { padding: 8px; border: 1px solid var(--ink); background: white; }
.recipe-component-row label { min-width: 0; display: grid; gap: 4px; }
.recipe-component-row label > span { display: none; color: var(--muted); font-size: 7px; font-weight: 800; }
.recipe-component-row input, .recipe-component-row select { min-width: 0; width: 100%; height: 35px; border: 1px solid var(--line); background: var(--paper); padding: 0 7px; font-size: 8px; }
.recipe-remove { width: 28px; height: 35px; border: 1px solid var(--ink); background: white; color: var(--danger); cursor: pointer; }
.add-recipe-row { width: 100%; margin-top: 9px; border-style: dashed; }
.hpp-live-summary { margin-top: 14px; padding: 12px; border: 1px solid var(--ink); background: var(--green-soft); display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; text-align: center; }
.hpp-live-summary span, .hpp-live-summary strong { display: block; }
.hpp-live-summary span { color: var(--muted); font-size: 8px; }
.hpp-live-summary strong { margin-top: 4px; color: var(--green); font-size: 13px; }
.person-avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--bg, #eadfd6); color: var(--fg, #604a3e); font-weight: 800; font-size: 9px; }

.report-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .75fr); gap: 14px; margin-bottom: 14px; }
.report-grid.lower { grid-template-columns: 1fr 1fr; }
.legend { color: var(--muted); font-size: 9px; }
.legend i { display: inline-block; width: 8px; height: 8px; margin-right: 5px; border-radius: 3px; background: var(--brand); }
.bar-chart { height: 240px; padding: 25px 22px 16px; display: flex; align-items: flex-end; gap: 12px; background-image: linear-gradient(to top, var(--line) 1px, transparent 1px); background-size: 100% 25%; }
.bar-group { height: 100%; flex: 1; min-width: 20px; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 7px; }
.bar { width: min(30px, 70%); min-height: 4px; border-radius: 7px 7px 3px 3px; background: linear-gradient(to top, var(--brand-dark), #d87955); position: relative; transition: height .45s ease; }
.bar:hover::after { content: attr(data-value); position: absolute; top: -27px; left: 50%; transform: translateX(-50%); padding: 4px 6px; border-radius: 5px; background: var(--espresso); color: white; white-space: nowrap; font-size: 7px; }
.bar-group span { color: var(--muted); font-size: 8px; }
.ranking-list { padding: 8px 17px 14px; }
.rank-row { padding: 9px 0; display: grid; grid-template-columns: 24px 34px 1fr auto; align-items: center; gap: 8px; border-bottom: 1px solid var(--line); }
.rank-row:last-child { border: 0; }
.rank-number { color: #a99d94; font-family: Georgia, serif; font-size: 13px; }
.rank-thumb { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; }
.rank-row h4 { margin: 0; font-size: 9px; }
.rank-row p { margin: 2px 0 0; color: var(--muted); font-size: 8px; }
.rank-row strong { font-size: 10px; }
.text-button { border: 0; background: none; color: var(--brand); cursor: pointer; font-size: 9px; font-weight: 800; }
.payment-breakdown { padding: 18px; }
.payment-total { display: flex; align-items: center; gap: 18px; }
.donut { width: 110px; height: 110px; border-radius: 50%; background: conic-gradient(var(--brand) 0 64%, #d8a779 64% 89%, #eadfd5 89% 100%); position: relative; flex: 0 0 auto; }
.donut::after { content: ""; position: absolute; inset: 20px; border-radius: 50%; background: var(--paper); }
.payment-legend { flex: 1; display: grid; gap: 10px; }
.payment-item { display: grid; grid-template-columns: 8px 1fr auto; gap: 7px; align-items: center; font-size: 9px; }
.payment-item i { width: 8px; height: 8px; border-radius: 3px; background: var(--color); }
.payment-item span { color: var(--muted); }
.history-filter-card { margin-bottom: 16px; padding: 13px; border: 1px solid var(--ink); background: var(--paper); display: grid; grid-template-columns: minmax(210px,1.5fr) repeat(5,minmax(112px,1fr)) auto; align-items: end; gap: 9px; }
.history-filter-card label { min-width: 0; display: grid; gap: 5px; }
.history-filter-card label > span { color: var(--muted); font-size: 8px; font-weight: 800; text-transform: uppercase; }
.history-filter-card input, .history-filter-card select { min-width: 0; width: 100%; height: 38px; border: 1px solid var(--ink); background: white; padding: 0 9px; font-size: 9px; outline: 0; }
.history-filter-card .history-search { height: 38px; border: 1px solid var(--ink); padding: 0 10px; display: flex; align-items: center; gap: 7px; }
.history-search input { height: 34px; border: 0; padding: 0; }
.history-filter-card > button { height: 38px; border: 1px solid var(--ink); background: var(--paper); padding: 0 12px; cursor: pointer; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.history-total { color: var(--brand); font-family: "Sorgtime Hand", sans-serif; font-size: 22px; }
#view-transactions table { min-width: 1050px; }
.payment-chip { display: inline-flex; padding: 5px 7px; border: 1px solid var(--ink); background: var(--yellow-soft); font-size: 8px; font-weight: 800; }
.history-actions { display: flex; gap: 5px; }
.history-actions button { height: 29px; border: 1px solid var(--ink); background: var(--paper); padding: 0 8px; cursor: pointer; font-size: 8px; font-weight: 800; }
.transaction-detail-head { margin-bottom: 14px; display: grid; grid-template-columns: repeat(4,1fr); border: 1px solid var(--ink); }
.transaction-detail-head > div { min-width: 0; padding: 11px; border-right: 1px solid var(--ink); }
.transaction-detail-head > div:last-child { border-right: 0; }
.transaction-detail-head span, .transaction-detail-head strong { display: block; }
.transaction-detail-head > div > span { margin-bottom: 5px; color: var(--muted); font-size: 8px; text-transform: uppercase; }
.transaction-detail-head > div > strong { font-size: 10px; }
.transaction-items { border: 1px solid var(--ink); }
.transaction-items table { min-width: 0; }
.transaction-detail-grid { margin-top: 14px; display: grid; grid-template-columns: 1fr .85fr; gap: 14px; }
.transaction-finance, .transaction-timeline { padding: 13px; border: 1px solid var(--ink); background: white; }
.transaction-finance > div { padding: 6px 0; border-bottom: 1px dotted var(--line); display: flex; justify-content: space-between; gap: 12px; font-size: 9px; }
.transaction-finance > div:last-child { border-bottom: 0; }
.transaction-finance .grand { margin-bottom: 4px; padding: 9px 0; border-bottom: 1px solid var(--ink); font-size: 13px; }
.transaction-timeline h3 { margin: 0 0 10px; font-size: 11px; text-transform: uppercase; }
.history-step { position: relative; min-height: 43px; padding: 0 0 11px 21px; }
.history-step::before { content: ""; position: absolute; left: 5px; top: 8px; bottom: -2px; border-left: 1px dotted var(--ink); }
.history-step:last-child::before { display: none; }
.history-step i { position: absolute; left: 0; top: 3px; width: 11px; height: 11px; border: 1px solid var(--ink); background: var(--brand); }
.history-step strong, .history-step small { display: block; }
.history-step strong { font-size: 9px; }
.history-step small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.health-list { padding: 8px 18px 15px; }
.health-row { padding: 11px 0; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; font-size: 9px; }
.health-row:last-child { border: 0; }
.health-label { display: flex; align-items: center; gap: 9px; }
.health-label i { width: 25px; height: 25px; border-radius: 8px; display: grid; place-items: center; background: var(--green-soft); color: var(--green); font-style: normal; }

.modal-backdrop { position: fixed; z-index: 50; inset: 0; padding: 18px; background: rgba(27,18,12,.58); backdrop-filter: blur(4px); display: grid; place-items: center; }
.modal-backdrop[hidden] { display: none; }
.modal { width: min(520px, 100%); max-height: calc(100vh - 36px); overflow: auto; border-radius: 20px; background: var(--paper); box-shadow: 0 28px 80px rgba(23,13,8,.3); }
.modal.wide { width: min(700px, 100%); }
.modal-header { padding: 19px 20px 15px; border-bottom: 1px solid var(--line); display: flex; align-items: flex-start; justify-content: space-between; }
.modal-header h2 { margin: 0; font-family: Georgia, serif; font-size: 21px; }
.modal-header p { margin: 4px 0 0; color: var(--muted); font-size: 9px; }
.modal-close { width: 32px; height: 32px; border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; }
.modal-body { padding: 18px 20px; }
.modal-footer { padding: 14px 20px 18px; border-top: 1px solid var(--line); display: flex; gap: 10px; }
.modal-footer button { flex: 1; height: 44px; border-radius: 11px; cursor: pointer; font-size: 11px; font-weight: 800; }
.button-ghost { border: 1px solid var(--line); background: white; }
.button-primary { border: 0; background: var(--brand); color: white; }
.modifier-product { display: flex; gap: 13px; align-items: center; margin-bottom: 17px; }
.modifier-product .product-art { width: 74px; height: 74px; flex: 0 0 auto; }
.modifier-product h3 { margin: 0 0 3px; font-size: 14px; }
.modifier-product p { margin: 0; color: var(--brand); font-size: 12px; font-weight: 800; }
.option-group { margin: 17px 0; }
.option-title { margin-bottom: 9px; display: flex; justify-content: space-between; font-size: 10px; font-weight: 800; }
.option-title em { color: var(--brand); font-style: normal; font-size: 8px; }
.option-title-actions { display: flex; align-items: center; gap: 9px; }
.option-title-actions button { border: 0; border-bottom: 1px solid currentColor; padding: 0 0 2px; background: transparent; color: var(--brand); cursor: pointer; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.option-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.option-button { min-height: 43px; border: 1px solid var(--line); border-radius: 10px; background: white; cursor: pointer; font-size: 10px; }
.option-button.selected { border: 2px solid var(--brand); background: var(--orange-soft); color: var(--brand-dark); font-weight: 800; }
.option-button small { display: block; margin-top: 2px; color: var(--muted); font-size: 7px; }
.customer-search { width: 100%; height: 43px; border: 1px solid var(--line); border-radius: 11px; padding: 0 13px; outline: 0; }
.customer-results { margin-top: 11px; display: grid; gap: 7px; }
.customer-option { border: 1px solid var(--line); border-radius: 12px; background: white; padding: 10px; display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 9px; cursor: pointer; text-align: left; }
.customer-option strong, .customer-option small { display: block; }
.customer-option strong { font-size: 10px; }
.customer-option small { color: var(--muted); font-size: 8px; margin-top: 2px; }
.customer-option b { color: var(--brand); font-size: 9px; }
.payment-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.payment-option { min-height: 88px; border: 1px solid var(--line); border-radius: 13px; background: white; cursor: pointer; text-align: left; padding: 14px; }
.payment-option.selected { border: 2px solid var(--brand); background: var(--orange-soft); }
.payment-option i { display: block; margin-bottom: 8px; font-style: normal; font-size: 20px; }
.payment-option strong, .payment-option small { display: block; }
.payment-option strong { font-size: 11px; }
.payment-option small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.payment-total-box { margin-bottom: 15px; padding: 13px 14px; border-radius: 12px; background: var(--espresso); color: white; display: flex; justify-content: space-between; align-items: center; }
.payment-total-box span { font-size: 9px; color: #cbbfb6; }
.payment-total-box strong { font-family: Georgia, serif; font-size: 22px; }
.cash-input { margin-top: 14px; }
.cash-input label { display: block; margin-bottom: 7px; font-size: 9px; font-weight: 800; }
.money-input { height: 44px; border: 1px solid var(--line); border-radius: 11px; padding: 0 13px; display: flex; align-items: center; gap: 8px; }
.money-input input { width: 100%; border: 0; outline: 0; font-weight: 800; }
.quick-cash { display: flex; gap: 7px; margin-top: 8px; }
.quick-cash button { flex: 1; border: 1px solid var(--line); border-radius: 8px; background: white; padding: 7px; font-size: 8px; cursor: pointer; }
.qris-box { margin-top: 14px; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #faf8f5; display: grid; grid-template-columns: 240px 1fr; align-items: center; gap: 22px; }
.fake-qr { width: 240px; height: 240px; flex: 0 0 auto; border: 10px solid white; box-shadow: 0 0 0 1px var(--line); background: repeating-conic-gradient(#271b14 0 25%, transparent 0 50%) 0/18px 18px; }
.fake-qr.uploaded { border-width: 3px; background: white; }
.fake-qr.uploaded img { width: 100%; height: 100%; display: block; object-fit: contain; }
.fake-qr.empty { border-width: 2px; background: #eee8de; display: grid; place-items: center; align-content: center; color: var(--muted); text-align: center; }
.fake-qr.empty strong { font-size: 22px; }
.fake-qr.empty small { margin-top: 5px; font-size: 10px; }
.qris-box strong, .qris-box small { display: block; }
.qris-box strong { font-size: 12px; }
.qris-box small { margin-top: 6px; color: var(--muted); font-size: 10px; line-height: 1.55; }
.qris-box b { display: block; margin-top: 8px; color: var(--brand); font-size: 22px; }
.qris-status { margin-top: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; display: flex; align-items: center; gap: 10px; background: var(--yellow-soft); }
.qris-status i { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.6); font-style: normal; }
.qris-status strong, .qris-status small { display: block; }
.qris-status strong { font-size: 10px; }
.qris-status small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.qris-status.verified { background: var(--green-soft); color: var(--green); }
.verify-qris { width: 100%; min-height: 40px; margin-top: 9px; border: 1px solid var(--line); border-radius: 10px; background: white; cursor: pointer; font-size: 10px; font-weight: 800; }
.verify-qris:disabled { opacity: .45; cursor: not-allowed; }
.upload-qris { display: inline-block; margin-top: 7px; padding-bottom: 2px; border-bottom: 1px solid currentColor; color: var(--brand); cursor: pointer; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.upload-qris input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.change-preview { margin-top: 9px; color: var(--green); font-size: 10px; font-weight: 800; text-align: right; }
.button-primary:disabled { opacity: .45; cursor: not-allowed; box-shadow: none !important; }
.empty-inline, .empty-table { padding: 24px 14px; color: var(--muted); text-align: center; }
.empty-inline strong, .empty-inline span, .empty-table strong, .empty-table span { display: block; }
.empty-inline strong, .empty-table strong { color: var(--ink); font-size: 11px; }
.empty-inline span, .empty-table span { margin-top: 5px; font-size: 9px; }
.success-body { text-align: center; padding: 28px 22px; }
.success-icon { width: 66px; height: 66px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; background: var(--green-soft); color: var(--green); font-size: 29px; }
.success-body h2 { margin: 0; font-family: Georgia, serif; font-size: 24px; }
.success-body p { color: var(--muted); font-size: 10px; }
.queue-big { margin: 16px auto; padding: 13px; border-radius: 13px; background: #f5f0ea; font-family: Georgia, serif; font-size: 30px; font-weight: 800; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: grid; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 9px; font-weight: 800; }
.field input, .field select, .field textarea { width: 100%; min-height: 41px; border: 1px solid var(--line); border-radius: 10px; background: white; padding: 0 11px; outline: 0; font: inherit; font-size: 10px; }
.field textarea { min-height: 75px; padding-top: 10px; resize: vertical; }
.notice { margin-top: 12px; padding: 10px 12px; border-radius: 10px; background: var(--yellow-soft); color: #7b5b1f; font-size: 9px; line-height: 1.5; }
.price-editor, .promotion-list { display: grid; gap: 9px; }
.price-row { padding: 10px 12px; border: 1px solid var(--line); background: white; display: grid; grid-template-columns: 1fr 180px; align-items: center; gap: 16px; }
.price-row strong, .price-row small { display: block; }
.price-row strong { font-size: 11px; }
.price-row small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.price-input { height: 38px; border: 1px solid var(--ink); display: flex; align-items: center; padding: 0 10px; }
.price-input i { color: var(--muted); font-size: 9px; font-style: normal; }
.price-input input { min-width: 0; width: 100%; border: 0; outline: 0; background: transparent; text-align: right; font-weight: 800; }
.promo-card { padding: 13px; border: 1px solid var(--ink); background: white; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; }
.promo-card.inactive { opacity: .58; }
.promo-card h3 { margin: 5px 0 3px; font-size: 13px; }
.promo-card p { margin: 0; color: var(--muted); font-size: 9px; }
.promo-kind { color: var(--brand); font-size: 8px; font-weight: 900; letter-spacing: .12em; }
.promo-actions { display: flex; gap: 5px; }
.promo-actions button { border: 1px solid var(--ink); background: var(--paper); padding: 7px 9px; cursor: pointer; font-size: 8px; font-weight: 800; }
.promo-actions button:disabled { opacity: .5; cursor: not-allowed; }
.promo-actions .danger-action { color: var(--danger); }
.toggle-field { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; font-size: 10px; font-weight: 800; }
.toggle-field input { width: 17px; height: 17px; accent-color: var(--brand); }
.catalog-manager-list { display: grid; gap: 8px; }
.catalog-manage-row { min-height: 58px; padding: 9px 11px; border: 1px solid var(--ink); background: white; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; }
.catalog-manage-row.product-manage-row { grid-template-columns: 50px 1fr auto; }
.catalog-manage-row strong, .catalog-manage-row small { display: block; }
.catalog-manage-row strong { font-size: 10px; }
.catalog-manage-row small { margin-top: 4px; color: var(--muted); font-size: 8px; }
.catalog-manage-thumb { width: 50px; height: 44px; overflow: hidden; border: 1px solid var(--ink); background: #eee7de; }
.catalog-manage-thumb img { width: 100%; height: 100%; display: block; object-fit: cover; }
.catalog-row-actions { display: flex; gap: 5px; }
.catalog-row-actions button { padding: 7px 9px; border: 1px solid var(--ink); background: var(--paper); cursor: pointer; font-size: 8px; font-weight: 800; }
.catalog-row-actions .danger-action { color: var(--danger); }
.menu-photo-field { margin-bottom: 17px; padding: 12px; border: 1px dashed var(--ink); background: white; display: grid; grid-template-columns: 92px 1fr; align-items: center; gap: 14px; cursor: pointer; }
.menu-photo-preview { width: 92px; height: 82px; overflow: hidden; border: 1px solid var(--ink); background: #eee7de; display: grid; place-items: center; color: var(--muted); font-size: 8px; text-align: center; }
.menu-photo-preview img { width: 100%; height: 100%; display: block; object-fit: cover; }
.menu-photo-field strong, .menu-photo-field small { display: block; }
.menu-photo-field strong { font-size: 11px; }
.menu-photo-field small { margin-top: 5px; color: var(--muted); font-size: 8px; }
.menu-photo-field input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.toast-stack { position: fixed; z-index: 80; right: 20px; bottom: 20px; display: grid; gap: 9px; pointer-events: none; }
.toast { min-width: 280px; max-width: 360px; padding: 12px 14px; border-radius: 12px; background: var(--espresso); color: white; box-shadow: 0 14px 35px rgba(28,17,10,.28); display: flex; align-items: center; gap: 10px; animation: toast-in .25s ease; font-size: 10px; }
.toast i { width: 23px; height: 23px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.12); font-style: normal; }
@keyframes toast-in { from { transform: translateY(12px); opacity: 0; } }

@media (max-width: 1200px) {
  .product-grid { grid-template-columns: repeat(3, minmax(140px, 1fr)); }
  .pos-layout { grid-template-columns: minmax(0, 1fr) 350px; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .history-filter-card { grid-template-columns: repeat(3, 1fr); }
  .history-search { grid-column: span 2; }
}

@media (max-width: 900px) {
  .app-shell { display: block; }
  .sidebar { transform: translateX(-100%); transition: transform .22s ease; width: 230px; align-items: stretch; padding: 22px 15px; }
  .sidebar.open { transform: translateX(0); }
  .brand { flex-direction: row; justify-content: flex-start; padding-left: 10px; }
  .nav-item { min-height: 50px; flex-direction: row; justify-content: flex-start; padding: 0 16px; font-size: 11px; }
  .nav-icon { width: 28px; text-align: center; }
  .nav-item em { position: static; margin-left: auto; }
  .sync-card { grid-template-columns: auto 1fr auto; text-align: left; gap: 10px; }
  .sync-card > div, .sync-card > button { display: block; }
  .sync-card strong, .sync-card small { display: block; }
  .sync-card strong { font-size: 9px; }
  .sync-card small { color: #9f9288; font-size: 8px; }
  .sync-card button { color: white; border: 0; background: none; }
  .profile-card { justify-content: flex-start; gap: 9px; align-items: center; text-align: left; }
  .profile-card > span:not(.avatar) { display: block; }
  .profile-card > span:nth-child(2) { flex: 1; }
  .profile-card strong, .profile-card small { display: block; }
  .profile-card strong { font-size: 10px; }
  .profile-card small { color: #a89b91; font-size: 8px; }
  .main-area { min-width: 0; }
  .mobile-menu { display: block; width: 38px; height: 38px; margin-right: 12px; border: 1px solid var(--line); border-radius: 10px; background: white; }
  .topbar { height: 76px; padding: 0 16px; justify-content: flex-start; }
  .topbar > div:nth-child(2) { flex: 1; }
  .store-state, .icon-button { display: none; }
  .view { min-height: calc(100vh - 76px); padding: 18px 16px 28px; }
  .pos-layout { display: block; }
  .catalog-panel { padding: 18px 16px 400px; }
  .cart-panel { position: fixed; z-index: 15; left: 0; right: 0; bottom: 0; top: auto; min-height: 0; max-height: 380px; border-left: 0; border-top: 1px solid var(--line); box-shadow: 0 -10px 28px rgba(39,25,16,.1); }
  .cart-head, .customer-trigger, .cart-items { display: none; }
  .cart-summary { padding: 8px 16px 12px; }
  .promo-row, .summary-line, .shortcut-hint { display: none; }
  .total-line { border-top: 0; padding-top: 4px; }
  .pay-button { margin-top: 6px; }
  .kanban { grid-template-columns: 1fr; }
  .kanban-column { min-height: auto; }
  .report-grid, .report-grid.lower { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .topbar h1 { font-size: 20px; }
  .eyebrow { font-size: 8px; }
  .shift-pill { padding: 6px 8px; }
  .shift-pill span { display: none; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-card { min-height: 162px; }
  .product-art { height: 82px; }
  .section-toolbar { align-items: flex-start; flex-direction: column; }
  .kds-stats, .metric-grid { grid-template-columns: 1fr 1fr; }
  .small-search { min-width: 0; width: 100%; }
  .card-header { align-items: flex-start; flex-direction: column; }
  .option-grid { grid-template-columns: 1fr 1fr; }
  .payment-options, .form-grid { grid-template-columns: 1fr; }
  .field.full { grid-column: auto; }
  .bar-chart { gap: 5px; padding-left: 10px; padding-right: 10px; }
  .toast-stack { left: 12px; right: 12px; bottom: 12px; }
  .toast { min-width: 0; width: 100%; }
}

/* ─────────────────────────────────────────────────────────────
   SORGTIME EDITORIAL SYSTEM
   Adapted from the Sorgtime brand site: cream, khaki, forest,
   coral, ruled borders, product photography, and hand lettering.
   ───────────────────────────────────────────────────────────── */
@font-face {
  font-family: "Sorgtime Hand";
  src: url("assets/fonts/tuku-hand.otf") format("opentype");
  font-display: swap;
}

:root {
  --ink: #211e1e;
  --muted: #6e655b;
  --line: #211e1e;
  --paper: #fcf5e6;
  --canvas: #f2eadb;
  --brand: #006512;
  --brand-dark: #004d0e;
  --espresso: #22301f;
  --green: #006512;
  --green-soft: #dfe9d9;
  --orange-soft: #f6c7ba;
  --yellow-soft: #efe0b9;
  --danger: #b63b2e;
  --shadow: 5px 5px 0 rgba(33, 30, 30, .92);
  --radius: 3px;
}

body { background: var(--canvas); }
button { border-radius: 0; }
.app-shell { grid-template-columns: 116px minmax(0, 1fr); }
.sidebar {
  width: 116px;
  padding: 18px 11px 12px;
  background: var(--brand);
  border-right: 2px solid var(--ink);
}
.brand { gap: 8px; padding-bottom: 20px; color: white; }
.brand-mark {
  width: 48px;
  height: 58px;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 4px;
  overflow: hidden;
  background: var(--brand);
}
.brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.brand strong { font-size: 12px; letter-spacing: .12em; }
.brand small { margin-top: 3px; color: rgba(255,255,255,.72); font-size: 6px; letter-spacing: .2em; }
.nav-list { gap: 5px; border-top: 1px solid rgba(255,255,255,.35); padding-top: 12px; }
.nav-item {
  min-height: 61px;
  border: 1px solid transparent;
  border-radius: 3px;
  color: rgba(255,255,255,.74);
  font-size: 9px;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.nav-item:hover { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.4); }
.nav-item.active { color: var(--ink); background: #f1644b; border-color: var(--ink); box-shadow: 3px 3px 0 var(--ink); }
.nav-icon { font-family: "Sorgtime Hand", Georgia, serif; font-size: 26px; }
.nav-item em { background: var(--paper); border: 1px solid var(--ink); border-radius: 50%; }
.sync-card { border: 1px solid rgba(255,255,255,.34); border-radius: 3px; background: rgba(0,0,0,.08); }
.profile-card .avatar { border: 1px solid var(--ink); border-radius: 2px; background: #f1644b; color: var(--ink); }

.topbar {
  height: 82px;
  padding: 0 25px;
  background: var(--paper);
  border-bottom: 2px solid var(--ink);
  backdrop-filter: none;
}
.eyebrow { color: var(--brand); font-weight: 800; letter-spacing: .13em; }
.topbar h1, .section-toolbar h2, .catalog-meta h2, .card-header h3, .modal-header h2, .success-body h2 { font-family: "Sorgtime Hand", Georgia, serif; font-weight: 500; text-transform: uppercase; }
.topbar h1 { font-size: 31px; line-height: .85; }
.store-state { border-color: var(--ink); }
.store-state > span { background: var(--brand); border: 1px solid var(--ink); }
.store-state small { color: var(--brand); font-weight: 800; }
.icon-button, .shift-pill {
  border: 1px solid var(--ink);
  border-radius: 3px;
  background: transparent;
}
.shift-pill { background: #e4ebd9; }
.shift-pill span { color: var(--brand); }
.view { min-height: calc(100vh - 82px); padding: 24px 26px 34px; }
.hand-label {
  display: block;
  width: max-content;
  margin-bottom: 5px;
  padding: 4px 8px 2px;
  background: #f1644b;
  border: 1px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  font-family: "Sorgtime Hand", sans-serif;
  font-size: 11px;
  letter-spacing: .04em;
}

.pos-layout { grid-template-columns: minmax(0, 1fr) 392px; min-height: calc(100vh - 82px); }
.catalog-panel { padding: 22px 24px 42px; background: var(--canvas); }
.cart-panel {
  top: 82px;
  max-height: calc(100vh - 82px);
  min-height: calc(100vh - 82px);
  background: #c3ad97;
  border-left: 2px solid var(--ink);
}
.search-row { grid-template-columns: 1fr 48px; }
.search-box, .scan-button {
  border: 1.5px solid var(--ink);
  border-radius: 3px;
  background: var(--paper);
  box-shadow: 3px 3px 0 var(--ink);
}
.category-tabs { gap: 0; padding-top: 19px; }
.category-tab {
  border: 1px solid var(--ink);
  border-radius: 0;
  margin-right: -1px;
  padding: 10px 13px 7px;
  background: transparent;
  color: var(--ink);
  font-family: "Sorgtime Hand", sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
}
.category-tab.active { background: #f1644b; border-color: var(--ink); color: var(--ink); }
.catalog-meta { margin-top: 24px; align-items: center; }
.catalog-meta h2 { font-size: 27px; line-height: .9; }
.catalog-meta p { color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.catalog-meta button, .date-button { border: 1px solid var(--ink); border-radius: 2px; background: var(--paper); color: var(--ink); }
.product-grid { grid-template-columns: repeat(3, minmax(150px, 1fr)); gap: 14px; }
.product-card {
  min-height: 222px;
  padding: 0 0 12px;
  border: 1.5px solid var(--ink);
  border-radius: 3px;
  background: var(--paper);
  overflow: visible;
}
.product-card:hover { transform: translate(-2px, -2px); border-color: var(--ink); box-shadow: 5px 5px 0 var(--ink); }
.product-art { height: 148px; border-radius: 0; border-bottom: 1px solid var(--ink); background: #d9d0c3; overflow: hidden; }
.product-art::before, .product-art .cup { display: none; }
.product-art img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: 50% 48%; transition: transform .45s cubic-bezier(.16,1,.3,1); }
.product-card:hover .product-art img { transform: scale(1.045); }
.product-art.retail-art img { object-fit: contain; padding: 10px; background: #ddd3c5; }
.product-card h3 { margin: 11px 12px 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .025em; }
.product-card p { margin: 0 12px; color: var(--brand); font-size: 12px; }
.product-badge {
  top: 10px;
  left: 9px;
  border: 1px solid var(--ink);
  border-radius: 0;
  padding: 5px 7px 3px;
  background: #f1644b;
  color: var(--ink);
  font-family: "Sorgtime Hand", sans-serif;
  font-size: 10px;
  font-weight: 500;
}
.product-card.sold-out::after { background: var(--brand); border: 1px solid var(--ink); }

.cart-head { border-bottom: 1px solid var(--ink); }
.order-label { color: var(--brand-dark); }
.cart-head h2 { font-family: "Sorgtime Hand", sans-serif; font-size: 28px; }
.more-button { border: 1px solid var(--ink); border-radius: 2px; background: var(--paper); }
.customer-trigger {
  margin-top: 14px;
  border: 1px dashed var(--ink);
  border-radius: 2px;
  background: rgba(252,245,230,.52);
}
.customer-icon { border: 1px solid var(--ink); border-radius: 2px; background: #f1644b; color: var(--ink); }
.cart-items { padding-top: 12px; }
.cart-thumb { border: 1px solid var(--ink); border-radius: 2px; overflow: hidden; background: var(--paper); }
.cart-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cart-item { border-color: rgba(33,30,30,.35); }
.cart-item h4 { text-transform: uppercase; }
.qty-control { border-color: var(--ink); border-radius: 0; }
.qty-control button { background: var(--paper); }
.cart-summary { border-color: var(--ink); background: var(--paper); }
.promo-row { color: var(--brand); border-color: rgba(33,30,30,.3); }
.total-line { border-color: var(--ink); }
.pay-button {
  border: 1px solid var(--ink);
  border-radius: 2px;
  background: var(--brand);
  box-shadow: 4px 4px 0 var(--ink);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.pay-button:hover:not(:disabled) { background: #f1644b; color: var(--ink); }
.pay-button:disabled { border-color: #8c8279; box-shadow: none; }

.section-toolbar h2 { font-size: 34px; line-height: .9; }
.section-toolbar p { color: var(--muted); }
.secondary-button, .primary-small { border: 1px solid var(--ink); border-radius: 2px; text-transform: uppercase; letter-spacing: .04em; }
.secondary-button { background: var(--paper); }
.primary-small { background: var(--brand); box-shadow: 3px 3px 0 var(--ink); }
.kds-stats { gap: 10px; }
.mini-stat, .metric-card, .content-card {
  border: 1.5px solid var(--ink);
  border-radius: 3px;
  background: var(--paper);
  box-shadow: none;
}
.mini-stat strong, .metric-card h3 { font-family: "Sorgtime Hand", sans-serif; font-weight: 500; }
.kanban { gap: 12px; }
.kanban-column { border: 1px solid var(--ink); border-radius: 3px; background: #c3ad97; }
.kanban-head span { border: 1px solid var(--ink); border-radius: 2px; background: var(--paper); }
.ticket { border: 1px solid var(--ink); border-radius: 2px; box-shadow: 3px 3px 0 var(--ink); }
.queue-number { font-family: "Sorgtime Hand", sans-serif; font-size: 28px; }
.ticket-action { border-color: var(--ink); border-radius: 2px; background: #f1644b; color: var(--ink); }
.ticket-action.filled { background: var(--brand); color: white; }
.metric-card .metric-icon, .table-icon { border: 1px solid var(--ink); border-radius: 2px; }
.card-header, td, th { border-color: rgba(33,30,30,.35); }
.small-search { border: 1px solid var(--ink); border-radius: 2px; }
.status-badge { border: 1px solid currentColor; border-radius: 2px; }
.person-avatar { border: 1px solid var(--ink); border-radius: 2px; }
.rank-thumb { border: 1px solid var(--ink); border-radius: 2px; overflow: hidden; }
.rank-thumb img { width: 100%; height: 100%; object-fit: cover; }
.bar { background: var(--brand); border: 1px solid var(--ink); border-radius: 1px 1px 0 0; }
.donut { border: 1px solid var(--ink); }
.modal-backdrop { background: rgba(34,48,31,.74); }
.modal { border: 1.5px solid var(--ink); border-radius: 3px; background: var(--paper); box-shadow: 8px 8px 0 var(--ink); }
.modal-header, .modal-footer { border-color: var(--ink); }
.modal-close, .button-ghost, .button-primary { border: 1px solid var(--ink) !important; border-radius: 2px !important; }
.button-primary { background: var(--brand); color: white; box-shadow: 3px 3px 0 var(--ink); }
.modifier-product .product-art { width: 110px; height: 82px; border: 1px solid var(--ink); }
.option-button, .customer-option, .payment-option, .customer-search, .money-input, .field input, .field select, .field textarea, .qris-box, .qris-status, .verify-qris, .notice {
  border-color: var(--ink);
  border-radius: 2px;
}
.option-button.selected, .payment-option.selected { border-color: var(--ink); background: #f1644b; color: var(--ink); box-shadow: 3px 3px 0 var(--ink); }
.payment-total-box { border: 1px solid var(--ink); border-radius: 2px; background: var(--brand); }
.success-icon { border: 1px solid var(--ink); border-radius: 2px; background: #f1644b; color: var(--ink); box-shadow: 4px 4px 0 var(--ink); }
.queue-big { border: 1px solid var(--ink); border-radius: 2px; background: #c3ad97; font-family: "Sorgtime Hand", sans-serif; }
.toast { border: 1px solid var(--ink); border-radius: 2px; background: var(--brand); box-shadow: 5px 5px 0 var(--ink); }

@media (max-width: 1200px) {
  .product-grid { grid-template-columns: repeat(2, minmax(150px, 1fr)); }
}

@media (max-width: 900px) {
  .sidebar { width: 242px; }
  .app-shell { display: block; }
  .topbar { height: 74px; }
  .pos-layout { display: block; }
  .catalog-panel { padding-bottom: 390px; }
  .cart-panel { border-top: 2px solid var(--ink); background: #c3ad97; }
  .nav-item { min-height: 50px; }
}

@media (max-width: 620px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .product-card { min-height: 176px; }
  .product-art { height: 110px; }
  .product-card h3 { margin: 8px 8px 3px; font-size: 10px; }
  .product-card p { margin-left: 8px; }
  .hand-label { font-size: 9px; }
  .section-toolbar h2 { font-size: 29px; }
}

/* Authentication and role management */
.auth-gate {
  position: fixed;
  z-index: 200;
  inset: 0;
  padding: 24px;
  display: grid;
  place-items: center;
  overflow: auto;
  background: #22301f;
}
.auth-gate[hidden] { display: none; }
.auth-locked .app-shell { height: 100vh; overflow: hidden; filter: blur(7px); pointer-events: none; user-select: none; }
.auth-shell {
  width: min(980px, 100%);
  min-height: 610px;
  display: grid;
  grid-template-columns: .92fr 1.08fr;
  border: 2px solid var(--ink);
  background: var(--paper);
  box-shadow: 12px 12px 0 #111b0f;
}
.auth-brand-panel {
  min-height: 100%;
  padding: 36px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--brand);
  color: white;
  border-right: 2px solid var(--ink);
  overflow: hidden;
  position: relative;
}
.auth-brand-panel::after { content: ""; position: absolute; width: 280px; height: 280px; right: -110px; bottom: 60px; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; box-shadow: 0 0 0 42px rgba(255,255,255,.035),0 0 0 84px rgba(255,255,255,.025); }
.auth-brand-panel > * { position: relative; z-index: 1; }
.auth-brand-panel img { width: 58px; height: 74px; object-fit: cover; border: 1px solid rgba(255,255,255,.75); border-radius: 4px; }
.auth-kicker { font-size: 9px; font-weight: 800; letter-spacing: .16em; }
.auth-brand-panel h1 { margin: 14px 0 13px; font-family: "Sorgtime Hand", sans-serif; font-size: clamp(48px, 6vw, 72px); font-weight: 500; line-height: .84; text-transform: uppercase; }
.auth-brand-panel p { max-width: 310px; margin: 0; color: rgba(255,255,255,.78); font-size: 12px; line-height: 1.65; }
.auth-brand-panel > small { max-width: 240px; font-size: 8px; letter-spacing: .15em; line-height: 1.7; }
.auth-form-panel { min-width: 0; padding: 44px clamp(28px, 5vw, 62px); display: grid; align-items: center; background: var(--paper); }
.auth-form-wrap { width: 100%; max-width: 410px; margin: auto; }
.auth-step { display: inline-block; padding: 5px 8px 3px; border: 1px solid var(--ink); background: #f1644b; box-shadow: 3px 3px 0 var(--ink); font-family: "Sorgtime Hand",sans-serif; font-size: 11px; }
.auth-form-wrap h2 { margin: 22px 0 7px; font-family: "Sorgtime Hand",sans-serif; font-size: 38px; font-weight: 500; line-height: .95; text-transform: uppercase; }
.auth-form-wrap > p { margin: 0 0 22px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.auth-form { display: grid; gap: 12px; }
.auth-form label { display: grid; gap: 6px; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; }
.auth-form input { width: 100%; height: 44px; padding: 0 12px; border: 1px solid var(--ink); border-radius: 2px; background: white; outline: 0; font-size: 12px; text-transform: none; letter-spacing: normal; }
.auth-form input:focus { box-shadow: 3px 3px 0 var(--ink); }
.auth-form button { height: 46px; margin-top: 4px; border: 1px solid var(--ink); background: var(--brand); color: white; box-shadow: 4px 4px 0 var(--ink); cursor: pointer; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.auth-form button:hover { background: #f1644b; color: var(--ink); }
.auth-message { margin-bottom: 14px; padding: 9px 11px; border: 1px solid var(--ink); background: var(--yellow-soft); font-size: 9px; line-height: 1.5; }
.auth-security { margin-top: 17px; padding-top: 13px; border-top: 1px dotted var(--ink); color: var(--muted); font-size: 8px; line-height: 1.5; }
.auth-roles { margin-top: 25px; display: grid; grid-template-columns: repeat(3,1fr); border: 1px solid var(--ink); }
.auth-role { min-width: 0; padding: 9px; border-right: 1px solid var(--ink); }
.auth-role:last-child { border-right: 0; }
.auth-role span, .auth-role small { display: block; }
.auth-role span { color: var(--brand); font-family: "Sorgtime Hand",sans-serif; font-size: 13px; text-transform: uppercase; }
.auth-role small { margin-top: 4px; color: var(--muted); font-size: 7px; line-height: 1.4; }

.role-overview { margin-bottom: 18px; display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; }
.role-card { padding: 16px; border: 1px solid var(--ink); background: var(--paper); }
.role-card > div { display: flex; align-items: center; justify-content: space-between; }
.role-card span { font-family: "Sorgtime Hand",sans-serif; font-size: 20px; text-transform: uppercase; }
.role-card strong { font-family: "Sorgtime Hand",sans-serif; font-size: 28px; color: var(--brand); }
.role-card p { min-height: 30px; margin: 9px 0 0; color: var(--muted); font-size: 9px; line-height: 1.5; }
.role-pill { display: inline-flex; padding: 5px 8px 3px; border: 1px solid var(--ink); font-family: "Sorgtime Hand",sans-serif; font-size: 11px; text-transform: uppercase; }
.role-pill.sysadmin { background: #f1644b; }
.role-pill.admin { background: #efe0b9; }
.role-pill.barista { background: #dfe9d9; }
.account-actions { display: flex; flex-wrap: wrap; gap: 4px; }
.account-actions button { padding: 5px 7px; border: 1px solid var(--ink); background: white; cursor: pointer; font-size: 7px; text-transform: uppercase; }
.account-actions button:last-child { color: var(--danger); }
.protected-label { color: var(--muted); font-size: 8px; }
.permission-preview { margin-top: 16px; border: 1px solid var(--ink); }
.permission-preview div { padding: 9px 10px; border-bottom: 1px dotted var(--ink); }
.permission-preview div:last-child { border-bottom: 0; }
.permission-preview strong, .permission-preview span { display: block; }
.permission-preview strong { color: var(--brand); font-family: "Sorgtime Hand",sans-serif; font-size: 13px; text-transform: uppercase; }
.permission-preview span { margin-top: 2px; color: var(--muted); font-size: 8px; }
.profile-detail { display: flex; align-items: center; gap: 12px; }
.profile-detail .person-avatar { width: 48px; height: 48px; font-size: 12px; background: #f1644b; }
.profile-detail strong, .profile-detail small { display: block; }
.profile-detail small { margin-top: 4px; color: var(--muted); font-size: 9px; }

.report-filter-card { margin-bottom: 16px; padding: 13px; border: 1.5px solid var(--ink); background: var(--paper); display: grid; grid-template-columns: 1.35fr repeat(4, minmax(125px, .75fr)) auto; align-items: end; gap: 9px; }
.report-filter-card label { min-width: 0; display: grid; gap: 5px; }
.report-filter-card label > span { color: var(--muted); font-size: 8px; font-weight: 800; text-transform: uppercase; }
.report-filter-card input, .report-filter-card select { min-width: 0; width: 100%; height: 38px; border: 1px solid var(--ink); background: white; padding: 0 9px; font-size: 9px; }
.report-filter-card > button, .report-presets button { height: 38px; border: 1px solid var(--ink); background: var(--paper); padding: 0 10px; cursor: pointer; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.report-presets { display: grid; grid-template-columns: repeat(4, 1fr); }
.report-presets button { min-width: 0; padding: 0 6px; border-right: 0; }
.report-presets button:last-child { border-right: 1px solid var(--ink); }
.report-presets button.active { background: var(--brand); color: white; }
.report-grid.finance-row { grid-template-columns: minmax(290px, .75fr) minmax(0, 1.6fr); }
.finance-summary { padding: 11px 17px 15px; }
.finance-summary > div { padding: 8px 0; border-bottom: 1px dotted rgba(33,30,30,.45); display: flex; justify-content: space-between; gap: 15px; font-size: 9px; }
.finance-summary > div:last-child { border-bottom: 0; }
.finance-summary .cost strong { color: var(--danger); }
.finance-summary .subtotal { margin-top: 2px; border-bottom: 1px solid var(--ink); font-weight: 800; }
.finance-summary .grand { margin-top: 5px; padding-top: 12px; color: var(--green); font-size: 12px; font-weight: 900; }
.finance-summary .included { color: var(--green); font-size: 8px; }
.finance-summary .included strong::before { content: "SUDAH MASUK · "; font-size: 6px; }
.finance-summary .credit strong { color: var(--green); }
.finance-summary .finance-section { margin: 8px -17px 2px; padding: 8px 17px 5px; border-bottom: 1px solid var(--ink); background: #e5dacb; }
.finance-summary .finance-section:first-child { margin-top: -11px; }
.finance-summary .finance-section strong { font-family: "Sorgtime Hand", sans-serif; font-size: 13px; font-weight: 500; }
.finance-summary .cash-grand { margin-top: 5px; padding-top: 12px; border-bottom: 0; color: var(--brand); font-size: 12px; font-weight: 900; }
.compact-report-table table { min-width: 680px; }
.compact-report-table th, .compact-report-table td { padding: 10px 11px; }
.payroll-report-table { min-width: 1040px !important; }
.payroll-report-table td small { margin-top: 3px; display: block; color: var(--muted); font-size: 7px; }
.payroll-status { display: inline-flex; padding: 4px 7px; border: 1px solid var(--ink); white-space: nowrap; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.payroll-status.paid { background: var(--green-soft); color: var(--green); }
.payroll-status.partial { background: #fbf0d6; color: #8d5c08; }
.payroll-status.unpaid { background: #f6d9d5; color: var(--danger); }
.modal-record-table { max-height: 235px; margin-top: 15px; border: 1px solid var(--ink); }
.modal-record-table table { min-width: 650px; }
.modal-record-table th, .modal-record-table td { padding: 8px 9px; }
#payroll-bulk-list[hidden] { display: none; }
#payroll-bulk-list input { width: 140px; min-height: 36px; padding: 6px 8px; border: 1px solid var(--ink); background: white; }
#payroll-bulk-list td small { display: block; margin-top: 3px; color: var(--muted); }
.daily-report-card, .purchase-report-card { margin-bottom: 14px; }
.daily-report-table { min-width: 1580px; }
.report-method-note { margin: -2px 0 14px; padding: 11px 13px; border: 1px solid var(--ink); background: var(--green-soft); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.report-method-note > span, .report-method-note strong, .report-method-note span span, .report-method-note em { display: block; }
.report-method-note strong { font-size: 9px; text-transform: uppercase; }
.report-method-note span span { margin-top: 3px; color: var(--muted); font-size: 8px; line-height: 1.45; }
.report-method-note em { margin-top: 4px; color: var(--green); font-size: 8px; font-style: normal; font-weight: 800; }
.report-method-note.warning { background: #fbf0d6; }
.report-method-note.warning em { color: #8d5c08; }
.report-method-note button { flex: 0 0 auto; height: 34px; padding: 0 11px; border: 1px solid var(--ink); background: var(--brand); color: white; cursor: pointer; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.table-footnote { margin: 0; padding: 8px 12px 10px; border-top: 1px dotted var(--ink); color: var(--muted); font-size: 7px; line-height: 1.45; }
.comparison-note { color: var(--muted); font-size: 8px; text-transform: uppercase; }
.comparison-chip { display: inline-flex; padding: 4px 6px; border: 1px solid var(--ink); background: #eee7dc; font-size: 8px; font-weight: 800; }
.comparison-chip.up { background: var(--green-soft); color: var(--green); }
.comparison-chip.down { background: #f6d9d5; color: var(--danger); }
.negative-value, .missing-cost { color: var(--danger); }
.missing-cost { font-size: 8px; }
.purchase-edit { height: 28px; padding: 0 9px; border: 1px solid var(--ink); background: var(--paper); cursor: pointer; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.payroll-formula { margin: 15px 0; padding: 12px; border: 1px solid var(--ink); background: var(--green-soft); display: grid; gap: 5px; }
.payroll-formula strong, .payroll-formula span { display: block; }
.payroll-formula strong { font-size: 10px; text-transform: uppercase; }
.payroll-formula span { color: var(--muted); font-size: 9px; }
.bar-chart.daily-range { overflow-x: auto; align-items: stretch; }
.bar-chart.daily-range .bar-group { flex: 0 0 34px; }

.shift-pill.closed { background: #f4d7cf; }
.shift-pill.closed span { color: #9f3827; }
.shift-closed-banner { margin: 16px 24px 0; padding: 13px 15px; border: 1.5px solid var(--ink); background: #f2d7c8; box-shadow: 4px 4px 0 var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.shift-closed-banner[hidden] { display: none; }
.shift-closed-banner span, .shift-closed-banner strong, .shift-closed-banner small { display: block; }
.shift-closed-banner strong { font-family: "Sorgtime Hand", sans-serif; font-size: 19px; font-weight: 500; text-transform: uppercase; }
.shift-closed-banner small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.shift-closed-banner button { flex: 0 0 auto; min-height: 38px; padding: 0 15px; border: 1px solid var(--ink); background: var(--brand); color: white; box-shadow: 3px 3px 0 var(--ink); cursor: pointer; font-size: 9px; font-weight: 800; text-transform: uppercase; }
.product-card.shift-locked { opacity: .55; cursor: not-allowed; filter: grayscale(.35); }
.product-card.shift-locked:hover { transform: none; box-shadow: none; }
.shift-summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); margin-bottom: 14px; border: 1px solid var(--ink); }
.shift-summary-grid > div { min-width: 0; padding: 11px; border-right: 1px dotted var(--ink); }
.shift-summary-grid > div:last-child { border-right: 0; }
.shift-summary-grid span, .shift-summary-grid strong { display: block; }
.shift-summary-grid span { color: var(--muted); font-size: 8px; text-transform: uppercase; }
.shift-summary-grid strong { margin-top: 5px; font-size: 12px; }
.shift-actual-field { margin-top: 14px; }
.cash-difference { margin-top: 9px; padding: 10px 12px; border: 1px dashed var(--ink); display: flex; justify-content: space-between; font-size: 10px; }
.cash-difference .negative { color: var(--danger); }
.danger-notice { background: #f6d9d5; color: #812b22; }
.shift-history-title { margin: 20px 0 8px; font: 500 19px "Sorgtime Hand", sans-serif; text-transform: uppercase; }
.shift-history-list { border: 1px solid var(--ink); }
.shift-history-list > div { padding: 10px 11px; border-bottom: 1px dotted var(--ink); display: flex; justify-content: space-between; gap: 15px; }
.shift-history-list > div:last-child { border-bottom: 0; }
.shift-history-list span:last-child { text-align: right; }
.shift-history-list strong, .shift-history-list small { display: block; }
.shift-history-list strong { font-size: 9px; }
.shift-history-list small { margin-top: 3px; color: var(--muted); font-size: 8px; }

@media (max-width: 760px) {
  .auth-gate { padding: 12px; }
  .auth-shell { min-height: 0; grid-template-columns: 1fr; box-shadow: 7px 7px 0 #111b0f; }
  .auth-brand-panel { min-height: 210px; padding: 22px; border-right: 0; border-bottom: 2px solid var(--ink); }
  .auth-brand-panel img { width: 38px; height: 49px; }
  .auth-brand-panel h1 { margin: 8px 0; font-size: 39px; }
  .auth-brand-panel p { display: none; }
  .auth-brand-panel > small { font-size: 6px; }
  .auth-form-panel { padding: 28px 22px; }
  .auth-form-wrap h2 { font-size: 31px; }
  .auth-roles { grid-template-columns: 1fr; }
  .auth-role { border-right: 0; border-bottom: 1px solid var(--ink); }
  .auth-role:last-child { border-bottom: 0; }
  .role-overview { grid-template-columns: 1fr; }
  .report-filter-card { grid-template-columns: 1fr 1fr; }
  .report-presets { grid-column: 1 / -1; }
  .report-grid.finance-row { grid-template-columns: 1fr; }
  .report-method-note { align-items: stretch; flex-direction: column; }
  .shift-closed-banner { margin: 10px 12px 0; align-items: stretch; flex-direction: column; }
  .shift-summary-grid { grid-template-columns: 1fr 1fr; }
  .shift-summary-grid > div:nth-child(2) { border-right: 0; }
  .shift-summary-grid > div:nth-child(-n+2) { border-bottom: 1px dotted var(--ink); }
}

@media (max-width: 620px) {
  .catalog-meta { align-items: flex-start; gap: 10px; }
  .catalog-actions { flex-direction: column; align-items: stretch; }
  .catalog-actions button { padding: 7px 8px; font-size: 8px; }
  .qris-box { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 14px; }
  .fake-qr { width: min(240px, 72vw); height: min(240px, 72vw); }
  .price-row { grid-template-columns: 1fr; gap: 8px; }
  .promo-card { grid-template-columns: 1fr; }
  .promo-actions { flex-wrap: wrap; }
  .cart-summary .promo-row { display: flex; }
  .catalog-manage-row.product-manage-row { grid-template-columns: 44px 1fr; }
  .catalog-manage-row.product-manage-row .catalog-row-actions { grid-column: 1 / -1; }
  .menu-photo-field { grid-template-columns: 72px 1fr; }
  .menu-photo-preview { width: 72px; height: 68px; }
  .stock-preview { grid-template-columns: 1fr; }
  .stock-preview b { transform: rotate(90deg); }
  .hpp-card { grid-template-columns: 1fr; }
  .hpp-card-value { text-align: left; }
  .recipe-columns { display: none; }
  .recipe-component-row { grid-template-columns: 1fr 1fr; gap: 8px; }
  .recipe-component-row label > span { display: block; }
  .recipe-remove { width: 100%; grid-column: 1 / -1; }
  .hpp-live-summary { grid-template-columns: 1fr; text-align: left; }
  .history-filter-card { grid-template-columns: 1fr; }
  .history-search { grid-column: auto; }
  .report-filter-card { grid-template-columns: 1fr; }
  .report-presets { grid-column: auto; grid-template-columns: 1fr 1fr; }
  .report-presets button:nth-child(2) { border-right: 1px solid var(--ink); }
  .report-presets button:nth-child(-n+2) { border-bottom: 0; }
  .transaction-detail-head { grid-template-columns: 1fr 1fr; }
  .transaction-detail-head > div:nth-child(2) { border-right: 0; }
  .transaction-detail-head > div:nth-child(-n+2) { border-bottom: 1px solid var(--ink); }
  .transaction-detail-grid { grid-template-columns: 1fr; }
}

/* ─────────────────────────────────────────────────────────────
   MOBILE HARDENING
   The editorial theme redefines several layout rules after the
   first responsive block, so on phones the cart turned into a
   full-screen fixed overlay and the topbar/view spacing was too
   large. These rules are appended last so they always win.
   ───────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  html, body { max-width: 100%; }
  .app-shell, .main-area { min-width: 0; max-width: 100%; }

  .sidebar { z-index: 60; overflow-y: auto; overscroll-behavior: contain; box-shadow: 8px 0 32px rgba(20, 14, 10, .22); }

  .view { min-height: calc(100vh - 74px); min-height: calc(100dvh - 74px); padding: 18px 16px calc(28px + env(safe-area-inset-bottom)); }
  #view-pos { padding: 0; }

  .topbar { height: 74px; padding: 0 14px; gap: 10px; }
  .topbar > div:nth-child(2) { min-width: 0; }
  .topbar h1 { font-size: 22px; line-height: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .topbar-actions { gap: 8px; }

  .pos-layout { display: block; min-height: 0; }
  .catalog-panel { padding: 16px 16px calc(190px + env(safe-area-inset-bottom)); }
  .catalog-meta { align-items: flex-start; flex-wrap: wrap; gap: 10px; }
  .catalog-meta h2 { font-size: 25px; }

  .cart-panel {
    position: fixed;
    top: auto;
    left: 0;
    right: 0;
    bottom: 0;
    width: auto;
    height: auto;
    min-height: 0;
    max-height: none;
    border-left: 0;
    border-top: 2px solid var(--ink);
    background: var(--paper);
    box-shadow: 0 -12px 30px rgba(33, 30, 30, .16);
    padding-bottom: env(safe-area-inset-bottom);
  }
  .cart-summary { padding: 8px 16px 12px; }

  .section-toolbar { flex-wrap: wrap; align-items: flex-start; }
  .toolbar-group { width: 100%; }

  .report-filter-card { grid-template-columns: 1fr 1fr; }
  .report-presets { grid-column: 1 / -1; }

  .modal-backdrop { padding: 10px; }
  .modal { max-height: calc(100vh - 20px); max-height: calc(100dvh - 20px); }

  .toast-stack { left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); }
  .toast { min-width: 0; width: 100%; max-width: none; }
}

@media (max-width: 620px) {
  .topbar { padding: 0 12px; }
  .topbar h1 { font-size: 20px; }
  .eyebrow { max-width: 46vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .shift-pill { padding: 6px 8px; }
  .shift-pill strong { font-size: 10px; }

  .catalog-panel { padding: 14px 12px calc(180px + env(safe-area-inset-bottom)); }
  .search-row { grid-template-columns: 1fr 44px; gap: 8px; }
  .search-box { height: 44px; padding: 0 12px; }
  .scan-button { font-size: 18px; }
  .category-tabs { padding-top: 14px; }
  .category-tab { font-size: 11px; padding: 8px 11px 6px; }

  .catalog-meta h2 { font-size: 22px; }
  .catalog-actions { width: 100%; flex-direction: row; }
  .catalog-actions button { flex: 1; }

  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .product-card { min-height: 168px; }
  .product-art { height: 104px; }

  .section-toolbar { flex-direction: column; align-items: stretch; }
  .section-toolbar h2 { font-size: 26px; }
  .section-toolbar p { font-size: 10px; }

  .metric-grid, .kds-stats { grid-template-columns: 1fr 1fr; gap: 9px; }
  .role-overview { grid-template-columns: 1fr; }
  .metric-card { min-height: 94px; padding: 13px; }
  .metric-card h3 { font-size: 19px; }

  .card-header { padding: 13px 14px; }
  .content-card { border-radius: 2px; }

  .history-filter-card, .report-filter-card { padding: 12px; grid-template-columns: 1fr; }
  .history-search { grid-column: auto; }
  .report-presets { grid-column: auto; grid-template-columns: 1fr 1fr; }
  .history-filter-card input, .history-filter-card select,
  .report-filter-card input, .report-filter-card select { height: 42px; font-size: 11px; }

  .transaction-detail-head { grid-template-columns: 1fr 1fr; }
  .shift-summary-grid { grid-template-columns: 1fr 1fr; }

  .modal-header { padding: 15px 14px 12px; }
  .modal-header h2 { font-size: 19px; }
  .modal-body { padding: 14px; }
  .modal-footer { padding: 12px 14px 14px; }
  .modal-footer button { height: 46px; }

  .cart-summary { padding: 8px 14px 10px; }
  .pay-button { height: 46px; }
  .total-line strong { font-size: 18px; }
}
