/*
 * Spark course catalogue page: hero with live search and category chips, glass filter bar.
 * Loaded only by classes_spark.blade.php (Spark theme).
 */

.sx-catalog {
    position: relative;
    overflow: hidden;
    padding: 92px 0 64px;
    color: #e8f1ff;
    background: #010819 url("/assets/design_1/img/spark/hero-flow.webp") center / cover no-repeat;
}

.sx-catalog::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(700px 360px at 85% -10%, rgba(79, 180, 255, .34), transparent 65%),
        radial-gradient(600px 320px at 0% 100%, rgba(10, 71, 184, .5), transparent 65%),
        linear-gradient(180deg, rgba(1, 8, 25, .82), rgba(5, 41, 106, .74));
}

.sx-catalog__art {
    position: absolute;
    inset-inline-end: 4%;
    top: 14%;
    width: 360px;
    height: 220px;
    background: url("/assets/design_1/img/spark/overlay-orbit.webp") center / contain no-repeat;
    opacity: .85;
    animation: spark-float 9s ease-in-out infinite;
    pointer-events: none;
}

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

.sx-catalog__crumbs {
    display: flex;
    align-items: center;
    margin-bottom: 22px;
    font-size: 13px;
    color: rgba(207, 224, 245, .7);
}

.sx-catalog__crumbs a { color: inherit; }
.sx-catalog__crumbs a:hover { color: #fff; }
.rtl .sx-catalog__crumbs svg { transform: scaleX(-1); }

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

.sx-catalog__title {
    max-width: 760px;
    margin: 18px 0 0;
    font-size: clamp(32px, 4.6vw, 56px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.02em;
    color: #fff;
    background: linear-gradient(90deg, #fff 30%, #9fe2ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.sx-catalog__lead {
    margin: 14px 0 0;
    max-width: 620px;
    font-size: 17px;
    line-height: 1.7;
    color: rgba(207, 224, 245, .8);
}

/* Search */
.sx-catalog__search {
    position: relative;
    max-width: 640px;
    margin-top: 30px;
}

.sx-catalog__search svg {
    position: absolute;
    inset-inline-start: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #9fe2ff !important;
    fill: currentColor;
    z-index: 2;
    pointer-events: none;
}

.sx-catalog__search input {
    width: 100%;
    height: 58px;
    padding: 0 20px;
    padding-inline-start: 52px;
    font-size: 16px;
    color: #fff;
    border-radius: 18px;
    border: 1px solid rgba(159, 226, 255, .28);
    background: rgba(255, 255, 255, .07);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    outline: 0;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.sx-catalog__search input::placeholder { color: rgba(207, 224, 245, .6); }

.sx-catalog__search input:focus {
    border-color: #4fb4ff;
    background: rgba(255, 255, 255, .1);
    box-shadow: 0 0 0 5px rgba(79, 180, 255, .18), 0 18px 44px rgba(1, 8, 25, .4);
}

/* Category chips */
.sx-catalog__chips {
    display: flex;
    gap: 10px;
    margin-top: 26px;
    padding: 4px 2px 10px;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(79, 180, 255, .4) transparent;
}

.sx-chip { margin: 0; flex-shrink: 0; cursor: pointer; }
.sx-chip input { position: absolute; opacity: 0; pointer-events: none; }

.sx-chip span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
    color: #cfe0f5;
    border: 1px solid rgba(159, 226, 255, .2);
    background: rgba(255, 255, 255, .05);
    transition: transform .2s ease, background .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
}

.sx-chip span b {
    min-width: 24px;
    padding: 1px 7px;
    border-radius: 999px;
    text-align: center;
    font-size: 11px;
    background: rgba(159, 226, 255, .16);
}

.sx-chip:hover span { transform: translateY(-2px); border-color: rgba(79, 180, 255, .6); color: #fff; }

.sx-chip input:checked + span {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, #0a47b8, #2f8cff);
    box-shadow: 0 12px 30px rgba(47, 140, 255, .4);
}

.sx-chip input:focus-visible + span { outline: 2px solid #9fe2ff; outline-offset: 2px; }

/* Filter bar and sidebar: lighter, glassy, aligned with the hero */
.sx-catalog__filters { margin-top: -28px; position: relative; z-index: 3; }

.sx-catalog__filters .courses-lists-filters > .position-relative {
    border: 1px solid rgba(79, 180, 255, .24);
    box-shadow: 0 20px 50px rgba(5, 41, 106, .16);
}

.spark-skin .sx-catalog ~ .container .courses-lists-left-filters,
.spark-skin .sx-catalog ~ .container [class*="left-filters"] {
    border-radius: 22px;
}

@media (max-width: 991px) {
    .sx-catalog { padding: 36px 0 52px; }
    .sx-catalog__art { display: none; }
    .sx-catalog__search input { height: 52px; }
}

@media (prefers-reduced-motion: reduce) {
    .sx-catalog__art { animation: none; }
}
