/* ═══════════════════════════════════════════════════════════════
   QR MENU  ·  allzin-inspired  ·  Mobile-first
   ═══════════════════════════════════════════════════════════════ */

@font-face {
  font-family: 'Abuget';
  src: url('../fonts/Abuget.ttf') format('truetype'),
       url('../fonts/Abuget.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg:        #FFFFFF;
  --bg-soft:   #F7F7F7;
  --surface:   #FFFFFF;
  --surface2:  #F2F2F2;
  --surface3:  #E8E8E8;

  --green:     #1A5C3A;
  --green-lt:  rgba(26,92,58,0.08);
  --handle:    #4E8B6C;

  --amber:     #D8B46C;
  --amber-dark:#C09A50;
  --amber-lt:  rgba(216,180,108,0.10);

  --text:      #1B1B1B;
  --text-2:    rgba(27,27,27,0.55);
  --text-3:    rgba(27,27,27,0.32);

  --border:    rgba(0,0,0,0.07);
  --border2:   rgba(0,0,0,0.13);

  --radius-lg: 20px;
  --radius:    14px;
  --radius-sm: 8px;

  --f-sans:    'Lato', -apple-system, sans-serif;
  --f-serif:   'Fraunces', Georgia, serif;
  --f-display: 'Abuget', 'Fraunces', cursive;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── DARK MODE ─────────────────────────────────────────────────── */
[data-theme="dark"] {
  --bg:        #111111;
  --bg-soft:   #1A1A1A;
  --surface:   #1C1C1E;
  --surface2:  #2C2C2E;
  --surface3:  #3A3A3C;

  --green:     #4ADE9A;
  --green-lt:  rgba(74,222,154,0.12);
  --handle:    #5DC8A0;

  --amber-dark:#E8C470;
  --amber-lt:  rgba(216,180,108,0.18);

  --text:      #F2F2F7;
  --text-2:    rgba(242,242,247,0.68);
  --text-3:    rgba(242,242,247,0.40);

  --border:    rgba(255,255,255,0.10);
  --border2:   rgba(255,255,255,0.22);
}

/* ── DARK MODE ÖZEL DÜZELTMELER ────────────────────────────────── */

/* Action bar: koyu yeşil üstünde beyaz yazı görünsün */
[data-theme="dark"] .action-btn--bill {
  background: #1E7A48;
}

/* Header scrolled gölgesi koyu arka planda görünsün */
[data-theme="dark"] .qr-header.scrolled {
  box-shadow: 0 2px 16px rgba(0,0,0,0.55);
}

/* Detay panel gölgesi */
[data-theme="dark"] .detail-panel {
  box-shadow: 0 -24px 60px rgba(0,0,0,0.70);
}

/* Action bar gölgesi */
[data-theme="dark"] .action-bar {
  box-shadow: 0 -4px 24px rgba(0,0,0,0.55);
}

/* Kapat butonu: hardcoded beyaz yerine tema yüzeyi */
[data-theme="dark"] .detail-close {
  background: var(--surface2);
  border-color: var(--border2);
  color: var(--text-2);
}

/* Modal arka plan */
[data-theme="dark"] .req-modal-box,
[data-theme="dark"] .req-modal-backdrop {
  box-shadow: 0 -24px 60px rgba(0,0,0,0.70);
}

/* Card hover gölgesi */
[data-theme="dark"] .pcard:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.50);
}

/* Pcard alt çizgisi */
[data-theme="dark"] .pcard-foot {
  border-top-color: rgba(255,255,255,0.10);
}

/* Search overlay gölge */
[data-theme="dark"] .search-box {
  box-shadow: 0 2px 12px rgba(0,0,0,0.40);
}

/* Başlıklar: karanlık temada yeşil yerine beyaz/açık metin */
[data-theme="dark"] .profile-name,
[data-theme="dark"] .req-modal-title,
[data-theme="dark"] .detail-name {
  color: var(--text);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-tap-highlight-color: transparent; scroll-behavior: smooth; }
body {
  font-family: var(--f-sans);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; }
button { font-family: inherit; cursor: pointer; }

/* ── SPLASH ────────────────────────────────────────────────────── */
.splash {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
  background: var(--bg);
}
.splash--exit { opacity: 0; transform: scale(1.03); pointer-events: none; }

.splash-bg {
  position: absolute;
  inset: 0;
  background: url('https://images.unsplash.com/photo-1555396273-367ea4eb4db5?q=80&w=900&auto=format&fit=crop')
    center/cover no-repeat;
  transform: scale(1.06);
  animation: splashZoom 9s ease-in-out infinite alternate;
}
@keyframes splashZoom {
  from { transform: scale(1.06); }
  to   { transform: scale(1.00); }
}
.splash-vignette {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top,
    rgba(255,255,255,0.97) 0%,
    rgba(255,255,255,0.5) 50%,
    rgba(255,255,255,0.2) 100%);
}
.splash-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 32px;
  animation: splashUp 1s var(--ease) 0.15s both;
}
@keyframes splashUp {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: none; }
}
.splash-eyebrow {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 0.85rem;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 12px;
}
.splash-title {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  line-height: 1;
}
.splash-title-italic {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.8rem, 8vw, 3rem);
  color: var(--text-2);
  letter-spacing: 3px;
}
.splash-title-bold {
  font-family: var(--f-display);
  font-size: clamp(3.2rem, 15vw, 6rem);
  letter-spacing: 4px;
  color: var(--green);
  line-height: 0.9;
}
.splash-cta {
  position: absolute;
  bottom: 48px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--amber);
  border: none;
  color: #fff;
  font-family: var(--f-sans);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 14px 30px;
  border-radius: 40px;
  white-space: nowrap;
  animation: splashUp 1s var(--ease) 0.45s both;
  transition: background 0.25s;
  box-shadow: 0 4px 20px rgba(192,120,48,0.35);
}
.splash-cta:hover { background: var(--amber-dark); }
.splash-cta svg { transition: transform 0.25s; }
.splash-cta:hover svg { transform: translateX(4px); }

/* ── APP SHELL ─────────────────────────────────────────────────── */
.app { padding-top: 65px; }

/* ── HEADER ────────────────────────────────────────────────────── */
.qr-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  height: 65px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}
.qr-header.scrolled {
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.qr-header-left { display: flex; align-items: center; }

.qr-back-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  color: var(--text-2);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  padding: 6px 12px 6px 8px;
  border-radius: 30px;
  border: 1.5px solid var(--border2);
  background: var(--surface2);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  white-space: nowrap;
}
.qr-back-btn:hover { color: var(--text); border-color: var(--amber); }
.qr-back-btn svg { flex-shrink: 0; }

.qr-logo {
  font-family: var(--f-display);
  font-size: 1.4rem;
  letter-spacing: 3px;
  color: var(--green);
  display: flex;
  align-items: center;
  height: 30px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}
.qr-logo img { height: 100%; object-fit: contain; }

.qr-header-right {
  display: flex;
  align-items: center;
  gap: 6px;
}
.qr-icon-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  flex-shrink: 0;
}
.qr-icon-btn:active { background: var(--surface3); color: var(--amber); }
.qr-lang-btn {
  font-family: var(--f-sans);
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.8px;
  width: auto;
  padding: 0 10px;
  border-radius: 20px;
}
/* eski search butonu artık qr-icon-btn kullanıyor */
.qr-search-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.88rem;
  transition: background 0.2s, color 0.2s;
}
.qr-search-btn:active { background: var(--surface3); color: var(--amber); }

/* ── ACTION BAR ────────────────────────────────────────────────── */
.action-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 300;
  display: flex;
  gap: 0;
  background: var(--surface);
  border-top: 1px solid var(--border2);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.10);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.action-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  padding: 14px 10px;
  font-family: var(--f-sans);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.4px;
  cursor: pointer;
  transition: filter 0.18s;
}
.action-btn:active { filter: brightness(0.9); }
.action-btn--waiter {
  background: var(--amber);
  color: #fff;
  border-right: 1px solid rgba(255,255,255,0.2);
}
.action-btn--bill {
  background: var(--green);
  color: #fff;
}

/* main içeriği action bar'a çakışmasın */
.qr-main { padding-bottom: 70px; }

/* ── MASA NUMARASI MODAL ───────────────────────────────────────── */
.req-modal {
  position: fixed;
  inset: 0;
  z-index: 600;
  display: flex;
  align-items: flex-end;
  pointer-events: none;
}
.req-modal.open { pointer-events: all; }
.req-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.3s;
}
.req-modal.open .req-modal-backdrop { opacity: 1; }
.req-modal-box {
  position: relative;
  z-index: 1;
  background: var(--surface);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  width: 100%;
  padding: 28px 22px 40px;
  transform: translateY(100%);
  transition: transform 0.38s var(--ease);
  text-align: center;
}
.req-modal.open .req-modal-box { transform: translateY(0); }
.req-modal-icon { font-size: 2.4rem; margin-bottom: 10px; }
.req-modal-title {
  font-family: var(--f-serif);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--green);
  margin-bottom: 20px;
}
.req-modal-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 8px;
  text-align: left;
}
.req-modal-input {
  width: 100%;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--f-display);
  font-size: 2rem;
  letter-spacing: 4px;
  text-align: center;
  padding: 14px;
  outline: none;
  transition: border-color 0.2s;
  margin-bottom: 8px;
}
.req-modal-input:focus { border-color: var(--amber); }
.req-modal-error {
  font-size: 0.75rem;
  color: #e53e3e;
  min-height: 18px;
  margin-bottom: 16px;
  text-align: left;
}
.req-modal-btns {
  display: flex;
  gap: 10px;
}
.req-modal-cancel {
  flex: 1;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text-2);
  font-family: var(--f-sans);
  font-size: 0.88rem;
  font-weight: 700;
  padding: 14px;
  cursor: pointer;
  transition: background 0.2s;
}
.req-modal-send {
  flex: 2;
  background: var(--amber);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: var(--f-sans);
  font-size: 0.88rem;
  font-weight: 800;
  padding: 14px;
  cursor: pointer;
  transition: filter 0.2s;
}
.req-modal-send:active { filter: brightness(0.9); }
.req-modal-send:disabled { opacity: 0.6; cursor: not-allowed; }

/* ── TOAST ─────────────────────────────────────────────────────── */
.qr-toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  z-index: 700;
  background: var(--text);
  color: var(--bg);
  font-family: var(--f-sans);
  font-size: 0.88rem;
  font-weight: 700;
  padding: 12px 22px;
  border-radius: 30px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.3s;
  max-width: 90vw;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.18);
}
.qr-toast--show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.qr-toast--success { background: #1a5c3a; color: #fff; }
.qr-toast--error   { background: #c53030; color: #fff; }

/* ── HERO BANNER ───────────────────────────────────────────────── */
.hero-banner {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: var(--surface2);
  aspect-ratio: 16/9;
  max-height: 280px;
  touch-action: pan-y;
}
.hero-slides { position: relative; width: 100%; height: 100%; }
.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.6s var(--ease);
}
.hero-slide.active { opacity: 1; }
.hero-slide img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--green-lt) 0%, var(--amber-lt) 100%);
  color: var(--text-3);
  font-size: 2.5rem;
}

/* Dots */
.hero-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}
.hero-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.25s, transform 0.25s;
}
.hero-dot.active { background: #fff; transform: scale(1.25); }

/* Arrows */
.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(6px);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  transition: background 0.2s;
}
.hero-arrow:hover { background: rgba(255,255,255,0.95); }
.hero-arrow--prev { left: 10px; }
.hero-arrow--next { right: 10px; }

/* ── PROFILE SECTION ───────────────────────────────────────────── */
.profile-section {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 16px 14px;
  border-bottom: 1px solid var(--border);
}
.profile-logo {
  width: 68px; height: 68px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--surface2);
  flex-shrink: 0;
  border: 1px solid var(--border2);
}
.profile-logo img {
  width: 100%; height: 100%;
  object-fit: contain;
  padding: 6px;
}
.profile-logo-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--f-display);
  font-size: 1.4rem;
  letter-spacing: 2px;
  color: var(--green);
}
.profile-info { flex: 1; min-width: 0; }
.profile-name {
  font-family: var(--f-serif);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--green);
  line-height: 1.15;
  margin-bottom: 3px;
}
.profile-handle {
  font-size: 0.78rem;
  color: var(--handle);
  font-weight: 600;
  margin-bottom: 7px;
}
.profile-bio {
  font-size: 0.78rem;
  line-height: 1.55;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.profile-site-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
  font-family: var(--f-sans);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--green);
  text-decoration: none;
  padding: 6px 13px;
  border-radius: 30px;
  background: var(--green-lt);
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
  transition: background 0.25s, color 0.25s, box-shadow 0.25s, transform 0.2s;
}
.profile-site-link i { font-size: 0.54rem; transition: transform 0.25s var(--ease); }
.profile-site-link:hover {
  background: var(--green);
  color: var(--bg);
  box-shadow: 0 6px 18px rgba(26,92,58,0.28);
  transform: translateY(-2px);
}
.profile-site-link:hover i { transform: translate(2px,-2px); }
.profile-site-link:active { transform: translateY(0) scale(0.97); }


/* ── KATEGORİ KARTI GRİD ───────────────────────────────────────── */
.cat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 14px 14px 80px;
}
.cat-tile {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  border: 1px solid var(--border);
  transition: transform 0.22s var(--ease), box-shadow 0.22s;
  -webkit-user-select: none;
  user-select: none;
  animation: cardIn 0.45s var(--ease) var(--delay, 0ms) both;
}
.cat-tile:active { transform: scale(0.96); }
.cat-tile-img-wrap {
  width: 100%;
  aspect-ratio: 1 / 1;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--surface2);
}
.cat-tile-img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s var(--ease);
}
.cat-tile:hover .cat-tile-img-wrap img { transform: scale(1.06); }
.cat-tile-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-3);
  font-size: 2rem;
}
.cat-tile-bar {
  flex: 1 1 auto;
  background: var(--amber);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.cat-tile-name {
  font-family: var(--f-sans);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #fff;
  line-height: 1.2;
}
.cat-tile-count {
  font-size: 0.6rem;
  font-weight: 700;
  color: rgba(255,255,255,.75);
  background: rgba(255,255,255,.18);
  padding: 2px 7px;
  border-radius: 20px;
  flex-shrink: 0;
  white-space: nowrap;
}

/* ── ÜRÜN LİSTESİ GÖRÜNÜMÜ ─────────────────────────────────────── */
.prod-view-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 65px;
  z-index: 100;
  background: var(--bg);
}
.prod-back-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 50%;
  color: var(--text-2);
  font-size: 0.82rem;
  cursor: pointer;
  flex-shrink: 0;
  transition: color 0.2s, border-color 0.2s;
}
.prod-back-btn:hover { color: var(--text); border-color: var(--amber); }

.prod-cat-nav {
  display: flex;
  overflow-x: auto;
  scrollbar-width: none;
  gap: 6px;
  flex: 1;
}
.prod-cat-nav::-webkit-scrollbar { display: none; }
.prod-cat-pill {
  flex-shrink: 0;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 30px;
  color: var(--text-2);
  font-family: var(--f-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  padding: 7px 14px;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.22s, color 0.22s, border-color 0.22s;
}
.prod-cat-pill.active {
  background: var(--amber);
  border-color: var(--amber);
  color: #fff;
}
.prod-view-grid-wrap { padding: 14px 0 80px; }

/* ── SEARCH OVERLAY ────────────────────────────────────────────── */
.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  padding: 60px 16px 24px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px);
  transition: opacity 0.28s var(--ease), transform 0.28s var(--ease);
}
.search-overlay.open { opacity: 1; pointer-events: all; transform: none; }
.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 0 14px;
  margin-bottom: 18px;
  flex-shrink: 0;
}
.search-box-icon { color: var(--text-3); font-size: 0.82rem; }
.search-input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--text);
  font-family: var(--f-sans);
  font-size: 1rem;
  padding: 13px 0;
  caret-color: var(--amber);
}
.search-input::placeholder { color: var(--text-3); }
.search-close {
  background: none;
  border: none;
  color: var(--text-3);
  font-size: 1rem;
  padding: 6px;
  transition: color 0.2s;
}
.search-close:active { color: var(--text); }
.search-results-wrap { overflow-y: auto; flex: 1; }
.sr-empty { color: var(--text-3); font-size: 0.88rem; padding: 20px 0; font-style: italic; }
.sr-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: none;
  border: none;
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: padding-left 0.18s;
}
.sr-row:hover { padding-left: 4px; }
.sr-thumb {
  width: 48px; height: 48px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
  background: var(--surface2);
}
.sr-thumb--empty { background: var(--surface3); }
.sr-info { flex: 1; min-width: 0; }
.sr-name {
  display: block;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sr-price {
  display: block;
  font-family: var(--f-sans);
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--amber);
  margin-top: 2px;
}
.sr-chev { color: var(--text-3); font-size: 0.72rem; }

/* ── PLACEHOLDER TABS ──────────────────────────────────────────── */
.tab-placeholder {
  display: none;
  text-align: center;
  padding: 80px 30px;
  color: var(--text-3);
  font-size: 0.9rem;
  font-style: italic;
}
.tab-placeholder.visible { display: block; }

/* ── MAIN ──────────────────────────────────────────────────────── */
.qr-main { padding: 0; }
.empty-state {
  text-align: center;
  padding: 80px 30px;
  color: var(--text-3);
  font-style: italic;
}
.cat-empty {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 20px 18px 40px;
  color: var(--text-3);
  font-size: 0.8rem;
  font-style: italic;
}
.cat-empty i { font-size: 0.7rem; }

/* ── PRODUCT GRID ──────────────────────────────────────────────── */
.product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 0 14px;
}

/* ── PRODUCT CARD ──────────────────────────────────────────────── */
.pcard {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  animation: cardIn 0.45s var(--ease) var(--delay, 0ms) both;
  transition: transform 0.18s var(--ease), box-shadow 0.18s;
  -webkit-user-select: none;
  user-select: none;
}
@keyframes cardIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}
.pcard:active { transform: scale(0.97); box-shadow: none; }

/* Image shell */
.pcard-img-shell {
  position: relative;
  overflow: hidden;
  background: var(--surface2);
  aspect-ratio: 1 / 1;
  flex-shrink: 0;
}
.pcard-img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.45s var(--ease);
}
.pcard:hover .pcard-img { transform: scale(1.05); }
.pcard-img-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-3);
  font-size: 1.8rem;
  background: var(--surface2);
  aspect-ratio: 1 / 1;
}

/* Badge */
.pcard-badge {
  position: absolute;
  top: 8px; left: 8px;
  background: #D43020;
  color: #fff;
  font-family: var(--f-sans);
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 7px;
  border-radius: 4px;
}
.pcard-badge--alt { background: var(--amber); }

/* Card info */
.pcard-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 11px 11px 13px;
  gap: 5px;
}
.pcard-name {
  font-family: var(--f-sans);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.pcard-desc {
  font-size: 0.7rem;
  line-height: 1.45;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.pcard-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  margin-top: auto;
}
.pcard-price {
  font-family: var(--f-sans);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--amber);
  line-height: 1;
}
.pcard-kcal {
  font-size: 0.6rem;
  color: var(--text-3);
  font-weight: 700;
  white-space: nowrap;
}
.pcard-kcal i { color: #e07a3a; margin-right: 2px; }

/* ── DETAIL OVERLAY ────────────────────────────────────────────── */
.detail-overlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: flex;
  align-items: flex-end;
  pointer-events: none;
}
.detail-overlay.open { pointer-events: all; }
.detail-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.38);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.32s;
  cursor: pointer;
}
.detail-overlay.open .detail-backdrop { opacity: 1; }

.detail-panel {
  position: relative;
  z-index: 1;
  background: var(--surface);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  width: 100%;
  max-height: 92%;
  overflow-y: auto;
  overscroll-behavior: contain;
  transform: translateY(100%);
  transition: transform 0.4s var(--ease);
  box-shadow: 0 -20px 50px rgba(0,0,0,0.10);
}
.detail-overlay.open .detail-panel { transform: translateY(0); }

.detail-close {
  position: absolute;
  top: 12px; right: 12px;
  z-index: 10;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border2);
  background: var(--surface);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  transition: background 0.2s, color 0.2s;
}
.detail-close:active { background: var(--surface3); color: var(--text); }

.detail-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4/5;
  overflow: hidden;
  background: var(--surface2);
}
.detail-img-wrap img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.detail-img-wrap--empty { aspect-ratio: 2/1; }
.detail-img-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 15%;
  background: linear-gradient(to top, var(--surface), transparent);
}

.detail-content { padding: 16px 18px 48px; }
.detail-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 10px; }
.dtag {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 3px;
  background: var(--surface2);
  color: var(--text-2);
  border: 1px solid var(--border2);
}

.detail-name-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.detail-name {
  font-family: var(--f-serif);
  font-size: clamp(1.6rem, 6vw, 2.2rem);
  font-weight: 600;
  color: var(--green);
  line-height: 1.1;
  flex: 1;
  min-width: 0;
}
.detail-badge {
  flex-shrink: 0;
  font-family: var(--f-sans);
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  background: #D43020;
  color: #fff;
  margin-top: 6px;
}

.detail-nutrition {
  display: flex;
  gap: 18px;
  align-items: center;
  background: var(--surface2);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  margin-bottom: 14px;
  border: 1px solid var(--border);
}
.nut-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  flex: 1;
  text-align: center;
}
.nut-item i { font-size: 0.72rem; color: var(--amber); margin-bottom: 2px; }
.nut-item span {
  font-family: var(--f-sans);
  font-size: 1.05rem;
  letter-spacing: 0.5px;
  color: var(--text);
  line-height: 1;
}
.nut-item em {
  font-style: normal;
  font-size: 0.58rem;
  color: var(--text-3);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.detail-desc {
  font-size: 0.86rem;
  line-height: 1.7;
  color: var(--text-2);
  margin-bottom: 20px;
}

.detail-price-bar {
  display: flex;
  gap: 24px;
  align-items: flex-end;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.detail-price-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 4px;
}
.detail-price {
  font-family: var(--f-sans);
  font-size: 28px;
  letter-spacing: 1px;
  color: var(--amber);
  line-height: 1;
}
.detail-allergen { font-size: 0.76rem; color: var(--text-2); line-height: 1.5; max-width: 180px; }

/* ── DESKTOP ────────────────────────────────────────────────────── */
@media (min-width: 580px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 0 16px; }
  .hero-banner { max-height: 340px; }
}
@media (min-width: 860px) {
  .qr-main { max-width: 1060px; margin: 0 auto; }
  .product-grid { grid-template-columns: repeat(4, 1fr); }
  .detail-panel {
    left: 50%;
    right: auto;
    width: min(500px, 96vw);
    transform: translateX(-50%) translateY(100%);
    border-radius: var(--radius-lg);
  }
  .detail-overlay.open .detail-panel { transform: translateX(-50%) translateY(0); }
  .profile-section { max-width: 1060px; margin: 0 auto; }
  .hero-banner { max-height: 420px; }
}

/* ── REDUCED MOTION ─────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
