/* ============================================================
   PLASMART v3 — "SIGNAL"
   Ultra-futurist · minimalist · Lenis + GSAP motion
   Space-black · hairline indigo accent · Sora thin display
   ============================================================ */

:root {
  --bg:    #08090b;
  --bg-2:  #0d0f13;
  --panel: #111419;
  --text:  #eef0f3;
  --muted: #8a8f99;
  --faint: #4f545d;
  --line:  rgba(255,255,255,.10);
  --line-2:rgba(255,255,255,.20);
  --accent:#6e7bff;
  --accent-soft: rgba(110,123,255,.6);

  --display: "Sora", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;

  --maxw: 1480px;
  --pad: clamp(20px, 4.5vw, 80px);
  --ease: cubic-bezier(.19,1,.22,1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html {
  -webkit-text-size-adjust: 100%; background: var(--bg);
  color-scheme: dark;                 /* dark form controls, UA scrollbars, etc. */
  scrollbar-color: var(--line-2) transparent; scrollbar-width: thin; /* Firefox */
}
body {
  background: var(--bg); color: var(--text);
  font-family: var(--display); font-weight: 400;
  font-size: 17px; line-height: 1.55; letter-spacing: -.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent; /* no blue flash on tap (mobile) */
}
/* themed scrollbar (WebKit) to match the space-black aesthetic */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 6px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
a, button, .btn { touch-action: manipulation; } /* remove 300ms tap delay */
::selection { background: var(--accent); color: #fff; }

/* a11y: visible keyboard focus (the custom cursor hides the pointer, so focus must be clear) */
a:focus-visible, button:focus-visible, .btn:focus-visible,
input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px;
}
/* a11y: skip-to-content link for keyboard/screen-reader users */
.skip-link {
  position: fixed; top: 10px; left: 10px; z-index: 9999;
  background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 4px;
  font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  transform: translateY(-160%); transition: transform .2s var(--ease);
}
.skip-link:focus { transform: none; outline: 2px solid var(--accent); outline-offset: 2px; }

/* grain */
body::after {
  content: ""; position: fixed; inset: -50%; z-index: 9000; pointer-events: none; opacity: .04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* ambient glow */
body::before {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(120% 70% at 50% -10%, rgba(110,123,255,.12), transparent 60%);
}

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding-inline: var(--pad); position: relative; }

/* type primitives */
.kicker { font-family: var(--mono); font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); display: inline-flex; align-items: center; gap: 10px; }
.kicker .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; color: var(--muted); }
h1, h2, h3 { font-weight: 200; line-height: .98; letter-spacing: -.035em; }
.h-xl { font-size: clamp(44px, 9vw, 150px); font-weight: 200; line-height: .94; letter-spacing: -.04em; }
.h-l  { font-size: clamp(34px, 5.6vw, 88px); font-weight: 200; letter-spacing: -.035em; }
.thin { font-weight: 200; } .med { font-weight: 500; }
.lead { font-size: clamp(17px, 1.5vw, 21px); color: var(--muted); font-weight: 400; max-width: 54ch; }

/* reveal helpers — hidden ONLY when libs confirmed (html.lib-on) */
html.lib-on [data-rv] { opacity: 0; }
html.lib-on [data-rv="up"] { transform: translateY(40px); }
html.lib-on [data-clip] { clip-path: inset(100% 0 0 0); }
.line-wrap { overflow: hidden; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; gap: 12px; position: relative;
  height: 58px; padding: 0 30px; border-radius: 100px;
  font-family: var(--display); font-weight: 500; font-size: 15px; letter-spacing: 0;
  border: 1px solid var(--line-2); color: var(--text); background: transparent;
  transition: color .3s, border-color .3s; cursor: pointer; overflow: hidden; will-change: transform;
}
.btn span { position: relative; z-index: 1; }
.btn .fill { position: absolute; inset: 0; background: var(--accent); border-radius: 100px; transform: translateY(101%); transition: transform .5s var(--ease); z-index: 0; }
.btn:hover { color: #fff; border-color: var(--accent); }
.btn:hover .fill { transform: translateY(0); }
.btn svg { width: 17px; height: 17px; position: relative; z-index: 1; }
.btn-solid { background: var(--text); color: var(--bg); border-color: var(--text); }
.btn-solid .fill { background: var(--accent); }
.btn-solid:hover { color: #fff; }

.arrow-link { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); transition: color .3s; }
.arrow-link:hover { color: var(--text); }
.arrow-link .ln { width: 28px; height: 1px; background: currentColor; transition: width .35s var(--ease); }
.arrow-link:hover .ln { width: 46px; }

/* ============================================================
   CURSOR
   ============================================================ */
@media (hover: hover) and (pointer: fine) {
  html.cursor-on, html.cursor-on * { cursor: none !important; }
}
.cursor { position: fixed; top: 0; left: 0; width: 30px; height: 30px; margin: -15px 0 0 -15px; border: 1px solid var(--text); border-radius: 50%; z-index: 9500; pointer-events: none; mix-blend-mode: difference; opacity: 0; transition: opacity .3s, width .25s var(--ease), height .25s var(--ease), margin .25s var(--ease), background .25s; }
html.cursor-on .cursor { opacity: 1; }
.cursor.hot { width: 64px; height: 64px; margin: -32px 0 0 -32px; background: rgba(255,255,255,.08); }
.cursor-dot { position: fixed; top: 0; left: 0; width: 4px; height: 4px; margin: -2px 0 0 -2px; border-radius: 50%; background: var(--text); z-index: 9501; pointer-events: none; mix-blend-mode: difference; opacity: 0; }
html.cursor-on .cursor-dot { opacity: 1; }

/* scroll progress */
.progress { position: fixed; top: 0; left: 0; height: 2px; width: 0; background: var(--accent); z-index: 9600; box-shadow: 0 0 12px var(--accent-soft); }

/* ============================================================
   LOADER
   ============================================================ */
.loader { position: fixed; inset: 0; z-index: 9700; background: var(--bg); display: flex; align-items: flex-end; justify-content: space-between; padding: var(--pad); }
.loader .lnum { font-family: var(--display); font-weight: 200; font-size: clamp(80px, 20vw, 280px); line-height: .8; letter-spacing: -.05em; }
.loader .llabel { font-family: var(--mono); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); padding-bottom: 12px; }
.loader-bar { position: absolute; left: 0; bottom: 0; height: 1px; width: 0; background: var(--text); }

/* ============================================================
   NAV
   ============================================================ */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 400; display: flex; align-items: center; justify-content: space-between; padding: 22px var(--pad); mix-blend-mode: difference; transition: background .35s var(--ease), backdrop-filter .35s var(--ease), box-shadow .35s var(--ease), border-color .35s var(--ease), padding .35s var(--ease); border-bottom: 1px solid transparent; }
/* once scrolled, drop the difference blend and give the bar a legible backdrop + soft shadow */
.nav.scrolled { mix-blend-mode: normal; background: rgba(8, 9, 11, .72); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0, 0, 0, .35); padding-top: 16px; padding-bottom: 16px; }
.nav .brand { font-family: var(--display); font-weight: 600; font-size: 26px; letter-spacing: -.03em; color: #fff; display: flex; align-items: center; }
.nav .brand img { height: 44px; width: auto; display: block; }
.nav .brand i { color: var(--accent); font-style: normal; }
.nav-mid { display: flex; gap: 30px; }
.nav-mid a { font-size: 14px; color: #fff; opacity: .7; transition: opacity .3s; }
.nav-mid a:hover { opacity: 1; }
.nav-right { display: flex; align-items: center; gap: 14px; }
.vchips { display: flex; gap: 5px; font-family: var(--mono); font-size: 11px; }
.vchips a { padding: 5px 9px; border: 1px solid rgba(255,255,255,.3); border-radius: 100px; color: #fff; transition: .25s; }
.vchips a.on { background: #fff; color: #000; border-color: #fff; }
.nav-cta { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #fff; border-bottom: 1px solid var(--accent); padding-bottom: 3px; }
/* language toggle (ES / EN) */
.lang { display: inline-flex; align-items: center; gap: 7px; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; }
.lang a { color: #fff; opacity: .55; transition: opacity .25s; }
.lang a:hover { opacity: 1; }
.lang a.on { opacity: 1; color: var(--accent); }
.lang .sep { opacity: .35; }
@media (max-width: 900px) { .nav-mid { display: none; } }
@media (max-width: 560px) { .nav-cta { display: none; } }

/* ============================================================
   HERO
   ============================================================ */
.hero { position: relative; min-height: 100svh; display: flex; flex-direction: column; justify-content: flex-end; padding: 0 var(--pad) clamp(40px, 7vh, 80px); overflow: hidden; }
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg .hbv { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; filter: grayscale(.25); transform: scale(1.04); transition: opacity .9s linear; }
.hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,9,11,.55) 0%, rgba(8,9,11,.12) 32%, rgba(8,9,11,.32) 60%, rgba(8,9,11,.9) 90%, var(--bg) 100%); }
.hero-inner { position: relative; z-index: 2; width: 100%; }
.hero-top { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: clamp(30px, 6vh, 80px); }
.hero h1 { max-width: 16ch; }
.hero h1 .l { display: block; }
.hero h1 .ln-mask { display: block; overflow: hidden; padding-bottom: .06em; }
.hero h1 .ln-in { display: block; }
.hero h1 .hl { color: var(--accent); }
.hero-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-top: clamp(28px, 4vw, 48px); }
.hero-foot .mono { max-width: 30ch; }
.scrollcue { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.scrollcue .bar { width: 1px; height: 50px; background: linear-gradient(var(--accent), transparent); position: relative; overflow: hidden; }
.scrollcue .bar::after { content: ""; position: absolute; inset: 0 0 auto 0; height: 40%; background: var(--text); animation: cue 2s var(--ease) infinite; }
@keyframes cue { to { transform: translateY(180%); } }

/* ============================================================
   MANIFESTO (word scrub)
   ============================================================ */
.mani { padding-block: clamp(120px, 22vh, 280px); }
.mani p { font-size: clamp(28px, 4.4vw, 72px); font-weight: 200; line-height: 1.12; letter-spacing: -.03em; max-width: 22ch; }
.mani .w { color: var(--faint); transition: color .3s; }
.mani .w.on { color: var(--text); }
.mani .accent.on { color: var(--accent); }
/* a11y: keep the manifesto legible when the scrub never runs (no GSAP or reduced-motion) */
html:not(.lib-on) .mani .w { color: var(--text); }
html:not(.lib-on) .mani .accent { color: var(--accent); }

/* ============================================================
   CAPACIDADES (hover-image list)
   ============================================================ */
.sec { padding-block: clamp(80px, 13vh, 180px); }
.sec-top { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; flex-wrap: wrap; padding-bottom: 28px; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.sec-top h2 { font-size: clamp(28px, 3.4vw, 52px); }

.cap-list { display: flex; flex-direction: column; }
.cap-row { position: relative; display: grid; grid-template-columns: 70px auto 1fr auto; align-items: center; gap: 24px; padding: clamp(22px, 3vw, 40px) 0; border-bottom: 1px solid var(--line); transition: padding-left .5s var(--ease); }
.cap-row .ci { font-family: var(--mono); font-size: 12px; color: var(--faint); }
.cap-row .cn { font-size: clamp(26px, 4vw, 60px); font-weight: 200; letter-spacing: -.03em; color: var(--muted); white-space: nowrap; transition: color .4s var(--ease); }
.cap-row .cdesc { font-size: 15px; line-height: 1.45; color: var(--muted); max-width: 52ch; padding-left: 26px; opacity: 0; transform: translateY(4px); transition: opacity .55s var(--ease), transform .55s var(--ease); }
.cap-row .cdesc.seen { opacity: 1; transform: none; }
.cap-row:hover .cdesc { opacity: 1; transform: none; }
.cap-row .cspec { font-family: var(--mono); font-size: 12px; color: var(--faint); text-align: right; letter-spacing: .08em; }
.cap-row:hover { padding-left: 28px; }
.cap-row:hover .cn { color: var(--text); }
.cap-row:hover .ci { color: var(--accent); }
.cap-row::before { content: ""; position: absolute; left: 0; top: 50%; width: 12px; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }
.cap-row:hover::before { transform: scaleX(1); }
/* floating preview */
/* floating text card */
.hover-card { position: fixed; top: 0; left: 0; width: 320px; z-index: 300; pointer-events: none; border: 1px solid var(--line-2); background: rgba(17,20,25,.92); backdrop-filter: blur(10px); border-radius: 4px; padding: 24px 24px 26px; opacity: 0; transform: translate(-50%,-50%) scale(.9); transform-origin: center; will-change: transform; }
.hover-card .hc-k { font-family: var(--mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); }
.hover-card .hc-d { margin-top: 12px; font-size: 18px; font-weight: 300; line-height: 1.35; color: var(--text); letter-spacing: -.01em; }
@media (max-width: 760px) {
  .hover-card { display: none; }
  .cap-row { grid-template-columns: 40px 1fr 24px; row-gap: 0; align-items: start; cursor: pointer; }
  .cap-row .ci { grid-column: 1; padding-top: 6px; }
  .cap-row .cn { grid-column: 2; white-space: normal; }
  .cap-row .cspec { grid-column: 2; text-align: left; font-size: 11px; margin-top: 4px; }
  .cap-row .cdesc { grid-column: 1 / -1; max-width: none; padding-left: 0; opacity: 0; transform: none; max-height: 0; overflow: hidden; margin-top: 0; transition: max-height .45s var(--ease), opacity .4s var(--ease), margin-top .45s var(--ease); }
  .cap-row.open .cdesc { opacity: 1; max-height: 240px; margin-top: 12px; }
  .cap-row .cap-plus { display: block; grid-column: 3; grid-row: 1; align-self: center; justify-self: end; font-family: var(--mono); color: var(--accent); font-size: 20px; line-height: 1; transition: transform .3s var(--ease); }
  .cap-row.open .cap-plus { transform: rotate(45deg); }
}

/* ============================================================
   STATS
   ============================================================ */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.stat { padding: clamp(28px,3vw,48px) 0; border-bottom: 1px solid var(--line); }
.stat .sv { font-size: clamp(40px, 6vw, 90px); font-weight: 200; letter-spacing: -.04em; display: flex; align-items: baseline; gap: 5px; }
.stat .sv .u { font-family: var(--mono); font-size: .22em; color: var(--accent); letter-spacing: .05em; }
.stat .sl { color: var(--muted); font-size: 14px; margin-top: 6px; }
@media (max-width: 760px) { .stats { grid-template-columns: 1fr 1fr; gap: 0 30px; } }

/* ============================================================
   PROYECTOS — pinned horizontal
   ============================================================ */
.work { position: relative; }
.work-head { padding: clamp(60px,8vh,120px) var(--pad) 40px; display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; max-width: var(--maxw); margin: 0 auto; }
.hpin { height: 100svh; overflow: hidden; display: flex; align-items: center; }
.htrack { display: flex; gap: clamp(20px, 3vw, 48px); padding: 0 var(--pad); will-change: transform; }
.wcard { width: 100%; }
.work-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2vw, 30px); max-width: var(--maxw); margin: 0 auto; padding: 20px var(--pad) clamp(40px,6vw,90px); align-items: start; }
.wg-col { display: flex; flex-direction: column; gap: clamp(16px, 2vw, 30px); will-change: transform; }
.wg-col:nth-child(2) { margin-top: clamp(40px, 8vw, 130px); }
/* infinite vertical marquee: JS wraps the cards in .wg-track and translates it,
   while .wg-col is clipped to one set's height so page flow stays normal */
.wg-col.is-marquee { display: block; overflow: hidden; }
.wg-track { display: flex; flex-direction: column; gap: clamp(16px, 2vw, 30px); will-change: transform; }
.wcard .pic { position: relative; aspect-ratio: 4/5; overflow: hidden; border-radius: 4px; background: var(--panel); }
.wcard .pic img { position: absolute; inset: -8% 0; width: 100%; height: 116%; object-fit: cover; filter: grayscale(.3); transition: filter .5s; will-change: transform; }
.wcard:hover .pic img { filter: none; }
.wcard .wm { display: flex; justify-content: space-between; margin-top: 14px; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; }
.wcard .wm .nm { color: var(--text); text-transform: uppercase; }
.wcard .wm .ty { color: var(--muted); }
/* fallback when no GSAP: horizontal scroll */
html:not(.lib-on) .hpin { height: auto; overflow-x: auto; }
html:not(.lib-on) .htrack { padding-block: 20px; }

/* ============================================================
   APLICACIONES — wipe rows
   ============================================================ */
.app3 { border-top: 1px solid var(--line); }
.app3-row { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px,5vw,80px); align-items: center; padding: clamp(40px,6vw,90px) 0; border-bottom: 1px solid var(--line); }
.app3-row .ap-pic { aspect-ratio: 16/11; overflow: hidden; border-radius: 4px; background: var(--panel); position: relative; }
.app3-row .ap-pic img { width: 100%; height: 100%; object-fit: cover; will-change: transform; }
.app3-row:nth-child(even) .ap-pic { order: -1; }
.app3-row .ai { font-family: var(--mono); font-size: 12px; color: var(--accent); letter-spacing: .12em; }
.app3-row h3 { font-size: clamp(32px, 5vw, 76px); font-weight: 200; letter-spacing: -.04em; margin: 14px 0 18px; }
.app3-row p { color: var(--muted); max-width: 40ch; }
.app3-row .arrow-link { margin-top: 26px; }
@media (max-width: 760px) { .app3-row { grid-template-columns: 1fr; gap: 22px; } .app3-row:nth-child(even) .ap-pic { order: 0; } }

/* ============================================================
   CONTACTO
   ============================================================ */
.contact { padding-block: clamp(100px,18vh,240px) clamp(60px,8vh,120px); text-align: center; position: relative; }
.contact .kicker { margin-bottom: 28px; }
.contact h2 { font-size: clamp(44px, 11vw, 200px); font-weight: 200; letter-spacing: -.05em; line-height: .9; }
.contact h2 .accent { color: var(--accent); }
.contact .c-cta { margin-top: clamp(36px,5vw,60px); display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }
.contact .c-meta { margin-top: clamp(50px,7vw,90px); display: flex; justify-content: center; gap: clamp(24px,5vw,70px); flex-wrap: wrap; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: var(--muted); }
.contact .c-meta a:hover, .contact .c-meta span:hover { color: var(--text); }
.contact .c-meta b { color: var(--text); font-weight: 500; }

/* ============================================================
   FOOTER
   ============================================================ */
.foot { border-top: 1px solid var(--line); overflow: hidden; }
.foot-marq { padding: 26px 0; border-bottom: 1px solid var(--line); overflow: hidden; }
.foot-marq .t { display: flex; gap: 50px; width: max-content; animation: marq 26s linear infinite; }
.foot-marq .t span { font-size: clamp(28px,4vw,56px); font-weight: 200; letter-spacing: -.03em; color: var(--muted); display: inline-flex; gap: 50px; align-items: center; }
.foot-marq .t span::after { content: "→"; color: var(--accent); }
@keyframes marq { to { transform: translateX(-50%); } }
.foot-grid { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; padding: clamp(40px,5vw,70px) 0 26px; }
.foot-grid .word { font-size: clamp(40px,8vw,120px); font-weight: 200; letter-spacing: -.04em; }
.foot-grid .word img { height: clamp(40px, 7vw, 84px); width: auto; display: block; }
.foot-grid .word i { color: var(--accent); font-style: normal; }
.foot-col h5 { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); margin-bottom: 14px; }
.foot-col a, .foot-col p { display: block; color: var(--muted); font-size: 14px; padding: 4px 0; }
.foot-col a:hover { color: var(--accent); }
.foot-cols { display: flex; gap: clamp(30px,5vw,70px); flex-wrap: wrap; }
.foot-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 18px 0 30px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: 11px; letter-spacing: .08em; color: var(--faint); }

/* hero CTA */
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: clamp(34px, 4vw, 54px); }

/* floating whatsapp */
.wa-float { position: fixed; right: 22px; bottom: 22px; z-index: 360; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: rgba(17,20,25,.9); border: 1px solid var(--line-2); color: var(--text); backdrop-filter: blur(8px); transition: transform .35s var(--ease), background .3s, color .3s, border-color .3s; }
.wa-float::after { content: ""; position: absolute; top: 8px; right: 8px; width: 8px; height: 8px; border-radius: 50%; background: #25d366; box-shadow: 0 0 8px #25d366; }
.wa-float:hover { background: var(--accent); border-color: var(--accent); color: #fff; transform: translateY(-3px); }
.wa-float svg { width: 26px; height: 26px; }

/* modal */
html.cursor-on input, html.cursor-on textarea { cursor: text !important; }
.modal { position: fixed; inset: 0; z-index: 9400; display: none; align-items: center; justify-content: center; padding: 24px; }
.modal.open { display: flex; }
.modal-bg { position: absolute; inset: 0; background: rgba(4,5,7,.72); backdrop-filter: blur(6px); opacity: 0; transition: opacity .35s; }
.modal.open .modal-bg { opacity: 1; }
.modal-card { position: relative; z-index: 1; width: 100%; max-width: 520px; max-height: calc(100svh - 48px); overflow-y: auto; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 6px; padding: clamp(28px,4vw,46px); opacity: 0; transform: translateY(22px) scale(.98); transition: opacity .4s var(--ease), transform .4s var(--ease); }
.modal.open .modal-card { opacity: 1; transform: none; }
.modal-x { position: absolute; top: 16px; right: 16px; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: transparent; color: var(--text); font-size: 16px; cursor: pointer; transition: .25s; }
.modal-x:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.modal-title { font-size: clamp(30px,4.4vw,52px); font-weight: 200; letter-spacing: -.03em; margin: 14px 0 26px; }
.modal-form { display: flex; flex-direction: column; gap: 18px; }
.mf-row { display: flex; flex-direction: column; gap: 7px; }
.mf-row label { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.mf-row input, .mf-row textarea { background: transparent; border: 0; border-bottom: 1px solid var(--line-2); color: var(--text); font-family: var(--display); font-size: 16px; font-weight: 300; padding: 9px 2px; resize: none; transition: border-color .3s; }
.mf-row input::placeholder, .mf-row textarea::placeholder { color: var(--faint); }
.mf-row input:focus, .mf-row textarea:focus { outline: none; border-color: var(--accent); }
.mf-row input:focus-visible, .mf-row textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.modal-form .btn { margin-top: 10px; align-self: flex-start; }
.modal-ok { display: none; font-size: 18px; font-weight: 300; color: var(--text); }

/* cap accordion + indicator (desktop hides plus) */
.cap-plus { display: none; }

/* ============================================================
   PROYECTOS — mobile carousel
   ============================================================ */
.work-mobile { display: none; }
.wm-stage { position: relative; width: 100%; aspect-ratio: 3/4; border-radius: 6px; overflow: hidden; background: var(--panel); cursor: pointer; }
.wm-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s var(--ease); }
.wm-slide.on { opacity: 1; }
.wm-slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.03); transition: transform 5s ease-out; }
.wm-slide.on img { transform: scale(1.14); }
.wm-meta { display: flex; justify-content: space-between; align-items: baseline; margin-top: 14px; }
.wm-nm { font-family: var(--display); font-weight: 200; font-size: 22px; letter-spacing: -.02em; }
.wm-ix { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.wm-bar { height: 2px; background: var(--line); margin-top: 12px; position: relative; }
.wm-bar span { position: absolute; left: 0; top: 0; height: 100%; width: 0; background: var(--accent); box-shadow: 0 0 8px var(--accent-soft); }
.wm-dots { display: flex; gap: 6px; margin-top: 14px; flex-wrap: wrap; }
.wm-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--line-2); transition: .3s var(--ease); cursor: pointer; }
.wm-dots i.on { background: var(--accent); width: 20px; border-radius: 4px; }
@media (max-width: 760px) {
  .work-grid { display: none; }
  .work-mobile { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; }
  html.lib-on [data-rv], html.lib-on [data-clip] { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .cursor, .cursor-dot { display: none !important; }
  html.cursor-on, html.cursor-on * { cursor: auto !important; }
}

/* ============================================================
   APLICACIONES — acordeón automático
   ============================================================ */
.acc3 { display: flex; gap: 12px; height: clamp(440px, 64vh, 640px); }
.acc3-panel { position: relative; flex: 1 1 0; min-width: 0; overflow: hidden; border-radius: 4px; cursor: pointer; background: var(--panel); transition: flex-grow .8s var(--ease); }
.acc3-panel.is-active { flex-grow: 4.4; cursor: default; }
.acc3-panel img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); filter: grayscale(.5) brightness(.5); transition: transform 1.2s var(--ease), filter .7s var(--ease); }
.acc3-panel.is-active img { transform: scale(1); filter: grayscale(.08) brightness(.82); }
.acc3-tint { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(8,9,11,.94) 4%, rgba(8,9,11,.4) 55%, transparent 100%); }
.acc3-tab { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding-bottom: 30px; gap: 16px; opacity: 1; transition: opacity .35s var(--ease); }
.acc3-tab .k { font-family: var(--mono); font-size: 12px; color: var(--accent); }
.acc3-tab .v { writing-mode: vertical-rl; transform: rotate(180deg); font-weight: 200; font-size: clamp(20px, 1.6vw, 26px); letter-spacing: -.02em; white-space: nowrap; }
.acc3-panel.is-active .acc3-tab { opacity: 0; pointer-events: none; }
.acc3-body { position: absolute; left: 0; right: 0; bottom: 0; padding: clamp(26px, 3vw, 48px); max-width: 620px; opacity: 0; transform: translateY(18px); pointer-events: none; transition: opacity .55s .12s var(--ease), transform .65s .12s var(--ease); }
.acc3-panel.is-active .acc3-body { opacity: 1; transform: none; pointer-events: auto; }
.acc3-body .ai { font-family: var(--mono); font-size: 12px; color: var(--accent); letter-spacing: .12em; }
.acc3-body h3 { font-size: clamp(30px, 4vw, 62px); font-weight: 200; letter-spacing: -.04em; margin: 12px 0 14px; }
.acc3-body p { color: #c9ced8; max-width: 44ch; }
.acc3-body .arrow-link { margin-top: 20px; color: #fff; }
.acc3-prog { position: absolute; left: 0; bottom: 0; height: 2px; width: 0; background: var(--accent); z-index: 3; box-shadow: 0 0 10px var(--accent-soft); }
@media (max-width: 760px) {
  .acc3 { flex-direction: column; height: auto; gap: 10px; }
  .acc3-panel { flex: none; height: 84px; }
  .acc3-panel.is-active { flex: none; height: 380px; }
  .acc3-tab { flex-direction: row; justify-content: flex-start; align-items: center; padding: 0 22px; gap: 14px; }
  .acc3-tab .v { writing-mode: horizontal-tb; transform: none; }
  .hpin { height: auto; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .htrack { padding-block: 8px; }
  .hero-cta { width: 100%; gap: 10px; }
  .hero-cta .btn { flex: 1 1 auto; justify-content: center; height: 44px; padding: 0 16px; font-size: 13px; gap: 8px; }
  .hero-cta .btn svg { width: 14px; height: 14px; }
}
