/* Scorecard Design Language System */

/* New styles for index-redesign.html */
.nav-logo img {
  height: 28px;
  filter: invert(1) brightness(0);
}

.nav-links {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn {
  padding: 10px 20px;
  font-size: 12px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
}

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

.btn-secondary {
  background: transparent;
  color: var(--text-main);
  border: 1px solid var(--text-main);
}

.btn-full-width {
  width: 100%;
  justify-content: space-between;
  margin-bottom: 16px;
}

.hero-subtitle {
  max-width: 500px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.tech-logos {
  display: flex;
  justify-content: space-between;
  opacity: 0.5;
  flex-wrap: wrap;
  gap: 30px;
}

.tech-logo {
  font-size: 16px;
  font-weight: 700;
}

.pain-card {
  padding: 80px;
}

.pain-grid {
  gap: 60px;
  margin-bottom: 0;
}

.pain-content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.pain-title {
  color: #888;
  margin-bottom: 1rem;
}

.pain-heading {
  font-size: 48px;
  color: white;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.pain-divider {
  width: 1px;
  background: #333;
}

.pain-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.pain-list-item {
  color: #ddd;
  font-size: 16px;
  display: flex;
  align-items: center;
}

.pain-list-item span {
  color: var(--accent-color);
  margin-right: 16px;
}

.waveform-visual {
  width: 100%;
  height: 100%;
}
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@200;300;400;500;600&family=Space+Mono:ital,wght@0,400;0,700;1,400&display=swap');

@font-face {
  font-family: 'Departure Mono';
  src: url('https://cdn.jsdelivr.net/gh/oztype/departure-mono@main/fonts/DepartureMono-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg-color: #f2f2f2;
  --card-bg: #ffffff;
  --text-main: #000000;
  --text-secondary: #666666;
  --accent-color: #ff4500;
  --border-color: #e0e0e0;
  --radius-lg: 16px;
  --radius-sm: 6px;
}

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 300; /* Thin/Light */
  letter-spacing: -0.02em;
}

.text-display {
  font-size: 64px;
  line-height: 1.2;
  font-weight: 300;
}

.text-display-md {
  font-size: 48px;
  line-height: 1.25;
  font-weight: 300;
}

.text-mono {
  font-family: 'Space Mono', monospace;
  text-transform: uppercase;
  font-size: 14px;
  letter-spacing: 0.02em;
  line-height: 1.7;
}

.text-mono-small {
  font-family: 'Space Mono', monospace;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  line-height: 1.6;
}

.dotted-number {
  font-family: 'Departure Mono', 'Space Mono', monospace;
  font-size: 80px;
  font-weight: 400;
  line-height: 1;
  color: var(--text-main);
  width: fit-content;
}

/* Layout Utilities */
.container {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 40px;
}

.grid-bento {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}

.grid-cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

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

.grid-cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

.grid-wide-split {
  grid-template-columns: 0.6fr 1.4fr;
  gap: 120px;
  align-items: flex-start;
}

.grid-pain {
  grid-template-columns: 1fr auto 1fr;
  align-items: stretch;
}

/* Components */
.card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 56px;
  height: 100%;
  position: relative;
  transition: transform 0.3s ease;
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px 32px;
  border-radius: var(--radius-sm);
  font-family: 'Space Mono', monospace;
  text-transform: uppercase;
  font-size: 14px;
  font-weight: 400;
  text-decoration: none;
  transition: all 0.2s ease;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--text-main);
  color: white;
}

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

.btn-secondary {
  background: transparent;
  border: 1px solid var(--text-main);
  color: var(--text-main);
}

.btn-secondary:hover {
  background: var(--text-main);
  color: white;
}

/* Navigation */
.nav-container {
  padding: 24px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: transparent;
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  max-width: 1440px;
  z-index: 100;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  width: 100%;
}

.nav-container.scrolled {
  background: var(--card-bg);
  width: calc(100% - 80px);
  max-width: 1360px;
  margin: 20px auto;
  padding: 16px 32px;
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  left: 50%;
  right: auto;
  transform: translateX(-50%);
  top: 0;
}

.nav-logo {
  font-weight: 600;
  font-size: 20px;
  letter-spacing: -0.03em;
  text-decoration: none;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-link {
  font-family: 'Space Mono', monospace;
  text-transform: uppercase;
  font-size: 13px;
  color: var(--text-main);
  text-decoration: none;
}

/* Hero Section */
.hero-section {
  min-height: 60vh;
  display: flex;
  align-items: center;
  padding: 180px 0 80px;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

/* Wireframe Graphic Simulation */
.hero-graphic {
  position: relative;
  width: 100%;
  height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wireframe-circle {
  width: 400px;
  height: 400px;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 50%;
  position: relative;
  animation: rotate 20s linear infinite;
}

.wireframe-circle::before,
.wireframe-circle::after {
  content: '';
  position: absolute;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.wireframe-circle::before { width: 70%; height: 70%; }
.wireframe-circle::after { width: 40%; height: 40%; }

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Marquee */
.marquee-section {
  background: var(--bg-color);
  padding: 40px 0;
  border-top: 1px solid rgba(0,0,0,0.05);
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* Services / Features */
.feature-number {
  font-family: 'Space Mono', monospace;
  font-size: 24px;
  margin-bottom: 24px;
  color: var(--text-main);
  /* Dotted effect applied via class */
}

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

/* Footer */
.footer-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 80px 60px;
  margin-top: 80px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
}

.footer-input-group {
  display: flex;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 8px;
  background: white;
  margin-top: 24px;
}

.footer-input {
  border: none;
  flex: 1;
  padding: 8px 16px;
  font-family: 'Space Mono', monospace;
  font-size: 14px;
  outline: none;
}

.footer-subscribe-form {
  margin-top: 24px;
}

.footer-submit-btn {
  background: #ff4500;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 4px;
  cursor: pointer;
}

.footer-submit-btn:disabled {
  opacity: 0.6;
  cursor: default;
}

.subscribe-status {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  margin-top: 8px;
}

.subscribe-status-success {
  color: #1a7f37;
}

.subscribe-status-error {
  color: #cf222e;
}

.footer-links-container {
  display: flex;
  justify-content: space-between;
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid #eee;
}

.footer-pill {
  background: white;
  padding: 12px 24px;
  border-radius: 100px; /* Pill shape for links container */
  border: 1px solid #eee;
  display: inline-flex;
  gap: 24px;
}

.footer-link {
  font-family: 'Space Mono', monospace;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--text-main);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.footer-link:hover {
  border-bottom-color: var(--text-main);
}

.copyright {
  text-align: center;
  padding: 40px 0;
  font-family: 'Space Mono', monospace;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--text-secondary);
}

/* Form Elements */
.minimal-input {
  width: 100%;
  padding: 16px;
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  font-family: 'Inter', sans-serif;
  margin-bottom: 16px;
}

/* Utilities */
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.mt-10 { margin-top: 100px; }
.mb-4 { margin-bottom: 24px; }
.text-orange { color: var(--accent-color); }

@media (min-width: 1025px) {
  .text-nowrap-desktop {
    white-space: nowrap;
  }
}

/* Dark Mode Card */
.card-dark {
  background: #111111;
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 60px 48px;
  position: relative;
  overflow: hidden;
}

.card-dark .text-display-md {
  color: #ffffff;
}

.card-dark .text-secondary {
  color: #888888;
}

/* Process Loop Visualization */
.process-loop-container {
  position: relative;
  height: 300px;
  width: 100%;
  background-image: 
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.process-node {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  padding: 8px 16px;
  border-radius: 4px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  color: #aaa;
  position: absolute;
  z-index: 2;
}

.process-node.active {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
  box-shadow: 0 0 20px rgba(255, 69, 0, 0.3);
}

.loop-path {
  position: absolute;
  width: 80%;
  height: 60%;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 100px;
  top: 20%;
  left: 10%;
}

/* CTA Split Section */
.cta-split-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  min-height: 800px;
  padding: 120px 0;
}

.cta-graphic-container {
  position: relative;
  height: 100%;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wireframe-ring-placeholder {
  width: 400px;
  height: 400px;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 50%;
  position: relative;
  transform: rotate(-15deg);
}

.wireframe-ring-placeholder::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 70%; height: 70%;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 50%;
}

/* Blog Page Styles */
.blog-header {
  padding: 80px 0 40px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.blog-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
}

.search-container {
  position: relative;
  width: 100%;
  max-width: 300px;
}

.search-input {
  width: 100%;
  padding: 12px 16px 12px 40px;
  border-radius: 100px;
  border: none;
  background: white;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  color: var(--text-main);
  outline: none;
}

.search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  opacity: 0.5;
}

.filter-pills {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.filter-pill {
  padding: 8px 16px;
  border-radius: 100px;
  background: white;
  border: none;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--text-main);
}

.filter-pill.active {
  background: var(--text-main);
  color: white;
}

.filter-pill:hover:not(.active) {
  background: #e0e0e0;
}

/* Blog Grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 80px;
}

.blog-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.3s ease;
  text-decoration: none;
  color: var(--text-main);
}

.blog-card:hover {
  transform: translateY(-4px);
}

.blog-image-container {
  width: 100%;
  aspect-ratio: 16/9;
  background: #f5f5f5;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 24px;
  position: relative;
}

.blog-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-tag {
  display: inline-block;
  padding: 6px 12px;
  background: #f2f2f2;
  border-radius: 100px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  margin-bottom: 16px;
  color: var(--text-secondary);
  font-weight: 700;
}

.blog-title {
  font-family: 'Inter', sans-serif;
  font-size: 24px;
  font-weight: 300;
  line-height: 1.3;
  margin-bottom: auto;
  color: var(--text-main);
}

.blog-meta {
  margin-top: 24px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  color: var(--text-secondary);
}

/* Modal Styles - Global */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  overflow-y: auto;
  padding: 40px 20px;
  box-sizing: border-box;
}

.modal-content {
  position: relative;
  background-color: white;
  margin: 0 auto;
  max-width: 580px;
  width: 100%;
  padding: 48px;
  border-radius: 8px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
}

.close-btn {
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 28px;
  font-weight: 300;
  cursor: pointer;
  color: #000;
  line-height: 1;
  transition: color 0.2s;
}

.close-btn:hover {
  color: #ff4500;
}

.modal-header {
  margin-bottom: 32px;
  text-align: left;
}

.modal-header h3 {
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 8px 0;
  letter-spacing: -0.5px;
  color: #000;
}

.modal-header p {
  font-size: 16px;
  color: #666;
  margin: 0;
  line-height: 1.5;
}

/* Form Styles */
.modal-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #000;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  color: #000;
  background-color: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: #000;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 12px;
  padding-right: 40px;
}

.btn-block {
  width: 100%;
  justify-content: center;
}

/* Form Status Messages */
.form-status {
  margin-top: 24px;
  padding: 16px;
  border-radius: 4px;
}

.success-message {
  color: #1a7f37;
  background-color: #e6f7eb;
  padding: 12px 16px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.5;
}

.error-message {
  color: #cf222e;
  background-color: #ffebe9;
  padding: 12px 16px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.5;
}

@media (max-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }
  
  /* Hero Animation Overlap Fix */
  .hero-graphic { 
    height: 500px;
    margin-top: -100px;
    margin-bottom: -200px;
    position: relative;
    z-index: 0;
  }

  .hero-content {
    position: relative;
    z-index: 2;
  }
  
  /* Optimize Hero for Mobile */
  .hero-section {
    padding: 120px 0 60px;
    min-height: auto;
  }
  .hero-grid {
    gap: 24px;
  }
  .text-display {
    font-size: 36px;
  }

  .blog-controls {
    flex-direction: column;
    align-items: flex-start;
  }
  .search-container {
    max-width: 100%;
  }

  /* Modal Responsive Overrides */
  .modal-content {
    padding: 32px 24px;
  }
  
  .modal-header h3 {
    font-size: 20px;
  }
  
  .modal-form {
    gap: 20px;
  }
  
  /* Mobile Navigation Updates */
  .nav-links {
    display: none;
  }
  
  /* Always hide secondary button on mobile nav */
  .nav-container .btn-secondary {
    display: none;
  }
  
  /* Always hide primary button on mobile nav */
  .nav-container .btn-primary {
    display: none;
  }

  /* Show Hamburger on Mobile */
  .hamburger-btn {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 101;
  }

  .hamburger-btn span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--text-main);
    transition: all 0.3s ease;
  }

  /* Removed specific scrolled rule for btn-primary as it is now always hidden on mobile */

  /* Full Screen Mobile Menu Overlay */
  .mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--bg-color);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    padding: 24px;
    transform: translateY(-100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    opacity: 0;
    pointer-events: none;
  }

  .mobile-menu-overlay.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 60px;
  }

  .close-menu-btn {
    font-family: 'Space Mono', monospace;
    font-size: 32px;
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    line-height: 1;
  }

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

  .mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 32px;
  }

  .mobile-nav-link {
    font-family: 'Space Mono', monospace;
    text-transform: uppercase;
    font-size: 24px;
    color: var(--text-main);
    text-decoration: none;
    font-weight: 700;
  }

  .nav-container {
    padding: 16px 20px;
  }

  /* Mobile Floating Nav Fix */
  .nav-container.scrolled {
    width: calc(100% - 32px) !important; /* Match container margins */
    left: 50% !important;
    transform: translateX(-50%) !important;
    padding: 16px 20px !important; /* Keep padding consistent */
    margin: 16px auto !important; /* Slightly less top margin */
  }
}

@media (max-width: 480px) {
  .modal-content {
    padding: 24px 16px;
  }
  
  .close-btn {
    top: 16px;
    right: 16px;
  }
}

/* Desktop Defaults */
@media (min-width: 769px) {
  .hamburger-btn {
    display: none;
  }

  .mobile-menu-overlay {
    display: none;
  }
}

/* Topology Visual */
.topology-container {
  position: relative;
  height: 400px;
  width: 100%;
  background-image: 
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.topology-node {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.15);
  padding: 10px 20px;
  border-radius: 100px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  text-transform: uppercase;
  color: #ccc;
  position: absolute;
  z-index: 10;
  white-space: nowrap;
  transition: all 0.3s ease;
}

.topology-node:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.3);
  color: white;
  transform: translate(-50%, -50%) scale(1.05);
  z-index: 100;
}

.topology-node.center {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
  font-weight: 700;
  z-index: 20;
  box-shadow: 0 0 30px rgba(255, 69, 0, 0.4);
}

.topology-lines-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.circuit-line {
  stroke: rgba(255,255,255,0.15);
  stroke-width: 1;
}

.circuit-dot {
  fill: var(--accent-color);
}

/* Message Feed Animation */
.message-feed-wrapper {
  position: relative;
  width: 100%;
  height: 450px;
  overflow: hidden;
  perspective: 1000px;
  mask-image: linear-gradient(to bottom, transparent, black 10%, black 90%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, transparent, black 10%, black 90%, transparent);
}

.message-feed-track {
  width: 360px;
  margin: 0 auto;
  transform-style: preserve-3d;
  /* Starting transform */
  transform: rotateX(20deg) rotateY(-10deg) rotateZ(5deg);
  animation: feedScroll 20s linear infinite;
}

.message-card {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  padding: 16px;
  border-radius: 12px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.message-card:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.message-avatar {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: #eee;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Mono', monospace;
  font-size: 14px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
}

.message-body {
  flex: 1;
  min-width: 0; /* Text overflow handling */
}

.message-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 4px;
  font-size: 11px;
  font-family: 'Space Mono', monospace;
  color: #888;
}

.message-user {
  font-weight: 700;
  color: #111;
  font-size: 12px;
}

.message-time {
  font-size: 10px;
  opacity: 0.7;
}

.message-content {
  font-size: 13px;
  color: #333;
  line-height: 1.4;
  font-family: 'Inter', sans-serif;
}

@keyframes feedScroll {
  0% {
    transform: rotateX(20deg) rotateY(-10deg) rotateZ(5deg) translateY(-50%);
  }
  100% {
    transform: rotateX(20deg) rotateY(-10deg) rotateZ(5deg) translateY(0);
  }
}

/* -----------------------------------------------------------------------------
   MOBILE RESPONSIVE OVERRIDES
   ----------------------------------------------------------------------------- */

@media (max-width: 1024px) {
  /* Tablet / Smaller Desktop Adjustments */
  .container {
    padding: 0 32px;
  }
  
  .text-display { font-size: 56px; }
  .text-display-md { font-size: 40px; }
  
  .grid-cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  /* Mobile Global Resets */
  .container {
    padding: 0 16px; /* Reduced from 20px */
  }

  .mt-10 {
    margin-top: 60px;
  }

  .section-header {
    margin-bottom: 40px;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  /* Typography Scaling & Safety */
  .text-display {
    font-size: 36px;
    line-height: 1.1;
  }

  .text-display-md {
    font-size: 28px;
    line-height: 1.2;
    white-space: normal !important; /* CRITICAL: Override inline nowrap */
  }
  
  .dotted-number {
    font-size: 48px;
  }
  
  /* Prevent horizontal scroll from long words/overflow */
  body, html {
    overflow-x: hidden;
    width: 100%;
  }

  /* Grid System Stacking - Force Override Inline Styles */
  .grid-bento,
  .grid-cols-2,
  .grid-cols-3,
  .grid-cols-4,
  .grid-wide-split,
  .grid-pain {
    display: flex !important; /* Switch to flex column for better control than grid 1fr */
    flex-direction: column !important;
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }
  
  /* Reset Specific Grid Gaps */
  .grid-wide-split {
    gap: 32px !important;
  }

  /* Card Padding Reduction - Maximize Width */
  .card, .card-dark, .pain-card {
    padding: 24px 16px !important; /* Reduced padding */
  }
  
  /* Marquee Fix */
  .marquee-section .container > div {
    justify-content: center !important;
    gap: 16px !important;
  }
  
  /* Hero Specifics */
  .hero-section {
    padding: 120px 0 60px;
    min-height: auto;
  }
  
  .hero-grid {
    display: flex;
    flex-direction: column; 
    gap: 40px;
  }

  /* Fix Hero Graphic sizing on mobile */
  .hero-graphic { 
    height: 300px;
    width: 100%;
    margin: 0;
  }

  /* CTA Split Layout Stacking */
  .cta-split-layout {
    display: flex !important;
    flex-direction: column !important;
    padding: 40px 16px !important;
    gap: 40px;
    min-height: auto;
  }
  
  .cta-graphic-container {
    height: 300px;
    width: 100%;
    order: -1;
  }

  /* Footer Stacking */
  .footer-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 40px;
  }
  
  .footer-card {
    padding: 40px 20px;
    margin-top: 40px;
  }
  
  .footer-links-container {
    flex-direction: column;
    gap: 16px;
    align-items: center;
  }
  
  .footer-pill {
    width: 100%;
    justify-content: center;
  }

  /* Mobile Images */
  .grid-wide-split img {
    height: 250px !important; /* Reduced height to save space */
  }
  
  /* Process Loop Container Adjustment */
  .process-loop-container {
    display: flex !important;
    flex-direction: column !important;
    height: auto !important;
    background: none !important;
    padding: 0 !important;
    gap: 40px !important;
  }
  
  /* Hide the visual loop line on mobile */
  .loop-path {
    display: none;
  }
  
  .process-node {
    position: relative;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    margin: 0 auto;
    width: 100%;
    text-align: center;
  }

  /* Topology Mobile Fix */
  .topology-container {
    height: 280px; /* Slightly smaller */
    margin-top: 24px;
    width: 100%;
  }
  
  /* Ensure topology nodes don't overflow */
  .topology-node {
     font-size: 9px !important;
     padding: 6px 12px !important;
  }
  
  /* Message Feed Mobile */
  .message-feed-wrapper {
    height: 300px;
  }
  .message-feed-track {
    width: 100%; /* Ensure it fits */
    max-width: 280px;
  }
  
  /* Pain Section specific fixes */
  .pain-list {
    margin-top: 32px;
  }
  
  /* General Flex utilities override */
  .d-flex.justify-between {
    flex-wrap: wrap;
    gap: 16px;
  }
}

/* -----------------------------------------------------------------------------
   PREMIUM ANIMATIONS
   ----------------------------------------------------------------------------- */

@keyframes blurIn {
  0% {
    opacity: 0;
    filter: blur(10px);
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
  }
}

.animate-blur-in {
  animation: blurIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  opacity: 0; /* Initial state */
}

/* Scroll Animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  filter: blur(5px);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), 
              transform 1s cubic-bezier(0.16, 1, 0.3, 1),
              filter 1s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform, filter;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Delays */
.delay-100 { animation-delay: 0.1s; transition-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; transition-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; transition-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; transition-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; transition-delay: 0.5s; }
