/* ===== Vyo — réplica Hashgraph ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #000209;
  --fg: #eeeeee;
  --accent: #9bb8e1;
  --accent-deep: #2c4e73;
  --dim: #6b7a92;
  --line: rgba(155, 184, 225, 0.18);
  --display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --sans: "Inter", system-ui, sans-serif;
  --gutter: 2.8rem;
  --ease: cubic-bezier(0.14, 1, 0.34, 1);
}
@media (min-width: 900px) { :root { --gutter: 6.4rem; } }

html { font-size: 62.5%; -webkit-font-smoothing: antialiased; background: var(--bg); }
body {
  background: transparent;
  color: var(--fg);
  font-family: var(--sans);
  font-size: 1.6rem;
  line-height: 1.45;
  overflow-x: hidden;
}
#bg-canvas {
  position: fixed; inset: 0; width: 100vw; height: 100vh;
  z-index: -1; display: block; pointer-events: none;
}
a { color: inherit; text-decoration: none; }
em { font-style: normal; }
strong { font-weight: 500; color: var(--fg); }
::selection { background: var(--accent); color: var(--bg); }

@media (hover: hover) and (pointer: fine) { * { cursor: none; } }

.display {
  font-family: var(--display);
  font-weight: 500;
  line-height: 0.96;
  letter-spacing: -0.02em;
}

/* ===== CURSOR ===== */
.cursor, .cursor-dot {
  position: fixed; top: 0; left: 0; z-index: 200; border-radius: 50%;
  pointer-events: none; transform: translate(-50%, -50%); mix-blend-mode: difference;
}
.cursor {
  width: 3.6rem; height: 3.6rem; border: 1px solid var(--fg);
  transition: width .4s var(--ease), height .4s var(--ease), background .4s var(--ease);
}
.cursor-dot { width: 5px; height: 5px; background: var(--fg); }
.cursor.is-hover { width: 7rem; height: 7rem; background: rgba(255,255,255,0.07); }
@media (hover: none), (pointer: coarse) { .cursor, .cursor-dot { display: none; } }

/* ===== HEADER ===== */
header {
  position: fixed; top: 0; left: 0; width: 100%; z-index: 80;
  display: flex; align-items: center; justify-content: space-between;
  padding: 3.2rem var(--gutter);
  mix-blend-mode: difference;
}
.logo { display: flex; align-items: center; column-gap: 1.2rem; }
.logo__mark { color: var(--accent); font-size: 1.4rem; transform: translateY(-1px); }
.logo__type { font-family: var(--display); font-size: 2.2rem; letter-spacing: 0.01em; }
.logo__type em { font-style: italic; color: var(--accent); }

.sound-toggle {
  display: flex; align-items: center; column-gap: 1.2rem;
  background: none; border: none; color: var(--fg);
  font-family: var(--sans); font-size: 1.3rem; letter-spacing: 0.04em;
}
.sound-toggle__status { color: var(--accent); min-width: 2.6rem; text-align: left; transition: transform .8s var(--ease); }
.sound-toggle.is-on .sound-toggle__status { transform: translateX(0.4rem); }
.sound-toggle__bars { display: flex; align-items: flex-end; gap: 2px; height: 1.4rem; }
.sound-toggle__bars i { width: 2px; height: 3px; background: var(--fg); transform-origin: bottom; transition: height .3s; }
.sound-toggle.is-on .sound-toggle__bars i { animation: eq .9s ease-in-out infinite alternate; }
.sound-toggle.is-on .sound-toggle__bars i:nth-child(2) { animation-delay: .15s; }
.sound-toggle.is-on .sound-toggle__bars i:nth-child(3) { animation-delay: .3s; }
.sound-toggle.is-on .sound-toggle__bars i:nth-child(4) { animation-delay: .45s; }
@keyframes eq { from { height: 3px; } to { height: 1.4rem; } }

/* ===== STAGE / PANELS ===== */
.stage { position: relative; }
.stage__inner { position: relative; height: 100svh; }
.panel {
  position: absolute; inset: 0; height: 100svh; width: 100%;
  padding: 0 var(--gutter) 4.8rem;
  display: flex; flex-direction: column; justify-content: flex-end;
  will-change: opacity, transform;
}
@media (min-width: 900px) {
  .panel:not(.hero) { justify-content: center; padding-bottom: 0; }
}

/* split text mechanics */
.split .ln, .split-footer { display: block; overflow: hidden; }
.split .ln { position: relative; }
.char, .ln > .inner { display: inline-block; }

/* ===== HERO ===== */
.hero { align-items: flex-start; }
@media (min-width: 768px) { .hero { flex-direction: row; align-items: flex-end; justify-content: space-between; } }
.hero__title {
  font-size: clamp(2.8rem, 6vw, 6rem);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.005em;
  line-height: 1.02;
}
.hero__title em { color: var(--accent); }
@media (min-width: 900px) {
  /* bloque limpio alineado a la izquierda, abajo (como la referencia) */
  .hero__title .ln { position: relative; left: 0; }
}
.hero__btn { display: none; }
@media (min-width: 768px) {
  .hero__btn { display: flex; align-items: flex-end; column-gap: 1.2rem; margin-bottom: 1rem; }
}
.hero__btn-label { font-size: 1.3rem; line-height: 1.3; text-align: right; color: var(--fg); letter-spacing: 0.02em; }
.hero__btn-line { display: block; height: 6.4rem; width: 1px; position: relative; overflow: hidden; }
.hero__btn-line::before, .hero__btn-line::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--accent), var(--accent-deep));
}
.hero__btn-line::before { animation: dash-wipe 2s linear infinite; clip-path: inset(0 0 0 0); }
.hero__btn-line::after  { animation: dash-reveal 2s linear infinite; clip-path: inset(0 0 100% 0); }
@keyframes dash-wipe { 0% { clip-path: inset(0 0 0 0); } 25%,100% { clip-path: inset(100% 0 0 0); } }
@keyframes dash-reveal { 12% { clip-path: inset(0 0 100% 0); } 30%,100% { clip-path: inset(0 0 0 0); } }

/* ===== PANEL TITLE + COPY layout ===== */
.panel__title { font-size: clamp(3.4rem, 8.5vw, 10rem); }
.panel__title em { color: var(--accent); }
.panel__title .ln { white-space: nowrap; }
.panel__title .ln[data-align="right"] { text-align: right; }

.panel__copy { max-width: 38rem; margin-top: 3.2rem; color: var(--dim); display: flex; flex-direction: column; row-gap: 1.6rem; }
.body-copy p { font-size: 1.6rem; line-height: 1.55; }
.body-copy strong { color: var(--accent); font-weight: 500; }
.link {
  align-self: flex-start; margin-top: 0.8rem;
  font-size: 1.3rem; letter-spacing: 0.12em; text-transform: uppercase;
  border-bottom: 1px solid var(--line); padding-bottom: 0.5rem;
  display: inline-flex; align-items: center; column-gap: 0.6rem;
}
.link span { transition: transform .4s var(--ease); }
.link:hover span { transform: translateX(0.6rem); }

/* Desktop scattered grid layouts */
@media (min-width: 900px) {
  .panel:not(.hero) { display: grid; grid-template-columns: repeat(12, 1fr); align-content: center; gap: 0 2rem; }
  .panel__title-wrap { grid-column: 2 / span 7; grid-row: 1; align-self: center; }
  .panel:not(.hero) .panel__copy { grid-row: 1; }
  .panel__title .ln { position: relative; }

  .manifesto .panel__title .ln[data-x="-2"] { left: -2rem; }
  .manifesto .panel__title .ln[data-x="2"]  { right: -2rem; }
  .manifesto .panel__copy { grid-column: 9 / span 4; margin-top: 0; align-self: center; }

  .portfolio .panel__title-wrap { grid-column: 2 / span 7; }
  .portfolio .panel__title .ln[data-x="-2"] { left: -2rem; }
  .portfolio .panel__title .ln[data-x="9"]  { left: 11rem; }
  .portfolio .panel__title .ln[data-x="4"]  { left: 5rem; }
  .portfolio .panel__copy { grid-column: 9 / span 4; margin-top: 0; align-self: center; }

  .team .panel__title-wrap { grid-column: 2 / span 7; }
  .team .panel__title .ln[data-x="-4"] { left: -4rem; }
  .team .panel__title .ln[data-x="4"]  { left: 4rem; }
  .team .panel__copy { grid-column: 9 / span 4; margin-top: 0; align-self: center; }
}

/* ===== TEAM MEMBERS (cycling) ===== */
.team__members {
  position: absolute; left: var(--gutter); bottom: 5.8rem;
  height: 7rem; width: 30rem;
}
@media (min-width: 900px) { .team__members { left: auto; right: var(--gutter); bottom: 5.8rem; } }
.member {
  position: absolute; inset: 0; display: flex; flex-direction: column; row-gap: 0.6rem;
  opacity: 0; transform: translateY(1rem); transition: opacity .6s var(--ease), transform .6s var(--ease);
}
.member.is-active { opacity: 1; transform: translateY(0); }
.member__name { font-size: 3.2rem; }
.member__role { font-size: 1.3rem; letter-spacing: 0.06em; color: var(--accent); }

/* ===== SCROLL PROGRESS RAIL ===== */
.rail {
  position: fixed; right: 2.4rem; top: 50%; transform: translateY(-50%);
  z-index: 70; display: flex; flex-direction: column; align-items: center; row-gap: 1.4rem;
}
.rail__num {
  font-family: var(--sans); font-size: 1.15rem; letter-spacing: 0.18em;
  color: var(--fg); font-variant-numeric: tabular-nums;
}
.rail__num--total { color: var(--dim); }
.rail__track {
  position: relative; width: 1px; height: 34vh; max-height: 30rem;
  background: rgba(238, 238, 238, 0.16); overflow: hidden;
}
.rail__fill {
  position: absolute; top: 0; left: 0; width: 100%; height: 0%;
  background: var(--accent);
}
@media (max-width: 767px) { .rail { display: none; } }

/* ===== FOOTER ===== */
.footer {
  position: relative; z-index: 1; background: transparent;
  min-height: 100svh; display: flex; flex-direction: column; justify-content: center;
  padding: 8rem var(--gutter) 4rem; border-top: 1px solid var(--line);
}
.footer__eyebrow { font-size: 1.4rem; letter-spacing: 0.12em; color: var(--dim); }
.footer__title { font-size: clamp(4.4rem, 12vw, 14rem); margin: 1.6rem 0 3.2rem; }
.footer__mail {
  font-family: var(--display); font-size: clamp(2.2rem, 6vw, 5rem);
  color: var(--accent); transition: opacity .4s var(--ease); width: fit-content;
}
.footer__mail:hover { opacity: 0.6; }
.footer__bottom {
  margin-top: auto; padding-top: 4rem; display: flex; flex-wrap: wrap; gap: 2rem;
  justify-content: space-between; align-items: flex-end;
}
.footer__list { list-style: none; display: flex; flex-direction: column; row-gap: 0.6rem; font-size: 1.3rem; color: var(--dim); }
.footer__list--socials { flex-direction: row; column-gap: 2rem; }
.footer__list--socials a { position: relative; letter-spacing: 0.08em; }
.footer__list--socials a::after { content: ""; position: absolute; left: 0; bottom: -3px; width: 0; height: 1px; background: var(--accent); transition: width .4s var(--ease); }
.footer__list--socials a:hover::after { width: 100%; }
.footer__list--legals { text-align: right; letter-spacing: 0.04em; }

@media (max-width: 899px) {
  .panel__title-wrap { margin-bottom: 2.4rem; }
}

/* ===== INTRO / SPLASH ===== */
.intro {
  position: fixed; inset: 0; z-index: 150;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: var(--bg);
  transition: opacity 1.1s var(--ease), visibility 1.1s var(--ease);
}
.intro.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.intro__tri {
  position: absolute; top: 50%; left: 50%;
  width: min(78vh, 70vw); height: min(78vh, 70vw);
  transform: translate(-50%, -50%);
  color: var(--line); pointer-events: none;
}
.intro__center { position: relative; display: flex; flex-direction: column; align-items: center; row-gap: 1.8rem; }
.intro__brand { font-size: clamp(3.2rem, 8vw, 7rem); letter-spacing: 0.01em; }
.intro__brand em { font-style: italic; color: var(--accent); }
.intro__rule {
  width: 7rem; height: 1px; background: var(--accent); transform-origin: center;
  animation: introRule 2.4s var(--ease) infinite;
}
@keyframes introRule {
  0%, 100% { transform: scaleX(0.25); opacity: 0.45; }
  50% { transform: scaleX(1); opacity: 1; }
}
.intro__hint {
  position: absolute; bottom: 4rem; left: 0; right: 0; text-align: center;
  font-size: 1.2rem; letter-spacing: 0.08em; color: var(--dim); line-height: 1.7;
}
@media (prefers-reduced-motion: reduce) {
  .intro__rule { animation: none; transform: scaleX(1); }
}

/* ===== 6 SECCIONES — copy nuevo ===== */
.hero__lead { display: flex; flex-direction: column; max-width: 64rem; }
.hero__eyebrow { font-size: clamp(1.3rem, 1.6vw, 1.6rem); letter-spacing: 0.06em; color: var(--accent); margin-bottom: 1.8rem; }
.hero__sub { margin-top: 2.2rem; max-width: 44rem; color: var(--dim); font-size: 1.6rem; line-height: 1.6; }
@media (min-width: 768px) { .hero { align-items: flex-end; } .hero__lead { margin-bottom: 0.5rem; } }

.panel__num {
  display: block; font-family: var(--sans); font-size: 1.25rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--accent); margin-bottom: 1.8rem;
}

/* pilares (02) */
.pillars { list-style: none; display: flex; flex-direction: column; row-gap: 2.2rem; }
.pillars li { display: flex; flex-direction: column; row-gap: 0.5rem; padding-left: 1.6rem; border-left: 1px solid var(--line); }
.pillar__t { font-size: 2rem; color: var(--fg); letter-spacing: -0.01em; }
.pillar__d { font-size: 1.45rem; line-height: 1.5; color: var(--dim); }

/* razones (04) */
.reasons { list-style: none; display: flex; flex-direction: column; row-gap: 1rem; margin-top: 0.6rem; }
.reasons li { font-size: 1.7rem; color: var(--fg); padding-left: 1.6rem; position: relative; }
.reasons li::before { content: "—"; position: absolute; left: 0; color: var(--accent); }
.reasons__neg { color: var(--dim) !important; }
.reasons__neg::before { color: var(--dim) !important; }

/* proceso (05) */
.steps { list-style: none; display: flex; flex-direction: column; row-gap: 1.8rem; counter-reset: step; }
.steps li { display: grid; grid-template-columns: 3.4rem 1fr; column-gap: 1.2rem; align-items: baseline; }
.step__n { grid-row: span 2; font-family: var(--display); font-size: 1.5rem; color: var(--accent); }
.step__t { font-size: 1.9rem; color: var(--fg); }
.step__d { grid-column: 2; font-size: 1.4rem; line-height: 1.5; color: var(--dim); margin-top: 0.3rem; }

/* footer sub */
.footer__sub { margin-top: 1.4rem; margin-bottom: 3rem; max-width: 46rem; color: var(--dim); font-size: 1.6rem; line-height: 1.55; }
.footer__eyebrow { line-height: 1.5; }

/* layout escritorio para las secciones nuevas */
@media (min-width: 900px) {
  .philosophy .panel__copy, .results .panel__copy, .process .panel__copy,
  .portfolio .panel__copy { grid-column: 9 / span 4; margin-top: 0; align-self: center; }
  .philosophy .panel__title .ln[data-x="-4"] { left: -4rem; }
  .philosophy .panel__title .ln[data-x="4"]  { left: 4rem; }
  .results .panel__title .ln[data-x="-2"] { left: -2rem; }
  .results .panel__title .ln[data-x="3"]  { left: 5rem; }
  .process .panel__title .ln[data-x="-3"] { left: -3rem; }
  .process .panel__title .ln[data-x="3"]  { left: 5rem; }
  .portfolio .panel__title .ln[data-x="9"] { left: 9rem; }
}
