/* =========================================================
   Bahij font
   ضع ملف الخط المرخّص داخل assets/fonts باسم:
   BahijTheSansArabic.woff2
   ========================================================= */
@font-face {
  font-family: "Bahij";
  src: url("../fonts/BahijTheSansArabic.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #050914;
  --bg-soft: #091121;
  --surface: rgba(255, 255, 255, 0.055);
  --surface-strong: rgba(255, 255, 255, 0.085);
  --line: rgba(255, 255, 255, 0.11);
  --text: #f8faff;
  --muted: #98a5ba;
  --blue: #5ca8ff;
  --violet: #816cff;
  --cyan: #67e8f9;
  --green: #60d9a7;
  --shadow: 0 45px 120px rgba(0, 0, 0, 0.55);
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow: hidden;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 12%, rgba(92, 168, 255, 0.13), transparent 29%),
    radial-gradient(circle at 89% 88%, rgba(129, 108, 255, 0.14), transparent 31%),
    linear-gradient(145deg, var(--bg), var(--bg-soft));
  font-family: "Bahij", Tahoma, Arial, sans-serif;
}

button,
input,
textarea,
select {
  font: inherit;
}

#networkCanvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.72;
}

.noise {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.035;
  background-image:
    url("data:image/svg+xml,%3Csvg viewBox='0 0 220 220' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.78' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.8'/%3E%3C/svg%3E");
}

.glow {
  position: fixed;
  z-index: 0;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  filter: blur(30px);
  pointer-events: none;
  opacity: 0.32;
  animation: glowFloat 11s ease-in-out infinite;
}

.glow--one {
  top: -130px;
  right: -90px;
  background: radial-gradient(circle, rgba(92, 168, 255, 0.65), transparent 67%);
}

.glow--two {
  bottom: -165px;
  left: -120px;
  background: radial-gradient(circle, rgba(129, 108, 255, 0.58), transparent 67%);
  animation-delay: -5s;
}

.page {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 36px));
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  place-items: center;
  padding: 28px 0;
}

.hero {
  position: relative;
  width: 100%;
  min-height: 650px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 36px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.072), rgba(255, 255, 255, 0.018)),
    rgba(5, 10, 22, 0.42);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: var(--shadow);
  animation: heroEntrance 0.95s cubic-bezier(.16, .84, .24, 1) both;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    125deg,
    rgba(255, 255, 255, 0.2),
    transparent 35%,
    transparent 68%,
    rgba(92, 168, 255, 0.23)
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  top: -180%;
  left: -40%;
  width: 24%;
  height: 380%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.045),
    transparent
  );
  transform: rotate(23deg);
  animation: sweep 8s ease-in-out infinite;
  pointer-events: none;
}

.top-line {
  position: absolute;
  top: 34px;
  right: 38px;
  left: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 4;
}

.secure-state,
.portal-label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
}

.secure-state {
  color: #cbf8e7;
}

.secure-state__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 rgba(96, 217, 167, 0.45);
  animation: securePulse 2.1s infinite;
}

.portal-label {
  color: var(--muted);
  letter-spacing: 0.02em;
}

.content {
  position: relative;
  z-index: 3;
  width: 57%;
  min-height: 650px;
  padding: 105px 68px 70px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.eyebrow {
  width: max-content;
  margin-bottom: 24px;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: #c9d4e3;
  font-size: 14px;
}

.eyebrow span {
  width: 34px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan));
  box-shadow: 0 0 12px rgba(103, 232, 249, 0.5);
}

h1 {
  margin: 0;
  line-height: 0.96;
  letter-spacing: -0.055em;
}

.title-line,
.title-gradient {
  display: block;
}

.title-line {
  font-size: clamp(52px, 6.2vw, 86px);
  font-weight: 400;
  color: #dfe6f0;
}

.title-gradient {
  margin-top: 9px;
  font-size: clamp(82px, 9vw, 132px);
  font-weight: 800;
  background:
    linear-gradient(
      90deg,
      #ffffff 0%,
      #8bc7ff 42%,
      #9e8aff 74%,
      #ffffff 100%
    );
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: titleLight 6s linear infinite;
}

.description {
  max-width: 610px;
  margin: 28px 0 34px;
  color: var(--muted);
  font-size: 17px;
  line-height: 2;
}

.status-card {
  width: min(100%, 570px);
  padding: 20px 21px 18px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.022));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.055),
    0 18px 45px rgba(0, 0, 0, 0.14);
}

.status-card__head {
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.status-card__head div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.status-card__head strong {
  font-size: 14px;
  font-weight: 700;
}

.status-card__head small {
  color: var(--muted);
  font-size: 11px;
}

.status-card__head > span {
  padding: 7px 12px;
  border: 1px solid rgba(92, 168, 255, 0.18);
  border-radius: 999px;
  color: #cfe7ff;
  background: rgba(92, 168, 255, 0.08);
  font-size: 11px;
}

.progress {
  position: relative;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.075);
}

.progress span {
  position: absolute;
  inset: 0 auto 0 0;
  width: 76%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--violet));
  box-shadow: 0 0 23px rgba(92, 168, 255, 0.38);
  transform-origin: right center;
  animation: progressLoad 1.65s cubic-bezier(.2, .76, .2, 1) 0.45s both;
}

.progress span::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 36%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.7), transparent);
  animation: progressSweep 2.4s linear infinite;
}

.status-card__foot {
  margin-top: 13px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: #77859b;
  font-size: 10px;
}

.visual {
  position: absolute;
  top: 50%;
  left: 6%;
  z-index: 2;
  width: 410px;
  height: 410px;
  display: grid;
  place-items: center;
  transform: translateY(-50%);
}

.visual::before {
  content: "";
  position: absolute;
  width: 77%;
  height: 77%;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(92, 168, 255, 0.12),
    rgba(129, 108, 255, 0.04) 45%,
    transparent 70%
  );
  filter: blur(4px);
  animation: visualBreath 5s ease-in-out infinite;
}

.orbital {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  animation: orbitSpin 18s linear infinite;
}

.orbital::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  border-top-color: rgba(92, 168, 255, 0.45);
  border-right-color: transparent;
  border-bottom-color: transparent;
  border-left-color: transparent;
  border-width: 1px;
  border-style: solid;
}

.orbital i {
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow:
    0 0 0 4px rgba(92, 168, 255, 0.08),
    0 0 22px rgba(92, 168, 255, 0.8);
}

.orbital i:nth-child(1) {
  top: 50%;
  left: -5px;
}

.orbital i:nth-child(2) {
  right: 13%;
  bottom: 14%;
  background: var(--violet);
  box-shadow:
    0 0 0 4px rgba(129, 108, 255, 0.08),
    0 0 22px rgba(129, 108, 255, 0.82);
}

.orbital--outer {
  inset: 5px;
}

.orbital--middle {
  inset: 59px;
  animation-duration: 13s;
  animation-direction: reverse;
}

.orbital--inner {
  inset: 114px;
  animation-duration: 9s;
}

.orbital--inner i {
  top: 10%;
  right: 17%;
  left: auto;
  background: var(--cyan);
  box-shadow:
    0 0 0 4px rgba(103, 232, 249, 0.08),
    0 0 20px rgba(103, 232, 249, 0.85);
}

.core {
  position: relative;
  z-index: 2;
  width: 150px;
  height: 150px;
  display: grid;
  place-content: center;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 42px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.025)),
    rgba(6, 13, 28, 0.76);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
  animation: coreFloat 4.5s ease-in-out infinite;
}

.core__pulse {
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(92, 168, 255, 0.22);
  border-radius: 30px;
  animation: corePulse 2.8s ease-out infinite;
}

.core strong {
  font-size: 29px;
  font-weight: 800;
}

.core small {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.float-card {
  position: absolute;
  z-index: 3;
  padding: 11px 15px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid rgba(255, 255, 255, 0.095);
  border-radius: 14px;
  color: #d8e2ee;
  background: rgba(5, 12, 25, 0.72);
  backdrop-filter: blur(12px);
  font-size: 11px;
  box-shadow: 0 13px 35px rgba(0, 0, 0, 0.2);
  animation: cardFloat 5s ease-in-out infinite;
}

.float-card span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 13px rgba(96, 217, 167, 0.7);
}

.float-card--one {
  top: 20%;
  right: -2%;
}

.float-card--two {
  bottom: 18%;
  left: -2%;
  animation-delay: -2.5s;
}

.float-card--two span {
  background: var(--blue);
  box-shadow: 0 0 13px rgba(92, 168, 255, 0.72);
}

footer {
  position: absolute;
  right: 68px;
  bottom: 31px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #69768b;
  font-size: 11px;
}

.footer-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #526078;
}

@keyframes heroEntrance {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes glowFloat {
  50% {
    transform: translate3d(24px, 22px, 0) scale(1.08);
  }
}

@keyframes securePulse {
  70% {
    box-shadow: 0 0 0 11px rgba(96, 217, 167, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(96, 217, 167, 0);
  }
}

@keyframes titleLight {
  to {
    background-position: -220% 0;
  }
}

@keyframes progressLoad {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

@keyframes progressSweep {
  from {
    transform: translateX(-160%);
  }
  to {
    transform: translateX(350%);
  }
}

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

@keyframes coreFloat {
  50% {
    transform: translateY(-12px) rotate(1deg);
  }
}

@keyframes corePulse {
  0% {
    opacity: 0.85;
    transform: scale(0.86);
  }
  75%,
  100% {
    opacity: 0;
    transform: scale(1.18);
  }
}

@keyframes visualBreath {
  50% {
    transform: scale(1.08);
    opacity: 0.8;
  }
}

@keyframes cardFloat {
  50% {
    transform: translateY(-11px);
  }
}

@keyframes sweep {
  0%,
  50% {
    left: -45%;
    opacity: 0;
  }
  60% {
    opacity: 1;
  }
  85%,
  100% {
    left: 120%;
    opacity: 0;
  }
}

@media (max-width: 980px) {
  body {
    overflow: auto;
  }

  .page {
    padding: 14px 0;
  }

  .hero {
    min-height: auto;
  }

  .content {
    width: 100%;
    min-height: 590px;
    padding: 105px 42px 65px;
    text-align: center;
    align-items: center;
  }

  .description {
    max-width: 680px;
  }

  .visual {
    position: relative;
    top: auto;
    left: auto;
    width: 360px;
    height: 360px;
    margin: -35px auto 65px;
    transform: none;
  }

  footer {
    right: 50%;
    bottom: 25px;
    transform: translateX(50%);
    white-space: nowrap;
  }
}

@media (max-width: 620px) {
  .page {
    width: min(100% - 18px, 1180px);
  }

  .hero {
    border-radius: 25px;
  }

  .top-line {
    top: 25px;
    right: 23px;
    left: 23px;
  }

  .portal-label {
    display: none;
  }

  .content {
    min-height: 560px;
    padding: 90px 23px 46px;
  }

  .eyebrow {
    margin-bottom: 20px;
    font-size: 12px;
  }

  .title-line {
    font-size: 46px;
  }

  .title-gradient {
    font-size: 78px;
  }

  .description {
    margin-top: 23px;
    font-size: 14px;
    line-height: 1.9;
  }

  .status-card {
    padding: 17px;
    border-radius: 17px;
  }

  .status-card__foot {
    gap: 6px;
    font-size: 9px;
  }

  .visual {
    width: 290px;
    height: 290px;
    margin-bottom: 66px;
  }

  .orbital--middle {
    inset: 44px;
  }

  .orbital--inner {
    inset: 86px;
  }

  .core {
    width: 118px;
    height: 118px;
    border-radius: 32px;
  }

  .core strong {
    font-size: 24px;
  }

  .float-card {
    padding: 9px 11px;
    font-size: 9px;
  }

  footer {
    font-size: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }

  #networkCanvas {
    display: none;
  }
}
