#view-product {

    $input-border: #b5bcc3;
    $checkbox-border: #6c757d;
    $primary: #4c8bf5;
    $row-odd: #f6f7f9;
    $row-even: #ffffff;

    .table {

        td {
            &.text-center {
                vertical-align: middle;
            }

            &:first-child {
                font-weight: 500;
                padding-left: 12px;
            }

            .form-control {
                display: inline-block;
                width: 60px;
                height: 28px;
                padding: 2px 6px;
                font-size: 12px;
                text-align: center;

                background-color: #fff;
                border: 1px solid $input-border;
                border-radius: 4px;
                box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);

                &:focus {
                    border-color: $primary;
                    box-shadow: 0 0 0 2px rgba($primary, 0.15);
                    outline: none;
                }
            }

            .form-check-input {
                display: inline-block;
                width: 16px;
                height: 16px;
                cursor: pointer;

                background-color: #fff;
                border: 1px solid $checkbox-border;

                &:checked {
                    background-color: $primary;
                    border-color: $primary;
                }
            }
        }

        th {
            text-align: center;
            font-weight: 600;

            &:first-child {
                text-align: left;
            }
        }
    }

    .table-striped > tbody > tr {
        &:nth-of-type(odd) {
            background-color: $row-odd;
        }

        &:nth-of-type(even) {
            background-color: $row-even;
        }
    }
}

#view-order {
    font-family: 'Inter', system-ui, sans-serif;

    .card {
        border-radius: 12px;
        overflow: hidden;
    }

    .risk-circle {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;

        svg {
            width: 110px;
            height: 110px;
            transform: rotate(-90deg);
        }

        .risk-progress {
            transition: stroke-dasharray 0.6s ease, stroke 0.3s ease;
        }

        .score {
            position: absolute;
            font-size: 26px;
            font-weight: 700;
        }

        @each $name, $map in $colors {
            &.risk-#{$name} {
                .risk-progress {
                    stroke: map.get($map, color);
                }

                .score {
                    color: map.get($map, color);
                }
            }
        }
    }

    .factor-item {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px;
        border-radius: 8px;
        background: #f8fafc;
    }

    .factor-icon {
        padding: 5px;
        border-radius: 9999px;
        background: rgba(22, 163, 74, 0.1);
        color: #16a34a;
    }

    .dropdown-item-blue {
        color: #0ea5e9;

        &:hover,
        &:focus {
            color: #0ea5e9;
            background-color: rgba(37, 99, 235, 0.1);
        }

        &:active,
        &.active {
            color: #0ea5e9;
            background-color: rgba(37, 99, 235, 0.15);
        }

        &:disabled,
        &.disabled {
            color: rgba(37, 99, 235, 0.4);
            cursor: not-allowed;
            opacity: 0.65;
        }
    }

    .dropdown-item-green {
        color: #16a34a;

        &:hover,
        &:focus {
            color: #16a34a;
            background-color: rgba(22, 163, 74, 0.1);
        }

        &:active,
        &.active {
            color: #16a34a;
            background-color: rgba(22, 163, 74, 0.15);
        }

        &:disabled,
        &.disabled {
            color: rgba(22, 163, 74, 0.4);
            cursor: not-allowed;
            opacity: 0.65;
        }
    }

    .dropdown-item-orange {
        color: #ea580c;

        &:hover,
        &:focus {
            color: #ea580c;
            background-color: rgba(234, 88, 12, 0.1);
        }

        &:active,
        &.active {
            color: #ea580c;
            background-color: rgba(234, 88, 12, 0.15);
        }

        &:disabled,
        &.disabled {
            color: rgba(234, 88, 12, 0.4);
            cursor: not-allowed;
            opacity: 0.65;
        }
    }

    .dropdown-item-red {
        color: #dc2626;

        &:hover,
        &:focus {
            color: #dc2626;
            background-color: rgba(220, 38, 38, 0.1);
        }

        &:active,
        &.active {
            color: #dc2626;
            background-color: rgba(220, 38, 38, 0.15);
        }

        &:disabled,
        &.disabled {
            color: rgba(220, 38, 38, 0.4);
            cursor: not-allowed;
            opacity: 0.65;
        }
    }

    .link-primary-custom {
        color: #0ea5e9;
        font-weight: 600;
        text-decoration: none;

        &:hover {
            text-decoration: underline;
            color: #0284c7;
        }
    }

    .text-primary-custom {
        color: #0ea5e9;
    }

    .btn-primary-custom {
        background: #0ea5e9;
        border-color: #0ea5e9;
        color: #fff;

        &:hover {
            background: #0284c7;
            border-color: #0284c7;
            color: #fff;
        }
    }

    h6 {
        font-size: 1rem;
    }
}

#ticket-lightbox-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 99999;
    justify-content: center;
    align-items: center;
    cursor: zoom-out;

    &.active {
        display: flex;
    }

    #ticket-lightbox-img {
        max-width: 90%;
        max-height: 90vh;
        border-radius: 6px;
        box-shadow: 0 4px 32px rgba(0, 0, 0, 0.5);
    }
}

.ticket-attachment-thumbnail {
    max-width: 120px;
    max-height: 120px;
    object-fit: cover;
    border-radius: 4px;
    cursor: zoom-in;
    margin: 4px;
    transition: opacity 0.2s ease, transform 0.2s ease;

    &:hover {
        opacity: 0.85;
        transform: scale(1.05);
    }
}

#view-editaddadminaccount {

    .staff-profile-image .ce-default-avatar-dark {
        width: 50px;
        -webkit-border-radius: 4px;
        -moz-border-radius: 4px;
        border-radius: 4px;
    }

    .profile-card {
        border: 1px solid #e5e7eb;
        border-radius: 10px;
        background: #fff;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
        overflow: hidden;

        .card-header {
            background: #f8fafc;
            border-bottom: 1px solid #e5e7eb;
            padding: 12px 16px;

            h5 {
                margin: 0;
                font-size: 14px;
                font-weight: 600;
                color: #374151;
            }
        }

        .card-body {
            padding: 16px;
        }
    }

    .form-elem {
        margin-bottom: 12px;

        label {
            font-size: 12px;
            color: #6b7280;
            margin-bottom: 4px;
        }

        .form-control,
        .form-select {
            height: 34px;
            font-size: 13px;
        }

        textarea.form-control {
            height: auto;
        }
    }
}

#view-profilebilling {
    .col-form-label[data-bs-toggle="tooltip"] {
        border-bottom: none;
        cursor: default;
    }
}

#view-profileproduct {
    .package-cancellation-box {
        border: 1px solid;
        border-radius: 8px;
        overflow: hidden;
        font-size: 13px;
        margin-bottom: 1rem;

        &__header {
            border-bottom: 1px solid;
            padding: 10px 16px;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        &__title {
            font-weight: 500;
        }

        &__badge {
            margin-left: auto;
            font-size: 11px;
            font-weight: 500;
            padding: 2px 8px;
            border-radius: 20px;
        }

        &__body {
            padding: 12px 16px;
            display: grid;
            grid-template-columns: auto 1fr;
            gap: 8px 24px;
        }

        &__label {
            color: #6c757d;
        }

        &__value {
            font-weight: 500;
        }

        &--pending {
            border-color: #F09595;

            .package-cancellation-box__header {
                background: #FCEBEB;
                border-color: #F09595;
            }

            .package-cancellation-box__title {
                color: #791F1F;
            }

            .package-cancellation-box__badge {
                background: #F7C1C1;
                color: #501313;
            }
        }

        &--processed {
            border-color: #5DCAA5;

            .package-cancellation-box__header {
                background: #E1F5EE;
                border-color: #5DCAA5;
            }

            .package-cancellation-box__title {
                color: #085041;
            }

            .package-cancellation-box__badge {
                background: #9FE1CB;
                color: #04342C;
            }
        }
    }
}
#view-customlinks {
    .cm-card {
        background: #fff;
        border: 1px solid #e5e7eb;
        border-radius: 10px;
        margin-top: 20px;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);

        &-header {
            padding: 12px 16px;
            font-weight: 600;
            border-bottom: 1px solid #eee;
            background: #f9fafb;
        }

        &-body {
            padding: 16px;
            position: relative;
        }
    }

    .code-block {
        position: relative;
        background: #1e1e1e;
        color: #dcdcdc;
        border-radius: 8px;
        padding: 15px;
        overflow-x: auto;
        font-size: 13px;
        margin-bottom: 15px;

        pre {
            margin: 0;
            white-space: pre-wrap;

            code {
                display: block;
                font-family: monospace;
            }
        }

        #copy-btn {
            position: absolute;
            top: 10px;
            right: 10px;
            display: flex;
            align-items: center;
            gap: 5px;
            padding: 5px 8px;
            font-size: 12px;
            color: #ccc;
            background: transparent;
            border: 1px solid #555;
            border-radius: 4px;
            cursor: pointer;
            transition: background 0.2s, color 0.2s, border-color 0.2s;

            &:hover {
                background: #333;
                color: #fff;
            }

            &.is-copied {
                border-color: #4caf50;
                color: #4caf50;
            }
        }
    }
}

#view-invoice {
    .card {
        .cm-holder.dt-info {
            margin-top: 0;
        }
    }
}

#product-tab-content {
    .cm-holder.dt-info {
        margin-top: 0;
    }
}


#view-dashboard {

    .dash-tile-wrapper {
        display: block;
        position: relative;
        margin-top: 20px;
        margin-bottom: 20px;
        z-index: 4;
        transition: all ease 0.2s;

        @include desktop {
            margin-top: 0;
        }

        &.go-down {
            z-index: inherit;
        }
    }

    .dashboard-counts {

        .count-block {
            padding: 0 5px;
            position: relative;
            flex: 0 0 auto;
            z-index: 1;

            &:hover,
            &:has(.dropdown-menu.show) {
                z-index: 999;
            }
        }

        @include desktop {
            .count-blocks {
                row-gap: 10px;
            }
        }

        .tile-item {
            position: relative;
            height: 135px;
            border-radius: 6px;
            overflow: hidden;
            color: #fff;
            width: 100%;
        }

        /* Gradients */
        .tile-item.bg1 { @include gradient1; }
        .tile-item.bg2 { @include gradient2; }
        .tile-item.bg3 { @include gradient3; }
        .tile-item.bg4 { @include gradient4; }
        .tile-item.bg5 { @include gradient5; }
        .tile-item.bg6 { @include gradient6; }

        .box-holder {
            position: absolute;
            top: 50%;
            left: 0;
            width: 100%;
            transform: translateY(-50%);
            padding: 0 20px;
            text-align: center;
        }

        .value {
            display: block;
            font-size: 25px;
            font-weight: 700;
            line-height: 1;
            margin-bottom: 4px;
            text-align: center;
            white-space: nowrap;
        }

        .title {
            display: block;
            font-size: 19px;
            font-weight: 500;
            line-height: 1.2;
            text-align: center;
        }

        .prev {
            position: absolute;
            left: 0;
            bottom: 0;
            width: 100%;
            height: 34px;
            line-height: 34px;
            padding: 0 20px;
            font-size: 12px;
            background: rgba(0, 0, 0, 0.1);
            color: rgba(255, 255, 255, 0.7);
            text-align: center;
        }

        .revenue-card {
            position: relative;
            overflow: visible;

            .box-holder {
                top: calc(50% + 2px);
            }

            .card-top {
                position: absolute;
                top: 14px;
                right: 14px;
                z-index: 3;
            }

            .currency-dropdown {

                .dropdown-toggle {
                    border: 0;
                    outline: 0;
                    box-shadow: none;
                    border-radius: 8px;
                    padding: 6px 12px;
                    background: rgba(0, 0, 0, 0.18);
                    color: #fff;
                    font-size: 13px;
                    font-weight: 700;
                    line-height: 1;
                    transition: background .2s ease;

                    &:hover,
                    &:focus,
                    &:active {
                        background: rgba(0, 0, 0, 0.28);
                        color: #fff;
                        box-shadow: none;
                    }

                    &::after {
                        margin-left: 6px;
                    }
                }

                .dropdown-menu {
                    border: 0;
                    border-radius: 12px;
                    overflow: hidden;
                    padding: 8px 0;
                    min-width: 140px;
                    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
                    z-index: 9999;

                    .dropdown-item {
                        font-size: 14px;
                        padding: 10px 16px;

                        &.active,
                        &:active {
                            background: #f3f6ff;
                            color: #0d6efd;
                        }
                    }
                }
            }
        }
    }

}

#view-ticket {

    .ticket-header-nav {
        background-color: #fff;
        border-top: 1px solid #ededed;
        border-bottom: 1px solid #e5e7eb;
        margin-top: 22px;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 14px 20px;

        @include desktop-vl {
            margin-top: 10px;
            padding: 10px 20px;
        }

        @include portrait {
            flex-direction: column;
            align-items: stretch;
            padding: 0;
            margin-top: 10px;
        }
    }

    .ticket-header-left {
        display: flex;
        align-items: center;

        @include portrait {
            padding: 10px 15px 0;
            justify-content: flex-start;
        }
    }

    .ticket-header-center {
        display: flex;
        align-items: center;
        gap: 24px;
        margin: 0;
        padding: 0;

        @include portrait {
            flex-direction: column;
            align-items: stretch;
            gap: 0;
            width: 100%;
        }
    }

    .ticket-header-center .nav-item {
        display: flex;
        align-items: center;
        gap: 6px;
        position: relative;

        @include portrait {
            flex-direction: row;
            align-items: center;
            padding: 10px 15px;
            border-bottom: 1px solid #eee;
            gap: 8px;
            width: 100%;

            &::after {
                display: none;
            }
        }
    }

    .ticket-header-center .nav-item:not(:last-child)::after {
        content: "";
        position: absolute;
        right: -12px;
        top: 50%;
        transform: translateY(-50%);
        width: 1px;
        height: 24px;
        background-color: #e5e7eb;
    }

    .ticket-status {
        label {
            margin: 0;
            font-weight: 500;
            color: #6b7280;

            @include portrait {
                display: none;
            }
        }

        @include portrait {
            .select2-container {
                flex: 1;
                width: auto !important;
            }

            .status-btn {
                flex: 1;
            }
        }
    }

    @include portrait {
        .change-ticket-type,
        .change-ticket-assignee,
        .change-ticket-package {
            .nav-link {
                flex: 1;
                padding: 0;

                &.dropdown-toggle::after {
                    margin-left: auto;
                }
            }
        }
    }

    .ticket-header-nav .nav-link {
        padding: 0;
        font-weight: 500;
        color: #374151;

        &:hover {
            color: #111827;
        }
    }

    .ticket-header-right {
        display: flex;
        align-items: center;

        @include portrait {
            padding: 8px 15px;
            justify-content: flex-start;
        }
    }

    .btn-ticket-actions {
        background: transparent;
        border: none;
        color: #374151;

        &:hover {
            color: #111827;
        }
    }

    .change-ticket-package {
        display: flex;
        align-items: center;

        #view-package-link {
            padding: 0;
            margin-left: 8px;
            color: #787597;
            display: flex;
            align-items: center;

            &:hover {
                color: $link-color-orange;
            }

            @include portrait {
                margin-left: 6px;
                flex: 0 0 auto;
            }
        }
    }

    .cm-holder {
        border-radius: 0;
    }

    #attachedfileblock {
        padding-left: 34px;
    }

    #ticket-top-bar-alsoviewing {
        color: #666;
        font-size: 10px;
        position: relative;
        top: 9px;
        left: 10px;
        width: 100%;
        background-color: rgb(255, 245, 205);
        margin-left: -10px;
        padding-left: 10px;
        border-top: 1px solid #FFE976;
    }

    #ticket-action-attach-file {
        font-size: 12px;
    }

    #ticket_subject_name {
        font-size: 20px;
        font-weight: 600;
        width: 75%;
        background-color: transparent;
        border: 0;
        -moz-box-shadow: none;
        -webkit-box-shadow: none;
        box-shadow: none;
        -webkit-transition: none;
        -o-transition: none;
        -ms-transition: none;
        -moz-transition: none;
        border: 1px solid transparent;
        padding: 7px;
        padding-right: 0;

        @include portrait {
            width: 100%;
        }

        &:focus {
            border: 1px solid #cfcfcf;
        }
    }

    .resp-tabs-list.inline {
        padding-left: 35px;
    }

    .cm-btns.dropdown-toggle {
        padding: 0px 10px;
    }

    .reply-wrap.btn-group {
        position: relative;
        overflow: visible;
    }

    .reply-wrap,
    .reply-wrap *,
    .btn-group-submit {
        overflow: visible !important;
    }

    .reply-wrap .dropdown-menu {
        z-index: 1056 !important;
    }

    .query-actions{
        display: inline-block;
        a{
            display: inline-block;
            width: 30px;height: 26px;line-height: 26px;color: #929aac;text-decoration: none;font-size:16px;
            border:1px solid #FFF;text-align:center;border-radius:2px;
            &:hover{color:var(--primary-hover);border:1px solid #ccced4;}
        }
    }

    .ticket-dscrp {
        display: block;
        padding: 20px 30px;

        @include portrait {
            padding: 20px 15px;
        }

        p {
            margin-bottom: 7px;
        }

        ul,
        ol {
            padding-left: 40px; // required for markers to show
        }

        ul {
            list-style-type: disc;
        }

        ol {
            list-style-type: decimal;
        }

        ul li,
        ol li {
            list-style: inherit; // <-- this is the key
        }
    }

    .reply-msg {
        display: none;
        padding: 15px 30px;
        position: relative;

        &.push-it {
            display: block;
        }

        @include portrait {
            padding: 20px 15px;
        }

        .form-elem {
            padding-bottom: 0;
        }

        textarea {
            &.form-control {
                height: 120px;
            }
        }

        .buttom-wrap {
            display: flex;
            justify-content: flex-end;
            margin-top: 8px;

            .cm-btns {
                line-height: 34px;
                margin-left: 6px;
            }
        }

        .editor-attachments {
            .ajax-file-upload {
                i { top: 0; }
            }
        }
    }
}

.snapin_view_licenses {
    #filterByReseller {
        + .select2-container {
            .select2-selection--single {
                height: 30px;
                border-radius: 20px;
                border: 1px solid #ccc;

                .select2-selection__rendered {
                    line-height: 30px;
                    padding-left: 10px;
                    padding-right: 18px;
                }

                .select2-selection__arrow {
                    height: 30px;
                }
            }
        }
    }
}