/* Delivery de Quentinhas · Restaurante Santinha */
:root {
  --ink: #2C1A0E;
  --ink-soft: #6E5343;
  --laranja-marmita: #DA680C;
  --terracota: #B83E00;
  --marrom-marmita: #7A2400;
  --laranja-light: #FFEDE0;
  --creme-marmita: #FFF3D6;
  --bordo: #B83E00; /* Mapeado para a paleta quente da marmita */
  --bordo-dark: #7A2400;
  --bordo-light: #FFEDE0;
  --gold: #E58925;
  --gold-dark: #B83E00;
  --cream: #FFFDF9;
  --sand: #F7EFE4;
  --white: #FFFFFF;
  --line: #E8D8C4;
  --green: #0F6B3C;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 8px 24px rgba(122, 36, 0, 0.10);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
.container { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }

/* Header */
.delivery-header {
  background: var(--white);
  border-bottom: 3px solid var(--terracota);
  padding: 12px 0;
  position: sticky; top: 0; z-index: 50;
  box-shadow: 0 4px 14px rgba(122, 36, 0, 0.08);
}
.header-content { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand-link { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.brand-logo { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; border: 2px solid var(--terracota); }
.brand-name { display: block; font-weight: 800; font-size: 16px; color: var(--terracota); letter-spacing: 0.5px; }
.brand-sub { display: block; font-size: 12px; color: var(--ink-soft); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.btn-voltar {
  padding: 6px 12px; border-radius: 20px; font-size: 13px; font-weight: 600;
  text-decoration: none; color: var(--ink-soft); border: 1px solid var(--line);
  transition: all .15s;
}
.btn-voltar:hover { background: var(--sand); color: var(--ink); }
.btn-whatsapp {
  padding: 6px 14px; border-radius: 20px; font-size: 13px; font-weight: 700;
  background: #25D366; color: #fff; text-decoration: none; display: flex; align-items: center; gap: 6px;
  box-shadow: 0 2px 6px rgba(37,211,102,0.3); transition: transform .15s;
}
.btn-whatsapp:hover { transform: translateY(-1px); }

/* Hero */
.delivery-hero { padding: 20px 0 12px; }
.hero-card {
  background: linear-gradient(135deg, #7A2400 0%, #B83E00 45%, #DA680C 100%);
  color: #fff; padding: 24px 20px; border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.hero-content-flex {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: center;
  text-align: center;
}
@media (min-width: 768px) {
  .hero-content-flex {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    gap: 30px;
  }
  .hero-text-col { flex: 1.2; }
  .hero-photos-col { flex: 0.9; width: 100%; max-width: 380px; }
}
.hero-badge {
  display: inline-block; padding: 4px 12px; border-radius: 20px;
  font-size: 13px; font-weight: 700; background: rgba(255,255,255,0.2);
  margin-bottom: 12px;
}
.hero-badge.aberto { background: #22C55E; color: #fff; }
.hero-badge.fechado { background: #EF4444; color: #fff; }
.hero-title { font-size: 26px; font-weight: 800; margin-bottom: 8px; line-height: 1.2; }
.hero-desc { font-size: 14px; opacity: 0.95; max-width: 600px; margin: 0 auto 16px; }
@media (min-width: 768px) {
  .hero-desc { margin: 0 0 16px; }
}
.hero-price-tag {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; color: var(--bordo); padding: 6px 16px; border-radius: 30px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.tag-label { font-size: 13px; font-weight: 600; }
.tag-value { font-size: 20px; font-weight: 800; color: var(--bordo); }

/* Hero Photos & Cartaz Oficial */
.hero-photos-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}
.hero-foto-destaque-cartaz {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
  border: 3px solid #FFF3D6;
  max-width: 400px;
  margin: 0 auto;
  background: #7A2400;
  transition: transform .2s ease;
}
.hero-foto-destaque-cartaz:hover {
  transform: scale(1.02);
}
.hero-foto-destaque-cartaz img {
  width: 100%;
  height: auto;
  max-height: 290px;
  object-fit: contain;
  display: block;
}
.hero-foto-destaque {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0,0,0,0.3);
  border: 2px solid rgba(255,255,255,0.25);
  height: 160px;
}
.hero-foto-destaque img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-foto-tag {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(184, 62, 0, 0.95);
  color: #fff;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.hero-fotos-mini {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.hero-fotos-mini img {
  width: 100%;
  height: 75px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  display: block;
}

/* Preview da Quentinha Montada */
.quentinha-preview-box {
  background: #FFFDF9;
  border: 2px dashed #DA680C;
  border-radius: 14px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(184, 62, 0, 0.08);
  animation: fadeIn 0.3s ease-in-out;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Mini galeria do montador */
.quentinhas-mini-galeria {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}
.foto-card {
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  text-align: center;
}
.foto-card img {
  width: 100%;
  height: 72px;
  object-fit: cover;
  display: block;
}
.foto-card span {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--bordo);
  padding: 4px 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Main Grid */
.delivery-main { padding: 16px 0 40px; }
.order-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 820px) {
  .order-grid { grid-template-columns: 1.2fr 0.9fr; gap: 24px; align-items: start; }
}

/* Card Box */
.card-box {
  background: var(--white); border-radius: var(--radius); padding: 18px;
  margin-bottom: 18px; box-shadow: var(--shadow); border: 1px solid var(--line);
}
.card-box-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px; padding-bottom: 10px; border-bottom: 1px solid var(--line);
}
.card-box-header h2, .card-box-header h3 { font-size: 17px; font-weight: 800; color: var(--bordo); }
.badge-fixos {
  background: var(--cream); border: 1px solid var(--gold);
  color: var(--bordo-dark); font-size: 11px; font-weight: 700;
  padding: 3px 8px; border-radius: 12px;
}

/* Steps */
.step-group { margin-bottom: 16px; }
.step-label {
  display: flex; align-items: center; justify-content: space-between;
  font-weight: 700; font-size: 14px; margin-bottom: 8px; color: var(--ink);
}
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%; background: var(--bordo); color: #fff;
  font-size: 12px; margin-right: 6px;
}
.counter-pill { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; background: var(--sand); color: var(--ink-soft); }
.counter-pill.completo { background: #DCFCE7; color: var(--green); }

/* Option Cards (Carnes / Acompanhamentos) */
.options-grid { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 480px) {
  .options-grid { grid-template-columns: 1fr 1fr; }
}
.opt-label {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--cream); cursor: pointer; transition: all .15s ease;
  user-select: none;
}
.opt-label:hover { border-color: var(--bordo); background: #fff; }
.opt-label input[type="radio"], .opt-label input[type="checkbox"] {
  accent-color: var(--bordo); width: 17px; height: 17px; cursor: pointer;
}
.opt-label.selected {
  border-color: var(--bordo); background: var(--bordo-light);
  font-weight: 700; color: var(--bordo-dark);
}
.opt-label.esgotado {
  opacity: 0.5; pointer-events: none; text-decoration: line-through; background: #eee;
}
.opt-nome { font-size: 13.5px; }

/* Quentinhas Adicionadas */
.quentinha-item {
  display: flex; justify-content: space-between; align-items: center;
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 10px 12px; margin-bottom: 8px; font-size: 13px;
}
.q-desc { font-weight: 700; color: var(--bordo); }
.q-sub { color: var(--ink-soft); font-size: 12px; }
.btn-remover-q {
  background: none; border: none; color: #DC2626; cursor: pointer;
  font-size: 13px; font-weight: 700; padding: 4px 8px;
}

/* Sobremesas */
.sobremesa-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 0; border-bottom: 1px dashed var(--line);
}
.sobremesa-item:last-child { border-bottom: none; }
.sob-nome { font-weight: 600; font-size: 13.5px; }
.sob-preco { color: var(--bordo); font-weight: 700; font-size: 13px; }
.sob-controls { display: flex; align-items: center; gap: 8px; }
.btn-qty {
  width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line);
  background: #fff; font-weight: 800; cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.btn-qty:hover { background: var(--sand); }
.qty-val { font-weight: 700; font-size: 14px; min-width: 18px; text-align: center; }

/* Forms */
.form-group { margin-bottom: 12px; }
.form-group label { display: block; font-size: 12.5px; font-weight: 700; margin-bottom: 4px; color: var(--ink); }
.form-input, .form-select {
  width: 100%; padding: 10px 12px; border: 1.5px solid var(--line);
  border-radius: var(--radius-sm); font: inherit; font-size: 14px; background: #fff;
  transition: border .15s;
}
.form-input:focus, .form-select:focus { outline: none; border-color: var(--bordo); }
.form-row { display: flex; gap: 10px; }
.col-8 { flex: 2; }
.col-4 { flex: 1; }

/* Pagamento */
.payment-options { display: flex; flex-direction: column; gap: 8px; }
.pay-radio {
  display: block; cursor: pointer;
}
.pay-radio input { display: none; }
.pay-box {
  display: flex; flex-direction: column; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--cream); transition: all .15s;
}
.pay-radio input:checked + .pay-box {
  border-color: var(--bordo); background: var(--bordo-light);
}
.pay-title { font-weight: 700; font-size: 14px; color: var(--ink); }
.pay-desc { font-size: 11.5px; color: var(--ink-soft); }

/* Resumo */
.summary-box { background: #fff; border: 2px solid var(--bordo); }
.summary-line { display: flex; justify-content: space-between; font-size: 13.5px; margin-bottom: 6px; }
.summary-divider { margin: 10px 0; border: none; border-top: 1px dashed var(--line); }
.total-line { font-size: 17px; font-weight: 800; color: var(--bordo); }
.summary-hint { font-size: 11px; color: var(--ink-soft); text-align: center; margin-top: 10px; }
.error-msg {
  background: #FEE2E2; color: #991B1B; padding: 8px 12px;
  border-radius: var(--radius-sm); font-size: 13px; font-weight: 600;
  margin-bottom: 10px;
}

/* Botões */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 20px; border-radius: 30px; font: inherit; font-weight: 700;
  cursor: pointer; text-decoration: none; border: none; transition: all .15s;
}
.btn-block { width: 100%; }
.btn-primary { background: var(--bordo); color: #fff; box-shadow: 0 4px 14px rgba(107, 0, 0, 0.25); }
.btn-primary:hover { background: var(--bordo-dark); transform: translateY(-1px); }
.btn-primary:disabled { background: #ccc; cursor: not-allowed; box-shadow: none; transform: none; }
.btn-secondary { background: var(--sand); color: var(--bordo); border: 1.5px solid var(--bordo); }
.btn-secondary:hover:not(:disabled) { background: var(--bordo); color: #fff; }
.btn-secondary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-lg { font-size: 16px; padding: 14px 24px; }
.btn-outline { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.btn-outline:hover { background: var(--sand); }

/* Estados */
.state-box {
  background: #fff; border-radius: var(--radius); padding: 40px 20px;
  text-align: center; max-width: 540px; margin: 30px auto;
  box-shadow: var(--shadow); border: 1px solid var(--line);
}
.state-icon, .success-icon { font-size: 48px; margin-bottom: 12px; }
.spinner {
  width: 36px; height: 36px; border: 4px solid var(--line);
  border-top-color: var(--bordo); border-radius: 50%;
  animation: spin 0.8s linear infinite; margin: 0 auto 16px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Tela de Sucesso */
.success-title { font-size: 22px; font-weight: 800; color: var(--bordo); margin-bottom: 8px; }
.order-code-badge {
  display: inline-block; background: #DCFCE7; color: var(--green);
  font-size: 20px; font-weight: 800; padding: 6px 18px; border-radius: 20px;
  margin: 12px 0 16px; letter-spacing: 1px;
}
.success-msg { font-size: 14px; color: var(--ink-soft); margin-bottom: 20px; }
.success-details-box {
  background: var(--cream); border-radius: var(--radius-sm); padding: 16px;
  text-align: left; font-size: 13.5px; margin-bottom: 24px;
}
.success-actions { display: flex; flex-direction: column; gap: 10px; }

/* Footer */
.delivery-footer {
  background: var(--white); border-top: 1px solid var(--line);
  padding: 24px 0; text-align: center; font-size: 12.5px; color: var(--ink-soft);
}
.footer-copy { margin-top: 8px; font-size: 11.5px; }
