.site-header.is-at-top {
  background-color: var(--color-primary);
  border-bottom-color: var(--color-secondary);
}

/* –––––––––––– HERO –––––––––––– */

section.hero.booking-hero {
  min-height: 210px;
  padding-block: var(--header-height) 0;

  background-color: rgba(31, 31, 31, 0.34);
  background-blend-mode: multiply;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;

  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

section.hero.booking-hero .container h1 {
  color: var(--color-white);
  font-family: var(--font-playfair);
  font-size: var(--text-2xl);
  font-style: italic;
  font-weight: 800;
  line-height: 1;
}

/* –––––––––––– BOOK –––––––––––– */

section.book {
  padding-block: var(--section-padding);
  background-color: var(--color-white);
  background-image: url("/wp-content/themes/zornica/assets/img/backgrounds/back-gn.svg");
  background-position: top center;
  background-repeat: repeat-x;
  background-size: auto 260px;
}

.book-form {
  color: var(--color-text);
}

.book-fields {
  display: grid;
  gap: 26px;
  max-width: 400px;
  margin-inline: auto;
}

.book-field {
  position: relative;
  display: block;
  min-width: 0;
}

.book-field > input,
.book-field > textarea,
.book-field.dropdown {
  width: 100%;
  min-height: 48px;
  border: 2px solid var(--color-secondary);
  border-radius: 8px;
  background-color: var(--color-white);
  padding: 12px 26px;

  color: var(--color-text);
  font-size: var(--text-md);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.02em;
}

.book-field > textarea {
  min-height: 130px;
  padding-top: 20px;
  resize: vertical;
}

.book-field > input::placeholder,
.book-field > textarea::placeholder {
  color: var(--color-text);
  opacity: 0.78;
}

.book-field--date input {
  padding-right: 60px;
}

.datepick-svg {
  position: absolute;
  top: 50%;
  right: 14px;
  z-index: 2;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 46px;
  height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--color-secondary);

  transform: translateY(-50%);
  cursor: pointer;
}

.book-field .iti {
  width: 100%;
}

.book-field .iti input {
  width: 100%;
  min-height: 48px;
  border: 2px solid var(--color-secondary);
  border-radius: 8px;
  background-color: var(--color-white);
  padding-right: 26px;

  color: var(--color-text);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.book-field .iti__flag-container {
  left: 18px;
}

.book-field .iti--allow-dropdown input,
.book-field .iti--allow-dropdown input[type="tel"] {
  padding-left: 58px;
}

/* Dropdowns */

span.dropdown {
  transform: unset;
}
.dropdown {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-direction: row;
  gap: 1rem;
  cursor: pointer;
  user-select: none;
}

.dropdown > span {
  overflow: hidden;
  color: var(--color-text);
  opacity: 0.78;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dropdown > svg,
.dropdown > img {
  flex: 0 0 auto;
  color: var(--color-primary-soft);
  transition: transform var(--dur-short) var(--ease);
}

.dropdown.active > svg,
.dropdown.active > img {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 20;

  display: grid;
  width: 100%;
  max-height: 220px;
  overflow-y: auto;
  margin: 0;
  padding: 8px 0;

  list-style: none;
  border: 2px solid var(--color-secondary);
  border-radius: 8px;
  background-color: var(--color-white);
  box-shadow: 0 14px 32px rgba(31, 31, 31, 0.12);

  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition:
    opacity var(--dur-short) var(--ease),
    visibility var(--dur-short) var(--ease),
    transform var(--dur-short) var(--ease);
  visibility: hidden;
}

.dropdown.active .dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  visibility: visible;
}

.dropdown-menu li {
  padding: 10px 18px;
  color: var(--color-text);
  font-size: 13px;
  transition:
    background-color var(--dur-short) var(--ease),
    color var(--dur-short) var(--ease);
}

/* First time */

.book-first {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 42px;

  color: var(--color-black);
  font-size: 13px;
}

.book-first strong {
  font-weight: 700;
}

.book-first label,
.book-consent {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.book-first input,
.book-consent input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.book-first label > span,
.book-consent > span {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 28px;
  height: 28px;
  border: 1px solid var(--color-primary-soft);
  border-radius: 8px;
  background-color: var(--color-white);
}

.book-first input:checked + span,
.book-consent input:checked + span {
  background-color: var(--color-primary-soft);
}

.book-first input:checked + span::after,
.book-consent input:checked + span::after {
  content: "";
  width: 14px;
  height: 8px;
  border-bottom: 3px solid var(--color-white);
  border-left: 3px solid var(--color-white);
  transform: rotate(-45deg) translate(1px, -1px);
}

/* Rooms */

.booking-rooms {
  margin-top: 4rem;
}

.booking-rooms h2,
.booking-extra h2 {
  color: var(--color-text);
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1.2;
}

.booking-rooms h2 {
  margin-bottom: 36px;
}

.booking-rooms__slider-wrap {
  position: relative;
}

.booking-rooms__swiper {
  height: auto;
  overflow: hidden;
  padding-bottom: 6px;
}

.booking-rooms__swiper .swiper-wrapper {
  align-items: stretch;
}

.booking-rooms__swiper .swiper-slide {
  height: auto;
}

.booking-room {
  display: flex;
  flex-direction: column;
  max-width: 415px;
  min-height: 560px;
  height: 100%;
  overflow: hidden;
  margin-inline: auto;

  border: 1px solid rgba(223, 206, 178, 0.45);
  border-radius: 7px;
  background-color: var(--color-white);
  box-shadow: 0 4px 8px rgba(181, 116, 111, 0.16);
}

.booking-room__head {
  position: relative;
  height: 138px;
  overflow: hidden;
}

.booking-room__head::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(31, 31, 31, 0.08), rgba(31, 31, 31, 0.48));
}

.booking-room__head img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.booking-room__head h3 {
  position: absolute;
  left: 24px;
  bottom: 18px;
  z-index: 1;

  max-width: 240px;
  color: var(--color-white);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.12;
}

.booking-room__body {
  display: grid;
  grid-template-columns: 1fr;
  row-gap: 2rem;
  grid-template-rows: min-content min-content;
  flex: 1;
  padding: 24px 22px 12px;
}

.booking-room__info {
  padding-right: 18px;
}

.booking-room__comforts {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  min-height: 29px;
  margin-bottom: 1rem;

  color: var(--color-primary-soft);
}

.booking-room__comforts svg {
  display: block;
  width: 23px;
  height: 23px;
}

.booking-room__comforts svg[viewBox="0 0 28 38"] {
  width: 20px;
  height: 30px;
}

.booking-room__info p {
  max-width: 270px;
  color: var(--color-text);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: 0.02em;
}

.booking-room__capacity {
  padding-left: 14px;
  border-left: 2px solid var(--color-secondary);
}

.booking-room__capacity span {
  display: block;
  margin-bottom: 12px;
  color: var(--color-text);
  font-size: 14px;
  font-weight: 600;
}

.booking-room__capacity div {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  color: var(--color-secondary);
}

.booking-room__foot {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 100px;
  align-items: center;
  gap: 16px;
  padding: 12px 22px 28px;
}

.booking-room__foot p {
  color: var(--color-text);
  font-size: 13px;
  font-weight: 600;
  line-height: 0.95;
}

.booking-room__foot p b {
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.05em;
}

.booking-room__foot p small {
  display: block;
  margin-top: 6px;
  color: var(--color-text);
  font-size: 10px;
  font-weight: 400;
  line-height: 1.2;
  opacity: 0.75;
}

.booking-room__choose {
  min-height: 38px;
  border: 0;
  border-radius: 7px;
  background-color: var(--color-primary-soft);
  color: var(--color-white);
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  transition:
    background-color var(--dur-short) var(--ease),
    color var(--dur-short) var(--ease);
}

.booking-room.is-selected .booking-room__choose {
  background-color: var(--color-secondary);
  color: var(--color-primary);
}

.booking-rooms__arrow {
  position: absolute;
  top: 52%;
  z-index: 5;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;

  border: 1px solid var(--color-primary-soft);
  border-radius: 50%;
  background-color: var(--color-white);
  color: var(--color-primary-soft);

  transform: translateY(-50%);
  cursor: pointer;
  transition:
    background-color var(--dur-short) var(--ease),
    color var(--dur-short) var(--ease);
}

.booking-rooms__arrow--prev {
  left: -0.5rem;
}

.booking-rooms__arrow--next {
  right: -0.5rem;
}

/* Additionally */

.booking-extra {
  margin-top: 4rem;
}

.booking-extra h2 {
  margin-bottom: 42px;
}

.booking-extra__grid {
  display: grid;
  gap: 42px;
}

.booking-extra__contacts {
  display: grid;
  gap: 26px;
  max-width: 400px;
  width: 100%;
  margin-inline: auto;
}

.booking-extra__options {
  display: grid;
  gap: 20px;
  width: 100%;
  margin-inline: auto;
}

.booking-extra__option {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 18px;
  min-width: 0;

  color: var(--color-black);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
}

.booking-mini-select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px 0 18px;
  border: 2px solid var(--color-secondary);
  border-radius: 8px;
  background-color: var(--color-white);
}

.booking-mini-select .dropdown-menu {
  min-width: 88px;
}

.book-consent {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-direction: row;
  gap: 1rem;
  margin-inline: auto;
  max-width: 520px;
  margin: 4rem auto 0;
}

.book-consent > span {
  flex: 0 0 auto;
  width: 21px;
  height: 21px;
  border-radius: 5px;
}

.book-consent input:checked + span::after {
  width: 10px;
  height: 6px;
  border-bottom-width: 2px;
  border-left-width: 2px;
}

.book-consent small {
  max-width: 460px;
  color: var(--color-black);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.25;
}

.book-consent a {
  color: var(--color-primary-soft);
  text-decoration: none;
}

.book-submit {
  display: flex;
  align-items: center;
  justify-content: center;

  width: min(100%, 220px);
  min-height: 58px;
  margin: 4rem auto 0;

  border: 0;
  border-radius: 8px;
  background-color: var(--color-primary-soft);
  color: var(--color-white);
  font-size: 26px;
  font-weight: 700;
  cursor: pointer;
  transition:
    background-color var(--dur-short) var(--ease),
    color var(--dur-short) var(--ease);
}

@media (hover: hover) {
  .dropdown-menu li:hover {
    background-color: var(--color-panel);
    color: var(--color-primary-soft);
  }

  .booking-room__choose:hover,
  .booking-room__choose:focus-visible,
  .booking-rooms__arrow:hover,
  .booking-rooms__arrow:focus-visible,
  .book-submit:hover,
  .book-submit:focus-visible {
    background-color: var(--color-secondary);
    color: var(--color-primary);
  }
}

@media screen and (min-width: 480px) {
  .booking-rooms__arrow--prev {
    left: -1.5rem;
  }

  .booking-rooms__arrow--next {
    right: -1.5rem;
  }

  .booking-room__body {
    grid-template-rows: unset;
    grid-template-columns: minmax(0, 1fr) 116px;
  }
}

@media screen and (min-width: 640px) {
  section.hero.booking-hero {
    min-height: 260px;
    background-position: center 58%;
  }

  section.book {
    background-size: auto 310px;
  }
}

@media screen and (min-width: 768px) {
  .book-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 50px;
    max-width: 736px;
  }

  .book-field--date {
    order: 1;
  }

  .book-field--phone {
    order: 2;
  }

  .book-field--name {
    order: 3;
  }

  .book-field--people {
    order: 4;
  }

  .book-field--children {
    order: 5;
    grid-column: 1 / -1;
    width: calc(50% - 25px);
    justify-self: center;
  }

  .book-field > input,
  .book-field > textarea,
  .book-field.dropdown,
  .book-field .iti input {
    padding-inline: 32px;
  }

  .book-field--date input {
    padding-right: 62px;
  }

  .datepick-svg {
    right: 20px;
  }

  .book-field .iti--allow-dropdown input,
  .book-field .iti--allow-dropdown input[type="tel"] {
    padding-left: 64px;
  }

  .book-first {
    margin-top: 48px;
  }

  .book-first label > span {
    width: 32px;
    height: 32px;
  }

  .booking-rooms,
  .booking-extra {
    margin-top: 5rem;
  }

  .booking-rooms h2 {
    margin-bottom: 42px;
  }

  .booking-room__head {
    height: 205px;
  }

  .booking-room__head h3 {
    left: 28px;
    bottom: 20px;
    max-width: 260px;
    font-size: 1.5rem;
  }

  .booking-room__body {
    grid-template-columns: minmax(0, 1fr) 126px;
    padding: 28px 24px 14px;
  }

  .booking-room__info {
    padding-right: 22px;
  }

  .booking-room__comforts {
    gap: 14px;
  }

  .booking-room__comforts svg {
    width: 26px;
    height: 26px;
  }

  .booking-room__info p {
    font-size: 12px;
  }

  .booking-room__foot {
    grid-template-columns: minmax(0, 1fr) 128px;
    padding-inline: 24px;
  }

  .booking-room__foot p b {
    font-size: 27px;
  }

  .booking-room__choose {
    min-height: 40px;
    font-size: 12px;
  }

  .booking-rooms__arrow {
    top: 50%;
    width: 38px;
    height: 38px;
  }

  .booking-rooms__arrow--prev {
    left: -2rem;
  }

  .booking-rooms__arrow--next {
    right: -2rem;
  }

  .booking-extra h2 {
    margin-bottom: 52px;
  }

  .booking-extra__grid {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 0.85fr);
    gap: 52px;
    align-items: start;
  }

  .booking-extra__contacts {
    max-width: none;
  }

  .booking-extra__options {
    width: 100%;
  }

  .booking-extra__option {
    grid-template-columns: minmax(110px, 1fr) auto;
    gap: 16px;
  }

  .book-consent small {
    font-size: 12px;
  }

  .book-submit {
    width: min(100%, 320px);
    min-height: 66px;
    font-size: 30px;
  }
}

@media screen and (min-width: 1024px) {
  section.hero.booking-hero {
    min-height: 320px;
  }

  .book-fields {
    max-width: 860px;
  }

  .booking-room {
    min-height: 565px;
  }

  .booking-room__head {
    height: 230px;
  }

  .booking-room__body {
    grid-template-columns: minmax(0, 1fr) 135px;
    padding: 30px 28px 16px;
  }

  .booking-room__info p {
    font-size: 13px;
  }

  .booking-room__foot {
    grid-template-columns: minmax(0, 1fr) 140px;
    gap: 22px;
    padding: 16px 28px 34px;
  }

  .booking-room__foot p {
    font-size: 15px;
  }

  .booking-room__foot p b {
    font-size: 31px;
  }

  .booking-extra__grid {
    gap: 64px;
  }

  .booking-extra__options {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 40px;
  }
}