:root {
  --bg: #04050B;
  --panel: #090A14;
  --panel-2: #101325;
  --fg: #EAF1FF;
  --muted: rgba(234, 241, 255, 0.66);
  --line: rgba(234, 241, 255, 0.12);
  --line-strong: rgba(185, 167, 255, 0.34);
  --lilac: #B9A7FF;
  --rose: #F29ED8;
  --ice: #9CD5FF;
  --font-display: 'Amiri', Georgia, serif;
  --font-body: 'IBM Plex Sans Arabic', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  line-height: 1.7;
  letter-spacing: 0;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; color: inherit; }
img, canvas, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; letter-spacing: 0; }

.bidi {
  display: inline-block;
  unicode-bidi: isolate;
}

.fw-container {
  width: min(1220px, calc(100% - 40px));
  margin-inline: auto;
}

/* Architectural subtle grid lines */
.fw-grid-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(to left, rgba(234, 241, 255, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(234, 241, 255, 0.035) 1px, transparent 1px);
  background-size: 25vw 260px;
}

/* Floating Pill Navbar */
.fw-header {
  position: fixed;
  top: 16px;
  inset-inline: 0;
  z-index: 80;
  display: flex;
  justify-content: center;
  padding-inline: 16px;
  pointer-events: none;
}

.fw-nav-pill {
  pointer-events: auto;
  width: min(1040px, 100%);
  min-height: 58px;
  padding: 7px 10px 7px 10px;
  padding-inline-start: 20px;
  border-radius: 999px;
  background: rgba(9, 10, 20, 0.86);
  border: 1px solid var(--line);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}

.fw-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
}

.fw-brand-mark {
  width: 24px;
  height: 24px;
  color: var(--lilac);
  flex-shrink: 0;
}

.fw-brand-en {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.fw-nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  list-style: none;
  margin: 0;
  padding: 0;
  white-space: nowrap;
}

.fw-nav-links a {
  font-size: 13.5px;
  color: var(--muted);
  transition: color 0.25s var(--ease);
}

.fw-nav-links a:hover { color: var(--fg); }

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

.fw-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 600;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s;
  cursor: pointer;
  border: 0;
  white-space: nowrap;
}

.fw-pill:hover { transform: translateY(-2px); }

.fw-pill-solid {
  background: var(--fg);
  color: var(--bg);
  box-shadow: 0 8px 28px rgba(185, 167, 255, 0.22);
}

.fw-pill-ghost {
  background: rgba(234, 241, 255, 0.04);
  color: var(--fg);
  border: 1px solid rgba(234, 241, 255, 0.24);
  backdrop-filter: blur(10px);
}

.fw-pill-sm {
  padding: 8px 15px;
  font-size: 12.5px;
}

/* 1. Hero 100svh */
.fw-hero {
  position: relative;
  min-height: 100svh;
  padding: 112px 0 68px;
  display: flex;
  align-items: center;
  overflow: clip;
  isolation: isolate;
  z-index: 1;
}

.fw-hero-word {
  position: absolute;
  inset-inline-end: 2vw;
  bottom: 28px;
  z-index: -1;
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(9rem, 22vw, 22rem);
  line-height: 0.95;
  color: transparent;
  -webkit-text-stroke: 1px rgba(185, 167, 255, 0.24);
  pointer-events: none;
  user-select: none;
}

.fw-hero-grid {
  display: grid;
  grid-template-columns: 1.04fr 0.96fr;
  gap: 36px;
  align-items: center;
}

.fw-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(9, 10, 20, 0.72);
  margin-bottom: 20px;
  font-size: 12px;
}

.fw-chip-badge {
  padding: 3px 9px;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--lilac), var(--rose));
  color: #06070F;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 10.5px;
  letter-spacing: 0.08em;
}

.fw-chip-text {
  color: var(--muted);
  font-size: 12.5px;
}

.fw-h1 {
  font-family: var(--font-display);
  font-size: clamp(2.55rem, 4.7vw, 4.35rem);
  font-weight: 400;
  line-height: 1.32;
  margin-bottom: 20px;
}

.fw-grad-em {
  font-style: italic;
  background: linear-gradient(110deg, var(--ice) 0%, var(--lilac) 48%, var(--rose) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.fw-lead {
  font-size: 16.5px;
  color: var(--muted);
  max-width: 540px;
  margin-bottom: 28px;
}

.fw-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 36px;
}

.fw-trusted {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.fw-trusted-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: rgba(234, 241, 255, 0.45);
}

.fw-trusted-list {
  display: flex;
  align-items: center;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 19px;
  color: rgba(234, 241, 255, 0.82);
}

/* Interactive 3D Knot + Pixel-Lens Stage */
.fw-knot-stage {
  position: relative;
  aspect-ratio: 1.08 / 1;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: radial-gradient(circle at 52% 48%, rgba(185, 167, 255, 0.16), rgba(4, 5, 11, 0.96) 72%);
  overflow: hidden;
  cursor: crosshair;
}

.fw-knot-stage::before,
.fw-knot-stage::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border-color: rgba(234, 241, 255, 0.28);
  pointer-events: none;
  z-index: 4;
}

.fw-knot-stage::before {
  top: 38px;
  inset-inline-end: 20px;
  border-top: 1px solid;
  border-inline-end: 1px solid;
}

.fw-knot-stage::after {
  bottom: 38px;
  inset-inline-start: 20px;
  border-bottom: 1px solid;
  border-inline-start: 1px solid;
}

.fw-knot-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  transition: transform 0.6s var(--ease);
}

.fw-pixel-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.fw-stage-hud-top,
.fw-stage-hud-bot {
  position: absolute;
  inset-inline: 20px;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: rgba(234, 241, 255, 0.64);
  pointer-events: none;
}

.fw-stage-hud-top { top: 14px; }
.fw-stage-hud-bot { bottom: 14px; }

.fw-float-card {
  position: absolute;
  z-index: 6;
  padding: 16px 18px;
  border-radius: 20px;
  background: rgba(11, 13, 28, 0.82);
  border: 1px solid rgba(185, 167, 255, 0.24);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
  pointer-events: none;
}

.fw-float-sprint {
  top: 64px;
  inset-inline-start: 18px;
  width: 190px;
}

.fw-float-shipped {
  bottom: 54px;
  inset-inline-end: 22px;
  width: 204px;
}

.fw-float-kicker {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--muted);
  margin-bottom: 6px;
}

.fw-float-big {
  font-family: var(--font-display);
  font-size: 34px;
  line-height: 1.25;
}

.fw-float-sub {
  font-size: 12.5px;
  color: var(--muted);
}

.fw-sprint-bars {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 5px;
  margin-top: 10px;
}

.fw-sprint-bars span {
  height: 4px;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--lilac), var(--rose));
}

.fw-dots-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}

.fw-dots {
  display: flex;
}

.fw-dots i {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid var(--panel);
  margin-inline-end: -5px;
}

.fw-hero-footbar {
  position: absolute;
  bottom: 0;
  inset-inline: 0;
  border-top: 1px solid var(--line);
  padding: 11px 0;
  background: rgba(4, 5, 11, 0.72);
  backdrop-filter: blur(8px);
}

.fw-hero-footbar-in {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: rgba(234, 241, 255, 0.56);
}

/* Sections Common */
.fw-sec {
  position: relative;
  z-index: 1;
  padding: 108px 0;
  border-top: 1px solid var(--line);
}

.fw-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  color: var(--lilac);
  margin-bottom: 18px;
}

.fw-eyebrow::before {
  content: '';
  width: 26px;
  height: 1px;
  background: var(--lilac);
}

.fw-h2 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  font-weight: 400;
  line-height: 1.32;
  margin-bottom: 14px;
}

.fw-sec-sub {
  color: var(--muted);
  font-size: 16px;
  max-width: 560px;
  margin-bottom: 48px;
}

/* 2. Selected Work (Asymmetric 2x2 Folds) */
.fw-work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  align-items: start;
}

.fw-work-card {
  border-radius: 26px;
  border: 1px solid var(--line);
  background: var(--panel);
  overflow: hidden;
  transition: transform 0.35s var(--ease), border-color 0.35s var(--ease);
}

.fw-work-card:nth-child(even) {
  margin-top: 52px;
}

.fw-work-card:hover {
  transform: translateY(-6px);
  border-color: var(--line-strong);
}

.fw-work-art {
  position: relative;
  aspect-ratio: 16 / 11;
  background: radial-gradient(circle at 30% 25%, rgba(185, 167, 255, 0.2), #070914 75%);
  display: grid;
  place-items: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.fw-work-art svg {
  width: 84%;
  height: 84%;
}

.fw-work-year {
  position: absolute;
  top: 16px;
  inset-inline-end: 16px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(4, 5, 11, 0.7);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
}

.fw-work-body {
  padding: 24px 26px 28px;
}

.fw-work-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 8px;
}

.fw-work-title {
  font-family: var(--font-display);
  font-size: 28px;
  line-height: 1.32;
}

.fw-work-metric {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--lilac);
}

.fw-work-desc {
  color: var(--muted);
  font-size: 14.5px;
  margin-bottom: 16px;
}

.fw-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.fw-tag {
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  color: rgba(234, 241, 255, 0.76);
}

/* 3. Services Hairline Rows */
.fw-srv-row {
  display: grid;
  grid-template-columns: 60px 1.1fr 1.2fr 1fr 40px;
  gap: 24px;
  align-items: center;
  padding: 34px 0;
  border-top: 1px solid var(--line);
  transition: background 0.3s;
}

.fw-srv-row:last-child { border-bottom: 1px solid var(--line); }

.fw-srv-num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--lilac);
}

.fw-srv-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 2.8vw, 2.6rem);
  line-height: 1.32;
}

.fw-srv-desc {
  color: var(--muted);
  font-size: 15px;
}

.fw-srv-arrow {
  font-size: 20px;
  color: var(--lilac);
  text-align: end;
}

/* 4. Process + 3D Torus + Scope Estimator */
.fw-proc-top {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 32px;
  align-items: stretch;
  margin-bottom: 36px;
}

.fw-torus-box {
  position: relative;
  min-height: 340px;
  border-radius: 26px;
  border: 1px solid var(--line);
  background: var(--panel);
  overflow: hidden;
}

.fw-torus-canvas {
  width: 100%;
  height: 100%;
}

.fw-beats-col {
  display: grid;
  gap: 14px;
}

.fw-beat-card {
  padding: 20px 24px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--panel);
  display: grid;
  gap: 6px;
}

.fw-beat-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--lilac);
}

.fw-beat-card h3 {
  font-family: var(--font-display);
  font-size: 23px;
  line-height: 1.32;
}

.fw-beat-card p {
  font-size: 14px;
  color: var(--muted);
}

/* Scope Estimator */
.fw-sim-box {
  padding: 30px;
  border-radius: 26px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(145deg, rgba(16, 19, 37, 0.9), rgba(9, 10, 20, 0.95));
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 28px;
  align-items: center;
}

.fw-mode-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 20px;
}

.fw-mode-btn {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}

.fw-mode-btn.active {
  background: var(--lilac);
  color: #06070F;
  border-color: var(--lilac);
  font-weight: 600;
}

.fw-range {
  width: 100%;
  accent-color: var(--lilac);
  cursor: pointer;
}

.fw-sim-out {
  padding: 24px;
  border-radius: 20px;
  background: rgba(4, 5, 11, 0.72);
  border: 1px solid var(--line);
  text-align: center;
}

.fw-sim-weeks {
  font-family: var(--font-display);
  font-size: 52px;
  line-height: 1.25;
  color: var(--lilac);
}

/* 5. Journal + 6. Contact */
.fw-journal-list {
  border-top: 1px solid var(--line);
}

.fw-journal-row {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  transition: padding-inline-start 0.25s var(--ease);
}

.fw-journal-row:hover {
  padding-inline-start: 10px;
  color: var(--lilac);
}

.fw-contact-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 40px;
  align-items: start;
}

.fw-form {
  padding: 30px;
  border-radius: 26px;
  border: 1px solid var(--line);
  background: var(--panel);
  display: grid;
  gap: 16px;
}

.fw-input {
  width: 100%;
  padding: 13px 16px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(4, 5, 11, 0.7);
  color: var(--fg);
}

.fw-budget-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.fw-budget-chip {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 12.5px;
  cursor: pointer;
}

.fw-budget-chip.active {
  border-color: var(--lilac);
  background: rgba(185, 167, 255, 0.16);
  color: var(--lilac);
}

/* Footer */
.fw-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--line);
  padding: 52px 0 40px;
  background: #030409;
}

.fw-foot-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.fw-showcase-rail {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
}

/* Custom Magnetic Cursor */
.fw-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(185, 167, 255, 0.55);
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  transition: width 0.28s var(--ease), height 0.28s var(--ease), background 0.28s;
}

.fw-cursor span {
  font-size: 11px;
  font-weight: 700;
  color: #04050B;
  opacity: 0;
  transition: opacity 0.2s;
}

.fw-cursor.is-big {
  width: 78px;
  height: 78px;
  background: var(--ice);
  border-color: transparent;
}

.fw-cursor.is-big span { opacity: 1; }

@media (hover: none), (pointer: coarse) {
  .fw-cursor { display: none; }
}

@media (max-width: 720px) {
  .fw-nav-links { display: none; }
  .fw-hero-grid,
  .fw-work-grid,
  .fw-proc-top,
  .fw-sim-box,
  .fw-contact-grid { grid-template-columns: 1fr; }
  .fw-work-card:nth-child(even) { margin-top: 0; }
  .fw-srv-row { grid-template-columns: 1fr; gap: 10px; }
  .fw-journal-row { grid-template-columns: 1fr; gap: 6px; }
}
