Template:LegalDocument/styles.css: Difference between revisions

From RACKWiki
No edit summary
Tag: Reverted
(Wooooo)
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
/* Gemini sucks */
/* Legal Document Formatting with Multi-Level Numbering */


/* Container Reset */
/* Initialize the document container and level 1 counter */
.legal-doc {
.legal-doc {
   counter-reset: level1;
   counter-reset: level1;
Line 8: Line 8:
}
}


/* 1. Reset all lists to zero indent so they align with "Normal Text" */
/* Remove default list styling from all nested lists */
.legal-doc ol {
.legal-doc ol {
   list-style-type: none;
   list-style-type: none;
Line 15: Line 15:
}
}


/* 2. LEVEL 1: Articles - Centered */
/* LEVEL 1: Articles (e.g., "ARTICLE 1")
  Centered, bold, larger font */
.legal-doc > ol > li {
.legal-doc > ol > li {
   counter-increment: level1;
   counter-increment: level1;
Line 26: Line 27:
}
}


/* 3. Common setup for Levels 2, 3, and 4 */
/* LEVEL 2: Sections (e.g., "Section 1.1")
.legal-doc ol ol li {
  Normal text with 8em left gutter for content, number at 0.5em */
.legal-doc > ol > li > ol > li {
   position: relative;
   position: relative;
  counter-increment: level2;
  counter-reset: level3;
   font-weight: normal;
   font-weight: normal;
   text-align: left;
   text-align: left;
  /* This padding creates the Gutter */
   padding-left: 8em;
   padding-left: 8em;  
   margin-bottom: 1.2em !important;
   margin-bottom: 1.2em !important;
}
}


/* Remove margin from the very last item in a sub-list to prevent stacking */
.legal-doc > ol > li > ol > li::before {
.legal-doc li:last-child {
   content: "Section " counter(level1) "." counter(level2);
  margin-bottom: 0 !important;
}
 
/* 1. Ensure the list container itself doesn't add extra padding */
.legal-doc ol ol ol,
.legal-doc ol ol ol ol {
   margin-top: 1.2em !important; /* Forces the same gap as margin-bottom */
}
 
.legal-doc ol ol li::before {
   position: absolute;
   position: absolute;
  left: 0.5em;
   font-weight: normal;
   font-weight: normal;
   white-space: nowrap;
   white-space: nowrap;
}
}


/* 4. LEVEL 2: "Section 1.1"
/* LEVEL 3: Subsections (e.g., "1.1.1")
  Number starts 0.5em from the left margin */
   Text aligns with level 2 gutter (8em), number at 2em */
.legal-doc ol ol > li {
.legal-doc > ol > li > ol > li > ol > li {
  counter-increment: level2;
  position: relative;
  counter-reset: level3;
}
 
.legal-doc ol ol > li::before {
  content: "Section " counter(level1) "." counter(level2);
  left: 0.5em;
}
 
/* 5. LEVEL 3: "1.1.1"  
   Text aligns with L2 gutter (8em), Number indents to 2em */
.legal-doc ol ol ol > li {
   counter-increment: level3;
   counter-increment: level3;
   counter-reset: level4;
   counter-reset: level4;
   /* Reset nesting: ensures L3 doesn't add to L2's padding */
   font-weight: normal;
   margin-left: -8em;  
  text-align: left;
   padding-left: 8em;  
   margin-left: -8em;
   padding-left: 8em;
  margin-bottom: 1.2em !important;
}
}


.legal-doc ol ol ol > li::before {
.legal-doc > ol > li > ol > li > ol > li::before {
   content: counter(level1) "." counter(level2) "." counter(level3);
   content: counter(level1) "." counter(level2) "." counter(level3);
   left: 2em;  
  position: absolute;
   left: 2em;
  font-weight: normal;
  white-space: nowrap;
}
}


/* 6. LEVEL 4: "1.1.1.1"  
/* LEVEL 4: Sub-subsections (e.g., "1.1.1.1")
   Both text and number move right */
   Text indented further to 9.5em, number at 3.5em */
.legal-doc ol ol ol ol li {
.legal-doc > ol > li > ol > li > ol > li > ol > li {
   counter-increment: level4 !important;
  position: relative;
   counter-increment: level4;
  font-weight: normal;
  text-align: left;
   margin-left: -8em;
   margin-left: -8em;
   padding-left: 9.5em;  
   padding-left: 9.5em;
  margin-bottom: 1.2em !important;
}
}


.legal-doc ol ol ol ol > li::before {
.legal-doc > ol > li > ol > li > ol > li > ol > li::before {
   content: counter(level1) "." counter(level2) "." counter(level3) "." counter(level4);
   content: counter(level1) "." counter(level2) "." counter(level3) "." counter(level4);
   left: 3.5em;  
  position: absolute;
   left: 3.5em;
  font-weight: normal;
  white-space: nowrap;
}
 
/* Remove bottom margin from last item in any list to prevent stacking */
.legal-doc li:last-child {
  margin-bottom: 0 !important;
}
 
/* Add top margin to nested list containers to maintain spacing */
.legal-doc ol ol ol,
.legal-doc ol ol ol ol {
  margin-top: 1.2em !important;
}
}


/* Line breaks: add spacing between paragraphs within list items */
.legal-doc br {
.legal-doc br {
   display: block;
   display: block;
   content: "";
   content: "";
   margin-top: 0.8em; /* Adds extra 1.5 spacing */
   margin-top: 0.8em;
}
}


.legal-doc li br:first-of-type {
/* Smaller gap after underlined headings within list items */
.legal-doc u + br {
   display: block;
   display: block;
   content: "";
   content: "";
   margin-top: 0; /* Create a smaller gap for the underlined title */
   margin-top: 0;
}
}

Latest revision as of 18:42, 10 February 2026

/* Legal Document Formatting with Multi-Level Numbering */

/* Initialize the document container and level 1 counter */
.legal-doc {
  counter-reset: level1;
  line-height: 1.6;
  margin-top: 1em;
}

/* Remove default list styling from all nested lists */
.legal-doc ol {
  list-style-type: none;
  margin: 0 !important;
  padding: 0 !important;
}

/* LEVEL 1: Articles (e.g., "ARTICLE 1")
   Centered, bold, larger font */
.legal-doc > ol > li {
  counter-increment: level1;
  counter-reset: level2;
  margin-top: 2.5em !important;
  margin-bottom: 1.5em !important;
  font-weight: bold;
  text-align: center;
  font-size: 1.1em;
}

/* LEVEL 2: Sections (e.g., "Section 1.1")
   Normal text with 8em left gutter for content, number at 0.5em */
.legal-doc > ol > li > ol > li {
  position: relative;
  counter-increment: level2;
  counter-reset: level3;
  font-weight: normal;
  text-align: left;
  padding-left: 8em;
  margin-bottom: 1.2em !important;
}

.legal-doc > ol > li > ol > li::before {
  content: "Section " counter(level1) "." counter(level2);
  position: absolute;
  left: 0.5em;
  font-weight: normal;
  white-space: nowrap;
}

/* LEVEL 3: Subsections (e.g., "1.1.1")
   Text aligns with level 2 gutter (8em), number at 2em */
.legal-doc > ol > li > ol > li > ol > li {
  position: relative;
  counter-increment: level3;
  counter-reset: level4;
  font-weight: normal;
  text-align: left;
  margin-left: -8em;
  padding-left: 8em;
  margin-bottom: 1.2em !important;
}

.legal-doc > ol > li > ol > li > ol > li::before {
  content: counter(level1) "." counter(level2) "." counter(level3);
  position: absolute;
  left: 2em;
  font-weight: normal;
  white-space: nowrap;
}

/* LEVEL 4: Sub-subsections (e.g., "1.1.1.1")
   Text indented further to 9.5em, number at 3.5em */
.legal-doc > ol > li > ol > li > ol > li > ol > li {
  position: relative;
  counter-increment: level4;
  font-weight: normal;
  text-align: left;
  margin-left: -8em;
  padding-left: 9.5em;
  margin-bottom: 1.2em !important;
}

.legal-doc > ol > li > ol > li > ol > li > ol > li::before {
  content: counter(level1) "." counter(level2) "." counter(level3) "." counter(level4);
  position: absolute;
  left: 3.5em;
  font-weight: normal;
  white-space: nowrap;
}

/* Remove bottom margin from last item in any list to prevent stacking */
.legal-doc li:last-child {
  margin-bottom: 0 !important;
}

/* Add top margin to nested list containers to maintain spacing */
.legal-doc ol ol ol,
.legal-doc ol ol ol ol {
  margin-top: 1.2em !important;
}

/* Line breaks: add spacing between paragraphs within list items */
.legal-doc br {
  display: block;
  content: "";
  margin-top: 0.8em;
}

/* Smaller gap after underlined headings within list items */
.legal-doc u + br {
  display: block;
  content: "";
  margin-top: 0;
}