/* ==========================================================================
   components.css — reusable pieces shared across pages
   ========================================================================== */

/* ---- Buttons ----------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: nowrap;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, filter 0.2s;
}

.btn--lg {
  padding: 15px 28px;
  font-size: 1.1875rem;
}

.btn--accent {
  background: var(--accent);
  color: var(--white);
}

.btn--accent:hover {
  filter: brightness(1.14);
}

.btn--whatsapp {
  background: var(--whatsapp);
  color: var(--ink);
}

.btn--whatsapp:hover {
  filter: brightness(1.08);
}

.btn--ghost {
  border-color: rgba(255, 255, 255, 0.28);
  color: var(--white);
}

.btn--ghost:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.06);
}

.btn--outline {
  border-color: var(--text);
  color: var(--text);
}

.btn--outline:hover {
  background: var(--text);
  color: var(--white);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  transition: color 0.2s, gap 0.2s;
}

.text-link:hover {
  gap: 12px;
  color: var(--hover);
}

/* ---- Eyebrow label ----------------------------------------------------- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: currentColor;
}

.eyebrow--light {
  color: var(--accent-bright);
}

/* ---- Tag --------------------------------------------------------------- */
.tag {
  display: inline-block;
  margin-left: 10px;
  padding: 1px 8px;
  background: var(--accent);
  color: var(--white);
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  vertical-align: 2px;
}

/* ---- Product cards ----------------------------------------------------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(264px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--white);
  border: 1px solid var(--line);
  transition: border-color 0.2s, box-shadow 0.25s, transform 0.25s;
}

.product-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-card);
  transform: translateY(-3px);
}

.product-card__link {
  display: flex;
  height: 100%;
  flex-direction: column;
}

/* Images are absolutely placed inside a fixed-ratio frame so a photo's own
   proportions can never stretch the card. */
.product-card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.product-card__media img {
  position: absolute;
  inset: 18px;
  width: calc(100% - 36px);
  height: calc(100% - 36px);
  object-fit: contain;
}

.product-card__body {
  flex: 1;
  padding: 20px 22px 18px;
}

.product-card__category {
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.product-card__title {
  margin-bottom: 10px;
  font-size: 1.75rem;
  line-height: 1.02;
}

.product-card__summary {
  font-size: 0.96875rem;
  line-height: 1.5;
  color: var(--muted);
}

.product-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 22px;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--muted);
}

.product-card__badge {
  font-weight: 600;
}

.product-card__go {
  display: grid;
  width: 34px;
  height: 34px;
  flex: none;
  place-items: center;
  background: var(--ink);
  color: var(--white);
  transition: background-color 0.2s;
}

.product-card:hover .product-card__go {
  background: var(--accent);
}

/* ---- Logo wall (customers) --------------------------------------------- */
.logo-wall {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  border-top: 1px solid var(--line-strong);
  border-left: 1px solid var(--line-strong);
}

.logo-wall__item {
  display: flex;
  height: 104px;
  align-items: center;
  justify-content: center;
  padding: 18px 20px;
  background: var(--white);
  border-right: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.logo-wall__item img {
  width: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0.72;
  transition: filter 0.25s, opacity 0.25s;
}

.logo-wall__item:hover img {
  filter: none;
  opacity: 1;
}

/* ---- Spec table / definition rows ------------------------------------- */
.spec-table > div {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line-strong);
  font-size: 0.96875rem;
}

.spec-table > div:first-child {
  border-top: 1px solid var(--line-strong);
}

.spec-table dt {
  color: var(--muted);
}

.spec-table dd {
  font-weight: 600;
  text-align: right;
}

/* ---- CTA band ---------------------------------------------------------- */
.cta {
  background: var(--ink);
  border-top: 3px solid var(--accent);
  color: var(--white);
}

.cta__inner {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  align-items: center;
  gap: 48px;
  padding-block: clamp(56px, 7vw, 88px);
}

.cta__title {
  margin-bottom: 14px;
  font-size: clamp(2rem, 4.4vw, 3.25rem);
}

.cta__copy p:last-child {
  max-width: 52ch;
  color: var(--on-dark-muted);
}

.cta__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ---- Floating WhatsApp button ------------------------------------------ */
.wa-float {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 90;
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  border-radius: 50%;
  background: var(--whatsapp);
  color: var(--ink);
  box-shadow: 0 6px 20px rgba(12, 14, 18, 0.35);
  transition: transform 0.2s;
}

.wa-float:hover {
  transform: scale(1.07);
}

@media (max-width: 1000px) {
  .logo-wall {
    grid-template-columns: repeat(4, 1fr);
  }

  .cta__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .cta__actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

@media (max-width: 640px) {
  .logo-wall {
    grid-template-columns: repeat(2, 1fr);
  }

  .logo-wall__item {
    height: 88px;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .cta__actions .btn {
    flex: 1 1 100%;
  }
}

/* ---- Extra mobile fixes (appended) ------------------------------------- */

/* Product card title scaling */
@media (max-width: 640px) {
  .product-card__title {
    font-size: 1.5rem;
  }

  .product-card__body {
    padding: 16px 16px 14px;
  }

  .product-card__foot {
    padding: 12px 16px;
  }

  /* CTA stacks */
  .cta__inner {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-block: 44px;
  }

  .cta__actions {
    flex-direction: column;
  }

  .cta__actions .btn {
    width: 100%;
    justify-content: center;
  }

  .cta__title {
    font-size: clamp(1.75rem, 8vw, 2.25rem);
  }
}

/* Prevent any element from causing horizontal overflow */
@media (max-width: 640px) {
  .wa-float {
    right: 14px;
    bottom: 14px;
    width: 48px;
    height: 48px;
  }
}
