* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #ffffff;
  --panel: #faf9f7;
  --panel-soft: #f3f1ee;
  --text: #171b21;
  --muted: #4d535a;
  --line: rgba(0, 0, 0, 0.08);
  --blue: #851eff;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 28px 70px;
  height: 96px;
  background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,255,255,0.88));
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.08);
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: transform 0.35s ease;
}

.site-header.hide {
  transform: translateY(-100%);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 26px;
  font-weight: 800;
}

.brand-logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
  display: block;
}

nav {
  display: flex;
  gap: 64px;
  font-size: 20px;
}

nav a {
  color: var(--muted);
  transition: 0.25s ease;
}

nav a:hover {
  color: var(--text);
}

.panel {
  margin: 124px 24px 28px;
  border-radius: 56px;
  background: radial-gradient(circle at top center, rgba(180, 74, 11, 0.07), transparent 42%), var(--panel);
  border: 1px solid var(--line);
}

.hero {
  min-height: calc(100vh - 150px);
  display: grid;
  place-items: center;
  text-align: center;
}

.hero-inner {
  max-width: 920px;
  padding: 90px 24px;
}

.hero h1 {
  font-size: clamp(4rem, 9vw, 7.5rem);
  line-height: 0.95;
  font-weight: 900;
  letter-spacing: -0.08em;
}

.hero-photo {
  display: inline-block;
  width: clamp(70px, 9vw, 115px);
  height: clamp(70px, 9vw, 115px);
  border-radius: 20px;
  overflow: hidden;
  margin: 0 16px;
  vertical-align: middle;
  transform: rotate(4deg);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
  border: 3px solid #ffffff;
}

.hero-photo img,
.about-image img,
.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero p {
  margin: 46px auto 72px;
  max-width: 790px;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  line-height: 1.65;
  color: var(--muted);
}

.down-arrow {
  font-size: 54px;
  font-weight: 900;
  display: inline-block;
  animation: bounce 1.45s infinite;
}

.projects-section {
  padding: 120px 56px 60px;
}

.section-title {
  text-align: center;
  font-size: clamp(3.2rem, 7vw, 5.7rem);
  letter-spacing: -0.06em;
  margin-bottom: 70px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 58px 52px;
  align-items: start;
}

.project-card {
  display: block;
  transition: transform 0.45s ease;
}

.project-card:hover {
  transform: translateY(-8px) scale(1.015);
}

.project-image {
  height: 520px;
  border-radius: 28px;
  overflow: hidden;
  display: grid;
  place-items: center;
  transition: box-shadow 0.45s ease;
}

.project-image img {
  transition: transform 0.7s ease;
}

.project-card:hover .project-image {
  box-shadow: 0 26px 55px rgba(0, 0, 0, 0.16);
}

.project-card:hover img {
  transform: scale(1.055);
}

.blue-bg { background: #dfeeff; }
.purple-bg { background: #e9e2ff; }
.pink-bg { background: #ffe0e8; }
.green-bg { background: #e2f4e8; }
.orange-bg { background: #f2c39b; }
.dark-bg { background: #ededed; }

.project-type {
  margin-top: 30px;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 900;
  color: var(--blue);
}

.project-card h3 {
  margin-top: 16px;
  font-size: clamp(2.4rem, 4vw, 4.2rem);
  letter-spacing: -0.05em;
  line-height: 0.95;
}

.project-description {
  margin-top: 22px;
  max-width: 720px;
  font-size: 1.35rem;
  line-height: 1.45;
  color: var(--muted);
}

.connect {
  min-height: 680px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 80px 24px;
}

.mini-heading {
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 36px;
  color: var(--muted);
}

.connect h2 {
  font-size: clamp(4rem, 11vw, 9.5rem);
  letter-spacing: -0.08em;
  line-height: 0.9;
}

.button-row {
  margin: 70px 0;
  display: flex;
  justify-content: center;
  gap: 20px;
}

.button {
  padding: 22px 34px;
  border-radius: 20px;
  font-size: 20px;
  border: 1px solid var(--line);
  transition: transform 0.3s ease;
}

.button:hover {
  transform: translateY(-5px);
}

.button.dark {
  color: #ffffff;
  background: var(--blue);
  font-weight: 800;
}

.button.light {
  background: transparent;
  color: var(--text);
}

.email {
  color: var(--muted);
  font-size: 16px;
}

.about-page {
  min-height: calc(100vh - 150px);
  padding: 90px 8%;
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 72px;
  align-items: center;
}

.about-image {
  height: 580px;
  border-radius: 42px;
  overflow: hidden;
  transform: rotate(-2deg);
  border: 1px solid var(--line);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.14);
}

.about-text h1,
.project-detail h1 {
  font-size: clamp(4rem, 8vw, 8rem);
  line-height: 0.95;
  letter-spacing: -0.08em;
}

.about-text p {
  color: var(--muted);
  font-size: clamp(1.2rem, 2vw, 1.75rem);
  line-height: 1.65;
  margin-top: 34px;
}

.project-detail {
  max-width: 1250px;
  padding: 90px 8%;
}

.project-intro {
  max-width: 800px;
  color: var(--muted);
  font-size: 1.55rem;
  line-height: 1.6;
  margin-top: 34px;
}

.detail-image {
  width: 100%;
  height: 620px;
  object-fit: cover;
  border-radius: 36px;
  margin: 70px 0;
  border: 1px solid var(--line);
}

.case-content {
  max-width: 850px;
}

.case-content h2 {
  font-size: 2.2rem;
  margin: 60px 0 18px;
}

.case-content p {
  color: var(--muted);
  font-size: 1.25rem;
  line-height: 1.75;
}

.reveal {
  opacity: 0;
  transform: translateY(45px) scale(0.98);
  transition: opacity 0.75s ease, transform 0.75s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Fail-safe: project pages should never stay invisible if JavaScript is delayed. */
.project-detail.reveal,
.about-page.reveal {
  opacity: 1;
  transform: none;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(14px); }
}

@media (max-width: 1100px) {
  .project-grid,
  .about-page {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 950px) {
  .site-header {
    height: auto;
    padding: 24px;
    flex-direction: column;
    gap: 24px;
  }

  nav {
    gap: 24px;
    flex-wrap: wrap;
    justify-content: center;
    font-size: 16px;
  }

  .panel {
    margin-top: 150px;
  }

  .project-image {
    height: 380px;
  }

  .about-image {
    height: 430px;
  }
}

@media (max-width: 600px) {
  .panel {
    margin-left: 12px;
    margin-right: 12px;
    border-radius: 34px;
  }

  .projects-section {
    padding: 80px 22px;
  }

  .project-image {
    height: 280px;
    border-radius: 22px;
  }

  .hero-photo {
    margin: 0 6px;
  }

  .button-row {
    flex-direction: column;
  }
}

/* STARBOUND PROJECT PAGE */
.project-hero-image {
  margin: 70px 0 90px;
  padding: 60px;
  border-radius: 42px;
  background: #f5f2ee;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
}

.project-hero-image img {
  width: 100%;
  max-width: 1100px;
  height: auto;
  display: block;
}

.wide-case {
  max-width: 100%;
}

.case-section {
  margin: 90px 0;
}

.case-section h2 {
  font-size: clamp(2.4rem, 5vw, 5rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
  margin-bottom: 24px;
}

.case-section p {
  color: var(--muted);
  font-size: clamp(1.05rem, 1.6vw, 1.35rem);
  line-height: 1.75;
  margin-bottom: 20px;
}

.two-column-case {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 70px;
  align-items: start;
}

.info-grid,
.empathy-grid {
  display: grid;
  gap: 24px;
  margin-top: 34px;
}

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

.empathy-grid {
  grid-template-columns: repeat(2, 1fr);
}

.info-grid article,
.empathy-grid article,
.task-callout {
  padding: 30px;
  border-radius: 28px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
}

.info-grid h3,
.empathy-grid h3,
.task-callout h3 {
  color: var(--blue);
  font-size: 1.35rem;
  margin-bottom: 12px;
}

.slide-figure {
  margin: 70px 0;
}

.slide-figure img {
  width: 100%;
  display: block;
  border-radius: 34px;
  border: 1px solid var(--line);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.12);
}

.slide-figure figcaption {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-top: 16px;
}

.task-callout {
  margin-top: 28px;
  background: linear-gradient(145deg, rgba(180, 74, 11, 0.10), var(--panel-soft));
}

@media (max-width: 900px) {
  .project-hero-image {
    padding: 28px;
    border-radius: 28px;
  }

  .two-column-case,
  .info-grid,
  .empathy-grid {
    grid-template-columns: 1fr;
  }

  .case-section {
    margin: 65px 0;
  }
}

/* LIGHT CASE STUDY PAGE — Starbound */
body.case-light {
  --case-bg: #ffffff;
  --case-panel: #faf9f7;
  --case-text: #171b21;
  --case-muted: #464b52;
  --case-accent: #0d64e8;
  --case-soft-blue: #eef5ff;
  background: var(--case-bg);
  color: var(--case-text);
}

body.case-light .site-header {
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

body.case-light .brand,
body.case-light nav a {
  color: var(--case-text);
}

body.case-light nav a:hover {
  color: var(--case-accent);
}

.case-main {
  padding-top: 124px;
}

.case-hero {
  min-height: 720px;
  margin: 28px 24px 0;
  padding: 120px 17vw;
  border-radius: 56px;
  background: var(--case-panel);
  display: grid;
  grid-template-columns: 1.35fr 0.8fr;
  gap: 90px;
  align-items: center;
}

.case-label {
  color: var(--case-accent);
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.95rem;
  font-weight: 900;
  margin-bottom: 28px;
}

.case-hero h1 {
  max-width: 830px;
  font-size: clamp(3.3rem, 5.4vw, 6.2rem);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.case-hero-copy > p:not(.case-label),
.text-section > p:not(.case-label) {
  margin-top: 30px;
  color: var(--case-muted);
  font-size: clamp(1.2rem, 1.5vw, 1.55rem);
  line-height: 1.6;
}

.prototype-button {
  display: inline-block;
  margin-top: 52px;
  padding: 20px 32px;
  border: 2px solid var(--case-accent);
  border-radius: 18px;
  color: var(--case-accent);
  font-size: 1.15rem;
  font-weight: 800;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.prototype-button:hover {
  transform: translateY(-4px);
  background: var(--case-accent);
  color: #fff;
}

.case-meta-card {
  padding: 58px 64px;
  border-radius: 42px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.06);
  transform: rotate(2deg);
}

.case-meta-card div {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 24px;
  align-items: baseline;
  margin-bottom: 34px;
}

.case-meta-card div:last-child {
  margin-bottom: 0;
}

.case-meta-card span {
  color: var(--case-accent);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-weight: 900;
}

.case-meta-card p {
  font-size: 1.5rem;
  line-height: 1.35;
}

.case-image-band,
.slide-showcase {
  margin: 56px 32px 120px;
  border-radius: 50px;
  overflow: hidden;
  background: #095df5;
}

.case-image-band {
  min-height: 760px;
  display: grid;
  place-items: center;
  padding: 80px;
}

.case-image-band img {
  width: min(1050px, 90%);
  height: auto;
  display: block;
  filter: drop-shadow(0 30px 50px rgba(0, 0, 0, 0.22));
}

.statement-panel {
  margin: 0 36px 150px;
  padding: 95px 12vw;
  border-radius: 0 0 56px 56px;
  background: var(--case-panel);
  text-align: center;
}

.statement-panel h2 {
  max-width: 1080px;
  margin: 0 auto;
  font-size: clamp(2.4rem, 4vw, 4.8rem);
  line-height: 1.3;
  letter-spacing: -0.045em;
}

.text-section {
  max-width: 980px;
  margin: 0 auto 105px;
  padding: 0 32px;
}

.text-section h2 {
  font-size: clamp(2.35rem, 4vw, 4.6rem);
  line-height: 1.12;
  letter-spacing: -0.05em;
}

.research-grid,
.empathy-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 54px;
}

.empathy-card-grid {
  grid-template-columns: repeat(2, 1fr);
}

.research-grid article,
.empathy-card-grid article {
  padding: 32px;
  border-radius: 28px;
  background: var(--case-panel);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.research-grid span {
  color: var(--case-accent);
  font-weight: 900;
  letter-spacing: 0.18em;
}

.research-grid h3,
.empathy-card-grid h3 {
  margin-top: 14px;
  margin-bottom: 14px;
  font-size: 1.4rem;
}

.research-grid p,
.empathy-card-grid p {
  color: var(--case-muted);
  font-size: 1.05rem;
  line-height: 1.6;
}

.slide-showcase {
  background: #050505;
  padding: 0;
}

.slide-showcase img {
  width: 100%;
  display: block;
}

.final-slide {
  margin-bottom: 150px;
}

body.case-light .reveal {
  transform: translateY(45px);
}

body.case-light .reveal.active {
  transform: translateY(0);
}

@media (max-width: 1150px) {
  .case-hero {
    grid-template-columns: 1fr;
    padding: 90px 8vw;
  }

  .case-meta-card {
    transform: none;
  }

  .case-image-band {
    min-height: 520px;
    padding: 48px;
  }

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

@media (max-width: 700px) {
  .case-main {
    padding-top: 150px;
  }

  .case-hero,
  .statement-panel,
  .case-image-band,
  .slide-showcase {
    margin-left: 14px;
    margin-right: 14px;
    border-radius: 34px;
  }

  .case-hero {
    padding: 58px 28px;
  }

  .case-meta-card {
    padding: 34px;
  }

  .case-meta-card div {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .statement-panel {
    padding: 70px 24px;
  }
}


/* LIGHT MODE REFINEMENTS */
body {
  background: #ffffff;
}

.site-header {
  color: var(--text);
}

nav a {
  color: #20242a;
}

nav a:hover {
  color: var(--blue);
}

.panel {
  box-shadow: 0 20px 70px rgba(0,0,0,0.04);
}

.project-detail.panel,
.about-page.panel {
  background: #ffffff;
  box-shadow: none;
}

.project-detail .mini-heading,
.case-section .mini-heading,
.project-type {
  color: var(--blue);
}

.button.light {
  border-color: rgba(0,0,0,0.35);
  color: var(--text);
}

.button.dark:hover,
.button.light:hover {
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.case-study-page {
  background: #ffffff;
  color: #171b21;
}

.case-study-page .site-header {
  background: rgba(255, 255, 255, 0.96);
  color: #171b21;
  border-bottom: 1px solid #ededed;
  box-shadow: 0 8px 35px rgba(0, 0, 0, 0.08);
}

.case-study-page .site-header nav a {
  color: #171b21;
}

.case-hero {
  min-height: 720px;
  padding: 170px 10% 100px;
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 80px;
  align-items: center;
}

.case-hero-text {
  max-width: 850px;
}

.project-label {
  color: #851eff;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.95rem;
  font-weight: 800;
  margin-bottom: 24px;
}

.case-hero h1 {
  font-size: clamp(3rem, 6vw, 5.7rem);
  line-height: 1.06;
  letter-spacing: -0.06em;
  margin-bottom: 32px;
}

.case-hero p,
.text-section p,
.process-intro p,
.process-section p,
.featured-story p {
  color: #4d535a;
  font-size: 1.28rem;
  line-height: 1.65;
}

.case-button {
  display: inline-block;
  margin-top: 42px;
  padding: 18px 30px;
  border-radius: 14px;
  border: 2px solid #851eff;
  color: #851eff;
  font-weight: 800;
  transition: 0.3s ease;
}

.case-button:hover {
  background: #851eff;
  color: #fff;
  transform: translateY(-4px);
}

.project-info-box {
  background: #ffffff;
  border-radius: 42px;
  padding: 48px;
  box-shadow: 0 18px 80px rgba(0, 0, 0, 0.08);
  transform: rotate(2deg);
}

.project-info-box div {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 24px;
  margin-bottom: 30px;
}

.project-info-box div:last-child {
  margin-bottom: 0;
}

.project-info-box span {
  color: #851eff;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-weight: 800;
}

.project-info-box p {
  font-size: 1.25rem;
  color: #171b21;
}

.hero-image-section {
  margin: 0 32px 120px;
  border-radius: 56px;
  background: #0b0b0b;
  overflow: hidden;
}

.hero-image-section img {
  width: 100%;
  display: block;
}

.statement-section {
  max-width: 1300px;
  margin: 0 auto 140px;
  padding: 110px 8%;
  text-align: center;
  background: #faf7f5;
  border-radius: 0 0 56px 56px;
}

.statement-section h2 {
  font-size: clamp(2.4rem, 5vw, 4.5rem);
  line-height: 1.22;
  letter-spacing: -0.05em;
}

.text-section,
.process-intro {
  max-width: 900px;
  margin: 0 auto 140px;
  padding: 0 32px;
}

.text-section h2,
.process-intro h2,
.process-section h2,
.featured-story h2 {
  font-size: clamp(2.4rem, 4vw, 4rem);
  line-height: 1.1;
  letter-spacing: -0.05em;
  margin-bottom: 26px;
}

.three-column {
  width: 86%;
  margin: 0 auto 150px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.three-column div {
  background: #faf7f5;
  padding: 42px;
  border-radius: 32px;
}

.three-column h3 {
  font-size: 1.8rem;
  margin-bottom: 16px;
}

.three-column p {
  color: #4d535a;
  font-size: 1.1rem;
  line-height: 1.6;
}

.process-section {
  width: 86%;
  margin: 0 auto 150px;
}

.process-text {
  max-width: 820px;
  margin-bottom: 42px;
}

.process-number {
  color: #851eff !important;
  font-weight: 900;
  letter-spacing: 0.2em;
  font-size: 1rem !important;
  margin-bottom: 18px;
}

.process-section img {
  width: 100%;
  border-radius: 36px;
  display: block;
  box-shadow: 0 18px 70px rgba(0, 0, 0, 0.12);
}

.featured-story {
  width: 86%;
  margin: 0 auto 150px;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 70px;
  align-items: center;
}

.featured-story img {
  width: 100%;
  border-radius: 36px;
  box-shadow: 0 18px 70px rgba(0, 0, 0, 0.12);
}

.next-project {
  padding: 100px 8%;
  text-align: center;
}

.next-project a {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 900;
  letter-spacing: -0.06em;
}

@media (max-width: 900px) {
  .case-hero,
  .featured-story,
  .three-column {
    grid-template-columns: 1fr;
  }

  .case-hero {
    padding-top: 150px;
  }

  .project-info-box {
    transform: none;
  }
}

.safely-hero {
  background: linear-gradient(135deg, #eb2f8d, #0b8cff);
}

.safely-hero img {
  width: 100%;
  display: block;
}

.zen-hero {
  background: #f7f6f2;
}

.zen-hero img {
  width: 100%;
  display: block;
}

.video-section {
  width: 86%;
  margin: 0 auto 150px;
}

.video-section h2 {
  font-size: clamp(2.4rem, 4vw, 4rem);
  line-height: 1.1;
  letter-spacing: -0.05em;
  margin-bottom: 26px;
}

.video-section p {
  max-width: 760px;
  color: #4d535a;
  font-size: 1.28rem;
  line-height: 1.65;
  margin-bottom: 42px;
}

.video-section video {
  width: 100%;
  border-radius: 36px;
  display: block;
  box-shadow: 0 18px 70px rgba(0, 0, 0, 0.12);
  background: #000;
}

.chris-case .project-label,
.blue-label {
  color: #00549a;
}

.blue-button {
  border-color: #00549a;
  color: #00549a;
}

.blue-button:hover {
  background: #00549a;
  color: #ffffff;
}

.blue-number {
  color: #00549a !important;
}

.chris-case .project-info-box span {
  color: #00549a;
}

.chris-hero {
  background: #050505;
}

.chris-hero img {
  width: 100%;
  display: block;
}

.chris-case .three-column div {
  background: #f3f6fa;
}

.chris-case .statement-section {
  background: #f3f6fa;
}

.wayste-case .project-label,
.wayste-case .project-info-box span,
.blue-label {
  color: #0b5fe8;
}

.blue-button {
  border-color: #0b5fe8;
  color: #0b5fe8;
}

.blue-button:hover {
  background: #0b5fe8;
  color: #ffffff;
}

.blue-number {
  color: #0b5fe8 !important;
}

.wayste-hero {
  background: #ffffff;
}

.wayste-hero img {
  width: 100%;
  display: block;
}
