@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&display=swap');

:root {
  --bg-color: #121212;
  --brand-teal: #003333;
  --accent-teal: #00CCCC;
  --text-color: #F5F5F5;
  --card-bg: #1c1c1c;
  --glow: 0 0 30px rgba(0, 204, 204, 0.3);
}

body {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  overflow-x: hidden;
  line-height: 1.6;
}

/* =========================================
   1. GLOBAL NAVIGATION
   ========================================= */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(18, 18, 18, 0.85);
  backdrop-filter: blur(12px);
  z-index: 1000;
  box-sizing: border-box;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-logo { height: 64px; width: auto; }

.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; }
.hamburger span { width: 25px; height: 2px; background-color: var(--text-color); transition: all 0.3s ease; }

.nav-links { display: flex; gap: 2.5rem; }
.nav-links a {
  color: var(--text-color); text-decoration: none; font-size: 0.85rem;
  font-weight: 600; text-transform: uppercase; letter-spacing: 1px; transition: color 0.3s ease;
}
.nav-links a:hover { color: var(--accent-teal); }


/* =========================================
   2. HOME PAGE (INDEX.HTML)
   ========================================= */
.hero {
  position: relative;
  background: linear-gradient(135deg, rgba(0, 51, 51, 0.8) 0%, rgba(18, 18, 18, 0.9) 100%),
              url('https://i.imgur.com/ar1ZA0e.jpeg');
  background-size: cover; background-position: center; background-attachment: fixed;
  min-height: 100vh; display: flex; flex-direction: column; justify-content: center;
  align-items: flex-start; padding: 0 10%; box-sizing: border-box;
}
.hero-content { max-width: 800px; text-align: left; }
.hero h1 { font-size: clamp(2.5rem, 8vw, 5rem); margin-bottom: 1rem; line-height: 1.1; text-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.subtitle { font-size: 1.25rem; opacity: 0.8; border-left: 3px solid var(--accent-teal); padding-left: 20px; max-width: 600px; line-height: 1.6; }
.hero-name { font-weight: 700; color: #FFF; }
.scroll-indicator { margin-top: 3rem; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 2px; opacity: 0.6; }

.bifurcated-hub { 
  display: flex; 
  height: 50vh; /* Changed from 100vh to 50vh to make it half as tall */
  overflow: hidden; 
}
.split { 
  flex: 1; 
  display: flex; 
  justify-content: center; 
  align-items: center; 
  transition: all 0.5s ease; 
  background-color: var(--card-bg); 
  border: 1px solid rgba(255,255,255,0.05); 
  cursor: pointer; 
  
  /* NEW RULES: Overriding the default browser link styles */
  text-decoration: none; 
  color: var(--text-color); 
}
.bifurcated-hub:hover .split { opacity: 0.3; }
.bifurcated-hub .split:hover { opacity: 1; transform: scale(1.03); box-shadow: var(--glow); z-index: 10; }

.process-journey { padding: 5rem 10%; }
.section-header { margin-bottom: 3rem; }
.process-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.process-card { background: var(--card-bg); border-radius: 12px; overflow: hidden; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); border: 1px solid rgba(255,255,255,0.05); display: flex; flex-direction: column; }
.process-card:hover { transform: translateY(-10px); box-shadow: var(--glow); border-color: rgba(0, 204, 204, 0.3); }
.card-media { aspect-ratio: 16/9; background: #000; position: relative; }
.card-media img { width: 100%; height: 100%; object-fit: cover; opacity: 0.8; transition: opacity 0.3s ease; }
.process-card:hover .card-media img { opacity: 1; }
.card-body { padding: 1.5rem; flex-grow: 1; display: flex; flex-direction: column; }
.tag { color: var(--accent-teal); font-size: 0.8rem; font-weight: bold; text-transform: uppercase; margin-bottom: 0.5rem; }
.card-body h3 { margin: 0.5rem 0; font-size: 1.25rem; }
.card-link { margin-top: auto; color: var(--text-color); text-decoration: none; font-weight: bold; font-size: 0.9rem; transition: color 0.3s ease; padding-top: 1rem; }
.card-link:hover { color: var(--accent-teal); }


/* =========================================
   3. DESIGN GALLERY PAGE (GALLERY.HTML)
   ========================================= */
.index-header {
  padding: 15vh 5% 5vh 5%;
  max-width: 1200px;
  margin: 0 auto;
  background: radial-gradient(circle at top left, rgba(0, 51, 51, 0.4) 0%, transparent 70%);
}
.index-header h1 { font-size: clamp(2.5rem, 5vw, 4rem); margin-bottom: 1rem; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  grid-auto-rows: 350px; 
  gap: 1.5rem;
  padding: 0 5% 10vh 5%;
  max-width: 1400px;
  margin: 0 auto;
}
.gallery-item { position: relative; border-radius: 8px; overflow: hidden; display: block; background-color: var(--card-bg); border: 1px solid rgba(255, 255, 255, 0.05); }
.gallery-item.featured { grid-column: span 2; grid-row: span 2; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.gallery-item:hover img { transform: scale(1.05); }

.item-overlay { position: absolute; bottom: 0; left: 0; width: 100%; padding: 2rem; background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0) 100%); box-sizing: border-box; transform: translateY(20px); opacity: 0.9; transition: all 0.4s ease; }
.gallery-item:hover .item-overlay { transform: translateY(0); opacity: 1; }
.item-tag { color: var(--accent-teal); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 2px; font-weight: bold; display: block; margin-bottom: 0.5rem; }
.item-overlay h2 { margin: 0; color: #FFF; font-size: 1.5rem; }
.featured .item-overlay h2 { font-size: 2.5rem; }


/* =========================================
   4. CASE STUDY PAGE (DIA-COMIC.HTML)
   ========================================= */
.cs-hero { padding: 15vh 5% 5vh 5%; max-width: 1400px; margin: 0 auto; }
.cs-hero-text { max-width: 800px; margin-bottom: 3rem; }
.cs-tag { color: var(--accent-teal); font-weight: 700; text-transform: uppercase; letter-spacing: 2px; font-size: 0.85rem; }
.cs-hero h1 { font-size: clamp(3rem, 6vw, 5rem); margin: 1rem 0; line-height: 1.1; }
.cs-intro { font-size: 1.25rem; opacity: 0.8; border-left: 3px solid var(--accent-teal); padding-left: 1.5rem; }
.cs-hero-image img { width: 100%; border-radius: 12px; display: block; }

.cs-button { display: inline-block; margin-top: 2rem; padding: 1rem 2.5rem; background-color: var(--accent-teal); color: #000; text-decoration: none; font-weight: 700; border-radius: 4px; text-transform: uppercase; letter-spacing: 1px; transition: all 0.3s ease; }
.cs-button:hover { background-color: transparent; color: var(--accent-teal); border: 1px solid var(--accent-teal); transform: translateY(-3px); box-shadow: 0 10px 20px rgba(0, 204, 204, 0.2); }

.cs-meta { display: flex; justify-content: flex-start; gap: 4rem; padding: 3rem 5%; max-width: 1400px; margin: 0 auto; border-bottom: 1px solid rgba(255, 255, 255, 0.1); }
.meta-item h4 { color: var(--accent-teal); text-transform: uppercase; letter-spacing: 1px; font-size: 0.8rem; margin-bottom: 0.5rem; }
.meta-item p { margin: 0; font-weight: 600; }

.cs-narrative-block { padding: 6rem 5%; max-width: 1000px; margin: 0 auto; }
.cs-narrative-block h2 { font-size: 2.5rem; margin-bottom: 1.5rem; }
.cs-narrative-block p { font-size: 1.1rem; opacity: 0.85; margin-bottom: 1.5rem; }

.split-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; max-width: 1400px; }
.cs-image-column img { width: 100%; border-radius: 8px; }

.cs-media-break { padding: 2rem 5%; max-width: 1400px; margin: 0 auto; }
.cs-media-break img { width: 100%; border-radius: 8px; }

/* =========================================
   8. VISUAL DEV PAGE (VISDEV.HTML)
   ========================================= */
.cinematic-container {
  width: 100%;
  display: flex;
  flex-direction: column;
}

.cinematic-panel {
  min-height: 100vh; /* Forces each piece of art to take up the full screen */
  width: 100%;
  background-size: cover;
  background-position: center;
  background-attachment: fixed; /* THE MAGIC TRICK: This creates the parallax wipe effect */
  display: flex;
  align-items: flex-end; /* Pushes the text to the bottom */
  padding: 5rem 10%;
  box-sizing: border-box;
  position: relative;
}

.panel-info {
  max-width: 800px;
  z-index: 2;
  margin-bottom: 5vh;
}

.panel-info h2 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin: 0.5rem 0;
  text-shadow: 0 4px 20px rgba(0,0,0,0.8);
}

.panel-info p {
  font-size: 1.2rem;
  opacity: 0.9;
  text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}
/* =========================================
   5. GLOBAL FOOTER
   ========================================= */
.site-footer { padding: 6rem 10%; background-color: #0a0a0a; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 2.5rem; border-top: 1px solid rgba(255, 255, 255, 0.05); }
.site-footer h2 { font-size: clamp(2rem, 4vw, 3rem); margin: 0; }
.social-links { display: flex; gap: 1.5rem; flex-wrap: wrap; justify-content: center; }
.social-btn { padding: 1rem 2rem; border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 4px; color: var(--text-color); text-decoration: none; font-weight: bold; font-size: 0.9rem; transition: all 0.3s ease; }
.social-btn:hover { background-color: rgba(255, 255, 255, 0.05); border-color: var(--accent-teal); color: var(--accent-teal); }
.substack-btn { background-color: var(--accent-teal); color: #000; border-color: var(--accent-teal); }
.substack-btn:hover { background-color: transparent; color: var(--accent-teal); }
.copyright { opacity: 0.4; font-size: 0.8rem; margin-top: 2rem; }


/* =========================================
   6. ANIMATIONS
   ========================================= */
.fade-in { opacity: 0; transform: translateY(30px); transition: all 0.8s ease-out; }
.fade-in.visible { opacity: 1; transform: translateY(0); }


/* =========================================
   7. MOBILE RESPONSIVENESS (ALL PAGES)
   ========================================= */
@media (max-width: 768px) {
  /* Global Nav */
  .hamburger { display: flex; }
  .nav-links { position: absolute; top: 100%; left: 0; width: 100%; background: rgba(18, 18, 18, 0.95); backdrop-filter: blur(15px); flex-direction: column; padding: 2rem 0; gap: 2rem; opacity: 0; transform: translateY(-20px); pointer-events: none; transition: all 0.4s ease; text-align: center; }
  .nav-links.active { opacity: 1; transform: translateY(0); pointer-events: all; }

  /* Home Page */
  .hero { padding: 15vh 5% 5vh 5%; align-items: center; text-align: center; }
  .hero-content { text-align: center; }
  .subtitle { border-left: none; border-top: 3px solid var(--accent-teal); padding-left: 0; padding-top: 20px; margin: 0 auto; }
  .bifurcated-hub { flex-direction: column; height: auto; }
  .split { height: 70vh; width: 100%; }
  .process-grid { grid-template-columns: 1fr; gap: 1.5rem; }

  /* Gallery Page */
  .gallery-grid { grid-template-columns: 1fr; grid-auto-rows: 300px; }
  .gallery-item.featured { grid-column: span 1; grid-row: span 1; }

  /* Case Study Page */
  .cs-meta { flex-direction: column; gap: 1.5rem; }
  .split-layout { grid-template-columns: 1fr; }

  /* Footer */
  .social-links { flex-direction: column; width: 100%; max-width: 300px; }
}
/* Hamburger 'X' Animation */
  .hamburger.toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  
  .hamburger.toggle span:nth-child(2) {
    opacity: 0; /* Hides the middle line */
  }
  
  .hamburger.toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }
  /* =========================================
   9. BLOG & CONTACT PAGES
   ========================================= */

/* Blog Layout */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  padding: 0 5% 10vh 5%;
  max-width: 1200px;
  margin: 0 auto;
}

.blog-card {
  background-color: var(--card-bg);
  padding: 2.5rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--glow);
  border-color: rgba(0, 204, 204, 0.3);
}

.blog-card h2 {
  font-size: 1.5rem;
  margin: 0.5rem 0 1rem 0;
  line-height: 1.3;
}

.blog-card p {
  opacity: 0.8;
  margin-bottom: 2rem;
  flex-grow: 1;
}

/* Contact Form Layout */
.contact-container {
  padding: 0 5% 10vh 5%;
  max-width: 800px;
  margin: 0 auto;
}

.contact-form {
  background-color: var(--card-bg);
  padding: 3rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.form-group {
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--accent-teal);
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 1px;
}

.form-group input,
.form-group textarea {
  background-color: #121212;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  padding: 1rem;
  color: var(--text-color);
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-teal);
}
/* =========================================
   BLOG CARD REFINEMENT (INTERACTIVE GLOW)
   ========================================= */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  padding: 2rem 5%;
}

.blog-card {
  background-color: var(--card-bg);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%; /* Keeps all cards in a row the same height */
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  text-decoration: none;
  color: var(--text-color);
}

/* The "Cropped" Image Container */
.card-media {
  width: 100%;
  height: 200px;
  overflow: hidden;
  background-color: #1a1a1a; /* Fallback color */
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover; 
  transition: transform 0.6s ease;
}

/* The Content Area */
.card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1; /* Fills the vertical space */
}

.blog-card h2 {
  font-size: 1.4rem;
  margin: 0.5rem 0 1rem 0;
  line-height: 1.3;
  /* Line Clamping for Titles */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card p {
  font-size: 0.95rem;
  opacity: 0.7;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

/* The Link/Button */
.card-link {
  margin-top: auto; /* Pushes button to the very bottom */
  color: var(--accent-teal);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 1px;
}

/* THE INTERACTIVE GLOW EFFECTS */
.blog-card:hover {
  transform: translateY(-10px);
  border-color: var(--accent-teal);
  box-shadow: 0