/* QUIET EARTH DESIGN SYSTEM ("Sanctuary & Trust") */

:root {
  /* Palette: Guided by User Request */
  --bg-paper: #F4F1EA;
  /* Alabaster/Parchment */
  --bg-card: #FFFFFF;

  --primary-sage: #724A73;
  /* Deep Purple - Primary */
  --accent-clay: #E07F7E;
  /* Coral - Accents */
  --accent-sand: #EDA575;
  /* Orange - Soft Accents */
  --accent-stone: #A48CBC;
  /* Lavender */
  --accent-pink: #CF80A0;
  /* Rosy Pink */
  --accent-gold: #B88A44;
  /* Darkened Warm Gold for better legibility */
  /* Warm Gold */

  --text-main: #2C2C2C;
  /* Charcoal */
  --text-muted: #595959;
  /* Slate */

  /* Typography */
  --font-heading: 'Cormorant Garamond', serif;
  /* Organic/Human */
  --font-body: 'Montserrat', sans-serif;
  /* Clean/Legible */

  /* Shapes */
  --radius-sm: 8px;
  --radius-md: 20px;
  /* Less rounded than before, more "hewn" */
  --radius-organic: 40% 60% 70% 30% / 40% 50% 60% 50%;
  /* Imperfect circle */

  /* Motion (The Exhale) */
  --ease-exhale: all 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Base Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-paper);
  color: var(--text-main);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.8;
  overflow-x: hidden;
  letter-spacing: 0.02em;
}

/* Texture Overlay (Grain) */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* Typography */
h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 400;
  color: var(--primary-sage);
  line-height: 1.2;
}

h1 {
  font-size: clamp(3rem, 6vw, 4.5rem);
  font-style: italic;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  margin-bottom: 1.5rem;
}

h3 {
  font-size: 1.5rem;
  color: var(--accent-clay);
  font-family: var(--font-body);
  /* Modern stylistic choice */
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 400;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

p {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 65ch;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--ease-exhale);
}

/* Utilities */
.container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 2rem;
}

.text-center {
  text-align: center;
}

.section-padding {
  padding: 6rem 0;
}

/* Buttons (Grounded) */
.btn-earth {
  display: inline-block;
  background-color: var(--primary-sage);
  color: #fff;
  padding: 1rem 2.5rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--primary-sage);
  cursor: pointer;
  transition: var(--ease-exhale);
}

.btn-earth:hover {
  background-color: transparent;
  color: var(--primary-sage);
}

.btn-outline {
  display: inline-block;
  background: transparent;
  border: 1px solid var(--accent-clay);
  color: var(--accent-clay);
  padding: 1rem 2.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: var(--ease-exhale);
}

.btn-outline:hover {
  border-color: var(--primary-sage);
  color: var(--primary-sage);
}

/* Navigation (Sanctuary) */
.navbar {
  padding: 0 0;
  position: absolute;
  /* Start absolute for transparency */
  top: 0;
  width: 100%;
  z-index: 1000;
  background-color: transparent;
  box-shadow: none;
  transition: padding 0.4s ease, background-color 0.4s ease, box-shadow 0.4s ease;
}

/* Paint splash pseudo-element */
.navbar::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #F3F0E9;
  /* Requested specific paint color */
  z-index: -1;
  /* Circle starts tiny, perfectly centered vertically and positioned over the logo horizontally */
  clip-path: circle(0% at 15% 50%);
  transition: clip-path 1.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Scrolled State for Sticky Navbar */
.navbar.scrolled {
  position: fixed;
  /* Stick to top when scrolling */
  padding: 0 0;
  background-color: transparent;
  /* Color is now handled by ::before */
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.navbar.scrolled::before {
  /* Expand large enough to cover the whole header */
  clip-path: circle(150% at 15% 50%);
}

.nav-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: none;
  /* Removing the bottom subtle sage line since the navbar now has a bg and shadow */
  padding-bottom: 0;
  /* Resetting padding bottom */
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  z-index: 1001;
}

.logo img {
  height: auto;
  width: 150px;
  transition: opacity 0.3s ease;
}

.logo .logo-solid {
  display: none;
}

.navbar.scrolled .logo .logo-transparent {
  display: none;
}

.navbar.scrolled .logo .logo-solid {
  display: block;
}

.logo:hover img {
  opacity: 0.8;
}

.nav-links {
  display: flex;
  gap: 2.5rem;
  align-items: center;
}

.nav-links a {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #FFFFFF;
  /* White for transparency over image */
  font-weight: 600;
  /* Bolded as requested */
  position: relative;
  transition: color 0.3s ease;
}

.navbar.scrolled .nav-links a {
  color: var(--primary-sage);
  /* Darker text on cream bg */
}

/* Nav Action Button */
.btn-nav {
  display: inline-block;
  background-color: transparent;
  color: #FFFFFF;
  padding: 0.8rem 1.8rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: var(--ease-exhale);
}

.btn-nav:hover {
  background-color: #FFFFFF;
  color: var(--primary-sage);
}

.navbar.scrolled .btn-nav {
  border-color: var(--primary-sage);
  color: var(--primary-sage);
}

.navbar.scrolled .btn-nav:hover {
  background-color: var(--primary-sage);
  color: #FFFFFF;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent-clay);
  transition: var(--ease-exhale);
}

.nav-links a:hover {
  opacity: 0.8;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

/* Hero: "Sanctuary" */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding-top: 10rem;
  padding-bottom: 6rem;
  color: #F4F1EA;
  /* Using the parchment variable base color directly */
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Image Background */
.hero-bg-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

/* Overlay for readability */
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.45);
  /* Dark overlay for text contrast */
  z-index: -1;
}

.hero-content {
  max-width: 800px;
  z-index: 1;
  padding: 0;
}

.hero-content h1 {
  font-size: clamp(3.5rem, 8vw, 6rem);
  line-height: 1.05;
  margin-bottom: 1.5rem;
  color: #FFFFFF;
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.hero-content h3 {
  color: var(--accent-gold);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  margin-bottom: 1.5rem;
}

.hero-content p {
  color: #F4F1EA;
  font-size: 1.25rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* Page Hero for Secondary Pages */
.page-hero {
  min-height: 50vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding-top: 10rem;
  padding-bottom: 5rem;
  color: #FFFFFF;
}

.page-hero h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1.1;
  color: #FFFFFF;
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.page-hero p {
  color: #F4F1EA;
  font-size: 1.1rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.page-hero h2 {
  color: var(--accent-gold);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.hero .btn-earth {
  background-color: var(--accent-gold);
  color: #FFFFFF;
  border-color: var(--accent-gold);
  font-weight: 600;
}

.hero .btn-earth:hover {
  background-color: transparent;
  color: var(--accent-gold);
}

/* About Section */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 5rem;
  align-items: start;
}

.portrait-frame {
  position: relative;
}

.portrait-img {
  width: 100%;
  border-radius: 200px 200px 0 0;
  /* Arch shape */
  filter: sepia(10%) contrast(90%);
  box-shadow: 20px 20px 0 rgba(158, 126, 107, 0.15);
  /* Soft clay shadow */
}

/* Services Cards (Grounded) */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.service-card {
  background: var(--bg-card);
  padding: 3.5rem 2.5rem;
  border: 1px solid rgba(114, 74, 115, 0.1);
  transition: var(--ease-exhale);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--accent-clay);
  transform: scaleX(0);
  transform-origin: left;
  transition: var(--ease-exhale);
}

.service-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-clay);
  box-shadow: 0 20px 40px rgba(114, 74, 115, 0.05);
}

.service-card:hover::before {
  transform: scaleX(1);
}

.price-tag {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  color: var(--primary-sage);
  display: block;
  margin: 1rem 0;
}

/* Safety Section */
.safety-box {
  border-left: 3px solid var(--accent-clay);
  padding: 0 0 0 3rem;
  margin: 4rem auto;
  max-width: 800px;
  text-align: left;
}

/* Testimonials (Clean) */
.testimonial-card {
  background: transparent;
  padding: 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.testimonial-card p {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--text-main);
  font-style: italic;
}

/* Footer (Redesigned) */
.site-footer {
  background: var(--primary-sage);
  /* Dark solid background for clear separation */
  padding: 6rem 0 3rem;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  margin-top: 5rem;
}

.footer-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 2rem;
}

.footer-logo img {
  height: 65px;
  width: auto;
  opacity: 0.9;
}

.footer-nav {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.footer-nav a {
  color: #FFFFFF;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
}

.footer-nav a:hover {
  color: var(--accent-gold);
}

.footer-socials {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}

.footer-socials a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: color 0.3s ease;
}

.footer-socials a:hover {
  color: var(--accent-gold);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  font-size: 0.85rem;
  color: #FFFFFF;
  text-align: center;
  line-height: 1.6;
}

.footer-copyright a {
  color: #FFFFFF;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.3);
  text-underline-offset: 3px;
  transition: all 0.3s ease;
}

.footer-copyright a:hover {
  color: var(--accent-gold);
  text-decoration-color: var(--accent-gold);
}

.footer-legal {
  display: flex;
  gap: 1.5rem;
}

.footer-legal a {
  color: rgba(255, 255, 255, 0.5);
  transition: color 0.3s ease;
}

.footer-legal a:hover {
  color: #FFFFFF;
}

/* Responsive Footer */
@media (max-width: 768px) {
  .footer-nav {
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 3rem;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
  }
}



/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1.2s ease-out, transform 1.2s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 900px) {
  .nav-links {
    display: none;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 2.8rem;
  }

  .section-padding {
    padding: 4rem 0;
  }

  .safety-box {
    padding: 2rem;
    border-left: none;
    border-top: 3px solid var(--accent-clay);
    text-align: center;
  }
}