/* =========================================================
   Datasuraksha — Home hero slider
   Scoped with the .hx prefix so it never collides with styles.css
   ========================================================= */

.hx {
  --hx-dur: 7s;
  position: relative;
  overflow: hidden;
  color: var(--white);
  background: linear-gradient(160deg, #051427 0%, var(--navy-900) 35%, var(--navy-800) 75%, #0e3157 100%);
  isolation: isolate;
}

/* ---------- Animated background ---------- */
.hx__bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hx__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .55;
  animation: hxFloat 18s ease-in-out infinite alternate;
}
.hx__orb--a { width: 520px; height: 520px; left: -140px; top: -160px; background: radial-gradient(circle, rgba(9,182,140,.55), transparent 70%); }
.hx__orb--b { width: 460px; height: 460px; right: -120px; top: 10%; background: radial-gradient(circle, rgba(79,157,255,.40), transparent 70%); animation-duration: 22s; animation-delay: -6s; }
.hx__orb--c { width: 380px; height: 380px; left: 35%; bottom: -220px; background: radial-gradient(circle, rgba(47,208,172,.35), transparent 70%); animation-duration: 26s; animation-delay: -12s; }
@keyframes hxFloat {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(40px, 30px) scale(1.08); }
  100% { transform: translate(-30px, 50px) scale(.95); }
}
.hx__grid-lines {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 80%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 80%);
}

.hx__inner { padding-top: 64px; padding-bottom: 34px; }
.hx:focus-visible { outline: 2px solid var(--teal-400); outline-offset: -4px; }

/* ---------- Slides: stacked in one grid cell so height never jumps ---------- */
.hx__viewport { display: grid; }
.hx-slide {
  grid-area: 1 / 1;
  display: grid;
  grid-template-columns: 1.08fr .92fr;
  gap: 56px;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity .6s ease, visibility 0s linear .6s;
}
.hx-slide.is-active {
  opacity: 1;
  visibility: visible;
  transition: opacity .6s ease, visibility 0s;
}

/* Staggered entrance of copy */
.hx-slide__copy > * {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .7s cubic-bezier(.2,.7,.2,1);
}
.hx-slide.is-active .hx-slide__copy > * { opacity: 1; transform: none; }
.hx-slide.is-active .hx-slide__copy > *:nth-child(1) { transition-delay: .05s; }
.hx-slide.is-active .hx-slide__copy > *:nth-child(2) { transition-delay: .15s; }
.hx-slide.is-active .hx-slide__copy > *:nth-child(3) { transition-delay: .25s; }
.hx-slide.is-active .hx-slide__copy > *:nth-child(4) { transition-delay: .35s; }
.hx-slide.is-active .hx-slide__copy > *:nth-child(5) { transition-delay: .45s; }

/* ---------- Copy ---------- */
.hx-pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px 7px 12px;
  border-radius: 999px;
  background: rgba(9,182,140,.12);
  border: 1px solid rgba(47,208,172,.35);
  color: var(--teal-400);
  font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  margin-bottom: 20px;
}
.hx-pill__pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--teal-400);
  box-shadow: 0 0 0 0 rgba(47,208,172,.7);
  animation: hxPulse 2s infinite;
}
@keyframes hxPulse {
  0%   { box-shadow: 0 0 0 0 rgba(47,208,172,.6); }
  70%  { box-shadow: 0 0 0 10px rgba(47,208,172,0); }
  100% { box-shadow: 0 0 0 0 rgba(47,208,172,0); }
}

.hx h1, .hx .hx-h {
  color: var(--white);
  font-size: clamp(2.1rem, 4vw, 3.1rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
  font-weight: 800;
  margin: 0 0 20px;
}
.hx-grad {
  background: linear-gradient(95deg, #2fd0ac 0%, #5fe3c4 40%, #6fb4ff 100%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
}
.hx-lead {
  font-size: 1.14rem;
  color: #c9d6e3;
  max-width: 560px;
  margin: 0 0 28px;
}
.hx-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 30px; }
.hx-btn { padding: 14px 26px; border-radius: 10px; font-size: 1rem; }
.hx-btn.btn--primary {
  background: linear-gradient(135deg, var(--teal-500), #10c9a0);
  box-shadow: 0 10px 30px -8px rgba(9,182,140,.6);
}
.hx-btn.btn--primary:hover { box-shadow: 0 14px 34px -8px rgba(9,182,140,.75); background: linear-gradient(135deg, #0cc59a, var(--teal-400)); }
.hx-btn.btn--primary svg { transition: transform .2s ease; }
.hx-btn.btn--primary:hover svg { transform: translateX(3px); }
.hx-btn.btn--ghost { border-color: rgba(255,255,255,.28); background: rgba(255,255,255,.04); backdrop-filter: blur(4px); }

.hx-chips { display: flex; flex-wrap: wrap; gap: 10px 22px; }
.hx-chips li { display: flex; align-items: center; gap: 8px; font-size: .9rem; color: #aebfd0; }
.hx-chips svg {
  width: 18px; height: 18px; padding: 3px;
  border-radius: 50%;
  background: rgba(9,182,140,.18);
  fill: none; stroke: var(--teal-400); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round;
  flex-shrink: 0;
}

/* ---------- Visual side ---------- */
.hx-visual {
  position: relative;
  padding: 26px 10px 26px 26px;
  opacity: 0;
  transform: translateX(30px) scale(.97);
  transition: opacity .7s ease .15s, transform .8s cubic-bezier(.2,.7,.2,1) .15s;
}
.hx-slide.is-active .hx-visual { opacity: 1; transform: none; }

.hx-panel {
  position: relative;
  background: linear-gradient(160deg, rgba(255,255,255,.10), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 20px;
  box-shadow: 0 30px 70px -20px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.08);
  backdrop-filter: blur(12px);
  padding: 0 0 18px;
  overflow: hidden;
}
.hx-panel__bar {
  display: flex; align-items: center; gap: 6px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
}
.hx-panel__bar i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.2); }
.hx-panel__bar i:nth-child(1) { background: #ff6b6b; }
.hx-panel__bar i:nth-child(2) { background: #ffc44d; }
.hx-panel__bar i:nth-child(3) { background: #39d98a; }
.hx-panel__bar span { margin-left: 10px; font-size: .8rem; color: #9fb2c6; font-weight: 600; }
.hx-panel__body { display: grid; grid-template-columns: 132px 1fr; gap: 22px; align-items: center; padding: 22px 22px 6px; }
.hx-panel__note { margin: 12px 22px 0; text-align: right; font-size: .72rem; color: #7f93a8; text-transform: uppercase; letter-spacing: .08em; }

/* score ring */
.hx-score { position: relative; width: 132px; height: 132px; }
.hx-ring { width: 100%; height: 100%; transform: rotate(-90deg); }
.hx-ring__track { fill: none; stroke: rgba(255,255,255,.1); stroke-width: 10; }
.hx-ring__fill {
  fill: none; stroke-width: 10; stroke-linecap: round;
  stroke-dasharray: 314.16;
  stroke-dashoffset: 314.16;
  transition: stroke-dashoffset 1.6s cubic-bezier(.2,.7,.2,1) .4s;
}
.hx-slide.is-active .hx-ring__fill { stroke-dashoffset: 56.5; } /* 82% */
.hx-score__label { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.hx-score__label strong { font-size: 1.9rem; line-height: 1; color: var(--white); }
.hx-score__label span { font-size: .72rem; color: #9fb2c6; margin-top: 4px; }

/* bars */
.hx-bars { display: flex; flex-direction: column; gap: 13px; }
.hx-bar span { display: block; font-size: .78rem; color: #c3d1df; margin-bottom: 5px; font-weight: 600; }
.hx-bar b {
  display: block; height: 7px; border-radius: 99px;
  background: rgba(255,255,255,.08);
  position: relative; overflow: hidden;
}
.hx-bar b::after {
  content: ""; position: absolute; inset: 0 auto 0 0;
  width: 0; border-radius: inherit;
  background: linear-gradient(90deg, var(--teal-500), #6fb4ff);
  transition: width 1.3s cubic-bezier(.2,.7,.2,1);
}
.hx-slide.is-active .hx-bar b::after { width: var(--w); }
.hx-slide.is-active .hx-bar:nth-child(2) b::after { transition-delay: .55s; }
.hx-slide.is-active .hx-bar:nth-child(3) b::after { transition-delay: .7s; }
.hx-slide.is-active .hx-bar:nth-child(4) b::after { transition-delay: .85s; }
.hx-slide.is-active .hx-bar:nth-child(1) b::after { transition-delay: .4s; }

/* checklist */
.hx-checks { margin: 14px 22px 0; display: flex; flex-direction: column; gap: 9px; }
.hx-checks li {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px;
  border-radius: 10px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.06);
  font-size: .84rem; color: #d3dee9;
}
.hx-ok, .hx-warn { width: 18px; height: 18px; border-radius: 50%; flex-shrink: 0; position: relative; }
.hx-ok { background: rgba(57,217,138,.2); }
.hx-ok::after { content: ""; position: absolute; left: 6px; top: 3px; width: 4px; height: 8px; border: solid #39d98a; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.hx-warn { background: rgba(255,196,77,.2); }
.hx-warn::after { content: "!"; position: absolute; inset: 0; display: grid; place-items: center; font-size: .72rem; font-weight: 800; color: #ffc44d; }

/* floating badges */
.hx-float {
  position: absolute;
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.96);
  color: var(--navy-800);
  box-shadow: 0 18px 40px -12px rgba(0,0,0,.55);
  animation: hxBob 5s ease-in-out infinite;
}
.hx-float strong { display: block; font-size: .84rem; line-height: 1.2; }
.hx-float small { display: block; font-size: .72rem; color: var(--gray-600); }
.hx-float__icon {
  width: 30px; height: 30px; border-radius: 9px;
  display: grid; place-items: center;
  background: var(--teal-050); color: var(--teal-600); font-weight: 800;
}
.hx-float__icon--blue { background: #e8f1ff; color: #2f6fd6; }
.hx-float--a { top: 2px; right: -6px; }
.hx-float--b { bottom: -4px; left: -8px; animation-delay: -2.5s; }
@keyframes hxBob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* roles (slide 2) */
.hx-roles { display: flex; flex-direction: column; gap: 16px; }
.hx-role {
  display: flex; align-items: center; gap: 16px;
  padding: 20px 20px;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(255,255,255,.10), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.14);
  box-shadow: 0 20px 50px -24px rgba(0,0,0,.6);
  backdrop-filter: blur(10px);
  opacity: 0; transform: translateX(28px);
  transition: opacity .6s ease, transform .7s cubic-bezier(.2,.7,.2,1), border-color .2s ease;
}
.hx-role:nth-child(2) { margin-left: 28px; }
.hx-role:nth-child(3) { margin-left: 56px; }
.hx-slide.is-active .hx-role { opacity: 1; transform: none; }
.hx-slide.is-active .hx-role:nth-child(1) { transition-delay: .3s; }
.hx-slide.is-active .hx-role:nth-child(2) { transition-delay: .45s; }
.hx-slide.is-active .hx-role:nth-child(3) { transition-delay: .6s; }
.hx-role:hover { border-color: rgba(47,208,172,.5); }
.hx-role > div { flex: 1; min-width: 0; }
.hx-role strong { display: block; color: var(--white); font-size: 1.05rem; }
.hx-role small { display: block; color: #a9bbcd; font-size: .86rem; }
.hx-role__icon {
  width: 48px; height: 48px; border-radius: 14px; flex-shrink: 0;
  display: grid; place-items: center;
  background: rgba(9,182,140,.18);
}
.hx-role__icon svg { width: 24px; height: 24px; fill: none; stroke: var(--teal-400); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hx-role__icon--blue { background: rgba(79,157,255,.18); }
.hx-role__icon--blue svg { stroke: #7fb6ff; }
.hx-role__icon--violet { background: rgba(167,139,250,.18); }
.hx-role__icon--violet svg { stroke: #b9a4ff; }
.hx-role__tag {
  font-size: .72rem; font-weight: 700; letter-spacing: .04em;
  padding: 5px 10px; border-radius: 999px;
  background: rgba(255,255,255,.08); color: #d3dee9; white-space: nowrap;
}

/* vendor flow (slide 3) */
.hx-link {
  display: flex; align-items: center; gap: 10px;
  margin: 20px 22px 6px;
  padding: 8px 8px 8px 12px;
  border-radius: 12px;
  background: rgba(3,14,28,.55);
  border: 1px solid rgba(255,255,255,.1);
  font-size: .84rem; color: #c3d1df; font-family: Consolas, "SFMono-Regular", Menlo, monospace;
}
.hx-link__lock svg { width: 16px; height: 16px; fill: none; stroke: var(--teal-400); stroke-width: 2.2; stroke-linecap: round; display: block; }
.hx-link__btn {
  margin-left: auto;
  font-family: "Segoe UI", -apple-system, Roboto, sans-serif;
  font-weight: 700; font-size: .8rem;
  padding: 6px 14px; border-radius: 8px;
  background: var(--teal-500); color: var(--white);
}
.hx-steps { margin: 14px 22px 4px; padding: 0; list-style: none; counter-reset: hxstep; position: relative; }
.hx-steps::before {
  content: ""; position: absolute; left: 11px; top: 12px; bottom: 12px; width: 2px;
  background: rgba(255,255,255,.1);
}
.hx-steps li {
  position: relative;
  display: flex; align-items: center; gap: 14px;
  padding: 8px 0;
  font-size: .9rem; color: #8ea3b8;
  opacity: 0; transform: translateY(8px);
  transition: opacity .5s ease, transform .6s ease;
}
.hx-slide.is-active .hx-steps li { opacity: 1; transform: none; }
.hx-slide.is-active .hx-steps li:nth-child(1) { transition-delay: .35s; }
.hx-slide.is-active .hx-steps li:nth-child(2) { transition-delay: .5s; }
.hx-slide.is-active .hx-steps li:nth-child(3) { transition-delay: .65s; }
.hx-slide.is-active .hx-steps li:nth-child(4) { transition-delay: .8s; }
.hx-slide.is-active .hx-steps li:nth-child(5) { transition-delay: .95s; }
.hx-steps li > span {
  position: relative; z-index: 1;
  width: 24px; height: 24px; border-radius: 50%; flex-shrink: 0;
  background: var(--navy-800);
  border: 2px solid rgba(255,255,255,.2);
}
.hx-steps li.is-done { color: #d3dee9; }
.hx-steps li.is-done > span { background: var(--teal-500); border-color: var(--teal-500); }
.hx-steps li.is-done > span::after { content: ""; position: absolute; left: 7px; top: 3px; width: 5px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.hx-steps li.is-now { color: var(--white); font-weight: 600; }
.hx-steps li.is-now > span { border-color: var(--teal-400); box-shadow: 0 0 0 5px rgba(47,208,172,.18); animation: hxPulse 2s infinite; }

/* ---------- Controls ---------- */
.hx-controls {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  margin-top: 40px;
}
.hx-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; flex: 1; max-width: 760px; }
.hx-tab {
  display: grid; grid-template-columns: auto 1fr; align-items: baseline; column-gap: 10px; row-gap: 10px;
  padding: 0; background: none; border: 0; text-align: left; color: #7f93a8;
  font-size: .9rem; font-weight: 600;
  transition: color .2s ease;
}
.hx-tab:hover, .hx-tab.is-active { color: var(--white); }
.hx-tab__num { font-size: .75rem; color: #5f7790; font-variant-numeric: tabular-nums; }
.hx-tab.is-active .hx-tab__num { color: var(--teal-400); }
.hx-tab__bar { grid-column: 1 / -1; display: block; height: 3px; border-radius: 3px; background: rgba(255,255,255,.12); overflow: hidden; }
.hx-tab__bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--teal-500), #6fb4ff); border-radius: inherit; }
.hx-tab.is-active .hx-tab__bar i { animation: hxProgress var(--hx-dur) linear forwards; }
.hx.is-paused .hx-tab.is-active .hx-tab__bar i { animation-play-state: paused; }
.hx.is-static .hx-tab.is-active .hx-tab__bar i { animation: none; width: 100%; }
@keyframes hxProgress { from { width: 0; } to { width: 100%; } }

.hx-arrows { display: flex; gap: 10px; }
.hx-arrow {
  width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.18);
  color: var(--white);
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}
.hx-arrow:hover { background: rgba(9,182,140,.2); border-color: var(--teal-400); transform: translateY(-2px); }
.hx-arrow svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.hx-arrow .hx-ico-play { display: none; fill: currentColor; stroke: none; }
.hx-arrow--pause[aria-pressed="true"] .hx-ico-pause { display: none; }
.hx-arrow--pause[aria-pressed="true"] .hx-ico-play { display: block; }
.hx-tab:focus-visible, .hx-arrow:focus-visible { outline: 2px solid var(--teal-400); outline-offset: 4px; border-radius: 6px; }
.hx-arrow:focus-visible { border-radius: 50%; }

/* ---------- Framework strip ---------- */
.hx-strip {
  border-top: 1px solid rgba(255,255,255,.08);
  background: rgba(3,14,28,.35);
  backdrop-filter: blur(6px);
}
.hx-strip__inner { display: flex; align-items: center; gap: 26px; padding-top: 18px; padding-bottom: 18px; }
.hx-strip__label { font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #6f869d; white-space: nowrap; }
.hx-strip ul { display: flex; flex-wrap: wrap; gap: 8px 28px; }
.hx-strip li { font-size: .92rem; font-weight: 700; color: #b5c5d5; letter-spacing: .01em; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .hx-slide { grid-template-columns: 1fr 1fr; gap: 36px; }
  .hx-panel__body { grid-template-columns: 110px 1fr; }
  .hx-score { width: 110px; height: 110px; }
  .hx-tab__label { font-size: .82rem; }
}
@media (max-width: 860px) {
  .hx__inner { padding-top: 60px; }
  .hx-slide { grid-template-columns: 1fr; gap: 28px; }
  .hx-visual { max-width: 520px; padding: 20px 6px 20px 14px; }
  .hx-role:nth-child(2), .hx-role:nth-child(3) { margin-left: 0; }
  .hx-controls { margin-top: 36px; }
  .hx-strip__inner { flex-direction: column; align-items: flex-start; gap: 10px; }
}
@media (max-width: 600px) {
  .hx__inner { padding-top: 44px; padding-bottom: 28px; }
  .hx-visual { display: none; }
  .hx-lead { font-size: 1.02rem; }
  .hx-actions .hx-btn { flex: 1 1 auto; justify-content: center; }
  .hx-tab__label { display: none; }
  .hx-tabs { gap: 8px; }
  .hx-controls { gap: 14px; }
  .hx-arrow { width: 40px; height: 40px; }
  .hx-strip ul { gap: 6px 18px; }
  .hx-strip li { font-size: .84rem; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .hx__orb, .hx-float, .hx-pill__pulse, .hx-steps li.is-now > span { animation: none; }
  .hx-slide, .hx-slide__copy > *, .hx-visual, .hx-role, .hx-steps li, .hx-ring__fill, .hx-bar b::after { transition: none !important; }
}
