@use "../abstracts/index"as *;

html,
body,
div,
span,
applet,
object,
iframe,
h1,
h2,
h3,
h4,
h5,
h6,
p,
blockquote,
pre,
a,
abbr,
acronym,
address,
big,
cite,
code,
del,
dfn,
em,
img,
ins,
kbd,
q,
s,
samp,
small,
strike,
strong,
sub,
sup,
tt,
var,
b,
u,
i,
center,
dl,
dt,
dd,
ol,
ul,
li,
fieldset,
form,
label,
legend,
table,
caption,
tbody,
tfoot,
thead,
tr,
th,
td,
article,
aside,
canvas,
details,
embed,
figure,
figcaption,
footer,
header,
hgroup,
menu,
nav,
output,
ruby,
section,
summary,
time,
mark,
audio,
video {
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
    font-family: inherit;
    font-size: 100%;
    font-style: inherit;
    font-weight: inherit;
}

article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
menu,
nav,
section {
    display: block;
}

/* Elements
-------------------------------------------------------------- */

html {
    margin-right: 0 !important;
    scroll-behavior: smooth;
}

/* Reserve scrollbar gutter so opening Bootstrap modals / offcanvas / popups
   does not shift body content right by ~15px. Wrapped in @supports because
   iOS Safari <16 (and overlay-scrollbar OSes like macOS default) handle it
   differently — fallback keeps current behavior. */
@supports (scrollbar-gutter: stable) {
    html {
        scrollbar-gutter: stable;
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: $font-main;
    font-weight: 400;
    font-size: var(--body-size, 16px);
    line-height: 26px;
    color: var(--text);
    background: var(--white);

    /* Guard against horizontal page drag on mobile when a single section
       (full-bleed slider, negative-margin row, etc.) overflows the viewport.
       Clipped on `body` (not `html`) so it never propagates to the viewport,
       which would disable vertical scrolling; and `clip` (not `hidden`) so
       `body` does NOT become a scroll container - keeping `position: sticky`
       (sticky header, `.sticky-top` sidebars) working. Also removes the
       horizontal offset the
       Bootstrap modal freezes the page at, which made the layout look like it
       "shifted/compressed" behind the login popup on mobile. */
    overflow-x: clip;

    &::-webkit-scrollbar {
        width: 3px; //
    }

    &::-webkit-scrollbar-thumb {
        cursor: grab;
        background-color: var(--primary);
        border-radius: 999px;
    }

    @include res(xl) {
        padding-bottom: 70px;
    }
}


img {
    max-width: 100%;
    height: auto;
    transform: scale(1);
    vertical-align: middle;
    -ms-interpolation-mode: bicubic;
}

ul,
li {
    list-style-type: none;
    margin-bottom: 0;
    padding-left: 0;
    list-style: none;
}

table {
    width: 100%;
    overflow-x: auto;
    table-layout: auto;
    border-collapse: collapse;
}

td,
th {
    padding: 0px 0px 12px;
}



svg path {
    @include transition3();
}

button {
    background: transparent;
    border: 0;
    display: inline-flex;
    @include transition3;
}

select,
option {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}

/* Since FF19 lowers the opacity of the placeholder by default */

:-ms-input-placeholder {
    color: var(--secondary-2);
}

b,
strong {
    font-weight: bolder;
}

video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

a {
    @include transition3;
    text-decoration: none;
    cursor: pointer;
    display: inline-block;
    font-family: $font-main;
    color: var(--text);

    &:focus,
    &:hover {
        outline: 0;
    }
}

p {
    display: block;
}

.grid-2 {
    @include grid(2, 1fr);
}

.grid-3 {
    @include grid(3, 1fr);
}

.grid-4 {
    @include grid(4, 1fr);
}

.grid-6 {
    @include grid(6, 1fr);
}


[data-grid="grid-1"] {
    display: grid;
    gap: 30px;
    grid-template-columns: 1fr;
}

[data-grid="grid-2"] {
    display: grid;
    gap: 30px;
    grid-template-columns: 1fr 1fr;
}

[data-grid="grid-3"] {
    display: grid;
    gap: 30px;
    grid-template-columns: repeat(3, 1fr);
}

[data-grid="grid-4"] {
    display: grid;
    gap: 30px;
    grid-template-columns: repeat(4, 1fr);
}

[data-grid="grid-5"] {
    display: grid;
    gap: 30px;
    grid-template-columns: repeat(5, 1fr);
}

[data-grid="grid-6"] {
    display: grid;
    gap: 30px;
    grid-template-columns: repeat(6, 1fr);
}

[data-grid="grid-7"] {
    display: grid;
    gap: 30px;
    grid-template-columns: repeat(7, 1fr);
}

.grid-template-columns-2 {
    grid-template-columns: 1fr 1fr;
}

.tf-row-flex {
    display: flex;
    flex-direction: row;
    column-gap: 30px;
    row-gap: 30px;
}


.overflow-unset {
    overflow: unset !important;
}

.sticky-top {
    position: sticky !important;
    z-index: 50;
    top: 15px;
    @include transition3;

    &.no-offset {
        top: 0;
    }
}

.wmax {
    width: max-content !important;
}


#scroll-top {
    position: fixed;
    display: block;
    width: 48px;
    height: 48px;
    line-height: 50px;
    border-radius: 4px;
    z-index: 1;
    border-radius: 50%;
    opacity: 0;
    visibility: hidden;
    cursor: pointer;
    overflow: hidden;
    z-index: 100;
    background-color: var(--main);
    border: 0;
    bottom: 92px;
    right: 20px;
    padding: 0;
    @include flex(center, center);
    @include transition3;

    &.show {
        opacity: 1;
        visibility: visible;
    }

    &.type-1 {
        bottom: 140px;
    }

    &:hover {
        transform: translateY(-5px);
        background-color: var(--primary);
    }
}

/* Preload 
------------------------------------------- */
.preload-container {
    display: flex;
    position: relative;
    width: 100%;
    height: 100%;
    background: #ffffff;
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    left: 0;
    z-index: 99999999999;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 3px solid transparent;
    border-top: 3px solid var(--text);
    border-radius: 100%;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    animation: spin 1s infinite linear;

    &.type-primary {
        border-top-color: var(--primary);
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.br-line {
    width: 100%;
    height: 1px;
    display: flex;
    background-color: var(--line);

    &.type-vertical {
        width: 1px;
        height: 16px;
    }

    &.fake-class {
        position: absolute;
        left: 0;
        right: 0;
    }

    &.h-24 {
        height: 24px;
    }
}

.br-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--primary);
}

.tf-swiper {
    .swiper-slide {
        height: auto;

        >* {
            height: 100%;
        }

    }
}



.initial-child-container {
    flex: 0 0 auto;
    display: flex;
    min-width: auto;
    flex-direction: row;
    align-items: center;
}

.marquee-wrapper {
    display: flex;
    animation: infiniteScroll 7s linear infinite;
    align-items: center;
    transition: animation-duration 300ms;
}



.flex-xl-1 {
    @include res(xl, min) {
        flex: 1 !important;
    }
}

.flex-sm-1 {
    @include res(sm, min) {
        flex: 1 !important;
    }
}

.h-unset {
    height: unset !important;
}

.opacity-10 {
    opacity: 0.1 !important;
}

@include res(sm, min) {
    .h-sm-100 {
        height: 100% !important;
    }
}

@include res(xl, min) {
    .gap-xl-64 {
        gap: 64px !important;
    }

    .gap-xl-40 {
        gap: 40px !important;
    }

    .h-xl-unset {
        height: unset !important;
    }
}

@include res(xxl, min) {
    .text-xxl-nowrap {
        white-space: nowrap !important;
    }
}



.w-maxcontent {
    width: max-content !important;
}