/* ============================================================
   EVERWISE TECHNOLOGY — Interaction & Motion Effects
   ============================================================ */

@property --fx-hole {
    syntax: '<length>';
    inherits: false;
    initial-value: 0px;
}

@property --fx-angle {
    syntax: '<angle>';
    inherits: false;
    initial-value: 0deg;
}

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

@keyframes fxBlink {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0.15; }
}

/* ============================================================
   PRELOADER — boot sequence & portal exit
   ============================================================ */
#preloader {
    overflow: hidden;
    -webkit-mask: radial-gradient(circle at 50% 50%, transparent var(--fx-hole), #000 calc(var(--fx-hole) + 1px));
    mask: radial-gradient(circle at 50% 50%, transparent var(--fx-hole), #000 calc(var(--fx-hole) + 1px));
    transition: --fx-hole 1.2s cubic-bezier(0.7, 0, 0.2, 1) 0.25s,
                opacity 0.3s ease 1.3s,
                visibility 0s linear 1.6s;
}

#preloader.loaded {
    --fx-hole: 150vmax;
    opacity: 0;
    visibility: hidden;
}

.fx-pre-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(8, 145, 178, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(8, 145, 178, 0.08) 1px, transparent 1px);
    background-size: 40px 40px;
    -webkit-mask-image: radial-gradient(circle at center, #000 0%, transparent 65%);
    mask-image: radial-gradient(circle at center, #000 0%, transparent 65%);
    animation: fxGridDrift 4s linear infinite;
}

@keyframes fxGridDrift {
    to { background-position: 40px 40px, 40px 40px; }
}

.fx-pre-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    border: 2px solid rgba(34, 211, 238, 0.9);
    box-shadow: 0 0 40px rgba(34, 211, 238, 0.6), inset 0 0 40px rgba(34, 211, 238, 0.35);
    transform: translate(-50%, -50%);
    opacity: 0;
    pointer-events: none;
}

#preloader.loaded .fx-pre-ring {
    width: 300vmax;
    height: 300vmax;
    opacity: 1;
    transition: width 1.2s cubic-bezier(0.7, 0, 0.2, 1) 0.25s,
                height 1.2s cubic-bezier(0.7, 0, 0.2, 1) 0.25s,
                opacity 0.2s ease 0.25s;
}

.preloader-inner {
    position: relative;
    z-index: 1;
    transition: transform 0.7s cubic-bezier(0.7, 0, 0.2, 1), filter 0.7s ease, opacity 0.5s ease;
}

#preloader.loaded .preloader-inner {
    transform: scale(1.4);
    filter: blur(12px);
    opacity: 0;
}

.fx-pre-core {
    position: relative;
    width: 180px;
    height: 180px;
    margin: 0 auto 26px;
    display: grid;
    place-items: center;
}

.fx-pre-core .preloader-logo {
    position: relative;
    z-index: 1;
    width: 84px;
    height: 84px;
    margin: 0;
    animation: fxLogoPulse 1.6s ease-in-out infinite;
}

@keyframes fxLogoPulse {
    0%, 100% { filter: drop-shadow(0 0 0 rgba(34, 211, 238, 0)); transform: scale(1); }
    50% { filter: drop-shadow(0 0 16px rgba(34, 211, 238, 0.6)); transform: scale(1.04); }
}

.fx-pre-orbit {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.fx-pre-orbit circle {
    fill: none;
    stroke-linecap: round;
    transform-box: fill-box;
    transform-origin: center;
}

.fx-pre-orbit .o1 {
    stroke: rgba(8, 145, 178, 0.55);
    stroke-width: 1.5;
    stroke-dasharray: 60 18 6 18;
    animation: fxSpin 6s linear infinite;
}

.fx-pre-orbit .o2 {
    stroke: rgba(34, 211, 238, 0.9);
    stroke-width: 3;
    stroke-dasharray: 110 393;
    filter: drop-shadow(0 0 4px rgba(34, 211, 238, 0.8));
    animation: fxSpin 1.3s linear infinite reverse;
}

.fx-pre-orbit .o3 {
    stroke: rgba(11, 35, 64, 0.2);
    stroke-width: 1;
    stroke-dasharray: 2 6;
    animation: fxSpin 12s linear infinite;
}

.fx-pre-scan {
    position: absolute;
    left: 22%;
    right: 22%;
    top: 22%;
    height: 2px;
    z-index: 2;
    background: linear-gradient(90deg, transparent, #22d3ee, transparent);
    box-shadow: 0 0 12px 1px rgba(34, 211, 238, 0.8);
    animation: fxScanY 1.6s ease-in-out infinite;
}

@keyframes fxScanY {
    0% { top: 22%; opacity: 0; }
    15% { opacity: 1; }
    50% { top: 76%; opacity: 1; }
    85% { opacity: 1; }
    100% { top: 22%; opacity: 0; }
}

.fx-pre-status {
    min-height: 1.2em;
    margin-bottom: 18px;
    font-family: var(--font-display);
    font-size: 0.68rem;
    letter-spacing: 0.32em;
    color: var(--accent-1);
}

.preloader-bar-wrap {
    width: 240px;
}

.preloader-bar {
    box-shadow: 0 0 12px rgba(34, 211, 238, 0.8);
}

/* ============================================================
   HERO — holographic stage
   ============================================================ */
#hero {
    --fx-ring-size: min(92vmin, 860px);
}

.fx-hero-floor {
    position: absolute;
    left: -50%;
    right: -50%;
    bottom: -8%;
    height: 58%;
    z-index: 0;
    background-image:
        linear-gradient(rgba(8, 145, 178, 0.24) 1.5px, transparent 1.5px),
        linear-gradient(90deg, rgba(8, 145, 178, 0.24) 1.5px, transparent 1.5px);
    background-size: 70px 70px;
    transform: perspective(600px) rotateX(68deg);
    transform-origin: 50% 100%;
    -webkit-mask-image: linear-gradient(to top, #000 0%, rgba(0, 0, 0, 0.55) 40%, transparent 85%);
    mask-image: linear-gradient(to top, #000 0%, rgba(0, 0, 0, 0.55) 40%, transparent 85%);
    opacity: 0;
    pointer-events: none;
    transition: opacity 1.6s ease 0.4s;
    animation: fxFloor 3.2s linear infinite;
}

#hero.fx-on .fx-hero-floor {
    opacity: 1;
}

@keyframes fxFloor {
    to { background-position: 0 70px, 0 0; }
}

.fx-hero-spot {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: radial-gradient(520px circle at var(--sx, 50%) var(--sy, 40%), rgba(34, 211, 238, 0.16), transparent 65%);
}

.fx-hero-rings {
    position: absolute;
    top: 50%;
    left: 50%;
    width: var(--fx-ring-size);
    height: var(--fx-ring-size);
    z-index: 1;
    pointer-events: none;
    opacity: 0;
    transform: translate(-50%, -50%)
               translate3d(calc(var(--mx, 0) * -26px), calc(var(--my, 0) * -26px), 0)
               scale(calc(0.85 + var(--fx-scroll, 0) * 0.45))
               rotate(calc(var(--fx-scroll, 0) * 50deg));
    transition: opacity 1.4s ease 0.2s, transform 1.4s var(--ease-out-expo);
}

#hero.fx-on .fx-hero-rings {
    opacity: 1;
    transform: translate(-50%, -50%)
               translate3d(calc(var(--mx, 0) * -26px), calc(var(--my, 0) * -26px), 0)
               scale(calc(1 + var(--fx-scroll, 0) * 0.45))
               rotate(calc(var(--fx-scroll, 0) * 50deg));
    transition: opacity 1.4s ease 0.2s, transform 0.2s linear;
}

.fx-hero-rings span {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px solid rgba(8, 145, 178, 0.18);
}

.fx-hero-rings span:nth-child(1) {
    border-style: dashed;
    animation: fxSpin 70s linear infinite;
}

.fx-hero-rings span:nth-child(2) {
    inset: 12%;
    border: 2px solid transparent;
    border-top-color: rgba(34, 211, 238, 0.6);
    border-right-color: rgba(34, 211, 238, 0.22);
    animation: fxSpin 14s linear infinite reverse;
}

.fx-hero-rings span:nth-child(3) {
    inset: 26%;
    border-color: rgba(11, 35, 64, 0.08);
    box-shadow: inset 0 0 80px rgba(34, 211, 238, 0.1);
    animation: fxRingBreath 5s ease-in-out infinite;
}

@keyframes fxRingBreath {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.05); opacity: 1; }
}

.fx-hero-rings i {
    position: absolute;
    top: 0;
    left: 50%;
    width: 10px;
    height: 10px;
    margin: -5px 0 0 -5px;
    border-radius: 50%;
    background: #22d3ee;
    box-shadow: 0 0 16px 5px rgba(34, 211, 238, 0.55);
    transform-origin: 5px calc(var(--fx-ring-size) / 2 + 5px);
    animation: fxSpin 9s linear infinite;
}

.fx-hero-hud {
    position: absolute;
    inset: calc(var(--nav-height) + 12px) clamp(16px, 3vw, 44px) 28px;
    z-index: 1;
    pointer-events: none;
    font-family: var(--font-display);
    font-size: 0.62rem;
    letter-spacing: 0.22em;
    color: rgba(11, 35, 64, 0.45);
    opacity: 0;
    transition: opacity 1s ease 0.9s;
}

#hero.fx-on .fx-hero-hud {
    opacity: 1;
}

.fx-hero-hud > span {
    position: absolute;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
}

.fx-hero-hud > span::before {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    border: 1.5px solid rgba(8, 145, 178, 0.6);
}

.fx-hud-tl { top: 0; left: 0; }
.fx-hud-tl::before { top: 0; left: 0; border-right: 0 !important; border-bottom: 0 !important; }
.fx-hud-tr { top: 0; right: 0; }
.fx-hud-tr::before { top: 0; right: 0; border-left: 0 !important; border-bottom: 0 !important; }
.fx-hud-bl { bottom: 0; left: 0; }
.fx-hud-bl::before { bottom: 0; left: 0; border-right: 0 !important; border-top: 0 !important; }
.fx-hud-br { bottom: 0; right: 0; }
.fx-hud-br::before { bottom: 0; right: 0; border-left: 0 !important; border-top: 0 !important; }

.fx-hud-signal {
    display: inline-flex;
    align-items: flex-end;
    gap: 2px;
    height: 12px;
}

.fx-hud-signal i,
.fx-eq i {
    display: block;
    width: 3px;
    background: var(--accent-1);
    transform-origin: bottom;
    animation: fxEq 1s ease-in-out infinite;
}

.fx-hud-signal i { height: 100%; }
.fx-hud-signal i:nth-child(2), .fx-eq i:nth-child(2) { animation-delay: -0.2s; }
.fx-hud-signal i:nth-child(3), .fx-eq i:nth-child(3) { animation-delay: -0.5s; }
.fx-hud-signal i:nth-child(4), .fx-eq i:nth-child(4) { animation-delay: -0.35s; }
.fx-hud-signal i:nth-child(5), .fx-eq i:nth-child(5) { animation-delay: -0.75s; }

@keyframes fxEq {
    0%, 100% { transform: scaleY(0.25); }
    50% { transform: scaleY(1); }
}

.fx-hud-br { color: var(--accent-1); }

/* Hero title glitch-in */
#hero .title-word.revealed {
    animation: fxGlitchIn 0.8s steps(1, end) calc(var(--d, 0) * 0.12s + 0.15s);
}

#hero .title-word.gradient-text.revealed {
    animation: fxGlitchIn 0.8s steps(1, end) calc(var(--d, 0) * 0.12s + 0.15s),
               textGlow 4s ease-in-out infinite;
}

@keyframes fxGlitchIn {
    0% { clip-path: inset(0 0 0 0); filter: none; }
    10% { clip-path: inset(12% 0 52% 0); filter: drop-shadow(-5px 0 0 rgba(34, 211, 238, 0.9)) drop-shadow(5px 0 0 rgba(14, 116, 144, 0.7)); }
    20% { clip-path: inset(62% 0 6% 0); filter: drop-shadow(4px 0 0 rgba(34, 211, 238, 0.9)); }
    30% { clip-path: inset(30% 0 34% 0); filter: drop-shadow(-3px 0 0 rgba(11, 35, 64, 0.5)) drop-shadow(3px 0 0 rgba(34, 211, 238, 0.9)); }
    40% { clip-path: inset(0 0 0 0); filter: none; }
    55% { clip-path: inset(76% 0 2% 0); filter: drop-shadow(-2px 0 0 rgba(34, 211, 238, 0.9)); }
    65%, 100% { clip-path: inset(0 0 0 0); filter: none; }
}

.fx-badge-text {
    font-variant-numeric: tabular-nums;
}

/* ============================================================
   SHINE SWEEP ON BUTTONS
   ============================================================ */
.fx-shine-host {
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

.fx-shine {
    position: absolute;
    top: 0;
    bottom: 0;
    left: -60%;
    width: 40%;
    z-index: 2;
    pointer-events: none;
    background: linear-gradient(105deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    transform: skewX(-20deg);
    animation: fxShine 3.8s ease-in-out infinite;
}

.btn-outline .fx-shine {
    background: linear-gradient(105deg, transparent, rgba(34, 211, 238, 0.3), transparent);
}

@keyframes fxShine {
    0%, 60% { left: -60%; }
    85%, 100% { left: 130%; }
}

/* ============================================================
   NAVBAR — scanning edge
   ============================================================ */
#navbar::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(34, 211, 238, 0.9), transparent) no-repeat;
    background-size: 40% 100%;
    opacity: 0;
    transition: opacity 0.4s ease;
    animation: fxNavScan 4s linear infinite;
}

#navbar.scrolled::after {
    opacity: 1;
}

@keyframes fxNavScan {
    from { background-position: -67% 0; }
    to { background-position: 167% 0; }
}

.scroll-progress {
    box-shadow: 0 0 10px rgba(34, 211, 238, 0.6);
}

.scroll-progress::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -3px;
    width: 8px;
    height: 8px;
    margin-top: -4px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 12px 4px rgba(34, 211, 238, 0.9);
}

/* ============================================================
   SECTIONS — ambient grid, headers
   ============================================================ */
.section-container {
    position: relative;
    z-index: 1;
}

section:not(#hero)::after {
    content: '';
    inset: 0;
    width: auto;
    max-width: none;
    height: auto;
    transform: none;
    z-index: 0;
    background: radial-gradient(rgba(8, 145, 178, 0.22) 1px, transparent 1.3px);
    background-size: 28px 28px;
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 10%, transparent 75%);
    mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 10%, transparent 75%);
    opacity: 0;
    transition: opacity 1.2s ease;
    animation: fxDots 40s linear infinite;
}

section.fx-inview::after {
    opacity: 0.75;
}

@keyframes fxDots {
    to { background-position: 280px 140px; }
}

.fx-divider + section {
    padding-top: calc(var(--section-padding) * 0.55);
}

section:not(#hero):has(+ .fx-divider) {
    padding-bottom: calc(var(--section-padding) * 0.55);
}

.section-header {
    will-change: transform;
}

.section-tag::before {
    content: '<';
    margin-right: 0.6em;
    opacity: 0.5;
}

.section-tag::after {
    content: '/>';
    margin-left: 0.6em;
    opacity: 0.5;
}

.section-title.scroll-reveal {
    width: fit-content;
    margin-inline: auto;
    opacity: 1;
    transform: none;
    filter: blur(6px);
    letter-spacing: 0.12em;
    -webkit-mask-image: linear-gradient(90deg, #000 0 45%, transparent 55% 100%);
    mask-image: linear-gradient(90deg, #000 0 45%, transparent 55% 100%);
    -webkit-mask-size: 250% 100%;
    mask-size: 250% 100%;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: 100% 0;
    mask-position: 100% 0;
    transition: -webkit-mask-position 1.2s cubic-bezier(0.77, 0, 0.18, 1) 0.1s,
                mask-position 1.2s cubic-bezier(0.77, 0, 0.18, 1) 0.1s,
                filter 1s ease 0.2s,
                letter-spacing 1.2s var(--ease-out-expo) 0.1s;
}

.section-title.scroll-reveal.visible {
    filter: none;
    letter-spacing: normal;
    -webkit-mask-position: 0 0;
    mask-position: 0 0;
}

.section-line.scroll-reveal {
    position: relative;
    width: 0;
    box-shadow: 0 0 12px rgba(34, 211, 238, 0.55);
    transition: opacity 0.8s ease,
                transform 0.8s var(--ease-out-expo),
                width 1.1s cubic-bezier(0.77, 0, 0.18, 1) 0.45s;
}

.section-line.scroll-reveal.visible {
    width: 140px;
}

.section-line::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 8px;
    height: 8px;
    margin-top: -4px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 10px 3px rgba(34, 211, 238, 0.95);
    animation: fxLineDot 2.4s ease-in-out infinite;
}

@keyframes fxLineDot {
    0%, 100% { left: 0; }
    50% { left: calc(100% - 8px); }
}

/* ============================================================
   SECTION DIVIDERS
   ============================================================ */
.fx-divider {
    position: relative;
    height: 140px;
    overflow: hidden;
    pointer-events: none;
    background: var(--fx-from, #fff);
}

.fx-divider:not(.is-visible) * {
    animation-play-state: paused !important;
}

.fx-divider svg,
.fx-divider canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}

.fx-wave {
    animation: fxWave 18s linear infinite;
}

.fx-wave.w1 {
    fill: rgba(8, 145, 178, 0.07);
    animation-duration: 24s;
}

.fx-wave.w2 {
    fill: rgba(34, 211, 238, 0.1);
    animation-duration: 15s;
    animation-direction: reverse;
}

.fx-wave.w3 {
    fill: var(--fx-to, #fff);
}

.fx-wave.w3-crest {
    fill: none;
    stroke: rgba(8, 145, 178, 0.35);
    stroke-width: 1.5;
    vector-effect: non-scaling-stroke;
}

@keyframes fxWave {
    to { transform: translateX(-1440px); }
}

.fx-trace {
    fill: none;
    stroke: rgba(8, 145, 178, 0.3);
    stroke-width: 1.5;
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    transition: stroke-dashoffset 1.6s cubic-bezier(0.65, 0, 0.35, 1);
}

.fx-divider.is-active .fx-trace {
    stroke-dashoffset: 0;
}

.fx-pulse {
    fill: none;
    stroke: #22d3ee;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-dasharray: 6 94;
    stroke-dashoffset: 100;
    filter: drop-shadow(0 0 4px rgba(34, 211, 238, 0.95));
    opacity: 0;
    transition: opacity 0.4s ease 1.4s;
}

.fx-divider.is-active .fx-pulse {
    opacity: 1;
    animation: fxPulse 2.8s linear infinite;
    animation-delay: var(--pd, 0s);
}

@keyframes fxPulse {
    to { stroke-dashoffset: 0; }
}

.fx-node {
    fill: #fff;
    stroke: var(--accent-1);
    stroke-width: 1.5;
    opacity: 0;
    transform-box: fill-box;
    transform-origin: center;
    transform: scale(0);
    transition: opacity 0.4s ease, transform 0.5s var(--ease-spring);
    transition-delay: calc(0.9s + var(--nd, 0s));
}

.fx-divider.is-active .fx-node {
    opacity: 1;
    transform: scale(1);
    animation: fxNodeGlow 2.4s ease-in-out infinite;
    animation-delay: var(--nd, 0s);
}

@keyframes fxNodeGlow {
    0%, 100% { fill: #fff; filter: none; }
    50% { fill: #22d3ee; filter: drop-shadow(0 0 5px rgba(34, 211, 238, 0.9)); }
}

.fx-divider-hud {
    position: absolute;
    top: 42%;
    left: 50%;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 18px;
    font-family: var(--font-display);
    font-size: 0.68rem;
    letter-spacing: 0.3em;
    white-space: nowrap;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(8, 145, 178, 0.25);
    border-radius: 4px;
    box-shadow: 0 8px 30px rgba(8, 145, 178, 0.12);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    transform: translate(-50%, -50%);
    clip-path: inset(0 50% 0 50%);
    transition: clip-path 0.9s cubic-bezier(0.77, 0, 0.18, 1) 0.5s;
}

.fx-divider.is-active .fx-divider-hud {
    clip-path: inset(0 0 0 0);
}

.fx-hud-idx {
    font-weight: 700;
    color: var(--accent-1);
}

.fx-hud-bar {
    width: 28px;
    height: 1px;
    background: currentColor;
    opacity: 0.4;
}

.fx-hud-blink {
    width: 6px;
    height: 6px;
    background: var(--accent-3);
    box-shadow: 0 0 8px var(--accent-3);
    animation: fxBlink 1.2s infinite;
}

.fx-eq {
    display: inline-flex;
    align-items: flex-end;
    gap: 2px;
    height: 12px;
}

.fx-eq i {
    height: 100%;
}

/* ============================================================
   CARDS — reveal, holographic border, scan
   ============================================================ */
.fx-card {
    position: relative;
    overflow: hidden;
}

.fx-glow,
.fx-border,
.fx-scan {
    position: absolute;
    pointer-events: none;
    border-radius: inherit;
}

.fx-glow {
    inset: 0;
    z-index: 0;
    background: radial-gradient(260px circle at var(--fx-x, 50%) var(--fx-y, 50%), rgba(34, 211, 238, 0.14), transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.fx-border {
    inset: 0;
    z-index: 3;
    padding: 1.5px;
    background: conic-gradient(from var(--fx-angle),
        transparent 0deg,
        rgba(34, 211, 238, 0.95) 40deg,
        rgba(8, 145, 178, 0.9) 80deg,
        transparent 140deg,
        transparent 220deg,
        rgba(14, 116, 144, 0.7) 260deg,
        transparent 320deg);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s ease;
    animation: fxAngle 3s linear infinite;
    animation-play-state: paused;
}

.fx-card:hover .fx-glow,
.fx-card:hover .fx-border {
    opacity: 1;
}

.fx-card:hover .fx-border {
    animation-play-state: running;
}

@keyframes fxAngle {
    to { --fx-angle: 360deg; }
}

.fx-scan {
    left: 0;
    right: 0;
    top: 0;
    height: 45%;
    z-index: 3;
    background: linear-gradient(180deg, transparent, rgba(34, 211, 238, 0.12) 70%, rgba(34, 211, 238, 0.55) 98%, transparent);
    transform: translateY(-100%);
    opacity: 0;
}

.fx-card.fx-in .fx-scan {
    animation: fxCardScan 1.2s cubic-bezier(0.6, 0, 0.3, 1) var(--fx-delay, 0s) both;
}

@keyframes fxCardScan {
    0% { transform: translateY(-100%); opacity: 1; }
    85% { opacity: 1; }
    100% { transform: translateY(260%); opacity: 0; }
}

.fx-rise.scroll-reveal {
    transform: perspective(1000px) translate3d(0, 90px, -60px) rotateX(24deg) scale(0.94);
    filter: blur(8px);
    transition: opacity 1s ease, transform 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1s ease;
    transition-delay: calc(var(--d, 0) * 0.12s);
}

.fx-rise.scroll-reveal.visible {
    transform: perspective(800px) rotateX(0) rotateY(0);
    filter: none;
}

.fx-rise.scroll-reveal.visible.fx-done {
    transition: transform 0.4s var(--ease-out-expo), border-color 0.4s ease, box-shadow 0.4s ease;
    transition-delay: 0s;
}

/* ============================================================
   SIDE HUD NAVIGATION
   ============================================================ */
.fx-sidenav {
    position: fixed;
    top: 50%;
    right: clamp(14px, 2vw, 28px);
    z-index: 9990;
    display: flex;
    flex-direction: column;
    gap: 20px;
    transform: translateY(-50%);
    opacity: 0;
    transition: opacity 0.6s ease 0.6s;
}

.fx-sidenav.is-ready {
    opacity: 1;
}

.fx-sidenav-track {
    position: absolute;
    top: 9px;
    bottom: 9px;
    right: 4px;
    width: 1.5px;
    background: rgba(8, 145, 178, 0.15);
}

.fx-sidenav-fill {
    display: block;
    width: 100%;
    height: var(--fx-progress, 0%);
    background: linear-gradient(var(--accent-3), var(--accent-1));
    box-shadow: 0 0 8px rgba(34, 211, 238, 0.8);
}

.fx-sidenav-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    height: 18px;
    cursor: none;
}

.fx-sidenav-idx {
    font-family: var(--font-display);
    font-size: 0.6rem;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    transition: color 0.3s ease;
}

.fx-sidenav-item i {
    position: relative;
    width: 10px;
    height: 10px;
    background: var(--bg-primary);
    border: 1.5px solid rgba(8, 145, 178, 0.5);
    transform: rotate(45deg);
    transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s var(--ease-spring);
}

.fx-sidenav-label {
    position: absolute;
    right: 52px;
    padding: 3px 10px;
    font-size: 0.75rem;
    white-space: nowrap;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--border-subtle);
    border-radius: 3px;
    box-shadow: 0 6px 18px rgba(11, 35, 64, 0.08);
    opacity: 0;
    transform: translateX(8px);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.fx-sidenav-item:hover .fx-sidenav-label {
    opacity: 1;
    transform: none;
}

.fx-sidenav-item:hover i,
.fx-sidenav-item.is-active i {
    background: var(--accent-1);
    border-color: var(--accent-1);
    box-shadow: 0 0 12px rgba(34, 211, 238, 0.85);
    transform: rotate(45deg) scale(1.25);
}

.fx-sidenav-item.is-active .fx-sidenav-idx {
    color: var(--accent-1);
}

/* ============================================================
   BACK TO TOP — progress ring
   ============================================================ */
.back-to-top .fx-btt-ring {
    position: absolute;
    inset: -4px;
    width: calc(100% + 8px);
    height: calc(100% + 8px);
    transform: rotate(-90deg);
    stroke: none;
}

.fx-btt-ring circle {
    fill: none;
    stroke: var(--accent-1);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-dasharray: 100;
    stroke-dashoffset: var(--fx-btt, 100);
    filter: drop-shadow(0 0 3px rgba(34, 211, 238, 0.7));
    transition: stroke-dashoffset 0.15s linear;
}

/* ============================================================
   CURSOR TRAIL & CLICK BURST
   ============================================================ */
.fx-trail {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 99997;
    pointer-events: none;
}

.fx-burst {
    position: fixed;
    width: 0;
    height: 0;
    z-index: 99996;
    pointer-events: none;
}

.fx-burst::before {
    content: '';
    position: absolute;
    left: -5px;
    top: -5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 1.5px solid var(--accent-1);
    animation: fxBurstRing 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.fx-burst i {
    position: absolute;
    left: 0;
    top: -1px;
    width: 14px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, rgba(34, 211, 238, 0), #22d3ee);
    transform-origin: 0 50%;
    transform: rotate(var(--r)) translateX(4px) scaleX(0.2);
    animation: fxBurstRay 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes fxBurstRing {
    to { transform: scale(8); opacity: 0; }
}

@keyframes fxBurstRay {
    to { transform: rotate(var(--r)) translateX(32px) scaleX(1); opacity: 0; }
}

/* ============================================================
   RESPONSIVE & ACCESSIBILITY
   ============================================================ */
@media (max-width: 1360px) {
    .fx-sidenav {
        display: none;
    }
}

@media (max-width: 768px) {
    .fx-hero-hud,
    .fx-hero-rings i {
        display: none;
    }

    .fx-divider {
        height: 110px;
    }

    .fx-divider-hud {
        gap: 8px;
        padding: 6px 12px;
        font-size: 0.56rem;
        letter-spacing: 0.2em;
    }

    .fx-hud-bar {
        width: 16px;
    }
}

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