/* =======================================================================
   Tsawwassen Massage Therapy — Responsive Stylesheet
   Mobile-first with progressive enhancements for tablet and desktop.
   ======================================================================= */

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

html {
  background-color: #6E8C8D;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0;
  font-family: Georgia, "Times New Roman", Times, serif;
  font-size: 100%;
  background-color: #6E8C8D;
  color: #f7eccc;
  line-height: 1.5;
}

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

a { color: inherit; }

/* ---------- Layout wrappers ---------- */
.wrapper {
  width: 100%;
  max-width: 1430px;
  margin: 0 auto;
  background-image: url("images/bgheader.png");
  background-repeat: no-repeat;
  background-size: 100% auto;
}

.container {
  position: relative;
  width: 100%;
  max-width: 1430px;
  margin: 0 auto;
  padding: 0 1rem;
}

.botwrap {
  position: relative;
  width: 100%;
  margin: 0;
  background-size: cover;
  align-content: center;
}

/* ---------- Logo ---------- */
.logo {
  display: flex;
  justify-content: center;
  padding: 10px 10px 20px;
}
.logo img {
  width: 100%;
  max-width: 1024px;
  height: auto;
}

/* ---------- Mobile hamburger nav ---------- */
.nav-toggle-cb { display: none; }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 40px;
  height: 32px;
  padding: 4px;
  margin: 0 auto 15px;
  cursor: pointer;
  background: #408e96;
  border-radius: 4px;
}
.nav-toggle span {
  display: block;
  width: 100%;
  height: 4px;
  background: #f7eccc;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-nav {
  display: none;
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  background: #408e96;
  border-radius: 4px;
  overflow: hidden;
}
.mobile-nav li { margin: 0; }
.mobile-nav a {
  display: block;
  padding: 14px 18px;
  color: #f7eccc;
  text-decoration: none;
  font-size: 1.1rem;
  text-align: center;
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
.mobile-nav li:last-child a { border-bottom: none; }
.mobile-nav a:hover,
.mobile-nav a:focus {
  background-color: #ddd;
  color: #fff;
}

.nav-toggle-cb:checked ~ .mobile-nav { display: block; }
.nav-toggle-cb:checked ~ .nav-toggle span:nth-child(1) { transform: translateY(10px) rotate(45deg); }
.nav-toggle-cb:checked ~ .nav-toggle span:nth-child(2) { opacity: 0; }
.nav-toggle-cb:checked ~ .nav-toggle span:nth-child(3) { transform: translateY(-10px) rotate(-45deg); }

/* ---------- Desktop decorative nav grid (hidden on mobile) ---------- */
.grid-8-columns { display: none; }

/* ---------- Page headings ---------- */
.topic_hed,
.topic_hedaboutus,
.topic_hedphys,
.topic_hedmas,
.topic_hedacu,
.topic_hedbook,
.topic_hedfacilities,
.topic_hedcontact {
  display: flex;
  justify-content: center;
  padding: 20px 10px;
  color: #f7eccc;
  font-size: clamp(1.8rem, 5vw, 3.4rem);
  text-align: center;
  font-style: italic;
  letter-spacing: 2px;
}
.topic_hed p,
.topic_hedaboutus p,
.topic_hedphys p,
.topic_hedmas p,
.topic_hedacu p,
.topic_hedbook p,
.topic_hedfacilities p,
.topic_hedcontact p { margin: 0; }

/* ---------- Reception / hero image ---------- */
.reception-image {
  display: flex;
  justify-content: center;
  padding: 0 0.5rem;
}
.reception-image img { width: 100%; height: auto; }

/* ---------- Welcome / text blocks ---------- */
.welcome-text,
.welcome-textaboutus,
.welcome-textfacilities,
.welcome-textbooking {
  background: #f7eccc;
  color: #000;
  padding: 20px;
  margin: 10px 0;
  line-height: 1.6;
  font-size: clamp(1rem, 2.2vw, 1.6rem);
  text-align: center;
}
.welcome-textaboutus,
.welcome-textfacilities { text-align: left; }

.welcome-textbooking a { color: #000; }
.welcome-textbooking a:hover {
  background-color: #ddd;
  color: #fff;
  transition: background-color 0.5s;
}

/* ---------- Fees ---------- */
.fees {
  font-size: clamp(1.2rem, 3vw, 2.2rem);
  color: #f7eccc;
  text-align: center;
  font-style: italic;
  padding: 20px 10px;
}

/* ---------- Media / service sections ---------- */
.media,
.media2 {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 10px;
}

.media .image_m1,
.media .image_p1,
.media .image_a1,
.media2 .image_m2,
.media2 .image_p2,
.media2 .image_a2 {
  width: 100%;
  min-height: 260px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
}

.media .image_m1 { background-image: url("images/massage_07.jpg"); }
.media .image_p1 { background-image: url("images/physio_05.jpg"); }
.media .image_a1 { background-image: url("images/acu_06.jpg"); }
.media2 .image_m2 { background-image: url("images/massage_08.jpg"); }
.media2 .image_p2 { background-image: url("images/physio_07.jpg"); }
.media2 .image_a2 { background-image: url("images/acu_07.jpg"); }

.media .text,
.media .textm,
.media .textp,
.media2 .textm,
.media2 .textp,
.media2 .texta {
  padding: 20px;
  font-size: clamp(1rem, 2vw, 1.5rem);
  background-color: #f7eccc;
  color: #000;
  line-height: 1.5;
}
.media2 .textm,
.media2 .textp,
.media2 .texta { text-align: center; }

/* ---------- Bio grid ---------- */
.biogrid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 15px;
  padding: 0 10px;
  margin-bottom: 20px;
}
.biogrid .one {
  display: flex;
  align-items: center;
  justify-content: center;
}
.biogrid .one img {
  width: 100%;
  max-width: 240px;
  height: auto;
}
.biogrid .two {
  color: #F4EBCF;
  font-size: clamp(1rem, 2vw, 1.4rem);
  padding: 0 10px;
}

/* ---------- Treatment headings ---------- */
.treatmentheading {
  color: #f7eccc;
  text-decoration: underline;
  font-style: italic;
  font-weight: 100;
  letter-spacing: 2px;
  padding: 20px 10px;
  font-size: clamp(1.4rem, 3vw, 2.5rem);
}

/* ---------- Contact page ---------- */
.flex { display: flex; flex-wrap: wrap; }
.flex > * { width: 100%; padding: 0 10px; }
.right {
  color: #f7eccc;
  padding: 10px 20px;
  font-size: clamp(1.1rem, 2.2vw, 1.7rem);
}
.right blockquote { margin: 10px 0; padding-left: 20px; }

.facilitiestext {
  color: #f7eccc;
  font-size: clamp(1.1rem, 2.2vw, 1.7rem);
}

/* ---------- Slogan ---------- */
.slogan { color: #f7eccc; padding: 5px 10px; }
.slogan p:nth-of-type(1) {
  color: #f7eccc;
  font-size: clamp(1.1rem, 2.2vw, 1.8rem);
  text-transform: uppercase;
  letter-spacing: 3px;
  text-align: center;
  padding: 30px 0 20px;
  margin: 0;
}

/* ---------- Footer ---------- */
.footer {
  margin: 30px auto 0;
  background-color: #408e96;
  width: 100%;
  list-style: none;
  padding: 0;
}
.footer ul {
  list-style-type: none;
  margin: 0;
  padding: 10px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}
.footer ul li { display: inline-block; }
.footer ul li a {
  text-decoration: none;
  color: #f7eccc;
  display: inline-block;
  text-transform: uppercase;
  padding: 12px 16px;
  font-size: clamp(0.85rem, 1.6vw, 1rem);
}
.footer a:hover {
  background-color: #ddd;
  color: #fff;
  transition: background-color 0.5s;
}

/* =======================================================================
   TABLET / SMALL DESKTOP (>= 700px)
   ======================================================================= */
@media (min-width: 700px) {
  .media {
    grid-template-columns: 2fr 3fr;
    grid-template-areas: "img content";
    column-gap: 40px;
  }
  .media2 {
    grid-template-columns: 3fr 2fr;
    grid-template-areas: "content img";
    column-gap: 40px;
  }
  .media .image_m1,
  .media .image_p1,
  .media .image_a1 { grid-area: img; min-height: 420px; }
  .media2 .image_m2,
  .media2 .image_p2,
  .media2 .image_a2 { grid-area: img; min-height: 400px; }
  .media .text,
  .media .textm,
  .media .textp { grid-area: content; }
  .media2 .textm,
  .media2 .textp,
  .media2 .texta { grid-area: content; }

  .biogrid {
    grid-template-columns: 220px 1fr;
    gap: 30px;
    padding: 0 20px;
  }

  .flex > * { width: 50%; padding-left: 40px; }
}

/* =======================================================================
   DESKTOP (>= 1024px)
   ======================================================================= */
@media (min-width: 1024px) {
  .nav-toggle,
  .mobile-nav,
  .nav-toggle-cb { display: none !important; }

  /* === FIXED: no padding/gap between images in nav row === */
  .grid-8-columns {
    width: 100%;
    max-width: 1430px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    grid-template-rows: auto auto;
    gap: 0;
    place-items: stretch;        /* fill cells instead of centering/shrinking */
    font-size: 0;                /* kill inline whitespace between cells */
    line-height: 0;
  }
  .grid-8-columns > div {
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
  }
  /* Restore text for bottom row of link cells */
  .grid-8-columns a {
    display: block;
    padding: 10px 0;
    text-align: center;
    text-decoration: none;
    color: #f7eccc;
    font-size: clamp(1rem, 1.6vw, 1.4rem);
    line-height: 1.3;
  }
  .grid-8-columns a:hover {
    background-color: #ddd;
    color: #fff;
    transition: background-color 0.5s;
  }

  /* Image cells — fill completely, no letterboxing */
  .yelbox,
  .massage,
  .physio,
  .acupuncture,
  .contact {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-repeat: no-repeat;
    background-size: 100% 100%;  /* stretch to fill, no gaps */
    background-position: center;
    display: block;
  }
  .yelbox      { background-image: url("images/yelbox.jpg"); }
  .massage     { background-image: url("images/massage.jpg"); }
  .physio      { background-image: url("images/physio.jpg"); }
  .acupuncture { background-image: url("images/acu.jpg"); }
  .contact     { background-image: url("images/contact.jpg"); }

  .biogrid {
    grid-template-columns: 260px 1fr;
    gap: 40px;
    padding: 0 40px;
  }

  .media .image_m1 { min-height: 645px; }
  .media .image_p1 { min-height: 450px; }
  .media .image_a1 { min-height: 500px; }
  .media2 .image_m2,
  .media2 .image_p2 { min-height: 450px; }
  .media2 .image_a2 { min-height: 400px; }

  .footer ul { padding: 10px; }
  .footer ul li a { padding: 25px; }
}

/* =======================================================================
   PRINT
   ======================================================================= */
@media print {
  .nav-toggle, .mobile-nav, .grid-8-columns, .footer { display: none !important; }
  body { background: #fff; color: #000; max-width: none; }
  .welcome-text, .welcome-textaboutus,
  .welcome-textfacilities, .welcome-textbooking { background: #fff; }
}
