/* Pirex Media — estilos */

:root {
	--bg: #07090D;
	--bg-alt: #0B0F15;
	--surface: #0E131B;
	--line: #1E2631;
	--line-strong: #2A3441;
	--text: #EDEFF2;
	--text-soft: #D5DAE0;
	--text-body: #C6CCD3;
	--muted: #A9B1BB;
	--muted-2: #8A939E;
	--accent: #F2913D;
	--overlay: 0.5;
	--rec: #FF4A3D;

	--f-display: 'Big Shoulders Display', 'Arial Narrow', 'Helvetica Neue', sans-serif;
	--f-body: 'Instrument Sans', 'Helvetica Neue', Arial, sans-serif;
	--f-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

	--gutter: clamp(20px, 4vw, 56px);
	--maxw: 1360px;
	--header-h: 88px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	overflow-x: clip;
	background: var(--bg);
	color: var(--text);
	font-family: var(--f-body);
	font-size: 17px;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
}

img, video { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
a:hover { color: var(--text); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link {
	position: absolute; left: 16px; top: -100px; z-index: 100;
	background: var(--accent); color: var(--bg); padding: 12px 18px; font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 16px; }

.wrap { width: 100%; max-width: calc(var(--maxw) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }

/* Botones */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 12px;
	min-height: 52px; padding: 0 26px; border: 1.5px solid transparent;
	font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; line-height: 1.2;
	transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.btn--small { min-height: 44px; padding: 0 22px; }
.btn--accent { background: var(--accent); color: var(--bg); }
.btn--accent:hover { background: var(--text); color: var(--bg); }
.btn--light { background: var(--text); color: var(--bg); }
.btn--light:hover { background: var(--accent); color: var(--bg); }
.btn--ghost { border-color: rgba(237, 239, 242, .5); color: var(--text); font-weight: 500; }
.btn--ghost:hover { border-color: var(--text); color: var(--text); }

/* Encabezado: de orilla a orilla, alineado con las esquinas de la telemetría */
.site-header { position: relative; z-index: 20; }
.has-hero .site-header { position: absolute; top: 0; left: 0; right: 0; }
.site-header__inner {
	max-width: none; margin: 0; padding: env(safe-area-inset-top, 0px) var(--gutter) 0;
	height: calc(var(--header-h) + env(safe-area-inset-top, 0px));
	display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: inline-flex; align-items: center; }
.brand__logo { height: 26px; width: auto; }
.site-nav { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 36px); font-size: 15px; }
.site-nav .menu, .mobile-menu .menu { list-style: none; margin: 0; padding: 0; display: flex; gap: clamp(16px, 2.4vw, 36px); }
.site-nav .menu a { color: var(--text); text-decoration: none; padding: 10px 0; }
.site-nav .menu a:hover, .site-nav .current-menu-item a { color: var(--accent); }

.menu-toggle {
	display: none; width: 48px; height: 48px; align-items: center; justify-content: center;
	background: rgba(7, 9, 13, .4); color: var(--text); border: 1.5px solid rgba(237, 239, 242, .5); cursor: pointer;
}
.menu-toggle__close { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__open { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__close { display: inline; }

.mobile-menu {
	position: fixed; inset: 0; z-index: -1; background: var(--bg);
	padding: calc(96px + env(safe-area-inset-top, 0px)) 24px calc(32px + env(safe-area-inset-bottom, 0px));
	display: flex; flex-direction: column; overflow-y: auto;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu .menu { flex-direction: column; gap: 4px; }
.mobile-menu .menu a, .mobile-menu__cta {
	display: block; color: var(--text); text-decoration: none;
	font-family: var(--f-display); font-weight: 800; font-size: 52px; line-height: 1.1; text-transform: uppercase;
}
.mobile-menu__cta { color: var(--accent); margin-top: 4px; }
.mobile-menu__foot { margin-top: auto; padding-top: 32px; font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; color: var(--muted-2); }

/* Portada */
.hero { position: relative; height: 100vh; height: 100svh; min-height: 640px; max-height: 1100px; overflow: hidden; display: flex; align-items: flex-end; background: var(--bg); }
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero__shade { position: absolute; inset: 0; background: rgba(7, 9, 13, var(--overlay)); }
.hero__content { position: relative; padding-bottom: clamp(64px, 10vh, 112px); padding-left: calc(var(--gutter) + clamp(0px, 3vw, 56px)); }
.hero__title {
	margin: 0; font-family: var(--f-display); font-weight: 900; text-transform: uppercase;
	font-size: clamp(76px, 10.5vw, 176px); line-height: .86; letter-spacing: .01em;
}
.hero__eyebrow { margin: 18px 0 0; font-family: var(--f-mono); font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--accent); }
.hero__text { margin: 20px 0 0; max-width: 520px; font-size: 19px; color: var(--text-soft); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 36px; }

/* Telemetría */
.hud {
	position: absolute; top: calc(var(--header-h) + 24px + env(safe-area-inset-top, 0px)); left: var(--gutter); right: var(--gutter); bottom: 40px;
	pointer-events: none; font-family: var(--f-mono); font-size: 12px; letter-spacing: .08em; color: rgba(237, 239, 242, .85);
}
.hud__corner { position: absolute; width: 40px; height: 40px; border: 0 solid rgba(237, 239, 242, .7); }
.hud__corner--tl { top: 0; left: 0; border-top-width: 1.5px; border-left-width: 1.5px; }
.hud__corner--tr { top: 0; right: 0; border-top-width: 1.5px; border-right-width: 1.5px; }
.hud__corner--bl { bottom: 0; left: 0; border-bottom-width: 1.5px; border-left-width: 1.5px; }
.hud__corner--br { bottom: 0; right: 0; border-bottom-width: 1.5px; border-right-width: 1.5px; }
.hud__text { position: absolute; display: flex; align-items: center; gap: 10px; }
.hud__text--tl { top: 14px; left: 56px; }
.hud__text--tr { top: 14px; right: 56px; }
.hud__text--br { bottom: 14px; right: 56px; }
.hud__rec { width: 8px; height: 8px; border-radius: 50%; background: var(--rec); animation: rec 1.6s steps(1) infinite; }
@keyframes rec { 50% { opacity: .2; } }
.hud__cross { position: absolute; top: 50%; left: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; }
.hud__cross::before, .hud__cross::after { content: ""; position: absolute; background: rgba(237, 239, 242, .7); }
.hud__cross::before { left: 21px; top: 0; width: 1.5px; height: 44px; -webkit-mask: linear-gradient(#000 0 14px, transparent 14px 30px, #000 30px); mask: linear-gradient(#000 0 14px, transparent 14px 30px, #000 30px); }
.hud__cross::after { top: 21px; left: 0; height: 1.5px; width: 44px; -webkit-mask: linear-gradient(90deg, #000 0 14px, transparent 14px 30px, #000 30px); mask: linear-gradient(90deg, #000 0 14px, transparent 14px 30px, #000 30px); }

/* Secciones */
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section--tight { padding: clamp(40px, 5vw, 64px) 0; }
.section--alt { background: var(--bg-alt); }
.section__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 40px; }
.section__head--filters { margin-bottom: 28px; }
.section__intro { margin: 0; max-width: 440px; color: var(--muted); }
.section__more { margin-top: 40px; display: flex; justify-content: center; }
.h2 { margin: 0; font-family: var(--f-display); font-weight: 800; font-size: clamp(44px, 5vw, 72px); line-height: .95; text-transform: uppercase; }
.split { display: flex; flex-wrap: wrap; gap: 56px; }
.split__aside { flex: 1 1 360px; }
.split__aside .section__intro { margin-top: 24px; }

/* Servicios */
.services { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.service { position: relative; display: block; height: 460px; overflow: hidden; background: var(--surface); color: var(--text); text-decoration: none; }
.service__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .62; transition: opacity .3s ease, transform .6s ease; }
.service:hover .service__img { opacity: .8; transform: scale(1.03); }
.service__body { position: absolute; left: 28px; right: 28px; bottom: 28px; display: block; }
.service__title { display: block; font-family: var(--f-display); font-weight: 800; font-size: 46px; line-height: 1; text-transform: uppercase; }
.service__desc { display: block; margin-top: 10px; font-size: 16px; color: var(--text-soft); }
.service:hover { color: var(--text); }

/* Filtros y galería */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters__btn {
	min-height: 44px; padding: 0 18px; background: transparent; color: var(--text);
	border: 1.5px solid var(--line-strong); font-family: var(--f-mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; cursor: pointer;
}
.filters__btn:hover { border-color: var(--text); }
.filters__btn[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--bg); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.card[hidden] { display: none; }
.card__link { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; background: var(--surface); color: var(--text); text-decoration: none; }
.card__img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.card__img--empty { display: block; background: var(--surface); }
.card__link:hover .card__img { transform: scale(1.04); }
.card__caption {
	position: absolute; left: 0; right: 0; bottom: 0; padding: 48px 16px 14px;
	background: linear-gradient(to top, rgba(7, 9, 13, .92), rgba(7, 9, 13, 0));
	display: flex; justify-content: space-between; align-items: flex-end; gap: 8px;
	font-family: var(--f-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
}
.card__title { color: var(--text); }
.card__meta { color: var(--accent); text-align: right; }
.grid__empty, .empty { color: var(--muted); }
.empty { padding: 48px; border: 1px dashed var(--line-strong); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.empty p { margin: 0; }

/* Bitácora */
.log { flex: 2 1 560px; min-width: 0; list-style: none; margin: 0; padding: 0; font-family: var(--f-mono); font-size: 14px; }
.log__item { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 20px 0; border-bottom: 1px solid var(--line); }
.log__n { color: #6E7884; }
.log__city { font-family: var(--f-display); font-weight: 700; font-size: 28px; letter-spacing: .02em; text-transform: uppercase; line-height: 1.1; }
.log__coords { color: var(--muted); }

/* Sobre mí */
.about { display: flex; flex-wrap: wrap; gap: 64px; align-items: center; }
.about__photo { position: relative; flex: 1 1 340px; max-width: 500px; margin: 0; }
.about__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.about__badge { position: absolute; left: 0; bottom: 0; background: var(--accent); color: var(--bg); padding: 10px 16px; font-family: var(--f-mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; font-weight: 500; }
.about__body { flex: 1 1 420px; }
.about__text { margin: 24px 0 0; max-width: 560px; color: var(--text-body); }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; align-items: end; margin: 40px 0 0; padding-top: 32px; border-top: 1px solid var(--line); }
.stat { display: flex; flex-direction: column; }
.stat__live { order: 0; display: flex; align-items: center; gap: 8px; margin-bottom: 8px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #FF6B5E; }
.stat__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--rec); animation: rec 1.6s steps(1) infinite; }
.stat__value { order: 1; margin: 0; font-family: var(--f-display); font-weight: 800; font-size: 48px; line-height: 1; }
.stat__label { order: 2; margin-top: 6px; font-size: 14px; color: var(--muted); }
.creds { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 32px 0 0; padding: 0; font-family: var(--f-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.creds li { border: 1px solid var(--line-strong); padding: 10px 14px; }

/* Clientes */
.clients { padding: 56px 0; border-top: 1px solid #161C25; border-bottom: 1px solid #161C25; }
.clients__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px 40px; }
.clients__title { margin: 0; font-family: var(--f-mono); font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted-2); }
.clients__logo { max-height: 40px; width: auto; opacity: .7; filter: grayscale(1); }

/* Contacto */
.contact__inner { display: flex; flex-wrap: wrap; gap: 64px; }
.contact__intro { flex: 1 1 380px; }
.contact__intro .section__intro { margin-top: 24px; color: var(--text-body); }
.contact__title { margin: 0; font-family: var(--f-display); font-weight: 900; font-size: clamp(56px, 6.5vw, 104px); line-height: .88; text-transform: uppercase; }
.contact__direct { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; margin-top: 36px; font-size: 18px; }
.contact__email { color: var(--text); }
.form { flex: 1 1 460px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-content: start; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field--full, .form .notice { grid-column: 1 / -1; }
.field label { font-size: 14px; color: var(--muted); }
.field input, .field select, .field textarea {
	min-height: 48px; width: 100%; background: var(--surface); border: 1px solid var(--line-strong); color: var(--text);
	padding: 0 14px; font: inherit; border-radius: 0;
}
.field textarea { padding: 14px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); outline: none; }
.form .btn { min-height: 54px; }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notice { margin: 0; padding: 14px 16px; border: 1px solid; }
.notice--ok { border-color: #3FAE6A; color: #8FE0AE; }
.notice--error { border-color: #E5574A; color: #FFB1A9; }

/* Pie y barra móvil */
.site-footer { padding: 32px 0 40px; border-top: 1px solid #161C25; }
.site-footer__inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted-2); }
.site-footer a { color: var(--muted-2); }
.site-footer a:hover { color: var(--text); }
.mobile-bar { display: none; }

/* Páginas internas y proyectos */
.page-head { padding-top: clamp(48px, 8vw, 96px); padding-bottom: 8px; }
.has-hero .page-head { padding-top: calc(var(--header-h) + 64px); }
.project-title { margin: 0; font-family: var(--f-display); font-weight: 900; font-size: clamp(56px, 8vw, 128px); line-height: .9; text-transform: uppercase; overflow-wrap: anywhere; }
.page-head .hero__eyebrow { margin: 0 0 14px; }
.page-head .section__intro { margin-top: 20px; }

.project-hero { position: relative; height: 88vh; height: 88svh; min-height: 520px; display: flex; align-items: flex-end; overflow: hidden; }
.project-hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.project-hero__shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(7, 9, 13, .85), rgba(7, 9, 13, .1) 60%); }
.project-hero__content { position: relative; padding-bottom: 56px; }
.project-hero__content .hero__eyebrow { margin: 0 0 14px; }

.project { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 56px; }
.project__meta { margin: 0; display: flex; flex-direction: column; gap: 18px; }
.project__meta dt { font-family: var(--f-mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted-2); }
.project__meta dd { margin: 4px 0 0; font-size: 18px; }
.project__meta a { color: var(--text); }

.prose { max-width: 720px; color: var(--text-body); font-size: 18px; }
.prose > :first-child { margin-top: 0; }
.prose h2, .prose h3 { font-family: var(--f-display); font-weight: 800; text-transform: uppercase; color: var(--text); line-height: 1; }
.prose h2 { font-size: 40px; }
.prose h3 { font-size: 30px; }
.prose img { margin: 24px 0; }

.video-frame { position: relative; background: #000; }
.video-frame iframe, .video-frame video { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; display: block; }
.video-frame .wp-embed-responsive, .video-frame > .btn { margin: 24px; }

.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.gallery__item { display: block; overflow: hidden; background: var(--surface); }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.gallery__item:hover img { transform: scale(1.02); }
.gallery__item:nth-child(3n+1) { grid-column: 1 / -1; }

.lightbox { padding: 0; border: 0; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; background: rgba(7, 9, 13, .97); color: var(--text); }
.lightbox[open] { display: flex; align-items: center; justify-content: center; }
.lightbox::backdrop { background: rgba(7, 9, 13, .9); }
.lightbox__img { max-width: calc(100vw - 160px); max-height: calc(100vh - 64px); object-fit: contain; }
.lightbox__btn { position: absolute; width: 52px; height: 52px; display: flex; align-items: center; justify-content: center; background: transparent; color: var(--text); border: 1.5px solid rgba(237, 239, 242, .4); cursor: pointer; }
.lightbox__btn:hover { border-color: var(--text); }
.lightbox__close { top: 20px; right: 20px; }
.lightbox__prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 20px; top: 50%; transform: translateY(-50%); }

.project-nav { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-top: 24px; padding-bottom: 24px; border-top: 1px solid var(--line); font-family: var(--f-mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.project-nav a { color: var(--text); text-decoration: none; }
.project-nav a:hover { color: var(--accent); }
.project-nav span { flex: 1; }
.project-nav span:last-child { text-align: right; }

.posts { display: flex; flex-direction: column; gap: 40px; max-width: 760px; }
.post-item__title { margin: 0; font-family: var(--f-display); font-weight: 800; font-size: 36px; text-transform: uppercase; line-height: 1; }
.post-item__title a { color: var(--text); text-decoration: none; }
.post-item__date { margin: 8px 0 12px; font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; color: var(--muted-2); }

/* Tableta */
@media (max-width: 1100px) {
	.services { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
	.project { grid-template-columns: 1fr; gap: 32px; }
}

/* Celular */
@media (max-width: 860px) {
	:root { --header-h: 68px; }
	.site-nav { display: none; }
	.menu-toggle { display: inline-flex; }
	.brand__logo { height: 20px; }
}

@media (max-width: 700px) {
	body { font-size: 16px; padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
	.hero { min-height: 600px; max-height: none; }
	.hero__content { padding-left: calc(var(--gutter) + 12px); padding-right: calc(var(--gutter) + 12px); padding-bottom: calc(64px + 72px + env(safe-area-inset-bottom, 0px)); }
	.hero__title { font-size: clamp(72px, 26vw, 112px); }
	.hero__eyebrow { font-size: 12px; letter-spacing: .16em; }
	.hero__text { font-size: 17px; }
	.hero__actions { flex-direction: column; }
	.hero__actions .btn { width: 100%; }

	.hud { left: 16px; right: 16px; bottom: calc(96px + env(safe-area-inset-bottom, 0px)); font-size: 10px; top: calc(var(--header-h) + 16px + env(safe-area-inset-top, 0px)); }
	.hud__corner { width: 28px; height: 28px; }
	.hud__text--tl, .hud__text--tr { top: 10px; display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
	.hud__text--tl { left: 38px; max-width: calc(55% - 38px); padding-left: 15px; }
	.hud__text--tl .hud__rec { position: absolute; left: 0; top: 50%; margin-top: -3.5px; width: 7px; height: 7px; }
	.hud__text--tr { right: 38px; max-width: calc(45% - 46px); }
	.hud__text--br { display: none; }
	.hud__cross { top: 38%; }

	.h2 { font-size: clamp(40px, 12vw, 48px); }
	.section__head { margin-bottom: 24px; }

	.services { display: flex; overflow-x: auto; gap: 12px; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 8px; scroll-snap-type: x mandatory; }
	.service { flex: 0 0 82%; height: 400px; scroll-snap-align: start; }
	.service__body { left: 20px; right: 20px; bottom: 20px; }
	.service__title { font-size: 40px; }

	.filters { flex-wrap: nowrap; overflow-x: auto; width: calc(100% + var(--gutter) * 2); margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 4px; }
	.filters__btn { flex: 0 0 auto; font-size: 12px; padding: 0 16px; }
	.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
	.card__caption { padding: 28px 10px 8px; font-size: 10px; flex-direction: column; align-items: flex-start; gap: 2px; }
	.card__meta { text-align: left; }

	.log__item { grid-template-columns: 32px minmax(0, 1fr); gap: 4px 12px; padding: 16px 0; font-size: 12px; }
	.log__n { grid-row: span 2; }
	.log__city { font-size: 26px; }

	.about { gap: 32px; }
	.stats { gap: 12px; }
	.stat__value { font-size: 36px; }
	.stat__label { font-size: 12px; }

	.contact__title { font-size: clamp(48px, 15vw, 72px); }
	.contact__direct { align-items: stretch; }
	.contact__direct .btn { width: 100%; }
	.form { grid-template-columns: 1fr; }

	.gallery { grid-template-columns: 1fr; gap: 8px; }
	.lightbox__img { max-width: 100vw; max-height: calc(100vh - 160px); }
	.lightbox__prev, .lightbox__next { top: auto; bottom: 24px; transform: none; }

	.site-footer__inner { flex-direction: column; gap: 6px; }

	.mobile-bar {
		display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px;
		position: fixed; left: 0; right: 0; bottom: 0; z-index: 15;
		padding: 10px 12px calc(14px + env(safe-area-inset-bottom, 0px));
		background: rgba(7, 9, 13, .94); border-top: 1px solid var(--line);
		-webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
	}
	.mobile-bar .btn { min-height: 48px; font-size: 15px; padding: 0 12px; }
	.menu-open .mobile-bar { display: none; }
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Barra de administración de WordPress */
.admin-bar.has-hero .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar.has-hero .site-header { top: 46px; } }

/* ==========================================================
   Líneas de títulos (en ambos modos)
   ========================================================== */
.line { display: block; }
.line__in { display: inline-block; }
.service__media { position: absolute; inset: 0; display: block; overflow: hidden; }

/* ==========================================================
   Modo cinematográfico
   ========================================================== */
.is-cine .section { padding: clamp(96px, 12vw, 176px) 0; }
.is-cine .section--tight { padding: clamp(48px, 6vw, 80px) 0; }
.is-cine .h2 { font-size: clamp(52px, 6.6vw, 108px); line-height: .9; letter-spacing: .005em; }
.is-cine .hero__title { font-size: clamp(88px, 13.5vw, 236px); line-height: .84; }
.is-cine .hero__eyebrow { letter-spacing: .28em; }
.is-cine .section__head { margin-bottom: clamp(40px, 5vw, 72px); }
.is-cine .service { height: clamp(460px, 42vw, 600px); }
.is-cine .service__title { font-size: clamp(46px, 4vw, 60px); }
.is-cine .hero__video { will-change: transform; }

/* Franjas a pantalla completa */
.band { position: relative; height: 82vh; height: 82svh; min-height: 480px; overflow: hidden; display: flex; align-items: flex-end; background: var(--surface); }
.band__media { position: absolute; left: 0; right: 0; top: -18%; height: 136%; will-change: transform; }
.band__img { width: 100%; height: 100%; object-fit: cover; }
.band__shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(7, 9, 13, .82), rgba(7, 9, 13, .15) 55%, rgba(7, 9, 13, .35)); }
.band__text {
	position: relative; margin: 0 auto; padding-bottom: clamp(48px, 8vw, 112px);
	font-family: var(--f-display); font-weight: 800; text-transform: uppercase;
	font-size: clamp(40px, 6vw, 104px); line-height: .92;
}
.band__text { max-width: calc(var(--maxw) + var(--gutter) * 2); }

/* Altímetro lateral */
.altimeter {
	position: fixed; right: 12px; top: 50%; z-index: 10; transform: translateY(-50%);
	display: none; flex-direction: column; align-items: center; gap: 12px;
	font-family: var(--f-mono); font-size: 10px; letter-spacing: .06em; color: var(--muted);
	opacity: 0; transition: opacity .5s ease; pointer-events: none;
}
.altimeter.is-visible { opacity: 1; }
.altimeter__scale {
	position: relative; width: 14px; height: 36vh;
	background: repeating-linear-gradient(to bottom, rgba(237, 239, 242, .35) 0 1px, transparent 1px 12px) center / 6px 100% no-repeat,
		repeating-linear-gradient(to bottom, rgba(237, 239, 242, .6) 0 1px, transparent 1px 60px) center / 14px 100% no-repeat;
}
.altimeter__marker { position: absolute; left: -6px; right: -6px; top: 0; height: 2px; background: var(--accent); }
@media (min-width: 1280px) { .altimeter { display: flex; } }

/* Entrada de la portada */
.letterbox { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.letterbox__bar { position: absolute; left: 0; right: 0; height: 0; background: #000; }
.letterbox__bar--top { top: 0; }
.letterbox__bar--bottom { bottom: 0; }
.cine-intro .letterbox__bar { animation: shutter 1.5s cubic-bezier(.76, 0, .24, 1) .25s both; }
@keyframes shutter { from { height: 50.5%; } to { height: 0; } }

.cine-intro .hero__video { animation: landing 2.8s cubic-bezier(.22, 1, .36, 1) .2s both; }
@keyframes landing { from { scale: 1.28; } to { scale: 1; } }

.cine-intro .hero__title .line { clip-path: inset(-.6em -.2em 0 -.2em); }
.cine-intro .hero__title .line__in { animation: rise 1.2s cubic-bezier(.22, 1, .36, 1) both; animation-delay: calc(1.05s + var(--i, 0) * .14s); }
@keyframes rise { from { transform: translateY(105%); } to { transform: none; } }

.cine-intro .hero__eyebrow,
.cine-intro .hero__text,
.cine-intro .hero__actions { animation: fadeup 1s cubic-bezier(.22, 1, .36, 1) both; }
.cine-intro .hero__eyebrow { animation-delay: 1.55s; }
.cine-intro .hero__text { animation-delay: 1.7s; }
.cine-intro .hero__actions { animation-delay: 1.85s; }
.cine-intro .hud { animation: fadein 1.2s ease 2s both; }
.cine-intro .site-header { animation: fadein 1s ease 1.6s both; }
@keyframes fadeup { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }

/* Apariciones al hacer scroll (solo si el navegador permite movimiento) */
.js-cine .h2 .line { clip-path: inset(-.6em -.2em 0 -.2em); }
.js-cine .h2 .line__in { transform: translateY(105%); transition: transform 1.1s cubic-bezier(.22, 1, .36, 1); transition-delay: calc(var(--i, 0) * .12s); }
.js-cine .h2.is-in .line__in { transform: none; }

.js-cine .card[data-reveal], .js-cine .about__photo[data-reveal] { position: relative; }
.js-cine [data-reveal]::after {
	content: ""; position: absolute; inset: -1px; z-index: 3; pointer-events: none; background: var(--bg);
	transform-origin: 50% 0; transition: transform 1.3s cubic-bezier(.76, 0, .24, 1); transition-delay: var(--d, 0s);
}
.js-cine [data-reveal].is-in::after { transform: scaleY(0); }
.js-cine .band__text[data-reveal]::after { content: none; }
.js-cine .band__text[data-reveal] { opacity: 0; transform: translateY(32px); transition: opacity 1.2s ease, transform 1.2s cubic-bezier(.22, 1, .36, 1); }
.js-cine .band__text[data-reveal].is-in { opacity: 1; transform: none; }
.js-cine .card[hidden] { display: none; }

.js-cine .service__img[data-parallax] { inset: -12% 0 auto 0; height: 124%; will-change: transform; }
.js-cine .card__img { transition: transform 1.2s cubic-bezier(.22, 1, .36, 1); }
.js-cine .card__link:hover .card__img { transform: scale(1.06); }
.js-cine .card__caption { transition: padding-bottom .5s cubic-bezier(.22, 1, .36, 1); }
.js-cine .card__link:hover .card__caption { padding-bottom: 20px; }

@media (max-width: 700px) {
	.band { height: 70svh; min-height: 420px; }
	.is-cine .hero__title { font-size: clamp(80px, 27vw, 120px); }
	.is-cine .h2 { font-size: clamp(44px, 13vw, 56px); }
}

@media (prefers-reduced-motion: reduce) {
	.letterbox { display: none; }
	.band__media { top: 0; height: 100%; }
}

/* Encabezado centrado (opción en Personalizar > Pirex > Telemetría y color) */
.header-boxed .site-header__inner { max-width: calc(var(--maxw) + var(--gutter) * 2); margin: 0 auto; }

/* Flexibles que no deben desbordarse */
.split__aside, .log, .about__body, .contact__intro, .form, .section__head > * { min-width: 0; }
.mobile-bar--single { grid-template-columns: 1fr; }

/* Celular en modo cinematográfico: mismas proporciones que el boceto */
@media (max-width: 700px) {
	.is-cine .section { padding: 64px 0; }
	.is-cine .section--tight { padding: 40px 0; }
	.is-cine .section__head { margin-bottom: 24px; }
	.is-cine .h2 { font-size: clamp(40px, 12.3vw, 48px); line-height: .95; }
	.is-cine .hero__title { font-size: clamp(80px, 26.5vw, 104px); line-height: .86; }
	.is-cine .hero__eyebrow { letter-spacing: .16em; }
	.is-cine .service { height: 400px; }
	.is-cine .service__title { font-size: 40px; }
	.is-cine .contact__title { font-size: clamp(44px, 15vw, 72px); }
	.band { height: 62svh; min-height: 400px; }
	.band__text { font-size: clamp(34px, 10vw, 44px); }
}

/* Clips de portada de proyectos */
.project-hero__video { z-index: 0; }
.card__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .4s ease; pointer-events: none; }
.card__video.is-playing { opacity: 1; }
.card__caption { z-index: 1; }

/* Página de proyecto: datos en una fila y videos/fotos a todo lo ancho */
.project { display: block; }
.project__meta {
	flex-direction: row; flex-wrap: wrap; gap: 20px 56px;
	margin-bottom: 48px; padding-bottom: 28px; border-bottom: 1px solid var(--line);
}
.project__content.prose { max-width: none; }
.project__content > p,
.project__content > ul,
.project__content > ol,
.project__content > h2,
.project__content > h3,
.project__content > h4,
.project__content > blockquote { max-width: 760px; }
.project__content > figure,
.project__content > .wp-block-embed,
.project__content > .wp-block-video,
.project__content > .wp-block-image,
.project__content > .wp-block-gallery { width: 100%; max-width: none; margin: 0 0 clamp(24px, 3vw, 48px); }
.project__content .wp-block-embed__wrapper { width: 100%; }
.project__content > iframe,
.project__content > p > iframe,
.project__content .wp-block-video video { width: 100%; height: auto; aspect-ratio: 16 / 9; border: 0; display: block; }
.project__content img { width: 100%; height: auto; }
.project__content figcaption { margin-top: 10px; font-family: var(--f-mono); font-size: 12px; letter-spacing: .08em; color: var(--muted-2); }

/* Pantallas muy grandes: las páginas de proyecto aprovechan más el ancho */
@media (min-width: 1800px) {
	.single-proyecto { --maxw: 1640px; }
}
@media (max-width: 700px) {
	.project__meta { gap: 16px 32px; margin-bottom: 32px; padding-bottom: 20px; }
}

/* Título de portada: grotesca gruesa (estilo Polysans) */
.title-inter .hero__title,
.title-inter.is-cine .hero__title {
	font-family: 'Inter Tight', 'Helvetica Neue', Arial, sans-serif; font-weight: 800;
	letter-spacing: -0.05em; line-height: .9; font-size: clamp(72px, 9.4vw, 168px);
}
.title-inter .hero__title .line__in { padding-right: .06em; }

/* Degradado plateado, como el logo */
.title-silver .hero__title .line__in {
	background: linear-gradient(90deg, #FFFFFF 0%, #FFFFFF 42%, #A3A6AB 100%);
	-webkit-background-clip: text; background-clip: text; color: transparent;
	padding-bottom: .08em;
}

@media (max-width: 700px) {
	.title-inter .hero__title,
	.title-inter.is-cine .hero__title { font-size: clamp(60px, 23vw, 100px); }
}

/* ==========================================================
   Inter Tight en todos los títulos (v1.4)
   ========================================================== */
.title-inter .hero__title,
.title-inter.is-cine .hero__title { line-height: .8; }
.title-inter .hero__title .line,
.title-inter.cine-intro .hero__title .line { clip-path: inset(-.6em -.2em -.12em -.2em); }
.title-inter .hero__eyebrow { font-size: 12px; }

.title-inter .h2,
.title-inter .service__title,
.title-inter .project-title,
.title-inter .contact__title,
.title-inter .band__text,
.title-inter .log__city,
.title-inter .stat__value,
.title-inter .post-item__title,
.title-inter .prose h2,
.title-inter .prose h3,
.title-inter .mobile-menu .menu a,
.title-inter .mobile-menu__cta {
	font-family: 'Inter Tight', 'Helvetica Neue', Arial, sans-serif; font-weight: 800; letter-spacing: -0.045em;
}
.title-inter .h2,
.title-inter.is-cine .h2 { font-size: clamp(40px, 4.6vw, 80px); line-height: .94; }
.title-inter .service__title,
.title-inter.is-cine .service__title { font-size: clamp(32px, 2.6vw, 44px); }
.title-inter .project-title { font-size: clamp(48px, 6vw, 108px); line-height: .92; }
.title-inter .contact__title,
.title-inter.is-cine .contact__title { font-size: clamp(48px, 5.4vw, 92px); line-height: .92; }
.title-inter .band__text { font-size: clamp(32px, 4vw, 72px); line-height: .98; }
.title-inter .log__city { font-size: 22px; letter-spacing: -0.03em; }
.title-inter .stat__value { font-size: 40px; letter-spacing: -0.04em; }
.title-inter .post-item__title { font-size: 30px; }
.title-inter .prose h2 { font-size: 32px; }
.title-inter .prose h3 { font-size: 24px; }
.title-inter .mobile-menu .menu a,
.title-inter .mobile-menu__cta { font-size: 38px; line-height: 1.15; }
.js-cine .title-inter .h2 .line { clip-path: inset(-.6em -.2em -.12em -.2em); }

/* Celular: tamaños más contenidos */
@media (max-width: 700px) {
	.hero__text { font-size: 16px; }
	.hero__eyebrow { font-size: 11px; }
	.title-inter .hero__title,
	.title-inter.is-cine .hero__title { font-size: clamp(56px, 19.5vw, 80px); line-height: .82; }
	.title-inter .h2,
	.title-inter.is-cine .h2 { font-size: clamp(30px, 9.2vw, 38px); }
	.title-inter .service__title,
	.title-inter.is-cine .service__title { font-size: 30px; }
	.title-inter.is-cine .service { height: 380px; }
	.title-inter .project-title { font-size: clamp(38px, 12vw, 52px); }
	.title-inter .contact__title,
	.title-inter.is-cine .contact__title { font-size: clamp(38px, 11.8vw, 48px); }
	.title-inter .band__text { font-size: clamp(26px, 7.6vw, 32px); }
	.title-inter .log__city { font-size: 20px; }
	.title-inter .stat__value { font-size: 30px; }
	.title-inter .mobile-menu .menu a,
	.title-inter .mobile-menu__cta { font-size: 36px; }
}

/* ==========================================================
   Cifras alineadas y logos de clientes ordenados (v1.4.1)
   ========================================================== */
.stats { align-items: start; }
.stat__label { line-height: 1.35; }

.clients__inner { display: flex; flex-wrap: nowrap; align-items: center; gap: 40px; }
.clients__title { flex: 0 0 auto; }
.clients__grid {
	flex: 1 1 auto; list-style: none; margin: 0; padding: 0;
	display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 16px 32px; align-items: center;
}
.clients__cell { height: 64px; display: flex; align-items: center; justify-content: center; }
.clients__logo { width: auto; height: auto; max-width: 150px; max-height: 44px; object-fit: contain; }

@media (max-width: 860px) {
	.clients__inner { flex-direction: column; align-items: stretch; gap: 24px; }
}
@media (max-width: 700px) {
	.stats { gap: 16px; }
	.stat__label { font-size: 12px; }
	.clients__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 20px; }
	.clients__cell { height: 72px; }
	.clients__logo { max-width: 78%; max-height: 38px; }
}

/* Logos cuadrados o compactos: un poco más altos para equilibrarlos con los alargados */
.clients__logo--compact { max-height: 60px; max-width: 110px; }
@media (max-width: 700px) { .clients__logo--compact { max-height: 56px; max-width: 60%; } }

/* ==========================================================
   Movimiento avanzado con GSAP (v1.5)
   ========================================================== */
html.gsap-smooth { scroll-behavior: auto; }
.has-gsap.cine-intro .hero__title .line__in { animation: none; }
.js-cine .has-gsap .h2 .line__in { transform: none; transition: none; }
.has-gsap .hero__title .line,
.js-cine .has-gsap .h2 .line { clip-path: inset(-.6em -.3em -.14em -.3em); }
.has-gsap .char { will-change: transform; }

/* GSAP: la frase de las franjas la anima GSAP palabra por palabra */
.js-cine .has-gsap .band__text[data-reveal] { opacity: 1; transform: none; transition: none; }
.has-gsap .band__text .word { display: inline-block; will-change: transform, opacity; }
.has-gsap .band { will-change: transform; }
/* Con GSAP la franja ocupa toda la pantalla mientras se queda fija */
.has-gsap .band { height: 100vh; height: 100svh; }

/* ==========================================================
   Protección de imágenes (v1.7)
   ========================================================== */
.protect-media img,
.protect-media video { -webkit-user-drag: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.protect-media .lightbox::after {
	content: "© PIREX MEDIA"; position: absolute; right: 28px; bottom: 24px;
	font-family: var(--f-mono); font-size: 12px; letter-spacing: .18em; color: rgba(237, 239, 242, .55);
	pointer-events: none;
}
