/* ═══════════════════════════════════════════════════════════════
 * MCCI · Nav (mix-blend-mode + backdrop scroll glass) + mobile menu + cursor follower
 * ═══════════════════════════════════════════════════════════════ */

/* NAV */
.nav {
	position: fixed;
	top: 0; left: 0; right: 0;
	z-index: 100;
	padding: 0 clamp(1.5rem, 4vw, 3rem);
	height: 72px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	mix-blend-mode: difference;
	transition: height 0.3s ease;
}

/* Backdrop glass — separate fixed layer below nav (avoids difference conflict) */
.nav-backdrop {
	position: fixed;
	top: 0; left: 0; right: 0;
	height: 72px;
	z-index: 99;
	background: rgba(18, 21, 25, 0);
	backdrop-filter: blur(0);
	-webkit-backdrop-filter: blur(0);
	pointer-events: none;
	transition: background 0.4s ease, backdrop-filter 0.4s ease, -webkit-backdrop-filter 0.4s ease, border-bottom-color 0.4s ease;
	border-bottom: 1px solid transparent;
}
.nav-backdrop.scrolled {
	background: rgba(245, 243, 238, 0.08);
	backdrop-filter: blur(22px) saturate(1.3);
	-webkit-backdrop-filter: blur(22px) saturate(1.3);
	border-bottom-color: rgba(18,21,25,0.06);
}

.nav-logo { display: flex; align-items: center; }
.nav-logo svg { height: 36px; width: auto; }
.nav-logo svg .logo-text { fill: #FFFFFF; }
.nav-logo img { height: 36px; width: auto; opacity: 1; filter: none; transition: none; }

.nav-links {
	display: flex;
	gap: 2.5rem;
	list-style: none;
	align-items: center;
}
.nav-links > li { position: relative; }
.nav-links a {
	font-family: var(--f-mono);
	font-size: 0.76rem;
	font-weight: 400;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #FFFFFF;
	position: relative;
	padding-bottom: 3px;
	opacity: 0.65;
	transition: opacity 0.3s ease;
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
}
.nav-links a:hover, .nav-links a.active { opacity: 1; }
.nav-links a::after {
	content: '';
	position: absolute;
	bottom: 0; left: 0;
	width: 0; height: 1px;
	background: #FFFFFF;
	transition: width 0.4s var(--ease);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

/* Dropdown */
.nav-dropdown-trigger svg {
	width: 9px; height: 9px;
	stroke: #FFFFFF;
	fill: none;
	stroke-width: 2;
	transition: transform 0.3s ease;
}
.nav-dropdown-parent:hover .nav-dropdown-trigger svg,
.nav-dropdown-parent:focus-within .nav-dropdown-trigger svg { transform: rotate(180deg); }

.nav-dropdown {
	position: absolute;
	top: calc(100% + 0.5rem);
	left: -1rem;
	background: var(--c-dark);
	border: 1px solid rgba(255,255,255,0.1);
	min-width: 260px;
	padding: 0.5rem 0;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-6px);
	transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
	mix-blend-mode: normal;
}
.nav-dropdown-parent:hover .nav-dropdown,
.nav-dropdown-parent:focus-within .nav-dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.nav-dropdown a {
	display: block;
	padding: 0.75rem 1.25rem;
	font-family: var(--f-mono);
	font-size: 0.68rem;
	font-weight: 400;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: rgba(255,255,255,0.6);
	opacity: 1;
	transition: all 0.2s ease;
}
.nav-dropdown a:hover { color: #FFFFFF; background: rgba(255,255,255,0.05); }
.nav-dropdown a::after { display: none; }
.nav-dropdown-item-meta {
	display: block;
	margin-top: 0.2rem;
	font-size: 0.58rem;
	opacity: 0.5;
	letter-spacing: 0.06em;
	text-transform: none;
	font-weight: 300;
}

.nav-contact {
	font-family: var(--f-mono);
	font-size: 0.76rem;
	font-weight: 400;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #FFFFFF;
	padding: 0.55rem 1.35rem;
	border: 1px solid rgba(255,255,255,0.35);
	transition: all 0.3s ease;
	opacity: 0.75;
}
.nav-contact:hover { opacity: 1; background: rgba(255,255,255,0.08); }

.nav-right { display: flex; align-items: center; gap: 1.5rem; }

/* Burger */
.nav-burger {
	display: none;
	width: 32px; height: 32px;
	background: none;
	border: none;
	cursor: pointer;
	padding: 0;
	position: relative;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin-left: auto;
}
.nav-burger span {
	display: block;
	width: 22px;
	height: 1px;
	background: #FFFFFF;
	transition: transform 0.4s var(--ease), opacity 0.3s ease;
	transform-origin: center;
}
.nav-burger.open span:nth-child(1) { transform: translateY(3.5px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }

/* Mobile menu */
.mobile-menu {
	position: fixed;
	top: 0; left: 0; right: 0; bottom: 0;
	background: var(--c-dark);
	z-index: 99;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.5s var(--ease), visibility 0.5s var(--ease);
	display: flex;
	flex-direction: column;
	/* Padding-top con clamp para escalar en pantallas grandes; HOME.html usaba 100px fijo. */
	padding: clamp(110px, 14vh, 140px) clamp(1.5rem, 4vw, 3rem) clamp(2rem, 4vw, 3rem);
}
/* Admin bar de WP (46px mobile, 32px ≥783px) cubre la parte superior del overlay
 * fixed; sumamos su altura al padding-top para mantener el aire visual. */
body.admin-bar .mobile-menu { padding-top: calc(clamp(110px, 14vh, 140px) + 46px); }
@media (min-width: 783px) {
	body.admin-bar .mobile-menu { padding-top: calc(clamp(110px, 14vh, 140px) + 32px); }
}
.mobile-menu.open { opacity: 1; visibility: visible; }

.mobile-menu-inner {
	display: flex;
	flex-direction: column;
	height: 100%;
	justify-content: space-between;
}

.mobile-menu-links {
	list-style: none;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}
.mobile-menu-links li {
	overflow: hidden;
	border-bottom: 1px solid rgba(245,243,238,0.08);
	padding: 0.5rem 0;
}
.mobile-menu-links a {
	display: inline-block;
	font-family: var(--f-display);
	font-weight: 800;
	font-stretch: 85%;
	font-size: clamp(2rem, 7vw, 3.2rem);
	letter-spacing: -0.02em;
	color: var(--c-inverse);
	line-height: 1.1;
	transform: translateY(110%);
	transition: transform 0.7s var(--ease-out);
}
.mobile-menu.open .mobile-menu-links li:nth-child(1) a { transition-delay: 0.18s; transform: translateY(0); }
.mobile-menu.open .mobile-menu-links li:nth-child(2) a { transition-delay: 0.26s; transform: translateY(0); }
.mobile-menu.open .mobile-menu-links li:nth-child(3) a { transition-delay: 0.34s; transform: translateY(0); }
.mobile-menu.open .mobile-menu-links li:nth-child(4) a { transition-delay: 0.42s; transform: translateY(0); }
.mobile-menu.open .mobile-menu-links li:nth-child(5) a { transition-delay: 0.50s; transform: translateY(0); }
.mobile-menu.open .mobile-menu-links li:nth-child(6) a { transition-delay: 0.58s; transform: translateY(0); }

/* Sub-menú móvil: hijos del primer nivel anidados visualmente bajo su padre. */
.mobile-menu-sub {
	list-style: none;
	margin: 0.6rem 0 0 0;
	padding: 0 0 0 1.2rem;
	display: flex;
	flex-direction: column;
	gap: 0.2rem;
	border-left: 1px solid rgba(245,243,238,0.12);
}
.mobile-menu-sub li {
	overflow: hidden;
	border-bottom: none;
	padding: 0.15rem 0;
}
.mobile-menu-sub a {
	font-family: var(--f-display);
	font-weight: 600;
	font-stretch: 85%;
	font-size: clamp(1.1rem, 4vw, 1.5rem);
	letter-spacing: -0.01em;
	opacity: 0.85;
}
.mobile-menu.open .mobile-menu-sub a {
	transform: translateY(0);
	transition-delay: 0.6s;
}

.mobile-menu-footer {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
	opacity: 0;
	transition: opacity 0.6s ease 0.55s;
}
.mobile-menu.open .mobile-menu-footer { opacity: 1; }
.mobile-menu-tagline {
	font-family: var(--f-mono);
	font-size: 0.62rem;
	font-weight: 400;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: rgba(245,243,238,0.35);
	line-height: 1.6;
}

/* Custom cursor follower (chip style) */
.cursor-follower {
	position: fixed;
	top: 0; left: 0;
	display: flex;
	align-items: center;
	gap: 0.4rem;
	pointer-events: none;
	z-index: 9999;
	opacity: 0;
	transform: translate(-50%, -50%) scale(0.85);
	transition: opacity 0.3s ease, transform 0.4s var(--ease-out);
	white-space: nowrap;
}
.cursor-follower.active {
	opacity: 1;
	transform: translate(-50%, -50%) scale(1);
}
.cursor-follower-text, .cursor-follower-arrow {
	font-family: var(--f-mono);
	font-size: 0.72rem;
	font-weight: 500;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--c-dark);
	background: var(--c-inverse);
	padding: 0.6rem 0.85rem;
	line-height: 1;
	box-shadow: 0 4px 20px rgba(18, 21, 25, 0.25);
}
.cursor-follower-arrow { padding: 0.6rem 0.7rem; }

/* WP admin bar offset */
.admin-bar .nav,
.admin-bar .nav-backdrop { top: 32px; }
@media (max-width: 782px) {
	.admin-bar .nav,
	.admin-bar .nav-backdrop { top: 46px; }
}

/* Responsive */
@media (max-width: 768px) {
	.nav-links,
	.nav-contact { display: none; }
	.nav-burger { display: flex; }
	.cursor-follower { display: none; }
}
@media (hover: none) and (pointer: coarse) {
	.cursor-follower { display: none; }
}

/* ═══════════════════════════════════════════════════════════════
 * Language switcher — desktop (.nav-lang) + mobile (.mobile-menu-lang)
 * Hereda tipografía y patrón hover de .nav-links.
 * ═══════════════════════════════════════════════════════════════ */

.nav-lang {
	display: flex;
	align-items: center;
	gap: 0.55rem;
	list-style: none;
	margin: 0;
	padding: 0;
}
.nav-lang li { position: relative; }
.nav-lang a {
	font-family: var(--f-mono);
	font-size: 0.72rem;
	font-weight: 400;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #FFFFFF;
	opacity: 0.65;
	padding-bottom: 3px;
	position: relative;
	transition: opacity 0.3s ease;
}
.nav-lang a:hover,
.nav-lang a.active { opacity: 1; }
.nav-lang a::after {
	content: '';
	position: absolute;
	bottom: 0; left: 0;
	width: 0; height: 1px;
	background: #FFFFFF;
	transition: width 0.4s var(--ease);
}
.nav-lang a:hover::after,
.nav-lang a.active::after { width: 100%; }
.nav-lang__sep {
	color: rgba(255,255,255,0.3);
	font-family: var(--f-mono);
	font-size: 0.72rem;
	line-height: 1;
	user-select: none;
}

/* Mobile variant */
.mobile-menu-lang {
	display: flex;
	align-items: center;
	gap: 0.65rem;
	list-style: none;
	margin: 0 0 0.4rem 0;
	padding: 0;
}
.mobile-menu-lang a {
	font-family: var(--f-mono);
	font-size: 0.72rem;
	font-weight: 500;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--c-inverse);
	opacity: 0.55;
	padding-bottom: 3px;
	position: relative;
	transition: opacity 0.3s ease;
}
.mobile-menu-lang a:hover,
.mobile-menu-lang a.active { opacity: 1; }
.mobile-menu-lang a::after {
	content: '';
	position: absolute;
	bottom: 0; left: 0;
	width: 0; height: 1px;
	background: var(--c-inverse);
	transition: width 0.4s var(--ease);
}
.mobile-menu-lang a:hover::after,
.mobile-menu-lang a.active::after { width: 100%; }
.mobile-menu-lang__sep {
	color: rgba(245,243,238,0.3);
	font-family: var(--f-mono);
	font-size: 0.72rem;
	line-height: 1;
	user-select: none;
}

/* Responsive: el switcher desktop se oculta en mobile (lo cubre el del menú móvil) */
@media (max-width: 768px) {
	.nav-lang { display: none; }
}
