/* ==========================================================================
   Atlaxena — gold (Atlas, cream shiba) × ice (Xena, black & white husky)
   ========================================================================== */
:root {
  --bg: #07080f;
  --bg-2: #0c0e1a;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-2: rgba(255, 255, 255, 0.07);
  --line: rgba(255, 255, 255, 0.09);
  --text: #eef1f8;
  --muted: #9aa3b8;
  --gold: #f2c98a;
  --gold-2: #e0a95a;
  --ice: #8fd8ff;
  --ice-2: #4aa8ec;
  --violet: #8b6cff;
  --grad-gold: linear-gradient(180deg, #fff1d4 0%, #f2c98a 45%, #d9973f 100%);
  --grad-ice: linear-gradient(180deg, #ffffff 0%, #bfe9ff 45%, #4aa8ec 100%);
  --grad-brand: linear-gradient(100deg, #f2c98a 0%, #ffe9c4 35%, #dff4ff 60%, #6cc8ff 100%);
  --radius: 22px;
  --display: "Unbounded", "Arial Black", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* film grain */
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 100; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-family: var(--display); letter-spacing: -0.02em; line-height: 1.05; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
::selection { background: var(--gold); color: var(--bg); }
:focus-visible { outline: 2px solid var(--ice); outline-offset: 3px; border-radius: 6px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; padding: 10px 16px; background: var(--gold); color: var(--bg); border-radius: 10px; font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--gutter);
  transition: background .3s, border-color .3s, backdrop-filter .3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled { background: rgba(7, 8, 15, .72); backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%); border-color: var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark { width: 30px; height: 30px; transition: transform .5s cubic-bezier(.2,.8,.2,1.4); }
.brand:hover .brand-mark { transform: rotate(-8deg) scale(1.08); }
.brand-name { font: 700 18px/1 var(--display); letter-spacing: -0.01em; }
.nav-links { display: flex; align-items: center; gap: clamp(6px, 2vw, 28px); }
.nav-links a { text-decoration: none; font-size: 15px; font-weight: 500; color: var(--muted); transition: color .2s; padding: 6px 2px; }
.nav-links a:hover { color: var(--text); }
.nav-links .nav-cta { color: var(--bg); background: var(--text); padding: 9px 16px; border-radius: 999px; font-weight: 600; }
.nav-links .nav-cta:hover { color: var(--bg); background: var(--gold); }
@media (max-width: 640px) {
  .nav-links li:not(:last-child) { display: none; }
  .brand-name { font-size: 16px; }
}

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 24px; border-radius: 999px; font-weight: 600; font-size: 16px; text-decoration: none;
  transition: transform .25s cubic-bezier(.2,.8,.2,1.2), box-shadow .25s, background .25s;
  will-change: transform;
}
.btn-primary { color: #0a0b14; background: linear-gradient(100deg, #f2c98a, #ffe9c4, #bfe9ff, #6cc8ff, #bfe9ff, #ffe9c4, #f2c98a); background-size: 200% 100%; box-shadow: 0 10px 30px -10px rgba(143, 216, 255, .55), 0 0 0 1px rgba(255,255,255,.3) inset; animation: sheen 6s linear infinite; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 40px -10px rgba(242, 201, 138, .65), 0 0 0 1px rgba(255,255,255,.4) inset; }
.btn-ghost { color: var(--text); background: var(--surface); border: 1px solid var(--line); backdrop-filter: blur(6px); }
.btn-ghost:hover { background: var(--surface-2); transform: translateY(-2px); }
.btn-lg { padding: 18px 32px; font-size: clamp(16px, 2.4vw, 20px); }
@keyframes sheen { to { background-position: -200% 0; } }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: grid; place-items: center; text-align: center;
  padding: 120px var(--gutter) 100px; overflow: hidden; isolation: isolate;
}
.sky { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.aurora { position: absolute; inset: 0; z-index: -2; pointer-events: none; filter: blur(60px); opacity: .75; }
.aurora span { position: absolute; border-radius: 50%; mix-blend-mode: screen; will-change: transform; }
.aurora span:nth-child(1) { width: 55vmax; height: 40vmax; left: -15vmax; top: -10vmax; background: radial-gradient(closest-side, rgba(242,201,138,.55), transparent); animation: drift1 18s ease-in-out infinite alternate; }
.aurora span:nth-child(2) { width: 60vmax; height: 45vmax; right: -20vmax; top: -5vmax; background: radial-gradient(closest-side, rgba(74,168,236,.55), transparent); animation: drift2 22s ease-in-out infinite alternate; }
.aurora span:nth-child(3) { width: 50vmax; height: 30vmax; left: 20vmax; bottom: -18vmax; background: radial-gradient(closest-side, rgba(139,108,255,.45), transparent); animation: drift3 26s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(12vmax, 8vmax) scale(1.15); } }
@keyframes drift2 { to { transform: translate(-14vmax, 10vmax) scale(.9); } }
@keyframes drift3 { to { transform: translate(-10vmax, -8vmax) scale(1.2); } }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 30%; background: linear-gradient(transparent, var(--bg)); z-index: -1; }

.hero-inner { width: 100%; max-width: 1200px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface);
  font-size: 13px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
  backdrop-filter: blur(6px);
}
@media (max-width: 600px) { .wordmark { font-size: 15vw; } }
@media (max-width: 480px) { .eyebrow { font-size: 11px; letter-spacing: .06em; padding: 7px 12px; } }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: #5df2a8; box-shadow: 0 0 0 0 rgba(93,242,168,.6); animation: pulse 2s infinite; flex: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(93,242,168,0); } 100% { box-shadow: 0 0 0 0 rgba(93,242,168,0); } }

.wordmark {
  margin: 28px 0 22px;
  font-weight: 900; font-size: clamp(40px, 12.2vw, 176px); line-height: .95; letter-spacing: -0.045em;
  display: flex; justify-content: center; white-space: nowrap;
}
.wm-atla, .wm-xena { display: inline-block; -webkit-background-clip: text; background-clip: text; color: transparent; }
.wm-atla { background-image: var(--grad-gold); animation: rise .9s cubic-bezier(.2,.8,.2,1) both; }
.wm-xena { background-image: var(--grad-ice); animation: rise .9s .12s cubic-bezier(.2,.8,.2,1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(40px) scale(.96); } }

.lede { max-width: 620px; margin: 0 auto; font-size: clamp(17px, 2.2vw, 21px); color: #c6cde0; animation: fade 1s .35s both; }
.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 36px; animation: fade 1s .5s both; }
@keyframes fade { from { opacity: 0; transform: translateY(14px); } }

.scroll-cue { position: absolute; bottom: 28px; left: 50%; translate: -50% 0; width: 26px; height: 42px; border: 2px solid rgba(255,255,255,.3); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--text); animation: wheel 1.8s infinite; }
@keyframes wheel { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; border-block: 1px solid var(--line); background: var(--bg-2); padding: 18px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee-track { display: flex; gap: 28px; width: max-content; animation: marquee 30s linear infinite; font: 500 clamp(18px, 2.6vw, 26px)/1 var(--display); white-space: nowrap; }
.marquee-track span { color: var(--text); }
.marquee-track span:nth-of-type(odd) { color: transparent; -webkit-text-stroke: 1px rgba(255,255,255,.35); }
.marquee-track i { font-style: normal; color: var(--gold); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { max-width: var(--max); margin: 0 auto; padding: clamp(80px, 12vw, 140px) var(--gutter) 0; }
.section-head { max-width: 680px; margin-bottom: 48px; }
.kicker { font: 500 13px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 16px; }
.section h2 { font-size: clamp(34px, 5.6vw, 64px); font-weight: 700; }
.section-sub { margin-top: 18px; color: var(--muted); font-size: clamp(16px, 1.8vw, 19px); }

/* ---------- Projects ---------- */
.projects { display: grid; grid-template-columns: 1.6fr 1fr; grid-template-rows: auto auto; gap: 20px; }
.card {
  position: relative; overflow: hidden; border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border: 1px solid var(--line); padding: 28px;
}
.card h3 { font-size: clamp(22px, 2.6vw, 28px); font-weight: 700; margin: 6px 0 10px; }
.card p { color: var(--muted); }
.card-feature { grid-row: span 2; display: flex; flex-direction: column; justify-content: flex-end; min-height: 520px; padding: 36px; transform-style: preserve-3d; transition: transform .2s ease-out, border-color .3s; }
.card-feature:hover { border-color: rgba(143,216,255,.35); }
.card-feature h3 { font-size: clamp(40px, 6vw, 72px); font-weight: 900; background: var(--grad-ice); -webkit-background-clip: text; background-clip: text; color: transparent; }
.card-glow { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(500px circle at var(--mx, 70%) var(--my, 20%), rgba(143,216,255,.18), transparent 45%); }
.card-art { position: absolute; top: 24px; right: 24px; width: min(58%, 320px); }
.waddle-floe { aspect-ratio: 1; padding: 14%; border-radius: 24%; background: linear-gradient(160deg, #ffffff 0%, #eef7fc 55%, #b9dcef 100%); box-shadow: 0 30px 60px -25px rgba(111,211,232,.5), inset 0 -8px 0 rgba(139,188,216,.6); }
.waddle-art { width: 100%; height: 100%; overflow: visible; }
.waddler { transform-box: fill-box; transform-origin: 50% 100%; animation: waddle 1.4s ease-in-out infinite; }
.card-link { text-decoration: none; color: inherit; }
.card-link::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.card-link:focus-visible { outline: none; }
.card-feature:has(.card-link:focus-visible) { outline: 2px solid var(--ice); outline-offset: 3px; }
.card-feature { cursor: pointer; }
.card-more { margin-top: 20px; color: var(--ice); }
@keyframes waddle { 0%,100% { transform: rotate(-5deg) translateY(0); } 25% { transform: rotate(0) translateY(-4px); } 50% { transform: rotate(5deg) translateY(0); } 75% { transform: rotate(0) translateY(-4px); } }
.card-body { position: relative; max-width: 460px; }
.badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; color: #5df2a8; background: rgba(93,242,168,.1); border: 1px solid rgba(93,242,168,.25); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.tags li { font-size: 13px; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); color: #cfd5e4; }

.card-ghost { border-style: dashed; border-color: rgba(255,255,255,.14); background: transparent; transition: border-color .3s, background .3s, transform .3s; }
.card-ghost:hover { border-color: rgba(242,201,138,.45); background: rgba(242,201,138,.04); transform: translateY(-4px); }
.ghost-icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 14px; background: var(--surface-2); color: var(--gold); margin-bottom: 18px; }
.ghost-icon svg { width: 22px; height: 22px; }
.text-link { display: inline-block; margin-top: 16px; font-weight: 600; color: var(--gold); text-decoration: none; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 860px) {
  .projects { grid-template-columns: 1fr; }
  .card-feature { grid-row: auto; min-height: 480px; padding: 28px; }
  .card-art { width: min(62%, 260px); }
}

/* ---------- Craft ---------- */
.craft { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--line); }
.craft-item { padding: 36px 28px 36px 0; border-bottom: 1px solid var(--line); }
.craft-item + .craft-item { padding-left: 28px; border-left: 1px solid var(--line); }
.craft-num { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line); font: 700 18px/1 var(--display); margin-bottom: 22px; background: var(--grad-brand); -webkit-background-clip: text; background-clip: text; color: transparent; }
.craft-item h3 { font-size: 24px; font-weight: 700; margin-bottom: 10px; }
.craft-item p { color: var(--muted); }
@media (max-width: 860px) {
  .craft { grid-template-columns: 1fr; }
  .craft-item, .craft-item + .craft-item { padding: 28px 0; border-left: 0; }
}

/* ---------- Story ---------- */
.pups { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: clamp(16px, 3vw, 40px); }
.pup { margin: 0; text-align: center; padding: 32px 24px; border-radius: var(--radius); border: 1px solid var(--line); position: relative; overflow: hidden; }
.pup-atlas { background: radial-gradient(120% 80% at 50% 0%, rgba(242,201,138,.16), transparent 60%), var(--bg-2); }
.pup-xena { background: radial-gradient(120% 80% at 50% 0%, rgba(143,216,255,.16), transparent 60%), var(--bg-2); }
.pup-art { width: min(220px, 70%); margin: 0 auto 20px; transition: transform .5s cubic-bezier(.2,.8,.2,1.4); }
.pup:hover .pup-art { transform: translateY(-6px) rotate(-3deg); }
.pup-xena:hover .pup-art { transform: translateY(-6px) rotate(3deg); }
.ear { transform-box: fill-box; transition: transform .35s cubic-bezier(.2,.8,.2,1.6); }
.ear-l { transform-origin: 100% 100%; }
.ear-r { transform-origin: 0% 100%; }
.pup:hover .ear-l { transform: rotate(-10deg); }
.pup:hover .ear-r { transform: rotate(10deg); }
.eyes { transform-box: fill-box; transform-origin: center; animation: blink 5s infinite; }
.pup-xena .eyes { animation-delay: 1.7s; }
@keyframes blink { 0%, 94%, 100% { transform: scaleY(1); } 97% { transform: scaleY(.1); } }
.pup figcaption { display: grid; gap: 6px; }
.pup-letters { font: 900 clamp(28px, 4vw, 44px)/1 var(--display); letter-spacing: .02em; }
.pup-letters b { font-weight: inherit; -webkit-background-clip: text; background-clip: text; color: transparent; }
.pup-atlas .pup-letters b { background-image: var(--grad-gold); }
.pup-xena .pup-letters b { background-image: var(--grad-ice); }
.pup-letters .dim { color: rgba(255,255,255,.2); }
.pup strong { font-size: 18px; margin-top: 6px; }
.pup figcaption > span:last-child { color: var(--muted); font-size: 15px; max-width: 320px; margin: 0 auto; }
.plus { font: 300 56px/1 var(--display); color: var(--muted); }

.equation {
  margin-top: 56px; text-align: center;
  font: 700 clamp(22px, 4.4vw, 48px)/1.2 var(--display); letter-spacing: -0.02em;
  display: flex; justify-content: center; align-items: baseline; flex-wrap: wrap; gap: 0 .35em;
}
.eq-gold { background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; color: transparent; }
.eq-ice { background: var(--grad-ice); -webkit-background-clip: text; background-clip: text; color: transparent; }
.eq-dim { color: rgba(255,255,255,.2); text-decoration: line-through; text-decoration-thickness: 3px; }
.eq-op { color: var(--muted); font-weight: 300; }
.eq-result { display: inline-flex; padding: 4px 18px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
@media (max-width: 760px) {
  .pups { grid-template-columns: 1fr; }
  .plus { font-size: 40px; }
}

/* ---------- Contact ---------- */
.contact { padding-bottom: clamp(80px, 10vw, 120px); }
.contact-card {
  position: relative; overflow: hidden; isolation: isolate; text-align: center;
  padding: clamp(48px, 8vw, 96px) clamp(20px, 5vw, 64px);
  border-radius: calc(var(--radius) + 8px); border: 1px solid var(--line); background: var(--bg-2);
}
.contact-card .section-sub { max-width: 520px; margin: 18px auto 36px; }
.aurora-sm { opacity: .5; }
.aurora-sm span:nth-child(1) { width: 60%; height: 120%; left: -10%; top: -40%; }
.aurora-sm span:nth-child(2) { width: 60%; height: 120%; right: -10%; top: 20%; }

/* ---------- Footer ---------- */
.footer { max-width: var(--max); margin: 0 auto; padding: 32px var(--gutter) 48px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }

/* ---------- Reveal on scroll (only when JS runs) ---------- */
.js .reveal { opacity: 0; transform: translateY(32px); transition: opacity .8s cubic-bezier(.2,.8,.2,1), transform .8s cubic-bezier(.2,.8,.2,1); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .js .reveal { opacity: 1; transform: none; }
}
.footer p a { color: var(--text); text-decoration: none; }
.footer p a:hover { color: var(--gold); }
