/* Custom CSS for Prism-H - Minimalist & Chic Theme */

/* Typography Refinements */
:root {
  --md-primary-fg-color: #455a64;
  --md-primary-fg-color--light: #607d8b;
  --md-primary-fg-color--dark: #37474f;
  --md-accent-fg-color: #ff5722;
  --md-text-color: #212121;
  --md-text-color--light: #757575;
  --section-spacing: 3rem;
}

/* Enhanced Typography */
h1 {
  font-weight: 300;
  letter-spacing: -0.02em;
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

h2 {
  font-weight: 400;
  letter-spacing: -0.01em;
  font-size: 1.75rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: var(--md-primary-fg-color);
}

h3 {
  font-weight: 500;
  font-size: 1.25rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--md-primary-fg-color--dark);
}

/* Text Alignment */
.md-content__inner p,
.md-content__inner li {
  text-align: left;
}

/* Homepage Styling */
.md-content__inner > h1:first-child {
  text-align: center;
  margin-bottom: 0.25rem;
  font-size: 3rem;
  font-weight: 200;
  max-width: 100%;
}

.md-content__inner > h1:first-child + h2 {
  text-align: center;
  font-weight: 300;
  color: var(--md-text-color--light);
  margin-bottom: 1rem;
  font-size: 1.5rem;
  max-width: 100%;
}

/* Center and justify main content */
.md-content__inner {
  max-width: none;
  margin: 0;
  padding: 2rem 0.5rem;
}

/* Remove special styling for first paragraph to make all content consistent */

/* Hide conflicting Home elements */
.md-nav__item--nested > .md-nav__link[href="#"] {
  display: none !important;
}

.md-nav__item .md-nav__link[title="Home"] {
  display: none !important;
}

/* Hide "Home" from TOC when it conflicts */
.md-nav--secondary .md-nav__item:first-child {
  display: none !important;
}

/* Move TOC to right side and improve styling */
.md-sidebar--secondary {
  right: 0;
  left: auto;
  width: 16rem;
}

.md-nav--secondary {
  border-left: 1px solid #e0e0e0;
  border-right: none;
  padding-left: 1rem;
  padding-right: 0;
}

.md-nav--secondary .md-nav__title {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--md-text-color--light);
  font-weight: 600;
  margin-bottom: 0.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f0f0f0;
}

.md-nav--secondary .md-nav__link {
  font-size: 0.8rem;
  padding: 0.25rem 0;
  line-height: 1.4;
  color: var(--md-text-color--light);
  transition: color 0.2s ease;
}

.md-nav--secondary .md-nav__link:hover {
  color: var(--md-primary-fg-color);
}

.md-nav--secondary .md-nav__link--active {
  color: var(--md-primary-fg-color);
  font-weight: 500;
}

/* Adjust main content to account for right TOC */
@media screen and (min-width: 76.25em) {
  .md-content {
    margin-right: 15rem;
    margin-left: 0;
  }
  
  .md-content__inner {
    max-width: none;
    padding: 2rem 0.5rem;
    margin: 0;
  }
  
  .md-sidebar--secondary {
    position: fixed;
    top: 6rem;
    right: 1rem;
    left: auto;
    height: calc(100vh - 8rem);
    overflow-y: auto;
  }
}

/* Section dividers */
hr {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, #e0e0e0, transparent);
  margin: var(--section-spacing) 0;
}

/* Enhanced tables */
.md-typeset table:not([class]) {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  margin: 2rem auto;
  max-width: 100%;
}

.md-typeset table:not([class]) th {
  background-color: var(--md-primary-fg-color);
  color: white;
  font-weight: 500;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  padding: 1rem;
}

.md-typeset table:not([class]) td {
  padding: 1rem;
  border-bottom: 1px solid #f5f5f5;
  text-align: left;
}

.md-typeset table:not([class]) tr:hover {
  background-color: #fafafa;
}

/* Code blocks */
.md-typeset .highlight {
  border-radius: 8px;
  margin: 1.5rem 0;
}

/* Mermaid diagrams */
.mermaid {
  text-align: center;
  margin: 2rem auto;
  max-width: 100%;
}

/* Navigation refinements */
.md-tabs__link {
  font-weight: 500;
  text-transform: none;
}

.md-nav__link--active {
  font-weight: 600;
}

/* List styling with better spacing */
.md-typeset ul {
  margin: 1rem 0;
}

.md-typeset ul li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}

/* Table styling improvements */
.md-typeset table th:contains("Component"),
.md-typeset table th:contains("Purpose"),
.md-typeset table th:contains("Key Features") {
  background-color: var(--md-primary-fg-color--dark);
}

/* Admonitions */
.md-typeset .admonition {
  border-radius: 8px;
  margin: 1.5rem 0;
}

/* Footer adjustments */
.md-footer {
  margin-top: 3rem;
}

/* Dark theme adjustments */
[data-md-color-scheme="slate"] {
  --md-text-color: #e0e0e0;
  --md-text-color--light: #b0b0b0;
}

[data-md-color-scheme="slate"] hr {
  background: linear-gradient(90deg, transparent, #424242, transparent);
}

[data-md-color-scheme="slate"] .md-typeset table:not([class]) td {
  border-bottom: 1px solid #424242;
}

[data-md-color-scheme="slate"] .md-typeset table:not([class]) tr:hover {
  background-color: #2a2a2a;
}

[data-md-color-scheme="slate"] .md-nav--secondary {
  border-left: 1px solid #424242;
}

[data-md-color-scheme="slate"] .md-nav--secondary .md-nav__title {
  border-bottom: 1px solid #424242;
}

/* Mobile responsiveness */
@media screen and (max-width: 76.1875em) {
  .md-content__inner > h1:first-child {
    font-size: 2.25rem;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  .md-sidebar--secondary {
    display: none;
  }
  
  .md-content {
    margin-right: 0;
    margin-left: 0;
  }

  .md-content__inner {
    padding: 2rem 1rem;
    max-width: none;
    margin: 0;
  }
} 