/* =============================================================
   IMAGGIO STUDIO · styles.css
   Sobrio por fuera, tech por dentro.
   ============================================================= */

/* =============================================================
   1. Tokens (manual de marca v1.0)
   ============================================================= */
:root {
  --orange: #ff4d00;        /* acción, firma y acentos puntuales */
  --orange-deep: #a02d0c;   /* sólo degradados */
  --black: #0a0a0a;
  --white: #f6f5f2;
  --gray: #999999;
  --surface: #111111;
  --surface-2: #161616;
  --line: rgba(246, 245, 242, 0.1);
  --line-strong: rgba(246, 245, 242, 0.22);
  --text-soft: rgba(246, 245, 242, 0.8);

  --font: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --gutter: clamp(20px, 5vw, 88px);
  --nav-h: 60px;
  --radius: 8px;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --dur-ui: 240ms;
  --dur-in: 700ms;
}

/* =============================================================
   2. Reset y base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scrollbar-gutter: stable; overflow-x: clip; background: var(--black); color-scheme: dark; }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--white);
  background: var(--black);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; touch-action: manipulation; }
a { color: inherit; text-decoration: none; touch-action: manipulation; }
ul, ol { list-style: none; padding: 0; }
p { text-wrap: pretty; }
h1, h2, h3, h4 { font-weight: 500; text-wrap: balance; line-height: 1.1; letter-spacing: -0.02em; }
em { font-style: normal; }
::selection { background: var(--orange); color: var(--black); }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 4px; border-radius: 4px; }
[tabindex="-1"]:focus { outline: none; }
[hidden] { display: none !important; }
html.project-open body { overflow: hidden; }
svg path { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

/* Grano muy sutil */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.35;
  mix-blend-mode: overlay;
  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='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* =============================================================
   3. Utilidades
   ============================================================= */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: -100px; left: 16px; z-index: 300; padding: 10px 16px; background: var(--white); color: var(--black); border-radius: 8px; font-weight: 600; }
.skip-link:focus { top: 16px; }
.label { font-family: var(--mono); font-size: 12px; line-height: 1.4; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gray); }
.label-accent { color: var(--orange); }
.label-dim { color: rgba(153, 153, 153, 0.85); }
.accent { color: var(--orange); }
.badge {
  display: inline-flex; align-items: center;
  font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--gray); border: 1px solid var(--line-strong); border-radius: 999px; padding: 1px 8px; line-height: 1.6;
}
.line { display: block; overflow: hidden; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.line-inner { display: inline-block; }

/* =============================================================
   4. Botones y enlaces
   ============================================================= */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 48px; padding: 0 22px; border-radius: 999px;
  font-size: 14px; font-weight: 600; white-space: nowrap;
  transition: transform 160ms var(--ease-out), background-color var(--dur-ui) ease, color var(--dur-ui) ease, border-color var(--dur-ui) ease;
}
.btn-arrow { width: 15px; height: 15px; flex: none; transition: transform var(--dur-ui) var(--ease-out); }
.btn-arrow.flip { transform: scaleX(-1); }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--orange); color: var(--black); }
.btn-ghost { border: 1px solid var(--line-strong); color: var(--white); }
.btn-sm { height: 40px; padding: 0 16px; font-size: 13px; }
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover { background: #ff6a29; }
  .btn-ghost:hover { border-color: var(--white); }
  .btn:hover .btn-arrow:not(.flip) { transform: translateX(3px); }
  .btn:hover .btn-arrow.flip { transform: scaleX(-1) translateX(3px); }
}
.link-arrow {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px;
  font-weight: 600; font-size: 14px; color: var(--white);
  background: linear-gradient(currentColor, currentColor) 0 100% / 0% 1px no-repeat;
  transition: background-size 400ms var(--ease-out);
}
.link-arrow svg { width: 15px; height: 15px; color: var(--orange); transition: transform var(--dur-ui) var(--ease-out); }
@media (hover: hover) { .link-arrow:hover { background-size: 100% 1px; } .link-arrow:hover svg { transform: translateX(3px); } }
.icon-btn {
  width: 44px; height: 44px; flex: none; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--line-strong);
  transition: background-color var(--dur-ui) ease, border-color var(--dur-ui) ease, transform 160ms var(--ease-out);
}
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn:active { transform: scale(0.94); }
@media (hover: hover) { .icon-btn:hover { background: rgba(246, 245, 242, 0.06); border-color: var(--white); } }

/* =============================================================
   5. Intro: el símbolo i_ se arma
   ============================================================= */
.splash { display: none; }
.js .splash {
  position: fixed; inset: 0; z-index: 250; display: grid; place-items: center; background: var(--black);
  clip-path: inset(0 0 0 0);
  animation: splash-safety 0.01s 3.6s forwards;
}
.js.intro-seen .splash { display: none; }
.js .splash.is-out { clip-path: inset(0 0 100% 0); transition: clip-path 800ms var(--ease-in-out); }
@keyframes splash-safety { to { clip-path: inset(0 0 100% 0); visibility: hidden; } }
.splash-mark { position: relative; width: 96px; height: 96px; }
.splash-mark span { position: absolute; display: block; }
.mark-dot { left: 20.25px; top: 9px; width: 12px; height: 12px; background: var(--orange); animation: mark-dot 520ms var(--ease-out) 120ms both; }
.mark-bar { left: 21.75px; top: 36px; width: 10.5px; height: 39px; background: var(--white); transform-origin: 50% 100%; animation: mark-bar 640ms var(--ease-expo) 260ms both; }
.mark-under { left: 39px; top: 77.25px; width: 37.5px; height: 9px; background: var(--orange); transform-origin: 0 50%; animation: mark-under 560ms var(--ease-expo) 620ms both, blink 0.42s steps(1) 1.2s 2; }
.splash.is-out .splash-mark { transform: translateY(-24px); opacity: 0; transition: transform 700ms var(--ease-in-out), opacity 500ms ease; }
@keyframes mark-dot { from { opacity: 0; transform: translateY(-18px); } }
@keyframes mark-bar { from { transform: scaleY(0); } }
@keyframes mark-under { from { transform: scaleX(0); } }
@keyframes blink { 50% { opacity: 0; } }

/* =============================================================
   6. Progreso y cursor
   ============================================================= */
.scroll-progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 70; pointer-events: none; }
.scroll-progress span { display: block; height: 100%; background: var(--orange); transform-origin: 0 50%; transform: scaleX(0); }

.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor { display: block; position: fixed; left: 0; top: 0; z-index: 260; pointer-events: none; opacity: 0; transition: opacity 300ms ease; }
  .cursor.is-ready { opacity: 1; }
  .cursor.is-off { opacity: 0; }
  html.has-cursor, html.has-cursor a, html.has-cursor button, html.has-cursor label { cursor: none; }
  html.has-cursor input, html.has-cursor textarea { cursor: text; }
}
.cursor-dot { position: absolute; left: -4px; top: -4px; width: 8px; height: 8px; background: #ffffff; transition: opacity 200ms ease; }
.cursor-ring { position: absolute; left: -40px; top: -40px; width: 80px; height: 80px; }
.cursor-shape {
  display: grid; place-items: center; width: 100%; height: 100%;
  border: 1.5px solid rgba(246, 245, 242, 0.3);
  transform: scale(0.42);
  transition: transform 420ms var(--ease-out), background-color 300ms ease, border-color 300ms ease;
}
.cursor-label { font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--black); opacity: 0; transition: opacity 200ms ease; }
.cursor.is-link .cursor-shape { transform: scale(0.6); border-color: rgba(246, 245, 242, 0.7); }
.cursor.is-view .cursor-shape { transform: scale(1); background: var(--white); border-color: var(--white); }
.cursor.is-view .cursor-label { opacity: 1; transition-delay: 80ms; }
.cursor.is-view .cursor-dot { opacity: 0; }
.cursor.is-down .cursor-shape { transform: scale(0.34); }
.cursor.is-view.is-down .cursor-shape { transform: scale(0.9); }

/* =============================================================
   7. Navegación
   ============================================================= */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 60;
  height: var(--nav-h);
  display: flex; align-items: center; gap: 28px;
  padding: 0 var(--gutter);
  border-bottom: 1px solid transparent;
  transition: background-color 300ms ease, border-color 300ms ease;
}
.nav.is-scrolled { background: rgba(10, 10, 10, 0.92); border-bottom-color: var(--line); }
@supports (backdrop-filter: blur(12px)) {
  .nav.is-scrolled { background: rgba(10, 10, 10, 0.72); backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%); }
}
.nav-logo { display: flex; align-items: center; height: 44px; flex: none; transition: opacity 400ms var(--ease-out), transform 400ms var(--ease-out); }
.nav-logo img { width: 108px; height: auto; }
.at-hero .nav-logo { opacity: 0; transform: translateY(-6px); pointer-events: none; }
.nav-links { display: none; margin-left: auto; gap: 30px; }
.nav-links a { position: relative; padding: 8px 0; font-size: 14px; font-weight: 500; color: rgba(246, 245, 242, 0.68); transition: color var(--dur-ui) ease; }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: var(--white);
  transform: scaleX(0); transform-origin: 100% 50%; transition: transform 360ms var(--ease-out);
}
.nav-links a:hover, .nav-links a.is-active { color: var(--white); }
.nav-links a:hover::after, .nav-links a.is-active::after { transform: scaleX(1); transform-origin: 0 50%; }
.nav-cta { display: none; height: 38px; padding: 0 16px; font-size: 13px; }

.nav-toggle { margin-left: auto; display: inline-flex; align-items: center; gap: 12px; height: 44px; padding: 0 2px; position: relative; z-index: 2; }
.nav-toggle-label { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; }
.nav-toggle-icon { position: relative; width: 22px; height: 10px; }
.nav-toggle-icon i { position: absolute; left: 0; right: 0; height: 1.5px; background: var(--white); transition: transform 400ms var(--ease-out); }
.nav-toggle-icon i:first-child { top: 0; }
.nav-toggle-icon i:last-child { bottom: 0; left: 8px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon i:first-child { transform: translateY(4.25px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon i:last-child { transform: translateY(-4.25px) rotate(-45deg); left: 0; }
.menu-open .nav { background: transparent; border-bottom-color: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
.menu-open .nav-logo { opacity: 1; transform: none; pointer-events: auto; }

.menu {
  position: fixed; inset: 0; z-index: 55;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--nav-h) + 5vh) var(--gutter) 28px;
  background: var(--black);
  clip-path: inset(0 0 100% 0);
  transition: clip-path 600ms var(--ease-in-out);
}
.menu[hidden] { display: none; }
.menu.is-open { clip-path: inset(0 0 0 0); }
.menu li { overflow: hidden; border-bottom: 1px solid var(--line); }
.menu a {
  display: flex; align-items: baseline; gap: 16px; padding: 14px 0;
  font-size: clamp(1.9rem, 9vw, 3rem); font-weight: 500; letter-spacing: -0.03em; line-height: 1.15;
  transform: translateY(100%); transition: transform 650ms var(--ease-expo);
}
.menu.is-open a { transform: none; }
.menu.is-open li:nth-child(2) a { transition-delay: 40ms; }
.menu.is-open li:nth-child(3) a { transition-delay: 80ms; }
.menu.is-open li:nth-child(4) a { transition-delay: 120ms; }
.menu.is-open li:nth-child(5) a { transition-delay: 160ms; }
.menu-foot { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gray); }

/* =============================================================
   8. Inicio
   ============================================================= */
.hero {
  position: relative; isolation: isolate;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: var(--nav-h) var(--gutter) 48px;
  text-align: center;
  overflow: clip;
}
.hero-ambient { position: absolute; inset: 0; z-index: -2; background: var(--black); }
/* Respaldo sin WebGL: dos masas de luz que se mueven */
.hero-ambient::before {
  content: ""; position: absolute; inset: -25%;
  background:
    radial-gradient(30% 34% at 32% 40%, rgba(255, 77, 0, 0.7), transparent 70%),
    radial-gradient(26% 30% at 68% 62%, rgba(160, 45, 12, 0.75), transparent 70%);
  filter: blur(30px);
  animation: ambient-drift 9s ease-in-out infinite alternate;
}
@keyframes ambient-drift {
  0% { transform: translate3d(0, 0, 0) scale(1) rotate(0deg); }
  50% { transform: translate3d(-6%, 4%, 0) scale(1.1) rotate(8deg); }
  100% { transform: translate3d(5%, -3%, 0) scale(0.95) rotate(-6deg); }
}
.hero-canvas { position: relative; z-index: 1; width: 100%; height: 100%; opacity: 0; transition: opacity 1.4s ease; }
.hero-canvas.is-on { opacity: 1; }
.hero-ambient::after { content: ""; position: absolute; z-index: 2; inset: auto 0 0 0; height: 28%; background: linear-gradient(to bottom, transparent, var(--black)); }

.hero-center { position: relative; display: flex; flex-direction: column; align-items: center; width: 100%; }
.hero-tag { font-size: 11px; letter-spacing: 0.3em; margin-right: -0.3em; color: var(--white); }
.hero-logo { margin: clamp(22px, 4vh, 40px) 0 0; font: inherit; width: min(78vw, 820px); }
.hero-logo img { width: 100%; height: auto; }
.hero-slogan { margin-top: clamp(22px, 4vh, 40px); font-size: clamp(1.15rem, 2.2vw, 1.75rem); font-weight: 500; line-height: 1.2; letter-spacing: -0.02em; }

/* Entrada del inicio */
.js .hero-logo { opacity: 0; transform: translateY(18px) scale(0.985); filter: blur(6px); }
.js.is-loaded .hero-logo { opacity: 1; transform: none; filter: none; transition: opacity 900ms ease 120ms, transform 1100ms var(--ease-expo) 120ms, filter 900ms ease 120ms; }
.js [data-hero-item] { opacity: 0; transform: translateY(12px); }
.js.is-loaded [data-hero-item] { opacity: 1; transform: none; transition: opacity var(--dur-in) var(--ease-out), transform var(--dur-in) var(--ease-out); }
.js.is-loaded .hero-slogan[data-hero-item] { transition-delay: 420ms; }

.pause-toggle { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--white); transition: color var(--dur-ui) ease; }
.pause-icon { position: relative; width: 10px; height: 10px; }
.pause-icon::before, .pause-icon::after { content: ""; position: absolute; top: 0; width: 3px; height: 10px; background: currentColor; }
.pause-icon::before { left: 1px; }
.pause-icon::after { right: 1px; }
.is-paused .pause-icon::before { width: 0; height: 0; border-left: 9px solid var(--orange); border-top: 5px solid transparent; border-bottom: 5px solid transparent; background: none; left: 1px; }
.is-paused .pause-icon::after { display: none; }
@media (hover: hover) { .pause-toggle:hover { color: var(--orange); } }

/* =============================================================
   9. Secciones
   ============================================================= */
.section { position: relative; padding: clamp(64px, 7vw, 112px) var(--gutter); }
.section-head { margin-bottom: clamp(32px, 4vw, 56px); }
.section-head.split { display: grid; gap: 20px; }
.kicker { font-family: var(--mono); font-size: clamp(15px, 1.25vw, 18px); font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--orange); line-height: 1.3; }
.section-title { margin-top: 16px; font-size: clamp(1.9rem, 3.8vw, 3.2rem); font-weight: 500; line-height: 1.08; letter-spacing: -0.035em; }
.section-note { max-width: 40ch; font-size: 15px; line-height: 1.7; color: var(--gray); }

.js [data-reveal] {
  opacity: 0; transform: translateY(16px);
  transition: opacity var(--dur-in) var(--ease-out), transform var(--dur-in) var(--ease-out);
  transition-delay: calc(var(--i, 0) * 80ms);
}
.js [data-reveal].is-revealed { opacity: 1; transform: none; }

/* ---------- 01 Servicios: lista minimalista ---------- */
.service-list { border-top: 1px solid var(--line); }
.service { border-bottom: 1px solid var(--line); }
.service-heading { font: inherit; letter-spacing: normal; }
.service-head {
  width: 100%; display: grid; grid-template-columns: 36px 1fr 32px; align-items: center; gap: 4px 16px;
  padding: 22px 0; text-align: left;
}
.service-num { align-self: start; padding-top: 0.35em; color: var(--gray); }
.service-title { font-size: clamp(1.15rem, 1.8vw, 1.45rem); font-weight: 500; letter-spacing: -0.015em; line-height: 1.3; transition: color var(--dur-ui) ease; }
.service-short { grid-column: 2; font-size: 14px; line-height: 1.6; color: var(--gray); }
.service-icon { grid-column: 3; grid-row: 1; position: relative; width: 32px; height: 32px; justify-self: end; }
.service-icon::before, .service-icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; margin: -0.75px 0 0 -6px; background: currentColor; transition: transform 380ms var(--ease-out), opacity 300ms ease; }
.service-icon::after { transform: rotate(90deg); }
.service.is-open .service-icon::after { transform: rotate(0deg); opacity: 0; }
@media (hover: hover) and (pointer: fine) { .service-head:hover .service-title { color: var(--orange); } }
.service-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 520ms var(--ease-out); }
.service.is-open .service-panel { grid-template-rows: 1fr; }
.service-panel-inner { overflow: hidden; min-height: 0; padding-left: 52px; }
.service-panel-inner > * { opacity: 0; transition: opacity 240ms ease; }
.service.is-open .service-panel-inner > * { opacity: 1; transition: opacity 500ms ease 120ms; }
.service-panel-inner > :last-child { margin-bottom: 28px; }
.service-desc { max-width: 58ch; font-size: 15px; line-height: 1.7; color: var(--text-soft); }
.service-cols { display: grid; gap: 24px; margin: 22px 0 14px; }
.service-cols .label { margin-bottom: 8px; }
.ticks li { display: flex; align-items: baseline; gap: 12px; padding: 7px 0; font-size: 14px; color: var(--text-soft); }
.ticks li::before { content: ""; flex: none; width: 10px; height: 1px; background: var(--gray); transform: translateY(-4px); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { font-family: var(--mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; padding: 5px 11px; border: 1px solid var(--line-strong); border-radius: 999px; color: var(--text-soft); }

/* ---------- 02 Trabajos ---------- */
.works-bar {
  position: sticky; top: var(--nav-h); z-index: 20;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px;
  margin: 0 calc(var(--gutter) * -1) clamp(24px, 3vw, 40px);
  padding: 10px var(--gutter);
  border-bottom: 1px solid transparent;
  transition: background-color 250ms ease, border-color 250ms ease;
}
.works-bar.is-stuck { background: rgba(10, 10, 10, 0.94); border-bottom-color: var(--line); }
@supports (backdrop-filter: blur(12px)) {
  .works-bar.is-stuck { background: rgba(10, 10, 10, 0.74); backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%); }
}
.filters { display: flex; flex-wrap: nowrap; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: -4px; padding: 4px; min-width: 0; max-width: 100%; }
.filters::-webkit-scrollbar { display: none; }
.filters button {
  flex: none; height: 36px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line-strong); font-size: 13px; font-weight: 500; color: rgba(246, 245, 242, 0.75);
  transition: background-color var(--dur-ui) ease, color var(--dur-ui) ease, border-color var(--dur-ui) ease, transform 160ms var(--ease-out);
}
.filters button[aria-pressed="true"] { background: var(--white); border-color: var(--white); color: var(--black); }
.filters button:active { transform: scale(0.96); }
@media (hover: hover) { .filters button:hover:not([aria-pressed="true"]) { border-color: var(--white); color: var(--white); } }
.works-count { display: none; flex: none; }
.rubro-filter { position: relative; flex: none; display: inline-flex; }
.rubro-filter::after { content: ""; position: absolute; right: 15px; top: 50%; width: 6px; height: 6px; margin-top: -5px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); pointer-events: none; color: var(--gray); }
.rubro-filter select {
  appearance: none; -webkit-appearance: none;
  height: 36px; padding: 0 38px 0 16px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: transparent; color: rgba(246, 245, 242, 0.85);
  font: 500 13px/1 var(--font); cursor: pointer;
  transition: border-color var(--dur-ui) ease, background-color var(--dur-ui) ease, color var(--dur-ui) ease;
}
.rubro-filter select option { background: var(--surface); color: var(--white); }
.rubro-filter select:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
.rubro-filter.is-active select { background: var(--white); border-color: var(--white); color: var(--black); }
.rubro-filter.is-active::after { color: var(--black); }
@media (hover: hover) { .rubro-filter select:hover { border-color: var(--white); } }
.works-none { padding: 32px 0; border-top: 1px solid var(--line); color: var(--gray); }
.works-none p { margin-bottom: 4px; }

.works, .shelves { overflow-anchor: none; }
.shelves { --row-h: clamp(220px, 58vw, 300px); display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(48px, 5vw, 80px); transition: opacity 320ms ease, transform 420ms var(--ease-out); }
.shelves > * { min-width: 0; }
.shelves.is-switching { opacity: 0; transform: translateY(10px); transition-duration: 180ms; }
.works-empty { color: var(--gray); padding: 40px 0; border-top: 1px solid var(--line); }

.shelf-head { display: grid; grid-template-columns: auto 1fr; align-items: end; gap: 8px 16px; margin-bottom: 16px; }
.shelf-num { align-self: start; padding-top: 0.35em; }
.shelf-title { font-size: clamp(1.2rem, 1.9vw, 1.55rem); font-weight: 500; letter-spacing: -0.02em; line-height: 1.2; }
.shelf-sub { margin-top: 4px; color: var(--gray); font-size: 14px; line-height: 1.5; max-width: 52ch; }
.shelf-side { grid-column: 1 / -1; display: flex; align-items: center; justify-content: flex-end; gap: 16px; }
.shelf-nav { display: none; gap: 8px; }
.shelf-nav .icon-btn { width: 38px; height: 38px; }
.shelf-nav .icon-btn[disabled] { opacity: 0.25; pointer-events: none; }
.shelf-nav .flip svg { transform: scaleX(-1); }
.shelf-track {
  display: flex; gap: clamp(12px, 1.4vw, 20px);
  margin: 0 calc(var(--gutter) * -1);
  padding: 4px var(--gutter) 18px;
  overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
  scrollbar-width: none;
}
.shelf-track::-webkit-scrollbar { display: none; }
.shelf-track .work { flex: none; width: min-content; scroll-snap-align: start; }
.shelf-track .work-media { width: min(calc(var(--row-h) * var(--ar, 0.8)), 78vw); height: auto; aspect-ratio: var(--ar, 0.8); }
.shelf-track.is-dragging { scroll-snap-type: none; cursor: grabbing; user-select: none; }
.shelf-track.is-dragging .work { pointer-events: none; }
.shelf-progress { position: relative; height: 1px; background: var(--line); overflow: hidden; opacity: 0; transition: opacity 300ms ease; }
.shelf.has-overflow .shelf-progress { opacity: 1; }
.shelf-progress span { position: absolute; left: 0; top: 0; height: 100%; width: 30%; background: var(--white); }
.shelves.is-filtered .shelf-nav, .shelves.is-filtered .shelf-progress { display: none; }
.shelves.is-filtered .shelf-track { flex-wrap: wrap; row-gap: clamp(28px, 3vw, 44px); margin: 0; padding: 4px 0 0; overflow: visible; scroll-snap-type: none; cursor: auto; }
.shelves.is-filtered .shelf-track .work-media { max-width: 100%; }

/* Tarjeta */
.work { display: block; width: 100%; text-align: left; }
.work-media { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--surface); aspect-ratio: var(--ar, 0.8); }
.work-media img, .work-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1000ms var(--ease-out), opacity 500ms ease; }
.work-media video { opacity: 0; }
.work.is-playing .work-media video { opacity: 1; }
.work-media::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(246, 245, 242, 0.06); pointer-events: none; }
.work-chips { position: absolute; left: 10px; top: 10px; z-index: 1; display: flex; flex-wrap: wrap; gap: 6px; pointer-events: none; }
.work-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; background: rgba(10, 10, 10, 0.7); font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--white); }
.work-stack { position: relative; width: 10px; height: 10px; border: 1.5px solid currentColor; border-radius: 2px; margin: 2px 3px 0 0; }
.work-stack::after { content: ""; position: absolute; left: 2px; top: -5px; width: 10px; height: 10px; border-top: 1.5px solid currentColor; border-right: 1.5px solid currentColor; border-radius: 0 2px 0 0; }
.work-play { display: inline-block; width: 0; height: 0; border-left: 7px solid var(--white); border-top: 4.5px solid transparent; border-bottom: 4.5px solid transparent; }
.work-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-top: 12px; }
.work-title { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 500; letter-spacing: -0.01em; line-height: 1.3; }
.work-title svg { width: 13px; height: 13px; color: var(--gray); opacity: 0; transform: translate(-6px, 3px); transition: opacity 300ms ease, transform 400ms var(--ease-out); }
.work-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 3px; font-size: 13px; color: var(--gray); }
.work-sub .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--line-strong); }
.shelf-track .work-sub .dot, .shelf-track .work-cat { display: none; }
.work-meta > .label { font-size: 11px; }
@media (hover: hover) and (pointer: fine) { .work:hover .work-title svg { opacity: 1; transform: none; } }
.work:focus-visible { outline-offset: 6px; }
.work:focus-visible .work-title svg { opacity: 1; transform: none; }

.js .work .work-media { clip-path: inset(100% 0 0 0 round var(--radius)); }
.js .work .work-media :is(img, video) { transform: scale(1.15); }
.js .work .work-meta { opacity: 0; transform: translateY(10px); }
.js .work.is-revealed .work-media { clip-path: inset(0 0 0 0 round var(--radius)); transition: clip-path 1100ms var(--ease-expo) var(--d, 0ms); }
.js .work.is-revealed .work-media :is(img, video) { transform: scale(1); transition: transform 1300ms var(--ease-out) var(--d, 0ms), opacity 500ms ease; }
.js .work.is-revealed .work-meta { opacity: 1; transform: none; transition: opacity var(--dur-in) ease calc(var(--d, 0ms) + 200ms), transform var(--dur-in) var(--ease-out) calc(var(--d, 0ms) + 200ms); }
@media (hover: hover) and (pointer: fine) {
  .js .work.is-revealed:hover .work-media :is(img, video) { transform: scale(1.035); transition: transform 1000ms var(--ease-out), opacity 500ms ease; }
}

/* Destacado (opcional desde el admin) */
.works-featured { margin-bottom: clamp(8px, 2vw, 24px); }
.works-featured .work-featured { display: grid; gap: 18px; }
.work-featured .work-media { width: 100%; max-height: 48vh; }
.work-featured .work-meta { margin-top: 0; }
.work-featured .work-title { font-size: clamp(1.5rem, 2.6vw, 2.2rem); letter-spacing: -0.03em; }
.work-kicker { margin-bottom: 10px; }
.work-desc { margin-top: 14px; max-width: 42ch; color: var(--text-soft); font-size: 15px; line-height: 1.65; }
.work-cta { margin-top: 12px; }

.works-note { margin-top: clamp(40px, 5vw, 64px); display: flex; flex-wrap: wrap; align-items: center; gap: 8px; text-transform: none; letter-spacing: 0.02em; font-size: 12.5px; }

/* ---------- 04 Proceso ---------- */
.steps { position: relative; padding-left: 30px; }
.steps-track { position: absolute; left: 4px; top: 6px; bottom: 6px; width: 1px; background: var(--line-strong); }
.steps-track span { position: absolute; inset: 0; background: var(--white); transform-origin: 50% 0; transform: scaleY(0); }
.steps-list { display: grid; gap: 40px; }
.step { position: relative; }
.step-node { position: absolute; left: -30px; top: 3px; width: 9px; height: 9px; background: var(--black); border: 1px solid var(--gray); transition: background-color 300ms ease, border-color 300ms ease; }
.step.is-active .step-node, .no-js .step-node { background: var(--orange); border-color: var(--orange); }
.step h3 { margin: 12px 0 8px; font-size: clamp(1.1rem, 1.6vw, 1.35rem); letter-spacing: -0.015em; }
.step p { color: var(--gray); max-width: 30ch; font-size: 15px; }

/* ---------- 05 Contacto (oscuro, sobrio) ---------- */
.contact { position: relative; display: grid; gap: 56px; padding: clamp(72px, 8vw, 128px) var(--gutter); background: var(--surface); border-top: 1px solid var(--line); }
.contact-title { margin-top: 18px; font-size: clamp(2.2rem, 5vw, 4.2rem); font-weight: 600; line-height: 1.02; letter-spacing: -0.045em; }
.contact-lead { margin-top: 20px; max-width: 34ch; font-size: clamp(1rem, 1.3vw, 1.15rem); line-height: 1.6; color: var(--text-soft); }
.contact-direct { margin-top: 40px; border-top: 1px solid var(--line); max-width: 480px; }
.contact-direct li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.contact-direct a { font-weight: 500; font-size: clamp(0.98rem, 1.2vw, 1.1rem); min-height: 44px; display: inline-flex; align-items: center; overflow-wrap: anywhere; text-align: right; background: linear-gradient(currentColor, currentColor) 100% 80% / 0% 1px no-repeat; transition: background-size 400ms var(--ease-out), color var(--dur-ui) ease; }
@media (hover: hover) { .contact-direct a:hover { color: var(--orange); background-size: 100% 1px; background-position: 0 80%; } }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 24px; }
.field > label, .chips legend { font-family: var(--mono); font-size: 11.5px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gray); }
.field input, .field textarea {
  width: 100%; padding: 10px 0 12px; border: 0; border-bottom: 1px solid var(--line-strong); border-radius: 0; background: transparent;
  font: 500 17px/1.4 var(--font); color: var(--white); transition: border-color 200ms ease, box-shadow 200ms ease;
}
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus-visible, .field textarea:focus-visible { outline: none; border-bottom-color: var(--white); box-shadow: 0 1px 0 0 var(--white); }
.field.has-error input, .field.has-error textarea { border-bottom-color: var(--orange); box-shadow: 0 1px 0 0 var(--orange); }
.field-error { font-size: 13px; font-weight: 600; line-height: 1.4; color: var(--orange); }
.chips { border: 0; padding: 0; margin-bottom: 26px; display: flex; flex-direction: row; flex-wrap: wrap; gap: 8px; }
.chips legend { margin-bottom: 12px; padding: 0; float: left; width: 100%; }
.chips label { position: relative; font-family: var(--font); text-transform: none; letter-spacing: normal; }
.chips input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chips span { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 999px; font-size: 14px; font-weight: 500; transition: background-color 220ms ease, color 220ms ease, border-color 220ms ease, transform 160ms var(--ease-out); }
.chips label:active span { transform: scale(0.96); }
.chips input:checked + span { background: var(--white); border-color: var(--white); color: var(--black); }
.chips input:focus-visible + span { outline: 2px solid var(--orange); outline-offset: 3px; }
@media (hover: hover) { .chips label:hover input:not(:checked) + span { border-color: var(--white); } }
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.field-opt { text-transform: none; letter-spacing: 0; color: rgba(153, 153, 153, 0.7); }
.field input::placeholder { color: rgba(246, 245, 242, 0.28); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-form { position: relative; }
.btn[aria-busy="true"] { opacity: 0.75; pointer-events: none; }
.contact-form.is-sent > :not(.form-done) { visibility: hidden; }
.form-done { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 10px; outline: none; }
.form-done:not([hidden]) { animation: done-in 600ms var(--ease-out) both; }
.form-done h3 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); font-weight: 600; letter-spacing: -0.03em; }
.form-done p { color: var(--text-soft); max-width: 36ch; }
.form-done-mark { width: 14px; height: 14px; background: var(--orange); margin-bottom: 6px; }
@keyframes done-in { from { opacity: 0; transform: translateY(12px); } }
.form-status { margin-top: 16px; font-weight: 500; font-size: 15px; min-height: 1.5em; max-width: 52ch; color: var(--text-soft); }
.form-status a { text-decoration: underline; text-underline-offset: 3px; }

/* =============================================================
   10. Pie
   ============================================================= */
.footer { position: relative; padding: clamp(64px, 7vw, 104px) var(--gutter) 24px; }
.footer-top { display: grid; gap: 40px; padding-bottom: clamp(40px, 5vw, 64px); }
.footer-logo { width: clamp(180px, 22vw, 300px); height: auto; }
.footer-nav { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; }
.footer-nav a { min-height: 36px; display: inline-flex; align-items: center; font-size: 15px; font-weight: 500; color: rgba(246, 245, 242, 0.7); transition: color var(--dur-ui) ease; }
@media (hover: hover) { .footer-nav a:hover { color: var(--white); } }
.footer-meta { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; padding-top: 20px; border-top: 1px solid var(--line); }
.to-top { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--white); }
.to-top svg { width: 14px; height: 14px; transition: transform 300ms var(--ease-out); }
@media (hover: hover) { .to-top:hover svg { transform: translateY(-3px); } }

/* =============================================================
   11. Ventana de proyecto con carrusel
   ============================================================= */
.project { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: transparent; color: var(--white); overflow: hidden; }
.project::backdrop { background: rgba(10, 10, 10, 0.85); opacity: 0; transition: opacity 300ms ease; }
.project.is-open::backdrop { opacity: 1; }
.project-shell {
  position: absolute; inset: 0; display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
  background: #0f0f0f; opacity: 0; transform: translateY(14px) scale(0.99);
  transition: opacity 300ms var(--ease-out), transform 320ms var(--ease-out);
}
.project.is-open .project-shell { opacity: 1; transform: none; }
.project.is-closing .project-shell { opacity: 0; transform: translateY(8px) scale(0.99); transition-duration: 200ms; }
.project-visual { flex: none; display: flex; flex-direction: column; background: #0b0b0b; }
.project-stage { position: relative; height: 58vh; overflow: hidden; touch-action: pan-y; transition: opacity 180ms ease; }
.project-stage.is-swapping { opacity: 0; }
.project-media { position: absolute; inset: 0; }
.project-media > img, .project-media > video, .project-media > .compare { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.stage-btn {
  position: absolute; top: 50%; z-index: 3; width: 44px; height: 44px; margin-top: -22px;
  display: grid; place-items: center; border-radius: 50%;
  background: rgba(10, 10, 10, 0.55); border: 1px solid var(--line-strong); color: var(--white);
  transition: background-color var(--dur-ui) ease, transform 160ms var(--ease-out);
}
.stage-btn svg { width: 16px; height: 16px; }
.stage-btn:active { transform: scale(0.94); }
.stage-prev { left: 12px; }
.stage-next { right: 12px; }
@media (hover: hover) { .stage-btn:hover { background: rgba(10, 10, 10, 0.85); } }
.stage-count { position: absolute; left: 50%; bottom: 12px; z-index: 3; transform: translateX(-50%); padding: 4px 10px; border-radius: 999px; background: rgba(10, 10, 10, 0.6); color: var(--white); font-variant-numeric: tabular-nums; }
.project-thumbs { display: flex; gap: 8px; padding: 12px var(--gutter); overflow-x: auto; scrollbar-width: thin; border-top: 1px solid var(--line); }
.project-thumb { position: relative; flex: none; width: 60px; height: 60px; border-radius: 6px; overflow: hidden; background: var(--surface); outline: 1px solid transparent; outline-offset: 2px; opacity: 0.5; transition: opacity 200ms ease, outline-color 200ms ease, transform 160ms var(--ease-out); }
.project-thumb img, .project-thumb video { width: 100%; height: 100%; object-fit: cover; }
.project-thumb[aria-current="true"] { opacity: 1; outline-color: var(--white); }
.project-thumb:active { transform: scale(0.95); }
.project-thumb .work-play { position: absolute; left: 50%; top: 50%; margin: -4.5px 0 0 -3px; }
.thumb-tag { position: absolute; inset: auto 0 0 0; padding: 2px 0; background: rgba(10, 10, 10, 0.75); font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-align: center; }
@media (hover: hover) { .project-thumb:hover { opacity: 1; } }

.compare { --pos: 50%; overflow: hidden; }
.compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.compare-before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare input { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.compare-line { position: absolute; top: 0; bottom: 0; left: var(--pos); z-index: 1; width: 2px; margin-left: -1px; background: var(--white); pointer-events: none; }
.compare-line::after { content: ""; position: absolute; left: 50%; top: 50%; width: 38px; height: 38px; margin: -19px 0 0 -19px; border-radius: 50%; background: var(--white); }
.compare-line::before { content: ""; position: absolute; left: 50%; top: 50%; z-index: 1; width: 12px; height: 8px; margin: -4px 0 0 -6px; background: linear-gradient(90deg, var(--black) 0 2px, transparent 2px 10px, var(--black) 10px); }
.compare input:focus-visible + .compare-line::after { outline: 2px solid var(--orange); outline-offset: 3px; }
.compare-tag { position: absolute; top: 12px; left: 12px; z-index: 1; padding: 4px 10px; border-radius: 999px; background: rgba(10, 10, 10, 0.7); color: var(--white); pointer-events: none; }
.compare-tag-after { left: auto; right: 12px; }

.project-info { display: flex; flex-direction: column; gap: 20px; padding: 22px var(--gutter) 26px; }
.project-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.project-title { font-size: clamp(1.7rem, 2.8vw, 2.5rem); font-weight: 500; letter-spacing: -0.03em; line-height: 1.08; }
.project-badge { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 13.5px; color: var(--gray); }
.project-sheet { display: grid; grid-template-columns: minmax(96px, 116px) 1fr; border-top: 1px solid var(--line); }
.project-sheet dt, .project-sheet dd { padding: 12px 0; border-bottom: 1px solid var(--line); }
.project-sheet dt { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gray); padding-top: 15px; }
.project-sheet dd { font-size: 15px; line-height: 1.6; color: var(--text-soft); }
.project-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.project-share svg { color: var(--gray); }
.project-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); }

/* =============================================================
   12. Responsive (mobile-first)
   ============================================================= */
@media (min-width: 720px) {
  .works-count { display: block; }
  .shelf-head { grid-template-columns: 52px 1fr auto; }
  .shelf-side { grid-column: auto; flex-direction: column; align-items: flex-end; justify-content: flex-end; gap: 12px; }
  .service-cols { grid-template-columns: 1.3fr 1fr; gap: 40px; }
}

@media (min-width: 960px) {
  :root { --nav-h: 68px; }
  .nav-logo img { width: 120px; }
  .nav-links { display: flex; }
  .nav-cta { display: inline-flex; }
  .nav-toggle { display: none; }
  .menu { display: none !important; }

  .section-head.split { grid-template-columns: 1.4fr 1fr; align-items: end; gap: 40px; }
  .section-head.split > :last-child { justify-self: end; }

  .service-head { grid-template-columns: 64px minmax(0, 1fr) minmax(0, 1fr) 32px; padding: 26px 0; }
  .service-short { grid-column: 3; grid-row: 1; }
  .service-icon { grid-column: 4; }
  .service-panel-inner { padding-left: 80px; padding-right: 48px; }
  .service-panel-inner .service-cols { max-width: 820px; }

  .shelves { --row-h: clamp(230px, 17vw, 300px); }

  .works-featured .work-featured { grid-template-columns: auto minmax(280px, 1fr); align-items: end; gap: clamp(32px, 4vw, 64px); }
  .work-featured .work-media { width: auto; height: min(46vh, 420px); max-height: none; max-width: 52vw; }

  .steps { padding-left: 0; padding-top: 42px; }
  .steps-track { left: 0; right: 0; top: 4px; bottom: auto; width: auto; height: 1px; }
  .steps-track span { transform-origin: 0 50%; transform: scaleX(0); }
  .steps-list { grid-template-columns: repeat(4, 1fr); gap: 28px; }
  .step-node { left: 0; top: -42px; }

  .contact { grid-template-columns: 1fr 1fr; column-gap: 7vw; align-items: start; }
  .contact-form { padding-top: 40px; }

  .footer-top { grid-template-columns: 1.5fr 1fr 1fr; align-items: start; }

  .project-shell { inset: 24px; flex-direction: row; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; }
  .project-visual { flex: 1.6; min-width: 0; height: 100%; }
  .project-stage { flex: 1; height: auto; min-height: 0; }
  .project-thumbs { padding: 12px 18px; }
  .project-info { flex: 1; min-width: 340px; max-width: 480px; overflow-y: auto; padding: 28px 36px; }
  .stage-prev { left: 18px; }
  .stage-next { right: 18px; }
}

@media (min-width: 1280px) {
  .service-head { grid-template-columns: 80px minmax(0, 1.1fr) minmax(0, 1fr) 32px; }
  .service-panel-inner { padding-left: 96px; }
}

@media (hover: hover) and (pointer: fine) {
  .shelf-nav { display: flex; }
  .shelf:not(.has-overflow) .shelf-nav { visibility: hidden; }
  .shelf-track { cursor: grab; }
}

/* =============================================================
   13. Pausa y movimiento reducido
   ============================================================= */
.is-paused .hero-ambient::before { animation-play-state: paused; }

@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { transform: none; }
  .js [data-hero-item], .js .hero-logo { transform: none; filter: none; }
  .hero-ambient::before { animation-duration: 40s; }
  .mark-under { animation: none; }
  .js .work .work-media :is(img, video) { transform: none; }
}
