/* ============================================================
   style.css — Country Living Assisted Living
   Palette: Maroon & Gold primary, warm cream backgrounds
   ============================================================ */

/* ---- CSS Variables ---- */
:root {
  /* Maroon — primary brand (headers, footer, buttons, headings) */
  --maroon-dark:  #4a1515;   /* deep anchor maroon */
  --maroon-mid:   #7a2c2c;   /* main action maroon */
  --maroon-light: #a85050;   /* softer maroon for hover states */
  --maroon-pale:  #fffde8;   /* warm pale yellow, close to original site's #FFFFCC */

  /* Gold — secondary brand (links, labels, accents) */
  --gold:         #b8902e;   /* carried from original #AC8126 */
  --gold-light:   #d4aa55;   /* hover / decorative */
  --gold-pale:    #fdf6e3;   /* warm gold-tinted alt background */

  /* Backgrounds */
  --cream:        #faf7f2;
  --warm-white:   #ffffff;

  /* Text */
  --text-dark:    #2e1f1f;   /* warm near-black */
  --text-mid:     #5c3f3f;   /* warm brown-maroon mid */
  --text-light:   #8a6a6a;   /* muted warm tone */

  /* Utility */
  --border:       #e0d0c8;
  --shadow:       0 4px 20px rgba(74,21,21,0.10);
  --radius:       10px;
  --font-head:    'Playfair Display', Georgia, serif;
  --font-body:    'Lato', Helvetica, sans-serif;
  --transition:   0.3s ease;
  --max-width:    1100px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-dark);
  background: var(--cream);
}

img { max-width: 100%; height: auto; display: block; border-radius: var(--radius); }

a { color: var(--gold); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--maroon-mid); }

ul { list-style: none; }

h1, h2, h3 { font-family: var(--font-head); line-height: 1.25; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); margin-bottom: 1rem; color: var(--maroon-dark); }
h3 { font-size: 1.2rem; margin-bottom: 0.5rem; color: var(--maroon-dark); }

p { margin-bottom: 1rem; color: var(--text-mid); }

/* ---- Layout ---- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section { padding: 4rem 0; }
.section-alt { background: var(--maroon-pale); }

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  text-align: center;
}

.btn-primary {
  background: var(--maroon-mid);
  color: #fff;
}
.btn-primary:hover { background: var(--maroon-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow); }

.btn-secondary {
  background: transparent;
  color: var(--maroon-mid);
  border: 2px solid var(--maroon-mid);
}
.btn-secondary:hover { background: var(--maroon-mid); color: #fff; transform: translateY(-2px); }

.full-width { width: 100%; }

/* ---- Section Labels ---- */
.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.5rem;
}
.section-label.centered, h2.centered { text-align: center; display: block; }

/* ============================================================
   HEADER & NAV
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--warm-white);
  border-bottom: 2px solid var(--border);
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.logo a { display: block; line-height: 0; }
.logo-img {
  height: 58px;
  width: auto;
  border-radius: 0;
}

.nav-toggle {
  background: none;
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--maroon-dark);
  display: none;
  padding: 0.25rem;
}

.main-nav ul {
  display: flex;
  gap: 0.25rem;
  align-items: center;
}

.main-nav ul a {
  display: block;
  padding: 0.4rem 0.8rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-mid);
  border-radius: 6px;
  transition: all var(--transition);
}
.main-nav ul a:hover,
.main-nav ul a.active {
  background: var(--maroon-pale);
  color: var(--maroon-dark);
}

/* ============================================================
   HERO SLIDER
   ============================================================ */
.hero-slider {
  position: relative;
  height: clamp(320px, 60vw, 600px);
  overflow: hidden;
  background: var(--maroon-dark);
}

.slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-color: var(--maroon-mid);
  opacity: 0;
  transition: opacity 1s ease;
}
.slide.active { opacity: 1; }

.slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.15) 0%, rgba(0,0,0,0.55) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  color: #fff;
}

.slide-overlay h1 {
  font-family: var(--font-head);
  color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.4);
  margin-bottom: 0.5rem;
}
.slide-overlay p {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: rgba(255,255,255,0.9);
  max-width: 600px;
  margin: 0;
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.2);
  border: none;
  color: #fff;
  font-size: 1.4rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background var(--transition);
  z-index: 10;
}
.slider-btn:hover { background: rgba(255,255,255,0.4); }
.slider-btn.prev { left: 1rem; }
.slider-btn.next { right: 1rem; }

.slider-dots {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
  z-index: 10;
}
.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.8);
  background: transparent;
  cursor: pointer;
  transition: background var(--transition);
  padding: 0;
}
.dot.active { background: #fff; }

/* ============================================================
   INFO BAR
   ============================================================ */
.info-bar {
  background: var(--maroon-dark);
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem 2.5rem;
  padding: 0.9rem 1.25rem;
  font-size: 0.9rem;
}
.info-item { display: flex; align-items: center; gap: 0.4rem; }
.info-item strong { color: var(--gold-light); }

/* ============================================================
   ABOUT SECTION
   ============================================================ */
.section-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.section-text p:last-of-type { margin-bottom: 1.5rem; }

.section-image img {
  width: 100%;
  height: 100%;
  max-height: 500px;
  object-fit: contain;
  background: var(--cream);
  box-shadow: var(--shadow);
  border: 4px solid var(--maroon-pale);
}

/* ============================================================
   SERVICES CARDS
   ============================================================ */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.card {
  background: var(--warm-white);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}
.card:hover { transform: translateY(-4px); box-shadow: 0 8px 30px rgba(74,21,21,0.15); }
.card-icon { font-size: 2.2rem; margin-bottom: 0.75rem; }

/* ============================================================
   AMENITIES
   ============================================================ */
.amenities-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.6rem;
  margin: 2rem 0;
}
.amenities-list li {
  background: var(--warm-white);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-weight: 600;
  color: var(--text-mid);
}

.gallery-teaser {
  text-align: center;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 2px dashed var(--border);
}
.gallery-teaser p { font-size: 1.1rem; margin-bottom: 1rem; }

/* ============================================================
   CONTACT
   ============================================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-top: 2rem;
}

.contact-details li {
  margin-bottom: 0.75rem;
  color: var(--text-mid);
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--maroon-dark);
  color: rgba(255,255,255,0.8);
  padding: 3rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.site-footer strong {
  display: block;
  color: #fff;
  font-family: var(--font-head);
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.site-footer p { color: rgba(255,255,255,0.7); font-size: 0.9rem; }
.site-footer ul li { margin-bottom: 0.4rem; }
.site-footer ul a { color: rgba(255,255,255,0.7); font-size: 0.9rem; }
.site-footer ul a:hover { color: var(--gold-light); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 1.25rem;
  text-align: center;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.5);
}
.footer-bottom p { margin-bottom: 0.25rem; color: rgba(255,255,255,0.5); }

/* ============================================================
   GALLERY PAGE
   ============================================================ */
.page-hero {
  background: linear-gradient(135deg, var(--maroon-dark), var(--maroon-mid));
  color: #fff;
  text-align: center;
  padding: 4rem 1.25rem 3rem;
}
.page-hero h1 { color: #fff; margin-bottom: 0.5rem; }
.page-hero p { color: rgba(255,255,255,0.85); font-size: 1.1rem; margin: 0; }

/* Filter Bar */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
  justify-content: center;
}
.filter-btn {
  padding: 0.5rem 1.1rem;
  border: 2px solid var(--border);
  border-radius: 50px;
  background: var(--warm-white);
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--text-mid);
  transition: all var(--transition);
}
.filter-btn.active,
.filter-btn:hover {
  background: var(--maroon-mid);
  border-color: var(--maroon-mid);
  color: #fff;
}

/* Gallery Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  cursor: pointer;
  box-shadow: var(--shadow);
  aspect-ratio: 4/3;
  background: var(--border);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius);
  transition: transform 0.4s ease;
}
.gallery-item:hover img { transform: scale(1.06); }

.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 1.5rem 0.75rem 0.5rem;
  border-radius: 0 0 var(--radius) var(--radius);
  opacity: 0;
  transition: opacity var(--transition);
}
.gallery-item:hover .gallery-caption { opacity: 1; }

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.lightbox.open { display: flex; }

.lightbox-content {
  max-width: 90vw;
  max-height: 90vh;
  text-align: center;
}
.lightbox-content img {
  max-width: 90vw;
  max-height: 75vh;
  object-fit: contain;
  border-radius: var(--radius);
  box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}
#lightboxCaption {
  color: rgba(255,255,255,0.9);
  margin-top: 0.75rem;
  font-size: 1rem;
}
#lightboxCounter {
  display: block;
  color: rgba(255,255,255,0.5);
  font-size: 0.8rem;
  margin-top: 0.25rem;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: fixed;
  background: rgba(255,255,255,0.12);
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  transition: background var(--transition);
  backdrop-filter: blur(4px);
}
.lightbox-close,
.lightbox-prev,
.lightbox-next:hover { background: rgba(255,255,255,0.25); }
.lightbox-close { top: 1rem; right: 1rem; font-size: 1.8rem; }
.lightbox-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 1rem; top: 50%; transform: translateY(-50%); }

/* ============================================================
   RESPONSIVE — MOBILE
   ============================================================ */
@media (max-width: 768px) {

  .nav-toggle { display: block; }

  .main-nav {
    display: none;
    position: absolute;
    top: 70px;
    left: 0; right: 0;
    background: var(--warm-white);
    border-bottom: 2px solid var(--border);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    padding: 1rem 1.25rem;
  }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; gap: 0.25rem; }
  .main-nav ul a { padding: 0.65rem 0.75rem; font-size: 1rem; }

  .section-grid,
  .contact-grid { grid-template-columns: 1fr; gap: 2rem; }
  .section-image { order: -1; }
  .section-image img { height: 250px; }

  .info-bar { flex-direction: column; gap: 0.5rem; text-align: center; }

  .hero-slider { height: 280px; }
  .slide-overlay p { display: none; }

  .lightbox-prev { left: 0.5rem; }
  .lightbox-next { right: 0.5rem; }
}

@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: 1fr 1fr; }
  .cards-grid { grid-template-columns: 1fr; }
}

/* ---- Contact map layout ---- */
.contact-map iframe {
  width: 100%;
  height: 380px;
  border: 0;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
@media (max-width: 768px) {
  .contact-map iframe { height: 260px; }
}
