/**
 1. Root
 2. Initial
 3. Reusable Classes
 4. Components
 5. Layout
 6. Pages
 7. Utilities
 8. Media Queries
**/
/* 1. Root */

/* 2. Initial */
html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    -o-box-sizing: border-box;
    -ms-box-sizing: border-box;
}

body {
    color: var(--paragraph-color);
    font-family: var(--inter-font);
    font-size: 0.875rem;
    line-height: 1.4;
}

html,
body {
    scroll-snap-type: y mandatory;
    scroll-behavior: smooth;
}

a {
    display: inline-block;
    text-decoration: none;
    color: inherit;
}

span {
    display: inline-block;
}

p {
    margin-bottom: 0;
}

img {
    max-width: 100%;
}

/* 3. Reusable Classes */
.unset {
    all: unset;
}

/* Speacing */
.mb-12 {
    margin-bottom: 12px;
}

.custom-container {
    max-width: 1920px;
    margin: 0 auto;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    justify-content: space-between;

    &.center {
        align-items: center;
    }
}

.flex-1 {
    flex: 1;
}

.flex-180 {
    flex: 1 1 180px;
}

.flex-220 {
    flex: 1 1 220px;
}

.max-w-200 {
    max-width: 200px;
}

.cursor-pointer {
    cursor: pointer;
}

.custom-scroll-bar {
    &::-webkit-scrollbar {
        width: 6px;
    }

    &::-webkit-scrollbar-track {
        background-color: transparent;
    }

    &::-webkit-scrollbar-thumb {
        background-color: var(--border-color);
        border-radius: 10px;
        transition: all 0.3s ease-in-out;
    }

    &::-webkit-scrollbar-thumb:hover {
        background-color: #777777;
    }
}

/* Image  Settings */
.base-20 {
    --image-base-size: 20px;
}

.base-24 {
    --image-base-size: 24px;
}

.base-30 {
    --image-base-size: 30px;
}

.base-40 {
    --image-base-size: 40px;
}

.base-48 {
    --image-base-size: 48px;
}

.base-50 {
    --image-base-size: 50px;
}

.rounded-image {
    width: var(--image-base-size);
    aspect-ratio: 1/1;
    flex-shrink: 0;
    border-radius: 50%;

    img {
        border-radius: 50%;
        height: 100%;
        width: 100%;
        object-fit: cover;
    }
}

/*Text setting*/
h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--secondary-color);
    margin-bottom: 0;
}

.page-title {
    font-size: 1.5rem;
    line-height: 1.17;
    font-weight: 600;
}

/* Font Size */
.fs-22 {
    font-size: 1.375rem;
    line-height: 1.4;
}

.fs-20 {
    font-size: 1.25rem;
    line-height: 1.4;
}

.fs-18 {
    font-size: 1.125rem;
    line-height: 1.4;
}

.fs-16 {
    font-size: 1rem;
    line-height: 1.4;
}

.fs-14 {
    font-size: 0.875rem;
    line-height: 1.4;
}

.fs-12 {
    font-size: 0.75rem;
    line-height: 1.4;
}

.fw-700 {
    font-weight: 700;
}

.fw-600 {
    font-weight: 600;
}

.fw-500 {
    font-weight: 500;
}

.fw-400 {
    font-weight: 400;
}

.lh-1 {
    line-height: 1;
}

/* Color Settings */
/* Text Colors */
.primary-text {
    color: var(--primary-color);
}

.black-text {
    color: var(--secondary-color);
}

.white-text {
    color: var(--white);
}

.paragraph-color {
    color: var(--paragraph-color);
}

.gradient-text {
    background: linear-gradient(90deg, var(--secondary-color), rgba(255, 255, 255, 0.1), var(--secondary-color));
    background-size: 50% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 2s infinite linear;
    font-weight: 500;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    100% {
        background-position: 100% 50%;
    }
}

/* BAckground color settings */
.bg-pastel-blue {
    background-color: var(--sc-pastel-blue);
}

.bg-peach-cream {
    background-color: var(--sc-peach-cream);
}

.bg-lavender-mist {
    background-color: var(--sc-lavender-mist);
}

.bg-mint-green {
    background-color: var(--sc-mint-green);
}

.bg-White {
    background-color: var(--white);
}

.bg-gray {
    background-color: var(--sc-light-gray);
}

.bg-orange-light {
    background-color: var(--sc-orange-light);
}

/* Main Structure */
.panel-wraper {
    display: flex;
}

.panel-left {
    width: 260px;
    height: 100svh;
    padding: 16px;
    padding-right: 8px;
    background-color: var(--sc-light-gray);
    border: 1px solid var(--border-color);
    transition: width 0.5s ease-in-out;
    position: sticky;
    top: 0;
}

.panel-right {
    flex: 1;
    padding: 40px;
    max-width: calc(100% - 260px);
    transition: max-width 0.5s ease-in-out;
}

/* Sidebar settings */
.sidebar {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.sidebar-logo {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;

    .navbar-brand {
        max-width: 148px;
        opacity: 1;
        visibility: visible;
        transition: max-width 0.3s ease, opacity 0.2s linear 0.3s, visibility 0s linear 0.3s;
    }

    .sidebar-toggleler {
        border: none;
        display: flex;
        margin-right: 10px;

        .expand-icon {
            display: none;
        }
    }
}

.sidebar-menu {
    .sidebar-menu-list {
        list-style: none;
        display: flex;
        flex-direction: column;
        gap: 8px;
        padding: 0;
        padding-right: 8px;
        margin: 0;
        height: calc(100svh - 194px);
        overflow-y: auto;
        overflow-x: clip;
    }

    .sidebar-menu-link {
        display: flex;
        gap: 8px;
        padding: 8px;
        border-radius: 6px;
        font-weight: 500;
        color: var(--secondary-color);
        transition: all 0.3s ease-in-out;

        &:hover,
        &.active {
            background-color: var(--white);
        }
    }

    .sidebar-menu-text {
        opacity: 1;
        visibility: visible;
        max-width: fit-content;
        transition: max-width 0.3s ease, opacity 0.2s linear 0.3s, visibility 0s linear 0.3s;
    }
}

.user-profile-menu-btn {
    display: flex;
    gap: 8px;
    padding: 8px;
    border-radius: 6px;
    align-items: center;
    background-color: var(--white);

    .img {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        overflow: hidden;
        flex-shrink: 0;

        img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }
    }

    .text-part {
        opacity: 1;
        visibility: visible;
        max-width: fit-content;
        transition: max-width 0.3s ease, opacity 0.2s linear 0.3s, visibility 0s linear 0.3s;
    }
}

/* sidebar when collapsed */
.panel-left.sidebar-collapsed {
    width: 74px;

    .sidebar-logo {
        justify-content: start;

        .navbar-brand {
            max-width: 0;
            opacity: 0;
            visibility: hidden;
            transition: max-width 0.3s ease, opacity 0.2s linear 0s, visibility 0s linear 0.2s;
        }

        .sidebar-toggleler {
            .expand-icon {
                display: block;
            }

            .close-icon {
                display: none;
            }
        }
    }

    .sidebar-menu-link {
        width: fit-content;
        gap: 0;
    }

    .sidebar-menu-text,
    .user-profile-menu-btn .text-part {
        white-space: nowrap;
        max-width: 0;
        opacity: 0;
        visibility: hidden;
        transition: max-width 0.3s ease, opacity 0.2s linear 0s, visibility 0s linear 0.2s;
    }
}

.panel-left.sidebar-collapsed + .panel-right {
    max-width: calc(100% - 74px);
}

/* Components */
/* Badge And Status Settings */
.custom-badge {
    font-size: 0.875rem;
    line-height: 1.4;
    padding: 4px 12px;
    border-radius: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
    /* Size */

    &.icon {
        padding: 4px 8px;
    }

    &.sm {
        font-size: 0.75rem;
        line-height: 1.2;
        padding: 3px 6px;
    }

    /* Color */

    &.purple {
        color: var(--sc-purple);
        background-color: var(--sc-lavender-mist);
    }

    &.sky-blue {
        color: var(--sc-sky-blue);
        background-color: var(--sc-pastel-blue);
    }

    &.orange {
        color: var(--sc-orange);
        background-color: var(--sc-peach-cream);
    }

    &.green {
        color: var(--sc-green);
        background-color: var(--sc-mint-green);
    }

    &.red {
        color: var(--sc-red);
        background-color: var(--sc-rose-pink);
    }

    &.light-gray {
        color: var(--paragraph-color);
        background-color: var(--sc-light-gray);
    }

    &.peach-cream {
        color: var(--paragraph-color);
        background-color: var(--sc-light-gray);
    }

    &.light-gray {
        color: var(--paragraph-color);
        background-color: var(--sc-light-gray);
    }
}

/* Breadcrumb */
.breadcrumb {
    padding-left: 0;
    margin-bottom: 0;
    display: flex;
    justify-content: start;
    gap: 20px;
    font-size: 1rem;
    color: var(--paragraph-color);

    li::marker {
        content: "> ";
    }

    li:first-child {
        padding-left: 0;

        &::marker {
            content: none;
        }
    }
}

/* Button Settings */
.cmn-btn {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 5px 11px;
    border: 1px solid transparent;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s ease-in-out;

    &.md-btn {
        padding: 9px 12px;
    }
}

/* Border Settings */
.borderd {
    border: 1px solid var(--border-color);
}

.border-b {
    border-bottom: 1px solid var(--border-color);
}

.border-t {
    border-top: 1px solid var(--border-color);
}

.border-r {
    border-right: 1px solid var(--border-color);
}

.border-l {
    border-left: 1px solid var(--border-color);
}

.rounded-sm {
    border-radius: 4px;
}

.rounded-md {
    border-radius: 6px;
}

.rounded-lg {
    border-radius: 8px;
}

.rounded-xl {
    border-radius: 12px;
}

.rounded-2xl {
    border-radius: 16px;
}

.rounded-100 {
    border-radius: 100px;
}

.rounded {
    border-radius: 50%;
}

.black-btn {
    background-color: var(--secondary-color);
    color: var(--white);

    &:hover {
        color: var(--secondary-color);
        background-color: transparent;
        border-color: var(--secondary-color);
    }
}

.primary-btn {
    color: var(--white);
    background-color: var(--primary-color);

    &:hover {
        color: var(--primary-color);
        background-color: transparent;
        border-color: var(--primary-color);
    }
}

.gray-btn-outline {
    border-color: var(--border-color);
    color: var(--paragraph-color);

    &:hover {
        color: var(--primary-color);
        border-color: var(--primary-color);
    }
}

/* Action-btn only icon */
.action-btn {
    height: 30px;
    width: 30px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--sc-light-gray);
    flex-shrink: 0;
    color: var(--secondary-color);

    &.dropdown-toggle::after {
        display: none;
    }
}

/* Send btn */
.send-btn {
    height: 30px;
    width: 30px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-color);
    flex-shrink: 0;
    color: var(--white);

    &.dropdown-toggle::after {
        display: none;
    }
}

/* Icon Wraper */
.icon-wrap {
    height: 30px;
    width: 30px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--sc-light-gray);
    flex-shrink: 0;
    color: var(--secondary-color);
    cursor: pointer;

    &.sm {
        height: 24px;
        width: 24px;
        border-radius: 4px;
    }

    &.md {
        height: 40px;
        width: 40px;
        border-radius: 4px;
    }
}

/* Warning widget */
.warning-wraper {
    background-color: #fff;
    max-width: 570px;
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 12px;

    .warning-header {
        padding: 30px;
        border-radius: 12px 12px 0 0;
        text-align: center;
    }

    .warning-body {
        padding: 30px;
        border-radius: 0 0 12px 12px;

        .warning-content-wraper {
            padding: 24px;
            border-radius: 12px;
            border: 1px solid var(--border-color);
            box-shadow: 0 10px 20px 0 #00000014;
            text-align: center;
        }
    }
}

.warning-alert-wraper {
    border-radius: 12px;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1035;
    padding: 20px;
}

/* Custom Table */
.custom-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 8px;
    color: var(--secondary-color);
    border: 1px solid var(--border-color);
    overflow: hidden;

    th,
    td {
        padding: 9px 16px;
        border-bottom: 1px solid var(--border-color);

        &:not(:last-child) {
            border-right: 1px solid var(--border-color);
        }
    }

    th {
        padding-block: 13px;
        background: var(--sc-light-gray);
        color: var(--paragraph-color);
        font-weight: 500;
    }

    tr:last-child td {
        border-bottom: none;
    }

    td {
        white-space: nowrap;

        .icon-wrap {
            color: var(--paragraph-color);
        }
    }
}

/* Custom pagination */
.custom-pagination-wraper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    list-style: none;
    margin-bottom: 0;

    .page-link {
        all: unset;
        height: 34px;
        width: 34px;
        border-radius: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
        background-color: var(--sc-light-gray);
        flex-shrink: 0;
        cursor: pointer;
        transition: all 0.3s ease-in-out;
        color: var(--secondary-color);
    }

    .page-item.active .page-link,
    .page-item:hover .page-link {
        color: var(--white);
        background-color: var(--secondary-color);
    }

    .page-item.disabled .page-link,
    .page-item.disabled:hover .page-link {
        color: var(--paragraph-color);
        background-color: var(--sc-light-gray);
        opacity: 0.8;
        cursor: default;
    }

    .page-item:first-child .page-link {
        border-top-left-radius: 8px;
        border-bottom-left-radius: 8px;
    }

    .page-item:last-child .page-link {
        border-top-right-radius: 8px;
        border-bottom-right-radius: 8px;
    }
}

/* Stat Card */
.stat-card {
    padding: 16px;
    border-radius: 8px;

    .top-part {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 8px;
    }

    .icon-part {
        display: flex;
        gap: 8px;
        align-items: center;
    }

    .icon-wraper {
        width: 40px;
        height: 40px;
        border-radius: 8px;
        display: flex;
        justify-content: center;
        align-items: center;
        flex-shrink: 0;
        background-color: var(--white);
    }

    .bottom-part {
        display: flex;
        align-items: center;
        gap: 8px;

        .sender-image {
            height: 24px;
            width: 24px;
            border-radius: 50%;
            overflow: hidden;
            flex-shrink: 0;

            img {
                height: 100%;
                width: 100%;
                object-fit: cover;
            }
        }
    }
}

/* Form Setting */
.custom-label {
    color: var(--secondary-color);
}

.custom-input {
    padding: 9px 12px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    width: 100%;
    transition: width 0.3s ease-in-out;

    &:focus {
        outline: none;
    }

    &::placeholder {
        color: var(--paragraph-color);
    }
}

.custom-input-wraper.with-icon {
    position: relative;

    .custom-input {
        padding-left: 30px;
    }

    .search-icon {
        position: absolute;
        top: 50%;
        left: 12px;
        transform: translateY(-50%);
    }
}

.password-input-field {
    position: relative;

    .icon {
        position: absolute;
        top: 50%;
        right: 12px;
        transform: translateY(-50%);
        cursor: pointer;
    }
}

/* Customize Select 2 */
.custom-select {
    padding: 9px 12px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    width: 100%;
    transition: width 0.3s ease-in-out;
    color: var(--paragraph-color);
    background: transparent;

    &:focus {
        outline: none;
    }

    &::placeholder {
        color: var(--paragraph-color);
    }
}

.custom-select + .select2 {
    span {
        display: block;
    }

    .select2-selection--single {
        height: auto;
        padding: 9px 12px;
        border: 1px solid var(--border-color);
        border-radius: 6px !important;
        background: transparent;

        .select2-selection__rendered {
            line-height: 1.4;
            padding: 0;
            color: var(--paragraph-color);
        }

        .select2-selection__arrow {
            all: unset;
            position: absolute;
            top: 50%;
            right: 20px;
            transform: translateY(-50%);

            b {
                all: unset;
                border: solid var(--paragraph-color);
                border-width: 0 2px 2px 0;
                border-radius: 2px;
                display: inline-block;
                padding: 3px;
                transform: rotate(45deg);
                -webkit-transform: rotate(45deg);
                margin: 3px 0 0 2px;
                transition: all 0.3s ease-in-out;
            }
        }
    }

    &.select2-container--open {
        .select2-selection__arrow {
            b {
                transform: rotate(-135deg);
                -webkit-transform: rotate(-135deg);
            }
        }
    }
}

.custom-select.w-100 + .select2 {
    width: 100% !important;
}

.custom-select.white-bg + .select2 {
    background-color: var(--white);
}

.select2-dropdown {
    border: 1px solid var(--border-color) !important;
    border-radius: 10px !important;
    overflow: hidden;
    z-index: 1055;

    .select2-search--dropdown {
        padding: 18px 20px;

        .select2-search__field {
            border: 1px solid var(--border-color);
            border-radius: 6px;
            padding: 8px 12px;

            &:focus {
                outline: none;
            }
        }
    }

    .select2-results__option {
        padding: 8px 20px;
        transition: all 0.2s ease-in-out;

        &.select2-results__option--highlighted {
            background-color: var(--primary-color);
        }
    }

    &.select2-dropdown--up {
        margin-bottom: 8px;
    }

    &.select2-dropdown--below {
        margin-top: 8px;
    }
}

/* Search */
.csutom-search-wraper {
    position: relative;

    .csutom-search-input {
        border: 1px solid transparent;
        padding: 9px 12px;
        padding-left: 24px;
        border-radius: 6px;
        border-color: var(--border-color);
        width: 100%;
        transition: width 0.3s ease-in-out;

        &:focus {
            outline: none;
        }
    }

    .search-icon {
        color: var(--secondary-color);
        position: absolute;
        top: 8px;
        left: 7px;
    }

    /* &.open {
       .csutom-search-input {
           width: 100%;
       }
   } */
}

/* Custom Checkbox */
.custom-checkbox-wraper {
    height: 30px;
    width: 30px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.custom-checkbox {
    appearance: none;
    -webkit-appearence: none;
    height: 16px;
    width: 16px;
    vertical-align: middle;
    background: #fff;
    border-radius: 6px;
    position: relative;
    border: 1.5px solid var(--paragraph-color);
    transition: all 0.3s;
    cursor: pointer;

    &::after {
        content: "\f00c";
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
        position: absolute;
        color: #fff;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
        font-size: 10px;
    }

    &:checked {
        background: var(--primary-color);
        border-color: var(--primary-color);
    }
}

.custom-switch {
    appearance: none;
    width: 22px;
    height: 13px;
    border-radius: 100px;
    background-color: var(--paragraph-color);
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease-in-out;

    &::after {
        content: "";
        position: absolute;
        top: 1px;
        left: 1px;
        width: 11px;
        height: 11px;
        border-radius: 50%;
        background-color: var(--sc-light-gray);
        transition: all 0.3s ease-in-out;
    }

    &:checked {
        background-color: var(--primary-color);

        &::after {
            left: 10px;
        }
    }
}

.custom-radio {
    appearance: none;
    width: 1em;
    height: 1em;
    border-radius: 50%;
    background-color: var(--color, gray);
    position: relative;
    cursor: pointer;
    border: 1px solid var(--color, gray);
    transition: all 0.3s ease-in-out;

    &::after {
        content: "";
        position: absolute;
        top: 50%;
        left: 50%;
        width: 1rem;
        height: 1rem;
        border-radius: 50%;
        transform: translate(-50%, -50%);
        background-color: var(--color, gray);
        transition: all 0.3s ease-in-out;
    }

    &:checked {
        background-color: transparent;
    }
}

/* custom color palate */
.color-palate {
    width: 1em; /* outer circle size */
    height: 1em;
    border: 1px dashed #5b6bff; /* dashed border like in your image */
    border-radius: 50%; /* circular shape */
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.color-palate input[type="color"] {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 50%;
    padding: 0;
    cursor: pointer;
    background: transparent;
    -webkit-appearance: none;
}

.color-palate input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
    border-radius: 50%;
}

.color-palate input[type="color"]::-webkit-color-swatch {
    border: none;
    border-radius: 50%;
}

.color-palate:hover {
    transform: scale(1.1); /* optional hover effect */
}

/* Custom Image Input */
.custom-image-input-field-wraper {
    border: 1px dashed var(--primary-color);
    border-radius: 6px;
    background-color: #586bf11a;
    padding: 16px;
    min-height: 130px;
    text-align: center;

    .uplod-image {
        height: 70px;
        width: 100px;
        border-radius: 6px;
        overflow: hidden;
        position: relative;

        .cancel-btn {
            position: absolute;
            top: 4px;
            right: 4px;
            height: 16px;
            width: 16px;
            border-radius: 50%;
            background-color: #dc3545;
            color: var(--white);
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
            transition: all 0.3s ease-in-out;
            opacity: 0;
            visibility: hidden;
        }

        .uploaded-image-wraper {
            height: 100%;
            width: 100%;
            display: flex;
            justify-content: center;
            align-items: center;
            border-radius: 6px;
            border: 1px dashed var(--primary-color);
        }

        img {
            height: 100%;
            width: 100%;
            object-fit: cover;
        }

        &:hover {
            .cancel-btn {
                opacity: 1;
                visibility: visible;
            }
        }
    }

    .csutom-image-input-btn {
        padding: 6px 8px;
        display: inline-flex;
        align-items: center;
        gap: 4px;
        border-radius: 4px;
        border: 1px solid transparent;
        color: var(--secondary-color);
        background-color: var(--white);
        cursor: pointer;
        transition: all 0.3s ease-in-out;

        &:hover {
            background-color: var(--primary-color);
            color: var(--white);
        }
    }
}

/* Custom Dropdown */
.custom-dropdown-menu {
    border: 1px solid var(--border-color);
    color: var(--secondary-color);
    font-size: 0.875rem;
    padding: 8px;
    border-radius: 6px;

    .dropdown-item {
        padding: 8px;
        border-radius: 6px;
        color: var(--secondary-color);
        transition: all 0.3s ease-in-out;

        &:hover {
            background-color: var(--sc-light-gray);
        }
    }
}

/* Custom Modal */
.custom-modal {
    .modal-content {
        border-radius: 16px;
        border: 1px solid var(--border-color);
    }

    .modal-header {
        padding: 40px;
        padding-bottom: 0;
    }

    .modal-body {
        padding: 24px 40px;
    }

    .modal-footer {
        padding: 40px;
        padding-top: 0;
    }
}

/* Custom nav tabs */
.custom-nav-tab-waper {
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.custom-nav-tabs {
    padding: 12px 20px;
    background-color: var(--sc-light-gray);
    display: flex;
    gap: 6px;
    border-radius: 12px 12px 0 0;

    .nav-link {
        padding: 8px 20px;
        border-radius: 6px;
        background-color: transparent;
        color: var(--secondary-color);
        font-size: 0.875rem;
        font-weight: 500;
        line-height: 1.3;
        transition: all 0.3s ease-in-out;

        &.active {
            background-color: var(--white);
        }
    }
}

.custom-tab-content {
    padding: 0 20px 20px 20px;
}

/* Custom Accordion */
.custom-accordion {
    border-radius: 8px;
    border: 1px solid var(--border-color);
    overflow: hidden;

    .custom-accordion-header {
        padding: 8px 16px;
        background-color: var(--sc-light-gray);
        border-radius: 8px 8px 0 0;
        display: flex;
        justify-content: space-between;

        .cancel-icon {
            background: var(--white);
        }
    }

    .custom-accordion-body {
        padding: 16px;
    }
}

/* Card Setting */

/* Knowledge Card */
.knowledge-card {
    padding: 16px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;

    .left-part {
        display: flex;
        align-items: center;
        gap: 24px;
    }

    .content-part {
        display: flex;
        gap: 8px;
    }

    .media {
        width: 100px;
        height: 72px;
        border-radius: 8px;
        overflow: hidden;
        flex-shrink: 0;

        img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }
    }

    .right-part {
        display: flex;
        gap: 8px;
    }
}

/* Notification Card */
.notification-card {
    background-color: #fff;
    transition: all .3s ease-in-out;

    &.active {
        background-color: var(--sc-light-gray);
    }
}

/* Ticker Form Card */
.ticket-form-card,
.consent-form-card {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 6px;

    .left-part {
        display: flex;
        align-items: center;
        gap: 8px;

        .form-name {
            color: var(--secondary-color);
            font-weight: 500;
        }
    }

    .right-part {
        display: flex;
        align-items: center;
        gap: 8px;

        .icon-wraper {
            color: var(--paragraph-color);
        }
    }
}

/* users card for chat and user */
.userCard {
    padding: 16px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    gap: 12px;
    background-color: var(--white);
    transition: all 0.3s ease-in-out;

    .img {
        height: 40px;
        width: 40px;
        border-radius: 50%;
        flex-shrink: 0;
        position: relative;

        img {
            width: 100%;
            height: 100%;
            border-radius: 50%;
            object-fit: cover;
        }

        .flag {
            position: absolute;
            right: 0;
            bottom: 0;
            height: 12px;
            width: 12px;
            display: flex;
            justify-content: center;
            align-items: center;
            border-radius: 50%;
            overflow: hidden;
            border: 1px solid var(--white);

            img {
                width: 100%;
                height: 100%;
                object-fit: cover;
            }
        }
    }

    .text-part {
        flex: 1;
    }

    .name-wraper {
        display: flex;
        justify-content: space-between;
        gap: 8px;
    }

    .name {
        font-size: 1rem;
        font-weight: 600;
        color: var(--secondary-color);
    }

    .small-message {
        margin-top: 4px;
        font-size: 0.875rem;
        color: var(--paragraph-color);
    }

    &:hover,
    &.active {
        border-color: var(--sc-light-gray);
        background-color: var(--sc-light-gray);
    }
}

/*==============================================
              All Pages
==============================================*/

/* Knowledge page */
.bulk-action-search {
    .right-part {
        flex: 1 1 500px;
        justify-content: end;
    }
}

/* Chatbot page */

.chatbot-wraper {
    border-radius: 12px;
    border: 1px solid var(--border-color);
    max-width: 566px;
    margin-left: auto;
    height: 100%;

    .chatbot-header {
        padding: 30px;
        border-radius: 12px 12px 0 0;
        background-color: var(--brand-color, var(--primary-color));
        color: var(--white);
        display: flex;
        justify-content: space-between;
        gap: 20px;

        .content-part {
            display: flex;
            gap: 12px;

            .img {
                height: 50px;
                width: 50px;
                border-radius: 50%;
                background: var(--white);
                display: flex;
                align-items: center;
                justify-content: center;

                img {
                    max-height: 100%;
                    max-width: 100%;
                    border-radius: 50%;
                }
            }
        }
    }

    .chatbot-body {
        padding: 30px;

        .chatbot-message-wraper {
            max-width: 70%;
            width: fit-content;
        }

        .chatbot-message-content {
            padding: 12px;
            border-radius: 16px;
            background-color: var(--sc-light-gray);
            color: var(--secondary-color);

            .chatbot-logo {
                display: flex;
                gap: 8px;
                align-items: center;
                margin-bottom: 14px;

                .img {
                    height: 24px;
                    width: 24px;
                    border-radius: 4px;
                    background: var(--brand-color, var(--primary-color));
                    display: flex;
                    align-items: center;
                    justify-content: center;

                    &.round {
                        border-radius: 50%;
                    }

                    &.bg-transparent {
                        background: transparent;
                    }

                    img {
                        max-height: 100%;
                        max-width: 100%;
                        border-radius: 4px;
                    }
                }

                .name {
                    font-size: 0.875rem;
                    line-height: 20px;
                    font-weight: 600;
                }
            }

            .text {
                font-size: 0.875rem;
                line-height: 1.3;
            }

        }

        .chatbot-message-wraper {
            cursor: default;

            .time {
                display: block;
                text-align: end;
                font-size: 0.65rem;
                font-weight: 400;
                line-height: 16px;
                color: var(--paragraph-color);
                opacity: 0.6;
                margin-top: 4px;
                margin-left: 36px;
                padding: 0;
            }

            &.user {
                margin-left: auto;

                .chatbot-message-content {
                    background-color: #011d3c;
                    color: var(--white);
                }

                .time {
                    text-align: end;
                    margin-left: 0;
                    margin-right: 8px;
                    color: var(--paragraph-color) !important;
                    opacity: 0.6 !important;
                }
            }
        }
    }

    .chatbot-footer {
        padding: 30px;
        border-radius: 0 0 12px 12px;
        background-color: var(--white);

        .input-wraper {
            position: relative;
            padding: 16px;
            border-radius: 12px;
            background: linear-gradient(#fff, #fff) padding-box, linear-gradient(90deg, var(--brand-color, #4f6ef7), #c46bf5, var(--brand-color, #4f6ef7)) border-box;
            border: 2px solid transparent;
        }

        .icon-field {
            position: relative;

            .icon {
                position: absolute;
                top: 0;
                left: 0;
            }
        }

        .custom-input {
            border: none;
            padding: 0;
            padding-left: 32px;
            min-height: 40px;
            max-height: 150px;
            overflow-y: auto;
            resize: none;

            &::placeholder {
                color: var(--paragraph-color);
            }
        }

        .send-btn {
            background: var(--brand-color, var(--primary-color));
        }
    }
}

/* Chatbot widget Design */
/* Chatbot widget */
.chatbot-widget-wraper {
    height: 100svh;

    .chatbot-wraper {
        margin-left: unset;
        position: relative;
        height: 100%;
        max-width: 100%;
        display: flex;
        flex-direction: column;
    }

    .chatbot-header {
        position: sticky;
        top: 0;
        z-index: 100;
        padding: 18px;

        .content-part .img {
            height: 40px;
            width: 40px;
        }
    }

    .chatbot-body-wraper {
        height: 100%;
        display: flex;
        flex-direction: column;
    }

    .chatbot-body {
        padding: 18px;
        margin-top: auto;
        flex: 1 1 0;
        overflow: hidden auto;
        display: flex;
        flex-direction: column;
    }

    .scroll-to-bottom-btn-wrapper {
        position: absolute;
        top: -40px;
        left: 50%;
        transform: translateX(-50%);

        .scroll-to-bottom {
            height: 32px;
            width: 32px;
            border-radius: 50%;
            background-color: var(--white);
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);
        }
    }

    .chatbot-footer-wraper {
        padding-bottom: 0;
    }

    .chatbot-footer {
        padding: 18px;
        padding-top: 0;
        width: 100%;
    }
}

/* Chatbot page Installation wraper */
.installation-code-container-wraper {
    border-radius: 8px;
    overflow: hidden;
    background: var(--sc-light-gray);

    .header {
        padding: 12px;
        background-color: var(--sc-pastel-blue);
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 12px;
    }

    .code-container {
        padding: 12px;
    }
}

/* Prefarance Settings */
.preference-group {
    padding: 12px;
    border-radius: 6px;
    background-color: var(--sc-light-gray);

    .slider-labels {
        display: grid;
        grid-template-columns: repeat(5, 1fr);
    }

    .slider-label {
        text-align: center;
        margin-bottom: 16px;

        .num {
            height: 24px;
            width: 24px;
            border-radius: 50%;
            background: transparent;
            color: var(--paragraph-color);
            border: 1px solid var(--border-color);
            display: inline-flex;
            align-items: center;
            justify-content: center;
            font-size: 0.875rem;
            font-weight: 600;
            transition: all 0.3s ease;
            margin-top: 8px;

            &.active {
                color: var(--white);
                background-color: var(--primary-color);
                border-color: var(--primary-color);
            }
        }
    }
}

.preference-slider {
    width: 100%;
    accent-color: var(--primary-color);
}

.preference-slider {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    background: #e1e1e2;
    border-radius: 50px;
    outline: none;
    position: relative;
    margin-top: 12px;
    background-image: linear-gradient(to right, var(--primary-color) 0%, var(--primary-color) 50%, #e1e1e2 50%);
    background-size: 100% 100%;
    background-repeat: no-repeat;
    transition: all 0.3s ease-in-out;
}

.preference-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: 3px solid var(--white);
    outline: 1px solid var(--primary-color);
    margin-top: -3px;
    transition: background 0.3s ease;
}

.preference-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: 3px solid var(--white);
    outline: 1px solid var(--primary-color);
}

/* Chat list page */
/* User list */
.userList-wraper-part {
    flex: 1;
    max-width: 410px;
    border-right: 1px solid var(--border-color);
    height: 100svh;
    position: sticky;
    top: 0;
    overflow-y: auto;
}

.userList-header {
    padding: 30px;
    border-bottom: 1px solid var(--border-color);
}

.userList-wraper {
    overflow-y: auto;
    max-height: calc(100svh - 86px);
    padding: 30px;

    .userListItems {
        display: flex;
        flex-direction: column;
        gap: 16px;
        flex: 1;
    }
}

.chat-list-page-wraper {
    display: flex;

    .chat-conversation-part {
        flex: 1;
        height: 100svh;
        position: sticky;
        top: 0;
        display: flex;
        flex-direction: column;

        .chat-conversation-head {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 30px;
            border-bottom: 1px solid var(--border-color);

            .right-part {
                display: flex;
                gap: 12px;
                align-items: center;
            }
        }

        .chatbot-wraper {
            margin-left: unset;
            border: none;
            border-radius: 0;
            max-width: 100%;
            position: relative;
            height: 100%;
            display: flex;
            flex-direction: column;

            .chatbot-body-wraper {
                overflow-y: auto;
                display: flex;
                flex-direction: column;
                flex: 1 1 0;
            }

            .chatbot-body {
                margin-top: auto;
            }

            .chatbot-footer {
                padding: 30px;
                padding-top: 0;
            }
        }
    }
}

.chat-contact-info-wraper-part {
    padding: 30px;
    max-width: 430px;
    flex: 1;
    height: 100%;
    border-left: 1px solid var(--border-color);

    .info-wraper-card {
        padding: 20px;
        border-radius: 12px;
        border: 1px solid var(--border-color);
        background-color: #f3f3f3cc;
    }

    .contact-info-card {
        padding: 12px;
        border-radius: 6px;
        border: 1px solid var(--border-color);
        background-color: #ffffff;
    }

    .profile-info {
        display: flex;
        gap: 12px;
        align-items: center;
    }
}

/* Visitor page */
.visitors-location-wraper-part {
    flex: 1;
    align-self: stretch;
    padding: 30px;

    .map-wraper {
        width: 100%;
        height: 100%;

        iframe {
            width: 100%;
            height: 100%;
            border-radius: 12px;
            border: 1px solid var(--border-color);
        }
    }
}

/* Animation for chatbor */
.celebrate {
    animation: pop 0.4s ease;
    appearance: none;
}

@keyframes pop {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.4);
    }
    100% {
        transform: scale(1);
    }
}

/* =========================
   Wavize Widget Toggler + Iframe (NEW)
   - Compatible avec embed.js (class .visible)
   - Compatible position left/right (wz-left / wz-right)
   - Mobile fullscreen
   ========================= */

.chat-toggler-wraper{
    position: fixed;
    z-index: 2147483646;
    bottom: 22px;
    right: 22px;
    left: auto;

    /* évite de “bouger” si le site a des transforms */
    transform: translateZ(0);
}

/* Position venant du JS: applyPosition(container) */
.chat-toggler-wraper.wz-right{
    right: 22px;
    left: auto;
}
.chat-toggler-wraper.wz-left{
    left: 22px;
    right: auto;
}

/* Le bouton (launcher) */
#chatbot-toggler{
    display: flex;
    align-items: center;
    justify-content: center;
}

/* IMPORTANT: ton JS met class="wz-launcher-btn" */
#chatbot-toggler-btn.wz-launcher-btn{
    width: 62px;
    height: 62px;
    border-radius: 999px;
    border: 0;
    background: var(--brand-color, #4f46e5);
    color: #fff;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 14px 40px rgba(0,0,0,.25);
    cursor: pointer;

    transition: transform .15s ease, filter .15s ease, box-shadow .15s ease;
}

/* SVG inherits currentColor */
#chatbot-toggler-btn.wz-launcher-btn svg{
    display: block;
    color: currentColor;
}

#chatbot-toggler-btn.wz-launcher-btn:hover{
    transform: translateY(-1px);
    filter: brightness(1.02);
    box-shadow: 0 16px 44px rgba(0,0,0,.28);
}

#chatbot-toggler-btn.wz-launcher-btn:active{
    transform: translateY(0px) scale(.98);
}

/* Animation “bouncing” (ton JS toggle cette class sur #chatbot-toggler) */
#chatbot-toggler.bouncing{
    animation: wz-bounce .22s ease;
}
@keyframes wz-bounce{
    0%{ transform: scale(1); }
    50%{ transform: scale(1.06); }
    100%{ transform: scale(1); }
}

/* Iframe wrapper (panel) */
.chat-toggler-wraper .chatbot-widget-iframe{
    position: fixed;

    /* position desktop */
    bottom: 96px;
    width: 390px;
    height: 560px;

    background: #fff;
    border-radius: 18px;
    overflow: hidden;

    box-shadow: 0 18px 50px rgba(2, 6, 23, .22);
    border: 1px solid rgba(15, 23, 42, .10);

    /* fermé par défaut */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(14px) scale(.98);
    transition: opacity .18s ease, transform .18s ease, visibility .18s ease;

    z-index: 2147483647;
}

/* Position du panel selon left/right */
.chat-toggler-wraper.wz-right .chatbot-widget-iframe{
    right: 22px;
    left: auto;
    transform-origin: bottom right;
}
.chat-toggler-wraper.wz-left .chatbot-widget-iframe{
    left: 22px;
    right: auto;
    transform-origin: bottom left;
}

/* ✅ ouvert (ton JS met .visible) */
.chat-toggler-wraper .chatbot-widget-iframe.visible{
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}

/* iframe inside */
.chat-toggler-wraper .chatbot-widget-iframe iframe{
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    border-radius: inherit;
    background: #fff;
}

/* ✅ Mobile fullscreen */
@media (max-width: 640px){
    /* bouton un peu plus bas */
    .chat-toggler-wraper.wz-right{ right: 18px; }
    .chat-toggler-wraper.wz-left{ left: 18px; }

    #chatbot-toggler-btn.wz-launcher-btn{
        width: 64px;
        height: 64px;
        bottom: 18px;
    }

  .chat-toggler-wraper .chatbot-widget-iframe{
    left: 0 !important;
    right: 0 !important;
    top: 0 !important;
    bottom: 0 !important;

    width: 100vw !important;
    height: 100dvh !important;   /* ✅ au lieu de 100vh */
    border-radius: 0 !important;
  }
}
    .chat-toggler-wraper .chatbot-widget-iframe.visible{
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none !important;
    }
}


/* User Settings */
.user-settings-wraper {
    display: flex;
}

.user-settings-nav-wraper {
    padding: 16px;
    height: 100svh;
    flex: 1;
    max-width: 260px;

    .user-settings-nav {
        display: flex;
        flex-direction: column;
        gap: 8px;

        .user-settings-nav-link {
            display: flex;
            gap: 8px;
            padding: 8px;
            border-radius: 6px;
            font-weight: 500;
            font-size: 0.875rem;
            line-height: 1.4;
            color: var(--secondary-color);
            transition: all 0.3s ease-in-out;

            &:hover,
            &.active {
                background-color: var(--sc-light-gray);
                color: var(--primary-color);
            }
        }
    }
}

.user-settings-tav-content-wraper {
    flex: 1;
    padding: 30px;
}

/* =========================
   Wavize – Products Slider (FINAL)
   ========================= */

.wz-products{
  font-family: inherit;
  color:#111827;
  font-size:14px;
  line-height:1.45;
}

.wz-products__title{
  margin:0 0 10px;
  font-size:14px;
}

.wz-products__tip{
  margin-top:10px;
  color:#111827;
  font-size:14px;
}

/* =========================
   Slider wrapper
   ========================= */

.wz-products__slider{
  position:relative;
}

/* Horizontal rail */
.wz-products__rail{
  display:flex;
  gap:12px;
  overflow-x:auto;

  scroll-snap-type:x mandatory;
  padding:8px 44px;

  -webkit-overflow-scrolling:touch;
  scrollbar-width:none;
}
.wz-products__rail::-webkit-scrollbar{
  display:none;
}

/* =========================
   Card
   ========================= */

.wz-card{
  flex:0 0 210px;
  scroll-snap-align:start;

  background:#fff;
  border:1px solid rgba(0,0,0,.10);
  border-radius:14px;
  overflow:hidden;

  box-shadow:0 2px 10px rgba(0,0,0,.06);
  transition:box-shadow .15s ease, transform .15s ease;
}

.wz-card:hover{
  box-shadow:0 6px 18px rgba(0,0,0,.10);
  transform:translateY(-1px);
}

/* =========================
   Media
   ========================= */

.wz-card__media{
  display:block;
  width:100%;
  height:150px;
  background:#f3f4f6;
}

.wz-card__media img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.wz-card__noimg{
  display:flex;
  width:100%;
  height:100%;
  align-items:center;
  justify-content:center;
  color:#6b7280;
  font-size:12px;
}

/* =========================
   Card body
   ========================= */

.wz-card__body{
  padding:10px 12px 6px;
}

.wz-card__name{
  font-weight:600;
  font-size:13px;
  line-height:1.25;
  margin:0 0 6px;
  word-break:break-word;
}

.wz-card__price{
  font-weight:700;
  font-size:13px;
  color:#111827;
}

/* =========================
   Bottom actions (FINAL)
   ========================= */

.wz-card__actions{
  display:flex;
  flex-direction:column;      /* 1 bouton par ligne */
  gap:6px;

  padding:8px 10px 10px;
  border-top:1px solid rgba(0,0,0,.08);
  background:#fafafa;
}

/* Bouton commun */
.wz-action{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:6px;

  padding:7px 10px;           /* compact */
  border-radius:10px;
  border:1px solid rgba(0,0,0,.14);

  background:#ffffff;
  color:#111827;

  cursor:pointer;
  font-size:12.5px;
  font-weight:700;
  line-height:1.2;

  text-decoration:none;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;

  transition:
    background .15s ease,
    border-color .15s ease,
    transform .12s ease;
}

.wz-action:hover{
  background:#f3f4f6;
  border-color:#d1d5db;
}

.wz-action:active{
  transform:scale(.98);
}

/* Variante secondaire */
.wz-action--ghost{
  background:#f7f7f7;
}

/* Icône */
.wz-ic{
  font-size:12px;
  opacity:.85;
  flex:0 0 auto;
}

/* Texte */
.wz-action__txt{
  overflow:hidden;
  text-overflow:ellipsis;
}

/* =========================
   Slider arrows (overlay)
   ========================= */

.wz-slide-arrow{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  z-index:5;

  width:36px;
  height:36px;

  border-radius:12px;
  border:1px solid rgba(0,0,0,.14);
  background:rgba(255,255,255,.92);

  color:#111827;
  font-size:28px;
  font-weight:900;
  line-height:1;

  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;

  box-shadow:0 6px 16px rgba(0,0,0,.12);
  transition:
    background .15s ease,
    transform .12s ease,
    opacity .15s ease;
}

.wz-slide-arrow--left{ left:6px; }
.wz-slide-arrow--right{ right:6px; }

.wz-slide-arrow:hover{
  background:#ffffff;
}

.wz-slide-arrow:active{
  transform:translateY(-50%) scale(.96);
}

.wz-slide-arrow.is-hidden{
  opacity:0;
  pointer-events:none;
}



#wz-panel{
  height: var(--wz-vh) !important;
  max-height: var(--wz-vh) !important;
}

/* fallback moderne */
@supports (height: 100dvh){
  #wz-panel{
    height: 100dvh !important;
    max-height: 100dvh !important;
  }
}


.chatbot-footer-wraper{
  padding-bottom: env(safe-area-inset-bottom) !important;
}


