/* Condensed styling overrides for GitHub Pages documentation */

/* Reduce base font sizes across all breakpoints - halfway between original and small */
html {
  font-size: 15px !important; /* Halfway: 16px → 14px = 15px */
}

@media screen and (min-width: 48em) {
  html {
    font-size: 16.5px !important; /* Halfway: 18px → 15px = 16.5px */
  }
}

@media screen and (min-width: 64em) {
  html {
    font-size: 18px !important; /* Halfway: 20px → 16px = 18px */
  }
}

@media screen and (min-width: 80em) {
  html {
    font-size: 19.5px !important; /* Halfway: 22px → 17px = 19.5px */
  }
}

/* Reduce heading sizes - halfway between original and small */
.page__content h1,
h1#page-title {
  font-size: 1.48em !important; /* Halfway: 1.563em → 1.4em = 1.48em */
  margin-top: 1.75em !important;
  margin-bottom: 0.4em !important;
}

.page__content h2 {
  font-size: 1.2em !important; /* Halfway: 1.25em → 1.15em = 1.2em */
  margin-top: 1.65em !important;
  margin-bottom: 0.4em !important;
}

.page__content h3 {
  font-size: 1.09em !important; /* Halfway: 1.125em → 1.05em = 1.09em */
  margin-top: 1.6em !important;
  margin-bottom: 0.38em !important;
}

.page__content h4 {
  font-size: 1.03em !important; /* Halfway: 1.0625em → 1em = 1.03em */
  margin-top: 1.5em !important;
  margin-bottom: 0.35em !important;
}

.page__content h5,
.page__content h6 {
  font-size: 0.99em !important; /* Halfway: 1.03em → 0.95em = 0.99em */
  margin-top: 1.4em !important;
  margin-bottom: 0.35em !important;
}

/* Reduce paragraph spacing */
.page__content p {
  margin-bottom: 0.9em !important; /* Moderate reduction */
  line-height: 1.6 !important; /* Moderate line height */
}

/* Reduce list spacing */
.page__content ul,
.page__content ol {
  margin-bottom: 0.8em !important;
  line-height: 1.5 !important;
}

.page__content li {
  margin-bottom: 0.2em !important;
}

/* Reduce code block sizes and spacing */
.page__content pre {
  font-size: 0.73em !important; /* Halfway: 0.75em → 0.7em = 0.73em */
  padding: 0.9em !important;
  margin: 0.9em 0 !important;
}

.page__content code {
  font-size: 0.88em !important; /* Moderate size */
  padding: 0.15em 0.35em !important;
}

/* Reduce table font size */
.page__content table {
  font-size: 0.73em !important; /* Halfway: 0.75em → 0.7em = 0.73em */
}

.page__content th,
.page__content td {
  padding: 0.4em 0.6em !important;
}

/* Reduce notice/alert box sizes */
.notice,
.notice--primary,
.notice--info,
.notice--warning,
.notice--success,
.notice--danger {
  font-size: 0.73em !important; /* Halfway: 0.75em → 0.7em = 0.73em */
  padding: 0.9em !important;
  margin: 0.9em 0 !important;
}

/* Reduce blockquote spacing */
.page__content blockquote {
  margin: 0.8em 0 !important;
  padding: 0.5em 1em !important;
  font-size: 0.95em !important;
}

/* Adjust content wrapper padding for condensed view */
.page__inner-wrap {
  padding: 1.5rem 2rem !important;
}

@media (min-width: 2000px) {
  .page__inner-wrap {
    padding: 1.5rem 3rem !important;
  }
}

@media (min-width: 1024px) and (max-width: 1439px) {
  .page__inner-wrap {
    padding: 1.5rem 1.5rem !important;
  }
}

@media (max-width: 1023px) {
  .page__inner-wrap {
    padding: 0.8rem !important;
  }
}

/* Reduce TOC spacing if present */
.toc {
  font-size: 0.75em !important;
}

.toc__menu {
  font-size: 0.85em !important;
}

.toc__menu a {
  padding: 0.2em 0 !important;
}

/* Reduce hero section sizes */
.hero-title {
  font-size: 2.25rem !important; /* Halfway: 2.5rem → 2rem = 2.25rem */
  margin-bottom: 0.4rem !important;
}

.hero-subtitle {
  font-size: 1.2rem !important; /* Halfway: 1.3rem → 1.1rem = 1.2rem */
}

/* Adjust wide screen typography override */
@media (min-width: 1440px) {
  .page__content {
    font-size: 1.06rem !important; /* Halfway: 1.125rem → 1rem = 1.06rem */
    line-height: 1.65 !important; /* Halfway: 1.7 → 1.6 = 1.65 */
  }
  
  .page__content h1 { font-size: 2.25rem !important; } /* Halfway: 2.5rem → 2rem = 2.25rem */
  .page__content h2 { font-size: 1.8rem !important; } /* Halfway: 2rem → 1.6rem = 1.8rem */
  .page__content h3 { font-size: 1.4rem !important; } /* Halfway: 1.5rem → 1.3rem = 1.4rem */
  
  .page__content pre {
    font-size: 0.9rem !important; /* Halfway: 0.95rem → 0.85rem = 0.9rem */
  }
}

/* Reduce image margins */
.page__content img,
.page__content figure {
  margin: 0.8em 0 !important;
}

/* Reduce horizontal rule spacing */
.page__content hr {
  margin: 1.5em 0 !important;
}

/* Make buttons more compact */
.btn {
  font-size: 0.7em !important;
  padding: 0.4em 0.8em !important;
}

/* Reduce feature row spacing if used */
.feature__wrapper {
  margin-bottom: 1.5em !important;
}

.feature__item {
  margin-bottom: 1em !important;
}

/* Reduce archive item spacing if used */
.archive__item {
  margin: 1em 0 !important;
}

.archive__item-title {
  margin-top: 0.5em !important;
  font-size: 1em !important;
}

/* Adjust any definition lists */
.page__content dl {
  font-size: 0.9em !important;
}

.page__content dt {
  margin-top: 0.5em !important;
}

.page__content dd {
  margin-left: 1em !important;
  margin-bottom: 0.5em !important;
}

/* Special adjustments for inline elements */
.page__content strong,
.page__content b {
  font-weight: 600 !important; /* Slightly less bold for smaller text */
}

/* Ensure nested lists don't get too small */
.page__content ul ul,
.page__content ol ol,
.page__content ul ol,
.page__content ol ul {
  font-size: 1em !important; /* Maintain parent size */
}