/* NexCen homepage — preloader + compact fancy hero */
:root {
  --nx-blue-deep: #052c65;
  --nx-blue: #0d6efd;
  --nx-blue-soft: #6ea8fe;
  --nx-gold: #ffc221;
  --nx-footer: #070b3b;
  --nxh-font: "Outfit", system-ui, sans-serif;
  --nxh-display: "Fraunces", Georgia, serif;
}

/* —— Preloader —— */
.nx-preloader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(900px 480px at 50% 35%, #0d6efd 0%, #052c65 55%, #031833 100%);
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
.nx-preloader.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.nx-preloader__inner { text-align: center; }
.nx-preloader__mark {
  width: clamp(220px, 42vw, 340px);
  height: auto;
  margin: 0 auto 18px;
  animation: nxMarkIn 0.85s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.nx-preloader__mark img {
  width: 100%;
  height: auto;
  display: block;
  filter: drop-shadow(0 12px 28px rgba(0, 0, 0, 0.35));
}
.nx-preloader__bar {
  width: 140px;
  height: 2px;
  margin: 16px auto 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.18);
  overflow: hidden;
}
.nx-preloader__bar > span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #ffe08a, var(--nx-gold));
  animation: nxLoadBar 1.1s ease-in-out forwards;
}

@keyframes nxMarkIn {
  from { opacity: 0; transform: scale(0.7); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes nxRise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes nxLoadBar {
  from { width: 0; }
  to { width: 100%; }
}

/* —— Hero: content height (not full screen) —— */
.nx-hero {
  --pad-x: clamp(16px, 4vw, 56px);
  --pad-top: clamp(92px, 10vh, 112px);
  --pad-bottom: clamp(28px, 4vh, 40px);

  position: relative;
  min-height: 0;
  overflow: hidden;
  color: #fff;
  font-family: var(--nxh-font);
  background:
    radial-gradient(ellipse 80% 60% at 85% 35%, rgba(13, 110, 253, 0.55) 0%, transparent 55%),
    radial-gradient(ellipse 50% 45% at 10% 80%, rgba(255, 194, 33, 0.12) 0%, transparent 50%),
    linear-gradient(145deg, #031833 0%, #052c65 40%, #0a4bb8 78%, #1a5fd4 100%);
  isolation: isolate;
  margin-bottom: 0;
  box-sizing: border-box;
}

.nx-hero__wash {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.nx-hero__beam {
  position: absolute;
  width: 140%;
  height: 55%;
  top: -20%;
  left: -20%;
  background: radial-gradient(ellipse at center, rgba(255, 194, 33, 0.18) 0%, transparent 62%);
  transform: rotate(-12deg);
  animation: nxBeam 10s ease-in-out infinite alternate;
}
.nx-hero__mesh {
  position: absolute;
  inset: 0;
  opacity: 0.4;
  background-image:
    repeating-linear-gradient(
      -28deg,
      transparent 0,
      transparent 18px,
      rgba(255, 255, 255, 0.045) 18px,
      rgba(255, 255, 255, 0.045) 19px
    );
  mask-image: linear-gradient(90deg, transparent, #000 30%, #000 70%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 30%, #000 70%, transparent);
}
.nx-hero__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
  opacity: 0.7;
}
.nx-hero__orb--1 {
  width: 180px;
  height: 180px;
  right: 8%;
  top: 18%;
  background: radial-gradient(circle, rgba(110, 168, 254, 0.45) 0%, transparent 70%);
  animation: nxOrb 8s ease-in-out infinite alternate;
}
.nx-hero__orb--2 {
  width: 120px;
  height: 120px;
  left: 42%;
  bottom: 18%;
  background: radial-gradient(circle, rgba(255, 194, 33, 0.28) 0%, transparent 70%);
  animation: nxOrb 11s ease-in-out infinite alternate-reverse;
}
.nx-hero__spark {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
  animation: nxSpark 3.2s ease-in-out infinite;
}
.nx-hero__spark--1 { top: 22%; left: 48%; }
.nx-hero__spark--2 { top: 48%; right: 28%; background: var(--nx-gold); box-shadow: 0 0 12px rgba(255, 194, 33, 0.9); animation-delay: 0.6s; }
.nx-hero__spark--3 { bottom: 28%; left: 58%; animation-delay: 1.1s; }
.nx-hero__spark--4 { top: 34%; right: 12%; background: var(--nx-blue-soft); animation-delay: 1.7s; }

.nx-hero__frame {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  min-height: 0;
  padding: var(--pad-top) var(--pad-x) var(--pad-bottom);
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(16px, 3vw, 32px);
  align-items: center;
}

.nx-hero__stage {
  max-width: 46rem;
  animation: nxRise 0.7s ease both;
}

.nx-hero__brand {
  margin: 0 0 0.1em;
  font-family: var(--nxh-display);
  font-size: clamp(2.35rem, 5.5vw, 3.6rem);
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: -0.045em;
  color: #fff;
  text-shadow: 0 8px 32px rgba(3, 24, 51, 0.35);
}
.nx-hero__brand::after {
  content: "";
  display: block;
  width: 3rem;
  height: 3px;
  margin-top: 0.35em;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--nx-gold), transparent);
  box-shadow: 0 0 18px rgba(255, 194, 33, 0.55);
}

.nx-hero__headline {
  margin: 0 0 0.4rem;
  max-width: 24ch;
  font-size: clamp(1.1rem, 2.1vw, 1.45rem);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: #fff;
}

.nx-hero__text {
  margin: 0 0 0.85rem;
  max-width: 46ch;
  font-size: clamp(0.88rem, 1.3vw, 0.98rem);
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.88);
}

.nx-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.nx-hero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.5rem;
  padding: 0 1.1rem;
  border-radius: 0.45rem;
  font-size: 0.88rem;
  font-weight: 700;
  text-decoration: none !important;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}
.nx-hero__btn--gold {
  background: linear-gradient(135deg, #ffe08a, var(--nx-gold));
  color: #052c65 !important;
  border: 1px solid var(--nx-gold);
  box-shadow: 0 10px 24px rgba(255, 194, 33, 0.32);
}
.nx-hero__btn--gold:hover {
  transform: translateY(-2px);
  background: #ffd24d;
  color: #052c65 !important;
}
.nx-hero__btn--line {
  background: rgba(255, 255, 255, 0.06);
  color: #fff !important;
  border: 1.5px solid rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(6px);
}
.nx-hero__btn--line:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.14);
  color: #fff !important;
}

.nx-hero__rail {
  position: relative;
  display: grid;
  gap: 10px;
  width: 100%;
  max-width: 420px;
  margin-left: auto;
  padding: 8px;
  animation: nxRise 0.85s ease 0.12s both;
}
.nx-hero__rail-glow {
  position: absolute;
  inset: -6% -10% -10% -6%;
  z-index: 0;
  border-radius: 32px;
  background:
    radial-gradient(ellipse at 70% 20%, rgba(255, 194, 33, 0.28), transparent 55%),
    radial-gradient(ellipse at 30% 80%, rgba(110, 168, 254, 0.35), transparent 50%);
  filter: blur(10px);
  pointer-events: none;
  animation: nxGlowPulse 5s ease-in-out infinite;
}

.nx-lane {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px 12px 12px 10px;
  min-height: 0;
  text-decoration: none !important;
  color: #fff !important;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid transparent;
  background:
    linear-gradient(#0a3a8a, #052c65) padding-box,
    linear-gradient(135deg, rgba(255, 255, 255, 0.55), rgba(255, 194, 33, 0.45), rgba(110, 168, 254, 0.35)) border-box;
  box-shadow:
    0 12px 28px rgba(3, 24, 51, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.nx-lane--ai { transform: translateX(0); }
.nx-lane--erp { transform: translateX(12px); }
.nx-lane--web { transform: translateX(4px); }

.nx-lane::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
}
.nx-lane--ai::before {
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.2) 0%, transparent 42%),
    linear-gradient(160deg, #1f6ae0 0%, #052c65 78%);
}
.nx-lane--erp::before {
  background:
    linear-gradient(125deg, rgba(255, 194, 33, 0.24) 0%, transparent 40%),
    linear-gradient(160deg, #0d6efd 0%, #031833 80%);
}
.nx-lane--web::before {
  background:
    linear-gradient(125deg, rgba(110, 168, 254, 0.38) 0%, transparent 42%),
    linear-gradient(160deg, #3d8bfd 0%, #052c65 80%);
}
.nx-lane::after {
  content: "";
  position: absolute;
  top: 0;
  left: -40%;
  width: 40%;
  height: 100%;
  z-index: 2;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.22), transparent);
  transform: skewX(-18deg);
  animation: nxShine 5.5s ease-in-out infinite;
  pointer-events: none;
}
.nx-lane > * {
  position: relative;
  z-index: 1;
}

.nx-lane__motif {
  position: absolute;
  right: -6px;
  bottom: -8px;
  width: 110px;
  height: 72px;
  color: rgba(255, 255, 255, 0.18);
  pointer-events: none;
  z-index: 0;
}
.nx-lane__motif svg {
  width: 100%;
  height: 100%;
  display: block;
}

.nx-lane__icon {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
}
.nx-lane__icon svg {
  width: 22px;
  height: 22px;
  display: block;
}
.nx-lane--erp .nx-lane__icon {
  color: #052c65;
  background: linear-gradient(145deg, #ffe08a, var(--nx-gold));
  border-color: rgba(255, 194, 33, 0.55);
  box-shadow: 0 6px 16px rgba(255, 194, 33, 0.35);
}

.nx-lane__body {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.nx-lane__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}
.nx-lane__name {
  font-size: 1.12rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.nx-lane--erp .nx-lane__name {
  font-size: 0.98rem;
  letter-spacing: -0.02em;
}
.nx-lane__index {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.5);
}
.nx-lane__sub {
  font-size: 0.74rem;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.84);
}
.nx-lane__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 3px;
}
.nx-lane__tags em {
  font-style: normal;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 2px 7px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.nx-lane__cta {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 1px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--nx-gold);
  white-space: nowrap;
  opacity: 0.95;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nx-lane__cta i { font-size: 1rem; }

.nx-lane:hover,
.nx-lane:focus {
  transform: translateY(-3px) translateX(0);
  box-shadow:
    0 18px 36px rgba(3, 24, 51, 0.42),
    0 0 0 1px rgba(255, 194, 33, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  color: #fff !important;
}
.nx-lane--erp:hover,
.nx-lane--erp:focus {
  transform: translateY(-3px) translateX(12px);
}
.nx-lane--web:hover,
.nx-lane--web:focus {
  transform: translateY(-3px) translateX(4px);
}
.nx-lane:hover .nx-lane__cta,
.nx-lane:focus .nx-lane__cta {
  opacity: 1;
  transform: translateX(3px);
}
.nx-lane:hover .nx-lane__motif {
  color: rgba(255, 255, 255, 0.3);
}

/* Homepage spacing under hero */
body:has(.nx-hero) #loading {
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  line-height: 0;
}
body:has(.nx-hero) .footer-area {
  margin-top: 0 !important;
  clear: both;
  position: relative;
  z-index: 1;
}
body:has(.nx-hero) .footer-area .footer-top {
  padding-top: 100px !important;
  padding-bottom: 70px !important;
}

@keyframes nxBeam {
  from { transform: rotate(-12deg) translate3d(0, 0, 0); }
  to { transform: rotate(-12deg) translate3d(4%, 6%, 0); }
}
@keyframes nxOrb {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(6%, -8%, 0) scale(1.08); }
}
@keyframes nxSpark {
  0%, 100% { opacity: 0.25; transform: scale(0.7); }
  50% { opacity: 1; transform: scale(1.15); }
}
@keyframes nxGlowPulse {
  0%, 100% { opacity: 0.75; }
  50% { opacity: 1; }
}
@keyframes nxShine {
  0%, 55% { left: -40%; opacity: 0; }
  60% { opacity: 1; }
  85% { left: 120%; opacity: 0.5; }
  100% { left: 120%; opacity: 0; }
}

@media (max-width: 991px) {
  .nx-hero__frame {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .nx-hero__headline { max-width: 22ch; }
  .nx-hero__rail {
    max-width: none;
    margin-left: 0;
    padding: 0;
  }
  .nx-lane--ai,
  .nx-lane--erp,
  .nx-lane--web {
    transform: none;
  }
  .nx-lane--erp:hover,
  .nx-lane--erp:focus,
  .nx-lane--web:hover,
  .nx-lane--web:focus {
    transform: translateY(-3px);
  }
}

@media (max-width: 575px) {
  .nx-hero {
    --pad-top: 92px;
    --pad-bottom: 4px;
  }
  .nx-hero__brand {
    font-size: clamp(2.2rem, 11vw, 2.8rem);
  }
  .nx-hero__headline {
    max-width: none;
    font-size: 1.1rem;
  }
  .nx-hero__text { max-width: none; }
  .nx-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }
  .nx-hero__btn { width: 100%; }
  .nx-lane {
    grid-template-columns: auto 1fr;
    padding: 11px;
  }
  .nx-lane__cta { display: none; }
  .nx-lane__motif { opacity: 0.5; }
}

@media (prefers-reduced-motion: reduce) {
  .nx-hero__beam,
  .nx-hero__orb,
  .nx-hero__spark,
  .nx-hero__rail-glow,
  .nx-lane::after,
  .nx-preloader__mark,
  .nx-hero__stage,
  .nx-hero__rail {
    animation: none !important;
  }
}
