/**
 * Futuristic home – rare, interactive welcome. No plugin/theme disclosure.
 */

@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;600;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
	--fh-bg: #030304;
	--fh-bg-soft: #0a0a0c;
	--fh-text: #eae9e6;
	--fh-text-dim: #6b6a68;
	--fh-accent: #00ffb3;
	--fh-accent-dim: #00c489;
	--fh-line: #1c1c1e;
	--fh-glow: rgba(0, 255, 179, 0.15);
}

.futuristic-home .futuristic-home-header,
.futuristic-home .futuristic-home-footer {
	position: fixed;
	left: 0;
	right: 0;
	z-index: 10;
	pointer-events: auto;
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.75rem;
	font-weight: 500;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--fh-text-dim);
	opacity: 0.9;
}

.futuristic-home .futuristic-home-header {
	top: 0;
	padding: 1.25rem 2rem;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.futuristic-home .futuristic-home-logo {
	color: inherit;
	text-decoration: none;
	transition: color 0.2s;
}
.futuristic-home .futuristic-home-logo:hover { color: var(--fh-accent); }

.fh-status {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	font-size: 0.65rem;
	letter-spacing: 0.18em;
	color: var(--fh-accent-dim);
}
.fh-status-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--fh-accent);
	animation: fhPulse 2s ease-in-out infinite;
}
@keyframes fhPulse {
	0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0, 255, 179, 0.4); }
	50% { opacity: 0.8; }
	70% { box-shadow: 0 0 0 6px rgba(0, 255, 179, 0); }
}

.futuristic-home .futuristic-home-footer {
	bottom: 0;
	padding: 1rem 2rem;
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.futuristic-home .futuristic-home-footer-links {
	display: flex;
	gap: 1rem;
}
.futuristic-home .futuristic-home-footer-links a {
	color: var(--fh-text-dim);
	text-decoration: none;
	font-size: 0.7rem;
	letter-spacing: 0.15em;
	transition: color 0.2s;
}
.futuristic-home .futuristic-home-footer-links a:hover { color: var(--fh-accent); }

/* ----- Canvas / scene ----- */
.fh-scene {
	position: fixed;
	inset: 0;
	overflow: hidden;
	background: var(--fh-bg);
}

/* Animated gradient mesh */
.fh-gradient-mesh {
	position: absolute;
	inset: -50%;
	background: conic-gradient(from 0deg at 50% 50%, rgba(0,255,179,0.06) 0deg, transparent 60deg, rgba(0,255,179,0.04) 120deg, transparent 180deg, rgba(0,200,150,0.05) 240deg, transparent 300deg);
	animation: fhMeshRotate 40s linear infinite;
	pointer-events: none;
}

@keyframes fhMeshRotate {
	to { transform: rotate(360deg); }
}

/* Perspective grid */
.fh-grid {
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(var(--fh-line) 1px, transparent 1px),
		linear-gradient(90deg, var(--fh-line) 1px, transparent 1px);
	background-size: 48px 48px;
	transform: perspective(400px) rotateX(60deg) scale(1.5);
	transform-origin: 50% 0%;
	opacity: 0.4;
	animation: fhGridMove 24s linear infinite;
}

@keyframes fhGridMove {
	0% { background-position: 0 0; }
	100% { background-position: 0 48px; }
}

/* Radial vignette + gradient */
.fh-vignette {
	position: absolute;
	inset: 0;
	background: radial-gradient(ellipse 80% 60% at 50% 0%, var(--fh-glow) 0%, transparent 50%),
	            radial-gradient(ellipse 100% 100% at 50% 100%, transparent 60%, var(--fh-bg) 100%);
	pointer-events: none;
}

/* Noise overlay */
.fh-noise {
	position: absolute;
	inset: 0;
	opacity: 0.03;
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
	pointer-events: none;
}

/* Floating orbs — wrapper for parallax, inner for blob + float */
.fh-orbs { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.fh-orb { position: absolute; }
.fh-orb-inner {
	display: block;
	border-radius: 50%;
	background: radial-gradient(circle, var(--fh-accent) 0%, transparent 70%);
	opacity: 0.06;
	animation: fhOrbFloat 18s ease-in-out infinite;
}
.fh-orb--1 { top: 12%; left: 8%; }
.fh-orb--1 .fh-orb-inner { width: 180px; height: 180px; animation-delay: 0s; }
.fh-orb--2 { top: 60%; right: 12%; }
.fh-orb--2 .fh-orb-inner { width: 140px; height: 140px; animation-delay: -5s; animation-duration: 22s; }
.fh-orb--3 { bottom: 20%; left: 18%; }
.fh-orb--3 .fh-orb-inner { width: 100px; height: 100px; animation-delay: -10s; animation-duration: 20s; }
.fh-orb--4 { top: 25%; right: 25%; }
.fh-orb--4 .fh-orb-inner { width: 120px; height: 120px; animation-delay: -7s; animation-duration: 25s; }
@keyframes fhOrbFloat {
	0%, 100% { transform: translate(0, 0) scale(1); }
	25% { transform: translate(15px, -20px) scale(1.05); }
	50% { transform: translate(-10px, 15px) scale(0.95); }
	75% { transform: translate(20px, 10px) scale(1.02); }
}

/* Scan line */
.fh-scanline {
	position: absolute;
	left: 0;
	right: 0;
	height: 2px;
	background: linear-gradient(to bottom, transparent, var(--fh-accent), transparent);
	opacity: 0.04;
	animation: fhScanline 6s linear infinite;
	pointer-events: none;
}
@keyframes fhScanline {
	0% { top: -2px; }
	100% { top: 100%; }
}

/* Boot overlay */
.fh-boot-overlay {
	position: absolute;
	inset: 0;
	z-index: 50;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--fh-bg);
	transition: opacity 0.6s ease;
	pointer-events: none;
}
.fh-boot-text {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.7rem;
	letter-spacing: 0.4em;
	color: var(--fh-text-dim);
	opacity: 0.8;
	animation: fhBootPulse 0.8s ease-in-out infinite;
}
@keyframes fhBootPulse {
	0%, 100% { opacity: 0.5; }
	50% { opacity: 1; }
}
body.fh-boot-done .fh-boot-overlay {
	opacity: 0;
	pointer-events: none;
}

/* Mouse-follow glow */
.fh-cursor-glow {
	position: fixed;
	width: 420px;
	height: 420px;
	margin: -210px 0 0 -210px;
	border-radius: 50%;
	background: radial-gradient(circle, var(--fh-glow) 0%, transparent 70%);
	pointer-events: none;
	z-index: 1;
	opacity: 0;
	transition: opacity 0.2s ease;
}

.fh-cursor-glow.visible {
	opacity: 1;
}

@media (hover: none) {
	.fh-cursor-glow { display: none; }
}

/* Custom cursor dot (JS-created, shown when hover capable) */
.fh-cursor-dot {
	position: fixed;
	width: 8px;
	height: 8px;
	margin: -4px 0 0 -4px;
	border-radius: 50%;
	background: var(--fh-accent);
	box-shadow: 0 0 12px var(--fh-accent);
	pointer-events: none;
	z-index: 9999;
	display: none;
	transition: transform 0.1s ease-out, opacity 0.15s;
}
body.fh-cursor-dot-active .fh-cursor-dot { display: block; }
body.fh-cursor-dot-active { cursor: none; }
body.fh-cursor-dot-active * { cursor: none; }

/* ----- Main content ----- */
.fh-main {
	position: relative;
	z-index: 5;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 2.5rem 1.5rem 7rem;
	text-align: center;
	gap: 0;
}

/* HUD corners */
.fh-corners {
	position: absolute;
	inset: 1.5rem;
	pointer-events: none;
	z-index: 2;
}
.fh-corner {
	position: absolute;
	width: 28px;
	height: 28px;
	border-color: var(--fh-accent);
	border-style: solid;
	border-width: 0;
	opacity: 0.5;
}
.fh-corner--tl { top: 0; left: 0; border-top-width: 2px; border-left-width: 2px; border-radius: 4px 0 0 0; }
.fh-corner--tr { top: 0; right: 0; border-top-width: 2px; border-right-width: 2px; border-radius: 0 4px 0 0; }
.fh-corner--bl { bottom: 0; left: 0; border-bottom-width: 2px; border-left-width: 2px; border-radius: 0 0 0 4px; }
.fh-corner--br { bottom: 0; right: 0; border-bottom-width: 2px; border-right-width: 2px; border-radius: 0 0 4px 0; }

/* Welcome title — split letters, 3D depth */
.fh-welcome {
	font-family: 'Syne', sans-serif;
	font-weight: 800;
	font-size: clamp(2.75rem, 11vw, 6.5rem);
	line-height: 0.95;
	letter-spacing: -0.02em;
	color: var(--fh-text);
	margin: 0 0 0.35rem;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.02em;
	transform: perspective(900px) rotateX(4deg);
	transform-style: preserve-3d;
	text-shadow: 0 0 50px rgba(0,255,179,0.12), 0 4px 12px rgba(0,0,0,0.4);
}

.fh-welcome .fh-char {
	display: inline-block;
	opacity: 0;
	transform: translateY(20px);
	background: linear-gradient(135deg, var(--fh-text) 0%, var(--fh-accent) 50%, var(--fh-text) 100%);
	background-size: 200% auto;
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
	background-clip: text;
	animation: fhCharReveal 0.6s ease forwards, fhShimmer 6s ease-in-out 0.5s infinite;
}
@keyframes fhCharReveal {
	to { opacity: 1; transform: translateY(0); }
}

@keyframes fhReveal {
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes fhShimmer {
	0%, 100% { background-position: 0% center; }
	50% { background-position: 100% center; }
}

/* Subtitle */
.fh-sub {
	font-family: 'JetBrains Mono', monospace;
	font-size: clamp(0.7rem, 2.5vw, 0.9rem);
	font-weight: 400;
	letter-spacing: 0.3em;
	text-transform: uppercase;
	color: var(--fh-text-dim);
	margin: 0 0 1rem;
	opacity: 0;
	animation: fhReveal 0.8s ease 0.5s forwards;
}

/* Live date & time */
.fh-datetime {
	font-family: 'JetBrains Mono', monospace;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.15rem;
	margin-bottom: 1.5rem;
	opacity: 0;
	animation: fhReveal 0.7s ease 0.6s forwards;
}
.fh-datetime .fh-time {
	font-size: clamp(1rem, 3vw, 1.35rem);
	font-weight: 500;
	letter-spacing: 0.15em;
	color: var(--fh-accent);
}
.fh-datetime .fh-date {
	font-size: 0.7rem;
	letter-spacing: 0.12em;
	color: var(--fh-text-dim);
}

/* Visitor HUD block */
.fh-visitor {
	margin-top: 2rem;
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.8rem;
	font-weight: 500;
	letter-spacing: 0.08em;
	color: var(--fh-text-dim);
	opacity: 0;
	animation: fhReveal 0.8s ease 0.9s forwards;
}

.fh-visitor { perspective: 1200px; }
.fh-visitor-inner {
	position: relative;
	padding: 0;
	border: 1px solid var(--fh-line);
	border-radius: 12px;
	background: rgba(10, 10, 12, 0.8);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.04), inset 0 0 60px rgba(0, 255, 179, 0.03);
	text-align: left;
	min-width: 300px;
	max-width: 580px;
	max-height: 65vh;
	overflow-y: auto;
	transform-style: preserve-3d;
	transition: transform 0.12s ease-out;
	will-change: transform;
}

.fh-visitor-inner::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	width: 4px;
	height: 100%;
	border-radius: 10px 0 0 10px;
	background: var(--fh-accent);
	opacity: 0.7;
}

.fh-visitor-head {
	font-size: 0.65rem;
	letter-spacing: 0.25em;
	text-transform: uppercase;
	color: var(--fh-accent);
	padding: 1rem 1.25rem 0.5rem 1.5rem;
	border-bottom: 1px solid var(--fh-line);
	margin-bottom: 0.5rem;
}

.fh-visitor-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.15rem 1.75rem;
	padding: 0 1.25rem 1.25rem 1.5rem;
}

@media (max-width: 520px) {
	.fh-visitor-grid { grid-template-columns: 1fr; gap: 0.15rem 0; }
	.fh-visitor-inner { min-width: 260px; max-width: 94vw; }
}

.fh-visitor-section {
	grid-column: 1 / -1;
	font-size: 0.6rem;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--fh-accent-dim);
	margin-top: 0.75rem;
	padding-top: 0.25rem;
}

.fh-visitor-section:first-child { margin-top: 0; padding-top: 0; }

.fh-visitor-row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 0.75rem;
	min-height: 1.4em;
}

.fh-visitor-label {
	flex-shrink: 0;
	font-size: 0.68rem;
	letter-spacing: 0.12em;
	color: var(--fh-text-dim);
}

.fh-visitor-value {
	color: var(--fh-text);
	font-size: 0.8rem;
	letter-spacing: 0.05em;
	text-align: right;
	word-break: break-word;
}

.fh-visitor .fh-loading {
	color: var(--fh-text-dim);
}

.fh-visitor .fh-loading::after {
	content: '';
	display: inline-block;
	width: 4px;
	height: 1em;
	background: var(--fh-accent);
	margin-left: 2px;
	animation: fhBlink 1s step-end infinite;
	vertical-align: -0.15em;
}

@keyframes fhBlink {
	50% { opacity: 0; }
}

.fh-visitor-inner::-webkit-scrollbar { width: 6px; }
.fh-visitor-inner::-webkit-scrollbar-track { background: var(--fh-line); }
.fh-visitor-inner::-webkit-scrollbar-thumb { background: var(--fh-text-dim); border-radius: 3px; }
.fh-visitor-inner::-webkit-scrollbar-thumb:hover { background: var(--fh-accent-dim); }

/* Action buttons */
.fh-actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.75rem 1.25rem;
	margin-top: 2rem;
	opacity: 0;
	animation: fhReveal 0.8s ease 1s forwards;
}
.fh-btn {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.75rem;
	font-weight: 500;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--fh-accent);
	background: transparent;
	border: 1px solid var(--fh-line);
	border-radius: 8px;
	padding: 0.65rem 1.35rem;
	text-decoration: none;
	transition: border-color 0.25s, color 0.25s, box-shadow 0.25s, transform 0.18s ease-out;
}
.fh-btn:hover {
	color: var(--fh-text);
	border-color: var(--fh-accent-dim);
	box-shadow: 0 0 24px rgba(0, 255, 179, 0.2), 0 0 48px rgba(0, 255, 179, 0.08);
}

/* Sonar ring (decorative) */
.fh-sonar {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 120px;
	height: 120px;
	margin: -60px 0 0 -60px;
	border: 1px solid var(--fh-line);
	border-radius: 50%;
	opacity: 0.3;
	animation: fhSonar 4s ease-out infinite;
	pointer-events: none;
}

@keyframes fhSonar {
	0% {
		transform: scale(0.6);
		opacity: 0.5;
	}
	100% {
		transform: scale(2.2);
		opacity: 0;
	}
}

.fh-main .fh-sonar:nth-child(3) { animation-delay: 1.33s; }
.fh-main .fh-sonar:nth-child(4) { animation-delay: 2.66s; }

/* ----- Prefers-reduced-motion: less motion, same structure ----- */
@media (prefers-reduced-motion: reduce) {
	.fh-gradient-mesh { animation: none; opacity: 0.5; }
	.fh-grid { animation: none; }
	.fh-orb-inner { animation: none; }
	.fh-scanline { animation: none; opacity: 0.02; }
	.fh-sonar { animation: none; opacity: 0.15; }
	.fh-boot-text { animation: none; }
	.fh-welcome .fh-char { animation: fhCharReveal 0.5s ease forwards; }
	.fh-visitor-inner { transition: none; }
	.fh-btn { transition: border-color 0.2s, color 0.2s, box-shadow 0.2s; }
}
