/* ===== RESET ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', 'Segoe UI', sans-serif;
  background: #f8fafc;
  color: #1e293b;
  line-height: 1.6;
}

/* ===== HEADER ===== */
header {
  background: #1233DA;
  color: white;
  /*padding: 10px 5%;*/ 
  display: flex;
  /* THIS LINE pushes logo to the left and menu to the right */
  justify-content: space-between; 
  align-items: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* BIGGER LOGO */
.logo-container img {
  height: 150px; /* Adjusted to be prominent but sleek */
  width: auto;
  display: block;
  transition: transform 0.3s ease;
}

.logo-container img:hover {
  transform: scale(1.05);
}

/* MENU TO THE RIGHT */
.main-nav {
  display: flex;
  align-items: center;
  gap: 15px; /* Space between the links */
}

.nav-item {
  color: white;
  text-decoration: none;
  font-weight: 600;
  padding: 10px 15px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 8px; /* Space for the icons */
  transition: 0.3s;
}

.nav-item:hover:not(.nav-cta) {
  background: rgba(255, 255, 255, 0.15);
}

/* EL BOTÓN "HACER PEDIDO" PROFESIONAL */
.nav-cta {
  background-color: #ffffff;    /* Initial: White background */
  color: #1233DA !important;    /* Initial: Blue text */
  border: 2px solid #FCD116;    /* White border for the hover transition */
  padding: 8px 22px;
  border-radius: 50px;          /* Professional Pill shape */
  font-weight: 700;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Smooth expansion */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Ensure the icon starts blue */
.nav-cta i {
  color: #1233DA !important;
  transition: all 0.3s ease;
}

/* THE HOVER EFFECT: Change to Blue & Expand */
.nav-cta:hover {
  background-color: #12da79;    /* Changes to Blue */
  color: #ffffff !important;    /* Changes text to White */
  transform: scale(1.08);       /* Expansion effect */
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  border: 2px solid #ffffff;    /* Keeps white border visible on blue */
}

/* Make sure the icon also turns white on hover */
.nav-cta:hover i {
  color: #ffffff !important;
  transform: rotate(-10deg);    /* Subtle icon movement */
}

/* MOBILE FIX */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    padding: 15px;
    gap: 15px;
  }
}


/* ===== HERO ===== */
.hero {
  padding: 100px 20px;
  text-align: center;
  background: linear-gradient(135deg, #2563eb, #1e40af);
  color: white;
}

.hero h2 {
  font-size: 40px;
  margin-bottom: 15px;
  font-weight: 700;
}

.hero p {
  font-size: 18px;
  opacity: 0.9;
}

/* ===== CATALOGO ===== */
.catalogo {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  padding: 60px 8%;
}

/* ===== TARJETAS ===== */
.libro {
  background: white;
  padding: 20px;
  border-radius: 16px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.06);
  transition: all 0.3s ease;
  border: 1px solid #e2e8f0;
}

.libro:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 35px #FCD116;
}

/* ===== IMAGENES ===== */
.libro img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 15px;
}

/* ===== FORMULARIOS ===== */
.formulario {
  padding: 20px; /* Reduced vertical padding since we use margin now */
  max-width: 600px;
  /* 120px top margin to clear the sticky header */
  margin: 120px auto 40px; 
  display: flex;
  flex-direction: column;
  gap: 18px;
  background: white; /* Optional: helps the form stand out */
  border-radius: 8px;
    margin-top: 140px; 
}

/* Mobile adjustment: if the header gets taller on small screens */
@media (max-width: 768px) {
  .formulario {
    margin-top: 140px; 
  }
}

input, select, textarea {
  padding: 14px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  font-size: 14px;
  transition: 0.3s;
  background: #ffffff;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}

/* ===== BOTONES ===== */
button {
  padding: 12px;
  background: #2a9d8f;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(37,99,235,0.3);
}

/* ===== CONTENIDO ===== */
.contenido {
  max-width: 900px;
  margin: 60px auto;
  padding: 40px;
  background: white;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
  border: 1px solid #e2e8f0;
}

/* ===== FOOTER ===== */
/* ===== FOOTER (FIXED & RESPONSIVE) ===== */
footer {
  background: #0f172a;
  color: #cbd5e1;
  text-align: center;
  padding: 40px 20px; /* Añadí padding para que respire */
  margin-top: 60px;
  font-size: 14px;
  width: 100%;
  overflow: clip; /* Evita que cualquier contenido se salga */
}

footer img {
  max-width: 100%;    /* La imagen nunca será más ancha que el celular */
  height: auto;       /* Mantiene la proporción */
  display: inline-block;
  margin-bottom: 20px;
  /* Opcional: limita el tamaño máximo en desktop para que no sea gigante */
  width: 300px; 
}

/* Ajuste específico para pantallas muy pequeñas */
@media (max-width: 480px) {
  footer {
    padding: 30px 15px;
  }
  footer img {
    width: 80%; /* En móviles pequeños se hace un poco más chica */
  }
}
/* ===== MODAL ===== */
/* ===== MODAL FIXED & CENTERED ===== */
.modal {
  display: none; /* Hidden by default, changed to 'flex' via JS */
  position: fixed;
  z-index: 2000; /* Must be higher than header's z-index (1000) */
  top: 0;
  left: 0;
  width: 100vw;  /* Use Viewport Width */
  height: 100vh; /* Use Viewport Height */
  background: rgba(0, 0, 0, 0.7); /* Darker overlay for focus */
  
  /* Perfect Centering */
  justify-content: center;
  align-items: center;
  
  /* Prevent interaction with background */
  backdrop-filter: blur(4px); 
}

.modal-contenido {
  background: white;
  padding: 25px;
  border-radius: 15px;
  max-width: 500px;
  width: 90%; /* Responsive on mobile */
  max-height: 90vh; /* Prevents crashing with screen edges */
  overflow-y: auto; /* Scroll if content is too long */
  position: relative;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  animation: modalScale 0.3s ease-out;
}

/* Optional: Smooth pop-up animation */
@keyframes modalScale {
  from { transform: scale(0.8); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-contenido img {
  width: 100%;
  border-radius: 8px;
  margin-bottom: 15px;
}

/* MODAL CLOSE BUTTON (The X) */
.cerrar {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  color: #aaa;
  cursor: pointer;
  line-height: 1;
  transition: all 0.2s ease;
  z-index: 2001; /* Above modal content */
}

.cerrar:hover {
  color: #1233DA; /* Turns your brand blue on hover */
  transform: scale(1.2);
}

/* Ensure the modal content is relative so the X can anchor to it */
.modal-contenido {
  position: relative; 
  padding: 40px 30px 30px; /* Extra top padding so content doesn't hit the X */
  background: white;
  border-radius: 15px;
}

.btn-whatsapp {
  display: block;
  background-color: #25d366; /* Verde oficial de WhatsApp */
  color: white;
  padding: 10px 20px;
  text-align: center;
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  margin-top: 15px;
}

.btn-whatsapp:hover {
  background-color: #128c7e;
}

/* Container for filters */
.filtros {
  padding: 20px;
  text-align: center;
  background: #f8f9fa;
  border-bottom: 1px solid #eee;
}

/* Individual Button Styling */
.filtros button {
  background-color: white;
  color: #1233DA; /* Your Brand Blue */
  border: 2px solid #1233DA;
  padding: 10px 18px;
  margin: 5px;
  border-radius: 25px; /* Rounded pill shape */
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease; /* Smooth transition */
  font-size: 14px;
}

/* HOVER EFFECT (Remark) */
.filtros button:hover {
  background-color: #1233DA;
  color: white;
  transform: translateY(-2px); /* Slight lift */
  box-shadow: 0 4px 12px rgba(18, 51, 218, 0.2);
  border: 2px solid #FCD116;    /* White border for the hover transition */

}

/* ACTIVE STATE (When clicked/selected) */
.filtros button.active {
  background-color: #1233DA;
  color: white;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

/* Search Input Styling */
#buscador {
  padding: 10px 20px;
  border: 2px solid #ddd;
  border-radius: 25px;
  margin-left: 15px;
  outline: none;
  transition: border-color 0.3s;
  width: 250px;
}

#buscador:focus {
  border-color: #FCD116;
}
/* Step Control */
.form-step { display: none; padding: 20px; background: white; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.1); }
.form-step.active { display: block; animation: fadeIn 0.4s ease; }

/* Progress Bar Styling */
.step-indicator { display: flex; justify-content: space-around; margin-bottom: 30px; }
.step { padding: 10px 20px; border-bottom: 4px solid #ddd; color: #999; font-weight: bold; flex: 1; text-align: center; }
.step.active { border-color: #1233DA; color: #1233DA; }

/* Button Styling */
/* CONTAINER FOR BUTTONS */
.step-buttons {
  display: flex;
  justify-content: flex-end; /* Aligns items to the right */
  gap: 15px;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #f1f5f9; /* Subtle divider */
}

/* MAIN ACTION BUTTONS (Next & Submit) */
/* CONTAINER FOR BUTTONS */
.step-buttons {
  display: flex;
  justify-content: flex-end; 
  gap: 15px;
  margin-top: 30px;
}

/* MATCHING CTA STYLE (Next & Submit) */
.btn-next, .btn-submit {
  background-color: #ffffff;    /* Initial: White background */
  color: #0b9a68 !important;    /* Initial: Green text */
  border: 2px solid #0b9a68;    /* Green border */
  padding: 10px 25px;
  border-radius: 50px;          /* Match Pill shape */
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  text-transform: uppercase;
  font-size: 0.85rem;
}

/* HOVER EFFECT: Invert to Green */
.btn-next:hover, .btn-submit:hover {
  background-color: #12da79;    /* Changes to Bright Green */
  color: #ffffff !important;    /* Changes text to White */
  border-color: #ffffff;        /* White border on hover */
  transform: scale(1.05);       /* Professional expansion */
  box-shadow: 0 6px 20px rgba(18, 218, 121, 0.3);
}

/* SECONDARY BUTTON (Previous/Back) */
.btn-prev {
  background-color: transparent;
  color: #64748b;               /* Subtle grey */
  border: 1px solid #e2e8f0;
  padding: 10px 25px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-prev:hover {
  background-color: #f1f5f9;
  color: #1e293b;
  border-color: #cbd5e1;
}

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

/* ===== FOOTER PREMIUM ===== */

.footer-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: 1px;
}
/* ============================================================
   FOOTER (ESTILO HEADER AZUL CON LOGO Y REDES)
   ============================================================ */
.main-footer {
  background-color: #1233DA;
  color: #ffffff;
  padding: 30px 10px 30px;
  margin-top: 40px;
  text-align: center;
}

.footer-logo {
  margin-bottom: 20px;
  display: flex;
  justify-content: center;
}

.footer-logo img {
  height: 120px; /* Tamaño ajustado para no romper el diseño */
  width: auto;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
  transition: transform 0.3s ease;
}

.footer-logo img:hover {
  transform: scale(1.1);
  /* Brillo amarillo de Paraíso al pasar el mouse */
  filter: drop-shadow(0 0 20px #FCD116);
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 25px;
  margin-bottom: 30px;
}

.social-link {
  color: #1233DA;
  background: white;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 1.5rem;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.social-link:hover {
  transform: translateY(-5px);
  background: #f0f0f0;
  box-shadow: 0 6px 15px rgba(252, 209, 22, 0.5); /* Sombra amarilla */
}

.social-link.wa-link:hover {
  background: #25D366; /* Verde oficial WhatsApp */
  color: white;
}

.footer-copy {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 25px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
}

.footer-copy strong {
  color: #FCD116; /* Nombre destacado en Amarillo Paraíso */
}

/* ============================================================
   ESTADOS DE LIBRO (TAGS DINÁMICOS)
   ============================================================ */
.estado-tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 700;
  margin-top: 10px;
  text-transform: uppercase;
  border: 1px solid transparent;
}

/* Estado por defecto (Disponible/Nuevo) */
.estado-tag.disponible {
  background-color: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

/* Estado Agotado */
.estado-tag.agotado {
  background-color: #fee2e2;
  color: #dc2626;
  border-color: #fca5a5;
}

/* ============================================================
   DISEÑO DE POLÍTICAS (INFO CARDS)
   ============================================================ */
.contenido-politicas {
  max-width: 1000px;
  margin: 120px auto 60px;
  padding: 0 20px;
}

.titulo-pagina {
  text-align: center;
  color: #1233DA;
  margin-bottom: 40px;
  font-size: 2.2rem;
  font-weight: 800;
}

.grid-politicas {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
}

.card-politica {
  background: white;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.05);
  border: 1px solid #edf2f7;
  text-align: center;
  transition: all 0.3s ease;
}

.card-politica:hover {
  transform: translateY(-8px);
  border-color: #FCD116; /* Borde amarillo al pasar el mouse */
}

.icon-circle {
  width: 60px;
  height: 60px;
  background: #f0f4ff;
  color: #1233DA;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 1.5rem;
}

/* ============================================================
   STEP 3 - RESUMEN DE PAGO (ESTILO TICKET)
   ============================================================ */
#step3 {
  background: #ffffff;
  padding: 25px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
}

.summary-section {
  margin-bottom: 20px;
  background: #f8f9fa;
  padding: 15px;
  border-radius: 8px;
  border-left: 4px solid #1233DA;
}

.summary-list {
  list-style: none;
  padding: 0;
}

.summary-list li {
  padding: 10px 0;
  border-bottom: 1px dashed #cbd5e1;
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
}

.total-highlight {
  margin-top: 15px;
  padding-top: 15px;
  border-top: 2px solid #1233DA;
  font-weight: 800;
  color: #1233DA;
  font-size: 1.3rem;
  display: flex;
  justify-content: space-between;
}

/* ============================================================
   BOTÓN SUBIR (SCROLL TOP)
   ============================================================ */
#scrollTopBtn {
  opacity: 0;
  pointer-events: none;
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 1500;
  background-color: #1233DA;
  color: white;
  border: none;
  width: 55px;
  height: 55px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

#scrollTopBtn:hover {
  background-color: #FCD116; /* Cambia a amarillo */
  color: #1233DA;
  transform: translateY(-8px);
  box-shadow: 0 8px 25px rgba(252, 209, 22, 0.6);
}

/* Validación visual */
label:has(+ input[required])::after,
label:has(+ textarea[required])::after {
  content: " *";
  color: #dc2626;
  font-weight: bold;
}
/* ===== LOGO SUPER PRO (ELITE EFFECT) ===== */
.logo-container {
  position: relative;
  perspective: 1000px; /* Prepara el espacio para 3D */
  padding-left: 5%;    /* Alineación elegante */
}

.logo-container a {
  display: block;
  position: relative;
  overflow: hidden;    /* Para contener el destello */
  border-radius: 12px; /* Suaviza el cuadrado sin perder la forma */
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.logo-container img {
  height: 150px;
  width: auto;
  display: block;
  filter: drop-shadow(0 5px 15px rgba(0,0,0,0.2));
  transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1); /* Efecto elástico */
  z-index: 2;
  position: relative;
}

/* El Destello "Glint" Profesional */
.logo-container a::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -150%;
  width: 50%;
  height: 200%;
  background: linear-gradient(
    to right, 
    transparent, 
    rgba(252, 209, 22, 0.4), /* Brillo en tu dorado #FCD116 */
    transparent
  );
  transform: rotate(30deg);
  transition: 0.7s;
  z-index: 3;
}

/* INTERACCIÓN AL PASAR EL MOUSE */
.logo-container:hover a {
  transform: translateY(-5px) rotateX(10deg) rotateY(-5deg); /* Efecto 3D sutil */
 /* Tu sombra dorada */
  background: rgba(255, 255, 255, 0.05);
}

.logo-container:hover img {
  transform: scale(1.1);
  /*filter: drop-shadow(0 12px 25px rgba(0,0,0,0.3));*/
}

/*.logo-container:hover a::after {
  left: 150%; 
  }*/ 

/* Animación de "Respiración" constante (Sutil) */
@keyframes logoSlowFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.logo-container img {
  animation: logoSlowFloat 5s ease-in-out infinite;
}

/* Ajuste para que el header no corte la sombra */
header {
  overflow: visible !important; 
}

