/* Common */
html,
body {
    padding: 0;
    margin: 0;
    font-family: Arial, "PingFangSC-Regular", "STHeiti", "WenQuanYi Zen Hei", "Microsoft JhengHei", "微軟正黑體", "儷黑 Pro", "LiHei Pro", "DFKai-SB", sans-serif;
}

.template {
    display: none !important;
}

.hide {
    display: none !important;
}

.no-select {
    user-select: none;
}

@media only screen and (max-width: 400px) {
    .xs-hide {
        display: none;
    }
}

.list .item:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.03);
}

.list .item:hover,
.list .item:focus-within {
    background-color: #e0f3ff;
}

.filter-form .btn {
    overflow: inherit;
}

/* Toaster */
.toaster {
    position: fixed;
    bottom: 20px;
    right: 100px;
    z-index: 10006;
    padding-bottom: 20px;
}

.toaster-item {
    display: block;
    opacity: 1;
    background: #2c2c2c;
    color: white !important;
    width: 300px;
    padding: 15px 20px;
    border-radius: 10px;
    opacity: 0;
    transition: opacity 0.3s;
    margin-top: 10px;
    position: relative;
    padding-left: 36px;
    padding-top: 35px;
    border: 1px solid #2c2c2c;
    word-break: break-all;
}

.toaster-item.show {
    opacity: 0.8;
}

.toaster-item.show:hover {
    opacity: 1;
}

.toaster-item::before {
    display: block;
    height: calc(100% - 30px);
    position: absolute;
    left: 23px;
    padding-left: 10px;
    top: 15px;
}

.toaster-item.error::before {
    content: '錯誤';
    border-left: 3px solid #fa5c2d;
    color: #fa5c2d;
}

.toaster-item.warn::before {
    content: '警告';
    border-left: 3px solid #fac32d;
    color: #fac32d;
}

.toaster-item.info::before {
    content: '訊息';
    border-left: 3px solid #2daffa;
    color: #2daffa;
}

a.toaster-item::after {
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    content: '\f0c1';
    display: block;
    position: absolute;
    top: 0;
    right: 0;
    width: 40px;
    height: 40px;
    text-align: center;
    line-height: 40px;
}

/* overwrite */
.btn {
    white-space: nowrap !important;
    border: none;
    overflow: hidden;
}

.btn:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25) !important;
}

.pagination-container {
    overflow-x: scroll;
    max-width: 340px;
    border-radius: 0 !important;
}

@media only screen and (max-width: 600px) {
    .pagination-container {
        max-width: 165px;
    }
}

.pagination-container .page-link {
    border-radius: 0 !important;
}

.root .pagination {
    margin-bottom: 0;
}

.table-bordered .data-row {
    margin-left: -15px !important;
    margin-right: -15px !important;
}

.data-row {
    margin-left: -20px !important;
    margin-right: -20px !important;
}

.data-row.mx-0 {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.data-row:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.03);
}

.data-row:hover {
    background-color: #e0f3ff !important;

}

.custom-control-label.original-pos {
    width: 20px !important;
    display: inline;
}

/* customize */
.pointer {
    cursor: pointer;
}

.block {
    display: block;
}

.loading {
    text-align: center;
    align-items: center;
    justify-content: center;
}

.loading .spinner {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 80px;
    justify-content: center;
}

.loading .spinner div {
    position: absolute;
    top: 33px;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #CCC;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.loading .spinner div:nth-child(1) {
    left: 8px;
    animation: loading1 0.6s infinite;
}

.loading .spinner div:nth-child(2) {
    left: 8px;
    animation: loading2 0.6s infinite;
}

.loading .spinner div:nth-child(3) {
    left: 32px;
    animation: loading2 0.6s infinite;
}

.loading .spinner div:nth-child(4) {
    left: 56px;
    animation: loading3 0.6s infinite;
}

@keyframes loading1 {
    0% {
        transform: scale(0);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes loading3 {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(0);
    }
}

@keyframes loading2 {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(24px, 0);
    }
}


.app-page-title .status {
    color: #ccc;
}

.imvisible {
    visibility: hidden;
}

.abs {
    position: absolute;
}

img[src=""] {
    display: none !important;
}

.invalid-messange {
    padding: 0.8rem;
    color: #fac32d;
}

label.btn-success.btn-upload-file {
    margin: 0;
    vertical-align: middle;
    display: inline-block;
    align-items: center;
    padding: .5rem 1rem;
    line-height: 1.5;
    border-radius: .3rem;
}

label.btn-success.btn-upload-file.disabled {
    background-color: #3ac47d !important;
    border-color: #3ac47d !important;
    opacity: 0.65;
    pointer-events: none;
}


a.form-control {
    overflow: hidden;
    white-space: nowrap;
}

.upload-thumb {
    position: relative;
    height: 100px;
    border: 1px solid rgb(206, 212, 218);
    width: 100%;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 0;
}

.upload-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.upload-thumb img.contain {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
}

.upload-thumb:hover::after {
    content: '\f382';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    font-size: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    background: rgba(0, 0, 0, 0.3);
    color: white;
    text-align: center;
    line-height: 100%;
}

/* overwrite template theme */
.root .app-header__logo .logo-src {
    background-image: url(/assets/images/logo.png);
    background-size: contain;
    background-repeat: no-repeat;
    height: 50px;
    margin-left: 12px;
}

.badge {
    text-transform: inherit;
}

.root .app-theme-white .app-footer .app-footer__inner,
.root .app-theme-white .app-header {
    background-color: #4a5f55;
}

.root .hamburger-inner,
.root .hamburger-inner::before,
.root .hamburger-inner::after {
    background-color: white;
}

.root .hamburger.is-active .hamburger-inner,
.root .hamburger.is-active .hamburger-inner::before,
.root .hamburger.is-active .hamburger-inner::after {
    background-color: white;
}

.root .app-header .btn {
    color: white;
}

.root .bg-plum-plate {
    background-color: #264b5b !important;
    background-image: none !important;
}

.root .form-control.disabled {
    background-color: #e9ecef;
}

.root .custom-control-label.original-pos::before,
.root .custom-control-label.original-pos::after {
    left: 0 !important;
    background-color: transparent !important;
}

.root .custom-control-input:checked~.custom-control-label::before {
    content: "\f00c";
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    color: #264b5b;
    border-color: #264b5b;
    font-size: 23px;
    line-height: 0.8rem;
    text-indent: -3px;
}

/* overwrite third-party tagify */

.root .tagify {
    --tag-bg: #264b5b;
    --tag-hover: #264b5b;
    --tag-text-color: white;
    padding: 20px;
    border-radius: .25rem;
    width: 100%;
    font-size: 1rem;
    font-weight: 400;
}

/* overwrite third-party autoComplete */
.autocomplete-suggestions {
    position: absolute;
    z-index: 40;
    border-left: 1px solid #ced4da;
    border-right: 1px solid #ced4da;
    border-bottom: 1px solid #ced4da;
    background: white;
    max-height: 400px;
    overflow-y: scroll;
}

.autocomplete-suggestions .autocomplete-suggestion {
    padding: 9px 12px;
    background-color: #fff;
}

.autocomplete-suggestions .autocomplete-suggestion:hover,
.autocomplete-suggestions .autocomplete-suggestion.selected {
    background-color: #e0f3ff !important;
}

.autocomplete-suggestions .autocomplete-suggestion:nth-child(odd) {
    background-color: rgba(0, 0, 0, 0.03);
}

/* new bootstrap */
/* Small devices (landscape phones, 576px and up) */
@media (min-width: 320px) {
    .w-xs-100 {
        width: 100% !important;
    }

    .w-xs-75 {
        width: 75% !important;
    }

    .w-xs-50 {
        width: 50% !important;
    }

    .w-xs-25 {
        width: 25% !important;
    }
}

@media (min-width: 576px) {
    .w-sm-100 {
        width: 100% !important;
    }

    .w-sm-75 {
        width: 75% !important;
    }

    .w-sm-50 {
        width: 50% !important;
    }

    .w-sm-25 {
        width: 25% !important;
    }
}

/* Medium devices (tablets, 768px and up) The navbar toggle appears at this breakpoint */
@media (min-width: 768px) {
    .w-md-100 {
        width: 100% !important;
    }

    .w-md-75 {
        width: 75% !important;
    }

    .w-md-50 {
        width: 50% !important;
    }

    .w-md-25 {
        width: 25% !important;
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
    .w-lg-100 {
        width: 100% !important;
    }

    .w-lg-75 {
        width: 75% !important;
    }

    .w-lg-50 {
        width: 50% !important;
    }

    .w-lg-25 {
        width: 25% !important;
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .w-xl-100 {
        width: 100% !important;
    }

    .w-xl-75 {
        width: 75% !important;
    }

    .w-xl-50 {
        width: 50% !important;
    }

    .w-xl-25 {
        width: 25% !important;
    }
}

img[src=""],
img:not([src]) {
    display: none !important;
}

.pill {
    border-radius: 60px;
    overflow: hidden;
}

.pill>* {
    padding: 0.5em;
}

.sorting {
    cursor: pointer;
}

.fa-long-arrow-alt-up {
    color: #ccc;
}

.fa-long-arrow-alt-up.active,
.fa-long-arrow-alt-down.active {
    color: black;
}

.fa-long-arrow-alt-down {
    color: #ccc;
    cursor: pointer;
}

input[type="radio"] {
    width: 20px;
}

.form-control.is-warning {
    border-color: #fac32d;
    padding-right: 2.25rem;
    background-repeat: no-repeat;
    background-position: center right calc(2.25rem / 4);
    background-size: calc(2.25rem / 2) calc(2.25rem / 2);
    box-shadow: 0 0 0 0.2rem rgb(243 181 38 / 25%);
}

.failed {
    background: #d9255040 !important;
}

.success {
    background: #3ac47d40 !important;
}