/* ============ Mozzafiato Ristorante ============ */
:root {
  --carbon: #2f2f2f;
  --carbon-2: #3c3c3c;
  --verde: #1f7a3a;
  --verde-claro: #e7f2ea;
  --rojo: #b3262e;
  --rojo-osc: #8f1d24;
  --crema: #faf6ef;
  --papel: #ffffff;
  --texto: #2a2522;
  --suave: #6e6560;
  --linea: #e6ddd0;
  --wa: #1fa855;
  --radio: 16px;
  --sombra: 0 6px 24px rgba(40, 25, 15, .10);
  --f-titulo: "Lobster", Georgia, serif;
  --f-texto: "Barlow", system-ui, sans-serif;
  --f-cond: "Barlow Condensed", "Barlow", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 130px; }
body {
  margin: 0;
  font-family: var(--f-texto);
  font-size: 17px;
  line-height: 1.5;
  color: var(--texto);
  background: var(--crema);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; }
h2 { font-family: var(--f-titulo); font-weight: 400; font-size: clamp(2.1rem, 5vw, 2.9rem); color: var(--carbon); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font: 600 1rem var(--f-texto);
  padding: .8em 1.4em; border-radius: 999px; border: 2px solid transparent;
  text-decoration: none; cursor: pointer; transition: transform .15s, background .15s, color .15s;
}
.btn:active { transform: scale(.97); }
.btn--red { background: var(--rojo); color: #fff; }
.btn--red:hover { background: var(--rojo-osc); }
.btn--ghost { border-color: var(--carbon); color: var(--carbon); background: transparent; }
.btn--ghost:hover { background: var(--carbon); color: #fff; }
.btn--wa { background: var(--wa); color: #fff; width: 100%; font-size: 1.05rem; }
.btn--wa:hover { background: #178a45; }
.btn:focus-visible, button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid #e0a106; outline-offset: 2px;
}

/* ---------- Barra superior ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 1.5rem;
  padding: .6rem clamp(16px, 4vw, 48px);
  background: var(--carbon);
  border-bottom: 4px solid var(--verde);
}
.topbar__logo img { height: 40px; width: auto; }
.topbar__nav { display: flex; gap: 1.4rem; margin-left: auto; }
.topbar__nav a {
  color: #fff; text-decoration: none; font: 500 1.05rem var(--f-cond); letter-spacing: .08em; text-transform: uppercase; opacity: .85;
}
.topbar__nav a:hover { opacity: 1; }
.cart-btn {
  display: inline-flex; align-items: center; gap: .5rem;
  background: var(--rojo); color: #fff; border: 0; border-radius: 999px;
  padding: .5rem 1rem; font: 600 .95rem var(--f-texto); cursor: pointer;
}
.cart-btn svg { width: 22px; height: 22px; }
.cart-btn__count {
  background: #fff; color: var(--rojo); border-radius: 999px; min-width: 1.5em; padding: 0 .4em; text-align: center; font-weight: 700;
}
.cart-btn.bump { animation: bump .35s; }
@keyframes bump { 50% { transform: scale(1.12); } }

/* ---------- Hero ---------- */
.hero {
  display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 2rem;
  max-width: 1200px; margin: 0 auto;
  padding: clamp(2rem, 6vw, 4.5rem) clamp(16px, 4vw, 48px);
}
.hero__logo { width: min(440px, 100%); height: auto; margin-bottom: 1.2rem; }
.hero h1 { font-size: clamp(1.9rem, 4.5vw, 3rem); font-weight: 700; color: var(--carbon); }
.hero h1 em { font-family: var(--f-titulo); font-style: normal; font-weight: 400; color: var(--rojo); }
.hero p { font-size: 1.1rem; color: var(--suave); max-width: 34em; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.6rem 0 1rem; }
.hero__note { font-size: .95rem !important; }
.hero__note::before { content: "⏱ "; }
.hero__plates { position: relative; aspect-ratio: 1 / 1; max-width: 520px; width: 100%; justify-self: center; }
.plate { position: absolute; border-radius: 50%; box-shadow: 0 18px 40px rgba(0,0,0,.25); border: 6px solid #fff; }
.plate--1 { width: 72%; top: 4%; left: 4%; }
.plate--2 { width: 44%; bottom: 2%; right: 0; }
.plate--3 { width: 34%; top: 0; right: 4%; }

.flag { display: flex; height: 8px; }
.flag span { flex: 1; }
.flag span:nth-child(1) { background: var(--verde); }
.flag span:nth-child(2) { background: #fff; }
.flag span:nth-child(3) { background: var(--rojo); }

/* ---------- Menú ---------- */
.menu { max-width: 1200px; margin: 0 auto; padding: clamp(2.5rem, 6vw, 4rem) clamp(16px, 4vw, 48px); }
.section-head { text-align: center; margin-bottom: 1.5rem; }
.section-head p { color: var(--suave); margin: 0 auto; max-width: 36em; }

.cats {
  position: sticky; top: 62px; z-index: 20;
  display: flex; gap: .5rem; overflow-x: auto; scrollbar-width: none;
  padding: .7rem clamp(16px, 4vw, 48px); margin: 0 calc(-1 * clamp(16px, 4vw, 48px)) 1rem;
  background: var(--crema);
}
.cats::-webkit-scrollbar { display: none; }
.cats a {
  flex: none; text-decoration: none; white-space: nowrap;
  font: 600 .95rem var(--f-texto);
  padding: .45rem 1rem; border-radius: 999px; border: 1.5px solid var(--linea); background: var(--papel);
}
.cats a.active { background: var(--carbon); color: #fff; border-color: var(--carbon); }

.cat { padding-top: 1.5rem; }
.cat__head { display: flex; align-items: baseline; flex-wrap: wrap; gap: .3rem 1rem; border-bottom: 2px solid var(--linea); margin-bottom: 1.2rem; }
.cat__head h3 { font-family: var(--f-titulo); font-weight: 400; font-size: 2rem; color: var(--carbon); margin: 0 0 .2rem; }
.cat__note { color: var(--suave); font-weight: 500; }
.cat__adult { font-size: .85rem; color: var(--rojo); font-weight: 600; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1rem; }
.item {
  display: flex; gap: 1rem; align-items: stretch;
  background: var(--papel); border-radius: var(--radio); padding: 1rem;
  box-shadow: var(--sombra); border: 1px solid #f0e8dc;
}
.item__img { flex: none; width: 96px; height: 96px; border-radius: 50%; object-fit: cover; align-self: center; }
.item__body { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.item__name { font-weight: 700; font-size: 1.1rem; margin: 0; }
.item__tag { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--verde); background: var(--verde-claro); padding: .1em .55em; border-radius: 6px; margin-left: .3em; vertical-align: 2px; }
.item__desc { color: var(--suave); font-size: .95rem; margin: .2rem 0 .6rem; }
.item__foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.item__price { font: 600 1.15rem var(--f-cond); color: var(--rojo); }
.item__price small { color: var(--suave); font-weight: 500; font-size: .85rem; }
.add {
  border: 0; background: var(--carbon); color: #fff; border-radius: 999px;
  font: 600 .92rem var(--f-texto); padding: .45rem 1rem; cursor: pointer;
}
.add:hover { background: var(--verde); }

/* ---------- Nosotros ---------- */
.about {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: center;
  max-width: 1100px; margin: 0 auto; padding: clamp(2.5rem, 6vw, 4rem) clamp(16px, 4vw, 48px);
}
.about__img img { border-radius: 50%; border: 8px solid #fff; box-shadow: var(--sombra); width: min(380px, 100%); margin: 0 auto; }
.about__lead { font-size: 1.25rem; font-weight: 600; color: var(--carbon); }
.about__lead em { font-family: var(--f-titulo); font-style: normal; font-weight: 400; color: var(--rojo); font-size: 1.2em; }
.badges { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.badges li { background: var(--verde-claro); color: var(--verde); font-weight: 600; padding: .35rem .9rem; border-radius: 999px; font-size: .95rem; }

/* ---------- Ubicación ---------- */
.visit {
  display: grid; grid-template-columns: 1fr 1.3fr; gap: 2rem; align-items: stretch;
  background: var(--carbon); color: #fff;
  padding: clamp(2.5rem, 6vw, 4rem) max(clamp(16px, 4vw, 48px), calc((100% - 1200px) / 2));
}
.visit h2 { color: #fff; }
.visit__addr { font-size: 1.2rem; }
.contact { list-style: none; padding: 0; margin: 1.2rem 0; display: grid; gap: .7rem; }
.contact a { display: inline-flex; align-items: center; gap: .7rem; text-decoration: none; font-weight: 500; cursor: pointer; }
.contact a:hover { text-decoration: underline; }
.apps { color: #cfcfcf; }
.visit__map iframe { width: 100%; height: 100%; min-height: 300px; border: 0; border-radius: var(--radio); }

.ic { display: inline-block; width: 22px; height: 22px; flex: none; background: currentColor; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.ic--wa { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 0 0-8.6 15.1L2 22l5-1.3A10 10 0 1 0 12 2zm5.8 14.2c-.2.7-1.4 1.3-2 1.4-.5.1-1.2.1-1.9-.1a17 17 0 0 1-1.7-.6 13.4 13.4 0 0 1-5.2-4.6c-.4-.5-1.2-1.7-1.2-3.2 0-1.5.8-2.3 1.1-2.6.3-.3.6-.4.8-.4h.6c.2 0 .4 0 .7.5l1 2.3c.1.2.1.4 0 .6l-.3.5-.5.5c-.1.2-.3.3-.1.6.2.3.8 1.3 1.6 2.1 1.1 1 2 1.3 2.3 1.4.3.1.5.1.6-.1l.9-1.1c.2-.3.4-.2.7-.1l2.2 1c.3.2.5.2.6.4 0 .1 0 .8-.2 1.5z'/%3E%3C/svg%3E"); }
.ic--tel { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.6 10.8a15 15 0 0 0 6.6 6.6l2.2-2.2c.3-.3.7-.4 1-.2 1.1.4 2.3.6 3.6.6.6 0 1 .4 1 1V20c0 .6-.4 1-1 1A17 17 0 0 1 3 4c0-.6.4-1 1-1h3.5c.6 0 1 .4 1 1 0 1.3.2 2.5.6 3.6.1.3 0 .7-.2 1z'/%3E%3C/svg%3E"); }
.ic--ig { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 2h10a5 5 0 0 1 5 5v10a5 5 0 0 1-5 5H7a5 5 0 0 1-5-5V7a5 5 0 0 1 5-5zm0 2a3 3 0 0 0-3 3v10a3 3 0 0 0 3 3h10a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3zm5 3.5a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9zm0 2a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM17.5 5.5a1 1 0 1 1 0 2 1 1 0 0 1 0-2z'/%3E%3C/svg%3E"); }
.ic--fb { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M14 8V6c0-.8.2-1.3 1.4-1.3H17V1.2C16.6 1.1 15.5 1 14.3 1 11.7 1 10 2.6 10 5.4V8H7v3.6h3V23h4V11.6h3l.5-3.6z'/%3E%3C/svg%3E"); }

/* ---------- Footer ---------- */
.footer { text-align: center; padding: 2.5rem 16px 6rem; color: var(--suave); }
.footer img { height: 44px; width: auto; margin: 0 auto 1rem; }
.footer p { margin: .2rem 0; }
.footer__small { font-size: .85rem; }

/* ---------- Carrito flotante (celular) ---------- */
.floating-cart {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 25;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  background: var(--rojo); color: #fff; border: 0; border-radius: 14px;
  padding: .95rem 1.2rem; font: 500 1rem var(--f-texto); cursor: pointer;
  box-shadow: 0 10px 30px rgba(179, 38, 46, .4);
}
.floating-cart[hidden] { display: none; }

/* ---------- Modal de opciones ---------- */
.modal { border: 0; padding: 0; border-radius: 20px; width: min(460px, calc(100% - 32px)); box-shadow: 0 30px 80px rgba(0,0,0,.35); }
.modal::backdrop { background: rgba(20, 15, 10, .55); }
.modal__box { padding: 1.5rem; position: relative; }
.modal__box h3 { font-family: var(--f-titulo); font-weight: 400; font-size: 1.8rem; margin-right: 2rem; }
.modal__desc { color: var(--suave); margin-top: -.3rem; }
.modal__close { position: absolute; top: .8rem; right: .8rem; width: 36px; height: 36px; border-radius: 50%; border: 0; background: #f1ebe2; font-size: 1.5rem; line-height: 1; cursor: pointer; }
.drawer__head .modal__close { position: static; }
.opt-group { border: 0; padding: 0; margin: 0 0 1rem; }
.opt-group legend { font-weight: 700; margin-bottom: .4rem; }
.opt { display: flex; justify-content: space-between; align-items: center; gap: .6rem; padding: .65rem .9rem; border: 1.5px solid var(--linea); border-radius: 12px; margin-bottom: .4rem; cursor: pointer; }
.opt:has(input:checked) { border-color: var(--verde); background: var(--verde-claro); }
.opt span:first-of-type { flex: 1; }
.opt input { accent-color: var(--verde); width: 18px; height: 18px; }
.opt b { font-family: var(--f-cond); color: var(--rojo); }
.field { display: grid; gap: .3rem; margin-bottom: .9rem; font-weight: 600; font-size: .95rem; }
.field input, .field select, .field textarea {
  font: 400 1rem var(--f-texto); padding: .7rem .8rem; border: 1.5px solid var(--linea); border-radius: 10px; background: #fff; width: 100%;
}
.modal__foot { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: .5rem; }
.modal__foot .btn { flex: 1; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--linea); border-radius: 999px; }
.qty button { width: 38px; height: 38px; border: 0; background: none; font-size: 1.3rem; cursor: pointer; border-radius: 50%; }
.qty output { min-width: 1.6em; text-align: center; font-weight: 700; }
.qty--sm button { width: 30px; height: 30px; font-size: 1.1rem; }

/* ---------- Cajón del carrito ---------- */
.drawer { position: fixed; inset: 0; z-index: 40; visibility: hidden; }
.drawer::before { content: ""; position: absolute; inset: 0; background: rgba(20, 15, 10, .5); opacity: 0; transition: opacity .25s; }
.drawer.open { visibility: visible; }
.drawer.open::before { opacity: 1; }
.drawer__panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(440px, 100%);
  display: flex; flex-direction: column; background: var(--crema);
  transform: translateX(100%); transition: transform .28s ease;
}
.drawer.open .drawer__panel { transform: none; }
.drawer__head { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.2rem; background: var(--carbon); color: #fff; }
.drawer__head h3 { font-family: var(--f-titulo); font-weight: 400; font-size: 1.7rem; margin: 0; }
.drawer__body { flex: 1; overflow-y: auto; padding: 1rem 1.2rem; }
.drawer__foot { padding: 1rem 1.2rem 1.2rem; border-top: 1px solid var(--linea); background: #fff; }
.total { display: flex; justify-content: space-between; font-size: 1.25rem; font-weight: 700; }
.drawer__hint { font-size: .85rem; color: var(--suave); margin: .2rem 0 .8rem; }
.lines { list-style: none; padding: 0; margin: 0 0 1rem; }
.line { display: grid; grid-template-columns: 1fr auto; gap: .3rem .8rem; padding: .8rem 0; border-bottom: 1px dashed var(--linea); }
.line__name { font-weight: 700; }
.line__det { grid-column: 1; color: var(--suave); font-size: .9rem; }
.line__price { font-family: var(--f-cond); font-weight: 600; color: var(--rojo); font-size: 1.1rem; text-align: right; }
.line__ctrl { grid-column: 2; display: flex; justify-content: flex-end; }
.empty { text-align: center; color: var(--suave); padding: 2rem 0; }
.seg { border: 0; padding: 0; margin: 0 0 1rem; display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
.seg legend { font-weight: 700; margin-bottom: .4rem; }
.seg label span { display: block; text-align: center; padding: .65rem; border: 1.5px solid var(--linea); border-radius: 10px; font-weight: 600; cursor: pointer; background: #fff; }
.seg input { position: absolute; opacity: 0; }
.seg input:checked + span { background: var(--carbon); color: #fff; border-color: var(--carbon); }
.seg input:focus-visible + span { outline: 3px solid #e0a106; }
.btn--loc { background: var(--verde-claro); color: var(--verde); border-color: var(--verde); width: 100%; margin-bottom: .2rem; }
.btn--loc:hover { background: var(--verde); color: #fff; }
.field__help { font-weight: 400; color: var(--suave); font-size: .82rem; }
.field__help.ok { color: var(--verde); font-weight: 600; }
.form-error { color: var(--rojo); font-weight: 600; min-height: 1em; margin: 0; }

.toast {
  position: fixed; left: 50%; bottom: 90px; z-index: 50; transform: translate(-50%, 20px);
  background: var(--carbon); color: #fff; padding: .7rem 1.2rem; border-radius: 999px; font-weight: 600;
  opacity: 0; pointer-events: none; transition: .25s; max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Responsivo ---------- */
@media (max-width: 860px) {
  .topbar__nav { display: none; }
  .topbar .cart-btn { margin-left: auto; }
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero p { margin-left: auto; margin-right: auto; }
  .hero__logo { margin: 0 auto 1rem; }
  .hero__cta { justify-content: center; }
  .hero__plates { max-width: 300px; }
  .about, .visit { grid-template-columns: 1fr; }
  .about { text-align: center; }
  .badges { justify-content: center; }
}
@media (max-width: 480px) {
  body { font-size: 16px; }
  .cart-btn__label { display: none; }
  .topbar__logo img { height: 32px; }
  .grid { grid-template-columns: 1fr; }
  .item__img { width: 76px; height: 76px; }
  .hero__cta .btn { width: 100%; }
}
@media (min-width: 861px) { .floating-cart { display: none !important; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; scroll-behavior: auto !important; } }
