/* ============================================
   Призма — кастомные стили
   ============================================ */

/* --- Hero section on the landing page --- */
.md-typeset .hero {
  text-align: center;
  padding: 2rem 1rem 1rem;
  margin-bottom: 2rem;
}

.md-typeset .hero h1 {
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.md-typeset .hero .hero-subtitle {
  font-size: 1.15rem;
  opacity: 0.82;
  max-width: 640px;
  margin: 0 auto 1.5rem;
  line-height: 1.6;
}

.md-typeset .hero .hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.md-typeset .hero .hero-actions .md-button {
  font-weight: 600;
}

/* --- Better table readability --- */
.md-typeset table:not([class]) {
  font-size: 0.82rem;
  display: block;
  overflow-x: auto;
  white-space: nowrap;
}

.md-typeset table:not([class]) th {
  white-space: nowrap;
  font-weight: 700;
  min-width: 100px;
}

.md-typeset table:not([class]) td {
  white-space: normal;
  min-width: 80px;
}

/* Allow wider tables to scroll on narrow screens */
@media screen and (max-width: 76.25em) {
  .md-typeset table:not([class]) {
    font-size: 0.78rem;
  }
}

/* --- Traffic light confidence badges --- */
.confidence-fact,
.confidence-hypothesis,
.confidence-gap {
  display: inline-block;
  width: 0.85em;
  height: 0.85em;
  border-radius: 50%;
  vertical-align: middle;
  margin-right: 0.25em;
}

.confidence-fact {
  background: #4caf50;
  box-shadow: 0 0 4px rgba(76, 175, 80, 0.5);
}

.confidence-hypothesis {
  background: #ff9800;
  box-shadow: 0 0 4px rgba(255, 152, 0, 0.5);
}

.confidence-gap {
  background: #f44336;
  box-shadow: 0 0 4px rgba(244, 67, 54, 0.5);
}

/* --- Grid cards layout --- */
.md-typeset .grid.cards > ul {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 0.8rem;
  list-style: none;
  padding: 0;
}

.md-typeset .grid.cards > ul > li {
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 0.4rem;
  padding: 1rem 1.2rem;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.md-typeset .grid.cards > ul > li:hover {
  border-color: var(--md-accent-fg-color);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* --- Template code blocks (brief, phase record) --- */
.md-typeset .template-block pre {
  border: 2px solid var(--md-accent-fg-color);
  border-radius: 0.5rem;
  background: var(--md-code-bg-color);
}

/* --- Mermaid diagram sizing --- */
.md-typeset .mermaid {
  text-align: center;
  margin: 1.5rem 0;
}

/* --- Phase definition list styling --- */
.md-typeset dl dt {
  font-weight: 700;
}

.md-typeset dl dd {
  margin-bottom: 1.2rem;
}
