/* ============================================================
   SOLUTIONS PAGE — page-specific styles (builds on cyberx.css)
   Ported from design_handoff_cyberx/Solutions.html <style> block.
   ============================================================ */

/* ---------- HERO ---------- */
.sx-hero {
  position: relative; overflow: hidden;
  min-height: 86vh; display: flex; flex-direction: column; justify-content: center;
  padding: 104px 0 56px;
  background:
    radial-gradient(110% 80% at 80% 6%, rgba(255,75,38,.20), transparent 55%),
    radial-gradient(80% 70% at 4% 96%, rgba(120,22,10,.34), transparent 60%),
    linear-gradient(180deg, #0b0608 0%, var(--bg) 72%);
}
.sx-hero #hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .85; }
.sx-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent 60%, var(--bg) 100%);
}
.sx-hero .wrap { position: relative; z-index: 3; }
.sx-hero-head { max-width: 880px; }
.sx-hero h1 {
  font-size: clamp(2rem, 4.1vw, 3.3rem); font-weight: 800; letter-spacing: -.03em;
  margin: 26px 0 0; text-wrap: balance;
}
.sx-hero h1 .hl {
  background: linear-gradient(110deg, var(--brand-2), var(--brand));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.sx-hero .sub {
  font-size: clamp(1.05rem, 1.5vw, 1.28rem); color: var(--muted);
  max-width: 660px; margin: 28px 0 0; line-height: 1.7;
}

/* hero metrics */
.sx-metrics { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 44px; }
.sx-metric {
  position: relative; padding: 20px 30px 18px; min-width: 150px;
  background: rgba(18,20,25,.55); border: 1px solid var(--line); border-radius: 14px;
  backdrop-filter: blur(6px);
  transition: border-color .3s var(--ease), transform .3s var(--ease);
}
.sx-metric:hover { border-color: var(--line-2); transform: translateY(-3px); }
.sx-metric .v {
  font-size: 2.1rem; font-weight: 800; letter-spacing: -.02em; line-height: 1;
  font-variant-numeric: tabular-nums; color: var(--text);
}
.sx-metric .v small { font-size: 1.2rem; color: var(--brand-2); margin-left: 2px; }
.sx-metric .k {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--dim); margin-top: 10px;
}

/* hero scrolling ticker of solution names */
.sx-ticker {
  position: relative; z-index: 3;
  margin-top: 58px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 16px 0; overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.sx-ticker-track { display: inline-flex; gap: 0; white-space: nowrap; will-change: transform; animation: sxScroll 46s linear infinite; }
.sx-hero:hover .sx-ticker-track,
.sx-ticker:hover .sx-ticker-track { animation-play-state: paused; }
.sx-tick {
  font-family: var(--mono); font-size: .9rem; letter-spacing: .04em; color: var(--muted);
  display: inline-flex; align-items: center; gap: 14px; padding: 0 26px;
}
.sx-tick::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); opacity: .8; }
@keyframes sxScroll { to { transform: translateX(-50%); } }

.sx-scroll-cue {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  font-family: var(--mono); font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--dim);
}
.sx-scroll-cue .line { width: 1px; height: 38px; background: linear-gradient(var(--brand-2), transparent); position: relative; overflow: hidden; }
.sx-scroll-cue .line::after { content: ""; position: absolute; top: -40%; left: 0; width: 100%; height: 40%; background: var(--brand); animation: cueDrop 2s var(--ease) infinite; }
@keyframes cueDrop { 0% { top: -40%; } 60%,100% { top: 110%; } }

/* ============================================================
   SOLUTIONS BODY — sticky index + stacked blocks
   ============================================================ */
.sx-body { position: relative; background: linear-gradient(180deg, var(--bg), var(--bg-2)); padding: 96px 0 40px; }
.sx-body::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.022) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(80% 60% at 50% 0%, #000, transparent 80%);
}
.sx-layout {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: 248px 1fr; gap: 64px; align-items: start;
}

/* ---- sticky index rail ---- */
.sx-idx { position: sticky; top: 104px; align-self: start; }
.sx-idx-head {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--dim);
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px;
  padding-bottom: 16px; border-bottom: 1px solid var(--line);
}
.sx-idx-head b { color: var(--brand-2); font-family: var(--font); font-size: 1rem; font-weight: 700; }
.sx-idx-list { position: relative; padding-left: 22px; }
.sx-idx-list::before { content: ""; position: absolute; left: 4px; top: 6px; bottom: 6px; width: 1px; background: var(--line); }
.sx-idx-prog { position: absolute; left: 4px; top: 6px; width: 1px; height: 0; background: linear-gradient(var(--brand-2), var(--brand)); transition: height .4s var(--ease); box-shadow: 0 0 8px rgba(255,75,38,.6); }
.sx-idx-row {
  position: relative; display: flex; align-items: center; gap: 11px;
  padding: 8px 0; color: var(--dim); cursor: pointer;
  transition: color .25s var(--ease);
}
.sx-idx-row .ix { font-family: var(--mono); font-size: .74rem; width: 22px; flex-shrink: 0; }
.sx-idx-row .nm { font-size: .86rem; font-weight: 500; line-height: 1.3; transition: color .25s, transform .25s var(--ease); }
.sx-idx-row::before {
  content: ""; position: absolute; left: -22px; top: 50%; transform: translateY(-50%) scale(.5);
  width: 7px; height: 7px; border-radius: 50%; background: var(--dim); opacity: .5;
  transition: all .25s var(--ease);
}
.sx-idx-row:hover { color: var(--muted); }
.sx-idx-row:hover .nm { transform: translateX(2px); }
.sx-idx-row.active { color: var(--text); }
.sx-idx-row.active .ix { color: var(--brand-2); }
.sx-idx-row.active::before { background: var(--brand); opacity: 1; transform: translateY(-50%) scale(1); box-shadow: 0 0 10px var(--brand); }

/* ---- solution blocks ---- */
.sx-blocks { min-width: 0; }
.sx-block {
  position: relative; padding: 60px 0 64px; border-top: 1px solid var(--line);
  --rgb: 255,75,38; --ac: #FF7A3C;
}
.sx-block:first-child { border-top: none; padding-top: 8px; }
.sx-block-grid { display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 48px; align-items: start; }

.sx-wm {
  position: absolute; top: 24px; right: 0; z-index: 0;
  font-family: var(--mono); font-weight: 600; font-size: clamp(7rem, 13vw, 12rem); line-height: .8;
  color: transparent; -webkit-text-stroke: 1px rgba(var(--rgb), .14);
  pointer-events: none; user-select: none; letter-spacing: -.04em;
  will-change: transform;
}

.sx-content { position: relative; z-index: 2; max-width: 640px; }
.sx-top { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
.sx-ic {
  position: relative; width: 56px; height: 56px; flex-shrink: 0; border-radius: 14px;
  display: grid; place-items: center;
  background: rgba(var(--rgb), .1); border: 1px solid rgba(var(--rgb), .28); color: var(--ac);
}
.sx-ic svg { width: 28px; height: 28px; }
.sx-ic::after {
  content: ""; position: absolute; inset: -1px; border-radius: 14px;
  border: 1px solid rgba(var(--rgb), .5); opacity: 0;
}
.sx-block.in .sx-ic::after { animation: icPulse 2.6s var(--ease) infinite; }
@keyframes icPulse { 0% { transform: scale(1); opacity: .7; } 70%,100% { transform: scale(1.5); opacity: 0; } }

.sx-tag {
  font-family: var(--mono); font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ac);
  display: inline-flex; align-items: center; gap: 9px;
}
.sx-tag .num { color: var(--dim); }

.sx-content h2 { font-size: clamp(1.5rem, 2.6vw, 2.15rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.1; margin-bottom: 16px; text-wrap: balance; }
.sx-lead { font-size: 1.12rem; color: var(--text); line-height: 1.66; margin-bottom: 16px; opacity: .92; }
.sx-desc { font-size: 1.02rem; color: var(--muted); line-height: 1.72; }

.sx-help {
  display: flex; align-items: flex-start; gap: 13px; margin-top: 26px; padding-top: 22px;
  border-top: 1px dashed var(--line-2);
}
.sx-help .chk {
  flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(var(--rgb), .14); color: var(--ac);
}
.sx-help .chk svg { width: 15px; height: 15px; }
.sx-help p { font-size: .98rem; color: var(--text); line-height: 1.6; }
.sx-help b { color: var(--ac); font-weight: 700; }

.sx-cta {
  display: inline-flex; align-items: center; gap: 10px; margin-top: 28px;
  font-weight: 600; font-size: .96rem; padding: 13px 24px; border-radius: 999px;
  color: var(--text); background: rgba(var(--rgb), .08); border: 1px solid rgba(var(--rgb), .3);
  transition: background .25s var(--ease), border-color .25s, transform .25s, box-shadow .25s, color .25s;
}
.sx-cta svg { width: 16px; height: 16px; transition: transform .25s var(--ease); }
.sx-cta:hover { background: var(--ac); color: #0b0507; border-color: var(--ac); transform: translateY(-2px); box-shadow: 0 12px 30px -10px rgba(var(--rgb), .6); }
.sx-cta:hover svg { transform: translateX(4px); }

/* per-block visual panel (animated rings + scan) */
.sx-viz {
  position: relative; z-index: 1; height: 240px; border-radius: 16px; overflow: hidden;
  border: 1px solid var(--line); background:
    radial-gradient(120% 100% at 70% 20%, rgba(var(--rgb), .12), transparent 60%),
    linear-gradient(180deg, rgba(18,20,25,.6), rgba(12,14,18,.6));
}
.sx-viz::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(var(--rgb),.06) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--rgb),.06) 1px, transparent 1px);
  background-size: 26px 26px; mask-image: radial-gradient(80% 80% at 50% 50%, #000, transparent);
}
.sx-viz .radar { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 200px; height: 200px; }
.sx-viz .ring { fill: none; stroke: rgba(var(--rgb), .25); stroke-width: 1; }
.sx-viz .ring.dash { stroke-dasharray: 4 6; }
.sx-block.in .sx-viz .rot { transform-origin: 100px 100px; animation: spin 16s linear infinite; }
.sx-viz .sweep { transform-origin: 100px 100px; }
.sx-block.in .sx-viz .sweep { animation: sweep 4.5s linear infinite; }
@keyframes sweep { to { transform: rotate(360deg); } }
.sx-viz .core { fill: var(--ac); filter: drop-shadow(0 0 8px rgba(var(--rgb),.9)); }
.sx-viz .blip { fill: var(--ac); opacity: 0; }
.sx-block.in .sx-viz .blip { animation: blip 4.5s linear infinite; }
.sx-viz .blip.b2 { animation-delay: 1.4s; }
.sx-viz .blip.b3 { animation-delay: 2.7s; }
@keyframes blip { 0%,12% { opacity: 0; } 18% { opacity: 1; } 55% { opacity: 0; } 100% { opacity: 0; } }
.sx-viz .scan {
  position: absolute; left: 0; right: 0; height: 60px;
  background: linear-gradient(180deg, transparent, rgba(var(--rgb), .14), transparent);
}
.sx-block.in .sx-viz .scan { animation: scanY 3.4s var(--ease) infinite; }
@keyframes scanY { 0% { top: -60px; } 100% { top: 240px; } }
.sx-viz .label {
  position: absolute; left: 16px; bottom: 14px; font-family: var(--mono); font-size: .64rem;
  letter-spacing: .16em; text-transform: uppercase; color: var(--ac); display: flex; align-items: center; gap: 8px;
}
.sx-viz .label .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ac); box-shadow: 0 0 8px var(--ac); animation: lblPulse 1.8s infinite; }
@keyframes lblPulse { 0%,100% { opacity: 1; } 50% { opacity: .3; } }

/* reveal */
.sx-r { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.sx-block.in .sx-r { opacity: 1; transform: none; }
.sx-block.in .sx-r[data-d="1"] { transition-delay: .08s; }
.sx-block.in .sx-r[data-d="2"] { transition-delay: .16s; }
.sx-block.in .sx-r[data-d="3"] { transition-delay: .24s; }
.sx-block.in .sx-r[data-d="4"] { transition-delay: .32s; }

@media (prefers-reduced-motion: reduce) {
  .sx-r { opacity: 1 !important; transform: none !important; }
  .sx-ticker-track, .sx-viz .rot, .sx-viz .sweep, .sx-viz .blip, .sx-viz .scan, .sx-block.in .sx-ic::after, .sx-scroll-cue .line::after { animation: none !important; }
}

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .sx-block-grid { grid-template-columns: 1fr; gap: 28px; }
  .sx-viz { height: 200px; max-width: 480px; }
}
@media (max-width: 920px) {
  .sx-layout { grid-template-columns: 1fr; gap: 0; }
  .sx-idx { display: none; }
}
@media (max-width: 720px) {
  .sx-hero { padding: 140px 0 60px; min-height: auto; }
  .sx-body { padding: 64px 0 30px; }
  .sx-block { padding: 44px 0 48px; }
  .sx-metric { padding: 16px 22px 14px; min-width: 130px; flex: 1; }
  .sx-wm { font-size: 6rem; top: 12px; }
}
