/* ═══════════════════════════════════════════════════════════════════
   OPERIX — ULTIMATE EDITION
   Aesthetic: Cinematic × Vercel × Apple × Linear
   ═══════════════════════════════════════════════════════════════════ */

/* ── @property for animated gradients ────────────────────────────── */
@property --gradient-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}
@property --glow-opacity {
  syntax: '<number>';
  initial-value: 0;
  inherits: false;
}

/* ── Tokens ──────────────────────────────────────────────────────── */
:root {
  --black: #000000;
  --surface-1: #0a0a0a;
  --surface-2: #111111;
  --surface-3: #1a1a1a;
  --border: rgba(255, 255, 255, 0.05);
  --border-hover: rgba(255, 255, 255, 0.1);
  --text-1: #fafafa;
  --text-2: #a1a1a1;
  --text-3: #555555;
  --text-4: #333333;
  --violet: #a855f7;
  --violet-dim: rgba(168, 85, 247, 0.12);
  --blue: #3b82f6;
  --emerald: #10b981;
  --amber: #f59e0b;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ── Utility Classes ───────────────────────────────────────────────── */
.dim { color: var(--blue); }

/* ── Focus States (a11y) ─────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--violet);
  outline-offset: 2px;
}
input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: none;
  border-color: var(--violet);
  box-shadow: 0 0 0 3px var(--violet-dim);
}
.social-icon:focus-visible {
  outline: 2px solid var(--violet);
  outline-offset: 4px;
  border-radius: 4px;
}

/* ══════════════════════════════════════════════════════════════
   TESTIMONIALS (EDITORIAL / PREMIUM)
   ──────────────────────────────────────────────────────────── */
#testimonials {
  direction: ltr; /* Keep the slider mechanics stable in both languages */
}

/* Language-aware alignment for the testimonial section header. */
.testimonials-heading {
  direction: ltr;
  text-align: left;
}

html[dir="rtl"] .testimonials-heading {
  direction: rtl;
  text-align: right;
}

.testimonials-slider {
  display: flex;
  justify-content: flex-start;
  gap: 24px;
  margin-top: 48px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  padding-bottom: 24px;
  scrollbar-width: none;
}
.testimonials-slider::-webkit-scrollbar {
  display: none;
}

.test-nav-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}
.test-nav-btn:hover {
  background: rgba(59, 130, 246, 0.1);
  border-color: rgba(59, 130, 246, 0.3);
  color: var(--text-1);
}

.test-nav-btn.abs-left {
  position: absolute;
  top: 50%;
  left: -24px;
  transform: translateY(-50%);
  z-index: 10;
}

.test-nav-btn.abs-right {
  position: absolute;
  top: 50%;
  right: -24px;
  transform: translateY(-50%);
  z-index: 10;
}



.test-card {
  scroll-snap-align: start;
  position: relative;
  background: #080808; /* Solid dark instead of heavy glassmorphism */
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 12px;
  padding: 40px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s ease, border-color 0.5s ease;
  z-index: 1;
  width: 380px;
  min-width: 380px;
  height: auto;
  min-height: 450px;
}

/* Subtle oversized quotation mark */
.test-card::before {
  content: "“";
  position: absolute;
  top: -20px;
  left: 20px;
  font-size: 160px;
  line-height: 1;
  font-family: serif;
  color: rgba(255, 255, 255, 0.02);
  z-index: 0;
  pointer-events: none;
  transition: color 0.5s ease;
}

/* Minimal hover glow / transform */
.test-card:hover {
  transform: translateY(-4px);
  border-color: rgba(59, 130, 246, 0.2);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6), inset 0 0 40px rgba(59, 130, 246, 0.02);
}

.test-card:hover::before {
  color: rgba(59, 130, 246, 0.05); /* very subtle blue hint on quote */
}

@media (max-width: 768px) {
  .test-card {
    width: 100%;
    min-width: 100%;
    padding: 32px 24px;
    height: auto; /* Let card grow on mobile */
    min-height: 400px;
  }
  
  .test-quote p {
    /* Removed line clamp override since it's removed globally */
  }

  .test-nav-btn.abs-left { 
    left: 50%; 
    top: auto; 
    bottom: -60px; 
    transform: translateX(-120%); 
  }
  
  .test-nav-btn.abs-right { 
    right: 50%; 
    top: auto; 
    bottom: -60px; 
    transform: translateX(120%); 
  }
  
  .slider-wrapper {
    margin-bottom: 80px; /* Make room for the arrows at the bottom */
  }
}

/* Testimonial Badge */
.test-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
  position: relative;
  z-index: 1;
  font-size: 0.65rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 600;
}

.glow-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--blue);
  box-shadow: 0 0 8px 2px rgba(59, 130, 246, 0.6);
}

.badge-line {
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin-left: 8px;
  max-width: 40px; /* Small line */
}

/* Quote Text */
.test-quote {
  flex: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
  margin-bottom: 40px;
}

.test-quote p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text-2);
  font-weight: 300;
  margin: 0;
  display: block;
}

.test-card.featured .test-quote p {
  font-size: 1.25rem;
  color: var(--text-1);
  line-height: 1.6;
}

/* Footer / Signature Area */
.test-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  position: relative;
  z-index: 1;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.test-author h4 {
  font-size: 0.95rem;
  color: var(--text-1);
  margin-bottom: 4px;
  font-weight: 500;
  letter-spacing: -0.2px;
}

.test-author span {
  font-size: 0.8rem;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* --- Testimonials RTL Overrides --- */
html[dir="rtl"] .test-quote {
  text-align: right;
  direction: rtl;
}

html[dir="rtl"] .test-badge {
  flex-direction: row-reverse;
}

html[dir="rtl"] .test-badge .badge-line {
  margin-left: 0;
  margin-right: 8px;
}

html[dir="rtl"] .test-footer {
  flex-direction: row-reverse;
  text-align: right;
}

/* Subtle Link */
.test-link {
  font-size: 0.8rem;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), color 0.4s ease;
}

.test-link i {
  width: 14px;
  height: 14px;
  opacity: 0.5;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.test-card:hover .test-link {
  color: var(--blue);
  transform: translateX(4px);
}

.test-card:hover .test-link i {
  opacity: 1;
  transform: translateX(2px);
}

/* (Removed unused full-width styles since they're in a marquee now) */


/* ── Reset ───────────────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  background: var(--black);
  color: var(--text-1);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  line-height: 1.6;
  position: relative;
}
::selection { background: rgba(168, 85, 247, 0.3); color: #fff; }
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--black); }
::-webkit-scrollbar-thumb { background: #222; border-radius: 4px; }

/* ── Global Cursor Spotlight ─────────────────────────────────────── */
@media (pointer: fine) {
  .cursor-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 800px;
    height: 800px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.04) 0%, transparent 70%);
   
    transition: opacity 0.5s;
    opacity: 0;
    will-change: transform, opacity;
  }
  body:hover .cursor-glow { opacity: 1; }
}


/* ── Noise Overlay ───────────────────────────────────────────────── */
@media (min-width: 768px) {
  .noise {
    position: fixed;
    inset: 0;
    z-index: 10000;
    pointer-events: none;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.7' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  }
}


/* ═══════════════════════════════════════════════════════════════════
   NAVBAR — FLOATING GLASSMORPHIC PILL
   ═══════════════════════════════════════════════════════════════════ */
.nav {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 92%;
  max-width: 1100px;
  z-index: 100;
  height: 56px;
  display: flex;
  align-items: center;
  padding: 0 24px;
  border-radius: 100px;
  background: rgba(5, 5, 5, 0.55);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 4px 30px rgba(0, 0, 0, 0.4),
    0 1px 0 rgba(255, 255, 255, 0.03) inset;
  transition: all 0.5s var(--ease);
}
.nav.scrolled {
  top: 12px;
  background: rgba(5, 5, 5, 0.75);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow:
    0 8px 40px rgba(0, 0, 0, 0.6),
    0 1px 0 rgba(255, 255, 255, 0.04) inset;
}
.nav-inner {
  max-width: 100%;
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.custom-logo {
  height: 32px;
  width: auto;
  object-fit: contain;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.3s ease;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}
.logo:hover .custom-logo {
  transform: rotate(12deg) scale(1.15) translateY(-3px);
  filter: drop-shadow(0 8px 12px rgba(0, 112, 243, 0.4));
}
.logo-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-1);
  letter-spacing: -0.4px;
}

/* Nav Links — Center */
.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}
.nav-links li a {
  color: var(--text-3);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 500;
  transition: color 0.3s, background 0.3s;
  letter-spacing: -0.1px;
  padding: 6px 14px;
  border-radius: 100px;
}
.nav-links li a:hover {
  color: var(--text-1);
  background: rgba(255, 255, 255, 0.06);
}

/* Nav Right Section */
.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

/* Nav CTA — Premium Pill */
.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 18px;
  border-radius: 100px;
  background: #fff;
  color: #000;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: -0.2px;
  position: relative;
  overflow: hidden;
  transition: all 0.4s var(--ease);
  flex-shrink: 0;
}
.nav-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, #e0e7ff, #ddd6fe, #c4b5fd);
  opacity: 0;
  transition: opacity 0.4s;
}
.nav-cta:hover {
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 4px 20px rgba(168, 85, 247, 0.25);
}
.nav-cta:hover::before { opacity: 1; }
.nav-cta span,
.nav-cta svg { position: relative; z-index: 2; }
.nav-cta svg { width: 13px; height: 13px; }

/* Mobile Toggle */
.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.mobile-toggle span {
  width: 18px;
  height: 1.5px;
  background: var(--text-2);
  border-radius: 2px;
  transition: all 0.3s;
}
.mobile-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(3.5px, 3.5px); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(4px, -4px); }

/* Mobile Menu — matches the pill aesthetic */
.mobile-menu {
  display: none;
  position: fixed;
  top: 80px;
  left: 4%;
  right: 4%;
  bottom: auto;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  background: rgba(5, 5, 5, 0.92);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  z-index: 99;
  padding: 1.5rem 1.75rem;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px);
  transition: opacity 0.35s, transform 0.35s var(--ease);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}
.mobile-menu.open {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}
.mobile-menu a {
  display: block;
  padding: 1rem 0;
  color: var(--text-2);
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 500;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: color 0.3s, padding-left 0.3s;
}
.mobile-menu a:hover { color: #fff; padding-left: 8px; }
.mobile-menu a:last-of-type:not(.m-cta) { border-bottom: none; }
.mobile-menu .m-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1.25rem;
  padding: 14px;
  border-radius: 100px;
  background: #fff;
  color: #000;
  font-weight: 600;
  border: none;
  border-bottom: none;
}

/* ═══════════════════════════════════════════════════════════════════
   HERO — CINEMATIC
   ═══════════════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 140px 2rem 100px;
  overflow: hidden;
  text-align: center;
}

/* Ambient orbs */
.hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}
.hero-orb-1 {
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.07) 0%, transparent 60%);
  top: -15%;
  left: 50%;
  transform: translateX(-50%);
  animation: orbPulse 12s ease-in-out infinite;
}
.hero-orb-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.05) 0%, transparent 60%);
  bottom: 10%;
  left: 10%;
  animation: orbPulse 15s ease-in-out infinite reverse;
}
.hero-orb-3 {
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.04) 0%, transparent 60%);
  bottom: 20%;
  right: 5%;
  animation: orbPulse 18s ease-in-out infinite;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
}

/* ── HERO V4 GRID ────────────────────────────────────────────────── */
.hero-grid {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1300px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 4rem;
  align-items: center;
  text-align: left;
}

/* ── LEFT: Typography & Actions ──────────────────────────────────── */
.hero-left {
  position: relative;
  z-index: 3;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px 5px 8px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: rgba(10, 10, 10, 0.8);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-2);
  margin-bottom: 2rem;
  letter-spacing: 0.3px;
  backdrop-filter: blur(12px);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.8s 0.2s var(--ease) forwards;
}
.hero-badge .pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 10px var(--emerald);
  animation: pulse 2.5s ease-in-out infinite;
}

.hero-title-left {
  font-size: clamp(3.5rem, 6vw, 5.2rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -3px;
  color: #fff;
  margin-bottom: 1.5rem;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.8s 0.4s var(--ease) forwards;
}
.hero-title-left .gradient-epic {
  background: linear-gradient(135deg, #1e3a8a, #8b5cf6, #10b981);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  background-size: 200% auto;
  animation: gradientFlow 8s ease-in-out infinite;
}

.hero-subtitle-left {
  font-size: clamp(1rem, 1.5vw, 1.1rem);
  color: var(--text-2);
  max-width: 480px;
  line-height: 1.65;
  font-weight: 400;
  margin-bottom: 2.5rem;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.8s 0.6s var(--ease) forwards;
}

.hero-actions-left {
  display: flex;
  align-items: center;
  gap: 16px;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.8s 0.8s var(--ease) forwards;
}

/* Primary Button ("Initialize Project") */
.btn-mag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  background: #fff; /* Solid white */
  color: #000;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.875rem;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform, box-shadow;
}
.btn-mag:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

/* Secondary Button ("View Systems") */
.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  background: transparent;
  color: #d1d5db; /* text-gray-300 */
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 100px;
  font-weight: 500;
  font-size: 0.875rem;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform, background, color;
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1); /* bg-white/10 */
  color: #fff;
  transform: translateY(-4px);
}

/* ── RIGHT: Dynamic Bento Core ───────────────────────────────────── */
.hero-right {
  position: relative;
  z-index: 2;
  perspective: 1000px;
}

.abstract-cloud {
  position: absolute;
  inset: -50px;
  z-index: -1;
  pointer-events: none;
  opacity: 0;
  animation: fadeInUp 1.5s 1s var(--ease) forwards;
}
.abs-node {
  position: absolute;
  width: 4px;
  height: 4px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 0 15px 2px rgba(139, 92, 246, 0.8);
  animation: floatNode 6s ease-in-out infinite alternate;
}
.an-1 { top: 10%; left: 20%; background: var(--blue); }
.an-2 { bottom: 20%; right: 10%; background: var(--emerald); animation-delay: -2s; }
.an-3 { top: 50%; right: -5%; background: var(--violet); animation-delay: -4s; }
.abs-line {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  opacity: 0.3;
}
@keyframes floatNode {
  0% { transform: translateY(0) translateX(0); }
  100% { transform: translateY(-20px) translateX(20px); }
}

.hero-bento-grid {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  opacity: 0;
  transform: rotateY(-10deg) translateX(40px);
  animation: floatIn 1.2s 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes floatIn {
  to { opacity: 1; transform: rotateY(0) translateX(0); }
}

.h-card {
  position: relative;
  background: rgba(10, 10, 10, 0.6);
  border: 1px solid var(--border);
  border-radius: 16px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  overflow: hidden;
  transition: transform 0.6s var(--ease), border-color 0.6s var(--ease);
  transform-style: preserve-3d;
  will-change: transform, opacity;
}
.h-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 20px 80px -20px rgba(139, 92, 246, 0.2);
  opacity: 0;
  transition: opacity 0.6s var(--ease);
  z-index: -1;
  pointer-events: none;
}
.h-card:hover {
  border-color: rgba(255, 255, 255, 0.1);
}
.h-card:hover::after {
  opacity: 0.7;
}

.h-card-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(800px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.04), transparent 40%);
  opacity: 0;
  transition: opacity 0.5s;
  pointer-events: none;
  z-index: 1;
}
.h-card:hover .h-card-glow { opacity: 1; }

/* Terminal Adjustments */
.terminal-card {
  background: #030303;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 2;
}
.t-dot { width: 9px; height: 9px; border-radius: 50%; }
.t-dot.r { background: #ff5f57; }
.t-dot.y { background: #febc2e; }
.t-dot.g { background: #28c840; }
.t-title {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--text-4);
  letter-spacing: 0.5px;
}
.compact-logs {
  padding: 16px 20px;
  min-height: 200px;
  line-height: 1.8;
  position: relative;
  z-index: 2;
}
.t-line {
  opacity: 0;
  transform: translateY(3px);
  white-space: nowrap;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 0.74rem;
}
.t-line.vis {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.3s, transform 0.3s var(--ease);
}
.t-line .pr { color: var(--emerald); margin-right: 6px; }
.t-line .cm { color: var(--text-1); }
.t-line .ok { color: var(--emerald); }
.t-line .inf { color: var(--violet); }
.t-line .bl { color: var(--blue); }
.t-line .yl { color: var(--amber); }
.t-line .ou { color: var(--text-3); font-size: 0.74rem; }
.t-cursor {
  display: inline-block;
  width: 7px;
  height: 15px;
  background: var(--emerald);
  border-radius: 1px;
  vertical-align: text-bottom;
  margin-left: 2px;
  animation: blink 1s step-end infinite;
}

/* Status Card */
.status-card {
  background: #050505;
}
.h-card-content {
  padding: 20px 24px;
  position: relative;
  z-index: 2;
}
.h-card-title {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-4);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}
.status-metrics {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}
.sm-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sm-label {
  font-size: 0.7rem;
  color: var(--text-3);
  font-weight: 500;
}
.sm-val {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-1);
}
.sm-sym { font-size: 1rem; color: var(--text-4); }
.sm-pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 10px var(--emerald);
  animation: pulse 2.5s infinite;
}

/* ═══════════════════════════════════════════════════════════════════
   MARQUEE
   ═══════════════════════════════════════════════════════════════════ */
.marquee-strip {
  width: 100%;
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 18px 0;
  position: relative;
}
/* Portfolio Marquee Layout */
.marquee-wrapper {
  overflow: hidden;
  width: 100%;
  position: relative;
  padding-bottom: 2rem; /* space for interactions */
  margin-top: 3rem;
}
.portfolio-grid {
  display: flex;
  justify-content: flex-start;
  gap: 0;
  width: max-content;
  animation: marqueeScroll 40s linear infinite;
  /* Hover pause is applied via wrapper below */
}
.marquee-wrapper:hover .portfolio-grid {
  animation-play-state: paused;
}
/* Cleaned up duplicated pf-card */
.marquee-track {
  display: flex;
  width: max-content;
  animation: marqueeScroll 30s linear infinite;
}
.marquee-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 3rem;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-3);
  white-space: nowrap;
  letter-spacing: -0.1px;
}
.marquee-item .m-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--text-4);
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   SECTION COMMONS
   ═══════════════════════════════════════════════════════════════════ */
.section {
  padding: 140px clamp(1.5rem, 4vw, 3rem);
  position: relative;
}
.section-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.section-eyebrow {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--text-4);
  margin-bottom: 1.25rem;
}
.section-heading {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -2.5px;
  color: #fff;
  line-height: 1.05;
  margin-bottom: 1rem;
}
.section-heading .dim { color: var(--blue); }
.section-desc {
  font-size: 1rem;
  color: var(--text-2);
  max-width: 460px;
  line-height: 1.6;
  letter-spacing: -0.2px;
}

/* ═══════════════════════════════════════════════════════════════════
   BENTO V2 — ULTRA PREMIUM
   ═══════════════════════════════════════════════════════════════════ */
.premium-bento {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 16px;
  margin-top: 4rem;
}
@media (max-width: 900px) {
  .premium-bento {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
}

.p-bento-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  will-change: transform, box-shadow;
  transform: translateZ(0);
}
.p-bento-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity 0.4s var(--ease);
  z-index: -1;
  pointer-events: none;
}
.p-bento-card:hover {
  background: rgba(15, 15, 15, 0.7);
  border-color: rgba(255, 255, 255, 0.1);
}
.p-bento-card:hover::after {
  opacity: 1;
}
.card-ai { grid-row: span 2; }
.card-web { grid-row: span 1; }
.card-auto { grid-row: span 1; }

.p-bento-content {
  padding: 36px;
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-grow: 1;
}

/* Mouse Glow Effect */
.p-bento-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.06), transparent 40%);
  opacity: 0;
  transition: opacity 0.5s;
  pointer-events: none;
  z-index: 1;
}
.p-bento-card:hover .p-bento-glow { opacity: 1; }

/* Text & Headers */
.p-bento-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 1rem;
}
.p-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #000;
  border: 1px solid rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-1);
}
.p-bento-header h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.5px;
}
.card-ai h3 { font-size: 1.5rem; }
.p-bento-content p {
  color: var(--text-2);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}
.p-bento-content p .highlight {
  color: var(--text-1);
  font-weight: 500;
}
.p-bento-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 2.5rem;
}
.p-tag {
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--text-3);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Visuals Container (Seamless Integration) */
.ai-visual, .perf-visual, .auto-visual {
  margin-top: auto;
  position: relative;
  border-radius: 12px;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.08), transparent);
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
  overflow: hidden;
  z-index: 1;
}

/* Glowing Backdrops for Tech Concepts */
.ai-visual::before, .perf-visual::before, .auto-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
.ai-visual::before {
  background: radial-gradient(circle at 50% 100%, rgba(139, 92, 246, 0.25), transparent 70%);
  filter: blur(20px);
}
.perf-visual::before {
  background: radial-gradient(circle at 50% 100%, rgba(16, 185, 129, 0.25), transparent 70%);
  filter: blur(20px);
}
.auto-visual::before {
  background: radial-gradient(circle at 50% 100%, rgba(59, 130, 246, 0.25), transparent 70%);
  filter: blur(20px);
}

/* Card 1: AI Chat Visual */
.ai-visual {
  padding: 24px 30px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 16px;
  min-height: 200px;
}
.chat-bubble {
  padding: 12px 18px;
  border-radius: 12px;
  font-size: 0.85rem;
  line-height: 1.5;
  max-width: 80%;
  opacity: 0;
  animation: fadeUp 0.5s forwards;
}
.user-bubble {
  align-self: flex-end;
  background: #2563eb;
  color: #fff;
  border-bottom-right-radius: 4px;
}
.ai-bubble {
  align-self: flex-start;
  background: #1f2937;
  color: #e5e7eb;
  border-bottom-left-radius: 4px;
  animation-delay: 1.5s;
}
.ai-typing {
  display: inline-block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #fff;
  animation: typing 1.5s infinite;
  box-shadow: 8px 0 0 #fff, 16px 0 0 #fff;
  margin-right: 16px;
}
.ai-bubble .ai-text {
  display: none;
}
.p-bento-card:hover .ai-typing { display: none; }
.p-bento-card:hover .ai-text { display: inline; animation: fadeIn 0.5s; }

/* Card 2: Perf Visual */
.perf-visual {
  padding: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  min-height: 180px;
}
.perf-ring {
  width: 70px;
  height: 70px;
  position: relative;
}
.perf-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.ring-bg { fill: none; stroke: rgba(255,255,255,0.05); stroke-width: 8; }
.ring-progress {
  fill: none;
  stroke: #10b981;
  stroke-width: 8;
  stroke-linecap: round;
  stroke-dasharray: 251;
  stroke-dashoffset: 251;
  transition: stroke-dashoffset 1.5s ease-out;
}
.p-bento-card:hover .ring-progress { stroke-dashoffset: 2; }
.perf-val {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: #10b981;
  line-height: 1;
}
.perf-val span { font-size: 0.5rem; color: var(--text-3); font-weight: 500; text-transform: uppercase; margin-top: 2px;}
.perf-bar-wrap { width: 100%; }
.perf-label { font-family: var(--mono); font-size: 0.7rem; color: var(--text-2); margin-bottom: 8px; text-align: center; }
.perf-bar { width: 100%; height: 6px; background: rgba(255,255,255,0.05); border-radius: 3px; overflow: hidden; }
.perf-fill { width: 0%; height: 100%; background: #3b82f6; transition: width 1.5s ease-out; }
.p-bento-card:hover .perf-fill { width: 85%; }

/* Card 3: Auto Visual */
.auto-visual {
  padding: 40px;
  min-height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.node-system {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  position: relative;
}
.nd {
  width: 50px;
  height: 50px;
  background: rgba(10,10,10,0.8);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 600;
  color: #fff;
  z-index: 2;
  transition: border-color 0.3s, box-shadow 0.3s;
  text-align: center;
}
.nd-line {
  height: 2px;
  flex-grow: 1;
  background: rgba(255,255,255,0.05);
  position: relative;
  z-index: 1;
  overflow: hidden;
}
.nd-particle {
  position: absolute;
  top: 50%;
  width: 6px;
  height: 6px;
  background: #8b5cf6;
  border-radius: 50%;
  transform: translateY(-50%);
  z-index: 3;
  opacity: 0;
}
.p-bento-card:hover .nd { border-color: #8b5cf6; box-shadow: 0 0 15px rgba(139,92,246,0.3); }
.p-bento-card:hover .nd-line .nd-particle { animation: flow 1.5s infinite; }

@keyframes flow {
  0% { left: 0%; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { left: 100%; opacity: 0; }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes typing {
  0% { box-shadow: 8px 0 0 rgba(255,255,255,0.2), 16px 0 0 rgba(255,255,255,0.2); }
  33% { box-shadow: 8px 0 0 #fff, 16px 0 0 rgba(255,255,255,0.2); }
  66% { box-shadow: 8px 0 0 rgba(255,255,255,0.2), 16px 0 0 #fff; }
}

/* ═══════════════════════════════════════════════════════════════════
   PORTFOLIO — Spotlight Cards
   ═══════════════════════════════════════════════════════════════════ */
/* Removed duplicated portfolio grid */

/* Grid for all projects page */
.portfolio-grid-all {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 4rem;
}
@media (max-width: 900px) {
  .portfolio-grid-all { grid-template-columns: 1fr; }
}


/* Spotlight Group Hover Effect */
.spotlight-group:hover .pf-card:not(:hover) {
  opacity: 0.4;
  filter: blur(4px);
}

.pf-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  flex: 0 0 auto;
  width: 350px;
  min-width: 350px;
  will-change: transform, box-shadow;
  transform: translateZ(0);
  transition: opacity 0.5s, filter 0.5s, transform 0.5s var(--ease-spring), border-color 0.5s, box-shadow 0.5s, background 0.5s;
}
.pf-card:hover {
  transform: translateY(-8px);
  background: rgba(15, 15, 15, 0.8);
}

/* Card-Specific Theme Colors */
.pf-murshid:hover { border-color: rgba(168, 85, 247, 0.6); box-shadow: 0 15px 40px rgba(168, 85, 247, 0.15); }
.pf-ags:hover { border-color: rgba(59, 130, 246, 0.6); box-shadow: 0 15px 40px rgba(59, 130, 246, 0.15); }
.pf-sana:hover { border-color: rgba(16, 185, 129, 0.6); box-shadow: 0 15px 40px rgba(16, 185, 129, 0.15); }

/* View All Projects Button */
.view-all-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 12px 24px;
  border-radius: 100px;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}
.view-all-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  color: #fff;
}

/* Visual Area (Top Half) */
.pf-visual {
  height: 220px;
  position: relative;
  overflow: hidden;
  background: #050505;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.pf-visual-bg {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pf-visual-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(10,10,10,0.8) 100%);
  pointer-events: none;
}

/* Abstract AI Nodes (Murshid) */
.abs-ai { position: relative; width: 120px; height: 80px; filter: drop-shadow(0 0 10px rgba(168,85,247,0.4)); }
.abs-node {
  position: absolute; width: 12px; height: 12px; background: rgba(168,85,247,0.5);
  border: 1px solid rgba(168,85,247,0.8); border-radius: 50%;
  box-shadow: 0 0 20px rgba(168,85,247,0.6); transition: background 0.5s, box-shadow 0.5s;
}
.n1 { top: 0; left: 50%; transform: translateX(-50%); }
.n2 { bottom: 0; left: 0; }
.n3 { bottom: 0; right: 0; }
.abs-line {
  position: absolute; height: 2px; background: rgba(168,85,247,0.6); transform-origin: top left;
  box-shadow: 0 0 10px rgba(168,85,247,0.4);
}
.l1 { top: 6px; left: 50%; width: 70px; transform: rotate(125deg); }
.l2 { top: 6px; left: 50%; width: 70px; transform: rotate(55deg); }
.pf-murshid:hover .abs-node { background: rgba(168,85,247,1); box-shadow: 0 0 30px rgba(168,85,247,0.9); }
.pf-murshid:hover .abs-line { background: rgba(168,85,247,0.9); }

/* Abstract Grid (AGS) */
.abs-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: 100px; height: 80px;
  filter: drop-shadow(0 0 10px rgba(59,130,246,0.4));
}
.ag-box {
  background: rgba(59,130,246,0.3); border: 1px solid rgba(59,130,246,0.6); border-radius: 4px;
  box-shadow: 0 0 10px rgba(59,130,246,0.2);
  transition: background 0.5s, transform 0.5s, box-shadow 0.5s;
}
.b1 { grid-column: span 2; }
.pf-ags:hover .ag-box { background: rgba(59,130,246,0.7); transform: scale(1.05); box-shadow: 0 0 20px rgba(59,130,246,0.5); }

/* Abstract Wave (SanaSkills) */
.abs-wave {
  display: flex; align-items: flex-end; gap: 6px; height: 60px;
  filter: drop-shadow(0 0 10px rgba(16,185,129,0.4));
}
.aw-bar {
  width: 12px; background: rgba(16,185,129,0.4); border-radius: 4px;
  box-shadow: 0 0 10px rgba(16,185,129,0.2);
  transition: height 0.5s ease-out, background 0.5s, box-shadow 0.5s;
}
.w1 { height: 20%; } .w2 { height: 50%; } .w3 { height: 30%; } .w4 { height: 80%; } .w5 { height: 60%; }
.pf-sana:hover .aw-bar { background: rgba(16,185,129,0.9); box-shadow: 0 0 20px rgba(16,185,129,0.6); }
.pf-sana:hover .w1 { height: 60%; } .pf-sana:hover .w2 { height: 90%; } .pf-sana:hover .w3 { height: 40%; }
.pf-sana:hover .w4 { height: 100%; } .pf-sana:hover .w5 { height: 70%; }

/* Ambient Global Glow */
.ambient-glow {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: -3; /* behind noise and cursor */
}

@keyframes orbBreathe {
  0%, 100% { opacity: 0.5; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.1); }
}

.ambient-orb {
  position: absolute;
  width: 900px;
  height: 900px;
  border-radius: 50%;

  will-change: transform, opacity;
  animation: orbBreathe 8s ease-in-out infinite;
}

.ambient-orb:nth-child(even) {
  animation-delay: -4s;
  animation-duration: 10s;
}

.ambient-orb:nth-child(3n) {
  animation-delay: -2s;
  animation-duration: 7s;
}

.ambient-orb.orb-1 {
  top: 20vh;
  left: -20vw;
  background: radial-gradient(circle closest-side, rgba(59, 130, 246, 0.25) 0%, rgba(59, 130, 246, 0.15) 30%, rgba(29, 78, 216, 0.05) 60%, transparent 100%);
}

.ambient-orb.orb-2 {
  top: 200vh;
  right: -20vw;
  left: auto;
  background: radial-gradient(circle closest-side, rgba(255, 255, 255, 0.8) 0%, rgba(147, 197, 253, 0.7) 10%, rgba(59, 130, 246, 0.4) 30%, rgba(29, 78, 216, 0.1) 65%, transparent 100%);
 
}

.ambient-orb.orb-3 {
  top: 350vh;
  left: -15vw;
  background: radial-gradient(circle closest-side, rgba(255, 255, 255, 0.8) 0%, rgba(147, 197, 253, 0.7) 10%, rgba(59, 130, 246, 0.4) 30%, rgba(29, 78, 216, 0.1) 65%, transparent 100%);
 
}

.ambient-orb.orb-4 {
  top: 500vh;
  right: -15vw;
  left: auto;
  background: radial-gradient(circle closest-side, rgba(255, 255, 255, 0.8) 0%, rgba(147, 197, 253, 0.7) 10%, rgba(59, 130, 246, 0.4) 30%, rgba(29, 78, 216, 0.1) 65%, transparent 100%);
 
}

.ambient-orb.orb-5 {
  top: 650vh;
  left: -20vw;
  background: radial-gradient(circle closest-side, rgba(255, 255, 255, 0.8) 0%, rgba(147, 197, 253, 0.7) 10%, rgba(59, 130, 246, 0.4) 30%, rgba(29, 78, 216, 0.1) 65%, transparent 100%);
 
}

.ambient-orb.orb-6 {
  top: 800vh;
  right: -20vw;
  left: auto;
  background: radial-gradient(circle closest-side, rgba(255, 255, 255, 0.8) 0%, rgba(147, 197, 253, 0.7) 10%, rgba(59, 130, 246, 0.4) 30%, rgba(29, 78, 216, 0.1) 65%, transparent 100%);
 
}

@media (max-width: 768px) {
  .ambient-orb {
    display: none !important;
  }
  .ambient-glow {
    background-image: 
      radial-gradient(circle 300px at -10% 5%, rgba(59, 130, 246, 0.25) 0%, transparent 100%),
      radial-gradient(circle 400px at 110% 15%, rgba(147, 197, 253, 0.2) 0%, transparent 100%),
      radial-gradient(circle 350px at -20% 25%, rgba(59, 130, 246, 0.15) 0%, transparent 100%),
      radial-gradient(circle 400px at 120% 35%, rgba(147, 197, 253, 0.2) 0%, transparent 100%),
      radial-gradient(circle 300px at -10% 45%, rgba(59, 130, 246, 0.15) 0%, transparent 100%),
      radial-gradient(circle 350px at 110% 55%, rgba(147, 197, 253, 0.2) 0%, transparent 100%),
      radial-gradient(circle 400px at -20% 65%, rgba(59, 130, 246, 0.15) 0%, transparent 100%),
      radial-gradient(circle 350px at 120% 75%, rgba(147, 197, 253, 0.2) 0%, transparent 100%),
      radial-gradient(circle 300px at -10% 85%, rgba(59, 130, 246, 0.15) 0%, transparent 100%),
      radial-gradient(circle 400px at 110% 95%, rgba(147, 197, 253, 0.2) 0%, transparent 100%);
  }
}

/* Card Body */
.pf-body {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  position: relative;
  z-index: 2;
}
.pf-badge {
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 100px;
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 1rem;
  border: 1px solid;
}
.pf-badge.award { color: var(--amber); border-color: rgba(245, 158, 11, 0.2); background: rgba(245, 158, 11, 0.05); }
.pf-badge.gold {
  background: rgba(250,204,21,0.1);
  color: #facc15;
  border: 1px solid rgba(250,204,21,0.4);
  box-shadow: 0 0 10px rgba(250,204,21,0.2);
  text-shadow: 0 0 5px rgba(250,204,21,0.5);
}
.pf-badge.sys { color: var(--blue); border-color: rgba(59, 130, 246, 0.2); background: rgba(59, 130, 246, 0.05); }
.pf-badge.plat { color: var(--emerald); border-color: rgba(16, 185, 129, 0.2); background: rgba(16, 185, 129, 0.05); }

.pf-body h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.5px;
  margin-bottom: 0.75rem;
}
.pf-body > p {
  font-size: 0.9rem;
  color: var(--text-2);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}
.pf-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 2rem;
}
.pf-stack-tag {
  padding: 4px 10px;
  border-radius: 6px;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-3);
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.05);
}

/* Hover Action Button */
.pf-action {
  margin-top: auto;
  overflow: hidden;
}
.pf-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out, gap 0.3s;
}
.pf-card:hover .pf-btn {
  opacity: 1;
  transform: translateY(0);
}
.pf-btn:hover { gap: 12px; }
.pf-murshid .pf-btn { color: #a855f7; }
.pf-ags .pf-btn { color: #3b82f6; }
.pf-sana .pf-btn { color: #10b981; }

/* ═══════════════════════════════════════════════════════════════════
   THE ARCHITECTS (Team Section)
   ═══════════════════════════════════════════════════════════════════ */
.team-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin: 3rem auto 0;
  max-width: 900px; /* Constrain width on desktop to make cards smaller */
}
@media (max-width: 800px) {
  .team-grid { gap: 1.5rem; }
}

.team-group:hover .team-card:not(:hover) {
  opacity: 0.5;
  filter: blur(2px);
}

.team-card {
  background: rgba(10, 10, 10, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: relative;
  overflow: hidden;
  transition: all 0.5s var(--ease-spring);
  will-change: transform, opacity;
  display: flex;
  flex-direction: column;
}
.team-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05), 0 10px 30px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity 0.5s;
  z-index: -1;
  pointer-events: none;
}
.team-card:hover::after { opacity: 1; }
.team-card:hover {
  transform: translateY(-8px) translateZ(0);
  border-color: rgba(59, 130, 246, 0.5); /* Accent Glow */
  background: rgba(15, 15, 15, 0.8);
  box-shadow: 0 15px 40px rgba(59, 130, 246, 0.15);
}

.tc-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  position: relative;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.tc-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%) contrast(1.1);
  transition: transform 0.8s var(--ease), filter 0.8s var(--ease);
  will-change: transform, filter;
}
.team-card:hover .tc-img {
  transform: scale(1.05) translateZ(0);
  filter: grayscale(0%) contrast(1);
}
.tc-body {
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.tc-role {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--blue);
  margin-bottom: 0.5rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.tc-name {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  letter-spacing: -0.5px;
  color: #fff;
}
.tc-desc {
  color: var(--text-2);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}
.tc-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.tc-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.tc-tags span {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-2);
  background: rgba(255, 255, 255, 0.05);
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  letter-spacing: 0.5px;
  transition: all 0.3s var(--ease);
}
.tc-tags span:hover {
  color: var(--text-1);
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
}
.tc-socials {
  display: flex;
  gap: 0.75rem;
}
.tc-socials a {
  color: var(--text-3);
  transition: color 0.3s;
}
.tc-socials a:hover { color: #fff; }

/* ═══════════════════════════════════════════════════════════════════
   METRICS — Micro-Bento Grid
   ═══════════════════════════════════════════════════════════════════ */
.m-bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 4rem;
}
@media (max-width: 900px) {
  .m-bento-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 550px) {
  .m-bento-grid { grid-template-columns: 1fr; }
}

.p-metric {
  background: rgba(10, 10, 10, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 3rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s var(--ease-spring), border-color 0.4s;
  will-change: transform, opacity;
}
.p-metric::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: var(--metric-shadow, 0 10px 30px rgba(0,0,0,0));
  opacity: 0;
  transition: opacity 0.4s;
  z-index: -1;
  pointer-events: none;
}
.p-metric:hover::after {
  opacity: 1;
}
.p-metric:hover {
  transform: translateY(-5px) translateZ(0);
  background: rgba(15, 15, 15, 0.8);
}
.m-glow {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.5s;
  pointer-events: none;
  z-index: 1;
}
.p-metric:hover .m-glow { opacity: 1; }
.m-val {
  position: relative;
  z-index: 2;
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -2px;
  line-height: 1;
  margin-bottom: 0.5rem;
  font-variant-numeric: tabular-nums;
  transition: text-shadow 0.4s;
}
.m-suffix { font-size: 0.5em; opacity: 0.8; }
.m-label {
  position: relative;
  z-index: 2;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: -0.1px;
}

/* Specific Theme Colors */
.m-emerald { --metric-shadow: 0 10px 30px rgba(16,185,129,0.1); }
.m-emerald .m-glow { background: radial-gradient(circle at 50% 0%, rgba(16,185,129,0.1), transparent 70%); }
.m-emerald:hover { border-color: rgba(16,185,129,0.3); }
.m-emerald .m-val { color: #10b981; }
.m-emerald:hover .m-val { text-shadow: 0 0 15px rgba(16,185,129,0.4); }

.m-blue { --metric-shadow: 0 10px 30px rgba(59,130,246,0.1); }
.m-blue .m-glow { background: radial-gradient(circle at 50% 0%, rgba(59,130,246,0.1), transparent 70%); }
.m-blue:hover { border-color: rgba(59,130,246,0.3); }
.m-blue .m-val { color: #3b82f6; }
.m-blue:hover .m-val { text-shadow: 0 0 15px rgba(59,130,246,0.4); }

.m-purple { --metric-shadow: 0 10px 30px rgba(168,85,247,0.1); }
.m-purple .m-glow { background: radial-gradient(circle at 50% 0%, rgba(168,85,247,0.1), transparent 70%); }
.m-purple:hover { border-color: rgba(168,85,247,0.3); }
.m-purple .m-val { color: #a855f7; }
.m-purple:hover .m-val { text-shadow: 0 0 15px rgba(168,85,247,0.4); }

.m-gold { --metric-shadow: 0 10px 30px rgba(245,158,11,0.1); }
.m-gold .m-glow { background: radial-gradient(circle at 50% 0%, rgba(245,158,11,0.1), transparent 70%); }
.m-gold:hover { border-color: rgba(245,158,11,0.3); }
.m-gold .m-val { color: #f59e0b; }
.m-gold:hover .m-val { text-shadow: 0 0 15px rgba(245,158,11,0.4); }

/* ═══════════════════════════════════════════════════════════════════
   CONTACT — Intake Terminal
   ═══════════════════════════════════════════════════════════════════ */
.intake-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 4rem;
  margin-top: 4rem;
}
@media (max-width: 900px) {
  .intake-grid { grid-template-columns: 1fr; gap: 3rem; }
}

.intake-text {
  display: flex;
  flex-direction: column;
}
.intake-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.2);
  background: rgba(16, 185, 129, 0.05);
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 2rem;
  align-self: flex-start;
}
.pulse-green {
  width: 6px; height: 6px; background: #10b981; border-radius: 50%;
  box-shadow: 0 0 8px #10b981; animation: pulse 2s infinite;
}

/* Contact Info Sub-block */
.contact-info { margin-top: 2rem; display: flex; flex-direction: column; gap: 1.25rem; }
.c-item { display: flex; align-items: center; gap: 14px; }
.c-item-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.05);
  display: flex; align-items: center; justify-content: center; color: var(--text-3);
}
.c-item h4 { font-size: 0.8rem; font-weight: 600; color: var(--text-1); margin-bottom: 2px; }
.c-item p { font-size: 0.8rem; color: var(--text-3); }

/* The Terminal Form */
.intake-terminal {
  background: rgba(10, 10, 10, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
  position: relative;
}
.terminal-header {
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.t-dots { display: flex; gap: 6px; }
.t-dots span { width: 10px; height: 10px; border-radius: 50%; background: #333; }
.t-dots span:nth-child(1) { background: #ef4444; }
.t-dots span:nth-child(2) { background: #f59e0b; }
.t-dots span:nth-child(3) { background: #10b981; }
.t-title { font-family: var(--mono); font-size: 0.7rem; color: var(--text-3); font-weight: 500; }

.terminal-form { padding: 32px; }
.tf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 550px) { .tf-row { grid-template-columns: 1fr; } }
.tf-group { margin-bottom: 20px; }
.tf-group label {
  display: block; font-family: var(--mono); font-size: 0.75rem; color: var(--text-2);
  margin-bottom: 8px; font-weight: 500; letter-spacing: 0.5px;
}
.tf-group input, .tf-group select {
  width: 100%; padding: 12px 16px; 
  background: rgba(255, 255, 255, 0.05); /* bg-white/5 */
  border: 1px solid rgba(255, 255, 255, 0.1); /* border-white/10 */
  border-radius: 8px;
  color: #fff; font-family: var(--font); font-size: 0.95rem;
  outline: none; transition: all 0.3s;
}
.tf-group input:focus, .tf-group select:focus {
  border-color: transparent; 
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5); /* focus:ring-blue-500/50 */
  background: rgba(255, 255, 255, 0.08);
}
.tf-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='%23aaa' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 6l3.5 4 3.5-4z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px;
}
.tf-group select option { background: #0a0a0a; color: #fff; }

/* Premium Dark Button */
.tf-submit {
  width: 100%;
  padding: 16px;
  margin-top: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #fff;
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.4s var(--ease);
  will-change: transform, opacity;
}
.tf-submit::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
  opacity: 0;
  transition: opacity 0.4s var(--ease);
  z-index: -1;
  pointer-events: none;
}
.tf-submit:hover::after { opacity: 1; }
.tf-submit-text { position: relative; z-index: 2; display: flex; align-items: center; justify-content: center; gap: 8px; }
.tf-submit-bg {
  position: absolute; inset: 0; background: linear-gradient(90deg, #1e3a8a, #3b82f6, #1e3a8a);
  opacity: 0; transition: opacity 0.4s var(--ease); z-index: 1;
}
.tf-submit:hover { border-color: rgba(59, 130, 246, 0.5); transform: translateY(-2px) translateZ(0); }
.tf-submit:hover .tf-submit-bg { opacity: 1; }
.soc-link svg { width: 16px; height: 16px; }
.soc-link:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
  background: var(--surface-2);
}

/* ═══════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════ */
.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding: 60px clamp(1.5rem, 4vw, 3rem) 30px;
}
.footer-inner { max-width: 1200px; margin: 0 auto; }
.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}
.footer-brand p {
  font-size: 0.82rem;
  color: #9ca3af; /* text-gray-400 */
  line-height: 1.6;
  margin-top: 1rem;
  max-width: 260px;
}
.footer-col h4 {
  font-size: 0.875rem; /* text-sm */
  font-weight: 600; /* font-semibold */
  color: #e5e7eb; /* text-gray-200 */
  margin-bottom: 1.25rem;
  letter-spacing: 1px; /* tracking-wider */
  text-transform: uppercase;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; }
.footer-col a {
  text-decoration: none;
  color: #9ca3af; /* text-gray-400 */
  font-size: 0.875rem; /* text-sm */
  display: inline-block;
  transition: all 0.3s;
}
.footer-col a:hover {
  color: #ffffff; /* hover:text-white */
  transform: translateX(4px); /* hover:translate-x-1 */
}
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-bottom p {
  font-size: 0.875rem; /* text-sm */
  color: #6b7280; /* text-gray-500 */
}
.footer-bottom a {
  color: #9ca3af;
  text-decoration: none;
  transition: color 0.3s;
}
.footer-bottom a:hover { color: #fff; }

/* ═══════════════════════════════════════════════════════════════════
   TOAST
   ═══════════════════════════════════════════════════════════════════ */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--surface-1);
  border: 1px solid rgba(16, 185, 129, 0.15);
  border-radius: 12px;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 10001;
  transform: translateY(150%);
  transition: transform 0.5s var(--ease);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}
.toast.show { transform: translateY(0); }
.toast-ic {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.toast-ic svg { width: 14px; height: 14px; color: var(--emerald); }
.toast-tx h4 { font-size: 0.82rem; font-weight: 600; color: #fff; }
.toast-tx p { font-size: 0.68rem; color: var(--text-4); }

/* ═══════════════════════════════════════════════════════════════════
   KEYFRAMES
   ═══════════════════════════════════════════════════════════════════ */
@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}
@keyframes wordReveal {
  to { opacity: 1; transform: translateY(0); }
}
@keyframes gradientFlow {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.3; transform: scale(0.7); }
}
@keyframes blink {
  50% { opacity: 0; }
}
@keyframes orbPulse {
  0%, 100% { opacity: 1; transform: translateX(-50%) scale(1); }
  50% { opacity: 0.6; transform: translateX(-50%) scale(1.15); }
}
@keyframes marqueeScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
@keyframes shineSlide {
  0% { transform: translateX(-60%) translateY(-60%) rotate(35deg); }
  100% { transform: translateX(60%) translateY(60%) rotate(35deg); }
}
@keyframes nodePulse {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.8); opacity: 1; }
}

/* Reveal */
.reveal {
  opacity: 0;
  transform: translateY(35px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.reveal.vis { opacity: 1; transform: translateY(0); }
.rv1 { transition-delay: 0.06s; }
.rv2 { transition-delay: 0.12s; }
.rv3 { transition-delay: 0.18s; }
.rv4 { transition-delay: 0.24s; }

/* Social Links */
.social-links {
  display: flex; gap: 1rem; margin-top: 2rem;
}
.social-icon {
  color: var(--text-3);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.social-icon:hover {
  transform: translateY(-2px);
}
.social-icon.facebook:hover { color: #1877F2; }
.social-icon.instagram:hover { color: #E4405F; }
.social-icon.whatsapp:hover { color: #25D366; }
.footer-socials { margin-top: 0; }

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE — COMPLETE MOBILE-FIRST OVERHAUL
   Breakpoints: 480 (Small Phone) | 768 (Tablet) | 1024 (Laptop) | 1440+ (Ultra-Wide)
   ═══════════════════════════════════════════════════════════════════ */

/* ── ULTRA-WIDE (1440px+) ─ generous spacing ───────────────────── */
@media (min-width: 1440px) {
  .section-inner { max-width: 1320px; }
  .hero-grid { max-width: 1400px; gap: 5rem; }
  .footer-inner { max-width: 1320px; }
}

/* ── LAPTOP / SMALL DESKTOP (≤ 1024px) ─────────────────────────── */
@media (max-width: 1024px) {
  /* Hero: stack to single column */
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
    text-align: center;
  }
  .hero-left { text-align: center; }
  .hero-subtitle-left { margin-left: auto; margin-right: auto; }
  .hero-actions-left { justify-content: center; }
  .hero-right { max-width: 520px; margin: 0 auto; }

  /* Bento */
  .premium-bento {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }
  .card-ai { grid-row: span 1; }

  /* Contact */
  .intake-grid { grid-template-columns: 1fr; gap: 3rem; }
  .intake-text { order: -1; }

  /* Footer */
  .footer-top { grid-template-columns: 1fr 1fr; gap: 2.5rem; }
}

/* ── TABLET / iPAD (≤ 768px) ───────────────────────────────────── */
@media (max-width: 768px) {
  /* Navigation */
  .nav-links { display: none; }
  .nav-cta.dsk { display: none; }
  .mobile-toggle { display: flex; }
  .mobile-menu { display: flex; }

  /* Hero */
  .hero {
    padding: 100px 1.25rem 60px;
    min-height: auto;
  }
  .hero-grid { gap: 2rem; }
  .hero-title-left {
    font-size: clamp(2rem, 8vw, 3.2rem);
    letter-spacing: -1.5px;
  }
  .hero-subtitle-left {
    font-size: 0.95rem;
    max-width: 100%;
  }
  .hero-actions-left {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }
  .btn-mag, .btn-outline {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
  .hero-badge {
    margin-bottom: 1.25rem;
  }

  /* Hero Right Bento */
  .hero-right { max-width: 100%; }
  .hero-bento-grid { gap: 1rem; }
  .abstract-cloud { display: none; }

  /* Terminal text wrap */
  .t-line {
    white-space: normal;
    word-break: break-word;
  }
  .compact-logs {
    padding: 12px 14px;
    min-height: 160px;
  }

  /* Status Card */
  .status-metrics {
    flex-direction: column;
    gap: 0.75rem;
  }
  .sm-item {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  /* Sections — reduce padding */
  .section { padding: 80px 1.25rem; }
  .section-heading {
    font-size: clamp(1.75rem, 6vw, 2.5rem);
    letter-spacing: -1.5px;
  }

  /* Bento Grid — single column */
  .premium-bento {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
  .card-ai { grid-row: span 1; }
  .p-bento-card { padding: 1.5rem; }
  .p-bento-content { padding: 20px; }

  /* Portfolio Marquee — smaller cards */
  .pf-card {
    width: 290px;
    min-width: 290px;
  }
  .pf-visual { height: 180px; }
  .pf-body { padding: 1.5rem; }
  .pf-body h3 { font-size: 1.1rem; }
  .pf-body > p { font-size: 0.85rem; }

  /* Team */
  .team-grid { grid-template-columns: 1fr; gap: 1.5rem; max-width: 380px; margin-inline: auto; }
  .tc-body { padding: 1.5rem; }
  .tc-name { font-size: 1.25rem; }
  .tc-footer { flex-direction: column; align-items: flex-start; gap: 1rem; }

  /* Metrics */
  .m-bento-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .p-metric { padding: 2rem 1.25rem; }
  .m-val { font-size: clamp(2rem, 5vw, 2.8rem); }

  /* Contact Form */
  .tf-row { grid-template-columns: 1fr; }
  .terminal-form { padding: 20px; }

  /* Footer */
  .footer-top { grid-template-columns: 1fr; gap: 2rem; }
  .footer-brand p { max-width: 100%; }
  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  /* Toast */
  .toast {
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
  }

  /* Marquee strip text */
  .marquee-item {
    padding: 0 1.5rem;
    font-size: 0.75rem;
  }
}

/* ── SMALL PHONE (≤ 480px) ─────────────────────────────────────── */
@media (max-width: 480px) {
  /* Hero: tighter */
  .hero {
    padding: 90px 1rem 50px;
  }
  .hero-title-left {
    font-size: clamp(1.6rem, 7.5vw, 2.4rem);
    letter-spacing: -1px;
  }
  .hero-subtitle-left {
    font-size: 0.88rem;
    line-height: 1.55;
  }
  .hero-badge {
    font-size: 0.65rem;
    padding: 4px 10px 4px 6px;
  }
  .hero-actions-left {
    max-width: 100%;
    gap: 0.75rem;
  }

  /* Terminal */
  .t-line { font-size: 0.65rem; }
  .compact-logs { min-height: 140px; padding: 10px 12px; }
  .t-title { font-size: 0.55rem; }

  /* Status card */
  .h-card-content { padding: 14px 16px; }
  .sm-val { font-size: 1rem; }
  .sm-label { font-size: 0.62rem; }

  /* Sections: extra compact */
  .section { padding: 60px 1rem; }
  .section-heading {
    font-size: clamp(1.5rem, 7vw, 2rem);
    letter-spacing: -1px;
  }
  .section-eyebrow {
    font-size: 0.6rem;
    letter-spacing: 2px;
  }
  .section-desc {
    font-size: 0.88rem;
  }

  /* Bento Cards */
  .p-bento-card { padding: 1rem; }
  .p-bento-content { padding: 16px; }
  .p-bento-header h3 { font-size: 1rem; }
  .p-bento-content p { font-size: 0.85rem; }
  .p-bento-tags { gap: 6px; margin-bottom: 1.5rem; }
  .p-tag { font-size: 0.6rem; padding: 3px 8px; }

  /* AI Visual */
  .ai-visual { padding: 16px 20px; min-height: 160px; }
  .chat-bubble { font-size: 0.78rem; padding: 10px 14px; max-width: 90%; }
  .perf-visual { padding: 20px; min-height: 140px; }
  .auto-visual { padding: 24px; min-height: 100px; }
  .nd { width: 40px; height: 40px; font-size: 0.55rem; }

  /* Portfolio Cards */
  .pf-card {
    width: 260px;
    min-width: 260px;
  }
  .pf-visual { height: 150px; }
  .pf-body { padding: 1.25rem; }
  .pf-body h3 { font-size: 1rem; }
  .pf-body > p { font-size: 0.8rem; margin-bottom: 1rem; }
  .pf-badge { font-size: 0.58rem; padding: 3px 8px; }
  .pf-stack-tag { font-size: 0.6rem; padding: 3px 8px; }

  /* Team Cards */
  .team-grid { grid-template-columns: 1fr; gap: 1.25rem; max-width: 340px; margin-inline: auto; }
  .tc-body { padding: 1.25rem; }
  .tc-name { font-size: 1.1rem; margin-bottom: 0.5rem; }
  .tc-desc { font-size: 0.85rem; line-height: 1.5; display: block; overflow: visible; }
  .tc-role { font-size: 0.65rem; margin-bottom: 0.5rem; }
  .tc-tags span { font-size: 0.6rem; padding: 3px 6px; }

  /* Metrics */
  .m-bento-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .p-metric { padding: 1.5rem 1rem; border-radius: 12px; }
  .m-val { font-size: clamp(1.8rem, 5vw, 2.2rem); letter-spacing: -1px; }
  .m-label { font-size: 0.7rem; }

  /* Contact Form */
  .terminal-form { padding: 16px; }
  .tf-group label { font-size: 0.68rem; }
  .tf-group input, .tf-group select { padding: 10px 12px; font-size: 0.88rem; }
  .tf-submit { padding: 14px; font-size: 0.88rem; }
  .terminal-header { padding: 10px 14px; }

  /* Contact Info */
  .c-item-icon { width: 34px; height: 34px; border-radius: 8px; }
  .c-item h4 { font-size: 0.72rem; }
  .c-item p { font-size: 0.72rem; }

  /* Footer */
  .footer { padding: 40px 1rem 20px; }
  .footer-col h4 { font-size: 0.78rem; margin-bottom: 0.75rem; }
  .footer-col a { font-size: 0.8rem; }
  .footer-bottom p { font-size: 0.78rem; }

  /* View All Projects Button */
  .view-all-btn { font-size: 0.85rem; padding: 10px 20px; }

  /* Marquee strip */
  .marquee-item {
    padding: 0 1rem;
    font-size: 0.7rem;
  }
}

/* ── TOUCH: better tap targets & disable cursor effects ────────── */
@media (hover: none) and (pointer: coarse) {
  .cursor-glow { display: none !important; }
  .h-card-glow { display: none; }
  .p-bento-glow { display: none; }
  .pf-card:hover .pf-btn { opacity: 1; transform: translateY(0); }
  .pf-btn { opacity: 1 !important; transform: translateY(0) !important; }
}


/* ═══════════════════════════════════════════════════════════════════
   i18n — LANGUAGE SWITCHER + RTL SUPPORT (v2 — Fixed)
   ═══════════════════════════════════════════════════════════════════ */

/* ── Arabic Font Variable ──────────────────────────────────────────── */
:root {
  --font-ar: 'Cairo', 'Segoe UI', Tahoma, Arial, sans-serif;
}

/* ── Language Switcher Button ──────────────────────────────────────── */
.lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  color: var(--text-2);
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  user-select: none;
  white-space: nowrap;
  line-height: 1;
}

.lang-switcher:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  color: var(--text-1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.lang-switcher:active {
  transform: translateY(0) scale(0.96);
}

.lang-en, .lang-ar {
  position: relative;
  transition: color 0.3s var(--ease);
}

/* Highlight the active language based on document direction */
html[dir="ltr"] .lang-en { color: var(--text-1); font-weight: 700; }
html[dir="ltr"] .lang-ar { color: var(--text-3); font-weight: 500; font-family: var(--font-ar); }

html[dir="rtl"] .lang-en { color: var(--text-3); font-weight: 500; }
html[dir="rtl"] .lang-ar { color: var(--text-1); font-weight: 700; font-family: var(--font-ar); }

/* Mobile lang switcher in mobile menu */
.mobile-lang-switcher {
  margin: 8px 0;
  width: 100%;
  justify-content: center;
}

/* ══════════════════════════════════════════════════════════════════════
   RTL OVERRIDES — Arabic Layout
   ══════════════════════════════════════════════════════════════════════ */

/* ── Arabic font on body text only ────────────────────────────────── */
[dir="rtl"] body {
  font-family: var(--font-ar), sans-serif;
}

/* ── RTL — Navbar ──────────────────────────────────────────────────
   IMPORTANT: .nav-links uses position:absolute + left:50% for centering.
   DO NOT use flex-direction:row-reverse on .nav-inner — it breaks layout.
   Instead, just keep the nav-right on the correct side.            ──── */
[dir="rtl"] .nav-links {
  /* Fix absolute centering: in RTL, browser flips 'left' anchor.
     Force it back to visual center using explicit left + right override */
  right: auto;
  left: 50%;
  transform: translateX(-50%);
  flex-direction: row-reverse;
}

[dir="rtl"] .nav-right {
  gap: 12px;
}

/* Arrow icons in CTA buttons flip in RTL */
[dir="rtl"] .nav-cta svg,
[dir="rtl"] .nav-cta i {
  transform: scaleX(-1);
}

/* ── RTL — Hero ────────────────────────────────────────────────────
   CRITICAL FIX: Do NOT apply direction:rtl to hero-grid — it breaks
   the bento card overflow. Use grid column assignment to swap visually. */
[dir="rtl"] .hero-grid {
  direction: ltr; /* keep LTR so bento doesn't overflow off-screen */
}

/* Swap columns ONLY on desktop where there are 2 columns */
@media (min-width: 1025px) {
  [dir="rtl"] .hero-left {
    text-align: right;
    grid-column: 2; /* Text moves to RIGHT column in RTL */
    grid-row: 1; /* Prevent pushing to next row */
  }

  [dir="rtl"] .hero-right {
    grid-column: 1; /* Bento moves to LEFT column in RTL */
    grid-row: 1; /* Prevent pushing to next row */
  }
}

/* On mobile, center the text properly for RTL */
@media (max-width: 1024px) {
  [dir="rtl"] .hero-left {
    text-align: center;
  }
  [dir="rtl"] .hero-subtitle-left {
    margin-left: auto;
    margin-right: auto;
  }
  [dir="rtl"] .hero-actions-left {
    justify-content: center;
  }
}

[dir="rtl"] .hero-title-left {
  font-size: clamp(2.5rem, 4.5vw, 4rem);
  line-height: 1.3;
}

[dir="rtl"] .hero-subtitle-left {
  margin-left: auto;
  margin-right: 0;
}

[dir="rtl"] .hero-actions-left {
  justify-content: flex-end;
}

[dir="rtl"] .hero-badge {
  flex-direction: row-reverse;
}

[dir="rtl"] .btn-mag {
  flex-direction: row-reverse;
}

[dir="rtl"] .btn-mag svg {
  transform: scaleX(-1);
}

/* ── RTL — Section headers ─────────────────────────────────────────── */
[dir="rtl"] .section-eyebrow,
[dir="rtl"] .section-heading,
[dir="rtl"] .section-desc {
  text-align: right;
}

/* ── RTL — Services Bento ──────────────────────────────────────────── */
[dir="rtl"] .p-bento-header {
  flex-direction: row-reverse;
}

[dir="rtl"] .p-bento-tags {
  justify-content: flex-end;
}

/* ── RTL — Portfolio Cards ─────────────────────────────────────────── */
[dir="rtl"] .pf-body {
  text-align: right;
}

[dir="rtl"] .pf-tags,
[dir="rtl"] .pf-stack {
  justify-content: flex-end;
}

[dir="rtl"] .pf-btn {
  flex-direction: row-reverse;
}

[dir="rtl"] .pf-btn svg,
[dir="rtl"] .pf-btn i {
  transform: scaleX(-1);
}

[dir="rtl"] .pf-action {
  display: flex;
  justify-content: flex-start; /* Left in LTR = Right in RTL perception */
}

/* ── RTL — Contact Form ────────────────────────────────────────────── */
[dir="rtl"] .intake-terminal {
  text-align: right;
}

[dir="rtl"] .tf-row {
  flex-direction: row-reverse;
}

[dir="rtl"] .tf-group label {
  text-align: right;
}

[dir="rtl"] .tf-group input,
[dir="rtl"] .tf-group select,
[dir="rtl"] .tf-group textarea {
  text-align: right;
  direction: rtl;
}

[dir="rtl"] .terminal-header {
  flex-direction: row-reverse;
}

[dir="rtl"] .intake-text {
  text-align: right;
  align-items: flex-start; /* in RTL flex-start is right */
}

[dir="rtl"] .contact-info {
  align-items: flex-start;
}

[dir="rtl"] .c-item {
  justify-content: flex-start;
  text-align: right;
}

[dir="rtl"] .intake-status {
  justify-content: flex-start;
}



[dir="rtl"] .social-links {
  justify-content: flex-end;
}

/* ── RTL — Team ────────────────────────────────────────────────────── */
[dir="rtl"] .team-card,
[dir="rtl"] .tc-body {
  text-align: right;
}

[dir="rtl"] .tc-footer {
  flex-direction: row-reverse;
}

[dir="rtl"] .tc-tags {
  justify-content: flex-end;
}

/* ── RTL — Metrics ─────────────────────────────────────────────────── */
[dir="rtl"] .p-metric {
  text-align: center; /* keep centered for metrics */
}

/* ── RTL — Footer ──────────────────────────────────────────────────── */
[dir="rtl"] .footer-top {
  flex-direction: row-reverse;
}

[dir="rtl"] .footer-brand,
[dir="rtl"] .footer-col {
  text-align: right;
}

[dir="rtl"] .footer-col ul {
  padding-right: 0;
  text-align: right;
}

[dir="rtl"] .footer-bottom {
  flex-direction: row-reverse;
}

@media (max-width: 768px) {
  [dir="rtl"] .footer-bottom {
    flex-direction: column;
  }
}

/* ── RTL — Mobile Menu ─────────────────────────────────────────────── */
[dir="rtl"] .mobile-menu {
  text-align: right;
}

[dir="rtl"] .mobile-menu a {
  padding-right: 8px;
}

[dir="rtl"] .mobile-menu a:hover {
  padding-left: 0;
  padding-right: 16px;
}

/* ── RTL — View All Btn ────────────────────────────────────────────── */
[dir="rtl"] .view-all-btn {
  flex-direction: row-reverse;
}

[dir="rtl"] .view-all-btn i,
[dir="rtl"] .view-all-btn svg {
  transform: scaleX(-1);
}

/* ── RTL — Toast ───────────────────────────────────────────────────── */
[dir="rtl"] .toast {
  flex-direction: row-reverse;
  left: 1.5rem;
  right: auto;
}

/* ── Arabic Typography ─────────────────────────────────────────────── */
[dir="rtl"] h1,
[dir="rtl"] h2,
[dir="rtl"] h3,
[dir="rtl"] h4 {
  font-family: var(--font-ar);
  letter-spacing: 0;
}

[dir="rtl"] p,
[dir="rtl"] label,
[dir="rtl"] li {
  font-family: var(--font-ar);
  letter-spacing: 0;
}

/* Keep buttons/links readable in both langs */
[dir="rtl"] .btn-mag,
[dir="rtl"] .btn-outline,
[dir="rtl"] .nav-cta span,
[dir="rtl"] .m-cta {
  font-family: var(--font-ar);
  letter-spacing: 0;
}

/* Keep monospace / terminal elements strictly LTR */
[dir="rtl"] .terminal,
[dir="rtl"] .terminal-body,
[dir="rtl"] .t-line,
[dir="rtl"] .t-title,
[dir="rtl"] code,
[dir="rtl"] pre,
[dir="rtl"] .logo-name {
  font-family: var(--mono) !important;
  direction: ltr !important;
  text-align: left !important;
  unicode-bidi: embed;
}

/* Keep Marquee tracks LTR so they scroll exactly like English (Right-to-Left visually) */
[dir="rtl"] .marquee-strip,
[dir="rtl"] .marquee-track,
[dir="rtl"] .marquee-wrapper,
[dir="rtl"] .portfolio-grid {
  direction: ltr !important;
}

/* Ensure the text inside the marquee items is properly RTL and uses Arabic font */
[dir="rtl"] .marquee-item {
  direction: rtl;
  font-family: var(--font-ar);
}

/* ── Prevent body overflow in RTL ──────────────────────────────────── */
[dir="rtl"] body {
  overflow-x: hidden;
}

/* =========================================================
   MOBILE AMBIENT ORBS OVERRIDES
   ========================================================= */
@media (max-width: 768px) {
  .ambient-orb {
    width: 600px;
    height: 600px;
  }
  .ambient-orb.orb-1 { top: 20vh; left: -300px; }
  .ambient-orb.orb-2 { top: 120vh; right: -300px; left: auto; }
  .ambient-orb.orb-3 { top: 220vh; left: -300px; }
  .ambient-orb.orb-4 { top: 320vh; right: -300px; left: auto; }
  .ambient-orb.orb-5 { top: 420vh; left: -300px; }
  .ambient-orb.orb-6 { top: 520vh; right: -300px; left: auto; }
  .ambient-orb.orb-7 { top: 620vh; left: -300px; }
  .ambient-orb.orb-8 { top: 720vh; right: -300px; left: auto; }
  .ambient-orb.orb-9 { top: 820vh; left: -300px; }
  .ambient-orb.orb-10 { top: 920vh; right: -300px; left: auto; }
  .ambient-orb.orb-11 { top: 1020vh; left: -300px; }
  .ambient-orb.orb-12 { top: 1120vh; right: -300px; left: auto; }
  .ambient-orb.orb-13 { top: 1220vh; left: -300px; }
  .ambient-orb.orb-14 { top: 1320vh; right: -300px; left: auto; }
  .ambient-orb.orb-15 { top: 1420vh; left: -300px; }
  .ambient-orb.orb-16 { top: 1520vh; right: -300px; left: auto; }
  .ambient-orb.orb-17 { top: 1620vh; left: -300px; }
  .ambient-orb.orb-18 { top: 1720vh; right: -300px; left: auto; }
  .ambient-orb.orb-19 { top: 1820vh; left: -300px; }
  .ambient-orb.orb-20 { top: 1920vh; right: -300px; left: auto; }
  .ambient-orb.orb-21 { top: 2020vh; left: -300px; }
  .ambient-orb.orb-22 { top: 2120vh; right: -300px; left: auto; }
  .ambient-orb.orb-23 { top: 2220vh; left: -300px; }
  .ambient-orb.orb-24 { top: 2320vh; right: -300px; left: auto; }
}
