.container {
    border-radius: 16px;
    box-shadow: 0 24px 40px rgba(0, 0, 0, 0.35);
    margin: 220px auto 60px;
    padding: 56px 32px 40px;
}

.page-title {
    margin-bottom: 40px;
}

.page-title-gap {
    height: 24px;
}

.translation-notice {
    margin: 32px auto 0;
    padding: 18px 20px;
    border-left: 4px solid #7d2128;
    background: rgba(125, 33, 40, 0.2);
    color: white;
    line-height: 1.6;
}

/* ==========================================================================
   Google Doc rules content
   The Google Doc HTML export ships dozens of font-size/color/alignment classes
   (.c1, .c14, .c21 …, scoped to #google-doc-content by rules.js). We override
   size/colour/alignment here with !important so the rules read consistently,
   while deliberately NOT touching font-weight/font-style so the document's
   bold/italic emphasis is preserved.
   ========================================================================== */
.google-doc {
    width: 100%;
    max-width: none;
    min-height: 50vh;
    margin: 32px auto 0;
    color: white;
    text-align: left;
}

/* Body text: one size, one alignment, readable line-height */
.google-doc p,
.google-doc li {
    color: white !important;
    text-align: left !important;
    font-size: 1.05rem !important;
    line-height: 1.65 !important;
    margin: 0 0 10px !important;
}

.google-doc p:empty {
    margin: 0 !important;
}

/* Normalise the inline spans inside body text and headings so the export's
   mixed point sizes (11/11.5/12/14/16/23/26pt) collapse to the parent size. */
.google-doc p span,
.google-doc li span,
.google-doc h2 span,
.google-doc h3 span,
.google-doc h4 span,
.google-doc .title span {
    color: white !important;
    font-size: inherit !important;
}

/* Document title - "Pravidla TFR" */
.google-doc .title {
    text-align: center !important;
    font-size: clamp(2rem, 4.5vw, 2.8rem) !important;
    font-weight: 700;
    margin: 8px 0 32px !important;
    padding-bottom: 18px;
    border-bottom: 3px solid #7d2128;
}

/* Chapter headings - "Hlava první/druhá…" */
.google-doc h2 {
    text-align: center !important;
    font-size: clamp(1.6rem, 3.2vw, 2.1rem) !important;
    font-weight: 700;
    color: white !important;
    margin: 48px 0 8px !important;
}

/* Section headings - "Předmluva", "Kázeňská opatření" … */
.google-doc h3 {
    text-align: center !important;
    font-size: clamp(1.2rem, 2.4vw, 1.5rem) !important;
    font-weight: 600;
    color: #fff !important;
    letter-spacing: 0.5px;
    margin: 28px 0 16px !important;
}

/* Article headings - "Článek X" - with red accent underline */
.google-doc h4 {
    text-align: center !important;
    font-size: clamp(1.15rem, 2.2vw, 1.35rem) !important;
    font-weight: 700;
    color: white !important;
    margin: 32px 0 6px !important;
    padding-bottom: 12px;
    border-bottom: 3px solid #7d2128;
}

/* Lists: render items as numbered points. We ignore the export's own "(1)"
   counters and use our own CSS counter, reset per <ol> so each list (article)
   starts again at 1. All body list items are level-0 li-bullet-0. */
.google-doc ol,
.google-doc ul {
    list-style: none !important;
    margin: 0 0 14px !important;
    padding: 0 0 0 8px !important;
    border: 0 !important;
    counter-reset: ruleitem !important;
}

.google-doc li {
    position: relative;
    padding: 4px 0 4px 34px !important;
    counter-increment: ruleitem !important;
}

.google-doc li:before {
    content: counter(ruleitem) "." !important;
    visibility: visible !important;
    position: absolute;
    left: 4px;
    top: 4px;
    min-width: 22px;
    text-align: right;
    color: #7d2128 !important;
    font-weight: 700;
}

/* Google Doc hyperlinks export as blue (#1155cc/#4a86e8); force them white like
   the rest of the rules text. Other inline colours are left untouched. */
.google-doc a,
.google-doc a span,
.google-doc a:link,
.google-doc a:visited {
    color: white !important;
    text-decoration: underline;
}

@media (min-width: 1600px) and (min-aspect-ratio: 21 / 9) {
    .page-intro,
    .google-doc {
        max-width: 1400px;
    }
}
