/* Base Environment */
body, html {
  margin: 0;
  padding: 0;
  width: 100%;
  background-color: #05060A;
  background-image: radial-gradient(circle at 50% 50%, #110B1F 0%, #030408 100%);
  color: #E0E7FF;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

/* Holographic Data Sweep Animation */
.cyber-sweep {
  width: 100%;
  display: block;
  text-align: center;
  background: linear-gradient(
    to right,
    #E0E7FF 20%,   
    #00e5ff 40%,   
    #ff00ff 60%,   
    #E0E7FF 80%    
  );
  background-size: 200% auto;
  color: transparent !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  animation: text-sweep 4s linear infinite;
  filter: drop-shadow(0px 2px 5px rgba(0, 0, 0, 0.9)) drop-shadow(0px 0px 8px rgba(0, 229, 255, 0.3));
}

@keyframes text-sweep {
  to {
    background-position: 200% center;
  }
}

/* Global Navigation (Centered Glassmorphism) */
#global-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 70px;
  display: flex;
  justify-content: center; /* Centered menu items */
  align-items: center;
  background: rgba(5, 6, 10, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(140, 158, 255, 0.05);
  z-index: 1000;
}

.nav-links {
  display: flex;
  gap: 40px;
}

.nav-links a {
  text-decoration: none;
  color: #8c9eff; /* Dimmer default state */
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: all 0.3s ease;
}

.nav-links a:hover, .nav-links a.active {
  color: #fff;
  text-shadow: 0 0 10px rgba(140, 158, 255, 0.4);
}

.logo-container {
  width: 100vw;       
  max-width: 100%;    
  height: auto;       /* Swapped from 69vh to auto */
  padding: 0;         
  margin-bottom: 2rem;
  box-sizing: border-box;
  overflow: hidden;   /* Keep this clean to prevent horizontal scrolling */
}


.hero-video {
  width: 100%;
  height: auto;       
  display: block;     
  border-radius: 0;   
  box-shadow: 0 5px 30px rgba(0, 229, 255, 0.1); 
  pointer-events: none;
}

.product-container {
  width: 100%;
  max-width: 600px; /* Tighter layout for the App page */
  padding: 20px;
  box-sizing: border-box;
}

.hero-video, .product-video {
  width: 100%;
  height: auto;
  border-radius: 12px;
  pointer-events: none;
}

.hero-video { box-shadow: 0 0 50px rgba(0, 229, 255, 0.1); }
.product-video { box-shadow: 0 0 60px rgba(140, 158, 255, 0.15); }



/* Typography & Layout */
.enterprise-tagline {
  margin-top: 1rem;
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: 2px;
  color: #A5B4FC;
  text-align: center;
}

.visually-hidden { display: none; }

/* --- FULL-WIDTH Z-PATTERN SHOWCASE --- */
.showcase-section {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 0 8rem 0;
}

.showcase-block {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1300px;
  margin: 0 auto 120px auto; 
  padding: 0 5%;
  gap: 80px; 
}

/* Flips the layout for the Z-Pattern */
.showcase-block.reverse {
  flex-direction: row-reverse;
}

.showcase-text {
  flex: 1;
}

.showcase-media {
  flex: 1.2; 
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Universal Video Styling */
.showcase-media video {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 0 50px rgba(0, 229, 255, 0.1);
  background: #030408;
}

/* Specific lock for the vertical mobile video so it doesn't balloon */
.vertical-media video {
  max-width: 400px;
}

/* Cinematic Typography */
.showcase-text h3 {
  color: #a5b4fc;
  font-size: 1.8rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  margin-top: 0;
  margin-bottom: 25px;
  text-transform: uppercase;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

/* Hover effects tied to the entire block to make it feel responsive */
.showcase-block:hover .showcase-text h3 {
  color: #ffffff;
  text-shadow: 0 0 10px rgba(0, 229, 255, 0.8), 0 0 20px rgba(255, 0, 255, 0.4);
}

.showcase-text p {
  color: #8c9eff;
  font-size: 1.15rem; 
  line-height: 1.8;
  margin: 0;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.showcase-block:hover .showcase-text p {
  opacity: 1;
}

/* UI Render Start */
/* Mobile Stacking & Typography Fix (Breaks the Z-pattern & stops text bleed) */
@media (max-width: 1024px) {
  /* 1. Stacks the Z-pattern cleanly */
  .showcase-block, 
  .showcase-block.reverse {
    flex-direction: column;
    text-align: center;
    gap: 40px;
    margin-bottom: 80px;
    width: 100% !important;
    max-width: 100vw !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
    box-sizing: border-box !important;
  }

  /* 2. Stops layout containers from pushing off the screen */
  .showcase-text, 
  .product-container,
  .dossier-section {
    width: 100% !important;
    max-width: 100vw !important;
    box-sizing: border-box !important;
    overflow-x: hidden; 
  }

  /* 3. The Physical Wall: Forces paragraphs to wrap and not get chopped */
  .showcase-text p, 
  .ethos-card p,
  .lab-entry p {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important; 
    overflow-wrap: break-word !important; 
    padding-right: 10px !important; 
  }

  /* 4. Scales down massive titles so they fit on the glass */
  .enterprise-tagline {
    font-size: 1.8rem !important; 
    letter-spacing: 2px !important; 
    overflow-wrap: break-word; 
    padding: 0 15px;
    box-sizing: border-box;
  }

  .hero-tagline {
    font-size: 2rem !important;
    letter-spacing: 3px !important;
    overflow-wrap: break-word;
    padding: 0 15px;
    box-sizing: border-box;
  }
  
  .showcase-text h3 {
    font-size: 1.4rem !important;
    letter-spacing: 1px !important;
    overflow-wrap: break-word;
  }
}
/* UI Render Block End */

/* The Animated Circuit Trace (Hidden on Standby) */
.ethos-card::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(
    transparent, 
    rgba(0, 229, 255, 0.2) 30%, 
    rgba(0, 229, 255, 1) 50%, 
    rgba(255, 0, 255, 1) 70%, 
    transparent 100%
  );
  animation: circuit-trace 2s linear infinite;
  opacity: 0; 
  transition: opacity 0.3s ease;
  z-index: -2;
}

/* The Inner Mask (Activates on Hover) */
.ethos-card::after {
  content: "";
  position: absolute;
  inset: 1px; /* The thickness of the neon border */
  background: rgba(5, 6, 10, 0.95);
  border-radius: 8px;
  z-index: -1;
  opacity: 0; 
  transition: opacity 0.3s ease;
}

@keyframes circuit-trace {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Hover State - Wakes up the card */
.ethos-card:hover {
  transform: translateY(-2px);
  box-shadow: none; /* Removes static border to let neon trace shine */
}

.ethos-card:hover::before,
.ethos-card:hover::after {
  opacity: 1; /* Ignites the trace and mask */
}

/* Holographic Typography */
.ethos-card h3 {
  color: #a5b4fc; /* Dimmer, professional default text */
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  margin-top: 0;
  margin-bottom: 15px;
  text-transform: uppercase;
  text-shadow: none;
  transition: color 0.3s ease, text-shadow 0.3s ease;
  z-index: 2; 
}

.ethos-card:hover h3 {
  color: #ffffff;
  text-shadow: 
    0 0 8px rgba(0, 229, 255, 1), 
    0 0 25px rgba(255, 0, 255, 0.6); /* Projects forward on hover */
}

.ethos-card p {
  color: #8c9eff;
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0;
  position: relative;
  z-index: 2;
  opacity: 0.7; /* Subdued reading text */
  transition: opacity 0.3s ease;
}

.ethos-card:hover p {
  opacity: 1; /* Brightens up for readability */
}

/* MirrorThought Hero Render Start */
#mirrorthought-hero {
  width: 100%;
  position: relative;
  background: #030408;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.mirrorthought-banner {
  width: 100%;
  height: 69vh; /* Increased from 55vh to match the company page scale */
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid rgba(0, 229, 255, 0.2);
}

.mirrorthought-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.9; 
}

.enterprise-tagline {
  margin-top: 2.5rem;
  margin-bottom: 1.5rem;
  color: #E0E7FF;
  font-size: 2.5rem; /* This is the scale you are looking for */
  font-weight: 300;
  letter-spacing: 4px;
  text-transform: uppercase;
  text-shadow: 0 0 10px rgba(0, 229, 255, 0.4);
  text-align: center;
  z-index: 2;
}
/* Supersized Tagline for the Company Hero */
.hero-tagline {
  margin-top: 3rem;       
  margin-bottom: 2rem;
  color: #E0E7FF;
  font-size: 3vw;         /* Scales fluidly with the massive logo */
  font-weight: 300;
  letter-spacing: 6px;    
  text-transform: uppercase;
  text-shadow: 0 0 15px rgba(0, 229, 255, 0.5); 
  text-align: center;
  z-index: 2;
}

/* Fallback for smaller screens to ensure it remains legible */
@media (max-width: 768px) {
  .hero-tagline {
    font-size: 1.8rem; 
    letter-spacing: 4px;
  }
} /* <--- MAKE SURE THIS BRACE EXISTS AND IS CLOSED */

/* --- THE LAB: ENCRYPTED DOSSIER --- */
.lab-hero {
  margin-top: 120px;
  text-align: center;
  padding: 2rem 0;
}

.lab-hero .hero-tagline {
  margin-bottom: 0.5rem;
}

.lab-hero .enterprise-tagline {
  margin-top: 0;
  font-size: 1.1rem;
  opacity: 0.8;
}

.dossier-section {
  max-width: 900px;
  margin: 0 auto 100px auto;
  padding: 0 2rem;
  box-sizing: border-box; /* Added to enforce padding strictly */
}

/* Tab Controls (The Interface) */
.dossier-controls {
  display: flex;
  justify-content: center;
  gap: 20px;
  border-bottom: 1px solid rgba(0, 229, 255, 0.2);
  padding-bottom: 15px;
  margin-bottom: 30px;
}

.tab-btn {
  background: transparent;
  color: #8c9eff;
  border: none;
  font-family: monospace;
  font-size: 0.95rem;
  letter-spacing: 2px;
  cursor: pointer;
  padding: 10px 20px;
  transition: all 0.3s ease;
  position: relative;
}

.tab-btn:hover {
  color: #00e5ff;
  text-shadow: 0 0 10px rgba(0, 229, 255, 0.4);
}

.tab-btn.active {
  color: #ffffff;
  text-shadow: 0 0 12px rgba(0, 229, 255, 0.8);
}

.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -16px; 
  left: 0;
  width: 100%;
  height: 2px;
  background: #00e5ff;
  box-shadow: 0 0 10px #00e5ff;
}

/* The Content Vault */
.dossier-vault {
  background: rgba(5, 6, 10, 0.6);
  border: 1px solid rgba(140, 158, 255, 0.05);
  border-radius: 8px;
  padding: 40px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  min-height: 400px;
}

.dossier-panel {
  display: none;
  animation: fadeIn 0.4s ease-in-out;
}

.dossier-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Individual Log Entries */
.lab-entry {
  margin-bottom: 40px;
  padding-bottom: 30px;
  border-bottom: 1px dashed rgba(140, 158, 255, 0.1);
}

.lab-entry:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.lab-meta {
  font-family: monospace;
  color: #ff00ff;
  font-size: 0.85rem;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.lab-title {
  color: #E0E7FF;
  font-size: 1.4rem;
  font-weight: 500;
  margin: 0 0 15px 0;
  letter-spacing: 1px;
}

.lab-entry p {
  color: #8c9eff;
  line-height: 1.7;
  font-size: 1rem;
  margin: 0;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
  .dossier-controls {
    flex-direction: column;
    align-items: center;
    gap: 15px;
  }
  .tab-btn.active::after {
    display: none; 
  }
  .dossier-vault {
    padding: 20px;
  }
}

/* MirrorThought Hero Render Block End */

/* --- CORPORATE ARCHITECTURE CARDS (company.html) --- */
.ethos-section {
  padding: 4rem 2rem 8rem 2rem;
  display: flex;
  justify-content: center;
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
  width: 100%;
  max-width: 1100px;
}

/* Cyberpunk Card Architecture (Standby State) */
.ethos-card {
  position: relative;
  background: #030408; 
  padding: 30px;
  border-radius: 8px;
  text-align: left;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  z-index: 1;
  transition: transform 0.3s ease;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}

/* The Animated Circuit Trace */
.ethos-card::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(
    transparent, 
    rgba(0, 229, 255, 0.2) 30%, 
    rgba(0, 229, 255, 1) 50%, 
    rgba(255, 0, 255, 1) 70%, 
    transparent 100%
  );
  animation: circuit-trace 2s linear infinite;
  opacity: 0; 
  transition: opacity 0.3s ease;
  z-index: -2;
}

/* The Inner Mask */
.ethos-card::after {
  content: "";
  position: absolute;
  inset: 1px;
  background: rgba(5, 6, 10, 0.95);
  border-radius: 8px;
  z-index: -1;
  opacity: 0; 
  transition: opacity 0.3s ease;
}

@keyframes circuit-trace {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Hover State */
.ethos-card:hover {
  transform: translateY(-2px);
  box-shadow: none; 
}

.ethos-card:hover::before,
.ethos-card:hover::after {
  opacity: 1; 
}

/* Holographic Typography */
.ethos-card h3 {
  color: #a5b4fc; 
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  margin-top: 0;
  margin-bottom: 15px;
  text-transform: uppercase;
  text-shadow: none;
  transition: color 0.3s ease, text-shadow 0.3s ease;
  z-index: 2; 
}

.ethos-card:hover h3 {
  color: #ffffff;
  text-shadow: 
    0 0 8px rgba(0, 229, 255, 1), 
    0 0 25px rgba(255, 0, 255, 0.6);
}

.ethos-card p {
  color: #8c9eff;
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0;
  position: relative;
  z-index: 2;
  opacity: 0.7; 
  transition: opacity 0.3s ease;
}

.ethos-card:hover p {
  opacity: 1; 
}

/* Corporate Footer */
#corporate-footer {
  width: 100vw;
  padding: 3rem 0;
  border-top: 1px solid rgba(140, 158, 255, 0.1);
  background-color: #030408;
  display: flex;
  justify-content: center;
  text-align: center;
}

.footer-content p {
  margin: 5px 0;
  font-size: 0.85rem;
  color: #6366F1;
}

.footer-content .address {
  font-size: 0.75rem;
  color: #4F46E5;
}

/* --- IN-VIDEO AUDIO TOGGLE --- */
.cyber-audio-btn {
  position: absolute;
  bottom: 20px;
  right: 20px;
  background: rgba(5, 6, 10, 0.7); /* Semi-transparent base */
  color: #00e5ff;
  border: 1px solid rgba(0, 229, 255, 0.3);
  border-radius: 4px;
  padding: 8px 16px;
  font-family: monospace;
  font-size: 0.85rem;
  letter-spacing: 1.5px;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px); /* The frosted glass effect */
  -webkit-backdrop-filter: blur(4px); /* Safari support */
  z-index: 10;
}

.cyber-audio-btn:hover {
  background: rgba(0, 229, 255, 0.1);
  border-color: #00e5ff;
  box-shadow: 0 0 10px rgba(0, 229, 255, 0.5);
  color: #ffffff;
}

.showcase-text, .showcase-media {
  flex: 1;
  min-width: 45%; /* Forces the text and video to take up equal space */
}

.showcase-media video {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Forces the smaller video to stretch and fill that 45% space */
  border-radius: 8px;
}

/* --- VERTICAL VIDEO SIZING FIX --- */
.showcase-block .showcase-media.vertical-media {
  flex: 0 0 auto !important; /* Stops the container from expanding */
  width: 320px !important; /* Locks it to a sleek phone width */
  margin: 0 auto; /* Centers the whole block */
}

.showcase-block .showcase-media.vertical-media video {
  width: 100% !important;
  height: auto !important;
}

/* Pushes the first showcase block down to create breathing room under the header */
.showcase-block:first-of-type {
  margin-top: 95px; 
}

/* --- THE LAB: CINEMATIC PROLOGUE --- */
#lab-prologue {
  width: 100vw;
  height: 100vh; /* Locks the video to fill the exact height of the user's screen */
  position: relative;
  overflow: hidden;
  margin: 0;
  padding: 0;
}

.lab-prologue-video {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensures the video fills the screen without stretching or distorting */
  display: block;
}

/* --- THE LAB: TITLE SECTION (Below the fold) --- */
.lab-title-section {
  text-align: center;
  padding: 6rem 2rem 2rem 2rem; /* Creates a massive, clean drop from the video to the text */
  background-color: transparent;
}

.lab-title-section .hero-tagline {
  margin-bottom: 0.5rem;
  margin-top: 0;
}

.lab-title-section .enterprise-tagline {
  margin-top: 0;
  font-size: 1.1rem;
  opacity: 0.8;
}


/* UI Render Start */
/* Hide the prompt by default on desktops and landscape screens */
#landscape-prompt {
  display: none;
}

@media screen and (max-width: 768px) and (orientation: portrait) {
  #landscape-prompt {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(5, 5, 5, 0.85); /* Dark frosted glass */
    backdrop-filter: blur(8px); /* Blurs the app in the background */
    -webkit-backdrop-filter: blur(8px); /* Safari support */
    z-index: 9999;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #00ffcc; /* Matches your neon aesthetic */
    font-family: monospace;
  }

  /* The physical phone shape */
  .phone-icon {
    width: 40px;
    height: 70px;
    border: 3px solid #00ffcc;
    border-radius: 6px;
    margin-bottom: 20px;
    position: relative;
    animation: tilt 2s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(0, 255, 204, 0.5); /* Neon glow */
  }

  /* The screen inside the phone */
  .phone-icon::after {
    content: '';
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    background-color: rgba(0, 255, 204, 0.2);
    border-radius: 2px;
  }

  .prompt-content h2 {
    margin: 0 0 10px 0;
    font-size: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 8px rgba(0, 255, 204, 0.6);
  }

  .prompt-content p {
    font-size: 1rem;
    color: #cccccc;
    max-width: 80%;
    margin: 0 auto;
  }

  /* Keyframe for phone rotating 90 degrees */
  @keyframes tilt {
    0% { transform: rotate(0deg); }
    40% { transform: rotate(-90deg); }
    60% { transform: rotate(-90deg); }
    100% { transform: rotate(0deg); }
  }
}
/* UI Render Block End */