/* ==========================================================================
   BOOKED. — agency site
   Split out of index.html so no single file runs long (see CLAUDE.md).
   Palette is deliberately multi-hue: the old site was mono-gold, which made
   a shop selling "bespoke design per business" look like it had one look.
   ========================================================================== */

:root {
  --bg: #08070a;
  --bg-2: #0d0c12;
  --surface: #131119;
  --surface-2: #1a1722;
  --text: #f6f3ee;
  --muted: #9b94a8;
  --border: rgba(246, 243, 238, 0.10);
  --border-strong: rgba(246, 243, 238, 0.20);

  --gold: #e8b84b;
  --violet: #8b5cf6;
  --cyan: #22d3ee;
  --pink: #f471b5;
  --lime: #a3e635;

  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Space Grotesk', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  --max: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, iframe { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { max-width: var(--max); margin: 0 auto; padding: 0 22px; }
.display { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; line-height: 1.03; }

/* Film grain over everything — cheap, and stops the flat-gradient look. */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Scroll progress rail */
.progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0%;
  background: linear-gradient(90deg, var(--gold), var(--pink), var(--violet), var(--cyan));
  z-index: 200;
  transition: width 0.1s linear;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--font-body);
  font-weight: 600; font-size: 0.94rem;
  padding: 14px 28px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  position: relative;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.25s, background 0.25s;
}
.btn-primary {
  color: #14110c;
  background: linear-gradient(135deg, var(--gold), #f6d67e 55%, var(--gold));
  box-shadow: 0 10px 34px -10px rgba(232, 184, 75, 0.65);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 44px -12px rgba(232, 184, 75, 0.8); }
.btn-ghost { color: var(--text); border-color: var(--border-strong); background: rgba(246, 243, 238, 0.02); }
.btn-ghost:hover { border-color: var(--gold); background: rgba(232, 184, 75, 0.07); transform: translateY(-2px); }
.btn-sm { padding: 10px 20px; font-size: 0.82rem; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 150;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 15px 22px;
  background: rgba(8, 7, 10, 0.6);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
.nav.scrolled { border-bottom-color: var(--border); background: rgba(8, 7, 10, 0.9); }
.nav-brand { font-family: var(--font-display); font-size: 1.2rem; font-weight: 600; letter-spacing: -0.02em; }
.nav-links { display: none; gap: 26px; font-size: 0.88rem; color: var(--muted); }
.nav-links a { transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }

/* ---------- Aurora hero ---------- */
.hero {
  position: relative;
  min-height: 90svh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 70px 22px 90px;
  overflow: hidden;
}
/* Three drifting blobs = a living gradient without a canvas or a library. */
.aurora { position: absolute; inset: -25%; z-index: -1; filter: blur(90px); opacity: 0.55; }
.blob { position: absolute; border-radius: 50%; mix-blend-mode: screen; }
.blob-1 { width: 46vw; height: 46vw; background: var(--gold);   top: 4%;  left: 14%; animation: drift1 19s ease-in-out infinite; }
.blob-2 { width: 40vw; height: 40vw; background: var(--violet); top: 26%; left: 52%; animation: drift2 23s ease-in-out infinite; }
.blob-3 { width: 34vw; height: 34vw; background: var(--cyan);   top: 46%; left: 26%; animation: drift3 27s ease-in-out infinite; }
@keyframes drift1 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(9vw, 7vh) scale(1.16); } }
@keyframes drift2 { 0%,100% { transform: translate(0,0) scale(1.1); } 50% { transform: translate(-11vw, 5vh) scale(0.9); } }
@keyframes drift3 { 0%,100% { transform: translate(0,0) scale(0.95); } 50% { transform: translate(7vw, -8vh) scale(1.2); } }

.hero-badge {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 7px 16px 7px 8px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: rgba(19, 17, 25, 0.6);
  backdrop-filter: blur(8px);
  font-size: 0.78rem; color: var(--muted);
  margin-bottom: 26px;
}
.hero-badge .dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--lime);
  box-shadow: 0 0 0 3px rgba(163, 230, 53, 0.18);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.hero h1 { font-size: clamp(2.6rem, 8vw, 5rem); max-width: 15ch; }
.hero h1 .grad {
  background: linear-gradient(100deg, var(--gold), var(--pink) 45%, var(--violet) 75%, var(--cyan));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  font-style: italic;
}
/* Rotating niche word — doubles as the "who we build for" statement. */
.rotator { display: inline-grid; vertical-align: bottom; text-align: left; }
.rotator span {
  grid-area: 1 / 1;
  opacity: 0; transform: translateY(0.35em) rotateX(-40deg);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
  white-space: nowrap;
}
.rotator span.on { opacity: 1; transform: none; }

.hero p { margin-top: 24px; color: var(--muted); font-size: 1.06rem; max-width: 46ch; }
.cta-row { margin-top: 36px; display: flex; gap: 13px; flex-wrap: wrap; justify-content: center; }

/* ---------- Stat strip ---------- */
.stats { margin-top: 58px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 16px; overflow: hidden; width: 100%; max-width: 760px; }
.stat { background: rgba(8, 7, 10, 0.72); backdrop-filter: blur(8px); padding: 20px 14px; }
.stat .n { font-family: var(--font-display); font-size: clamp(1.5rem, 4.4vw, 2.1rem); font-weight: 600; }
.stat .l { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }
.stat:nth-child(1) .n { color: var(--gold); }
.stat:nth-child(2) .n { color: var(--pink); }
.stat:nth-child(3) .n { color: var(--cyan); }
.stat:nth-child(4) .n { color: var(--lime); }

/* ---------- Marquee ---------- */
.marquee { border-block: 1px solid var(--border); padding: 17px 0; overflow: hidden; background: var(--bg-2); }
.marquee-track { display: flex; gap: 0; width: max-content; animation: slide 34s linear infinite; }
.marquee-track span {
  font-family: var(--font-display); font-size: 1.35rem; font-style: italic;
  padding: 0 26px; color: var(--muted); white-space: nowrap;
}
.marquee-track span::after { content: '✦'; margin-left: 26px; color: var(--gold); font-style: normal; font-size: 0.7rem; vertical-align: middle; }
@keyframes slide { to { transform: translateX(-50%); } }
.marquee:hover .marquee-track { animation-play-state: paused; }

/* ---------- Sections ---------- */
section { padding: 92px 0; }
.section-head { max-width: 620px; margin-bottom: 48px; }
.section-head .eyebrow { display: block; margin-bottom: 13px; }
.section-head h2 { font-size: clamp(1.9rem, 5vw, 2.9rem); }
.section-head p { color: var(--muted); margin-top: 14px; }

.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Bento ---------- */
.bento { display: grid; grid-template-columns: 1fr; gap: 14px; }
.tile {
  position: relative; overflow: hidden;
  padding: 30px 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  transition: border-color 0.3s, transform 0.3s var(--ease);
}
.tile:hover { border-color: var(--border-strong); transform: translateY(-3px); }
/* Cursor spotlight — app.js writes --mx/--my per card on mousemove. */
.tile::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,0.07), transparent 65%);
  opacity: 0; transition: opacity 0.35s;
}
.tile:hover::before { opacity: 1; }
.tile .num { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.2em; color: var(--gold); }
.tile h3 { font-family: var(--font-display); font-size: 1.35rem; margin: 12px 0 9px; font-weight: 500; }
.tile p { color: var(--muted); font-size: 0.94rem; }
.tile-wide { background: linear-gradient(150deg, var(--surface-2), var(--surface)); }
.tile-wide .num { color: var(--cyan); }
.tile-accent { background: linear-gradient(150deg, rgba(139, 92, 246, 0.14), var(--surface)); }
.tile-accent .num { color: var(--violet); }

/* ---------- Live work previews ---------- */
.work-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
.work-card {
  border: 1px solid var(--border); border-radius: 18px; overflow: hidden;
  background: var(--surface);
  transition: border-color 0.3s, transform 0.35s var(--ease);
}
.work-card:hover { border-color: var(--border-strong); transform: translateY(-4px); }
.chrome { display: flex; align-items: center; gap: 7px; padding: 11px 14px; background: var(--surface-2); border-bottom: 1px solid var(--border); }
.chrome i { width: 9px; height: 9px; border-radius: 50%; background: var(--border-strong); }
.chrome .addr {
  flex: 1; margin-left: 7px;
  font-family: var(--font-mono); font-size: 0.63rem; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* The iframe renders the real deployed demo, scaled down. Sized at desktop
   width then transform-scaled so the demo lays out as a desktop page. */
.shot { position: relative; height: 230px; overflow: hidden; background: var(--bg-2); }
.shot iframe { width: 1280px; height: 900px; border: 0; transform: scale(0.29); transform-origin: 0 0; pointer-events: none; }
.shot .fallback {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: var(--font-display); font-size: 1.05rem; color: var(--muted); text-align: center; padding: 20px;
  background: linear-gradient(140deg, var(--surface-2), var(--bg-2));
}
.shot iframe { position: relative; z-index: 1; }
.work-meta { padding: 16px 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.work-meta .name { font-family: var(--font-display); font-size: 1.05rem; }
.work-meta .tag { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.14em; text-transform: uppercase; padding: 4px 9px; border-radius: 999px; border: 1px solid var(--border-strong); color: var(--muted); white-space: nowrap; }

/* ---------- Packages ---------- */
.packages-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
.package-card {
  position: relative; display: flex; flex-direction: column;
  padding: 32px 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  transition: border-color 0.3s, transform 0.3s var(--ease);
}
.package-card:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.package-card.featured {
  border-color: transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    linear-gradient(150deg, var(--gold), var(--pink), var(--violet)) border-box;
  border: 1px solid transparent;
}
.package-card .badge {
  position: absolute; top: -11px; left: 26px;
  background: linear-gradient(100deg, var(--gold), var(--pink));
  color: #14110c;
  font-family: var(--font-mono); font-size: 0.6rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 5px 11px; border-radius: 999px;
}
.package-name { font-family: var(--font-display); font-size: 1.5rem; margin-bottom: 5px; }
.package-tagline { color: var(--muted); font-size: 0.87rem; margin-bottom: 20px; }
.package-features { list-style: none; }
.package-features li { padding: 10px 0 10px 24px; border-top: 1px solid var(--border); color: var(--muted); font-size: 0.9rem; position: relative; }
.package-features li:first-child { border-top: none; }
.package-features li::before { content: '→'; position: absolute; left: 0; color: var(--gold); }
.package-cta { margin-top: 24px; }

/* ---------- Contact ---------- */
.contact-card {
  position: relative; overflow: hidden;
  border: 1px solid var(--border); border-radius: 24px;
  padding: 52px 26px;
  text-align: center;
  background: radial-gradient(ellipse 70% 100% at 50% 0%, rgba(139, 92, 246, 0.16), transparent 70%), var(--surface);
}
.contact-card h2 { font-size: clamp(1.8rem, 5vw, 2.7rem); }
.contact-card > p { color: var(--muted); margin-top: 14px; max-width: 46ch; margin-inline: auto; }
.contact-methods { display: flex; flex-direction: column; gap: 12px; align-items: stretch; margin-top: 30px; max-width: 380px; margin-inline: auto; }

/* ---------- Footer ---------- */
footer { padding: 46px 22px 40px; text-align: center; border-top: 1px solid var(--border); }
.footer-brand { font-family: var(--font-display); font-size: 1.25rem; margin-bottom: 16px; }
.social-row { display: flex; justify-content: center; gap: 14px; margin-bottom: 20px; }
.social-row a {
  width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; color: var(--muted);
  transition: border-color 0.25s, color 0.25s, transform 0.25s;
}
.social-row a:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-2px); }
.footer-fine { color: var(--muted); font-size: 0.76rem; }

/* ---------- Responsive ---------- */
@media (min-width: 700px) {
  .nav-links { display: flex; }
  .stats { grid-template-columns: repeat(4, 1fr); }
  .bento { grid-template-columns: repeat(3, 1fr); }
  .tile-wide { grid-column: span 2; }
  .work-grid { grid-template-columns: repeat(2, 1fr); }
  .packages-grid { grid-template-columns: repeat(3, 1fr); }
  .package-cta { margin-top: auto; }
  .contact-methods { flex-direction: row; justify-content: center; max-width: none; }
  .contact-card { padding: 62px 40px; }
}
@media (min-width: 1000px) {
  .work-grid { grid-template-columns: repeat(3, 1fr); }
  .shot { height: 260px; }
  .shot iframe { transform: scale(0.265); }
}

/* Respect reduced-motion: kill drift, marquee, rotator and reveal offsets. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
  .rotator span { position: static; }
}
