/* ==========================================================================
   FRATELLO RESTAURANT — LUXURY DIGITAL MENU BOOK
   Visual Source of Truth: Authentic Fratello Printed Menu
   ========================================================================== */

/* --- 1. CSS VARIABLES & DESIGN SYSTEM --- */
:root {
  --black-base: #060606;
  --black-leather: #0b0a09;
  --black-page: #0d0c0a;
  --black-card: #12110e;
  --black-trans: rgba(8, 8, 8, 0.88);

  --gold-pure: #d4af37;
  --gold-warm: #cba238;
  --gold-dark: #8c6e1e;
  --gold-darker: #5b4712;
  --gold-light: #f5e4a8;
  --gold-bright: #ffe89e;
  --gold-glow: rgba(212, 175, 55, 0.22);
  --gold-border: rgba(212, 175, 55, 0.55);
  --gold-border-dim: rgba(212, 175, 55, 0.25);

  --cream-pure: #f8f3e8;
  --cream-soft: #eee5d3;
  --cream-dim: #c5bba6;
  --muted-gold: #9d8c6b;
  --text-muted: #8b8070;

  --font-serif-luxury: 'Cormorant Garamond', 'Playfair Display', Garamond, Georgia, serif;
  --font-serif-classic: 'Cinzel', 'Times New Roman', serif;
  --font-sans-subtle: 'Montserrat', 'Jost', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --shadow-page: 0 15px 45px rgba(0, 0, 0, 0.85);
  --shadow-gold: 0 4px 20px rgba(212, 175, 55, 0.15);
  --shadow-inset-page: inset 0 0 80px rgba(0, 0, 0, 0.7);

  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);

  --page-turn-duration: 650ms;
}

/* --- 2. RESET & BASE --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  width: 100%;
  height: 100%;
  height: -webkit-fill-available;
}

body {
  width: 100%;
  height: 100%;
  min-height: 100vh;
  min-height: 100svh;
  min-height: 100lvh;
  min-height: 100dvh;
  height: 100dvh;
  background-color: #060504;
  background-image:
    radial-gradient(ellipse 70% 55% at 50% 48%, rgba(38, 30, 18, 0.45) 0%, rgba(14, 12, 9, 0.92) 65%, #050403 100%),
    url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.02'/%3E%3C/svg%3E");
  background-attachment: fixed;
  color: var(--cream-soft);
  font-family: var(--font-serif-luxury);
  line-height: 1.5;
  margin: 0;
  padding: 0;
  overflow: hidden;
  touch-action: pan-x;
  overscroll-behavior: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

/* Accessible hidden element */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* ==========================================================================
   3. LOADING EXPERIENCE (Target ~2.2s branded sequence)
   ========================================================================== */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background: radial-gradient(circle at center, #15130f 0%, #060606 80%);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.85s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.85s ease;
  pointer-events: all;
}

#preloader.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-content {
  text-align: center;
  max-width: 380px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.loader-logo-wrap {
  width: 240px;
  max-width: 80vw;
  margin-bottom: 24px;
  opacity: 0;
  transform: translateY(8px) scale(0.96);
  animation: loaderLogoReveal 1s cubic-bezier(0.25, 1, 0.5, 1) 0.25s forwards;
}

.loader-logo-wrap img {
  width: 100%;
  filter: drop-shadow(0 4px 15px rgba(212, 175, 55, 0.3));
}

.loader-ornament {
  width: 90px;
  height: 18px;
  margin-bottom: 20px;
  opacity: 0;
  animation: loaderFadeIn 0.8s ease 0.65s forwards;
}

.loader-bar-track {
  width: 200px;
  height: 1.5px;
  background: rgba(212, 175, 55, 0.15);
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}

.loader-bar-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-light), var(--gold-warm));
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.7);
  transition: width 1.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.loader-subtitle {
  font-family: var(--font-serif-classic);
  font-size: 0.68rem;
  letter-spacing: 0.35em;
  color: var(--muted-gold);
  margin-top: 16px;
  text-transform: uppercase;
  opacity: 0;
  animation: loaderFadeIn 0.8s ease 0.8s forwards;
}

@keyframes loaderLogoReveal {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes loaderFadeIn {
  to {
    opacity: 1;
  }
}

/* ==========================================================================
   4. APP CONTAINER & BRAND HEADER
   ========================================================================== */
.app-container {
  width: 100%;
  max-width: 1200px;
  height: 100%;
  height: 100vh;
  height: 100svh;
  height: 100lvh;
  height: 100dvh;
  max-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  position: relative;
  padding-top: max(var(--safe-top), 4px);
  padding-bottom: max(var(--safe-bottom), 4px);
  padding-left: max(var(--safe-left), 8px);
  padding-right: max(var(--safe-right), 8px);
  box-sizing: border-box;
  overflow: hidden;
}

/* Global Top Navigation Bar */
.top-brand-bar {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px;
  margin-bottom: 6px;
  z-index: 50;
  gap: 12px;
  flex-shrink: 0;
}

.brand-crest-small {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.brand-crest-small:hover,
.brand-crest-small:focus-visible {
  opacity: 0.9;
  transform: translateY(-1px);
}

.brand-logo-nav {
  height: 42px;
  width: 42px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 2px 8px rgba(212, 175, 55, 0.45));
  transition: transform 0.25s ease;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-luxury-sm {
  font-family: var(--font-serif-classic);
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-light);
  border: 1px solid var(--gold-border-dim);
  padding: 6px 12px;
  border-radius: 2px;
  background: rgba(18, 16, 12, 0.85);
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.btn-luxury-sm:hover,
.btn-luxury-sm:focus-visible {
  border-color: var(--gold-warm);
  color: var(--gold-bright);
  box-shadow: 0 0 14px var(--gold-glow);
  transform: translateY(-1px);
}

/* ==========================================================================
   5. LUXURY 3D BOOK STAGE & SCENE (Expansive & Full Screen Optimized)
   ========================================================================== */
.book-stage {
  perspective: 2400px;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 1;
  min-height: 0;
  position: relative;
  padding: 2px 0 4px;
}

.book-wrapper {
  position: relative;
  width: 100%;
  max-width: 820px;
  height: 100%;
  max-height: 880px;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1), max-width 0.4s ease;
  box-shadow:
    0 1px 0 #1c1913,
    0 2px 0 #12100c,
    0 3px 0 #18150f,
    0 4px 0 #0f0d09,
    0 25px 65px rgba(0, 0, 0, 0.95);
}

/* Simulated 300gsm Paper Stack Edges */
.book-stack-edge {
  position: absolute;
  pointer-events: none;
  z-index: 2;
}

.book-stack-edge.right {
  top: 6px;
  bottom: 6px;
  right: -7px;
  width: 7px;
  background: repeating-linear-gradient(
    90deg,
    #201c15 0px,
    #201c15 1px,
    #14120e 1px,
    #14120e 2px
  );
  box-shadow: 4px 0 12px rgba(0, 0, 0, 0.85);
  border-radius: 0 3px 3px 0;
  border-right: 1px solid rgba(212, 175, 55, 0.28);
}

.book-stack-edge.left {
  display: none;
  top: 6px;
  bottom: 6px;
  left: -7px;
  width: 7px;
  background: repeating-linear-gradient(
    90deg,
    #14120e 0px,
    #14120e 1px,
    #201c15 1px,
    #201c15 2px
  );
  box-shadow: -4px 0 12px rgba(0, 0, 0, 0.85);
  border-radius: 3px 0 0 3px;
  border-left: 1px solid rgba(212, 175, 55, 0.28);
}

/* Central Spine Crease with Antique Leather Binding & Shadow */
.book-spine-crease {
  display: none;
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(50% - 18px);
  width: 36px;
  z-index: 45;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.55) 25%,
    rgba(0, 0, 0, 0.95) 47%,
    rgba(25, 20, 14, 0.9) 50%,
    rgba(0, 0, 0, 0.95) 53%,
    rgba(0, 0, 0, 0.55) 75%,
    rgba(0, 0, 0, 0) 100%
  );
}

.book-spine-crease::before,
.book-spine-crease::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 6px;
  height: 14px;
  background: radial-gradient(circle, var(--gold-warm) 0%, var(--gold-dark) 70%, #000 100%);
  border-radius: 2px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.9);
}

.book-spine-crease::before { top: 6px; }
.book-spine-crease::after { bottom: 6px; }

@media (min-width: 992px) {
  .book-stage {
    padding: 2px 20px 4px;
  }

  .book-wrapper {
    max-width: 1260px;
    width: 96%;
    height: 100%;
    max-height: 860px;
    padding: 3px;
    background: #0a0907;
    border-radius: 4px;
    box-shadow:
      0 0 0 1px rgba(212, 175, 55, 0.35),
      0 2px 0 #1c1913,
      0 4px 0 #12100c,
      0 6px 0 #18150f,
      0 8px 0 #0f0d09,
      0 28px 75px rgba(0, 0, 0, 0.95),
      0 8px 25px rgba(0, 0, 0, 0.85);
  }

  .book-stack-edge.left {
    display: block;
  }

  .book-spine-crease.spine-visible {
    display: block;
  }
}

@media (max-width: 991px) {
  .book-spine-crease,
  .book-spine-crease.spine-visible {
    display: none !important;
  }
}

@media (min-width: 1380px) {
  .book-wrapper {
    max-width: 1380px;
    max-height: 890px;
  }
}

@media (min-width: 1750px) {
  .book-wrapper {
    max-width: 1540px;
    max-height: 930px;
  }
}

/* When in Native Fullscreen */
:fullscreen .book-wrapper,
:-webkit-full-screen .book-wrapper {
  max-width: 1580px;
  max-height: 93vh;
}

/* ==========================================================================
   6. PHYSICAL CLOSED COVER
   ========================================================================== */
.menu-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-color: #0b0907;
  background-image:
    radial-gradient(circle at 50% 30%, #17140e 0%, #080705 85%),
    url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
  border-radius: 4px;
  box-shadow:
    0 25px 60px rgba(0, 0, 0, 0.9),
    0 5px 15px rgba(0, 0, 0, 0.7),
    inset 0 0 60px rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 36px 28px;
  z-index: 200;
  transform-origin: left center;
  transform-style: preserve-3d;
  transition: transform 0.85s cubic-bezier(0.25, 1, 0.45, 1), opacity 0.35s ease 0.5s;
  backface-visibility: hidden;
  user-select: none;
}

.menu-cover.cover-opened {
  transform: rotateY(-130deg);
  pointer-events: none;
  opacity: 0;
}

.cover-frame-outer {
  position: absolute;
  inset: 14px;
  border: 1px solid var(--gold-border);
  pointer-events: none;
  border-radius: 2px;
}

.cover-frame-inner {
  position: absolute;
  inset: 20px;
  border: 1px solid var(--gold-border-dim);
  pointer-events: none;
}

.botanical-corner {
  position: absolute;
  width: 54px;
  height: 54px;
  pointer-events: none;
  z-index: 10;
  background-repeat: no-repeat;
  background-size: contain;
}

.botanical-corner.top-left {
  top: 10px;
  left: 10px;
  background-image: url('../assets/deco/corner-botanical.png');
}

.botanical-corner.top-right {
  top: 10px;
  right: 10px;
  background-image: url('../assets/deco/corner-botanical.png');
  transform: scaleX(-1);
}

.botanical-corner.bottom-left {
  bottom: 10px;
  left: 10px;
  background-image: url('../assets/deco/corner-botanical.png');
  transform: scaleY(-1);
}

.botanical-corner.bottom-right {
  bottom: 10px;
  right: 10px;
  background-image: url('../assets/deco/corner-botanical.png');
  transform: scale(-1, -1);
}

.cover-header-tag {
  font-family: var(--font-serif-classic);
  font-size: 0.68rem;
  letter-spacing: 0.32em;
  color: var(--muted-gold);
  text-transform: uppercase;
  margin-top: 8px;
  text-align: center;
}

.cover-main-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 420px;
  width: 100%;
}

.cover-logo-img {
  width: 270px;
  max-width: 80%;
  filter: drop-shadow(0 6px 20px rgba(212, 175, 55, 0.45));
  margin-bottom: 20px;
}

.cover-book-title {
  font-family: var(--font-serif-classic);
  font-size: 1.15rem;
  letter-spacing: 0.28em;
  color: var(--gold-light);
  text-transform: uppercase;
  margin-bottom: 10px;
  font-weight: 500;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.cover-divider-flourish {
  width: 110px;
  height: 14px;
  margin-bottom: 14px;
}

.cover-description {
  font-family: var(--font-serif-luxury);
  font-size: 1.02rem;
  font-style: italic;
  color: var(--cream-dim);
  line-height: 1.55;
  max-width: 320px;
  margin-bottom: 22px;
}

.btn-open-menu {
  font-family: var(--font-serif-classic);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-bright);
  background: linear-gradient(135deg, rgba(35, 30, 20, 0.9), rgba(15, 12, 8, 0.95));
  border: 1px solid var(--gold-border);
  padding: 11px 28px;
  border-radius: 2px;
  box-shadow:
    0 6px 20px rgba(0, 0, 0, 0.6),
    inset 0 0 12px rgba(212, 175, 55, 0.15);
  transition: all 0.35s cubic-bezier(0.25, 1, 0.5, 1);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
}

.btn-open-menu:hover,
.btn-open-menu:focus-visible {
  border-color: var(--gold-bright);
  color: #fff;
  box-shadow:
    0 8px 25px rgba(212, 175, 55, 0.35),
    inset 0 0 20px rgba(212, 175, 55, 0.3);
  transform: translateY(-2px);
}

.cover-footer {
  font-family: var(--font-serif-classic);
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  color: var(--muted-gold);
  text-align: center;
}

/* ==========================================================================
   7. REAL PHYSICAL MENU BOOK SPREAD & EMBOSSED UNDERSIDE
   ========================================================================== */
.menu-book {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 4px;
  transform-style: preserve-3d;
  background: var(--black-base);
  box-shadow: var(--shadow-page);
  display: none;
}

.menu-book.book-active {
  display: block;
}

.menu-page {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  display: none;
  box-sizing: border-box;
}

/* Mobile Single-Page Display */
.menu-page.active-page {
  display: block;
  z-index: 10;
}

.menu-page.flipping-next {
  display: block;
  z-index: 30;
  transform-origin: left center;
  animation: pageFlipForwardMobile var(--page-turn-duration) cubic-bezier(0.25, 1, 0.45, 1) forwards;
}

.menu-page.flipping-prev {
  display: block;
  z-index: 30;
  transform-origin: left center;
  animation: pageFlipBackwardMobile var(--page-turn-duration) cubic-bezier(0.25, 1, 0.45, 1) forwards;
}

/* Mobile Flip Keyframes with Dynamic Peak Shadow & Curvature */
@keyframes pageFlipForwardMobile {
  0% {
    transform: rotateY(0deg) skewY(0deg);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
  }
  30% {
    transform: rotateY(-50deg) skewY(-2deg) scale(0.99);
    box-shadow: -15px 15px 35px rgba(0, 0, 0, 0.75);
  }
  50% {
    transform: rotateY(-90deg) skewY(-3deg) scale(0.97);
    box-shadow: -35px 25px 65px rgba(0, 0, 0, 0.95), 0 0 35px rgba(0, 0, 0, 0.85);
  }
  70% {
    transform: rotateY(-130deg) skewY(-2deg) scale(0.99);
    box-shadow: -15px 15px 35px rgba(0, 0, 0, 0.75);
  }
  100% {
    transform: rotateY(-180deg) skewY(0deg) scale(1);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
  }
}

@keyframes pageFlipBackwardMobile {
  0% {
    transform: rotateY(-180deg) skewY(0deg);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
  }
  30% {
    transform: rotateY(-130deg) skewY(2deg) scale(0.99);
    box-shadow: 15px 15px 35px rgba(0, 0, 0, 0.75);
  }
  50% {
    transform: rotateY(-90deg) skewY(3deg) scale(0.97);
    box-shadow: 35px 25px 65px rgba(0, 0, 0, 0.95), 0 0 35px rgba(0, 0, 0, 0.85);
  }
  70% {
    transform: rotateY(-50deg) skewY(2deg) scale(0.99);
    box-shadow: 15px 15px 35px rgba(0, 0, 0, 0.75);
  }
  100% {
    transform: rotateY(0deg) skewY(0deg) scale(1);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
  }
}

/* Front Face of the Page */
.page-front {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-color: var(--black-page);
  background-image:
    radial-gradient(circle at 50% 15%, #18150f 0%, #090806 80%),
    radial-gradient(circle at 50% 90%, #120f09 0%, #070605 90%);
  border-radius: 3px;
  overflow: hidden;
  box-shadow: var(--shadow-page), var(--shadow-inset-page);
  display: flex;
  flex-direction: column;
  padding: 20px 22px 26px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  z-index: 2;
  transform: rotateY(0deg);
}

/* Realistic Embossed Paper Underside with Fratello Watermark */
.page-underside {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-color: #0c0a08;
  background-image:
    radial-gradient(circle at 50% 50%, #16130e 0%, #070605 85%),
    url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.035'/%3E%3C/svg%3E");
  border-radius: 3px;
  box-shadow:
    inset 0 0 60px rgba(0, 0, 0, 0.9),
    0 10px 30px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transform: rotateY(180deg);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  pointer-events: none;
  user-select: none;
  z-index: 1;
}

.underside-border-outer {
  position: absolute;
  inset: 12px;
  border: 1px solid var(--gold-border);
  border-radius: 2px;
  pointer-events: none;
}

.underside-border-inner {
  position: absolute;
  inset: 18px;
  border: 1px solid var(--gold-border-dim);
  pointer-events: none;
}

.underside-crease-shadow {
  position: absolute;
  top: 0;
  bottom: 0;
  right: 0;
  width: 30px;
  background: linear-gradient(90deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.85) 100%);
  pointer-events: none;
}

.underside-watermark-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0.52;
  text-align: center;
  padding: 20px;
}

.underside-watermark-crest {
  width: 85px;
  height: auto;
  filter: drop-shadow(0 2px 8px rgba(212, 175, 55, 0.4));
  margin-bottom: 12px;
}

.underside-flourish {
  margin-bottom: 8px;
}

.underside-watermark-title {
  font-family: var(--font-serif-classic);
  font-size: 0.8rem;
  letter-spacing: 0.32em;
  color: var(--gold-light);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.underside-watermark-sub {
  font-family: var(--font-serif-luxury);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  font-style: italic;
  color: var(--muted-gold);
  text-transform: uppercase;
}

/* Desktop Two-Page Open Spread Mechanics (>= 992px) */
@media (min-width: 992px) {
  .menu-page {
    width: 50%;
    height: 100%;
    top: 0;
    bottom: 0;
    inset: auto;
  }

  .menu-page.spread-left {
    left: 0;
    right: auto;
  }

  .menu-page.spread-left .page-front {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    box-shadow: inset -22px 0 35px rgba(0, 0, 0, 0.75), var(--shadow-page);
  }

  .menu-page.spread-right {
    left: 50%;
    right: auto;
    transform-origin: left center;
  }

  .menu-page.spread-right .page-front {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    box-shadow: inset 22px 0 35px rgba(0, 0, 0, 0.75), var(--shadow-page);
  }

  .menu-page.active-spread-page {
    display: block;
    z-index: 10;
  }

  .menu-page.flipping-spread-forward {
    display: block;
    z-index: 35;
    transform-origin: left center;
    animation: pageFlipForwardSpread var(--page-turn-duration) cubic-bezier(0.25, 1, 0.45, 1) forwards;
  }

  .menu-page.flipping-spread-backward {
    display: block;
    z-index: 35;
    transform-origin: left center;
    animation: pageFlipBackwardSpread var(--page-turn-duration) cubic-bezier(0.25, 1, 0.45, 1) forwards;
  }
}

@keyframes pageFlipForwardSpread {
  0% {
    transform: rotateY(0deg) skewY(0deg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  }
  30% {
    transform: rotateY(-50deg) skewY(-2deg) scale(0.99);
    box-shadow: -15px 15px 35px rgba(0, 0, 0, 0.7);
  }
  50% {
    transform: rotateY(-90deg) skewY(-3deg) scale(0.97);
    box-shadow: -35px 25px 65px rgba(0, 0, 0, 0.95), 0 0 40px rgba(0, 0, 0, 0.85);
  }
  70% {
    transform: rotateY(-130deg) skewY(-2deg) scale(0.99);
    box-shadow: -20px 15px 45px rgba(0, 0, 0, 0.75);
  }
  100% {
    transform: rotateY(-180deg) skewY(0deg) scale(1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  }
}

@keyframes pageFlipBackwardSpread {
  0% {
    transform: rotateY(-180deg) skewY(0deg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  }
  30% {
    transform: rotateY(-130deg) skewY(2deg) scale(0.99);
    box-shadow: 20px 15px 45px rgba(0, 0, 0, 0.75);
  }
  50% {
    transform: rotateY(-90deg) skewY(3deg) scale(0.97);
    box-shadow: 35px 25px 65px rgba(0, 0, 0, 0.95), 0 0 40px rgba(0, 0, 0, 0.85);
  }
  70% {
    transform: rotateY(-50deg) skewY(2deg) scale(0.99);
    box-shadow: 15px 15px 35px rgba(0, 0, 0, 0.7);
  }
  100% {
    transform: rotateY(0deg) skewY(0deg) scale(1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  }
}

.page-spine {
  position: absolute;
  top: 0;
  left: 0;
  width: 20px;
  height: 100%;
  background: linear-gradient(90deg, rgba(0,0,0,0.8) 0%, rgba(20,18,12,0.3) 40%, rgba(0,0,0,0) 100%);
  pointer-events: none;
  z-index: 40;
}

.page-border-outer {
  position: absolute;
  inset: 10px;
  border: 1px solid var(--gold-border);
  pointer-events: none;
  z-index: 5;
  border-radius: 2px;
}

.page-border-inner {
  position: absolute;
  inset: 15px;
  border: 1px solid var(--gold-border-dim);
  pointer-events: none;
  z-index: 5;
}

.page-brand-header {
  text-align: center;
  margin-bottom: 8px;
  position: relative;
  z-index: 10;
  flex-shrink: 0;
}

.page-logo-img {
  width: 80px;
  height: 80px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  margin: 0 auto 2px;
  filter: drop-shadow(0 2px 8px rgba(212, 175, 55, 0.3));
}

.page-body-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 2px 4px 20px;
  position: relative;
  z-index: 10;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-dark) transparent;
}

.page-body-content::-webkit-scrollbar {
  width: 4px;
}

.page-body-content::-webkit-scrollbar-thumb {
  background: var(--gold-dark);
  border-radius: 4px;
}

/* ==========================================================================
   8. ORNAMENTAL SECTION TITLE PLAQUE
   ========================================================================== */
.section-plaque-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 6px auto 12px;
  width: 100%;
  max-width: 360px;
}

.section-plaque {
  position: relative;
  display: inline-block;
  padding: 5px 24px;
  text-align: center;
  background: radial-gradient(circle at center, rgba(32, 27, 18, 0.7) 0%, rgba(12, 10, 8, 0.95) 100%);
  border: 1px solid var(--gold-warm);
  box-shadow:
    0 4px 15px rgba(0, 0, 0, 0.6),
    inset 0 0 10px rgba(212, 175, 55, 0.15);
  clip-path: polygon(
    0 8px, 8px 8px, 8px 0,
    calc(100% - 8px) 0, calc(100% - 8px) 8px, 100% 8px,
    100% calc(100% - 8px), calc(100% - 8px) calc(100% - 8px), calc(100% - 8px) 100%,
    8px 100%, 8px calc(100% - 8px), 0 calc(100% - 8px)
  );
}

.section-plaque-inner {
  border: 1px solid var(--gold-border-dim);
  padding: 3px 12px;
}

.section-title {
  font-family: var(--font-serif-classic);
  font-size: 1.1rem;
  letter-spacing: 0.18em;
  color: var(--gold-light);
  text-transform: uppercase;
  font-weight: 600;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
  white-space: nowrap;
}

.plaque-crown,
.plaque-foot {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-warm);
  line-height: 1;
}

.plaque-crown { margin-bottom: 2px; }
.plaque-foot { margin-top: 2px; }

.flourish-svg {
  fill: var(--gold-warm);
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.8));
}

/* Editorial Intro Box Styling */
.editorial-intro-box {
  text-align: center;
  max-width: 440px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.intro-box-subtitle {
  font-family: var(--font-serif-classic);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  color: var(--gold-light);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.intro-box-flourish {
  margin-bottom: 8px;
}

.intro-box-quote {
  font-family: var(--font-serif-luxury);
  font-size: clamp(0.9rem, 2.4vw, 1.05rem);
  font-style: italic;
  color: var(--cream-pure);
  margin-bottom: 12px;
  line-height: 1.45;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

.intro-prose-wrap {
  margin: 6px auto 14px;
  max-width: 420px;
  text-align: justify;
  text-justify: inter-word;
  line-height: 1.6;
}

.intro-prose-text {
  font-family: var(--font-serif-luxury);
  font-size: clamp(0.88rem, 2vw, 0.98rem);
  color: var(--cream-soft);
}

.intro-dropcap {
  font-family: var(--font-serif-classic);
  float: left;
  font-size: 2.8rem;
  line-height: 0.8;
  padding-right: 8px;
  padding-top: 4px;
  color: var(--gold-light);
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8);
}

.intro-divider-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 8px 0 14px;
  color: var(--gold-warm);
  font-size: 1.1rem;
  opacity: 0.8;
}

.intro-pillars-editorial {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.intro-pillar-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.pillar-name {
  font-family: var(--font-serif-classic);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--gold-light);
  font-weight: 600;
  margin-bottom: 2px;
}

.pillar-desc {
  font-family: var(--font-serif-luxury);
  font-size: 0.75rem;
  font-style: italic;
  color: var(--cream-dim);
}

.pillar-sep {
  color: var(--gold-dark);
  font-size: 0.65rem;
}

.intro-box-footer {
  font-family: var(--font-serif-classic);
  font-size: 0.68rem;
  letter-spacing: 0.28em;
  color: var(--muted-gold);
  margin-top: 6px;
}


/* ==========================================================================
   9. REAL FOOD PHOTOGRAPHY SHOWCASE
   ========================================================================== */
.editorial-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
}

@media (min-width: 680px) {
  .editorial-hero-grid.two-col {
    grid-template-columns: 1.15fr 1fr;
    gap: 18px;
  }
  .editorial-hero-grid.two-col.reverse {
    grid-template-columns: 1fr 1.15fr;
  }
}

.food-image-frame {
  position: relative;
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid var(--gold-border);
  box-shadow:
    0 6px 20px rgba(0, 0, 0, 0.75),
    0 0 1px rgba(212, 175, 55, 0.4);
  background: #0c0a08;
  width: 100%;
}

.food-image-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  border: 1px solid rgba(212, 175, 55, 0.22);
  pointer-events: none;
}

/* Specific aspect ratios preserving 100% of the food subjects */
.frame-hero-burger,
.frame-hero-box,
.frame-hero-ojja,
.frame-hero-fish {
  aspect-ratio: 16 / 11;
  max-height: 200px;
}

.frame-hero-pizza,
.frame-hero-tacos {
  aspect-ratio: 16 / 7;
  max-height: 160px;
}

.frame-hero-salad {
  aspect-ratio: 16 / 9;
  max-height: 140px;
}

@media (min-width: 680px) {
  .frame-hero-burger,
  .frame-hero-box,
  .frame-hero-ojja,
  .frame-hero-fish {
    aspect-ratio: 5 / 4;
    max-height: 220px;
  }
  .frame-hero-pizza,
  .frame-hero-tacos {
    aspect-ratio: 21 / 9;
    max-height: 185px;
  }
}

.food-image-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  image-rendering: -webkit-optimize-contrast;
  transition: transform 12s cubic-bezier(0.25, 1, 0.5, 1);
  transform-origin: center center;
}

.food-image-frame:hover .food-image-photo,
.active-page .food-image-photo {
  animation: subtleKenBurns 18s ease-in-out infinite alternate;
}

@keyframes subtleKenBurns {
  0% { transform: scale(1) translate(0, 0); }
  50% { transform: scale(1.03) translate(1px, -1px); }
  100% { transform: scale(1.01) translate(-1px, 1px); }
}

.editorial-quote-text {
  font-family: var(--font-serif-luxury);
  font-size: clamp(0.95rem, 2.2vw, 1.1rem);
  font-style: italic;
  color: var(--gold-light);
  line-height: 1.4;
  margin: 0;
}

.secondary-editorial-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  background: transparent;
  border-top: 1px solid var(--gold-border-dim);
  border-bottom: 1px solid var(--gold-border-dim);
  border-left: none;
  border-right: none;
  padding: 8px 4px;
  border-radius: 0;
  margin-top: 10px;
  box-shadow: none;
}

.editorial-thumb-img {
  width: 78px;
  height: 52px;
  border-radius: 3px;
  object-fit: cover;
  border: 1px solid var(--gold-border);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
  flex-shrink: 0;
  image-rendering: -webkit-optimize-contrast;
}

.editorial-card-text h4 {
  font-family: var(--font-serif-classic);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--gold-light);
  margin-bottom: 2px;
  text-transform: uppercase;
}

.editorial-card-text p {
  font-size: 0.78rem;
  color: var(--cream-dim);
  font-style: italic;
  line-height: 1.25;
  margin: 0;
}

/* ==========================================================================
   10. MENU ITEMS & DOTTED PRICE LEADERS
   ========================================================================== */
.menu-items-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.menu-item-row {
  display: flex;
  flex-direction: column;
  position: relative;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.45s cubic-bezier(0.25, 1, 0.5, 1), transform 0.45s cubic-bezier(0.25, 1, 0.5, 1);
}

.active-page .menu-item-row,
.active-spread-page .menu-item-row {
  opacity: 1;
  transform: translateY(0);
}

.active-page .menu-item-row:nth-child(1),
.active-spread-page .menu-item-row:nth-child(1) { transition-delay: 0.20s; }
.active-page .menu-item-row:nth-child(2),
.active-spread-page .menu-item-row:nth-child(2) { transition-delay: 0.26s; }
.active-page .menu-item-row:nth-child(3),
.active-spread-page .menu-item-row:nth-child(3) { transition-delay: 0.32s; }
.active-page .menu-item-row:nth-child(4),
.active-spread-page .menu-item-row:nth-child(4) { transition-delay: 0.38s; }
.active-page .menu-item-row:nth-child(5),
.active-spread-page .menu-item-row:nth-child(5) { transition-delay: 0.44s; }
.active-page .menu-item-row:nth-child(6),
.active-spread-page .menu-item-row:nth-child(6) { transition-delay: 0.50s; }
.active-page .menu-item-row:nth-child(7),
.active-spread-page .menu-item-row:nth-child(7) { transition-delay: 0.56s; }
.active-page .menu-item-row:nth-child(8),
.active-spread-page .menu-item-row:nth-child(8) { transition-delay: 0.62s; }

/* Staggered Element Reveals on Page Turn */
.active-page .section-plaque-wrap,
.active-spread-page .section-plaque-wrap {
  animation: cascadeFadeDown 0.45s cubic-bezier(0.25, 1, 0.5, 1) 0.06s both;
}

.active-page .food-image-frame,
.active-spread-page .food-image-frame {
  animation: cascadeFadeUp 0.5s cubic-bezier(0.25, 1, 0.5, 1) 0.14s both;
}

.active-page .editorial-page-quote,
.active-spread-page .editorial-page-quote {
  animation: cascadeFadeUp 0.5s cubic-bezier(0.25, 1, 0.5, 1) 0.20s both;
}

.active-page .pizza-table-wrap,
.active-spread-page .pizza-table-wrap {
  animation: cascadeFadeUp 0.52s cubic-bezier(0.25, 1, 0.5, 1) 0.22s both;
}

@keyframes cascadeFadeDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cascadeFadeUp {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.menu-item-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  width: 100%;
  gap: 6px;
}

.menu-item-name {
  font-family: var(--font-serif-luxury);
  font-size: clamp(0.85rem, 2.3vw, 1.05rem);
  letter-spacing: 0.04em;
  color: var(--cream-pure);
  font-weight: 500;
  text-transform: uppercase;
  flex-shrink: 0;
  max-width: 72%;
  white-space: normal;
}

.menu-item-dots {
  flex-grow: 1;
  min-width: 12px;
  border-bottom: 1.5px dotted rgba(212, 175, 55, 0.45);
  margin: 0 4px;
  height: 1px;
  align-self: baseline;
  position: relative;
  top: -4px;
}

.menu-item-price {
  font-family: var(--font-serif-classic);
  font-size: clamp(0.85rem, 2.2vw, 1rem);
  letter-spacing: 0.05em;
  color: var(--gold-light);
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  text-align: right;
}

.menu-item-desc {
  font-family: var(--font-serif-luxury);
  font-size: clamp(0.72rem, 1.8vw, 0.82rem);
  font-style: italic;
  color: var(--muted-gold);
  line-height: 1.25;
  margin-top: 1px;
  padding-right: 15px;
}

/* Multi-Column Suppléments Grid */
.supplements-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px 20px;
  width: 100%;
}

@media (min-width: 580px) {
  .supplements-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Multi-Size Pizza Table */
.pizza-table-wrap {
  width: 100%;
  margin-top: 6px;
  border-top: 1px solid var(--gold-border-dim);
}

.pizza-table-header {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  padding: 6px 4px;
  border-bottom: 1px solid var(--gold-border);
  font-family: var(--font-serif-classic);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: var(--gold-warm);
  text-align: right;
}

.pizza-table-header span:first-child {
  text-align: left;
}

.pizza-table-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  padding: 6px 4px;
  border-bottom: 1px dotted rgba(212, 175, 55, 0.2);
  align-items: baseline;
  text-align: right;
}

.pizza-name-col {
  text-align: left;
}

.pizza-name-col h4 {
  font-family: var(--font-serif-luxury);
  font-size: 0.95rem;
  color: var(--cream-pure);
  text-transform: uppercase;
  font-weight: 500;
}

.pizza-name-col p {
  font-size: 0.72rem;
  font-style: italic;
  color: var(--text-muted);
}

.pizza-price-val {
  font-family: var(--font-serif-classic);
  font-size: 0.85rem;
  color: var(--gold-light);
  font-weight: 500;
}

/* ==========================================================================
   11. DESKTOP INTERACTION: DUAL CORNER LIFTS & HOVER HINTS
   ========================================================================== */
.corner-lift-hint {
  position: absolute;
  bottom: 0;
  width: 45px;
  height: 45px;
  cursor: pointer;
  z-index: 35;
  pointer-events: all;
}

.corner-lift-hint.bottom-right {
  right: 0;
  display: block;
}

.corner-lift-hint.bottom-left {
  left: 0;
  display: none;
}

@media (min-width: 992px) {
  .spread-left .corner-lift-hint.bottom-left {
    display: block;
  }
  .spread-left .corner-lift-hint.bottom-right {
    display: none;
  }
  .spread-right .corner-lift-hint.bottom-right {
    display: block;
  }
  .spread-right .corner-lift-hint.bottom-left {
    display: none;
  }
}

.corner-lift-triangle.right {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 0 26px 26px;
  border-color: transparent transparent rgba(212, 175, 55, 0.25) transparent;
  transition: all 0.35s cubic-bezier(0.25, 1, 0.5, 1);
}

.corner-lift-triangle.left {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 26px 26px 0;
  border-color: transparent rgba(212, 175, 55, 0.25) transparent transparent;
  transition: all 0.35s cubic-bezier(0.25, 1, 0.5, 1);
}

@media (hover: hover) and (pointer: fine) {
  .corner-lift-hint.bottom-right:hover .corner-lift-triangle.right {
    border-width: 0 0 34px 34px;
    border-color: transparent transparent var(--gold-warm) transparent;
    filter: drop-shadow(-3px -3px 8px rgba(212, 175, 55, 0.4));
  }
  .corner-lift-hint.bottom-left:hover .corner-lift-triangle.left {
    border-width: 0 34px 34px 0;
    border-color: transparent var(--gold-warm) transparent transparent;
    filter: drop-shadow(3px -3px 8px rgba(212, 175, 55, 0.4));
  }
}

/* ==========================================================================
   12. NAVIGATION CONTROLS & BOTTOM DOCK
   ========================================================================== */
.bottom-dock {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 16px;
  margin-top: 8px;
  margin-bottom: calc(var(--safe-bottom) + 4px);
  z-index: 50;
}

.nav-arrow-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--gold-border-dim);
  background: rgba(18, 16, 12, 0.85);
  backdrop-filter: blur(8px);
  color: var(--gold-light);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.7);
}

.nav-arrow-btn:disabled {
  opacity: 0.25;
  cursor: not-allowed;
  pointer-events: none;
  border-color: rgba(212, 175, 55, 0.15);
}

.nav-arrow-btn:not(:disabled):hover,
.nav-arrow-btn:not(:disabled):focus-visible {
  border-color: var(--gold-warm);
  color: #fff;
  box-shadow: 0 0 16px var(--gold-glow);
  transform: scale(1.06);
}

.nav-arrow-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.page-indicator-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(18, 16, 12, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid var(--gold-border-dim);
  padding: 5px 16px;
  border-radius: 30px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.indicator-counter {
  font-family: var(--font-serif-classic);
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  color: var(--gold-light);
}

.page-dots-list {
  display: flex;
  gap: 6px;
  list-style: none;
}

.page-dot-item {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(212, 175, 55, 0.25);
  transition: all 0.3s ease;
  cursor: pointer;
}

.page-dot-item.active-dot {
  background: var(--gold-bright);
  transform: scale(1.35);
  box-shadow: 0 0 8px var(--gold-warm);
}

/* ==========================================================================
   13. MODALS: TABLE OF CONTENTS & ORIGINAL MENU SCAN VIEWER
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: rgba(4, 4, 4, 0.88);
  backdrop-filter: blur(10px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.35s cubic-bezier(0.25, 1, 0.5, 1);
}

.modal-overlay.modal-open {
  opacity: 1;
  visibility: visible;
}

.modal-container {
  background: var(--black-card);
  border: 1px solid var(--gold-border);
  border-radius: 4px;
  padding: 28px 24px;
  max-width: 520px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.95);
}

.modal-close-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--gold-border-dim);
  color: var(--gold-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all 0.3s ease;
}

.modal-close-btn:hover {
  border-color: var(--gold-warm);
  color: #fff;
  transform: rotate(90deg);
}

.modal-title {
  font-family: var(--font-serif-classic);
  font-size: 1.05rem;
  letter-spacing: 0.18em;
  color: var(--gold-light);
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 18px;
}

.toc-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toc-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: 2px;
  background: rgba(18, 16, 12, 0.5);
  border: 1px solid var(--gold-border-dim);
  color: var(--cream-pure);
  text-decoration: none;
  font-family: var(--font-serif-luxury);
  font-size: 1rem;
  transition: all 0.25s ease;
  width: 100%;
}

.toc-link:hover,
.toc-link:focus-visible {
  background: rgba(35, 30, 20, 0.7);
  border-color: var(--gold-warm);
  color: var(--gold-bright);
  padding-left: 16px;
}

.toc-page-num {
  font-family: var(--font-serif-classic);
  font-size: 0.76rem;
  color: var(--muted-gold);
}

.scan-viewer-container {
  max-width: 800px;
  max-height: 90vh;
  padding: 20px;
  text-align: center;
}

.scan-image-wrap {
  position: relative;
  max-height: 75vh;
  overflow: auto;
  border: 1px solid var(--gold-border-dim);
  border-radius: 3px;
  margin-top: 10px;
}

.scan-image-wrap img {
  margin: 0 auto;
  max-height: 75vh;
  object-fit: contain;
}

/* ==========================================================================
   14. MOBILE FIRST & IPHONE SAFARI SAFE AREA OPTIMIZATION
   ========================================================================== */
@media (max-width: 991px) {
  :root {
    --page-turn-duration: 500ms;
  }

  /* 1. Global Viewport & Container Containment */
  .app-container {
    padding-top: max(var(--safe-top), 2px);
    padding-bottom: max(var(--safe-bottom), 2px);
    padding-left: max(var(--safe-left), 4px);
    padding-right: max(var(--safe-right), 4px);
  }

  /* Top Navigation Bar: Prominent Fratello Logo (75-85px) + Essential Minimal Controls */
  .top-brand-bar {
    padding: 3px 8px;
    margin-bottom: 2px;
    height: auto;
    min-height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
  }

  .brand-crest-small {
    display: flex;
    align-items: center;
    text-decoration: none;
  }

  .brand-logo-nav {
    width: 78px;
    height: 78px;
    max-width: 88px;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 2px 8px rgba(212, 175, 55, 0.45));
    image-rendering: -webkit-optimize-contrast;
  }

  /* Hide non-essential controls on mobile to keep navbar clean and uncluttered */
  #btnToggleFullscreen,
  #btnViewScan,
  .btn-text {
    display: none !important;
  }

  .top-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
  }

  .btn-luxury-sm {
    padding: 0;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    background: rgba(18, 16, 12, 0.85);
    border: 1px solid var(--gold-border-dim);
    color: var(--gold-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  }

  .btn-luxury-sm svg {
    margin: 0;
    width: 17px;
    height: 17px;
  }

  /* 2. Book Stage & Physical Single Page Canvas */
  .book-stage {
    padding: 1px 0 2px;
    flex: 1;
    min-height: 0;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    touch-action: pan-x;
  }

  .book-wrapper {
    width: 96%;
    max-width: 440px;
    height: 100%;
    max-height: 100%;
    margin: 0 auto;
    box-shadow:
      0 2px 0 #18150f,
      0 8px 25px rgba(0, 0, 0, 0.9);
  }

  .book-stack-edge.right {
    width: 4px;
    right: -4px;
    top: 4px;
    bottom: 4px;
  }

  .book-stack-edge.left {
    display: none !important;
  }

  .book-spine-crease {
    display: none !important;
  }

  /* 3. Single Physical Page Framing */
  .menu-page {
    width: 100%;
    height: 100%;
    inset: 0;
  }

  .page-front {
    padding: 8px 10px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    overflow: hidden !important;
  }

  .page-border-outer {
    inset: 3px;
    border: 1px solid rgba(212, 175, 55, 0.35);
  }

  .page-border-inner {
    inset: 6px;
    border: 1px solid rgba(212, 175, 55, 0.18);
  }

  .botanical-corner {
    width: 20px;
    height: 20px;
    opacity: 0.65;
  }

  /* Header & Title Plaque */
  .page-brand-header {
    display: none !important;
    margin-bottom: 0;
  }

  .section-plaque-wrap {
    margin: 2px auto 6px;
    max-width: 270px;
    flex-shrink: 0;
  }

  .section-plaque {
    padding: 2px 14px;
    border: 1px solid var(--gold-border);
    background: linear-gradient(180deg, #181510 0%, #0c0a07 100%);
  }

  .section-plaque-inner {
    padding: 1px 6px;
  }

  .section-title {
    font-family: var(--font-serif-classic);
    font-size: 1.10rem; /* ~17.6px - 19px readable hierarchy */
    font-weight: 600;
    letter-spacing: 0.12em;
    color: var(--gold-light);
    line-height: 1.2;
    text-transform: uppercase;
  }

  .plaque-crown svg {
    width: 28px;
    height: 8px;
  }

  .plaque-foot svg {
    width: 22px;
    height: 6px;
  }

  /* 4. Page Body - Centered, Balanced, Zero Dead Void */
  .page-body-content {
    flex: 1;
    min-height: 0;
    overflow: hidden !important;
    padding: 0 2px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
  }

  /* 5. Food Photography: Large, Appetizing, Purpose-Built */
  .editorial-hero-grid {
    margin-bottom: 0;
    gap: 0;
    grid-template-columns: 1fr;
    width: 100%;
    flex-shrink: 0;
  }

  .editorial-page-quote {
    display: none !important;
  }

  .food-image-frame {
    border-radius: 3px;
    border: 1px solid var(--gold-border);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.8);
    width: 100%;
    height: 155px;
    max-height: 165px;
    margin: 0 auto;
    flex-shrink: 0;
    overflow: hidden;
  }

  .page-compact-6 .food-image-frame {
    height: 136px;
    max-height: 142px;
  }

  .frame-hero-salad {
    height: 135px;
    max-height: 140px;
  }

  .food-image-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 50%;
    image-rendering: -webkit-optimize-contrast;
  }

  /* 6. 4-Item Menu Category (Burgers, Box, Ojja, Grillades, Poissons, Pâtes, Baguettes, Tacos) */
  .page-compact-4 .menu-items-list {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    flex: none;
    gap: 7px;
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .page-compact-4 .menu-item-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin: 0;
    padding: 0;
    line-height: 1.2;
  }

  .page-compact-4 .menu-item-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    width: 100%;
  }

  .page-compact-4 .menu-item-name {
    font-family: var(--font-serif-luxury);
    font-size: 0.90rem; /* ~14.4px clear readable text */
    font-weight: 600;
    letter-spacing: 0.03em;
    color: var(--cream-pure);
    flex-shrink: 1;
    min-width: 0;
  }

  .page-compact-4 .menu-item-dots {
    flex-grow: 1;
    min-width: 8px;
    border-bottom: 1px dotted rgba(212, 175, 55, 0.45);
    margin: 0 6px;
    position: relative;
    top: -2px;
  }

  .page-compact-4 .menu-item-price {
    font-family: var(--font-serif-classic);
    font-size: 0.92rem; /* ~14.7px clear gold price */
    font-weight: 600;
    color: var(--gold-light);
    white-space: nowrap;
    text-align: right;
    flex-shrink: 0;
    padding-left: 6px;
  }

  .page-compact-4 .menu-item-desc {
    font-size: 0.66rem; /* ~10.5px legible description */
    line-height: 1.25;
    font-style: italic;
    color: var(--muted-gold);
    margin: 0;
    padding-right: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* 7. 6-Item Menu Category (Pizzas Partie I & II) */
  .page-compact-6 .menu-items-list {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    flex: none;
    gap: 4px;
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .page-compact-6 .menu-item-row {
    display: flex;
    flex-direction: column;
    gap: 1px;
    margin: 0;
    padding: 0;
    line-height: 1.18;
  }

  .page-compact-6 .menu-item-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    width: 100%;
  }

  .page-compact-6 .menu-item-name {
    font-family: var(--font-serif-luxury);
    font-size: 0.84rem; /* ~13.5px */
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--cream-pure);
    flex-shrink: 1;
    min-width: 0;
  }

  .page-compact-6 .menu-item-dots {
    flex-grow: 1;
    min-width: 6px;
    border-bottom: 1px dotted rgba(212, 175, 55, 0.45);
    margin: 0 5px;
    position: relative;
    top: -2px;
  }

  .page-compact-6 .menu-item-price {
    font-family: var(--font-serif-classic);
    font-size: 0.86rem; /* ~13.8px */
    font-weight: 600;
    color: var(--gold-light);
    white-space: nowrap;
    text-align: right;
    flex-shrink: 0;
    padding-left: 6px;
  }

  .page-compact-6 .menu-item-desc {
    font-size: 0.62rem; /* ~10px */
    line-height: 1.2;
    font-style: italic;
    color: var(--muted-gold);
    margin: 0;
    padding-right: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* 8. Suppléments 2-Column Side-by-Side Layout */
  .supplements-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 5px 12px !important;
    width: 100%;
    flex: none;
    align-content: flex-start;
  }

  .supplements-grid .menu-items-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
  }

  .supplements-grid .menu-item-name {
    font-size: 0.80rem;
    max-width: 65%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
  }

  .supplements-grid .menu-item-price {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--gold-light);
  }

  /* 9. Cover on Mobile */
  .menu-cover {
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
  }

  .cover-main-content {
    max-width: 320px;
    margin: auto 0;
  }

  .cover-header-tag {
    font-size: 0.62rem;
    letter-spacing: 0.22em;
    margin-top: 2px;
  }

  .cover-logo-img {
    width: 150px;
    max-width: 60%;
    margin-bottom: 8px;
  }

  .cover-book-title {
    font-size: 0.88rem;
    letter-spacing: 0.18em;
    margin-bottom: 6px;
  }

  .cover-divider-flourish {
    width: 80px;
    height: 10px;
    margin-bottom: 8px;
  }

  .cover-description {
    font-size: 0.8rem;
    line-height: 1.35;
    margin-bottom: 12px;
    max-width: 290px;
  }

  .btn-open-menu {
    padding: 8px 22px;
    font-size: 0.72rem;
    gap: 8px;
  }

  .cover-footer {
    font-size: 0.58rem;
    letter-spacing: 0.18em;
    margin-bottom: 2px;
  }

  /* 10. Bottom Navigation Dock - Centered & Subtle */
  .bottom-dock {
    width: 100%;
    max-width: 440px;
    margin: 2px auto 0;
    padding: 2px 6px;
    padding-bottom: max(var(--safe-bottom), 2px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-shrink: 0;
    z-index: 50;
    height: 38px;
  }

  .nav-arrow-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .nav-arrow-btn svg {
    width: 17px;
    height: 17px;
  }

  .page-indicator-pill {
    padding: 3px 12px;
    height: 26px;
    gap: 8px;
    display: flex;
    align-items: center;
    border-radius: 20px;
  }

  .indicator-counter {
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    color: var(--gold-light);
  }

  .page-dots-list {
    gap: 3px;
    display: flex;
    align-items: center;
    max-width: 130px;
    overflow: hidden;
  }

  .page-dot-item {
    width: 3.5px;
    height: 3.5px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.3);
    transition: all 0.3s ease;
    cursor: pointer;
  }

  .page-dot-item.active-dot {
    width: 10px;
    border-radius: 2px;
    background: var(--gold-light);
  }
}

/* 11. Mid-Height Mobile Screens (701px - 819px, e.g. iPhone 12/13/14) */
@media (min-height: 701px) and (max-height: 819px) and (max-width: 991px) {
  .brand-logo-nav {
    width: 80px;
    height: 80px;
  }

  .page-front {
    padding: 8px 10px 10px;
  }

  .section-title {
    font-size: 1.15rem;
  }

  .food-image-frame {
    height: 165px;
    max-height: 172px;
  }

  .page-compact-6 .food-image-frame {
    height: 145px;
    max-height: 150px;
  }

  .page-compact-4 .menu-items-list {
    gap: 8px;
  }

  .page-compact-4 .menu-item-name {
    font-size: 0.92rem;
  }

  .page-compact-4 .menu-item-price {
    font-size: 0.94rem;
  }

  .bottom-dock {
    height: 40px;
  }
}

/* 12. Tall Mobile Screens (>= 820px, e.g. iPhone Pro Max, Pixel 7) */
@media (min-height: 820px) and (max-width: 991px) {
  .brand-logo-nav {
    width: 84px;
    height: 84px;
  }

  .page-front {
    padding: 10px 12px 12px;
  }

  .section-title {
    font-size: 1.20rem;
  }

  .food-image-frame {
    height: 175px;
    max-height: 182px;
  }

  .page-compact-6 .food-image-frame {
    height: 152px;
    max-height: 158px;
  }

  .page-compact-4 .menu-items-list {
    gap: 9px;
  }

  .page-compact-4 .menu-item-name {
    font-size: 0.94rem;
  }

  .page-compact-4 .menu-item-price {
    font-size: 0.96rem;
  }

  .bottom-dock {
    height: 42px;
  }
}

/* 13. Ultra-narrow Mobile (<= 380px, e.g. iPhone SE) */
@media (max-width: 380px) {
  .app-container {
    padding-left: 2px;
    padding-right: 2px;
  }

  .top-brand-bar {
    min-height: 48px;
    padding: 2px 6px;
  }

  .brand-logo-nav {
    width: 68px;
    height: 68px;
  }

  .btn-luxury-sm {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
  }

  .book-wrapper {
    width: 98%;
  }

  .page-front {
    padding: 6px 8px;
  }

  .section-plaque-wrap {
    margin: 2px auto 4px;
    max-width: 240px;
  }

  .section-title {
    font-size: 1.05rem;
  }

  .food-image-frame {
    height: 145px;
    max-height: 150px;
  }

  .page-compact-6 .food-image-frame {
    height: 126px;
    max-height: 130px;
  }

  .page-compact-4 .menu-items-list {
    gap: 6px;
  }

  .page-compact-4 .menu-item-name {
    font-size: 0.84rem;
  }

  .page-compact-4 .menu-item-price {
    font-size: 0.86rem;
  }

  .page-compact-4 .menu-item-desc {
    font-size: 0.62rem;
  }

  .page-compact-6 .menu-items-list {
    gap: 3.5px;
  }

  .page-compact-6 .menu-item-name {
    font-size: 0.78rem;
  }

  .page-compact-6 .menu-item-price {
    font-size: 0.80rem;
  }

  .page-compact-6 .menu-item-desc {
    font-size: 0.58rem;
  }
}

/* ==========================================================================
   15. ACCESSIBILITY & REDUCED MOTION
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .menu-page.flipping-next,
  .menu-page.flipping-prev,
  .menu-page.flipping-spread-forward,
  .menu-page.flipping-spread-backward {
    animation: none !important;
  }

  .food-image-frame:hover .food-image-photo,
  .active-page .food-image-photo {
    animation: none !important;
  }

  .menu-cover.cover-opened {
    transform: none !important;
    display: none !important;
  }
}

/* ==========================================================================
   16. JAVASCRIPT DISABLED FALLBACK (Clean Vertical Scroll)
   ========================================================================== */
.no-js-menu-view {
  display: none;
  width: 100%;
  max-width: 820px;
  margin: 20px auto;
  padding: 24px;
  background: var(--black-card);
  border: 1px solid var(--gold-border);
}

noscript .no-js-menu-view {
  display: block;
}

noscript .book-stage,
noscript .bottom-dock,
noscript #preloader {
  display: none !important;
}
