:root {
  --bg: #f3f5f8;
  --surface: #ffffff;
  --line: #dce3ee;
  --text: #243044;
  --muted: #6a778b;
  --primary: #1f6ad8;
  --primary-2: #1552ab;
  --ok: #15803d;
  --warn: #9a6700;
  --bad: #c0392b;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; font-family: "Segoe UI", Tahoma, sans-serif; background: var(--bg); color: var(--text); }
.wrap { max-width: 1240px; margin: 0 auto; padding: 18px; }
.topo { background: var(--surface); border-bottom: 1px solid var(--line); }
.topo-com-capa { background-size: cover; background-position: center; }
.topo-cliente {
  position: sticky;
  top: 0;
  z-index: 26;
  backdrop-filter: blur(12px);
}
.topo-grid { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.marca-box { display: flex; align-items: center; gap: 12px; }
.logo-topo { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.marca { font-size: 1.35rem; font-weight: 800; }
.submarca { color: var(--muted); font-size: .92rem; }
.nav { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.nav a { color: var(--text); text-decoration: none; margin-left: 0; font-weight: 600; }
.nav a:hover { color: var(--primary); }
.nav a.ativo { color: var(--primary); }
.btn-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  border: 1px solid rgba(31,106,216,.18);
  background: linear-gradient(180deg, #ffffff, #f6f9ff);
  border-radius: 999px;
  padding: 9px 14px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .05);
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
}
.btn-nav:hover {
  color: var(--primary);
  border-color: rgba(31,106,216,.35);
  background: linear-gradient(180deg, #ffffff, #eef4ff);
  box-shadow: 0 12px 24px rgba(31, 106, 216, .12);
  transform: translateY(-1px);
}
.btn-nav.ativo {
  color: var(--primary);
  border-color: rgba(31,106,216,.48);
  background: linear-gradient(180deg, #f8fbff, #eaf2ff);
}
.nav-badge {
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: .7rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.hero h1 { margin-bottom: 6px; }
.muted { color: var(--muted); }
.hero-mobile-cardapio,
.catalogo-topbar-mobile,
.mobile-client-brand,
.mobile-bottom-nav { display: none; }

.layout-catalogo { display: grid; grid-template-columns: 1fr 340px; gap: 18px; }
.cards-produtos { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.produto-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px; cursor: pointer; min-height: 220px; }
.produto-thumb { width: 100%; height: 140px; border-radius: 10px; display: grid; place-items: center; font-weight: 900; font-size: 2rem; background: #eef2f8; color: var(--primary); }
.produto-thumb-img { width: 100%; height: 140px; object-fit: cover; border-radius: 10px; margin-bottom: 8px; }
.produto-info h3 { margin: 6px 0; font-size: 1.02rem; }
.produto-info p { margin: 0 0 10px 0; color: var(--muted); font-size: .92rem; }
.linha-preco { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.status { border-radius: 999px; padding: 4px 8px; font-size: .77rem; }
.status.ok { background: #dcfce7; color: #166534; }
.status.aviso { background: #fef3c7; color: #92400e; }
.status.ruim { background: #fee2e2; color: #991b1b; }
.link-agendar { display: inline-block; margin-top: 6px; font-size: .85rem; color: var(--primary); text-decoration: none; font-weight: 700; }
.link-agendar:hover { text-decoration: underline; }

.sacola { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px; position: sticky; top: 16px; height: fit-content; }
.lista-sacola { list-style: none; margin: 0; padding: 0; }
.lista-sacola li { border-bottom: 1px solid var(--line); padding: 8px 0; display: flex; justify-content: space-between; gap: 8px; }
.total-sacola { font-size: 1.1rem; font-weight: 800; margin-top: 10px; }
.link-remover { background: none; border: none; color: var(--bad); cursor: pointer; }
.btn-principal {
  width: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(180deg, #2b76e0, #1f6ad8);
  border: 1px solid rgba(15, 91, 198, .35);
  border-radius: 14px;
  padding: 12px 14px;
  box-shadow: 0 12px 24px rgba(31, 106, 216, .18);
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
}
.btn-principal:hover {
  background: linear-gradient(180deg, #347fe6, #1b5fc1);
  box-shadow: 0 16px 30px rgba(31, 106, 216, .24);
  transform: translateY(-1px);
}
.btn-principal.full {
  width: 100%;
}

.categorias-barra { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.cat-chip { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 8px 12px; cursor: pointer; }
.cat-chip.ativo { background: var(--primary); border-color: var(--primary); color: #fff; }
.secao-titulo { font-size: 1.35rem; margin: 18px 0 10px; font-weight: 800; }
.catalogo-busca-wrap { margin-bottom: 14px; }
.catalogo-busca { background: #fff; }

.modal { position: fixed; inset: 0; background: rgba(0,0,0,.62); display: none; align-items: center; justify-content: center; padding: 12px; z-index: 2000; backdrop-filter: blur(6px); }
.modal.aberto { display: flex; }
.modal-card {
  width: min(680px, 100%);
  max-height: min(92vh, 840px);
  overflow: auto;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(249,251,255,.98));
  border-radius: 22px;
  padding: 18px;
  position: relative;
  z-index: 2001;
  box-shadow: 0 30px 70px rgba(15,23,42,.28);
  border: 1px solid rgba(226,232,240,.9);
}
.modal-fechar {
  position: absolute;
  right: 14px;
  top: 14px;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(203,213,225,.95);
  border-radius: 999px;
  background: rgba(255,255,255,.96);
  font-size: 1.9rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(15,23,42,.08);
}
.modal-head { display: grid; gap: 8px; margin: 10px 0 14px; }
.modal-head h2 { margin: 0; font-size: 1.55rem; line-height: 1.1; letter-spacing: -.02em; color: #243044; }
.modal-head p { margin: 0; }
.modal-disponibilidade { color: #64748b; font-size: .95rem; }
.modal-preco {
  font-size: 1.55rem;
  font-weight: 900;
  margin: 6px 0 0;
  color: #1f6ad8;
}
.modal-foto-wrap {
  margin: 8px 0 14px;
  padding: 8px;
  border-radius: 20px;
  background: linear-gradient(180deg, #f8fbff, #eff4fb);
  border: 1px solid rgba(219,229,242,.9);
}
.modal-foto {
  width: 100%;
  aspect-ratio: 16 / 11;
  object-fit: cover;
  border-radius: 16px;
  border: 1px solid #dbe5f2;
  box-shadow: 0 12px 26px rgba(15,23,42,.08);
}
.modal-foto-fallback {
  width: 100%;
  min-height: 240px;
  border-radius: 16px;
  border: 1px solid #dbe5f2;
  background: linear-gradient(135deg, #eff6ff, #f8fafc);
  display: grid;
  place-items: center;
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--primary);
}
.modal-personalizacao { margin-top: 14px; }
.modal-personalizacao h3 { margin: 0 0 6px; font-size: 1.08rem; }
.modal-personalizacao-ajuda {
  margin: 0 0 12px;
  color: #64748b;
  font-size: .92rem;
  line-height: 1.35;
}
.modal-personalizacao-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.modal-opcoes { display: grid; gap: 8px; margin-top: 8px; }
.modal-opcao {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 12px;
  border: 1px solid #dbe5f2;
  border-radius: 14px;
  background: linear-gradient(180deg, #f9fbff, #f3f8ff);
  box-shadow: 0 8px 18px rgba(15,23,42,.04);
}
.modal-opcao label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  margin: 0;
  color: #243044;
}
.modal-opcao label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  accent-color: var(--primary);
}
.modal-opcao small { color: #64748b; font-weight: 700; }
.qtd-box { display: grid; grid-template-columns: 40px 1fr 40px; gap: 6px; }
.qtd-box button { border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.modal-form { margin-top: 12px; display: grid; gap: 8px; }
.modal-form .btn-principal { width: 100%; }
.agenda-dias, .agenda-horas { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.agenda-chip { border: 1px solid var(--line); background: #f8fbff; color: var(--text); border-radius: 999px; padding: 7px 10px; cursor: pointer; font-size: .88rem; }
.agenda-chip:hover { background: #e8f0fe; border-color: #bfd3fb; }
.agenda-chip.ativo { background: var(--primary); border-color: var(--primary); color: #fff; }

.checkout-layout { display: grid; grid-template-columns: 1fr 320px; gap: 16px; }
.card-bloco { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(180px, 1fr)); gap: 12px; }
.form-grid .full { grid-column: 1 / -1; }
.opcoes-entrega { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.opcao-entrega { display: inline-flex; align-items: center; gap: 8px; background: #eef3fb; border: 1px solid #d6e2f8; border-radius: 10px; padding: 10px 12px; font-weight: 600; }
.agenda-toggle-box { display: grid; gap: 8px; }
.agenda-toggle { display: inline-flex; align-items: center; gap: 8px; background: #ecfdf3; border: 1px solid #b7efc5; border-radius: 10px; padding: 10px 12px; width: fit-content; font-weight: 700; cursor: pointer; }
input, select, textarea { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 10px; background: #fff; color: var(--text); }
textarea { min-height: 74px; }
input[type="checkbox"] { width: auto; padding: 0; border: 0; accent-color: var(--primary); }
input[type="file"].file-input-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.file-input-ui {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.file-input-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
}
.file-input-btn:hover {
  background: #eef2f7;
}
.file-input-name {
  color: var(--muted);
  font-size: .92rem;
}
.file-input-name.tem-arquivo {
  color: var(--text);
}
.dias-combobox { border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; }
.dias-combobox summary { list-style: none; cursor: pointer; padding: 10px 12px; font-weight: 600; user-select: none; }
.dias-combobox summary::-webkit-details-marker { display: none; }
.dias-combobox summary::after { content: "▾"; float: right; color: #64748b; }
.dias-combobox[open] summary::after { content: "▴"; }
.dias-checks { border-top: 1px solid var(--line); padding: 8px 10px; display: grid; grid-template-columns: repeat(4, minmax(120px, 1fr)); gap: 8px; background: #fbfcff; }
.dias-checks label { display: inline-flex; align-items: center; gap: 6px; margin: 0; background: #f8fbff; border: 1px solid #e2e8f0; border-radius: 8px; padding: 6px 8px; font-size: .92rem; }
.dias-checks label:has(input:checked) { background: #e8f0fe; border-color: #a8c3f7; color: #1d4ed8; font-weight: 600; }

.login-box { max-width: 560px; }
.landing { max-width: 760px; padding-top: 42px; }

/* =========================
   Auth / Login Pages
   ========================= */
body.auth-page {
  min-height: 100vh;
  background:
    radial-gradient(900px 520px at 12% 14%, rgba(31,106,216,.18), transparent 60%),
    radial-gradient(700px 420px at 88% 18%, rgba(21,171,114,.14), transparent 58%),
    radial-gradient(900px 520px at 60% 92%, rgba(244,63,94,.10), transparent 55%),
    linear-gradient(180deg, #f7f9fc, #f1f5fb 55%, #eef2f8);
}

.auth-shell {
  max-width: 1040px;
  margin: 0 auto;
  padding: 28px 18px;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 16px;
  align-items: stretch;
}
.auth-shell-wide { grid-template-columns: 1fr 1fr; }
.auth-shell-single {
  max-width: 560px;
  grid-template-columns: 1fr;
  align-items: start;
}

.auth-panel {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid rgba(220,227,238,.9);
  background: rgba(255,255,255,.72);
  box-shadow: 0 18px 40px rgba(15, 23, 42, .06);
  padding: 22px;
}
.auth-panel::before {
  content: "";
  position: absolute;
  inset: -160px -180px auto auto;
  width: 420px;
  height: 420px;
  background: conic-gradient(from 220deg, rgba(31,106,216,.35), rgba(21,171,114,.28), rgba(31,106,216,.22));
  border-radius: 50%;
  filter: blur(18px);
  opacity: .35;
  transform: rotate(12deg);
}

.auth-brand { display: flex; align-items: center; gap: 12px; position: relative; z-index: 1; }
.auth-mark {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  letter-spacing: .6px;
  background: linear-gradient(135deg, #1f6ad8, #0ea5e9);
  box-shadow: 0 10px 22px rgba(31,106,216,.22);
}
.auth-brand-name { font-weight: 900; font-size: 1.1rem; }
.auth-brand-sub { color: var(--muted); font-weight: 600; font-size: .92rem; }

.auth-title { position: relative; z-index: 1; margin: 16px 0 6px; font-size: 2rem; letter-spacing: -.02em; }
.auth-subtitle { position: relative; z-index: 1; margin: 0; color: #475569; font-size: 1.02rem; line-height: 1.45; }
.auth-mini-info {
  position: relative;
  z-index: 1;
  margin-top: 14px;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px dashed rgba(148,163,184,.75);
  background: rgba(248,250,252,.85);
  color: #475569;
  font-weight: 600;
}

.auth-summary {
  display: grid;
  gap: 8px;
  padding: 14px 14px;
  border-radius: 14px;
  background: #f8fbff;
  border: 1px solid rgba(220,227,238,.95);
  color: #334155;
  font-size: .95rem;
}

.auth-summary strong {
  color: #0f172a;
}

.auth-card { border-radius: 18px; padding: 18px; box-shadow: 0 18px 40px rgba(15, 23, 42, .06); }
.auth-card.auth-card-login { padding: 22px 20px; }
.auth-card-top {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 10px;
  padding: 6px 0 8px;
}
.auth-logo {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1px solid rgba(226,232,240,.9);
  box-shadow: 0 14px 28px rgba(15,23,42,.10);
  overflow: hidden;
}
.auth-logo img { width: 100%; height: 100%; object-fit: cover; }
.auth-logo-fallback {
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: .4px;
  color: #0f172a;
  background: radial-gradient(circle at 30% 30%, #e0f2fe, #dbeafe 55%, #dcfce7);
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
}
.auth-card-title { margin: 2px 0 0; font-size: 1.25rem; letter-spacing: -.01em; }
.auth-hint { margin: 6px 0 0; color: var(--muted); }

.auth-form { display: grid; gap: 12px; }
.auth-form label { font-weight: 800; color: #334155; }
.auth-form input, .auth-form select, .auth-form textarea { background: #fff; }
.auth-form input:focus, .auth-form select:focus, .auth-form textarea:focus {
  outline: none;
  border-color: rgba(31,106,216,.6);
  box-shadow: 0 0 0 4px rgba(31,106,216,.12);
}

.auth-input {
  display: grid;
  grid-template-columns: 46px 1fr;
  border: 1px solid rgba(220,227,238,.95);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}
.auth-input-icon {
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, #f8fafc, #f1f5fb);
  border-right: 1px solid rgba(226,232,240,.92);
  color: #64748b;
}
.auth-input-icon svg { width: 18px; height: 18px; display: block; }
.auth-input input,
.auth-input select {
  border: 0;
  border-radius: 0;
  padding: 11px 12px;
  background: transparent;
}
.auth-input input:focus,
.auth-input select:focus {
  outline: none;
  box-shadow: inset 0 0 0 2px rgba(31,106,216,.22);
}
.auth-links { display: grid; justify-items: center; gap: 8px; text-align: center; }

.card-menor {
  padding: 16px;
  border: 1px solid #d9e4f3;
  border-radius: 16px;
  background: #f8fbff;
}

.texto-secundario {
  margin: 4px 0 14px;
  color: #5e6d84;
  font-size: 0.95rem;
}

.permissoes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px 14px;
}

.permissoes-grid label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  padding: 8px 10px;
  border: 1px solid #d7e1ef;
  border-radius: 12px;
  background: #fff;
}

.auth-form-grid { grid-template-columns: repeat(2, minmax(180px, 1fr)); }
.auth-form-grid .full { grid-column: 1 / -1; }

.auth-divider { height: 1px; background: linear-gradient(90deg, transparent, rgba(148,163,184,.65), transparent); margin: 6px 0 2px; }
.auth-section-title { margin: 0; font-size: 1rem; color: #0f172a; }
.auth-footer { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

@media (max-width: 940px) {
  .auth-shell, .auth-shell-wide { grid-template-columns: 1fr; }
  .auth-title { font-size: 1.7rem; }
}

.topo-empresa { position: sticky; top: 0; z-index: 20; }
.empresa-head { display: grid; gap: 12px; }
.empresa-logo-centro { display: grid; place-items: center; text-align: center; }
.logo-central { width: 92px; height: 92px; border-radius: 50%; object-fit: cover; border: 3px solid #e5edfa; }
.logo-preview { width: 140px; max-width: 100%; border-radius: 10px; border: 1px solid var(--line); }
.config-preview { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #f8fbff; }
.config-capa { height: 180px; background: linear-gradient(120deg, #dbeafe, #d1fae5); background-size: cover; background-position: center; }
.config-logo-wrap { margin-top: -46px; display: grid; place-items: center; gap: 8px; padding: 0 12px 14px 12px; }
.logo-placeholder { width: 92px; height: 92px; border-radius: 50%; background: #e2e8f0; border: 3px solid #fff; display: grid; place-items: center; font-size: 2rem; font-weight: 800; color: #334155; }
.empresa-nav { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.empresa-nav a { text-decoration: none; color: var(--text); background: #eef3fb; padding: 8px 12px; border-radius: 8px; font-weight: 600; }
.empresa-nav a:hover { background: #dfe9fa; }
.empresa-nav a.ativo { background: var(--primary); color: #fff; }
.cards-resumo { display: grid; grid-template-columns: repeat(3, minmax(140px, 1fr)); gap: 12px; }
.cards-resumo strong { font-size: 1.8rem; }
.tabela { width: 100%; border-collapse: collapse; }
.tabela th, .tabela td { border-bottom: 1px solid var(--line); padding: 9px; text-align: left; vertical-align: top; }
.pedido-cancelado td { background: #fff1f2; color: #9f1239; }
.pedido-cancelado td:first-child { border-left: 4px solid #e11d48; }
.status-tag { display: inline-block; margin-left: 8px; padding: 2px 8px; border-radius: 999px; font-size: .72rem; font-weight: 800; letter-spacing: .3px; }
.status-tag-cancelado { background: #ffe4e6; border: 1px solid #fecdd3; color: #be123c; }
.item-editor { border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; padding: 10px; background: #fbfcff; }
.categoria-item { border: 1px solid var(--line); border-radius: 10px; margin-top: 12px; padding: 12px; background: #fbfcff; }
.categoria-item h3 { margin: 0 0 10px 0; font-size: 1rem; color: #334155; }
.produto-mini { width: 100px; height: 70px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }

.btn, .file-input-btn, .agenda-chip, .cat-chip, .mobile-nav-item {
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease, color .16s ease;
}
.btn {
  background: linear-gradient(180deg, #ffffff, #edf2fb);
  border: 1px solid #d3deef;
  border-radius: 12px;
  padding: 9px 12px;
  cursor: pointer;
  font-weight: 700;
  color: #1f2a3d;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .04);
}
.btn:hover {
  background: linear-gradient(180deg, #ffffff, #e4ecf8);
  border-color: #bfd0ea;
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, .08);
}
.btn:focus-visible,
.btn-principal:focus-visible,
.btn-status:focus-visible,
.btn-nav:focus-visible,
.agenda-chip:focus-visible,
.cat-chip:focus-visible,
.file-input-btn:focus-visible,
.mobile-nav-item:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px rgba(31,106,216,.16), 0 12px 24px rgba(15, 23, 42, .08);
}
.btn-status {
  min-width: 132px;
  font-weight: 700;
  border-radius: 12px;
  padding: 9px 12px;
  background: linear-gradient(180deg, #ffffff, #f6f9ff);
  border: 1px solid #d6e2f8;
}
.btn-status:hover { transform: translateY(-1px); }
.btn-status.ativo { background: linear-gradient(180deg, #e8f1ff, #dbeafe); border-color: #60a5fa; color: #1e40af; cursor: default; box-shadow: none; }
.btn-status:disabled { opacity: 1; }
.btn-status-cancelar.ativo { background: linear-gradient(180deg, #fff1f2, #fee2e2); border-color: #fca5a5; color: #991b1b; }
.btn-copy-empresa { background: linear-gradient(180deg, #eef4ff, #e8f0fe); border-color: #a8c3f7; color: #1d4ed8; font-weight: 700; }
.btn-copy-empresa:hover { background: linear-gradient(180deg, #f5f8ff, #dbeafe); }
.btn-copy-cardapio { background: linear-gradient(180deg, #f0fdf4, #ecfdf3); border-color: #9be7bf; color: #0f766e; font-weight: 700; }
.btn-copy-cardapio:hover { background: linear-gradient(180deg, #f8fffb, #dcfce7); }
.btn-danger { background: linear-gradient(180deg, #fff5f6, #fff1f2); border-color: #fecdd3; color: #be123c; font-weight: 700; }
.btn-danger:hover { background: linear-gradient(180deg, #fff8f9, #ffe4e6); }
.admin-acao-inline { display: inline-block; margin-left: 6px; }
.linha { display: flex; gap: 10px; align-items: center; }
.erro-box { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; border-radius: 8px; padding: 10px; }
.alerta-agendamento {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  border-radius: 12px;
  padding: 14px 16px;
  margin: 12px 0 16px;
}
.alerta-agendamento p { margin: 6px 0 10px; }
.alerta-agendamento ul { margin: 0; padding-left: 18px; }
.alerta-agendamento li + li { margin-top: 6px; }
.ok-box { background: #dcfce7; color: #166534; border: 1px solid #86efac; border-radius: 8px; padding: 10px; margin-bottom: 10px; }
.btn-principal:disabled,
.btn-desabilitado {
  opacity: .62;
  cursor: not-allowed;
  filter: saturate(.8);
}
.bloqueio-wrap { min-height: 70vh; display: grid; place-items: center; }
.bloqueio-card { max-width: 760px; text-align: center; padding: 28px; }
.timeline-pedido { display: grid; grid-template-columns: repeat(4, minmax(120px, 1fr)); gap: 8px; margin: 12px 0; }
.tp-item { position: relative; border: 1px solid var(--line); border-radius: 10px; padding: 10px; background: #f8fafc; text-align: center; }
.tp-icon { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #e2e8f0; color: #334155; font-size: .72rem; font-weight: 800; margin-right: 6px; vertical-align: middle; }
.tp-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: #94a3b8; margin-right: 6px; vertical-align: middle; }
.tp-label { font-weight: 600; color: #475569; font-size: .92rem; vertical-align: middle; }
.tp-item.ok { border-color: #86efac; background: #f0fdf4; }
.tp-item.ok .tp-icon { background: #bbf7d0; color: #166534; }
.tp-item.ok .tp-dot { background: #22c55e; }
.tp-item.ok .tp-label { color: #166534; }
.tp-item.atual { box-shadow: 0 0 0 2px #93c5fd inset; }

.mobile-bottom-nav {
  backdrop-filter: blur(14px);
}
.mobile-nav-item {
  border-radius: 14px;
}
.mobile-nav-item:hover {
  transform: translateY(-1px);
}
.mobile-nav-item.ativo {
  box-shadow: 0 10px 22px rgba(31,106,216,.12);
}

@media (max-width: 1000px) {
  .layout-catalogo, .checkout-layout { grid-template-columns: 1fr; }
  .sacola { position: static; }
  .dias-checks { grid-template-columns: repeat(3, minmax(120px, 1fr)); }
  .topo-grid { flex-direction: column; align-items: flex-start; }
  .cards-produtos { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
  .tabela { display: block; overflow-x: auto; white-space: nowrap; }
}
@media (max-width: 860px), (hover: none) and (pointer: coarse) {
  .wrap { padding: 12px; }
  body.path-cardapio,
  body.path-cardapio-finalizar,
  body.path-cardapio-carrinho,
  body.path-cardapio-pagamento,
  body.path-cardapio-status,
  body.path-cardapio-pedidos { background: #fff; }
  body.path-cardapio .topo,
  body.path-cardapio-finalizar .topo,
  body.path-cardapio-carrinho .topo,
  body.path-cardapio-pagamento .topo,
  body.path-cardapio-status .topo,
  body.path-cardapio-pedidos .topo { border-bottom: 0; background: #fff; }
  body.path-cardapio .topo-grid,
  body.path-cardapio-finalizar .topo-grid,
  body.path-cardapio-carrinho .topo-grid,
  body.path-cardapio-pagamento .topo-grid,
  body.path-cardapio-status .topo-grid,
  body.path-cardapio-pedidos .topo-grid { display: none; }
  body.modal-produto-aberto .mobile-client-brand,
  body.modal-produto-aberto .catalogo-cabecalho-mobile,
  body.modal-produto-aberto .mobile-bottom-nav {
    display: none !important;
  }
  .form-grid { grid-template-columns: 1fr; }
  .dias-checks { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .timeline-pedido { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .modal-personalizacao-grid { grid-template-columns: 1fr; }
  .empresa-nav { flex-wrap: nowrap; overflow-x: auto; justify-content: flex-start; padding-bottom: 4px; }
  .empresa-nav a { white-space: nowrap; }
  .nav { display: flex; flex-wrap: nowrap; gap: 8px; overflow-x: auto; }
  .nav a { white-space: nowrap; }
  .cards-produtos { grid-template-columns: 1fr !important; gap: 0; }
  .produto-card {
    min-height: 0 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 96px !important;
    gap: 12px !important;
    align-items: start !important;
    padding: 16px 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    border-bottom: 1px solid #eceff5 !important;
    background: transparent !important;
    box-shadow: none !important;
  }
  .produto-thumb-img, .produto-thumb {
    height: 96px !important;
    width: 96px !important;
    min-width: 96px !important;
    max-width: 96px !important;
    margin: 0 !important;
    border-radius: 10px !important;
    order: 2;
  }
  .produto-info { order: 1; }
  .produto-info h3 { font-size: 1.05rem; margin-top: 0; }
  .produto-info p { font-size: .9rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .produto-info { min-width: 0; }
  .linha-preco { flex-direction: column; align-items: flex-start; gap: 8px; }
  .hero-desktop-cardapio,
  .hero-mobile-cardapio { display: none; }
  .mobile-client-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 10px;
    padding: 10px 12px;
    position: sticky;
    top: 0;
    z-index: 24;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226,232,240,.9);
    border-radius: 0 0 14px 14px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    box-shadow: 0 8px 24px rgba(15, 23, 42, .08);
  }
  .mobile-client-brand-capa {
    overflow: hidden;
  }
  .mobile-client-brand-capa::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(255,255,255,.95), rgba(255,255,255,.80));
    z-index: 0;
    pointer-events: none;
  }
  .mobile-client-brand > * {
    position: relative;
    z-index: 1;
  }
  .mobile-client-brand-logo {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 10px;
    object-fit: cover;
    background: #eef2f8;
  }
  .mobile-client-brand-fallback {
    display: grid;
    place-items: center;
    font-size: 1rem;
    font-weight: 800;
    color: var(--primary);
  }
  .mobile-client-brand-copy {
    display: grid;
    gap: 2px;
    min-width: 0;
  }
  .mobile-client-brand-copy strong {
    font-size: .98rem;
    line-height: 1.1;
    color: #1f2937;
  }
  .mobile-client-brand-copy span {
    font-size: .76rem;
    color: #6b7280;
    line-height: 1.1;
  }
  .catalogo-topo-sentinela {
    width: 1px;
    height: 1px;
    margin-top: -1px;
    pointer-events: none;
  }
  .hero-mobile-top { display: grid; grid-template-columns: 92px 1fr; gap: 14px; align-items: start; }
  .hero-mobile-logo { width: 92px; height: 92px; border-radius: 12px; object-fit: cover; background: #facc15; }
  .hero-mobile-logo-fallback { display: grid; place-items: center; font-size: 2rem; font-weight: 800; color: #111827; }
  .hero-mobile-copy h1 { margin: 0 0 6px; font-size: 1.85rem; line-height: 1.05; }
  .hero-mobile-copy p { margin: 0 0 10px; color: rgba(255,255,255,.82); }
  .hero-mobile-tag { color: #fff; font-weight: 700; font-size: .94rem; }
  .catalogo-topbar-mobile { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 6px 0 14px; }
  .catalogo-cabecalho-mobile {
    position: sticky;
    top: 0;
    z-index: 27;
    background: #ffffff;
    padding: 8px 0 10px;
    border-bottom: 1px solid #eef2f7;
    box-shadow: 0 10px 24px rgba(15,23,42,.08);
    overflow: hidden;
    max-height: 260px;
    opacity: 1;
    transform: translateY(0);
    transition:
      max-height .24s ease,
      opacity .18s ease,
      transform .18s ease,
      padding .22s ease,
      margin .22s ease,
      box-shadow .18s ease,
      border-color .18s ease;
  }
  .catalogo-topbar-mobile { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 0 4px; }
  .catalogo-topbar-mobile h2 { margin: 0; font-size: 1.65rem; font-weight: 800; letter-spacing: -.03em; color: #243044; }
  .catalogo-search-toggle { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border: 0; background: rgba(31,106,216,.06); color: #1f6ad8; padding: 0; border-radius: 12px; }
  .catalogo-search-toggle svg { width: 30px; height: 30px; display: block; }
  .catalogo-busca-wrap {
    margin: 0 0 4px;
    padding: 0 2px;
  }
  .catalogo-busca {
    border: 1px solid #dce5f0;
    border-radius: 14px;
    padding: 10px 12px;
    font-size: .98rem;
    background: linear-gradient(180deg, #ffffff, #fbfcfe);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.9);
  }
  .categorias-bloco {
    position: relative;
    z-index: 27;
    margin-top: 0;
  }
  .categorias-barra {
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 18px;
    padding: 0 10px 6px;
    position: static;
    background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(249,251,255,.98));
    z-index: 28;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .05);
    border: 1px solid rgba(226,232,240,.88);
    border-radius: 14px;
    backdrop-filter: blur(10px);
  }
  .cat-chip {
    border: 0;
    border-radius: 0;
    background: transparent;
    padding: 10px 0 12px;
    white-space: nowrap;
    color: #9ca3af;
    font-size: .9rem;
    font-weight: 700;
    border-bottom: 3px solid transparent;
  }
  .cat-chip.ativo { background: transparent; color: #243044; border-color: #1f6ad8; }
  body.catalogo-cabecalho-colapsado .catalogo-cabecalho-mobile {
    max-height: 0;
    opacity: 0;
    transform: translateY(-8px);
    padding-top: 0;
    padding-bottom: 0;
    margin-top: 0;
    margin-bottom: 0;
    border-bottom-color: transparent;
    box-shadow: none;
    pointer-events: none;
  }
  .secao-titulo { font-size: 1.75rem; margin: 10px 0 8px; }
  .layout-catalogo { gap: 0; padding-bottom: 132px; }
  .layout-catalogo > section { min-width: 0; }
  .sacola { display: none; }
  .categoria-secao { scroll-margin-top: 24px; }
  .mobile-bottom-nav {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 8px;
    z-index: 30;
    background: rgba(255,255,255,.94);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(203,213,225,.85);
    box-shadow: 0 18px 40px rgba(15,23,42,.14);
    border-radius: 18px;
    padding: 7px 7px calc(7px + env(safe-area-inset-bottom));
  }
  .mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 46px;
    text-decoration: none;
    color: #94a3b8;
    background: transparent;
    border: 0;
    border-radius: 13px;
    font-size: .72rem;
    font-weight: 700;
    text-align: center;
    padding: 5px 3px;
    transition: background .18s ease, color .18s ease, transform .18s ease;
  }
  .mobile-nav-item:active {
    transform: translateY(1px);
  }
  .mobile-nav-item.ativo {
    color: #0f172a;
    background: linear-gradient(180deg, #eef4ff 0%, #e0ecff 100%);
    box-shadow: inset 0 0 0 1px #bfdbfe;
  }
  .mobile-nav-icon {
    position: relative;
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .mobile-nav-icon svg {
    width: 18px;
    height: 18px;
    display: block;
  }
  .mobile-nav-label {
    line-height: 1;
    letter-spacing: .01em;
  }
  .mobile-nav-badge {
    position: absolute;
    top: -8px;
    right: -10px;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    border-radius: 999px;
    background: #ef4444;
    color: #fff;
    font-size: .64rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 0 2px rgba(255,255,255,.96);
    line-height: 1;
  }
  body.path-cardapio main,
  body.path-cardapio-finalizar main,
  body.path-cardapio-carrinho main,
  body.path-cardapio-pagamento main,
  body.path-cardapio-status main,
  body.path-cardapio-pedidos main { padding-bottom: calc(132px + env(safe-area-inset-bottom)); }
  .modal { padding: 8px; align-items: flex-end; }
  .modal-card {
    width: 100%;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    max-height: 90vh;
    padding: 12px 12px calc(126px + env(safe-area-inset-bottom));
  }
  .qtd-box { grid-template-columns: 42px 1fr 42px; }
}
@media (max-width: 430px) {
  .marca { font-size: 1.15rem; }
  .submarca { font-size: .82rem; }
  .btn-principal, .btn { font-size: .92rem; }
  input, select, textarea { padding: 9px; }
  .file-input-btn { width: 100%; }
  .mobile-bottom-nav {
    left: 8px;
    right: 8px;
    bottom: 6px;
    padding-left: 6px;
    padding-right: 6px;
  }
  .mobile-nav-item {
    min-height: 42px;
    font-size: .68rem;
  }
}
