/* ==========================================================================
   SARAH ELSAYED — AVANT-GARDE ARCHITECTURAL TECH DESIGN SYSTEM (ENGLISH LTR)
   Unique Spatial Bento Grid + Interactive 3D Command Deck + Glass Dock Nav
   ========================================================================== */

:root {
  /* Core Palette inspired by SE Logo */
  --bg: #050714;
  --bg-elevated: #0a0e24;
  --bg-glass: rgba(13, 18, 46, 0.72);
  --surface: rgba(20, 26, 66, 0.48);
  --surface-hover: rgba(32, 41, 98, 0.68);
  --text: #f3f5ff;
  --text-muted: #949bc7;
  --line: rgba(138, 79, 255, 0.16);
  --line-strong: rgba(138, 79, 255, 0.4);

  --accent: #8a4fff;
  --accent-light: #b68eff;
  --accent-cyan: #00f0ff;
  --accent-pink: #ff3b9a;
  --accent-emerald: #10b981;

  --grad-primary: linear-gradient(135deg, #8a4fff 0%, #c084fc 50%, #00f0ff 100%);
  --grad-surface: linear-gradient(160deg, rgba(138, 79, 255, 0.12) 0%, rgba(0, 240, 255, 0.03) 100%);
  --shadow-glow: 0 20px 60px -15px rgba(138, 79, 255, 0.34);
  --shadow-card: 0 24px 48px -12px rgba(2, 4, 18, 0.7);

  --r-sm: 14px;
  --r-md: 24px;
  --r-lg: 34px;
  --r-pill: 999px;

  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-display: 'Syne', 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

[data-theme="light"] {
  --bg: #f7f6fc;
  --bg-elevated: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.85);
  --surface: rgba(255, 255, 255, 0.9);
  --surface-hover: #ffffff;
  --text: #0a0e24;
  --text-muted: #525882;
  --line: rgba(10, 14, 36, 0.09);
  --line-strong: rgba(138, 79, 255, 0.4);
  --grad-surface: linear-gradient(160deg, rgba(138, 79, 255, 0.07) 0%, rgba(0, 240, 255, 0.03) 100%);
  --shadow-glow: 0 20px 50px -15px rgba(138, 79, 255, 0.22);
  --shadow-card: 0 20px 45px -15px rgba(13, 18, 50, 0.09);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 110px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
  position: relative;
  min-height: 100vh;
}

/* Architectural Blueprint Background Grid */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 25%, #000 35%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 25%, #000 35%, transparent 100%);
  pointer-events: none;
  z-index: -2;
  opacity: 0.45;
}

.ambient-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: -1;
  opacity: 0.28;
  transition: opacity 0.4s;
}
.orb-1 {
  width: 520px;
  height: 520px;
  background: var(--accent);
  top: -160px;
  right: -120px;
  animation: floatOrb 16s ease-in-out infinite alternate;
}
.orb-2 {
  width: 440px;
  height: 440px;
  background: var(--accent-cyan);
  bottom: -140px;
  left: -120px;
  animation: floatOrb 20s ease-in-out infinite alternate-reverse;
}
@keyframes floatOrb {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-50px, 45px) scale(1.12); }
}

.cursor-glow {
  position: fixed;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(138, 79, 255, 0.13) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
  transition: width 0.2s, height 0.2s;
}

img {
  max-width: 100%;
  display: block;
}
a {
  color: inherit;
  text-decoration: none;
}
ul {
  list-style: none;
}
button, input, textarea, select {
  font: inherit;
}

.container {
  width: min(1260px, 92%);
  margin-inline: auto;
  position: relative;
  z-index: 2;
}

.mono {
  font-family: var(--font-mono);
}

.grad-text {
  background: var(--grad-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Scroll Progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: var(--grad-primary);
  z-index: 1000;
  box-shadow: 0 0 15px var(--accent);
}

/* ==========================================================================
   UNIFIED FLOATING NAVBAR (DOCK ARCHITECTURE)
   ========================================================================== */
.site-header {
  position: fixed;
  top: 18px;
  left: 0;
  right: 0;
  z-index: 900;
  transition: top 0.3s ease;
}

.nav-dock {
  width: min(1260px, 94%);
  margin-inline: auto;
  background: var(--bg-glass);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: var(--shadow-card);
  transition: border-color 0.3s, background 0.3s, transform 0.3s;
}

.site-header.scrolled .nav-dock {
  border-color: var(--line-strong);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-inline: 6px;
}

.brand-logo-wrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #ffffff;
  display: grid;
  place-items: center;
  padding: 5px;
  box-shadow: 0 4px 15px rgba(138, 79, 255, 0.25);
  border: 1.5px solid rgba(138, 79, 255, 0.35);
  flex-shrink: 0;
}

.brand-logo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.brand-name {
  font-weight: 800;
  font-size: 1.02rem;
  letter-spacing: -0.3px;
}
.brand-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent-light);
}

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

.nav-link {
  position: relative;
  padding: 9px 16px;
  border-radius: var(--r-pill);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: color 0.25s, background 0.25s;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--text);
  background: rgba(138, 79, 255, 0.08);
}

.nav-link.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(138, 79, 255, 0.85), rgba(91, 33, 182, 0.85));
  box-shadow: 0 6px 20px rgba(138, 79, 255, 0.35);
}

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

.tool-btn {
  height: 40px;
  min-width: 40px;
  padding-inline: 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.25s;
}

.tool-btn:hover {
  border-color: var(--accent);
  color: var(--accent-light);
  transform: translateY(-2px);
}

.burger-btn {
  display: none;
}

/* ==========================================================================
   BUTTONS & BADGES
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, var(--accent) 0%, #5b21b6 100%);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.96rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  box-shadow: var(--shadow-glow);
  transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
  position: relative;
  overflow: hidden;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 55px -10px rgba(138, 79, 255, 0.55);
  filter: brightness(1.07);
}

.btn-sm {
  padding: 9px 20px;
  font-size: 0.86rem;
}

.btn-outline {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line-strong);
  box-shadow: none;
  backdrop-filter: blur(12px);
}

.btn-outline:hover {
  background: rgba(138, 79, 255, 0.14);
  border-color: var(--accent);
  color: var(--text);
  box-shadow: 0 12px 30px rgba(138, 79, 255, 0.18);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text);
  backdrop-filter: blur(10px);
}

.pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.22);
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  50% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-light);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "<";
  color: var(--accent-cyan);
}
.eyebrow::after {
  content: "/>";
  color: var(--accent-cyan);
}

/* ==========================================================================
   HERO & SPATIAL BENTO ARCHITECTURE
   ========================================================================== */
.hero-spatial {
  padding: 155px 0 80px;
  position: relative;
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 44px;
  align-items: center;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 4.7vw, 4.1rem);
  font-weight: 800;
  line-height: 1.12;
  margin: 20px 0;
  letter-spacing: -1.5px;
}

.hero-lead {
  font-size: 1.12rem;
  color: var(--text-muted);
  max-width: 620px;
  margin-bottom: 24px;
}

.typed-terminal {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--r-sm);
  background: rgba(10, 14, 36, 0.7);
  border: 1px solid var(--line-strong);
  color: var(--accent-cyan);
  font-family: var(--font-mono);
  font-size: 0.95rem;
  margin-bottom: 28px;
}
[data-theme="light"] .typed-terminal {
  background: #0d122e;
  color: #38bdf8;
}

.caret {
  display: inline-block;
  width: 8px;
  height: 1.15em;
  background: var(--accent-cyan);
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

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

/* 3D Interactive Command Deck in Hero */
.command-deck {
  position: relative;
  perspective: 1200px;
}

.deck-window {
  background: #080b1f;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-card), 0 0 60px rgba(138, 79, 255, 0.2);
  overflow: hidden;
  transition: transform 0.2s ease-out;
}

.deck-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.deck-dots {
  display: flex;
  gap: 8px;
}
.deck-dots i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ff5f56;
}
.deck-dots i:nth-child(2) { background: #ffbd2e; }
.deck-dots i:nth-child(3) { background: #27c93f; }

.deck-tabs {
  display: flex;
  gap: 6px;
}
.deck-tab {
  padding: 4px 12px;
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  background: transparent;
  color: #8b93c9;
  border: 1px solid transparent;
  cursor: pointer;
  transition: 0.2s;
}
.deck-tab.active {
  background: rgba(138, 79, 255, 0.2);
  color: #fff;
  border-color: rgba(138, 79, 255, 0.45);
}

.deck-body {
  padding: 24px;
  font-family: var(--font-mono);
  font-size: 0.87rem;
  line-height: 1.85;
  color: #e2e8f0;
  min-height: 270px;
}

.code-line { display: block; }
.c-com { color: #64748b; }
.c-key { color: #c084fc; }
.c-var { color: #38bdf8; }
.c-prop { color: #a5b4fc; }
.c-str { color: #4ade80; }
.c-num { color: #fb923c; }

.floating-badge {
  position: absolute;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  padding: 14px 20px;
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  gap: 12px;
  animation: floatCard 6s ease-in-out infinite;
}
.floating-badge b {
  font-size: 1.55rem;
  font-weight: 800;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.floating-badge span {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.3;
}
.fb-1 {
  bottom: -22px;
  left: -24px;
}
.fb-2 {
  top: -22px;
  right: -20px;
  animation-delay: -3s;
}
@keyframes floatCard {
  50% { transform: translateY(-10px); }
}

/* ==========================================================================
   INFINITE TECH & PARTNER MARQUEE
   ========================================================================== */
.marquee-strip {
  margin: 40px 0 20px;
  padding: 18px 0;
  border-block: 1px solid var(--line);
  background: rgba(138, 79, 255, 0.03);
  overflow: hidden;
}

.marquee-track {
  display: flex;
  width: max-content;
  gap: 42px;
  animation: scrollMarquee 32s linear infinite;
}
.marquee-strip:hover .marquee-track {
  animation-play-state: paused;
}

.marquee-item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}
.marquee-item i {
  color: var(--accent-cyan);
  font-style: normal;
}

@keyframes scrollMarquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ==========================================================================
   PAGE HERO (INTERNAL PAGES)
   ========================================================================== */
.page-hero {
  padding: 155px 0 65px;
  position: relative;
  text-align: center;
}

.page-hero-inner {
  max-width: 820px;
  margin-inline: auto;
}

.page-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4.5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
  margin: 12px 0 18px;
}

.page-subtitle {
  font-size: 1.12rem;
  color: var(--text-muted);
  max-width: 680px;
  margin-inline: auto;
}

/* ==========================================================================
   SECTIONS & BENTO MATRIX CARDS
   ========================================================================== */
.section {
  padding: 90px 0;
  position: relative;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 50px;
  flex-wrap: wrap;
}
.section-head.center {
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.4vw, 2.75rem);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -0.8px;
}

.section-desc {
  color: var(--text-muted);
  max-width: 580px;
  font-size: 1.02rem;
}

/* Bento Grid System */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
}

.bento-card {
  grid-column: span 4;
  background: var(--surface);
  background-image: var(--grad-surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 32px;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(16px);
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.35s, box-shadow 0.35s;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.bento-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(500px circle at var(--mx, 50%) var(--my, 50%), rgba(138, 79, 255, 0.14), transparent 40%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.bento-card:hover::before {
  opacity: 1;
}

.bento-card:hover {
  transform: translateY(-6px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-glow);
}

.span-12 { grid-column: span 12; }
.span-8  { grid-column: span 8; }
.span-7  { grid-column: span 7; }
.span-6  { grid-column: span 6; }
.span-5  { grid-column: span 5; }
.span-4  { grid-column: span 4; }
.span-3  { grid-column: span 3; }

.card-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: rgba(138, 79, 255, 0.15);
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
  color: var(--accent-light);
}

.bento-card h3 {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.bento-card p {
  color: var(--text-muted);
  font-size: 0.96rem;
}

.card-number {
  position: absolute;
  top: 22px;
  right: 26px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent-light);
  opacity: 0.65;
}

/* Metrics / Stats Strip */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.metric-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 30px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: 0.3s;
}
.metric-box:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
}
.metric-val {
  font-size: clamp(2.2rem, 3.5vw, 3rem);
  font-weight: 900;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.1;
  margin-bottom: 8px;
}
.metric-label {
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 600;
}

/* ==========================================================================
   PROJECTS SHOWCASE & CASE STUDY CARDS
   ========================================================================== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 42px;
}

.filter-chip {
  padding: 10px 22px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: 0.25s;
}
.filter-chip:hover,
.filter-chip.active {
  background: linear-gradient(135deg, var(--accent), #5b21b6);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 8px 24px rgba(138, 79, 255, 0.35);
}

.projects-matrix {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}
.project-card.hide {
  display: none;
}
.project-card:hover {
  transform: translateY(-8px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-glow);
}

.project-visual {
  height: 220px;
  position: relative;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}
.pv-1 { background: linear-gradient(135deg, #2e1065 0%, #7c3aed 60%, #06b6d4 100%); }
.pv-2 { background: linear-gradient(135deg, #0f172a 0%, #1d4ed8 55%, #38bdf8 100%); }
.pv-3 { background: linear-gradient(135deg, #3b0764 0%, #c026d3 60%, #f43f5e 100%); }
.pv-4 { background: linear-gradient(135deg, #064e3b 0%, #10b981 60%, #34d399 100%); }
.pv-5 { background: linear-gradient(135deg, #451a03 0%, #d97706 60%, #fbbf24 100%); }
.pv-6 { background: linear-gradient(135deg, #1e1b4b 0%, #6366f1 55%, #a855f7 100%); }

.project-visual::after {
  content: "<SE/>";
  position: absolute;
  bottom: -18px;
  right: 12px;
  font-family: var(--font-mono);
  font-weight: 900;
  font-size: 4.2rem;
  color: rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.project-top-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1;
}
.project-cat {
  padding: 5px 14px;
  border-radius: var(--r-pill);
  background: rgba(5, 7, 20, 0.55);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 700;
}
.project-year {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.85);
}

.project-kpi {
  z-index: 1;
  color: #fff;
}
.project-kpi strong {
  display: block;
  font-size: 1.55rem;
  font-weight: 900;
}
.project-kpi span {
  font-size: 0.8rem;
  opacity: 0.88;
}

.project-body {
  padding: 26px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
}

.project-body h3 {
  font-size: 1.22rem;
  font-weight: 800;
  margin-bottom: 8px;
}
.project-body p {
  color: var(--text-muted);
  font-size: 0.93rem;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tag-list span {
  padding: 4px 12px;
  border-radius: var(--r-pill);
  background: rgba(138, 79, 255, 0.1);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--accent-light);
}

.project-action {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--accent-light);
  background: none;
  border: 0;
  cursor: pointer;
  padding: 0;
  margin-top: 8px;
}
.project-action:hover {
  color: var(--accent-cyan);
}

/* ==========================================================================
   TIMELINE & SKILLS ARCHITECTURE (ABOUT PAGE)
   ========================================================================== */
.timeline-grid {
  position: relative;
  display: grid;
  gap: 24px;
  padding-left: 32px;
  border-left: 2px solid var(--line-strong);
}

.timeline-node {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 28px 32px;
  transition: 0.3s;
}
.timeline-node:hover {
  border-color: var(--accent);
  transform: translateX(4px);
}
.timeline-node::before {
  content: "";
  position: absolute;
  left: -41px;
  top: 32px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(138, 79, 255, 0.2);
}

.timeline-period {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--accent-cyan);
  margin-bottom: 6px;
  display: inline-block;
}

.skill-bars {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px 40px;
}
.skill-item-top {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  margin-bottom: 8px;
  font-size: 0.95rem;
}
.skill-track {
  height: 10px;
  border-radius: var(--r-pill);
  background: rgba(138, 79, 255, 0.12);
  overflow: hidden;
}
.skill-fill {
  height: 100%;
  width: var(--w, 90%);
  background: var(--grad-primary);
  border-radius: var(--r-pill);
}

/* ==========================================================================
   PARTNERS OF SUCCESS (LOGOS & TESTIMONIALS)
   ========================================================================== */
.partners-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.partner-tile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  transition: 0.3s;
}
.partner-tile:hover {
  border-color: var(--accent);
  transform: translateY(-6px);
  box-shadow: var(--shadow-glow);
}

.partner-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.partner-monogram {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(138, 79, 255, 0.25), rgba(0, 240, 255, 0.15));
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--text);
}
.partner-sector {
  font-size: 0.75rem;
  padding: 4px 12px;
  border-radius: var(--r-pill);
  background: rgba(138, 79, 255, 0.12);
  color: var(--accent-light);
  font-weight: 700;
}

.testimonial-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 32px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 22px;
}
.quote-mark {
  font-size: 2.6rem;
  line-height: 1;
  color: var(--accent-light);
  opacity: 0.5;
}
.testimonial-author {
  display: flex;
  align-items: center;
  gap: 14px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
}
.author-avatar {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--grad-primary);
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #fff;
}

/* ==========================================================================
   BLOG & TECHNICAL ARTICLES
   ========================================================================== */
.blog-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 38px;
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 260px;
  max-width: 400px;
}
.search-box input {
  width: 100%;
  padding: 13px 20px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--text);
  outline: none;
  transition: 0.25s;
}
.search-box input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 4px rgba(0, 240, 255, 0.12);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.article-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: 0.35s;
}
.article-card.hide {
  display: none;
}
.article-card:hover {
  transform: translateY(-7px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-glow);
}

.article-banner {
  padding: 26px;
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  position: relative;
}

.article-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.article-body {
  padding: 26px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}

.article-body h3 {
  font-size: 1.2rem;
  font-weight: 800;
  line-height: 1.4;
}

/* ==========================================================================
   MODAL DIALOG (FOR CASE STUDIES & BLOG ARTICLES)
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(3, 5, 16, 0.78);
  backdrop-filter: blur(12px);
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  width: min(760px, 100%);
  max-height: 86vh;
  overflow-y: auto;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-md);
  padding: 36px;
  box-shadow: var(--shadow-card);
  position: relative;
}

.modal-close {
  position: sticky;
  top: 0;
  float: right;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-size: 1.1rem;
}

/* ==========================================================================
   CONTACT PAGE & INTERACTIVE FORM
   ========================================================================== */
.contact-layout {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 40px;
  align-items: start;
}

.contact-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 38px;
}

.contact-channel {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
  background: rgba(138, 79, 255, 0.04);
  margin-bottom: 14px;
  transition: 0.25s;
}
.contact-channel:hover {
  border-color: var(--accent);
  transform: translateX(4px);
}
.channel-ico {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: rgba(138, 79, 255, 0.16);
  display: grid;
  place-items: center;
  font-size: 1.25rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}
.form-group.full {
  grid-column: 1 / -1;
}
.form-group label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
}
.form-control {
  width: 100%;
  padding: 14px 18px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-strong);
  background: rgba(10, 14, 36, 0.45);
  color: var(--text);
  outline: none;
  transition: 0.25s;
}
[data-theme="light"] .form-control {
  background: #f8f9ff;
}
.form-control:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 4px rgba(138, 79, 255, 0.15);
}
.form-control.invalid {
  border-color: #f87171;
}

/* ==========================================================================
   UNIFIED ARCHITECTURAL FOOTER
   ========================================================================== */
.site-footer {
  margin-top: 80px;
  border-top: 1px solid var(--line-strong);
  background: linear-gradient(180deg, transparent 0%, rgba(138, 79, 255, 0.06) 100%);
  padding: 80px 0 36px;
  position: relative;
}

.footer-cta-banner {
  background: linear-gradient(135deg, rgba(138, 79, 255, 0.22) 0%, rgba(10, 14, 36, 0.9) 100%);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-lg);
  padding: 48px;
  margin-bottom: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--line);
}

.footer-col h4 {
  font-size: 1.02rem;
  font-weight: 800;
  margin-bottom: 18px;
  color: var(--text);
}

.footer-links {
  display: grid;
  gap: 10px;
}
.footer-links a {
  color: var(--text-muted);
  font-size: 0.92rem;
  transition: 0.2s;
}
.footer-links a:hover {
  color: var(--accent-light);
  padding-left: 6px;
}

.social-row {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}
.social-btn {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.85rem;
  transition: 0.25s;
}
.social-btn:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-3px);
}

.footer-bottom {
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.back-to-top {
  position: fixed;
  bottom: 26px;
  right: 26px;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(135deg, var(--accent), #5b21b6);
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 800;
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px);
  transition: 0.3s;
  box-shadow: var(--shadow-glow);
}
.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

/* Reveal Animations (Fail-safe visible by default) */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.js-ready .reveal:not(.show) {
  opacity: 0;
  transform: translateY(28px);
}

/* ==========================================================================
   RESPONSIVE BREAKPOINTS
   ========================================================================== */
@media (max-width: 1040px) {
  .hero-layout,
  .contact-layout {
    grid-template-columns: 1fr;
  }
  .bento-card.span-8,
  .bento-card.span-7,
  .bento-card.span-6,
  .bento-card.span-5,
  .bento-card.span-4,
  .bento-card.span-3 {
    grid-column: span 6;
  }
  .projects-matrix,
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .partners-grid,
  .metrics-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .burger-btn {
    display: inline-flex;
  }
  .nav-links {
    position: absolute;
    top: calc(100% + 12px);
    left: 4%;
    right: 4%;
    background: var(--bg-elevated);
    border: 1px solid var(--line-strong);
    border-radius: var(--r-md);
    padding: 20px;
    flex-direction: column;
    align-items: stretch;
    box-shadow: var(--shadow-card);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-12px);
    transition: 0.3s ease;
  }
  .nav-links.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }
}

@media (max-width: 680px) {
  .bento-card,
  .bento-card.span-8,
  .bento-card.span-7,
  .bento-card.span-6,
  .bento-card.span-5,
  .bento-card.span-4,
  .bento-card.span-3 {
    grid-column: span 12;
  }
  .projects-matrix,
  .blog-grid,
  .partners-grid,
  .metrics-grid,
  .skill-bars,
  .form-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .footer-cta-banner {
    padding: 30px 24px;
  }
  .fb-1, .fb-2 {
    position: static;
    margin-top: 12px;
  }
}
