/**
 * JYM GROUP — Hoja de estilos principal
 * -----------------------------------------------------------------
 * Convenciones:
 *  - Diseño mobile-first invertido: reglas base pensadas para
 *    desktop, con overrides en @media (max-width) para tablet (860px)
 *    y mobile (520px), siguiendo el layout ya definido en el sitio.
 *  - Paleta y escalas centralizadas en :root para no repetir valores.
 *  - BEM-lite: nombres de clase por componente (.carousel, .plan,
 *    .testi, etc.), sin anidar más de un nivel de especificidad.
 * -----------------------------------------------------------------
 */

:root {
  --graphite: #1b1e1c;
  --graphite-soft: #3a3f3c;
  --concrete: #eae7e1;
  --paper: #f7f5f0;
  --teal: #2b6e62;
  --teal-dark: #204f47;
  --orange: #ff5a1f;
  --line: rgba(27, 30, 28, 0.14);
  --line-soft: rgba(27, 30, 28, 0.08);
  --radius: 2px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  scroll-padding-top: 88px;
}

body {
  font-family: 'IBM Plex Sans', sans-serif;
  background: var(--paper);
  color: var(--graphite);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100vw;
  padding-top: 74px; /* alto real del header fijo, ver .nav */
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.mono {
  font-family: 'IBM Plex Mono', monospace;
}

.display {
  font-family: 'Space Grotesk', sans-serif;
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 28px;
}

.eyebrow {
  font-family: 'IBM Plex Mono', monospace;
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--teal-dark);
  display: flex;
  align-items: center;
  gap: 10px;
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--orange);
  display: inline-block;
}

section {
  padding: 96px 0;
  border-bottom: 1px solid var(--line-soft);
}

h1, h2, h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  letter-spacing: -.01em;
}

h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  margin-bottom: 14px;
}

.section-head {
  max-width: 640px;
  margin-bottom: 56px;
}

.section-head p {
  color: var(--graphite-soft);
  font-size: 1.02rem;
  margin-top: 10px;
}

/* focus visibility */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
}

/* HEADER */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(247, 245, 240, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line-soft);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 28px;
  max-width: 1180px;
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Space Grotesk';
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: .01em;
}

.brand .dot {
  width: 9px;
  height: 9px;
  background: var(--orange);
  border-radius: 50%;
  display: inline-block;
}

.brand .logo-img {
  height: 34px;
  width: 34px;
  object-fit: contain;
  display: inline-block;
}

.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
  font-size: .92rem;
}

.nav-links a {
  color: var(--graphite-soft);
  transition: color .15s;
}

.nav-links a:hover {
  color: var(--graphite);
}

.nav-cta {
  background: var(--orange);
  color: var(--paper) !important;
  padding: 10px 18px;
  font-size: .85rem;
  font-family: 'IBM Plex Mono';
  border: 1px solid var(--orange);
  transition: all .15s;
}

.nav-cta:hover {
  background: var(--graphite);
  border-color: var(--graphite);
  color: var(--paper) !important;
}

.nav-cta-dark {
  background: var(--graphite);
  color: var(--paper) !important;
  padding: 10px 18px;
  font-size: .85rem;
  font-family: 'IBM Plex Mono';
  border: 1px solid var(--graphite);
  transition: all .15s;
}

.nav-cta-dark:hover {
  background: transparent;
  color: var(--graphite) !important;
}

.burger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

.burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--graphite);
  margin: 5px 0;
}

/* HERO */
.hero {
  padding: 72px 0 90px;
  border-bottom: 1px solid var(--line-soft);
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 56px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1.06;
  margin: 18px 0 22px;
}

.layer-line {
  display: block;
  overflow: hidden;
}

.layer-line span {
  display: inline-block;
  transform: translateY(110%);
  animation: layerUp .6s cubic-bezier(.2, .8, .2, 1) forwards;
}

@keyframes layerUp {
  to { transform: translateY(0); }
}

.hero-copy {
  position: relative;
  isolation: isolate;
}

.hero-copy::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -60px;
  width: 420px;
  height: 420px;
  background-image: url('assets/logo.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: .15;
  z-index: -1;
  pointer-events: none;
}

@media (max-width: 860px) {
  .hero-copy::before {
    width: 280px;
    height: 280px;
    right: -30px;
    top: -20px;
  }
}

.hero p.lead {
  font-size: 1.08rem;
  color: var(--graphite-soft);
  max-width: 480px;
  margin-bottom: 32px;
}

.cta-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.btn {
  font-family: 'IBM Plex Mono', monospace;
  font-size: .85rem;
  padding: 14px 22px;
  border: 1px solid var(--graphite);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all .15s;
}

/* ==========================================================================
   EFECTO "GOTA DE TINTA" CENTRADO - EXCLUSIVO PARA BOTONES EN .cta-row
   ========================================================================== */

.cta-row .btn {
  position: relative;
  overflow: hidden;
  isolation: isolate; /* Contiene la gota (z-index: -1) dentro del botón */
}

/* Pseudo-elemento centrado horizontal y verticalmente */
.cta-row .btn::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0);
  z-index: -1;
  opacity: 0;
  pointer-events: none;
}

/* La animación sólo se ejecuta mientras NO está en hover */
.cta-row .btn:not(:hover)::before {
  animation: centerInkDrop 2.8s cubic-bezier(.45, 0, .4, 1) infinite;
}

@keyframes centerInkDrop {
  0%   { transform: translate(-50%, -50%) scale(0);   opacity: 1; }
  12%  { transform: translate(-50%, -50%) scale(1.4); opacity: 1; }
  34%  { transform: translate(-50%, -50%) scale(9);   opacity: 1; }
  46%  { transform: translate(-50%, -50%) scale(16);  opacity: 1; }
  75%  { transform: translate(-50%, -50%) scale(16);  opacity: 1; }
  92%  { transform: translate(-50%, -50%) scale(16);  opacity: 0; }
  100% { transform: translate(-50%, -50%) scale(0);   opacity: 0; }
}

/* Configuración de colores para Botón Primario en .cta-row */
.cta-row .btn.btn-primary {
  background: #ff8a5c;
  border-color: #ff8a5c;
  color: var(--paper);
}

.cta-row .btn.btn-primary::before {
  background: var(--orange);
  animation-delay: 0s;
}

.cta-row .btn.btn-primary:hover {
  background: var(--graphite);
  border-color: var(--graphite);
  color: var(--paper);
}

/* Configuración de colores y texto para Botón Outline en .cta-row */
.cta-row .btn.btn-outline:not(:hover) {
  animation: inkTextFlip 2.8s cubic-bezier(.45, 0, .4, 1) infinite;
  animation-delay: .9s;
}

.cta-row .btn.btn-outline::before {
  background: var(--graphite);
  animation-delay: .9s;
}

.cta-row .btn.btn-outline:hover {
  background: var(--graphite);
  border-color: var(--graphite);
  color: var(--paper);
  animation: none;
}

@keyframes inkTextFlip {
  0%   { color: var(--graphite); }
  30%  { color: var(--graphite); }
  40%  { color: var(--paper); }
  80%  { color: var(--paper); }
  90%  { color: var(--graphite); }
  100% { color: var(--graphite); }
}

/* Estilos de botones generales fuera de .cta-row */
.btn-primary {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--paper);
}

.btn-primary-contact {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--paper);
}

.btn-primary:hover {
  background: var(--graphite);
  border-color: var(--graphite);
}

.btn-primary-contact:hover {
  background: var(--graphite);
  border-color: var(--graphite);
  filter: invert(100%);
}

.btn-outline {
  background: transparent;
  color: var(--graphite);
}

.btn-outline:hover {
  background: var(--graphite);
  color: var(--paper);
}

.hero-visual { position: relative; }

.hero-visual .frame {
  border: 1px solid var(--line);
  background: var(--concrete);
  position: relative;
  aspect-ratio: 4/5;
  overflow: hidden;
}

.hero-visual img { width: 100%; height: 100%; object-fit: cover; }

.ruler {
  position: absolute; left: -26px; top: 0; bottom: 0; width: 20px;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 6px 0;
}

.ruler span { width: 12px; height: 1px; background: var(--graphite-soft); opacity: .5; }

.ruler-label {
  position: absolute; left: -58px; top: 50%; transform: translateY(-50%) rotate(-90deg);
  font-family: 'IBM Plex Mono'; font-size: .62rem; letter-spacing: .1em; color: var(--graphite-soft);
  white-space: nowrap;
}

.tag-float {
  position: absolute; bottom: 14px; left: 14px; background: var(--paper);
  border: 1px solid var(--line); padding: 8px 12px;
  font-family: 'IBM Plex Mono'; font-size: .72rem;
  z-index: 6;
}

/* HERO CAROUSEL */
.carousel { position: absolute; inset: 0; }
.carousel-track { position: relative; width: 100%; height: 100%; }

.carousel-slide {
  position: absolute; inset: 0; opacity: 0; pointer-events: none;
  transition: opacity .7s ease;
}

.carousel-slide.active { opacity: 1; pointer-events: auto; }
.carousel-slide img { width: 100%; height: 100%; object-fit: cover; }

.carousel-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px; border: none; cursor: pointer;
  background: rgba(27, 30, 28, .5); color: var(--paper);
  font-family: 'IBM Plex Mono'; font-size: 1.1rem;
  display: flex; align-items: center; justify-content: center;
  z-index: 6; transition: background .15s;
}

.carousel-arrow:hover { background: var(--orange); }
.carousel-arrow.prev { left: 10px; }
.carousel-arrow.next { right: 10px; }

.carousel-dots {
  position: absolute; bottom: 14px; right: 14px; z-index: 6;
  display: flex; gap: 7px;
}

.carousel-dot {
  width: 8px; height: 8px; padding: 0; border-radius: 50%;
  border: 1px solid var(--paper); background: transparent; cursor: pointer;
}

.carousel-dot.active { background: var(--orange); border-color: var(--orange); }
.carousel-hidden { display: none; }

/* CAPABILITIES */
.cap-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.cap-card { background: var(--paper); padding: 34px 28px; }
.cap-card .idx { font-family: 'IBM Plex Mono'; font-size: .75rem; color: var(--orange); margin-bottom: 16px; display: block; }
.cap-card h3 { font-size: 1.15rem; margin-bottom: 10px; }
.cap-card p { color: var(--graphite-soft); font-size: .94rem; }

.gallery-block { margin-top: 64px; }
.gallery-block .section-head { margin-bottom: 28px; }
.gallery-block h3 { font-size: 1.3rem; }
.about-visual .frame {
  border: 1px solid var(--line); background: var(--concrete);
  position: relative; width: 100%; aspect-ratio: 16/8; overflow: hidden;
}

/* SERVICES */
.services { background: var(--graphite); color: var(--paper); }
.services .section-head p { color: rgba(247, 245, 240, .65); }
.services .eyebrow { color: #ffb08f; }
.plan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: rgba(247, 245, 240, .16); }
.plan { background: var(--graphite); padding: 40px; }
.plan.featured { background: #232722; }
.plan-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.plan h3 { font-size: 1.4rem; }
.plan .price { font-family: 'IBM Plex Mono'; color: var(--orange); font-size: .95rem; }
.plan p.desc { color: rgba(247, 245, 240, .7); font-size: .94rem; margin: 18px 0 26px; }
.plan .btn { border-color: rgba(247, 245, 240, .4); color: var(--paper); }
.plan .btn:hover { background: var(--paper); color: var(--graphite); }

/* PROCESS */
.process-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.step { border-top: 2px solid var(--graphite); padding-top: 16px; }
.step .num { font-family: 'IBM Plex Mono'; font-size: .8rem; color: var(--teal-dark); }
.step h3 { font-size: 1.02rem; margin: 10px 0 8px; }
.step p { font-size: .9rem; color: var(--graphite-soft); }

/* TESTIMONIALS */
.testi-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.testi { border: 1px solid var(--line); padding: 28px; background: var(--concrete); }
.testi p.quote { font-size: .98rem; margin-bottom: 18px; }
.testi .who { font-family: 'IBM Plex Mono'; font-size: .78rem; color: var(--teal-dark); }

/* COTIZADOR */
.quote-wrap { display: grid; grid-template-columns: .85fr 1.15fr; gap: 56px; }
.ticket-note {
  font-family: 'IBM Plex Mono'; font-size: .82rem; color: var(--graphite-soft);
  border-left: 2px solid var(--orange); padding-left: 16px; margin-top: 24px;
}
form { border: 1px solid var(--line); padding: 32px; background: var(--paper); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.field label { font-family: 'IBM Plex Mono'; font-size: .72rem; letter-spacing: .05em; text-transform: uppercase; color: var(--graphite-soft); }
.field input, .field select, .field textarea {
  font-family: 'IBM Plex Sans'; font-size: .95rem; width: 100%; max-width: 100%;
  padding: 11px 12px; border: 1px solid var(--line); background: var(--paper); color: var(--graphite);
}
.field textarea { resize: vertical; min-height: 90px; }
.field.invalid input { border-color: #c62828; }
.field-error {
  display: none; font-family: 'IBM Plex Mono'; font-size: .76rem;
  color: #c62828;
}
.submit-row { display: flex; align-items: center; gap: 16px; margin-top: 8px; flex-wrap: wrap; }
.submit-row button {
  font-family: 'IBM Plex Mono'; font-size: .88rem;
  background: var(--orange); color: var(--paper); border: 1px solid var(--orange);
  padding: 14px 24px; cursor: pointer; transition: all .15s;
}
.submit-row button:hover { background: var(--graphite); border-color: var(--graphite); }
.form-status { font-family: 'IBM Plex Mono'; font-size: .8rem; color: var(--teal-dark); display: none; }
.form-status.show { display: block; }

/* ABOUT */
.about-grid { display: grid; grid-template-columns: 1fr; max-width: 760px; }
.about-grid p { color: var(--graphite-soft); margin-bottom: 16px; }
.stat-row { display: flex; gap: 36px; margin-top: 28px; }
.stat .num { font-family: 'Space Grotesk'; font-size: 1.8rem; font-weight: 700; }
.stat .lbl { font-family: 'IBM Plex Mono'; font-size: .7rem; color: var(--graphite-soft); text-transform: uppercase; letter-spacing: .06em; }

/* CONTAIN CAROUSEL */
.carousel-slide.contain img { object-fit: contain; background: var(--concrete); }

/* DESTACADOS */
.product-frame {
  border: 1px solid var(--line); background: var(--paper);
  position: relative; width: 100%; max-width: 420px; margin: 0 auto;
  aspect-ratio: 3/4; overflow: hidden;
}
.product-frame .carousel-slide { display: flex; flex-direction: column; background: var(--paper); }
.product-frame .carousel-slide img { flex: 1; min-height: 0; width: 100%; object-fit: contain; background: var(--concrete); }
.prod-info { padding: 18px 20px; border-top: 1px solid var(--line); }
.prod-category-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-bottom: 10px;
}
.prod-category {
  font-family: 'IBM Plex Mono'; font-size: .7rem;
  text-transform: uppercase; letter-spacing: .05em; color: var(--teal-dark);
}
.prod-category-link {
  font-family: 'IBM Plex Mono'; font-size: .72rem; color: var(--paper);
  background: var(--teal); padding: 5px 12px; white-space: nowrap;
  transition: background .15s;
}
.prod-category-link:hover { background: var(--teal-dark); }
.prod-price { font-family: 'IBM Plex Mono'; font-size: .85rem; color: var(--orange); display: block; margin-bottom: 4px; }
.prod-title { font-size: .98rem; margin-bottom: 12px; line-height: 1.3; }
.prod-link {
  font-family: 'IBM Plex Mono'; font-size: .78rem; color: var(--graphite);
  display: inline-flex; align-items: center; gap: 6px; border-bottom: 1px solid var(--graphite);
}
.destacados-foot { text-align: center; margin-top: 28px; }

/* FOOTER SOCIAL */
.foot-social { display: flex; gap: 16px; align-items: center; }
.foot-social a {
  width: 30px; height: 30px; border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  transition: border-color .15s, background .15s;
}
.foot-social a:hover { background: var(--graphite); border-color: var(--graphite); }
.foot-social img { width: 16px; height: 16px; object-fit: contain; }

/* CONTACT */
.contact { background: var(--concrete); border-bottom: none; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }
.contact-info dl { display: grid; grid-template-columns: auto 1fr; gap: 12px 20px; }
.contact-info dt { font-family: 'IBM Plex Mono'; font-size: .75rem; color: var(--graphite-soft); text-transform: uppercase; letter-spacing: .04em; padding-top: 2px; }
.contact-info dd { font-size: 1rem; }
.wa-btns { display: flex; flex-direction: column; gap: 10px; margin-top: 24px; }
.wa-btn {
  border: 1px solid var(--graphite); padding: 14px 18px;
  display: flex; justify-content: space-between; align-items: center;
  font-family: 'IBM Plex Mono'; font-size: .9rem; background: var(--paper);
  transition: all .15s;
}
.wa-btn:hover {
  background: var(--graphite);
  color: var(--paper);
}
.wa-btn:hover img {
  filter: invert(100%);
}

.shop-card {
  background: var(--graphite); color: var(--paper); padding: 40px;
  display: flex; flex-direction: column; justify-content: space-between;
}
.shop-card h3 { font-size: 1.5rem; margin-bottom: 12px; }
.shop-card p { color: rgba(247, 245, 240, .7); margin-bottom: 28px; }
.shop-card .btn { align-self: flex-start; }

footer { padding: 32px 0; }
.foot-row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.foot-row p { font-family: 'IBM Plex Mono'; font-size: .76rem; color: var(--graphite-soft); }

.mnav {
  display: none;
  flex-direction: column;
  gap: 2px;
  padding: 0 28px 18px;
}
.mnav.show { display: flex; }
.mnav a {
  padding: 10px 0;
  border-top: 1px solid var(--line-soft);
}
.mnav a.mnav-cta { color: var(--orange); }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .burger { display: block; }
  .hero-grid, .about-grid, .quote-wrap, .contact-grid { grid-template-columns: 1fr; }
  .cap-grid { grid-template-columns: 1fr; }
  .plan-grid { grid-template-columns: 1fr; }
  .process-list { grid-template-columns: 1fr 1fr; }
  .testi-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .ruler, .ruler-label { display: none; }
  section { padding: 64px 0; }
}

@media (max-width: 520px) {
  .process-list { grid-template-columns: 1fr; }
  #cotizador .wrap > div:first-child { text-align: center; }
  #cotizador .wrap > div:first-child .eyebrow,
  #cotizador .wrap > div:first-child h2,
  #cotizador .wrap > div:first-child p { margin-left: auto; margin-right: auto; }
  form { padding: 22px 18px; }
  #cotizador .wrap { padding: 0 18px; }
  .submit-row { flex-direction: column; align-items: stretch; text-align: center; }
  .submit-row button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .layer-line span { animation: none; transform: none; }
  .cta-row .btn:not(:hover)::before { animation: none; }
  .cta-row .btn.btn-outline:not(:hover) { animation: none; }
}

/* WHATSAPP FLOTANTE */
.wa-float {
  position: fixed; right: 24px; bottom: 24px; z-index: 60;
  display: flex; flex-direction: column; align-items: flex-end; gap: 12px;
  transition: opacity .2s ease, transform .2s ease;
}
.wa-float-hidden { opacity: 0; transform: translateY(12px); pointer-events: none; }
.wa-float-btn {
  width: 58px; height: 58px; border-radius: 50%; border: none; cursor: pointer;
  background: var(--graphite); box-shadow: 0 6px 18px rgba(27, 30, 28, .28);
  display: flex; align-items: center; justify-content: center;
  transition: transform .15s ease, background .15s ease;
}
.wa-float-btn:hover { transform: scale(1.06); background: var(--orange); }
.wa-float-btn img { width: 30px; height: 30px; object-fit: contain; filter: invert(1); }
.wa-float-menu {
  display: none; flex-direction: column; gap: 8px;
  background: var(--paper); border: 1px solid var(--line);
  padding: 10px; box-shadow: 0 8px 22px rgba(27, 30, 28, .16);
}
.wa-float-menu.show { display: flex; }
.wa-float-option {
  font-family: 'IBM Plex Mono'; font-size: .85rem; text-align: left;
  background: none; border: none; cursor: pointer; padding: 10px 14px;
  color: var(--graphite); white-space: nowrap; transition: background .15s;
}
.wa-float-option:hover { background: var(--concrete); }

@media (max-width: 520px) {
  .wa-float { right: 16px; bottom: 16px; }
  .wa-float-btn { width: 52px; height: 52px; }
}