/* keyes-site.css — FOUND LEGACY TEAM at Keyes · shared site styles
 *
 * Loaded by every public page (after its own <style>), so it owns only what
 * must be identical everywhere: the static Keyes co-brand lockup, the Keyes
 * legal footer, and a couple of type fixes for the Keyes fonts.
 *
 * Keyes palette (brandguidelines.keyes.com/color):
 *   Everglade Green #044439 · Miami Sands #F3D8BE · Delray Beach #F7F3E5
 *   Coral Blush #FBBFA7 (secondary, sparing) · Team accent: Crimson Violet #59133A
 * Keyes type: Instrument Serif (headlines) + Plus Jakarta Sans (everything else)
 */

/* Instrument Serif ships a single weight. Many page styles ask headings for
   600/700 (a holdover from Playfair) — without this, browsers fake-bold it
   and it smears. Style synthesis stays on for any italic fallbacks. */
html { font-synthesis-weight: none; }

/* ── Static logo: FOUND LEGACY TEAM mark | Keyes wordmark ─────────────
   The team's key + FOUND / LEGACY TEAM logo (horizontal version), a thin
   rule, then the official Keyes wordmark. Plain <img>s, no JS, so the
   brokerage name can't go missing. FREC: the Keyes mark must never render
   smaller than the team logo — keep .kf-keyes at least as tall as .kf-mark. */
.kf-lockup {
  display: inline-flex; align-items: center; gap: .8rem;
  text-decoration: none; white-space: nowrap; line-height: 1;
}
.kf-lockup .kf-mark, .kf-lockup .kf-keyes { height: 38px; width: auto; display: block; }
.kf-lockup .kf-rule { width: 1px; height: 28px; background: #044439; opacity: .45; flex-shrink: 0; }
/* Before nav.js renders (or if it never does), show the lockup inside the
   empty fixed header so the page is never un-branded. */
#site-nav > .kf-lockup { margin: 0; }
#site-nav:not(:has(.sn-logo)) {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000; height: 68px;
  display: flex; align-items: center; padding: 0 4vw;
  background: #F7F3E5; border-bottom: 1px solid rgba(4,68,57,.12);
}

/* ── Keyes legal footer ─────────────────────────────────────────────── */
.kf-footer {
  background: #044439; color: rgba(247,243,229,.78); border-top: 5px solid #59133A;
  font-family: 'Plus Jakarta Sans', Arial, sans-serif; letter-spacing: -.01em;
  padding: clamp(3rem, 6vw, 4.5rem) 5vw 1.8rem; text-align: left; margin: 0;
}
.kf-footer *, .kf-footer *::before, .kf-footer *::after { box-sizing: border-box; }
.kf-footer .kf-wrap { max-width: 1240px; margin: 0 auto; }
.kf-footer a { color: inherit; }
.kf-footer .kf-top {
  display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(2, minmax(0, 1fr));
  gap: 2.5rem; padding-bottom: 2.6rem; border-bottom: 1px solid rgba(247,243,229,.14);
}
.kf-footer .kf-logo { display: inline-block; margin-bottom: 1.3rem; }
.kf-footer .kf-logo img { width: 168px; height: auto; display: block; }
.kf-footer .kf-lockup .kf-rule { background: #F7F3E5; opacity: .5; }
.kf-footer .kf-brand p { font-size: .88rem; line-height: 1.6; max-width: 20rem; margin: 0; color: rgba(247,243,229,.78); }
.kf-footer h4 {
  font-family: 'Plus Jakarta Sans', Arial, sans-serif; font-size: .66rem; font-weight: 600;
  letter-spacing: .13em; text-transform: uppercase; color: #F3D8BE; margin: 0 0 1rem;
}
.kf-footer .kf-col a {
  display: block; font-size: .9rem; color: rgba(247,243,229,.82); text-decoration: none;
  margin-bottom: .6rem; transition: color .2s; letter-spacing: -.01em; text-transform: none;
}
.kf-footer .kf-col a:hover { color: #FBBFA7; }
.kf-footer .kf-col a.kf-addr { line-height: 1.5; margin-top: .9rem; color: rgba(247,243,229,.7); }
.kf-footer .kf-legal {
  padding-top: 1.7rem; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1.2rem 3rem; align-items: start;
}
.kf-footer .kf-legal p { font-size: .72rem; line-height: 1.6; color: rgba(247,243,229,.58); max-width: 62rem; margin: 0; }
.kf-footer .kf-legal p + p { margin-top: .8rem; }
.kf-footer .kf-legal .kf-office { color: rgba(247,243,229,.85); font-weight: 600; font-size: .76rem; }
.kf-footer .kf-eho {
  display: inline-flex; align-items: center; gap: .45rem; font-size: .7rem; font-weight: 600;
  letter-spacing: .06em; color: rgba(247,243,229,.7); white-space: nowrap;
}
.kf-footer .kf-bottom {
  margin-top: 1.4rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: .75rem;
  font-size: .74rem; color: rgba(247,243,229,.5);
}
.kf-footer .kf-bottom a { color: rgba(247,243,229,.6); text-decoration: none; }
.kf-footer .kf-bottom a:hover { color: #FBBFA7; }
@media (max-width: 1080px) {
  .kf-footer .kf-top { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kf-footer .kf-brand { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .kf-footer .kf-top { grid-template-columns: 1fr 1fr; }
  .kf-footer .kf-legal { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  .kf-footer .kf-top { grid-template-columns: 1fr; }
}

/* Compact variant — for app-style pages whose body doesn't scroll (search.html
   locks body overflow for its map layout), placed inside the scrolling results
   panel so the brokerage identification + MLS disclaimer are still reachable. */
.kf-footer.kf-compact { padding: 1.8rem 1.4rem 1.4rem; margin-top: 1rem; }
.kf-footer.kf-compact .kf-lockup { margin-bottom: 1rem; }
.kf-footer.kf-compact .kf-lockup .kf-mark, .kf-footer.kf-compact .kf-lockup .kf-keyes { height: 32px; }
.kf-footer.kf-compact .kf-lockup .kf-rule { height: 24px; }
.kf-footer.kf-compact .kf-legal { grid-template-columns: 1fr; padding-top: 0; }
.kf-footer.kf-compact .kf-legal p { font-size: .68rem; }
.kf-footer.kf-compact .kf-bottom { flex-direction: column; gap: .4rem; }

/* ── Crimson Violet (#59133A) accents — the team colour ───────────────
   Keyes' primary palette carries the brand; Crimson Violet marks the team's
   own moments: the booking CTAs, a signature stripe under every green page
   header, and the footer's top edge. */
.hero:not(.home-hero), .team-hero { box-shadow: inset 0 -6px 0 #59133A; }

/* Booking / showing buttons on listing, neighborhood and guide pages */
.agent-cta, .agent-btn:not(.secondary), .nav-book {
  background: #59133A !important; border-color: #59133A !important; color: #F7F3E5 !important;
}
.agent-cta:hover, .agent-btn:not(.secondary):hover, .nav-book:hover {
  background: #044439 !important; border-color: #044439 !important; color: #F7F3E5 !important;
}

/* ── Language blocks ───────────────────────────────────────────────────
   Pages with hand-written Spanish put it in .es next to the English .en;
   lang.js sets <html lang>. (Everything else is translated by lang.js.) */
html[lang="es"] .en { display: none !important; }
html:not([lang="es"]) .es { display: none !important; }
/* "This legal document is English-only" note on privacy/terms (light page headers) */
.kf-es-notice {
  display: block !important; margin: 1.1rem 0 0 !important; padding: .8rem 1.1rem !important;
  max-width: 40rem; font-size: .9rem !important; line-height: 1.55 !important; text-align: left;
  border-left: 3px solid #59133A; border-radius: 0 10px 10px 0; background: rgba(243,216,190,.45); color: #16312B !important;
}
.kf-es-notice a { color: inherit; }

/* ── Motion ────────────────────────────────────────────────────────────
   Progressive only: every page is fully visible without JS, nav.js hides
   nothing that's already on screen, and visitors who ask their OS for
   reduced motion get a still page. Hooks (added by nav.js):
     .kf-rv / .kf-in   scroll reveal for blocks that start below the fold
     .kf-enter          staggered entrance for a sub-page's header block
     .kf-glow           soft light that follows the pointer on green/crimson bands */
@keyframes kfRise  { from { opacity: 0; transform: translate3d(0, 26px, 0); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes kfLine  { from { opacity: 0; clip-path: inset(0 0 100% 0); transform: translate3d(0, 34%, 0); } to { opacity: 1; clip-path: inset(-25% -10% -35% -10%); transform: none; } }
@keyframes kfSheen { from { background-position: 100% 0; } to { background-position: 0 0; } }
@keyframes kfFloat { 0%, 100% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(0, -7px, 0); } }
@keyframes kfDrift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(-7%, 9%, 0) scale(1.18); } }
@keyframes kfSweep { from { transform: translateX(-130%) skewX(-18deg); } to { transform: translateX(260%) skewX(-18deg); } }

/* Pointer light (static setup; it only shows on hover) */
.kf-glow { position: relative; isolation: isolate; }
.kf-glow::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(560px circle at var(--kf-mx, 50%) var(--kf-my, 50%), rgba(247,243,229,.10), transparent 62%);
  opacity: 0; transition: opacity .5s ease;
}
.kf-glow:hover::before { opacity: 1; }

/* Homepage hero ambience: two soft light fields behind the content */
.home-hero { position: relative; isolation: isolate; overflow: clip; }
.home-hero::before, .home-hero::after {
  content: ""; position: absolute; z-index: -1; border-radius: 50%; pointer-events: none;
}
.home-hero::before {
  width: min(56vw, 760px); aspect-ratio: 1; right: -10vw; top: -18%;
  background: radial-gradient(closest-side, rgba(243,216,190,.95), rgba(243,216,190,0));
}
.home-hero::after {
  width: min(40vw, 520px); aspect-ratio: 1; left: -12vw; bottom: -30%;
  background: radial-gradient(closest-side, rgba(89,19,58,.10), rgba(89,19,58,0));
}

/* Buttons: a quick sweep of light on hover */
.kf-sweep { position: relative; overflow: hidden; isolation: isolate; }
.kf-sweep::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 45%; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.28), transparent);
  transform: translateX(-130%) skewX(-18deg);
}

@media (prefers-reduced-motion: no-preference) {
  .kf-rv { opacity: 0; transform: translate3d(0, 30px, 0); filter: blur(6px); }
  .kf-rv.kf-in {
    opacity: 1; transform: none; filter: none;
    transition: opacity .9s cubic-bezier(.2,.7,.2,1), transform 1.05s cubic-bezier(.2,.7,.2,1), filter .9s ease;
    transition-delay: var(--kf-d, 0ms);
  }
  .kf-enter { animation: kfRise .95s cubic-bezier(.2,.7,.2,1) var(--kf-d, 0ms) both; }

  html.kf-motion .home-hero h1.display { animation: kfLine 1.15s cubic-bezier(.2,.7,.2,1) .12s both; }
  html.kf-motion .home-hero h1.display em {
    background: linear-gradient(100deg, #59133A 0%, #59133A 40%, #C4789A 50%, #59133A 60%, #59133A 100%);
    background-size: 300% 100%; background-position: 100% 0;
    -webkit-background-clip: text; background-clip: text; color: transparent;
    padding-right: .08em; margin-right: -.08em;
    animation: kfSheen 1.5s cubic-bezier(.4,0,.2,1) 1.15s both;
  }
  html.kf-motion .home-hero .name-card { animation: kfFloat 7s ease-in-out 1.6s infinite; }
  html.kf-motion .home-hero::before { animation: kfDrift 18s ease-in-out infinite alternate; }
  html.kf-motion .home-hero::after  { animation: kfDrift 22s ease-in-out -6s infinite alternate-reverse; }

  .kf-sweep:hover::after, .kf-sweep:focus-visible::after { animation: kfSweep .75s cubic-bezier(.4,0,.2,1); }
  .kf-sweep:active { transform: scale(.97); }
  .kf-lift { transition: transform .45s cubic-bezier(.2,.7,.2,1), box-shadow .45s ease; }
  .kf-lift:hover { transform: translateY(-4px); box-shadow: 0 26px 46px -30px rgba(4,68,57,.55); }
}

@media print {
  .kf-rv { opacity: 1 !important; transform: none !important; filter: none !important; }
}
