/* Meikero — dark field heroes (home + every inner page), glass console, site-wide dark glass header. */

/* Dark glass header, identical on every page */
.site-main { margin-top: -65px; }
.site-header {
	background: rgba(11,11,12,.92);
	border-bottom-color: rgba(255,255,255,.08);
	-webkit-backdrop-filter: blur(14px) saturate(140%);
	backdrop-filter: blur(14px) saturate(140%);
	color: #fff;
}
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }
.site-header .brand { color: #fff; }
.site-header .brand__mark { background: #fff; }
.site-header .nav__list a { color: rgba(255,255,255,.62); transition: color .2s; }
.site-header .nav__list a:hover, .site-header .nav__list a[aria-current="page"] { color: #fff; }
.site-header .nav__list a[aria-current="page"] { box-shadow: inset 0 -1px 0 #fff; }
.site-header .nav__actions { display: flex; align-items: center; gap: 18px; }
.site-header .nav__account { display: inline-flex; align-items: center; gap: 6px; color: rgba(255,255,255,.62); text-decoration: none; font-size: .95rem; }
.site-header .nav__account:hover { color: #fff; }
.site-header .nav__account .icon { width: 18px; height: 18px; }
.site-header .button--primary { background: #fff; color: #0a0a0a; border-color: #fff; }
.site-header .button--primary:hover { background: #e9e9e9; color: #0a0a0a; }
.site-header .nav-toggle { color: #fff; border-color: rgba(255,255,255,.2); }
.site-header a:focus-visible, .site-header button:focus-visible { outline-color: #fff; }
@media (max-width: 900px) {
	.nav-toggle { display: inline-flex; }
	.site-header .nav {
		display: none; position: absolute; left: 0; right: 0; top: 100%;
		flex-direction: column; align-items: stretch; gap: 16px;
		padding: 16px var(--gutter) 28px;
		background: rgba(10,10,10,.97); border-bottom: 1px solid rgba(255,255,255,.08);
	}
	.site-header .nav.is-open { display: flex; }
	.site-header .nav__list { flex-direction: column; gap: 0; }
	.site-header .nav__list a { display: block; padding: 13px 0; border-bottom: 1px solid rgba(255,255,255,.08); font-size: 1.05rem; box-shadow: none; }
	.site-header .nav__actions { justify-content: space-between; }
	.site-header .nav__actions .button { flex: 1; justify-content: center; }
}

/* Inner page hero */
.hero-x--page { padding: calc(65px + clamp(48px, 7vw, 96px)) 0 clamp(48px, 6vw, 80px); }
.hero-x--page .hero-x__field { -webkit-mask-image: radial-gradient(ellipse 70% 90% at 75% 40%, #000 25%, transparent 85%); mask-image: radial-gradient(ellipse 70% 90% at 75% 40%, #000 25%, transparent 85%); }
.hero-x__title--page { max-width: 18ch; font-size: clamp(2.3rem, 5vw, 3.8rem); margin-bottom: 18px; }
.hero-x--page .hero-x__lead { margin-bottom: 0; }

/* Hero shell */
.hero-x {
	position: relative; isolation: isolate; overflow: hidden;
	background: #0a0a0a; color: #fff;
	padding: calc(65px + clamp(56px, 9vw, 120px)) 0 clamp(72px, 9vw, 120px);
	border-bottom: 1px solid #1d1d1d;
}
.hero-x__field {
	position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%;
	-webkit-mask-image: radial-gradient(ellipse 85% 75% at 62% 45%, #000 35%, transparent 90%);
	mask-image: radial-gradient(ellipse 85% 75% at 62% 45%, #000 35%, transparent 90%);
}
.hero-x__glow {
	position: absolute; inset: 0; z-index: -1; pointer-events: none;
	background: radial-gradient(560px circle at var(--mx, 72%) var(--my, 42%), rgba(255,255,255,.07), transparent 62%);
	transition: background .2s linear;
}
.hero-x__grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(40px, 6vw, 88px); align-items: center; }
@media (max-width: 960px) { .hero-x__grid { grid-template-columns: 1fr; } }

/* Copy */
.hero-x__eyebrow {
	display: inline-flex; align-items: center; gap: 10px; margin-bottom: 28px;
	padding: 6px 12px 6px 10px; border-radius: 99px;
	border: 1px solid rgba(255,255,255,.12); background: rgba(255,255,255,.04);
	-webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
	font-family: var(--font-mono); font-size: .74rem; letter-spacing: .06em; text-transform: uppercase;
	color: rgba(255,255,255,.62);
}
.hero-x__live { position: relative; width: 7px; height: 7px; border-radius: 50%; background: #4ade80; }
.hero-x__live::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid #4ade80; opacity: 0; animation: hx-ping 2.4s cubic-bezier(0,0,.2,1) infinite; }

.hero-x__title {
	margin: 0 0 28px; max-width: 11.5ch; color: #fff;
	font-size: clamp(2.7rem, 6.4vw, 4.9rem); line-height: 1.0; letter-spacing: -.048em; font-weight: 600;
}
.hero-x__title .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 .02em .1em 0; margin-bottom: -.1em; }
.hero-x__title .w > span {
	display: inline-block; transform: translateY(108%);
	animation: hx-rise 1s cubic-bezier(.16,.84,.24,1) forwards;
	animation-delay: calc(var(--i) * 65ms + 120ms);
}
.hero-x__title .w--muted > span {
	background: linear-gradient(100deg, #ffffff 0%, #9a9a9a 70%, #6b6b6b 100%);
	-webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-x__lead { max-width: 50ch; margin-bottom: 36px; font-size: clamp(1.05rem, 1.4vw, 1.2rem); line-height: 1.6; color: rgba(255,255,255,.66); }

.hero-x .button--primary { background: #fff; color: #0a0a0a; border-color: #fff; }
.hero-x .button--primary:hover { background: #e9e9e9; color: #0a0a0a; }
.hero-x .button--ghost {
	background: rgba(255,255,255,.04); color: #fff; border-color: rgba(255,255,255,.18);
	-webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.hero-x .button--ghost:hover { background: rgba(255,255,255,.09); border-color: rgba(255,255,255,.34); color: #fff; }
.hero-x .button .icon { transition: transform .25s cubic-bezier(.2,.7,.1,1); }
.hero-x .button:hover .icon { transform: translateX(3px); }
.hero-x .actions__note { color: rgba(255,255,255,.42); margin-top: 6px; }

.hx-fade { opacity: 0; transform: translateY(10px); animation: hx-fade .9s cubic-bezier(.16,.84,.24,1) forwards; animation-delay: calc(var(--d, 0) * 110ms + 200ms); }

/* Glass console */
.hx-stage { perspective: 1400px; }
.hx-card {
	position: relative; border-radius: 18px;
	background: linear-gradient(180deg, rgba(255,255,255,.085), rgba(255,255,255,.025));
	border: 1px solid rgba(255,255,255,.12);
	-webkit-backdrop-filter: blur(20px) saturate(150%); backdrop-filter: blur(20px) saturate(150%);
	box-shadow: 0 40px 100px -30px rgba(0,0,0,.9), 0 0 0 1px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.1);
	transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
	transition: transform .5s cubic-bezier(.16,.84,.24,1);
	will-change: transform;
}
.hx-card::before {
	content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
	background: radial-gradient(420px circle at var(--sx, 50%) var(--sy, -10%), rgba(255,255,255,.1), transparent 55%);
}

.hx-bar { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid rgba(255,255,255,.08); font-family: var(--font-mono); font-size: .74rem; color: rgba(255,255,255,.7); }
.hx-node { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.hx-node__dot { width: 8px; height: 8px; border-radius: 2px; background: #fff; }
.hx-link { position: relative; flex: 1; height: 1px; min-width: 40px; background: linear-gradient(90deg, rgba(255,255,255,.08), rgba(255,255,255,.28), rgba(255,255,255,.08)); }
.hx-link::after { content: ""; position: absolute; top: -2px; left: 0; width: 5px; height: 5px; border-radius: 50%; background: #6ee7a0; box-shadow: 0 0 12px 2px rgba(110,231,160,.7); opacity: 0; }
.hx-link.is-pulse::after { animation: hx-packet .85s cubic-bezier(.45,0,.2,1); }
.hx-link.is-pulse.is-deny::after { background: #f87171; box-shadow: 0 0 12px 2px rgba(248,113,113,.7); animation-name: hx-packet-deny; }
.hx-tag { padding: 2px 7px; border-radius: 99px; border: 1px solid rgba(255,255,255,.14); color: rgba(255,255,255,.45); font-size: .66rem; letter-spacing: .06em; text-transform: uppercase; }

.hx-scopes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 14px; }
.hx-switch {
	position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px;
	padding: 10px 12px; border-radius: 10px; text-align: left; cursor: pointer;
	border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.025); color: rgba(255,255,255,.88);
	font: inherit; font-size: .86rem; line-height: 1.3;
	transition: border-color .25s, background .25s, color .25s;
}
.hx-switch small { display: block; margin-top: 2px; font-family: var(--font-mono); font-size: .68rem; color: rgba(255,255,255,.4); }
.hx-switch:hover { border-color: rgba(255,255,255,.22); background: rgba(255,255,255,.06); }
.hx-switch:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.hx-switch[aria-checked="false"] { color: rgba(255,255,255,.5); }
.hx-switch.is-active { animation: hx-ok .9s ease-out; }
.hx-switch.is-denied { animation: hx-deny .9s ease-out; }
.hx-toggle { position: relative; flex: 0 0 auto; width: 30px; height: 18px; border-radius: 99px; background: rgba(255,255,255,.14); transition: background .3s; }
.hx-toggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.4); transition: transform .35s cubic-bezier(.3,.7,.2,1.25); }
.hx-switch[aria-checked="true"] .hx-toggle { background: #16a34a; }
.hx-switch[aria-checked="true"] .hx-toggle::after { transform: translateX(12px); }

.hx-log {
	display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden;
	height: 138px; margin: 0 14px 12px; padding: 10px 14px; border-radius: 10px;
	background: rgba(0,0,0,.5); border: 1px solid rgba(255,255,255,.06);
	font-family: var(--font-mono); font-size: .74rem; line-height: 1.5;
	-webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 40%); mask-image: linear-gradient(to bottom, transparent 0, #000 40%);
}
.hx-line { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; padding: 2px 0; color: rgba(255,255,255,.82); animation: hx-line .35s ease-out; }
.hx-line time { color: rgba(255,255,255,.32); }
.hx-line .txt { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.hx-line.is-typing .txt::after { content: "▍"; margin-left: 1px; color: rgba(255,255,255,.6); animation: hx-blink 1s steps(1) infinite; }
.hx-line .res { opacity: 0; transform: translateX(-4px); transition: opacity .3s, transform .3s; white-space: nowrap; }
.hx-line.is-done .res { opacity: 1; transform: none; }
.res.ok { color: #6ee7a0; }
.res.deny { color: #f87171; }
.res.warn { color: #fbbf24; }

.hx-foot { display: flex; justify-content: space-between; gap: 12px; padding: 0 16px 14px; font-size: .74rem; color: rgba(255,255,255,.42); }
.hx-count { font-family: var(--font-mono); white-space: nowrap; color: rgba(255,255,255,.6); }

@media (max-width: 480px) {
	.hx-scopes { gap: 6px; padding: 10px; }
	.hx-switch { padding: 9px 10px; font-size: .8rem; }
	.hx-log { margin: 0 10px 10px; height: 124px; font-size: .68rem; }
	.hx-line time { display: none; }
	.hx-foot { flex-direction: column; gap: 4px; }
}

/* Keyframes */
@keyframes hx-rise { to { transform: translateY(0); } }
@keyframes hx-fade { to { opacity: 1; transform: none; } }
@keyframes hx-ping { 0% { transform: scale(.6); opacity: .8; } 100% { transform: scale(2.2); opacity: 0; } }
@keyframes hx-blink { 50% { opacity: 0; } }
@keyframes hx-line { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes hx-packet { 0% { left: 0; opacity: 0; } 12% { opacity: 1; } 88% { opacity: 1; } 100% { left: calc(100% - 5px); opacity: 0; } }
@keyframes hx-packet-deny { 0% { left: 0; opacity: 0; } 12% { opacity: 1; } 55% { left: 48%; opacity: 1; } 70% { left: 46%; } 100% { left: 46%; opacity: 0; } }
@keyframes hx-ok { 0% { border-color: rgba(110,231,160,.7); box-shadow: 0 0 0 3px rgba(110,231,160,.12); } 100% { border-color: rgba(255,255,255,.08); box-shadow: 0 0 0 0 transparent; } }
@keyframes hx-deny { 0%, 100% { transform: none; } 15% { transform: translateX(-3px); border-color: rgba(248,113,113,.7); } 30% { transform: translateX(3px); } 45% { transform: translateX(-2px); } 60% { transform: none; border-color: rgba(248,113,113,.4); } }

@media (prefers-reduced-motion: reduce) {
	.hero-x__title .w > span, .hx-fade { animation: none; transform: none; opacity: 1; }
	.hero-x__live::after, .hx-switch.is-active, .hx-switch.is-denied, .hx-line, .hx-link.is-pulse::after { animation: none; }
	.hx-card { transform: none; transition: none; }
}
