/* ==========================================================================
   HALFTONE WORDMARK FOOTER — P7 Barber Master Studio
   Adaptado de 21st.dev (HalftoneWordmarkFooter) a HTML/CSS/JS puro
   Full Responsive: Móvil (320px+) · Tablet (680px+) · Escritorio (1024px+)
   ========================================================================== */

.hwf-root {
  --hwf-bg: #0A0909;
  --hwf-ink: #F2EFE9;
  --hwf-warm: var(--p7-champagne, #C3B9A0);
  --hwf-yellow: var(--p7-colombia-yellow, #FCD116);
  --hwf-mono: var(--font-sans, 'Switzer', sans-serif);
  --hwf-accent: var(--font-accent, 'IBM Plex Mono', monospace);

  position: relative;
  width: 100%;
  height: clamp(490px, 58svh, 580px);
  overflow: hidden;
  isolation: isolate;
  background: var(--hwf-bg);
  color: var(--hwf-ink);
  -webkit-font-smoothing: antialiased;
  touch-action: pan-y;
}

.hwf-root canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  max-width: none;
  pointer-events: none;
}

.hwf-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Cabecera superior: Logo P7 sin fondo + Navegación + Legal */
.hwf-top {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1320px;
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 24px 32px;
  padding: clamp(32px, 4.2vw, 48px) var(--gutter, clamp(20px, 5vw, 80px)) 0;
  font-family: var(--hwf-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1.65;
}

.hwf-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}

.hwf-slogan {
  margin: 0;
  max-width: 34ch;
  font-family: var(--font-sans, 'Switzer', sans-serif);
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: 0.01em;
  text-transform: none;
  color: rgba(232, 229, 223, 0.86);
}

.hwf-logo-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: transform 280ms cubic-bezier(0.16, 1, 0.3, 1), opacity 220ms ease;
}

.hwf-logo-link:hover {
  transform: scale(1.04);
}

.hwf-logo-img {
  width: clamp(96px, 9.5vw, 124px);
  height: auto;
  display: block;
  object-fit: contain;
  background: transparent;
  filter: drop-shadow(0 8px 22px rgba(0, 0, 0, 0.5));
}

.hwf-col h3 {
  margin: 0 0 10px;
  font-family: var(--hwf-accent);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--p7-colombia-yellow, #FCD116);
  opacity: 1;
}

.hwf-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.hwf-col a,
.hwf-col button,
.hwf-up {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  color: #F2EFE9;
  text-decoration: none;
  opacity: 1;
  background: none;
  border: 0;
  padding: 4px 0;
  font-family: var(--font-sans, 'Switzer', sans-serif);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  background-image: linear-gradient(var(--hwf-yellow), var(--hwf-yellow));
  background-size: 0% 1px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition:
    opacity 240ms ease,
    color 240ms ease,
    background-size 340ms cubic-bezier(0.2, 0.7, 0.1, 1);
}

.hwf-col a:hover,
.hwf-col button:hover,
.hwf-up:hover {
  opacity: 1;
  color: var(--p7-colombia-yellow, #FCD116);
  background-size: 100% 1px;
}

.hwf-col a:focus-visible,
.hwf-col button:focus-visible,
.hwf-up:focus-visible {
  outline: 1px solid var(--p7-colombia-yellow, #FCD116);
  outline-offset: 4px;
  opacity: 1;
}

/* Créditos MYNEXT (centrados encima de la línea separadora · estilo editorial delicado) */
.hwf-credits {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1320px;
  margin-inline: auto;
  padding: clamp(20px, 2.6vw, 28px) var(--gutter, clamp(20px, 5vw, 80px)) 0;
  display: flex;
  justify-content: center;
  text-align: center;
}

.hwf-credit-link {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 0 5px;
  font-family: var(--font-display, 'Fraunces', serif);
  font-style: italic;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.015em;
  line-height: 1.5;
  text-transform: none;
  color: rgba(243, 234, 216, 0.72);
  text-decoration: none;
  transition: color 220ms ease;
}

.hwf-credit-link strong {
  font-family: var(--font-sans, 'Switzer', sans-serif);
  font-style: normal;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #FFFFFF;
  transition: color 220ms ease;
}

.hwf-credit-link:hover,
.hwf-credit-link:hover strong {
  color: var(--p7-colombia-yellow, #FCD116);
}

/* Línea separadora + solo Volver arriba */
.hwf-rule {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1320px;
  margin-inline: auto;
  padding: clamp(14px, 2vw, 20px) var(--gutter, clamp(20px, 5vw, 80px)) 0;
}

.hwf-rule-inner {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(243, 234, 216, 0.18);
  font-family: var(--hwf-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Móvil (< 680px): Amplio, aireado, tipografía nítida y sin solape con el wordmark */
@media (max-width: 679px) {
  .hwf-root {
    height: 648px;
    min-height: 648px;
  }

  .hwf-top {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 22px 16px;
    padding: 28px var(--gutter, 20px) 0;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    line-height: 1.5;
  }

  .hwf-brand {
    grid-column: 1 / -1;
    align-items: center;
    text-align: center;
    gap: 14px;
    margin-bottom: 4px;
  }

  .hwf-slogan {
    max-width: 34ch;
    font-size: 0.8125rem;
    line-height: 1.55;
    letter-spacing: 0.01em;
  }

  .hwf-logo-img {
    width: 72px;
  }

  .hwf-col h3 {
    font-size: 0.75rem;
    margin-bottom: 8px;
  }

  .hwf-col a,
  .hwf-col button,
  .hwf-up {
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    min-height: 36px;
    padding: 2px 0;
  }

  .hwf-col--legal {
    width: 100%;
    text-align: right;
    justify-self: stretch;
  }

  .hwf-col--legal ul {
    align-items: flex-end;
  }

  .hwf-col ul {
    gap: 4px;
  }

  .hwf-credits {
    justify-content: center;
    padding: 16px var(--gutter, 20px) 0;
  }

  .hwf-credit-link {
    font-size: 0.64rem;
    letter-spacing: 0.01em;
    gap: 0 4px;
  }

  .hwf-credit-link strong {
    font-size: 0.56rem;
    letter-spacing: 0.1em;
  }

  .hwf-rule {
    padding: 12px var(--gutter, 20px) 0;
  }

  .hwf-rule-inner {
    padding-top: 10px;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
  }
}

@media (min-width: 680px) and (max-width: 1023px) {
  .hwf-root {
    height: 540px;
  }
}

/* Escritorio (>= 1024px): Más respiro vertical entre columnas, créditos, línea y wordmark */
@media (min-width: 1024px) {
  .hwf-root {
    height: clamp(610px, 72svh, 700px);
  }

  .hwf-top {
    padding-top: clamp(48px, 5.2vw, 68px);
    gap: 28px 40px;
  }

  .hwf-credits {
    padding-top: clamp(32px, 3.6vw, 44px);
  }

  .hwf-rule {
    padding-top: clamp(18px, 2.2vw, 26px);
  }

  .hwf-rule-inner {
    padding-top: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hwf-col a,
  .hwf-col button,
  .hwf-up,
  .hwf-logo-link {
    transition: none;
  }
}
