/* Shared base extracted from the existing portfolio project pages. */

:root {
  --bg: #f4efe8;
  --bg-warm: #ebe4d9;
  --bg-soft: #efe9de;
  --ink: #131211;
  --ink-soft: #2c2826;
  --muted: #6b6259;
  --line: #d8cfc1;
  --dark: #0d0c0b;
  --dark-soft: #1a1816;
  --accent: #b94e2c;
  --accent-warm: #d56a3f;
  --serif: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter Tight', 'Inter', system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'ss01', 'cv11';
}

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

/* ============== NAV ============== */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 48px;
  z-index: 100;
  mix-blend-mode: difference;
  color: white;
  pointer-events: none;
}
.site-nav > * { pointer-events: auto; }
.nav-logo {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
  font-style: italic;
}
.nav-links {
  display: flex;
  gap: 36px;
  font-size: 14px;
  letter-spacing: 0.02em;
}
.nav-links a {
  position: relative;
  padding-bottom: 2px;
  transition: opacity 0.2s;
}
.nav-links a.active::after {
  content: none;
  position: absolute;
  left: 0; right: 0;
  bottom: -2px;
  height: 1px;
  background: currentColor;
}
.nav-links a:hover { opacity: 0.7; }

@media (max-width: 720px) {
  .site-nav { padding: 20px 24px; }
  .nav-links { gap: 24px; font-size: 13px; }
}

/* ============== HOME HERO ============== */
.hero {
  min-height: 100vh; min-height: 100dvh;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 0 48px 80px;
  overflow: hidden;
  background: linear-gradient(135deg, #f4efe8 0%, #e8ddc8 100%);
}

.hero-orb {
  position: absolute;
  top: -10%;
  right: -5%;
  width: 70vw;
  height: 90vh;
  background: radial-gradient(ellipse at 30% 40%,
    rgba(120, 80, 220, 0.85) 0%,
    rgba(140, 60, 200, 0.6) 25%,
    rgba(180, 90, 220, 0.3) 45%,
    transparent 70%);
  filter: blur(20px);
  border-radius: 50% 40% 60% 30%;
  animation: orb-drift 20s ease-in-out infinite alternate;
}

@keyframes orb-drift {
  0%   { transform: translate(0, 0) rotate(0deg) scale(1); }
  50%  { transform: translate(-30px, 20px) rotate(-5deg) scale(1.05); }
  100% { transform: translate(20px, -30px) rotate(3deg) scale(0.98); }
}

.hero-content {
  position: relative;
  max-width: 920px;
  z-index: 2;
}
.hero-greeting {
  font-family: var(--serif);
  font-size: clamp(20px, 2.2vw, 28px);
  font-weight: 400;
  font-style: italic;
  margin-bottom: 18px;
  color: var(--ink-soft);
}
.hero-headline {
  font-family: var(--serif);
  font-size: clamp(48px, 7.5vw, 110px);
  font-weight: 350;
  line-height: 1.02;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.hero-headline em { font-style: italic; font-weight: 350; }
.hero-headline .accent { font-style: italic; color: var(--accent); }

.scroll-cue {
  position: absolute;
  bottom: 36px; right: 48px;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 2;
}
.scroll-cue::before {
  content: none;
  width: 32px;
  height: 1px;
  background: currentColor;
  display: block;
}

@media (max-width: 720px) {
  .hero { padding: 0 24px 60px; }
  .scroll-cue { right: 24px; bottom: 24px; }
}

/* ============== PROJECTS GRID ============== */
.projects-section {
  background: var(--dark);
  color: #efe8db;
  padding: 100px 48px 80px;
}
.projects-section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 0;
  padding-bottom: 24px;
  margin-bottom: 64px;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #8a7e6e;
}
.projects-section-head h2 {
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: #efe8db;
}
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 64px 48px;
}
@media (max-width: 980px) { .projects-grid { grid-template-columns: repeat(2, 1fr); gap: 48px 32px; } }
@media (max-width: 600px) { .projects-grid { grid-template-columns: 1fr; gap: 40px; } }

.project-card { display: block; cursor: pointer; }
.project-card-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #1a1816;
  border-radius: 4px;
}
.project-card-media img,
.project-card-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.project-card:hover .project-card-media img,
.project-card:hover .project-card-media video { transform: scale(1.04); }
.project-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 16px;
  font-size: 14px;
  color: #d4c8b6;
  font-weight: 400;
}
.project-card-meta .num {
  font-family: var(--serif);
  font-style: italic;
  color: #8a7e6e;
  font-size: 13px;
}

@media (max-width: 720px) { .projects-section { padding: 64px 24px 60px; } }

/* ============== HOME FOOTER ============== */
.home-footer {
  background: var(--dark);
  color: #efe8db;
  padding: 80px 48px 60px;
  border-top: 0;
}
.home-footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: end;
}
.home-footer h2 {
  font-family: var(--serif);
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 350;
  line-height: 1;
  letter-spacing: -0.02em;
  font-style: italic;
}
.home-footer-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 16px;
}
.home-footer-links a {
  display: inline-block;
  padding: 4px 0;
  border-bottom: 0;
  transition: padding-left 0.2s, border-color 0.2s;
}
.home-footer-links a:hover {
  padding-left: 8px;
  border-color: #efe8db;
}
.home-footer-links .label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #8a7e6e;
  margin-bottom: 8px;
}
.home-footer-base {
  margin-top: 80px;
  padding-top: 24px;
  border-top: 0;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #8a7e6e;
  letter-spacing: 0.05em;
}
@media (max-width: 720px) {
  .home-footer { padding: 60px 24px 40px; }
  .home-footer-grid { grid-template-columns: 1fr; gap: 36px; }
}

/* ============== PROJECT PAGES ============== */
.project-hero {
  padding: 140px 48px 80px;
  background: var(--bg);
}
.project-hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 80px;
  max-width: 1400px;
  margin: 0 auto;
  align-items: end;
}
.project-hero-title {
  font-family: var(--serif);
  font-size: clamp(56px, 8vw, 120px);
  line-height: 0.95;
  font-weight: 350;
  letter-spacing: -0.03em;
}
.project-hero-title .main { display: block; }
.project-hero-title .sub  { display: block; font-style: italic; font-weight: 350; font-size: 0.42em; line-height: 1.1; margin-top: 16px; color: var(--ink-soft); }
.project-hero-title .year { display: inline-block; font-weight: 600; font-style: normal; }
.project-hero-role {
  background: var(--bg-warm);
  border-radius: 14px;
  padding: 32px 36px;
  font-size: 15px;
  line-height: 1.65;
}
.project-hero-role .label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
  display: block;
}
.project-hero-role h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 14px;
  color: var(--ink);
}
.project-hero-role p { color: var(--ink-soft); }

@media (max-width: 980px) {
  .project-hero { padding: 120px 24px 60px; }
  .project-hero-grid { grid-template-columns: 1fr; gap: 40px; }
}

.project-hero-image {
  width: 100%;
  margin: 0 auto;
  padding: 0 48px 60px;
  background: var(--bg);
}
.project-hero-image-inner {
  border-radius: 8px;
  overflow: hidden;
  background: #fafafa;
}
.project-hero-image img,
.project-hero-image video {
  width: 100%;
  max-height: 75vh;
  object-fit: cover;
  display: block;
}
@media (max-width: 720px) { .project-hero-image { padding: 0 24px 40px; } }

/* Section title rail */
.section-rail {
  text-align: center;
  padding: 100px 48px 60px;
  background: var(--bg);
}
.section-rail .kicker {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 350;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
.section-rail .sub {
  font-family: var(--serif);
  font-size: clamp(18px, 2vw, 24px);
  font-style: italic;
  font-weight: 350;
  color: var(--muted);
  max-width: 720px;
  margin: 0 auto;
}

/* Banner cards */
.banner-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  padding: 0 48px 80px;
  max-width: 1500px;
  margin: 0 auto;
}
@media (max-width: 980px) { .banner-grid { grid-template-columns: repeat(2, 1fr); padding: 0 24px 60px; } }
@media (max-width: 600px) { .banner-grid { grid-template-columns: 1fr; gap: 32px; } }

.banner-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
}
.banner-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.08);
}
.banner-card-media {
  aspect-ratio: 4 / 3;
  background: #f6f1e8;
  overflow: hidden;
}
.banner-card-media img { width: 100%; height: 100%; object-fit: cover; }
.banner-card-body { padding: 24px 26px 28px; flex: 1; }
.banner-card-body h3 {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.25;
  font-weight: 400;
  margin-bottom: 12px;
  color: var(--ink);
}
.banner-card-body p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-soft);
}

/* Where will your journey */
.journey-section {
  background: linear-gradient(180deg, #f5b558 0%, #e8a14a 100%);
  color: var(--ink);
  padding: 100px 48px;
  position: relative;
  overflow: hidden;
}
.journey-section::before {
  content: '';
  position: absolute;
  top: 10%; left: 5%;
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(255,255,255,0.4), transparent 70%);
  filter: blur(40px);
}
.journey-section::after {
  content: '';
  position: absolute;
  bottom: 5%; right: 5%;
  width: 250px; height: 250px;
  background: radial-gradient(circle, rgba(255,255,255,0.3), transparent 70%);
  filter: blur(40px);
}
.journey-section h2 {
  font-family: var(--serif);
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 350;
  font-style: italic;
  text-align: center;
  margin-bottom: 60px;
  position: relative;
  z-index: 2;
}
.journey-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  max-width: 1400px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}
.journey-card {
  background: rgba(255,255,255,0.15);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.3);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
}
.journey-card-img {
  aspect-ratio: 1;
  overflow: hidden;
  background: rgba(255,255,255,0.2);
}
.journey-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s;
}
.journey-card:hover .journey-card-img img { transform: scale(1.04); }
.journey-card h3 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.3;
  padding: 20px 22px 24px;
}
.journey-cta {
  text-align: center;
  margin-top: 60px;
  position: relative;
  z-index: 2;
}
.journey-cta a {
  display: inline-block;
  padding: 14px 36px;
  background: var(--ink);
  color: var(--bg);
  border-radius: 999px;
  font-size: 14px;
  letter-spacing: 0.04em;
  transition: transform 0.2s, background 0.2s;
}
.journey-cta a:hover { transform: scale(1.05); background: var(--accent); }

@media (max-width: 980px) { .journey-grid { grid-template-columns: repeat(2, 1fr); } .journey-section { padding: 60px 24px; } }
@media (max-width: 600px) { .journey-grid { grid-template-columns: 1fr; } }

/* MyStories style block */
.midstory {
  padding: 120px 48px;
  max-width: 1300px;
  margin: 0 auto;
}
.midstory-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}
.midstory-head h2 {
  font-family: var(--serif);
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 350;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.midstory-head p {
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink-soft);
  align-self: end;
}
.midstory-previews {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 48px;
}
.midstory-previews > div {
  background: #d8d3c5;
  border-radius: 16px;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.midstory-previews img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}
.principles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px 60px;
  margin-top: 60px;
}
.principle {
  font-size: 15px;
  line-height: 1.6;
}
.principle b {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--ink);
  display: inline-block;
  margin-right: 6px;
}
.principle span { color: var(--ink-soft); }

@media (max-width: 760px) {
  .midstory { padding: 80px 24px; }
  .midstory-head { grid-template-columns: 1fr; gap: 24px; }
  .midstory-previews { grid-template-columns: 1fr; }
  .principles { grid-template-columns: 1fr; gap: 24px; }
}

/* HiBob design system 4-up */
.dsystem-4col {
  padding: 120px 48px;
  max-width: 1500px;
  margin: 0 auto;
}
.dsystem-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-bottom: 64px;
}
.dsystem-head h2 {
  font-family: var(--serif);
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 350;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.dsystem-head p {
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink-soft);
  align-self: end;
}
.dsystem-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 36px;
}
.dsystem-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.dsystem-card-media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #f6f1e8;
}
.dsystem-card-media img { width: 100%; height: 100%; object-fit: cover; }
.dsystem-card-body { padding: 24px 28px 30px; }
.dsystem-card-body .label {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
  display: block;
}
.dsystem-card-body h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 400;
  margin-bottom: 10px;
}
.dsystem-card-body p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-soft);
}
@media (max-width: 760px) {
  .dsystem-4col { padding: 80px 24px; }
  .dsystem-head { grid-template-columns: 1fr; gap: 20px; }
  .dsystem-grid { grid-template-columns: 1fr; }
}

/* Two-column case study layout */
.case-study {
  padding: 100px 48px;
  max-width: 1300px;
  margin: 0 auto;
}
.case-study-blurb {
  font-family: var(--serif);
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.4;
  font-weight: 350;
  margin-bottom: 60px;
  max-width: 920px;
  color: var(--ink);
}
.case-study-blurb em { font-style: italic; }

.cs-section {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 60px;
  padding: 36px 0;
  border-top: 0;
}
.cs-section:last-child { border-bottom: 0; }
.cs-section h2 {
  font-family: var(--serif);
  font-size: 28px;
  font-weight: 400;
  font-style: italic;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.cs-section .body {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink-soft);
}
.cs-section .body p { margin-bottom: 16px; }
.cs-section .body ul { margin: 16px 0 16px 22px; }
.cs-section .body li { margin-bottom: 10px; padding-left: 4px; }
.cs-section .body li::marker { color: var(--accent); }

.cs-sub {
  margin: 24px 0 12px;
}
.cs-sub h3 {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--ink);
}

@media (max-width: 760px) {
  .case-study { padding: 60px 24px; }
  .cs-section { grid-template-columns: 1fr; gap: 16px; padding: 28px 0; }
}

/* Captioned gallery */
.cs-gallery {
  padding: 80px 48px 100px;
  background: var(--bg-warm);
}
.cs-gallery-inner {
  max-width: 1300px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
}
.cs-gallery-item {
  display: flex;
  flex-direction: column;
}
.cs-gallery-item.full { grid-column: 1 / -1; }
.cs-gallery-media {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.cs-gallery-item.full .cs-gallery-media { aspect-ratio: 16 / 9; }
.cs-gallery-media img,
.cs-gallery-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cs-gallery-item .caption {
  margin-top: 14px;
  font-size: 13px;
  color: var(--muted);
  font-family: var(--serif);
  font-style: italic;
}
@media (max-width: 760px) {
  .cs-gallery { padding: 60px 24px; }
  .cs-gallery-inner { grid-template-columns: 1fr; gap: 28px; }
  .cs-gallery-item.full .cs-gallery-media { aspect-ratio: 4 / 3; }
}

/* Project navigation */
.project-nav {
  background: var(--bg);
  padding: 80px 48px;
  border-top: 0;
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}
.project-nav a {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  background: var(--ink);
  color: var(--bg);
  border-radius: 999px;
  font-size: 14px;
  transition: transform 0.2s, background 0.2s;
}
.project-nav a:hover { transform: scale(1.04); background: var(--accent); }
.project-nav .arrow { font-family: var(--serif); }

/* Site footer */
.site-footer {
  background: var(--dark);
  color: #efe8db;
  padding: 60px 48px 40px;
}
.site-footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: end;
  max-width: 1400px;
  margin: 0 auto;
  flex-wrap: wrap;
  gap: 40px;
}
.site-footer h3 {
  font-family: var(--serif);
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 350;
  font-style: italic;
}
.site-footer .links { display: flex; gap: 36px; align-items: end; padding-bottom: 8px; }
.site-footer .links a {
  border-bottom: 0;
  padding-bottom: 4px;
  transition: border-color 0.2s;
}
.site-footer .links a:hover { border-color: #efe8db; }
.site-footer .meta {
  margin-top: 50px;
  padding-top: 24px;
  border-top: 0;
  font-size: 12px;
  color: #8a7e6e;
  letter-spacing: 0.05em;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
@media (max-width: 720px) {
  .site-footer { padding: 50px 24px 30px; }
  .site-footer .links { flex-direction: column; gap: 8px; }
}

/* About page */
.about-hero {
  min-height: 90vh;
  padding: 160px 48px 80px;
  background: var(--bg);
  display: flex;
  align-items: center;
}
.about-hero-grid {
  max-width: 1300px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 80px;
  align-items: center;
}
.about-hero h1 {
  font-family: var(--serif);
  font-size: clamp(48px, 6.5vw, 92px);
  line-height: 1;
  font-weight: 350;
  letter-spacing: -0.025em;
}
.about-hero h1 em { font-style: italic; }
.about-hero p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-soft);
  margin-top: 24px;
  max-width: 580px;
}
.about-portrait {
  aspect-ratio: 4 / 5;
  background: var(--bg-warm);
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}
.about-portrait::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 30%, rgba(180, 90, 220, 0.4), transparent 60%);
}
.about-portrait .placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-style: italic;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: 0.1em;
}

@media (max-width: 760px) {
  .about-hero { padding: 120px 24px 60px; }
  .about-hero-grid { grid-template-columns: 1fr; gap: 40px; }
}

/* Pre-launch accessibility and interaction QA */
.skip-link{position:fixed;left:16px;top:12px;z-index:9999;padding:10px 14px;background:#fff;color:#111;border-radius:4px;transform:translateY(-160%);transition:transform .2s ease}.skip-link:focus{transform:translateY(0)}
a:focus-visible,button:focus-visible{outline:3px solid var(--accent-warm);outline-offset:4px;border-radius:3px}

@media (max-width:420px){.site-nav{padding-left:18px;padding-right:18px}.nav-links{gap:18px}.site-footer,.projects-section,.home-footer{padding-left:20px;padding-right:20px}}

/* Final pre-launch QA hardening */
html, body { max-width: 100%; overflow-x: clip; }
button, a { -webkit-tap-highlight-color: transparent; }
a, button { touch-action: manipulation; }
img, video { max-inline-size: 100%; }
@media (max-width: 600px) {
  a, button { min-height: 44px; }
  .nav-links a, .nav-logo { display: inline-flex; align-items: center; }
}
@supports not (overflow: clip) {
  html, body { overflow-x: hidden; }
}


/* Production QA pass: responsive, accessible, and performance-safe */
:where(a, button, input, textarea, select):focus-visible {
  outline: 3px solid var(--accent-warm);
  outline-offset: 4px;
}
.site-nav a { min-block-size: 44px; display: inline-flex; align-items: center; }
@media (max-width: 720px) {
  .site-nav { padding: 16px clamp(18px, 5vw, 24px); }
  .nav-links { gap: clamp(14px, 5vw, 24px); }
}
@media (max-width: 420px) {
  .projects-section { padding: 72px 20px 64px; }
  .projects-section-head { margin-bottom: 40px; }
  .home-footer, .site-footer { padding-left: 20px; padding-right: 20px; }
  .project-card-meta { gap: 16px; }
  .project-card-meta span:first-child { min-width: 0; }
}
.project-card-media.media-contain {
  background: #161311;
  display: grid;
  place-items: center;
}
.project-card-media.media-contain video {
  object-fit: contain;
  transform: none !important;
}
.cs-gallery-media.low-res-media {
  background: #151210;
  padding: clamp(18px, 4vw, 56px);
  display: grid;
  place-items: center;
}
.cs-gallery-media.low-res-media video {
  width: min(100%, 600px);
  height: auto;
  object-fit: contain;
}
video { background: #151210; }
@media (prefers-reduced-motion: reduce) {
  .project-card:hover .project-card-media img,
  .project-card:hover .project-card-media video { transform: none; }
}



/* Final visual QA: reduce oversized headings and prevent soft project screenshots from being over-enlarged. */
.hero-headline {
  font-size: clamp(42px, 6.2vw, 88px);
  line-height: 0.98;
}
.project-hero-title {
  font-size: clamp(48px, 6.5vw, 92px);
}
.project-hero-title .sub {
  font-size: 0.38em;
}
.section-rail .kicker,
.journey-section h2,
.midstory-head h2,
.dsystem-head h2,
.about-section h2,
.about-hero h1 {
  font-size: clamp(34px, 4.4vw, 58px);
}
.case-study-blurb {
  font-size: clamp(26px, 3.2vw, 42px);
  line-height: 1.18;
}
.cs-section h2 {
  font-size: clamp(24px, 2.2vw, 30px);
}
.project-hero-image {
  width: min(100%, 1240px);
  padding: 0 clamp(24px, 4vw, 48px) clamp(44px, 5vw, 64px);
}
.project-hero-image-inner {
  display: grid;
  place-items: center;
  background: #f7f4ee;
  box-shadow: 0 1px 0 rgba(19,18,17,.04);
}
.project-hero-image img,
.project-hero-image video {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: min(72vh, 760px);
  object-fit: contain;
  margin-inline: auto;
}
/* These hero screenshots contain fine UI text and look soft when stretched across a large monitor. */
body:has(.project-hero-title .main) .project-hero-image-inner {
  padding: clamp(12px, 1.6vw, 24px);
}
@media (min-width: 1280px) {
  .project-hero-image { width: min(100%, 1180px); }
}
@media (max-width: 720px) {
  .hero-headline { font-size: clamp(40px, 12vw, 58px); }
  .project-hero-title { font-size: clamp(46px, 14vw, 68px); }
  .project-hero-title .sub { font-size: 0.42em; }
  .section-rail .kicker,
  .journey-section h2,
  .midstory-head h2,
  .dsystem-head h2,
  .about-section h2,
  .about-hero h1 { font-size: clamp(32px, 10vw, 46px); }
  .case-study-blurb { font-size: clamp(24px, 7vw, 34px); }
  .project-hero-image { width: 100%; padding-inline: 18px; }
  .project-hero-image-inner { padding: 8px; }
}



.project-hero-image-inner.film { background:#0d0c0b; border-radius:8px; }
.project-hero-image-inner.film video { width:100%; max-height:min(74vh,780px); object-fit:contain; background:#0d0c0b; }
.cs-tools { display:flex; flex-wrap:wrap; gap:10px; }
.cs-tools span { font-size:13px; letter-spacing:.02em; color:var(--ink); border:1px solid var(--line); border-radius:999px; padding:7px 14px; background:var(--bg-soft); }
.hero-note { display:inline-block; font-size:11px; letter-spacing:.18em; text-transform:uppercase; color:#fff; background:var(--accent); padding:5px 12px; border-radius:999px; margin-bottom:18px; }



/* animated gradient header on inner pages */
.project-hero, .about-hero { position: relative; overflow: hidden;
  background: linear-gradient(120deg,#f4efe8,#efe6f2,#e6d9f3,#f1e3dd,#ece0f0,#f4efe8);
  background-size: 320% 320%; animation: heroGradient 20s ease infinite; }
.project-hero::after { content:""; position:absolute; width:42vw; height:42vw; right:-6%; top:-22%;
  background: radial-gradient(circle, rgba(150,90,220,.32), transparent 68%); filter: blur(60px); z-index:0; pointer-events:none; animation: blobA 24s ease-in-out infinite alternate; }
.project-hero-grid, .about-hero > * { position: relative; z-index: 1; }
@keyframes heroGradient { 0%{background-position:0% 50%} 50%{background-position:100% 50%} 100%{background-position:0% 50%} }
@keyframes blobA { 0%{transform:translate(0,0) scale(1)} 100%{transform:translate(-30px,24px) scale(1.12)} }
/* recolour hero accent away from the red 'warning' look */
.hero-headline .accent { background: linear-gradient(92deg,#7b4fd1,#a86bd0 55%,#c58aa0); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
/* remove the short scroll-cue divider dash */
.scroll-cue::before { display: none !important; }
.scroll-cue { gap: 0 !important; }
/* scroll reveal */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
/* project card hover caption */
.project-card-media { position: relative; }
.project-card-media::after { content: "View project →"; position: absolute; left: 14px; bottom: 14px; z-index: 3;
  font-size: 12px; letter-spacing: .02em; color: #fff; background: rgba(19,18,17,.72); padding: 7px 12px; border-radius: 999px;
  opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .3s; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); pointer-events: none; }
.project-card:hover .project-card-media::after { opacity: 1; transform: none; }
.project-card.is-app .project-card-media::after { content: "Open app →"; }
/* live-app tile */
.app-tile { background: radial-gradient(120% 120% at 30% 20%, #241f3a, #0d0c0b 70%); display: grid; place-items: center; }
.app-tile-inner { text-align: center; color: #efe8db; padding: 24px; }
.app-name { font-family: var(--serif); font-style: italic; font-size: clamp(26px,3vw,34px); }
.app-sub { font-size: 13px; color: #b9ad9b; margin-top: 8px; }
.tag-live { background: #2ec26a !important; }
/* zoomable images */
.cs-gallery-media img, .project-hero-image img, .banner-card-media img, .midstory-previews img, .journey-card-img img { cursor: zoom-in; }
/* lightbox */
#lb { position: fixed; inset: 0; background: rgba(10,9,8,.93); display: none; align-items: center; justify-content: center; z-index: 9999; padding: 4vw; cursor: zoom-out; opacity: 0; transition: opacity .25s; }
#lb.open { display: flex; opacity: 1; }
#lb img { max-width: 96vw; max-height: 92vh; object-fit: contain; border-radius: 6px; box-shadow: 0 24px 70px rgba(0,0,0,.55); }
#lb .lb-close { position: fixed; top: 18px; right: 26px; color: #fff; font-size: 32px; line-height: 1; cursor: pointer; opacity: .85; }
/* nav gains a soft backdrop once scrolled */
.site-nav.scrolled { mix-blend-mode: normal; color: var(--ink); background: rgba(244,239,232,.7); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }




.project-key-hint { position: fixed; right: 22px; bottom: 20px; z-index: 90; display: flex; align-items: center; gap: 5px; padding: 7px 9px; border: 1px solid rgba(19,18,17,.16); border-radius: 999px; background: rgba(244,239,232,.78); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); color: var(--ink); box-shadow: 0 8px 28px rgba(19,18,17,.08); font-size: 11px; line-height: 1; }
.project-key-hint a, .project-key-hint .is-disabled { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; font-family: var(--sans); font-size: 14px; transition: background .2s ease, transform .2s ease; }
.project-key-hint a:hover { background: rgba(19,18,17,.08); transform: translateY(-1px); }
.project-key-hint .is-disabled { opacity: .25; }
.project-key-hint small { margin: 0 4px 0 2px; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; font-size: 9px; }
@media (max-width: 760px), (pointer: coarse) { .project-key-hint { display: none; } }

