/* =========================================
   Pueblito Tacos — Shared Stylesheet
   ========================================= */

:root {
  --blue: #005f9e;    /* Brand primary */
  --accent: orange;   /* Accent for buttons/links */
  --text: #ffffff;    /* Base text color */
  --dark: #003e66;    /* Deep blue for UI elements */
}

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

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: 'Almarai', sans-serif;
  background-color: var(--blue);
  color: var(--text);
  text-align: center;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Global media defaults */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* =========================================
   Header & Branding
   ========================================= */

header {
  padding: 0.5em 1em 0.25em;
}

header h1 {
  font-family: 'Ranchers', cursive;
  font-size: 3em;
  margin: 0.5em 0 0.25em;
  line-height: 1.05;
}

/* Title with chef icons inline to the right */
.title-with-chefs {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
}

.title-with-chefs .chef-icon {
  height: 1em;    
  width: auto;
  display: inline-block;
}

/* Hero image under title (splash.png or truck1.png) */
header img {
  width: 35%;
  max-width: 720px;
  height: auto;
  margin: 0.35em auto 0.75em;
  border-radius: 8px;
}

/* Tagline under header image */
header p {
  font-size: 1.2em;
  margin-bottom: 1em;
}

/* =========================================
   Language Toggle
   ========================================= */

#language-toggle {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  gap: 8px;
  z-index: 50;
}

#language-toggle button {
  padding: 0.4em 0.8em;
  font-size: 0.95em;
  background-color: var(--dark);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 6px;
  cursor: pointer;
}

#language-toggle button:hover {
  background-color: #004d80;
}

/* =========================================
   Navigation
   ========================================= */

nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6em;
  padding: 0.5em 1em 1.2em;
}

nav button {
  padding: 0.7em 1.2em;
  font-size: 1em;
  background-color: var(--accent);
  color: #222;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 2px 0 rgba(0,0,0,0.15);
  transition: transform 120ms ease, box-shadow 120ms ease, opacity 120ms ease;
}

nav button:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

nav button:active {
  transform: translateY(0);
  opacity: 0.9;
}

/* =========================================
   Main Content
   ========================================= */

main {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem 2rem;
}

section h2 {
  font-family: 'Ranchers', cursive;
  letter-spacing: 0.5px;
  margin: 0.5em 0 0.25em;
  font-size: 2em;
}

/* =========================================
   Menu Images — Uniform Sizing (menu.html)
   ========================================= */

.menu-images {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  align-items: start;
  width: 100%;
  padding: 0.5em 1em 1.5em;
  gap: 1em;
}

.menu-images img {
  width: min(90vw, 420px);
  aspect-ratio: 3 / 4;
  height: auto;
  object-fit: cover;
  margin: 0 auto;
  border: 3px solid var(--text);
  border-radius: 10px;
  cursor: pointer;
  background: var(--dark);
}

.menu-images img:hover {
  filter: brightness(1.02) contrast(1.02);
}

/* =========================================
   Full-size Popup Viewer (menu.html)
   ========================================= */

#popup {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(2px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 10000;
  padding: 2vh 2vw;
}

#popup-img {
  max-width: 95vw;
  max-height: 90vh;
  width: auto;
  height: auto;
  border: 5px solid var(--text);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.55);
}

/* =========================================
   Transition Overlay (Spin + Shrink)
   ========================================= */

#transition-overlay {
  position: fixed;
  inset: 0;
  background: var(--blue);
  display: none; /* hidden by default */
  justify-content: center;
  align-items: center;
  z-index: 9999;
  flex-direction: column;
  pointer-events: none; /* prevent blocking nav when hidden */
}

#transition-overlay.active {
  display: flex;
  pointer-events: auto; /* block only when active */
}

#shrinking-circle {
  width: 100vw;
  height: 100vh;
  border-radius: 50%;
  background: var(--accent);
  animation: shrinkSpin 900ms ease-in forwards;
}

#taco-icon {
  font-size: 3em;
  opacity: 0;
  animation: fadeIn 950ms ease-in forwards;
  animation-delay: 750ms;
}

@keyframes shrinkSpin {
  0%   { transform: scale(1) rotate(0deg);      opacity: 1; }
  60%  { transform: scale(0.08) rotate(360deg); opacity: 0.8; }
  100% { transform: scale(0.02) rotate(540deg); opacity: 0; }
}

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

/* =========================================
   Footer
   ========================================= */

footer {
  padding: 0.5em 1em 1.75em;
}

footer p {
  font-size: 0.9em;
  line-height: 1.5;
}

footer a {
  color: var(--accent);
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

/* =========================================
   Responsive Adjustments
   ========================================= */

@media (max-width: 900px) {
  header h1 { font-size: 2.4em; }
}

@media (max-width: 600px) {
  header h1 { font-size: 2em; }
  nav button { font-size: 0.95em; padding: 0.6em 1em; }
  header img { width: 75%; }
}

main p {
  font-size: 1.1em;
  margin: 0.5em auto 1em;
  max-width: 800px;
  line-height: 1.5;
}

/* =========================================
   Optional: 2-column menu layout on very wide screens
----------------------------------------------
@media (min-width: 1100px) {
  .menu-images {
    grid-template-columns: repeat(2, minmax(0, 420px));
  }
}
---------------------------------------------- */
-height: 1.5;
}

/* =========================================
   Optional: 2-column menu layout on very wide screens
   Uncomment if you want side-by-side images on desktop.
   Keeps each item the same size due to fixed cap.
----------------------------------------------
@media (min-width: 1100px) {
  .menu-images {
    grid-template-columns: repeat(2, minmax(0, 420px));
  }
}
---------------------------------------------- */