/* ============================================================
   SHAJ Technologies Ltd
   Main stylesheet for index.html
   ============================================================ */

:root {
  /* Brand palette — sampled directly from the SHAJ logo */
  --blue: #004aad;        /* royal blue — centerpiece + primary accent */
  --blue-2: #003d99;      /* deeper blue for hover / accent text on light */
  --blue-glow: #6ea8ff;   /* light blue for accents on dark backgrounds */
  --indigo: #2b317d;      /* logo wordmark indigo */
  --gold: #f4cd1f;        /* logo gold arc */
  --gold-2: #d9b310;      /* deeper gold for text on light */
  --pink: #f64b6d;        /* logo pink arc */

  --navy: #131a4d;        /* deep indigo-navy, tuned to the logo family */
  --navy-2: #1e2568;

  /* Back-compat aliases: the HTML references these names inline,
     now repointed to the logo blue so the whole site follows the brand. */
  --teal: var(--blue);
  --teal-2: var(--blue-2);
  --teal-glow: var(--blue-glow);

  --off-white: #f6f8fb;
  --white: #ffffff;
  --slate: #64748b;
  --line: #e2e8f0;
  --text: #172033;
  --shadow: 0 12px 35px rgba(19, 26, 77, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--white);
  font-family: "Inter", sans-serif;
  line-height: 1.6;
}

img {
  max-width: 100%;
  display: block;
}

a {
  text-decoration: none;
}

button,
input {
  font: inherit;
}

/* ============================================================
   Layout
   ============================================================ */

.container-x {
  width: min(1180px, calc(100% - 40px));
  margin-left: auto;
  margin-right: auto;
}

.section {
  padding: 6rem 0;
}

.bg-off {
  background: var(--off-white);
}

.bg-navy {
  background: var(--navy);
}

.bg-navy-grad {
  background:
    radial-gradient(circle at 82% 18%, rgba(110, 168, 255, 0.18), transparent 34%),
    radial-gradient(circle at 12% 88%, rgba(246, 75, 109, 0.1), transparent 34%),
    linear-gradient(135deg, var(--navy), var(--navy-2));
}

/* ============================================================
   Navbar
   ============================================================ */

.navbar {
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid transparent;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.navbar.scrolled {
  box-shadow: 0 8px 30px rgba(15, 38, 71, 0.08);
  border-color: var(--line);
}

.nav-link {
  position: relative;
  color: var(--navy);
  font-size: 0.92rem;
  font-weight: 600;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--teal-2);
}

.nav-link.active::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -9px;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: var(--teal);
}

.mobile-menu {
  display: none;
}

.mobile-menu.open {
  display: block;
}

/* ============================================================
   Buttons
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  border-radius: 0.75rem;
  padding: 0.82rem 1.25rem;
  font-size: 0.92rem;
  font-weight: 700;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease,
    color 0.2s ease;
}

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

.btn-primary {
  color: #ffffff;
  background: var(--blue);
  box-shadow: 0 10px 25px rgba(0, 74, 173, 0.28);
}

.btn-primary:hover {
  background: var(--blue-2);
  box-shadow: 0 14px 30px rgba(0, 74, 173, 0.38);
}

.btn-secondary {
  color: #e8effa;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
}

.btn-secondary:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.12);
}

.btn-outline-navy {
  color: var(--navy);
  border-color: var(--navy);
  background: transparent;
}

.btn-outline-navy:hover {
  color: var(--white);
  background: var(--navy);
}

.btn-sm {
  padding: 0.62rem 0.95rem;
  font-size: 0.82rem;
}

/* ============================================================
   Typography / components
   ============================================================ */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--teal-2);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--teal);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.42rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--navy);
  background: var(--white);
  font-size: 0.74rem;
  font-weight: 600;
}

.grad-text {
  background: linear-gradient(90deg, var(--blue-glow), var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.card {
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--white);
  box-shadow: 0 6px 22px rgba(15, 38, 71, 0.04);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.card:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 74, 173, 0.35);
  box-shadow: var(--shadow);
}

.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.8rem;
  height: 2.8rem;
  border-radius: 0.8rem;
  color: var(--teal-2);
  background: rgba(0, 74, 173, 0.1);
  font-size: 1.1rem;
}

/* Logo-accent variants for icon tiles */
.card-icon.icon-gold {
  color: var(--gold-2);
  background: rgba(244, 205, 31, 0.16);
}
.card-icon.icon-pink {
  color: var(--pink);
  background: rgba(246, 75, 109, 0.12);
}
.card-icon.icon-indigo {
  color: var(--indigo);
  background: rgba(43, 49, 125, 0.12);
}

.card-flagship {
  position: relative;
  overflow: hidden;
  color: var(--white);
  border: 1px solid rgba(110, 168, 255, 0.16);
  background:
    radial-gradient(circle at 85% 15%, rgba(110, 168, 255, 0.24), transparent 32%),
    radial-gradient(circle at 8% 92%, rgba(244, 205, 31, 0.12), transparent 34%),
    linear-gradient(135deg, var(--navy), var(--navy-2));
}

.card-flagship::after {
  content: "";
  position: absolute;
  right: -80px;
  bottom: -80px;
  width: 230px;
  height: 230px;
  border: 1px solid rgba(110, 168, 255, 0.12);
  border-radius: 50%;
  box-shadow:
    0 0 0 35px rgba(110, 168, 255, 0.025),
    0 0 0 70px rgba(110, 168, 255, 0.02);
}

.badge-flagship {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  color: var(--gold);
  background: rgba(244, 205, 31, 0.12);
  border: 1px solid rgba(244, 205, 31, 0.28);
  font-size: 0.72rem;
  font-weight: 700;
}

.stat-number {
  margin: 0;
  color: var(--white);
  font-family: "Space Grotesk", sans-serif;
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
}

.stat-label {
  margin: 0.55rem 0 0;
  color: #9fb1ce;
  font-size: 0.82rem;
}

.hero-network-line {
  fill: none;
  stroke: url(#heroLineGrad);
  stroke-width: 1.5;
  stroke-dasharray: 7 7;
  animation: dash 3s linear infinite;
}

.hero-node {
  filter: drop-shadow(0 0 7px rgba(110, 168, 255, 0.65));
  animation: pulseNode 2.8s ease-in-out infinite;
}

.d2 { animation-delay: 0.4s; }
.d3 { animation-delay: 0.8s; }
.d4 { animation-delay: 1.2s; }
.d5 { animation-delay: 1.6s; }

.hero-packet {
  offset-rotate: 0deg;
  animation-name: packetMove;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}

.signal-rail {
  position: absolute;
  left: 0;
  top: 12%;
  bottom: 12%;
  width: 1px;
  background: linear-gradient(transparent, rgba(0, 74, 173, 0.35), transparent);
}

.signal-dot {
  position: absolute;
  left: -3px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 12px rgba(244, 205, 31, 0.75);
  animation: signalMove 5s linear infinite;
}

.quote-mark {
  display: block;
  height: 1.7rem;
  color: var(--teal);
  font-family: Georgia, serif;
  font-size: 4rem;
  line-height: 1;
}

.underline-teal {
  color: var(--navy);
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 0.65rem;
  color: #b8c6dc;
  transition: all 0.2s ease;
}

.social-icon:hover {
  color: var(--navy);
  background: var(--teal-glow);
  border-color: var(--teal-glow);
  transform: translateY(-2px);
}

.footer-link {
  color: #94a5c2;
  font-size: 0.88rem;
  transition: color 0.2s ease;
}

.footer-link:hover {
  color: var(--teal-glow);
}

.form-input {
  width: 100%;
  min-width: 0;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.65rem;
  outline: none;
}

.form-input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0, 74, 173, 0.15);
}

.section-divider {
  height: 1px;
  width: 100%;
}

/* ============================================================
   Animations
   ============================================================ */

@keyframes dash {
  to {
    stroke-dashoffset: -28;
  }
}

@keyframes pulseNode {
  0%, 100% {
    transform: scale(1);
    opacity: 0.85;
  }
  50% {
    transform: scale(1.18);
    opacity: 1;
  }
}

@keyframes packetMove {
  from {
    offset-distance: 0%;
  }
  to {
    offset-distance: 100%;
  }
}

@keyframes signalMove {
  from {
    top: 0%;
    opacity: 0;
  }
  15%, 80% {
    opacity: 1;
  }
  to {
    top: 100%;
    opacity: 0;
  }
}

/* ============================================================
   Responsive adjustments
   ============================================================ */

@media (max-width: 1023px) {
  .section {
    padding: 4.5rem 0;
  }

  .nav-link.active::after {
    display: none;
  }

  .signal-rail {
    display: none;
  }
}

@media (max-width: 640px) {
  .container-x {
    width: min(100% - 28px, 1180px);
  }

  .section {
    padding: 4rem 0;
  }

  .stat-number {
    font-size: 2rem;
  }

  .card:hover {
    transform: none;
  }
}

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