.body,

/* Make youtube videos full screen */
iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
}

/* Grid Layout */
.grid {
  grid-template-columns: 1fr !important;
}

.grid ul {
  margin: 0 !important;
  list-style: none;
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 2em !important;
  padding: 0;
}

.grid li {
  margin: 0;
  flex: 1 0 45% !important;
  padding: 1.25em;
  background-color: rgba(255, 255, 255, 0.03);
  border: 0px !important;
  border-radius: 0.5em !important;
  transition: all 0.5s ease;
  display: flex;
  flex-direction: column;
}

.grid-wide li {
  flex: 1 0 100% !important;
}

.grid > ul li > h1 {
  margin: 0px;
  display: block;
  font-size: 1.5em;
}
.grid > ul li:hover {
  box-shadow: 5px 10px 0px rgba(0, 0, 0, 0.7);
  background-color: rgba(255, 255, 255, 0.05);
}

.grid ul li h2 {
  margin: 0px;
  display: block;
  font-weight: 400;
  font-size: 1.2em;
}
.grid ul li > hr {
  margin: 0.5em 0;
}

.grid ul li > p {
  font-weight: 100;
}

.grid ul li img {
  float: left;
  margin-right: 2em;
  width: 30%;
}

/* Read the docs */
.rst-versions.rst-badge {
  bottom: 80px !important;
}
.grid ul li a {
  color: var(--md-accent-fg-color) !important;
  text-decoration: none;
}

.grid ul li a:hover {
  color: #fc8500 !important;
  text-decoration: underline;
}

.grid > ul li > h1 > a::after {
  content: "→";
  margin-left: 0.3em;
  font-size: 0.9em;
  opacity: 0.6;
  transition: opacity 0.2s ease;
}

.grid > ul li > h1 > a:hover::after {
  opacity: 1;
}

/* ===================================================================
   Foundry brand palette — SIGGRAPH 2026 template
   Amber   #fcb434  signature accent (Foundry "F." dot, bullets, highlights)
   Orange  #fc8500  deeper orange for hover states
   Burnt   #d35400  readable orange for links on light surfaces
   Black   #0e0e0e  Foundry near-black surface / header
   Cream   #f9f3ed  warm off-white
   =================================================================== */

/* Header / nav bar: Foundry near-black in both light and dark modes */
[data-md-color-primary="custom"] {
  --md-primary-fg-color: #0e0e0e;
  --md-primary-fg-color--light: #333333;
  --md-primary-fg-color--dark: #000000;
  --md-primary-bg-color: #ffffff;
  --md-primary-bg-color--light: rgba(255, 255, 255, 0.7);
}

/* Fallback accent, overridden per scheme below */
[data-md-color-accent="custom"] {
  --md-accent-fg-color: #fcb434;
  --md-accent-fg-color--transparent: rgba(252, 180, 52, 0.1);
}

/* Dark variation: Foundry near-black canvas, amber accent + links */
[data-md-color-scheme="slate"] {
  --md-default-bg-color: #0e0e0e;
  --md-default-bg-color--light: #1a1a1a;
  --md-code-bg-color: #1a1a1a;
  --md-accent-fg-color: #fcb434;
  --md-accent-fg-color--transparent: rgba(252, 180, 52, 0.1);
  --md-typeset-a-color: #fcb434;
}

/* Light variation: white canvas, burnt-orange links for AA contrast */
[data-md-color-scheme="default"] {
  --md-accent-fg-color: #d35400;
  --md-accent-fg-color--transparent: rgba(211, 84, 0, 0.1);
  --md-typeset-a-color: #d35400;
}
