:root {
  --background: 0 0% 100%;
  --foreground: 222.2 84% 4.9%;

  --card: 240 4.8% 95.9%;
  --card-foreground: 240 5.9% 10%;

  --popover: 0 0% 100%;
  --popover-foreground: 222.2 84% 4.9%;

  --primary: 222.2 47.4% 11.2%;
  --primary-foreground: 210 40% 98%;

  --secondary: 210 40% 96.1%;
  --secondary-foreground: 222.2 47.4% 11.2%;

  --muted: 210 40% 96.1%;
  --muted-foreground: 215.4 16.3% 46.9%;

  --accent: 210 40% 96.1%;
  --accent-foreground: 222.2 47.4% 11.2%;

  --destructive: 0 84.2% 60.2%;
  --destructive-foreground: 210 40% 98%;

  --border: 214.3 31.8% 91.4%;
  --input: 240 19% 83%;
  --ring: 222.2 84% 4.9%;

  --error: 0 84.2% 60.2%;
  --error-foreground: 210 40% 98%;

  --success: 120 67% 55%;
  --success-foreground: 240 5.9% 10%;

  --warning: 45 96.5% 53.5%;
  --warning-foreground: 210 40% 98%;

  --info: 212.7 100% 56%;
  --info-foreground: 210 40% 98%;

  --radius: 0.5rem;
}

.dark {
  --background: 230 15% 8%;
  --foreground: 240 19% 83%;
  --overlay: 220 12% 15%;

  --muted: 240, 19%, 83%, 0.5;
  --muted-foreground: 240, 19%, 83%, 0.3;

  --popover: 231 15% 18%;
  --popover-foreground: 60 30% 96%;

  --text: 240 19% 83%;
  --text-secondary: 240, 19%, 83%, 0.65;
  --border: 240, 19%, 83%, 0.12;
  --input: 240, 19%, 83%, 0.2;

  --card: 240 3.7% 15.9%;
  --card-foreground: 0 0% 98%;

  --primary: 212 100% 56%;
  --primary-foreground: 212 100% 98%;

  --secondary: 214 13% 22%;
  --secondary-foreground: 60 30% 96%;

  --accent: 225 27% 51%;
  --accent-foreground: 60 30% 96%;

  --destructive: 0 100% 67%;
  --destructive-foreground: 60 30% 96%;

  --error: 0 84% 60%;
  --error-foreground: 0 84% 98%;

  --success: 142 71% 45%;
  --success-foreground: 142 71% 98%;

  --warning: 25 95% 53%;
  --warning-foreground: 25 95% 98%;

  --info: 212.7 100% 56%;
  --info-foreground: 210 40% 98%;

  --ring: 240 19% 83% 0.4;
}
.sidebar-overlay {
  display: none;
}

.sidebar li a.active {
  background-color: var(--gray-a3);
  color: var(--gray-12);
}

.sidebar li ul li a.active {
  background-color: transparent;
  color: var(--gray-12);
}

.sidebar-mobile li a.active {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}

.sidebar-mobile li ul li a.active {
  background-color: transparent;
  color: var(--gray-12);
}

.content-builder td {
  position: relative;
  padding: 1rem;
  text-align: left;
  font-size: 0.875rem;
}
.content-builder > table > tbody > tr > td > .line-corner {
  display: none;
}
.dynamic-zone > td:first-of-type::before {
  content: "";
  width: 0.25rem;
  height: calc(100% - 45px);
  position: absolute;
  top: -7px;
  left: 30px;
  border-radius: 4px;
  background-color: #cbd5e1;
}

@media (prefers-color-scheme: dark) {
  .dynamic-zone > td:first-of-type::before {
    background-color: #64748b;
  }
}

.dynamic-zone > td {
  padding: 0;
}
.line-corner {
  position: absolute;
  left: -12.5px;
  top: 0px;
  color: #cbd5e1;
}

@media (prefers-color-scheme: dark) {
  .line-corner {
    color: #64748b;
  }
}

.line-corner::before {
  content: "";
  width: 0.25rem;
  height: 0.5rem;
  display: block;
}

.pam-switch {
  height: 38px;
  width: 100%;
  display: flex;
  align-items: center;
  border-radius: 4px;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--background));
  padding: 2px;
}

.pam-switch-label {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  width: 50%;
  height: 100%;
  border-radius: 4px;
  border: 1px solid transparent;
  background-color: transparent;
  color: hsl(var(--foreground));
  cursor: pointer;
}

.pam-switch .pam-switch-label-false {
  background-color: hsl(var(--primary));
  color: hsl(var(--destructive));
  border-color: hsl(var(--border));
}

.pam-switch:has(input:checked) .pam-switch-label-false {
  background-color: transparent;
  color: hsl(var(--foreground));
  border-color: transparent;
}

.pam-switch:has(input:checked) .pam-switch-label-true {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border-color: hsl(var(--border));
}

.pam-switch:has(input:focus) {
  border: 1px solid hsl(var(--primary));
}

.pam-switch:has(input:disabled) .pam-switch-label {
  opacity: 0.5;
  cursor: not-allowed;
}

.pam-card.selected {
  background-color: hsl(var(--secondary));
}

.pam-card.selected .check-icon {
  opacity: 1;
}

.uppy-Dashboard-inner {
  border: 1px solid hsl(var(--border));
}

.pam-loading {
  pointer-events: none;
  position: relative;
}

.pam-loading span {
  opacity: 0;
}

.pam-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  margin-top: -7px;
  margin-left: -15px;
  width: 30px;
  aspect-ratio: 2;
  --_g: no-repeat radial-gradient(circle closest-side, #fff 90%, #fff0);
  background: var(--_g) 0% 50%, var(--_g) 50% 50%, var(--_g) 100% 50%;
  background-size: calc(100% / 3) 50%;
  animation: l3 1s infinite linear;
}
@keyframes l3 {
  20% {
    background-position: 0% 0%, 50% 50%, 100% 50%;
  }
  40% {
    background-position: 0% 100%, 50% 0%, 100% 50%;
  }
  60% {
    background-position: 0% 50%, 50% 100%, 100% 0%;
  }
  80% {
    background-position: 0% 50%, 50% 50%, 100% 100%;
  }
}

.uppy-Dashboard-inner {
  height: 320px !important;
}

.img-selectable img {
  cursor: pointer;
}

.img-selectable:hover img {
  opacity: 0.8;
}

.img-selectable:hover .select-overlay {
  opacity: 1;
}

table.dataTable span.highlight {
  background-color: #ffff88;
  border-radius: 0.28571429rem;
}

table.dataTable span.column_highlight {
  background-color: #ffcc99;
  border-radius: 0.28571429rem;
}

.dt-layout-cell.dt-end {
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 4px !important;
}

.choices__inner {
  padding: 0 !important;
  min-height: 36px !important;
  border-radius: 0.375rem !important;
}

.is-focused .choices__inner {
  border-bottom-right-radius: 0 !important;
  border-bottom-left-radius: 0 !important;
}

.choices__list.choices__list--dropdown .is-selected {
  background-color: hsl(var(--primary)) !important;
  color: hsl(var(--primary-foreground)) !important;
}

.image-table:has(img:is([src=""])) {
  position: relative;
}

.image-table:has(img:is([src=""])):before {
  font-size: 8px;
  content: "No image";
  width: 100%;
  height: 100%;
  background-color: hsl(var(--card));
  color: hsl(var(--muted-foreground));
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  overflow: hidden;
}

[data-sort="asc"] .table-sort svg:first-child {
  color: hsl(var(--primary-foreground));
}
[data-sort="desc"] .table-sort svg:last-child {
  color: hsl(var(--primary-foreground));
}

[class*="pam-inline"] {
  display: inline-block;
  position: relative;
  max-width: 100%;
  vertical-align: middle;
  -webkit-backface-visibility: hidden;
}

.pam-dropdown {
  width: auto;
  min-width: 150px;
  padding: 10px 16px;
  background: hsl(var(--card));
  border: 1px solid hsl(var(--border));
  border-radius: 8px;
}

.pam-dropdown > :last-child {
  margin-bottom: 0;
}
.pam-dropdown :focus-visible {
  outline-color: #333 !important;
}
/* Size modifier
 ========================================================================== */
.pam-dropdown-large {
  padding: 40px;
}
/* Dropbar modifier
 ========================================================================== */
/*
 * 1. Reset dropdown width to prevent to early shifting
 * 2. Reset style
 * 3. Padding
 */
.pam-dropdown-dropbar {
  /* 1 */
  width: auto;
  /* 2 */
  background: transparent;
  /* 3 */
  padding: 15px 0 15px 0;
  --pam-position-viewport-offset: 15px;
}
/* Phone landscape and bigger */
@media (min-width: 640px) {
  .pam-dropdown-dropbar {
    --pam-position-viewport-offset: 30px;
  }
}
/* Tablet landscape and bigger */
@media (min-width: 960px) {
  .pam-dropdown-dropbar {
    --pam-position-viewport-offset: 40px;
  }
}
.pam-dropdown-dropbar-large {
  padding-top: 40px;
  padding-bottom: 40px;
}
/* Nav
 * Adopts `pam-nav`
 ========================================================================== */
/*
 * Items
 */
.pam-dropdown-nav > li > a {
  color: #999;
}
/* Hover + Active */
.pam-dropdown-nav > li > a:hover,
.pam-dropdown-nav > li.pam-active > a {
  color: #666;
}
/*
 * Subtitle
 */
.pam-dropdown-nav .pam-nav-subtitle {
  font-size: 0.875rem;
}
/*
 * Header
 */
.pam-dropdown-nav .pam-nav-header {
  color: #333;
}
/*
 * Divider
 */
.pam-dropdown-nav .pam-nav-divider {
  border-top: 1px solid #e5e5e5;
}
/*
 * Sublists
 */
.pam-dropdown-nav .pam-nav-sub a {
  color: #999;
}
.pam-dropdown-nav .pam-nav-sub a:hover,
.pam-dropdown-nav .pam-nav-sub li.pam-active > a {
  color: #666;
}

.pam-drop {
  /* 1 */
  display: none;
  /* 2 */
  position: absolute;
  z-index: 1020;
  --pam-position-offset: 20px;
  --pam-position-viewport-offset: 15px;
  /* 3 */
  box-sizing: border-box;
  width: 200px;
}
/* Show */
.pam-drop.pam-open {
  display: block;
}
/* Grid modifiers
 ========================================================================== */
.pam-drop-stack .pam-drop-grid > * {
  width: 100% !important;
}
/* Parent icon
 ========================================================================== */
.pam-drop-parent-icon {
  margin-left: 0.25em;
  transition: transform 0.3s ease-out;
}
[aria-expanded="true"] > .pam-drop-parent-icon {
  transform: rotateX(180deg);
}

.pam-dropbar {
  --pam-position-offset: 0;
  --pam-position-shift-offset: 0;
  --pam-position-viewport-offset: 0;
  --pam-inverse: dark;
  /* 1 */
  width: auto;
  /* 2 */
  padding: 15px 15px 15px 15px;
  background: #f8f8f8;
  color: #666;
}
/*
 * Remove margin from the last-child
 */
.pam-dropbar > :last-child {
  margin-bottom: 0;
}
/* Phone landscape and bigger */
@media (min-width: 640px) {
  .pam-dropbar {
    padding-left: 30px;
    padding-right: 30px;
  }
}
/* Tablet landscape and bigger */
@media (min-width: 960px) {
  .pam-dropbar {
    padding-left: 40px;
    padding-right: 40px;
  }
}
.pam-dropbar :focus-visible {
  outline-color: #333 !important;
}
/* Size modifier
 ========================================================================== */
.pam-dropbar-large {
  padding-top: 40px;
  padding-bottom: 40px;
}

.pam-dropnav-dropbar {
  position: absolute;
  z-index: 980;
  padding: 0;
  left: 0;
  right: 0;
}

.pam-bg-transparent {
  background-color: #ccc;
  background-image: linear-gradient(
      45deg,
      white 25%,
      transparent 25%,
      transparent 75%,
      white 75%,
      white
    ),
    linear-gradient(
      45deg,
      white 25%,
      transparent 25%,
      transparent 75%,
      white 75%,
      white
    );
  background-size: 20px 20px;
  background-position: 0px 0px, 10px 10px;
}

/*============= custom button table =============*/
.dt-buttons > button.dt-button,
div.dt-container .dt-paging .dt-paging-button {
  transition: 0.1s ease-in-out;
  transition-property: color, background-color, border-color;
  display: inline-flex;
  height: 2.25rem;
  align-items: center;
  justify-content: center;
  border-radius: 0.375rem;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 500;
  --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color),
    0 1px 2px -1px var(--tw-shadow-color);
  box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000),
    var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);

  border: 1px solid hsl(var(--input));
  background: hsl(var(--background));
  color: hsl(var(--accent-foreground));
}

.dt-buttons > button.dt-button:disabled,
.dt-buttons > button.dt-button.disabled,
div.dt-container .dt-paging .dt-paging-button:disabled,
div.dt-container .dt-paging .dt-paging-button.disabled {
  cursor: not-allowed;
}

div.dt-container .dt-paging {
  display: inline-flex;
}

div.dt-container .dt-paging .dt-paging-button.current {
  background: hsl(var(--accent)) !important;
  border: 1px solid hsl(var(--input)) !important;
}

html.dark div.dt-buttons > .dt-button,
html.dark .dt-container .dt-paging .dt-paging-button {
  border: 1px solid hsl(var(--input));
  background: hsl(var(--background));
  margin-left: 6px;
}

html.dark div.dt-buttons > .dt-button:hover,
html.dark .dt-container .dt-paging .dt-paging-button:hover {
  border: 1px solid hsl(var(--input));
  background: hsl(var(--accent)) !important;
}

div.dt-container .dt-search input,
div.dt-container .dt-length select {
  transition: 0.2s ease-in-out;
  transition-property: color, background-color, border;
  border-radius: 0.375rem;
  border: 1px solid hsl(var(--input));
  background-color: transparent;
  padding: 0.25rem 0.75rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  color: hsl(var(--foreground));
  --tw-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);
  box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000),
    var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
  height: 2.25rem;
}

div.dt-container .dt-length {
  position: relative;
}

div.dt-container .dt-length select {
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  padding-right: 2rem;
}

div.dt-container .dt-length:before {
  content: "▼";
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: hsl(var(--foreground));
}

div.dt-container .dt-search input:focus,
div.dt-container .dt-length select:focus {
  outline: 2px solid transparent;
  outline-offset: 2px;
  --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0
    var(--tw-ring-offset-width) var(--tw-ring-offset-color);
  --tw-ring-shadow: var(--tw-ring-inset) 0 0 0
    calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);
  box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow),
    var(--tw-shadow, 0 0 #0000);
  --tw-ring-color: hsl(var(--ring));
}

html.dark .dt-container .dt-search input,
html.dark .dt-container .dt-length select {
  border-color: hsl(var(--input));
  background-color: transparent;
}

/* HTML: <div class="loader"></div> */
.loader {
  width: 120px;
  height: 12px;
  border-radius: 20px;
  color: hsl(var(--primary));
  border: 2px solid;
  position: relative;
}
.loader::before {
  content: "";
  position: absolute;
  margin: 2px;
  width: 25%;
  top: 0;
  bottom: 0;
  left: 0;
  border-radius: inherit;
  background: currentColor;
  animation: l4 1s infinite linear;
}
@keyframes l4 {
  50% {
    left: 100%;
    transform: translateX(calc(-100% - 4px));
  }
}

.pam-form-stacked {
  padding-bottom: 2rem;
}

textarea {
  field-sizing: content;
  max-height: 60vh;
}

.choices__list--dropdown,
.choices__list[aria-expanded] {
  z-index: 11;
}

.skin-select .choices {
  overflow: visible;
}

.pam-modal .uppy-size--lg .uppy-Dashboard-Item-preview {
  height: 80%;
}

.pam-modal .uppy-Dashboard-inner {
  height: auto !important;
  width: 100% !important;
}

.pam-modal .uppy-Dashboard-innerWrap {
  height: 60vh;;
}

body:has(.pam-modal) {
  overflow: hidden;
}