@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Outfit:wght@400;500;600;700&display=swap');

/* Traditional Mexican palette: #73020C #F2BE22 #F2A413 #BF6B04 #F25C05 */
:root {
  --ink: #2a0a0e;
  --muted: #6e4a3a;
  --paper: #faf3e6;
  --paper-deep: #f0e0c4;
  --leaf: #73020c;
  --leaf-deep: #520109;
  --ember: #f25c05;
  --ember-mid: #f2a413;
  --ember-deep: #bf6b04;
  --gold: #f2be22;
  --line: rgba(115, 2, 12, 0.14);
  --white: #fff8ee;
  --shadow: 0 18px 40px rgba(42, 10, 14, 0.12);
  --radius: 16px;
  --font-display: 'DM Serif Display', Georgia, serif;
  --font-body: 'Outfit', system-ui, sans-serif;
  --max: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(ellipse at 0% 0%, rgba(242, 92, 5, 0.16), transparent 42%),
    radial-gradient(ellipse at 100% 0%, rgba(242, 190, 34, 0.22), transparent 36%),
    linear-gradient(165deg, #fff8ee 0%, #faf0dc 55%, #f3e4c8 100%);
  min-height: 100vh;
  line-height: 1.55;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--leaf-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--ember-deep);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(14px);
  background: rgba(255, 248, 238, 0.92);
  border-bottom: 1px solid var(--line);
}

.site-header__inner,
.site-footer__inner,
.wrap {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
}

.brand {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.5vw, 1.85rem);
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand span {
  color: var(--ember);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1.1rem;
  align-items: center;
}

.nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
}

.nav a:hover,
.nav a.is-active {
  color: var(--ember-deep);
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--ember);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  margin-left: 0.25rem;
}

.hero {
  position: relative;
  overflow: hidden;
  max-height: 300px;
  display: grid;
  align-items: end;
  background:
    linear-gradient(
      180deg,
      rgba(115, 2, 12, 0.55) 0%,
      rgba(115, 2, 12, 0.72) 55%,
      rgba(42, 10, 14, 0.85) 100%
    ),
    linear-gradient(
      135deg,
      rgba(191, 107, 4, 0.25) 0%,
      transparent 50%,
      rgba(242, 92, 5, 0.2) 100%
    ),
    url("../img/hero-pattern.svg") center / cover no-repeat;
  color: var(--white);
}

.hero__inner {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.5rem 0 1.35rem;
  animation: rise 0.9s ease both;
}

.hero__brand {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 6vw, 3.25rem);
  line-height: 0.95;
  margin: 0 0 0.5rem;
  letter-spacing: -0.04em;
}

.hero__lead {
  max-width: 34rem;
  font-size: clamp(0.95rem, 1.6vw, 1.1rem);
  opacity: 0.92;
  margin: 0 0 0.9rem;
}

.hero__actions,
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.85rem 1.25rem;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--ember);
  color: #fff8ee;
  box-shadow: 0 10px 24px rgba(242, 92, 5, 0.32);
}

.btn-primary:hover {
  background: #d94f04;
  color: #fff8ee;
}

.btn-secondary {
  background: rgba(255, 248, 238, 0.14);
  color: white;
  border: 1px solid rgba(242, 190, 34, 0.45);
}

.btn-secondary:hover {
  background: rgba(242, 190, 34, 0.22);
  color: white;
}

.btn-ink {
  background: var(--leaf);
  color: white;
}

.btn-ink:hover {
  background: var(--leaf-deep);
  color: white;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}

.btn-small {
  padding: 0.55rem 0.9rem;
  font-size: 0.92rem;
}

.section {
  padding: 3.5rem 0;
}

.section__head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: end;
  margin-bottom: 1.5rem;
}

.section h2,
.page-title,
.meal-hero h1 {
  font-family: var(--font-display);
  letter-spacing: -0.03em;
  margin: 0;
  line-height: 1.1;
}

.section h2,
.page-title {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}

.lede {
  color: var(--muted);
  max-width: 38rem;
  margin: 0.5rem 0 0;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.step {
  padding: 1.25rem 1.3rem;
  border-radius: var(--radius);
  background: rgba(255, 248, 238, 0.72);
  border: 1px solid var(--line);
  animation: rise 0.7s ease both;
}

.step:nth-child(2) { animation-delay: 0.08s; }
.step:nth-child(3) { animation-delay: 0.16s; }

.step__num {
  font-family: var(--font-display);
  color: var(--ember);
  font-size: 1.4rem;
  margin-bottom: 0.35rem;
}

.step h3 {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
}

.step p {
  margin: 0;
  color: var(--muted);
}

.meal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.meal-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  text-decoration: none;
  color: inherit;
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(255, 248, 238, 0.88);
  border: 1px solid var(--line);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: rise 0.55s ease both;
}

.meal-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  color: inherit;
}

.meal-card__media {
  aspect-ratio: 4 / 3;
  background:
    linear-gradient(145deg, rgba(115, 2, 12, 0.22), rgba(242, 92, 5, 0.28)),
    repeating-linear-gradient(-35deg, transparent, transparent 10px, rgba(115, 2, 12, 0.04) 10px, rgba(115, 2, 12, 0.04) 11px);
  display: grid;
  place-items: center;
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 1.4rem;
}

.meal-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.meal-card__body {
  padding: 0.95rem 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.meal-card__cat {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--leaf);
  font-weight: 700;
}

.meal-card__body h3 {
  margin: 0;
  font-size: 1.12rem;
  line-height: 1.25;
}

.meal-card__actions {
  margin-top: auto;
  padding-top: 0.65rem;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.25rem;
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 248, 238, 0.8);
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
}

.chip:hover,
.chip.is-active {
  background: var(--leaf);
  border-color: var(--leaf);
  color: white;
}

.search-bar {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.search-bar input[type="search"],
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
input[type="number"],
input[type="password"],
input[type="file"],
textarea,
select {
  width: 100%;
  padding: 0.8rem 0.95rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--white);
  font: inherit;
  color: var(--ink);
}

.search-bar input[type="search"] {
  max-width: 320px;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.field {
  margin-bottom: 1rem;
}

.field-error {
  color: #73020c;
  font-size: 0.9rem;
  margin-top: 0.3rem;
}

.flash {
  padding: 0.85rem 1rem;
  border-radius: 12px;
  margin-bottom: 1rem;
  border: 1px solid var(--line);
}

.flash-success {
  background: rgba(242, 190, 34, 0.18);
  border-color: rgba(191, 107, 4, 0.35);
}

.flash-error {
  background: rgba(115, 2, 12, 0.08);
  border-color: rgba(115, 2, 12, 0.22);
}

.meal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 2rem;
  align-items: start;
}

.meal-hero__media {
  border-radius: 24px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background:
    linear-gradient(145deg, rgba(115, 2, 12, 0.28), rgba(242, 164, 19, 0.35)),
    var(--paper-deep);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--muted);
}

.meal-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.8rem 0 1rem;
}

.tag {
  font-size: 0.8rem;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: rgba(242, 190, 34, 0.22);
  color: var(--leaf-deep);
  font-weight: 700;
}

.site-footer {
  margin-top: 3rem;
  border-top: 1px solid var(--line);
  padding: 2rem 0 2.5rem;
  color: var(--muted);
}

.site-footer a {
  color: inherit;
}

.empty {
  padding: 2rem;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: rgba(255, 248, 238, 0.6);
  text-align: center;
  color: var(--muted);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 1rem;
}

.form-grid .full {
  grid-column: 1 / -1;
}

.selected-meals {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}

.selected-meals li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--line);
}

.admin-body {
  background: #f7ebda;
}

.admin-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  min-height: 100vh;
}

.admin-nav {
  background: #73020c;
  color: #fff8ee;
  padding: 1.5rem 1rem;
}

.admin-nav a {
  display: block;
  color: inherit;
  text-decoration: none;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  margin-bottom: 0.25rem;
}

.admin-nav a:hover,
.admin-nav a.is-active {
  background: rgba(242, 190, 34, 0.18);
  color: #f2be22;
}

.admin-nav__brand {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin: 0 0 1.5rem;
}

.admin-main {
  padding: 1.5rem;
}

.admin-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 248, 238, 0.88);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 0.75rem 0.9rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.status {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  background: rgba(42, 10, 14, 0.08);
}

.status-new { background: rgba(242, 92, 5, 0.18); color: #9a3a04; }
.status-contacted { background: rgba(242, 190, 34, 0.28); color: #7a5a08; }
.status-booked { background: rgba(191, 107, 4, 0.22); color: #6b3d02; }
.status-declined { background: rgba(115, 2, 12, 0.12); color: #73020c; }

.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat {
  padding: 1.2rem;
  border-radius: var(--radius);
  background: rgba(255, 248, 238, 0.9);
  border: 1px solid var(--line);
}

.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  line-height: 1;
  margin-bottom: 0.35rem;
}

.checkboxes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
}

.checkboxes label {
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.login-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
}

.login-card {
  width: min(420px, 100%);
  padding: 1.75rem;
  border-radius: 20px;
  background: rgba(255, 248, 238, 0.95);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 860px) {
  .steps,
  .meal-hero,
  .admin-shell,
  .form-grid,
  .stats {
    grid-template-columns: 1fr;
  }

  .admin-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    align-items: center;
  }

  .admin-nav__brand {
    width: 100%;
    margin-bottom: 0.5rem;
  }

  .hero__inner {
    padding-top: 1.25rem;
  }
}
