/* ==========================================================================
   1. FONTS & VARIABLES
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Cabin:wght@400;500&family=Oswald:wght@400;500&display=swap');

:root {
  /* Layout */
  --content-width: 1100px;
  --site-margin: 5%;
  
  /* Colors */
  --text-main: #111;
  --text-muted: #666;
  --text-light: #888;
  --brand-blue: #14AAE1;
  --brand-blue-hover: #7CD4F4;
  --brand-dark: #07374B;
  --accent-blue: #427df2;
  --accent-blue-hover: #3166d6;
  --accent-green: #01CB84;
  --border-light: #f0f0f0;
  --bg-light: #f8f9fa;
  --bg-dark: #0b1120;
}

html {
  scroll-behavior: smooth;
}

/* ==========================================================================
   2. RESET & GLOBAL STYLES
   ========================================================================== */
body {
  font-family: 'Cabin', sans-serif;
  font-optical-sizing: auto;
  color: var(--text-main);
  line-height: 1.5;
  margin: 0;
  overflow-x: hidden;
}

main {
  max-width: var(--content-width) !important;
  margin: 0 auto;
  padding: 0 var(--site-margin);
}

section {
  padding: 6rem 0;
}

a {
  transition: all .25s ease;
  text-decoration: none;
  color: inherit;
}

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

/* --- Reveal Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6), 
              transform 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6) !important;
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal[data-delay] {
  transition-delay: var(--delay, 0ms) !important;
}

/* --- Placeholder System --- */
.placeholder {
  background-color: #e0e0e0;
  width: 100%;
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: 20px;
}

.placeholder > img,
.placeholder > video,
.placeholder > iframe {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: inherit;
}

.placeholder.square { aspect-ratio: 1 / 1; }
.placeholder.wide { aspect-ratio: 16 / 9; }
.placeholder.hero { aspect-ratio: 21 / 9; }
.placeholder.id-card { 
  border: 2px solid var(--border-light);
  transition: transform 0.3s ease, border-color 0.3s ease;
  aspect-ratio: 3 / 2; 
}

.placeholder.id-card:hover {
  border-color: var(--broadcast-red, red);
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.placeholder::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  animation: placeholderPulse 2s infinite;
}

.placeholder:has(video, img, iframe)::after,
.placeholder:has(video, img, iframe)::before {
  display: none;
}

@keyframes placeholderPulse {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* ==========================================================================
   3. HEADER & NAV
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.95);
  z-index: 1000;
  border-bottom: 1px solid var(--border-light);
}

.header-container {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 1.5rem var(--site-margin);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo { height: 40px; }
.logo img { height: 100%; }

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.nav-menu a {
  font-weight: 500;
  color: var(--text-main);
  font-size: 0.95rem;
}

.nav-menu a:hover {
  color: var(--brand-blue);
}

.header-btn {
  display: inline-block;
  background-color: var(--accent-blue);
  color: white !important;
  padding: 0.8rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  opacity: 1 !important;
}

.header-btn .activted {
  box-shadow: 0px 0px 96px 24px var(--accent-blue), 0px 0px 8px 1px #89b1ff inset;
}

.menu-toggle {
  display: none;
  cursor: pointer;
  z-index: 1001;
  position: relative;
}

.bar {
  display: block;
  width: 25px;
  height: 2px;
  margin: 5px auto;
  background-color: var(--text-main);
  transition: all 0.3s ease-in-out;
}

/* ==========================================================================
   4. HOMEPAGE COMPONENTS
   ========================================================================== */
.intro {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 16rem 0rem 12rem;
  max-width: var(--content-width);
}

.intro-text { max-width: 600px; }

.intro h1 {
  font-family: 'Oswald', sans-serif;
  font-weight: 500;
  font-size: clamp(3rem, 6vw, 5rem);
  text-transform: uppercase;
  letter-spacing: -.2rem;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.intro p {
  font-size: 1.2rem;
  line-height: 1.4;
}

/* --- Work Grid --- */
.work { padding-top: 1rem; }

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem 2.5rem;
}



/* Homepage Grid Cards */
.card img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Forces the image to center and crop beautifully */
  display: block;
  border-radius: 12px;
  transition: scale 0.2s cubic-bezier(0.68, -0.6, 0.32, 1.6), 
              border-radius 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6), 
              opacity 0.2s ease;
}

/* Add this block back right below your .card-hero definition! */
.card-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-hero video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card:hover img {
  border-radius: 24px;
  opacity: 0.9; 
}

.card:active img { scale: 0.96; }

.meta-top {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: bold;
  margin-bottom: 0.4rem;
  opacity: 0.8;
}

.meta-bottom {
  display: flex;      
  justify-content: space-between;
  font-size: 1rem;
  margin-top: 0.4rem;
  opacity: 0.8;
}

/* --- About Strip --- */
.about-strip {
  border-top: 1px solid var(--border-light);
  padding: 8rem 0; 
  margin: 4rem auto;
}

.about-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
  align-items: center;
}

.statement-main {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1.1;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  color: var(--text-main);
}

.statement-sub {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 500px;
  line-height: 1.6;
}

.about-specs {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-left: 3rem;
  border-left: 1px solid var(--border-light);
}

.spec-item { display: flex; flex-direction: column; }

.spec-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1rem;
  color: var(--brand-blue);
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.spec-value {
  font-family: 'Oswald', sans-serif;
  font-size: 1.5rem;
  text-transform: uppercase;
  color: #333;
}

/* Link Animations */
@keyframes highlight {
  from { background-position: 0; }
  to { background-position: -100%; }
}

a.animated {
  margin: 16px;
  padding: 6px 8px;
  border-radius: 8px;
}

a.animated:hover {
  background: #CBE7F4;
  animation: highlight 0.25s forwards;
}

/* ==========================================================================
   5. ABOUT PAGE
   ========================================================================== */
.about-grid-container {
  display: flex;
  gap: 4rem;
  padding: 10rem 0 8rem !important; 
  max-width: var(--content-width);
  margin: 0 auto;
  align-items: flex-end; 
  justify-content: flex-start; 
  min-height: 80vh;
}

.about-col { height: auto; }

.col-1 {
  flex: 1;
  min-width: 300px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.col-1 h1 {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  text-transform: uppercase;
  letter-spacing: -.16rem;
  line-height: 1.1;
  margin-bottom: 2rem;
}

.origin-text {
  font-size: 1.1rem;
  color: var(--text-light);
  line-height: 1.6;
}

.col-narrative {
  flex: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.bio-lead {
  font-size: 1.75rem;
  line-height: 1.3;
  font-weight: 500;
  margin-bottom: 1rem;
  color: var(--brand-blue);
}

.bio-columns {
  display: flex;
  gap: 3rem;
}

.bio-column-inner { flex: 1; }

.bio-column-inner p {
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
  opacity: 0.85;
}

/* --- Slideshow Styling --- */
.slideshow-container {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  margin-top: 2rem;
  border-radius: 8px;
  background: #000; 
}

.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 2.5s ease-in-out; 
  z-index: 1;
}

.slide.active {
  opacity: 1;
  z-index: 2;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  animation: slowZoom 20s linear infinite;
  animation-play-state: paused;
}

.slide.active img { animation-play-state: running; }

@keyframes slowZoom {
  from { transform: scale(1); }
  to { transform: scale(1.3); } 
}

/* --- Hover Words --- */
.word-trigger {
  position: relative;
  display: inline-block; 
  color: var(--brand-blue); 
  font-weight: 700;
  cursor: help;
  white-space: nowrap;
}

.hover-box {
  position: absolute;
  bottom: -420%; 
  left: 50%;
  transform: translateX(-50%) translateY(10px); 
  width: 160px; 
  border-radius: 12px;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none; 
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 9999; 
}

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

.word-trigger:hover .hover-box,
.word-trigger:active .hover-box {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.hover-box::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -8px;
  border-width: 8px;
  border-style: solid;
  border-color: var(--text-main) transparent transparent transparent;
}

/* ==========================================================================
   6. WORK PAGE & PROJECT LISTS
   ========================================================================== */
.work-page { padding-top: 8rem; }
.work-intro { margin-bottom: 4rem; }

.work-intro h1 {
  font-family: 'Oswald', sans-serif;
  font-size: 3.5rem;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.project-list {
  display: flex;
  flex-direction: column;
  gap: 3rem; 
  padding-bottom: 8rem;
}

.wide-card {
  display: flex;
  align-items: center;
  gap: 3rem;
  background-color: var(--bg-light);
  padding: 2.5rem;
  border-radius: 32px;
  transition: scale 0.2s cubic-bezier(0.68, -0.6, 0.32, 1.6), 
              border-radius 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6);
  min-height: 400px; 
  box-sizing: border-box;
}

.wide-card img { transition: opacity 0.2s ease; }

.wide-card:hover {
  border-radius: 24px;
  opacity: 0.9;
}

.card-hero {
  flex: 0 0 320px;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 20px;
  border: var(--text-light) 1px solid ;
}
.card-hero>img {
  width:100%;
}

.card-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.project-name {
  font-family: 'Oswald', sans-serif;
  font-size: 2.2rem;
  line-height: 1.2;
  text-transform: uppercase;
  margin: 8px 0px 2px 0px;
}

.project-description {
  opacity: 0.8;
  line-height: 1.6;
}

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

.view-project-btn {
  font-weight: 600;
  font-size: 1rem;
  color: white;
  margin-left: -4px;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  background-color: var(--brand-blue);
  border-radius: 100px;
  padding: 0.5rem 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05rem;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all .2s;
}

.view-project-btn:hover {
  gap: 8px;
  background-color: var(--brand-dark);
}

.tag-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
  margin-left: -4px;
}

.tag {
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05rem;
  padding: 0.5rem 1rem;
  background: #dbf5ff;
  border-radius: 50px;
  color: var(--brand-dark);
}

/* Half Card Layout */
.half-row {
  display: flex;
  gap: 3rem; 
}

.wide-card.half {
  flex: 1;
  flex-direction: column; 
  align-items: flex-start;
}

.wide-card.half .card-hero {
  flex: 0 0 auto;
  width: 100%;
  height: 250px; 
}

.wide-card.half .project-name { font-size: 1.8rem; }

.achievers-center-featured .project-date {
  color: var(--brand-blue);
  font-weight: 700;
  letter-spacing: 0.05rem;
}

/* ==========================================================================
   7. PROJECT TEMPLATING
   ========================================================================== */
.project-hero {
  max-width: var(--content-width);
  margin: 0 auto;
  padding-top: 10rem;
  padding-bottom: 2rem;
}

.hero-content {
  max-width: 800px;
  margin-bottom: 4rem;
}

.project-category {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1rem;
  color: var(--brand-blue);
  font-weight: 600;
}

.project-hero h1 {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(3rem, 8vw, 6rem);
  text-transform: uppercase;
  line-height: 0.9;
  margin: 1.5rem 0;
}

.project-lead {
  font-size: 1.5rem;
  line-height: 1.4;
  opacity: 0.8;
}

.hero-image-full img {
  width: 100%;
  border-radius: 24px;
}

.project-info-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  max-width: var(--content-width);
  margin: 0 auto;
  gap: 6rem;
  padding: 6rem 0;
}

.info-block h3, .info-sidebar h4 {
  font-family: 'Oswald', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.05rem;
  margin-bottom: 1rem;
}

.info-sidebar {
  border-left: 1px solid var(--border-light);
  padding-left: 3rem;
}

.sidebar-item { margin-bottom: 2rem; }

/* --- Gallery --- */
.project-gallery {
  display: flex;
  flex-direction: column;
  gap: 6rem;
  max-width: var(--content-width);
  margin: 0 auto;
}

.gallery-item img {
  width: 100%;
  border-radius: 12px;
}

.gallery-item.full-width img {
  width: 100%;
  display: block;
}

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

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

.gallery-grid-3 img { border-radius: 8px; }

/* --- Bottom Navigation --- */
.project-nav {
  padding: 8rem 0;
  border-top: 1px solid var(--border-light);
  margin-top: 6rem;
}

.next-link {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.nav-label {
  display: block;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1rem;
  color: var(--text-light);
  font-weight: 600;
}

.project-nav .col-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.previous-title, .next-title {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(1.2rem, 3vw, 2.5rem);
  text-transform: uppercase;
  color: var(--text-main);
  transition: color 0.3s ease, transform 0.3s ease;
}

.previous-title:hover {
  color: var(--brand-blue);
  transform: translateX(-10px);
}

.next-title:hover {
  color: var(--brand-blue);
  transform: translateX(10px);
}

.id-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.voiceover-showcase {
  background: var(--bg-light);
  padding: 3rem;
  border-radius: 24px;
  border-left: 8px solid var(--brand-blue);
  margin: 2rem 0;
}

.voiceover-showcase h3 { margin-top: 0; color: var(--text-main); }

/* ==========================================================================
   8. FOOTER
   ========================================================================== */
.site-footer {
  background-color: var(--bg-dark);
  color: #ffffff;
  padding: 80px var(--site-margin) 40px;
  text-align: left;
}

.footer-container {
  max-width: var(--content-width) !important;
  margin: 0 auto;
}

.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 40px 0;
}

.row-top { border-bottom: 1px solid rgba(255, 255, 255, 0.1); }

.footer-logo {
  height: 30px;
  filter: brightness(0) invert(1);
  display: block;
  margin-bottom: 10px;
}

.copyright {
  font-size: 0.8rem;
  color: #8892b0;
  margin: 0;
}

.col-socials, .col-nav {
  display: flex;
  gap: 24px;
  align-items: center;
}

.footer-col a {
  color: #ffffff;
  font-size: 0.9rem;
  opacity: 0.7;
}

.footer-col a:hover { opacity: 1; }

.col-cta { text-align: right; }

.footer-btn {
  display: inline-block;
  background-color: var(--accent-blue);
  color: white !important;
  padding: 0.8rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  opacity: 1 !important;
}

.footer-btn .activted {
  box-shadow: 0px 0px 96px 24px var(--accent-blue), 0px 0px 8px 1px #89b1ff inset;
}

/* ==========================================================================
   9. 404 ERROR PAGE
   ========================================================================== */
.error-page main {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 70vh; 
  text-align: center;
}

.error-container { max-width: 600px; }

.error-code {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(6rem, 15vw, 10rem);
  line-height: 1;
  margin: 0;
  color: var(--border-light); 
  letter-spacing: -0.5rem;
}

.error-title {
  font-family: 'Oswald', sans-serif;
  font-size: 2rem;
  text-transform: uppercase;
  margin-top: -2rem; 
  margin-bottom: 1.5rem;
}

.error-message {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  line-height: 1.6;
}

.error-button {
  display: inline-block;
  background-color: var(--accent-blue);
  color: white !important;
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05rem;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.error-button:hover {
  background-color: var(--accent-blue-hover);
  transform: translateY(-2px);
}

/* ==========================================================================
   10. RESPONSIVE MEDIA QUERIES (CONSOLIDATED)
   ========================================================================== */

/* Large Tablets / Small Laptops */
@media (max-width: 1024px) {
  .about-grid-container {
    flex-direction: column;
    padding-top: 6rem;
  }
  .bio-columns {
    flex-direction: column;
    gap: 0;
  }
  .half-row {
    flex-direction: column;
  }
  .wide-card {
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    min-height: auto;
  }
  .card-hero {
    width: 100%;
    flex: 0 0 auto;
  }
  .card-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }
}

/* Standard Tablets */
@media (max-width: 900px) {
  .grid { grid-template-columns: 1fr; }
  .intro {
    flex-direction: column;
    align-items: flex-start;
  }
  .logo { height: 20px; }
  .case-study-content, .case-study-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .about-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .about-specs {
    border-left: none;
    padding-left: 0;
    border-top: 1px solid var(--border-light);
    padding-top: 3rem;
  }
}

/* Mobile Devices */
@media (max-width: 768px) {
  .menu-toggle { display: block; }
  
  .menu-toggle.is-active .bar:nth-child(2) { opacity: 0; }
  .menu-toggle.is-active .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-toggle.is-active .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .nav-menu {
    position: fixed;
    flex-direction: column;
    background-color: #fff;
    width: 100%;
    height: 100vh;
    top: 0;
    left: -100%; 
    text-align: center;
    transition: 0.3s;
    justify-content: center;
    padding-top: 80px;
  }
  .nav-menu.active { left: 0; }
  .nav-menu a {
    font-size: 2rem;
    margin: 1.5rem 0;
  }

  .grid{
    gap: 8rem;;
  }

  .project-info-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .info-sidebar {
    border-left: none;
    padding-left: 0;
  }
  .gallery-grid-2, .gallery-grid-3 {
    grid-template-columns: 1fr;
  }

  .footer-row {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 30px;
  }
  .col-cta { text-align: center; }

  .error-code { margin-bottom: 1rem; }
  .error-title { margin-top: 0; }
}