/* variables: containers, margins, colors */
:root {
  --max-width: 1360px;
  --header-height: 82px;

  --default-padding: 24px;
  --half-padding: 12px;
  --double-padding: 48px;
  
  --marine-200: #b7c3d0;
  --marine-400: #4d6c8b;
  --marine-500: #0f3862;
  --marine-600: #0c2d4e;
  --sand-50: #fff5e8;
  --sand-100: #ffe9ce;
  --sand-200: #ffdaab;
  --sand-500: #ffb75d;
  --sand-700: #7a531d;
  --sand-800: #442e10;
  --white: #ffffff;
  --error: #a32b2b;
  --error-bg:#a32b2b99;
  --success: #2f6b4f;
  --success-bg:#2f6b4f99;
}

.primary-text {
  color: var(--marine-500);
  background: var(--white);
}
.secondary-text {
  color: var(--marine-400);
  background: var(--white);
}
.reverse-text {
  color: var(--white);
  background: var(--marine-500);
}
.reverse-featured-text {
  color: var(--sand-500);
  background: var(--marine-500);
}
.primary-action {
  color: var(--white);
  background: var(--marine-500);
}
.primary-action:hover {
  color: var(--white);
  background: var(--marine-600);
}
.secondary-action {
  color: var(--marine-500);
  background: var(--sand-500);
}
.secondary-action:hover {
  color: var(--white);
  background: var(--sand-700);
}
.secondary-action:active {
  color: var(--white);
  background: var(--sand-800);
}

.picture-action {
  color: var(--white);
  background: var(--charcoal-500);
}

.primary-action:disabled, .secondary-action:disabled {
  color: var(--sand-700);
  background: var(--sand-100);
}

.error {
  color: var(--error);
  background: var(--error-bg);
}
.success {
  color: var(--success);
  background: var(--success-bg);
}

/* ***** */
/* RESET */
/* ***** */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

body {
  margin: 0;
}

ul,
li {
  list-style: none;
}

a,
a:visited,
a:hover {
  text-decoration: none;
}

/* ****** */
/* COMMON */
/* ****** */
main {
  margin: auto;
}

input, textarea, select {
  color: var(--marine-500);
  background: var(--white);
  padding: 9px 12px;
  border: 1px solid var(--sand-500);
}

/* Display */
.display, .display > p {
  font-family: "Libre Baskerville", serif;
  font-size: 32px;
  font-weight: 400;
  line-height: 110%;
  letter-spacing: 0;
  display: inline-block;
}

/* h1 */
h1, .h1 {
  font-family: "Libre Baskerville", serif;
  font-size: 24px;
  font-weight: 400;
  line-height: 125%;
  letter-spacing: 0;
}

/* h2 */
h2, .h2 {
  font-family: "Libre Baskerville", serif;
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  font-weight: 400;
  line-height: 125%;
}

/* h3 */
h3, .h3 {
  font-family: "Libre Baskerville", serif;
  font-size: 16px;
  letter-spacing: 0.96px;
  font-weight: 500;
  line-height: 145%;
  text-transform: uppercase;
  margin-bottom: 8px;
}

/* h4 */
h4, .h4 {
  font-family: "Libre Baskerville", serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 145%;
  letter-spacing: 0;
}

/* citation */
q, q > p, address {
  font-family: "Libre Baskerville", serif;
  font-size: 26px;
  font-weight: 500;
  line-height: 160%;
  letter-spacing: 0;
  display: inherit;
  text-align: center;
}

q > p {
  display: inline;
}

/* corps 1 */
body {
  font-family: "Montserrat", sans-serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 165%;
  letter-spacing: 0;
  color: var(--marine-500);
}

/* corps 2 */
p {
  font-variation-settings: "wdth" 100;
  font-family: "Montserrat", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 160%;
  letter-spacing: 0;
  max-width: calc(var(--max-width) / 2);
}

/* Annotation */
small, label {
  font-family: "Montserrat", sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 145%;
  letter-spacing: 0;
}

/* ETIQUETTE */
a {
  font-family: "Libre Baskerville", serif;
  font-size: 14px;
  letter-spacing: 1.12px;
  font-weight: 400;
  line-height: 100%;
  color: var(--marine-500);
  cursor: pointer;
}

.button, button {
  font-family: "Libre Baskerville", serif;
  text-transform: uppercase;
  padding: 18px 38px;
  border: none;
  text-align: center;
  margin: auto;
  cursor: pointer;
  min-width: max-content;
  display: block;
}

@media (max-width: 600px) {
  q + address {
    margin-top: var(--default-padding);
  }
  .button, button {
    width: 100%;
  }
}

@media (min-width: 600px) {
  /* Display */
  .display, .display > p {
    font-size: 48px;
  }
  
  /* h1 */
  h1, .h1 {
    font-size: 32px;
  }

  h1 + section > p {
    max-width: calc(var(--max-width) * 2/3);
    margin: auto;
  }

  /* h2 */
  h2, .h2 {
    font-size: 24px;
    letter-spacing: 0;
    text-transform: unset;
  }
  
  /* h3 */
  h3, .h3 {
    font-size: 18px;
    letter-spacing: 1.08px;
  }

  /* citation */
  q, q > p {
    font-size: 32px;
  }
  q {
    display: inline-block;
    margin: 0 var(--double-padding);
  }
  address {
    display: block;
    font-size: 32px;
    margin: 0 var(--double-padding);
    text-align: right;
  }

  /* ETIQUETTE */
  a {
    font-size: 14px;
    letter-spacing: 1.12px;
  }
}

main > section {
  padding: var(--default-padding) max(var(--default-padding), calc(calc(100vw - var(--max-width)) / 2));
  margin: auto;
}

img {
  max-width: 100%;
  display: block;
}

img.captcha {
  width: 100px;
}

/* carousel */
.carousel {
  display: flex;
  overflow-x: scroll;
  scroll-snap-type: x mandatory;
  align-items: stretch;
  scrollbar-color: transparent transparent;
}

.carousel > * {
  flex: 0 0 100%;
  scroll-snap-align: start;
}

.prev, .next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  line-height: 50px;
  text-align: center;
  color: var(--sand-500);
  border: 1px solid var(--sand-500);
  cursor: pointer;
}

.bullets {
  margin: var(--half-padding) 0;
  display: flex;
  gap: 3px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.bullets span {
  display: inline-block;
  box-sizing: content-box;
  width: 24px;
  height: 3px;
  background-color: var(--sand-500);
}

.bullets span.active {
  background-color: var(--marine-500);
}

/* shouldn't be here but it's ok */
.cookies {
  max-width: var(--max-width);
  margin: auto;
}

/* ****** */
/* HEADER */
/* ****** */
body > header {
  background-color: var(--marine-500);
  color: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  height: min-content;
  position: sticky;
  top: 0px;
  z-index: 10;
}

body > header nav ul {
  flex-direction: column;
  align-items: flex-start;
  width: calc(100vw - var(--double-padding));
  gap: 0;
}

#hamburger-toggle {
  display: inline;
}
#hamburger-menu {
  flex-direction: column;
  height: 0;
  overflow: hidden;
  transition: 1s height;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-grow: 2;
}

#hamburger-menu.visible {
  height: calc(100vh - var(--header-height));
}

body > header a {
  color: var(--white);
}

body > header a.active {
  color: var(--sand-500);
}
body > header a.active:before {
  content: "→";
}

@media (max-width: 600px) {
  body > header nav:first-child {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 var(--default-padding);
  }
  body > header figure {
    height: 40px;
    font-size: 9px;
  }
  body > header figure img {
    height: 40px;
  }
  
  body > header nav:first-child {
    padding: var(--half-padding) var(--default-padding);
    border-bottom: 1px solid var(--white);
    width: 100vw;
  }
  body > header nav ul {
    padding-top: var(--half-padding);
  }
  body > header nav ul li {
    border-bottom: 1px solid var(--white);
    width: 100%;
    padding: var(--default-padding) 0 var(--half-padding) 0;
  }
  #hamburger-menu .button {
    margin: var(--default-padding) 0;
  }
}

@media (min-width: 600px) {
  body > header {
    width: 100%;
    flex-direction: row;
    min-height: var(--header-height);
    padding: 0 max(var(--default-padding), calc(calc(100vw - var(--max-width)) / 2));
    gap: 80px;
    border-bottom: 1px solid var(--white);
  }

  /* body > header figure img { */
  /*   height: var(--header-height); */
  /* } */

  body > header nav ul {
    display: flex;
    flex-direction: row;
    gap: 40px;
  }
  #hamburger-menu {
    height: unset;
    flex-direction: row;
  }
  #hamburger-toggle {
    display: none;
  }
}

.cards {
  clear: left;
  background: var(--marine-500);
  color: var(--sand-500);
}

.cards h2 {
  margin-bottom: var(--half-padding);
}

.cards li {
  border: 1px solid var(--sand-200);
  padding: var(--default-padding);
  margin-bottom: var(--half-padding);
  text-align: center;
}

.cards li .h3 {
  display: block;
  margin-bottom: var(--half-padding);
}

.cards li a {
  color: var(--sand-500);
  cursor: pointer;
}

.cards li img {
  margin: 0px auto var(--half-padding) auto;
  height: 60px;
  display: block;
}

@media (min-width: 600px) {
  .cards {
    max-width: unset;
    padding: var(--default-padding) max(var(--default-padding), calc(calc(100vw - var(--max-width)) / 2));
  }
  .cards ul {
    display: flex;
    flex-wrap: nowrap;
    gap: var(--half-padding);
  }
  .cards ul li {
    flex: 1 0 0;
  }
}

/* ****** */
/* FOOTER */
/* ****** */
.logo {
  display: flex;
  text-transform: uppercase;
  align-items: flex-end;
  gap: var(--half-padding);
}
.logo p {
  font-weight: 500;
  text-align: center;
}
.logo p:last-child {
  font-size: 18px;
}

body > footer {
  width: 100%;
  padding: var(--default-padding) max(var(--default-padding), calc(calc(100vw - var(--max-width)) / 2));
  background-color: var(--marine-500);
  color: var(--white);
  font-family: "Libre Baskerville", serif;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}

/* logo */
body > footer img {
  height: 90px;
}

/* nl */
body > footer form {
  margin: var(--half-padding) 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

body > footer input, body > footer textarea {
  color: var(--marine-200);
  background: var(--marine-500);
}

body > footer button {
  width: 100%;
}

/* sitemap */
body > footer ul {
  column-count: 2;
}

body > footer a {
  color: var(--sand-500);
  text-transform: none;
}
/* social networks */
body > footer svg {
  width: 24px;
  margin: var(--half-padding);
  margin-left: 0;
}

@media (max-width: 600px) {
  body > footer {
    flex-direction: column;
    width: 100%;
    padding: var(--default-padding);
  }

  body > footer section {
    border-bottom: 1px solid var(--sand-500);
    margin-bottom: var(--default-padding);
    padding-bottom: var(--half-padding);
  }

  body > footer section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
  }
}
