/**
 * Copyright 2024-2025 Kronseder & Reiner GmbH, smartics
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
/*
   ... Heading Numbers Layout Configuration ................................
 */
div.projectdoc-top-section.projectdoc-section-heading1 > h1,
div.projectdoc-top-section.projectdoc-section-heading2 > h2,
div.projectdoc-top-section.projectdoc-section-heading3 > h3,
div.projectdoc-top-section.projectdoc-section-heading4 > h4,
div.projectdoc-top-section.projectdoc-section-heading5 > h5,
div.projectdoc-top-section.projectdoc-section-heading6 > h6 {
  margin-top: 0;
}

/* https://www.smartics.eu/jira/browse/PDAC-652
     CSS Face Lifting for Spacing between Headings (Confluence 5.9.x)
     spacing between e.g. h1 h2 following directly each other without any
     text in between  */
.wiki-content h1 + div > span:first-of-type + div.projectdoc-section-heading2 h2,
.wiki-content h2 + div > span:first-of-type + div.projectdoc-section-heading3 h3,
.wiki-content h3 + div > span:first-of-type + div.projectdoc-section-heading4 h4,
.wiki-content h4 + div > span:first-of-type + div.projectdoc-section-heading5 h5,
.wiki-content h5 + div > span:first-of-type + div.projectdoc-section-heading6 h6 {
  margin-top: 10px;
}

/* https://www.smartics.eu/jira/browse/PDAC-435 spacing between e.g. h1 h2
    following directly each other without any text in between */
.wiki-content h1 + span + div.projectdoc-section-heading2 h2,
.wiki-content h2 + span + div.projectdoc-section-heading3 h3,
.wiki-content h3 + span + div.projectdoc-section-heading4 h4,
.wiki-content h4 + span + div.projectdoc-section-heading5 h5,
.wiki-content h5 + span + div.projectdoc-section-heading6 h6 {
  margin-top: 10px;
}

/* https://www.smartics.eu/jira/browse/PDAC-402 Spacing for Sections is Too Large */
.wiki-content div.projectdoc-section-heading1 h1,
.wiki-content div.projectdoc-section-heading2 h2,
.wiki-content div.projectdoc-section-heading3 h3,
.wiki-content div.projectdoc-section-heading4 h4,
.wiki-content div.projectdoc-section-heading5 h5,
.wiki-content div.projectdoc-section-heading6 h6 {
  margin-top: 10px;
}

/* https://www.smartics.eu/jira/browse/PDAC-402 Spacing for Sections is Too Large */
.wiki-content .panelContent div.projectdoc-section-heading1 h1:first-child,
.wiki-content .panelContent div.projectdoc-section-heading2 h2:first-child,
.wiki-content .panelContent div.projectdoc-section-heading3 h3:first-child,
.wiki-content .panelContent div.projectdoc-section-heading4 h4:first-child,
.wiki-content .panelContent div.projectdoc-section-heading5 h5:first-child,
.wiki-content .panelContent div.projectdoc-section-heading6 h6:first-child {
  margin-top: 0;
}
