/* Reset & Variables */
:root {
  /* Colors */
  --bg: #0b0f1b;
  --surface: #151a2e;
  --text: #E9EBF1; /* Shirt Blue */
  --text-muted: #8892b0;
  
  --accent: #47A9FF; /* Vibrant Blue */
  --accent-secondary: #007bff;
  --accent-gradient: linear-gradient(135deg, #47A9FF, #2988DF);
  
  --border: rgba(255, 255, 255, 0.08);
  --grid-line: rgba(255, 255, 255, 0.03);
  
  --font-main: "Space Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-display: "Clash Display", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "Space Mono", "Courier New", monospace;
  --container: 1400px;
}

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

html {
  scroll-behavior: smooth;
}

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

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

img {
  max-width: 100%;
  display: block;
}

/* Grid Overlay */
.grid-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 20% 100%; /* 5 columns */
  opacity: 0.4;
}

/* Layout */
.layout {
  display: flex;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* Sidebar */
.sidebar {
  width: 260px;
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: fixed;
  height: 100vh;
  top: 0;
  left: 0;
  z-index: 100;
}

.sidebar::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(11, 15, 27, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-right: 1px solid var(--border);
  z-index: -1;
}

.brand {
  margin-bottom: 60px;
}

.logo-mark {
  font-family: var(--font-display);
  font-size: 1.15rem; /* ~30% smaller than 1.6rem */
  font-weight: 600;
  letter-spacing: 0.02em; 
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  text-transform: uppercase; 
}

.logo-last {
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 0.1em;
}

.logo-dot {
  color: var(--accent);
  font-size: 2rem;
  line-height: 0;
  margin-left: 2px;
  opacity: 0; /* Removing the dot for now based on "clean" feedback, or let's keep it minimal */
  display: none; 
}

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

.nav a {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 8px 0;
  display: block;
}

.nav a:hover {
  color: var(--text);
  transform: translateX(4px);
}

.cta-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px 24px;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  line-height: 1;
}

.btn-primary {
  background: var(--text);
  color: var(--bg);
  border: 1px solid var(--text);
}

.btn-primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
  transform: translateY(-2px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  border: 1px solid var(--border);
  backdrop-filter: blur(4px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--text-muted);
  transform: translateY(-2px);
}

/* Main Content */
.main-content {
  margin-left: 260px;
  flex: 1;
  width: calc(100% - 260px);
}

/* Sections General */
section {
  border-bottom: 1px solid var(--border);
  padding: 100px 80px;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 48px;
  display: block;
  letter-spacing: 0.1em;
}

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 0;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  background-image: url('assets/Gemini_Generated_Image_47qnyc47qnyc47qn 1.jpg');
  background-size: cover;
  background-position: 90% center; /* Shift further right to prevent cutout */
  background-repeat: no-repeat;
  image-rendering: -webkit-optimize-contrast; /* Ensure crisp rendering */
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  /* Reduced gradient opacity since the image has its own negative space */
  background: linear-gradient(90deg, 
    rgba(11, 15, 27, 0.8) 0%, 
    rgba(11, 15, 27, 0.4) 50%, 
    transparent 100%
  );
  z-index: 1;
  pointer-events: none; /* Ensure gradient doesn't block interactions if any */
}

.hero-content {
  padding: 120px 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 2;
  max-width: 800px;
  /* Text naturally sits on the left, person is on the right */
}

.hero-title {
  font-family: var(--font-display);
  font-size: 4.5rem;
  line-height: 1.1;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 32px;
}

.text-accent {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: block;
}

.hero-lead {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 540px;
  margin-bottom: 48px;
  font-weight: 300;
  line-height: 1.6;
}

.hero-cta {
  display: flex;
  gap: 16px;
  align-items: center;
}

/* 
.hero-cta .arrow {
  margin-left: 8px;
}
*/

/* Removed old .hero-cta .btn-primary styles since we use shared .btn class now */
/* Removed .hero-image styles */
/* Removed .image-wrapper styles */

/* Trusted By Ticker */
.ticker-section {
  padding: 60px 80px;
  background: var(--surface);
}

.logo-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* 5 columns edge-to-edge */
  align-items: center;
  gap: 0; /* Remove gap for edge-to-edge look */
  width: 100%;
}

.logo-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 40px 20px;
  opacity: 0.7;
  transition: all 0.3s ease;
  height: 100%;
  border-right: 1px solid rgba(255, 255, 255, 0.03); /* Subtle dividers */
}

.logo-item:last-child {
  border-right: none;
}

.logo-item:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.02);
}

.logo-item img {
  max-height: 64px; /* Increased from 36px */
  max-width: 100%;
  width: auto;
  object-fit: contain;
  /* Removed grayscale filter */
  filter: none;
}

.logo-name {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 500;
  margin-top: 8px;
}

/* Capabilities */
.panel-section {
  background: var(--bg);
}

.panel-header {
  margin-bottom: 80px;
}

.panel-header h2 {
  font-family: var(--font-display);
  font-size: 2.5rem;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
  font-weight: 600;
}

.panel-sub {
  color: var(--text-muted);
  font-size: 1.1rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px; /* Gap for border effect */
  background: var(--border);
  border: 1px solid var(--border);
}

.card {
  padding: 40px;
  background: var(--bg);
  transition: background 0.3s ease;
}

.card:hover {
  background: var(--surface);
}

.card-icon {
  font-size: 2rem;
  color: var(--accent);
  display: block;
  margin-bottom: 24px;
}

.card-number {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 0.8rem;
  display: block;
  margin-bottom: 24px;
}

.card h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin-bottom: 16px;
  font-weight: 600;
  line-height: 1.2;
}

.card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 32px;
  line-height: 1.6;
}

.tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tags span {
  font-size: 0.7rem;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.03);
  padding: 4px 10px;
  color: var(--text-muted);
  border-radius: 2px;
}

/* Selected Work */
.work-section {
  padding-left: 0;
  padding-right: 0;
}

.work-section .section-label {
  padding-left: 80px;
}

.project-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 60px 80px;
  border-bottom: 1px solid var(--border);
  transition: background 0.3s ease;
}

.project-row:hover {
  background: var(--surface);
}

.project-row:last-child {
  border-bottom: none;
}

.project-info h3 {
  font-family: var(--font-display);
  font-size: 2rem;
  margin-bottom: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 16px;
}

.badge {
  font-size: 0.65rem;
  background: var(--accent);
  color: var(--bg);
  padding: 2px 8px;
  border-radius: 99px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  vertical-align: middle;
}

.project-info p {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 600px;
  margin-bottom: 0;
}

.link-arrow {
  color: var(--accent);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  margin-top: 16px;
  display: inline-block;
}

.project-meta {
  text-align: right;
  display: flex;
  gap: 16px;
}

.project-meta span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* Philosophy */
.philosophy-section {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 160px 80px;
  background: var(--surface);
  position: relative;
}

.content-block {
  max-width: 720px;
}

.content-block h2 {
  font-family: var(--font-display);
  font-size: 3rem;
  margin-bottom: 40px;
  color: var(--text);
  font-weight: 600;
  letter-spacing: -0.01em;
}

.content-block p {
  font-size: 1.25rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 32px;
}

/* Footer */
.footer {
  padding: 120px 80px 40px;
  background: var(--bg);
}

.footer-cta {
  margin-bottom: 120px;
}

.footer-label {
  font-size: 1rem;
  color: var(--accent);
  margin-bottom: 24px;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.email-link {
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.03em;
  display: inline-block;
  margin-bottom: 32px;
}

.email-link:hover {
  color: var(--accent);
}

.availability-note {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 400px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border);
  padding-top: 40px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-links a {
  margin-left: 32px;
  color: var(--text);
}

/* Utilities */
.glass-panel {
  background: rgba(11, 15, 27, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Responsive */
@media (max-width: 1200px) {
  .hero-title {
    font-size: 3.5rem;
  }
}

@media (max-width: 1024px) {
  .layout {
    flex-direction: column;
  }

  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
  }

  .sidebar::before {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .nav {
    display: none; /* Collapsed nav for mobile */
  }
  
  .brand {
      margin-bottom: 0;
  }
  
  /* Floating CTA for Mobile/Tablet */
  .sidebar-bottom {
      display: flex; 
      position: fixed;
      bottom: 24px;
      left: 50%;
      transform: translateX(-50%);
      width: calc(100% - 48px);
      max-width: 400px;
      z-index: 1000;
      background: rgba(11, 15, 27, 0.85);
      backdrop-filter: blur(16px);
      -webkit-backdrop-filter: blur(16px);
      padding: 12px;
      border-radius: 100px; /* Pill shape */
      border: 1px solid rgba(255, 255, 255, 0.1);
      box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  }
  
  .cta-stack {
     flex-direction: row;
     width: 100%;
     gap: 8px;
  }
  
  .cta-stack .btn {
     flex: 1;
     padding: 12px 16px;
     border-radius: 99px; /* Pill buttons */
     font-size: 0.85rem;
  }

  .main-content {
    margin-left: 0;
    width: 100%;
  }

  section {
      padding: 80px 40px;
  }

  .hero {
    min-height: 80vh;
    background-position: 85% center; /* Adjust for tablet to keep person visible */
  }
  
  .hero::before {
    /* Stronger gradient on tablet/mobile to ensure text readability over the image if overlaps occur */
    background: linear-gradient(90deg, 
      rgba(11, 15, 27, 0.95) 0%, 
      rgba(11, 15, 27, 0.9) 60%, 
      rgba(11, 15, 27, 0.4) 100%
    );
  }
  
  .hero-content {
      padding: 80px 24px;
      max-width: 100%;
      position: relative; 
      z-index: 10;
  }
  
  .nav {
    display: flex; /* Show nav */
    flex-direction: row;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 4px; /* Scrollbar space */
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
  }
  
  .nav::-webkit-scrollbar {
    display: none;
  }
  
  .nav a {
      font-size: 0.8rem;
      white-space: nowrap;
  }

  .grid-3 {
      grid-template-columns: repeat(2, 1fr); /* 2 columns on tablet */
  }

  .project-row {
      padding: 40px;
  }

  .philosophy-section {
      padding: 120px 40px;
  }

  .footer {
      padding: 80px 40px 120px; /* Extra bottom padding for floating CTA */
  }
}

/* Mobile specifics */
@media (max-width: 600px) {
  section {
      padding: 60px 24px;
  }

  .logo-grid {
      grid-template-columns: repeat(2, 1fr); /* 2 columns on mobile */
  }
  
  .logo-item {
      border-right: 1px solid rgba(255, 255, 255, 0.03);
      padding: 30px 10px; /* Slightly tighter padding */
  }

  .logo-item:nth-child(2n) {
      border-right: none;
  }
  
  .logo-item:last-child {
      grid-column: span 2;
      border-right: none;
      border-top: 1px solid rgba(255, 255, 255, 0.03);
  }
  
  .hero-title {
      font-size: 2.5rem; 
  }
  
  .hero-lead {
      font-size: 1rem;
  }
  
  .sidebar {
      flex-direction: column;
      align-items: flex-start;
      gap: 16px;
      padding: 24px;
  }
  
  .nav {
      width: 100%;
      gap: 20px;
  }

  .grid-3 {
      grid-template-columns: 1fr; /* 1 column on mobile */
  }

  .project-row {
      flex-direction: column;
      align-items: flex-start;
      padding: 40px 24px;
      gap: 24px;
  }

  .project-info h3 {
      font-size: 1.5rem;
  }

  .project-meta {
      text-align: left;
      width: 100%;
      justify-content: flex-start;
  }

  .philosophy-section {
      padding: 80px 24px;
  }

  .content-block h2 {
      font-size: 2rem;
  }

  .content-block p {
      font-size: 1rem;
  }

  .footer {
      padding: 60px 24px 140px; /* More space for CTA */
  }

  .email-link {
      font-size: 1.8rem;
      word-break: break-all;
  }

  .footer-bottom {
      flex-direction: column-reverse;
      gap: 24px;
      align-items: flex-start;
  }

  .footer-links a {
      margin-left: 0;
      margin-right: 24px;
  }
}
