/* =============================================
   VetClinic Portal - Custom Styles
   ============================================= */

:root {
  --primary: #b91c1c;
  --primary-light: #dc2626;
  --primary-dark: #991b1b;
  --accent: #d97706;
  --accent-light: #f59e0b;
  --dark: #1a1a2e;
  --gray: #6b7280;
  --light-gray: #f3f4f6;
  --white: #ffffff;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.16);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --transition: all 0.3s ease;
}

/* ---- Base ---- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--dark);
  background: var(--white);
  overflow-x: hidden;
  line-height: 1.6;
  max-width: 100%;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  line-height: 1.2;
}

/* Custom scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--light-gray); }
::-webkit-scrollbar-thumb { background: var(--primary-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* ---- Navbar ---- */
:root {
  --navbar-h: 72px;
}

.navbar-portal {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1050;
  padding: 16px 0;
  transition: var(--transition);
  background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 60%, #92400e 100%);
  box-shadow: 0 2px 20px rgba(0,0,0,0.2);
}

.navbar-portal.scrolled {
  background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 60%, #92400e 100%) !important;
  box-shadow: 0 2px 24px rgba(0,0,0,0.25);
  padding: 10px 0;
}

.navbar-portal.scrolled .nav-link { color: rgba(255,255,255,0.9) !important; }
.navbar-portal.scrolled .navbar-brand { color: var(--white) !important; }

.navbar-portal .navbar-brand {
  color: var(--white);
  text-decoration: none;
}

.navbar-logo {
  height: 44px;
  width: auto;
  object-fit: contain;
  border-radius: 6px;
}

.footer-logo {
  height: 54px;
  width: auto;
  object-fit: contain;
  border-radius: 6px;
  filter: brightness(0) invert(1);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-line1 {
  font-family: 'Poppins', sans-serif;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: inherit;
}

.brand-line2 {
  font-family: 'Poppins', sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 1.5px;
  color: var(--accent);
}

.navbar-portal.scrolled .brand-line1 { color: var(--white); }
.navbar-portal.scrolled .brand-line2 { color: var(--accent); }

.brand-text-footer .brand-line1 { color: #fff; }
.brand-text-footer .brand-line2 { color: var(--accent); }

.navbar-portal .nav-link {
  color: rgba(255,255,255,0.9) !important;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 6px 14px !important;
  transition: var(--transition);
  border-radius: var(--radius-sm);
}

.navbar-portal .nav-link:hover {
  color: var(--accent) !important;
  background: rgba(255,255,255,0.1);
}

.navbar-portal.scrolled .nav-link:hover {
  background: var(--light-gray);
}

.btn-intranet {
  background: rgba(255,255,255,0.15);
  border: 2px solid rgba(255,255,255,0.85);
  color: var(--white) !important;
  border-radius: 50px;
  padding: 7px 18px !important;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  transition: var(--transition);
  backdrop-filter: blur(4px);
  box-shadow: 0 2px 10px rgba(0,0,0,0.15);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-intranet:hover {
  background: rgba(255,255,255,0.28) !important;
  border-color: var(--white) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.navbar-portal.scrolled .btn-intranet {
  background: rgba(255,255,255,0.15);
  border-color: rgba(255,255,255,0.5);
  color: var(--white) !important;
}

.navbar-portal.scrolled .btn-intranet:hover {
  background: rgba(255,255,255,0.25) !important;
  border-color: var(--white) !important;
  color: var(--white) !important;
}

.btn-login-nav {
  background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
  color: var(--white) !important;
  border-radius: 50px;
  padding: 8px 22px !important;
  font-size: 0.85rem;
  font-weight: 700;
  border: none;
  letter-spacing: 0.3px;
  box-shadow: 0 4px 14px rgba(217,119,6,0.35);
  transition: var(--transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.btn-login-nav:hover {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
  color: var(--white) !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(217,119,6,0.5);
}

/* Móvil: botón compacto solo icono + texto corto */
@media (max-width: 400px) {
  .btn-login-nav .btn-login-text { display: none; }
  .btn-login-nav {
    padding: 8px 12px !important;
    border-radius: 50%;
    width: 38px; height: 38px;
    justify-content: center;
    gap: 0;
  }
}

@media (min-width: 401px) and (max-width: 991px) {
  .btn-login-nav {
    padding: 7px 16px !important;
    font-size: 0.8rem;
  }
}

.cart-btn {
  position: relative;
  background: rgba(255,255,255,0.15);
  border: none;
  border-radius: 50%;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  color: var(--white);
  font-size: 1.1rem;
  transition: var(--transition);
  cursor: pointer;
}

.cart-btn:hover { background: rgba(255,255,255,0.25); }

.navbar-portal.scrolled .cart-btn {
  background: rgba(255,255,255,0.15);
  color: var(--white);
}

.cart-badge {
  position: absolute;
  top: -4px; right: -4px;
  background: var(--accent);
  color: var(--white);
  font-size: 0.65rem;
  font-weight: 700;
  width: 18px; height: 18px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--white);
}

.navbar-toggler {
  border: none;
  padding: 4px 8px;
  margin-left: -10px;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,0.9)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.navbar-portal.scrolled .navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,0.9)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ---- Menú móvil ---- */
#mobileMenu {
  background: linear-gradient(160deg, #7f1d1d 0%, #b91c1c 60%, #92400e 100%);
  border-radius: 0 0 20px 20px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  margin: 0 -16px;
  padding: 0 16px;
}

#mobileMenu .border-top {
  border-color: rgba(255,255,255,0.15) !important;
}

#mobileMenu .nav-link {
  color: rgba(255,255,255,0.9) !important;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 12px 16px !important;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: background 0.2s, color 0.2s;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

#mobileMenu .nav-link:last-child {
  border-bottom: none;
}

#mobileMenu .nav-link:hover,
#mobileMenu .nav-link:active {
  background: rgba(255,255,255,0.12) !important;
  color: #fff !important;
}

/* ---- HERO ---- */
.hero-section {
  margin-top: var(--navbar-h);
  min-height: calc(100vh - var(--navbar-h));
  background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 40%, #92400e 80%, #78350f 100%);
  position: relative;
  display: flex;
  align-items: center;
  padding-bottom: 0;
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 20% 80%, rgba(217,119,6,0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255,255,255,0.05) 0%, transparent 50%);
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-shape-1 {
  position: absolute;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: rgba(255,255,255,0.03);
  top: -100px; right: -100px;
}

.hero-shape-2 {
  position: absolute;
  width: 300px; height: 300px;
  border-radius: 50%;
  background: rgba(217,119,6,0.08);
  bottom: 50px; right: 200px;
}

.hero-shape-3 {
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  top: 30%; left: -50px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(217,119,6,0.2);
  border: 1px solid rgba(217,119,6,0.4);
  color: var(--accent-light);
  padding: 6px 16px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 20px;
  backdrop-filter: blur(4px);
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 20px;
}

.hero-title .highlight {
  color: var(--accent);
  position: relative;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: rgba(255,255,255,0.8);
  margin-bottom: 40px;
  max-width: 540px;
  line-height: 1.8;
}

.hero-buttons { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 60px; }

.btn-hero-primary {
  background: var(--accent);
  color: var(--white);
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1rem;
  border: none;
  text-decoration: none;
  transition: var(--transition);
  display: inline-flex; align-items: center; gap: 8px;
  box-shadow: 0 4px 20px rgba(217,119,6,0.4);
}

.btn-hero-primary:hover {
  background: var(--accent-light);
  color: var(--white);
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(217,119,6,0.5);
}

.btn-hero-secondary {
  background: rgba(255,255,255,0.1);
  color: var(--white);
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  border: 2px solid rgba(255,255,255,0.4);
  text-decoration: none;
  transition: var(--transition);
  display: inline-flex; align-items: center; gap: 8px;
  backdrop-filter: blur(4px);
}

.btn-hero-secondary:hover {
  background: rgba(255,255,255,0.2);
  color: var(--white);
  transform: translateY(-3px);
  border-color: rgba(255,255,255,0.7);
}

/* ── HERO BACKGROUND SLIDESHOW (full-width) ── */
.hero-bg-slideshow {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.hero-bg-overlay {
  position: absolute;
  inset: 0;
  background: rgba(30, 5, 5, 0.30);
  z-index: 1;
}

/* Side cards stack (desktop) */
.hero-side-cards {
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: flex-end;
}
.hero-side-cards .hero-floating-card {
  position: relative;
  top: auto; left: auto; right: auto; bottom: auto;
  animation: float-card 4.5s ease-in-out infinite;
}
.hero-side-cards .hero-floating-card:nth-child(2) { animation-duration: 5s; animation-delay: 0.8s; }
.hero-side-cards .hero-floating-card:nth-child(3) { animation-duration: 4s; animation-delay: 0.4s; }

/* Hero visual element (legacy — kept for safety) */
.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-circle-main {
  width: 100%; height: 420px;
  border-radius: 28px;
  background: rgba(255,255,255,0.07);
  border: 2px solid rgba(255,255,255,0.15);
  display: flex; align-items: center; justify-content: center;
  position: relative;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}

.hero-icon-main {
  font-size: 8rem;
  color: rgba(255,255,255,0.7);
}

/* ── HERO SLIDESHOW ── */
.hero-circle-main { overflow: hidden; }

.hero-slide-track {
  position: absolute; inset: 0;
  border-radius: 28px; overflow: hidden;
}
.hero-bg-slideshow .hero-slide-track { border-radius: 0; }

.hero-slide {
  position: absolute; inset: 0;
  opacity: 0;
  transition: opacity 0.9s ease;
  border-radius: 28px;
}
.hero-bg-slideshow .hero-slide { border-radius: 0; }
.hero-slide.active { opacity: 1; }

.hero-slide img {
  width: 100%; height: 100%;
  object-fit: cover; border-radius: 28px;
  user-select: none; pointer-events: none;
}
.hero-bg-slideshow .hero-slide img { border-radius: 0; }

/* título sobre la imagen */
.hero-slide-title {
  position: absolute;
  top: 0; left: 0; right: 0;
  padding: 10px 14px;
  background: linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, transparent 100%);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-align: center;
  border-radius: 28px 28px 0 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.9s ease;
}
.hero-slide.active .hero-slide-title { opacity: 1; }

/* shimmer ring on active slide */
.hero-slide.active::after {
  content: '';
  position: absolute; inset: 0;
  border-radius: 0;
  box-shadow: inset 0 0 40px rgba(255,255,255,0.06), inset 0 0 80px rgba(0,0,0,0.20);
  pointer-events: none;
}

.hero-slide-fallback {
  display: flex; align-items: center; justify-content: center;
  position: absolute; inset: 0;
  transition: opacity 0.6s ease;
}
.hero-slide-fallback.hidden { opacity: 0; pointer-events: none; }

.hero-logo-fallback {
  width: 75%;
  max-width: 280px;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: 0.85;
  padding: 20px;
}

/* Logo siempre visible dentro del círculo */
.hero-logo-overlay {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  background: linear-gradient(to top, rgba(0,0,0,0.55) 0%, transparent 100%);
}

.hero-logo-overlay img {
  height: 52px;
  width: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: 0.92;
  drop-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

/* dots */
.hero-slide-dots {
  position: absolute;
  bottom: 18px;
  left: 50%; transform: translateX(-50%);
  display: flex; gap: 6px;
  z-index: 10;
}
.hero-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.35);
  border: none; padding: 0; cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}
.hero-dot.active {
  background: #fff;
  transform: scale(1.35);
}
/* hide dots when only 1 photo */
.hero-slide-dots:empty,
.hero-slide-dots .hero-dot:only-child { display: none; }

.hero-floating-card {
  position: absolute;
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--dark);
  white-space: nowrap;
}

.hero-floating-card .icon {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
}

/* .card-1/.card-2/.card-3 replaced by .hero-side-cards flex layout */

@keyframes float-card {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-10px) rotate(2deg); }
}

/* Hero Stats */
.hero-stats {
  background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 60%, #92400e 100%);
  border-top: 1px solid rgba(255,255,255,0.15);
  padding: 30px 0;
  position: relative;
  z-index: 5;
}

.stat-item { text-align: center; }

.stat-number {
  font-family: 'Poppins', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  color: var(--white);
  display: block;
  line-height: 1;
}

.stat-number span { color: var(--accent); }

.stat-label {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.7);
  font-weight: 500;
  letter-spacing: 0.5px;
  margin-top: 4px;
  display: block;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: rgba(255,255,255,0.2);
  align-self: center;
}

/* ---- Section Base ---- */
.section-padding { padding: 90px 0; }

.section-header { text-align: center; margin-bottom: 60px; }

.section-badge {
  display: inline-block;
  background: rgba(185,28,28,0.1);
  color: var(--primary);
  padding: 6px 16px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 16px;
}

.section-title .text-primary-custom { color: var(--primary); }

.section-subtitle {
  font-size: 1.05rem;
  color: var(--gray);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.8;
}

.section-line {
  width: 60px; height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 2px;
  margin: 0 auto 16px;
}

/* ---- QUIENES SOMOS ---- */
.about-section { background: var(--white); }

.about-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 36px 28px;
  box-shadow: var(--shadow-md);
  height: 100%;
  transition: var(--transition);
  border: 1px solid rgba(185,28,28,0.08);
  position: relative;
  overflow: hidden;
}

.about-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--primary-light));
  transform: scaleX(0);
  transition: var(--transition);
  transform-origin: left;
}

.about-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.about-card:hover::before { transform: scaleX(1); }

.about-card-icon {
  width: 64px; height: 64px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 20px;
}

.about-card-icon.historia { background: rgba(185,28,28,0.1); color: var(--primary); }
.about-card-icon.mision { background: rgba(217,119,6,0.1); color: var(--accent); }
.about-card-icon.vision { background: rgba(146,64,14,0.1); color: #92400e; }

.about-card h4 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--dark);
}

.about-card p {
  color: var(--gray);
  font-size: 0.92rem;
  line-height: 1.8;
  margin: 0;
}

/* Team section */
.team-section { background: var(--light-gray); }

.team-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 28px 20px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid transparent;
}

.team-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: rgba(185,28,28,0.15);
}

.team-avatar {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
  border: 3px solid rgba(185,28,28,0.2);
}

.team-card h5 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--dark);
}

.team-cargo {
  font-size: 0.82rem;
  color: var(--primary);
  font-weight: 600;
  background: rgba(185,28,28,0.08);
  padding: 3px 12px;
  border-radius: 50px;
  display: inline-block;
}

/* ---- PRODUCTOS ---- */
/* ============================================================
   SHOP LAYOUT — Sidebar + Products
============================================================ */
.productos-section { background: #f4f7fb; }

.shop-layout {
  display: flex;
  gap: 26px;
  align-items: flex-start;
}

/* ── Sidebar ── */
.shop-sidebar {
  width: 285px;
  flex-shrink: 0;
  background: var(--white);
  border-radius: 22px;
  padding: 24px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
  position: sticky;
  top: 90px;
  max-height: calc(100vh - 110px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #e5e7eb transparent;
  z-index: 10;
}
.shop-sidebar::-webkit-scrollbar { width: 4px; }
.shop-sidebar::-webkit-scrollbar-thumb { background: #e5e7eb; border-radius: 2px; }

.sf-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 22px;
  font-size: 1.15rem;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  color: var(--dark);
}

.sf-close-btn {
  display: none;
  background: var(--light-gray);
  border: none;
  width: 30px; height: 30px;
  border-radius: 50%;
  align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--gray);
  font-size: 0.85rem;
  transition: var(--transition);
}
.sf-close-btn:hover { background: #fee2e2; color: #ef4444; }

/* Filter box */
.sf-box {
  margin-bottom: 22px;
  padding-bottom: 22px;
  border-bottom: 1px solid #f1f5f9;
}

.sf-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray);
  margin-bottom: 12px;
}

/* Search in sidebar */
.sf-search-wrap { position: relative; }
.sf-search-wrap i {
  position: absolute;
  left: 12px; top: 50%;
  transform: translateY(-50%);
  color: var(--gray);
  font-size: 0.8rem;
  pointer-events: none;
  transition: var(--transition);
}
.sf-search-wrap input {
  width: 100%;
  height: 44px;
  border: 2px solid #f1f5f9;
  border-radius: 12px;
  padding: 0 12px 0 36px;
  font-size: 0.875rem;
  font-family: 'Inter', sans-serif;
  background: #f8fafc;
  outline: none;
  color: var(--dark);
  transition: var(--transition);
}
.sf-search-wrap input:focus {
  border-color: var(--primary);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(185,28,28,0.09);
}
.sf-search-wrap:focus-within i { color: var(--primary); }

/* Category checkboxes */
.sf-cat-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 3px;
  user-select: none;
}
.sf-cat-item:hover { background: #f8fafc; }
.sf-cat-item input[type="checkbox"] { display: none; }

.sf-cat-box {
  width: 20px; height: 20px;
  border: 2px solid #d1d5db;
  border-radius: 6px;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.6rem;
  color: transparent;
  transition: var(--transition);
  background: var(--white);
}
.sf-cat-item.checked .sf-cat-box {
  background: var(--cat-color, var(--primary));
  border-color: var(--cat-color, var(--primary));
  color: var(--white);
}

.sf-cat-icon {
  width: 32px; height: 32px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.sf-cat-name {
  flex: 1;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--dark);
  transition: var(--transition);
}
.sf-cat-item.checked .sf-cat-name {
  color: var(--cat-color, var(--primary));
  font-weight: 600;
}

.sf-cat-count {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--gray);
  background: #f1f5f9;
  padding: 2px 8px;
  border-radius: 10px;
  transition: var(--transition);
  flex-shrink: 0;
}
.sf-cat-item.checked .sf-cat-count {
  background: var(--cat-color-bg, #f0fdf4);
  color: var(--cat-color, var(--primary));
}

/* ── Dual range slider ── */
.sf-range-wrap {
  position: relative;
  height: 28px;
  margin: 6px 0 14px;
}

.sf-range-track {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  left: 0; right: 0;
  height: 5px;
  background: #e5e7eb;
  border-radius: 3px;
}

.sf-range-fill {
  position: absolute;
  height: 100%;
  background: var(--primary);
  border-radius: 3px;
  transition: left 0.05s, width 0.05s;
}

.sf-range-input {
  position: absolute;
  width: 100%;
  top: 50%; transform: translateY(-50%);
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  pointer-events: none;
  outline: none;
  height: 5px;
  margin: 0;
}

.sf-range-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--primary);
  cursor: grab;
  pointer-events: auto;
  border: 3px solid var(--white);
  box-shadow: 0 2px 8px rgba(185,28,28,0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.sf-range-input::-webkit-slider-thumb:hover,
.sf-range-input:active::-webkit-slider-thumb {
  transform: scale(1.25);
  box-shadow: 0 3px 12px rgba(185,28,28,0.45);
  cursor: grabbing;
}

.sf-range-input::-moz-range-thumb {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--primary);
  cursor: grab;
  pointer-events: auto;
  border: 3px solid var(--white);
  box-shadow: 0 2px 8px rgba(185,28,28,0.35);
}

.sf-price-display {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--primary);
  font-family: 'Poppins', sans-serif;
}
.sf-price-sep { color: var(--gray); font-weight: 400; font-size: 0.85rem; }

/* Sidebar buttons */
.sf-apply-btn {
  width: 100%;
  height: 50px;
  border: none;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  border-radius: 14px;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 10px;
}
.sf-apply-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(185,28,28,0.3); }

.sf-clear-btn {
  width: 100%;
  height: 42px;
  border: 2px solid #e5e7eb;
  background: transparent;
  color: var(--gray);
  border-radius: 12px;
  font-size: 0.84rem;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: var(--transition);
}
.sf-clear-btn:hover { border-color: #ef4444; color: #ef4444; background: #fef2f2; }

/* ── Shop Main ── */
.shop-main { flex: 1; min-width: 0; }

.shop-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 10px;
}

.shop-results {
  font-size: 0.875rem;
  color: var(--gray);
  font-weight: 500;
}
.shop-results strong { color: var(--dark); font-weight: 700; }

.shop-topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.shop-filter-toggle {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  background: var(--white);
  font-size: 0.84rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  color: var(--dark);
  cursor: pointer;
  transition: var(--transition);
}
.shop-filter-toggle:hover { border-color: var(--primary); color: var(--primary); }

.shop-filter-badge {
  display: inline-flex;
  align-items: center; justify-content: center;
  min-width: 18px; height: 18px;
  background: var(--primary);
  color: var(--white);
  border-radius: 9px;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0 5px;
}

.shop-sort-select {
  height: 42px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  padding: 0 14px;
  font-size: 0.84rem;
  font-family: 'Inter', sans-serif;
  color: var(--dark);
  background: var(--white);
  outline: none;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}
.shop-sort-select:focus { border-color: var(--primary); }

/* Overlay móvil */
.shop-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,0.5);
  z-index: 1040;
  backdrop-filter: blur(2px);
}
.shop-overlay.active { display: block; }

/* No-results */
.filter-no-results { text-align: center; padding: 60px 20px; color: var(--gray); }
.filter-no-results i { font-size: 2.8rem; opacity: 0.15; display: block; margin-bottom: 14px; }

/* ── Responsive ── */
@media (max-width: 991px) {
  .shop-layout { display: block; }

  .shop-sidebar {
    position: fixed;
    left: -310px;
    top: 0; bottom: 0;
    width: 300px;
    max-height: 100dvh;
    border-radius: 0 22px 22px 0;
    z-index: 1050;
    transition: left 0.32s cubic-bezier(0.4,0,0.2,1);
    overflow-y: auto;
    padding-top: 40px;
  }
  .shop-sidebar.open {
    left: 0;
    box-shadow: 6px 0 40px rgba(0,0,0,0.18);
  }

  .sf-close-btn { display: flex; }
  .shop-filter-toggle { display: inline-flex; }
}

.producto-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid rgba(0,0,0,0.06);
  height: 100%;
  display: flex; flex-direction: column;
}

.producto-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.producto-img-wrapper {
  position: relative;
  height: 200px;
  overflow: hidden;
  background: var(--light-gray);
}

.producto-img-wrapper img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.producto-card:hover .producto-img-wrapper img { transform: scale(1.08); }

.producto-img-placeholder {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(185,28,28,0.08), rgba(185,28,28,0.04));
  color: var(--primary);
}

.producto-img-placeholder .initial {
  font-family: 'Poppins', sans-serif;
  font-size: 3rem;
  font-weight: 800;
  opacity: 0.4;
}

.producto-badge-cat {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--primary);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 50px;
  letter-spacing: 0.5px;
}

.producto-badge-agotado {
  position: absolute;
  top: 12px; left: 12px;
  background: #dc2626;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 50px;
  letter-spacing: 0.5px;
}

.producto-agotado .producto-img-wrapper img,
.producto-agotado .producto-img-placeholder {
  filter: grayscale(80%);
  opacity: 0.6;
}

.producto-agotado:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
  cursor: default;
}

.producto-body {
  padding: 18px;
  flex: 1;
  display: flex; flex-direction: column;
}

.producto-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 4px;
  line-height: 1.4;
}

.producto-desc {
  font-size: 0.82rem;
  color: var(--gray);
  margin-bottom: 14px;
  flex: 1;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.producto-price {
  font-family: 'Poppins', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 12px;
}

.producto-price small {
  font-size: 0.75rem;
  color: var(--gray);
  font-weight: 400;
  font-family: 'Inter', sans-serif;
}

.btn-add-cart {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  border: none;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  width: 100%;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}

.btn-add-cart:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(185,28,28,0.4);
}

/* ---- Selector unidad producto ---- */
.btn-unidad {
  border-color: var(--primary) !important;
  color: var(--primary) !important;
  font-size: 0.72rem;
  line-height: 1.3;
  padding: 4px 6px;
  white-space: normal;
  transition: all .2s;
}
.btn-unidad.active {
  background: var(--primary) !important;
  color: #fff !important;
  font-weight: 600;
}
.btn-unidad:hover:not(.active) {
  background: rgba(185,28,28,0.08) !important;
}

/* ---- SERVICIOS ---- */
.servicios-section {
  background: linear-gradient(180deg, var(--light-gray) 0%, #e8f5ee 100%);
}

.servicio-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  height: 100%;
  display: flex; flex-direction: column;
}

.servicio-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.servicio-img-wrapper {
  height: 180px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
}

.servicio-img-wrapper img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.servicio-card:hover .servicio-img-wrapper img { transform: scale(1.08); }

.servicio-img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 4rem;
  color: rgba(255,255,255,0.7);
}

.servicio-body {
  padding: 20px;
  flex: 1;
  display: flex; flex-direction: column;
}

.servicio-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}

.servicio-desc {
  font-size: 0.85rem;
  color: var(--gray);
  flex: 1;
  margin-bottom: 14px;
  line-height: 1.7;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.servicio-price {
  font-family: 'Poppins', sans-serif;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 12px;
}

.btn-solicitar {
  background: var(--accent);
  color: var(--white);
  border: none;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  width: 100%;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}

.btn-solicitar:hover {
  background: var(--accent-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(217,119,6,0.4);
}

/* =============================================
   GALERÍA — Premium Dark Studio
   ============================================= */
.galeria-section {
  background: #07090f;
  position: relative;
  overflow: hidden;
}

/* Side-lighting glow */
.galeria-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at -5% 110%, rgba(185,28,28,0.22) 0%, transparent 55%),
    radial-gradient(ellipse 55% 50% at 108% -10%, rgba(217,119,6,0.10) 0%, transparent 50%),
    radial-gradient(ellipse 40% 40% at 50% 50%, rgba(15,50,90,0.15) 0%, transparent 60%);
  pointer-events: none;
}

/* Dot-grid texture */
.galeria-section::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

/* Ambient orbs */
.galeria-orb { position: absolute; border-radius: 50%; pointer-events: none; filter: blur(80px); }
.galeria-orb-1 { width: 400px; height: 400px; background: rgba(185,28,28,0.1);  top: -100px; left: -120px; animation: orb-drift 14s ease-in-out infinite; }
.galeria-orb-2 { width: 280px; height: 280px; background: rgba(217,119,6,0.07); bottom: -70px; right: 8%;   animation: orb-drift 18s ease-in-out infinite reverse; }
.galeria-orb-3 { width: 200px; height: 200px; background: rgba(30,125,180,0.08); top: 35%;   right: -60px;  animation: orb-drift 11s ease-in-out infinite 4s; }

@keyframes orb-drift {
  0%,100% { transform: translate(0,0) scale(1); }
  40%     { transform: translate(25px,-18px) scale(1.07); }
  70%     { transform: translate(-18px,12px) scale(0.94); }
}

/* ── Section header overrides ── */
.galeria-section .section-badge {
  background: rgba(217,119,6,0.12);
  color: #ffb070;
  border: 1px solid rgba(217,119,6,0.22);
  backdrop-filter: blur(8px);
}
.galeria-section .section-line {
  background: linear-gradient(90deg, var(--primary-light), var(--accent), transparent);
  width: 90px;
}
.galeria-section .section-title { color: var(--white); }
.galeria-section .section-subtitle { color: rgba(255,255,255,0.42); font-size: 1rem; }

/* Gradient text on "Galería" */
.g-text-gradient {
  background: linear-gradient(135deg, #38ef7d 0%, #11998e 45%, #d97706 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Filter — Tab strip ── */
.galeria-tabs {
  display: flex;
  justify-content: center;
  gap: 0;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 50px;
  padding: 5px;
  width: fit-content;
  margin: 0 auto 44px;
  backdrop-filter: blur(12px);
}

.galeria-filter-btn {
  background: transparent;
  color: rgba(255,255,255,0.5);
  border: none;
  padding: 9px 22px;
  border-radius: 50px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 7px;
  transition: all 0.3s ease;
  white-space: nowrap;
  letter-spacing: 0.2px;
}

.galeria-filter-btn i { font-size: 0.78rem; opacity: 0.8; }

.galeria-filter-btn:hover {
  color: rgba(255,255,255,0.85);
  background: rgba(255,255,255,0.07);
}

.galeria-filter-btn.active {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff;
  box-shadow: 0 4px 18px rgba(185,28,28,0.45), inset 0 1px 0 rgba(255,255,255,0.15);
}
.galeria-filter-btn.active i { opacity: 1; }

/* ── Bento Grid ── */
.galeria-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 220px;
  grid-auto-flow: dense;
  gap: 12px;
  position: relative;
  z-index: 2;
}

.galeria-item.g-large { grid-column: span 2; grid-row: span 2; }
.galeria-item.g-wide  { grid-column: span 2; }
.galeria-item.g-tall  { grid-row: span 2; }

@media (max-width: 1100px) {
  .galeria-grid { grid-template-columns: repeat(3, 1fr); grid-auto-rows: 200px; }
}
@media (max-width: 768px) {
  .galeria-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 175px; gap: 8px; }
  .galeria-item.g-large { grid-column: span 2; grid-row: span 1; }
  .galeria-item.g-tall  { grid-row: span 1; }
}
@media (max-width: 480px) {
  .galeria-grid { grid-auto-rows: 140px; gap: 6px; }
}

/* ── Gallery Item ── */
.galeria-item {
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  border: 1px solid rgba(255,255,255,0.07);
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
  /* entrance: hidden */
  opacity: 0;
  transform: translateY(26px) scale(0.93);
  transition: opacity 0.52s ease,
              transform 0.52s cubic-bezier(0.16,1,0.3,1),
              box-shadow 0.35s ease,
              border-color 0.35s ease;
}

.galeria-item.g-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Shine sweep on reveal */
.galeria-item::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0; left: 0;
  width: 70%;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.11) 50%, transparent 100%);
  transform: translateX(-110%) skewX(-14deg);
  z-index: 7; pointer-events: none; opacity: 0;
}
.galeria-item.g-visible::before {
  opacity: 1;
  animation: gShine 1s cubic-bezier(0.4,0,0.2,1) 0.38s forwards;
}
@keyframes gShine {
  to { transform: translateX(180%) skewX(-14deg); }
}

/* Hover state */
.galeria-item.g-visible:hover {
  border-color: rgba(217,119,6,0.45);
  box-shadow:
    0 0 0 1px rgba(217,119,6,0.25),
    0 22px 55px rgba(0,0,0,0.65),
    0 0 40px rgba(217,119,6,0.07);
  transform: scale(1.022) translateY(-3px);
  z-index: 4;
}

/* Image */
.galeria-item img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: transform 0.7s cubic-bezier(0.25,0.46,0.45,0.94);
  will-change: transform;
}
.galeria-item:hover img { transform: scale(1.09); }

/* ── Info overlay ── */
.galeria-overlay {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: flex-start; justify-content: flex-end;
  padding: 20px 18px;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0)   0%,
    transparent     100%
  );
  transition: background 0.38s ease;
}

.galeria-item:hover .galeria-overlay {
  background: linear-gradient(
    to top,
    rgba(2,5,10,0.93)  0%,
    rgba(5,15,8,0.60)  30%,
    rgba(10,40,20,0.18) 65%,
    transparent        100%
  );
}

/* Top-right zoom button */
.galeria-overlay-zoom {
  position: absolute;
  top: 13px; right: 13px;
  width: 36px; height: 36px;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.9);
  font-size: 0.82rem;
  transform: scale(0) rotate(-20deg);
  transition: transform 0.42s cubic-bezier(0.34,1.6,0.64,1) 0.05s,
              background 0.25s ease;
}
.galeria-item:hover .galeria-overlay-zoom { transform: scale(1) rotate(0deg); }
.galeria-overlay-zoom:hover { background: rgba(217,119,6,0.6) !important; border-color: var(--accent); }

/* Category badge */
.galeria-type-badge {
  font-size: 0.59rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 50px;
  letter-spacing: 0.8px;
  margin-bottom: 7px;
  display: inline-flex; align-items: center; gap: 4px;
  transform: translateY(10px);
  opacity: 0;
  transition: transform 0.32s ease 0.1s, opacity 0.32s ease 0.1s;
}
.galeria-type-badge.tipo-producto {
  background: rgba(185,28,28,0.92);
  color: #c8ffd9;
  border: 1px solid rgba(80,200,120,0.3);
}
.galeria-type-badge.tipo-servicio {
  background: rgba(217,119,6,0.92);
  color: #fff0e0;
  border: 1px solid rgba(217,119,6,0.45);
}
.galeria-item:hover .galeria-type-badge { transform: translateY(0); opacity: 1; }

/* Caption */
.galeria-overlay-caption {
  font-family: 'Poppins', sans-serif;
  color: rgba(255,255,255,0.96);
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.35;
  text-shadow: 0 2px 10px rgba(0,0,0,0.8);
  max-width: calc(100% - 46px);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  transform: translateY(12px);
  opacity: 0;
  transition: transform 0.36s cubic-bezier(0.16,1,0.3,1) 0.07s,
              opacity 0.36s ease 0.07s;
}
.galeria-item.g-large .galeria-overlay-caption { font-size: 1.05rem; font-weight: 700; }
.galeria-item:hover .galeria-overlay-caption { transform: translateY(0); opacity: 1; }

/* "Destacado" ribbon on large items */
.galeria-featured-tag {
  position: absolute;
  top: 14px; left: 14px;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  padding: 4px 13px;
  border-radius: 50px;
  backdrop-filter: blur(10px);
  z-index: 5;
}
.galeria-featured-tag i { margin-right: 4px; color: #ffd166; }

/* =============================================
   LIGHTBOX — Premium
   ============================================= */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
  /* Layered blur + dark bg */
  background: rgba(3,5,10,0.92);
  backdrop-filter: blur(18px) saturate(0.6);
}
.lightbox-overlay.active { opacity: 1; pointer-events: all; }

/* Top bar */
.lightbox-topbar {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  background: linear-gradient(to bottom, rgba(0,0,0,0.6), transparent);
  z-index: 10002;
}

.lightbox-counter {
  color: rgba(255,255,255,0.55);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 1px;
  background: rgba(255,255,255,0.07);
  padding: 5px 16px;
  border-radius: 50px;
  border: 1px solid rgba(255,255,255,0.1);
}

.lightbox-close {
  color: rgba(255,255,255,0.75);
  font-size: 1.1rem;
  cursor: pointer;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  width: 42px; height: 42px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.3s ease;
}
.lightbox-close:hover {
  background: rgba(217,119,6,0.65);
  border-color: var(--accent);
  color: #fff;
  transform: rotate(90deg);
}

/* Image area */
.lightbox-content {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-height: calc(100vh - 130px);
  padding: 0 80px;
}

.lightbox-img {
  max-width: 100%;
  max-height: calc(100vh - 130px);
  border-radius: 14px;
  box-shadow: 0 30px 90px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.06);
  display: block;
  object-fit: contain;
}

/* Prev / Next */
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.75);
  font-size: 1rem;
  cursor: pointer;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  width: 48px; height: 48px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.28s ease;
  backdrop-filter: blur(8px);
  z-index: 10001;
}
.lightbox-prev { left: 18px; }
.lightbox-next { right: 18px; }
.lightbox-nav:hover {
  background: rgba(217,119,6,0.65);
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-50%) scale(1.08);
}
.lightbox-nav:disabled { opacity: 0.18; cursor: default; pointer-events: none; }

/* Bottom caption bar */
.lightbox-caption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 20px 24px 24px;
  background: linear-gradient(to top, rgba(0,0,0,0.75), transparent);
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 10002;
}
.lightbox-caption-text {
  color: rgba(255,255,255,0.88);
  font-size: 0.9rem;
  font-weight: 600;
  font-family: 'Poppins', sans-serif;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}

@media (max-width: 768px) {
  .lightbox-content { padding: 0 60px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-nav { width: 40px; height: 40px; }
  .lightbox-caption { padding: 16px 20px 20px; }
}

/* ---- UBICACION ---- */
.ubicacion-section { background: var(--white); }

.map-wrapper {
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 3px solid rgba(185,28,28,0.15);
}

.map-wrapper iframe { display: block; }

.sede-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(0,0,0,0.07);
  transition: var(--transition);
  margin-bottom: 16px;
}

.sede-card:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(185,28,28,0.2);
  transform: translateX(4px);
}

.sede-card.principal {
  border-left: 4px solid var(--primary);
}

.sede-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  background: rgba(185,28,28,0.1);
  color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.sede-card h6 {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--dark);
  margin-bottom: 4px;
}

.sede-card p {
  font-size: 0.82rem;
  color: var(--gray);
  margin: 0;
  line-height: 1.6;
}

.sede-badge {
  font-size: 0.7rem;
  background: var(--primary);
  color: var(--white);
  padding: 2px 8px;
  border-radius: 50px;
  font-weight: 600;
}

.sede-clickable {
  cursor: pointer;
}

.sede-clickable:hover {
  background: rgba(185,28,28,0.04);
}

/* ---- CONTACTO ---- */
.contacto-section {
  background: linear-gradient(135deg, #f0faf5 0%, #e8f5ee 100%);
}

.contact-form-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-md);
}

.contact-info-card {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: var(--radius-lg);
  padding: 40px;
  color: var(--white);
  height: 100%;
}

.contact-info-card h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.contact-info-card p { color: rgba(255,255,255,0.7); margin-bottom: 30px; }

.contact-info-item {
  display: flex; align-items: flex-start; gap: 14px;
  margin-bottom: 20px;
}

.contact-info-icon {
  width: 42px; height: 42px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.15);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.contact-info-text strong {
  display: block;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  font-weight: 500;
  margin-bottom: 2px;
}

.contact-info-text span {
  font-size: 0.9rem;
  color: var(--white);
  font-weight: 600;
}

.social-links { display: flex; gap: 10px; margin-top: 30px; }

.social-link {
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.15);
  color: var(--white);
  display: flex; align-items: center; justify-content: center;
  text-decoration: none;
  font-size: 1rem;
  transition: var(--transition);
}

.social-link:hover {
  background: var(--accent);
  color: var(--white);
  transform: translateY(-3px);
}

/* Form styles */
.form-floating > .form-control, .form-floating > .form-select {
  border: 2px solid rgba(0,0,0,0.08);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.form-floating > .form-control:focus,
.form-floating > .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(185,28,28,0.1);
}

.form-floating > label { color: var(--gray); }

.btn-contact-submit {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  border: none;
  padding: 14px 36px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  width: 100%;
}

.btn-contact-submit:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(185,28,28,0.4);
}

/* ---- FOOTER ---- */
footer {
  background: linear-gradient(180deg, #1a0505 0%, #2d0a0a 100%);
  color: rgba(255,255,255,0.7);
  padding: 60px 0 0;
}

footer .footer-brand {
  font-family: 'Poppins', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--white);
}

footer .footer-brand span { color: var(--accent); }

footer .footer-tagline {
  font-size: 0.9rem;
  line-height: 1.7;
  margin: 12px 0 24px;
  max-width: 280px;
}

footer h6 {
  color: var(--white);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}

footer ul { list-style: none; padding: 0; margin: 0; }

footer ul li { margin-bottom: 10px; }

footer ul li a {
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  font-size: 0.88rem;
  transition: var(--transition);
  display: flex; align-items: center; gap: 6px;
}

footer ul li a:hover {
  color: var(--accent);
  padding-left: 6px;
}

.footer-contact-item {
  display: flex; align-items: flex-start; gap: 10px;
  margin-bottom: 14px;
}

.footer-contact-item i {
  color: var(--accent);
  font-size: 0.9rem;
  margin-top: 2px;
  flex-shrink: 0;
}

.footer-contact-item span {
  font-size: 0.85rem;
  line-height: 1.5;
}

.footer-divider {
  border-color: rgba(255,255,255,0.08);
  margin: 40px 0 0;
}

.footer-bottom {
  padding: 20px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-bottom p { margin: 0; font-size: 0.85rem; }

.footer-social { display: flex; gap: 8px; }

.footer-social a {
  width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.6);
  display: flex; align-items: center; justify-content: center;
  text-decoration: none;
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--accent);
  color: var(--white);
  transform: translateY(-3px);
}

/* ---- FLOATING WHATSAPP ---- */
.whatsapp-float {
  position: fixed;
  bottom: 32px;
  right: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  color: #111;
  border-radius: 16px;
  padding: 10px 18px 10px 10px;
  text-decoration: none;
  z-index: 999;
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  animation: pulse-wa 3s infinite;
  border: 1px solid rgba(0,0,0,0.06);
}

.whatsapp-float:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(0,0,0,0.18);
  animation: none;
  color: #111;
}

.wa-icon {
  width: 56px;
  height: 44px;
  background: linear-gradient(135deg, #25d366, #1aa851);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(37,211,102,0.4);
}

.wa-icon i {
  font-size: 1.55rem;
  color: #fff;
  line-height: 1;
}

.wa-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.wa-text-top {
  font-size: 0.7rem;
  font-weight: 600;
  color: #25d366;
  font-family: 'Poppins', sans-serif;
  letter-spacing: 0.05em;
  line-height: 1;
}

.wa-text-bottom {
  font-size: 0.82rem;
  font-weight: 700;
  color: #1a1a1a;
  font-family: 'Poppins', sans-serif;
  white-space: nowrap;
  line-height: 1.3;
}

@keyframes pulse-wa {
  0%   { box-shadow: 0 8px 30px rgba(0,0,0,0.15); }
  50%  { box-shadow: 0 8px 30px rgba(0,0,0,0.15), 0 0 0 6px rgba(37,211,102,0.12); }
  100% { box-shadow: 0 8px 30px rgba(0,0,0,0.15); }
}

/* ---- CART MODAL ---- */
.cart-modal-header {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.cart-item {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

.cart-item:last-child { border-bottom: none; }

.cart-item-img {
  width: 56px; height: 56px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--light-gray);
  flex-shrink: 0;
}

.cart-item-info { flex: 1; }

.cart-item-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--dark);
  margin-bottom: 2px;
}

.cart-item-price {
  font-size: 0.82rem;
  color: var(--gray);
}

.cart-item-subtotal {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  color: var(--primary);
  font-size: 0.95rem;
}

.cart-item-remove {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 1rem;
  padding: 4px;
  transition: var(--transition);
  border-radius: 4px;
}

.cart-item-remove:hover { background: rgba(239,68,68,0.1); }

.cart-qty-control {
  display: flex; align-items: center; gap: 8px;
}

.cart-qty-btn {
  background: var(--light-gray);
  border: none;
  width: 26px; height: 26px;
  border-radius: 50%;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem;
  transition: var(--transition);
  font-weight: 700;
}

.cart-qty-btn:hover { background: var(--primary); color: var(--white); }

.cart-qty-num {
  font-weight: 700;
  min-width: 20px;
  text-align: center;
}

.cart-total-row {
  background: var(--light-gray);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.cart-empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--gray);
}

.cart-empty-state i { font-size: 3rem; opacity: 0.3; margin-bottom: 12px; display: block; }

/* ---- BUTTONS GENERAL ---- */
.btn-primary-custom {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  border: none;
  padding: 12px 30px;
  border-radius: 50px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex; align-items: center; gap: 8px;
  text-decoration: none;
}

.btn-primary-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(185,28,28,0.4);
  color: var(--white);
}

/* ---- NOTIFICATIONS ---- */
.toast-container { z-index: 9999; }

/* ---- LOADING ---- */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---- RESPONSIVE ---- */
@media (max-width: 992px) {
  .section-padding { padding: 70px 0; }
  .hero-title { text-align: center; }
  .hero-subtitle { text-align: center; margin: 0 auto 40px; }
  .hero-buttons { justify-content: center; }
  .hero-badge { display: block; text-align: center; }

  /* El slideshow de fondo ya es absoluto — sin ajustes adicionales en móvil */

  .hero-slide-title {
    border-radius: 0;
  }
}

@media (max-width: 768px) {
  .section-padding { padding: 60px 0; }
  .hero-section { min-height: calc(90vh - var(--navbar-h)); }
  .hero-stats .stat-divider { display: none; }
  .contact-form-card { padding: 28px 20px; }
  .contact-info-card { padding: 28px 20px; margin-top: 24px; }
  .whatsapp-float { bottom: 20px; right: 16px; padding: 8px 14px 8px 8px; border-radius: 14px; gap: 10px; }
  .wa-icon { width: 48px; height: 38px; border-radius: 8px; }
  .wa-icon i { font-size: 1.35rem; }
  .wa-text-bottom { font-size: 0.75rem; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 2rem; }
  .btn-hero-primary, .btn-hero-secondary { width: 100%; justify-content: center; }
  .hero-buttons { flex-direction: column; }
}

/* ---- AOS Overrides ---- */
[data-aos] { pointer-events: none; }
[data-aos].aos-animate { pointer-events: auto; }

/* ---- Tarjetas móvil ---- */
.hero-cards-mobile {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 16px;
  padding: 0 8px;
}

.card-mobile {
  position: relative;
  top: auto; right: auto; bottom: auto; left: auto;
  animation: none;
  white-space: nowrap;
  flex: 0 0 auto;
  padding: 10px 14px;
  font-size: 0.8rem;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
}

.card-mobile .icon {
  width: 30px; height: 30px;
  font-size: 0.85rem;
}

.card-mobile div > div {
  color: rgba(255,255,255,0.75) !important;
}

.card-mobile div > div:last-child {
  color: #fff !important;
  font-weight: 600;
}

/* ── CLIENTES PORTAL ── */
.clientes-portal-section {
  position: relative;
  padding: 70px 0 80px;
  background: linear-gradient(160deg, #1a0505 0%, #7f1d1d 55%, #3d1010 100%);
  overflow: hidden;
}
.cp-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.18;
  pointer-events: none;
}
.cp-orb-1 {
  width: 420px; height: 420px;
  background: #b91c1c;
  top: -120px; left: -100px;
}
.cp-orb-2 {
  width: 320px; height: 320px;
  background: #d97706;
  bottom: -80px; right: -60px;
}

/* Marquee container */
.cp-marquee-wrap {
  margin-top: 40px;
  overflow: hidden;
  position: relative;
}
.cp-marquee-wrap::before,
.cp-marquee-wrap::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 120px;
  z-index: 2;
  pointer-events: none;
}
.cp-marquee-wrap::before {
  left: 0;
  background: linear-gradient(to right, #1a0505, transparent);
}
.cp-marquee-wrap::after {
  right: 0;
  background: linear-gradient(to left, #3d1010, transparent);
}

@keyframes cp-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.cp-marquee-track {
  display: flex;
  gap: 20px;
  padding: 10px 0;
  width: max-content;
  animation: cp-scroll 35s linear infinite;
}
.cp-marquee-track:hover {
  animation-play-state: paused;
}

/* Individual card */
.cp-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 16px;
  padding: 16px 22px;
  min-width: 240px;
  max-width: 300px;
  flex-shrink: 0;
  backdrop-filter: blur(6px);
  transition: transform .25s, background .25s, box-shadow .25s;
  cursor: default;
}
.cp-card:hover {
  transform: translateY(-4px);
  background: rgba(255,255,255,0.13);
  box-shadow: 0 12px 32px rgba(0,0,0,0.3);
}

/* Avatar */
.cp-avatar {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  font-weight: 800;
  color: #fff;
  font-family: 'Poppins', sans-serif;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,0.2);
}
.cp-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Text */
.cp-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow: hidden;
}
.cp-nombre {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 0.88rem;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cp-galpon {
  font-size: 0.76rem;
  color: rgba(255,255,255,0.6);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cp-galpon i {
  color: #f59e0b;
  margin-right: 3px;
}

/* Override section-header colors inside dark section */
.clientes-portal-section .section-badge {
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.85);
  border-color: rgba(255,255,255,0.15);
}
.clientes-portal-section .section-title {
  color: #fff;
}
.clientes-portal-section .section-subtitle {
  color: rgba(255,255,255,0.65);
}
.clientes-portal-section .section-line {
  background: rgba(255,255,255,0.25);
}
.clientes-portal-section .text-primary-custom {
  color: #f59e0b !important;
}
