/* ==========================================================================
   KONNO - Landing Temporal Fase 1
   Metodología: IBXF
   Dirección visual: VD-003B "White Kinu"
   Atmósfera: Helado artesanal japonés contemporáneo, blanco editorial, cálido y sensorial
   Motion Design: Animaciones elegantes y sutiles con soporte prefers-reduced-motion
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Tipografía y fuentes locales
   -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('assets/fonts/Manrope-Variable.woff2') format('woff2');
}

/* --------------------------------------------------------------------------
   2. Variables de diseño y tokens (VD-003B White Kinu)
   -------------------------------------------------------------------------- */
:root {
  /* Fondo blanco puro */
  --color-bg: #FFFFFF;
  --color-bg-elevated: #FAF7F2;

  /* Marco del producto: arco crema cálido */
  --color-frame-bg: #F7F4EE;
  --color-frame-border: rgba(122, 78, 45, 0.16);

  /* Jerarquía tipográfica accesible sobre blanco puro (WCAG AAA) */
  --color-text-primary: #111111;       /* Negro profundo: 18.88:1 */
  --color-text-accent: #7A4E2D;        /* Bronce cálido Kinu: 7.19:1 (Supera AAA) */
  --color-text-secondary: #555555;     /* Gris editorial: 7.46:1 (Supera AAA) */
  --color-text-muted: #767676;         /* Detalles: 4.54:1 (Cumple AA) */

  /* Botón CTA Cápsula (Fondo negro, texto blanco) */
  --color-cta-bg: #111111;
  --color-cta-text: #FFFFFF;
  --color-cta-hover: #262626;
  --color-cta-arrow-bg: #FFFFFF;
  --color-cta-arrow-text: #111111;

  /* Redes sociales */
  --color-social-bg: rgba(0, 0, 0, 0.04);
  --color-social-border: rgba(0, 0, 0, 0.12);
  --color-social-hover-bg: #111111;
  --color-social-hover-border: #111111;
  --color-social-hover-color: #FFFFFF;

  /* Accesibilidad y foco */
  --color-focus: #111111;

  --font-family-base: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --ease-out-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

/* --------------------------------------------------------------------------
   3. Reset y base global
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  background-color: var(--color-bg);
  color: var(--color-text-primary);
  font-family: var(--font-family-base);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  min-height: 100vh;
  background-color: var(--color-bg);
  color: var(--color-text-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow-x: hidden;
}

.ambient-glow {
  display: none;
}

/* --------------------------------------------------------------------------
   4. Estructura y contenedores
   -------------------------------------------------------------------------- */
.page-container {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 16px 40px 16px;
  position: relative;
  z-index: 1;
}

.editorial-flow {
  width: 100%;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* --------------------------------------------------------------------------
   5. Logo de marca (V04 oficial en negro original)
   -------------------------------------------------------------------------- */
.brand-header {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  animation: motionLogo 650ms var(--ease-out-smooth) 100ms both;
}

.brand-logo {
  display: block;
  width: 100%;
  max-width: 240px;
  height: auto;
  aspect-ratio: 588 / 176;
  filter: none;
  transition: opacity 0.3s ease;
}

/* --------------------------------------------------------------------------
   6. Titular principal (Único H1)
   -------------------------------------------------------------------------- */
.headline {
  margin-top: 24px;
  font-family: var(--font-family-base);
  font-weight: 700;
  font-size: 30px;
  line-height: 38px;
  text-align: center;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
  animation: motionHeadline 750ms var(--ease-out-smooth) 320ms both;
}

.headline-phrase {
  display: block;
}

.headline-chunk {
  display: block;
}

.phrase-1 {
  color: var(--color-text-primary);
}

.phrase-2 {
  color: var(--color-text-accent);
}

/* --------------------------------------------------------------------------
   8. Descripción
   -------------------------------------------------------------------------- */
.description {
  margin-top: 18px;
  width: 100%;
  max-width: 100%;
  font-family: var(--font-family-base);
  font-weight: 400;
  font-size: 15px;
  line-height: 24px;
  color: var(--color-text-secondary);
  text-align: center;
  overflow-wrap: break-word;
  animation: motionFadeUp 600ms var(--ease-out-smooth) 440ms both;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.description p {
  margin: 0;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
  text-align: inherit;
}

.description strong {
  font-weight: 700;
  color: #111111;
}

/* --------------------------------------------------------------------------
   9. CTA en Móvil y Hero del Producto auténtico (VD-003B)
   -------------------------------------------------------------------------- */
.cta-container {
  margin-top: 20px;
  width: 100%;
  display: flex;
  justify-content: center;
}

.visual-container {
  margin-top: 22px;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: motionScaleIn 800ms var(--ease-out-smooth) 620ms both;
}

.hero-card {
  position: relative;
  width: 100%;
  max-width: 270px;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Presentación directa de la ilustración editorial sobre el fondo blanco */
.product-frame {
  position: relative;
  width: 100%;
  background: transparent;
  aspect-ratio: 1312 / 1199;
  display: flex;
  justify-content: center;
  align-items: center;
}

.product-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1312 / 1199;
  object-fit: contain;
  transition: transform 0.6s var(--ease-out-smooth);
}

.hero-card:hover .product-image {
  transform: scale(1.02);
}

/* --------------------------------------------------------------------------
   10. Grupo de acciones y enlaces
   -------------------------------------------------------------------------- */
.actions-group {
  margin-top: 24px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* CTA principal rediseñado: Cápsula negra con texto blanco y flecha SVG */
.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 280px;
  min-height: 52px;
  padding: 6px 8px 6px 24px;
  background-color: var(--color-cta-bg);
  color: var(--color-cta-text);
  font-family: var(--font-family-base);
  font-weight: 700;
  font-size: 16px;
  line-height: 24px;
  text-decoration: none;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.15);
  transition: 
    background-color 0.25s var(--ease-out-smooth),
    box-shadow 0.25s var(--ease-out-smooth),
    transform 0.15s ease;
  user-select: none;
  animation: motionFadeUp 550ms var(--ease-out-smooth) 540ms both;
}

.btn-cta .btn-text {
  flex-grow: 1;
  text-align: center;
  color: var(--color-cta-text);
}

.btn-cta .btn-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: var(--color-cta-arrow-bg);
  color: var(--color-cta-arrow-text);
  margin-left: 12px;
  flex-shrink: 0;
  transition: 
    transform 0.25s var(--ease-out-smooth),
    background-color 0.2s ease;
}

a.btn-cta:hover {
  background-color: var(--color-cta-hover);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
  transform: translateY(-1px);
}

a.btn-cta:hover .btn-arrow {
  transform: translateX(3px);
  background-color: #FAF6F2;
}

a.btn-cta:active {
  transform: scale(0.98);
}

/* Enlace secundario Instagram */
.link-instagram {
  margin-top: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 6px 14px;
  font-family: var(--font-family-base);
  font-weight: 500;
  font-size: 15px;
  line-height: 24px;
  color: var(--color-text-primary);
  text-decoration: underline;
  text-underline-offset: 4px;
  cursor: pointer;
  transition: color 0.2s ease, opacity 0.2s ease;
  animation: motionFadeUp 500ms var(--ease-out-smooth) 720ms both;
}

a.link-instagram:hover {
  opacity: 0.75;
}

/* Fila de redes sociales con 4 iconos SVG consistentes */
.social-row {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  animation: motionFadeUp 500ms var(--ease-out-smooth) 800ms both;
}

.link-social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-height: 44px;
  min-width: 44px;
  padding: 0;
  border-radius: 50%;
  background-color: var(--color-social-bg);
  border: 1px solid var(--color-social-border);
  color: var(--color-text-primary);
  text-decoration: none;
  cursor: pointer;
  transition: 
    background-color 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.2s var(--ease-out-smooth);
}

.link-social svg {
  display: block;
}

a.link-social:hover {
  background-color: var(--color-social-hover-bg);
  border-color: var(--color-social-hover-border);
  color: var(--color-social-hover-color);
  transform: translateY(-2px);
}

/* Utilidad para lectores de pantalla */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Enlace de ubicación / Maps (Tratamiento temporal: texto informativo limpio) */
.link-location {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 6px 12px;
  font-family: var(--font-family-base);
  font-weight: 400;
  font-size: 15px;
  line-height: 24px;
  color: var(--color-text-secondary);
  text-decoration: none;
  cursor: default;
  text-align: center;
  transition: color 0.2s ease;
  animation: motionFadeUp 500ms var(--ease-out-smooth) 880ms both;
}

.link-location .pin {
  margin-right: 6px;
  text-decoration: none;
  font-style: normal;
  display: inline-block;
}

.link-location .address-text {
  text-decoration: none;
}

a.link-location {
  cursor: pointer;
}

a.link-location:hover {
  color: var(--color-text-primary);
}

a.link-location:hover .address-text {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Elementos no configurados (vista previa local honesta) */
.is-unconfigured {
  cursor: default;
  opacity: 0.9;
}

/* --------------------------------------------------------------------------
   11. Firma no interactiva
   -------------------------------------------------------------------------- */
.page-footer {
  margin-top: 28px;
  padding-bottom: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  animation: motionFadeUp 600ms var(--ease-out-smooth) 960ms both;
}

.signature {
  font-family: var(--font-family-base);
  font-weight: 500;
  font-size: 13px;
  line-height: 22px;
  letter-spacing: 0.12em;
  color: var(--color-text-accent);
  text-align: center;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   12. Accesibilidad y Foco
   -------------------------------------------------------------------------- */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 4px;
}

/* --------------------------------------------------------------------------
   13. Animaciones y Motion Design
   -------------------------------------------------------------------------- */
@keyframes motionLogo {
  0% {
    opacity: 0;
    transform: translateY(-10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes motionHeadline {
  0% {
    opacity: 0;
    transform: translateY(12px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes motionFadeUp {
  0% {
    opacity: 0;
    transform: translateY(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes motionScaleIn {
  0% {
    opacity: 0;
    transform: scale(0.96) translateY(12px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* --------------------------------------------------------------------------
   14. Modo de movimiento reducido (prefers-reduced-motion)
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    animation-delay: 0ms !important;
  }
  .brand-header,
  .headline,
  .description,
  .cta-container,
  .visual-container,
  .product-image,
  .btn-cta,
  .btn-arrow,
  .link-instagram,
  .social-row,
  .link-social,
  .link-location,
  .page-footer {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
    transition: none !important;
  }
}

/* --------------------------------------------------------------------------
   15. Responsive Breakpoints
   -------------------------------------------------------------------------- */

/* Viewport 360px */
@media (min-width: 360px) {
  .page-container {
    padding: 32px 20px 44px 20px;
  }

  .brand-logo {
    max-width: 270px;
  }

  .headline {
    font-size: 34px;
    line-height: 42px;
  }

  .hero-card {
    max-width: 275px;
  }

  .btn-cta {
    max-width: 300px;
  }
}

/* Viewport 390px */
@media (min-width: 390px) {
  .page-container {
    padding: 36px 24px 48px 24px;
    max-width: 440px;
  }

  .brand-logo {
    max-width: 280px;
  }

  .headline {
    font-size: 36px;
    line-height: 44px;
  }

  .hero-card {
    max-width: 295px;
  }

  .btn-cta {
    max-width: 320px;
  }
}

/* Tablet (768px) */
@media (min-width: 768px) {
  .page-container {
    padding: 56px 36px 64px 36px;
    max-width: 680px;
  }

  .brand-logo {
    max-width: 330px;
  }

  .headline {
    margin-top: 28px;
    font-size: 44px;
    line-height: 52px;
  }

  .headline-chunk {
    display: inline;
  }

  .description {
    margin-top: 20px;
    max-width: 540px;
    font-size: 16px;
    line-height: 26px;
    gap: 18px;
  }

  .cta-container {
    margin-top: 24px;
  }

  .btn-cta {
    max-width: 320px;
  }

  .visual-container {
    margin-top: 32px;
  }

  .hero-card {
    max-width: 350px;
  }

  .actions-group {
    margin-top: 28px;
  }

  .social-row {
    gap: 16px;
    margin-top: 16px;
  }

  .link-location {
    margin-top: 20px;
    font-size: 16px;
  }

  .page-footer {
    margin-top: 36px;
  }
}

/* Desktop (1024px) - Composición editorial de 2 columnas */
@media (min-width: 1024px) {
  .page-container {
    padding: 64px 56px;
    max-width: 1240px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .editorial-flow {
    display: grid;
    grid-template-columns: 1.12fr 0.88fr;
    grid-template-rows: auto auto auto auto auto 1fr auto;
    grid-template-areas:
      "header visual"
      "headline visual"
      "desc visual"
      "cta visual"
      "actions visual"
      "spacer visual"
      "footer visual";
    column-gap: 56px;
    row-gap: 0;
    width: 100%;
    align-items: center;
  }

  .brand-header {
    grid-area: header;
    justify-content: flex-start;
  }

  .brand-logo {
    max-width: 340px;
  }

  .headline {
    grid-area: headline;
    text-align: left;
    margin-top: 32px;
    font-size: 50px;
    line-height: 60px;
  }

  .description {
    grid-area: desc;
    text-align: left;
    margin-top: 20px;
    max-width: 520px;
    font-size: 16.5px;
    line-height: 27px;
    gap: 20px;
  }

  .cta-container {
    grid-area: cta;
    justify-content: flex-start;
    margin-top: 24px;
  }

  .btn-cta {
    max-width: 290px;
  }

  .visual-container {
    grid-area: visual;
    margin-top: 0;
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .hero-card {
    max-width: 440px;
  }

  .actions-group {
    grid-area: actions;
    align-items: flex-start;
    margin-top: 14px;
  }

  .link-instagram {
    padding-left: 4px;
  }

  .social-row {
    justify-content: flex-start;
    gap: 14px;
    margin-top: 14px;
  }

  .link-location {
    padding-left: 2px;
    margin-top: 18px;
  }

  .page-footer {
    grid-area: footer;
    justify-content: flex-start;
    margin-top: 36px;
  }

  .signature {
    text-align: left;
  }
}

/* Desktop (1440px y superiores) */
@media (min-width: 1440px) {
  .page-container {
    padding: 72px 64px;
    max-width: 1360px;
  }

  .editorial-flow {
    column-gap: 72px;
  }

  .brand-logo {
    max-width: 360px;
  }

  .headline {
    margin-top: 36px;
    font-size: 56px;
    line-height: 68px;
  }

  .description {
    margin-top: 24px;
    max-width: 540px;
    font-size: 17.5px;
    line-height: 28px;
    gap: 20px;
  }

  .cta-container {
    margin-top: 18px;
  }

  .hero-card {
    max-width: 480px;
  }

  .actions-group {
    margin-top: 12px;
  }

  .social-row {
    margin-top: 10px;
  }

  .link-location {
    margin-top: 24px;
  }

  .page-footer {
    margin-top: 42px;
  }
}

/* Desktop (1920px y superiores) */
@media (min-width: 1920px) {
  .page-container {
    padding: 88px 80px;
    max-width: 1440px;
  }

  .editorial-flow {
    column-gap: 88px;
  }

  .hero-card {
    max-width: 515px;
  }
}
