@import url('https://fonts.googleapis.com/css2?family=Crimson+Text:ital,wght@0,400;0,600;0,700;1,400;1,600;1,700&family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap');

@import url('https://fonts.googleapis.com/css2?family=Cardo:ital,wght@0,400;0,700;1,400&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Atkinson+Hyperlegible:ital,wght@0,400;0,700;1,400;1,700&family=Crimson+Pro:ital,wght@0,200..900;1,200..900&family=Urbanist:ital,wght@0,100..900;1,100..900&family=Victor+Mono:ital,wght@0,100..700;1,100..700&display=swap');
@import url('https://fonts.cdnfonts.com/css/opendyslexic');

:root {
  --font-base: "Crimson Text", Georgia, serif;
  --font-heading: "Playfair Display", Georgia, serif;

  --font-size-base: 18px;
  --line-height-base: 24px;

  --color-background: #FFFFFF;
  --color-background-2: #FAFAFA;

  --color-text: #003153 ; /*#1A1A1A;*/
  --color-heading: #A67D03;
  --color-accent: #A50000; /*#6B2F2F;*/
  --color-faded: black;
  --color-link: #A67D03; /*#2E4A6B;*/
  --scale-ratio: 1.25;
  --color-hover: #A50000; /*#1A3550; #4A6B52; (pour la nav)*/
  --width-border:0.1em;
  --type-border:solid;
  --color-border: black; /*#E0E0E0;*/

  --color-border-light: #F0F0F0;

  --color-shadow: rgba(0, 0, 0, 0.08);
  --color-shadow-strong: rgba(0, 0, 0, 0.15);

  --radius: 8px;
  --easing: cubic-bezier(.2, .7, .2, 1);
}

body,
html {
  height: fit-content;
  font-family: var(--font-base);
  background: var(--color-background);
  color: var(--color-text);
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  -webkit-font-smoothing: antialiased;
  text-align: justify;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 0.5rem 0;
  font-family: var(--font-heading);
  color: var(--color-accent);
  letter-spacing: 0.01em;
  grid-column: 1/-1;
}

h1 {
  font-size: 42px;
  line-height: 65px;
}

h2 {
  font-size: 33px;
  line-height: 52px;
}

h2 small {
  font-size: 26px;
}

h3 {
  font-size: 26px;
  line-height: 41px;
}

h4 {
  font-size: 20px;
  line-height: 33px;
}

h5 {
  font-size: var(--font-base);
  line-height: var(--line-height-base);
}

h6 {
  font-size: 13px;
  line-height: 23px;
}

small {
  font-size: 13px;
}

.smallcaps {
  font-variant: small-caps;
}

a {
  text-decoration: none;
  color: var(--color-link);
  transition: color 0.2s ease;
}

a:hover {
  color: var(--color-hover);
}



.card {
  background: var(--color-background-2);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: 0 2px 8px var(--color-shadow);
  border: 1px solid var(--color-border-light);
  text-align: center;
}

section.hero{
  display: flex;
  align-items: end;
  padding: 1em;
  margin-bottom: 2em;
}

section.hero h1 {
  color: var(--color-background);
}

.card h3 {
  color: var(--color-background)
}

#startpageheader.hero {
  position: relative;
  height: 100vh;
  /*background: url('https://gallica.bnf.fr/iiif/ark:/12148/btv1b8427253m/f56/780,1300,2805,2000/full/0/native.jpg') center center / cover no-repeat;*/
  /*background: url('https://gallica.bnf.fr/iiif/ark:/12148/btv1b8427253m/f56/1120,1300,2180,1500/full/0/native.jpg') center center / cover no-repeat;*/
  background-image:
    linear-gradient(to bottom right, rgba(117, 35, 45, 0.8), rgba(222, 196, 150, 0.6)),
    url('https://gallica.bnf.fr/iiif/ark:/12148/btv1b8427253m/f56/1120,1300,2180,1500/full/0/native.jpg');
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-bottom: 5em;
}

#startpageheader .hero-content {
  position: relative;
  z-index: 2;
  max-width: 90%;
}

#startpageheader .hero-ref {
  position: absolute;
  z-index: 2;
  bottom: 1em;
  right: 1em;
}

#startpageheader.hero h1 {
  color: var(--color-background);
  font-size: 3rem;
  margin-bottom: 0.5em;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#startpageheader.hero p {
  font-size: 1.2rem;
  color: var(--color-background);
}

.hero {
  color: var(--color-background);
}

header:has(>.navigation) {
  background-color: var(--color-background);
  padding: 1em 2em;
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  box-shadow: 0 2px 8px var(--color-shadow);
  border-bottom: 1px solid var(--color-border);
  z-index: 100;
  margin-bottom: 2em;
}

.navigation #menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  /*justify-content: space-between;*/
  gap: 3em;
}

.navigation #menu .param {
  margin-left: auto;
}

.navigation #menu span {
  cursor: pointer;
  font-size: 2em;
}

.navigation nav,
.navigation #menuParam {
  height: 100%;
  width: 0;
  position: fixed;
  z-index: 2;
  top: 0;
  background-color: var(--color-background-2);
  overflow-x: hidden;
  transition: 0.5s;
  padding-top: 60px;
  text-align: left;
}

.navigation nav {
  left: 0;
}

.navigation #menuParam {
  right: 0;
}

.navigation nav li {
  color: var(--color-link);
  display: block;
}

.navigation nav a:hover {
  color: var(--color-hover);
}

.navigation nav .closebtn {
  position: absolute;
  top: 1em;
  right: 1em;
  font-size: 36px;
  margin-left: 50px;
}

#sidenav > ul {
  padding: 3em;
  font-size: 1.5em;
}

#sidenav > ul > li {
  margin-bottom: 1em;
}

#sidenav > ul > li > ul {
  padding-left: 1em;
}


main {
  margin: auto;
  /*width: 60ch;*/
  width: 920px;
}

main#text {
  padding: 0 3em;
  width: 100%;

}

article.article {
  margin: auto;
  width: 60ch;
}

footer {
  display: flex;
  flex-direction: column;
  gap: 1em;
  padding: 2rem 1rem;
  margin-top: 5em;
  min-height: 10em;
  background: linear-gradient(135deg, var(--color-accent) 0%, #4A1F1F 100%);
  color: var(--color-background);
}

footer>ul {
  display: grid;
  list-style: none;
  padding-left: 0;
  grid-template-columns: 1fr 1fr 3fr;
}

footer>ul>li {
  justify-self: center;
}

footer .licence img {
  width: 117px;
  height: 41px;
}

.partners {
  padding: 2rem 1rem;
  background-color: var(--color-background);
  border-top: 1px solid var(--color-border);
  display: flex;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 1.5rem;
  align-items: center;
  /*justify-items: center;*/
  max-width: 1200px;
  margin: 0 auto;
}

.partners img {
  max-width: 100%;
  max-height: 60px;
  object-fit: contain;
  filter: grayscale(100%);
  transition: filter 0.3s ease;
}

.partners img:hover {
  filter: grayscale(0%);
}

article {
  margin: 1em 0 2em;
}

.frontmatter {
  text-align: center;
  margin-bottom: 1em;
}

.frontmatter h2 {
  text-align: center;
}

span.verse {
  display: block;
}

.lettrine {
  font-size: 3em;
  color: var(--color-accent);
  font-size: 3.2em;
  line-height: 1;
  display: inline-block;
}

.reg {
  background-color: rgba(46, 74, 107, 0.15);
  padding: 0 2px;
  border-radius: 2px;
}

.expan {
  background-color: rgba(201, 169, 97, 0.2);
  padding: 0 2px;
  border-radius: 2px;
}

.choice {
  position: relative;
  display: inline-block;
}

.choice .orig, .choice .abbr {
  visibility: hidden;
  opacity: 0;
  background-color: var(--color-text);
  color: var(--color-background);
  text-align: center;
  border-radius: 6px;
  padding: 4px 8px;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  /* au-dessus du mot */
  left: 50%;
  transform: translateX(-50%);
  transition: opacity 0.2s;
  white-space: nowrap;
  font-size: 0.85em;
}

.gloss .choice .orig, .choice .abbr {
    transform: translateX(-25%);
}

/* Petite flèche du tooltip */
.choice .orig::after,
.choice .abbr::after {
  content: "";
  position: absolute;
  top: 100%;
  /* sous le tooltip */
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: var(--color-text) transparent transparent transparent;
}

/* Affiche le tooltip au survol de .reg */
.choice:has(.reg:hover) .orig,
.choice:has(.expan:hover) .abbr {
  visibility: visible;
  opacity: 1;
}

.switch {
  display: inline-block;
  position: relative;
  width: 80px;
  height: 30px;
  margin-bottom: 1em;
}

.switch input {
  display: none;
}

.slider {
  background-color: var(--color-border);
  border-radius: 15px;
  cursor: pointer;
  position: relative;
  width: 100%;
  height: 100%;
  transition: background-color 0.3s;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  font-size: 14px;
  font-family: sans-serif;
  color: var(--color-background);
}

.slider::before {
  content: "";
  position: absolute;
  width: 26px;
  height: 26px;
  background-color: var(--color-background);
  border-radius: 50%;
  top: 2px;
  left: 2px;
  transition: transform 0.3s;
}

/* Move knob when checked */
input:checked+.slider::before {
  transform: translateX(50px);
}

input:checked+.slider {
  background-color: var(--color-hover);
}

.label {
  z-index: 1;
  font-weight: bold;
  color: var(--color-text);
}

.figure {
  margin: 1em 0;
}

main#main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1em;
}

#content {
  display: none;
}

#view {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1em;
}

.presentation {
  margin-bottom: 2em;
}

#osd {
  position: sticky;
  top: 6em;
}

sup {
  font-size: smaller;
  vertical-align: super;
  line-height: 0;
}

@media (max-width: 768px) {
  #startpageheader.hero h1 {
    font-size: 2rem;
  }
}

#epitre {
    line-height: 24px;
}
#smalla {
  font-size: smaller;
}
#biga {
  font-size: large;
}

#smallIl {
  font-size: smaller;
  text-decoration: overline underline;
}
#bigIl {
  font-size: large;
  text-decoration: overline underline;

}
