/* ==========================================================================
   GABRIEL BROSIUS PORTFOLIO - CORE STYLES
   ========================================================================== */

/* Typography & Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,700&family=Inter:wght@300;400;500;600;700&display=swap');

/* Color Variables & Theme Tokens */
:root {
  --background: hsl(0, 0%, 5%);     /* Deep cinematic dark: #0d0d0d */
  --foreground: hsl(0, 0%, 90%);    /* Soft white: #e5e5e5 */
  --border: hsl(0, 0%, 15%);        /* Dark grey borders: #262626 */
  --input: hsl(0, 0%, 15%);
  --ring: hsl(24, 90%, 50%);        /* Vibrant orange accent: #f97316 */
  
  --card: hsl(0, 0%, 7%);
  --card-foreground: hsl(0, 0%, 90%);
  --card-border: hsl(0, 0%, 15%);
  
  --primary: hsl(24, 90%, 50%);     /* Orange: #f97316 */
  --primary-hover: hsl(24, 95%, 45%);
  --primary-foreground: hsl(0, 0%, 100%);
  
  --muted: hsl(0, 0%, 15%);
  --muted-foreground: hsl(0, 0%, 60%);
  
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-serif: 'Fraunces', Georgia, serif;
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  overflow-x: hidden;
  background-color: var(--background);
  color: var(--foreground);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--background);
}
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--muted-foreground);
}

/* Text Selection */
::selection {
  background-color: var(--primary);
  color: white;
}

/* Global Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 300;
  letter-spacing: -0.02em;
}

p {
  color: var(--muted-foreground);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

/* Base Layout Helpers */
.relative { position: relative; }
.w-full { width: 100%; }
.h-screen { height: 100vh; }
.overflow-hidden { overflow: hidden; }

/* Film Grain Overlay */
.film-grain {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Navbar */
nav.fixed-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  border-bottom: 1px solid transparent;
}

nav.fixed-nav.scrolled {
  background-color: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-link {
  font-family: var(--font-serif);
  font-size: 1rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: white;
}

.nav-links {
  display: none;
  align-items: center;
  gap: 1.75rem;
}

@media (min-width: 1024px) {
  .nav-links {
    display: flex;
  }
}

.nav-link {
  position: relative;
  font-size: 0.75rem;
  font-weight: 400;
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--muted-foreground);
  padding-bottom: 0.25rem;
  transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
  color: white;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background-color: var(--primary);
}

/* Hamburger Menu button */
.menu-toggle {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 0.5rem;
  z-index: 1001;
}

@media (min-width: 1024px) {
  .menu-toggle {
    display: none;
  }
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 1px;
  background-color: white;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.menu-toggle.open span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Mobile Dropdown Menu */
.mobile-nav {
  display: block;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  background-color: rgba(0, 0, 0, 0.95);
}

.mobile-nav.open {
  max-height: 500px;
  opacity: 1;
}

.mobile-nav-container {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.5rem;
}

.mobile-nav-link {
  padding: 0.75rem 0;
  font-size: 0.875rem;
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--muted-foreground);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
}

.mobile-nav-link:last-child {
  border-bottom: none;
}

.mobile-nav-link.active {
  color: white;
}

.mobile-nav-link.active::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--primary);
  margin-right: 0.5rem;
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 1;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  transform: scale(1.12);
}

.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
  padding: 0 1rem;
  max-width: 1000px;
  margin-top: 5rem;
}

.hero-title {
  font-size: clamp(3.5rem, 8vw, 8rem);
  text-transform: uppercase;
  letter-spacing: -0.03em;
  line-height: 0.9;
  margin-bottom: 1.5rem;
  color: white;
}

.hero-subtitle {
  font-family: var(--font-sans);
  font-size: clamp(0.875rem, 2vw, 1.25rem);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: hsl(0, 0%, 80%);
}

.hero-scroll {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  opacity: 0.8;
}

/* Bio Section */
.bio-section {
  padding: 6rem 1.5rem;
  background-color: var(--background);
  position: relative;
  z-index: 20;
}

.container-narrow {
  max-width: 900px;
  margin: 0 auto;
}

.section-label {
  font-size: 0.75rem;
  font-family: var(--font-sans);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 2rem;
  font-weight: 500;
}

.bio-text {
  font-family: var(--font-serif);
  font-size: clamp(1.375rem, 3.5vw, 3rem);
  line-height: 1.3;
  color: hsl(0, 0%, 85%);
  font-weight: 300;
}

.bio-text p {
  color: hsl(0, 0%, 85%);
  margin-bottom: 2rem;
}

.bio-location {
  color: var(--muted-foreground) !important;
}

/* Grid Layouts for Projects */
.projects-section {
  padding: 6rem 1.5rem;
  background-color: black;
  position: relative;
  z-index: 20;
}

.projects-section.alt-bg {
  background-color: var(--background);
}

.container-wide {
  max-width: 1400px;
  margin: 0 auto;
}

.project-list {
  display: flex;
  flex-direction: column;
  gap: 5rem;
}

@media (min-width: 1024px) {
  .project-list {
    gap: 7rem;
  }
}

.project-card {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

@media (min-width: 768px) {
  .project-card {
    flex-direction: row;
    align-items: center;
    gap: 4rem;
  }
  .project-card.reverse {
    flex-direction: row-reverse;
  }
}

@media (min-width: 1024px) {
  .project-card {
    gap: 6rem;
  }
}

.project-image-wrapper {
  width: 100%;
}

@media (min-width: 768px) {
  .project-image-wrapper {
    width: 60%;
  }
}

.project-image-link {
  display: block;
  width: 100%;
  overflow: hidden;
  position: relative;
  cursor: pointer;
}

.project-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: grayscale(20%);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
}

.project-image-link:hover .project-image {
  transform: scale(1.03);
  filter: grayscale(0%);
}

.project-overlay-text {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.5s ease;
}

.project-image-link:hover .project-overlay-text {
  background-color: rgba(0, 0, 0, 0.2);
}

.project-overlay-text span {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: white;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.project-image-link:hover .project-overlay-text span {
  opacity: 1;
}

.project-details-wrapper {
  width: 100%;
}

@media (min-width: 768px) {
  .project-details-wrapper {
    width: 40%;
  }
}

.project-meta {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--muted-foreground);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.project-title {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  margin-bottom: 0.75rem;
  color: white;
  transition: color 0.3s ease;
  line-height: 1.1;
}

.project-title:hover {
  color: var(--primary);
}

.project-role {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 1.25rem;
}

.project-logline {
  font-size: 1rem;
  color: hsl(0, 0%, 75%);
  line-height: 1.6;
  margin-bottom: 1rem;
  max-width: 450px;
}

.project-note {
  font-size: 0.75rem;
  color: hsl(0, 0%, 50%);
  font-style: italic;
  line-height: 1.5;
}

/* Television Writing Section (Grids) */
.tv-grid {
  display: grid;
  grid-template-columns: 1fr;
  background-color: hsl(0, 0%, 10%);
  gap: 1px;
}

@media (min-width: 768px) {
  .tv-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Center grids with fewer than 3 cards */
.tv-grid--center {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  background-color: black;
}

.tv-grid--center .tv-card {
  flex: 0 0 100%;
}

@media (min-width: 768px) {
  .tv-grid--center .tv-card {
    flex: 0 0 50%;
    border-right: 1px solid hsl(0, 0%, 10%);
  }

  .tv-grid--center .tv-card:last-child {
    border-right: none;
  }
}

/* Single card — one third width */
.tv-grid--single .tv-card {
  flex: 0 0 100%;
}

@media (min-width: 768px) {
  .tv-grid--single .tv-card {
    flex: 0 0 33.333%;
    border-right: none;
  }
}

.tv-card {
  background-color: black;
  padding: 2.5rem 2rem;
}

@media (min-width: 1024px) {
  .tv-card {
    padding: 3rem 2.5rem;
  }
}

.tv-meta {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--muted-foreground);
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.tv-title {
  font-size: 1.75rem;
  color: white;
  margin-bottom: 0.75rem;
  line-height: 1.2;
}

.tv-logline {
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--muted-foreground);
  margin-bottom: 1rem;
}

.tv-note {
  font-size: 0.75rem;
  color: var(--primary);
  font-style: italic;
  letter-spacing: 0.05em;
}

/* Theater Experience Section (List) */
.theater-list {
  display: flex;
  flex-direction: column;
}

.theater-row {
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .theater-row {
    flex-direction: row;
    gap: 4rem;
    align-items: flex-start;
  }
}

.theater-row:first-child {
  padding-top: 0;
}

.theater-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.theater-meta {
  width: 100%;
}

@media (min-width: 768px) {
  .theater-meta {
    width: 12rem;
    flex-shrink: 0;
  }
}

.theater-year {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: var(--muted-foreground);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.theater-role {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: var(--primary);
  text-transform: uppercase;
}

.theater-details {
  flex-grow: 1;
}

.theater-title {
  font-size: 1.75rem;
  color: white;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.theater-venue {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: var(--muted-foreground);
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.theater-logline {
  font-size: 1rem;
  color: hsl(0, 0%, 75%);
  line-height: 1.6;
}

/* Recognition/Awards Section */
.awards-list {
  display: flex;
  flex-direction: column;
}

.award-row {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

@media (min-width: 768px) {
  .award-row {
    flex-direction: row;
    align-items: baseline;
    gap: 2.5rem;
  }
}

.award-row:first-child {
  padding-top: 0;
}

.award-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.award-year {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: var(--muted-foreground);
  width: 4rem;
  flex-shrink: 0;
}

.award-content {
  flex-grow: 1;
}

.award-title {
  font-size: 1.5rem;
  color: white;
  margin-bottom: 0.25rem;
  line-height: 1.2;
}

.award-festival {
  font-size: 0.875rem;
  letter-spacing: 0.1em;
  color: var(--muted-foreground);
  text-transform: uppercase;
}

.award-separator {
  color: hsl(0, 0%, 25%);
  margin: 0 0.5rem;
}

/* Education Section */
.education-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 640px) {
  .education-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .education-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.education-card {
  border-left: 1px solid rgba(255, 100, 0, 0.4);
  padding-left: 1.25rem;
}

.education-degree {
  font-size: 1.125rem;
  color: white;
  margin-bottom: 0.25rem;
  line-height: 1.3;
}

.education-school {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: var(--muted-foreground);
  text-transform: uppercase;
}

/* Administrative Experience Section */
.admin-grid {
  display: grid;
  grid-template-columns: 1fr;
  background-color: var(--border);
  gap: 1px;
}

@media (min-width: 768px) {
  .admin-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.admin-card {
  background-color: black;
  padding: 2.5rem;
}

@media (min-width: 1024px) {
  .admin-card {
    padding: 3.5rem;
  }
}

.admin-year {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--muted-foreground);
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.admin-org {
  font-size: 1.75rem;
  color: white;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.admin-role {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: var(--primary);
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.admin-desc {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--muted-foreground);
}

/* Contact Section */
.contact-section {
  padding: 6rem 1.5rem;
  background-color: var(--background);
  position: relative;
  z-index: 20;
}

.contact-container {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

@media (min-width: 768px) {
  .contact-container {
    flex-direction: row;
    align-items: flex-start;
    gap: 5rem;
  }
}

.contact-photo-wrapper {
  width: 100%;
  max-width: 280px;
  flex-shrink: 0;
  overflow: hidden;
}

@media (max-width: 767px) {
  .contact-photo-wrapper {
    max-width: 100%;
    aspect-ratio: 2/3;
  }
}

.contact-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(15%);
  display: block;
}

.contact-content {
  flex-grow: 1;
}

.contact-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  text-transform: uppercase;
  color: white;
  line-height: 0.95;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.contact-subtitle {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  margin-bottom: 2rem;
}

/* Forms */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 640px) {
  .form-row {
    flex-direction: row;
  }
}

.form-input, .form-textarea {
  width: 100%;
  background-color: transparent;
  border: 1px solid hsl(0, 0%, 20%);
  color: white;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  padding: 0.75rem 1rem;
  transition: border-color 0.3s ease;
}

.form-input::placeholder, .form-textarea::placeholder {
  color: hsl(0, 0%, 25%);
}

.form-input:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--primary);
}

.form-textarea {
  resize: none;
}

.form-status {
  font-size: 0.75rem;
  font-family: var(--font-sans);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.form-status.success {
  color: var(--primary);
}

.form-status.error {
  color: hsl(0, 85%, 60%);
}

.btn-submit {
  align-self: flex-start;
  background-color: var(--primary);
  color: black;
  border: none;
  font-size: 0.75rem;
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: 0.3em;
  padding: 0.75rem 2rem;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.btn-submit:hover {
  background-color: white;
  color: black;
}

.btn-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.social-links {
  display: flex;
  gap: 2rem;
  font-size: 0.875rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.social-link {
  color: var(--muted-foreground);
  transition: color 0.3s ease;
}

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

/* Footer */
footer.footer {
  padding: 2rem 0;
  text-align: center;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: hsl(0, 0%, 25%);
  border-top: 1px solid var(--border);
  background-color: black;
  position: relative;
  z-index: 20;
}

/* Project Details Page Styles */
.nav-project-type {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}

.nav-back-link {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  cursor: pointer;
}

.nav-back-link:hover {
  color: white;
}

.sticky-project-title {
  display: none;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.sticky-project-title.visible {
  display: block;
  max-height: 60px;
  opacity: 1;
}

.sticky-project-container {
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: baseline;
  gap: 1rem;
}

.sticky-title-text {
  font-family: var(--font-serif);
  font-size: 1.125rem;
  color: white;
  text-transform: uppercase;
  line-height: 1;
}

.sticky-subtitle-text {
  font-size: 0.75rem;
  color: var(--muted-foreground);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  display: none;
}

@media (min-width: 640px) {
  .sticky-subtitle-text {
    display: block;
  }
}

.project-hero {
  position: relative;
  height: 42vh;
  width: 100%;
  overflow: hidden;
  margin-top: 3.5rem; /* Heights of nav bar */
}

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

.project-hero-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.55);
  z-index: 1;
}

.project-hero-content {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 10;
  padding: 2rem 1.5rem;
}

@media (min-width: 768px) {
  .project-hero-content {
    padding: 3rem 4rem;
  }
}

.project-hero-meta {
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.75rem;
}

.project-hero-title {
  font-size: clamp(2.25rem, 5vw, 4.5rem);
  text-transform: uppercase;
  color: white;
  line-height: 0.95;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.project-hero-role {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}

.project-body {
  max-width: 900px;
  margin: 0 auto;
  padding: 4rem 1.5rem 6rem 1.5rem;
}

@media (min-width: 768px) {
  .project-body {
    padding: 6rem 3rem 8rem 3rem;
  }
}

.project-body-section {
  margin-bottom: 5rem;
}

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

.project-large-logline {
  font-family: var(--font-serif);
  font-size: clamp(1.375rem, 3vw, 2.25rem);
  line-height: 1.4;
  color: hsl(0, 0%, 85%);
  font-weight: 300;
  margin-bottom: 2rem;
}

.project-large-note {
  font-size: 0.875rem;
  color: var(--primary);
  font-style: italic;
  line-height: 1.5;
  margin-bottom: 2rem;
}

.btn-external {
  display: inline-block;
  font-size: 0.75rem;
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 0.75rem 1.5rem;
  transition: all 0.3s ease;
}

.btn-external:hover {
  background-color: var(--primary);
  color: black;
}

.project-video-wrapper {
  aspect-ratio: 16/9;
  width: 100%;
  background-color: black;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.project-video-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.project-gallery-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) {
  .project-gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.gallery-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: opacity 0.7s ease, transform 0.6s ease;
}

.gallery-image.lazy {
  opacity: 0;
}

.gallery-image.loaded {
  opacity: 1;
}

.back-to-portfolio-footer {
  padding: 2rem 0;
  text-align: center;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  border-top: 1px solid var(--border);
  background-color: black;
}

.back-to-portfolio-footer span:hover {
  color: var(--primary);
}

/* Animations / Reveal on Scroll */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1s ease, transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.reveal-left {
  opacity: 0;
  transform: translateX(-30px);
  transition: opacity 1s ease, transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-left.revealed {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(30px);
  transition: opacity 1s ease, transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-right.revealed {
  opacity: 1;
  transform: translateX(0);
}

/* ==========================================================================
   ADDITIONS
   ========================================================================== */

/* Hero image credit label */
.hero-image-credit {
  position: absolute;
  bottom: 2.5rem;
  right: 1.5rem;
  z-index: 10;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
}

.hero-image-credit a {
  color: rgba(255, 255, 255, 0.4);
  transition: color 0.3s ease;
}

.hero-image-credit a:hover {
  color: rgba(255, 255, 255, 0.75);
}

/* Fix mobile "Scroll" centering */
.hero-scroll {
  left: 50%;
  transform: translateX(-50%);
}

/* Featured Work section */
.featured-section {
  padding: 5rem 1.5rem 6rem;
  background-color: var(--background);
  position: relative;
  z-index: 20;
  border-top: 1px solid var(--border);
}

.featured-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
}

@media (min-width: 640px) {
  .featured-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
  }
}

.featured-card {
  display: block;
  cursor: pointer;
}

.featured-image-wrapper {
  position: relative;
  overflow: hidden;
  margin-bottom: 1.25rem;
  aspect-ratio: 16/10;
}

.featured-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(20%);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
}

.featured-card:hover .featured-image {
  transform: scale(1.04);
  filter: grayscale(0%);
}

.featured-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(0,0,0,0);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.5s ease;
}

.featured-card:hover .featured-overlay {
  background-color: rgba(0,0,0,0.25);
}

.featured-overlay span {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: white;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.featured-card:hover .featured-overlay span {
  opacity: 1;
}

.featured-title {
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  color: white;
  margin-bottom: 0.4rem;
  line-height: 1.1;
}

.featured-sub {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
}

/* TV genre + available */
.tv-genre {
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.4rem;
  margin-top: 0.5rem;
}

.tv-available {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: hsl(0, 0%, 35%);
  font-style: italic;
}

/* Ensure award-year is always visible */
.award-year {
  font-weight: 500;
  color: var(--muted-foreground) !important;
  min-width: 4rem;
}

@media (max-width: 767px) {
  .award-row {
    flex-direction: row !important;
    align-items: baseline;
    gap: 1.25rem;
  }
  .award-year {
    font-size: 0.7rem;
  }
}

/* Poster-style hero (taller, image shown more fully) */
.project-hero--poster {
  height: 60vh;
}

.project-hero--poster img {
  object-position: center top;
}

@media (min-width: 768px) {
  .project-hero--poster {
    height: 72vh;
  }
}

/* Play the Game — big centered CTA */
.play-btn-wrapper {
  margin-top: 2.5rem;
  display: flex;
  justify-content: center;
}

.btn-play-game {
  display: inline-block;
  font-size: 1rem;
  font-family: var(--font-sans);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  background-color: var(--primary);
  color: black;
  padding: 1.25rem 3.5rem;
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.btn-play-game:hover {
  background-color: white;
  color: black;
  transform: scale(1.03);
}

@media (min-width: 640px) {
  .btn-play-game {
    font-size: 1.125rem;
    padding: 1.5rem 5rem;
  }
}

/* Orange project titles in awards */
.award-project {
  color: var(--primary);
}

/* Smaller hero for Spallas visualizer */
.project-hero--compact {
  height: 30vh;
}

@media (min-width: 768px) {
  .project-hero--compact {
    height: 33vh;
  }
}

/* Constrain tall/portrait project card images to landscape ratio */
.project-image-link--landscape {
  aspect-ratio: 16/9;
}

.project-image-link--landscape .project-image {
  height: 100%;
  object-position: center;
}

/* Writing section subsection labels */
.writing-subsection-label {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  margin-bottom: 1.5rem;
  margin-top: 3rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

/* Script snippet link */
.tv-snippet {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.4rem;
  margin-top: 0.25rem;
  transition: opacity 0.2s ease;
}

.tv-snippet:hover {
  opacity: 0.7;
}

/* Two-card centered grid — no grey sides */
.tv-grid--pair {
  display: flex;
  justify-content: center;
  background-color: black;
  gap: 0;
}

.tv-grid--pair .tv-card {
  flex: 0 0 100%;
  border-bottom: 1px solid hsl(0, 0%, 10%);
}

@media (min-width: 768px) {
  .tv-grid--pair .tv-card {
    flex: 0 0 33.333%;
    border-bottom: none;
    border-right: 1px solid hsl(0, 0%, 10%);
  }

  .tv-grid--pair .tv-card:last-child {
    border-right: none;
  }
}
