/* ============================================================
   ANDREA PERGEL — Portfolio
   Global Stylesheet
   Style: Minimal / Editorial (Dieter Rams / Muji)
   ============================================================ */

/* ------------------------------------------------------------
   1. RESET & BASE
   ------------------------------------------------------------ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Palette — white with lavender accents */
  --bg:          #F9F9F7;
  --fg:          #42443E;
  --fg-muted:    #767672;
  --fg-subtle:   #B0B0AA;
  --border:      #DDD9EC;
  --accent:      #7B72A0;
  --accent-ink:  #6A5FA0;
  --accent-strong: #564C84;
  --accent-tint:  rgba(123, 114, 160, 0.14);

  /* Orb gradient */
  --orb-a:       rgba(200, 185, 230, 0.60);
  --orb-b:       rgba(225, 175, 100, 0.30);
  --orb-c:       rgba(180, 160, 220, 0.15);

  /* Typography */
  --font-sans:   'DM Sans', system-ui, -apple-system, sans-serif;
  --font-serif:  'DM Serif Display', Georgia, serif;

  /* Spacing scale */
  --space-xs:    0.5rem;
  --space-sm:    1rem;
  --space-md:    2rem;
  --space-lg:    4rem;
  --space-xl:    8rem;

  /* Layout */
  --max-w:       clamp(1100px, 72vw, 1440px);
  --nav-h:       72px;
}

html {
  font-size: clamp(16px, 0.16vw + 14px, 18px);
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

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

ul, ol {
  list-style: none;
}

/* ------------------------------------------------------------
   2. TYPOGRAPHY
   ------------------------------------------------------------ */

/* Display — used for hero / section titles */
.t-display {
  font-family: var(--font-serif);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

/* Heading 1 */
h1, .t-h1 {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.015em;
}

/* Heading 2 */
h2, .t-h2 {
  font-family: var(--font-sans);
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

/* Heading 3 */
h3, .t-h3 {
  font-family: var(--font-sans);
  font-size: 1.125rem;
  font-weight: 500;
  line-height: 1.3;
}

/* Body */
p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--fg-muted);
  max-width: 60ch;
}

/* Small / label */
.t-label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ------------------------------------------------------------
   3. LAYOUT UTILITIES
   ------------------------------------------------------------ */

.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

.section {
  padding-block: var(--space-xl);
}

.section--sm {
  padding-block: var(--space-md);
}

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin-block: 0;
}

/* ------------------------------------------------------------
   4. NAV
   ------------------------------------------------------------ */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  background-color: var(--bg);
  border-bottom: none;
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.07);
  z-index: 100;
  display: flex;
  align-items: center;
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

.nav__logo {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--fg);
}

.nav__monogram {
  height: 6rem;
  width: auto;
  display: block;
  mix-blend-mode: multiply;
}

.footer__monogram {
  mix-blend-mode: multiply;
}

.nav__links {
  display: flex;
  gap: var(--space-md);
}

.nav__link {
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

.nav__link:hover { color: var(--accent-ink); text-decoration: underline; }
.nav__link.is-active { color: var(--accent-ink); }

/* Hamburger — mobile only */
.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav__toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--fg);
  margin-block: 5px;
  transition: all 0.25s ease;
}

/* ------------------------------------------------------------
   5. PAGE OFFSET (below fixed nav)
   ------------------------------------------------------------ */

.page-wrap {
  margin-top: var(--nav-h);
  flex: 1;
}

/* ------------------------------------------------------------
   6. HERO
   ------------------------------------------------------------ */

.hero {
  padding-block: var(--space-xl) var(--space-lg);
  border-bottom: 1px solid var(--border);
}

.hero__eyebrow {
  margin-bottom: var(--space-md);
  color: var(--accent);
  letter-spacing: 0.25em;
}

.hero__title {
  margin-bottom: var(--space-md);
}

.hero__sub {
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  line-height: 1.6;
  color: var(--fg-muted);
  max-width: 50ch;
}

.hero__links {
  margin-top: var(--space-md);
  display: flex;
  align-items: center;
  gap: 0.9rem;
  max-width: none;
}
.hero__links a {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  transition: color 0.2s, border-color 0.2s, background-color 0.2s, transform 0.2s;
}
/* Plain scroll cue — no pill */
.hero__links a.hero__links--plain {
  color: var(--fg-muted);
}
.hero__links a.hero__links--plain:hover {
  color: var(--accent-ink);
  text-decoration: underline;
  transform: translateY(2px);
}
/* Outlined pill */
.hero__links a:not(.hero__links--plain):not(.hero__links--filled) {
  color: var(--fg-muted);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.35em 0.9em;
}
.hero__links a:not(.hero__links--plain):not(.hero__links--filled):hover {
  color: var(--accent-ink);
  border-color: var(--accent-ink);
}
/* Filled pill */
.hero__links a.hero__links--filled {
  background-color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0.35em 0.9em;
  color: #fff;
}
.hero__links a.hero__links--filled:hover {
  background-color: transparent;
  color: var(--accent-ink);
}
.hero__links-dot {
  display: inline;
  color: var(--fg-subtle);
}

/* ------------------------------------------------------------
   7. PROJECT GRID
   ------------------------------------------------------------ */

.project-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-xs) var(--space-sm);
  background-color: transparent;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

.project-card {
  flex: 0 0 calc(33.333% - 0.667rem);
  background-color: var(--bg);
  overflow: hidden;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s ease;
}

.project-card:hover {
  box-shadow: 0 8px 32px rgba(123, 114, 160, 0.35), 0 2px 8px rgba(123, 114, 160, 0.2);
}

.project-card__image {
  aspect-ratio: 4 / 3;
  background-color: var(--border);
  overflow: hidden;
  border-radius: 12px;
}

.project-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  mix-blend-mode: multiply;
  transition: transform 0.5s ease;
}

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

.project-card__body {
  padding: 0.75rem var(--space-sm) var(--space-sm);
}

.project-card__title {
  font-size: 1rem;
  font-weight: 500;
  color: var(--fg);
  margin-bottom: 0.25rem;
}

.project-card__category {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  max-width: none;
}

.project-card__tags {
  margin-top: 0.3rem;
  white-space: nowrap;
  overflow: hidden;
}

.project-card__tag {
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}

.project-card__tag::after {
  content: ' · ';
}

.project-card__tag:last-child::after {
  content: '';
}

/* ------------------------------------------------------------
   8. ABOUT PAGE
   ------------------------------------------------------------ */

.about-grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--space-lg);
  align-items: start;
}

.about-image-outer {
  position: relative;
  margin-top: 10rem;
  margin-left: -5rem;
}

.orb--about {
  top: 38%;
  left: 47%;
  transform: translate(-50%, -50%);
  width: 280px;
  height: 280px;
  filter: blur(72px);
  opacity: 0.45;
}

.about-image {
  aspect-ratio: 3 / 4;
  background-color: var(--border);
  overflow: hidden;
  border-radius: 50%;
  position: relative;
  z-index: 1;
  border: 4px solid white;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
}

.about-image img {
  width: 100%;
  height: 110%;
  object-fit: cover;
  object-position: 55% 50%;
  transform: translateY(-8%);
}

.about-content {
  padding-top: var(--space-sm);
}

.about-content h1 {
  margin-bottom: var(--space-md);
}

.about-content p {
  margin-bottom: var(--space-md);
}

/* CV download button */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--accent-ink);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-ink);
  background: transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
  text-decoration: none;
}

.btn:hover {
  background-color: var(--accent);
  color: #fff;
}

.btn--sm {
  padding: 0.5rem 1rem;
  font-size: 0.7rem;
}

/* ------------------------------------------------------------
   9. CONTACT PAGE
   ------------------------------------------------------------ */

.contact-wrap {
  max-width: 70ch;
}

.contact-wrap h1 {
  margin-bottom: var(--space-md);
}

.contact-wrap p {
  margin-bottom: var(--space-lg);
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.contact-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: var(--space-sm);
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

.contact-link:last-child {
  border-bottom: 1px solid var(--border);
}

.contact-link:hover {
  color: var(--fg);
}

.contact-link__arrow {
  font-size: 1rem;
  transition: transform 0.2s ease;
}

.contact-link:hover .contact-link__arrow {
  transform: translate(3px, -3px);
}

/* ------------------------------------------------------------
   10. FOOTER
   ------------------------------------------------------------ */

.footer {
  border-top: 1px solid var(--border);
  padding-block: var(--space-md);
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.footer__copy {
  font-size: 0.75rem;
  color: var(--fg-subtle);
}

.footer__monogram {
  height: 5.2rem;
  width: auto;
  opacity: 0.35;
}

.footer__links {
  display: flex;
  gap: var(--space-md);
}

.footer__link {
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  transition: color 0.2s ease;
}

.footer__link:hover {
  color: var(--accent-ink);
  text-decoration: underline;
}

/* ------------------------------------------------------------
   11. ORB DECORATIVE ELEMENT
   ------------------------------------------------------------ */

.orb {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(
    circle at 35% 35%,
    var(--orb-a) 0%,
    var(--orb-b) 40%,
    var(--orb-c) 75%,
    transparent 100%
  );
  filter: blur(48px);
  pointer-events: none;
  z-index: 0;
}

/* Sizes */
.orb--lg  { width: 520px; height: 520px; }
.orb--md  { width: 320px; height: 320px; }
.orb--sm  { width: 180px; height: 180px; }

/* Positions — combine with size modifiers */
.orb--hero    { top: -120px; right: -80px; }
.orb--hero-left { top: -100px; left: -60px; opacity: 0.85; }
.orb--left    { top: 50%; left: -80px; transform: translateY(-50%); }
.orb--center  { top: 50%; left: 50%; transform: translate(-50%, -50%); }
.orb--portrait {
  top: -30px; left: -30px;
  width: 110%; height: 110%;
  filter: blur(32px);
  opacity: 0.85;
}

/* Ensure parent has position:relative and its children sit above the orb */
.orb-wrap {
  position: relative;
  overflow: hidden;
}
.orb-wrap > *:not(.orb) {
  position: relative;
  z-index: 1;
}

/* ------------------------------------------------------------
   12. CASE STUDY PAGES
   ------------------------------------------------------------ */

/* ---- Case study hero + intro: portrait image beside content ---- */

.case-opener {
  display: flex;
  flex-direction: row;
  min-height: 90vh;
  border-bottom: 1px solid var(--border);
}

.case-opener__image {
  width: 42%;
  flex-shrink: 0;
  overflow: hidden;
  background-color: var(--border);
}

.case-opener__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.case-opener__content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: var(--space-lg);
  gap: var(--space-lg);
}

.case-opener__top {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.case-opener__tags {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.case-opener__tag {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  border: 1px solid var(--border);
  padding: 0.3rem 0.75rem;
  white-space: nowrap;
}

.case-opener__title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 3.5vw, 3.5rem);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.05;
  color: var(--fg);
}

.case-opener__desc {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--fg-muted);
  max-width: none;
}

.case-opener__details {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.case-detail {
  border-top: 1px solid var(--border);
  padding-top: var(--space-sm);
}

.case-detail dt {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  margin-bottom: 0.3rem;
}

.case-detail dd {
  font-size: 0.9rem;
  color: var(--fg-muted);
}

/* Keep old case-meta/case-intro/case-hero for backward compat if needed */
.case-hero {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: var(--border);
}

.case-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.case-meta {
  display: flex;
  align-items: baseline;
  gap: var(--space-lg);
  padding-block: var(--space-md);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.case-meta__title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 400;
  letter-spacing: -0.015em;
  flex: 1;
  min-width: 200px;
}

.case-meta__tags {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.case-meta__tag {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  border: 1px solid var(--border);
  padding: 0.3rem 0.75rem;
  white-space: nowrap;
}

.case-intro {
  padding-block: var(--space-lg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: start;
  border-bottom: 1px solid var(--border);
}

.case-intro p {
  font-size: 1.1rem;
  line-height: 1.75;
  max-width: none;
}

.case-intro__details {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

/* Process sections */
.case-section {
  padding-block: var(--space-lg);
  border-bottom: 1px solid var(--border);
}

.case-section__label {
  margin-bottom: var(--space-md);
}

.case-section__label + .case-section__title {
  margin-top: 0;
}

.case-section__title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: var(--space-md);
}

.case-section__body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: start;
}

.case-section__body.reverse {
  direction: rtl;
}

.case-section__body.reverse > * {
  direction: ltr;
}

.case-section__text h3 {
  margin-bottom: var(--space-sm);
}

.case-section__text p {
  max-width: none;
}

.case-section__text p + p {
  margin-top: var(--space-sm);
}

.case-section__image {
  overflow: hidden;
  background-color: var(--border);
}

.case-section__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Full-width image */
.case-image-full {
  width: 100%;
  overflow: hidden;
  background-color: var(--border);
}

.case-image-full img {
  width: 100%;
  display: block;
  object-fit: cover;
}

/* Image grid (2 or 3 col) */
.case-image-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background-color: var(--border);
}

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

.case-image-grid__item {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background-color: var(--bg);
}

.case-image-grid__item.tall {
  aspect-ratio: 3 / 4;
}

.case-image-grid__item.wide {
  grid-column: span 2;
  aspect-ratio: 16 / 9;
}

.case-image-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.case-image-grid__item:hover img {
  transform: scale(1.03);
}

/* NeetNook — context photo row (same-height, natural widths, no crop) */
.nn-context-photos {
  display: flex;
  gap: 4px;
  margin-bottom: 2rem;
}
.nn-context-photos img {
  height: 100%;
  width: auto;
  display: block;
  flex-shrink: 0;
}

/* NeetNook — numbered finding cards */
.nn-findings {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.nn-finding {
  background: var(--bg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.nn-finding__dot {
  display: block;
  width: 16px;
  height: 2px;
  background: var(--fg-subtle);
}
.nn-finding__label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--fg);
  line-height: 1.3;
}
.nn-finding__desc {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.6;
  margin: 0;
}

@media (max-width: 700px) {
  .nn-findings {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* NeetNook — prototype grid (photos left, catalogue right) */
.nn-prototype-grid {
  display: flex;
  gap: 4px;
}
.nn-prototype-grid__left {
  display: flex;
  gap: 4px;
  flex: 1;
}
.nn-prototype-grid__left img {
  flex: 1;
  min-width: 0;
  height: 100%;
  width: 100%;
  object-fit: cover;
  display: block;
}
.nn-prototype-grid__right {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.nn-prototype-grid__right img {
  width: 100%;
  height: auto;
  display: block;
}

/* NeetNook — inline highlight */
.nn-highlight {
  background: #f0e8c8;
  color: inherit;
  padding: 0.05em 0.2em;
  border-radius: 3px;
}

/* NeetNook — subsection label with padding */
.nn-subsection-label {
  margin-top: var(--space-md);
  margin-bottom: var(--space-sm, 1rem);
}

/* NeetNook — keyword chip rows */
.nn-chips-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 2rem;
}
.nn-chip-row {
  display: flex;
  align-items: baseline;
  gap: 1rem;
}
.nn-chip {
  white-space: nowrap;
  flex-shrink: 0;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--fg);
  background: var(--border);
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
}
.nn-chip-desc {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.6;
  margin: 0;
}

/* Subsections within a case section */
.case-subsection {
  padding-top: var(--space-md);
  margin-top: var(--space-md);
}

.case-subsection:first-child {
  margin-top: 0;
  padding-top: var(--space-sm);
}

.case-subsection__label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: var(--space-sm);
}

/* Image placeholder — shown until real image is provided */
.img-placeholder {
  background-color: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.img-placeholder span {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}

/* White content area — everything after the hero/overview on case study pages */
.case-content {
  background-color: #fff;
}

.case-content p {
  max-width: none;
}

/* Process booklet button */
.booklet-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--accent-ink);
  color: var(--accent-ink);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.booklet-btn:hover {
  background-color: var(--accent);
  color: #fff;
}

/* Project nav (prev / next) */
.case-nav {
  display: flex;
  justify-content: space-between;
  padding-block: var(--space-lg);
  gap: var(--space-md);
}

.case-nav__link {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.case-nav__link.next {
  text-align: right;
}

.case-nav__link span:first-child {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}

.case-nav__link span:last-child {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: var(--fg);
  transition: color 0.2s ease;
}

.case-nav__link:hover span:last-child {
  color: var(--accent-ink);
  text-decoration: underline;
}

/* ------------------------------------------------------------
   12. RVCA INFO BLOCK (About the RVCA subsection)
   ------------------------------------------------------------ */

.rvca-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: start;
}

.rvca-eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 0.6rem;
}

.rvca-heading {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 2.4vw, 2.15rem);
  line-height: 1.15;
  margin-bottom: var(--space-sm);
  text-transform: none;
  letter-spacing: normal;
  color: var(--fg);
  font-weight: 400;
}

.rvca-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: var(--space-sm) 0;
}

.rvca-body p {
  font-size: 0.93rem;
  line-height: 1.7;
  color: var(--fg-muted);
  margin-bottom: 0.65rem;
}

/* 4-icon row */
.rvca-icons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin: var(--space-sm) 0;
}

.rvca-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.45rem;
}

.rvca-icon svg {
  width: 34px;
  height: 34px;
  color: #576650;
  flex-shrink: 0;
}

.rvca-icon-title {
  font-size: 0.63rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg);
}

.rvca-icon-desc {
  font-size: 0.73rem;
  color: var(--fg-muted);
  line-height: 1.4;
}

/* 3-stat row */
.rvca-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  padding-top: var(--space-sm);
}

.rvca-stat {
  text-align: center;
}

.rvca-stat-number {
  font-family: var(--font-serif);
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  line-height: 1;
  color: var(--fg);
}

.rvca-stat-label {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--fg);
  margin: 0.3rem 0 0.2rem;
}

.rvca-stat-desc {
  font-size: 0.75rem;
  color: var(--fg-muted);
  line-height: 1.4;
}

/* Map column */
.rvca-map img {
  width: 100%;
  height: auto;
  display: block;
}

/* ------------------------------------------------------------
   13. SITE CONTEXT PHOTO GRID
   ------------------------------------------------------------ */

.sc-grid {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-top: var(--space-sm);
}

.sc-photo {
  position: relative;
  overflow: hidden;
  background: var(--border);
}

.sc-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sc-caption {
  position: absolute;
  bottom: 0.6rem;
  left: 0.6rem;
  background: rgba(0, 0, 0, 0.48);
  color: #fff;
  font-size: 0.7rem;
  letter-spacing: 0.01em;
  padding: 0.22rem 0.6rem;
  border-radius: 99px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.sc-col-labels {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 0.35rem;
}

.sc-label {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-muted);
  padding: 0.25rem 0 0.1rem;
}

.sc-row-middle {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 0.35rem;
}

.sc-nodes {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

/* ------------------------------------------------------------
   14. PROBLEM DIAGRAM
   ------------------------------------------------------------ */

.prob-diagram {
  margin-top: var(--space-md);
  width: 100%;
}

.prob-top {
  display: flex;
  justify-content: center;
  position: relative;
  margin-bottom: 2rem;
}

.prob-top::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 8%;
  right: 8%;
  height: 1px;
  background: #586651;
  transform: translateY(-50%);
}

.prob-top__circle {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1.5px solid #586651;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: #586651;
  background: #fff;
  position: relative;
  z-index: 1;
  font-family: 'DM Serif Display', serif;
  letter-spacing: -0.02em;
}

.prob-columns {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.25rem;
  text-align: center;
}

.prob-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.prob-item::before {
  content: '';
  position: absolute;
  top: -2rem;
  left: 50%;
  width: 1px;
  height: 2rem;
  background: #586651;
}

.prob-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #eef0ec;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.9rem;
  color: #586651;
  flex-shrink: 0;
}

.prob-icon svg {
  width: 34px;
  height: 34px;
}

.prob-item-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #586651;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.prob-item-desc {
  font-size: 0.8rem;
  color: var(--fg-muted);
  line-height: 1.55;
  max-width: 150px;
  margin: 0 auto;
}

/* ------------------------------------------------------------
   OPP COLUMNS (Framing the Opportunity 3-column layout)
   ------------------------------------------------------------ */

.opp-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: var(--space-md);
}

.opp-col {}

.opp-col__photos {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 1.1rem;
}

.opp-col__photo {
  position: relative;
  overflow: hidden;
  background: var(--border);
}

.opp-col__photo--tall {
  height: 180px;
}

.opp-col__photo--short {
  height: 110px;
}

.opp-col__photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.opp-col__label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #586651;
  margin-bottom: 0.55rem;
}

.opp-col__desc {
  font-size: 0.88rem;
  color: var(--fg-muted);
  line-height: 1.6;
  max-width: none;
}

@media (max-width: 768px) {
  .opp-columns {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* ------------------------------------------------------------
   DRIVERS GRID (Critical Design Drivers 5×2 icon grid)
   ------------------------------------------------------------ */

.drivers-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.75rem 1rem;
  margin-top: var(--space-sm);
}

.driver-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.65rem;
}

.driver-icon {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background: #eef0ec;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #586651;
  flex-shrink: 0;
}

.driver-icon svg {
  width: 32px;
  height: 32px;
}

.driver-label {
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--fg);
}

.drivers-divider {
  grid-column: 1 / -1;
  height: 1px;
  background: var(--border);
  margin: 0.25rem 0;
}

/* ------------------------------------------------------------
   15. RESPONSIVE
   ------------------------------------------------------------ */

@media (max-width: 768px) {
  :root {
    --space-xl: 4rem;
    --space-lg: 2.5rem;
  }

  /* Nav mobile */
  .nav__links {
    display: none;
    position: fixed;
    inset: var(--nav-h) 0 0 0;
    background-color: var(--bg);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-lg);
  }

  .nav__links.is-open {
    display: flex;
  }

  .nav__link {
    font-size: 1rem;
  }

  .nav__toggle {
    display: block;
  }

  /* Layouts */
  .project-grid {
    grid-template-columns: 1fr;
  }

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

  /* Case study opener */
  .case-opener {
    flex-direction: column;
    min-height: unset;
  }

  .case-opener__image {
    width: 100%;
    height: 60vw;
    max-height: 420px;
  }

  .case-opener__content {
    padding: var(--space-md);
  }

  /* Legacy */
  .case-hero {
    aspect-ratio: 4 / 3;
  }

  .case-intro {
    grid-template-columns: 1fr;
  }

  .case-section__body,
  .case-section__body.reverse {
    grid-template-columns: 1fr;
    direction: ltr;
  }

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

  .rvca-layout {
    grid-template-columns: 1fr;
  }

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

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

  .drivers-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .drivers-divider {
    display: none;
  }

  .prob-top::before {
    display: none;
  }

  .prob-item::before {
    display: none;
  }

  .prob-top {
    display: none;
  }

  .case-image-grid__item.wide {
    grid-column: span 2;
  }

  .case-nav {
    flex-direction: column;
  }

  .case-nav__link.next {
    text-align: left;
  }

  .case-meta {
    flex-direction: column;
    gap: var(--space-sm);
  }

  .about-image {
    aspect-ratio: 1 / 1;
  }

  .footer__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .container {
    padding-inline: var(--space-sm);
  }
}


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

/* ---- Mobile: image lists become one column at natural aspect ratio ---- */
@media (max-width: 640px) {
  /* Any inline multi-column grid (galleries, photo pairs, icon rows) -> single column */
  .page-wrap [style*="grid-template-columns"] { grid-template-columns: 1fr !important; }

  /* Art page: the two side-by-side creative-work carousels stack */
  .creative-cols { flex-direction: column !important; }

  /* Sitting with Nature: justified photo strips stack to one full-width
     column (natural aspect ratio) instead of clipping at the right edge */
  #swn-fullscale-row, #swn-sensory-row, #swn-ie-row, #swn-feedback-row {
    flex-direction: column !important;
    overflow: visible !important;
    height: auto !important;
  }
  #swn-fullscale-row > div, #swn-sensory-row > div,
  #swn-ie-row > div, #swn-feedback-row > div {
    width: 100% !important;
    height: auto !important;
    flex-shrink: 1 !important;
  }
  #swn-fullscale-row img, #swn-sensory-row img,
  #swn-ie-row img, #swn-feedback-row img {
    width: 100% !important;
    height: auto !important;
  }
}

/* ---- Art "Creative Work" carousels: fit images within the frame on phones ---- */
@media (max-width: 640px) {
  #tennis-carousel img,
  #earrings-carousel img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
  }
}

/* ---- About headshot: drop the left overhang once the window is too narrow
       for the side gutter, so the oval never gets clipped on the left ---- */
@media (max-width: 1260px) {
  .about-image-outer { margin-left: 0; }
}
@media (max-width: 768px) {
  .about-image-outer { margin-top: 0; margin-left: 0; }
}

/* ---- Disclosure ("About this work" / "View process") buttons (Art page) ---- */
.disclosure-btn {
  background: none; border: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 0.55rem;
  font-family: var(--font-sans); font-size: 0.75rem; font-weight: 400;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--fg-muted); padding: 0; margin-bottom: 0.75rem;
  transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.disclosure-btn:hover { color: var(--accent-ink); background: var(--accent-tint); box-shadow: 0 0 0 0.3rem var(--accent-tint); border-radius: 4px; }
.disclosure-btn__icon {
  position: relative;
  display: inline-block;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}
/* +/- drawn as two centered bars (geometric, font-independent) */
.disclosure-btn__icon::before,
.disclosure-btn__icon::after {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  background: #fff;
  transform: translate(-50%, -50%);
}
.disclosure-btn__icon::before { width: 50%; height: 1.5px; }
.disclosure-btn__icon::after  { width: 1.5px; height: 50%; transition: transform 0.2s ease; }
.disclosure-btn[aria-expanded="true"] .disclosure-btn__icon::after { transform: translate(-50%, -50%) scaleY(0); }
.disclosure-btn:hover .disclosure-btn__icon { background: var(--accent-strong); }

.project-card:hover .project-card__title {
  color: var(--accent-ink);
  text-decoration: underline;
}

/* Contact form */
.contact-form { max-width: 34rem; display: flex; flex-direction: column; gap: var(--space-md); }
.contact-form__field { display: flex; flex-direction: column; gap: 0.4rem; }
.contact-form__field label {
  font-size: 0.72rem; font-weight: 500; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--fg-subtle);
}
.contact-form input, .contact-form textarea {
  font-family: var(--font-sans); font-size: 0.95rem; color: var(--fg);
  background: transparent; border: 1px solid var(--border); border-radius: 4px;
  padding: 0.6rem 0.75rem; width: 100%; box-sizing: border-box;
  transition: border-color 0.2s ease;
}
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: var(--accent-ink); }
.contact-form textarea { resize: vertical; }
.contact-form__submit { align-self: flex-start; margin-top: 0.25rem; }

/* LinkedIn link on the contact page */
.contact-elsewhere { margin: var(--space-sm) 0 var(--space-lg); font-size: 0.95rem; }
.contact-elsewhere a { display: inline-flex; align-items: center; gap: 0.45rem; color: var(--fg); text-decoration: none; font-weight: 500; transition: color 0.2s ease; }
.contact-elsewhere a:hover { color: var(--accent-ink); text-decoration: underline; }
.contact-elsewhere__icon { width: 18px; height: 18px; flex-shrink: 0; fill: var(--accent); }

/* Primary (filled) action button — e.g. form submit */
.btn-primary {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1.1rem; border-radius: 999px;
  border: 1px solid var(--accent); background: var(--accent); color: #fff;
  font-family: var(--font-sans); font-size: 0.8rem; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.btn-primary:hover { background-color: var(--accent-strong); border-color: var(--accent-strong); }

#autoplay-toggle:hover { color: var(--accent-ink); border-color: var(--accent-ink); background: var(--accent-tint); }
