/* ================================================================
   SEC-CONTENT-IMAGE v3.1
   Focofy Factory — Design Tokens Contract v3.6

   v3.0 → v3.1:
     - max-width: 1023px (breakpoint inválido) removido
       ↳ order de layout reescrito como mobile-first:
         base = mobile (mídia acima, conteúdo abaixo — order 1/2)
         desktop via min-width: 1024px aplica order da variante image-left
   ================================================================ */

/* ── BASE LAYOUT ─────────────────────────────────────────────── */

.focofy-content-image {
  display: grid;
  grid-template-columns: 1fr;           /* mobile: coluna única */
  gap: var(--space-6);
  align-items: center;
  padding: var(--space-6) 0;
}

@media (min-width: 1024px) {            /* --bp-desktop */
  .focofy-content-image {
    grid-template-columns: var(--content-size, 50%) var(--media-size, 50%);
    gap: var(--space-8);
  }
}

/* ── LAYOUT VARIANTS ─────────────────────────────────────────── */

/* Mobile-first: mídia sempre acima (order 1), conteúdo abaixo (order 2) */
.focofy-content-image__content { order: 2; }
.focofy-content-image__media   { order: 1; }

@media (min-width: 1024px) {            /* --bp-desktop */

  /* image-right (default): content | media */
  .focofy-content-image--image-right .focofy-content-image__content { order: 1; }
  .focofy-content-image--image-right .focofy-content-image__media   { order: 2; }

  /* image-left: media | content — inverte colunas no grid */
  .focofy-content-image--image-left {
    grid-template-columns: var(--media-size, 50%) var(--content-size, 50%);
  }
}

/* ── BACKGROUND VARIANTS ─────────────────────────────────────── */

.focofy-content-image--bg-none {
  background: transparent;
}

.focofy-content-image--bg-light {
  background: color-mix(in srgb, var(--color-surface-2) 50%, transparent);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
}

.focofy-content-image--bg-dark {
  background: var(--gradient-dark);
  color: var(--color-text-inverse);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-lg);
}

/* ── CONTENT COLUMN ──────────────────────────────────────────── */

.focofy-content-image__content {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.focofy-content-image__subtitle {
  margin: 0;
  font-size: var(--font-size-sm);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.7;
  color: var(--color-accent-2);
}

.focofy-content-image__title {
  margin: 0;
  font-size: var(--font-size-4xl);
  line-height: var(--lh-tight);
  font-weight: var(--fw-extrabold);
}

.focofy-content-image__text {
  font-size: var(--font-size-base);
  line-height: var(--lh-relaxed);
  color: var(--color-text-muted);
}

.focofy-content-image__text p {
  margin: 0 0 var(--space-4);
}

.focofy-content-image__text p:last-child {
  margin-bottom: 0;
}

/* ── CHECKLIST ───────────────────────────────────────────────── */

.focofy-content-image__checklist {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.focofy-content-image__checklist-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  font-size: var(--font-size-base);
  line-height: var(--lh-relaxed);
}

.focofy-content-image__check-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  color: var(--color-accent);
}

/* ── CTAs ────────────────────────────────────────────────────── */

.focofy-content-image__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-2);
}

/* ── MEDIA COLUMN ────────────────────────────────────────────── */

.focofy-content-image__media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

/* Imagem */
.focofy-content-image__img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
}

/* Lottie */
.focofy-content-image__lottie {
  width: 100%;
  min-height: 300px;
}

/* Vídeo MP4 */
.focofy-content-image__video {
  width: 100%;
  border-radius: var(--radius-lg);
}

/* iFrame embed (YouTube / Vimeo) */
.focofy-content-image__video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;             /* 16:9 */
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-surface-dark);
}

.focofy-content-image__iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ── RESPONSIVO ──────────────────────────────────────────────── */

@media (max-width: 767px) {             /* abaixo de --bp-tablet */
  .focofy-content-image {
    padding: var(--space-4) 0;
    gap: var(--space-4);
  }

  .focofy-content-image--bg-light,
  .focofy-content-image--bg-dark {
    padding: var(--space-6);
  }

  .focofy-content-image__title {
    font-size: var(--font-size-3xl);
  }

  .focofy-content-image__ctas {
    flex-direction: column;
  }

  .focofy-content-image__ctas a {
    width: 100%;
    text-align: center;
  }
}

/* ── ACESSIBILIDADE ──────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  .focofy-content-image__video {
    animation: none;
  }
}
