/* ==========================================================================
   GRUPO PYA — Hoja de estilos principal
   Holding empresarial · Deporte · Salud · Infraestructura · Tecnología
   Identidad visual: negro · blanco · dorado
   ========================================================================== */

/* ---------- 1. Variables de diseño ---------- */
:root {
  /* Base (negro profundo) */
  --bg: #050505;            /* fondo principal */
  --bg-2: #0d0d0d;          /* negro secundario (tarjetas / bloques) */
  --bg-soft: #0d0d0d;       /* alias de bloques secundarios */

  --dark: #050505;
  --dark-2: #0d0d0d;
  --dark-line: rgba(255, 255, 255, 0.08);

  /* Texto */
  --white: #ffffff;         /* títulos / máxima jerarquía */
  --white-soft: #d8d8d8;    /* párrafos / descripciones */
  --muted: #8f8f8f;         /* etiquetas terciarias */

  --ink: #d8d8d8;           /* texto por defecto */
  --ink-strong: #ffffff;
  --ink-soft: #d8d8d8;
  --ink-on-dark: #ffffff;
  --muted-on-dark: #d8d8d8;

  /* Bordes */
  --line: rgba(255, 255, 255, 0.10);
  --line-gold: rgba(201, 162, 39, 0.45);

  /* Dorado */
  --gold: #c9a227;
  --gold-light: #e2c766;
  --accent: #c9a227;        /* dorado principal */
  --accent-2: #e2c766;      /* dorado claro */
  --accent-soft: rgba(201, 162, 39, 0.14);

  --font-display: "Sora", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;

  --max-w: 1200px;
  --radius: 18px;
  --radius-sm: 12px;
  --header-h: 78px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.45);
  --shadow-md: 0 24px 50px -22px rgba(0, 0, 0, 0.75);
  --shadow-lg: 0 40px 80px -30px rgba(0, 0, 0, 0.85);
}

/* ---------- 2. Reset y base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.no-scroll { overflow: hidden; }

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

::selection { background: var(--gold); color: #050505; }

/* ---------- 3. Utilidades ---------- */
.container { width: 100%; max-width: var(--max-w); margin-inline: auto; padding-inline: 24px; }

.section { padding: 120px 0; }
.section--dark { background: var(--dark); color: var(--white-soft); }
.section--soft { background: var(--dark-2); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow::before { content: ""; width: 24px; height: 1px; background: var(--gold); }

.h2 {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4.4vw, 3rem);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: var(--white);
}

.section__head { max-width: 760px; margin-bottom: 64px; }
.section__head--center { margin-inline: auto; text-align: center; }
.section__head--center .eyebrow::after { content: ""; width: 24px; height: 1px; background: var(--gold); }

.section__sub { margin-top: 18px; font-size: 1.1rem; color: var(--white-soft); }

/* ---------- 4. Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 30px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease),
              background-color 0.35s var(--ease), color 0.35s var(--ease),
              border-color 0.35s var(--ease);
  white-space: nowrap;
}

.btn--primary {
  background: var(--gold);
  color: #050505;
  box-shadow: 0 14px 34px -14px rgba(201, 162, 39, 0.55);
}
.btn--primary:hover { background: var(--gold-light); transform: translateY(-2px); box-shadow: 0 18px 40px -14px rgba(201, 162, 39, 0.65); }

.btn--ghost { color: var(--white); border: 1px solid var(--gold); }
.btn--ghost:hover { background: var(--gold); color: #050505; border-color: var(--gold); transform: translateY(-2px); }

.btn--outline { color: var(--white); border: 1px solid var(--line); }
.btn--outline:hover { border-color: var(--gold); color: var(--gold); }

/* ---------- 5. Header / Navegación ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.4s var(--ease);
}
.site-header.is-scrolled {
  background: rgba(5, 5, 5, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--dark-line);
}

.header__inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand { display: inline-flex; align-items: center; }
.brand__logo { height: 42px; width: auto; object-fit: contain; }

.nav__list { display: flex; align-items: center; gap: 34px; }

.nav__link {
  position: relative;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--white-soft);
  opacity: 0.85;
  transition: opacity 0.3s var(--ease), color 0.3s var(--ease);
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 100%; height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}
.nav__link:hover, .nav__link.is-active { opacity: 1; color: var(--white); }
.nav__link:hover::after, .nav__link.is-active::after { transform: scaleX(1); }

.header__cta { padding: 11px 22px; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 44px; height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
}
.nav-toggle span {
  display: block;
  width: 20px; height: 1.6px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.35s var(--ease), opacity 0.35s var(--ease);
}
.nav-toggle.is-open span:nth-child(1) { transform: translateY(6.6px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-6.6px) rotate(-45deg); }

/* ---------- 6. Hero / Portada ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--dark);
  color: var(--white-soft);
  overflow: hidden;
  padding: calc(var(--header-h) + 60px) 0 90px;
}

.hero__bg { position: absolute; inset: 0; pointer-events: none; }

/* Rejilla sutil de fondo */
.hero__bg::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 30%, transparent 72%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 30%, transparent 72%);
}

/* Resplandor dorado muy suave */
.hero__bg::after {
  content: "";
  position: absolute;
  width: 640px; height: 640px;
  left: 50%; top: 44%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(201, 162, 39, 0.13) 0%, rgba(226, 199, 102, 0.04) 42%, transparent 70%);
  filter: blur(12px);
}

.hero__inner { position: relative; z-index: 2; }
.hero__content { max-width: 860px; margin-inline: auto; text-align: center; }

.hero__logo { height: 84px; width: auto; object-fit: contain; margin: 0 auto 36px; }

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5.6vw, 4.1rem);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.025em;
  color: var(--white);
  max-width: 18ch;
  margin-inline: auto;
}

.hero__tagline {
  margin-top: 26px;
  font-family: var(--font-display);
  font-size: clamp(1rem, 2vw, 1.3rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--gold);
}

.hero__intro {
  margin-top: 26px;
  max-width: 60ch;
  margin-inline: auto;
  font-size: 1.06rem;
  line-height: 1.75;
  color: var(--white-soft);
}

.hero__actions { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 44px; justify-content: center; }

.hero__scroll {
  position: absolute;
  left: 50%; bottom: 28px;
  transform: translateX(-50%);
  width: 26px; height: 42px;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
  transition: border-color 0.3s var(--ease);
}
.hero__scroll:hover { border-color: var(--gold); }
.hero__scroll-line {
  width: 2px; height: 10px;
  background: var(--gold);
  border-radius: 2px;
  animation: scrollHint 1.8s ease-in-out infinite;
}
@keyframes scrollHint {
  0% { transform: translateY(0); opacity: 0; }
  30% { opacity: 1; }
  100% { transform: translateY(14px); opacity: 0; }
}

/* Entrada del contenido del hero */
.hero__content > * { opacity: 0; transform: translateY(20px); animation: heroUp 0.9s var(--ease) forwards; }
.hero__content > *:nth-child(1) { animation-delay: 0.05s; }
.hero__content > *:nth-child(2) { animation-delay: 0.15s; }
.hero__content > *:nth-child(3) { animation-delay: 0.25s; }
.hero__content > *:nth-child(4) { animation-delay: 0.35s; }
.hero__content > *:nth-child(5) { animation-delay: 0.45s; }
@keyframes heroUp { to { opacity: 1; transform: none; } }

/* ---------- 7. Quiénes Somos ---------- */
.about__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 72px;
  align-items: center;
}

.about__text p { margin-bottom: 20px; color: var(--white-soft); font-size: 1.06rem; }
.about__text p:last-child { margin-bottom: 0; }
.about__lead { font-size: 1.28rem !important; color: var(--white) !important; font-weight: 500; line-height: 1.5; }

.about__visual { display: flex; justify-content: center; }
.about__visual svg { width: 100%; max-width: 470px; height: auto; }

/* ---------- 8. Nuestras Marcas ---------- */
.brands-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.brand-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--dark-2);
  border: 1px solid var(--dark-line);
  border-radius: var(--radius);
  padding: 34px 26px 30px;
  overflow: hidden;
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease), border-color 0.45s var(--ease);
}
.brand-card::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease);
}
.brand-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-md); border-color: var(--line-gold); }
.brand-card:hover::after { transform: scaleX(1); }

/* Zona de logo: panel limpio y claro con altura fija */
.brand-card__logo {
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white-soft);
  border-radius: var(--radius-sm);
  padding: 18px;
  margin-bottom: 26px;
}
.brand-card__logo img {
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
}

.brand-card__name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--white);
}

.brand-card__desc {
  margin-top: 12px;
  font-size: 0.8rem;
  line-height: 1.7;
  color: var(--white-soft);
  flex: 1;
}

.brand-card__link {
  margin-top: 28px;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--white);
  border: 1px solid var(--line-gold);
  border-radius: 999px;
  transition: background-color 0.35s var(--ease), color 0.35s var(--ease),
              border-color 0.35s var(--ease), transform 0.35s var(--ease);
}
.brand-card__link svg { transition: transform 0.3s var(--ease); }
.brand-card__link:hover { background: var(--gold); color: #050505; border-color: var(--gold); }
.brand-card__link:hover svg { transform: translateX(3px); }

/* ---------- 9. Nuestra Visión ---------- */
.vision__inner { max-width: 920px; }

.vision__phrase {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.9rem);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: var(--white);
  margin-bottom: 26px;
}
.vision__phrase span { color: var(--gold); }

.vision__text { color: var(--white-soft); font-size: 1.06rem; line-height: 1.8; max-width: 72ch; }

/* Flujo: Deporte → Infraestructura → Tecnología → Salud */
.flow {
  display: flex;
  align-items: stretch;
  gap: 18px;
  margin-top: 64px;
}
.flow__item {
  flex: 1;
  background: var(--dark-2);
  border: 1px solid var(--dark-line);
  border-radius: var(--radius-sm);
  padding: 28px 20px;
  text-align: center;
  transition: border-color 0.35s var(--ease), background-color 0.35s var(--ease), transform 0.35s var(--ease);
}
.flow__item:hover { border-color: var(--line-gold); transform: translateY(-4px); }

.flow__index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--gold);
  border: 1px solid var(--line-gold);
  margin-bottom: 14px;
}
.flow__label { font-family: var(--font-display); font-size: 1.05rem; font-weight: 600; letter-spacing: 0.02em; color: var(--white); }
.flow__sub { margin-top: 6px; font-size: 0.78rem; color: var(--white-soft); letter-spacing: 0.04em; }

.flow__arrow {
  align-self: center;
  flex: 0 0 auto;
  color: var(--gold);
  opacity: 0.7;
}

/* ---------- 10. Ecosistema ---------- */
.ecosystem { background: var(--dark-2); }
.ecosystem--alt { border-top: 1px solid var(--dark-line); }

.ecosystem__wrap {
  position: relative;
  margin-top: 30px;
  min-height: 540px;
}
.ecosystem__lines {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}
.ecosystem__lines line {
  stroke: var(--gold);
  stroke-opacity: 0.35;
  stroke-width: 1.5;
  stroke-dasharray: 5 6;
}

.ecosystem__core {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: 190px; height: 190px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: radial-gradient(circle at 30% 25%, #1a1a1a, #050505);
  border: 1px solid var(--dark-line);
  box-shadow: 0 24px 60px -24px rgba(201, 162, 39, 0.35), var(--shadow-lg);
  z-index: 2;
}
.ecosystem__core img { height: 46px; width: auto; object-fit: contain; }

.ecosystem__brand {
  position: absolute;
  background: #050505;
  border: 1px solid var(--dark-line);
  border-radius: var(--radius-sm);
  padding: 18px 24px;
  text-align: center;
  min-width: 176px;
  transition: border-color 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.ecosystem__brand strong {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--white);
}
.ecosystem__brand:hover { border-color: var(--line-gold); box-shadow: 0 18px 40px -20px rgba(201, 162, 39, 0.3); }

/* Posiciones (escritorio) */
.ecosystem__brand--top    { left: 50%; top: 0;   transform: translateX(-50%); }
.ecosystem__brand--right  { right: 2%; top: 50%; transform: translateY(-50%); }
.ecosystem__brand--bottom { left: 50%; bottom: 0; transform: translateX(-50%); }
.ecosystem__brand--left   { left: 2%;  top: 50%; transform: translateY(-50%); }

/* ---------- 11. Contacto ---------- */
.contact__cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 20px;
}
.contact__item {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 24px;
  border: 1px solid var(--dark-line);
  border-radius: var(--radius-sm);
  background: var(--dark-2);
  transition: border-color 0.35s var(--ease), box-shadow 0.35s var(--ease), transform 0.35s var(--ease);
}
.contact__item:hover { border-color: var(--line-gold); box-shadow: var(--shadow-sm); transform: translateY(-3px); }

.contact__icon {
  flex: 0 0 auto;
  width: 48px; height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--gold);
}
.contact__icon svg { width: 22px; height: 22px; }

.contact__label { font-size: 0.76rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.contact__value { margin-top: 3px; font-size: 1.02rem; font-weight: 500; color: var(--white); }
a.contact__value:hover { color: var(--gold); }

.contact__social {
  margin-top: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}
.contact__social-label { font-size: 0.9rem; color: var(--white-soft); }
.social-btn {
  width: 46px; height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--dark-line);
  color: var(--white-soft);
  transition: background-color 0.35s var(--ease), border-color 0.35s var(--ease),
              color 0.35s var(--ease), transform 0.35s var(--ease);
}
.social-btn svg { width: 20px; height: 20px; }
.social-btn:hover { background: var(--gold); border-color: var(--gold); color: #050505; transform: translateY(-3px); }

/* ---------- 12. Footer ---------- */
.footer {
  background: #050505;
  color: var(--white-soft);
  padding: 72px 0 40px;
  border-top: 1px solid var(--dark-line);
}
.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
}
.footer__logo { height: 48px; width: auto; object-fit: contain; }
.footer__tagline { letter-spacing: 0.16em; font-size: 0.9rem; }

.footer__bar {
  width: 100%;
  margin-top: 30px;
  padding-top: 26px;
  border-top: 1px solid var(--dark-line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  color: var(--muted);
}

/* ---------- 13. Animaciones de aparición ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  will-change: opacity, transform;
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }

[data-reveal-delay="1"] { transition-delay: 0.1s; }
[data-reveal-delay="2"] { transition-delay: 0.2s; }
[data-reveal-delay="3"] { transition-delay: 0.3s; }
[data-reveal-delay="4"] { transition-delay: 0.4s; }

/* Accesibilidad */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  .hero__content > * { animation: none; opacity: 1; transform: none; }
  .hero__scroll-line { animation: none; }
}

/* ---------- 14. Responsive ---------- */

/* Tablet */
@media (max-width: 1024px) {
  .section { padding: 90px 0; }
  .about__grid { grid-template-columns: 1fr; gap: 48px; }
  .about__visual { order: -1; }
  .brands-grid { grid-template-columns: repeat(2, 1fr); }
  .contact__cards { grid-template-columns: 1fr 1fr; }
}

/* Móvil */
@media (max-width: 760px) {
  .section { padding: 72px 0; }

  .nav {
    position: fixed;
    inset: 0;
    background: rgba(5, 5, 5, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s var(--ease), visibility 0.4s var(--ease);
    z-index: 99;
  }
  .nav.is-open { opacity: 1; visibility: visible; }
  .nav__list { flex-direction: column; gap: 26px; text-align: center; }
  .nav__link { font-size: 1.3rem; }
  .header__cta { display: none; }
  .nav-toggle { display: flex; }

  .hero { padding-top: calc(var(--header-h) + 40px); }
  .hero__logo { height: 60px; }
  .hero__actions { flex-direction: column; align-items: stretch; }
  .hero__actions .btn { width: 100%; }
  .hero__scroll { display: none; }

  .brands-grid { grid-template-columns: 1fr; }
  .contact__cards { grid-template-columns: 1fr; }

  .flow { flex-direction: column; gap: 14px; }
  .flow__arrow { transform: rotate(90deg); align-self: center; }

  .ecosystem__wrap {
    min-height: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
  }
  .ecosystem__lines { display: none; }
  .ecosystem__core { position: static; transform: none; margin-bottom: 8px; }
  .ecosystem__brand {
    position: static;
    transform: none !important;
    min-width: 0;
    width: 100%;
    max-width: 320px;
  }
}

/* Móvil pequeño */
@media (max-width: 400px) {
  .container { padding-inline: 18px; }
  .hero__title { font-size: 2.1rem; }
  .footer__bar { flex-direction: column; }
}




