/* Slightly tighter card grids on the landing pages */
.md-typeset .grid.cards > ul > li {
  padding: 1.2rem;
}

/* Brand accent on the top banner */
.md-header {
  box-shadow: 0 0 0.2rem rgba(0, 0, 0, 0.1), 0 0.2rem 0.4rem rgba(0, 0, 0, 0.2);
}

/* Make code samples a touch friendlier */
.md-typeset code {
  border-radius: 0.2rem;
  padding: 0.1em 0.3em;
}

/* Status pills (new / deprecated) */
.md-status--new::after {
  background-color: var(--md-accent-fg-color);
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin: 1.5rem 0;
}

.video-cell {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.video-cell .video-container {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
}

.video-cell .video-container iframe {
  position: absolute !important;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  border: 0;
}

.video-cell p > a.glightbox[data-type="image"][href*="youtube.com/embed"] {
  display: none;
}

.video-cell p:empty,
.video-cell p:has(> a.glightbox:only-child) {
  display: none;
  margin: 0;
}

.md-typeset .admonition.question,
.md-typeset details.question {
  border-color: #1976d2;
}

.md-typeset .question > .admonition-title,
.md-typeset .question > summary {
  background-color: rgba(68, 138, 255, 0.1);
}

.md-typeset .question > .admonition-title::before,
.md-typeset .question > summary::before {
  background-color: #1976d2;
}

.md-typeset details.question > summary::after {
  background-color: #1976d2;
}

.md-typeset details.plain > summary {
  display: block !important;
  background: transparent !important;
  border: none !important;
  padding: 0.2em 0 0.2em 1.4em !important;
  font-weight: normal !important;
  color: var(--md-default-fg-color--light);
  cursor: pointer;
  list-style: none;
  position: relative;
}

.md-typeset details.plain > summary::before {
  content: "⏵";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.8em;
  line-height: 1;
  color: var(--md-default-fg-color--light);
  transform-origin: center center;
  transition: transform 0.2s ease;
  background: none !important;
  mask-image: none !important;
  -webkit-mask-image: none !important;
}

.md-typeset details.plain[open] > summary::before {
  transform: translateY(-50%) rotate(90deg);
}

.md-typeset .grid.cards.three-cols {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)) !important;
  gap: 1rem;
}

/* Collapse to a single column on narrow screens */
@media (max-width: 700px) {
  .video-grid {
    grid-template-columns: 1fr;
  }
}