/* CalmaLink · Quiénes somos — "Calma + Link". Living network hero, pinned scroll story (people → mess → calm → link → future),
   age counter, word-by-word manifesto, values, multiplying network, closing logo. Scoped with the cx- prefix. */
.cx {
  --cx-navy: #16354B; --cx-deep: #071528; --cx-teal: #167E79; --cx-mint: #9fe3c9; --cx-amber: #f2c35a; --cx-coral: #ff9a7a;
  --cx-muted: #4b5d72; --cx-line: #dbe5ee; --cx-paper: #f6f9fb; --cx-white: #fff;
  --cx-hand: Manrope, sans-serif;
  color: var(--cx-navy); overflow-x: clip;
}
.cx, .cx *, .cx *::before, .cx *::after { box-sizing: border-box; }
.cx-c { max-width: 1180px; margin: 0 auto; padding-inline: 20px; }
.cx h1, .cx h2, .cx h3 { margin: 0; text-wrap: balance; }
.cx p { margin: 0; }
.cx .cx-eyebrow { font-size: .76rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--cx-teal); }
.cx-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.cx-btn { display: inline-flex; align-items: center; gap: 8px; border-radius: 14px; padding: 14px 20px; font-weight: 800; text-decoration: none; border: 1px solid transparent; transition: transform .2s ease, box-shadow .2s ease; }
.cx-btn.cx-amber { background: var(--cx-amber); color: var(--cx-navy); }
.cx-btn.cx-amber:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(242, 195, 90, .45); }
.cx-btn.cx-ghost { color: #fff; border-color: rgba(255, 255, 255, .35); }
.cx-btn.cx-line { background: var(--cx-white); color: var(--cx-navy); border-color: var(--cx-line); }
.cx-btn:focus-visible { outline: 3px solid var(--cx-amber); outline-offset: 3px; }
.cx-data { display: none; }

/* ---------- 1 · hero ---------- */
.cx-hero { position: relative; isolation: isolate; overflow: hidden; color: #fff; padding-block: clamp(64px, 11vh, 120px) clamp(80px, 13vh, 140px);
  background: radial-gradient(90% 80% at 75% 20%, #1e4b74 0%, #0f2b48 45%, var(--cx-deep) 100%); }
.cx-sky { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.cx-crumb { font-size: .82rem; color: #9fb4c7; margin-bottom: 22px; }
.cx-crumb a { color: inherit; }
.cx-hero .cx-eyebrow { color: var(--cx-mint); }
.cx-hero h1 { margin-top: 12px; font-size: clamp(2.6rem, 7vw, 5.4rem); line-height: 1; font-weight: 800; letter-spacing: -.035em; }
.cx-hero h1 em { font-style: normal; background: linear-gradient(90deg, var(--cx-amber), #ffd98a, var(--cx-mint)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.cx-rot { margin-top: 18px !important; font-size: clamp(1.3rem, 3vw, 2.1rem); font-weight: 700; color: #d5e2ef; display: flex; flex-wrap: wrap; gap: 0 .35em; align-items: baseline; min-height: 2.6em; }
.cx-words { position: relative; display: inline-grid; color: var(--cx-amber); font-family: Manrope, sans-serif; font-size: 1.3em; line-height: 1.15; }
.cx-words span { grid-area: 1 / 1; opacity: 0; transform: translateY(.6em); transition: opacity .5s ease, transform .5s cubic-bezier(.2, .8, .2, 1); }
.cx-words span.on { opacity: 1; transform: none; }
.cx-words span.out { opacity: 0; transform: translateY(-.6em); }
.cx-lead { margin-top: 16px !important; max-width: 62ch; font-size: 1.12rem; color: #c6d6e5; }
.cx-hero .cx-btns { margin-top: 28px; }
.cx-down { position: absolute; left: 50%; bottom: 22px; width: 26px; height: 40px; border: 2px solid rgba(255, 255, 255, .45); border-radius: 14px; transform: translateX(-50%); }
.cx-down::after { content: ""; position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; border-radius: 2px; background: var(--cx-amber); transform: translateX(-50%); animation: cx-wheel 1.6s ease-in-out infinite; }
@keyframes cx-wheel { 0% { opacity: 0; top: 6px; } 30% { opacity: 1; } 100% { opacity: 0; top: 22px; } }

/* ---------- 2 · Calma + Link scene ---------- */
.cx-scene { position: relative; height: 520vh; background: var(--cx-deep); }
.cx-stage { position: sticky; top: var(--cx-top, 0px); height: calc(100vh - var(--cx-top, 0px)); overflow: hidden; color: #fff; display: grid; grid-template-rows: auto minmax(0, 1fr);
  padding-block: clamp(26px, 6vh, 60px) 14px; isolation: isolate;
  background: radial-gradient(70% 60% at 50% 60%, rgba(242, 195, 90, var(--cx-fin, 0)) 0%, rgba(242, 195, 90, 0) 70%), radial-gradient(90% 90% at 50% 40%, #173d63 0%, #0c2239 55%, var(--cx-deep) 100%); }
.cx-texts { position: relative; z-index: 2; max-width: 820px; width: 100%; margin: 0 auto; padding-inline: 20px; min-height: clamp(150px, 22vh, 210px); text-align: center; }
.cx-step { position: absolute; inset: 0 20px auto; display: grid; gap: 10px; justify-items: center; opacity: 0; transform: translateY(18px); transition: opacity .5s ease, transform .5s cubic-bezier(.2, .8, .2, 1); pointer-events: none; }
.cx-step.on { opacity: 1; transform: none; pointer-events: auto; }
.cx-step .cx-eyebrow { color: var(--cx-amber); }
.cx-step h2 { font-size: clamp(1.7rem, 3.8vw, 2.8rem); line-height: 1.06; font-weight: 800; letter-spacing: -.025em; }
.cx-step p { font-size: 1.06rem; color: #d5e2ef; max-width: 58ch; }
.cx-map { width: 100%; height: 100%; display: block; overflow: visible; }
.cx-map text { font-family: inherit; font-weight: 700; font-size: 15px; fill: #fff; }
.cx-map.cx-m text { font-size: 12.5px; }
.cx-pill rect { fill: rgba(255, 255, 255, .08); stroke: rgba(255, 255, 255, .3); stroke-width: 1; }
.cx-goal rect { fill: rgba(242, 195, 90, .15); stroke: rgba(242, 195, 90, .7); }
.cx-goal text { fill: #ffe3a3; }
.cx-mapdot { fill: var(--cx-mint); }
.cx-goal .cx-mapdot { fill: var(--cx-amber); }
.cx-in, .cx-out { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; }
.cx-word { font-size: 14px; fill: #ffb4a0; }
.cx-map.cx-m .cx-word { font-size: 12px; }
.cx-wig { transform-box: fill-box; transform-origin: center; animation: cx-wig 2.2s ease-in-out infinite alternate; }
@keyframes cx-wig { from { transform: translate(-6px, 3px) rotate(-5deg); } to { transform: translate(6px, -4px) rotate(5deg); } }
.cx-hubc { fill: var(--cx-navy); stroke: var(--cx-amber); stroke-width: 3; }
.cx-hubk { fill: none; stroke: var(--cx-amber); stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; }
.cx-map text.cx-hublab { font-size: 19px; font-weight: 800; }
.cx-map.cx-m text.cx-hublab { font-size: 16px; }
.cx-pulse { fill: #fff3c4; }
.cx-dots { position: absolute; right: clamp(10px, 2vw, 26px); top: 50%; transform: translateY(-50%); list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; z-index: 3; }
.cx-dots li { display: flex; align-items: center; gap: 8px; justify-content: flex-end; font-size: .74rem; font-weight: 700; color: rgba(255, 255, 255, .45); transition: color .3s ease; }
.cx-dots li::after { content: ""; width: 10px; height: 10px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .5); transition: background .3s ease, border-color .3s ease, transform .3s ease; }
.cx-dots li.on { color: #fff; }
.cx-dots li.on::after { background: var(--cx-amber); border-color: var(--cx-amber); transform: scale(1.25); }
@media (max-width: 1100px) { .cx-dots { display: none; } }
@media (max-width: 700px) {
  .cx-texts { min-height: 214px; }
  .cx-step h2 { font-size: 1.55rem; }
  .cx-step p { font-size: .95rem; }
}

/* ---------- 3 · ages ---------- */
.cx-ages { position: relative; height: 260vh; background: linear-gradient(180deg, #fff6e3 0%, #ffffff 100%); }
.cx-agestage { position: sticky; top: var(--cx-top, 0px); height: calc(100vh - var(--cx-top, 0px)); display: grid; align-content: center; }
.cx-agegrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: center; }
.cx-ages h2 { margin-top: 10px; font-size: clamp(2.2rem, 5vw, 3.8rem); line-height: 1.02; font-weight: 800; letter-spacing: -.03em; }
.cx-agesub { margin-top: 14px !important; color: var(--cx-muted); font-size: 1.1rem; max-width: 40ch; }
.cx-agebox { display: grid; gap: 14px; justify-items: start; }
.cx-agenum { display: flex; align-items: baseline; gap: 12px; font-variant-numeric: tabular-nums; }
.cx-agenum span { font-size: clamp(6rem, 18vw, 11rem); line-height: .9; font-weight: 800; letter-spacing: -.05em; background: linear-gradient(135deg, #102F48, var(--cx-teal)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.cx-agenum small { font-size: 1.4rem; font-weight: 800; color: var(--cx-muted); }
.cx-agecap { font-family: Manrope, sans-serif; font-size: clamp(1.8rem, 3.6vw, 2.6rem); line-height: 1.1; color: var(--cx-teal); min-height: 2.3em; }
.cx-agebar { width: min(100%, 420px); height: 8px; border-radius: 4px; background: #eadfc6; overflow: hidden; }
.cx-agebar i { display: block; height: 100%; width: 0; border-radius: 4px; background: linear-gradient(90deg, var(--cx-amber), var(--cx-teal)); }
.cx-agelist { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 760px) { .cx-agegrid { grid-template-columns: 1fr; } }

/* ---------- 4 · manifesto, lit word by word ---------- */
.cx-mani { padding-block: clamp(80px, 14vh, 150px); background: #fff; }
.cx-mani p.cx-says { margin-top: 18px !important; font-size: clamp(1.8rem, 4.2vw, 3.2rem); line-height: 1.15; font-weight: 800; letter-spacing: -.02em; max-width: 28ch; }
.cx-says span { color: var(--cx-navy); opacity: .14; transition: opacity .25s ease, color .25s ease; }
.cx-says span.lit { opacity: 1; }
.cx-says span.hl.lit { color: var(--cx-teal); }

/* ---------- 5 · values ---------- */
.cx-vals { padding-block: clamp(64px, 10vh, 110px); background: var(--cx-paper); }
.cx-head { display: grid; gap: 10px; max-width: 760px; margin-bottom: clamp(26px, 4vw, 40px); }
.cx-head h2 { font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.06; font-weight: 800; letter-spacing: -.025em; }
.cx-head p:not(.cx-eyebrow) { color: var(--cx-muted); font-size: 1.08rem; }
.cx-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.cx-card { background: var(--cx-white); border: 1px solid var(--cx-line); border-radius: 22px; padding: 26px 24px; display: grid; gap: 10px; align-content: start;
  opacity: 0; transform: translateY(30px); transition: opacity .6s ease var(--d, 0s), transform .6s cubic-bezier(.2, .8, .2, 1) var(--d, 0s), box-shadow .3s ease; }
.cx-card.in { opacity: 1; transform: none; }
.cx-card:hover { box-shadow: 0 22px 44px rgba(11, 23, 38, .12); transform: translateY(-6px); transition-delay: 0s; }
.cx-card h3 { font-size: 1.3rem; font-weight: 800; }
.cx-card p { color: var(--cx-muted); }
.cx-tick { width: 46px; height: 46px; }
.cx-tick circle { fill: #eaf6f0; stroke: var(--cx-teal); stroke-width: 3; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset .8s ease calc(var(--d, 0s) + .3s); }
.cx-tick path { fill: none; stroke: var(--cx-teal); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset .5s ease calc(var(--d, 0s) + 1s); }
.cx-card.in .cx-tick circle, .cx-card.in .cx-tick path { stroke-dashoffset: 0; }
@media (max-width: 960px) { .cx-cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .cx-cards { grid-template-columns: 1fr; } }

/* ---------- 6 · ambition network ---------- */
.cx-amb { padding-block: clamp(70px, 12vh, 130px); color: #fff; background: radial-gradient(80% 90% at 30% 50%, #1e4b74 0%, #11314f 50%, var(--cx-deep) 100%); }
.cx-ambgrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: center; }
.cx-amb .cx-eyebrow { color: var(--cx-mint); }
.cx-amb h2 { margin-top: 12px; font-size: clamp(2rem, 4.6vw, 3.4rem); line-height: 1.05; font-weight: 800; letter-spacing: -.025em; }
.cx-amb h2 em { font-style: normal; color: var(--cx-amber); }
.cx-amb p:not(.cx-eyebrow) { margin-top: 16px !important; color: #c6d6e5; font-size: 1.1rem; max-width: 48ch; }
.cx-net { width: 100%; height: auto; overflow: visible; }
.cx-net line { stroke: rgba(159, 227, 201, .55); stroke-width: 1.4; stroke-dasharray: var(--len); stroke-dashoffset: var(--len); transition: stroke-dashoffset .8s ease var(--d, 0s); }
.cx-net circle { fill: var(--cx-amber); transform-box: fill-box; transform-origin: center; transform: scale(0); transition: transform .45s cubic-bezier(.2, .8, .3, 1.5) var(--d, 0s); }
.cx-net circle.r0 { fill: #fff; }
.cx-net.in line { stroke-dashoffset: 0; }
.cx-net.in circle { transform: scale(1); }
@media (max-width: 860px) { .cx-ambgrid { grid-template-columns: 1fr; } }

/* ---------- 7 · what we do ---------- */
.cx-do { padding-block: clamp(64px, 10vh, 110px); }
.cx-dogrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; counter-reset: dd; }
.cx-doit { border-radius: 20px; padding: 22px; background: linear-gradient(160deg, #eef8f3, #eef4fb); display: grid; gap: 8px; align-content: start; counter-increment: dd;
  opacity: 0; transform: translateY(24px); transition: opacity .5s ease var(--d, 0s), transform .5s ease var(--d, 0s); }
.cx-doit.in { opacity: 1; transform: none; }
.cx-doit::before { content: "0" counter(dd); font-weight: 800; color: var(--cx-teal); font-size: .9rem; letter-spacing: .1em; }
.cx-doit h3 { font-size: 1.12rem; font-weight: 800; }
.cx-doit p { color: var(--cx-muted); font-size: .95rem; }
.cx-doit a { color: var(--cx-teal); font-weight: 700; }
.cx-dofoot { margin-top: 22px !important; color: var(--cx-muted); }
.cx-dofoot b { color: var(--cx-navy); }
@media (max-width: 960px) { .cx-dogrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .cx-dogrid { grid-template-columns: 1fr; } }

/* ---------- 8 · closing: the CalmaLink check draws itself ---------- */
.cx-cta { text-align: center; padding-block: clamp(70px, 12vh, 130px); background: linear-gradient(180deg, #fff 0%, #fff4dc 100%); }
.cx-cta .cx-c { display: grid; justify-items: center; gap: 14px; }
.cx-cta h2 { font-size: clamp(1.9rem, 4.6vw, 3.4rem); line-height: 1.06; font-weight: 800; letter-spacing: -.03em; max-width: 22ch; }
.cx-cta h2 em { font-style: normal; font-family: Manrope, sans-serif; color: var(--cx-teal); font-size: 1.15em; }
.cx-cta p { color: var(--cx-muted); font-size: 1.1rem; }
.cx-logo { width: 110px; height: 110px; overflow: visible; }
.cx-ring { fill: none; stroke: var(--cx-amber); stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.cx-cta.in .cx-ring { animation: cx-ring 2.6s ease-out 1.5s infinite; }
.cx-cta.in .cx-ring.r2 { animation-delay: 2.8s; }
@keyframes cx-ring { 0% { opacity: .8; transform: scale(1); } 100% { opacity: 0; transform: scale(1.7); } }
.cx-reg { margin-top: 26px !important; font-size: .82rem; color: var(--cx-muted); }

/* without motion: everything finished and visible, no pinning */
.cx.cx-still .cx-scene, .cx.cx-still .cx-ages { height: auto; }
.cx.cx-still .cx-stage { position: relative; height: auto; min-height: 0; }
.cx.cx-still .cx-map { height: min(70vh, 600px); }
.cx.cx-still .cx-step { display: none; }
.cx.cx-still .cx-step:last-child { display: grid; position: static; opacity: 1; transform: none; }
.cx.cx-still .cx-texts { min-height: 0; }
.cx.cx-still .cx-agestage { position: relative; height: auto; padding-block: 70px; }
.cx.cx-still .cx-agelist { position: static; width: auto; height: auto; clip: auto; white-space: normal; list-style: none; margin: 24px auto 0; padding: 0 20px; max-width: 1180px; display: grid; gap: 6px; font-family: Manrope, sans-serif; font-size: 1.5rem; color: var(--cx-teal); }
.cx.cx-still .cx-card, .cx.cx-still .cx-doit { opacity: 1; transform: none; }
.cx.cx-still .cx-says span { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .cx-down::after, .cx-wig, .cx-ring { animation: none !important; }
  .cx * { transition: none !important; }
}

/* Quiénes somos · cierre: el logo nuevo se dibuja solo (sustituye a .cx-lc y .cx-lk) */
.cx-logo .cl-a,
.cx-logo .cl-b { stroke-dasharray: 1; stroke-dashoffset: 1; }
.cx-logo .cl-a { transition: stroke-dashoffset .8s ease .1s; }
.cx-logo .cl-b { transition: stroke-dashoffset .9s ease .75s; }
.cx-cta.in .cx-logo .cl-a,
.cx-cta.in .cx-logo .cl-b { stroke-dashoffset: 0; }
@media (prefers-reduced-motion: reduce) {
  .cx-logo .cl-a,
  .cx-logo .cl-b { stroke-dashoffset: 0; transition: none; }
}
