:root,
html[data-theme="dark"] {
  color-scheme: dark;
  --bg-page: #141210;
  --bg-accent: #251f18;
  --bg-card: #1e1a16;
  --bg-card-alt: #18231b;
  --bg-header: rgba(22, 19, 16, 0.95);
  --bg-dock: rgba(24, 20, 17, 0.95);
  --bg-input: #221d18;
  --bg-sheet: linear-gradient(180deg, #211c17 0%, #171411 100%);
  --saffron: #ff7a3d;
  --saffron-deep: #f5672a;
  --leaf: #6aaa54;
  --leaf-deep: #53913f;
  --brass: #d3b26b;
  --bronze: #dfb873;
  --marble: #15181a;
  --marble-deep: #0e1012;
  --ink: #f6efe2;
  --ink-soft: #cfc6b8;
  --shadow-card: rgba(0, 0, 0, 0.44);
  --serif: "Gilda Display", "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

html[data-theme="light"] {
  color-scheme: light;
  --bg-page: #fff8eb;
  --bg-accent: #ffecc6;
  --bg-card: #fffdf8;
  --bg-card-alt: #effef5;
  --bg-header: rgba(255, 248, 235, 0.95);
  --bg-dock: rgba(255, 248, 235, 0.96);
  --bg-input: #ffffff;
  --bg-sheet: linear-gradient(180deg, #fff8eb 0%, #ffecc6 100%);
  --saffron: #f5672a;
  --saffron-deep: #d94d12;
  --leaf: #6aaa54;
  --leaf-deep: #4b8738;
  --brass: #d3b26b;
  --bronze: #9c6c32;
  --marble: #1a1e20;
  --marble-deep: #111416;
  --ink: #262422;
  --ink-soft: #4c4d4d;
  --shadow-card: rgba(156, 108, 50, 0.14);
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 98px;
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg-page);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  padding-bottom: env(safe-area-inset-bottom, 0px);
  transition: background-color 0.25s ease, color 0.25s ease;
}

body.curtain-open,
body.dialog-open {
  overflow: hidden;
}

/* Personal Namaste Split-Door Welcome Entrance */
.welcome-curtain {
  position: fixed;
  inset: 0;
  z-index: 60;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
}

.welcome-curtain.is-opening {
  pointer-events: none;
}

.welcome-curtain.is-done {
  display: none;
  pointer-events: none;
}

.door-seam-glow {
  position: absolute;
  left: 50%;
  top: 8%;
  bottom: 8%;
  width: 6px;
  margin-left: -3px;
  z-index: 3;
  border-radius: 999px;
  background: radial-gradient(circle, #fff3cc 0%, #ffd788 45%, rgba(245, 103, 42, 0) 100%);
  box-shadow: 0 0 28px 8px rgba(255, 215, 136, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.65s var(--ease-out);
}

.welcome-curtain.is-opening .door-seam-glow {
  opacity: 0.95;
  transform: scaleY(1.06);
}

.door-half {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  overflow: hidden;
  will-change: transform, opacity;
  transition: transform 0.92s cubic-bezier(0.76, 0, 0.24, 1), opacity 0.32s ease 0.62s;
}

.door-half-left {
  left: 0;
}

.door-half-right {
  right: 0;
}

.welcome-curtain.is-opening .door-half-left {
  transform: translate3d(-104%, 0, 0);
  opacity: 0;
}

.welcome-curtain.is-opening .door-half-right {
  transform: translate3d(104%, 0, 0);
  opacity: 0;
}

.door-sheet {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 200%;
  display: grid;
  place-items: center;
  padding: 20px 18px;
  background:
    radial-gradient(circle at 50% 34%, rgba(245, 103, 42, 0.2) 0%, rgba(211, 178, 107, 0.08) 28%, transparent 56%),
    radial-gradient(circle at 50% 72%, rgba(106, 170, 84, 0.14) 0%, transparent 50%),
    linear-gradient(180deg, #1d1611 0%, #141210 52%, #0c0a08 100%);
}

.door-half-left .door-sheet {
  left: 0;
}

.door-half-right .door-sheet {
  left: -100%;
}

.door-panel-ornament {
  position: absolute;
  top: 16px;
  bottom: 16px;
  width: calc(50% - 20px);
  border: 1.5px solid rgba(211, 178, 107, 0.38);
  border-radius: 18px;
  box-shadow: inset 0 0 0 6px rgba(211, 178, 107, 0.08);
  pointer-events: none;
}

.door-panel-left {
  left: 14px;
}

.door-panel-right {
  right: 14px;
}

.door-seam-brass {
  position: absolute;
  top: 6%;
  bottom: 6%;
  width: 3px;
  background: linear-gradient(180deg, transparent 0%, rgba(211, 178, 107, 0.72) 18%, #ffd788 50%, rgba(211, 178, 107, 0.72) 82%, transparent 100%);
  pointer-events: none;
}

.door-seam-brass-left {
  left: calc(50% - 3px);
}

.door-seam-brass-right {
  left: 50%;
}

.welcome-plaque {
  position: relative;
  z-index: 2;
  width: min(100%, 420px);
  padding: 26px 18px 22px;
  border-radius: 24px;
  border: 1.5px solid rgba(211, 178, 107, 0.56);
  background: linear-gradient(180deg, rgba(35, 27, 21, 0.94) 0%, rgba(20, 17, 14, 0.97) 100%);
  box-shadow:
    0 24px 56px rgba(0, 0, 0, 0.65),
    inset 0 1px 0 rgba(255, 224, 168, 0.24);
  text-align: center;
  animation: welcomeReveal 0.45s var(--ease-out) both;
}

@keyframes welcomeReveal {
  from { opacity: 0.92; transform: scale(0.98) translateY(4px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.welcome-logo-halo {
  display: inline-block;
  padding: 0;
  background: transparent;
}

.welcome-logo {
  display: block;
  width: clamp(166px, 46vw, 224px);
  height: auto;
  aspect-ratio: 681 / 361;
  object-fit: contain;
  filter: drop-shadow(0 0 1px rgba(255, 248, 230, 0.5)) drop-shadow(0 4px 14px rgba(0, 0, 0, 0.55));
}

.welcome-namaste {
  margin: 12px auto 2px;
  display: grid;
  place-items: center;
  animation: namasteBreath 2.2s ease-in-out infinite;
}

@keyframes namasteBreath {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-2px) scale(1.04); }
}

.welcome-eyebrow {
  margin: 4px auto 8px;
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(106, 170, 84, 0.18);
  border: 1px solid rgba(155, 224, 130, 0.48);
  color: #9de885;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.welcome-heading {
  margin: 0 0 8px;
  font: 400 clamp(26px, 6.8vw, 35px) / 1.12 var(--serif);
  color: #ffd788;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.65);
}

.welcome-message {
  margin: 0 auto 16px;
  max-width: 33ch;
  color: #f3eadc;
  font-size: 13px;
  line-height: 1.58;
}

.welcome-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(245, 103, 42, 0.14);
  border: 1px solid rgba(255, 152, 96, 0.42);
  color: #ffb88c;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.welcome-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #6aaa54;
  box-shadow: 0 0 8px #9de885;
}

button,
input {
  font: inherit;
  color: inherit;
}

/* Sticky Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  padding: 7px 14px;
  border-bottom: 1.5px solid var(--brass);
  background: var(--bg-header);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 6px 20px var(--shadow-card);
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}

.header-spacer {
  justify-self: start;
  width: 64px;
}

.brand-lockup {
  justify-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background: transparent;
}

.brand-logo {
  display: block;
  width: clamp(144px, 40vw, 206px);
  height: auto;
  aspect-ratio: 681 / 361;
  max-height: 76px;
  object-fit: contain;
  filter: drop-shadow(0 0 1px rgba(255, 248, 230, 0.48)) drop-shadow(0 3px 10px rgba(0, 0, 0, 0.45));
  transition: transform 0.2s var(--ease-out);
}

html[data-theme="light"] .brand-logo {
  filter: drop-shadow(0 3px 8px rgba(156, 108, 50, 0.16));
}

.brand-lockup:active .brand-logo {
  transform: scale(0.97);
}

.theme-toggle {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1.5px solid var(--brass);
  background: var(--bg-accent);
  color: var(--saffron-deep);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s, background 0.2s;
}

html[data-theme="dark"] .theme-toggle {
  color: #ffd788;
}

.theme-toggle:active {
  transform: scale(0.94);
}

/* Direct Menu Card Container */
.browse {
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 14px 20px;
}

/* Front-Cover Inspired Heritage Menu Cover Header */
.menu-cover-card {
  position: relative;
  min-height: 162px;
  padding: 20px 18px 26px;
  border-radius: 20px;
  border: 2px solid var(--brass);
  background: #171a1c;
  box-shadow:
    0 14px 32px var(--shadow-card),
    inset 0 0 0 1px rgba(255, 215, 136, 0.28);
  overflow: hidden;
  display: flex;
  align-items: center;
  animation: cardEnter 0.4s var(--ease-out) both;
}

@keyframes cardEnter {
  from { opacity: 0; transform: translateY(10px) scale(0.99); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.cover-temple-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
  opacity: 0.62;
  pointer-events: none;
}

.cover-scrim {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 42%, rgba(20, 23, 25, 0.56) 0%, rgba(16, 18, 20, 0.78) 100%);
  pointer-events: none;
}

.cover-lamp {
  position: absolute;
  top: -2px;
  width: 44px;
  height: 66px;
  object-fit: contain;
  pointer-events: none;
  z-index: 2;
  transform-origin: top center;
  animation: lampSway 5.5s ease-in-out infinite;
}

.cover-lamp-left { left: 10px; }
.cover-lamp-right { right: 10px; animation-delay: -2.6s; }

@keyframes lampSway {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(2deg); }
}

.cover-content {
  position: relative;
  z-index: 3;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 18px;
}

.kathakali-crest {
  width: 68px;
  height: 68px;
  flex: none;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, #ffd788, #f5672a, #6aaa54);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

.kathakali-crest img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.cover-copy {
  min-width: 0;
  flex: 1;
}

.eyebrow {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--leaf-deep);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

html[data-theme="dark"] .eyebrow {
  color: #8ad773;
}

.cover-eyebrow {
  color: #9be88a;
  font-size: 9px;
}

.cover-copy h1 {
  margin: 4px 0 6px;
  color: #ffd788;
  font: 400 clamp(26px, 7.2vw, 38px) / 1.1 var(--serif);
  text-shadow: 0 3px 14px rgba(0, 0, 0, 0.7);
}

.menu-stats {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #efe4d2;
  font-size: 11px;
  font-weight: 500;
}

.menu-stats b {
  color: #ff9860;
  font: 700 16px var(--serif);
  margin-right: 3px;
}

.menu-stats i {
  width: 1px;
  height: 13px;
  background: rgba(211, 178, 107, 0.6);
}

.cover-gopuram-svg {
  width: 60px;
  height: 76px;
  flex: none;
  object-fit: contain;
  opacity: 0.85;
  display: none;
}

/* Ornamental Scroll Filigree Divider */
.filigree-divider {
  margin: 12px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.filigree-divider img {
  width: min(100%, 380px);
  height: 20px;
  object-fit: contain;
  display: block;
}

/* Search & Quick Category Pills */
.search-shell {
  position: relative;
  z-index: 4;
}

.search-deck {
  padding: 11px 11px 5px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(40, 33, 27, 0.94) 0%, rgba(23, 19, 15, 0.98) 100%);
  border: 1.5px solid rgba(211, 178, 107, 0.44);
  box-shadow:
    0 14px 28px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 224, 168, 0.14);
}

html[data-theme="light"] .search-deck {
  background: linear-gradient(180deg, #fff5e1 0%, #fde9c5 100%);
  border-color: rgba(211, 178, 107, 0.72);
  box-shadow:
    0 12px 24px rgba(156, 108, 50, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.search-box {
  min-height: 50px;
  background: linear-gradient(180deg, #1b1713 0%, #120f0d 100%);
  border: 1.5px solid rgba(211, 178, 107, 0.75);
  border-radius: 999px;
  display: flex;
  align-items: center;
  padding: 5px 5px 5px 7px;
  gap: 8px;
  box-shadow:
    inset 0 3px 8px rgba(0, 0, 0, 0.58),
    inset 0 -1px 0 rgba(255, 215, 136, 0.16),
    0 4px 0 #0d0a08,
    0 8px 18px rgba(0, 0, 0, 0.35);
  transition: border-color 0.2s, box-shadow 0.2s;
}

html[data-theme="light"] .search-box {
  background: linear-gradient(180deg, #ffffff 0%, #fff7e6 100%);
  box-shadow:
    inset 0 2px 6px rgba(156, 108, 50, 0.14),
    inset 0 -1px 0 rgba(255, 255, 255, 0.95),
    0 3px 0 #d5b470,
    0 8px 18px rgba(156, 108, 50, 0.14);
}

.search-box:focus-within {
  border-color: var(--saffron);
  box-shadow:
    inset 0 3px 8px rgba(0, 0, 0, 0.58),
    0 4px 0 #0d0a08,
    0 0 0 3px rgba(245, 103, 42, 0.26);
}

html[data-theme="light"] .search-box:focus-within {
  box-shadow:
    inset 0 2px 6px rgba(156, 108, 50, 0.14),
    0 3px 0 #d5b470,
    0 0 0 3px rgba(245, 103, 42, 0.22);
}

.search-icon-badge {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(245, 103, 42, 0.26) 0%, rgba(211, 178, 107, 0.14) 100%);
  border: 1px solid rgba(211, 178, 107, 0.48);
  color: #ffd788;
}

html[data-theme="light"] .search-icon-badge {
  background: linear-gradient(180deg, #ffecc6 0%, #ffdba3 100%);
  border-color: rgba(211, 178, 107, 0.8);
  color: var(--saffron-deep);
}

.search-box input {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 13.5px;
}

.search-box input::placeholder {
  color: #a69c8f;
}

html[data-theme="light"] .search-box input::placeholder {
  color: #82786d;
}

.search-box input::-webkit-search-cancel-button {
  display: none;
}

.clear-search-btn {
  flex: none;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 50%;
  background: rgba(211, 178, 107, 0.18);
  color: var(--saffron);
  font-size: 19px;
  line-height: 1;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.clear-search-btn[hidden] {
  display: none;
}

.search-3d-btn {
  flex: none;
  min-height: 38px;
  padding: 0 18px;
  border: 1px solid rgba(255, 212, 160, 0.56);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #ff9255 0%, #f5672a 55%, #cb420d 100%);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.38);
  cursor: pointer;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.45),
    inset 0 -1px 0 rgba(0, 0, 0, 0.2),
    0 4px 0 #8d2a05,
    0 7px 14px rgba(0, 0, 0, 0.4);
  transition: transform 0.14s var(--ease-out), box-shadow 0.14s var(--ease-out), filter 0.18s;
}

.search-3d-btn:hover {
  filter: brightness(1.06);
}

.search-3d-btn:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 2px 0 #942e06,
    0 3px 8px rgba(0, 0, 0, 0.35);
}

.quick-pills {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding: 13px 2px 10px;
  scrollbar-width: none;
}

.quick-pills::-webkit-scrollbar {
  display: none;
}

.quick-pill {
  flex: none;
  min-height: 36px;
  padding: 0 15px;
  border-radius: 999px;
  border: 1px solid rgba(211, 178, 107, 0.65);
  background: linear-gradient(180deg, #2d261e 0%, #1d1813 100%);
  color: #f3e8d4;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  box-shadow:
    inset 0 1px 0 rgba(255, 232, 184, 0.22),
    inset 0 -1px 0 rgba(0, 0, 0, 0.32),
    0 3px 0 #0f0c09,
    0 6px 12px rgba(0, 0, 0, 0.36);
  transition: transform 0.14s var(--ease-out), box-shadow 0.14s var(--ease-out), border-color 0.2s, color 0.2s;
}

html[data-theme="light"] .quick-pill {
  background: linear-gradient(180deg, #ffffff 0%, #f9ecd2 100%);
  color: #3f382f;
  border-color: #d3b26b;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 3px 0 #c5a15a,
    0 5px 10px rgba(156, 108, 50, 0.16);
}

.quick-pill:hover {
  border-color: var(--saffron);
  color: #ffd788;
}

html[data-theme="light"] .quick-pill:hover {
  color: var(--saffron-deep);
}

.quick-pill:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 232, 184, 0.16),
    0 1px 0 #0f0c09,
    0 2px 6px rgba(0, 0, 0, 0.3);
}

.quick-pill.is-active {
  background: linear-gradient(180deg, #7bc261 0%, #5b9b44 58%, #42782f 100%);
  border-color: #9be082;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    inset 0 -1px 0 rgba(0, 0, 0, 0.18),
    0 3px 0 #2b541d,
    0 7px 14px rgba(75, 135, 56, 0.36);
}

html[data-theme="light"] .quick-pill.is-active {
  background: linear-gradient(180deg, #7bc261 0%, #5b9b44 58%, #42782f 100%);
  color: #ffffff;
  border-color: #4b8738;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    0 3px 0 #2d591e,
    0 6px 14px rgba(75, 135, 56, 0.32);
}

html[data-theme="light"] .quick-pill:active {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 1px 0 #c5a15a,
    0 2px 5px rgba(156, 108, 50, 0.14);
}

.quick-pill.is-active:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    0 1px 0 #2b541d,
    0 3px 8px rgba(75, 135, 56, 0.28);
}

/* 9-Section 3D Menu Card Grid — Uncropped Square Photo Wells */
.section-overview-head {
  margin: 12px 0 12px;
  padding-bottom: 8px;
  border-bottom: 2.5px solid var(--saffron);
}

.section-overview-head h2 {
  margin: 3px 0 2px;
  color: var(--saffron);
  font: 400 clamp(22px, 5.8vw, 28px) / 1.15 var(--serif);
}

.section-overview-head > p:last-child {
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  perspective: 1100px;
}

.category-tile {
  --rx: 0deg;
  --ry: 0deg;
  --gx: 50%;
  --gy: 50%;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  padding: 10px;
  border: 1.5px solid var(--brass);
  border-radius: 18px;
  background: var(--bg-card);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  box-shadow: 0 10px 24px var(--shadow-card);
  transition: transform 0.22s var(--ease-out), border-color 0.22s, box-shadow 0.22s;
  overflow: hidden;
  animation: cardFlipIn 0.36s var(--ease-out) both;
  animation-delay: calc(min(var(--i, 0), 8) * 28ms);
}

.category-tile:nth-child(even) {
  background: linear-gradient(165deg, var(--bg-card-alt) 0%, var(--bg-card) 72%);
  border-color: rgba(106, 170, 84, 0.6);
}

.category-tile:nth-child(odd) {
  background: linear-gradient(165deg, var(--bg-accent) 0%, var(--bg-card) 68%);
}

/* Ornamental temple corner motif on cards */
.category-tile::after {
  content: "✥";
  position: absolute;
  top: 6px;
  right: 9px;
  font-size: 11px;
  color: var(--brass);
  opacity: 0.72;
  pointer-events: none;
}

.category-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--gx) var(--gy), rgba(245, 103, 42, 0.14), transparent 56%);
  opacity: 0;
  transition: opacity 0.25s;
  pointer-events: none;
}

.category-tile:hover::before,
.category-tile.is-tilting::before {
  opacity: 1;
}

.category-tile:hover {
  border-color: var(--saffron);
  box-shadow: 0 16px 30px rgba(245, 103, 42, 0.2);
}

.category-tile:active {
  transform: scale(0.97) rotateX(4deg);
}

/* Clean 1:1 Uncropped Photo Frame with Double Brass Rim */
.category-tile-photo {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 13px;
  border: 1.5px solid var(--brass);
  background: var(--marble);
  transform: translateZ(18px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
}

.category-tile-photo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  transition: transform 0.35s var(--ease-out);
}

.category-tile:hover .category-tile-photo img {
  transform: scale(1.05);
}

.category-tile-copy {
  display: flex;
  width: 100%;
  flex-direction: column;
  gap: 5px;
  padding-right: 26px;
  transform: translateZ(12px);
}

.category-tile-copy strong {
  font: 400 17px / 1.2 var(--serif);
  color: var(--saffron-deep);
}

html[data-theme="dark"] .category-tile-copy strong {
  color: #ff945e;
}

.category-tile-copy small {
  display: inline-block;
  align-self: flex-start;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--leaf);
  color: #ffffff;
  font-size: 10px;
  font-weight: 600;
}

.category-tile-arrow {
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--saffron);
  color: #ffffff;
  display: grid;
  place-items: center;
  font-size: 13px;
  transform: translateZ(20px);
  box-shadow: 0 4px 10px rgba(245, 103, 42, 0.3);
}

/* Section Detail & Dish Cards */
.back-to-sections {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  margin: 12px 0 10px;
  padding: 0 16px;
  border: 1px solid var(--leaf-deep);
  border-radius: 999px;
  background: var(--leaf);
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(106, 170, 84, 0.25);
  transition: background 0.2s, transform 0.15s;
}

.back-to-sections:active {
  transform: scale(0.96);
}

.menu-section {
  margin: 6px 0 28px;
}

.section-hero {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px;
  margin-bottom: 14px;
  border: 1.5px solid var(--brass);
  border-radius: 18px;
  background: linear-gradient(135deg, var(--leaf) 0%, var(--leaf-deep) 100%);
  color: #ffffff;
  box-shadow: 0 10px 24px rgba(75, 135, 56, 0.24);
  animation: cardEnter 0.32s var(--ease-out) both;
}

.section-hero > img {
  width: 84px;
  height: 84px;
  flex: none;
  object-fit: cover;
  border-radius: 12px;
  border: 2px solid #ffd788;
  background: var(--marble);
}

.section-hero-copy {
  min-width: 0;
}

.section-hero-copy .eyebrow {
  color: #ffecc6;
}

.section-hero-copy h2 {
  margin: 4px 0 6px;
  font: 400 clamp(22px, 5.8vw, 29px) / 1.15 var(--serif);
  color: #ffffff;
}

.item-count {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.dish-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  perspective: 1000px;
}

.dish-card {
  --rx: 0deg;
  --ry: 0deg;
  --gx: 50%;
  --gy: 50%;
  position: relative;
  width: 100%;
  min-height: 112px;
  display: flex;
  align-items: stretch;
  text-align: left;
  gap: 14px;
  padding: 10px;
  background: var(--bg-card);
  border: 1.5px solid var(--brass);
  border-radius: 18px;
  color: var(--ink);
  cursor: pointer;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  box-shadow: 0 8px 20px var(--shadow-card);
  transition: transform 0.2s var(--ease-out), border-color 0.2s, box-shadow 0.2s;
  overflow: hidden;
  animation: cardFlipIn 0.34s var(--ease-out) both;
  animation-delay: calc(min(var(--i, 0), 9) * 26ms);
}

@keyframes cardFlipIn {
  from { opacity: 0; transform: translateY(12px) rotateX(-10deg) scale(0.98); }
  to { opacity: 1; transform: translateY(0) rotateX(0deg) scale(1); }
}

.dish-card:hover {
  border-color: var(--saffron);
  box-shadow: 0 14px 28px rgba(245, 103, 42, 0.2);
}

.dish-card:active {
  transform: scale(0.98);
}

.card-photo {
  position: relative;
  display: block;
  flex: 0 0 92px;
  height: 92px;
  align-self: center;
  overflow: hidden;
  border-radius: 13px;
  border: 1.5px solid var(--brass);
  background: var(--marble);
  transform: translateZ(16px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.2);
}

.card-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-copy {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transform: translateZ(10px);
}

.card-category {
  color: var(--leaf-deep);
  text-transform: uppercase;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  margin-bottom: 3px;
}

html[data-theme="dark"] .card-category {
  color: #8ad773;
}

.card-name {
  font: 400 18px / 1.22 var(--serif);
  color: var(--ink);
}

.card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
}

.card-bottom strong {
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--bg-accent);
  color: var(--saffron-deep);
  font-size: 14px;
  font-weight: 700;
}

html[data-theme="dark"] .card-bottom strong {
  color: #ff945e;
}

.view-hint {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--leaf);
  color: #ffffff;
  font-size: 10px;
  font-weight: 600;
}

.photo-pending {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 2px;
  color: #ffd788;
}

.photo-pending span { font-size: 20px; }
.photo-pending small { font-size: 7px; text-align: center; }

/* Empty State */
.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--ink-soft);
}

.empty-state > span { font-size: 32px; color: var(--saffron); }
.empty-state h3 { font: 400 26px var(--serif); color: var(--saffron); margin: 8px 0; }
.empty-state p { font-size: 13px; }
.text-button {
  border: 0;
  background: none;
  color: var(--leaf-deep);
  font-weight: 600;
  text-decoration: underline;
  padding: 10px;
  cursor: pointer;
}

/* Rich Architectural South Indian Temple & Kathakali Footer */
.site-footer {
  position: relative;
  overflow: hidden;
  text-align: center;
  border-top: 3px solid var(--saffron);
  margin: 24px auto 0;
  padding: 34px 20px calc(32px + env(safe-area-inset-bottom, 0px));
  background: #141916;
  color: #ffffff;
}

.footer-temple-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
  opacity: 0.72;
  pointer-events: none;
}

.footer-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(22, 48, 28, 0.86) 0%, rgba(18, 28, 22, 0.68) 48%, rgba(16, 18, 18, 0.54) 100%);
  pointer-events: none;
}

.footer-lamp {
  position: absolute;
  top: 0;
  width: 48px;
  height: 74px;
  object-fit: contain;
  z-index: 2;
  pointer-events: none;
  transform-origin: top center;
  animation: lampSway 6s ease-in-out infinite;
}

.footer-lamp-left { left: max(10px, calc(50% - 260px)); }
.footer-lamp-right { right: max(10px, calc(50% - 260px)); animation-delay: -3s; }

.footer-inner {
  position: relative;
  z-index: 3;
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.footer-crest {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, #ffd788, #f5672a, #6aaa54);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
}

.footer-crest img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.footer-logo-wrap {
  margin-top: 4px;
  background: transparent;
}

.footer-logo {
  display: block;
  width: clamp(172px, 46vw, 236px);
  height: auto;
  aspect-ratio: 681 / 361;
  object-fit: contain;
  filter: drop-shadow(0 0 1px rgba(255, 248, 230, 0.5)) drop-shadow(0 4px 14px rgba(0, 0, 0, 0.55));
}

.footer-quote {
  margin: 4px 0 2px;
  font: 400 clamp(20px, 5vw, 24px) / 1.2 var(--serif);
  color: #ffd788;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7);
}

.footer-meta-pills {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 4px 14px;
  border-radius: 999px;
  background: rgba(18, 22, 20, 0.74);
  border: 1px solid rgba(211, 178, 107, 0.52);
  color: #ffecc6;
  font-size: 11px;
}

.footer-credit {
  color: #ebe2d3;
  font-size: 11px;
  letter-spacing: 0.04em;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.85);
}

.footer-credit .brand-terracotta,
.footer-credit a {
  color: #e06d44;
  font-weight: 700;
  text-decoration: none;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.75);
}

.footer-credit a {
  border-bottom: 1px dotted rgba(224, 109, 68, 0.72);
}

.footer-credit a:hover {
  color: #f08862;
  border-bottom-color: #f08862;
}

/* Interactive 3D Dish Sheet Dialog */
.dialog {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  visibility: hidden;
  pointer-events: none;
}

.dialog.is-open {
  visibility: visible;
  pointer-events: auto;
}

.dialog-scrim {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(16, 18, 20, 0.74);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.22s;
}

.dialog.is-open .dialog-scrim { opacity: 1; }

.dish-sheet {
  position: relative;
  width: min(100%, 540px);
  max-height: min(92dvh, 840px);
  overflow-y: auto;
  border-radius: 24px 24px 0 0;
  background: var(--bg-sheet);
  border: 1.5px solid var(--brass);
  border-bottom: 0;
  color: var(--ink);
  transform: translateY(36px);
  opacity: 0;
  transition: transform 0.24s var(--ease-out), opacity 0.2s;
  outline: none;
  overscroll-behavior: contain;
  padding-bottom: env(safe-area-inset-bottom, 0px);
  box-shadow: 0 -16px 48px rgba(0, 0, 0, 0.36);
}

.dialog.is-open .dish-sheet {
  transform: translateY(0);
  opacity: 1;
}

.sheet-handle {
  width: 42px;
  height: 4px;
  border-radius: 5px;
  background: var(--brass);
  margin: 10px auto 8px;
}

.close-button {
  position: absolute;
  top: 16px;
  right: 14px;
  z-index: 5;
  width: 38px;
  height: 38px;
  border: 1.5px solid var(--brass);
  border-radius: 50%;
  background: var(--bg-card);
  color: var(--saffron-deep);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.dish-stage-wrap { padding: 0 14px; }

.dish-image-frame {
  --rx: 0deg;
  --ry: 0deg;
  --gx: 50%;
  --gy: 35%;
  position: relative;
  width: 100%;
  height: min(82vw, 48dvh, 380px);
  border-radius: 20px;
  overflow: hidden;
  display: grid;
  place-items: center;
  padding: 14px;
  background:
    radial-gradient(circle at 50% 42%, rgba(211, 178, 107, 0.16) 0%, rgba(26, 30, 32, 0.96) 64%, var(--marble-deep) 100%);
  border: 2px solid var(--brass);
  box-shadow: 0 14px 32px rgba(20, 22, 24, 0.34);
  perspective: 950px;
  cursor: grab;
  touch-action: none;
}

.dish-image-frame.is-tilting { cursor: grabbing; }

.dish-2d-tilt {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  transition: transform 0.24s var(--ease-out);
  will-change: transform;
}

.dialog.is-open .dish-2d-tilt {
  animation: photoPopIn 0.44s var(--ease-out) both;
}

@keyframes photoPopIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.92) rotateX(-10deg);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1) rotateX(0deg);
  }
}

.dish-detail-image {
  display: block;
  width: min(100%, 340px);
  height: 100%;
  max-height: 100%;
  object-fit: cover;
  border-radius: 14px;
  border: 1.5px solid rgba(211, 178, 107, 0.65);
  box-shadow:
    0 20px 38px rgba(0, 0, 0, 0.56),
    0 0 24px rgba(245, 103, 42, 0.14);
  transform: translateZ(20px);
}

.dish-detail-image[hidden] { display: none; }

.stage-shimmer {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  pointer-events: none;
  background: radial-gradient(circle at var(--gx) var(--gy), rgba(255, 224, 168, 0.22), transparent 56%);
  opacity: 0;
  transition: opacity 0.25s;
  transform: translateZ(24px);
}

.dish-image-frame:hover .stage-shimmer,
.dish-image-frame.is-tilting .stage-shimmer {
  opacity: 1;
}

.detail-image-placeholder {
  position: relative;
  z-index: 3;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  color: #ffd788;
  font-size: 10px;
  letter-spacing: 0.16em;
}

.detail-image-placeholder[hidden] { display: none; }

.dish-detail-copy { padding: 18px 20px 26px; }

.dish-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-top: 6px;
}

.dish-title-row h2 {
  margin: 0;
  color: var(--saffron);
  font: 400 28px / 1.15 var(--serif);
}

.dish-title-row strong {
  padding: 4px 14px;
  border-radius: 999px;
  background: var(--saffron);
  color: #ffffff;
  font-size: 18px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(245, 103, 42, 0.32);
}

.detail-description {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.62;
  margin: 12px 0 0;
}

.detail-meta-note {
  margin: 14px 0 0;
  padding-top: 10px;
  border-top: 1px dashed var(--brass);
  color: var(--bronze);
  font-size: 10px;
  font-weight: 500;
}

body.dialog-open { overflow: hidden; }

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--saffron);
  outline-offset: 2px;
}

noscript {
  display: block;
  padding: 24px;
  text-align: center;
  color: var(--saffron);
}

/* Responsive Tablet & Desktop */
@media (min-width: 720px) {
  .browse { padding: 18px 20px 30px; }
  .cover-gopuram-svg { display: block; }
  .category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
  .dish-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .dialog { align-items: center; padding: 24px; }
  .dish-sheet {
    border-radius: 24px;
    border-bottom: 1.5px solid var(--brass);
    max-height: 90vh;
    padding-top: 14px;
  }
  .sheet-handle { display: none; }
}

@media (min-width: 1020px) {
  .dish-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 390px) {
  .kathakali-crest { width: 58px; height: 58px; }
  .cover-content { padding: 0 12px; gap: 11px; }
  .cover-lamp { width: 34px; height: 52px; }
  .cover-lamp-left { left: 4px; }
  .cover-lamp-right { right: 4px; }
}

@media (max-width: 360px) {
  .header-spacer { width: 32px; }
  .theme-toggle { padding: 0 9px; font-size: 10px; }
  .category-grid { gap: 8px; }
  .category-tile { padding: 8px; }
  .category-tile-copy strong { font-size: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
