/* ============================================================
   Dovetail Mediation — stylesheet
   Aesthetic: editorial-warm. Cream + forest + clay.
   Type: Fraunces (display) + Lora (body).
   ============================================================ */

:root {
  /* Color */
  --ink:        #1f1d1a;
  --ink-soft:   #4a463f;
  --ink-mute:   #7a7368;
  --cream:      #f5efe2;
  --cream-soft: #ebe3d2;
  --cream-deep: #e0d6bf;
  --paper:      #faf6ed;
  --forest:     #2d4a3e;
  --forest-deep:#1f3a30;
  --clay:       #b6843e;
  --clay-soft:  #d4a866;
  --rule:       rgba(31, 29, 26, 0.12);

  /* Type */
  --display: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
  --body:    'Lora', Georgia, 'Times New Roman', serif;

  /* Layout */
  --gutter:  clamp(1.25rem, 4vw, 2.5rem);
  --section: clamp(4.5rem, 10vw, 8rem);
  --max:     1240px;
}

/* ---- Reset ---- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

body {
  font-family: var(--body);
  font-size: clamp(1rem, 0.95vw + 0.6rem, 1.0625rem);
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--forest); color: var(--cream); }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1rem var(--gutter);
  background: rgba(245, 239, 226, 0.86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-shrink: 0;
}
.brand-mark {
  width: 52px;
  height: 38px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.brand-mark svg,
.brand-mark img { width: 100%; height: 100%; object-fit: contain; }
.brand-words {
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.brand-name {
  font-family: var(--display);
  font-style: italic;
  font-weight: 500;
  font-size: 1.45rem;
  color: var(--forest);
  letter-spacing: -0.01em;
}
.brand-tag {
  font-family: var(--body);
  font-weight: 500;
  font-size: 0.66rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-top: 4px;
}

.primary-nav { margin-left: auto; }
.primary-nav ul { display: flex; gap: 2.25rem; }
.primary-nav a {
  font-size: 0.95rem;
  color: var(--ink-soft);
  position: relative;
  padding-bottom: 2px;
  transition: color 0.2s ease;
}
.primary-nav a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--forest);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.25s ease;
}
.primary-nav a:hover { color: var(--forest); }
.primary-nav a:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 32px;
  height: 32px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.25s, opacity 0.25s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.85em 1.6em;
  font-family: var(--body);
  font-size: 0.94rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  background: var(--forest);
  color: var(--cream);
  border: 1px solid var(--forest);
  border-radius: 999px;
  transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}
.cta:hover {
  background: var(--forest-deep);
  border-color: var(--forest-deep);
  transform: translateY(-1px);
}
.cta-ghost {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}
.cta-ghost:hover {
  background: var(--forest);
  color: var(--cream);
}
.cta-header { padding: 0.7em 1.3em; font-size: 0.88rem; }

/* ============================================================
   COMMON
   ============================================================ */
.eyebrow {
  font-family: var(--body);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--clay);
  margin-bottom: 1.5rem;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(4rem, 10vw, 8rem) var(--gutter) clamp(4rem, 9vw, 7rem);
}
.hero-inner {
  position: relative;
  z-index: 2;
  max-width: var(--max);
  margin: 0 auto;
}

.hero h1 {
  font-family: var(--display);
  font-weight: 350;
  font-size: clamp(2.4rem, 6.4vw, 5.25rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
  color: var(--ink);
  max-width: 14ch;
  margin-bottom: 2rem;
}
.hero h1 em {
  display: block;
  font-style: italic;
  font-weight: 350;
  color: var(--forest);
}

.hero .lede {
  font-size: clamp(1.08rem, 1.05vw + 0.5rem, 1.28rem);
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 36em;
  margin-bottom: 2.75rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-watermark {
  position: absolute;
  top: 50%;
  right: -8%;
  width: clamp(380px, 50vw, 720px);
  aspect-ratio: 130 / 90;
  transform: translateY(-50%) rotate(-6deg);
  color: var(--forest);
  opacity: 0.06;
  pointer-events: none;
  z-index: 1;
}
.hero-watermark svg { width: 100%; height: 100%; }

/* ============================================================
   ABOUT
   ============================================================ */
.about {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
  padding: var(--section) var(--gutter);
  max-width: var(--max);
  margin: 0 auto;
  border-top: 1px solid var(--rule);
}

.about-image {
  position: sticky;
  top: 7rem;
}
.about-image img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 2px;
  filter: saturate(0.92) contrast(1.02);
}
.about-image .caption {
  margin-top: 1rem;
  font-family: var(--display);
  font-style: italic;
  font-size: 0.96rem;
  color: var(--ink-mute);
  text-align: center;
  letter-spacing: 0.01em;
}

.about-content h2 {
  font-family: var(--display);
  font-weight: 350;
  font-style: italic;
  font-size: clamp(1.85rem, 3.5vw, 2.85rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  color: var(--forest);
  margin-bottom: 2rem;
  max-width: 22ch;
}

.about-content p {
  font-size: 1.05rem;
  line-height: 1.72;
  color: var(--ink-soft);
  margin-bottom: 1.25rem;
}

.credentials {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  display: grid;
  gap: 0.6rem;
}
.credentials li {
  font-size: 0.96rem;
  line-height: 1.5;
  color: var(--ink-soft);
  padding-left: 1.5rem;
  position: relative;
}
.credentials li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--clay);
}

/* ============================================================
   SERVICES
   ============================================================ */
.services {
  background: var(--cream-soft);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: var(--section) var(--gutter);
}
.services-inner {
  max-width: var(--max);
  margin: 0 auto;
}

.services h2 {
  font-family: var(--display);
  font-weight: 350;
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 4rem;
  max-width: 16ch;
}
.services h2 em {
  font-style: italic;
  color: var(--forest);
  font-weight: 350;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.service {
  background: var(--cream);
  padding: 2.75rem 2rem 2.5rem;
  border-radius: 3px;
  border: 1px solid var(--rule);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.service:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(31, 29, 26, 0.07);
  border-color: rgba(45, 74, 62, 0.25);
}

.service-num {
  display: inline-block;
  font-family: var(--display);
  font-style: italic;
  font-weight: 400;
  font-size: 1.4rem;
  color: var(--clay);
  margin-bottom: 1.2rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--rule);
}

.service h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.55rem;
  line-height: 1.18;
  margin-bottom: 1rem;
  color: var(--forest);
  letter-spacing: -0.005em;
}

.service p {
  font-size: 0.99rem;
  line-height: 1.65;
  color: var(--ink-soft);
}

/* ============================================================
   PROCESS
   ============================================================ */
.process {
  padding: var(--section) var(--gutter);
  max-width: var(--max);
  margin: 0 auto;
}

.process h2 {
  font-family: var(--display);
  font-weight: 350;
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 4rem;
  max-width: 16ch;
  font-style: italic;
  color: var(--forest);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(2rem, 4vw, 3.5rem);
  position: relative;
}
.steps::before {
  content: '';
  position: absolute;
  top: 1.5rem;
  left: 11%;
  right: 11%;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--rule) 12%, var(--rule) 88%, transparent);
  z-index: 0;
}

.step {
  position: relative;
  z-index: 1;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: var(--cream);
  border: 1px solid var(--forest);
  color: var(--forest);
  font-family: var(--display);
  font-style: italic;
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}

.step h3 {
  font-family: var(--display);
  font-size: 1.4rem;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: var(--ink);
}

.step p {
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink-soft);
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact {
  background: var(--forest);
  color: var(--cream);
  text-align: center;
  padding: var(--section) var(--gutter);
  position: relative;
  overflow: hidden;
}
.contact::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at top left, rgba(178, 90, 60, 0.18), transparent 55%),
    radial-gradient(ellipse at bottom right, rgba(245, 239, 226, 0.06), transparent 55%);
  pointer-events: none;
}
.contact > * { position: relative; z-index: 1; }

.contact .eyebrow { color: var(--clay-soft); }

.contact h2 {
  font-family: var(--display);
  font-weight: 350;
  font-style: italic;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}

.contact-lede {
  font-size: clamp(1.05rem, 1vw + 0.5rem, 1.2rem);
  margin-bottom: 3rem;
  color: rgba(245, 239, 226, 0.78);
  max-width: 28em;
  margin-left: auto;
  margin-right: auto;
}

.contact-info {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.25rem;
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(1.1rem, 1.4vw + 0.4rem, 1.55rem);
  margin-bottom: 2rem;
}

.contact-info a {
  color: var(--cream);
  border-bottom: 1px solid rgba(245, 239, 226, 0.35);
  padding-bottom: 2px;
  transition: border-color 0.2s, color 0.2s;
}
.contact-info a:hover {
  color: var(--clay-soft);
  border-color: var(--clay-soft);
}

.dot {
  display: inline-block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--cream);
  opacity: 0.45;
}

.contact-aside {
  font-family: var(--body);
  font-size: 0.92rem;
  color: rgba(245, 239, 226, 0.6);
  margin-top: 0.5rem;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  padding: 3.5rem var(--gutter) 2.5rem;
  background: var(--cream);
  border-top: 1px solid var(--rule);
  font-size: 0.88rem;
  color: var(--ink-mute);
}

.foot-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  max-width: var(--max);
  margin: 0 auto;
}

.foot-brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.foot-brand .brand-name {
  font-family: var(--display);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--forest);
}
.foot-brand .brand-tag {
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-top: 3px;
}
.foot-brand .brand-words {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.foot-info { line-height: 1.65; text-align: right; }
.foot-info a {
  border-bottom: 1px solid var(--rule);
  transition: border-color 0.2s;
}
.foot-info a:hover { border-color: var(--forest); }

.foot-copy {
  max-width: var(--max);
  margin: 2.5rem auto 0;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  font-size: 0.78rem;
  line-height: 1.55;
  text-align: center;
  color: var(--ink-mute);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 880px) {
  .primary-nav, .cta-header { display: none; }
  .nav-toggle { display: flex; }

  .primary-nav.is-open {
    display: block;
    position: fixed;
    top: 70px;
    left: 0; right: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--rule);
    padding: 2rem var(--gutter);
  }
  .primary-nav.is-open ul {
    flex-direction: column;
    gap: 1.5rem;
  }

  .about {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .about-image { position: static; max-width: 320px; margin: 0 auto; }

  .service-grid { grid-template-columns: 1fr; }
  .steps {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .steps::before { display: none; }

  .foot-grid { flex-direction: column; align-items: flex-start; }
  .foot-info { text-align: left; }
}

@media (max-width: 500px) {
  .hero h1 { font-size: clamp(2rem, 9vw, 2.8rem); }
  .brand-tag { display: none; }
  .brand-name { font-size: 1.3rem; }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
