/*
Theme Name: Springfield Supportive Living
Theme URI: https://example.com
Author: Your Community
Description: A warm, accessible WordPress theme for senior living and care communities. Hero, service cards, team spotlight, video CTA, and a two-location footer, styled around a prairie-inspired palette.
Version: 1.0
Requires PHP: 7.4
Text Domain: ssl
*/

/* ==========================================================================
   DESIGN TOKENS
   Palette grounded in Central Illinois prairie: deep evergreen (mature
   shade trees), wheat gold (autumn prairie grass), warm brick clay
   (Springfield's brick storefronts), soft cream (open sky/light).
   ========================================================================== */

:root{
  --evergreen:      #2F4538;
  --evergreen-dark:  #202F26;
  --wheat:          #D9B382;
  --wheat-light:    #F1E4CC;
  --clay:           #B5573A;
  --clay-dark:      #94432B;
  --cream:          #F7F3EC;
  --ink:            #292623;
  --ink-soft:       #57534C;
  --line:           #E3DACB;
  --white:          #FFFFFF;

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* Base font size is intentionally larger than typical defaults —
     this audience (and their adult children) reads more comfortably
     at 18px+ body copy. */
  --fs-base: 1.125rem;
  --radius: 6px;
  --shadow-soft: 0 8px 30px rgba(41,38,35,0.08);
  --container: 1200px;
}

/* ==========================================================================
   RESET & BASE
   ========================================================================== */

*, *::before, *::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin:0;
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

img{ max-width:100%; display:block; }

a{ color: var(--clay); text-decoration:none; }
a:hover{ color: var(--clay-dark); }

h1,h2,h3,h4{
  font-family: var(--font-display);
  color: var(--evergreen-dark);
  line-height:1.15;
  margin:0 0 0.5em;
  font-weight: 600;
}

h1{ font-size: clamp(2.4rem, 5vw, 3.8rem); }
h2{ font-size: clamp(1.9rem, 3.4vw, 2.6rem); }
h3{ font-size: 1.4rem; }

p{ margin:0 0 1.2em; }

.container{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* Visible keyboard focus everywhere */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible{
  outline: 3px solid var(--clay);
  outline-offset: 3px;
}

.skip-link{
  position:absolute; left:-999px; top:auto;
  background: var(--evergreen); color:#fff; padding: 12px 20px;
  z-index: 10000; border-radius: var(--radius);
}
.skip-link:focus{ left: 16px; top: 16px; }

@media (prefers-reduced-motion: reduce){
  *{ animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* ==========================================================================
   SIGNATURE ELEMENT: the horizon line
   A thin gold rule with a small rising/setting circle — used as a section
   divider and echoed subtly in the button underline. Represents the flat
   prairie skyline this community sits on.
   ========================================================================== */

.horizon{
  position: relative;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--wheat) 15%, var(--wheat) 85%, transparent);
  margin: 0 auto;
  max-width: 220px;
}
.horizon::after{
  content:"";
  position:absolute;
  top:50%; left:50%;
  width:10px; height:10px;
  background: var(--clay);
  border-radius:50%;
  transform: translate(-50%,-50%);
}

/* ==========================================================================
   TOP UTILITY BAR
   ========================================================================== */

.top-bar{
  background: var(--evergreen-dark);
  color: var(--wheat-light);
  font-size: 0.9rem;
}
.top-bar .container{
  display:flex; justify-content:flex-end; gap: 28px;
  padding-top:8px; padding-bottom:8px;
  flex-wrap: wrap;
}
.top-bar a{ color: var(--wheat-light); }
.top-bar a:hover{ color: var(--wheat); }

/* ==========================================================================
   HEADER / NAV
   ========================================================================== */

.site-header{
  background: var(--evergreen);
  position: relative;
  z-index: 100;
}
.site-header .container{
  display:flex;
  align-items:center;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
  gap: 24px;
}
.site-branding{
  display:flex;
  align-items:center;
  gap:12px;
}
.site-branding a{ display:flex; align-items:center; gap:12px; color:#fff; }
.site-title{
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: #fff;
  margin:0;
  letter-spacing: 0.01em;
}
.site-logo img{ max-height: 52px; width:auto; }

.primary-nav ul{
  list-style:none; margin:0; padding:0;
  display:flex; align-items:center; gap: 6px;
}
.primary-nav li{ position:relative; }
.primary-nav a{
  color: var(--wheat-light);
  display:block;
  padding: 10px 14px;
  font-weight: 600;
  font-size: 0.98rem;
  border-radius: var(--radius);
}
.primary-nav a:hover,
.primary-nav a:focus-visible{ color: #fff; background: rgba(255,255,255,0.08); }

.primary-nav .sub-menu{
  list-style:none;
  position:absolute; top: 100%; left:0;
  background: var(--white);
  min-width: 240px;
  padding: 8px;
  margin:0;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  opacity:0; visibility:hidden; transform: translateY(6px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
}
.primary-nav li:hover > .sub-menu,
.primary-nav li:focus-within > .sub-menu{
  opacity:1; visibility:visible; transform: translateY(0);
}
.primary-nav .sub-menu a{ color: var(--ink); padding: 10px 12px; }
.primary-nav .sub-menu a:hover{ background: var(--cream); color: var(--clay-dark); }

.header-cta{
  display:inline-block;
  background: var(--clay);
  color:#fff !important;
  padding: 12px 22px;
  border-radius: var(--radius);
  font-weight:700;
  white-space: nowrap;
  border-bottom: 2px solid var(--wheat);
}
.header-cta:hover{ background: var(--clay-dark); }

.menu-toggle{
  display:none;
  background:none; border:none; color:#fff;
  font-size: 1.8rem; cursor:pointer;
  padding: 4px 8px;
}

@media (max-width: 960px){
  .menu-toggle{ display:block; }
  .primary-nav{
    display:none;
    position:absolute; top:100%; left:0; right:0;
    background: var(--evergreen);
    padding: 12px 24px 24px;
  }
  .primary-nav.is-open{ display:block; }
  .primary-nav ul{ flex-direction:column; align-items:stretch; }
  .primary-nav .sub-menu{
    position:static; opacity:1; visibility:visible; transform:none;
    box-shadow:none; background: rgba(255,255,255,0.06); display:none;
  }
  .primary-nav li.is-expanded .sub-menu{ display:block; }
  .header-cta{ margin-top: 10px; text-align:center; }
}

/* ==========================================================================
   HERO
   ========================================================================== */

.hero{
  background: linear-gradient(180deg, var(--evergreen) 0%, var(--evergreen-dark) 100%);
  color: var(--wheat-light);
  padding: 96px 0 110px;
  position: relative;
  overflow:hidden;
}
.hero::before{
  /* prairie horizon glow */
  content:"";
  position:absolute; left:0; right:0; bottom:0;
  height: 140px;
  background: radial-gradient(60% 100% at 50% 100%, rgba(217,179,130,0.25), transparent 70%);
}
.hero .container{ position:relative; }
.hero-inner{ max-width: 720px; }
.hero-eyebrow{
  display:inline-block;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.82rem;
  font-weight:700;
  color: var(--wheat);
  margin-bottom: 18px;
}
.hero h1{ color:#fff; }
.hero p.lede{ font-size: 1.25rem; color: var(--wheat-light); max-width: 62ch; }
.hero-actions{ display:flex; gap:16px; margin-top: 32px; flex-wrap:wrap; }

.btn{
  display:inline-flex; align-items:center; gap:8px;
  font-weight:700; padding: 15px 28px; border-radius: var(--radius);
  border: 2px solid transparent; cursor:pointer; font-size: 1rem;
  font-family: var(--font-body);
}
.btn-primary{ background: var(--clay); color:#fff; border-bottom: 3px solid var(--wheat); }
.btn-primary:hover{ background: var(--clay-dark); color:#fff; }
.btn-outline{ background:transparent; color:#fff; border-color: rgba(255,255,255,0.5); }
.btn-outline:hover{ border-color:#fff; background: rgba(255,255,255,0.08); color:#fff; }

/* ==========================================================================
   SECTION SPACING / EYEBROW PATTERN
   ========================================================================== */

.section{ padding: 88px 0; }
.section-cream{ background: var(--cream); }
.section-white{ background: var(--white); }
.section-evergreen{ background: var(--evergreen); color: var(--wheat-light); }
.section-evergreen h2{ color:#fff; }

.section-head{ text-align:center; max-width: 680px; margin: 0 auto 56px; }
.eyebrow{
  display:block;
  text-transform: uppercase; letter-spacing:0.14em; font-size:0.82rem;
  font-weight:700; color: var(--clay); margin-bottom: 14px;
}

/* ==========================================================================
   INTRO / SPLIT (image + text)
   ========================================================================== */

.split{
  display:grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items:center;
}
.split img{ border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.split.reverse .split-media{ order:2; }

@media (max-width: 860px){
  .split{ grid-template-columns: 1fr; gap: 32px; }
  .split.reverse .split-media{ order:0; }
}

/* ==========================================================================
   SERVICES GRID
   ========================================================================== */

.services-grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
@media (max-width: 960px){ .services-grid{ grid-template-columns: repeat(2,1fr); } }
@media (max-width: 620px){ .services-grid{ grid-template-columns: 1fr; } }

.service-card{
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px 28px;
  transition: transform .2s ease, box-shadow .2s ease;
}
.service-card:hover{ transform: translateY(-4px); box-shadow: var(--shadow-soft); }
.service-icon{
  width:56px; height:56px; border-radius:50%;
  background: var(--wheat-light);
  display:flex; align-items:center; justify-content:center;
  margin-bottom:18px;
  font-size:1.6rem;
}
.service-card h3{ margin-bottom:10px; }
.service-card p{ color: var(--ink-soft); margin-bottom: 18px; }
.service-link{ font-weight:700; color: var(--clay); }
.service-link:hover{ color: var(--clay-dark); }

/* ==========================================================================
   VIDEO / CTA BAND
   ========================================================================== */

.video-band{
  position: relative;
  border-radius: var(--radius);
  overflow:hidden;
  background: var(--evergreen-dark);
  min-height: 420px;
  display:flex; align-items:center; justify-content:center;
  text-align:center;
  color:#fff;
}
.video-band img{
  position:absolute; inset:0; width:100%; height:100%; object-fit:cover; opacity:0.55;
}
.video-band-inner{ position:relative; z-index:2; padding: 24px; }
.play-btn{
  width:78px; height:78px; border-radius:50%;
  background: var(--clay);
  color:#fff; font-size:1.6rem;
  display:flex; align-items:center; justify-content:center;
  margin: 0 auto 18px;
  border: 3px solid rgba(255,255,255,0.7);
}

/* ==========================================================================
   FINAL CTA
   ========================================================================== */

.final-cta{ text-align:center; }
.final-cta h2{ margin-bottom: 8px; }
.final-cta p{ color: var(--wheat-light); font-size:1.15rem; }

/* ==========================================================================
   FOOTER
   ========================================================================== */

.site-footer{ background: var(--evergreen-dark); color: var(--wheat-light); padding-top: 72px; }
.footer-grid{
  display:grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
@media (max-width: 860px){ .footer-grid{ grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px){ .footer-grid{ grid-template-columns: 1fr; } }

.footer-grid h4{
  color: var(--wheat);
  font-family: var(--font-body);
  text-transform: uppercase; letter-spacing:0.1em; font-size:0.85rem;
  margin-bottom: 18px;
}
.footer-grid ul{ list-style:none; margin:0; padding:0; }
.footer-grid li{ margin-bottom: 10px; }
.footer-grid a{ color: var(--wheat-light); }
.footer-grid a:hover{ color:#fff; }

.footer-locations{ display:flex; flex-direction:column; gap: 20px; }
.footer-location h5{ margin:0 0 4px; color:#fff; font-family: var(--font-body); font-weight:700; }
.footer-location p{ margin:0; color: var(--wheat-light); font-size:0.95rem; }
.footer-location a{ font-weight:700; }

.footer-bottom{
  padding: 24px 0 32px;
  font-size: 0.88rem;
  color: rgba(241,228,204,0.7);
  display:flex; justify-content:space-between; flex-wrap:wrap; gap:10px;
}

/* ==========================================================================
   GENERIC PAGE CONTENT (page.php)
   ========================================================================== */

.page-hero{
  background: var(--evergreen);
  color:#fff;
  padding: 64px 0;
  text-align:center;
}
.page-hero h1{ color:#fff; margin-bottom:0; }
.entry-content{ max-width: 760px; margin: 0 auto; padding: 64px 24px; }
.entry-content img{ border-radius: var(--radius); margin: 24px 0; }
.entry-content h2{ margin-top:1.4em; }
