/* ==========================================================================
   TMZ SUSHI DELIVERY - CARTA DIGITAL INTERACTIVA & LINK-IN-BIO
   Estilo: Dopaminérgico, Dark Gourmet Japonés, Ultra-rápido, Mobile-First
   ========================================================================== */

:root {
  --bg-deep: #0a0b0e;
  --bg-surface: #12141a;
  --bg-card: rgba(22, 26, 35, 0.88);
  --bg-card-hover: rgba(30, 36, 48, 0.95);
  --bg-glass: rgba(255, 255, 255, 0.05);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(230, 57, 70, 0.35);

  --accent-red: #E63946;
  --accent-red-hover: #D90429;
  --accent-salmon: #FF6B6B;
  --accent-gold: #F59E0B;
  --accent-gold-light: #FDE68A;
  --accent-green: #10B981;
  --accent-green-dark: #059669;
  --accent-avocado: #2DD4BF;

  --text-main: #FFFFFF;
  --text-muted: #94A3B8;
  --text-subtle: #64748B;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(230, 57, 70, 0.22);
  --shadow-glow-accent: 0 0 25px rgba(255, 107, 107, 0.35);

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  --transition-fast: 0.16s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-spring: 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-deep);
  color: var(--text-main);
  line-height: 1.45;
  min-height: 100vh;
  padding-bottom: 120px;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(230, 57, 70, 0.16) 0%, transparent 60%),
    radial-gradient(circle at 100% 40%, rgba(245, 158, 11, 0.07) 0%, transparent 50%),
    radial-gradient(circle at 0% 80%, rgba(230, 57, 70, 0.1) 0%, transparent 50%);
  background-attachment: fixed;
}

/* App Container */
.app-container {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 16px;
  position: relative;
}

/* ==========================================================================
   HEADER / HERO (Link in bio profile)
   ========================================================================== */
.hero-header {
  text-align: center;
  padding: 28px 8px 16px;
  position: relative;
}

.logo-wrapper {
  width: 105px;
  height: 105px;
  margin: 0 auto 14px;
  border-radius: var(--radius-full);
  padding: 4px;
  background: linear-gradient(135deg, #E63946, #F59E0B, #FF6B6B);
  box-shadow: 0 8px 25px rgba(230, 57, 70, 0.35);
  cursor: pointer;
  transition: transform var(--transition-spring);
  position: relative;
}

.logo-wrapper:active {
  transform: scale(0.92);
}

.logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-full);
  display: block;
  background: #000;
  border: 2px solid #000;
}

.brand-title {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.5px;
  color: #FFFFFF;
  margin-bottom: 4px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.brand-location {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-salmon);
  background: rgba(255, 107, 107, 0.1);
  padding: 4px 12px;
  border-radius: var(--radius-full);
  margin-bottom: 12px;
  border: 1px solid rgba(255, 107, 107, 0.2);
}

.brand-bio {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0 auto 16px;
  max-width: 480px;
}

.brand-bio strong {
  color: #FFFFFF;
}

/* Status Pill */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2px;
  margin-bottom: 18px;
  transition: all var(--transition-smooth);
}

.status-pill.open {
  background: rgba(16, 185, 129, 0.12);
  color: #34D399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-pill.closed {
  background: rgba(239, 68, 68, 0.12);
  color: #F87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-indicator-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: currentColor;
  box-shadow: 0 0 10px currentColor;
  animation: pulse-dot 2s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.85); }
}

/* Quick Action Buttons */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 18px;
}

.action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 4px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-main);
  text-decoration: none;
  font-size: 11.5px;
  font-weight: 600;
  transition: all var(--transition-fast);
}

.action-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.action-btn:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

.action-btn:active {
  transform: scale(0.95);
}

.action-btn.primary-highlight {
  background: linear-gradient(135deg, rgba(37, 211, 102, 0.25), rgba(18, 140, 126, 0.25));
  border-color: rgba(37, 211, 102, 0.5);
  color: #25D366;
}

/* Quick Search */
.search-wrapper {
  position: relative;
  margin-bottom: 8px;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--text-subtle);
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 13px 40px 13px 42px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  color: #FFFFFF;
  font-size: 14px;
  outline: none;
  transition: all var(--transition-smooth);
}

.search-input:focus {
  border-color: var(--accent-red);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.2);
}

.search-input::placeholder {
  color: var(--text-subtle);
}

.search-clear-btn {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
}

/* ==========================================================================
   STICKY CATEGORY BAR
   ========================================================================== */
.categories-bar-wrapper {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 11, 14, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 10px 0;
  margin: 0 -16px 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.categories-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0 16px;
  scrollbar-width: none;
}

.categories-bar::-webkit-scrollbar {
  display: none;
}

.category-pill {
  white-space: nowrap;
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  user-select: none;
}

.category-pill:hover {
  background: var(--bg-card-hover);
  color: #FFFFFF;
}

.category-pill.active {
  background: var(--accent-red);
  color: #FFFFFF;
  border-color: var(--accent-red);
  box-shadow: 0 4px 15px rgba(230, 57, 70, 0.4);
}

/* ==========================================================================
   MENU CONTENT & ITEM CARDS
   ========================================================================== */
.category-section {
  margin-bottom: 30px;
  scroll-margin-top: 70px;
}

.category-header {
  margin-bottom: 12px;
}

.category-title {
  font-size: 18px;
  font-weight: 800;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  gap: 8px;
}

.category-subtitle {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.items-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Product Card */
.product-card {
  display: flex;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px;
  gap: 12px;
  transition: all var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.product-card:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-sm);
}

.product-card.agotado {
  opacity: 0.55;
  filter: grayscale(0.7);
}

.card-img-wrapper {
  width: 100px;
  height: 100px;
  min-width: 100px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  background: #181c24;
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-smooth);
}

.product-card:hover .card-img {
  transform: scale(1.06);
}

.card-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
}

.card-header-line {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.card-badge {
  align-self: flex-start;
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: rgba(230, 57, 70, 0.16);
  color: var(--accent-salmon);
  border: 1px solid rgba(230, 57, 70, 0.3);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  color: #FFFFFF;
  line-height: 1.25;
}

.card-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 4px 0 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-footer-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.card-price {
  font-size: 16px;
  font-weight: 800;
  color: var(--accent-gold);
}

/* Add Button & Counter */
.btn-add {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--accent-red);
  color: #FFFFFF;
  border: none;
  padding: 7px 14px;
  border-radius: var(--radius-full);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 12px rgba(230, 57, 70, 0.3);
}

.btn-add:hover {
  background: var(--accent-red-hover);
  transform: translateY(-1px);
}

.btn-add:active {
  transform: scale(0.94);
}

.qty-stepper {
  display: inline-flex;
  align-items: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 2px;
}

.qty-btn {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #FFFFFF;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.qty-btn:active {
  background: rgba(255, 255, 255, 0.15);
}

.qty-value {
  min-width: 24px;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: #FFFFFF;
}

/* ==========================================================================
   FLOATING CART BAR
   ========================================================================== */
.floating-cart-bar {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  width: calc(100% - 32px);
  max-width: 608px;
  background: linear-gradient(135deg, #E63946, #D90429);
  color: #FFFFFF;
  padding: 12px 18px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 10px 30px rgba(230, 57, 70, 0.5), 0 0 20px rgba(0, 0, 0, 0.4);
  z-index: 99;
  cursor: pointer;
  transition: transform var(--transition-spring);
}

.floating-cart-bar.active {
  transform: translateX(-50%) translateY(0);
}

.cart-bar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cart-badge-count {
  width: 32px;
  height: 32px;
  background: #FFFFFF;
  color: var(--accent-red);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.cart-bar-info {
  display: flex;
  flex-direction: column;
}

.cart-bar-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.9;
}

.cart-bar-total {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -0.2px;
}

.cart-bar-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.2);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ==========================================================================
   MODAL BOTTOM SHEET
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-smooth);
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-sheet {
  width: 100%;
  max-width: 640px;
  max-height: 88vh;
  background: #141720;
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform var(--transition-spring);
  overflow: hidden;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.6);
}

.modal-overlay.active .modal-sheet {
  transform: translateY(0);
}

.modal-handle {
  width: 40px;
  height: 4px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: var(--radius-full);
  margin: 10px auto 4px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.modal-title {
  font-size: 17px;
  font-weight: 800;
  color: #FFFFFF;
}

.modal-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  color: var(--text-muted);
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #FFFFFF;
}

.modal-body {
  padding: 18px 20px;
  overflow-y: auto;
  max-height: calc(88vh - 140px);
}

.modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border-subtle);
  background: #0d0f15;
}

/* Cart Items inside Modal */
.cart-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
}

.cart-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  gap: 10px;
}

.cart-item-name {
  font-size: 13.5px;
  font-weight: 700;
  color: #FFFFFF;
}

.cart-item-price {
  font-size: 13px;
  font-weight: 800;
  color: var(--accent-gold);
}

/* Delivery vs Retiro Toggle */
.delivery-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  background: var(--bg-surface);
  padding: 4px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  border: 1px solid var(--border-subtle);
}

.delivery-tab {
  text-align: center;
  padding: 10px 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.delivery-tab.active {
  background: var(--accent-red);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(230, 57, 70, 0.4);
}

/* Forms */
.form-group {
  margin-bottom: 12px;
}

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 5px;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 11px 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #FFFFFF;
  font-size: 13.5px;
  outline: none;
  font-family: inherit;
  transition: border-color var(--transition-fast);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--accent-red);
}

.form-select option {
  background: #141720;
  color: #FFFFFF;
}

/* Summary Box */
.summary-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px;
  margin-top: 14px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 6px;
}

.summary-label {
  color: var(--text-muted);
}

.summary-total {
  font-size: 16px;
  font-weight: 800;
  border-top: 1px solid var(--border-subtle);
  padding-top: 8px;
  margin-top: 6px;
  color: var(--accent-gold);
}

/* Big WhatsApp Button */
.btn-whatsapp-order {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px;
  background: linear-gradient(135deg, #25D366, #128C7E);
  color: #FFFFFF;
  border: none;
  border-radius: var(--radius-full);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.btn-whatsapp-order:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.btn-whatsapp-order:active {
  transform: scale(0.98);
}

/* Footer Section */
.footer-section {
  text-align: center;
  padding: 40px 10px 20px;
  font-size: 13px;
  color: var(--text-muted);
  border-top: 1px solid var(--border-subtle);
  margin-top: 40px;
}

.footer-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  text-align: left;
}

.footer-logo {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
}

.footer-section a {
  color: var(--accent-salmon);
  text-decoration: none;
  font-weight: 600;
}

.btn-admin-trigger {
  margin-top: 16px;
  background: transparent;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  color: var(--text-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 11.5px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-admin-trigger:hover {
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.3);
}

/* Responsive tweaks */
@media (max-width: 360px) {
  .brand-title { font-size: 22px; }
  .card-img-wrapper { width: 85px; height: 85px; min-width: 85px; }
  .quick-actions { grid-template-columns: repeat(2, 1fr); }
}

