/* =============================================
   HARVESTCHILE — PATCH v4
   ============================================= */

/* ── 1. FUENTE TKTYPE ── */
@font-face {
  font-family: 'TKTypeRegular';
  src: url('/assets/fonts/TKTypeRegular.woff2') format('woff2'),
       url('/assets/fonts/TKTypeRegular.woff')  format('woff'),
       url('/assets/fonts/TKTypeRegular.ttf')   format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root { --font-body: 'TKTypeRegular', system-ui, -apple-system, sans-serif; }
html, body { font-family: 'TKTypeRegular', system-ui, -apple-system, sans-serif !important; }
input, select, textarea, button, h1, h2, h3, h4, h5, h6 { font-family: inherit !important; }


/* ── 2. LAYOUT STICKY ── */
html { height: 100%; overflow: hidden; }
body { height: 100%; display: flex; flex-direction: column; overflow: hidden; }
.navbar { flex-shrink: 0; }
.site-main {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--teal-accent, #7DD8D4) transparent;
}
.site-main::-webkit-scrollbar { width: 5px; }
.site-main::-webkit-scrollbar-thumb { background: var(--teal-accent, #7DD8D4); border-radius: 3px; }
.footer { flex-shrink: 0; padding: 0 !important; }


/* ── 3. FOOTER COMPACTO ── */
.footer-grid { display: none !important; }

.footer-compact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-compact__left { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.footer-brand-link { display: flex; align-items: center; }
.footer-sep { color: rgba(255,255,255,.2); font-size: .9rem; }
.footer-tagline { font-size: .72rem; color: rgba(255,255,255,.38); white-space: nowrap; }
.footer-compact__center { display: flex; align-items: center; gap: 0; flex-wrap: wrap; }
.footer-compact__center a {
  font-size: .75rem; color: rgba(255,255,255,.54);
  padding: 4px 9px; border-radius: 4px;
  transition: color .16s, background .16s; white-space: nowrap;
}
.footer-compact__center a:hover { color: var(--teal-light, #0AB4AB); background: rgba(255,255,255,.06); }
.footer-compact__right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.footer-compact__right a { white-space: nowrap; font-size: .75rem; }

.footer-bottom-bar {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 6px; padding: 8px 20px;
}
.footer-bottom-bar p { font-size: .68rem; color: rgba(255,255,255,.28); margin: 0; }
.footer-bottom-bar .footer-bottom-links { display: flex; gap: 12px; }
.footer-bottom-bar .footer-bottom-links a { color: rgba(255,255,255,.25); font-size: .68rem; transition: color .16s; }
.footer-bottom-bar .footer-bottom-links a:hover { color: var(--teal-light, #0AB4AB); }


/* ── 4. IMÁGENES GRANDES (desktop) ── */
.hero-visual img        { max-width: 560px !important; width: 100% !important; }
.page-hero__img-wrap    { width: 420px !important; }
.page-hero__product-img { max-width: 420px !important; }
.product-card           { grid-template-columns: 56px 130px 1fr 28px !important; }
.product-card__img      { width: 130px !important; height: 106px !important; }
.product-card__img img  { max-height: 106px !important; }
.detail-header-img-wrap { width: 120px !important; height: 100px !important; }


/* ── 5. TABLET ── */
@media (max-width: 900px) {
  .page-hero__img-wrap    { width: 320px !important; }
  .page-hero__product-img { max-width: 320px !important; }
  .footer-tagline { display: none; }
}


/* ── 6. MÓVIL ── */
@media (max-width: 640px) {

  /* INDEX HERO: compacto para ceder espacio a las cards */
  .hero-inner {
    grid-template-columns: 0.55fr 1.45fr !important;
    min-height: auto !important;
    align-items: center !important;
  }
  .hero-text-wrap { padding: 8px 0 !important; }
  .hero-text-wrap h1 { font-size: .82rem !important; line-height: 1.1 !important; margin-bottom: 4px !important; }
  .eyebrow { font-size: .5rem !important; margin-bottom: 4px !important; }
  .hero-desc  { display: none !important; }
  .hero-badges { display: none !important; }
  .hero-dots  { display: none !important; }
  .hero-actions { gap: 4px !important; margin-bottom: 6px !important; flex-direction: column !important; align-items: flex-start !important; }
  .hero-actions .btn { font-size: .58rem !important; padding: 5px 8px !important; }
  .hero-visual { justify-content: flex-end !important; padding: 4px 0 !important; }
  .hero-visual img { max-width: 100% !important; width: 100% !important; }

  /* PAGE HERO SPLIT */
  .page-hero__inner--split {
    flex-direction: row !important;
    align-items: center !important;
    gap: 4px !important;
    padding: 12px 8px 10px !important;
    flex-wrap: nowrap !important;
  }
  .page-hero__text { flex: 0 0 26% !important; min-width: 0 !important; }
  .page-hero__inner--split .breadcrumb { font-size: .52rem !important; margin-bottom: 6px !important; }
  .page-hero__inner--split .section-eyebrow { font-size: .5rem !important; }
  .page-hero__inner--split h1 { font-size: .62rem !important; line-height: 1.12 !important; margin-bottom: 4px !important; }
  .page-hero__inner--split p  { font-size: .5rem !important; margin-bottom: 5px !important; }
  .page-hero__inner--split .hero-checks { display: none !important; }
  .page-hero__inner--split .btn { font-size: .5rem !important; padding: 4px 6px !important; gap: 2px !important; }
  .page-hero__img-wrap {
    flex: 0 0 72% !important;
    width: 72% !important;
    justify-content: flex-end !important;
  }
  .page-hero__product-img { max-width: 100% !important; width: 100% !important; }

  /* ══════════════════════════════════════════
     PRODUCT CARDS en móvil:
     - Sin círculo (oculto)
     - Imagen pequeña
     - Texto con más espacio y wrap en 2 líneas
  ══════════════════════════════════════════ */

  /* Ocultar el círculo vacío — no aporta nada sin emoji */
  .product-card__circle {
    display: none !important;
  }

  .product-card {
    grid-template-columns: 38px 1fr 12px !important;
    padding: 5px 12px !important;
    gap: 8px !important;
    min-height: 0 !important;
  }
  .product-card__img {
    width: 38px !important;
    height: 30px !important;
    flex-shrink: 0 !important;
  }
  .product-card__img img {
    max-height: 30px !important;
    max-width: 38px !important;
  }
  .product-card__body {
    padding: 0 !important;
    min-width: 0 !important;
  }
  .product-card__body h3 {
    font-size: .62rem !important;
    margin-bottom: 1px !important;
    line-height: 1.2 !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
    word-break: break-word !important;
  }
  .product-card__body p {
    font-size: .54rem !important;
    margin-bottom: 1px !important;
    line-height: 1.2 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 1 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
  }
  .product-card__cta {
    font-size: .52rem !important;
    gap: 2px !important;
  }
  .product-card__chevron {
    font-size: .8rem !important;
  }

  /* FOOTER MÓVIL: ocultar marquee, solo copyright */
  .footer-compact { display: none !important; }
  .footer-brands  { display: none !important; }
  .footer-bottom-bar {
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 5px 14px !important;
    gap: 6px !important;
  }
  .footer-bottom-bar p { font-size: .58rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .footer-bottom-links { gap: 8px; flex-shrink: 0; }
  .footer-bottom-links a { font-size: .58rem; white-space: nowrap; }
  .footer-bottom-links a:nth-child(1),
  .footer-bottom-links a:nth-child(2) { display: none; }
}


/* ── 7. PANTALLAS MUY PEQUEÑAS (<=380px) ── */
@media (max-width: 380px) {
  .hero-inner { grid-template-columns: 0.5fr 1.5fr !important; }
  .hero-visual { justify-content: flex-end !important; padding: 0 0 4px !important; }
  .page-hero__inner--split { flex-direction: row !important; gap: 4px !important; }
  .page-hero__text { flex: 0 0 24% !important; }
  .page-hero__img-wrap { flex: 0 0 74% !important; width: 74% !important; }

  .product-card {
    grid-template-columns: 30px 1fr 10px !important;
    padding: 4px 8px !important;
    gap: 6px !important;
  }
  .product-card__img {
    width: 30px !important;
    height: 24px !important;
  }
  .product-card__img img {
    max-height: 24px !important;
    max-width: 30px !important;
  }
  .product-card__body h3 { font-size: .58rem !important; }
  .product-card__body p  { font-size: .5rem !important; }
  .product-card__cta     { font-size: .48rem !important; }
}


/* ── FOOTER BRANDS — marquee deslizante ──────────────── */
.footer-brands {
  background: rgba(0,0,0,.22);
  border-bottom: 1px solid rgba(255,255,255,.07);
  overflow: hidden;
  position: relative;
}
.footer-brands::before,
.footer-brands::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 48px;
  z-index: 2;
  pointer-events: none;
}
.footer-brands::before {
  left: 0;
  background: linear-gradient(to right, rgba(11,90,87,.9), transparent);
}
.footer-brands::after {
  right: 0;
  background: linear-gradient(to left, rgba(11,90,87,.9), transparent);
}
.footer-brands__track-wrap { overflow: hidden; width: 100%; }
.footer-brands__track {
  display: flex;
  align-items: center;
  gap: 0;
  width: max-content;
  animation: brands-scroll 18s linear infinite;
  padding: 8px 0;
}
.footer-brands__track:hover { animation-play-state: paused; }

@keyframes brands-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.footer-brands__dot {
  width: 4px; height: 4px; border-radius: 50%;
  background: rgba(255,255,255,.18);
  margin: 0 20px; flex-shrink: 0;
}
.footer-brand-card {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; padding: 5px 14px;
  border-radius: 8px; transition: background .18s ease;
  flex-shrink: 0; white-space: nowrap;
}
.footer-brand-card:hover { background: rgba(255,255,255,.06); }
.footer-brand-card__logo {
  width: 54px; height: 38px; border-radius: 6px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; flex-shrink: 0;
}
.footer-brand-card__logo img {
  max-width: 100%; max-height: 100%; object-fit: contain; padding: 4px;
}
.footer-brand-card__logo--fallback {
  display: none; align-items: center; justify-content: center;
  font-weight: 900; font-size: .8rem; letter-spacing: .04em;
  width: 100%; height: 100%;
}
.footer-brand-card__logo--gemu { color: var(--teal-light, #0AB4AB); }
.footer-brand-card__logo--lw   { color: rgba(255,255,255,.8); }
.footer-brand-card__info { display: flex; flex-direction: column; gap: 1px; }
.footer-brand-card__info strong {
  font-size: .75rem; font-weight: 800; color: rgba(255,255,255,.85);
  white-space: nowrap; display: block;
}
.footer-brand-card__info span {
  font-size: .62rem; color: rgba(255,255,255,.38);
  white-space: nowrap; display: block;
}
.footer-brand-tagline {
  display: flex; align-items: center; gap: 10px;
  padding: 5px 14px; flex-shrink: 0; white-space: nowrap;
}
.footer-brand-tagline div { display: flex; flex-direction: column; gap: 2px; }
.footer-brand-tagline strong {
  font-size: .75rem; font-weight: 800; color: rgba(255,255,255,.85);
  white-space: nowrap; display: block;
}
.footer-brand-tagline span {
  font-size: .62rem; color: rgba(255,255,255,.4);
  white-space: nowrap; display: block;
}

@media (max-width: 640px) {
  .footer-brands__track { animation-duration: 14s; }
  .footer-brand-card { padding: 4px 10px; gap: 7px; }
  .footer-brand-card__logo { width: 40px; height: 30px; }
  .footer-brand-card__info strong { font-size: .68rem; }
  .footer-brand-card__info span   { font-size: .58rem; }
  .footer-brand-tagline { padding: 4px 10px; gap: 7px; }
  .footer-brand-tagline strong { font-size: .68rem; }
  .footer-brand-tagline span   { font-size: .58rem; display: block !important; }
  .footer-brands__dot { margin: 0 12px; }
}
/* Íconos de imagen en cards de producto (index) */
.pcard-icon-img {
  width: 48px;
  height: 48px;
  object-fit: contain;
  display: block;
}

/* Íconos de imagen en "Cómo podemos ayudarle" (contacto) */
.contact-how-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}
.footer-icon-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.footer-icon-img {
  width: 16px;
  height: 16px;
  object-fit: contain;
}