/* ========================================
   CSS CUSTOM PROPERTIES & RESET
   ======================================== */

html {
  scroll-behavior: smooth;
}

:root {
  /* Colors */
  --text-color: #111111;
  --bg-color: #f5f5f5;
  --border-color: #dbdbdb;
  --border-light: #eeeeee;
  --link-color: #454545;
  --hover-color: #000000;
  --gray-light: #e1e1e1;
  --gray-med: #383838;
  --accent: #980000;

  /* Typography */
  --sans-font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --serif-font: 'Playfair Display', Georgia, serif;

  /* Layout */
  --container-width: 1440px;
  --header-height: 56px;

  /* Spacing - Number matches pixel value (reasonable sizes) */
  --sp-2: 2px;
  --sp-3: 3px;
  --sp-4: 4px;
  --sp-8: 8px;
  --sp-12: 12px;
  --sp-16: 16px;
  --sp-20: 20px;
  --sp-24: 24px;
  --sp-32: 32px;
  --sp-40: 40px;
  --sp-48: 48px;

  /* Typography Scale - Number matches pixel value */
  --txt-10: 10px;
  --txt-11: 11px;
  --txt-12: 12px;
  --txt-13: 13px;
  --txt-14: 14px;
  --txt-15: 15px;
  --txt-16: 16px;
  --txt-18: 18px;
  --txt-20: 20px;
  --txt-24: 24px;
  --txt-28: 28px;
  --txt-32: 32px;
  --txt-40: 40px;
  --txt-48: 48px;
  --txt-60: 60px;
  --txt-72: 72px;
}

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

html, body {
  overflow-x: hidden;
  max-width: 100%;
}

body {
  font-family: var(--sans-font);
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  font-size: var(--txt-16);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   MAGAZINE-STYLE TYPOGRAPHY SYSTEM
   ======================================== */


/* Flexbox utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }

/* Spacing utilities */
.gap-xs { gap: var(--sp-8); }
.gap-sm { gap: var(--sp-12); }
.gap-md { gap: var(--sp-16); }
.gap-lg { gap: var(--sp-24); }
.gap-xl { gap: var(--sp-32); }

.flex-1 { flex: 1; }

.p-xs { padding: var(--sp-8); }
.p-sm { padding: var(--sp-12); }
.p-md { padding: var(--sp-16); }
.p-lg { padding: var(--sp-24); }
.p-xl { padding: var(--sp-32); }

.mb-xs { margin-bottom: var(--sp-8); }
.mb-sm { margin-bottom: var(--sp-12); }
.mb-md { margin-bottom: var(--sp-16); }
.mb-lg { margin-bottom: var(--sp-32); }
.mb-xl { margin-bottom: var(--sp-32); }

/* Text utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

/* Typography utilities - Magazine Style */

.font-serif { font-family: var(--serif-font); }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.text-accent { color: var(--accent); }
.text-gray { color: var(--gray-med); }
.text-link { color: var(--link-color); }

.uppercase { text-transform: uppercase; }
.italic { font-style: italic; }
.tracking-wide { letter-spacing: 0.08em; }

/* Layout utilities */
.w-full { width: 100%; }
.h-full { height: 100%; }
.relative { position: relative; }
.absolute { position: absolute; }
.overflow-hidden { overflow: hidden; }

/* Visual utilities - Minimal newspaper style */
.border { border: 1px solid var(--border-light); }
.border-b { border-bottom: 1px solid var(--border-light); }
.border-t { border-top: 1px solid var(--border-light); }
.border-accent { border-color: var(--accent); }

/* Transition utilities */
.transition { transition: all 0.3s ease; }
.transition-transform { transition: transform 0.3s ease; }

/* ========================================
   LAYOUT COMPONENTS
   ======================================== */

.page-container {
  width: 100%;
  padding: 0 10%;
}

/* ========================================
   HEADER & NAVIGATION
   ======================================== */

.page-header {
  padding: var(--sp-24) 0;
  border-bottom: 1px solid var(--border-light);
  position: relative;
  margin-bottom: var(--sp-40);
}

.page-header::before {
  content: '';
  position: absolute;
  bottom: 6px;
  left: 0;
  width: 100%;
  height: 1px;
  background-color: var(--accent);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.date-info {
  font-family: var(--serif-font);
  font-style: italic;
  font-size: var(--txt-14);
}

.masthead-nav,
.social-icons {
  display: flex;
  align-items: center;
  gap: var(--sp-32);
}

.social-icons {
  margin-left: var(--sp-32);
  padding-left: var(--sp-32);
  border-left: 1px solid var(--border-color);
}

.social-icons a {
  text-decoration: none;
  color: var(--text-color);
  font-size: var(--txt-14);
  transition: color 0.2s ease;
}

.social-icons a:hover {
  color: var(--accent);
}

.social-text-link {
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 400;
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.social-text-link:hover {
  color: var(--accent);
}

/* ========================================
   TITLE BANNER
   ======================================== */

/* Improved Page Title */
.page-title {
  text-align: center;
  margin-bottom: var(--sp-24);
}

.page-title h1 {
  margin-bottom: var(--sp-24);
  font-weight: 600;; /* Increased spacing */
}

.page-title .subtitle1 {
  color: var(--accent);
  font-style: italic;
  font-weight: 500;
}


/* ========================================
   ISSUE DETAILS
   ======================================== */

.page-info {
  display: flex;
  justify-content: space-between;
  border-bottom: var(--sp-3) double var(--border-color);
  border-top: 1px solid var(--border-color);
  padding: var(--sp-24) 0;
  margin-bottom: var(--sp-8);
  font-size: var(--txt-12);
  color: var(--gray-med);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ========================================
   MAIN CONTENT LAYOUT (FLEXBOX)
   ======================================== */

.main-layout {
  display: grid;
  grid-column-gap: var(--sp-48); /* Reduced from 48px for better balance */
  grid-template-columns: repeat(20, 1fr); /* 20 column grid system */
  margin-bottom: var(--sp-48);
  margin-top: var(--sp-48); /* Reduced from 48px */
  align-items: start; /* Align content areas to top */
}

.content-area {
  grid-column: span 14; /* Left content takes 14 of 20 columns (70%) */
  max-width: none; /* Remove width constraint for natural flow */
  font-family: var(--sans-font); /* Use sans-serif for body text */
  line-height: 1.6; /* Improved readability */
  color: var(--text-color);
}



/* Featured Work Layout */

/* Workshop Featured Items - Magazine Style */
.workshop-featured.thought-item {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.workshop-featured.thought-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

/* Project Content Styling */
.project-info {
  padding: 0;
}



/* Projects Additional Content - Unified Section */
.projects-additional {
  margin-top: var(--sp-24);
  display: flex;
  flex-direction: column;
  gap: var(--sp-24);
}

/* Featured Horizontal Layout */
.featured-horizontal {
  display: flex;
  gap: var(--sp-32);
  align-items: flex-start;
  margin-bottom: 0; /* No margin - handled by parent */
}

.featured-horizontal .project-info {
  flex: 1;
}

.featured-horizontal .card-image {
  flex: 1;
}

/* Small Projects Grid */
.projects-grid-small {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-16); /* Match projects-grid gap */
  margin-bottom: var(--sp-32); /* Match projects-grid margin */
}

.project-small {
  display: flex;
  flex-direction: column;
  gap: var(--sp-12);
}


.project-small .project-details {
  font-family: var(--sans-font);
  font-size: var(--txt-10);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray-med);
  margin-bottom: var(--sp-8);
}

.sidebar-area {
  min-width: 0;
  position: relative;
  grid-column: span 6; /* Right sidebar takes 6 of 20 columns (30%) */
  font-family: var(--sans-font);
  display: flex;
  flex-direction: column;
  gap: var(--sp-32);
}

/* Typography Scale - Material Design Style */
.h1 {
  font-family: var(--serif-font);
  font-size: var(--txt-72);
  font-weight: 300;
  line-height: 0.8;
  letter-spacing: -0.02em;
  margin-bottom: var(--sp-16);
}

.h1 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.h1 a:hover {
  color: var(--accent);
}

.h2 {
  font-family: var(--serif-font);
  font-size: var(--txt-32);
  font-weight: 500;
  line-height: 0.9;
  letter-spacing: -0.01em;
  margin-bottom: var(--sp-32);
}

.h2 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.h2 a:hover {
  color: var(--accent);
}

.h3 {
  font-family: var(--serif-font);
  font-size: var(--txt-32);
  font-weight: 400;
  line-height: 1.0;
  letter-spacing: 0;
  margin-bottom: var(--sp-12);
}

.h3 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.h3 a:hover {
  color: var(--accent);
}

.h4 {
  font-family: var(--serif-font);
  font-size: var(--txt-24);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: 0.01em;
  margin-bottom: var(--sp-12);
}

.h4 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.h4 a:hover {
  color: var(--accent);
}

.h5 {
  font-family: var(--serif-font);
  font-size: var(--txt-20);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0;
  margin-bottom: var(--sp-8);
}

.h5 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.h5 a:hover {
  color: var(--accent);
}

.h6 {
  font-family: var(--serif-font);
  font-size: var(--txt-18);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.01em;
  margin-bottom: var(--sp-8);
}

.h6 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.h6 a:hover {
  color: var(--accent);
}

.subtitle1 {
  font-family: var(--sans-font);
  font-size: var(--txt-16);
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0.01em;
  margin-bottom: var(--sp-8);
}

.subtitle2 {
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.01em;
  margin-bottom: var(--sp-8);
}

.body1 {
  font-family: var(--sans-font);
  font-size: var(--txt-16);
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: 0.03em;
  margin-bottom: var(--sp-16);
  color: var(--gray-med); /* Gray color for all body text */
}

.body1 a {
  color: var(--gray-med);
  text-decoration: underline;
  transition: color 0.2s ease;
}

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

.body2 {
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0.01em;
  margin-bottom: var(--sp-8);
  color: var(--gray-med); /* Gray color for secondary body text */
}

.button {
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--sp-8);
}

.caption {
  font-family: var(--sans-font);
  font-size: var(--txt-12);
  font-weight: 400;
  line-height: 1.4;
  letter-spacing: 0.02em;
  margin-bottom: var(--sp-8);
}

.overline {
  font-family: var(--sans-font);
  font-size: var(--txt-10);
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: var(--sp-8);
}

.project-details,
.featured-meta,
.text-xs,
.workshop-meta,
.workshop-featured .text-xs {
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray-med);
  margin-bottom: var(--sp-16);
}

.project-text,
.featured-description,
.about-content p,
.thought-item p,
.workshop-featured p {
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 400;
  line-height: 1.6;
  color: var(--gray-med); /* Gray color for workshop descriptions */
  margin-bottom: var(--sp-16);
}

/* Rive Carousel Animation */
.carousel {
  position: relative;
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
  overflow: hidden;
  border-radius: var(--radius-md);
}

.carousel-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

.carousel-img.active {
  opacity: 1;
}

/* Balanced Section Spacing */
.section {
  margin-bottom: var(--sp-48);
  padding-bottom: 0;
  border-bottom: none;
}

.section:last-child {
  margin-bottom: 0;
}

.sidebar {
  margin-bottom: 0;
  border-bottom: none;
  padding-bottom: var(--sp-24);
}



/* Featured Content Spacing */
.featured-content {
  margin-top: var(--sp-16); /* Reduced from 24px */
}

.featured-single {
  display: flex;
  flex-direction: column;
  gap: var(--sp-16);
}

/* Projects Content Spacing */
.projects-content {
  margin-top: var(--sp-16); /* Reduced from 24px */
  display: flex;
  flex-direction: column;
}

.projects-content > .card:not(:last-child) {
  margin-bottom: var(--sp-24);
}

.projects-content > .featured-horizontal {
  margin-top: var(--sp-24);
}

.projects-content > .projects-grid-small {
  margin-top: var(--sp-24);
}

.projects-grid {
  display: flex;
  gap: var(--sp-16); /* Match gap-md utility class */
  margin-bottom: var(--sp-32); /* Match mb-lg utility class */
}

/* About Content Spacing */
.about-content {
  margin-top: var(--sp-16); /* Reduced from 24px */
}

.about-text {
  margin-bottom: var(--sp-24);
}

/* Workshops Content Spacing */
.workshop-content {
  margin-top: var(--sp-16); /* Reduced from 24px */
  display: flex;
  flex-direction: column;
  gap: var(--sp-24);
}

.workshop-list {
  margin-top: var(--sp-24);
}

/* ========================================
   CARD COMPONENTS - NEWSPAPER STYLE
   ======================================== */

/* Base card styles - minimal newspaper approach */
.card {
  border-bottom: 1px solid var(--border-light);
  padding-bottom: var(--sp-48);
  margin-bottom: var(--sp-48);
  transition: none;
}

.card:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.card-image {
  width: 100%;
  aspect-ratio: 16/9; /* Standard video aspect ratio */
  overflow: hidden;
  position: relative;
  border: 1px solid var(--border-light);
  margin-bottom: var(--sp-12);
}

.card-image.large {
  aspect-ratio: 16/9; /* Same 16:9 ratio for all cards */
}

.card-image video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s ease;
  will-change: transform;
  /* Performance optimizations for videos */
  transform: translateZ(0); /* Force hardware acceleration */
  backface-visibility: hidden; /* Reduce repaints */
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s ease;
  will-change: transform;
  /* Performance optimizations for images */
  transform: translateZ(0); /* Force hardware acceleration */
  backface-visibility: hidden; /* Reduce repaints */
}

.card-image:hover video,
.card-image:hover img {
  transform: scale(1.02) translateZ(0); /* Reduced scale for better performance */
}




/* ========================================
   FEATURED PROJECTS SECTION
   ======================================== */


.featured-project-card {
  flex: 1;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: var(--sp-48);
}

/* ========================================
   DESIGN EXPERIMENTS SECTION
   ======================================== */

.experiments-filter {
  display: flex;
  gap: var(--sp-32);
  margin-bottom: var(--sp-48);
  flex-wrap: wrap;
}

.filter-btn {
  padding: var(--sp-48) var(--sp-32);
  background: transparent;
  border: 1px solid var(--border-color);
  font-family: var(--sans-font);
  font-size: var(--txt-14);
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.experiments-grid {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-48);
}

.experiment-card {
  flex: 1 1 280px;
  min-width: 280px;
}

/* ========================================
   THREE.JS EXPERIMENTS SECTION
   ======================================== */

.threejs-grid {
  display: flex;
  gap: var(--sp-32);
}

.threejs-card {
  flex: 1;
  background: #000;
  border: 1px solid var(--border-color);
  overflow: hidden;
  position: relative;
  aspect-ratio: 16/9;
}

.threejs-preview {
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, #1a1a1a, #333);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-family: var(--serif-font);
  font-size: var(--txt-18);
  font-weight: 500;
  line-height: 1.4;
}

.threejs-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
  color: white;
  padding: var(--sp-32);
}

.threejs-title {
  font-family: var(--serif-font);
  font-size: var(--txt-16);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin-bottom: var(--sp-8);
}

.threejs-tech {
  font-family: var(--sans-font);
  font-size: var(--txt-12);
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.8;
}

/* ========================================
   WORKSHOPS SECTION
   ======================================== */

.workshop-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-48);
}

.workshop-item {
  display: flex;
  align-items: center;
  gap: var(--sp-48);
  padding: var(--sp-48) 0;
  border-bottom: 1px solid var(--border-light);
  border-left: var(--sp-2) solid var(--accent);
  padding-left: var(--sp-48);
}

.workshop-date {
  min-width: 80px;
  font-family: var(--serif-font);
  font-weight: 700;
  color: var(--accent);
  text-align: center;
}

.workshop-info {
  flex: 1;
}

.workshop-title {
  font-size: var(--txt-16);
  font-weight: 600;
  margin-bottom: var(--sp-48);
}

.workshop-venue {
  font-size: var(--txt-14);
  color: var(--gray-med);
}

.workshop-status {
  padding: var(--sp-48) var(--sp-48);
  background: var(--accent);
  color: white;
  font-size: var(--txt-12);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid var(--accent);
}

/* ========================================
   PROJECT CTA SECTION
   ======================================== */

.project-cta {
  background: transparent;
  border: var(--sp-2) solid var(--accent);
  color: var(--text-color);
  text-align: center;
  padding: var(--sp-48);
  margin: var(--sp-48) 0;
}

.cta-title {
  font-family: var(--serif-font);
  font-size: var(--txt-24);
  font-weight: 700;
  margin-bottom: var(--sp-48);
  color: var(--accent);
}

.cta-description {
  font-size: var(--txt-18);
  margin-bottom: var(--sp-48);
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-48);
  padding: var(--sp-32) var(--sp-48);
  background: var(--accent);
  color: white;
  text-decoration: none;
  border: var(--sp-2) solid var(--accent);
  font-weight: 600;
  transition: all 0.3s ease;
}

.cta-button:hover {
  background: transparent;
  color: var(--accent);
}

/* ========================================
   SIDEBAR COMPONENTS
   ======================================== */

.about-image {
  margin-bottom: var(--sp-48);
  border: 1px solid var(--border-light);
  padding: var(--sp-2);
  background-color: white;
}

.about-image img {
  width: 100%;
  height: auto;
  display: block;
}

.about-content p {
  margin-bottom: var(--sp-48);
  font-size: var(--txt-16);
  line-height: 1.6;
}

.about-content p:first-of-type::first-letter {
  font-family: var(--serif-font);
  font-size: var(--txt-48);
  float: left;
  line-height: 0.9;
  margin-right: var(--sp-12);
  margin-top: var(--sp-4);
  color: var(--accent);
}

.thought-title {
  font-size: var(--txt-16);
  font-weight: 600;
  margin-bottom: var(--sp-48);
  line-height: 1.3;
}

.thought-title a,
.text-base.font-semibold a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.thought-title a:hover,
.text-base.font-semibold a:hover {
  color: var(--accent);
}

.thought-meta {
  font-size: var(--txt-12);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-med);
  margin-bottom: var(--sp-48);
}

.thought-excerpt {
  font-size: var(--txt-14);
  line-height: 1.6;
  color: var(--gray-med);
}

/* ========================================
   FOOTER
   ======================================== */

.colophon {
  border-top: 1px solid var(--border-color);
  padding: var(--sp-32) 0;
  margin-top: var(--sp-48);
}

.colophon-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: var(--txt-12);
  color: var(--gray-med);
  letter-spacing: 0.05em;
}

.colophon-links {
  display: flex;
  gap: var(--sp-32);
}

.colophon-links a {
  color: var(--gray-med);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: var(--txt-12);
  transition: color 0.2s;
}

.colophon-links a:hover {
  color: var(--accent);
  text-decoration: underline;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 992px) {
  .main-content {
    display: flex;
    flex-direction: column;
    gap: var(--sp-48);
  }

  .content-area {
    grid-column: unset;
    width: 100%;
  }

  .right-sidebar {
    grid-column: unset;
    width: 100%;
  }

  .featured-horizontal {
    flex-direction: column;
    gap: var(--sp-32);
  }

  .projects-grid-small {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--sp-16); /* Match consistent gap */
  }

  .about-content {
    flex-direction: column-reverse;
    gap: var(--sp-32);
    text-align: flex-start;
  }

  .section-title {
    margin-bottom: var(--sp-48);
  }

  .threejs-grid {
    flex-direction: column;
  }

  .experiments-grid {
    justify-content: center;
  }

  .experiment-card {
    flex: 1 1 250px;
    min-width: 250px;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 var(--sp-32);
  }

  .header-content {
    flex-direction: column;
    gap: var(--sp-32);
  }

  .page-title {
    padding: var(--sp-24) 0 var(--sp-24);
  }

  .page-title h1 {
    font-size: clamp(var(--txt-32), 6vw, var(--txt-40));
  }

  .subtitle {
    font-size: var(--txt-15);
  }

  .section,
  .sidebar {
    padding-bottom: var(--sp-48);
  }

  .sidebar {
    margin-bottom: var(--sp-32);
  }

  .projects-grid-small {
    grid-template-columns: 1fr;
    gap: var(--sp-16); /* Match consistent gap */
  }

  .card-image {
    aspect-ratio: 16/9;
  }

  .about-image {
    width: 200px;
    height: 200px;
  }

  .carousel {
    aspect-ratio: 16/9;
  }

  .experiments-filter {
    justify-content: center;
  }

  .workshop-item {
    flex-direction: column;
    text-align: center;
    padding-left: 0;
    border-left: none;
    border-top: var(--sp-2) solid var(--accent);
    padding-top: var(--sp-32);
  }

  .workshop-date {
    min-width: auto;
  }

  .colophon-content {
    flex-direction: column;
    gap: var(--sp-48);
    text-align: center;
  }

  .colophon-links {
    margin-top: var(--sp-48);
  }
}

@media (max-width: 576px) {
  .container {
    padding: 0 var(--sp-48);
  }

  .page-title h1 {
    font-size: clamp(var(--txt-28), 5vw, var(--txt-32));
  }

  .subtitle {
    font-size: var(--txt-13);
  }

  .experiments-filter {
    flex-direction: column;
    align-items: stretch;
  }

  .filter-btn {
    width: 100%;
    text-align: center;
  }

  .workshop-item {
    padding: var(--sp-32) 0;
  }

  .project-cta {
    padding: var(--sp-48) var(--sp-32);
  }

  .cta-title {
    font-size: var(--txt-18);
  }

  .about-image {
    width: 150px;
    height: 150px;
  }

/* Responsive Media Containers - Consistent Heights */
@media (max-width: 768px) {
  .card-image,
  .workshop-image,
  .carousel {
    aspect-ratio: 16/9; /* Maintain consistent aspect ratio on mobile */
  }
  
  .about-image {
    width: 200px;
    height: 200px;
    align-self: center;
  }
}

@media (max-width: 480px) {
  .card-image,
  .workshop-image,
  .carousel {
    aspect-ratio: 16/9; /* Maintain consistent aspect ratio on small mobile */
  }
  
  .about-image {
    width: 150px;
    height: 150px;
  }
}

  .cta-description {
    font-size: var(--txt-16);
  }

  .experiment-card {
    flex: 1 1 100%;
    min-width: 100%;
  }
}

/* ========================================
   UTILITY CLASSES
   ======================================== */

/* ========================================
   LARGE SCREEN LAYOUT (Publication Style)
   ======================================== */

@media (min-width: 1440px) {
  .container {
    margin: auto;
    padding: 0 3%;
    max-width: 1440px;
  }
  
  .main-content {
    grid-column-gap: var(--sp-48); /* Larger gap on desktop */
  }
  
  .content-area {
    grid-column: span 14; /* Left content takes 14 of 20 columns on desktop (70%) */
  }
  
  .right-sidebar {
    grid-column: span 6; /* Right sidebar takes 6 of 20 columns on desktop (30%) */
  }
}

/* About Me Section */
.about-content {
  display: flex;
  flex-direction: row-reverse;
  gap: var(--sp-48);
  align-items: flex-start;
}

.about-image {
  flex: 0 0 300px;
}

.about-image img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.about-text {
  flex: 1;
}

.about-text p {
  font-family: var(--sans-font);
  font-size: var(--txt-16);
  line-height: 1.7;
  color: var(--text-color);
  margin-bottom: var(--sp-32);
}

.about-text p:last-child {
  margin-bottom: 0;
}

/* Workshop Featured Styling */
.workshop-image {
  margin-bottom: var(--sp-12);
  aspect-ratio: 16/9; /* Consistent aspect ratio */
  overflow: hidden;
  border-radius: var(--sp-8);
}

.workshop-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensure proper fitting */
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
}


.workshop-featured h3 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

/* Play Ambassador Styling */
.ambassador-content {
  margin-top: var(--sp-16);
  display: flex;
  flex-direction: column;
  gap: var(--sp-24);
}

.ambassador-featured {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.ambassador-image {
  margin-bottom: var(--sp-12);
  aspect-ratio: 1/1; /* Consistent aspect ratio */
  overflow: hidden;
  border-radius: var(--sp-8);
}

.ambassador-image img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Fit the entire image within container */
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
}

.ambassador-featured h3 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.ambassador-featured h3 a:hover {
  color: var(--accent);
}

.workshop-featured .text-xs {
  color: var(--gray-600);
  font-weight: 500;
}

/* Rive Projects Styling */
.rive-content {
  margin-top: var(--sp-16);
  display: flex;
  flex-direction: column;
  gap: var(--sp-24);
}

.rive-featured {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.rive-image {
  margin-bottom: var(--sp-12);
  aspect-ratio: 16/9; /* Consistent aspect ratio */
  overflow: hidden;
  border-radius: var(--sp-8);
}

.rive-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensure proper fitting */
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
}

.rive-image video {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensure proper fitting */
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
}

.rive-featured h3 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.rive-featured h3 a:hover {
  color: var(--accent);
}

/* Freebies Styling */
.freebies-content {
  margin-top: var(--sp-16);
  display: flex;
  flex-direction: column;
  gap: var(--sp-24);
}

.freebie-featured {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: none;
}

.freebie-image {
  margin-bottom: var(--sp-12);
  aspect-ratio: 16/9; /* Consistent aspect ratio */
  overflow: hidden;
  border-radius: var(--sp-8);
}

.freebie-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensure proper fitting */
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
}

.freebie-featured h3 a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.freebie-featured h3 a:hover {
  color: var(--accent);
}


/* Forced Colors Mode Support (Accessibility) */
@media (forced-colors: none) {
  .content-area *,
  .right-sidebar * {
    outline: 1px solid var(--border-light);
    outline-offset: var(--sp-2);
    outline-color: transparent;
  }
}

/* Clean Responsive Design */
@media (max-width: 1024px) {
  .main-layout {
    grid-template-columns: 1fr;
    grid-column-gap: 0;
    gap: var(--sp-32);
    margin-top: var(--sp-32);
    margin-bottom: var(--sp-32);
  }
  
  .content-area,
  .sidebar-area {
    grid-column: span 20;
  }
  
  .content-area {
    order: -1; /* Move main content (featured work) above sidebar */
  }
  
  .sidebar-area {
    order: 1; /* Move sidebar below main content */
  }
  
  .page-title h1 {
    font-size: var(--txt-48);
  }
  
  .h2 {
    font-size: var(--txt-28);
    margin-bottom: var(--sp-24);
  }
}

@media (max-width: 768px) {
  .page-container {
    padding: 0 var(--sp-16);
  }
  
  .page-header {
    padding: var(--sp-16) 0;
    margin-bottom: var(--sp-24);
  }
  
  .header-content {
    flex-direction: column;
    gap: var(--sp-12);
    align-items: flex-start;
  }
  
  .date-info {
    order: 1;
  }
  
  .masthead-nav {
    order: 2;
    align-self: flex-end;
  }
  
  .page-title {
    padding: var(--sp-32) 0 var(--sp-20);
  }
  
  .page-title h1 {
    font-size: var(--txt-40); /* Larger mobile title */
    margin-bottom: var(--sp-20);
    line-height: 1.1;
  }
  
  .h2 {
    font-size: var(--txt-28); /* Larger section titles */
    margin-bottom: var(--sp-20);
    line-height: 1.2;
  }
  
  .h3 {
    font-size: var(--txt-24); /* Better h3 size */
    margin-bottom: var(--sp-16);
  }
  
  .h4 {
    font-size: var(--txt-20); /* Better h4 size */
    margin-bottom: var(--sp-12);
  }
  
  .h5 {
    font-size: var(--txt-18); /* Better h5 size */
    margin-bottom: var(--sp-12);
  }
  
  .body1 {
    font-size: var(--txt-16); /* Keep readable body text */
    line-height: 1.6;
    color: var(--gray-600);
    margin-bottom: var(--sp-16);
  }
  
  .body2 {
    font-size: var(--txt-14); /* Keep readable secondary text */
    line-height: 1.5;
    margin-bottom: var(--sp-12);
  }
  
  .subtitle1 {
    font-size: var(--txt-16); /* Keep readable subtitle */
  }
  
  .overline {
    font-size: var(--txt-11); /* Keep readable overline */
  }
  
  .main-layout {
    margin-top: var(--sp-24);
    margin-bottom: var(--sp-24);
    gap: var(--sp-24);
  }
  
  .section {
    margin-bottom: var(--sp-32);
    padding-bottom: var(--sp-16);
  }
  
  .projects-grid {
    flex-direction: column;
    gap: var(--sp-16);
  }
  
  .projects-grid-small {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--sp-16);
  }
  
  .featured-horizontal {
    flex-direction: column-reverse; /* Reverse order: text first, then image */
    gap: var(--sp-16);
  }
  
  .about-content {
    flex-direction: column;
    gap: var(--sp-16);
  }
  
  .about-image {
    width: 200px;
    height: 200px;
    align-self: center;
  }
}

@media (max-width: 480px) {
  .page-title h1 {
    font-size: var(--txt-32); /* Better small mobile title */
    margin-bottom: var(--sp-16);
  }
  
  .h2 {
    font-size: var(--txt-24); /* Better small mobile section titles */
    margin-bottom: var(--sp-16);
  }
  
  .h3 {
    font-size: var(--txt-20); /* Better h3 for small mobile */
    margin-bottom: var(--sp-12);
  }
  
  .h4 {
    font-size: var(--txt-18); /* Better h4 for small mobile */
    margin-bottom: var(--sp-4);
  }
  
  .h5 {
    font-size: var(--txt-16); /* Better h5 for small mobile */
    margin-bottom: var(--sp-8);
  }
  
  .body1 {
    font-size: var(--txt-15); /* Slightly smaller but still readable */
    line-height: 1.5;
    margin-bottom: var(--sp-12);
  }
  
  .body2 {
    font-size: var(--txt-13); /* Slightly smaller but still readable */
    line-height: 1.4;
    margin-bottom: var(--sp-10);
  }
  
  .subtitle1 {
    font-size: var(--txt-15); /* Keep readable */
  }
  
  .overline {
    font-size: var(--txt-10); /* Keep readable */
  }
  
  .projects-grid-small {
    grid-template-columns: 1fr;
    gap: var(--sp-16); /* Match consistent gap */
  }
  
  .about-image {
    width: 150px;
    height: 150px;
  }
  
  .main-layout {
    gap: var(--sp-16);
  }
  
  .section {
    margin-bottom: var(--sp-24);
    padding-bottom: var(--sp-12);
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}