/* ============================================================
   TEHILLAH LANDSCAPES — header-footer.css
   Styles for the shared Header + Footer injected by include.js.
   Self-contained: carries its own tokens + the base rules the
   header/footer need. Safe to load alongside style.css or
   subpage.css (rules are identical copies).
   ============================================================ */

:root {
  --ink:   #10140F;
  --pine:  #1A231B;
  --bone:  #EDEAE0;
  --leaf:  #8FBF6B;
  --leaf-deep: #5E8A43;
  --stone: #9AA093;
  --line:  rgba(237, 234, 224, .14);
  --line-dark: rgba(16, 20, 15, .16);

  --f-display: "Fraunces", serif;
  --f-body: "Instrument Sans", sans-serif;
  --f-mono: "Instrument Sans", sans-serif;

  --arch: 999px 999px 0 0;
  --ease: cubic-bezier(.65, .05, 0, 1);
  --wrap: 1240px;
}

/* ---------- base rules the header/footer rely on ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { overflow-x: hidden; max-width: 100%; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; background: none; border: 0; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--leaf); outline-offset: 3px; }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: 24px; }
.mono { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; }

/* pills (header + off-canvas CTAs) */
.pill {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--f-mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
  padding: .95rem 1.5rem; border-radius: 999px;
  transition: background .35s var(--ease), color .35s var(--ease), border-color .35s;
}
.pill-leaf { background: var(--leaf); color: var(--ink); }
.pill-leaf:hover { background: var(--bone); }

/* expand/collapse marker (off-canvas services accordion) */
.fx { color: var(--leaf-deep); font-family: var(--f-mono); transition: transform .3s var(--ease); }

/* ============================================================
   TOP BAR
   ============================================================ */
.top-bar {
  position: fixed; inset: 0 0 auto 0; z-index: 61;
  background: var(--leaf-deep);
  padding: 0;
}
.top-bar-in {
  display: flex; align-items: center; justify-content: center;
  height: 38px;
}
.top-bar-text {
  color: #fff; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
  text-align: center;
}

/* ============================================================
   HEADER
   ============================================================ */
.hdr {
  position: fixed; inset: 38px 0 auto 0; z-index: 60;
  border-bottom: 1px solid var(--line-dark);
  background:#ffffff;
  transition: background .4s;
}
.hdr9 {
  position: fixed; inset: 38px 0 auto 0; z-index: 60;
  border-bottom: 1px solid var(--line-dark);
  background: rgba(255, 255, 255, 0.96);
  transition: background .4s;
}
.hdr.solid { background: #ffffff;}
.hdr-in { display: flex; align-items: center; gap: 2rem; height: 86px; }
.brand { display: flex; align-items: center; gap: .8rem; }
.brand-chip {border-radius: 10px; padding: 5px 10px; display: inline-flex; }
.brand-chip img { height: 34px; }
.brand-chip { padding: 6px 12px; border-radius: 12px; }
.brand-chip img { height: 52px; }

.hdr-nav {
  display: flex; align-items: center; gap: 1.5rem;
  margin-inline: auto; flex-wrap: nowrap; height: 100%;
}
.hdr-nav a {
  font-family: var(--f-body); font-size: .92rem; letter-spacing: .01em; text-transform: none;
  color: var(--pine); padding: .4rem 0; position: relative;
  white-space: nowrap; line-height: 1;
  transition: color .3s;
}
.hdr-nav a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0;
  height: 1px; background: var(--leaf-deep);
  transition: right .35s var(--ease);
}
.hdr-nav a:hover, .hdr-nav a.on { color: var(--leaf-deep); }
.hdr-nav a:hover::after, .hdr-nav a.on::after { right: 0; }

/* --- Services dropdown --- */
.nav-drop { position: relative; display: flex; align-items: center; height: 86px; }
.nav-drop > .drop-toggle {
  font-family: var(--f-body); font-size: .92rem; letter-spacing: .01em; text-transform: none;
  color: var(--pine); padding: .4rem 0; display: inline-flex; align-items: center; gap: .35rem;
  white-space: nowrap; line-height: 1;
  transition: color .3s;
}
.drop-caret { font-size: .6rem; transition: transform .3s var(--ease); }
.nav-drop:hover > .drop-toggle, .nav-drop:focus-within > .drop-toggle { color: var(--leaf-deep); }
.nav-drop:hover .drop-caret, .nav-drop:focus-within .drop-caret { transform: rotate(180deg); }
.drop-menu {
  position: absolute; top: 100%; left: 50%; transform: translate(-50%, 8px);
  min-width: 280px; padding: .7rem 0;
  background: var(--pine); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0,0,0,.45);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .3s var(--ease) .12s, transform .3s var(--ease) .12s, visibility .3s .12s;
  max-height: min(70vh, 560px); overflow: auto;
}

.nav-drop:hover .drop-menu, .nav-drop:focus-within .drop-menu {
  opacity: 1; visibility: visible; pointer-events: auto; transform: translate(-50%, 0);
  transition-delay: 0s;
}
.drop-menu a {
  display: block; padding: .55rem 1.3rem;
  font-size: .84rem; color: var(--stone);
  border-left: 2px solid transparent;
  transition: color .25s, background .25s, border-color .25s, padding-left .25s var(--ease);
}
.drop-menu a:hover { color: var(--bone); background: rgba(143,191,107,.08); border-left-color: var(--leaf); padding-left: 1.55rem; }
.drop-menu .drop-all { margin-top: .4rem; border-top: 1px solid var(--line); padding-top: .8rem; color: var(--leaf); font-family: var(--f-mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; }
.drop-menu .drop-all:hover { color: var(--ink); background: var(--leaf); }

/* Active state for services dropdown toggle */
.nav-drop.active > .drop-toggle { color: var(--leaf-deep); }
.nav-drop.active > .drop-toggle::after { right: 0; }

.hdr-right { display: flex; align-items: center; gap: 1.2rem; }
.hdr-tel { color: var(--pine); transition: color .3s; }
.hdr-tel:hover { color: var(--leaf-deep); }

.burger { display: none; flex-direction: column; gap: 6px; padding: .6rem .2rem; }
.burger span { width: 26px; height: 2px; background: var(--pine); transition: transform .35s var(--ease), opacity .3s; }
.burger[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* --- Off-canvas menu (mobile) --- */
.oc-backdrop {
  position: fixed; inset: 0; z-index: 9998;
  background: rgba(6, 8, 5, .6); backdrop-filter: blur(3px);
  opacity: 0; visibility: hidden;
  transition: opacity .35s var(--ease), visibility .35s;
}
.oc-backdrop.show { opacity: 1; visibility: visible; }
.offcanvas {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 9999;
  width: min(86vw, 360px);
  background: var(--pine); border-left: 1px solid var(--line);
  display: flex; flex-direction: column;
  transform: translateX(100%);
  transition: transform .42s var(--ease);
  overscroll-behavior: contain;
}
.offcanvas.open { transform: none; box-shadow: -30px 0 80px rgba(0,0,0,.5); }
.oc-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 1.2rem; border-bottom: 1px solid var(--line);
}
.oc-close {
  width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%;
  font-size: .9rem; transition: all .3s var(--ease);
}
.oc-close:hover { background: var(--leaf); border-color: var(--leaf); color: var(--ink); }
.oc-links { flex: 1; overflow-y: auto; padding: .6rem 1.2rem; }
.oc-links > a, .oc-sub-t {
  display: flex; align-items: center; width: 100%;
  font-family: var(--f-mono); font-weight: 600; font-size: 1.00rem;
  padding: .85rem 0; border-bottom: 1px solid var(--line);
  text-align: left; transition: color .3s, padding-left .3s var(--ease);
}
.oc-links > a:hover, .oc-sub-t:hover { color: var(--leaf); padding-left: .4rem; }

/* ── Mobile nav active state ── */
.oc-links > a.on { color: var(--leaf); padding-left: .4rem; }
.oc-links > a.on::before {
  content: "";
  display: inline-block;
  width: 5px; height: 5px;
  background: var(--leaf);
  border-radius: 50%;
  margin-right: .5rem;
  flex-shrink: 0;
}
.oc-sub-t.on { color: var(--leaf); }

.oc-sub-t .fx { color: var(--leaf); }
.oc-sub-t[aria-expanded="true"] .fx { transform: rotate(45deg); }
.oc-sub-m {
  display: grid; overflow: hidden; max-height: 0;
  transition: max-height .45s var(--ease);
  border-bottom: 1px solid var(--line);
}
.oc-sub-m.open { max-height: 640px; }
.oc-sub-m a {
  font-size: .88rem; color: var(--stone);
  padding: .55rem 0 .55rem 1rem; border-left: 2px solid var(--line);
  margin-left: .2rem;
  transition: color .25s, border-color .25s, padding-left .25s var(--ease);
}
.oc-sub-m a:first-child { margin-top: .5rem; }
.oc-sub-m a:last-child { margin-bottom: .8rem; }
.oc-sub-m a:hover { color: var(--leaf); border-left-color: var(--leaf); padding-left: 1.25rem; }
.oc-sub-m a.on { color: var(--leaf); border-left-color: var(--leaf); }
.oc-sub-m .drop-all { color: var(--leaf); font-family: var(--f-mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; }
.oc-foot { display: grid; gap: .7rem; padding: 1.1rem 1.2rem 1.4rem; border-top: 1px solid var(--line); }
.oc-foot .mono { color: var(--stone); text-transform: none; letter-spacing: .02em; font-size: .78rem; }
.oc-foot .mono:hover { color: var(--leaf); }
.oc-foot .pill { justify-content: center; }

/* ============================================================
   FOOTER
   ============================================================ */
.ftr { background: #F8F6EF; border-top: 1px solid var(--line-dark); padding: clamp(56px, 8vw, 90px) 0 28px; overflow: hidden; }
.ftr-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 2.5rem; }
.ftr-brand p { color: #444; font-size: .9rem; margin: 1rem 0 1.3rem; max-width: 30ch; }
.ftr-social { display: flex; gap: .6rem; }
.ftr-social a {
  width: 42px; height: 42px; border: 1px solid var(--leaf-deep); border-radius: 50%;
  background: var(--leaf-deep); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .3s var(--ease);
}
.ftr-social a:hover { background: transparent; border-color: var(--leaf-deep); color: var(--leaf-deep); }
.ftr-col { display: grid; gap: .55rem; align-content: start; }
.ftr-col h4 { color: var(--leaf-deep); margin-bottom: .5rem; font-weight: 400; }
.ftr-col a { color: #444; font-size: .9rem; transition: color .3s; width: fit-content; }
.ftr-col a:hover { color: var(--pine); }
.ftr-col.mono a, .ftr-col.mono span { text-transform: none; letter-spacing: .02em; font-size: .78rem; color: #555; }

/* ── Footer nav links — Font Awesome angle-right ── */
.ftr-link {
  display: flex !important;
  align-items: center;
  gap: .5rem;
  width: fit-content;
  color: #444;
  font-size: .9rem;
  line-height: 1.5;
  transition: color .28s, padding-left .22s;
}
.ftr-link .ftr-icon {
  color: var(--leaf-deep);
  font-size: .72rem;
  width: 12px;
  flex-shrink: 0;
  transition: color .28s, transform .22s;
}
.ftr-link:hover { color: var(--pine); padding-left: .25rem; }
.ftr-link:hover .ftr-icon { color: var(--leaf-deep); transform: translateX(3px); }

/* ── Footer contact column ── */
.ftr-contact-link {
  display: flex;
  align-items: flex-start;
  gap: .65rem;
  color: #555;
  font-size: .85rem;
  line-height: 1.55;
  text-transform: none;
  letter-spacing: 0;
  transition: color .28s;
}
.ftr-contact-link .ftr-icon {
  color: var(--leaf-deep);
  font-size: .82rem;
  width: 14px;
  text-align: center;
  flex-shrink: 0;
  margin-top: .22rem;
}
.ftr-contact-link span { overflow-wrap: anywhere; }
a.ftr-contact-link:hover { color: var(--pine); }
a.ftr-contact-link:hover .ftr-icon { color: var(--pine); }

/* ── Footer bar — centered copyright only ── */
.ftr-bar {
  margin-top: clamp(2.5rem, 5vw, 4rem); padding-top: 1.4rem;
  border-top: 1px solid var(--line-dark);
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: .8rem;
  background: #F8F6EF; color: #555;
  text-align: center;
}
.ftr-bar a:hover { color: var(--leaf-deep); }

.to-top {
  position: fixed; right: 22px; bottom: 22px; z-index: 50;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--leaf); color: var(--ink);
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: all .35s var(--ease);
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }

/* ============================================================
   RESPONSIVE (header/footer only)
   ============================================================ */
@media (max-width: 1240px) {
  .hdr-in { gap: 1.2rem; }
  .hdr-nav { gap: 1.05rem; }
  .hdr-nav a, .nav-drop > .drop-toggle { font-size: .74rem; letter-spacing: .06em; }
  .hdr-tel { display: none; }
}

@media (max-width: 900px) {
  .hdr-nav, .hdr-tel { display: none; }
  .burger { display: flex; }
  /* Hide desktop top bar on small screens (mobile pages use their own bar) */
  .top-bar { display: none; }
  .hdr { top: 0; }
}

/* ── Footer: 2-column on tablet ── */
@media (max-width: 768px) {
  .ftr-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

/* ── Footer: full single column on mobile ── */
@media (max-width: 480px) {
  .ftr-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .ftr-brand { text-align: left; }
  .ftr-social { justify-content: flex-start; }
  .ftr-col { gap: .8rem; }
  .ftr-bar { font-size: .7rem; }
  .hdr .pill { display: none; }
}

@media (max-width: 640px) {
  .hdr .pill { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: .01ms !important; }
}
/* --- phone icon in header + call pills --- */
@media (min-width: 1241px) {
  .hdr-tel { display: inline-flex; align-items: center; gap: .45rem; white-space: nowrap; }
}
.hdr-tel svg { width: 14px; height: 14px; flex: none; color: var(--leaf); }
.hdr-tel:hover svg { color: inherit; }
.pill svg { width: 14px; height: 14px; flex: none; }

/* --- footer social symbol icons --- */
.ftr-social a svg { width: 18px; height: 18px; display: block; }

/* --- floating contact buttons (call + email) --- */
.float-contact {
  position: fixed; left: 18px; bottom: 18px; z-index: 55;
  display: flex; flex-direction: column; gap: 10px;
}
.float-contact a {
  width: 50px; height: 50px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 26px rgba(0, 0, 0, .38);
  transition: transform .3s var(--ease), background .3s, color .3s, border-color .3s;
}
.float-contact a svg { width: 21px; height: 21px; }
.float-contact .fc-call { background: var(--leaf); color: var(--ink); border: 1px solid var(--leaf); }
.float-contact .fc-mail { background: var(--pine); color: var(--leaf); border: 1px solid var(--leaf-deep); }
.float-contact a:hover { transform: translateY(-3px); }
.float-contact .fc-call:hover { background: var(--bone); border-color: var(--bone); }
.float-contact .fc-mail:hover { background: var(--leaf); color: var(--ink); border-color: var(--leaf); }
@media (max-width: 640px) {
  .float-contact { left: 12px; bottom: 12px; }
  .float-contact a { width: 46px; height: 46px; }
}
