/*
 * Leclerc cookie consent banner.
 *
 * Compiled from the Rails site, in the order the rules applied there:
 *   - reset.sass (margins/padding/font-weight/flex on all elements)
 *   - pages/welcome.sass (layout, switches)
 *   - components/cookie_eu.sass + components/phone/cookie_eu.sass
 *   - cookies_eu gem base CSS (loaded last)
 *
 * Everything is scoped under #cookies-eu so WordPress theme styles
 * (buttons, headings, lists, .slider, .hidden...) don't change the look.
 */

#cookies-eu,
#cookies-eu * {
  box-sizing: content-box;
  flex: none;
  margin: 0;
  padding: 0;
  font-weight: normal;
  letter-spacing: normal;
  text-transform: none;
}

#cookies-eu {
  position: fixed;
  z-index: 99999;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: 0 20px;
  border-top: 1px solid #e4e4e4;
  background: #ea1920;
  font-size: 12px;
  line-height: 40px;
  text-align: center;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

#cookies-eu.hidden {
  display: none;
}

#cookies-eu .cookies_consent_col {
  display: flex;
  flex: auto;
  flex-direction: row;
  justify-content: space-around;
  width: 50%;
}

#cookies-eu .cookies-eu-content-holder {
  display: inline-block;
  flex: auto;
  padding: 0 20px;
  color: #fff;
  font-family: Karla, sans-serif;
  font-size: 12px;
  line-height: 20px;
}

#cookies-eu .cookies-eu-link,
#cookies-eu .cookies-eu-link:hover,
#cookies-eu .cookies-eu-link:visited {
  color: #fff;
  font-family: Karla, sans-serif;
  text-decoration: underline;
}

#cookies-eu .cookies-consent-choices {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-around;
  max-width: 500px;
  padding-bottom: 10px;
  text-align: left;
}

#cookies-eu h3.cookies-eu-options {
  color: #fff;
  font-family: Karla, sans-serif;
  font-size: 1.17em;
  line-height: 40px;
  text-align: center;
}

#cookies-eu ul.cookies-eu-options {
  list-style-type: none;
  color: #fff;
  font-family: Karla, sans-serif;
}

#cookies-eu ul.cookies-eu-options li {
  list-style-type: none;
  color: #fff;
  font-size: 12px;
  line-height: 40px;
}

#cookies-eu ul.cookies-eu-options li::before,
#cookies-eu ul.cookies-eu-options li::marker {
  content: none;
}

#cookies-eu .cookie-consent-label {
  display: inline-block;
  min-width: 200px;
}

/* Toggle switches */
#cookies-eu .switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
  vertical-align: baseline;
}

#cookies-eu .switch input {
  position: static;
  width: 0;
  height: 0;
  opacity: 0;
}

#cookies-eu .slider {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  cursor: pointer;
  background-color: #ccc;
  -webkit-transition: .4s;
  transition: .4s;
}

#cookies-eu .slider:before {
  position: absolute;
  content: "";
  left: 4px;
  bottom: 4px;
  width: 26px;
  height: 26px;
  background-color: #fff;
  -webkit-transition: .4s;
  transition: .4s;
}

#cookies-eu input:checked + .slider {
  background-color: #ff5050;
}

#cookies-eu input:focus + .slider {
  box-shadow: 0 0 1px #ff5050;
}

#cookies-eu input:checked + .slider:before {
  -webkit-transform: translateX(26px);
  -ms-transform: translateX(26px);
  transform: translateX(26px);
}

#cookies-eu .slider.round {
  border-radius: 34px;
}

#cookies-eu .slider.round:before {
  border-radius: 50%;
}

/* Buttons: browser-default button font, as on the Rails site */
#cookies-eu .cookies-eu-ok {
  display: inline-block;
  width: auto;
  min-width: 0;
  height: auto;
  padding: 5px 15px;
  border: 0;
  border-radius: 20px;
  box-shadow: none;
  background: #000;
  color: #fff;
  font: 400 13.3333px Arial, sans-serif;
  line-height: normal;
  text-align: center;
  cursor: pointer;
}

#cookies-eu .cookies-eu-ok:hover,
#cookies-eu .cookies-eu-ok:focus {
  background: #000;
  color: #fff;
}

#cookies-eu .cookies-eu-ok:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

@media only screen and (max-width: 767px) {
  #cookies-eu {
    font-size: 12px;
    line-height: 30px;
  }

  #cookies-eu ul.cookies-eu-options li,
  #cookies-eu h3.cookies-eu-options {
    line-height: 30px;
  }
}

@media only screen and (max-width: 720px) {
  #cookies-eu .cookie-consent-label {
    min-width: 100px;
  }

  #cookies-eu #cookie-buttons {
    margin-top: 15px;
  }
}
