@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@600;700;800&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

/* Import Footer Styles */
@import 'footer.css';

:root {
  --bg-pure: #000000;
  --bg-soft: #000000;
  --text-main: #FFFFFF;
  --text-dim: rgba(255, 255, 255, 0.6);
  --accent-silver: #E5E4E2;
  --accent-slate: #666666;
  --font-main: 'Inter', sans-serif;
  --font-heading: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --header-border: rgba(255, 255, 255, 0.05);
  --radius-swiss: 2px;
}

/* Global Hero Label Token */
.hero-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
  display: block;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.8s ease-out;
}

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

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  background: #FFFFFF;
  color: var(--text-main);
  overflow-x: hidden;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Page Loader System */
.page-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  /* Precision thin line */
  background: transparent;
  z-index: 31000;
  /* Absolute top */
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.page-loader.active {
  opacity: 1;
}

.loader-progress {
  height: 100%;
  width: 0;
  background: #000000;
  /* High contrast precision line */
  transition: width 1.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-loader.active .loader-progress {
  width: 80%;
  /* Smooth organic crawl */
}

.page-loader.complete .loader-progress {
  width: 100% !important;
  transition: width 0.4s ease-out !important;
}

.loader-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.5em;
  color: #000000;
  text-transform: uppercase;
  font-weight: 500;
  opacity: 0.8;
}

@keyframes monolith-organic-spin {
  0% {
    transform: rotate(0deg) scale(1);
  }

  50% {
    transform: rotate(180deg) scale(0.9);
  }

  100% {
    transform: rotate(360deg) scale(1);
  }
}

@keyframes monolith-breathe {

  0%,
  100% {
    transform: scale(1);
    opacity: 0.05;
  }

  50% {
    transform: scale(1.15);
    opacity: 0.2;
  }
}

@keyframes monolith-core-flicker {

  0%,
  100% {
    opacity: 0.2;
    transform: scale(0.8);
  }

  33% {
    opacity: 0.8;
    transform: scale(1.2);
  }

  66% {
    opacity: 0.4;
    transform: scale(1);
  }
}

.loader-progress {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #E8E8E8 0%, #000000 100%);
  transition: width 0.4s cubic-bezier(0.1, 0.7, 0.1, 1);
}

.page-loader.active .loader-progress {
  width: 70%;
  /* Initial jump to 70% */
}

.page-loader.complete .loader-progress {
  width: 100% !important;
}

/* Noise/Grain Overlay (Subtle) */
.noise-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 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");
  opacity: 0.03;
  /* Kept for overlay texture, but very subtle */
  pointer-events: none;
  z-index: 9999;
}

/* =========================================
   HEADER - Institutional Navigation System
   ========================================= */
.aideniti-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 72px;
  display: flex;
  align-items: center;
  z-index: 20000;
  background: #FFFFFF;
  border-bottom: 1px solid #E8E8E8;
  transition: background 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.aideniti-nav.scrolled {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  border-bottom-color: #E0E0E0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.nav-container {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 4%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.nav-logo {
  flex-shrink: 0;
}

.nav-logo img {
  height: 50px;
  transition: opacity 0.3s ease;
}

.nav-logo:hover img {
  opacity: 0.8;
}

/* Desktop Navigation Links - Left Aligned */
.nav-links {
  list-style: none;
  display: flex;
  gap: 32px;
  align-items: center;
  margin: 0;
  margin-left: 64px;
  margin-right: auto;
  padding: 0;
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-links a {
  color: #666666;
  font-family: var(--font-main);
  font-size: 15px;
  font-weight: 500;
  text-transform: none;
  text-decoration: none;
  letter-spacing: -0.015em;
  transition: color 0.3s ease;
  position: relative;
  padding-bottom: 4px;
  display: inline-flex;
  align-items: center;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: #1A1A1A;
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-links a:hover {
  color: #1A1A1A;
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-links a.active {
  color: #1A1A1A;
}

.nav-links a.active::after {
  width: 100%;
}

/* Right Side Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}

.btn-header-cta {
  background: #1A1A1A;
  color: #FFFFFF;
  border: none;
  padding: 12px 32px;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 800;
  /* Heavy Bold */
  text-transform: uppercase;
  letter-spacing: 0.12em;
  border-radius: 0;
  /* Sharp Corners */
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-header-cta:hover {
  background: #333333;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

/* =========================================
   HAMBURGER ICON - From Scratch
   ========================================= */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  position: relative;
  z-index: 20005;
  outline: none;
}

.hamburger-line {
  display: block;
  width: 26px;
  height: 2.5px;
  background: #000000;
  /* Absolute black for maximum contrast */
  border-radius: 2px;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
  transform-origin: center;
  pointer-events: none;
}

.nav-hamburger.active .hamburger-line:first-child {
  transform: translateY(4.25px) rotate(45deg);
}

.nav-hamburger.active .hamburger-line:last-child {
  transform: translateY(-4.25px) rotate(-45deg);
}

/* =========================================
   MOBILE DRAWER - From Scratch
   Appended directly to <body> by JS
   ========================================= */
.mobile-drawer {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100vh !important;
  height: 100dvh !important;
  background: #FFFFFF;
  z-index: 30000 !important;
  display: flex !important;
  flex-direction: column;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0s linear 0.4s;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.mobile-drawer.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.4s ease, visibility 0s linear 0s;
}

/* Close button inside the drawer */
/* Close button inside the drawer - High Visibility */
.drawer-close-btn {
  position: fixed !important;
  top: 16px;
  right: 16px;
  width: 48px;
  height: 48px;
  display: flex !important;
  align-items: center;
  justify-content: center;
  background: #F8F8F8;
  /* Subtle off-white background for definition */
  border: 1px solid #EEEEEE;
  cursor: pointer;
  z-index: 30001 !important;
  padding: 0;
  border-radius: 50%;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  -webkit-tap-highlight-color: transparent;
}

.drawer-close-btn:hover {
  background: #EEEEEE;
  transform: rotate(90deg) scale(1.05);
}

.drawer-close-btn svg {
  pointer-events: none;
}

.drawer-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 32px;
  padding: 100px 24px 60px;
  text-align: center;
  min-height: min-content;
}

.drawer-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.drawer-link {
  display: flex;
  align-items: center;
  gap: 20px;
  text-decoration: none;
  padding: 16px 0;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease, color 0.3s ease;
}

.mobile-drawer.open .drawer-link {
  opacity: 1;
  transform: translateY(0);
}

.mobile-drawer.open .drawer-link:nth-child(1) {
  transition-delay: 0.3s;
}

.mobile-drawer.open .drawer-link:nth-child(2) {
  transition-delay: 0.35s;
}

.mobile-drawer.open .drawer-link:nth-child(3) {
  transition-delay: 0.4s;
}

.mobile-drawer.open .drawer-link:nth-child(4) {
  transition-delay: 0.45s;
}

.mobile-drawer.open .drawer-link:nth-child(5) {
  transition-delay: 0.5s;
}

.mobile-drawer.open .drawer-link:nth-child(6) {
  transition-delay: 0.55s;
}

.mobile-drawer.open .drawer-link:nth-child(7) {
  transition-delay: 0.6s;
}

.mobile-drawer.open .drawer-link:nth-child(8) {
  transition-delay: 0.65s;
}

.mobile-drawer.open .drawer-link:nth-child(9) {
  transition-delay: 0.7s;
}

.mobile-drawer.open .drawer-link:nth-child(10) {
  transition-delay: 0.75s;
}

.drawer-divider {
  width: 40px;
  height: 1px;
  background: #EEEEEE;
  margin: 16px auto;
}

.drawer-link.secondary .drawer-link-text {
  font-size: 1.25rem;
  font-weight: 600;
  color: #888888;
}

.drawer-link-number {
  font-family: var(--font-mono);
  font-size: 11px;
  color: #888888;
  letter-spacing: 0.1em;
  min-width: 28px;
  text-align: right;
}

.drawer-link-text {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  color: #666666;
  /* Darker for accessibility */
  letter-spacing: -0.02em;
  transition: color 0.3s ease;
}

.drawer-link:hover .drawer-link-text {
  color: #1A1A1A;
}

.drawer-link.active .drawer-link-text {
  color: #1A1A1A;
}

.drawer-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease 0.3s, transform 0.5s ease 0.3s;
}

.mobile-drawer.open .drawer-footer {
  opacity: 1;
  transform: translateY(0);
}

.drawer-email {
  font-family: var(--font-mono);
  font-size: 12px;
  color: #888888;
  text-decoration: none;
  letter-spacing: 0.05em;
  transition: color 0.3s ease;
}

.drawer-email:hover {
  color: #1A1A1A;
}

.btn-drawer-cta {
  background: #1A1A1A;
  color: #FFFFFF;
  border: none;
  padding: 16px 40px;
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-drawer-cta:hover {
  background: #333333;
  transform: translateY(-2px);
}

.btn-drawer-cta .arrow {
  transition: transform 0.3s ease;
}

.btn-drawer-cta:hover .arrow {
  transform: translateX(6px);
}

/* Prevent scroll when drawer open */
body.drawer-open {
  overflow: hidden !important;
}

/* Hide hamburger X when drawer is open - drawer has its own close button */
body.drawer-open .nav-hamburger {
  display: none !important;
}

/* =========================================
   FULL-WIDTH MEGA PANELS
   ========================================= */
.nav-chevron {
  margin-left: 5px;
  opacity: 0.4;
  transition: transform 0.3s ease, opacity 0.3s ease;
  vertical-align: middle;
}

.nav-item.has-dropdown:hover .nav-chevron,
.nav-item.has-dropdown.active .nav-chevron {
  transform: rotate(180deg);
  opacity: 1;
}

.mega-panel {
  position: fixed;
  top: 72px;
  left: 0;
  width: 100%;
  background: #FFFFFF;
  border-bottom: 1px solid #E8E8E8;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
  z-index: 998;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.25s ease;
}

.mega-panel.open {
  max-height: 520px;
  opacity: 1;
}

.mega-panel-inner {
  max-width: 1600px;
  margin: 0 auto;
  padding: 40px 4% 44px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 64px;
}

.mega-col {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mega-col:not(:last-child) {
  border-right: 1px solid #F0F0F0;
  padding-right: 32px;
}

.mega-col-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: #AAAAAA;
  font-weight: 600;
  margin-bottom: 20px;
  display: block;
}

.mega-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.15s ease;
}

.mega-link:hover {
  background: #F5F5F5;
}

.mega-link-title {
  font-family: var(--font-main);
  font-size: 15px;
  font-weight: 600;
  color: #1A1A1A;
  transition: color 0.15s ease;
}

.mega-link:hover .mega-link-title {
  color: #000000;
}

.mega-link-desc {
  font-family: var(--font-main);
  font-size: 13px;
  color: #888888;
  line-height: 1.6;
}

/* Featured Column */
.mega-col-feature {
  background: #F8F8F8;
  border-radius: 10px;
  padding: 24px;
  gap: 8px;
}

.mega-col-feature .mega-col-label {
  margin-bottom: 12px;
}

.mega-feature-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-decoration: none;
  padding: 16px;
  border-radius: 8px;
  transition: background 0.15s ease;
}

.mega-feature-card:hover {
  background: #EFEFEF;
}

.mega-feature-tag {
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #AAAAAA;
}

.mega-feature-card.static {
  cursor: default;
}

.mega-feature-card.static:hover {
  background: transparent;
}

.mega-feature-title {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 700;
  color: #1A1A1A;
}

.mega-feature-desc {
  font-family: var(--font-main);
  font-size: 13px;
  color: #888888;
  line-height: 1.5;
}

.mega-feature-cta {
  font-family: var(--font-main);
  font-size: 12px;
  font-weight: 600;
  color: #888888;
  margin-top: 4px;
  transition: color 0.15s ease;
}

.mega-feature-card:hover .mega-feature-cta {
  color: #1A1A1A;
}

/* Contact Block in Company Panel */
.mega-contact-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
}

.mega-email {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 600;
  color: #1A1A1A;
  text-decoration: none;
  transition: color 0.15s ease;
}

.mega-email:hover {
  color: #000000;
}

.mega-contact-note {
  font-family: var(--font-main);
  font-size: 13px;
  color: #888888;
}

/* Overlay behind mega panel */
.mega-overlay {
  position: fixed;
  top: 72px;
  left: 0;
  width: 100%;
  height: 100vh;
  background: transparent;
  z-index: 997;
  display: none;
}

.mega-overlay.active {
  display: block;
}

/* =========================================
   RESPONSIVE - Header Breakpoints
   ========================================= */
@media (max-width: 1024px) {
  .nav-links {
    display: none;
  }

  .btn-header-cta {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }

  .mega-panel {
    display: none !important;
  }

  .nav-container {
    height: 100%;
  }
}

@media (max-width: 600px) {
  .aideniti-nav {
    height: 64px;
  }

  .nav-logo img {
    height: 32px;
  }

  .drawer-link-text {
    font-size: 2rem;
  }
}

/* Hero Section */
.hero-section {
  position: relative;
  height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 60px;
  overflow: hidden;
  background-color: #FFFFFF;
}

/* Ambient Atmosphere - Sculpted Centered Lighting */
.hero-section::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, rgba(212, 175, 55, 0.05) 0%, rgba(255, 255, 255, 0) 70%);
  transform: translate(-50%, -50%);
  z-index: 1;
  filter: blur(100px);
  pointer-events: none;
}

.hero-section::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 50% 50%, rgba(15, 23, 42, 0.04) 0%, rgba(255, 255, 255, 0) 60%),
    radial-gradient(circle at 50% 10%, rgba(212, 175, 55, 0.02) 0%, rgba(255, 255, 255, 0) 30%);
  z-index: 1;
  pointer-events: none;
}

.background-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.hero-center-container {
  width: 100%;
  max-width: 1600px;
  height: 100%;
  margin: 0 auto;
  padding: 0 4%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  z-index: 10;
}

.hero-content {
  max-width: 1200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 80px;
}

.hero-eyebrow {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
}

/* Editorial Elite Typography */
.hero-headline {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 8vw, 7.5rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.05em;
  word-spacing: 0.05em;
  margin-bottom: 40px;
  color: #000000;
  text-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
  white-space: nowrap;
  min-height: 1.1em;
}

.typed-text {
  display: inline;
}

.cursor {
  display: inline-block;
  width: 5px;
  height: 0.85em;
  background-color: #000000;
  margin-left: 6px;
  vertical-align: middle;
  animation: blink 0.8s infinite;
  transition: opacity 0.5s ease;
}

@keyframes blink {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

/* Typewriter active states handled by JS */

/* Core Hero Typography Tokens */
.hero-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
  display: block;
  opacity: 0;
  transform: translateY(10px);
  transition: all 1s cubic-bezier(0.16, 1, 0.3, 1) 0.1s;
}

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

.hero-title-universal {
  font-family: var(--font-heading);
  font-size: clamp(2.8rem, 6.5vw, 5rem);
  font-weight: 800;
  color: #000000;
  line-height: 1.05;
  margin-bottom: 28px !important;
  letter-spacing: -0.04em;
  opacity: 0;
  transform: translateY(20px);
  transition: all 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.2s;
}

.reveal-active .hero-title-universal {
  opacity: 1;
  transform: translateY(0);
}

.hero-subtext-universal {
  font-family: var(--font-main);
  font-size: 1.1rem;
  font-weight: 400;
  color: #555555;
  line-height: 1.8;
  max-width: 580px;
  letter-spacing: 0.005em;
  opacity: 0;
  transform: translateY(15px);
  transition: all 1s ease-out 0.4s;
}

.hero-center-container .hero-subtext-universal {
  margin-left: auto;
  margin-right: auto;
}

.reveal-active .hero-subtext-universal {
  opacity: 1;
  transform: translateY(0);
}

.hero-subheadline {
  /* Legacy/Index support */
  margin-bottom: 64px;
}

/* Precision CTAs */
.hero-ctas {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 1.2s ease-out 1.5s, transform 1.2s ease-out 1.5s;
}

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

.btn-primary-neural {
  background: #1A1A1A;
  color: #FFFFFF;
  padding: 20px 48px;
  /* Standardized Padding */
  border: none;
  border-radius: 0px;
  /* Sharp Edges */
  font-family: var(--font-main);
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  display: inline-block;
}

.btn-primary-neural:hover {
  background: #333333;
  transform: translateY(-2px);
}

.btn-secondary-neural {
  background: transparent;
  color: #888888;
  border: none;
  font-family: var(--font-main);
  font-weight: 500;
  font-size: 14px;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.btn-secondary-neural:hover {
  color: #1A1A1A;
}

/* Trust Bar Anchor */
.hero-trust-bar {
  position: absolute;
  bottom: 60px;
  width: 100%;
  max-width: 1200px;
  display: flex;
  justify-content: space-between;
  padding-top: 40px;
  border-top: 1px solid #F0F0F0;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 1.2s ease-out 2s, transform 1.2s ease-out 2s;
}

.reveal-active .hero-trust-bar {
  opacity: 1;
  transform: translateY(0);
}

.hero-trust-bar .trust-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.hero-trust-bar .trust-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: #999999;
}

.hero-trust-bar .trust-value {
  font-size: 13px;
  color: #0F172A;
  font-weight: 600;
  letter-spacing: -0.01em;
}

@media (max-width: 1024px) {

  /* Legacy split-screen (no longer in use) */
  .split-screen-container {
    flex-direction: column;
    text-align: center;
  }

  .hero-left {
    flex: 1;
    margin-bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-right {
    display: none;
  }
}

/* =========================================
   HERO - Tablet Refinements (769px - 1024px)
   ========================================= */
@media (min-width: 769px) and (max-width: 1024px) {
  .hero-section {
    height: 100vh;
    padding-top: 72px;
  }

  .hero-headline {
    font-size: clamp(3rem, 6.5vw, 5.5rem);
    white-space: normal;
    line-height: 1.0;
    letter-spacing: -0.04em;
    min-height: auto;
  }

  .hero-subheadline {
    white-space: normal;
    font-size: 1.15rem;
    max-width: 66%;
    line-height: 1.55;
  }

  .hero-content {
    margin-bottom: 60px;
  }

  .hero-ctas {
    gap: 24px;
  }
}

/* =========================================
   Lifecycle Section - Horizontal Timeline
   ========================================= */
.lifecycle-section {
  background-color: #FFFFFF;
  padding: 150px 0;
  position: relative;
  z-index: 20;
  border-top: 1px solid #E5E5E5;
}

.lifecycle-container {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 4%;
}

.lifecycle-header {
  margin-bottom: 100px;
  text-align: center;
}

.lifecycle-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.lifecycle-headline {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 4rem;
  color: #1A1A1A;
  line-height: 1;
  letter-spacing: -0.04em;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out 0.1s, transform 0.6s ease-out 0.1s;
}

.lifecycle-flow {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  position: relative;
  padding-top: 60px;
}

.lifecycle-connector {
  position: absolute;
  top: 120px;
  left: 12.5%;
  right: 12.5%;
  height: 1px;
  background: rgba(0, 0, 0, 0.1);
  z-index: 1;
}

.lifecycle-phase {
  flex: 1;
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 280px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* Visible state when section is in viewport */
.lifecycle-section.visible .lifecycle-label {
  opacity: 1;
  transform: translateY(0);
}

.lifecycle-section.visible .lifecycle-headline {
  opacity: 1;
  transform: translateY(0);
}

.lifecycle-section.visible .lifecycle-phase {
  opacity: 1;
  transform: translateY(0);
}

.lifecycle-section.visible .lifecycle-phase:nth-child(2) {
  transition-delay: 0.4s;
}

.lifecycle-section.visible .lifecycle-phase:nth-child(3) {
  transition-delay: 0.6s;
}

.lifecycle-section.visible .lifecycle-phase:nth-child(4) {
  transition-delay: 0.8s;
}

.lifecycle-section.visible .lifecycle-phase:nth-child(5) {
  transition-delay: 1s;
}

.phase-number {
  position: absolute;
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-heading);
  font-size: 7rem;
  font-weight: 800;
  color: rgba(0, 0, 0, 0.04);
  line-height: 1;
  z-index: -1;
  pointer-events: none;
}

.phase-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #FFFFFF;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: var(--radius-swiss);
  position: relative;
  z-index: 3;
}

.phase-icon svg,
.phase-icon img {
  width: 24px;
  height: 24px;
  color: #1A1A1A;
}

.phase-icon.color-1 svg {
  stroke: #3B82F6;
}

.phase-icon.color-1 {
  border-color: rgba(59, 130, 246, 0.3);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.1);
}

.phase-icon.color-2 svg {
  stroke: #10B981;
}

.phase-icon.color-2 {
  border-color: rgba(16, 185, 129, 0.3);
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.1);
}

.phase-icon.color-3 svg {
  stroke: #8B5CF6;
}

.phase-icon.color-3 {
  border-color: rgba(139, 92, 246, 0.3);
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.1);
}

.phase-icon.color-4 svg {
  stroke: #F59E0B;
}

.phase-icon.color-4 {
  border-color: rgba(245, 158, 11, 0.3);
  box-shadow: 0 0 15px rgba(245, 158, 11, 0.1);
}

.phase-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: #1A1A1A;
  line-height: 1.3;
  margin-bottom: 16px;
}

.phase-desc {
  font-family: var(--font-main);
  font-size: 0.95rem;
  color: #555555;
  line-height: 1.6;
}

@media (max-width: 1024px) {
  .lifecycle-section {
    padding: 100px 0;
  }

  .lifecycle-container {
    padding: 0 6%;
  }

  .lifecycle-header {
    margin-bottom: 60px;
    text-align: left;
  }

  .lifecycle-headline {
    font-size: 2.5rem;
    line-height: 1.1;
  }

  .lifecycle-flow {
    flex-direction: column;
    gap: 0;
    padding-top: 40px;
    padding-left: 0;
  }

  .lifecycle-connector {
    top: 0;
    left: 40px;
    /* Alaligned with center of 80px offset */
    right: auto;
    width: 1px;
    height: 100%;
    background: linear-gradient(to bottom,
        rgba(0, 0, 0, 0) 0%,
        rgba(0, 0, 0, 0.1) 5%,
        rgba(0, 0, 0, 0.1) 95%,
        rgba(0, 0, 0, 0) 100%);
    transform: none;
    z-index: 1;
  }

  .lifecycle-phase {
    max-width: 100%;
    text-align: left;
    padding-left: 90px;
    padding-bottom: 72px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  .phase-number {
    position: absolute;
    top: 0;
    right: 0;
    left: auto;
    transform: none;
    font-size: 5.5rem;
    opacity: 0.05;
    letter-spacing: -0.05em;
    font-weight: 800;
    line-height: 0.8;
  }

  .phase-icon {
    margin: 0 0 24px 0;
    width: 50px;
    height: 50px;
    background: #FFFFFF;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.03);
    margin-left: -75px;
    /* (90 padding / 2) - (50 width / 2) ? No, center is at 40. 90-50 = 40. So -75 puts it at... 90-75=15. Center at 15+25=40. Correct. */
    z-index: 5;
    border-radius: 0;
  }

  .phase-icon svg,
  .phase-icon img {
    width: 22px;
    height: 22px;
  }

  .phase-title {
    font-size: 1.45rem;
    margin-bottom: 12px;
    letter-spacing: -0.035em;
  }

  .phase-desc {
    font-size: 0.95rem;
    max-width: 100%;
    line-height: 1.6;
    color: #666666;
  }
}

@media (max-width: 480px) {
  .lifecycle-headline {
    font-size: 2.2rem;
  }
}

/* Engineering Expertise Section */
.expertise-section {
  background-color: #FFFFFF;
  color: #000000;
  padding: 200px 0 100px;
  position: relative;
  z-index: 20;
  border-top: 1px solid #E5E5E5;
}

.expertise-container {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 4%;
  display: flex;
  gap: 80px;
}

.expertise-left {
  flex: 0 0 40%;
}

.sticky-wrapper {
  position: sticky;
  top: 120px;
}

.expertise-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.expertise-section.visible .expertise-label {
  opacity: 1;
  transform: translateY(0);
}

.expertise-heading {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 3.5rem;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  color: #000000;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.expertise-section.visible .expertise-heading {
  opacity: 1;
  transform: translateY(0);
}

.expertise-subtext {
  font-family: var(--font-main);
  font-size: 1.125rem;
  line-height: 1.6;
  color: #666666;
  max-width: 480px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out 0.2s, transform 0.8s ease-out 0.2s;
}

.expertise-section.visible .expertise-subtext {
  opacity: 1;
  transform: translateY(0);
}

.expertise-right {
  flex: 1;
  padding-top: 16px;
}

.service-block {
  border-top: 1px solid #EEEEEE;
  padding: 40px 0;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.expertise-section.visible .service-block {
  opacity: 1;
  transform: translateY(0);
}

.expertise-section.visible .service-block:nth-child(1) {
  transition-delay: 0.3s;
}

.expertise-section.visible .service-block:nth-child(2) {
  transition-delay: 0.4s;
}

.expertise-section.visible .service-block:nth-child(3) {
  transition-delay: 0.5s;
}

.expertise-section.visible .service-block:nth-child(4) {
  transition-delay: 0.6s;
}

.service-block:last-child {
  border-bottom: 1px solid #EEEEEE;
}

.service-number {
  display: block;
  font-family: var(--font-mono);
  font-size: 14px;
  color: #999999;
  margin-bottom: 16px;
}

.service-title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 12px;
  color: #000000;
  transition: transform 0.3s ease;
}

.service-content:hover .service-title {
  transform: translateX(10px);
}

.service-desc {
  font-family: var(--font-main);
  font-size: 1rem;
  color: #444444;
  margin-bottom: 24px;
  max-width: 500px;
  line-height: 1.5;
  transition: transform 0.3s ease;
}

.service-content:hover .service-desc {
  transform: translateX(10px);
}

.service-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-main);
  font-size: 14px;
  font-weight: 600;
  color: #000000;
  text-decoration: none;
  opacity: 0;
  transform: translateX(-10px);
  transition: all 0.3s ease;
}

.service-content:hover .service-link {
  opacity: 1;
  transform: translateX(0);
}

.service-link .arrow-icon {
  font-size: 16px;
}

@media (max-width: 1024px) {
  .expertise-container {
    flex-direction: column;
    gap: 60px;
  }

  .expertise-left {
    flex: none;
  }

  .sticky-wrapper {
    position: static;
  }

  .expertise-heading {
    font-size: 2.5rem;
  }
}

/* =========================================
   Projects / Portfolio Section
   ========================================= */
/* =========================================
   Selected Architectural Builds - Clinical Showcase
   Supreme Engineering Elegance
   ========================================= */
.projects-section {
  background-color: #FFFFFF;
  padding: 0;
  position: relative;
  z-index: 20;
  border-top: 1px solid #E5E5E5;
}

.projects-container {
  width: 100%;
  max-width: 100%;
}

/* Section Header - Massive & Confident */
.projects-header {
  padding: 180px 8% 80px;
  /* Reduced padding */
  background: #FFFFFF;
}

.projects-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
  display: block;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.projects-section.visible .projects-label {
  opacity: 1;
  transform: translateY(0);
}

.projects-headline {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 4.5rem;
  color: #000;
  line-height: 1;
  letter-spacing: -0.04em;
  max-width: 1000px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1s ease-out 0.2s, transform 1s ease-out 0.2s;
}

.projects-section.visible .projects-headline {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Immersive Sticky Canvas ===== */
.projects-stack {
  position: relative;
}

.project-card {
  position: sticky;
  top: 0;
  height: 100vh;
  width: 100%;
  display: flex;
  background: #FFFFFF;
  overflow: hidden;
  will-change: transform, opacity;
  border-top: 1px solid #F8F8F8;
  opacity: 0;
  transform: translateY(40px);
  box-shadow: 0 -40px 100px rgba(0, 0, 0, 0.03);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.projects-section.visible .project-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Clearer Z-Index Hierarchy */
.project-card:nth-child(1) {
  z-index: 10;
}

.project-card:nth-child(2) {
  z-index: 20;
}

.project-card:nth-child(3) {
  z-index: 30;
}

.project-card+.project-card {
  box-shadow: 0 -60px 120px rgba(0, 0, 0, 0.05);
}

/* Narrative Half (Clinical & Clean) */
.project-content {
  flex: 0 0 42%;
  padding: 60px 8% 60px 10%;
  /* Tighter vertical padding */
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 10;
  background: #FFFFFF;
}

.project-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.35em;
  color: #999999;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.project-meta::before {
  content: '';
  width: 32px;
  height: 1px;
  background: #E5E5E5;
}

.project-title {
  display: flex;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 40px;
}

.project-name {
  font-family: var(--font-heading);
  font-size: 3.8rem;
  font-weight: 800;
  color: #000;
  line-height: 0.85;
  letter-spacing: -0.05em;
}

.project-name-divider {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 200;
  color: #DDD;
  margin-bottom: 6px;
}

.project-descriptor {
  font-family: var(--font-main);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-slate);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 12px;
  white-space: nowrap;
}

.project-brief {
  font-family: var(--font-main);
  font-size: 1.05rem;
  font-weight: 400;
  color: #444;
  line-height: 1.7;
  margin-bottom: 48px;
  max-width: 520px;
  min-height: 4.8em;
  /* Reserve vertical space for typewriter animation */
  letter-spacing: -0.01em;
}

/* Refined Professional Metrics */
.project-metrics {
  display: flex;
  justify-content: flex-start;
  gap: 80px;
  margin-bottom: 60px;
  padding-top: 40px;
  border-top: 1px solid #F2F2F2;
  width: 100%;
  flex-wrap: nowrap;
}

.metric-item {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.metric-value {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: #000;
  line-height: 1;
  letter-spacing: -0.02em;
  white-space: nowrap;
  /* Prevent multi-line metrics */
}

.metric-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: #999;
  white-space: nowrap;
}

/* Elegant Typographic CTA */
.project-cta {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: #FFFFFF;
  background: #000000;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  padding: 12px 28px;
  gap: 16px;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid #000000;
  align-self: flex-start;
}

.project-cta:hover {
  background: #222222;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
  border-color: #222222;
}

.project-cta .arrow {
  font-size: 1.2rem;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-cta:hover .arrow {
  transform: translateX(8px);
}

/* ===== The Immersive 'Pristine Studio' Visual Layer ===== */
.project-image-wrap {
  flex: 1;
  position: relative;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px;
  overflow: hidden;
}

/* Ambient Light Splash (The "Gallery" Factor) */
.project-image-wrap::before {
  content: '';
  position: absolute;
  width: 140%;
  height: 140%;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.015) 0%, transparent 60%);
  pointer-events: none;
  z-index: 1;
}

/* Secondary Soft Light from Top-Left */
.project-image-wrap::after {
  content: '';
  position: absolute;
  top: -20%;
  left: -20%;
  width: 80%;
  height: 80%;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.01) 0%, transparent 70%);
  filter: blur(80px);
  pointer-events: none;
  z-index: 1;
}

.project-visual-frame {
  position: relative;
  z-index: 5;
  width: 100%;
  max-width: 1100px;
  aspect-ratio: 16 / 10;
  background: #FFF;
  border-radius: 40px;
  /* Luxury Multi-Stop Shadow for real depth */
  box-shadow:
    0 10px 20px rgba(0, 0, 0, 0.01),
    0 30px 60px rgba(0, 0, 0, 0.02),
    0 60px 100px rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.03);
  overflow: hidden;
  transition: transform 1s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.8s ease;
  transform: translateX(30px);
  /* Initial offset for horizontal reveal */
}

/* Subtle Glass Reflection Overlay */
.project-visual-frame::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 200%;
  height: 100%;
  background: linear-gradient(115deg,
      transparent 0%,
      rgba(255, 255, 255, 0.05) 30%,
      transparent 50%);
  transform: translateX(-100%);
  transition: transform 1.5s ease;
  z-index: 6;
  pointer-events: none;
}

.project-card:hover .project-visual-frame::after {
  transform: translateX(50%);
}

.projects-section.visible .project-card.visible .project-visual-frame {
  transform: translateX(0);
}

.project-card:hover .project-visual-frame {
  transform: scale(1.01) !important;
  box-shadow:
    0 20px 30px rgba(0, 0, 0, 0.02),
    0 50px 80px rgba(0, 0, 0, 0.04),
    0 80px 120px rgba(0, 0, 0, 0.06);
}

.project-visual-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Portfolio Footer */
.projects-footer {
  padding: 120px 10%;
  /* Reduced padding */
  background: #FFFFFF;
}

.portfolio-link {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5em;
  color: #000;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 32px;
}

.portfolio-link::after {
  content: '';
  width: 48px;
  height: 1px;
  background: #AAA;
  transition: width 0.3s ease;
}

.portfolio-link:hover::after {
  width: 100px;
}

/* Responsive Adaptations */
@media (max-width: 1300px) {
  .project-name {
    font-size: 2.5rem;
  }

  .project-descriptor {
    font-size: 0.8rem;
    letter-spacing: 0.1em;
  }

  .projects-headline {
    font-size: 3.5rem;
  }
}

@media (max-width: 1000px) {
  .project-card {
    flex-direction: column;
    height: auto;
    position: relative;
  }

  .project-content {
    padding: 100px 8%;
    order: 2;
  }

  .project-image-wrap {
    height: 60vh;
    padding: 40px;
    order: 1;
  }

  .project-visual-frame {
    border-radius: 32px;
  }
}

@media (max-width: 600px) {
  .projects-headline {
    font-size: 2.5rem;
  }

  .project-title {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .project-name {
    font-size: 2rem;
  }

  .project-name-divider {
    display: none;
  }

  .project-descriptor {
    font-size: 0.8rem;
  }
}

/* =========================================
   The Modern Stack Section - "Our Arsenal"
   Elite Institutional Manifest
   ========================================= */
.stack-section {
  background-color: #FFFFFF;
  padding: 160px 0;
  position: relative;
  z-index: 20;
  border-top: 1px solid #E5E5E5;
}

.stack-container {
  width: 100%;
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 5%;
}

/* Section Header revealing animations */
.stack-header {
  margin-bottom: 120px;
  max-width: 800px;
}

.stack-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
  display: block;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.stack-section.visible .stack-label {
  opacity: 1;
  transform: translateY(0);
}

.stack-headline {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 3.5rem;
  color: #000;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out 0.1s, transform 0.6s ease-out 0.1s;
}

.stack-section.visible .stack-headline {
  opacity: 1;
  transform: translateY(0);
}

.stack-subtext {
  font-family: var(--font-main);
  font-size: 1.125rem;
  font-weight: 400;
  color: #555;
  line-height: 1.6;
  max-width: 580px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out 0.4s, transform 0.8s ease-out 0.4s;
}

.stack-section.visible .stack-subtext {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Manifest Group Layout ===== */
.stack-groups {
  display: flex;
  flex-direction: column;
  gap: 120px;
}

.stack-group {
  display: grid;
  grid-template-columns: 280px 1fr;
  align-items: start;
  gap: 60px;
}

.group-label {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: #000;
  display: flex;
  align-items: center;
  gap: 20px;
  position: sticky;
  top: 120px;
  /* Aligned with sticky-header if applicable */
  opacity: 0;
  transform: translateX(-20px);
  transition: opacity 0.8s ease-out 0.6s, transform 0.8s ease-out 0.6s;
}

.stack-section.visible .group-label {
  opacity: 1;
  transform: translateX(0);
}

.group-label::before {
  content: '';
  width: 1px;
  height: 24px;
  background: #E5E5E5;
}

/* ===== Architectural Tech Grid ===== */
.tech-minimal-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 80px 40px;
}

.hex-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  cursor: pointer;
  transition: opacity 0.4s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  opacity: 0;
  transform: translateY(30px);
}

.stack-section.visible .hex-card {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger hex cards within each group */
.stack-section.visible .stack-group:nth-child(1) .hex-card:nth-child(1) {
  transition-delay: 0.7s;
}

.stack-section.visible .stack-group:nth-child(1) .hex-card:nth-child(2) {
  transition-delay: 0.75s;
}

.stack-section.visible .stack-group:nth-child(1) .hex-card:nth-child(3) {
  transition-delay: 0.8s;
}

.stack-section.visible .stack-group:nth-child(1) .hex-card:nth-child(4) {
  transition-delay: 0.85s;
}

.stack-section.visible .stack-group:nth-child(1) .hex-card:nth-child(5) {
  transition-delay: 0.9s;
}

.stack-section.visible .stack-group:nth-child(2) .hex-card:nth-child(1) {
  transition-delay: 0.8s;
}

.stack-section.visible .stack-group:nth-child(2) .hex-card:nth-child(2) {
  transition-delay: 0.85s;
}

.stack-section.visible .stack-group:nth-child(2) .hex-card:nth-child(3) {
  transition-delay: 0.9s;
}

.stack-section.visible .stack-group:nth-child(2) .hex-card:nth-child(4) {
  transition-delay: 0.95s;
}

.stack-section.visible .stack-group:nth-child(2) .hex-card:nth-child(5) {
  transition-delay: 1.0s;
}

.stack-section.visible .stack-group:nth-child(2) .hex-card:nth-child(6) {
  transition-delay: 1.05s;
}

.stack-section.visible .stack-group:nth-child(3) .hex-card:nth-child(1) {
  transition-delay: 0.9s;
}

.stack-section.visible .stack-group:nth-child(3) .hex-card:nth-child(2) {
  transition-delay: 0.95s;
}

.stack-section.visible .stack-group:nth-child(3) .hex-card:nth-child(3) {
  transition-delay: 1.0s;
}

.stack-section.visible .stack-group:nth-child(3) .hex-card:nth-child(4) {
  transition-delay: 1.05s;
}

.stack-section.visible .stack-group:nth-child(3) .hex-card:nth-child(5) {
  transition-delay: 1.1s;
}

.stack-section.visible .stack-group:nth-child(3) .hex-card:nth-child(6) {
  transition-delay: 1.15s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(1) {
  transition-delay: 1.0s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(2) {
  transition-delay: 1.05s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(3) {
  transition-delay: 1.1s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(4) {
  transition-delay: 1.15s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(5) {
  transition-delay: 1.2s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(6) {
  transition-delay: 1.25s;
}

.stack-section.visible .stack-group:nth-child(4) .hex-card:nth-child(7) {
  transition-delay: 1.3s;
}

.stack-section.visible .stack-group:nth-child(5) .hex-card:nth-child(1) {
  transition-delay: 1.1s;
}

.stack-section.visible .stack-group:nth-child(5) .hex-card:nth-child(2) {
  transition-delay: 1.15s;
}

.stack-section.visible .stack-group:nth-child(5) .hex-card:nth-child(3) {
  transition-delay: 1.2s;
}

.stack-section.visible .stack-group:nth-child(5) .hex-card:nth-child(4) {
  transition-delay: 1.25s;
}

.hex-card:hover {
  opacity: 0.7;
  transform: translateY(-4px);
}

.hex-card-inner {
  display: flex;
  align-items: center;
  gap: 20px;
}

.hex-icon-wrap {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.hex-card:hover .hex-icon-wrap {
  transform: scale(1.1);
}

.hex-icon-wrap img,
.hex-icon-wrap svg {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.hex-name {
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: 500;
  color: #1A1A1A;
  letter-spacing: -0.01em;
}

/* ===== Refined Stats (Aligned) ===== */
.arsenal-stats {
  margin-top: 180px;
  display: flex;
  justify-content: flex-start;
  gap: 120px;
  padding-top: 80px;
  border-top: 1px solid #F0F0F0;
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1s ease-out 1.2s, transform 1s ease-out 1.2s;
}

.stack-section.visible .arsenal-stats {
  opacity: 1;
  transform: translateY(0);
}

.arsenal-stat {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.arsenal-stat-value {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 800;
  color: #000;
  line-height: 1;
}

.arsenal-stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: #AAA;
}

/* ===== Responsive Adaptations ===== */
@media (max-width: 1200px) {
  .stack-group {
    grid-template-columns: 200px 1fr;
  }

  .tech-minimal-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .stack-headline {
    font-size: 2.8rem;
  }

  .arsenal-stats {
    gap: 60px;
    justify-content: space-between;
  }
}

@media (max-width: 900px) {
  .stack-group {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .group-label {
    position: relative;
    top: 0;
    transform: none;
  }

  .tech-minimal-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 60px 40px;
  }

  .arsenal-stats {
    flex-direction: column;
    gap: 48px;
    margin-top: 100px;
    padding-top: 60px;
    align-items: center;
    text-align: center;
  }

  .arsenal-stat {
    align-items: center;
  }

  .arsenal-stat-divider {
    display: none;
  }
}

@media (max-width: 600px) {
  .tech-minimal-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .arsenal-stat-value {
    font-size: 2.5rem;
  }

  .arsenal-stats {
    flex-direction: column;
    gap: 40px;
    margin-top: 100px;
    padding-top: 60px;
    align-items: center;
    text-align: center;
  }

  .arsenal-stat {
    align-items: center;
  }

  .arsenal-stat-divider {
    display: none;
  }
}


/* =========================================
   The Strategic Briefing Section (White Contrast)
   ========================================= */
.briefing-section {
  background-color: #FFFFFF;
  padding: 120px 0;
  position: relative;
  z-index: 20;
  overflow: hidden;
  border-top: 1px solid #E5E5E5;
  border-bottom: 1px solid #E5E5E5;
}

/* Subtle Grey Gradient (Bottom Right) */
.briefing-glow {
  position: absolute;
  bottom: -200px;
  right: -200px;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.03) 0%, transparent 70%);
  pointer-events: none;
  z-index: 1;
}

.briefing-container {
  width: 100%;
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 5%;
  display: flex;
  flex-direction: column;
  gap: 64px;
  position: relative;
  z-index: 2;
}

/* Full Width Header Layout */
.briefing-header {
  max-width: 1200px;
  width: 100%;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.briefing-section.visible .briefing-header {
  opacity: 1;
  transform: translateY(0);
}

/* Grid Layout Components */
.briefing-grid-layout {
  display: flex;
  align-items: stretch;
  gap: 80px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out 0.2s, transform 0.8s ease-out 0.2s;
}

.briefing-section.visible .briefing-grid-layout {
  opacity: 1;
  transform: translateY(0);
}

.briefing-narrative {
  flex: 0 0 28%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-right: 40px;
  border-right: 1px solid #EEEEEE;
}

.briefing-form-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.briefing-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: #888888;
  margin-bottom: 24px;
}

.briefing-headline {
  font-family: var(--font-heading);
  font-size: 4.5rem;
  /* Matched to Project Headline */
  font-weight: 800;
  color: #000000;
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin-bottom: 32px;
}

.briefing-body {
  font-family: var(--font-main);
  font-size: 1rem;
  font-weight: 400;
  color: #666666;
  line-height: 1.75;
  max-width: 100%;
}

.briefing-contact-meta {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.meta-label {
  font-family: var(--font-mono);
  font-size: 9px;
  color: #999999;
  letter-spacing: 0.2em;
}

.briefing-email {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: #000000;
  text-decoration: none;
  border-bottom: 1px solid #EEEEEE;
  padding-bottom: 4px;
  display: inline-block;
  align-self: flex-start;
  transition: all 0.3s ease;
}

.briefing-email:hover {
  border-color: #000000;
  transform: translateX(4px);
}

.intake-form {
  display: flex;
  flex-direction: column;
  gap: 28px;
  flex: 1;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.form-field {
  position: relative;
}

.form-field input,
.form-field textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid #E5E5E5;
  padding: 16px 0;
  font-family: var(--font-main);
  font-size: 1.05rem;
  color: #000000;
  transition: border-color 0.3s ease;
  outline: none;
}

.form-field input::placeholder,
.form-field textarea::placeholder {
  color: #BBBBBB;
  font-weight: 400;
}

.form-field input:focus,
.form-field textarea:focus {
  border-bottom-color: #000000;
}

.form-field textarea {
  resize: none;
  min-height: 120px;
}

/* ---- Conversational Form Labels ---- */
.form-field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label-conversational {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  color: #1A1A1A;
  letter-spacing: 0.01em;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Standardized Briefing CTA - Matched to Site Pattern */
.btn-submit-briefing {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: #FFFFFF;
  background: #000000;
  border: 1px solid #000000;
  padding: 20px 48px;
  gap: 16px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  margin-top: auto;
}

.btn-submit-briefing .arrow {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-submit-briefing:hover {
  background: #222222;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.btn-submit-briefing:hover .arrow {
  transform: translateX(8px);
}

@media (max-width: 1100px) {
  .briefing-grid-layout {
    gap: 48px;
  }

  .briefing-narrative {
    flex: 0 0 32%;
  }
}

@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .briefing-headline {
    font-size: 2.8rem;
  }

  .btn-submit-briefing {
    width: 100%;
  }
}

.briefing-section.visible .briefing-left,
.briefing-section.visible .briefing-right {
  opacity: 1;
  transform: translateY(0);
}

/* =========================================
   MOBILE OPTIMIZATION - Comprehensive Layer
   Ensuring Institutional Integrity on all Screens
   ========================================= */

@media (max-width: 768px) {

  /* ─────────────────────────────────────────────────────────
     Hero - Mobile
     KEY FIX: Use height:100vh (not auto) so:
       1. The canvas always matches the viewport exactly
          → ring draws at (50vw, 50vh) = true screen center ✓
       2. justify-content:center has a defined height to work
          against → text is genuinely vertically centered ✓
  ───────────────────────────────────────────────────────── */
  .hero-section {
    height: 100svh;
    height: 100vh;
    /* fallback for older browsers */
    min-height: unset;
    padding: 0;
    overflow: hidden;
    /* Section stays as flex (desktop), no override needed */
  }

  /* Adjust the fade vignette on mobile so particles aren't swallowed by the narrow screen */
  .hero-section::before {
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 1) 100%) !important;
  }

  /* Center container fills the full section height
     UX FIX: Reverting to perfect vertical centering to align text 
     precisely with the neural ring's white core (50vh).
     This ensures the text sits comfortably in the 'eye' of the storm. */
  .hero-center-container {
    height: 100%;
    min-height: 100svh;
    min-height: 100vh;
    padding: 0 6%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-sizing: border-box;
    padding-top: 0;
  }

  .hero-eyebrow {
    font-size: 8px;
    letter-spacing: 0.35em;
    margin-bottom: 12px;
  }

  @media (max-width: 600px) {
    .hero-eyebrow {
      display: none;
    }
  }

  /* Hero content block: headline + sub + CTAs */
  .hero-content {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    /* No margin-bottom; trust bar is at absolute bottom */
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-headline {
    font-size: clamp(2.2rem, 10vw, 3.4rem);
    white-space: normal;
    line-height: 1.0;
    letter-spacing: -0.04em;
    word-break: break-word;
    text-align: center;
    margin-bottom: 24px;
    min-height: 1.2em;
    /* Ensure it doesn't collapse while typing */
    display: block;
    /* Changed from flex to block for safer text rendering */

    /* Reveal transition to anchor the typewriter */
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 1s ease-out, transform 1s ease-out;
  }

  body.reveal-active .hero-headline {
    opacity: 1;
    transform: translateY(0);
  }

  .hero-subheadline {
    white-space: normal;
    font-size: 0.9rem;
    line-height: 1.55;
    text-align: center;
    max-width: 94%;
    margin-bottom: 32px;
    letter-spacing: -0.01em;
    color: #555555;
    margin-left: auto;
    margin-right: auto;

    /* Animation hooks - robust mobile entrance */
    opacity: 0 !important;
    transform: translateY(20px) !important;
    transition: opacity 0.7s ease-out 0.1s, transform 0.7s ease-out 0.1s !important;
  }

  body.reveal-active .hero-subheadline {
    opacity: 1 !important;
    transform: translateY(0) !important;
  }

  .hero-ctas {
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding: 0;
    gap: 14px;

    /* Animation hooks */
    opacity: 0 !important;
    transform: translateY(20px) !important;
    transition: opacity 0.7s ease-out 0.3s, transform 0.7s ease-out 0.3s !important;
  }

  body.reveal-active .hero-ctas {
    opacity: 1 !important;
    transform: translateY(0) !important;
  }

  .btn-primary-neural {
    width: auto;
    min-width: 200px;
    text-align: center;
    padding: 16px 36px;
    font-size: 13px;
  }

  .btn-secondary-neural {
    font-size: 13px;
  }

  /* ── Trust bar: anchored to the absolute bottom of the hero ── */
  .hero-trust-bar {
    position: absolute;
    bottom: 28px;
    left: 6%;
    right: 6%;
    width: auto;
    max-width: none;
    /* Horizontal row - compact on mobile */
    flex-direction: row;
    justify-content: space-around;
    align-items: flex-start;
    gap: 8px;
    margin-top: 0;
    padding: 16px 0 0;
    border-top: 1px solid #F0F0F0;
    opacity: 1;
    transform: none;
  }

  .hero-trust-bar .trust-item {
    flex: 1;
    align-items: center;
    text-align: center;
    gap: 4px;
  }

  .hero-trust-bar .trust-label {
    font-size: 7px;
    letter-spacing: 0.15em;
    line-height: 1.4;
  }

  .hero-trust-bar .trust-value {
    font-size: 10px;
    font-weight: 600;
    line-height: 1.3;
  }

  /* --- Projects Section Polish --- */
  .projects-header {
    padding: 100px 6% 40px;
  }

  .projects-headline {
    font-size: 2.8rem;
    line-height: 1.1;
  }

  .project-content {
    padding: 60px 6%;
  }

  .project-name {
    font-size: 2.2rem;
  }

  .project-descriptor {
    font-size: 0.75rem;
  }

  .project-metrics {
    flex-direction: column;
    gap: 32px;
    padding-top: 32px;
    margin-bottom: 40px;
  }

  .metric-item {
    gap: 4px;
  }

  .metric-value {
    font-size: 1.2rem;
  }

  .project-image-wrap {
    height: 45vh;
    padding: 30px;
  }

  .project-visual-frame {
    border-radius: 20px;
    transform: none !important;
    /* Remove horizontal offset on mobile */
  }

  /* --- Briefing Section Polish --- */
  .briefing-section {
    padding: 100px 0;
  }

  .briefing-headline {
    font-size: 2.8rem;
    line-height: 1.1;
  }

  .briefing-grid-layout {
    flex-direction: column;
    gap: 60px;
  }

  .briefing-narrative {
    flex: none;
    width: 100%;
    gap: 32px;
    padding-right: 0;
    border-right: none;
  }

  .briefing-body {
    font-size: 1rem;
  }

  .briefing-email {
    font-size: 1.1rem;
  }

  .intake-form {
    gap: 24px;
  }

  .form-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

@media (max-width: 480px) {

  /* Nav is 60px on very small screens - centering remains absolute */
  .hero-center-container {
    padding-top: 0;
  }

  .hero-headline {
    font-size: clamp(2rem, 11vw, 2.8rem);
    line-height: 1.08;
  }

  .hero-subheadline {
    font-size: 0.95rem;
    max-width: 94%;
  }

  .hero-ctas {
    padding: 0;
  }

  .btn-primary-neural {
    min-width: 190px;
    padding: 16px 32px;
  }

  .projects-headline,
  .briefing-headline,
  .lifecycle-headline,
  .expertise-heading,
  .stack-headline {
    font-size: 2.2rem;
  }

  .section-label,
  .projects-label,
  .expertise-label,
  .stack-label,
  .lifecycle-label,
  .briefing-label {
    letter-spacing: 0.25em;
  }

  .aideniti-nav {
    height: 60px;
  }

  .nav-logo img {
    height: 36px;
  }

  .briefing-headline br {
    display: none;
  }
}

/* Global Section Divider - Full Length Bleed */
.section-divider {
  width: 100%;
  height: 1px;
  background: #E8E8E8;
  margin: 0 auto;
  position: relative;
  z-index: 10;
}

/* Fix for horizontal scroll issues */
body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
  position: relative;
}

.noise-overlay {
  pointer-events: none;
}

/* Mobile/Tablet layout safeguard - ensure white background shows everywhere */
@media (max-width: 1024px) {

  html,
  body {
    background: #FFFFFF;
  }

  main {
    background: #FFFFFF;
    overflow-x: hidden;
  }

  /* Ensure sections always fill full width */
  .hero-section,
  .expertise-section,
  .lifecycle-section,
  .projects-section,
  .stack-section,
  .briefing-section {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }
}