/* Light Theme inspired by Apple.com design language */
:root {
	--bg: #ffffff;
	--text: #111111;
	--muted: #6e6e73;
	--link: #06c;
	--border: #e5e5e7;
	--surface: #f5f5f7;
	--reveal-duration: .6s;
	--reveal-distance: 18px;
}

/***** Dark theme *****/
[data-theme="dark"] {
	--bg: #000000;
	--text: #f5f5f7;
	--muted: #a1a1a6;
	--link: #2997ff;
	--border: #1d1d1f;
	--surface: #0a0a0a;
}

/***** Follow system by default *****/
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #000000;
		--text: #f5f5f7;
		--muted: #a1a1a6;
		--link: #2997ff;
		--border: #1d1d1f;
		--surface: #0a0a0a;
	}
}

/* Base */
* { box-sizing: border-box; }
html, body { height: 100%; }
html { scroll-behavior: smooth; }
body {
	margin: 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
	color: var(--text);
	background: var(--bg);
}

/* Layout */
.container { max-width: 1068px; margin: 0 auto; padding: 0 22px; }
.container-wide { max-width: 1250px; margin: 0 auto; padding: 0 22px; }
@media (min-width: 1440px){ .container-wide { max-width: 1400px; } }
.section { padding: 60px 0; scroll-margin-top: 64px; }
.section--tight { padding: 36px 0; }
.divider { height: 1px; background: var(--border); margin: 0; border: 0; }

/* Full-bleed utility */
.full-bleed { width: 100vw; margin-left: calc(50% - 50vw); }

/* 3D Perspective utility for hero */
.perspective { perspective: 1200px; perspective-origin: 50% 25%; }
#hero-media { transform-style: preserve-3d; transform-origin: 50% 80%; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 80%, transparent); backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid var(--border); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 44px; }
.brand { font-weight: 600; font-size: 14px; letter-spacing: .02em; }
.nav-links { display: flex; gap: 18px; align-items: center; }
.nav a, .nav button { color: var(--text); text-decoration: none; font-size: 12px; background: none; border: 0; cursor: pointer; padding: 0; }
.nav a:hover, .nav button:hover { text-decoration: underline; }

/* Typography */
h1, h2, h3 { margin: 0 0 10px; font-weight: 700; }
.title-xxl { font-size: clamp(36px, 6vw, 72px); line-height: 1.05; letter-spacing: -0.02em; }
.title-xl { font-size: clamp(28px, 5vw, 56px); line-height: 1.06; letter-spacing: -0.02em; }
.title-lg { font-size: clamp(22px, 3.6vw, 32px); line-height: 1.2; font-weight: 700; }
.title-md { font-size: 20px; line-height: 1.3; font-weight: 700; }
.lead { font-size: clamp(16px, 2.2vw, 20px); color: var(--muted); margin: 0; max-width: 70ch; }
.muted { color: var(--muted); }

/* Links as CTAs */
.link { color: var(--link); text-decoration: none; font-weight: 600; position: relative; }
.link::after { content: ""; position: absolute; left: 0; right: 100%; bottom: -2px; height: 1px; background: var(--link); transition: right .25s ease; }
.link:hover::after { right: 0; }
.row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }

/* Tiles */
.tiles { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 734px) { .tiles { grid-template-columns: 1fr 1fr; } }
.tile { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 40px 28px; display: grid; gap: 8px; transition: transform .25s ease, box-shadow .25s ease; will-change: transform, box-shadow; }
.tile:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,0.06); }
.tile h3 { margin: 0; }
.tile .desc { color: var(--muted); margin: 0; }
.tile .actions { display: flex; gap: 16px; margin-top: 6px; }

/* Media */
.media { border-radius: 20px; overflow: hidden; border: 1px solid var(--border); aspect-ratio: 16 / 9; background: var(--surface); display: grid; place-items: center; color: var(--muted); transition: transform .4s ease; will-change: transform; }
.media:hover { transform: scale(1.005); }
.media img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Reveal on scroll (customizable) */
.reveal { opacity: 0; transform: translateY(var(--reveal-distance)); transition: opacity var(--reveal-duration) ease, transform var(--reveal-duration) ease; will-change: opacity, transform; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal.fast { --reveal-duration: .4s; }
.reveal.slow { --reveal-duration: .9s; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	* { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
	.media:hover { transform: none; }
}

/* Footer */
.footer { padding: 40px 0; color: var(--muted); font-size: 12px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; border-top: 1px solid var(--border); } 