/* CSS Variables for colors and common values */
:root {
  --bg-color-light: rgb(244 241 232);
  --bg-color-dark: rgb(118 75 54);
  --border-color-light: rgb(0 0 0 / 7%);
  --subheader-color: rgb(19 19 19);
  --button-bg: rgb(216 167 144);
  --nav-link-color: rgb(48 66 84);

  /* Typography */
  --font-primary: 'Playfair Display', serif;
  --font-system:
    system-ui, -apple-system, blinkmacsystemfont, 'Segoe UI', roboto, oxygen,
    ubuntu, cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;

  /* Spacing */
  --section-padding: 5rem;
  --border-radius-small: 0.5rem;
  --border-radius-medium: 1rem;
  --border-radius-full: 100vh;

  /* Animations */
  --transition-fast: 0.3s ease;
  --transition-medium: 0.4s;

  /* Shadows */
  --shadow-light: 0 4px 8px rgb(0 0 0 / 30%);
  --shadow-medium: 0 1rem 2rem rgb(0 0 0 / 30%);
}

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  top: -9999px;
  left: -9999px;
  z-index: 9999;
  padding: 1rem;
  color: var(--bg-color-light);
  text-decoration: none;
  background: var(--bg-color-dark);
  border-radius: var(--border-radius-small);
}

.skip-link:focus {
  top: 1rem;
  left: 1rem;
}

/* Fade in/out transitions for SPA sections */
.fade-in {
  animation: fade-in 0.4s;
}

.fade-out {
  animation: fade-out 0.4s;
}

.show {
  display: block;
  opacity: 1;
}

.hide {
  display: none;
  opacity: 0;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes fade-out {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

html,
* {
  box-sizing: border-box;
  scroll-behavior: smooth;
}

body {
  padding: 0;
  margin: 0;
  overflow: hidden;
  font-family: var(--font-primary);
  font-size: clamp(12px, 1.2vw, 16px);
}

main {
  position: absolute;
  inset: 3rem 0 0;
  width: 100vw;
  padding: 0;
  overflow-y: auto;
  text-align: center;
}

div {
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
  overflow-wrap: break-word;
}

section {
  padding: var(--section-padding);
}

p {
  line-height: 1.5;
  word-spacing: 0.075rem;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
}

.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  text-align: center;
}

nav {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: right;
  width: 100vw;
  height: 3rem;
  padding: 0 2rem;
  font-size: 1.075rem;
  text-transform: uppercase;
  background-color: var(--bg-color-light);
  border: 1px solid var(--border-color-light);
}

nav #menu-toggle {
  display: none;
  font-size: 2rem;
  color: var(--nav-link-color);
  cursor: pointer;
}

nav ul {
  display: flex;
  gap: 1rem;
  justify-content: space-evenly;
  width: 100%;
  max-width: fit-content;
  padding: 0;
  margin: 0;
  list-style: none;
}

nav li {
  min-width: 5rem;
  padding: 0;
  margin: 0;
}

nav li:last-child {
  min-width: 8rem;
}

nav a {
  margin-inline: auto;
  font-family: var(--font-system);
  color: var(--nav-link-color);
  text-decoration: none;
}

nav a:hover {
  font-weight: bold;
}

nav a.active {
  padding-bottom: 0.1rem;
  font-weight: bold;
  border-bottom: 2px solid var(--nav-link-color);
}

main .content > section {
  position: absolute;
  inset: 0;
  height: 100vh;
  padding: 2rem;
  color: inherit;
  background-color: inherit;
  opacity: 1;
  transition: opacity 0.4s;
}

.footer {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1.125rem;
  padding: 0;
  color: white;
  text-align: center;
}

.footer > p {
  margin: 0;
  font-size: 0.875rem;
  text-align: center;
}

.section-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 100vh;
}

.active {
  padding-bottom: 0.1rem;
  font-weight: bold;
  border-bottom: 2px solid var(--nav-link-color);
}

/* Top left image */
.bg-topleft {
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
  width: 10vw;
  height: 10vw;
  pointer-events: none;
  user-select: none;
}

/* Rotated bottom left image */
.bg-rotated {
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: -1;
  width: 10vw;
  height: 10vw;
  pointer-events: none;
  user-select: none;
  transform: rotate(180deg);
}

#index {
  height: 100vh;
}

.bg-dark {
  color: white;
  background-color: var(--bg-color-dark);
}

.bg-light {
  color: var(--bg-color-dark);
  background-color: var(--bg-color-light);
}

h1 {
  padding: 0;
  margin: 0;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.2;
}

h1.title {
  padding: 0;
  margin: -5rem 0 0;
  font-size: 8rem;
  line-height: 1.1;
}

h2 {
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--subheader-color);
}

h2.subtitle {
  padding: 0;
  margin: 1rem 0 2rem;
  font-family: 'Playfair Display', serif;
  font-size: 3.75rem;
  line-height: 1.15;
  color: var(--bg-color-dark);
  text-transform: uppercase;
}

p.title-page {
  max-width: min(50rem, 90vw);
  margin: clamp(2rem, 5vw, 4rem) 0;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.4;
}

#index > .section-content {
  justify-content: start;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: clamp(0.75rem, 2vw, 1rem) clamp(1.5rem, 4vw, 2rem);
  font-family: var(--font-primary);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  color: var(--bg-color-dark);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  background-color: var(--button-bg);
  border: none;
  border-radius: var(--border-radius-full);
  transition: var(--transition-fast);
}

.button:hover,
.button:focus {
  outline: none;
  opacity: 0.9;
  transform: scale(1.05);
}

.button:focus-visible {
  outline: 2px solid var(--bg-color-dark);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .button:hover,
  .button:focus {
    transform: none;
  }
}

.logo {
  width: 80vw;
  max-width: 20rem;
  height: auto;
  object-fit: cover;
  object-position: center;
}

.about-content {
  display: flex;
  flex-flow: row wrap-reverse;
  gap: 4rem;
  align-items: center;
  justify-content: center;
  margin-top: 2rem;
}

.about-image {
  width: 500px;
  height: 500px;
  margin-bottom: 2rem;
  object-fit: cover;
  object-position: bottom;
  border-radius: 1rem;
  box-shadow: 0 4px 8px rgb(0 0 0 / 30%);
}

.about-content div {
  max-width: 600px;
  padding: 0 1rem;
}

.about-content p {
  max-width: 100%;
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  line-height: 1.6;
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
}

.team-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  place-items: stretch center;
  width: 100%;
  max-width: 80rem;
  margin-top: 2rem;
}

.team-member-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: stretch;
  width: 100%;
  max-width: 50ch;
  padding: 4rem 2rem 2rem;
  text-align: center;
  background-color: var(--button-bg);
  border-radius: 100vh 100vh 1rem 1rem;
  box-shadow: 0 4px 8px rgb(0 0 0 / 30%);
}

.team-member-image {
  width: 20rem;
  height: 20rem;
  min-height: 15rem;
  aspect-ratio: 1;
  margin-bottom: 1rem;
  object-fit: cover;
  object-position: top;
  border-radius: var(--border-radius-full);
}

.team-member-card hr {
  width: 50%;
  margin: 1rem 0;
  border: 1px solid var(--bg-color-dark);
}

.team-member-bio {
  max-width: 35ch;
  font-family: 'Playfair Display', serif;
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--nav-link-color);
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
}

.offer-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 8vw, 8rem);
  place-items: stretch center;
  width: 100%;
  margin-top: 2rem;
}

.offer-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 36rem;
  height: auto;
  min-height: 60vh;
  padding: 2rem;
  border-radius: var(--border-radius-medium);
}

.offer-item-image {
  width: clamp(20rem, 30vw, 25rem);
  height: clamp(20rem, 30vw, 25rem);
  aspect-ratio: 1;
  margin-bottom: 1rem;
  object-fit: cover;
  object-position: center;
  border-radius: var(--border-radius-full);
}

.offer-item hr {
  width: 50%;
  margin: 1rem 0;
  border: 1px solid var(--bg-color-dark);
}

.offer-item-description {
  max-width: 70%;
  font-family: 'Playfair Display', serif;
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--nav-link-color);
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
}

.offer-item-wide {
  display: flex;
  flex-flow: row nowrap;
  grid-column: span 2;
  gap: 2rem;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 90rem;
  height: max-content;
  min-height: 90vh;
  margin: 2rem auto;
}

.offer-item-image-wide {
  width: 40%;
  min-width: 15rem;
  max-width: 450px;
  height: auto;
  border-radius: var(--border-radius-small);
  box-shadow: var(--shadow-medium);
}

.offer-item-wide > div {
  width: 40%;
  min-width: 50ch;
}

.offer-item-wide h2 {
  padding: 0;
  margin: 0;
  font-size: 4rem;
  line-height: 1.1;
  color: var(--bg-color-dark);
}

.offer-item-map {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 450px;
  height: 650px;
  overflow: hidden;
  border: none;
  border-radius: var(--border-radius-small);
  box-shadow: var(--shadow-light);
}

.offer-item-wide-description {
  width: 100%;
  margin-inline: auto;
  margin-bottom: 2rem;
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  line-height: 1.6;
  color: var(--bg-color-dark);
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
}

.offer-item-wide-images {
  position: relative;
  width: 10%;
  min-width: 5rem;
  height: 100%;
}

.offer-item-wide-images img {
  position: absolute;
  width: 30rem;
  height: 30rem;
  object-fit: cover;
  object-position: left bottom;
  border-radius: var(--border-radius-full);
  transition: transform var(--transition-fast);
  will-change: transform;
}

.offer-item-gallery > .offer-item-wide-description {
  margin: 0;
}

.offer-item-gallery-images img {
  width: clamp(15rem, 25vw, 20rem);
  height: clamp(15rem, 25vw, 20rem);
  aspect-ratio: 1;
  cursor: pointer;
  object-fit: cover;
  object-position: center;
  border-radius: var(--border-radius-medium);
  box-shadow: var(--shadow-medium);
  transition: transform var(--transition-fast);
}

.offer-item-gallery-images img:focus {
  outline: 2px solid var(--button-bg);
  outline-offset: 2px;
}

.offer-item-wide-images img:hover {
  z-index: 10;
  transform: scale(1.05) rotate(5deg);
}

.offer-item-gallery-images img:hover {
  z-index: 10;
  transform: scale(1.2);
}

@media (prefers-reduced-motion: reduce) {
  .offer-item-wide-images img,
  .offer-item-gallery-images img {
    transition: none;
  }

  .offer-item-wide-images img:hover,
  .offer-item-gallery-images img:hover {
    transform: none;
  }
}

.offer-item-wide-images img:nth-child(1) {
  top: -2rem;
  left: 4rem;
}

.offer-item-wide-images img:nth-child(2) {
  bottom: -2rem;
}

.offer-item-gallery {
  display: flex;
  flex-direction: column;
  grid-column: span 2;
  gap: 2rem;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 70rem;
  height: max-content;
  margin: 2rem auto;
}

.offer-item-gallery h2 {
  padding: 0;
  margin: 0;
  font-size: 4rem;
  line-height: 1.1;
  color: var(--bg-color-dark);
}

.offer-item-gallery-images {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: 2rem;
  justify-items: center;
  width: 100%;
}

.timetable-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  justify-items: center;
  width: 100%;
  scroll-snap-type: y mandatory;
  scroll-snap-stop: always;
}

.timetable-day-card {
  width: 80%;
  height: 80vh;
  padding: 2rem;
  margin-inline: auto;
  scroll-snap-align: start;
  border-radius: 1rem;
}

.timetable-day-card h2 {
  padding: 0;
  margin: 0;
  font-size: 3rem;
  line-height: 1.2;
  color: var(--bg-color-light);
}

.timetable-day-card hr {
  width: 50%;
  margin: 1rem auto;
  border: 1px solid var(--bg-color-light);
}

.timetable-day-card p {
  width: 100%;
  max-width: 100%;
  font-size: 1.5rem;
  line-height: 1.6;
  color: var(--bg-color-light);
  text-align: justify;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 2;
}

/* Booking form styling */
.booking-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
  max-width: 60rem;
  padding: 2rem;
  margin-top: 4rem;
  background-color: var(--button-bg);
  border-radius: 1rem;
  box-shadow: 0 4px 8px rgb(0 0 0 / 30%);
}

#booking {
  height: 100vh;
}

#booking .section-content {
  display: flex;
  flex-direction: column;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: unset;
}

.booking-form label {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 1.5rem;
  color: var(--nav-link-color);
  text-align: left;
}

.booking-form input,
.booking-form textarea {
  padding: 0.5rem;
  font-family: inherit;
  font-size: 1.25rem;
  color: var(--nav-link-color);
  background-color: var(--bg-color-light);
  border: none;
  border-radius: 0.5rem;
  box-shadow: inset 0 4px 8px rgb(0 0 0 / 7%);
  transition: all 0.3s ease;
}

.booking-form textarea {
  min-height: 10rem;
  resize: vertical;
}

.booking-form input:focus,
.booking-form textarea:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--bg-color-dark);
}

.booking-form button {
  padding: 1rem 3rem;
  margin-top: 2rem;
  font-family: inherit;
  font-size: 1.5rem;
  color: var(--bg-color-light);
  cursor: pointer;
  background-color: var(--bg-color-dark);
  border: none;
  border-radius: 100vh;
  box-shadow: 0 4px 8px rgb(0 0 0 / 30%);
  transition: all 0.3s ease;
}

.booking-form button:hover {
  opacity: 0.9;
  transform: scale(1.05);
}

#booking .section-content > iframe {
  width: min(640px, 100%);
  height: 3100px;
  border: 1px solid var(--border-color-light);
}

/* Media Queries for responsiveness */
@media (width <= 1200px) {
  :root {
    --section-padding: 1rem;
  }

  body,
  html {
    font-size: 14px;
  }

  section {
    padding: var(--section-padding);
  }

  img.logo {
    margin-top: 6rem;
  }

  .about-image {
    width: 300px;
    height: 300px;
  }

  .about-content div {
    max-width: 90%;
    padding: 0;
  }

  .offer-content,
  .team-content {
    gap: 1rem;
  }

  .team-member-card {
    width: min(100%, 50ch);
  }

  .offer-item {
    width: min(100%, 36rem);
  }

  .offer-item,
  .team-member-card {
    margin-bottom: 25vh;
  }

  .offer-item p {
    max-width: 90%;
  }

  .offer-item-wide,
  .offer-item-gallery {
    flex-direction: column;
    gap: 1rem;
    width: 100%;
  }

  .offer-item-wide > div {
    width: 100%;
    min-width: unset;
  }

  .offer-item-wide-images {
    display: flex;
    flex-direction: row;
    gap: 1rem;
    width: 100%;
    min-width: unset;
    height: 15rem;
  }

  .offer-item-wide-images img {
    position: absolute;
    top: unset;
    right: unset;
    bottom: unset;
    left: unset;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 15rem;
    height: 15rem;
    object-fit: fill;
    transform: none !important;
  }

  .offer-item-wide-images img:nth-child(1) {
    top: 0;
    right: 50%;
    transform: translate(50%, 0) !important;
  }

  .offer-item-wide-images img:nth-child(2) {
    display: none !important;
  }

  h1.title {
    margin: -2rem 0 0;
    font-size: 5rem;
  }

  h2.subtitle {
    margin: 1rem 0;
    font-size: 2.5rem;
  }

  nav ul {
    max-width: 100%;
  }

  .section-content h1 {
    font-size: 3rem;
    line-height: 1.2;
  }

  h2 {
    font-size: 2rem;
    line-height: 1.25;
  }

  .about-content p {
    font-size: 1.75rem;
    line-height: 1.55;
  }

  p.team-member-bio {
    max-width: 90%;
    font-size: 1.5rem;
    font-weight: 500;
  }

  p.offer-item-description {
    max-width: 90%;
    font-size: 1.5rem;
  }

  p.offer-item-wide-description {
    font-size: 1.5rem;
  }
}

@media (width <= 1023px) {
  body,
  html {
    font-size: 12px;
  }

  nav #menu-toggle {
    display: block;
  }

  nav {
    flex-direction: column;
    gap: 0;
    align-items: flex-start;
    justify-content: center;
    height: auto;
    min-height: 3rem;
    padding: 0.5rem 2rem;
    font-size: 14px;
  }

  nav ul {
    display: block;
    gap: 0.5rem;
    height: 0;
    overflow: hidden;
    list-style: none;
    transition: height 0.3s ease;
  }

  nav ul li {
    margin: 1rem 0;
  }

  nav ul.show {
    height: auto;
  }

  p {
    max-width: none;
  }

  section {
    padding: 1rem;
  }

  .team-content {
    grid-template-columns: 1fr;
    gap: 2rem;
    width: 100%;
  }

  .offer-content {
    grid-template-columns: 1fr;
    gap: 2rem;
    width: 100%;
  }

  .offer-item {
    width: 100%;
    padding: 0;
  }

  .offer-item-wide,
  .offer-item-gallery {
    grid-column: span 1;
  }

  .offer-item-wide-description {
    text-align: justify;
  }
}

/* Print styles */
@media print {
  .skip-link,
  nav,
  .bg-topleft,
  .bg-rotated {
    display: none;
  }

  main {
    position: static;
    overflow: visible;
  }

  section {
    padding: 1rem;
    break-inside: avoid;
  }

  .button {
    background: transparent;
    border: 1px solid currentcolor;
  }
}
