/* Decoherence Studio — night field, paper type, bronze accent */
:root {
  --night: #0B1016;
  --night-deep: #07090D;
  --paper: #EDE8DF;
  --paper-muted: #A39E94;
  --alum: #C5C9CE;
  --alum-dark: #8B929A;
  --bronze: #B8A58A;
  --hair: rgba(237, 232, 223, 0.16);
  --hair-strong: rgba(237, 232, 223, 0.28);
  --glass: rgba(7, 9, 13, 0.58);
  --font-serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-sans: "Source Sans 3", system-ui, sans-serif;
  --header-h: 4.25rem;
  --max: 68rem;
  --radius: 0.55rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  font-weight: 400;
  color: var(--paper);
  background: var(--night);
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 1000;
  padding: 0.7rem 1rem;
  background: var(--night-deep);
  color: var(--paper);
  border: 1px solid var(--bronze);
  border-radius: var(--radius);
  font-weight: 500;
}

.skip-link:focus {
  top: 1rem;
}

#galaxy {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
  pointer-events: none;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 60% at 50% 40%, transparent 18%, rgba(7, 9, 13, 0.55) 72%, rgba(7, 9, 13, 0.9) 100%),
    linear-gradient(180deg, rgba(7, 9, 13, 0.35) 0%, transparent 28%, transparent 62%, rgba(7, 9, 13, 0.88) 100%);
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0.045;
  mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

.site-header,
main,
.site-footer,
.pause-field {
  position: relative;
  z-index: 5;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(16px) saturate(1.05);
  background: rgba(11, 16, 22, 0.42);
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  border-bottom-color: var(--hair);
  background: rgba(7, 9, 13, 0.78);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  min-height: var(--header-h);
  padding: 0 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--paper);
  letter-spacing: 0.01em;
}

.nav {
  display: none;
  gap: 1.5rem;
  margin-left: auto;
  margin-right: 0.35rem;
}

.nav a {
  color: var(--alum-dark);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--paper);
}

.header-inner > .btn {
  display: none;
}

.nav-toggle {
  margin-left: auto;
  width: 44px;
  height: 44px;
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  border-radius: var(--radius);
  border: 1px solid var(--hair);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 1px;
  background: var(--paper);
  transition: transform 0.25s ease;
}

.nav-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(3.5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-3.5px) rotate(-45deg);
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 0.35rem 1.25rem 1.25rem;
  border-bottom: 1px solid var(--hair);
  background: rgba(7, 9, 13, 0.94);
}

.mobile-nav[hidden] {
  display: none;
}

.mobile-nav a:not(.btn) {
  color: var(--alum);
  padding: 0.35rem 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.62rem 1.15rem;
  border-radius: 0.28rem;
  border: 1px solid var(--hair-strong);
  background: transparent;
  color: var(--paper);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.btn:hover,
.btn:focus-visible {
  border-color: var(--bronze);
  color: var(--paper);
  background: rgba(184, 165, 138, 0.08);
}

.btn:focus-visible {
  outline: 2px solid var(--bronze);
  outline-offset: 3px;
}

.pause-field {
  position: fixed;
  z-index: 30;
  right: 1.15rem;
  bottom: 1.15rem;
  font-size: 0.82rem;
  padding: 0.5rem 0.85rem;
}

.glass {
  background: var(--glass);
  border: 1px solid var(--hair);
  backdrop-filter: blur(14px) saturate(1.05);
  border-radius: 0.7rem;
}

.hero {
  min-height: calc(100vh - var(--header-h));
  display: flex;
  align-items: flex-end;
  padding: 3.5rem 1.25rem 4.5rem;
}

.hero-panel {
  max-width: 42rem;
  padding: 1.85rem 1.6rem 1.9rem;
}

.kicker {
  margin: 0 0 0.55rem;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--alum);
}

.kicker-bronze {
  color: var(--bronze);
}

.rule {
  display: block;
  width: 2.6rem;
  height: 1px;
  margin: 0.85rem 0 1.15rem;
  background: var(--bronze);
}

.hero h1,
.section-head h2,
.contact-panel h2,
.chip h3,
.card h3 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--paper);
}

.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2.15rem, 6.2vw, 3.35rem);
  line-height: 1.12;
}

.lede {
  margin: 0 0 1.6rem;
  max-width: 46ch;
  color: var(--paper-muted);
  font-size: 1.05rem;
  line-height: 1.7;
}

.section {
  padding: 4.5rem 1.25rem;
}

.section-inner {
  max-width: var(--max);
  margin: 0 auto;
}

.section-head {
  max-width: 38rem;
  margin-bottom: 1.75rem;
}

.section-head h2 {
  margin: 0 0 0.55rem;
  font-size: clamp(1.65rem, 3.2vw, 2.15rem);
  line-height: 1.2;
}

.section-head p {
  margin: 0;
  color: var(--paper-muted);
}

.card-grid,
.work-grid {
  display: grid;
  gap: 0.85rem;
}

.card {
  display: grid;
  grid-template-columns: 2.4rem 1fr;
  gap: 0.85rem;
  padding: 1.25rem 1.2rem 1.3rem;
}

.card-num {
  margin: 0.2rem 0 0;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--bronze);
}

.card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.15rem;
  line-height: 1.3;
}

.card p {
  margin: 0;
  color: var(--paper-muted);
  font-size: 0.98rem;
}

.card .meta {
  margin-top: 0.7rem;
  font-size: 0.82rem;
  color: var(--alum-dark);
}

.about-panel {
  padding: 1.5rem 1.4rem;
  margin-bottom: 0.85rem;
}

.about-panel p {
  margin: 0;
  max-width: 62ch;
  font-size: 1.08rem;
  line-height: 1.7;
  color: var(--paper);
}

.about-panel p + p {
  margin-top: 1.05rem;
}

.chip-grid {
  display: grid;
  gap: 0.85rem;
}

.chip {
  padding: 1.15rem 1.25rem 1.2rem;
}

.chip h3 {
  margin: 0.45rem 0 0;
  font-size: 1.2rem;
}

.contact-panel {
  padding: 1.85rem 1.5rem 1.9rem;
}

.contact-panel h2 {
  margin: 0 0 0.45rem;
  font-size: clamp(1.65rem, 3.2vw, 2.15rem);
}

.lede-small {
  margin: 0 0 0.85rem;
  color: var(--paper-muted);
}

.email,
.phone {
  margin: 0 0 0.35rem;
  font-family: var(--font-serif);
  font-size: clamp(1.25rem, 3vw, 1.7rem);
}

.phone {
  margin-bottom: 1.4rem;
  font-size: clamp(1.1rem, 2.6vw, 1.45rem);
}

.email a:hover,
.email a:focus-visible,
.phone a:hover,
.phone a:focus-visible {
  color: var(--bronze);
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.site-footer {
  border-top: 1px solid var(--hair);
  padding: 1.25rem 1.25rem 2.4rem;
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.5rem;
  justify-content: space-between;
  color: var(--alum-dark);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-footer p {
  margin: 0;
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (min-width: 720px) {
  .nav {
    display: flex;
  }

  .header-inner > .btn {
    display: inline-flex;
  }

  .nav-toggle,
  .mobile-nav {
    display: none !important;
  }

  .hero-panel {
    padding: 2.25rem 2rem 2.3rem;
  }

  .card-grid {
    grid-template-columns: 1fr 1fr;
  }

  .work-grid,
  .chip-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .chip-grid {
    grid-template-columns: 1fr 1fr;
  }
}


@media (max-width: 719px) {
  .header-inner,
  .hero,
  .section,
  .site-footer {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }

  .header-inner {
    min-height: 3.75rem;
    padding-top: env(safe-area-inset-top);
  }

  .logo {
    font-size: 0.98rem;
    min-width: 0;
  }

  .mobile-nav {
    padding-left: max(1.15rem, env(safe-area-inset-left));
    padding-right: max(1.15rem, env(safe-area-inset-right));
    padding-bottom: 1.15rem;
  }

  .mobile-nav a:not(.btn) {
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .mobile-nav .btn {
    width: 100%;
    margin-top: 0.25rem;
  }

  .hero {
    min-height: calc(100svh - var(--header-h));
    padding-top: 2rem;
    padding-bottom: 5.75rem;
  }

  .hero-panel {
    width: 100%;
    max-width: none;
    padding: 1.35rem 0.15rem 1.45rem;
    background: transparent;
    border-color: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
  }

  .hero-panel h1,
  .hero-panel .lede,
  .hero-panel .kicker {
    text-shadow: 0 1px 16px rgba(7, 9, 13, 0.72);
  }

  .hero h1 {
    font-size: clamp(1.85rem, 9vw, 2.45rem);
  }

  .lede {
    max-width: none;
    font-size: 1rem;
  }

  .kicker {
    letter-spacing: 0.12em;
    line-height: 1.55;
  }

  .section {
    padding-top: 3rem;
    padding-bottom: 3rem;
  }

  .card {
    grid-template-columns: 2rem 1fr;
    gap: 0.65rem;
    padding: 1.1rem 1rem 1.15rem;
  }

  .about-panel,
  .contact-panel {
    padding: 1.25rem 1.1rem 1.3rem;
  }

  .email,
  .phone {
    font-size: 1.05rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
  }

  .contact-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .contact-actions .btn {
    width: 100%;
  }

  .pause-field {
    right: max(0.85rem, env(safe-area-inset-right));
    bottom: max(0.85rem, env(safe-area-inset-bottom));
  }

  .footer-inner {
    letter-spacing: 0.04em;
    text-transform: none;
    font-size: 0.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
