/* Blog page intro: views/blog/_hero.php, _search.php; behaviour in assets/js/blog-page.js */
.bh-wrap {
    margin-top: 40px;
}
.bh-layer {
    display: block;
    height: 20px;
    margin: 0 59px;
    border-radius: 30px 30px 0 0;
    background: #3A3466;
}
.bh-layer-2 {
    margin: 0 30px;
    background: #2B2652;
}
.bh {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 34px 34px 28px;
    border-radius: 32px;
    color: #fff;
    background:
        radial-gradient(rgba(255, 255, 255, .05) 1px, transparent 1.4px) 0 0 / 18px 18px,
        linear-gradient(160deg, #0B0920, #16123A 55%, #1F1950);
    box-shadow: 0 34px 70px -34px rgba(17, 14, 45, .85);
}
.bh-stars {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(1.2px 1.2px at 12% 18%, #fff, transparent),
        radial-gradient(1px 1px at 28% 72%, rgba(255, 255, 255, .8), transparent),
        radial-gradient(1.4px 1.4px at 46% 12%, #fff, transparent),
        radial-gradient(1px 1px at 63% 88%, rgba(255, 255, 255, .7), transparent),
        radial-gradient(1.3px 1.3px at 82% 30%, #fff, transparent),
        radial-gradient(1px 1px at 92% 66%, rgba(255, 255, 255, .8), transparent);
    animation: bhTwinkle 4.5s ease-in-out infinite;
    will-change: opacity;
}
@keyframes bhTwinkle {
    50% { opacity: .3; }
}
.bh-glow {
    position: absolute;
    top: -18%;
    left: 50%;
    z-index: -1;
    width: 760px;
    height: 460px;
    border-radius: 50%;
    background: radial-gradient(closest-side, rgba(238, 93, 56, .32), rgba(155, 123, 255, .14) 60%, transparent);
    transform: translateX(-50%);
}
.bh-top {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 410px;
}
.bh-center {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: min(540px, 100%);
    text-align: center;
}
.bh-tag {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 6px 15px;
    border: 1px solid rgba(255, 255, 255, .13);
    border-radius: 999px;
    background: rgba(255, 255, 255, .07);
    font-size: 13px;
}
.bh-tag-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #47DC94;
    box-shadow: 0 0 0 4px rgba(71, 220, 148, .22);
}
.bh-title {
    margin-top: 14px;
    font-size: 60px;
    line-height: 1.3;
}
.bh-title em {
    font-style: normal;
    color: #EE5D38;
}
.bh-search {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    height: 62px;
    margin-top: 20px;
    padding: 0 22px;
    border-radius: 999px;
    color: #110E2D;
    background: #fff;
    box-shadow: 0 22px 44px -18px rgba(0, 0, 0, .7), 0 0 0 6px rgba(255, 255, 255, .07);
    transition: box-shadow .3s;
}
.bh-search:focus-within {
    box-shadow: 0 22px 44px -18px rgba(0, 0, 0, .7), 0 0 0 6px rgba(238, 93, 56, .4);
}
.bh-search-input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    font: inherit;
    font-size: 15px;
    color: #110E2D;
}
.bh-stats {
    display: flex;
    margin-top: 24px;
}
.bh-stats div {
    display: flex;
    flex-direction: column;
    padding: 0 24px;
    border-inline-start: 1px solid rgba(255, 255, 255, .12);
}
.bh-stats div:first-child {
    border: 0;
}
.bh-stats strong {
    font-size: 26px;
    line-height: 1.3;
}
.bh-stats span {
    font-size: 12px;
    color: rgba(255, 255, 255, .55);
}

/* the floating covers */
.bh-floats {
    position: absolute;
    inset: 0;
}
.bh-float {
    --x: 0px;
    --y: 0px;
    position: absolute;
    z-index: 1;
    display: block;
    transform: translate(var(--x), var(--y));
    transition: transform .5s ease-out;
    will-change: transform;
}
.bh-float-in {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    border: 3px solid rgba(255, 255, 255, .85);
    border-radius: 20px;
    box-shadow: 0 26px 40px -20px rgba(0, 0, 0, .85);
    transform: rotate(var(--r, 0deg));
    animation: bhDrift var(--t, 8s) ease-in-out infinite alternate;
    transition: box-shadow .3s;
}
@keyframes bhDrift {
    to { translate: 0 -14px; }
}
.bh-float-in img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.bh-float-t {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    padding: 22px 10px 8px;
    background: linear-gradient(transparent, rgba(11, 9, 32, .92));
    font-size: 11.5px;
    line-height: 1.6;
    color: #fff;
    opacity: 0;
    transition: opacity .25s;
}
.bh-float:hover {
    z-index: 3;
}
.bh-float:hover .bh-float-in {
    box-shadow: 0 30px 50px -16px rgba(238, 93, 56, .8);
    animation-play-state: paused;
}
.bh-float:hover .bh-float-t,
.bh-float:focus-visible .bh-float-t {
    opacity: 1;
}
.bh-float-1 { top: 2%; left: 1%; width: 178px; --r: -6deg; --t: 8s; }
.bh-float-2 { top: 11%; left: 15.5%; width: 140px; --r: 5deg; --t: 10s; }
.bh-float-3 { top: 52%; left: 3%; width: 152px; --r: 4deg; --t: 9s; }
.bh-float-4 { top: 56%; left: 15%; width: 182px; --r: -4deg; --t: 7s; }
.bh-float-5 { top: 2%; right: 1%; width: 178px; --r: 6deg; --t: 9s; }
.bh-float-6 { top: 11%; right: 15.5%; width: 140px; --r: -5deg; --t: 7s; }
.bh-float-7 { top: 52%; right: 3%; width: 152px; --r: -4deg; --t: 10s; }
.bh-float-8 { top: 56%; right: 15%; width: 182px; --r: 4deg; --t: 8s; }

/* categories */
.bh-cats {
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, .1);
}
.bh-cat {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 42px;
    padding: 0 8px 0 14px;
    border: 1px solid rgba(255, 255, 255, .13);
    border-radius: 999px;
    background: rgba(255, 255, 255, .05);
    font-size: 13.5px;
    color: rgba(255, 255, 255, .85);
    transition: background-color .25s, border-color .25s, color .25s, transform .25s;
}
[dir="rtl"] .bh-cat {
    padding: 0 14px 0 8px;
}
.bh-cat svg {
    color: #FF9A6B;
    transition: color .25s;
}
.bh-cat b {
    min-width: 26px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    font-size: 11.5px;
    line-height: 24px;
    text-align: center;
}
.bh-cat:hover {
    border-color: #EE5D38;
    color: #fff;
    transform: translateY(-2px);
}
.bh-cat.is-active {
    border-color: transparent;
    color: #fff;
    background: linear-gradient(135deg, #FF7A50, #EE5D38);
    box-shadow: 0 12px 24px -12px rgba(238, 93, 56, .9);
}
.bh-cat.is-active svg {
    color: #fff;
}
.bh-cat.is-active b {
    background: rgba(255, 255, 255, .25);
}

/* the list under a chosen category or search */
.bh-list {
    scroll-margin-top: 16px;
}
.bh-result {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 26px;
}
.bh-result-title {
    font-size: 24px;
    line-height: 1.6;
    color: #110E2D;
}
.bh-result-title span {
    margin-inline-start: 8px;
    font-size: 13px;
    color: #EE5D38;
}
.bh-result a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 999px;
    background: #fff;
    font-size: 13px;
    color: #110E2D;
    box-shadow: 0 10px 20px -14px rgba(17, 14, 45, .5);
    transition: color .25s;
}
.bh-result a:hover {
    color: #EE5D38;
}

.bh.is-off .bh-stars,
.bh.is-off .bh-float-in {
    animation-play-state: paused;
}

@media (max-width: 1279px) {
    .bh-float-2,
    .bh-float-6 {
        display: none;
    }
    .bh-float-4 { left: 4%; top: 58%; width: 150px; }
    .bh-float-8 { right: 4%; top: 58%; width: 150px; }
    .bh-float-3,
    .bh-float-7 {
        display: none;
    }
}
@media (max-width: 1023px) {
    .bh-top {
        flex-direction: column;
        min-height: 0;
    }
    .bh-floats {
        position: relative;
        inset: auto;
        display: flex;
        justify-content: center;
        width: 100%;
        margin-bottom: 18px;
    }
    .bh-float,
    .bh-float-1,
    .bh-float-2,
    .bh-float-3,
    .bh-float-4,
    .bh-float-5,
    .bh-float-6,
    .bh-float-7,
    .bh-float-8 {
        position: relative;
        top: auto;
        right: auto;
        left: auto;
        display: none;
        width: 150px;
        margin-inline: -14px;
    }
    .bh-float-1,
    .bh-float-5,
    .bh-float-8 {
        display: block;
    }
    .bh-float-8 {
        z-index: 2;
        order: 0;
    }
    .bh-float-1 { order: -1; }
    .bh-float-5 { order: 1; }
}
@media (max-width: 639px) {
    .bh-wrap {
        margin-top: 20px;
    }
    .bh-layer {
        height: 14px;
        margin: 0 30px;
    }
    .bh-layer-2 {
        margin: 0 15px;
    }
    .bh {
        padding: 22px 14px;
        border-radius: 24px;
    }
    .bh-float,
    .bh-float-1,
    .bh-float-5,
    .bh-float-8 {
        width: 112px;
        margin-inline: -10px;
    }
    .bh-title {
        font-size: 42px;
    }
    .bh-search {
        height: 54px;
        padding: 0 16px;
    }
    .bh-stats div {
        padding: 0 14px;
    }
    .bh-stats strong {
        font-size: 21px;
    }
    .bh-cats {
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        margin-inline: -14px;
        padding-inline: 14px;
        scrollbar-width: none;
    }
    .bh-cats::-webkit-scrollbar {
        display: none;
    }
    .bh-cat {
        flex-shrink: 0;
    }
    .bh-result-title {
        font-size: 20px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .bh-stars,
    .bh-float-in {
        animation: none;
    }
}
