﻿/* Global Reset
   Ensures consistent box sizing and margin behavior across browsers
   Important for Aspose.Words rendering consistency */
*,
*::before,
*::after {
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    margin: 0;
}

/* Base Typography
   Default font settings used throughout the document
   Times New Roman is standard for EMA regulatory documents */
body {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    color: #000;
    line-height: normal;
}

p {
    margin: 0;
}

/* Document Section Headers - Level 0
   Hidden headers that are not rendered but maintained in structure
   Used across all document types (SmPC, Annex II, Labelling, Package Leaflet) */
.epi__smpc--level-0,
.epi__annexii--level-0,
.epi__labelling--level-0,
.epi__packageleaflet--level-0 {
    display: none; /* Not rendered by default */
}

/* Document Section Headers - Level 1
   Main document title formatting with central alignment
   Used for primary headings in all document types
   No spacing before, one blank line after */
.epi__smpc--level-1,
.epi__annexii--level-1,
.epi__labelling--level-1,
.epi__packageleaflet--level-1 {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    font-weight: bold;
    color: #000;
    text-align: center;
    line-height: normal;
    margin-top: 0em;
    margin-bottom: 1em;
}

/* Document Section Headers - Level 2
   Secondary heading style for SmPC, Annex II and Package Leaflet
   Bold with significant spacing (2em) before to create visual separation
   Not applied to Labelling which uses borders instead */
.epi__smpc--level-2,
.epi__annexii--level-2,
.epi__packageleaflet--level-2 {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    font-weight: bold;
    color: #000;
    line-height: normal;
    margin-top: 2em;
    margin-bottom: 1em;
}

/* Document Section Headers - Level 3
   Tertiary heading style used across all document types
   Bold with moderate spacing (1em) before section
   Creates visual hierarchy while maintaining document flow */
.epi__smpc--level-3,
.epi__annexii--level-3,
.epi__packageleaflet--level-3 {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    font-weight: bold;
    color: #000;
    line-height: normal;
    margin-top: 1em;
    margin-bottom: 1em;
}

/* SmPC-Specific Heading Styles
   Additional heading levels only used in Summary of Product Characteristics
   Levels 4-5 use underline instead of bold for visual distinction */
.epi__smpc--level-4 {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    color: #000;
    text-decoration: underline;
    line-height: normal;
    margin-top: 1em;
    margin-bottom: 1em;
}

.epi__smpc--level-5 {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    color: #000;
    font-style: italic;
    text-decoration: underline;
    line-height: normal;
    margin-top: 1em;
    margin-bottom: 1em;
}

/* Labelling-Specific Styles
   Uses bordered containers rather than just spacing for visual separation
   Border styling complies with EMA QRD template requirements
   Critical for proper rendering of product labelling information */
.epi__labelling--level-2-border,
.epi__labelling--level-3-border {
    border: 1px solid black;
    padding: 5px;
    margin-top: 2em;
    margin-bottom: 1em;
}

.epi__labelling--level-2,
.epi__labelling--level-3 {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    font-weight: bold;
    color: #000;
    line-height: normal;
}

/* Default Content Style
   Fallback style for general content without specific class assignments
   Ensures consistent rendering throughout document */
.epi__default {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    color: #000;
    line-height: normal;
}

.epi__error {
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    font-weight: bold;
    color: red;
    line-height: normal;
}

/* Numbered Title Formatting
   Creates structured layout for numbered sections
   Uses flexbox for consistent alignment between numbers and headings */
.epi-row {
    display: flex;
    align-items: flex-start;
    flex-wrap: nowrap;
}

.epi-row__number {
    width: 1cm;
    text-align: left;
    font-weight: bold;
    flex-shrink: 0;
}

.epi-row__aligned-text {
    padding-left: 0px;
    font-weight: bold;
    flex-grow: 1;
    word-break: break-word;
}

/* Text Emphasis Elements
   Standard HTML emphasis markers with consistent styling
   Used for highlighting important information in content */
em {
    font-style: italic;
}

strong {
    font-weight: bold;
}

/* List Styling
   Hierarchical list formatting for ordered and unordered lists
   Disc → Circle → Square progression for nested unordered lists */
ul {
    list-style-type: disc;
}

    ul ul {
        list-style-type: circle;
    }

        ul ul ul {
            list-style-type: square;
        }

ol, ol ol, ol ol ol {
    list-style-type: decimal;
}

ul, ol {
    margin: 0;
    padding: 0;
    list-style-position: outside;
}

/* Apply custom list styling */
ul, ol {
    padding-left: 0.5cm; /* Bullet point distance from left margin */
}

/* Style for list items */
li {
    padding-left: 0.5cm; /* Text distance from bullet point */
    margin-left: 0.5cm; /* Ensure consistent indentation for wrapped lines */
}

/* Image Constraints
   Prevents oversized images from breaking layout
   600px matches EMA guidance for diagram width */
img {
    max-width: 600px;
}

/* Scientific Notation Elements
   Specialized formatting for chemical formulas and footnotes
   70% size maintains readability while ensuring proper line height */
sub,
sup {
    font-size: 70%;
    line-height: 0;
    position: relative;
}

sub {
    vertical-align: -0.25em;
}

sup {
    vertical-align: 0.5em;
}

/* Table Formatting
   EMA-compliant table styling for data presentation
   Uses thin 0.5pt borders as per regulatory requirements
   Tables must maintain full width with consistent cell padding */
table {
    border-collapse: collapse;
    width: 100%;
    font-family: "Times New Roman", Times, serif;
    font-size: 11pt;
    color: #000;
    line-height: normal;
    border: 0.5pt solid black;
    text-align: left;
}

table th,
table td,
table thead {
    border: 0.5pt solid black;
    padding: 8px;
    text-align: left;
}

table caption {
    font-weight: bold;
    text-align: left;
}

table foot {
    font-size: 9pt;
    text-align: left;
}

table img {
    max-width: 600px;
    width: 100%;
    height: auto;
    display: block;
}