/*
 * Spark home sections: ribbon, "find your path", bento grid, journey, closing call to action.
 * Self-contained: dark sections use fixed Spark colors, so they look the same in light and dark mode.
 * Motion is transform/opacity only and is switched off by prefers-reduced-motion.
 */

.sx {
    --sx-night: #010819;
    --sx-navy: #05296a;
    --sx-electric: #0a47b8;
    --sx-bright: #2f8cff;
    --sx-sky: #4fb4ff;
    --sx-ice: #9fe2ff;
    position: relative;
    overflow: hidden;
    padding: 96px 0;
}

.sx-dark {
    color: #e8f1ff;
    background: linear-gradient(180deg, #010819 0%, #031640 55%, #010819 100%);
}

.sx__bg span {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    opacity: .55;
    animation: sx-drift 22s ease-in-out infinite alternate;
}

.sx__bg span:nth-child(1) { width: 520px; height: 520px; left: -160px; top: -120px; background: rgba(10, 71, 184, .6); }
.sx__bg span:nth-child(2) { width: 460px; height: 460px; right: -140px; bottom: -140px; background: rgba(79, 180, 255, .35); animation-delay: -8s; }

@keyframes sx-drift {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(40px, 30px, 0); }
}

.sx .container { position: relative; z-index: 1; }

/* ---------------------------------------------------------------- Headings */

.sx__head { max-width: 720px; margin: 0 auto 56px; text-align: center; }
.sx__head--left { margin: 0; text-align: start; }

.sx__eyebrow {
    display: inline-block;
    margin-bottom: 16px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--sx-ice);
    border: 1px solid rgba(159, 226, 255, .28);
    background: rgba(79, 180, 255, .08);
}

.sx__title {
    margin: 0;
    font-size: clamp(30px, 4.4vw, 52px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.02em;
}

.sx__title--xl { font-size: clamp(36px, 6vw, 72px); }

.sx__grad {
    background: linear-gradient(90deg, #4fb4ff, #9fe2ff 60%, #ffffff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.sx__lead {
    margin: 18px auto 0;
    max-width: 620px;
    font-size: 17px;
    line-height: 1.7;
    opacity: .78;
}

.sx__head--left .sx__lead { margin-inline-start: 0; }

/* ---------------------------------------------------------------- Buttons */

.sx-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    border-radius: 14px;
    font-weight: 700;
    font-size: 14px;
    color: #e8f1ff;
    text-decoration: none;
    border: 1px solid rgba(159, 226, 255, .32);
    background: rgba(255, 255, 255, .04);
    transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}

.sx-btn:hover { color: #fff; background: rgba(79, 180, 255, .16); transform: translateY(-2px); }
.rtl .sx-btn svg { transform: scaleX(-1); }

.sx-btn--solid {
    border-color: transparent;
    background: linear-gradient(135deg, #0a47b8, #2f8cff);
    box-shadow: 0 14px 34px rgba(47, 140, 255, .35);
}

.sx-btn--solid:hover { background: linear-gradient(135deg, #0a47b8, #4fb4ff); box-shadow: 0 18px 44px rgba(79, 180, 255, .5); }
.sx-btn--lg { padding: 16px 28px; font-size: 16px; border-radius: 16px; }

/* ---------------------------------------------------------------- Ribbon */

.sx-marquee {
    padding: 28px 0;
    background: #010819;
    border-block: 1px solid rgba(159, 226, 255, .1);
}

.sx-marquee__label {
    margin: 0 0 14px;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: rgba(159, 226, 255, .6);
}

.sx-marquee__row {
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.sx-marquee__row + .sx-marquee__row { margin-top: 12px; }

.sx-marquee__track {
    display: flex;
    width: max-content;
    animation: sx-scroll 38s linear infinite;
}

.sx-marquee__row[data-dir="right"] .sx-marquee__track { animation-direction: reverse; animation-duration: 46s; }
.sx-marquee:hover .sx-marquee__track { animation-play-state: paused; }

.sx-marquee__group { display: flex; align-items: center; flex-shrink: 0; }

.sx-marquee__item {
    padding: 0 22px;
    white-space: nowrap;
    font-size: clamp(20px, 3vw, 34px);
    font-weight: 800;
    letter-spacing: -.01em;
    color: transparent;
    -webkit-text-stroke: 1px rgba(159, 226, 255, .55);
    transition: color .25s ease;
}

.sx-marquee__row[data-dir="right"] .sx-marquee__item { -webkit-text-stroke: 0; color: rgba(232, 241, 255, .82); font-weight: 600; font-size: clamp(16px, 2vw, 22px); }
.sx-marquee__item:hover { color: #4fb4ff; -webkit-text-stroke-color: #4fb4ff; }

.sx-marquee__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4fb4ff, #9fe2ff);
    box-shadow: 0 0 14px rgba(79, 180, 255, .8);
}

@keyframes sx-scroll {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(-50%, 0, 0); }
}

.rtl .sx-marquee__track { animation-name: sx-scroll-rtl; }

@keyframes sx-scroll-rtl {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(50%, 0, 0); }
}

/* ---------------------------------------------------------------- Find your path */

.sx-paths__grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 28px;
    align-items: start;
}

.sx-paths__tabs { display: flex; flex-direction: column; gap: 8px; max-height: 560px; overflow-y: auto; padding-inline-end: 6px; scrollbar-width: thin; scrollbar-color: rgba(79, 180, 255, .4) transparent; }

.sx-paths__tab {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 14px 16px;
    border-radius: 16px;
    text-align: start;
    color: #cfe0f5;
    border: 1px solid rgba(159, 226, 255, .1);
    background: rgba(255, 255, 255, .03);
    transition: transform .2s ease, background .2s ease, border-color .2s ease, color .2s ease;
}

.sx-paths__tab:hover { transform: translateX(4px); background: rgba(79, 180, 255, .1); }
.rtl .sx-paths__tab:hover { transform: translateX(-4px); }

.sx-paths__tab.is-active {
    color: #fff;
    border-color: rgba(79, 180, 255, .6);
    background: linear-gradient(135deg, rgba(10, 71, 184, .55), rgba(47, 140, 255, .22));
    box-shadow: 0 12px 32px rgba(10, 71, 184, .35);
}

.sx-paths__num { font-size: 12px; font-weight: 800; color: var(--sx-sky); letter-spacing: .08em; }
.sx-paths__name { flex: 1; font-weight: 700; font-size: 15px; line-height: 1.3; }

.sx-paths__count {
    min-width: 28px;
    padding: 2px 8px;
    border-radius: 999px;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    background: rgba(159, 226, 255, .14);
}

.sx-paths__stage { position: relative; min-height: 440px; }

.sx-paths__panel { display: none; }
.sx-paths__panel.is-active { display: block; animation: sx-panel .5s cubic-bezier(.2, .7, .2, 1) both; }

@keyframes sx-panel {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
}

.sx-paths__panel-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.sx-paths__panel-head h3 { margin: 0; font-size: 26px; font-weight: 800; color: #fff; }
.sx-paths__panel-head p { margin: 4px 0 0; font-size: 14px; color: rgba(207, 224, 245, .7); }

.sx-paths__cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.sx-paths__empty { padding: 40px; text-align: center; border-radius: 18px; border: 1px dashed rgba(159, 226, 255, .3); color: rgba(207, 224, 245, .7); }

.sx-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 20px;
    color: inherit;
    text-decoration: none;
    border: 1px solid rgba(159, 226, 255, .14);
    background: rgba(255, 255, 255, .04);
    transition: transform .3s cubic-bezier(.2, .7, .2, 1), border-color .3s ease, box-shadow .3s ease;
}

.sx-card:hover { transform: translateY(-8px); border-color: rgba(79, 180, 255, .6); box-shadow: 0 24px 50px rgba(0, 0, 0, .35), 0 0 0 1px rgba(79, 180, 255, .25); color: inherit; }
.sx-card__img { display: block; aspect-ratio: 360 / 250; overflow: hidden; }
.sx-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease; }
.sx-card:hover .sx-card__img img { transform: scale(1.08); }
.sx-card__body { display: flex; flex-direction: column; gap: 10px; padding: 16px; flex: 1; }
.sx-card__title { font-weight: 700; font-size: 15px; line-height: 1.4; color: #fff; }
.sx-card__meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; color: rgba(207, 224, 245, .7); }
.sx-card__price { margin-top: auto; font-weight: 800; font-size: 16px; color: var(--sx-ice); }

/* ---------------------------------------------------------------- Bento */

.sx-bento__grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 18px; }

.sx-tile {
    position: relative;
    overflow: hidden;
    min-height: 300px;
    padding: 26px;
    border-radius: 26px;
    border: 1px solid rgba(159, 226, 255, .14);
    background: linear-gradient(160deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .02));
    backdrop-filter: blur(10px);
    transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}

.sx-tile:hover { border-color: rgba(79, 180, 255, .5); box-shadow: 0 24px 56px rgba(0, 0, 0, .35); transform: translateY(-4px); }
.sx-tile h3 { margin: 18px 0 8px; font-size: 20px; font-weight: 800; color: #fff; }
.sx-tile p { margin: 0; font-size: 14px; line-height: 1.65; color: rgba(207, 224, 245, .78); }

.sx-tile--pace { grid-column: span 5; }
.sx-tile--lang { grid-column: span 4; }
.sx-tile--numbers { grid-column: span 3; display: flex; align-items: center; }
.sx-tile--cert { grid-column: span 3; }
.sx-tile--practice { grid-column: span 4; }
.sx-tile--teams { grid-column: span 5; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 24px; background: linear-gradient(135deg, rgba(10, 71, 184, .6), rgba(47, 140, 255, .25)); }
.sx-tile--teams h3 { margin-top: 0; font-size: 26px; }

/* Progress ring */
.sx-ring { position: relative; width: 132px; height: 132px; }
.sx-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.sx-ring circle { fill: none; stroke-width: 9; }
.sx-ring__bg { stroke: rgba(159, 226, 255, .14); }
.sx-ring__fg { stroke: #4fb4ff; stroke-linecap: round; stroke-dasharray: 327; stroke-dashoffset: 327; transition: stroke-dashoffset 1.6s cubic-bezier(.2, .7, .2, 1); filter: drop-shadow(0 0 8px rgba(79, 180, 255, .7)); }
.sx-ring strong { position: absolute; inset: 0; display: grid; place-items: center; font-size: 28px; font-weight: 800; color: #fff; }

/* Language switch */
.sx-lang__switch { display: inline-flex; padding: 4px; border-radius: 14px; background: rgba(1, 8, 25, .6); border: 1px solid rgba(159, 226, 255, .2); }
.sx-lang__switch button { padding: 8px 18px; border-radius: 10px; font-weight: 700; font-size: 13px; color: #cfe0f5; background: transparent; border: 0; transition: background .2s ease, color .2s ease; }
.sx-lang__switch button.is-active { background: linear-gradient(135deg, #0a47b8, #2f8cff); color: #fff; }
.sx-lang__sample { margin: 22px 0 0 !important; min-height: 56px; font-size: 18px !important; font-weight: 700; color: #fff !important; transition: opacity .25s ease, transform .25s ease; }
.sx-lang__sample.is-swapping { opacity: 0; transform: translateY(8px); }
.sx-lang__sample[dir="rtl"] { text-align: right; }
.sx-lang__sample[dir="ltr"] { text-align: left; }

/* Numbers */
.sx-tile--numbers ul { margin: 0; padding: 0; list-style: none; width: 100%; display: grid; gap: 20px; }
.sx-tile--numbers li { display: flex; align-items: baseline; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid rgba(159, 226, 255, .12); }
.sx-tile--numbers li:last-child { border: 0; padding: 0; }
.sx-tile--numbers strong { font-size: 40px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; background: linear-gradient(90deg, #4fb4ff, #fff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.sx-tile--numbers span { font-size: 13px; color: rgba(207, 224, 245, .75); }

/* Certificate */
.sx-cert {
    position: relative;
    width: 100%;
    max-width: 230px;
    padding: 20px 18px 16px;
    border-radius: 16px;
    border: 1px solid rgba(159, 226, 255, .4);
    background: linear-gradient(135deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .03));
    box-shadow: 0 18px 40px rgba(0, 0, 0, .35);
    transform: perspective(700px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
    transition: transform .15s ease-out;
}

.sx-cert__seal { width: 44px; height: 44px; margin-bottom: 14px; }
.sx-cert__seal img { width: 100%; height: 100%; }
.sx-cert__line { display: block; height: 6px; margin-bottom: 8px; border-radius: 4px; background: rgba(159, 226, 255, .35); }
.sx-cert__line--short { width: 60%; }
.sx-cert em { display: block; margin-top: 10px; font-style: normal; font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--sx-ice); }

/* Orbit */
.sx-orbit { position: relative; width: 132px; height: 132px; }
.sx-orbit__core { position: absolute; inset: 50px; border-radius: 50%; background: radial-gradient(circle, #9fe2ff, #2f8cff); box-shadow: 0 0 28px rgba(79, 180, 255, .9); }
.sx-orbit__ring { position: absolute; border-radius: 50%; border: 1px solid rgba(159, 226, 255, .3); animation: sx-spin 12s linear infinite; }
.sx-orbit__ring i { position: absolute; top: -4px; left: 50%; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: #9fe2ff; box-shadow: 0 0 12px #4fb4ff; }
.sx-orbit__ring--1 { inset: 30px; animation-duration: 7s; }
.sx-orbit__ring--2 { inset: 14px; animation-duration: 11s; animation-direction: reverse; }
.sx-orbit__ring--3 { inset: 0; animation-duration: 16s; }

@keyframes sx-spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------- Journey */

.sx-journey { background: linear-gradient(180deg, #f3f7fc, #e6f6ff); color: #010819; }
.dark-mode .sx-journey { background: linear-gradient(180deg, #030a1c, #0b1a3d); color: #eaf3ff; }
.sx-journey__layout { display: grid; grid-template-columns: 1fr 1.2fr; gap: 64px; align-items: start; }
.sx-journey__head { position: sticky; top: 120px; }
.sx-journey .sx__eyebrow { color: #0a47b8; border-color: rgba(10, 71, 184, .25); background: rgba(10, 71, 184, .06); }
.dark-mode .sx-journey .sx__eyebrow { color: #9fe2ff; }
.sx-journey .sx__grad { background: linear-gradient(90deg, #0a47b8, #4fb4ff); -webkit-background-clip: text; background-clip: text; }

.sx-journey__steps { position: relative; margin: 0; padding: 0; list-style: none; display: grid; gap: 28px; padding-inline-start: 64px; }

.sx-journey__rail { position: absolute; inset-block: 12px; inset-inline-start: 22px; width: 3px; border-radius: 3px; background: rgba(10, 71, 184, .14); }
.sx-journey__rail i { display: block; width: 100%; height: 0; border-radius: 3px; background: linear-gradient(180deg, #4fb4ff, #0a47b8); box-shadow: 0 0 14px rgba(79, 180, 255, .8); }

.sx-step { position: relative; opacity: .4; transform: translateX(14px); transition: opacity .5s ease, transform .5s ease; }
.rtl .sx-step { transform: translateX(-14px); }
.sx-step.is-reached { opacity: 1; transform: none; }

.sx-step__num {
    position: absolute;
    inset-inline-start: -64px;
    top: 14px;
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    font-weight: 800;
    color: #0a47b8;
    background: #fff;
    border: 2px solid rgba(10, 71, 184, .25);
    transition: all .4s ease;
}

.sx-step.is-reached .sx-step__num { color: #fff; border-color: transparent; background: linear-gradient(135deg, #0a47b8, #4fb4ff); box-shadow: 0 0 0 6px rgba(79, 180, 255, .2), 0 0 24px rgba(79, 180, 255, .7); }

.sx-step__card { padding: 24px 26px; border-radius: 22px; background: #fff; border: 1px solid rgba(10, 71, 184, .12); box-shadow: 0 16px 40px rgba(5, 41, 106, .08); transition: box-shadow .3s ease; }
.dark-mode .sx-step__card { background: #0d1d42; border-color: rgba(79, 180, 255, .2); }
.sx-step.is-reached .sx-step__card { box-shadow: 0 22px 52px rgba(10, 71, 184, .18); }
.sx-step h3 { margin: 0 0 8px; font-size: 20px; font-weight: 800; }
.sx-step p { margin: 0; font-size: 15px; line-height: 1.7; opacity: .75; }

/* ---------------------------------------------------------------- Closing call to action */

.sx-cta { padding: 140px 0; text-align: center; }
.sx-cta__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.sx-cta__inner { position: relative; z-index: 2; max-width: 860px; margin: 0 auto; }
.sx-cta__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; margin-top: 38px; }

/* ---------------------------------------------------------------- Reveal (class added by JS, so nothing hides without JS) */

.sx-reveal.sx-pending { opacity: 0; transform: translateY(26px); }
.sx-reveal { transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }

/* ---------------------------------------------------------------- Responsive */

@media (max-width: 991px) {
    .sx { padding: 72px 0; }
    .sx-paths__grid { grid-template-columns: 1fr; }
    .sx-paths__tabs { flex-direction: row; max-height: none; overflow-x: auto; padding-bottom: 8px; }
    .sx-paths__tab { width: auto; flex-shrink: 0; }
    .sx-paths__cards { grid-template-columns: 1fr 1fr; }
    .sx-bento__grid { grid-template-columns: 1fr 1fr; }
    .sx-tile--pace, .sx-tile--lang, .sx-tile--numbers, .sx-tile--cert, .sx-tile--practice, .sx-tile--teams { grid-column: span 1; }
    .sx-tile--teams { grid-column: span 2; }
    .sx-journey__layout { grid-template-columns: 1fr; gap: 36px; }
    .sx-journey__head { position: static; }
}

@media (max-width: 575px) {
    .sx-paths__cards { grid-template-columns: 1fr; }
    .sx-bento__grid { grid-template-columns: 1fr; }
    .sx-tile--teams { grid-column: span 1; }
    .sx-journey__steps { padding-inline-start: 56px; }
    .sx-step__num { inset-inline-start: -56px; width: 40px; height: 40px; }
    .sx-journey__rail { inset-inline-start: 19px; }
}

@media (prefers-reduced-motion: reduce) {
    .sx *, .sx *::before, .sx *::after { animation: none !important; transition: none !important; }
    .sx-reveal.sx-pending { opacity: 1; transform: none; }
    .sx-step { opacity: 1; transform: none; }
}
