/* Progress bar */
/* Chrome, Safari, Edge, Opera */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

#result.htmx-added {
    opacity: 0;
}

#result {
    opacity: 1;
    transition: opacity 1s ease-out;
}

.hidden-spinner > svg {
    display: none;
}

.progress {
    height: 4px;
    width: 100%;
    border-radius: 2px;
    background-clip: padding-box;
    overflow: hidden;
    position: relative;
}

.progress {
    opacity: 0;
}

.htmx-request .progress {
    opacity: 1;
}

.htmx-request.progress {
    opacity: 1;
}

.progress .indeterminate {
    background-color: rgba(87, 87, 86, 0.232);
}

.htmx-request.progress .indeterminate:before {
    content: '';
    border-radius: 10px;
    position: absolute;
    background-color: inherit;
    top: 0;
    left: 0;
    bottom: 0;
    will-change: left, right;
    -webkit-animation: indeterminate 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
    animation: indeterminate 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
}

.htmx-request.progress .indeterminate:after {
    content: '';
    border-radius: 10px;
    position: absolute;
    background-color: inherit;
    top: 0;
    left: 0;
    bottom: 0;
    will-change: left, right;
    -webkit-animation: indeterminate-short 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) infinite;
    animation: indeterminate-short 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) infinite;
    -webkit-animation-delay: 1.15s;
    animation-delay: 1.15s;
}

[data-loading] {
    display: none;
}

@keyframes indeterminate {
    0% {
        left: -35%;
        right: 100%;
    }

    60% {
        left: 100%;
        right: -90%;
    }

    100% {
        left: 100%;
        right: -90%;
    }
}

@keyframes indeterminate-short {
    0% {
        left: -200%;
        right: 100%;
    }

    60% {
        left: 107%;
        right: -8%;
    }

    100% {
        left: 107%;
        right: -8%;
    }
}

/* tables */


/* select {
    background-image: none;
} */

dialog::backdrop {
    background-color: rgba(0, 0, 0, 0.5);
}

#modal, #discardChanges-modal, #modal-persistent, #modal-history, .modal {
    /* Underlay covers entire screen. */
    position: fixed;
    top: 0px;
    bottom: 0px;
    left: 0px;
    right: 0px;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    will-change: transform;
}

#modal>.modal-underlay,
#discardChanges-modal>.modal-underlay,
#modal-persistent>.modal-underlay,
#modal-history>.modal-underlay,
.modal>.modal-underlay {
    /* underlay takes up the entire viewport. This is only
	required if you want to click to dismiss the popup */
    position: absolute;
    z-index: -1;
    top: 0px;
    bottom: 0px;
    left: 0px;
    right: 0px;
    will-change: transform;
}

.modal-content {
    /* Sizing for visible dialog */
    width: 100%;
    max-width: 600px;
}

.modal-xl.modal-content {
    max-width: 1140px!important;
}

/* on screens above md */
@media screen and (min-width: 768px) and (max-width: 1200px) {
    .modal-xl.modal-content {
        max-width: 93.5%!important;
    }
}

[id*="toast"], .toast {
    animation-name: pullUpToast;
    animation-duration: 350ms;
    animation-timing-function: ease;
    will-change: transform;
}

[id*="toast"].closing,
.toast.closing {
    animation-name: pullDownToast;
    animation-duration: 350ms;
    animation-timing-function: ease;
    will-change: transform;
}


@media screen and (min-width: 641px) {
    #modal, #discardChanges-modal, #modal-persistent, .modal {
        /* Animate when opening */
        animation: fadeIn 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
    }

    .modal-content {

        /* Animate when opening */
        animation-name: zoomIn;
        animation-duration: 250ms;
        animation-timing-function: ease;
    }

    #modal.closing,
    #discardChanges-modal.closing,
    #modal-persistent.closing,
    #modal-history.closing,
    .modal.closing {
        /* Animate when closing */
        animation-name: fadeOut;
        animation-duration: 250ms;
        animation-timing-function: ease;
    }

    #modal.closing>.modal-content,
    #discardChanges-modal.closing>.modal-content,
    #modal-persistent.closing>.modal-content,
    #modal-history.closing>.modal-content,
    .modal.closing>.modal-content {
        /* Animate when closing */
        animation-name: zoomOut;
        animation-duration: 250ms;
        animation-timing-function: ease;
    }

}


/* only on mobile */
@media (max-width: 640px) {
    #modal, #discardChanges-modal, #modal-persistent, #modal-history, .modal {
        animation: pullUpTransparency 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
        -webkit-animation: fadeIn 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
    }

    .modal-height {
        animation-name: pullUp;
        animation-duration: 650ms;
        animation-timing-function: ease;
        will-change: transform;
    }


    #modal.closing .modal-content,
    #discardChanges-modal.closing .modal-content,
    #modal-persistent.closing .modal-content,
    #modal-history.closing .modal-content,
    .modal.closing .modal-content {
        animation-name: pullDown;
        animation-duration: 550ms;
        animation-timing-function: ease;
    }

    #modal.closing,
    #discardChanges-modal.closing,
    #modal-persistent.closing,
    #modal-history.closing,
    .modal.closing {
        animation: fadeOut 0.8s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
        -webkit-animation: fadeOut 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
    }

}

/* create animation that goes from 0.5 transparency background to transparent */

@keyframes pullUpToast {
    0% {
        transform: translateY(100%);
        opacity: 0;
    }

    100% {
        transform: translateY(0%);
        opacity: 1;
    }
}


@keyframes pullDownToast {

    0% {
        transform: translateY(0px);
        opacity: 1;
    }


    100% {
        transform: translateY(84px);
        opacity: 0;
    }
}


@keyframes pullUpTransparency {
    0% {
        background-color: rgba(0, 0, 0, 0);
    }

    100% {
        background-color: rgba(0, 0, 0, 0.5);
    }
}

@keyframes pullDownTransparency {
    0% {
        background-color: rgba(0, 0, 0, 0.5);
    }

    100% {
        background-color: rgba(0, 0, 0, 0);
    }
}

@keyframes pullUp {
    0% {
        transform: translateY(100%);
    }

    100% {
        transform: translateY(0%);
    }
}

@keyframes pullDown {
    0% {
        transform: translateY(0%);
    }

    100% {
        transform: translateY(100%);
    }
}


@keyframes fadeIn {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes fadeOut {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
        display: none;
    }
}

@keyframes zoomIn {
    0% {
        transform: scale(0.9);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes zoomOut {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(0.9);
    }
}

form.htmx-request {
    opacity: .5;
    transition: opacity 300ms linear;
}

/* add transition for the tables */
.table-container table {
    transition: opacity 300ms linear;
}

/* filedrop */
.file-drop-area {
    position: relative;
    padding: 1rem 1rem;
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
    border: 2px dashed #dae1e7;
    background-color: #fff;
    text-align: center;
    cursor: pointer;
}

.file-drop-area .file-drop-icon {
    margin-bottom: 0.75rem;
    color: #aeb4be;
    font-size: 1.625rem;
}

.file-drop-area .file-drop-message {
    display: block;
    word-wrap: break-word;
    font-size: .875rem;
    margin-bottom: 1.25rem;
}

.file-drop-area .file-drop-input {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: transparent;
    opacity: 0;
    outline: none;
    cursor: pointer;
    z-index: 2;
}

.file-drop-area .btn {
    position: relative;
    z-index: 3;
}

.file-drop-area .file-drop-preview {
    max-width: 16rem;
    margin-right: auto;
    margin-bottom: 0.75rem;
    margin-left: auto;
}

img,
figure {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

/* filedrop */
.main-wrapper {
    height: calc(100% - 3.5rem);
}

.table-image {
    min-width: 40px;
    min-height: 40px;
    width: 40px;
    height: 40px;
    object-fit: cover;
}

.highcharts-title {
    font-weight: 400!important;
    fill: #000!important;
    font-size: 1rem!important;
}

/* daterangepicker */
.daterangepicker .ranges li.active {
    background-color: #d5d3d1!important;
    color: #000!important;
}

.daterangepicker td.active, .daterangepicker td.active:hover {
    background-color: #d5d3d1!important;
    color: #000!important;
}

.daterangepicker td.in-range {
    background-color: #d5d3d14a!important;
}

/* daterangepicker */

.phase-ingredients-border {
    height: calc(70% - 22px);
    border: 3px dashed var(--muted-border-color, #6b7280);
    display: inline-flex;
    border-right: none;
    position: absolute;
    left: -13px;
    bottom: 30%;
    /* z-index: -1; */
    width: 30px;
    border-top-left-radius: 8px;
    border-bottom-left-radius: 8px;
    border-start-end-radius: 1px;
    border-end-end-radius: 1px;
}

/* .full-fleed {
    box-shadow: 0 0 0 100vmax var(--full-bleed-bg-color, #efe8e0);
    clip-path: inset(0 -100vmax);
    background-color: var(--full-bleed-bg-color, #efe8e0);
}
 */


 .ck-toolbar {
    border-top-left-radius: 10px!important;
    border-top-right-radius: 10px!important;
 }

 .ck-content {
    border-bottom-left-radius: 10px!important;
    border-bottom-right-radius: 10px!important;
 }

 .ck-powered-by {
    display: none;
 }

 /* .django-ckeditor-widget{
    width: 100%;
  }

  .cke_chrome{
    border-radius: 10px;
    border: 1px solid #695656;
    border-width: thin;
}

.cke_top{
    border-color: #d0d5db!important;
    border-radius: 10px 10px 0px 0px;
    background-color: white!important;
}

.cke_inner.cke_reset {
    border-radius: 10px;
}

.cke_contents.cke_reset {
    border-radius: 10px;
}

.cke_chrome {
    border-color: #d0d5db!important;
} */

/* remove the transparency cause by the cke */
/* this was causing modal animation problems */
/* #modal {
    opacity: 1!important;
} */

.default-li-style {
    list-style: initial!important;
}

td ul {
    list-style: initial;
    display: inline-block;
}

td ol {
    list-style: decimal;
    display: inline-block;
}

/* loading spinner start */
.lds-default {
    display: inline-block;
    position: relative;
    width: 78px;
    height: 78px;
  }
  .lds-default div {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    animation: lds-default 1.5s linear infinite,
    hue 1.5s linear infinite;
  }

  /* make the odd black and the even white */
  .lds-default div {
    background: rgb(149, 224, 149);
  }

  .lds-default div:nth-child(1) {
    animation-delay: 0s;
    top: 37px;
    left: 66px;
  }
  .lds-default div:nth-child(2) {
    animation-delay: -0.1s;
    top: 22px;
    left: 62px;
  }
  .lds-default div:nth-child(3) {
    animation-delay: -0.2s;
    top: 11px;
    left: 52px;
  }
  .lds-default div:nth-child(4) {
    animation-delay: -0.3s;
    top: 7px;
    left: 37px;
  }
  .lds-default div:nth-child(5) {
    animation-delay: -0.4s;
    top: 11px;
    left: 22px;
  }
  .lds-default div:nth-child(6) {
    animation-delay: -0.5s;
    top: 22px;
    left: 11px;
  }
  .lds-default div:nth-child(7) {
    animation-delay: -0.6s;
    top: 37px;
    left: 7px;
  }
  .lds-default div:nth-child(8) {
    animation-delay: -0.7s;
    top: 52px;
    left: 11px;
  }
  .lds-default div:nth-child(9) {
    animation-delay: -0.8s;
    top: 62px;
    left: 22px;
  }
  .lds-default div:nth-child(10) {
    animation-delay: -0.9s;
    top: 66px;
    left: 37px;
  }
  .lds-default div:nth-child(11) {
    animation-delay: -1s;
    top: 62px;
    left: 52px;
  }
  .lds-default div:nth-child(12) {
    animation-delay: -1.1s;
    top: 52px;
    left: 62px;
  }
  @keyframes lds-default {
    0%, 20%, 80%, 100% {
      transform: scale(1);
      border-radius: 0%;
    }
    50% {
      transform: scale(1.5);
      border-radius: 50%;
    }
  }

  @keyframes hue {
    from {
      -webkit-filter: hue-rotate(0deg);
    }

    to {
      -webkit-filter: hue-rotate(360deg);
    }
}
/* loading spinner end */

.select2-container--default .select2-selection--single .select2-selection__arrow {
    right: 16px!important;
    height: 25px!important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: transparent!important;
    border-style: solid;
    border-width: 0px!important;
    height: 21px!important;
    left: 50%;
    width: 5px;
    margin-left: -4px;
    margin-top: -2px;
    position: absolute;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3E%3C/svg%3E");
    top: 50%;
    width: 21px!important;
    background-repeat: no-repeat;
}

/* hide broken phase ingredient select2 widget */
.relative > .select2:nth-of-type(2) {
    display: none;
}


input#session-date {
    display: inline-block;
    position: relative;
}

input[type="date"]::-webkit-calendar-picker-indicator {
    background: transparent;
    bottom: 0;
    color: transparent;
    cursor: pointer;
    height: auto;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
    width: auto;
}

input.select2-search__field {
    width: 100%!important;
    /* margin-left: 4px!important; */
}

.Stars {
    --percent: calc(var(--rating) / 5* 100%);
    font-family: var(--star-font-familiy);
    font-size: 20px;
    line-height: 1;
}

.Stars::before {
    content: '\2605\2605\2605\2605\2605';
    letter-spacing: 1px;
    background: linear-gradient(90deg, var(--star-background, #f7cb2d) var(--percent), var(--star-color, #dcdcdc) var(--percent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

@keyframes borderAnimation {
    0% {
        border-color: rgb(209, 213, 219);
        outline: 1px solid rgb(209, 213, 219);
    }

    50% {
        border-color: rgb(32, 164, 52);
        outline: 1px solid rgb(32, 164, 52);
    }

    100% {
        border-color: rgb(209, 213, 219);
        outline: 1px solid rgb(209, 213, 219);
    }

}


.updating-field {
    animation-name: borderAnimation;
    animation-duration: 1.5s;
    animation-timing-function: linear;
    animation-iteration-count: 3;
}


.skeleton {
    will-change: background-position;
    background-image: linear-gradient(105deg, #0000 0% 15%, #ffffff 40%, #0000 70% 100%);
    background-position-x: -50%;
    background-repeat: no-repeat;
    background-size: 200%;
    animation: 1.8s ease-in-out infinite skeleton;
}

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


.phase-ingredient-row .select2-container--default .select2-selection--single {
    border-top-right-radius: 0px!important;
    border-bottom-right-radius: 0px!important;
}

.htmx-indicator {
    display: none;
    opacity:0;
    transition: opacity 500ms ease-in;
}

.htmx-request .htmx-indicator {
    display: block;
    opacity: 1;
}

.htmx-request.button-text {
    opacity: 0;
}

.htmx-request .button-text {
    opacity: 0;
}

.htmx-request.htmx-indicator {
    display: block;
    opacity: 1;
}

.risk-risk {}

.low-risk {}

.medium-risk {}

.high-risk {}

@keyframes lively-gradient {
  0% {
    background-position: 0% 50%;
  }
  25% {
    background-position: 50% 100%;
  }
  50% {
    background-position: 100% 50%;
  }
  75% {
    background-position: 50% 0%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.ai-button-animated {
	background: linear-gradient(-45deg, #3f0896, #e74785, #3f0896, #e74785);
	background-size: 400% 400%;
	animation: gradient 8s ease infinite;
}

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

.gradient-analytics-card {
	background: linear-gradient(-45deg, #ee76521d, #e73c7e1e, #30178a23, #ab23d513);
	background-size: 400% 400%;
	animation: gradient 5s ease infinite;
}

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



@property --angle {
    syntax: "<angle>";
    inherits: false;
    initial-value: 0deg;
}

@keyframes _glow_1daja_1 {
    0% {
        --angle: 0deg
    }

    to {
        --angle: 360deg
    }
}

.ai-textarea:has(textarea:focus):before {
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    border-radius: 0px;
    filter: blur(.375rem);
    background: conic-gradient(from var(--angle) at 50% 50%, #a0cbff 0deg, #d1bdff 90deg, #f4c2ff 126deg, #ffb9a2 180deg, #f4c2ff 234deg, #d1bdff 270deg, #a0cbff 306deg);
    animation: _glow_1daja_1 5s linear forwards infinite;
}

.ai-textarea:has(textarea:focus)::before {
    content: "";
    position: absolute;
    pointer-events: none;
    transition: opacity 5s cubic-bezier(.25, .1, .25, 1);
}

.ai-textarea textarea {
    resize: none;
}

.ai-textarea .input-field:focus {
    box-shadow: none;
    border-color: transparent;
}
