/* ==========================================================================
   CSS Variables & Design Tokens
   ========================================================================== */
:root {
	/* Colors */
	--tech-blue-base: #0f172a;
	--tech-blue-dark: #020617;
	--tech-blue-light: #1e293b;
	--tech-blue-glow: rgba(56, 189, 248, 0.4);
	
	--accent-orange: #ff6b00;
	--accent-orange-hover: #ff8533;
	--accent-orange-glow: rgba(255, 107, 0, 0.5);

	/* Text */
	--text-primary: #f8fafc;
	--text-secondary: #94a3b8;
	--text-muted: #64748b;
	
	/* Glass */
	--glass-bg: rgba(30, 41, 59, 0.6);
	--glass-border: rgba(255, 255, 255, 0.08);
	--glass-border-hover: rgba(255, 255, 255, 0.2);
	
	/* Layout */
	--container-width: 1200px;
	--container-padding: 2rem;
	--section-padding: 6rem;
	--border-radius-lg: 16px;
	--border-radius-md: 12px;
	--border-radius-sm: 8px;
	
	/* Typography */
	--font-primary: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
	
	/* Transitions */
	--transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* ==========================================================================
   Resets and Base
   ========================================================================== */
* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

body {
	font-family: var(--font-primary);
	background-color: var(--tech-blue-dark);
	color: var(--text-primary);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow-x: hidden;
}

a {
	color: var(--text-primary);
	text-decoration: none;
	transition: var(--transition-smooth);
}

a:hover {
	color: var(--accent-orange);
}

img {
	max-width: 100%;
	height: auto;
	display: block;
}

h1, h2, h3, h4, h5, h6 {
	font-weight: 700;
	line-height: 1.2;
	margin-bottom: 1rem;
	letter-spacing: -0.02em;
}

/* ==========================================================================
   Utilities & Layout
   ========================================================================== */
.container {
	max-width: var(--container-width);
	margin: 0 auto;
	padding: 0 var(--container-padding);
	width: 100%;
}

.section-padding {
	padding: var(--section-padding) 0;
}

.text-center { text-align: center; }
.text-orange { color: var(--accent-orange); }
.text-blue { color: #38bdf8; }

.eyebrow {
	display: block;
	font-size: 0.875rem;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	margin-bottom: 0.5rem;
}

/* ==========================================================================
   Glassmorphism System
   ========================================================================== */
.glass-header {
	background: rgba(2, 6, 23, 0.7);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	border-bottom: 1px solid var(--glass-border);
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	z-index: 1000;
	transition: var(--transition-smooth);
}

.glass-card {
	background: var(--glass-bg);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	border: 1px solid var(--glass-border);
	border-radius: var(--border-radius-lg);
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
	transition: var(--transition-smooth);
}

.glass-card:hover {
	transform: translateY(-4px);
	border-color: var(--glass-border-hover);
	box-shadow: 0 12px 48px rgba(0, 0, 0, 0.4), 0 0 20px rgba(56, 189, 248, 0.1);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.75rem 1.5rem;
	border-radius: var(--border-radius-sm);
	font-weight: 600;
	font-size: 1rem;
	cursor: pointer;
	border: none;
	transition: var(--transition-smooth);
	white-space: nowrap;
}

.btn-sm {
	padding: 0.5rem 1rem;
	font-size: 0.875rem;
}

.btn-primary {
	background-color: var(--accent-orange);
	color: #fff;
}

.btn-primary:hover {
	background-color: var(--accent-orange-hover);
	color: #fff;
	transform: translateY(-2px);
}

.btn-glow {
	box-shadow: 0 0 15px var(--accent-orange-glow);
}
.btn-glow:hover {
	box-shadow: 0 0 25px var(--accent-orange-glow);
}

.btn-secondary.glass-btn {
	background: rgba(255, 255, 255, 0.05);
	color: var(--text-primary);
	border: 1px solid var(--glass-border);
	backdrop-filter: blur(8px);
}

.btn-secondary.glass-btn:hover {
	background: rgba(255, 255, 255, 0.1);
	border-color: var(--glass-border-hover);
	color: #fff;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.header-container {
	display: flex;
	justify-content: space-between;
	align-items: center;
	height: 80px;
	padding: 0 var(--container-padding);
	max-width: var(--container-width);
	margin: 0 auto;
}

.site-branding .logo-text {
	font-size: 1.5rem;
	font-weight: 700;
	letter-spacing: -0.05em;
	color: var(--text-primary);
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.site-branding .logo-text::before {
	content: '';
	display: block;
	width: 24px;
	height: 24px;
	background: linear-gradient(135deg, var(--tech-blue-glow), var(--accent-orange));
	border-radius: 6px;
}

.main-navigation ul {
	list-style: none;
	display: flex;
	gap: 2rem;
}

.main-navigation a {
	font-size: 0.95rem;
	font-weight: 500;
	color: var(--text-secondary);
}

.main-navigation a:hover {
	color: var(--text-primary);
}

.menu-toggle {
	display: none;
	background: none;
	border: none;
	color: var(--text-primary);
	cursor: pointer;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-tech {
	position: relative;
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding-top: 80px; /* Offset for fixed header */
	text-align: center;
	overflow: hidden;
}

.hero-content {
	position: relative;
	z-index: 10;
	max-width: 800px;
}

.hero-title {
	font-size: clamp(3rem, 6vw, 5rem);
	line-height: 1.1;
	margin-bottom: 1.5rem;
}

.gradient-text {
	background: linear-gradient(to right, #fff, var(--text-secondary));
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
	background-clip: text;
}

.hero-subtitle {
	font-size: clamp(1.125rem, 2vw, 1.35rem);
	color: var(--text-secondary);
	margin-bottom: 2.5rem;
	max-width: 600px;
	margin-left: auto;
	margin-right: auto;
}

.hero-actions {
	display: flex;
	gap: 1rem;
	justify-content: center;
}

/* Decorative Orbs & Backgrounds */
.tech-grid-bg {
	position: absolute;
	inset: 0;
	background-image: 
		linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
		linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
	background-size: 50px 50px;
	z-index: 1;
	mask-image: radial-gradient(circle at center, black, transparent 80%);
	-webkit-mask-image: radial-gradient(circle at center, black, transparent 80%);
}

.blob-blue {
	position: absolute;
	top: 20%;
	left: 15%;
	width: 50vw;
	height: 50vw;
	max-width: 600px;
	max-height: 600px;
	background: var(--tech-blue-base);
	border-radius: 50%;
	filter: blur(100px);
	z-index: 1;
	opacity: 0.6;
	animation: float 20s ease-in-out infinite;
}

.blob-orange {
	position: absolute;
	bottom: 10%;
	right: 15%;
	width: 40vw;
	height: 40vw;
	max-width: 500px;
	max-height: 500px;
	background: rgba(255, 107, 0, 0.15);
	border-radius: 50%;
	filter: blur(80px);
	z-index: 1;
	animation: float 25s ease-in-out infinite reverse;
}

@keyframes float {
	0%, 100% { transform: translate(0, 0); }
	33% { transform: translate(30px, -50px); }
	66% { transform: translate(-20px, 20px); }
}

/* ==========================================================================
   Features Section
   ========================================================================== */
.section-header {
	margin-bottom: 4rem;
}

.section-title {
	font-size: 2.5rem;
	font-weight: 700;
	margin-bottom: 1rem;
}

.section-desc {
	font-size: 1.25rem;
	color: var(--text-secondary);
}

.features-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
	gap: 2rem;
}

.feature-card {
	padding: 2.5rem;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
}

.feature-icon {
	margin-bottom: 1.5rem;
	display: inline-flex;
	padding: 1rem;
	border-radius: var(--border-radius-md);
	background: rgba(255,255,255,0.03);
	border: 1px solid var(--glass-border);
}

.feature-icon svg {
	width: 32px;
	height: 32px;
}

.feature-card h3 {
	font-size: 1.5rem;
	margin-bottom: 1rem;
}

.feature-card p {
	color: var(--text-secondary);
	line-height: 1.7;
}

/* ==========================================================================
   Highlight (Split) Section
   ========================================================================== */
.split-layout {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 4rem;
	align-items: center;
}

.split-content .sub-title {
	font-size: 2.5rem;
	margin-bottom: 1.5rem;
}

.split-content p {
	font-size: 1.125rem;
	color: var(--text-secondary);
}

/* ==========================================================================
   Inner Pages (page.php, index.php)
   ========================================================================== */
.page-main {
	padding-top: 80px;
}

.page-tech-header {
	position: relative;
	padding: 6rem 0 3rem;
	text-align: center;
	border-bottom: 1px solid var(--glass-border);
	background: var(--tech-blue-base);
	overflow: hidden;
}

.ambient-glow {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 80%;
	height: 100%;
	background: radial-gradient(ellipse at center, rgba(56, 189, 248, 0.1) 0%, transparent 70%);
	z-index: 1;
	pointer-events: none;
}

.page-tech-header .container {
	position: relative;
	z-index: 2;
}

.page-title {
	font-size: 3rem;
	margin-bottom: 0;
}

.glow-text {
	text-shadow: 0 0 20px rgba(255,255,255,0.2);
}

.text-content {
	max-width: 800px;
	margin: 0 auto;
	font-size: 1.125rem;
	line-height: 1.8;
	color: var(--text-secondary);
	padding: 3rem; /* Used if wrapped in glass-card */
}

.text-content h1, .text-content h2, .text-content h3 {
	color: var(--text-primary);
	margin-top: 2rem;
	margin-bottom: 1rem;
}

.text-content p {
	margin-bottom: 1.5rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
	background: #000;
	border-top: 1px solid var(--glass-border);
	padding: 4rem 0 2rem;
	margin-top: 4rem;
}

.footer-widgets {
	display: grid;
	grid-template-columns: 2fr 1fr 1fr;
	gap: 3rem;
	max-width: var(--container-width);
	margin: 0 auto 3rem;
	padding: 0 var(--container-padding);
}

.widget-title {
	font-size: 1.125rem;
	margin-bottom: 1.5rem;
	color: #fff;
}

.brand-widget p {
	color: var(--text-muted);
	margin-bottom: 0.5rem;
}

.link-widget ul {
	list-style: none;
}

.link-widget li {
	margin-bottom: 0.75rem;
}

.link-widget a {
	color: var(--text-muted);
}

.link-widget a:hover {
	color: var(--accent-orange);
}

.site-info {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 2rem var(--container-padding) 0;
	max-width: var(--container-width);
	margin: 0 auto;
	border-top: 1px solid rgba(255,255,255,0.05);
	color: var(--text-muted);
	font-size: 0.875rem;
}

.legal-links {
	display: flex;
	gap: 1.5rem;
}

.legal-links a {
	color: var(--text-muted);
}

.legal-links a:hover {
	color: var(--text-primary);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 992px) {
	.split-layout {
		grid-template-columns: 1fr;
		gap: 3rem;
	}
	.footer-widgets {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 768px) {
	:root {
		--section-padding: 4rem;
	}
	.main-navigation ul {
		display: none; /* In a real scenario, implement a hamburger toggle with main.js */
	}
	.menu-toggle {
		display: block;
	}
	.header-actions {
		display: none;
	}
	.hero-actions {
		flex-direction: column;
	}
	.site-info {
		flex-direction: column;
		gap: 1rem;
		text-align: center;
	}
	.text-content {
		padding: 1.5rem;
	}
}

/* ==========================================================================
   Advanced UI Upgrades (Phase 5)
   ========================================================================== */

/* Cyber SVG Background layer */
.cyber-bg-layer {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	z-index: 0;
	pointer-events: none;
	opacity: 0.8;
}

.animated-line {
	animation: scanline 8s linear infinite;
}

@keyframes scanline {
	0% { transform: translateY(-100%); }
	100% { transform: translateY(100vh); }
}

/* Deep Glassmorphism overrides */
.glass-header {
	background: rgba(2, 6, 23, 0.4);
	border-bottom: 1px solid rgba(255, 255, 255, 0.05);
	box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
	backdrop-filter: blur(20px) saturate(150%);
	-webkit-backdrop-filter: blur(20px) saturate(150%);
}

.glass-card {
	background: linear-gradient(135deg, rgba(30, 41, 59, 0.7) 0%, rgba(15, 23, 42, 0.4) 100%);
	backdrop-filter: blur(24px) saturate(120%);
	-webkit-backdrop-filter: blur(24px) saturate(120%);
	border: 1px solid rgba(255, 255, 255, 0.08);
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255,255,255,0.1);
}

.element-hover-glow:hover {
	border-color: rgba(56, 189, 248, 0.4);
	box-shadow: 0 10px 40px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.2), 0 0 20px rgba(56, 189, 248, 0.15);
	transform: translateY(-6px);
}

/* Feature Grid Adjustments */
.features-grid {
	position: relative;
	z-index: 2;
}

.cyber-grid .feature-card {
	position: relative;
	overflow: hidden;
}

.cyber-grid .feature-card::before {
	content: '';
	position: absolute;
	top: -50%;
	left: -50%;
	width: 200%;
	height: 200%;
	background: radial-gradient(circle, rgba(56,189,248,0.05) 0%, transparent 50%);
	opacity: 0;
	transition: opacity 0.5s ease;
	pointer-events: none;
}

.cyber-grid .feature-card:hover::before {
	opacity: 1;
}

/* Hero Badge */
.hero-badge {
	display: inline-block;
	padding: 0.4rem 1rem;
	background: rgba(56,189,248,0.1);
	border: 1px solid rgba(56,189,248,0.3);
	color: #38bdf8;
	border-radius: 20px;
	font-size: 0.85rem;
	font-weight: 600;
	margin-bottom: 1.5rem;
	letter-spacing: 0.05em;
	box-shadow: 0 0 15px rgba(56,189,248,0.2);
}

/* Cyan Blob for extra tech feel */
.blob-cyan {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 30vw;
	height: 30vw;
	background: rgba(34, 211, 238, 0.1);
	border-radius: 50%;
	filter: blur(120px);
	z-index: 0;
	animation: pulse 15s infinite;
}

@keyframes pulse {
	0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
	50% { opacity: 0.8; transform: translate(-50%, -50%) scale(1.2); }
}

/* Terminal Mockup */
.terminal-mockup {
	border-radius: 12px;
	overflow: hidden;
	font-family: 'Fira Code', 'Courier New', Courier, monospace;
	font-size: 0.9rem;
	text-align: left;
}
.terminal-header {
	background: rgba(0,0,0,0.4);
	padding: 0.75rem 1rem;
	border-bottom: 1px solid rgba(255,255,255,0.05);
	display: flex;
	align-items: center;
}
.terminal-header .dot {
	width: 12px;
	height: 12px;
	border-radius: 50%;
	margin-right: 8px;
	display: inline-block;
}
.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27c93f; }
.term-title {
	color: #888;
	margin-left: 1rem;
	font-size: 0.85rem;
}
.terminal-body {
	padding: 1.5rem;
	background: rgba(10, 15, 25, 0.8);
	line-height: 1.6;
}
.term-line {
	margin-bottom: 0.5rem;
}
.term-line.prompt span {
	color: #38bdf8;
	margin-right: 0.5rem;
}
.term-line.output {
	color: #94a3b8;
}
.term-line.output.success {
	color: #22c55e;
}
.term-line.output.info {
	color: #eab308;
}
.cursor-blink {
	animation: blink 1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* Highlight Badges */
.highlight-badges {
	display: flex;
	gap: 1rem;
	margin-top: 2rem;
	flex-wrap: wrap;
}
.tech-badge {
	padding: 0.4rem 0.8rem;
	background: rgba(255,255,255,0.05);
	border: 1px solid rgba(255,255,255,0.1);
	border-radius: 6px;
	font-size: 0.85rem;
	color: #cbd5e1;
}

/* Adjust layout overlaps */
.dynamic-graphic-box {
	position: relative;
	z-index: 2;
}
.deep-glass-box {
	position: relative;
	z-index: 2;
}
