/* Extra styles that Tailwind classes do not cover */

html { scroll-behavior: smooth; }

/* Big orange "plate" behind the hero text */
.plate {
  position: absolute;
  right: -140px;
  top: -120px;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ff7a3d 0%, #ff5b1f 55%, #e24a10 100%);
  box-shadow: inset 0 0 0 28px rgba(255, 243, 226, 0.08), inset 0 0 0 29px rgba(255, 243, 226, 0.25);
  animation: plateIn 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
@keyframes plateIn {
  from { transform: translate(60px, -40px) scale(0.85); opacity: 0; }
  to   { transform: none; opacity: 1; }
}
@media (max-width: 640px) { .plate { width: 300px; height: 300px; right: -120px; top: -90px; } }

/* "Surprise me" button */
.btn-random {
  align-items: center;
  justify-content: center;
  border: 2px solid #fff3e2;
  color: #fff3e2;
  border-radius: 9999px;
  padding: 0.6rem 1.3rem;
  font-weight: 600;
  background: transparent;
  transition: background 0.2s, color 0.2s;
}
.btn-random:hover, .btn-random:focus-visible { background: #fff3e2; color: #231f1c; outline: none; }

/* Category chips */
.chips { scrollbar-width: thin; scrollbar-color: #ff5b1f transparent; }
.chip {
  flex: none;
  border-radius: 9999px;
  border: 2px solid #231f1c;
  padding: 0.45rem 1.1rem;
  font-weight: 600;
  background: transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.chip:hover { background: #f6e1c0; }
.chip:focus-visible { outline: 3px solid #ff5b1f; outline-offset: 2px; }
.chip[aria-pressed="true"] { background: #ff5b1f; border-color: #ff5b1f; color: #fff; }

/* Meal cards */
.card {
  display: block;
  text-align: left;
  overflow: hidden;
  border-radius: 1.5rem;
  background: #fff;
  box-shadow: 0 1px 0 rgba(35, 31, 28, 0.08);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.card:hover, .card:focus-visible { transform: translateY(-6px); box-shadow: 0 18px 30px -14px rgba(35, 31, 28, 0.35); outline: none; }
.card:focus-visible { box-shadow: 0 0 0 4px #ff5b1f; }
.card img { transition: transform 0.5s ease; }
.card:hover img { transform: scale(1.07); }
.badge {
  display: inline-block;
  border-radius: 9999px;
  background: #ffe2d3;
  color: #b53a0a;
  padding: 0.2rem 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
}

/* Loading spinner */
.spinner {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 6px solid #f6e1c0;
  border-top-color: #ff5b1f;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Popup */
.modal { position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.modal.hidden { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(35, 31, 28, 0.7); backdrop-filter: blur(3px); animation: fade 0.2s ease both; }
.modal-panel {
  position: relative;
  width: 100%;
  max-width: 900px;
  max-height: 92vh;
  overflow-y: auto;
  border-radius: 1.75rem;
  background: #fff3e2;
  animation: pop 0.28s cubic-bezier(0.2, 0.9, 0.3, 1.1) both;
}
.modal-panel:focus { outline: none; }
.modal-close {
  position: absolute; top: 0.75rem; right: 0.9rem; z-index: 2;
  width: 2.5rem; height: 2.5rem; border-radius: 50%;
  background: #231f1c; color: #fff3e2; font-size: 1.6rem; line-height: 1; cursor: pointer;
}
.modal-close:hover { background: #ff5b1f; }
.modal-close:focus-visible { outline: 3px solid #ff5b1f; outline-offset: 2px; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: translateY(24px) scale(0.97); } to { opacity: 1; transform: none; } }

.ingredient { display: flex; justify-content: space-between; gap: 1rem; border-bottom: 1px dashed rgba(35, 31, 28, 0.25); padding: 0.45rem 0; }

/* Respect people who prefer less motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
