/* PepKit docs polish (works with sphinx_rtd_theme + fallback themes) */

/* --- Layout / typography --- */
.wy-nav-content {
  max-width: 980px;
}

.rst-content h1, .rst-content h2, .rst-content h3 {
  letter-spacing: 0.2px;
}

/* Make paragraphs breathe a bit */
.rst-content p {
  line-height: 1.65;
}

/* Slightly nicer inline code */
.rst-content code.literal {
  border-radius: 6px;
  padding: 0 4px;
  border: 1px solid rgba(0,0,0,0.10);
  background: rgba(0,0,0,0.02);
}

/* --- Code blocks --- */
.rst-content pre {
  border-radius: 10px;
}

.rst-content div[class*='highlight'] {
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

/* Improve spacing around code blocks */
.rst-content div[class*='highlight'] {
  margin: 14px 0;
}

/* --- Tables --- */
.rst-content table.docutils {
  border-radius: 10px;
  overflow: hidden;
}

.rst-content table.docutils thead th {
  background: rgba(0,0,0,0.03);
}

/* Slightly tighter table cells */
.rst-content table.docutils td, .rst-content table.docutils th {
  padding: 8px 10px;
}

/* --- Admonitions --- */
.rst-content .admonition {
  border-radius: 10px;
  border-left-width: 6px;
}

/* Make tips/notes a touch more compact */
.rst-content .admonition p {
  margin: 8px 0;
}

/* --- Landing page components --- */
.hero {
  padding: 22px 22px 14px 22px;
  margin: 10px 0 20px 0;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(0,0,0,0.02), rgba(0,0,0,0.00));
}

.hero-title {
  font-size: 34px;
  font-weight: 700;
  margin: 0;
}

.hero-subtitle {
  margin-top: 6px;
  font-size: 16px;
  opacity: 0.9;
}

/* Badges */
.badges {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.10);
  background: rgba(255,255,255,0.65);
  font-size: 12px;
}

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin: 14px 0 22px 0;
}

.card {
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255,255,255,0.65);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.card h3 {
  margin: 0 0 6px 0;
  font-size: 16px;
}

.card p {
  margin: 0 0 10px 0;
  font-size: 13px;
  opacity: 0.95;
}

.card a {
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.card a:hover {
  text-decoration: underline;
}

/* --- Keyboard key styling (Sphinx :kbd: role) --- */
.rst-content kbd {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 6px;
  border: 1px solid rgba(0,0,0,0.18);
  background: rgba(0,0,0,0.03);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
    "Courier New", monospace;
  font-size: 12px;
}

/* Optional custom kbd utility class */
.kbd {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 6px;
  border: 1px solid rgba(0,0,0,0.18);
  background: rgba(0,0,0,0.03);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
    "Courier New", monospace;
  font-size: 12px;
}

/* make clickable figures feel interactive */
.clickable-figure,
.clickable-figure-img {
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  will-change: transform;
}

.clickable-figure:hover,
.clickable-figure-img:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 40px rgba(11,63,136,0.08);
}

/* focus-visible for keyboard users */
.clickable-figure:focus-visible,
.clickable-figure-img:focus-visible,
a:focus-visible > .clickable-figure-img {
  outline: 3px solid rgba(11,95,255,0.12);
  outline-offset: 6px;
  border-radius: 8px;
}
