/********** components.css — Mega Fresh Carolina **********/
/* Navbar, Search Overlay, Hero Carousel, Feature Cards, Deal Cards,
   Stats Bar, Testimonials, CTA Band, Footer */

/* ════════════════════════════════════════════════════
   NAVBAR
   ════════════════════════════════════════════════════ */
.top-bar {
  background: var(--secondary);
  color: rgba(255,255,255,0.75);
  font-size: 0.82rem;
  padding: 6px 0;
}
.top-bar i { color: var(--primary); }
.top-bar a { color: rgba(255,255,255,0.75); text-decoration: none; }
.top-bar a:hover { color: #fff; }

.navbar {
  background: #fff;
  box-shadow: var(--shadow-nav);
  transition: var(--transition);
}
.navbar.scrolled {
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.navbar-logo-img {
  height: 44px;
  width: auto;
  object-fit: contain;
}
.mega-fresh-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.logo-text-block {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.logo-subtitle {
  font-family: var(--font-heading);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.logo-location {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--gray-600);
}

.navbar .nav-link {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--secondary) !important;
  padding: 1.2rem 1rem !important;
  transition: color 0.2s;
}
.navbar .nav-link:hover,
.navbar .nav-link.active { color: var(--primary) !important; }

.nav-tv-link {
  background: var(--primary);
  color: #fff !important;
  border-radius: var(--radius-pill);
  padding: 0.4rem 1rem !important;
  font-size: 0.78rem !important;
  margin-left: 0.5rem;
}
.nav-tv-link:hover { background: var(--primary-dark); color: #fff !important; }

/* Search Button */
.btn-search-nav {
  background: none;
  border: none;
  color: var(--secondary);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.4rem 0.6rem;
  transition: color 0.2s;
}
.btn-search-nav:hover { color: var(--primary); }

/* ════════════════════════════════════════════════════
   SEARCH OVERLAY
   ════════════════════════════════════════════════════ */
#search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 99998;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 80px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
#search-overlay.open {
  opacity: 1;
  visibility: visible;
}
#search-overlay .search-inner {
  width: 90%;
  max-width: 680px;
}
#search-input {
  width: 100%;
  padding: 16px 20px;
  font-size: 1.2rem;
  font-family: var(--font-body);
  border: none;
  border-radius: var(--radius);
  outline: none;
  background: #fff;
  color: #333;
}
#search-results {
  margin-top: 16px;
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  max-height: 400px;
  overflow-y: auto;
}
.search-result-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-100);
  cursor: pointer;
  transition: background 0.15s;
  text-decoration: none;
  color: #333;
}
.search-result-item:last-child { border-bottom: none; }
.search-result-item:hover { background: var(--gray-50); }
.search-result-item .result-name { font-weight: 600; font-size: 0.95rem; }
.search-result-item .result-price { color: var(--primary); font-weight: 700; margin-left: auto; white-space: nowrap; }
.search-result-item .result-cat { font-size: 0.78rem; color: var(--gray-600); }
.search-empty { padding: 24px; text-align: center; color: var(--gray-600); }
.btn-close-search {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
}

/* ════════════════════════════════════════════════════
   HERO CAROUSEL
   ════════════════════════════════════════════════════ */
.hero-carousel { position: relative; }
.hero-carousel .carousel-item img {
  height: 100vh;
  min-height: 500px;
  max-height: 700px;
  object-fit: cover;
  width: 100%;
  filter: brightness(0.55);
}
.hero-carousel .carousel-caption {
  text-align: left;
  top: 50%;
  transform: translateY(-50%);
  bottom: auto;
  left: 0;
  right: 0;
  padding: 0 5%;
}
.hero-caption-tag {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 16px;
}
.hero-carousel .carousel-caption h1 {
  font-size: clamp(2rem, 5vw, 3.8rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.1;
  margin-bottom: 28px;
}
.hero-carousel .btn { font-weight: 700; letter-spacing: 0.04em; }

/* ════════════════════════════════════════════════════
   FEATURES STRIP (4 badges)
   ════════════════════════════════════════════════════ */
.features-strip {
  background: var(--red-tint-1);
  padding: 36px 0;
  border-top: 3px solid var(--primary);
  border-bottom: 3px solid var(--primary);
}
.feature-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
}
.feature-badge-icon {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.4rem;
}
.feature-badge h5 {
  font-size: 0.9rem;
  font-weight: 800;
  margin: 0;
  color: var(--secondary);
}
.feature-badge p {
  font-size: 0.78rem;
  color: var(--gray-600);
  margin: 0;
}

/* ════════════════════════════════════════════════════
   ABOUT PREVIEW SECTION
   ════════════════════════════════════════════════════ */
.about-preview-img {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card-hover);
  height: 100%;
  min-height: 380px;
}
.about-preview-img img {
  width: 100%;
  height: 100%;
  min-height: 380px;
  object-fit: cover;
  display: block;
}
.banner-logo {
  max-width: 320px;
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  display: block;
  margin: 0 auto 1.5rem;
}

/* ════════════════════════════════════════════════════
   CATEGORY CARDS (with GIF icons) — Horizontal rectangle
   ════════════════════════════════════════════════════ */
.category-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  border: 2px solid var(--primary);
  padding: 0;
  transition: box-shadow 0.35s ease;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  height: 100%;
  overflow: hidden;
}
.category-card:hover {
  box-shadow: var(--shadow-card-hover);
  color: inherit;
  text-decoration: none;
}
/* Clip zone — constrains the GIF so text is never pushed out */
.category-card-img-wrap {
  width: 42%;
  min-width: 42%;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--red-tint-1);
  display: flex;
  align-items: center;
  justify-content: center;
}
.category-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 20px;
  transition: transform 0.4s ease;
  transform-origin: center center;
  display: block;
}
.category-card:hover img {
  transform: scale(1.22);
}
.category-card-body {
  padding: 1.5rem 1.5rem 1.5rem 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1;
  min-width: 0;
}
.category-card h4 {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--secondary);
  margin-bottom: 0.4rem;
}
.category-card p {
  font-size: 0.84rem;
  color: var(--gray-600);
  margin: 0;
  line-height: 1.5;
}
.category-card .cat-link {
  display: inline-block;
  margin-top: 0.75rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ════════════════════════════════════════════════════
   DEAL / PRODUCT CARDS
   ════════════════════════════════════════════════════ */
.deal-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
  border: 2px solid var(--primary);
}
.deal-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-card-hover);
}
.deal-card-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: var(--gray-100);
}
.deal-card-body {
  padding: 1rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.deal-card-cat {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--gray-600);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}
.deal-card-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--secondary);
  margin-bottom: 8px;
  flex-grow: 1;
}
.deal-card-price {
  font-size: 1.4rem;
  font-weight: 900;
  color: var(--primary);
}
.deal-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.deal-badge-oferta { background: var(--primary); color: #fff; }
.deal-badge-frio   { background: #1565C0; color: #fff; }

/* ════════════════════════════════════════════════════
   STATS BANNER
   ════════════════════════════════════════════════════ */
.stats-banner {
  background: #B00000;
  padding: 48px 0;
  color: #fff;
}
.stat-item { text-align: center; }
.stat-number {
  font-family: var(--font-heading);
  font-size: 2.8rem;
  font-weight: 900;
  line-height: 1;
  color: #fff;
}
.stat-label {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.8);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ════════════════════════════════════════════════════
   TESTIMONIALS (Owl Carousel)
   ════════════════════════════════════════════════════ */
.testimonial-item {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  padding: 2rem 2rem 1.5rem;
  position: relative;
  margin-top: 1.5rem;
  border: 2px solid var(--primary);
}
.testimonial-item i.fa-quote-left {
  color: var(--primary);
  position: absolute;
  top: -18px;
  left: 30px;
  font-size: 2rem;
}
.testimonial-item p { color: #555; font-size: 0.95rem; line-height: 1.7; }
.testimonial-item h5 { font-weight: 800; color: var(--secondary); margin: 0; }
/* ── Owl Carousel dots — horizontal row ── */
.owl-carousel .owl-dots {
  display: flex !important;
  flex-direction: row !important;
  justify-content: center;
  align-items: center;
  margin-top: 28px;
  gap: 6px;
}
.owl-carousel .owl-dot {
  display: inline-flex !important;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}
.owl-carousel .owl-dot span {
  width: 10px;
  height: 10px;
  background: var(--gray-200);
  border-radius: 50%;
  display: block;
  transition: background 0.25s, transform 0.25s;
}
.owl-carousel .owl-dot.active span {
  background: var(--primary);
  transform: scale(1.3);
}

/* ── Owl Carousel nav arrows ── */
.owl-carousel .owl-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}
.owl-carousel .owl-nav button.owl-prev,
.owl-carousel .owl-nav button.owl-next {
  width: 42px;
  height: 42px;
  border-radius: 50% !important;
  background: #fff !important;
  border: 2px solid var(--gray-200) !important;
  color: var(--secondary) !important;
  font-size: 1.1rem !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  box-shadow: var(--shadow-card);
}
.owl-carousel .owl-nav button.owl-prev:hover,
.owl-carousel .owl-nav button.owl-next:hover {
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  color: #fff !important;
}
.owl-carousel .owl-nav button.owl-prev i,
.owl-carousel .owl-nav button.owl-next i {
  font-size: 1rem;
  line-height: 1;
}

/* ════════════════════════════════════════════════════
   CTA BAND
   ════════════════════════════════════════════════════ */
.cta-band {
  background: #B00000;
  padding: 60px 0;
}
.cta-band h2 { color: #fff; font-weight: 900; }
.cta-band p  { color: rgba(255,255,255,0.85); }
.cta-band .btn-secondary { font-weight: 700; }

/* ════════════════════════════════════════════════════
   FILTER BAR (Ofertas page)
   ════════════════════════════════════════════════════ */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 32px;
  align-items: center;
}
.filter-btn {
  border: 2px solid var(--gray-200);
  background: #fff;
  border-radius: var(--radius-pill);
  padding: 6px 18px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  color: var(--gray-600);
}
.filter-btn:hover,
.filter-btn.active {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}
.filter-btn.cold-toggle {
  border-color: #1565C0;
  color: #1565C0;
}
.filter-btn.cold-toggle.active {
  background: #1565C0;
  color: #fff;
}

/* ════════════════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════════════════ */
.footer {
  background: var(--secondary) !important;
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
}
.footer h4 {
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
}
.footer p { color: rgba(255,255,255,0.65); margin-bottom: 0.6rem; }
.footer p i { color: var(--primary); width: 20px; }
.footer-logo-img {
  height: 50px;
  width: auto;
  object-fit: contain;
  margin-bottom: 6px;
  display: block;
}
.footer-brand-sub {
  display: block;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}
.footer-social { display: flex; gap: 10px; margin-top: 12px; }
.footer-social a {
  width: 36px; height: 36px;
  background: rgba(255,255,255,0.08);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.9rem;
  transition: background 0.2s;
  text-decoration: none;
}
.footer-social a:hover { background: var(--primary); }

.footer .btn-link {
  display: block;
  color: rgba(255,255,255,0.65) !important;
  text-decoration: none;
  padding: 3px 0;
  font-size: 0.88rem;
  transition: color 0.2s;
  text-align: left !important;
}
.footer .btn-link:hover { color: var(--primary) !important; }

/* Newsletter row inside footer */
.footer-newsletter {
  display: flex;
  gap: 6px;
  align-items: center;
}
.footer-newsletter .form-control {
  flex: 1;
  min-width: 0;
  border-radius: var(--radius-pill) !important;
  border-color: rgba(255,255,255,0.2);
  color: #fff;
}
.footer-newsletter .form-control::placeholder { color: rgba(255,255,255,0.45); }
.footer-newsletter .btn { border-radius: var(--radius-pill) !important; flex-shrink: 0; }

.copyright {
  background: rgba(0,0,0,0.25);
  padding: 18px 0;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.45);
}
.copyright a { color: rgba(255,255,255,0.55); }
.copyright a:hover { color: var(--primary); }
