:root {
  --vine: #1E3A2B;
  --leaf: #EAF0DC;
  --panel: #F8FAEF;
  --phlox: #A81F66;
  --phlox-dark: #7E154B;
  --apricot: #F3B562;
  --ink: #16261C;
  --muted: #3F5145;
  --rule: #A9B9A0;
  --on-dark: #F4F2E3;
  --line-dark: #4B6655;
  --focus: var(--phlox);
  --serif: Alegreya, Georgia, serif;
  --sans: "Alegreya Sans", "Trebuchet MS", sans-serif;
  --radius: 6px;
  color-scheme: light;
}

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

html { -webkit-text-size-adjust: 100%; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--leaf);
  color: var(--ink);
  font: 400 18px/1.55 var(--sans);
}

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

[hidden] { display: none !important; }

h1, h2, h3, p, ul, dl, dd, figure, blockquote { margin: 0; }

ul { padding: 0; list-style: none; }

a { color: var(--phlox); text-underline-offset: 0.15em; }
a:hover { color: var(--phlox-dark); }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

[id] { scroll-margin-top: 16px; }

.wrap { max-width: 1200px; margin-inline: auto; padding-inline: 24px; }

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 10;
  padding: 10px 16px;
  background: var(--apricot);
  color: var(--ink);
  font-weight: 700;
  border-radius: var(--radius);
}
.skip-link:focus { top: 16px; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Buttons */

.actions { display: flex; flex-wrap: wrap; gap: 12px; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 2px solid transparent;
  border-radius: var(--radius);
  font: 700 18px/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
}
.button--apricot { background: var(--apricot); color: var(--ink); }
.button--apricot:hover { background: #F7C985; color: var(--ink); }
.button--phlox { background: var(--phlox); color: #FFFFFF; }
.button--phlox:hover { background: var(--phlox-dark); color: #FFFFFF; }
.button--outline { background: transparent; border-color: var(--on-dark); color: var(--on-dark); }
.button--outline:hover { background: rgba(244, 242, 227, 0.12); color: var(--on-dark); }

/* Hero: the three houses hang out of the dark band into the page */

.hero {
  --focus: var(--apricot);
  background: var(--vine);
  color: var(--on-dark);
}
.hero a:not(.button) { color: var(--on-dark); }

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-block: 20px;
}
.nav__brand {
  font: 800 21px/1.2 var(--serif);
  text-decoration: none;
}
.nav__links { display: flex; flex-wrap: wrap; gap: 4px 22px; }

.hero__body {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding-top: 40px;
}
.hero__title {
  max-width: 16ch;
  font: 800 clamp(48px, 9vw, 108px)/1 var(--serif);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.hero__lead { max-width: 52ch; font-size: 21px; }

.hero__houses {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  align-items: start;
  margin-top: 24px;
  margin-bottom: -150px;
}
.hero__houses > li:nth-child(2) { margin-top: 88px; }

.house-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-decoration: none;
}
.house-card__head {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-height: 3.6em;
}
.house-card__name { font: 800 28px/1.15 var(--serif); }
.house-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius);
}
.house-card:hover .house-card__name { text-decoration: underline; }

/* Page sections */

.main {
  display: flex;
  flex-direction: column;
  gap: 104px;
  padding-top: 230px;
}
.section { display: flex; flex-direction: column; gap: 24px; }
.section__title { font: 800 clamp(34px, 4.4vw, 46px)/1.1 var(--serif); }

.note { max-width: 70ch; }
.note--strong { font-weight: 700; }

/* Date checker */

.checker {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(190px, 100%), 1fr));
  gap: 16px;
  padding: 24px;
  background: var(--panel);
  border: 2px solid var(--vine);
  border-radius: var(--radius);
}
.checker__result {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.checker__result p { max-width: 62ch; }

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-weight: 700;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 0 12px;
  font: 400 18px/1.4 var(--sans);
  color: var(--ink);
  background: #FFFFFF;
  border: 1px solid #4B5F52;
  border-radius: 4px;
}
.field textarea { padding-block: 10px; resize: vertical; }
.field--dark input,
.field--dark textarea { border-color: transparent; }

/* Houses */

.house {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  align-items: start;
  padding-top: 32px;
  border-top: 2px solid var(--vine);
}
.house--flip .collage { order: 2; }

.collage {
  display: grid;
  grid-template-columns: 3fr 2fr;
  grid-template-rows: 1fr 1fr;
  gap: 12px;
  height: 460px;
}
.collage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius);
}
.collage__main { grid-row: span 2; }

.house__info { display: flex; flex-direction: column; gap: 24px; }
.house__name { font: 800 34px/1.15 var(--serif); }

.room {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 12px 0;
  border-top: 1px solid var(--rule);
}
.room > span:first-child { display: flex; flex-direction: column; }
.room__name { font-weight: 700; }
.room__beds { color: var(--muted); }
.room__price { flex: none; font-weight: 700; text-align: right; }

.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(140px, 100%), 1fr));
  gap: 12px 24px;
}
.facts div:last-child { grid-column: 1 / -1; }
.facts dt { font-weight: 700; }

/* Location */

.places {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: 40px 28px;
}
.place { display: flex; flex-direction: column; gap: 8px; }
.place__map {
  width: 100%;
  height: 240px;
  margin-bottom: 8px;
  border: 0;
  border-radius: var(--radius);
  background: #D5E0C3;
}
.place__map--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}
.place__name { font: 800 28px/1.15 var(--serif); }

/* Reviews */

.reviews {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 48px;
  align-items: center;
}
.reviews__text { display: flex; flex-direction: column; gap: 20px; }
.reviews__text > p { max-width: 56ch; }
.quote { display: flex; flex-direction: column; gap: 10px; }
.quote blockquote {
  color: var(--vine);
  font: 500 clamp(30px, 3.6vw, 44px)/1.2 var(--serif);
}
.reviews__photo { display: flex; flex-direction: column; gap: 8px; }
.reviews__photo img { width: 100%; border-radius: var(--radius); }
.link-row { display: flex; flex-wrap: wrap; gap: 8px 24px; }

/* Contact and footer */

.contact {
  --focus: var(--apricot);
  margin-top: 104px;
  background: var(--vine);
  color: var(--on-dark);
}
.contact a:not(.button) { color: var(--on-dark); }
.contact__body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr));
  gap: 48px;
  padding-block: 72px;
}
.contact__direct {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}
.contact__list { display: flex; flex-direction: column; gap: 6px; }
.contact__list div { display: flex; flex-wrap: wrap; gap: 0 10px; }
.contact__list dt { font-weight: 700; }
.contact__form { display: flex; flex-direction: column; gap: 14px; }
.contact__form .button { align-self: flex-start; }
.contact__status:empty { display: none; }

.footer { border-top: 1px solid var(--line-dark); }
.footer__body {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px 32px;
  padding-block: 24px 104px;
}

.whatsapp-float {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--phlox);
  color: #FFFFFF;
  box-shadow: 0 2px 10px rgba(22, 38, 28, 0.35);
}
.whatsapp-float:hover { background: var(--phlox-dark); color: #FFFFFF; }

/* Phones and small tablets */

@media (max-width: 760px) {
  body { font-size: 17px; }
  .wrap { padding-inline: 16px; }
  .nav__links { font-size: 16px; gap: 4px 18px; }
  .hero__body { padding-top: 16px; gap: 22px; }
  .hero__lead { font-size: 19px; }

  /* The three houses become a row you swipe through */
  .hero__houses {
    display: flex;
    gap: 14px;
    margin-inline: -16px;
    padding: 0 16px 4px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 16px;
    scrollbar-width: none;
    margin-bottom: -110px;
  }
  .hero__houses::-webkit-scrollbar { display: none; }
  .hero__houses > li { flex: 0 0 82%; scroll-snap-align: start; }
  .hero__houses > li:nth-child(2) { margin-top: 0; }
  .house-card__name { font-size: 24px; }

  .main { padding-top: 150px; gap: 80px; }
  .checker { padding: 16px; }
  .house { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .house--flip .collage { order: 0; }
  .collage { height: 320px; }
  .reviews { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .contact { margin-top: 80px; }
  .contact__body { padding-block: 56px; }
}
