/* Hypermodern Dark Theme — Luke Bullimore */

/* Design tokens */
:root {
  --bg-0: #0b0f14; /* page */
  --bg-1: #0e141b; /* surface */
  --bg-2: #121a24; /* elevated */
  --text-0: #e6edf3; /* high */
  --text-1: #a1adbb; /* low */
  --muted: #7e8a98;
  color-scheme: dark;
  --header-h: 64px;

  --accent-1: #6cf0ff; /* cyan */
  --accent-2: #8a7dff; /* violet */
  --accent-3: #ff6ec7; /* magenta */

  --ring: color-mix(in lab, var(--accent-1) 60%, var(--accent-3));

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 20px;
  --shadow-1: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-2: 0 20px 50px rgba(0, 0, 0, 0.45);

  --container: 1120px;
  --gutter: clamp(16px, 2vw, 28px);
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial;
  color: var(--text-0);
  background: var(--bg-0);
  line-height: 1.6;
}

img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; margin: 0; }

.skip-link {
  position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden;
}
.skip-link:focus { left: var(--gutter); top: var(--gutter); width: auto; height: auto; padding: 8px 12px; background: var(--bg-2); border-radius: var(--radius-sm); box-shadow: var(--shadow-1); }

/* Background layers */
.bg { position: fixed; inset: 0; z-index: -1; overflow: clip; }
.bg__gradient { position: absolute; inset: -10%; filter: blur(80px); background:
  radial-gradient(40% 40% at 20% 10%, color-mix(in lab, var(--accent-1) 25%, transparent) 0, transparent 70%),
  radial-gradient(30% 30% at 90% 20%, color-mix(in lab, var(--accent-3) 22%, transparent) 0, transparent 70%),
  radial-gradient(35% 35% at 50% 80%, color-mix(in lab, var(--accent-2) 18%, transparent) 0, transparent 70%);
  animation: floatGrad 22s linear infinite alternate;
}
.bg__stars { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.bg__grid { position: absolute; inset: 0; background:
  linear-gradient(to right, rgba(255,255,255,.03) 1px, transparent 1px),
  linear-gradient(to bottom, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(70% 50% at 50% 50%, #000 60%, transparent 100%);
  animation: drift 60s linear infinite;
}
.bg__noise { position: absolute; inset: 0; opacity: .06; background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency="0.9" numOctaves="2" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23n)" opacity="0.45"/></svg>'); mix-blend-mode: overlay; }

@keyframes floatGrad { from { transform: translateY(-2%); } to { transform: translateY(2%); } }
@keyframes drift { from { background-position: 0 0, 0 0; } to { background-position: 200px 200px, 200px 200px; } }

/* Layout */
.container { width: min(100% - 2*var(--gutter), var(--container)); margin-inline: auto; }
.section { padding: clamp(56px, 8vw, 120px) 0; }
.section--tight { padding: clamp(40px, 6vw, 80px) 0; }
.section__header { max-width: 720px; margin-bottom: clamp(20px, 3vw, 36px); }
.section__header h2 { font-family: "Space Grotesk", Inter, system-ui; font-size: clamp(28px, 6vw, 40px); line-height: 1.1; margin: 0 0 6px; }
.section__header p { color: var(--text-1); margin: 0; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 100; backdrop-filter: saturate(140%) blur(10px); background: color-mix(in lab, var(--bg-0) 94%, transparent); border-bottom: 1px solid rgba(255,255,255,.08); }
.header__inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; position: relative; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: .3px; }
.brand__dot { width: 10px; height: 10px; border-radius: 999px; background: linear-gradient(135deg, var(--accent-1), var(--accent-3)); box-shadow: 0 0 14px color-mix(in lab, var(--ring) 50%, transparent); }
.nav ul { display: flex; gap: 18px; align-items: center; }
.nav a { padding: 8px 12px; border-radius: 999px; color: var(--text-1); transition: color .2s, background-color .2s, box-shadow .2s; }
.nav a:hover { color: var(--text-0); background: rgba(255,255,255,.04); }
.nav__cta { border: 1px solid rgba(255,255,255,.08); }

/* Mobile nav */
.nav__toggle { display: none; position: relative; width: 40px; height: 40px; border-radius: 10px; border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.06); color: var(--text-0); cursor: pointer; align-items: center; justify-content: center; z-index: 80; -webkit-appearance: none; appearance: none; -webkit-tap-highlight-color: transparent; }
.nav__toggle:hover { background: rgba(255,255,255,.09); }
.nav__toggle:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
.nav__bars, .nav__bars::before, .nav__bars::after { content: ""; display: block; width: 18px; height: 2px; background: var(--text-0); border-radius: 2px; position: relative; transition: transform .2s ease, opacity .2s ease; }
.nav__bars::before { position: absolute; top: -6px; }
.nav__bars::after { position: absolute; top: 6px; }

@media (max-width: 820px) {
  .nav__toggle { display: inline-flex; }
  .nav { position: fixed; inset: var(--header-h) 0 auto 0; background: rgba(11,15,20,.96); border-bottom: 1px solid rgba(255,255,255,.10); backdrop-filter: blur(10px); z-index: 70; opacity: 0; transform: translateY(0); pointer-events: none; visibility: hidden; transition: opacity .2s ease, transform .2s ease, visibility .2s ease; box-shadow: 0 8px 30px rgba(0,0,0,.35); }
  .nav ul { flex-direction: column; align-items: stretch; gap: 0; }
  .nav li + li a { border-top: 1px solid rgba(255,255,255,.06); }
  .nav a { padding: 14px var(--gutter); display: block; border-radius: 0; background: transparent; }
  .nav a:hover { background: rgba(255,255,255,.06); }
  .nav .nav__cta { border: none; }
  .nav.is-open { opacity: 1; transform: translateY(0); pointer-events: auto; visibility: visible; }
  /* ensure space for the toggle so links (e.g. Contact) don't sit under it */
  .header__inner { padding-right: calc(40px + 12px); }
  #nav-toggle { position: absolute; right: 0; top: 50%; transform: translateY(-50%); }
}

/* Toggle animation to X */
.nav__toggle[aria-expanded="true"] .nav__bars { transform: rotate(45deg); }
.nav__toggle[aria-expanded="true"] .nav__bars::before { transform: rotate(90deg) translateX(0); top: 0; }
.nav__toggle[aria-expanded="true"] .nav__bars::after { opacity: 0; }

/* Hero */
.hero { padding-top: clamp(32px, 6vw, 64px); }
.grid-two { display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; gap: clamp(24px, 4vw, 48px); }
@media (max-width: 900px) { .grid-two { grid-template-columns: 1fr; } }
.stack > * { margin: 0 0 18px; }
.hero__title { font-family: "Space Grotesk", Inter, system-ui; font-weight: 800; letter-spacing: -0.02em; font-size: clamp(34px, 7vw, 64px); line-height: 1.05; margin: 0; }
.txt-gradient { background: linear-gradient(90deg, var(--accent-1), var(--accent-3)); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: 0 0 22px color-mix(in lab, var(--ring) 35%, transparent); }
.hero__subtitle { color: var(--text-1); font-size: clamp(16px, 2.5vw, 22px); min-height: 1.6em; }
.hero__subtitle #role-rotator { display: inline-block; transition: transform .35s ease, opacity .35s ease; will-change: transform, opacity; }
.role-in { opacity: 1; transform: translateY(0); }
.role-out { opacity: 0; transform: translateY(8px); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
.chiplist { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.chip { padding: 6px 12px; border-radius: 999px; background: rgba(255,255,255,.05); color: var(--text-1); border: 1px solid rgba(255,255,255,.06); }

.hero__visual { position: relative; height: min(420px, 60vh); display: grid; place-items: center; }
.orb { position: absolute; border-radius: 999px; filter: blur(8px) saturate(120%); opacity: .7; mix-blend-mode: screen; z-index: 0; }
.orb--one { width: 240px; height: 240px; background: radial-gradient(circle at 30% 30%, var(--accent-1), transparent 60%); animation: float1 12s ease-in-out infinite; }
.orb--two { width: 320px; height: 320px; background: radial-gradient(circle at 70% 40%, var(--accent-3), transparent 60%); animation: float2 14s ease-in-out infinite; }
@keyframes float1 { 0% { transform: translate(-20px, -10px); } 50% { transform: translate(20px, 10px); } 100% { transform: translate(-20px, -10px); } }
@keyframes float2 { 0% { transform: translate(10px, 0px); } 50% { transform: translate(-14px, 6px); } 100% { transform: translate(10px, 0px); } }

.glass-card { position: relative; border-radius: var(--radius-lg); background: linear-gradient(180deg, rgba(18,26,36,.82), rgba(18,26,36,.62)); border: 1px solid rgba(255,255,255,.14); box-shadow: var(--shadow-2), inset 0 1px 0 rgba(255,255,255,.12); overflow: clip; backdrop-filter: blur(10px) saturate(140%); z-index: 1; }
.glass-card p { color: var(--text-1); text-shadow: 0 1px 0 rgba(0,0,0,.25); }
.glass-card__inner { padding: 22px; }
.glass-card h3 { margin: 0 0 6px; font-family: "Space Grotesk", Inter, system-ui; }
.glass-card p { margin: 0; color: var(--text-1); }
.progress { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 16px; }
.progress span { display: grid; place-items: center; height: 10px; border-radius: 999px; background: linear-gradient(90deg, var(--accent-1), var(--accent-3)); position: relative; }
.progress span::before { content: attr(title); position: absolute; top: -28px; font-size: 12px; color: var(--muted); }
.progress span::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--accent-1), var(--accent-3)); border-radius: 999px; transform: scaleX(var(--p)); transform-origin: left; }

/* Buttons */
.btn { --glow: color-mix(in lab, var(--ring) 35%, transparent); display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 10px 16px; border-radius: 12px; border: 1px solid rgba(255,255,255,.10); color: var(--text-0); background: rgba(255,255,255,.04); box-shadow: 0 0 0 0 var(--glow); transition: transform .15s ease, box-shadow .25s ease, background-color .2s ease, border-color .2s ease; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 0 0 8px var(--glow); }
.btn:active { transform: translateY(0); }
.btn--primary { background: linear-gradient(135deg, var(--accent-1), var(--accent-3)); border-color: rgba(255,255,255,.14); color: #0b0f14; font-weight: 700; }
.btn--ghost { background: rgba(255,255,255,.03); }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2.5vw, 28px); }
@media (max-width: 1000px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 680px) { .cards { grid-template-columns: 1fr; } }
.card { border-radius: var(--radius-lg); background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02)); border: 1px solid rgba(255,255,255,.12); padding: 18px; box-shadow: var(--shadow-1); position: relative; overflow: clip; }
.card__tag { position: absolute; top: 12px; right: 12px; padding: 6px 10px; font-size: 12px; color: var(--text-0); border: 1px solid rgba(255,255,255,.12); background: rgba(255,255,255,.04); border-radius: 999px; }
.card h3 { margin: 6px 0 8px; font-family: "Space Grotesk", Inter, system-ui; }
.card p { margin: 0 0 14px; color: var(--text-1); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; color: var(--muted); font-size: 13px; }
.card__actions { display: flex; gap: 10px; margin-top: 18px; }

/* Timeline */
.timeline { display: grid; gap: 20px; position: relative; }
.timeline::before { content: ""; position: absolute; left: 10px; top: 0; bottom: 0; width: 2px; background: linear-gradient(var(--accent-1), var(--accent-3)); opacity: .4; }
.timeline__item { display: grid; grid-template-columns: 32px 1fr; gap: 14px; padding-left: 6px; }
.timeline__dot { width: 22px; height: 22px; border-radius: 999px; background: linear-gradient(135deg, var(--accent-1), var(--accent-3)); box-shadow: 0 0 16px color-mix(in lab, var(--ring) 60%, transparent); margin-top: 4px; }
.timeline__content h3 { margin: 0; font-size: 18px; }
.timeline .muted { color: var(--muted); margin: 4px 0 8px; }

/* CTA */
.cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; padding: clamp(18px, 3vw, 28px); }
.cta__content h2 { margin: 0 0 6px; font-family: "Space Grotesk", Inter, system-ui; font-size: clamp(22px, 4vw, 32px); }
.cta__content p { margin: 0; color: var(--text-1); }

/* Footer */
.site-footer { border-top: 1px solid rgba(255,255,255,.08); padding: 18px 0 40px; }
.footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.socials { display: flex; gap: 12px; }
.socials a { color: var(--text-1); }
.socials a:hover { color: var(--text-0); }

/* Astro companion */
.astro-wrap { position: fixed; right: 16px; bottom: 16px; display: inline-block; z-index: 60; }
.astro { width: 88px; height: 88px; object-fit: contain; filter: drop-shadow(0 10px 20px rgba(0,0,0,.5)); cursor: pointer; animation: bob 5.5s ease-in-out infinite; display: block; }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.astro__bubble { position: absolute; bottom: 100%; right: 0; margin-bottom: 8px; max-width: 280px; background: rgba(18,26,36,.88); border: 1px solid rgba(255,255,255,.14); color: var(--text-0); padding: 10px 12px; border-radius: 12px; box-shadow: var(--shadow-2); font-size: 14px; line-height: 1.4; transform-origin: bottom right; transform: scale(.9) translateY(6px); opacity: 0; pointer-events: none; transition: opacity .25s ease, transform .25s ease; }
.astro-wrap.is-open .astro__bubble { opacity: 1; transform: scale(1) translateY(0); pointer-events: auto; }

/* Reveal on scroll */
[data-reveal] { opacity: 0; transform: translateY(8px) scale(.98); filter: saturate(.8); transition: opacity .6s ease, transform .6s ease, filter .6s ease; }
.is-visible { opacity: 1 !important; transform: translateY(0) scale(1) !important; filter: saturate(1) !important; }

/* Tilt */
.tilt { transform-style: preserve-3d; transform: perspective(800px) rotateX(0) rotateY(0); will-change: transform; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}


