/* ==========================================================================
   SERVD. ROLE 1 — CUSTOMER (DINER) WEB STYLES
   100% Parity with Mockup & Flutter Reference (9:16 & 16:9 Adaptive)
   ========================================================================== */

/* Camera QR Scanner Screen */
.cust-scanner-view {
  position: relative;
  flex: 1;
  background: #0A0A0C;
  color: #FFFFFF;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px 18px 24px;
  overflow-x: hidden;
  overflow-y: auto;
}

.scanner-ambient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 42%, rgba(255, 214, 153, 0.16) 0%, rgba(10, 10, 12, 0.92) 74%),
    url('https://images.unsplash.com/photo-1517248135467-4c7edcad34c4?auto=format&fit=crop&w=900&q=80') center/cover no-repeat;
  filter: brightness(0.42);
  pointer-events: none;
}

.scanner-hud {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.glass-dark-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(28, 28, 30, 0.72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 0.5px solid rgba(255, 255, 255, 0.18);
  padding: 6px 12px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: #FFFFFF;
}

.scanner-stage-center {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.qr-reticle {
  position: relative;
  width: 210px;
  height: 210px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: transparent;
  border: none;
}

.qr-corner {
  position: absolute;
  width: 30px;
  height: 30px;
  border-color: #FFD60A;
  border-style: solid;
  transition: all 0.3s var(--ios-spring);
}

.qr-tl { top: 0; left: 0; border-width: 3.5px 0 0 3.5px; border-top-left-radius: 20px; }
.qr-tr { top: 0; right: 0; border-width: 3.5px 3.5px 0 0; border-top-right-radius: 20px; }
.qr-bl { bottom: 0; left: 0; border-width: 0 0 3.5px 3.5px; border-bottom-left-radius: 20px; }
.qr-br { bottom: 0; right: 0; border-width: 0 3.5px 3.5px 0; border-bottom-right-radius: 20px; }

.table-qr-tile {
  width: 164px;
  height: 164px;
  background: #FFFFFF;
  border-radius: 22px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45), 0 0 28px rgba(0, 122, 255, 0.22);
  position: relative;
  overflow: hidden;
}

.scan-laser {
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #FFD60A, transparent);
  box-shadow: 0 0 10px #FFD60A;
  animation: sweepLaser 2.2s ease-in-out infinite;
}

@keyframes sweepLaser {
  0%, 100% { top: 14px; opacity: 0.4; }
  50% { top: 146px; opacity: 1; }
}

.venue-link-pill {
  background: rgba(0, 122, 255, 0.18);
  color: #4DA3FF;
  border: 0.5px solid rgba(0, 122, 255, 0.32);
  padding: 7px 14px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.scanner-bottom-cta {
  position: relative;
  z-index: 2;
  width: min(420px, 100%);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Digital Menu Screen */
.cust-menu-view {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: var(--ios-bg-grouped);
  position: relative;
}

.cust-nav-header {
  background: var(--ios-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  padding: 12px 18px;
  border-bottom: 0.5px solid var(--ios-separator);
  z-index: 20;
  flex-shrink: 0;
}

.cust-header-inner {
  max-width: 1060px;
  margin: 0 auto;
  width: 100%;
}

.cust-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 14px 18px 104px;
}

.cust-scroll::-webkit-scrollbar {
  display: none;
}

.cust-content-inner {
  max-width: 1060px;
  margin: 0 auto;
  width: 100%;
}

/* Active Table Order Live Tracker Card */
.live-tracker-card {
  background: var(--ios-bg-elevated);
  border-radius: 20px;
  padding: 16px;
  margin-bottom: 18px;
  border: 0.5px solid var(--ios-separator-light);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.stepper-wrap {
  position: relative;
  display: flex;
  justify-content: space-between;
  margin: 16px 4px 12px;
}

.stepper-line-bg {
  position: absolute;
  top: 9px;
  left: 10px;
  right: 10px;
  height: 3.5px;
  border-radius: 10px;
  background: var(--ios-bg-secondary);
}

.stepper-line-fill {
  position: absolute;
  top: 9px;
  left: 10px;
  height: 3.5px;
  border-radius: 10px;
  background: var(--ios-green);
  transition: width 0.45s var(--ios-spring);
}

.step-item {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.step-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--ios-bg-elevated);
  border: 2px solid var(--ios-separator);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  color: transparent;
}

.step-item.done .step-dot {
  background: var(--ios-green);
  border-color: var(--ios-green);
  color: #FFFFFF;
}

.step-item.current .step-dot {
  border-color: var(--ios-orange);
}

/* Menu Section & Responsive 9:16 / 16:9 Grid */
.cust-section-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.4px;
  color: var(--ios-label-primary);
  margin: 6px 2px 10px;
}

.cust-dish-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: 18px;
}

@media (min-width: 721px) and (min-aspect-ratio: 1/1) {
  .cust-dish-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.cust-dish-card {
  background: var(--ios-bg-elevated);
  border-radius: 16px;
  padding: 12px;
  border: 0.5px solid var(--ios-separator-light);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.dish-thumb-wrap {
  position: relative;
  width: 86px;
  height: 86px;
  flex-shrink: 0;
}

.dish-thumb {
  width: 86px;
  height: 86px;
  border-radius: 14px;
  object-fit: cover;
  background: var(--ios-bg-secondary);
  display: block;
}

.dish-thumb-fallback {
  width: 86px;
  height: 86px;
  border-radius: 14px;
  background: var(--ios-bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.dish-add-pill {
  position: absolute;
  bottom: -6px;
  left: 4px;
  right: 4px;
  height: 30px;
  border-radius: 100px;
  background: #FFFFFF;
  color: var(--ios-blue);
  border: 0.8px solid var(--ios-separator);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (min-width: 721px) and (min-aspect-ratio: 1/1) {
  .cust-scanner-view {
    padding: 16px 24px 18px;
  }

  .scanner-stage-center {
    gap: 10px;
  }

  .qr-reticle {
    width: 184px;
    height: 184px;
  }

  .table-qr-tile {
    width: 146px;
    height: 146px;
  }
}

.dish-add-pill.in-cart {
  background: var(--ios-blue);
  border-color: var(--ios-blue);
  color: #FFFFFF;
}

.dish-86-pill {
  position: absolute;
  bottom: -6px;
  left: 6px;
  right: 6px;
  height: 24px;
  border-radius: 100px;
  background: rgba(229, 229, 234, 0.92);
  color: var(--ios-label-tertiary);
  font-size: 10.5px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Floating Bottom Cart Dock */
.floating-cart-dock {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  width: min(440px, calc(100% - 32px));
  z-index: 50;
}

.floating-cart-inner {
  width: 100%;
  height: 52px;
  padding: 0 16px;
  border-radius: 100px;
  border: none;
  background: rgba(28, 28, 30, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
  cursor: pointer;
}

/* Exit Pass Screen */
.cust-exit-view {
  flex: 1;
  background: var(--ios-bg-grouped);
  padding: 18px 20px 22px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}

.exit-pass-inner {
  max-width: 460px;
  width: 100%;
  margin: 0 auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}

.wallet-card {
  background: linear-gradient(150deg, #1C1C1E 0%, #2C2C2E 100%);
  color: #FFFFFF;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
}

.pin-digit-box {
  width: 52px;
  height: 56px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.20);
  font-size: 28px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
}

/* Sheet Cards */
.sheet-card {
  background: var(--ios-bg-elevated);
  border-radius: 14px;
  border: 0.5px solid var(--ios-separator-light);
  overflow: hidden;
  margin-bottom: 14px;
}

.addon-row-btn {
  width: 100%;
  background: transparent;
  border: none;
  padding: 11px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  border-bottom: 0.5px solid var(--ios-separator-light);
}

.addon-row-btn:last-child {
  border-bottom: none;
}
