/* Ensure content takes up full size */
#main-content {
  height: 100vh;
}

/* Format menu bar */
#main-content #toolbar {
  box-shadow: 1px 1px 10px -3px rgba(252, 252, 252, 0.8)
}

/* Style series cards */
.series-name {
  text-align: center;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ui.cards > .card {
  min-width: 100px;
  width: 10%;
  max-width: 150px;
}

#toolbar .invisible.item {
  display: none;
}

/* #series-list .card > .image {
  position: relative;
} */

/* #series-list .card > .image::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 10px;
  height: 10px;
  background-color: red;
  border-radius: 50%;
} */

/* Force the aspect ratio for all posters */
.card img {
  aspect-ratio: 1 / 1.5;
}

/* Make unmonitored posters grayscale/blur */
.card img.unmonitored {
  filter: grayscale(100%) blur(4px);
}
table img.unmonitored {
  filter: grayscale(100%) blur(2px);
}

/* Enforce a max width of name rows */
table td[data-row="name"] {
  max-width: 2.5em;
  overflow: hidden;
}
table td[data-row="name"] .content {
  white-space: normal;
  word-break: break-word;
  max-width: calc(100% - 30px - 0.1em);
}
/* When in select mode, highlight selected rows */
#series-table tr.selected {
  background-color: rgba(255, 227, 0, 0.29);
}
table .dropdown[data-value="libraries"] .active.item {
  color: crimson !important; 
}

/* Do not round edges of progress bars */
.ui.progress {
  border-radius: 0;
}

/* Remove minimum width on progress bar */
.ui.progress.attached .bar {
  min-width: 0;
}

/* Vertically center statistic loaders */
.statistics .statistic .value .loader {
  top: -0.2em;
}

/* Mobile formatting */
@media (max-width: 768px) {
  /* Show 3 cards/row */
  .ui.cards .card {
    min-width: unset;
    width: calc(33% - 1em);
  }
  /* Hide year and library columns on mobile */
  .ui.basic.sortable.striped.celled.unstackable.table thead th:nth-child(3),
  .ui.basic.sortable.striped.celled.unstackable.table thead th:nth-child(4),
  .ui.basic.sortable.striped.celled.unstackable.table tbody td[data-row="year"],
  .ui.basic.sortable.striped.celled.unstackable.table tbody td[data-row="libraries"] {
    display: none !important;
  }
}

/* Pulse cards on hover - alternate */
.ui.cards > .card:hover {
  animation: pulse 0.75s 1; 
}
@keyframes pulse {
  0%, 
  100% {
    animation-timing-function: ease-in;
  }
  50% {
    transform: scale(1.03);
  }
}

/* Pulse the add series button on hover */
#add-series:hover {
  animation: pulse 2s infinite;
}

/* Reduce vertical margin on statistics */
.horizontal.statistics .statistic {
  margin-top: 0.5em !important;
  margin-bottom: 0.5em !important;
}

/* Add margin above pagination menu */
.cards ~ #pagination {
  margin-top: 1em;
}

@media only screen and (hover: none) and (pointer: coarse) {
  #pagination {
    /* On mobile, wrap pagination if wider than screen */
    max-width: 100%;
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
  }
}

:root {
  --layer-size: 9em;
  --moveup-distance: 2em; /* 1em */
  --x-rotation: 57deg; /* 50deg */
  --inter-layer-margin: 3.5em;
}
/**
 * Create the loop delay with
 * the extra keyframes
 */
@keyframes moveup {
  0%, 60%, 100% {
    transform: rotateX(var(--x-rotation)) rotateY(0deg) rotateZ(45deg) translateZ(0);
  }
  25% {
    transform: rotateX(var(--x-rotation)) rotateY(0deg) rotateZ(45deg) translateZ(var(--moveup-distance));
  }
}
@keyframes movedown {
  0%, 60%, 100% {
    transform: rotateX(var(--x-rotation)) rotateY(0deg) rotateZ(45deg) translateZ(0);
  }
  25% {
    transform: rotateX(var(--x-rotation)) rotateY(0deg) rotateZ(45deg) translateZ(calc(-1 * var(--moveup-distance)));
  }
}

/**
 * Square layer styles
 */
.container .layer {
  display: block;
  position: absolute;
  height: var(--layer-size);
  width: var(--layer-size);
  box-shadow: 10px 10px 4px rgba(0, 0, 0, 0.2); /* 3px 3px 2px rgba(0, 0, 0, 0.2); */
  transform: rotateX(var(--x-rotation)) rotateY(0deg) rotateZ(45deg);
  background-color: rgba(29, 29, 29, 0.9);
}
.container .layer:nth-of-type(1) {
  border: 1.25em solid var(--tcm-blue-color);
  margin-top: var(--inter-layer-margin); /* 1.5em; */
  -webkit-animation: movedown 1.8s cubic-bezier(0.39, 0.575, 0.565, 1) 0.9s infinite normal;
          animation: movedown 1.8s cubic-bezier(0.39, 0.575, 0.565, 1) 0.9s infinite normal;
}
.container .layer:nth-of-type(2) {
  border: 1.25em solid white;
  margin-top: calc(var(--inter-layer-margin) / 2.0); /* 0.75em; */
}
.container .layer:nth-of-type(3) {
  border: 1.25em solid var(--tcm-blue-color);
  -webkit-animation: moveup 1.8s cubic-bezier(0.39, 0.575, 0.565, 1) infinite normal;
          animation: moveup 1.8s cubic-bezier(0.39, 0.575, 0.565, 1) infinite normal;
}

/* Stage and link styles */
.container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
