/* ==========================================================================
   AutoSync — Design Tokens
   Palette: signal/broadcast theme, not the generic cream+terracotta default
   ========================================================================== */
:root {
	--bg:          #0B0F1A;
	--surface:     #131A2B;
	--surface-2:   #1A2338;
	--border:      #26314A;

	--text:        #F5F7FA;
	--text-muted:  #8891A8;

	--signal-cyan:   #4FE3C1;
	--signal-violet: #8B7FFF;

	--font-display: 'Space Grotesk', sans-serif;
	--font-body:    'Inter', sans-serif;
	--font-mono:    'IBM Plex Mono', monospace;

	--radius: 14px;
	--wrap: 1160px;
}

/* ==========================================================================
   Reset & base
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font-family: var(--font-body);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}
h1, h2, h3 {
	font-family: var(--font-display);
	line-height: 1.1;
	margin: 0 0 0.5em;
	letter-spacing: -0.01em;
}
p { margin: 0 0 1em; color: var(--text-muted); }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
.mono { font-family: var(--font-mono); }

.wrap {
	max-width: var(--wrap);
	margin: 0 auto;
	padding: 0 24px;
}

:focus-visible {
	outline: 2px solid var(--signal-cyan);
	outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after {
		animation-duration: 0.001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.001ms !important;
	}
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 20px;
	border-radius: 999px;
	font-weight: 600;
	font-size: 0.95rem;
	border: 1px solid transparent;
	transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
	background: linear-gradient(135deg, var(--signal-cyan), var(--signal-violet));
	color: #0B0F1A;
}
.btn-ghost {
	background: transparent;
	color: var(--text);
	border-color: var(--border);
}
.btn-ghost:hover { border-color: var(--signal-cyan); }
.btn-lg { padding: 14px 28px; font-size: 1rem; }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background: rgba(11, 15, 26, 0.85);
	backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--border);
}
.header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-top: 16px;
	padding-bottom: 16px;
}
.brand {
	display: flex;
	align-items: center;
	gap: 10px;
	font-family: var(--font-display);
	font-weight: 700;
	font-size: 1.15rem;
}
.brand-node {
	width: 14px;
	height: 14px;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--signal-cyan), var(--signal-violet));
	box-shadow: 0 0 12px rgba(79, 227, 193, 0.6);
}
.nav-links {
	display: flex;
	gap: 32px;
}
.nav-links a {
	color: var(--text-muted);
	font-size: 0.95rem;
	transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--text); }
.header-actions { display: flex; gap: 12px; align-items: center; }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { padding: 88px 0 40px; }
.hero-inner {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 48px;
	align-items: center;
}
.eyebrow {
	display: inline-block;
	color: var(--signal-cyan);
	font-size: 0.85rem;
	letter-spacing: 0.04em;
	margin-bottom: 18px;
}
.hero h1 {
	font-size: clamp(2.4rem, 4.5vw, 3.6rem);
	font-weight: 700;
}
.hero-sub {
	font-size: 1.1rem;
	max-width: 480px;
}
.hero-actions {
	display: flex;
	gap: 14px;
	margin-top: 28px;
	flex-wrap: wrap;
}

/* Signal pulse SVG */
.pulse-svg { width: 100%; height: auto; }

.ring {
	fill: none;
	stroke: var(--signal-cyan);
	stroke-width: 1.5;
	opacity: 0;
	transform-origin: 300px 300px;
	animation: pulse-ring 3.6s ease-out infinite;
}
.ring-2 { animation-delay: 1.2s; }
.ring-3 { animation-delay: 2.4s; }

@keyframes pulse-ring {
	0%   { transform: scale(0.6); opacity: 0.7; }
	100% { transform: scale(2.6); opacity: 0; }
}

.core {
	fill: var(--surface-2);
	stroke: var(--signal-violet);
	stroke-width: 2;
}
.core-label {
	fill: var(--text);
	font-size: 15px;
	text-anchor: middle;
	letter-spacing: 0.05em;
}

.sync-line {
	stroke: var(--border);
	stroke-width: 2;
	stroke-dasharray: 6 8;
	animation: dash-flow 2.4s linear infinite;
}
@keyframes dash-flow {
	to { stroke-dashoffset: -28; }
}

.node circle {
	fill: var(--surface);
	stroke: var(--border);
	stroke-width: 1.5;
	transition: stroke 0.2s ease;
}
.node-label {
	fill: var(--text-muted);
	font-size: 13px;
	text-anchor: middle;
}
.node-1 circle { animation: node-glow 3.6s ease-in-out infinite; }
.node-2 circle { animation: node-glow 3.6s ease-in-out infinite; animation-delay: 0.4s; }
.node-3 circle { animation: node-glow 3.6s ease-in-out infinite; animation-delay: 0.8s; }
.node-4 circle { animation: node-glow 3.6s ease-in-out infinite; animation-delay: 1.2s; }

@keyframes node-glow {
	0%, 100% { stroke: var(--border); }
	50% { stroke: var(--signal-cyan); }
}

/* ==========================================================================
   Stats
   ========================================================================== */
.stats-bar {
	border-top: 1px solid var(--border);
	border-bottom: 1px solid var(--border);
	background: var(--surface);
}
.stats-inner {
	display: flex;
	justify-content: space-around;
	padding: 36px 24px;
	flex-wrap: wrap;
	gap: 24px;
}
.stat { text-align: center; }
.stat-value {
	display: block;
	font-size: 2rem;
	font-weight: 600;
	background: linear-gradient(135deg, var(--signal-cyan), var(--signal-violet));
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}
.stat-label {
	display: block;
	color: var(--text-muted);
	font-size: 0.85rem;
	margin-top: 4px;
}

/* ==========================================================================
   Features (sync log style)
   ========================================================================== */
.features { padding: 96px 0; }
.features h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); max-width: 600px; margin-bottom: 48px; }

.feature-log {
	border-left: 2px solid var(--border);
	padding-left: 32px;
}
.feature-entry {
	display: grid;
	grid-template-columns: 70px 1fr;
	gap: 24px;
	position: relative;
	padding-bottom: 44px;
}
.feature-entry:last-child { padding-bottom: 0; }
.feature-entry::before {
	content: '';
	position: absolute;
	left: -38px;
	top: 4px;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--signal-cyan);
	box-shadow: 0 0 0 4px var(--bg);
}
.feature-time { color: var(--signal-cyan); font-size: 0.9rem; padding-top: 2px; }
.feature-body h3 { font-size: 1.2rem; margin-bottom: 6px; }
.feature-body p { max-width: 520px; }

/* ==========================================================================
   CTA
   ========================================================================== */
.cta {
	background: var(--surface);
	border-top: 1px solid var(--border);
}
.cta-inner {
	padding: 72px 24px;
	text-align: center;
}
.cta h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-bottom: 28px; }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
	border-top: 1px solid var(--border);
	padding-top: 56px;
}
.footer-inner {
	display: grid;
	grid-template-columns: 2fr 1fr 1fr;
	gap: 32px;
	padding-bottom: 40px;
}
.footer-brand { display: flex; flex-direction: column; gap: 8px; }
.footer-tagline { color: var(--text-muted); font-size: 0.9rem; max-width: 280px; margin-top: 6px; }
.footer-col h4 {
	font-family: var(--font-body);
	font-size: 0.8rem;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--text-muted);
	margin-bottom: 14px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--text); font-size: 0.95rem; }
.footer-col a:hover { color: var(--signal-cyan); }
.footer-bottom {
	border-top: 1px solid var(--border);
	padding: 20px 24px;
	color: var(--text-muted);
	font-size: 0.85rem;
}

/* ==========================================================================
   Generic page content (about/contact fallback)
   ========================================================================== */
.generic-content { padding: 72px 24px; max-width: 780px; }
.generic-content h1 { font-size: 2.2rem; margin-bottom: 24px; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 860px) {
	.hero-inner { grid-template-columns: 1fr; }
	.hero { padding-top: 56px; }
	.nav-links { display: none; }
	.footer-inner { grid-template-columns: 1fr; }
}
