/* Crowd Zero - static copy of crowdzero.co
   Breakpoints follow the original site: 768, 1024, 1280 and 1536 px. */

/* ---------- Fonts (self-hosted, SIL Open Font License 1.1, see assets/fonts) ---------- */

@font-face {
  font-family: "Karla";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/karla-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Karla";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/karla-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Old Standard TT";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/old-standard-tt-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Old Standard TT";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/old-standard-tt-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Old Standard TT";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/old-standard-tt-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Old Standard TT";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/old-standard-tt-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */

:root {
  --serif: "Old Standard TT", serif;
  --sans: "Karla", sans-serif;

  --ink: rgb(27, 27, 27);
  --ink-input: rgb(21, 21, 21);
  --dark: rgb(22, 22, 22);
  --paper: rgb(255, 255, 255);
  --line: rgb(115, 115, 115);
  --field-hover: rgb(246, 246, 246);
  --link: rgb(33, 130, 138);
  --link-hover: rgb(13, 78, 84);
  --link-active: rgb(6, 54, 58);
  --label-focus: rgb(25, 125, 133);
  --error: rgb(239, 0, 0);
  --footer-text: rgb(247, 247, 247);

  /* Type sizes. The original site steps them up at 1536 px. */
  --fs-body: 16px;
  --fs-heading: 22px;
  --fs-lead: 22px;
  --fs-title: 35px;
  --fs-button: 14px;
  --fs-button-small: 12px;
  --fs-footer: 14px;
  --fs-float-label: 12px;

  --container: 100%;
  --gutter: 24px;
}

@media (min-width: 768px) {
  :root { --fs-title: 42px; }
}
@media (min-width: 1024px) {
  :root { --container: 984px; --gutter: 56px; }
}
@media (min-width: 1280px) {
  :root { --container: 1160px; --fs-title: 54px; }
}
@media (min-width: 1536px) {
  :root {
    --container: 1280px;
    --fs-body: 18px;
    --fs-heading: 24px;
    --fs-lead: 24px;
    --fs-title: 56px;
    --fs-button: 16px;
    --fs-button-small: 14px;
    --fs-footer: 16px;
    --fs-float-label: 14px;
  }
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: var(--fs-body);
  font-weight: 400;
  line-height: 1.5;
  overflow-wrap: break-word;
}

a {
  color: var(--link);
  text-decoration: none;
}
a:hover { color: var(--link-hover); }
a:active { color: var(--link-active); }

.container {
  width: var(--container);
  max-width: 100%;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.heading {
  margin: 0 0 24px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: var(--fs-heading);
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: 2px;
}

.text {
  margin: 0 0 24px;
  line-height: 1.5;
}

/* ---------- Buttons ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 56px;
  padding: 8px 40px;
  border: 2px solid currentColor;
  border-radius: 48px;
  background-color: transparent;
  font-family: var(--sans);
  font-size: var(--fs-button);
  font-weight: 700;
  line-height: normal;
  letter-spacing: 2px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.3s ease-in-out;
}

.button--on-dark,
.button--on-dark:active { color: rgb(255, 255, 255); }
.button--on-dark:hover {
  color: rgb(0, 0, 0);
  background-color: rgb(255, 255, 255);
  border-color: rgb(255, 255, 255);
}

.button--on-light,
.button--on-light:active,
.button--map,
.button--map:active { color: var(--ink); }
.button--on-light:hover,
.button--map:hover {
  color: rgb(255, 255, 255);
  background-color: rgb(0, 0, 0);
  border-color: rgb(0, 0, 0);
}

/* ---------- Hero ---------- */

.hero {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 600px;
  background-color: var(--dark);
  background-image:
    linear-gradient(rgba(22, 22, 22, 0.25), rgba(22, 22, 22, 0.25)),
    url("../img/hero.jpg");
  background-position: center center;
  background-size: auto, cover;
  background-repeat: no-repeat;
  color: rgb(255, 255, 255);
}

.hero__container {
  width: 100%;
  padding: 0 32px;
}

.hero__content {
  padding: 40px 0;
}

.hero__title {
  margin: 0;
  font-family: var(--sans);
  font-size: var(--fs-title);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 2px;
}

.hero__lead {
  margin: 0 0 24px;
  font-size: var(--fs-lead);
  line-height: 1.5;
  letter-spacing: 2px;
}

@media (min-width: 768px) {
  .hero__title { letter-spacing: 4px; }
}

@media (min-width: 1024px) {
  .hero {
    min-height: 85vh;
    padding-top: 56px;
  }
  .hero__container {
    width: var(--container);
    max-width: 85%;
    margin: 0 auto;
    padding: 0 24px;
  }
  .hero__content {
    width: 85%;
    padding: 72px 0;
  }
  .hero__title { margin-bottom: 16px; }
}

/* ---------- Contact ---------- */

/* The original page has an empty white band between the hero and this section
   (80 px on phones, 200 px from 768 px). It is part of the top padding here. */
.contact {
  padding-top: 120px;
  background: var(--paper);
}

.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  scroll-margin-top: 40px;   /* where "Ponte en contacto" stops */
}

.contact__info {
  margin-top: 40px;
  text-align: center;
}

.heading--form { text-align: center; }

@media (min-width: 768px) {
  .contact { padding-top: 300px; }
  .contact__grid { scroll-margin-top: 100px; }
  .contact__info { text-align: left; }
  .heading--form { text-align: left; }
}

@media (min-width: 1024px) {
  .contact__grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    column-gap: 48px;
  }
  .contact__info { margin-top: 0; }
}

/* Form */

.field {
  padding-bottom: 24px;
}

.field__float {
  position: relative;
}

.field input,
.field textarea {
  display: block;
  width: 100%;
  margin: 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background-color: transparent;
  color: var(--ink-input);
  font: inherit;
  font-size: var(--fs-body);
}

.field input {
  padding: 23px 8px 8px;
  line-height: normal;
}

.field textarea {
  padding: 8px;
  line-height: 1.75;
  resize: vertical;
}

.field--message {
  padding-bottom: 30px;
}

.field input:hover,
.field input:focus,
.field textarea:hover,
.field textarea:focus {
  outline: none;
  box-shadow: none;
  background-color: var(--field-hover);
}

.field textarea::placeholder {
  color: inherit;
  opacity: 1;
}

.field label {
  position: absolute;
  top: 30%;
  left: 8px;
  color: var(--ink);
  line-height: normal;
  pointer-events: none;
  transition: 0.15s;
}

.field input:focus + label,
.field input:not(:placeholder-shown) + label {
  top: 8px;
  color: var(--label-focus);
  font-size: var(--fs-float-label);
}

.field__error {
  margin: 4px 0 0;
  color: var(--error);
  line-height: 1.5;
}

.field--submit {
  text-align: center;
}

.form__fallback {
  margin: 0 0 24px;
  text-align: center;
}

@media (min-width: 768px) {
  .button--submit { width: 100%; }
}

/* Visit us */

/* Bottom margins of the last element in a block merge with the block's own 40 px. */
.info-block {
  margin-bottom: 40px;
}
.info-block--last {
  margin-bottom: 0;
}

.intro {
  margin: 0;
  line-height: 1.8;
}

.whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 88%;
  min-height: 56px;
  margin-bottom: 40px;
  padding: 8px 16px;
  border-radius: 48px;
  background-color: rgb(69, 90, 100);
  color: rgb(255, 255, 255);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: normal;
  text-align: center;
  transition: background-color 0.3s ease-in-out;
}
.whatsapp:hover {
  background-color: rgb(79, 102, 114);
  color: rgb(255, 255, 255);
}
.whatsapp:active {
  background-color: rgb(69, 90, 100);
  color: rgb(255, 255, 255);
}
.whatsapp__inner {
  position: relative;
  display: block;
  margin-left: -8px;
}
.whatsapp__icon {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}
.whatsapp__text {
  display: block;
  margin-left: 32px;
}

@media (min-width: 768px) {
  .whatsapp { padding: 8px 40px; }
}

/* Opening hours */

.hours {
  min-height: calc(1.5em + 7px);
  margin-bottom: 24px;
  line-height: 1.5;
}

.hours__summary {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 1px;
  border: 0;
  background: none;
  color: var(--ink);
  font: inherit;
  line-height: 1.5;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}
.hours__summary[hidden] { display: none; }

.hours__value {
  margin-left: 6px;
  color: var(--link);
}
.hours__summary:hover .hours__value { color: var(--link-hover); }

.hours__chevron {
  flex: none;
  margin: 4px 0 0 6px;
  color: var(--link);
}

.hours__week {
  display: inline-table;
  border-spacing: 0;
  text-align: left;
  vertical-align: top;
}
.hours__week[hidden] { display: none; }

.hours__week th,
.hours__week td {
  padding: 1px;
  font-weight: 400;
  line-height: 1.5;
  white-space: nowrap;
}
.hours__week td {
  padding-left: 5px;
}
.hours__week .is-today th,
.hours__week .is-today td {
  font-weight: 700;
}

/* Added by the script: the first line closes the list again. */
.hours__week .hours__close {
  padding-left: 5px;
}
.hours__week tr.is-toggle {
  cursor: pointer;
}
.hours__close .hours__chevron {
  display: block;
  margin: 4px 0 0;
  transform: rotate(180deg);
}

/* ---------- Map ---------- */

.map {
  position: relative;
  margin-top: 40px;
  padding-bottom: 30%;
  overflow: hidden;
  background: rgb(170, 211, 223);
}

.map__image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: none;            /* natural size, centred on the pin, like a fixed-zoom map */
  object-position: center center;
}

.button--map {
  position: absolute;
  top: 8px;
  left: 8px;
  max-width: 90%;
  min-height: 40px;
  padding: 4px 24px;
  background-color: rgb(255, 255, 255);
  font-size: var(--fs-button-small);
}
.button__inner {
  position: relative;
  display: block;
  margin-left: -4px;
}
.button__icon {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}
.button__text {
  display: block;
  margin-left: 26px;
}

.map__credit {
  position: absolute;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 1px 6px;
  background: rgba(255, 255, 255, 0.75);
  color: rgb(60, 60, 60);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 10px;
  line-height: 14px;
}
.map__credit a { color: inherit; }

@media (max-width: 767px) {
  .map { min-height: 200px; }
}
@media (min-width: 768px) {
  .button--map {
    left: 56px;
    max-width: 100%;
  }
}
@media (min-width: 2561px) {
  .map__image { object-fit: cover; }
}

/* ---------- Footer ---------- */

.footer {
  padding: 40px 0;
  background: var(--dark);
}

.footer__container {
  padding: 0 24px;
}

.footer__text {
  margin: 0;
  color: var(--footer-text);
  font-size: var(--fs-footer);
  line-height: 1.5;
  text-align: center;
}

@media (min-width: 768px) {
  .footer { padding: 32px 0; }
}
@media (min-width: 1024px) {
  .footer__container { padding: 0 56px; }
}
