:root{
  --bg:#FFFFFF;
  --surface:#F6F2EE;
  --surface-2:#EEE7DF;
  --border:#DED4C8;
  --text:#221B14;
  --text-muted:#6E6255;
  --accent:#CC4425;
  --accent-hover:#B23A1F;
  --accent-contrast:#FFFFFF;
  --accent-soft:#F7E1D8;
  --focus:#CC4425;
  --st-recebido:#5B6472; --st-recebido-bg:#E7E9EC;
  --st-prep:#966015;     --st-prep-bg:#F5E7CE;
  --st-pronto:#1E8E5A;   --st-pronto-bg:#DCF2E6;
  --st-entregue:#4B7A73; --st-entregue-bg:#E1EDEA;
  --shadow: 0 1px 2px rgba(34,27,20,0.06), 0 8px 24px -12px rgba(34,27,20,0.18);
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --bg:#18130E; --surface:#231C15; --surface-2:#2E251C; --border:#3D3122;
    --text:#F4ECE2; --text-muted:#B7A996;
    --accent:#FF7A45; --accent-hover:#FF9066; --accent-contrast:#1B0F06; --accent-soft:#3D2213; --focus:#FF9066;
    --st-recebido:#A9B3C2; --st-recebido-bg:#2A303B;
    --st-prep:#E3A83A;     --st-prep-bg:#3A2E14;
    --st-pronto:#3FCB8B;   --st-pronto-bg:#123B29;
    --st-entregue:#7FB0A8; --st-entregue-bg:#1E332F;
    --shadow: 0 1px 2px rgba(0,0,0,0.3), 0 8px 24px -12px rgba(0,0,0,0.5);
  }
}
:root[data-theme="dark"]{
  --bg:#18130E; --surface:#231C15; --surface-2:#2E251C; --border:#3D3122;
  --text:#F4ECE2; --text-muted:#B7A996;
  --accent:#FF7A45; --accent-hover:#FF9066; --accent-contrast:#1B0F06; --accent-soft:#3D2213; --focus:#FF9066;
  --st-recebido:#A9B3C2; --st-recebido-bg:#2A303B;
  --st-prep:#E3A83A;     --st-prep-bg:#3A2E14;
  --st-pronto:#3FCB8B;   --st-pronto-bg:#123B29;
  --st-entregue:#7FB0A8; --st-entregue-bg:#1E332F;
  --shadow: 0 1px 2px rgba(0,0,0,0.3), 0 8px 24px -12px rgba(0,0,0,0.5);
}

*{ box-sizing:border-box; }
html,body{ margin:0; padding:0; }
body{
  background:var(--bg); color:var(--text);
  font-family:"Archivo",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  -webkit-font-smoothing:antialiased; padding-bottom:96px;
}
h1,h2,h3{ font-family:"Archivo Black","Archivo",sans-serif; text-wrap:balance; margin:0; }
.mono{ font-family:"IBM Plex Mono",ui-monospace,monospace; font-variant-numeric:tabular-nums; }
a{ color:inherit; }
button{ font-family:inherit; }
::selection{ background:var(--accent-soft); }
:focus-visible{ outline:2px solid var(--focus); outline-offset:2px; }

.topbar{
  position:sticky; top:0; z-index:20; display:flex; align-items:center; justify-content:space-between;
  gap:12px; flex-wrap:wrap; padding:14px 20px; background:var(--bg); border-bottom:1px solid var(--border);
}
.brand{ display:flex; flex-direction:column; gap:1px; }
.brand .name{ font-size:1.05rem; letter-spacing:0.01em; }
.brand .tag{ font-size:0.72rem; color:var(--text-muted); letter-spacing:0.03em; }

.mark{
  width:34px; height:34px; border-radius:9px; flex:none;
  display:flex; align-items:center; justify-content:center;
  background:var(--accent); color:#fff; font-family:"Archivo Black",sans-serif;
  font-size:1.05rem; box-shadow:0 2px 6px rgba(0,0,0,0.25);
}
.brand-row{ display:flex; align-items:center; gap:10px; }
.wordmark{ font-family:"Archivo Black",sans-serif; letter-spacing:-0.01em; }

.hero{
  position:relative; overflow:hidden;
  background:#18130E; color:#F4ECE2;
  padding:56px 20px 64px; text-align:center;
}
.hero::before{
  content:""; position:absolute; inset:0; pointer-events:none;
  background:
    radial-gradient(ellipse 60% 50% at 15% 20%, rgba(255,122,69,0.20), transparent 60%),
    radial-gradient(ellipse 55% 45% at 85% 85%, rgba(255,122,69,0.14), transparent 60%);
}
.hero-inner{ position:relative; max-width:640px; margin:0 auto; }
.hero .mark{ margin:0 auto 18px; width:52px; height:52px; font-size:1.6rem; border-radius:14px; }
.hero h1{
  font-size:clamp(2.2rem, 6vw, 3.2rem); line-height:1.02; color:#FFFFFF;
  text-wrap:balance; animation:hero-rise .6s cubic-bezier(.2,.8,.2,1) both;
}
.hero p{
  margin:14px auto 0; max-width:46ch; color:#D9CCBE; font-size:1rem; line-height:1.55;
  animation:hero-rise .6s cubic-bezier(.2,.8,.2,1) .08s both;
}
@keyframes hero-rise{ from{ opacity:0; transform:translateY(10px); } to{ opacity:1; transform:translateY(0); } }
@media (prefers-reduced-motion: reduce){ .hero h1, .hero p{ animation:none; } }

.tabs{ display:inline-flex; background:var(--surface); border:1px solid var(--border); border-radius:10px; padding:3px; gap:2px; }
.tab-btn{
  appearance:none; border:none; background:transparent; color:var(--text-muted); text-decoration:none;
  font-size:0.86rem; font-weight:600; padding:8px 14px; border-radius:8px; cursor:pointer;
  transition:background .15s ease, color .15s ease; display:inline-flex; align-items:center;
}
.tab-btn.active{ background:var(--bg); color:var(--text); box-shadow:var(--shadow); }
.tab-btn:hover:not(.active){ color:var(--text); }

.wrap{ max-width:920px; margin:0 auto; padding:0 20px; }
section.screen{ padding:24px 0 40px; }
.section-head{ margin-bottom:16px; }
.section-head h2{ font-size:1.3rem; }
.section-head p{ margin:6px 0 0; color:var(--text-muted); font-size:0.9rem; max-width:60ch; }

.menu-toolbar{ display:flex; flex-direction:column; gap:14px; margin-bottom:22px; }
.menu-search{ position:relative; }
.menu-search svg{ position:absolute; left:14px; top:50%; transform:translateY(-50%); width:16px; height:16px; color:var(--text-muted); pointer-events:none; }
.menu-search input{ padding-left:38px; border-radius:999px; }
.cat-pills{ display:flex; gap:8px; overflow-x:auto; padding-bottom:2px; scrollbar-width:none; }
.cat-pills::-webkit-scrollbar{ display:none; }
.cat-pill{
  appearance:none; border:1px solid var(--border); background:var(--surface); color:var(--text);
  font-family:inherit; font-weight:600; font-size:0.84rem; padding:8px 16px; border-radius:999px;
  white-space:nowrap; cursor:pointer; flex:none; transition:background .15s ease, color .15s ease, border-color .15s ease;
}
.cat-pill:hover{ border-color:var(--accent); transform:translateY(-1px); }
.cat-pill.active{ background:var(--accent); border-color:var(--accent); color:var(--accent-contrast); }

.menu-grid{ display:grid; grid-template-columns:repeat(auto-fill,minmax(200px,1fr)); gap:18px; }
.menu-grid .item-card{ animation:card-in .45s cubic-bezier(.2,.8,.2,1) both; }
.menu-grid .item-card:nth-child(1){ animation-delay:.02s; } .menu-grid .item-card:nth-child(2){ animation-delay:.06s; }
.menu-grid .item-card:nth-child(3){ animation-delay:.10s; } .menu-grid .item-card:nth-child(4){ animation-delay:.14s; }
.menu-grid .item-card:nth-child(5){ animation-delay:.18s; } .menu-grid .item-card:nth-child(6){ animation-delay:.22s; }
.menu-grid .item-card:nth-child(n+7){ animation-delay:.24s; }
@keyframes card-in{ from{ opacity:0; transform:translateY(8px); } to{ opacity:1; transform:translateY(0); } }
@media (prefers-reduced-motion: reduce){ .menu-grid .item-card{ animation:none; } }
.item-card{
  background:var(--surface); border:1px solid var(--border); border-radius:18px; overflow:hidden;
  display:flex; flex-direction:column; box-shadow:var(--shadow);
  transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.item-card[hidden]{ display:none; }
.item-card:hover{ transform:translateY(-3px); border-color:var(--accent); box-shadow:0 12px 28px -14px rgba(0,0,0,0.35); }
.item-photo{ position:relative; aspect-ratio:1/1; display:flex; align-items:center; justify-content:center; font-size:4.4rem; line-height:1; overflow:hidden; }
.item-photo::after{ content:""; position:absolute; left:50%; bottom:14%; width:56%; height:12%; background:rgba(0,0,0,0.16); filter:blur(7px); border-radius:50%; transform:translateX(-50%); }
.item-photo span{ position:relative; z-index:1; filter:drop-shadow(0 6px 10px rgba(0,0,0,0.18)); display:inline-block; transition:transform .25s cubic-bezier(.2,.8,.2,1); }
.item-card:hover .item-photo span{ transform:scale(1.08) rotate(-2deg); }
.item-photo img{ width:100%; height:100%; object-fit:cover; display:block; transition:transform .35s cubic-bezier(.2,.8,.2,1); }
.item-card:hover .item-photo img{ transform:scale(1.06); }
@media (prefers-color-scheme: dark){ :root:not([data-theme="light"]) .item-photo{ filter:saturate(0.85) brightness(0.82); } }
:root[data-theme="dark"] .item-photo{ filter:saturate(0.85) brightness(0.82); }
.item-body{ padding:12px 14px 14px; display:flex; flex-direction:column; gap:8px; flex:1; }
.item-info{ flex:1; min-width:0; }
.item-info .name{ font-family:"Archivo Black",sans-serif; font-size:0.92rem; letter-spacing:0.01em; }
.item-info .desc{ font-size:0.76rem; color:var(--text-muted); line-height:1.4; margin-top:3px; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.item-bottom{ display:flex; align-items:center; justify-content:space-between; margin-top:auto; gap:8px; }
.price{ font-family:"Archivo Black",sans-serif; font-size:1.05rem; color:var(--accent); }
.add-btn{
  appearance:none; border:1px solid var(--accent); background:transparent; color:var(--accent);
  font-family:inherit; font-weight:700; font-size:0.78rem; padding:7px 14px; border-radius:999px;
  cursor:pointer; white-space:nowrap; transition:background .15s ease, color .15s ease;
}
.add-btn:hover{ background:var(--accent); color:var(--accent-contrast); transform:translateY(-1px); }
.add-btn:active{ transform:translateY(0) scale(0.96); }
.stepper{ display:flex; align-items:center; gap:6px; }
.stepper button{ width:26px; height:26px; border-radius:50%; border:1px solid var(--border); background:var(--bg); color:var(--text); font-size:1rem; cursor:pointer; line-height:1; }
.stepper button:hover{ border-color:var(--accent); color:var(--accent); }
.stepper .qty{ min-width:16px; text-align:center; font-weight:600; font-variant-numeric:tabular-nums; }

.cartbar{ position:fixed; left:0; right:0; bottom:0; z-index:30; background:var(--surface); border-top:1px solid var(--border); box-shadow:0 -8px 24px -12px rgba(0,0,0,0.18); }
.cartbar-inner{ max-width:920px; margin:0 auto; padding:12px 20px; display:flex; align-items:center; gap:14px; flex-wrap:wrap; }
.cart-summary{ font-size:0.86rem; color:var(--text-muted); flex:none; }
.cart-summary b{ color:var(--text); font-family:"Archivo Black",sans-serif; font-size:1rem; }
.field{ flex:1; min-width:180px; }
.field label{ display:block; font-size:0.72rem; color:var(--text-muted); margin-bottom:3px; letter-spacing:0.02em; }
input[type="tel"], input[type="text"], input[type="password"], input[type="number"]{
  width:100%; padding:9px 11px; border-radius:9px; border:1px solid var(--border); background:var(--bg); color:var(--text); font-size:0.95rem;
}
input.mono{ font-family:"IBM Plex Mono",monospace; letter-spacing:0.02em; }
.btn{
  appearance:none; border:none; border-radius:10px; padding:10px 18px; font-weight:700; font-size:0.9rem;
  cursor:pointer; white-space:nowrap; background:var(--accent); color:var(--accent-contrast);
  transition:background .15s ease, transform .05s ease;
}
.btn:hover{ background:var(--accent-hover); }
.btn:active{ transform:scale(0.98); }
.btn.secondary{ background:var(--surface-2); color:var(--text); }
.btn.secondary:hover{ background:var(--border); }
.btn:disabled{ opacity:0.5; cursor:not-allowed; }
.btn.small{ padding:6px 10px; font-size:0.76rem; width:100%; }
.field-error{ color:var(--accent); font-size:0.76rem; margin-top:4px; }

.confirm-card{ background:var(--surface); border:1px solid var(--border); border-radius:16px; padding:28px; max-width:520px; }
.confirm-code{ font-family:"Archivo Black",sans-serif; font-size:2rem; letter-spacing:0.02em; }
.confirm-list{ margin:14px 0; padding:0; list-style:none; }
.confirm-list li{ display:flex; justify-content:space-between; padding:6px 0; border-bottom:1px dashed var(--border); font-size:0.9rem; }
.confirm-total{ display:flex; justify-content:space-between; padding-top:10px; font-weight:700; }
.callout{ background:var(--accent-soft); border-radius:12px; padding:14px 16px; margin-top:18px; font-size:0.86rem; line-height:1.5; }
.callout .k{ font-family:"IBM Plex Mono",monospace; font-weight:600; }
.eyebrow{ color:var(--text-muted); font-size:0.8rem; font-weight:600; letter-spacing:0.03em; text-transform:uppercase; }

.search-panel{ background:var(--surface); border:1px solid var(--border); border-radius:16px; padding:20px; display:flex; gap:10px; align-items:flex-end; flex-wrap:wrap; }
.search-panel .field{ flex:1; min-width:220px; }

.order-result{ background:var(--surface); border:1px solid var(--border); border-radius:14px; padding:16px 18px; margin-top:14px; }
.order-result-head{ display:flex; align-items:flex-start; justify-content:space-between; gap:10px; flex-wrap:wrap; }
.order-id{ font-family:"IBM Plex Mono",monospace; color:var(--text-muted); font-size:0.82rem; }
.pill{ display:inline-flex; align-items:center; gap:5px; padding:4px 10px; border-radius:999px; font-size:0.74rem; font-weight:700; letter-spacing:0.02em; text-transform:uppercase; }
.pill.recebido{ background:var(--st-recebido-bg); color:var(--st-recebido); }
.pill.em_preparo{ background:var(--st-prep-bg); color:var(--st-prep); }
.pill.pronto{ background:var(--st-pronto-bg); color:var(--st-pronto); }
.pill.entregue{ background:var(--st-entregue-bg); color:var(--st-entregue); }
.meta-row{ display:flex; gap:14px; flex-wrap:wrap; margin:10px 0; font-size:0.8rem; color:var(--text-muted); }
.order-actions{ display:flex; gap:8px; margin-top:12px; flex-wrap:wrap; }

.empty-state{ text-align:center; padding:36px 20px; color:var(--text-muted); font-size:0.9rem; }
.empty-state .big{ font-size:2rem; margin-bottom:8px; }

.order-name{ font-weight:700; font-size:0.95rem; }
.notified-note{ font-size:0.76rem; color:var(--st-pronto); margin-top:8px; }
.pay-note{ font-size:0.76rem; color:var(--st-pronto); margin-top:6px; }
.eta-note{ font-size:0.76rem; color:var(--text-muted); margin-top:6px; }
.eta-note.late{ color:var(--accent); font-weight:600; }
.accept-actions{ display:flex; align-items:center; gap:6px; flex-wrap:wrap; }
.accept-label{ font-size:0.72rem; color:var(--text-muted); width:100%; }
.accept-actions .btn.small{ flex:1; min-width:56px; width:auto; }
.order-result.compact{ padding:10px 12px; border-radius:10px; }
.order-result.compact .order-id{ font-size:0.7rem; }
.order-result.compact .order-name{ font-size:0.85rem; }
.order-result.compact .meta-row{ margin:6px 0; }

.pix-box{ margin-top:18px; text-align:center; }
.pix-qr-wrap{ background:#fff; padding:10px; border-radius:10px; display:inline-block; }
.pix-qr{ width:140px; height:140px; display:block; }
.pix-hint{ font-size:0.78rem; color:var(--text-muted); margin-top:10px; max-width:340px; margin-left:auto; margin-right:auto; }
.pix-code{ background:var(--surface-2); border-radius:8px; padding:8px 10px; font-size:0.72rem; word-break:break-all; margin-top:10px; }

.admin-list{ margin-top:16px; display:flex; flex-direction:column; gap:6px; }
.admin-row{ display:flex; flex-wrap:wrap; gap:8px; align-items:center; padding:8px 0; border-bottom:1px solid var(--border); }
.admin-row.admin-head{ border-bottom:none; font-size:0.72rem; color:var(--text-muted); text-transform:uppercase; letter-spacing:0.02em; }
.admin-row .admin-photo{ width:40px; height:40px; flex:none; border-radius:8px; overflow:hidden; background:var(--surface-2); display:flex; align-items:center; justify-content:center; cursor:pointer; border:1px dashed var(--border); font-size:1.1rem; }
.admin-row .admin-photo img{ width:100%; height:100%; object-fit:cover; display:block; }
.admin-row .admin-photo:hover{ border-color:var(--accent); }
.admin-row .admin-icon{ width:50px; text-align:center; flex:none; }
.admin-row .admin-name{ flex:1; min-width:120px; }
.admin-row .admin-desc{ flex:2; min-width:160px; }
.admin-row .admin-cat{ flex:1; min-width:110px; }
.admin-row .admin-price{ width:90px; flex:none; }
.admin-row button{ flex:none; }
.admin-add{ margin-top:18px; padding-top:14px; border-top:1px dashed var(--border); }

.kanban-head{ margin-top:32px; font-weight:700; font-size:0.95rem; margin-bottom:12px; }
.kanban{ display:grid; grid-template-columns:repeat(4,1fr); gap:12px; }
.kanban-col{ background:var(--surface-2); border-radius:14px; padding:10px; display:flex; flex-direction:column; gap:8px; min-height:90px; }
.kanban-col-head{ display:flex; align-items:center; font-size:0.8rem; font-weight:700; padding:4px 4px 2px; }
.kanban-col-head .dot{ width:8px; height:8px; border-radius:50%; margin-right:6px; flex:none; }
.dot.recebido{ background:var(--st-recebido); }
.dot.em_preparo{ background:var(--st-prep); }
.dot.pronto{ background:var(--st-pronto); }
.dot.entregue{ background:var(--st-entregue); }
.kcount{ margin-left:auto; color:var(--text-muted); font-weight:600; font-variant-numeric:tabular-nums; }
.kanban-col-body{ display:flex; flex-direction:column; gap:8px; }
.kanban-empty{ color:var(--text-muted); font-size:0.78rem; text-align:center; padding:14px 0; }

.tracker{ display:flex; align-items:flex-start; margin:24px 0 8px; }
.tracker-step{ display:flex; flex-direction:column; align-items:center; flex:1; text-align:center; position:relative; }
.tracker-dot{
  width:34px; height:34px; border-radius:50%; background:var(--surface-2); border:2px solid var(--border);
  display:flex; align-items:center; justify-content:center; font-size:0.85rem; font-weight:700; color:var(--text-muted); z-index:1;
}
.tracker-line{ position:absolute; top:17px; left:-50%; width:100%; height:2px; background:var(--border); z-index:0; }
.tracker-step:first-child .tracker-line{ display:none; }
.tracker-label{ font-size:0.74rem; color:var(--text-muted); margin-top:6px; max-width:80px; }
.tracker-step.done .tracker-dot{ background:var(--accent); border-color:var(--accent); color:var(--accent-contrast); }
.tracker-step.done .tracker-line{ background:var(--accent); }
.tracker-step.current .tracker-dot{ background:var(--accent-soft); border-color:var(--accent); color:var(--accent); }
.tracker-step.current .tracker-label{ color:var(--text); font-weight:700; }

.login-wrap{ max-width:360px; margin:14vh auto 0; padding:0 20px; }
.login-card{ background:var(--surface); border:1px solid var(--border); border-radius:16px; padding:28px; display:flex; flex-direction:column; gap:14px; }

@media (max-width:860px){ .kanban{ grid-template-columns:1fr 1fr; } }
@media (max-width:560px){
  .kanban{ grid-template-columns:1fr; }
  .confirm-card{ padding:20px; }
  .topbar{ padding:12px 14px; }
  .wrap{ padding-left:14px; padding-right:14px; }
}
