/* =========================
   Colour Palette
========================= */

:root {
  --colour-burgundy: #44243f;
  --colour-burgundy-light: #573a52;
  --colour-purple: #8e6a9b;
  --colour-purple-light: #c5b3d3;

  --colour-pink: #fbefef;
  --colour-pink-dark: #ffe2e2;
  --colour-lilac: #dac0cbd9;
  --colour-lilac-solid: #dac0cd;

  --colour-text: #4a4a4a;
  --colour-text-muted: #756a6a;
  --colour-description: #795a84;

  --colour-border: #eee3e3;
  --colour-white: #ffffff;

  --colour-whatsapp: #25d366;
}

/* =========================
   Base
========================= */

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

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

body {
  font-family: "Glacial Indifference", system-ui, -apple-system, "Segoe UI",
    sans-serif;
  color: var(--colour-text);
}

/* =========================
   Accessibility Helpers
========================= */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 2000;

  padding: 0.75rem 1rem;

  background-color: var(--colour-burgundy);
  color: var(--colour-white);
  text-decoration: none;

  transform: translateY(-200%);
}

.skip-link:focus {
  transform: translateY(0);
}

/* =========================
   Navigation
========================= */

.navbar {
  position: absolute;
  inset: 0 0 auto;
  z-index: 1000;

  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;

  padding: 2.4rem 3rem;

  background-color: var(--colour-lilac);
}

/* Floating navigation (shown by script.js once the hero is scrolled past) */

.navbar-floating {
  position: fixed;

  padding: 1.2rem 3rem;

  opacity: 0;
  visibility: hidden;
  pointer-events: none;

  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.navbar-floating.visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Links */

.nav-links {
  display: flex;
  align-items: center;
  gap: 7rem;

  list-style: none;
}

.nav-links a,
.home-link,
.contact-link {
  color: var(--colour-text);

  font-size: 1rem;
  letter-spacing: 0.1rem;
  text-decoration: none;

  transition: color 0.3s ease;
}

.home-link {
  justify-self: start;
  margin-left: 2.5rem;
}

.contact-link {
  justify-self: end;
  margin-right: 5rem;
}

.nav-links a:hover,
.home-link:hover,
.contact-link:hover {
  color: var(--colour-purple);
}

/* Menu/hamburger button (only shown on small screens) */

.nav-toggle {
  display: none;

  align-items: center;
  justify-content: center;

  width: 2.5rem;
  height: 2.5rem;

  border: 0;
  background: transparent;

  color: var(--colour-text);

  cursor: pointer;
}

.nav-toggle ion-icon {
  font-size: 1.8rem;
}

/* =========================
   Hero
   Desktop image 1920 x 1080 (16 / 9), mobile image 1080 x 1350 (4 / 5).
========================= */

.hero {
  position: relative;

  width: 100%;
  aspect-ratio: 16 / 9;

  overflow: hidden;

  background-color: var(--colour-pink-dark);

  container-type: inline-size;
}

.hero picture {
  display: block;
  width: 100%;
  height: 100%;
}

.hero-image {
  display: block;

  width: 100%;
  height: 100%;

  object-fit: cover;
}

.hero-buttons {
  position: absolute;
  left: 12%;
  bottom: 33%;
  z-index: 2;
  display: flex;
  gap: 2em;

  /* Changes button size throughout all screens */
  font-size: max(0.75rem, 1.2cqw);
}

.hero-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;

  min-width: 0;
  padding: 0.9em 1.6em;

  border: 1px solid var(--colour-purple);
  border-radius: 0.4em;

  background-color: var(--colour-burgundy);

  color: var(--colour-white);

  letter-spacing: 0.04em;
  text-decoration: none;

  cursor: pointer;

  transition: background-color 0.3s ease, color 0.3s ease,
    border-color 0.3s ease;
}

.hero-button ion-icon {
  font-size: 1.3em;
}

.hero-button:hover {
  background-color: var(--colour-purple);
  border-color: var(--colour-purple);
  color: var(--colour-pink);
}

/* =========================
   Shared section headings
========================= */

.about-eyebrow,
.services-eyebrow,
.gallery-eyebrow,
.contact-eyebrow,
.cancellation-eyebrow {
  margin-bottom: 1.5rem;

  font-weight: 400;
  letter-spacing: 0.15rem;

  color: var(--colour-purple);
}

.about-eyebrow,
.services-eyebrow,
.gallery-eyebrow {
  font-size: 1rem;
}

.contact-eyebrow,
.cancellation-eyebrow {
  font-size: 0.8rem;
}

.about h2,
.services-header h2,
.gallery-header h2,
.contact-header h2,
.cancellation-header h2 {
  font-size: 2.5rem;
  font-weight: 400;

  color: var(--colour-burgundy);
}

.services-header,
.gallery-header,
.contact-header,
.cancellation-header {
  max-width: 45rem;

  text-align: center;
}

/* =========================
   About
========================= */

.about {
  padding: 6rem 3rem;

  background-color: var(--colour-pink);
}

.about-content {
  max-width: 45rem;
  margin: 0 auto;

  text-align: center;
}

.about h2 {
  margin-bottom: 2rem;
}

.about p:not(.about-eyebrow) {
  margin-bottom: 1.25rem;

  font-size: 1.05rem;
  line-height: 1.8;

  color: var(--colour-text);
}

/* =========================
   Services
========================= */

.services {
  padding: 7rem 3rem;

  background-color: var(--colour-lilac);
}

.services-header {
  margin: 0 auto 5rem;
}

.service-category {
  max-width: 55rem;
  margin: 0 auto 5rem;

  scroll-margin-top: 8rem;
}

.service-category:last-child {
  margin-bottom: 0;
}

.service-category h3 {
  margin-bottom: 2rem;

  font-size: 1.75rem;
  font-weight: 400;

  color: var(--colour-burgundy);
}

.service-group {
  margin-bottom: 3rem;
}

.service-group:last-child {
  margin-bottom: 0;
}

.service-group h4 {
  margin-bottom: 1.2rem;

  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.08rem;
  text-transform: uppercase;

  color: var(--colour-purple);
}

.service-list {
  list-style: none;
}

.service-list li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;

  padding: 1rem 0;

  border-bottom: 1px solid var(--colour-border);

  font-size: 1.2rem;

  color: var(--colour-burgundy-light);
}

.service-list li:first-child {
  border-top: 1px solid var(--colour-border);
}

.service-list li > span:last-child {
  margin-left: 2rem;

  font-weight: 500;
  white-space: nowrap;

  color: var(--colour-burgundy);
}

.service-with-description {
  gap: 2rem;
}

.service-with-description div {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.service-with-description p {
  font-size: 0.85rem;
  line-height: 1.5;

  color: var(--colour-description);
}

/* =========================
   Gallery
========================= */

.gallery {
  padding: 7rem 3rem;

  background-color: var(--colour-pink);
}

.gallery-header {
  margin: 0 auto 5rem;
}

.gallery-header h2 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.gallery-header h2 ion-icon {
  transform: translateY(0.1rem);
}

.gallery-carousel {
  display: flex;
  align-items: center;
  gap: 1rem;

  max-width: 75rem;
  margin: 0 auto;
}

.gallery-viewport {
  flex: 1;

  overflow: hidden;
}

.gallery-track {
  display: flex;
  gap: 1rem;

  transition: transform 0.5s ease;
}

.gallery-slide {
  position: relative;

  flex: 0 0 calc((100% - 2rem) / 3);

  aspect-ratio: 1 / 1;

  overflow: hidden;
}

.gallery-slide img {
  display: block;

  width: 100%;
  height: 100%;

  object-fit: cover;
}

.gallery-slide:nth-child(9) img,
.gallery-slide:nth-child(10) img {
  object-position: center 10%;
}

.gallery-slide:nth-child(16) img {
  object-position: center 80%;
}

.gallery-slide::after {
  content: "";

  position: absolute;
  inset: 0;

  background-color: #4a4a4a33;

  opacity: 0;

  transition: opacity 0.3s ease;
}

.gallery-slide:hover::after {
  opacity: 1;
}

.gallery-arrow {
  display: flex;
  align-items: center;
  justify-content: center;

  flex: 0 0 2.75rem;

  width: 2.75rem;
  height: 2.75rem;

  border: 1px solid var(--colour-burgundy);

  background-color: transparent;

  color: var(--colour-text);

  cursor: pointer;

  transition: background-color 0.3s ease, color 0.3s ease,
    border-color 0.3s ease;
}

.gallery-arrow ion-icon {
  font-size: 1.2rem;
}

.gallery-arrow:hover {
  background-color: var(--colour-burgundy);
  color: var(--colour-pink);
}

.gallery-instagram {
  margin-top: 3rem;

  text-align: center;
}

.instagram-link {
  font-size: 0.9rem;
  letter-spacing: 0.08rem;

  text-decoration: none;

  color: var(--colour-purple);

  transition: color 0.3s ease;
}

.instagram-link:hover {
  color: var(--colour-burgundy);
}

/* =========================
   Contact
========================= */

.contact {
  padding: 7rem 3rem;

  background-color: var(--colour-lilac);
}

.contact-header {
  margin: 0 auto 3rem;
}

.contact-content {
  max-width: 45rem;
  margin: 0 auto;

  text-align: center;
}

.contact-intro {
  max-width: 35rem;
  margin: 0 auto;

  font-size: 1.05rem;
  line-height: 1.8;

  color: var(--colour-text);
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 2rem;

  margin-top: 2.5rem;
}

.contact-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;

  min-width: 11rem;
  padding: 1rem 1.5rem;

  border: 1px solid var(--colour-burgundy);
  border-radius: 0.5rem;

  background-color: var(--colour-burgundy);

  font-size: 1rem;
  letter-spacing: 0.04rem;
  text-decoration: none;

  color: var(--colour-white);

  transition: background-color 0.3s ease, border-color 0.3s ease,
    color 0.3s ease;
}

.contact-button ion-icon {
  font-size: 2rem;
}

.whatsapp-button ion-icon {
  color: var(--colour-whatsapp);
}

.instagram-button ion-icon {
  color: var(--colour-purple-light);
}

.contact-button:hover {
  background-color: var(--colour-purple);
  border-color: var(--colour-purple);
  color: var(--colour-white);
}

.contact-location {
  margin-top: 2.5rem;

  font-size: 0.9rem;
  letter-spacing: 0.08rem;

  color: var(--colour-text-muted);
}

/* =========================
   Cancellation Policy
========================= */

.cancellation {
  padding: 5rem 3rem;

  background-color: var(--colour-pink);
}

.cancellation-header {
  margin: 0 auto 2.5rem;
}

.cancellation-content {
  max-width: 45rem;
  margin: 0 auto;
}

.cancellation-content p {
  margin-bottom: 1.25rem;

  font-size: 1rem;
  line-height: 1.8;

  color: var(--colour-text);

  text-align: center;
}

.cancellation-content p:last-child {
  margin-bottom: 0;
}

/* =========================
   Footer
========================= */

.footer {
  padding: 5rem 3rem 4rem;

  background-color: var(--colour-burgundy);

  color: var(--colour-white);
}

.footer-container {
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr 1fr;
  align-items: start;
  gap: 3rem;

  max-width: 75rem;
  margin: 0 auto;
}

.footer-brand {
  height: fit-content;
  margin-right: -4rem;
}

.footer-brand img {
  display: block;

  width: 34rem;
  height: auto;

  transform: translateX(-8rem);
}

.footer-contact {
  transform: translateX(-3rem);
}

.footer-contact h3,
.footer-hours h3,
.footer-links h3 {
  margin-bottom: 1.25rem;

  font-size: 0.9rem;
  font-weight: 400;
  letter-spacing: 0.12rem;
  text-transform: uppercase;

  color: var(--colour-pink);
}

.footer-contact p {
  margin-bottom: 0.6rem;

  font-size: 0.95rem;
}

.footer-contact a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;

  text-decoration: none;

  color: var(--colour-white);

  transition: color 0.3s ease;
}

.footer-contact ion-icon {
  font-size: 1.1rem;

  color: var(--colour-purple-light);
}

.footer-contact ion-icon[name="logo-whatsapp"] {
  color: var(--colour-whatsapp);
}

.footer-contact a:hover {
  color: var(--colour-purple-light);
}

.footer-hours p {
  margin-bottom: 0.6rem;

  font-size: 0.95rem;

  color: var(--colour-white);
}

.footer-hours .footer-hours-note {
  max-width: 15rem;
  margin-top: 1.25rem;

  font-size: 0.8rem;
  line-height: 1.5;

  color: var(--colour-pink);
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.6rem;
}

.footer-links a {
  font-size: 0.95rem;

  text-decoration: none;

  color: var(--colour-white);

  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--colour-purple-light);
}

.blackrock {
  padding-top: 1.15rem;
}

.footer-bottom {
  max-width: 70rem;
  margin: 2.5rem auto 0;
  padding-top: 1rem;

  border-top: 1px solid rgba(251, 239, 239, 0.2);

  text-align: center;
}

.footer-bottom p {
  font-size: 0.75rem;
  letter-spacing: 0.05rem;

  color: #fbefefb3;
}

/* =========================
   Focus States
========================= */

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--colour-purple);
  outline-offset: 3px;
}

/* The purple ring is too faint on the dark footer */
.footer a:focus-visible {
  outline-color: var(--colour-purple-light);
}

/* =========================
   Reduced Motion
========================= */

@media (prefers-reduced-motion: reduce) {
  .gallery-track {
    transition: none;
  }
}

/* =====================================================
   RESPONSIVE
===================================================== */

/* ---------- Navigation collapses to a menu button (up to 1024px) ---------- */

@media (width <= 64rem) {
  .navbar {
    grid-template-columns: 1fr auto;
  }

  .navbar .nav-links,
  .navbar .contact-link {
    display: none;
  }

  .navbar .home-link {
    margin-left: 0;
  }

  .nav-toggle {
    display: flex;
    justify-self: end;
  }

  .navbar.menu-open {
    grid-template-rows: auto auto;
  }

  .navbar.menu-open .nav-links {
    display: flex;
    grid-column: 1 / -1;

    flex-direction: column;
    align-items: center;
    gap: 1.5rem;

    padding-top: 2rem;
  }

  .navbar.menu-open .contact-link {
    display: block;
    grid-column: 1 / -1;

    margin: 0;
    padding-top: 1.5rem;

    justify-self: center;
    text-align: center;
  }
}

/* ---------- Tablet (769px - 1024px) ---------- */

@media (48rem < width <= 64rem) {
  .navbar {
    padding: 1.1rem 2.5rem;
  }

  .navbar-floating {
    padding: 0.8rem 2.5rem;
  }

  .home-link {
    font-size: 0.9rem;
    letter-spacing: 0.08rem;
  }
}

/* ---------- Mobile (up to 768px) ---------- */

@media (width <= 48rem) {
  /* Navigation */

  .navbar {
    padding: 1.25rem 1.5rem;
  }

  .home-link {
    font-size: 0.8rem;
    letter-spacing: 0.08rem;
  }

  /* Hero (mobile image, 4 / 5) */

  .hero {
    aspect-ratio: 3 / 4;
  }

  .hero-buttons {
    left: 50%;
    bottom: 20%;
    transform: translateX(-50%);

    flex-direction: column;
    gap: 0.8em;

    /* 20rem on phones, grows with the hero on wider screens */
    width: max(min(85%, 20rem), 45cqw);
    font-size: max(0.9rem, 2.2cqw);
  }

  .hero-button {
    width: 100%;
    padding: 0.8em 1em;
  }

  /* About */

  .about {
    padding: 5rem 3rem;
  }

  .about-content {
    max-width: 100%;
  }

  .about-eyebrow,
  .services-eyebrow {
    margin-bottom: 1rem;
    font-size: 0.85rem;
    letter-spacing: 0.12rem;
  }

  .about h2 {
    margin-bottom: 1.5rem;
    font-size: 2rem;
  }

  .about p:not(.about-eyebrow) {
    margin-bottom: 1rem;
    font-size: 0.95rem;
    line-height: 1.7;
  }

  /* Services */

  .services {
    padding: 5rem 3rem;
  }

  .services-header {
    max-width: 100%;
    margin-bottom: 3.5rem;
  }

  .services-header h2 {
    font-size: 2rem;
  }

  .service-category {
    max-width: 100%;
    margin-bottom: 4rem;
    scroll-margin-top: 6rem;
  }

  .service-category h3 {
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    text-align: center;
  }

  .service-group {
    margin-bottom: 2.5rem;
  }

  .service-group h4 {
    margin-bottom: 1rem;
    font-size: 0.85rem;
    letter-spacing: 0.07rem;
  }

  .service-list li {
    padding: 0.9rem 0;
    font-size: 1rem;
  }

  .service-list li > span:last-child {
    margin-left: 1rem;
  }

  .service-with-description {
    gap: 1rem;
  }

  .service-with-description p {
    font-size: 0.8rem;
  }

  /* Gallery */

  .gallery {
    padding: 5rem 1.5rem;
  }

  .gallery-header {
    margin-bottom: 3rem;
  }

  .gallery-header h2 {
    font-size: 2.2rem;
  }

  .gallery-carousel {
    gap: 0.75rem;
  }

  .gallery-slide {
    flex: 0 0 100%;
  }

  .gallery-arrow {
    flex: 0 0 2rem;
    width: 2rem;
    height: 2rem;
  }

  /* Contact */

  .contact {
    padding: 5rem 3rem;
  }

  .contact-header {
    max-width: 100%;
    margin-bottom: 2.5rem;
  }

  .contact-eyebrow,
  .cancellation-eyebrow {
    margin-bottom: 1rem;
    font-size: 0.75rem;
    letter-spacing: 0.12rem;
  }

  .contact-header h2 {
    font-size: 2rem;
  }

  .contact-content {
    max-width: 100%;
  }

  .contact-intro {
    max-width: 100%;
    font-size: 0.95rem;
    line-height: 1.7;
  }

  .contact-links {
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 2rem;
  }

  .contact-button {
    width: 100%;
    min-width: 0;
    padding: 0.7rem 1rem;
    font-size: 0.9rem;
  }

  .contact-button ion-icon {
    font-size: 1.5rem;
  }

  .contact-location {
    margin-top: 2rem;
    font-size: 0.8rem;
  }

  /* Cancellation */

  .cancellation {
    padding: 4rem 3rem;
  }

  .cancellation-header {
    max-width: 100%;
    margin-bottom: 2rem;
  }

  .cancellation-header h2 {
    font-size: 2rem;
  }

  .cancellation-content {
    max-width: 100%;
  }

  .cancellation-content p {
    margin-bottom: 1rem;
    font-size: 0.9rem;
    line-height: 1.7;
  }

  /* Footer */

  .footer {
    padding: 4rem 2rem 3rem;
    text-align: center;
  }

  .footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.75rem;

    max-width: 100%;
  }

  .footer-brand {
    width: 100%;
    height: auto;
    margin-right: 0;
  }

  .footer-brand img {
    width: 100%;
    max-width: 22rem;
    height: auto;

    margin: 0 auto 1rem;
    transform: none;
  }

  .footer-contact {
    transform: none;
  }

  .footer-contact h3,
  .footer-hours h3,
  .footer-links h3 {
    margin-bottom: 1rem;
    font-size: 0.8rem;
    letter-spacing: 0.1rem;
  }

  .footer-contact p,
  .footer-hours p,
  .footer-links a {
    font-size: 0.9rem;
  }

  .footer-hours .footer-hours-note {
    max-width: 100%;
    margin-top: 1rem;
    font-size: 0.75rem;
  }

  .footer-links ul {
    text-align: center;
  }

  .footer-links li {
    margin-bottom: 0.5rem;
  }

  .blackrock {
    padding-top: 1rem;
  }

  .footer-bottom {
    margin-top: 1rem;
  }

  .footer-bottom p {
    font-size: 0.7rem;
    line-height: 1.5;
  }
}

/* ---------- Wider phones / small tablets: one centred gallery slide ---------- */

@media (27.5rem <= width <= 50rem) {
  .gallery-carousel {
    max-width: 25rem;
    margin: 0 auto;
  }

  .gallery-slide {
    flex: 0 0 100%;
  }

  .gallery-slide img {
    max-height: 20rem;
  }
}

/* ---------- Tablet footer (769px - 1120px) ---------- */

@media (48rem < width <= 70rem) {
  .footer-container {
    grid-template-columns: 1fr 1.2fr 1fr;
    gap: 2rem;
    max-width: 42rem;
  }

  .footer-brand {
    grid-column: 1 / -1;
    margin-right: 0;
    text-align: center;
  }

  .footer-brand img {
    width: 30rem;
    margin: 0 auto 1rem;
    transform: none;
  }

  .footer-links {
    padding-left: 1rem;
  }

  .footer-links li {
    margin-bottom: 0.9rem;
  }

  .footer-hours p {
    margin-bottom: 1rem;
  }

  .footer-contact {
    transform: none;
  }

  .blackrock {
    margin-top: 1.9rem;
  }
}

/* ---------- Navbar colour at exactly 768px and 1121px - 1280px ---------- */

@media (width: 48rem), (70rem < width <= 80rem) {
  .navbar:not(.navbar-floating) {
    background-color: var(--colour-lilac-solid);
  }
}

/* ---------- Footer logo position, by width ---------- */

@media (70rem < width <= 80rem) {
  .footer-brand img {
    width: 20rem;
    transform: translateX(-1.4rem);
  }
}

@media (width > 80rem) {
  .footer-brand img {
    width: 24rem;
    transform: translate(-2.4rem, 0.5rem);
  }
}

@media (width >= 112.5rem) {
  .footer-brand img {
    transform: translate(-7rem, 1rem);
  }
}
