/* ======================================================== */
/* ESTILOS GLOBALES Y DISEÑO DARK-MODE DE ALTA FIDELIDAD     */
/* Pastelería Boutique "Dulces Momentos"                     */
/* ======================================================== */

@import url('https://fonts.googleapis.com/css2?family=Alex+Brush&family=Caveat:wght@400;600;700&family=Playfair+Display:ital,wght@0,400;0,600;0,700;0,900;1,400;1,600&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Space+Mono:wght@400;700&display=swap');

:root {
  --bg-main: #0c090c;
  --bg-surface: #140f13;
  --bg-card: #181317;
  --bg-card-hover: #1f181e;
  --border-subtle: #2a1e27;
  --border-card: #33222e;
  --accent-pink: #e03a6c;
  --accent-pink-hover: #be185d;
  --accent-pink-light: #f472b6;
  --accent-pink-glow: rgba(224, 58, 108, 0.35);
  --text-primary: #f8fafc;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
}

html {
  background-color: #0c090c;
  color: #f8fafc;
  scroll-behavior: smooth;
}

body {
  overflow-x: hidden !important;
  width: 100% !important;
  max-width: 100vw !important;
  background-color: #0c090c;
  font-family: 'Plus Jakarta Sans', sans-serif;
}

/* Tipografías especiales */
.font-serif {
  font-family: 'Playfair Display', Georgia, serif;
}

.font-script {
  font-family: 'Alex Brush', cursive;
}

.font-handwriting {
  font-family: 'Caveat', cursive;
}

.font-mono {
  font-family: 'Space Mono', monospace;
}

/* Scrollbars estilizados en tono oscuro y rosa */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: #0c090c;
}
::-webkit-scrollbar-thumb {
  background: rgba(224, 58, 108, 0.35);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(224, 58, 108, 0.7);
}

/* Efectos de resplandor rosa */
.glow-pink {
  box-shadow: 0 0 25px -5px rgba(224, 58, 108, 0.45);
}

.glow-pink-sm {
  box-shadow: 0 4px 15px -2px rgba(224, 58, 108, 0.35);
}

.text-gradient-pink {
  background: linear-gradient(135deg, #f472b6 0%, #e03a6c 50%, #db2777 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Tarjeta de producto con hover interactivo */
.product-card {
  background: #171216;
  border: 1px solid #2d1f2b;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover {
  transform: translateY(-6px);
  border-color: rgba(224, 58, 108, 0.5);
  box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.7), 0 0 20px -5px rgba(224, 58, 108, 0.25);
}

/* ======================================================== */
/* BARRA DE NAVEGACIÓN DE CATEGORÍAS CIRCULARES (3D & GLOW)  */
/* ======================================================== */
.category-nav-wrapper {
  background-color: #000000;
}

.category-circle-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: transparent;
  border: none;
  cursor: pointer;
  outline: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0.5rem;
}

.category-circle-btn {
  width: 76px;
  height: 76px;
  border-radius: 9999px;
  background: radial-gradient(circle at 35% 30%, #4a2330 0%, #2b131c 60%, #12080e 100%);
  border: 1.5px solid rgba(74, 35, 48, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.9), inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

@media (min-width: 640px) {
  .category-circle-btn {
    width: 90px;
    height: 90px;
  }
}

.category-circle-item:hover .category-circle-btn {
  transform: translateY(-4px) scale(1.05);
  border-color: rgba(233, 84, 179, 0.5);
  box-shadow: 0 15px 30px -5px rgba(0, 0, 0, 0.9), 0 0 20px rgba(233, 84, 179, 0.3);
}

.category-circle-item:hover .category-label {
  color: #ffffff;
}

/* Estado Activo: Resplandor rosa vibrante (#e954b3) */
.category-circle-item.active .category-circle-btn {
  border-color: #e954b3;
  box-shadow: 0 0 30px rgba(233, 84, 179, 0.75), 0 0 12px rgba(233, 84, 179, 0.5), inset 0 0 16px rgba(233, 84, 179, 0.4);
  transform: scale(1.06);
}

.category-circle-item.active .category-label {
  color: #e954b3 !important;
  text-shadow: 0 0 14px rgba(233, 84, 179, 0.65);
  font-weight: 700;
}

.category-icon-3d {
  filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.6));
  transition: transform 0.3s ease;
  font-size: 2rem;
  line-height: 1;
}

@media (min-width: 640px) {
  .category-icon-3d {
    font-size: 2.35rem;
  }
}

.category-circle-item:hover .category-icon-3d {
  transform: scale(1.12);
}

.category-circle-item.active .category-icon-3d {
  transform: scale(1.12);
  filter: drop-shadow(0 6px 12px rgba(233, 84, 179, 0.5));
}

.category-label {
  font-size: 0.825rem;
  font-weight: 500;
  color: #e2e8f0;
  transition: all 0.25s ease;
  letter-spacing: 0.01em;
}

/* ======================================================== */
/* MODAL RESPONSIVE DEL CARRITO ("TU PEDIDO")                */
/* ======================================================== */
.modal-carrito-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background-color: rgba(5, 3, 5, 0.85);
  backdrop-filter: blur(6px);
  transition: opacity 0.25s ease;
}

.modal-carrito-card {
  width: 100%;
  max-width: 550px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  background: #171216;
  border-radius: 1.5rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8), 0 0 30px -5px rgba(224, 58, 108, 0.2);
  border: 1px solid #33202e;
  overflow-y: auto;
  animation: modalEntrada 0.25s ease-out;
  color: #f8fafc;
}

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

/* Adaptación para móviles */
@media (max-width: 640px) {
  .modal-carrito-backdrop {
    padding: 0.5rem;
    align-items: flex-end;
  }

  .modal-carrito-card {
    max-width: 100% !important;
    width: 100% !important;
    max-height: 90vh;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
  }

  .metodos-entrega-grid {
    grid-template-columns: 1fr !important;
    gap: 0.5rem !important;
  }

  .form-control-input {
    width: 100% !important;
  }
}

/* ======================================================== */
/* IMPRESIÓN TÉRMICA DE TICKETS KDS (@media print)          */
/* ======================================================== */
@media print {
  body * {
    visibility: hidden;
  }
  #ticket-termico-impresion,
  #ticket-termico-impresion * {
    visibility: visible;
  }
  #ticket-termico-impresion {
    display: block !important;
    position: absolute;
    left: 0;
    top: 0;
    width: 78mm;
    margin: 0;
    padding: 8px;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    line-height: 1.25;
    color: #000 !important;
    background: #fff !important;
  }
  .ticket-termico .separador {
    border-top: 1px dashed #000;
    margin: 6px 0;
  }
  .ticket-termico .titulo {
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
  }
  .ticket-termico .subtitulo {
    font-size: 10px;
    text-align: center;
    margin-bottom: 6px;
  }
  .ticket-termico .item-fila {
    display: flex;
    justify-content: space-between;
    margin: 3px 0;
  }
  .ticket-termico .total-fila {
    font-size: 13px;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    margin-top: 6px;
  }
  @page {
    size: auto;
    margin: 0mm;
  }
}

/* ======================================================== */
/* CONTENEDOR TOAST NOTIFICATIONS                           */
/* ======================================================== */
#toast-container {
  position: fixed !important;
  bottom: 24px !important;
  left: 24px !important;
  right: auto !important;
  z-index: 9999 !important;
  max-width: 360px;
  width: calc(100vw - 48px);
  pointer-events: none !important;
}

#toast-container > div {
  pointer-events: auto !important;
}

/* ======================================================== */
/* ESTILOS Y ANIMACIONES DEL PORTAL DE AUTENTICACIÓN        */
/* ======================================================== */
@keyframes shakeAuth {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-7px); }
  40%, 80% { transform: translateX(7px); }
}

.animate-shake {
  animation: shakeAuth 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

.auth-input-valid {
  border-color: #10b981 !important;
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2) !important;
}

.auth-input-invalid {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.2) !important;
}

#seccion-auth-portal {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Forzar cursor pointer e interactividad garantizada */
#tab-btn-login,
#tab-btn-register,
#link-ir-registro,
#link-ir-login,
#btn-logout {
  cursor: pointer !important;
  pointer-events: auto !important;
}


