/* Variables & Theming */
:root {
  /* Dark Theme (Default) */
  --bg-color: #1A1516;
  --bg-alternate: #241D1E;
  --text-primary: #FCEEEE;
  --text-secondary: #B3A1A3;
  --border-color: rgba(255, 233, 233, 0.1);
  --glass-bg: rgba(26, 21, 22, 0.7);
  --glass-border: rgba(255, 233, 233, 0.08);
  --accent-color: #FF8EAD;
  --primary-color: #FF8EAD;
  --accent-gradient: linear-gradient(135deg, #FF8EAD, #E06C8B);
  --btn-text: #1A1516;
  --hero-shape-bg: #2B1D20;
}

[data-theme="light"] {
  /* Light Theme */
  --bg-color: #FDFBFB;
  --bg-alternate: #FFE9E9;
  --text-primary: #2D2325;
  --text-secondary: #6B5E62;
  --border-color: rgba(90, 70, 75, 0.1);
  --glass-bg: rgba(253, 251, 251, 0.85);
  --glass-border: rgba(90, 70, 75, 0.08);
  --accent-color: #D65A78;
  --primary-color: #D65A78;
  --accent-gradient: linear-gradient(135deg, #FF7096, #D65A78);
  --btn-text: #FFFFFF;
  --hero-shape-bg: #FFE9E9;
}

/* Reset & Basics */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Geist', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.6;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
}

h1, h2, h3, h4, .logo {
  font-family: 'TiemposText', 'Tiempos Text', serif;
  letter-spacing: -0.02em;
}

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

/* Typography */
.gradient-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.max-w-lg {
  max-width: 800px;
}

.text-center { text-align: center; }
.mb-5 { margin-bottom: 3rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mt-5 { margin-top: 3rem; }

.glass {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.cs-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

.section-spacing {
  padding: 8rem 0;
}

.alternate-bg {
  background-color: var(--bg-alternate);
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 1.25rem 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: var(--glass-bg);
  border-bottom: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

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

.mobile-only {
  display: none;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -1px;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s;
}

.nav-link:hover {
  color: var(--text-primary);
}

.icon-button {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.2s;
}

.icon-button:hover {
  background: var(--glass-border);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.8rem;
  border-radius: 100px;
  font-weight: 600;
  font-size: 1rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.btn-primary {
  background: var(--text-primary);
  color: var(--bg-color);
  border: none;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(255, 255, 255, 0.1);
}

[data-theme="light"] .btn-primary:hover {
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.15);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  border-color: var(--text-primary);
  background: var(--glass-border);
}

.social-icon {
  padding: 0.8rem;
}

.btn-large {
  padding: 1.2rem 2.5rem;
  font-size: 1.1rem;
}

.glow-effect {
  position: relative;
  background: var(--accent-gradient);
  color: var(--btn-text);
  border: none;
}

.glow-effect::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: var(--accent-gradient);
  border-radius: inherit;
  z-index: -1;
  filter: blur(15px);
  opacity: 0.6;
  transition: opacity 0.3s ease;
}

.glow-effect:hover::before {
  opacity: 0.9;
}

/* Glassmorphism Classes */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
}

.glass-panel {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
}

[data-theme="light"] .glass-panel {
  background: rgba(0,0,0,0.02);
}

/* Sections Core */
.section-header {
  margin-bottom: 4rem;
  max-width: 600px;
}

.section-title {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 6rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -10%;
  width: 120vh;
  height: 120vh;
  min-width: 800px;
  min-height: 800px;
  background-color: var(--hero-shape-bg);
  border-radius: 50%;
  z-index: 0;
  transition: background-color 0.3s ease;
}

.hero-content {
  position: relative;
  z-index: 10;
}

.hero-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  border-radius: 100px;
  background: color-mix(in srgb, var(--accent-color) 15%, transparent);
  color: var(--accent-color);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 2rem;
  border: 1px solid color-mix(in srgb, var(--accent-color) 30%, transparent);
}

.hero-title {
  font-size: clamp(3rem, 6vw, 5.5rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  color: var(--text-secondary);
  max-width: 650px;
  margin-bottom: 4rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Art Section */
.subsection-title {
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
}
.subsection-desc {
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.art-canvas {
  height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.canvas-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--text-secondary);
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: 0.85rem;
}

.pulse-dot {
  width: 12px; height: 12px;
  background: var(--accent-color);
  border-radius: 50%;
  margin-bottom: 1rem;
  box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(59, 130, 246, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(59, 130, 246, 0); }
}

/* Games Section */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.game-card {
  padding: 0;
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  min-height: 250px;
}

.game-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-color);
}

.game-num {
  font-size: 2rem;
  opacity: 0.1;
  font-weight: 800;
  margin-bottom: 1rem;
}

.game-title {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.game-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  flex-grow: 1;
  margin-bottom: 1.5rem;
}

.game-link {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-color);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.game-link .arrow {
  transition: transform 0.2s ease;
}

.game-card:hover .game-link .arrow {
  transform: translateX(5px);
}

/* Footer & Contact */
.contact-desc {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 3rem;
}

.footer {
  padding: 3rem 0;
  border-top: 1px solid var(--border-color);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--text-primary);
}

/* Animation Utilities */
.ig-post:hover .ig-img {
  transform: scale(1.1) !important;
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

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

/* ========================================================================= */
/* Case Study Template Styles */
/* ========================================================================= */
.case-study-page .navbar {
  position: fixed;
}

.cs-hero {
  position: relative;
  height: 80vh;
  min-height: 500px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.cs-hero-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(180deg, rgba(10, 10, 15, 0.5) 0%, rgba(10, 10, 15, 0.95) 100%);
}

.cs-hero-content {
  position: relative;
  z-index: 10;
}

.cs-logo {
  max-width: 250px;
  margin-bottom: 2rem;
}

.cs-title {
  font-size: 5rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  font-family: 'TiemposText', 'Tiempos Text', serif;
}

.cs-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.meta-item {
  padding: 1.5rem;
  border-radius: 12px;
}

.meta-item h5 {
  font-size: 0.85rem;
  text-transform: uppercase;
  color: var(--text-secondary);
  letter-spacing: 1px;
  margin-bottom: 0.5rem;
}

.cs-intro .lead-text {
  font-size: 1.5rem;
  line-height: 1.8;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  font-weight: 300;
}

.cs-text-wrap {
  max-width: 800px;
  margin: 0 auto 3rem auto;
}

.inline-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.cs-img-rounded {
  width: 100%;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

.cs-img-rounded:hover {
  transform: translateY(-5px);
}

.cs-img-full {
  max-width: 100%;
  border-radius: 20px;
}

/* --- Showcase Module (Carousel vs Grid) --- */
.cs-showcase-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
}

.view-toggle {
  display: flex;
  background: rgba(255,255,255,0.05);
  border-radius: 100px;
  padding: 0.3rem;
  border: 1px solid rgba(255,255,255,0.1);
}

.toggle-btn {
  background: transparent;
  color: var(--text-secondary);
  border: none;
  padding: 0.5rem 1.5rem;
  border-radius: 100px;
  cursor: pointer;
  font-family: 'Geist', sans-serif;
  font-weight: 600;
  transition: all 0.3s ease;
}

.toggle-btn.active {
  background: var(--primary-color);
  color: white;
  box-shadow: 0 4px 15px rgba(230, 57, 70, 0.4);
}

/* Carousel Mode */
.showcase-carousel-mode {
  width: 100%;
  overflow: hidden;
  position: relative;
  padding: 2rem 0;
  mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}

.showcase-carousel-mode .showcase-track {
  display: flex;
  gap: 2rem;
  animation: slide 30s linear infinite;
  width: max-content;
}

.showcase-carousel-mode .showcase-track:hover {
  animation-play-state: paused;
}

@keyframes slide {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); } 
  /* Note: In production you would duplicate the images to make it truly infinite. 
     For this demo, we shift halfway so it scrolls broadly. */
}

/* Grid Mode */
.showcase-grid-mode .showcase-track {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  animation: none;
  width: 100%;
}

.showcase-item {
  width: 280px;
  border-radius: 24px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.3);
  object-fit: contain;
  background: #FFF; /* specific for clean mockup isolation */
  transition: transform 0.3s ease;
}

.showcase-carousel-mode .showcase-item {
  flex-shrink: 0;
}

.showcase-grid-mode .showcase-item {
  width: 100%;
}

.showcase-grid-mode .showcase-item:hover {
  transform: translateY(-10px);
}

/* Pull Quote */
.pull-quote {
  font-family: 'TiemposText', 'Tiempos Text', serif;
  font-size: 2rem;
  font-weight: 300;
  line-height: 1.4;
  text-align: center;
  max-width: 900px;
  margin: 0 auto 2rem auto;
  color: #FFF;
}

.quote-author {
  font-size: 1.1rem;
  color: var(--primary-color);
  letter-spacing: 1px;
}

/* Responsive */
@media (max-width: 768px) {
  .mobile-only {
    display: flex;
  }

  .nav-content {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .nav-links {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: color-mix(in srgb, var(--bg-color) 98%, transparent);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    margin: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 90;
  }
  
  .nav-links.active {
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links .nav-link {
    font-size: 2rem;
    font-weight: 600;
    position: relative;
    padding-bottom: 0.2rem;
  }
  
  .nav-links .nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-gradient);
    transition: width 0.3s ease;
  }
  
  .nav-links .nav-link:hover::after,
  .nav-links .nav-link:active::after {
    width: 100%;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
    width: 100%;
  }

  .hero-actions .btn-primary {
    width: 100%;
  }

  .hero::before {
    top: -5%;
    right: -30vw;
    width: 160vw;
    height: 55%;
    min-width: unset;
    min-height: unset;
    border-radius: 50%;
  }
  
  body {
    overflow-x: hidden;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .footer-content {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

/* About Page Timeline */
.about-hero {
  padding-top: 12rem;
}

.timeline-grid {
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.timeline-entry {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 3rem;
  align-items: flex-start;
}

.timeline-date {
  font-family: 'TiemposText', 'Tiempos Text', serif;
  font-size: 1.5rem;
  font-weight: 700;
  position: sticky;
  top: 120px;
  color: var(--primary-color);
}

.timeline-content {
  padding: 3rem;
  border-radius: 24px;
}

.timeline-company {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.timeline-role {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
}

.timeline-desc {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.timeline-roles {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
  border-left: 2px solid var(--border-color);
  padding-left: 1.5rem;
}

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

.role-item .role-title {
  font-weight: 600;
  color: var(--text-primary);
}

.role-item .role-date {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.project-placeholders {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 1rem;
}

.placeholder-card {
  min-width: 280px;
  height: 180px;
  border-radius: 16px;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--border-color);
  transition: transform 0.3s ease;
  display: flex;
  align-items: flex-end;
  padding: 1rem;
  color: #fff;
  font-weight: 700;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
  background-color: var(--bg-alternate);
}

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

@media (max-width: 768px) {
  .timeline-entry {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .timeline-date {
    position: static;
    margin-bottom: 1rem;
  }
  
  .role-item {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Nav Item Visibility Controls */
.desktop-only { 
  display: flex; 
}

.mobile-only-link { 
  display: none; 
}

.mobile-only {
  display: none;
}

@media (max-width: 768px) {
  .desktop-only { 
    display: none !important; 
  }
  .mobile-only-link { 
    display: block; 
  }
  .mobile-only {
    display: flex; /* Assuming button is flex/block */
  }
}


/* Updated Paragraph Styles */
p, .small-text, .lead-text, .timeline-desc, .subsection-desc, .game-desc, .cs-intro p {
  color: var(--text-secondary);
  opacity: 0.95;
}


/* Work List - Arlen McCluskey Style */
.work-list {
  display: flex;
  flex-direction: column;
}

.work-row {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 4rem;
  padding: 4rem 0;
  border-bottom: 1px solid var(--border-color);
  align-items: center;
  transition: transform 0.4s ease;
  position: relative;
  text-decoration: none;
}

.work-row:first-child {
  border-top: 1px solid var(--border-color);
}
.work-row:last-child {
  border-bottom: none;
}

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

.work-left {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.work-number {
  font-family: 'Geist', sans-serif;
  font-size: 1rem;
  color: var(--accent-color);
  font-weight: 600;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

.work-company {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--text-secondary);
  border: 1px solid color-mix(in srgb, var(--accent-color) 30%, transparent);
  padding: 0.25rem 0.75rem;
  border-radius: 100px;
  width: fit-content;
  margin-bottom: 1rem;
}

.work-title {
  font-family: 'TiemposText', 'Tiempos Text', serif;
  font-size: clamp(2rem, 3.5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.work-list-desc {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 90%;
  margin-bottom: 1.5rem;
}

.work-link-text {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--accent-color);
  transition: gap 0.3s ease;
}

.work-row:hover .work-link-text {
  gap: 1rem;
}

.work-right {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  aspect-ratio: 16/10;
  background: var(--bg-alternate);
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
  transform: translateZ(0); 
}

.work-list-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.work-row:hover .work-list-img {
  transform: scale(1.05);
}

@media (max-width: 992px) {
  .work-row {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 3rem 0;
  }
}


/* Mobile Nav FAB System */
.mobile-nav-fab {
  display: none; /* hidden on desktop */
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  font-family: 'Geist', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.85rem;
  padding: 1rem 3rem;
  border-radius: 100px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  cursor: pointer;
  transition: transform 0.3s ease, background 0.3s ease;
}

.mobile-nav-fab:hover {
  background: var(--bg-alternate);
  transform: translateX(-50%) translateY(-3px);
}

.mobile-nav-fab:active {
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 768px) {
  .mobile-only {
    display: flex !important;
  }
  .mobile-nav-fab {
    display: flex !important;
  }
}

/* Platform Tags */
.work-platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.platform-pill {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 700;
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  padding: 0.2rem 0.65rem;
  border-radius: 100px;
}

/* Adobe-style multi-link work row */
.work-sub-links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.work-row-multi {
  cursor: default;
}

.work-row-multi:hover {
  transform: none;
}

.work-row-multi:hover .work-list-img {
  transform: scale(1.03);
}

.work-sub-links .work-link-text {
  display: inline-flex;
  width: fit-content;
}

.work-sub-links .work-link-text .arrow {
  transition: transform 0.2s ease;
}

.work-sub-links .work-link-text:hover .arrow {
  transform: translateX(5px);
}

/* Case Study Breadcrumb (top nav strip) */
.cs-breadcrumb-nav {
  padding: 5rem 0 0.875rem;
  border-bottom: 1px solid var(--border-color);
}

.cs-breadcrumb-nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cs-breadcrumb-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.cs-breadcrumb-link:hover {
  color: var(--text-primary);
}

/* Case Study Prev/Next Pagination */
.cs-pagination {
  border-top: 1px solid var(--border-color);
}

.cs-nav-strip {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.cs-nav-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.5rem;
  border-radius: 20px;
  transition: transform 0.3s ease;
  color: inherit;
}

.cs-nav-card:hover {
  transform: translateY(-4px);
}

.cs-nav-card-right {
  flex-direction: row-reverse;
  text-align: right;
}

.cs-nav-thumb {
  width: 90px;
  height: 65px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}

.cs-nav-thumb-placeholder {
  width: 90px;
  height: 65px;
  border-radius: 10px;
  flex-shrink: 0;
  background: var(--bg-alternate);
  border: 1px solid var(--border-color);
}

.cs-nav-card-text {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.cs-nav-direction {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent-color);
  font-weight: 700;
}

.cs-nav-card-right .cs-nav-direction {
  text-align: right;
}

.cs-nav-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
}

@media (max-width: 640px) {
  .cs-nav-strip {
    grid-template-columns: 1fr;
  }
  .cs-nav-card-right {
    flex-direction: row;
    text-align: left;
  }
  .cs-nav-card-right .cs-nav-direction {
    text-align: left;
  }
}

/* =========================================================================
   Case Study Hero — Tilt Card Layout
   ========================================================================= */

/* Hero container: full-viewport gradient canvas */
.cs-hero--card {
  height: auto;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7rem 2rem 6rem;
  text-align: left;
}

/* ── Card + meta strip column wrapper ── */
.cs-hero-card-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  width: 100%;
  max-width: 680px;
}

/* Perspective wrapper — keeps perspective off the card so it doesn't flatten */
.cs-hero-card-scene {
  perspective: 1400px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

/* ── Meta strip — Team + Timeline below the card ── */
.cs-hero-meta-strip {
  display: flex;
  align-items: stretch;
  width: 100%;
  max-width: 620px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
}

.cs-hero-meta-chip {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 1rem 1.75rem;
  gap: 0.2rem;
}

.cs-hero-meta-chip + .cs-hero-meta-chip {
  border-left: 1px solid rgba(255,255,255,0.08);
}

.cs-hero-meta-label {
  font-size: 0.63rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.35);
  font-family: inherit;
}

.cs-hero-meta-value {
  font-size: 0.9rem;
  font-weight: 600;
  color: rgba(255,255,255,0.84);
  font-family: inherit;
}

/* Light mode strip */
[data-theme="light"] .cs-hero-meta-strip {
  background: rgba(255,255,255,0.68);
  border-color: rgba(0,0,0,0.08);
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

[data-theme="light"] .cs-hero-meta-chip + .cs-hero-meta-chip {
  border-left-color: rgba(0,0,0,0.07);
}

[data-theme="light"] .cs-hero-meta-label {
  color: rgba(0,0,0,0.38);
}

[data-theme="light"] .cs-hero-meta-value {
  color: rgba(0,0,0,0.78);
}

/* The card itself */
.cs-hero-card {
  position: relative;
  width: 100%;
  max-width: 620px;
  border-radius: 28px;
  padding: 2.75rem 3rem 3rem;
  overflow: hidden;
  cursor: default;
  transform-style: preserve-3d;
  /* smooth snap back */
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1),
              box-shadow 0.4s ease;
  /* defaults — overridden per-page */
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow:
    0 2px 0 rgba(255,255,255,0.08) inset,
    0 32px 72px rgba(0,0,0,0.45);
  will-change: transform;
}

.cs-hero-card:hover {
  box-shadow:
    0 2px 0 rgba(255,255,255,0.1) inset,
    0 48px 100px rgba(0,0,0,0.6);
  /* fast response on move — JS overrides, this just guards */
  transition: transform 0.08s ease-out, box-shadow 0.35s ease;
}

/* Glare overlay — position updated by JS */
.cs-hero-card-glare {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
  background: radial-gradient(circle at 50% 30%, rgba(255,255,255,0.14) 0%, transparent 65%);
  mix-blend-mode: screen;
}

.cs-hero-card:hover .cs-hero-card-glare {
  opacity: 1;
}

/* Top meta row: tags left, role right */
.cs-hero-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.cs-hero-card-tags {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

/* Re-skin the existing platform-pill for the card context */
.cs-hero-card-tags .platform-pill {
  color: rgba(255,255,255,0.75);
  border-color: rgba(255,255,255,0.2);
}

.cs-hero-card-role {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.4);
  white-space: nowrap;
  padding-top: 0.15rem;
}

/* Card body — slightly lifted for depth */
.cs-hero-card-body {
  transform: translateZ(12px);
}

.cs-hero-card-company {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.4);
  margin-bottom: 0.6rem;
  display: block;
}

/* Title inside card — inherits per-page font */
.cs-hero-card .cs-title {
  font-size: 3.75rem;
  line-height: 1.06;
  margin-bottom: 1rem;
  color: #fff;
}

.cs-hero-card .cs-subtitle {
  font-size: 0.95rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.55);
  max-width: 480px;
}

/* ── Mobile ── */
@media (max-width: 768px) {
  .cs-hero--card {
    min-height: 90vh;
    padding: 6rem 1.25rem 4rem;
  }

  .cs-hero-card-wrap {
    gap: 1rem;
  }

  .cs-hero-card {
    padding: 2rem 2rem 2.5rem;
    border-radius: 20px;
  }

  .cs-hero-card .cs-title {
    font-size: 2.6rem;
  }

  .cs-hero-card-meta {
    margin-bottom: 1.75rem;
  }

  .cs-hero-meta-chip {
    padding: 0.85rem 1.25rem;
  }
}

@media (max-width: 420px) {
  .cs-hero-meta-strip {
    flex-direction: column;
  }
  .cs-hero-meta-chip + .cs-hero-meta-chip {
    border-left: none;
    border-top: 1px solid rgba(255,255,255,0.08);
  }
  [data-theme="light"] .cs-hero-meta-chip + .cs-hero-meta-chip {
    border-top-color: rgba(0,0,0,0.07);
    border-left: none;
  }
}

/* =========================================================================
   Hero Card — Light Mode Overrides
   ========================================================================= */

/* Text → dark */
[data-theme="light"] .cs-hero-card .cs-title    { color: #111111; }
[data-theme="light"] .cs-hero-card .cs-subtitle  { color: rgba(0,0,0,0.55); }
[data-theme="light"] .cs-hero-card-company       { color: rgba(0,0,0,0.38); }
[data-theme="light"] .cs-hero-card-role          { color: rgba(0,0,0,0.38); }

/* Pill fallback (each page still overrides with its accent) */
[data-theme="light"] .cs-hero-card-tags .platform-pill {
  color: rgba(0,0,0,0.6);
  border-color: rgba(0,0,0,0.14);
}

/* Softer shadow on light background */
[data-theme="light"] .cs-hero-card {
  box-shadow:
    0 2px 0 rgba(255,255,255,0.9) inset,
    0 24px 60px rgba(0,0,0,0.09);
}
[data-theme="light"] .cs-hero-card:hover {
  box-shadow:
    0 2px 0 rgba(255,255,255,0.9) inset,
    0 36px 80px rgba(0,0,0,0.14);
}

/* Suppress white glare — invisible on white card anyway */
[data-theme="light"] .cs-hero-card-glare,
[data-theme="light"] .cs-hero-card:hover .cs-hero-card-glare {
  opacity: 0 !important;
}

/* ─── Legacy visual-tilt (kept for any page not yet migrated) ─────────────── */
.cs-hero--has-visual {
  flex-direction: column;
  justify-content: center;
  height: auto;
  min-height: 92vh;
  padding-top: 5rem;
  padding-bottom: 0;
  gap: 2rem;
}

.cs-hero-visual {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  pointer-events: none;
}

.cs-hero-tilt {
  transition: transform 0.1s ease-out;
  will-change: transform;
  pointer-events: none;
}

.cs-hero-tilt img {
  max-height: 340px;
  width: auto;
  display: block;
  filter: drop-shadow(0 28px 72px rgba(0,0,0,0.5));
}

@media (max-width: 768px) {
  .cs-hero--has-visual {
    min-height: 80vh;
    padding-top: 4rem;
    gap: 1.5rem;
  }
  .cs-hero-tilt img {
    max-height: 240px;
  }
}

