:root {
  --bg: #fff7f1;
  --card: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --orange: #ff7a18;
  --orange-soft: #fff0e4;
  --purple: #7c4dff;
  --purple-soft: #f1ebff;
  --border: rgba(255, 122, 24, 0.12);
  --shadow: 0 16px 40px rgba(255, 122, 24, 0.12);
  --radius: 24px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: linear-gradient(180deg, #fff8f3 0%, #fff4ed 100%); color: var(--text); font-family: Inter, Arial, sans-serif; min-height: 100%; overflow-x: hidden; }
body { max-width: 100vw; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button { border: 0; cursor: pointer; }
.hidden { display: none !important; }
.screen { min-height: 100vh; }
.app-shell { width: 100%; max-width: 480px; min-height: 100vh; margin: 0 auto; background: transparent; position: relative; overflow-x: hidden; }
.content-wrap { padding: 18px 16px 110px; }
.login-screen { display: flex; align-items: center; justify-content: center; padding: 24px; }
.login-card { position: relative; background: linear-gradient(180deg, rgba(255,255,255,0.95), rgba(255,244,237,0.96)); padding: 28px; border-radius: 32px; box-shadow: var(--shadow); width: 100%; border: 1px solid rgba(255,255,255,0.7); overflow: hidden; }
.glass-card { backdrop-filter: blur(12px); }
.spark { position: absolute; border-radius: 50%; filter: blur(8px); opacity: .4; }
.spark-1 { width: 120px; height: 120px; top: -30px; right: -20px; background: #ffb06b; }
.spark-2 { width: 90px; height: 90px; bottom: -10px; left: -10px; background: #b786ff; }
.login-pill { display: inline-flex; padding: 10px 14px; background: var(--orange-soft); color: var(--orange); border-radius: 999px; font-weight: 700; font-size: 12px; margin-bottom: 18px; }
.login-card h1 { margin: 0 0 8px; font-size: 28px; }
.login-card p { margin: 0 0 20px; color: var(--muted); line-height: 1.6; }
.demo-buttons { display: grid; gap: 12px; }
.big-demo-btn { padding: 16px 18px; border-radius: 18px; font-weight: 700; transition: transform .16s ease, box-shadow .2s ease, opacity .2s ease; }
.big-demo-btn:active, .tap { transform: scale(.98); }
.big-demo-btn.primary { background: linear-gradient(135deg, var(--orange), #ff944d); color: #fff; box-shadow: 0 10px 24px rgba(255,122,24,.25); }
.big-demo-btn.secondary { background: linear-gradient(135deg, var(--purple), #9f78ff); color: #fff; box-shadow: 0 10px 24px rgba(124,77,255,.2); }
.big-demo-btn.ghost { background: #fff; color: var(--text); border: 1px solid #eee; }
.mobile-header { display: flex; justify-content: space-between; align-items: center; padding: 18px 16px 12px; background: rgba(255,247,241,.88); backdrop-filter: blur(8px); }
.sticky-top { position: sticky; top: 0; z-index: 20; }
.tiny-label { font-size: 12px; color: var(--muted); letter-spacing: .2px; }
.tiny-label.light { color: rgba(255,255,255,.84); }
.mobile-header h2 { margin: 4px 0 0; font-size: 22px; }
.header-actions { display: flex; gap: 10px; }
.icon-btn { width: 42px; height: 42px; border-radius: 14px; background: #fff; box-shadow: 0 10px 24px rgba(0,0,0,.06); font-size: 18px; }
.hero-summary { border-radius: 28px; padding: 20px; color: #fff; box-shadow: var(--shadow); }
.gradient-orange { background: linear-gradient(135deg, #ff7a18, #ff9b54 62%, #7c4dff 140%); }
.summary-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.hero-number { font-size: 40px; font-weight: 800; margin-top: 6px; }
.status-badge { padding: 8px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.status-badge.soft { background: rgba(255,255,255,.16); color: #fff; }
.summary-grid-3 { margin-top: 18px; display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; }
.mini-stat { background: rgba(255,255,255,.12); padding: 12px; border-radius: 18px; }
.mini-stat span { display: block; font-size: 11px; opacity: .9; }
.mini-stat strong { display: block; margin-top: 8px; font-size: 14px; }
.card-section { margin-top: 18px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.section-head h3 { margin: 0; font-size: 18px; }
.icon-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.menu-icon-card { background: var(--card); border-radius: 22px; padding: 14px 10px; box-shadow: 0 10px 28px rgba(0,0,0,.05); border: 1px solid rgba(255,122,24,.06); text-align: center; min-height: 94px; }
.menu-icon-card .emoji { width: 42px; height: 42px; display: grid; place-items: center; margin: 0 auto 8px; border-radius: 14px; background: var(--orange-soft); font-size: 22px; }
.menu-icon-card small { display: block; font-size: 12px; color: var(--text); line-height: 1.3; }
.horizontal-scroll { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 4px; scroll-snap-type: x proximity; }
.horizontal-scroll::-webkit-scrollbar { display: none; }
.menu-card, .promo-card, .history-card, .stack-card, .stat-card, .chart-card { background: var(--card); border-radius: 24px; box-shadow: 0 12px 28px rgba(0,0,0,.05); border: 1px solid rgba(255,122,24,.08); }
.menu-card { min-width: 210px; padding: 14px; scroll-snap-align: start; }
.food-thumb { height: 116px; border-radius: 20px; padding: 14px; color: #fff; display: flex; align-items: flex-end; font-weight: 700; position: relative; overflow: hidden; }
.food-thumb:after { content: ''; position: absolute; inset: auto -20px -30px auto; width: 80px; height: 80px; background: rgba(255,255,255,.18); border-radius: 50%; }
.price-pill { display: inline-flex; padding: 8px 12px; border-radius: 999px; background: var(--orange-soft); color: var(--orange); font-weight: 800; font-size: 12px; margin-top: 10px; }
.menu-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 10px; }
.stock-chip { padding: 6px 10px; border-radius: 999px; font-size: 11px; font-weight: 700; }
.stock-ok { background: #ebfff0; color: #17a34a; }
.stock-off { background: #fff1f1; color: #de3d3d; }
.promo-stack, .history-stack, .stack-list { display: grid; gap: 12px; }
.promo-card, .history-card, .stack-card, .stat-card, .chart-card { padding: 16px; }
.promo-card { background: linear-gradient(180deg, #fff, #fff8f4); }
.promo-tag { display: inline-flex; padding: 7px 10px; border-radius: 999px; background: #fff1e6; color: var(--orange); font-size: 11px; font-weight: 700; margin-bottom: 10px; }
.bottom-nav { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; width: 100%; max-width: 480px; background: rgba(255,255,255,.92); backdrop-filter: blur(12px); border-top: 1px solid rgba(255,122,24,.08); display: grid; grid-template-columns: repeat(5,1fr); padding: 10px 8px calc(10px + env(safe-area-inset-bottom)); z-index: 22; }
.nav-item { background: transparent; color: var(--muted); border-radius: 18px; padding: 8px 6px; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.nav-item.active { background: #fff4eb; color: var(--orange); font-weight: 700; }
.nav-item span { font-size: 18px; }
.nav-item small { font-size: 11px; }
.drawer-overlay, .modal-overlay { position: fixed; inset: 0; background: rgba(13,19,33,.28); backdrop-filter: blur(2px); z-index: 40; }
.side-drawer { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; width: 100%; max-width: 480px; min-height: 64vh; max-height: 92vh; background: linear-gradient(180deg, #fff, #fffaf6); border-radius: 28px 28px 0 0; z-index: 45; padding: 18px 16px 30px; overflow-y: auto; animation: slideUp .28s ease; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.drawer-close { width: 40px; height: 40px; border-radius: 14px; background: #fff1e6; color: var(--orange); }
.form-card { background: #fff; padding: 14px; border-radius: 22px; border: 1px solid rgba(255,122,24,.08); box-shadow: 0 12px 28px rgba(0,0,0,.04); }
.field { margin-bottom: 12px; }
.field label { display: block; font-size: 12px; font-weight: 700; margin-bottom: 7px; color: var(--muted); }
.field input, .field textarea, .field select { width: 100%; border: 1px solid #f1d9c7; background: #fffdfb; padding: 14px 14px; border-radius: 16px; outline: none; min-height: 50px; }
.field textarea { min-height: 88px; resize: vertical; }
.btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn-primary, .btn-secondary, .btn-soft, .mini-btn { padding: 14px 16px; border-radius: 16px; font-weight: 700; }
.btn-danger { padding: 14px 16px; border-radius: 16px; font-weight: 700; background: linear-gradient(135deg, #ff5e57, #ff7a45); color: #fff; box-shadow: 0 10px 24px rgba(255,94,87,.18); }
.btn-danger:active { transform: scale(.98); }
.btn-primary { background: linear-gradient(135deg, var(--orange), #ff9c54); color: #fff; }
.btn-secondary { background: linear-gradient(135deg, var(--purple), #a27aff); color: #fff; }
.btn-soft { background: var(--orange-soft); color: var(--orange); }
.mini-btn { padding: 10px 12px; font-size: 12px; background: #fff2e8; color: var(--orange); }
.inline-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kv { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; margin: 8px 0; }
.muted { color: var(--muted); }
.badge { display: inline-flex; padding: 6px 10px; border-radius: 999px; font-size: 11px; font-weight: 700; background: var(--purple-soft); color: var(--purple); }
.badge.orange { background: var(--orange-soft); color: var(--orange); }
.badge.green { background: #ecfff1; color: #18984a; }
.badge.red { background: #fff1f1; color: #dc4b4b; }
.stat-cards-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; }
.stat-card strong { font-size: 24px; display: block; margin-top: 8px; }
.analytics-grid { display: grid; gap: 12px; }
.chart-bars { display: grid; gap: 10px; margin-top: 12px; }
.chart-row { display: grid; grid-template-columns: 54px 1fr 44px; align-items: center; gap: 10px; }
.chart-bar-wrap { height: 10px; background: #fff2e9; border-radius: 999px; overflow: hidden; }
.chart-bar { height: 100%; background: linear-gradient(90deg, var(--orange), var(--purple)); border-radius: 999px; }
.order-card { padding: 14px; border-radius: 22px; background: #fff; border: 1px solid rgba(255,122,24,.08); box-shadow: 0 10px 24px rgba(0,0,0,.04); }
.order-card + .order-card { margin-top: 10px; }
.skeleton-list > * { position: relative; overflow: hidden; }
.skeleton { background: linear-gradient(90deg, #fff2ea 25%, #fffbf8 37%, #fff2ea 63%); background-size: 400% 100%; animation: shimmer 1.2s infinite; border-radius: 20px; min-height: 80px; }
.toast-box { position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%); width: calc(100% - 32px); max-width: 448px; z-index: 60; display: grid; gap: 8px; pointer-events: none; }
.toast { background: rgba(29,39,56,.95); color: #fff; padding: 14px 16px; border-radius: 18px; box-shadow: 0 18px 42px rgba(0,0,0,.24); animation: fadeToast .35s ease; }
.qr-card { background: linear-gradient(135deg, #fff, #fff2e6); border: 1px dashed #ffb88a; border-radius: 24px; padding: 16px; text-align: center; }
.qr-box { width: 150px; height: 150px; margin: 14px auto; background: conic-gradient(from 45deg, #000 0 25%, #fff 0 50%, #000 0 75%, #fff 0); background-size: 24px 24px; border: 10px solid #fff; border-radius: 18px; box-shadow: 0 10px 24px rgba(0,0,0,.06); }
.export-card { background: linear-gradient(135deg, #fff, #f6f0ff); }
.fade-in { animation: fadeIn .35s ease; }
.fade-in-up { animation: fadeUp .45s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideUp { from { transform: translate(-50%, 100%); } to { transform: translate(-50%, 0); } }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
@keyframes fadeToast { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
@media (min-width: 720px) {
  .app-shell { max-width: 520px; }
  .bottom-nav, .side-drawer { max-width: 520px; }
}
