/* ============================================
   ma - shared design system
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.011em;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; }

:root {
  --ink: #0a0a0a; --ink-2: #1c1917; --ink-3: #292524;
  --paper: #ffffff; --paper-2: #fafaf9; --paper-3: #f5f5f4;
  --cream: #fff8f0; --cream-2: #fdf2e3;
  --muted: #78716c; --muted-2: #a8a29e;
  --border: #e7e5e4; --border-strong: #d6d3d1;
  --cyan: #03b7d2; --cyan-2: #00a5be; --cyan-soft: rgba(3, 183, 210, 0.10);
  --pink: #ff006e; --pink-2: #e60063; --pink-soft: rgba(255, 0, 110, 0.10);
  --petrol: #0e2b30;
  --graphite: #26262b; --lime: #d4ff3f;
  --grain: 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='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
  --gutter: 24px; --max: 1440px; --pad-block: clamp(80px, 12vw, 160px);
  --display-1: clamp(64px, 11vw, 188px);
  --display-2: clamp(48px, 8vw, 128px);
  --display-3: clamp(36px, 5.5vw, 84px);
  --h1: clamp(40px, 5vw, 72px);
  --h2: clamp(28px, 3.5vw, 48px);
  --h3: clamp(22px, 2.2vw, 28px);
  --body-lg: clamp(17px, 1.4vw, 20px);
  --body: 16px; --small: 13px; --label: 11px;
}
::selection { background: var(--cyan); color: var(--ink); }
.container { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

.label {
  font-family: 'JetBrains Mono', monospace;
  font-size: var(--label); font-weight: 700; letter-spacing: 2.5px;
  text-transform: uppercase; display: inline-flex; align-items: center; gap: 10px;
}
.label::before { content: ''; display: inline-block; width: 28px; height: 1px; background: currentColor; }
.label.cyan { color: var(--cyan); }
.label.pink { color: var(--pink); }

/* CUSTOM CURSOR (desktop) */
@media (pointer: fine) {
  body { cursor: none; }
  .cursor-dot, .cursor-ring {
    position: fixed; top: 0; left: 0; pointer-events: none; z-index: 9999;
    transition: transform 0.15s ease-out, width 0.3s ease, height 0.3s ease, background 0.3s ease, border-color 0.3s ease;
    transform: translate(-50%, -50%); will-change: transform;
  }
  /* White + "difference" blend keeps the cursor visible on ANY background
     (light, dark petrol, photos), regardless of what the nav treats as dark. */
  .cursor-dot { width: 8px; height: 8px; background: #fff; border-radius: 50%; mix-blend-mode: difference; }
  .cursor-ring { width: 36px; height: 36px; border: 1.5px solid #fff; border-radius: 50%; mix-blend-mode: difference; }
  .cursor-ring.is-hover { width: 64px; height: 64px; background: var(--cyan); border-color: var(--cyan); mix-blend-mode: difference; }
  .cursor-dot.is-hover { opacity: 0; }
}
@media (pointer: coarse) { .cursor-dot, .cursor-ring { display: none; } }

/* ACCESSIBILITY: visible keyboard focus + skip link */
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 2px; }
a:focus:not(:focus-visible), button:focus:not(:focus-visible) { outline: none; }
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 1000;
  background: var(--ink); color: var(--paper); padding: 12px 22px;
  font-weight: 700; font-size: 14px; border-radius: 0 0 8px 0; text-decoration: none;
}
.skip-link:focus { left: 0; }

/* NAV */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 18px var(--gutter);
  transition: background 0.3s ease, border-color 0.3s ease, padding 0.25s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom-color: var(--border); padding: 12px var(--gutter);
}
.nav.dark-bg:not(.scrolled) { color: var(--paper); }
.nav-inner { max-width: var(--max); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.nav-brand { display: flex; align-items: center; gap: 12px; }
.nav-brand img { width: 120px; height: auto; display: block; border-radius: 4px; box-shadow: 0 4px 16px rgba(3, 183, 210, 0.32); transition: width 0.3s ease, transform 0.3s ease; }
.nav.scrolled .nav-brand img { width: 60px; }
.nav-brand:hover img { transform: scale(1.05); }
@media (max-width: 880px) { .nav-brand img { width: 88px; } .nav.scrolled .nav-brand img { width: 54px; } }
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; }
.nav-links a {
  font-size: 15.5px; font-weight: 600; padding: 10px 15px; border-radius: 8px;
  transition: color 0.2s ease, background 0.2s ease; position: relative;
}
.nav-links a:hover { color: var(--cyan); }
.nav.scrolled .nav-links a:hover { background: var(--cyan-soft); }
.nav-links a.active { color: var(--cyan); }
.nav-cta {
  display: inline-flex; align-items: center; gap: 8px; padding: 13px 23px;
  background: var(--ink); color: var(--paper); font-size: 15.5px; font-weight: 700;
  border-radius: 99px; transition: all 0.2s ease; position: relative; overflow: hidden;
}
.nav-cta::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--pink) 0%, var(--cyan) 100%);
  opacity: 0; transition: opacity 0.25s ease;
}
.nav-cta > * { position: relative; z-index: 1; }
.nav-cta:hover::before { opacity: 1; }
.nav-cta:hover { transform: translateY(-1px); color: var(--ink); }
.nav.dark-bg:not(.scrolled) .nav-cta { background: var(--paper); color: var(--ink); }
.nav-mobile-toggle { display: none; width: 40px; height: 40px; align-items: center; justify-content: center; color: inherit; }
@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-mobile-toggle { display: flex; }
}

/* PAGE HERO (smaller than homepage) */
.page-hero {
  position: relative; min-height: 60vh; color: var(--paper);
  background-color: var(--petrol); background-image: var(--grain); background-size: 160px; background-blend-mode: overlay;
  overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 180px var(--gutter) 80px var(--gutter);
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(900px 600px at 92% -10%, rgba(255, 0, 110, 0.18), transparent 60%),
    radial-gradient(700px 500px at -10% 110%, rgba(3, 183, 210, 0.18), transparent 60%);
  pointer-events: none; z-index: 1;
}
.page-hero-bg {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0.32; filter: contrast(1.08) saturate(0.65); z-index: 0;
}
.page-hero-inner { position: relative; z-index: 2; max-width: var(--max); width: 100%; margin: 0 auto; }
.page-hero .label { color: var(--cyan); margin-bottom: 24px; }
.page-hero h1 {
  font-size: clamp(56px, 9vw, 144px); font-weight: 900; line-height: 1;
  letter-spacing: -0.05em; margin-bottom: 32px; max-width: 1100px;
}
.page-hero h1 .accent { color: var(--cyan); }
.page-hero h1 .pink { color: var(--pink); }
.page-hero .lede {
  max-width: 580px; font-size: var(--body-lg);
  color: rgba(255, 255, 255, 0.72); line-height: 1.55; font-weight: 400;
}

/* SECTION */
.section { padding: var(--pad-block) var(--gutter); }
.section.cream { background: var(--cream); }
.section.dark { background-color: var(--petrol); background-image: var(--grain); background-size: 160px; background-blend-mode: overlay; color: var(--paper); }
.section.paper-2 { background: var(--paper-2); }
.section-inner { max-width: var(--max); margin: 0 auto; }
.section-head { display: grid; grid-template-columns: 1fr 2fr; gap: 80px; align-items: end; margin-bottom: 80px; }
@media (max-width: 880px) { .section-head { grid-template-columns: 1fr; gap: 24px; margin-bottom: 48px; } }
.section-head h2 { font-size: var(--display-3); font-weight: 900; line-height: 1; letter-spacing: -0.04em; }
.section-head h2 .accent-pink { color: var(--pink); }
.section-head h2 .accent-cyan { color: var(--cyan); }
.section-head-side { display: flex; flex-direction: column; gap: 20px; }
.section-head-side p { font-size: var(--body-lg); color: var(--muted); max-width: 460px; line-height: 1.55; }
.section.dark .section-head-side p { color: rgba(255, 255, 255, 0.6); }

/* FOOTER */
.footer { background: var(--ink-2); color: var(--paper); padding: 64px var(--gutter) 24px var(--gutter); }
.footer-inner { max-width: var(--max); margin: 0 auto; }
.footer-top { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 48px; padding-bottom: 48px; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
@media (max-width: 880px) { .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; } }
.footer-brand img { width: 64px; height: 51px; border-radius: 3px; margin-bottom: 20px; }
.footer-brand p { font-size: 14px; color: rgba(255, 255, 255, 0.55); max-width: 280px; line-height: 1.55; }
.footer-col h4 {
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase; color: var(--cyan); margin-bottom: 16px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 14px; color: rgba(255, 255, 255, 0.7); transition: color 0.2s ease; }
.footer-col a:hover { color: var(--pink); }
.footer-bottom {
  margin-top: 32px; display: flex; flex-wrap: wrap; justify-content: space-between;
  align-items: center; gap: 16px; font-size: 12px; color: rgba(255, 255, 255, 0.4);
  font-family: 'JetBrains Mono', monospace; letter-spacing: 0.5px;
}
.footer-bottom a { color: rgba(255, 255, 255, 0.4); transition: color 0.2s ease; }
.footer-bottom a:hover { color: var(--cyan); }

/* BUTTONS */
.btn-primary, .btn-secondary {
  display: inline-flex; align-items: center; gap: 10px; padding: 18px 32px;
  border-radius: 99px; font-weight: 700; font-size: 15px; letter-spacing: -0.1px;
  transition: all 0.25s ease; position: relative; overflow: hidden;
}
.btn-primary { background: var(--cyan); color: var(--ink); }
.btn-primary:hover { background: var(--pink); color: var(--paper); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(255, 0, 110, 0.4); }
.btn-secondary { background: transparent; color: var(--ink); border: 1.5px solid var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--paper); transform: translateY(-2px); }
.section.dark .btn-secondary { color: var(--paper); border-color: rgba(255, 255, 255, 0.3); }
.section.dark .btn-secondary:hover { border-color: var(--paper); background: transparent; }

/* REVEAL */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1); }
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal.delay-1 { transition-delay: 0.1s; }
.reveal.delay-2 { transition-delay: 0.2s; }
.reveal.delay-3 { transition-delay: 0.3s; }
.reveal.delay-4 { transition-delay: 0.4s; }

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

/* ===== Self-hosted brand fonts: Inter (text) + JetBrains Mono (labels) ===== */
@font-face{font-family:'Inter';font-style:normal;font-weight:100 900;font-display:swap;src:url('/fonts/Inter.woff') format('woff'),url('/fonts/Inter.ttf') format('truetype');}
@font-face{font-family:'Inter';font-style:italic;font-weight:100 900;font-display:swap;src:url('/fonts/Inter-Italic.woff') format('woff');}
@font-face{font-family:'JetBrains Mono';font-style:normal;font-weight:100 800;font-display:swap;src:url('/fonts/JetBrainsMono.woff') format('woff'),url('/fonts/JetBrainsMono.ttf') format('truetype');}
@font-face{font-family:'JetBrains Mono';font-style:italic;font-weight:100 800;font-display:swap;src:url('/fonts/JetBrainsMono-Italic.woff') format('woff');}
