/* NUMEN — estilos. Mobile-first, editorial, monocromático. */
:root {
  --black: #0b0b0a;
  --ink: #161614;
  --paper: #f4f1ea;      /* blanco cálido */
  --paper-2: #ebe7de;
  --gray: #8f8c85;       /* gris de apoyo sobre negro */
  --gray-dark: #5b5953;  /* gris de apoyo sobre claro */
  --stone: #b9b7b2;      /* fondo gris de la foto de presentación */
  --line-dark: rgba(244, 241, 234, .16);
  --line-light: rgba(11, 11, 10, .14);
  --font: "Archivo", "Helvetica Neue", Arial, system-ui, sans-serif;
  --gutter: clamp(20px, 5vw, 56px);
  --max: 1240px;
  --radius: 4px;
  --header-h: 64px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -.02em; line-height: 1.02; text-wrap: balance; }
h1 { font-size: clamp(2.6rem, 9vw, 5.6rem); }
h2 { font-size: clamp(2.1rem, 6.4vw, 4rem); }
h3 { font-size: 1.3rem; line-height: 1.15; letter-spacing: -.01em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure { margin: 0; }
button { font: inherit; color: inherit; }

:focus-visible { outline: 3px solid #e8b04a; outline-offset: 3px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--paper); color: var(--black); padding: 10px 14px; font-weight: 600; }
.skip:focus { top: 12px; }

.eyebrow { font-size: .82rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 18px; }
.lead { font-size: clamp(1.06rem, 2.2vw, 1.25rem); line-height: 1.55; max-width: 38em; }
.muted { color: var(--gray-dark); }
.section-dark .muted, .hero .muted, .viewer .muted { color: var(--gray); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 50px; padding: 0 24px;
  border: 2px solid transparent; border-radius: 999px;
  font-weight: 600; font-size: 1rem; text-decoration: none; cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
}
.btn-sm { min-height: 42px; padding: 0 18px; font-size: .95rem; }
.btn-block { width: 100%; }
.btn-light { background: var(--paper); color: var(--black); }
.btn-light:hover { background: #fff; }
.btn-outline-light { border-color: var(--paper); color: var(--paper); }
.btn-outline-light:hover { background: var(--paper); color: var(--black); }
.btn-dark { background: var(--black); color: var(--paper); }
.btn-dark:hover { background: #2a2a27; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

.icon-btn {
  width: 48px; height: 48px; border-radius: 50%;
  border: 2px solid var(--black); background: transparent; color: var(--black);
  font-size: 1.15rem; cursor: pointer; display: grid; place-items: center;
}
.icon-btn:hover:not(:disabled) { background: var(--black); color: var(--paper); }
.icon-btn:disabled { opacity: .3; cursor: default; }
.icon-btn-light { border-color: var(--paper); color: var(--paper); }
.icon-btn-light:hover { background: var(--paper) !important; color: var(--black) !important; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 11, 10, .92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  color: var(--paper);
  border-bottom: 1px solid var(--line-dark);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand img { width: 118px; height: auto; }
.menu-toggle {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 4px;
  background: none; border: 0; color: var(--paper); cursor: pointer; font-weight: 600;
}
.menu-toggle-bars, .menu-toggle-bars::before, .menu-toggle-bars::after {
  display: block; width: 20px; height: 2px; background: currentColor; position: relative; transition: transform .2s;
}
.menu-toggle-bars::before, .menu-toggle-bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle-bars::before { top: -6px; }
.menu-toggle-bars::after { top: 6px; }
.menu-open .menu-toggle-bars { background: transparent; }
.menu-open .menu-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.menu-open .menu-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

.nav {
  display: none;
  position: absolute; top: var(--header-h); left: 0; right: 0;
  background: var(--black); border-bottom: 1px solid var(--line-dark);
  padding: 8px var(--gutter) 24px;
  max-height: calc(100dvh - var(--header-h)); overflow-y: auto;
}
.menu-open .nav { display: block; }
.nav ul { margin-bottom: 16px; }
.nav li a { display: block; padding: 14px 0; font-size: 1.35rem; font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--line-dark); }
.nav .btn { width: 100%; }

@media (min-width: 960px) {
  .menu-toggle { display: none; }
  .nav { display: flex !important; position: static; align-items: center; gap: 28px; padding: 0; background: none; border: 0; max-height: none; overflow: visible; }
  .nav ul { display: flex; gap: 24px; margin: 0; }
  .nav li a { padding: 6px 0; font-size: .95rem; border: 0; border-bottom: 2px solid transparent; }
  .nav li a:hover { border-bottom-color: var(--paper); }
  .nav .btn { width: auto; }
}

/* ---------- Portada ---------- */
.hero { background: var(--black); color: var(--paper); overflow: hidden; }
.hero-grid { display: flex; flex-direction: column-reverse; gap: 0; padding-top: 0; padding-bottom: 64px; }
.hero-photo {
  margin: 0 calc(var(--gutter) * -1);
  aspect-ratio: 4 / 4.2;
  overflow: hidden;
}
.hero-photo { position: relative; }
.hero-photo::after { content: ""; position: absolute; inset: auto 0 0 0; height: 35%; background: linear-gradient(to bottom, rgba(11,11,10,0), var(--black)); pointer-events: none; }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; }
@media (min-width: 900px) { .hero-photo::after { height: 18%; } }
.hero-copy { position: relative; margin-top: -48px; }
.hero h1 { margin-bottom: 22px; }
.hero .lead { color: #d8d4cc; }
.hero .actions .btn { flex: 1 1 220px; }

@media (min-width: 900px) {
  .hero-grid { flex-direction: row; align-items: center; gap: 56px; padding-top: 40px; padding-bottom: 0; min-height: calc(100svh - var(--header-h)); }
  .hero-copy { flex: 1 1 55%; margin-top: 0; padding: 56px 0; }
  .hero .actions .btn { flex: 0 0 auto; }
  .hero-photo { flex: 0 0 40%; margin: 0; aspect-ratio: 3 / 4; align-self: flex-end; }
  .hero-photo img { object-position: 50% 30%; }
}

/* ---------- Secciones ---------- */
.section { padding: clamp(72px, 11vw, 136px) 0; }
.section-light { background: var(--paper); }
.section-paper { background: var(--paper-2); }
.section-dark { background: var(--black); color: var(--paper); }
.section-gray { background: var(--stone); color: var(--black); }
.section-head { margin-bottom: clamp(36px, 6vw, 64px); }
.section-head .lead { margin-top: 20px; }

/* ---------- Trabajos ---------- */
.filters { display: flex; gap: 8px; overflow-x: auto; padding: 4px 4px 12px; margin: 0 -4px 24px; scrollbar-width: none; }
.filters::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; min-height: 44px; padding: 0 18px; border-radius: 999px;
  border: 1.5px solid var(--line-light); background: transparent; cursor: pointer; font-weight: 500; white-space: nowrap;
}
.chip[aria-pressed="true"] { background: var(--black); border-color: var(--black); color: var(--paper); }
.chip:hover:not([aria-pressed="true"]) { border-color: var(--black); }

.video-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
@media (min-width: 720px) { .video-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; } }
.video-card[hidden] { display: none; }

.video-thumb {
  position: relative; display: block; width: 100%; padding: 0; border: 0; cursor: pointer;
  aspect-ratio: 9 / 16; overflow: hidden; border-radius: var(--radius); background: #222;
}
.video-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.video-thumb:hover img { transform: scale(1.03); }
.play {
  position: absolute; left: 12px; bottom: 12px;
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--paper); box-shadow: 0 2px 12px rgba(0,0,0,.25);
}
.play::after {
  content: ""; position: absolute; left: 21px; top: 17px;
  border-style: solid; border-width: 9px 0 9px 14px; border-color: transparent transparent transparent var(--black);
}
.video-tag {
  position: absolute; left: 10px; top: 10px;
  padding: 6px 12px; border-radius: 999px;
  background: rgba(11, 11, 10, .78); color: var(--paper);
  font-size: .8rem; font-weight: 600; line-height: 1.2; letter-spacing: .02em;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
@media (min-width: 720px) { .video-tag { font-size: .88rem; left: 14px; top: 14px; } }

.more { display: flex; justify-content: center; margin-top: 44px; }
.more[hidden] { display: none; }

/* Carrusel */
.carousel-project {
  margin-top: clamp(80px, 12vw, 140px);
  padding-top: clamp(40px, 6vw, 64px);
  border-top: 1px solid var(--line-light);
  display: grid; gap: 28px;
}
.carousel-info h3 { font-size: clamp(1.6rem, 4.6vw, 2.6rem); margin-bottom: 10px; }
.carousel-controls { display: flex; align-items: center; gap: 14px; margin-top: 24px; }
.carousel-count { font-weight: 600; font-variant-numeric: tabular-nums; min-width: 3.5em; text-align: center; }
.carousel-track {
  display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory;
  margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 6px; scroll-padding: 0 var(--gutter);
  scrollbar-width: thin;
}
.slide { flex: 0 0 82%; scroll-snap-align: start; border-radius: var(--radius); overflow: hidden; background: #ddd; }
.slide img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
@media (min-width: 720px) { .slide { flex-basis: 44%; } }
@media (min-width: 960px) {
  .carousel-project { grid-template-columns: 300px minmax(0, 1fr); align-items: start; gap: 48px; }
  .carousel-track { margin: 0; padding: 0 0 6px; scroll-padding: 0; }
  .slide { flex-basis: 46%; }
}

/* ---------- Caso ---------- */
.case-grid { display: grid; gap: 48px; }
.case-copy h2 { margin-bottom: 24px; }
.case-copy .lead { color: #d8d4cc; }
.roles { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.roles li { border: 1.5px solid var(--line-dark); border-radius: 999px; padding: 8px 16px; font-weight: 500; font-size: .95rem; }
.case-videos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.metrics { margin: 36px 0 0; display: grid; gap: 16px; }
.metric { display: flex; flex-direction: column; padding-top: 24px; border-top: 1px solid var(--line-dark); }
.metric dd { margin: 0; font-size: clamp(3.2rem, 11vw, 5rem); font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.metric dt { margin-top: 8px; color: #d8d4cc; font-size: 1.05rem; max-width: 22em; }
@media (min-width: 900px) {
  .case-grid { grid-template-columns: 1fr 1fr; align-items: center; gap: 72px; }
  .case-videos { gap: 24px; }
}

/* ---------- Planes ---------- */
.plans { display: grid; gap: 20px; }
@media (min-width: 1000px) { .plans { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; } }
.plan {
  display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--line-light); border-radius: 10px;
  padding: clamp(24px, 4vw, 36px);
}
.plan-count { font-size: .85rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gray-dark); margin-bottom: 10px; }
.plan h3 { font-size: clamp(1.6rem, 3.6vw, 2rem); margin-bottom: 12px; }
.plan-for { font-size: 1.02rem; margin-bottom: 22px; }
.plan-list { display: grid; gap: 10px; padding-top: 20px; border-top: 1px solid var(--line-light); font-size: .97rem; }
.plan-list li, .plan-notes li { position: relative; padding-left: 22px; }
.plan-list li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 8px; height: 8px; background: var(--black); border-radius: 50%; }
.plan-notes { display: grid; gap: 6px; margin-top: 18px; font-size: .92rem; color: var(--gray-dark); }
.plan-notes li::before { content: "—"; position: absolute; left: 0; }
.plan-benefit { margin: 24px 0; padding: 16px 18px; background: var(--paper); border-radius: 6px; font-weight: 500; flex-grow: 0; }
.plan .btn { margin-top: auto; }

/* ---------- Proceso ---------- */
.steps { display: grid; gap: 0; counter-reset: s; }
.steps li { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: baseline; padding: 22px 0; border-top: 1px solid var(--line-light); }
.steps li:last-child { border-bottom: 1px solid var(--line-light); }
.step-n { font-size: 1.6rem; font-weight: 800; }
.steps p { font-size: clamp(1.1rem, 2.6vw, 1.5rem); font-weight: 500; line-height: 1.35; }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(5, 1fr); gap: 24px; }
  .steps li { grid-template-columns: 1fr; border-bottom: 0 !important; padding-top: 24px; }
  .step-n { font-size: 2.6rem; }
  .steps p { font-size: 1.1rem; }
}

/* ---------- Sobre ---------- */
.about-grid { display: grid; gap: 40px; }
.about-photo { margin: calc(clamp(72px, 11vw, 136px) * -1) calc(var(--gutter) * -1) 0; aspect-ratio: 4 / 4.4; overflow: hidden; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 12%; }
.about-copy h2 { margin-bottom: 24px; }
.about-links { margin-top: 28px; font-weight: 600; }
.about-links a { text-underline-offset: 4px; }
@media (min-width: 900px) {
  .about-grid { grid-template-columns: 5fr 6fr; align-items: center; gap: 72px; }
  .about-photo { margin: 0; aspect-ratio: 3 / 4; border-radius: var(--radius); }
  .about-photo img { object-position: 50% 30%; }
}

/* ---------- FAQ ---------- */
.faq-grid { display: grid; gap: 0; }
@media (min-width: 900px) { .faq-grid { grid-template-columns: 1fr 1.6fr; gap: 72px; } }
.faq details { border-top: 1px solid var(--line-light); }
.faq details:last-child { border-bottom: 1px solid var(--line-light); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 22px 0; cursor: pointer; list-style: none; font-weight: 600; font-size: 1.12rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.6rem; font-weight: 400; line-height: 1; flex: 0 0 auto; }
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 0 24px; max-width: 40em; color: #3a3935; }

/* ---------- Cierre ---------- */
.closing h2 { font-size: clamp(2.4rem, 8vw, 5.4rem); margin-bottom: 24px; max-width: 12ch; }
.closing .lead { color: #d8d4cc; }
.closing .actions .btn { flex: 1 1 220px; }
@media (min-width: 720px) { .closing .actions .btn { flex: 0 0 auto; } }
.contact-list { margin-top: 56px; display: grid; gap: 0; }
.contact-list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; padding: 16px 0; border-top: 1px solid var(--line-dark); }
.contact-list a { font-weight: 600; text-underline-offset: 4px; overflow-wrap: anywhere; }

/* ---------- Footer ---------- */
.site-footer { background: var(--black); color: var(--gray); border-top: 1px solid var(--line-dark); padding: 32px 0 40px; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 16px 32px; align-items: center; justify-content: space-between; font-size: .95rem; }
.footer-inner img { width: 96px; }

/* ---------- Visor ---------- */
.viewer {
  padding: 0; border: 0; background: transparent; color: var(--paper);
  width: 100%; max-width: 100%; height: 100%; max-height: 100%;
}
.viewer::backdrop { background: rgba(5, 5, 5, .94); }
.viewer-inner { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 12px 12px 16px; }
.viewer-bar { width: min(460px, 100%, calc((100dvh - 110px) * 9 / 16)); min-width: 280px; max-width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.viewer-title { font-weight: 700; font-size: 1.05rem; }
.viewer-meta { font-size: .88rem; }
.viewer video {
  width: min(460px, 100%, calc((100dvh - 110px) * 9 / 16)); height: auto;
  aspect-ratio: 9 / 16; background: #000; border-radius: var(--radius); object-fit: contain;
}
.viewer-open { overflow: hidden; }
