/*
Theme Name: Overeaters Anonymous San Fernando Valley v2
Theme URI: https://oasfvalley.org/
Author: Overeaters Anonymous San Fernando Valley
Description: A welcoming, accessible, journey-first theme for Overeaters Anonymous San Fernando Valley.
Version: 0.35.100
Requires at least: 6.6
Requires PHP: 7.4
Text Domain: oasf-valley-v2
*/

:root {
  --ink: #17312f;
  --ink-soft: #47625f;
  --paper: #fbf8f0;
  --paper-deep: #f1eadb;
  --white: #fff;
  --sage: #dce7dc;
  --sage-dark: #285e52;
  --ocean: #0f6470;
  --sun: #e9a65b;
  --coral: #d46b53;
  --line: rgba(23, 49, 47, .16);
  --shadow: 0 18px 55px rgba(34, 65, 60, .13);
  --radius: 1.4rem;
  --wrap: min(1160px, calc(100% - 2rem));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1.05rem;
  line-height: 1.65;
}
body.menu-open { overflow: hidden; }
a { color: var(--ocean); text-underline-offset: .18em; }
a:hover { color: var(--coral); }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 {
  margin: 0 0 .6em;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.08;
  letter-spacing: -.025em;
}
h1 { font-size: clamp(3rem, 8vw, 6.8rem); }
h2 { font-size: clamp(2.2rem, 5vw, 4rem); }
h3 { font-size: clamp(1.35rem, 3vw, 1.8rem); }
p { margin: 0 0 1.2em; }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 4px; }
.wrap { width: var(--wrap); margin-inline: auto; }
.narrow { width: min(760px, calc(100% - 2rem)); margin-inline: auto; }
.eyebrow {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--sage-dark);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.skip-link {
  position: fixed; z-index: 1000; top: .75rem; left: .75rem;
  padding: .7rem 1rem; background: var(--ink); color: #fff;
  transform: translateY(-180%);
}
.skip-link:focus { transform: none; }

.site-header { position: relative; z-index: 20; border-bottom: 1px solid var(--line); background: rgba(251,248,240,.94); }
.header-inner { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: flex; align-items: center; gap: .8rem; color: var(--ink); text-decoration: none; }
.brand-mark {
  display: grid; place-items: center; width: 46px; aspect-ratio: 1; border-radius: 50%;
  color: #fff; background: var(--ocean); font-family: Georgia, serif; font-size: 1.2rem;
}
.brand-text { display: grid; line-height: 1.15; }
.brand-text strong { font-family: Georgia, serif; font-size: 1.1rem; }
.brand-text span { color: var(--ink-soft); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; }
.nav-row { display: flex; align-items: center; gap: 1.5rem; }
.primary-nav ul { display: flex; align-items: center; gap: 1.25rem; margin: 0; padding: 0; list-style: none; }
.primary-nav a { color: var(--ink); font-size: .92rem; font-weight: 700; text-decoration: none; }
.primary-nav a:hover { color: var(--ocean); }
.menu-toggle { display: none; border: 0; background: transparent; color: var(--ink); font: inherit; font-weight: 800; }
.button, .wp-block-button__link {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  min-height: 48px; padding: .72rem 1.15rem; border: 2px solid var(--ocean); border-radius: 999px;
  color: #fff; background: var(--ocean); font-weight: 800; text-decoration: none;
}
.button:hover, .wp-block-button__link:hover { color: #fff; background: var(--ink); border-color: var(--ink); }
.button-outline { color: var(--ink); background: transparent; border-color: var(--ink); }
.button-light { color: var(--ink); background: var(--white); border-color: var(--white); }

.hero { position: relative; overflow: hidden; padding: clamp(5rem, 10vw, 9rem) 0 6rem; }
.hero::before {
  content: ""; position: absolute; width: 42rem; height: 42rem; right: -14rem; top: -18rem;
  border-radius: 46% 54% 65% 35%; background: var(--sage); transform: rotate(18deg);
}
.hero-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(300px, .65fr); align-items: center; gap: clamp(2rem, 6vw, 6rem); }
.hero h1 span { display: block; color: var(--ocean); font-style: italic; }
.hero-copy > p { max-width: 650px; color: var(--ink-soft); font-size: clamp(1.1rem, 2vw, 1.35rem); }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.hope-card { position: relative; padding: 2rem; border: 1px solid var(--line); border-radius: 48% 48% var(--radius) var(--radius); background: var(--white); box-shadow: var(--shadow); }
.hope-card::before { content: ""; display: block; width: 74px; height: 7px; margin: .5rem auto 2rem; border-radius: 99px; background: var(--sun); }
.hope-card blockquote { margin: 0; font: 1.55rem/1.35 Georgia, serif; }
.hope-card cite { display: block; margin-top: 1rem; color: var(--ink-soft); font: 700 .8rem/1.4 Inter, sans-serif; letter-spacing: .08em; text-transform: uppercase; }

.journeys { padding: 5rem 0; background: var(--white); }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 2rem; margin-bottom: 2.2rem; }
.section-heading p { max-width: 560px; color: var(--ink-soft); }
.card-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.journey-card { min-height: 270px; display: flex; flex-direction: column; padding: 1.5rem; border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); background: var(--paper); text-decoration: none; transition: transform .2s ease, box-shadow .2s ease; }
.journey-card:nth-child(2) { background: #edf3f1; }
.journey-card:nth-child(3) { background: #fff2e4; }
.journey-card:nth-child(4) { background: #f7ebe7; }
.journey-card:hover { color: var(--ink); transform: translateY(-6px); box-shadow: var(--shadow); }
.card-number { margin-bottom: auto; color: var(--ocean); font-size: .75rem; font-weight: 900; letter-spacing: .12em; }
.journey-card p { color: var(--ink-soft); font-size: .94rem; }
.card-link { font-weight: 800; }

.meeting-band { padding: 5rem 0; color: #fff; background: var(--ocean); }
.meeting-grid { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 4rem; }
.meeting-band .eyebrow, .meeting-band p { color: rgba(255,255,255,.78); }
.meeting-list { display: grid; gap: .75rem; }
.meeting-item { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 1.15rem; border: 1px solid rgba(255,255,255,.24); border-radius: 1rem; background: rgba(255,255,255,.08); }
.meeting-item strong { display: block; }
.meeting-item span { color: rgba(255,255,255,.72); font-size: .9rem; }

.recovery { padding: 6rem 0; }
.feature-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 1rem; }
.feature { min-height: 360px; padding: clamp(1.5rem, 4vw, 3rem); border-radius: var(--radius); background: var(--sage); }
.feature-secondary { background: var(--paper-deep); }
.feature p { max-width: 540px; color: var(--ink-soft); }
.link-list { margin: 2rem 0 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.link-list a { display: flex; justify-content: space-between; padding: .9rem 0; border-bottom: 1px solid var(--line); color: var(--ink); font-weight: 800; text-decoration: none; }

.newsletter { padding: 5rem 0; border-block: 1px solid var(--line); background: var(--white); text-align: center; }
.newsletter p { max-width: 600px; margin-inline: auto; color: var(--ink-soft); }
.site-main:not(.home-main) { min-height: 60vh; padding: 4rem 0 6rem; }
.entry-header { margin-bottom: 2rem; }
.entry-title { font-size: clamp(2.5rem, 6vw, 4.5rem); }
.entry-content > * { max-width: 760px; margin-left: auto; margin-right: auto; }
.entry-content > .alignwide { max-width: 1160px; }
.entry-content > .alignfull { max-width: none; }
.post-card { padding: 1.4rem 0; border-bottom: 1px solid var(--line); }

.hub-hero { position: relative; overflow: hidden; padding: clamp(1rem, 4vw, 3rem) 0 5rem; text-align: center; }
.hub-hero::after {
  content: ""; position: absolute; z-index: -1; width: 18rem; height: 18rem; right: -8rem; bottom: -8rem;
  border-radius: 44% 56% 41% 59%; background: var(--sage); transform: rotate(28deg);
}
.hub-lead { max-width: 720px; margin-inline: auto; color: var(--ink-soft); font-size: clamp(1.15rem, 2.4vw, 1.45rem); }
.hub-hero .actions { justify-content: center; }
.hub-cards { padding: 0 0 6rem; }
.hub-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.hub-card { min-height: 290px; display: flex; flex-direction: column; padding: 1.7rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.hub-card:nth-child(2) { background: #edf3f1; }
.hub-card:nth-child(3) { background: #fff2e4; }
.hub-card .card-number { margin-bottom: auto; }
.hub-card p { color: var(--ink-soft); }
.text-link { margin-top: auto; color: var(--ink); font-weight: 800; text-decoration: none; }
.hub-details { padding: 5rem clamp(1rem, 5vw, 4rem); border-radius: var(--radius); background: var(--paper-deep); }
.step-list { display: grid; margin: 2rem 0 0; padding: 0; list-style: none; counter-reset: hub-step; border-top: 1px solid var(--line); }
.step-list li { counter-increment: hub-step; display: grid; grid-template-columns: 74px 1fr; gap: 1rem; padding: 1.6rem 0; border-bottom: 1px solid var(--line); }
.step-list li::before { content: "0" counter(hub-step); color: var(--ocean); font-size: .8rem; font-weight: 900; letter-spacing: .1em; }
.step-list h3 { margin-bottom: .3rem; }
.step-list p { max-width: 720px; margin: 0; color: var(--ink-soft); }
.hub-editor { padding: 5rem 0 0; }
.hub-editor-content > * { max-width: 100%; }
.hub-service-signup { padding: clamp(3rem, 6vw, 5rem) 1rem; scroll-margin-top: 7rem; background: var(--paper); }
.hub-service-signup .oasf-intake { margin-block: 0; }
.empty-state { margin-top: 2rem; padding: 2rem; border: 1px dashed var(--line); border-radius: 1rem; background: rgba(255,255,255,.45); }
.empty-state p { margin: 0; color: var(--ink-soft); }
.hub-callout { margin: 5rem 0 0; padding: 3rem 1rem; border-radius: var(--radius); color: #fff; background: var(--ocean); text-align: center; }
.hub-callout p { margin: 0; font: clamp(1.45rem, 3vw, 2.1rem)/1.35 Georgia, serif; }

.site-footer { padding: 4rem 0 2rem; color: #fff; background: var(--ink); }
.footer-grid { display: grid; grid-template-columns: 1.3fr .7fr .7fr; gap: 3rem; }
.site-footer a { color: #fff; }
.footer-title { font-size: 1.5rem; }
.footer-links { margin: 0; padding: 0; list-style: none; }
.footer-links li { margin-bottom: .55rem; }
.footer-note { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,.18); color: rgba(255,255,255,.68); font-size: .82rem; }

@media (max-width: 768px) {
  .menu-toggle { display: inline-flex; }
  .header-cta { display: none; }
  .primary-nav { display: none; position: absolute; inset: 88px 0 auto; padding: 1rem; background: var(--paper); border-bottom: 1px solid var(--line); }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { align-items: stretch; flex-direction: column; gap: 0; }
  .primary-nav a { display: block; padding: .8rem; }
}

@media (max-width: 900px) {
  .hero-grid, .meeting-grid, .feature-grid { grid-template-columns: 1fr; }
  .hero::before { opacity: .65; }
  .hope-card { max-width: 520px; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .hub-card-grid { grid-template-columns: 1fr; }
  .hub-card { min-height: 240px; }
}
@media (max-width: 600px) {
  .brand-text span { display: none; }
  .hero { padding-top: 4rem; }
  .card-grid, .footer-grid { grid-template-columns: 1fr; }
  .section-heading { align-items: start; flex-direction: column; }
  .meeting-item { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
/* Operator identity and readable policy details. */
.organization-address{font-style:normal;line-height:1.6;margin:.5rem 0;overflow-wrap:anywhere;}
.footer-office-contact .organization-address{font-size:14px;margin:.25rem 0;color:#fff;}
.footer-environment{color:#eeb57e;font-size:.8rem;}
.hub-contact-details h2{font-size:clamp(1.35rem,2vw,1.65rem);line-height:1.3;}
.hub-contact-details p{margin:.65rem 0;}
.policy-review-notice{margin:1.5rem 0;padding:1rem 1.2rem;border-left:3px solid var(--cm-orange);background:var(--cm-mist);font-size:.95rem;line-height:1.6;}
.policy-review-notice p{margin:.5rem 0 0;}
.policy-table-wrap code{overflow-wrap:anywhere;word-break:break-word;}
.interior-article .entry-content .policy-table-wrap table{display:table;min-width:40rem;overflow:visible;}
.policy-table-wrap:focus-visible{outline:3px solid var(--cm-orange);outline-offset:3px;}
.policy-table-hint{font-size:.9rem;color:var(--cm-olive);}
/* Align the live caption to the artwork's visible gold line, not its white image margins. */
.brand .brand-lockup--wordmark-only{display:block;width:max-content;max-width:100%;aspect-ratio:auto;padding-right:.65rem;}
.brand .brand-lockup--wordmark-only .brand-lockup__wordmark{display:block;position:relative;width:104.2553%;margin-left:-2.2667%;aspect-ratio:782 / 282;background-position:right top;background-size:148.5946% auto;}
.brand-lockup__registration{position:absolute;right:-.7em;top:56%;font-size:clamp(.625rem,.85vw,.875rem);font-weight:600;line-height:1;color:#34472f;}
.brand-lockup__service-body{display:block;margin-top:.5rem;color:#34472f;font-size:.6875rem;font-weight:500;letter-spacing:normal;line-height:1.3;text-align:center;text-wrap:balance;overflow-wrap:normal;}
@media(min-width:901px){.site-header .header-inner .brand{width:min(360px,calc(100vw - 455px));}}
@media(max-width:900px){.site-header .header-inner{padding-block:.75rem;}.site-header .header-inner .brand{width:210px;flex-shrink:0;}.brand .brand-lockup--wordmark-only{width:100%;}.brand-lockup__name,.brand-lockup__fellowship{display:block;}}
@media(max-width:560px){.site-header .header-inner{padding-block:.75rem;column-gap:.75rem;}.site-header .header-inner .brand{width:180px;}.site-header .header-language-label{display:none;}.site-header .header-language-toggle{width:44px;min-width:44px;padding:0;justify-content:center;}.site-header .header-inner .nav-row{gap:.5rem;}}
@media(max-width:380px){.site-header .header-inner{flex-wrap:wrap;row-gap:.5rem;}.site-header .header-inner .nav-row{width:100%;justify-content:flex-end;}}
/* Start contact links on the shared content edge; allow wrapping before overflow. */
body .office-contact-strip .wrap{justify-content:flex-start;}
@media(max-width:600px){body .office-contact-strip .wrap{flex-wrap:wrap;gap:4px 16px;padding-inline:0;}}
