/* GLOBAL STYLES - Resets, Base Typography, Prose. Images */
/*********************************************************/


/* =================== */
/* [[[ SPACE RESET ]]] */
/* =================== */

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}


html {
  scroll-behavior: smooth;
}

/* ======================== */
/* [[[ BASE BODY STYLES ]]] */
/* ======================== */

body {

  font-family: var(--font-main);
  color: var(--color-grey-dark);
  font-weight: 350;
  font-style: normal;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Sticky Footer & Layout Setup */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  overflow-x: hidden;
  /* Prevent horizontal scroll from 100vw elements */
}



/* ======================== */
/* [[[ BASE TYPOGRAPHY ]]] */
/* ======================== */

h1 {
  font-weight: 700;
  font-size: 2.4rem;
  line-height: 1.4em;
}

h2 {
  font-weight: 650;
  font-size: 1.9rem;
  line-height: 1.2em;
}

h3 {

  font-weight: 550;
  font-size: 1.65rem;
  line-height: 1.2em;
}

h4 {
  font-weight: 550;
  font-size: 1.35rem;
  line-height: 1.2em;
}

p,
li,
address {
  font-size: 1.2rem;
  line-height: 1.45em;
}


address,
figcaption {
  font-style: normal;
}

b {
  font-weight: 600;
}

a {
  color: var(--color-primary-variant);
  font-weight: 400;
}

.small-text {
  font-size: 0.9rem;
}



/* ========================= */
/* [[[ PARAGRAPH MARGINS ]]] */
/* ========================= */

.prose {
  max-width: 75ch;
  /* Reading container width */
}

.prose p {
  margin-top: 0;
  margin-bottom: 0.8rem;
}

.prose>*:first-child {
  margin-top: 0;
}

.prose>*:last-child {
  margin-bottom: 0;
  /* Prevent double spacing with the Container's row-gap */
}

/* ======================= */
/* [[[ HEADING MARGINS ]]] */
/* ======================= */


.prose h1,
.prose h2 {
  margin-bottom: 0.3rem;
}

.prose h3 {
  margin-top: 1.2rem;
  margin-bottom: 0.2rem;
}


/* ======================= */
/* [[[ LIST FORMATTING ]]] */
/* ======================= */

.prose li {
  /* Generic reset for non-OL items */
  list-style-position: outside;
}

.prose ul {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
  list-style-type: disc;
}

/* Ordered list with counters */
.prose ol {
  counter-reset: section;
  list-style-type: none;
  margin-bottom: 1.5rem;
  padding-left: 0;
}

.prose ol>li {
  position: relative;
  counter-increment: section;
  margin-bottom: 1rem;
  padding-left: 2rem;
}

/* Numbering logic: 3, 3.1, 3.1.1 */
.prose ol>li::before {
  content: counters(section, ".") ".";
  position: absolute;
  left: 0;
  top: 0;
  font-weight: 600;

}

.prose ol ol {
  margin-top: 0.5rem;
  margin-bottom: 0;
}

.prose ol ol>li {
  padding-left: 2.8rem;
}

.prose ol ol ol>li {
  padding-left: 3.2rem;
}




/* ==================== */
/* [[[ IMAGE STYLES ]]] */
/* ==================== */

/* Ensures images are responsive and do not exceed their container's width */
img {
  max-width: 100%;
  height: auto;
}

hr {
  grid-column: 1 / -1;
  border: none;
  border-top: 1px solid var(--color-primary);
}