/*
Theme Name: Purity Local
Theme URI: https://puritylocal.com
Author: Safina Studio
Author URI: https://safinastudio.com
Description: Classic WordPress theme for Purity Local — a virtual marketplace and community platform for Muslim and Arab communities in the USA. Warm-editorial design system (Fraunces + Satoshi, green/sand/gold palette) ported from the locked rebuild brief. All home-page, About, Services, and Contact copy is transcribed verbatim from the live site crawl. Requires Contact Form 7 for the contact form; WooCommerce, Dokan, wp-event-manager, and UsersWP are styled, never forked.
Version: 1.0.1
Requires at least: 5.5
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: purity
Tags: community, marketplace, e-commerce, custom-menu, custom-logo, block-patterns, translation-ready
*/

/* ============================================================================
   Purity Local — style.css (tokens + all components, single source of truth)
   Palette/type per BRIEF §Design system (locked). Warm-paper editorial calm.
   Zero third-party runtime requests: fonts self-hosted woff2 only.
   ============================================================================ */
:root {
  --ink:       #182720;  /* text                                              */
  --green:     #1E5B44;  /* primary actions / links / CTA fills               */
  --green-deep:#143D2E;  /* hover + dark bands                                */
  --sand:      #F7F2E8;  /* alternating section wash                          */
  --ground:    #FCFAF5;  /* page background                                   */
  --gold:      #C19A2E;  /* sparing accent — markers, underlines              */
  --line:      rgba(24,39,32,.14);

  --r: 8px;              /* softened sharp */
  --ease: .3s ease-in-out;

  --container: 1160px;
  --section-pad: 4.5rem;
  --section-pad-lg: 7rem;

  --font-sans:  'Satoshi', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-arabic:'Amiri', 'Scheherazade New', serif; /* single Arabic touch */
}

/* ── Self-hosted fonts (byte-identical copies; no third-party requests) ── */
@font-face {
  font-family: 'Fraunces';
  src: url('assets/fonts/Fraunces-SemiBold.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Fraunces';
  src: url('assets/fonts/Fraunces-SemiBoldItalic.woff2') format('woff2');
  font-weight: 600; font-style: italic; font-display: swap;
}
@font-face {
  font-family: 'Satoshi';
  src: url('assets/fonts/Satoshi-Regular.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Satoshi';
  src: url('assets/fonts/Satoshi-Medium.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Satoshi';
  src: url('assets/fonts/Satoshi-Bold.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  font-weight: 400;
  color: var(--ink);
  background: var(--ground);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, picture, svg, video { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: none; }
a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }
::selection { background: var(--gold); color: var(--ink); }

:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 2px; }

/* ── Headings (Fraunces SemiBold, tight tracking) ── */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.12;
  color: var(--ink);
  letter-spacing: -0.015em;
}
h1 { font-size: clamp(2.2rem, 4.2vw, 3.4rem); }
h2 { font-size: clamp(1.7rem, 2.8vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 1.7vw, 1.45rem); }
h4 { font-size: 1.08rem; }
p { max-width: 66ch; }
p + p { margin-top: 1em; }

/* ── Layout primitives ── */
.container { max-width: var(--container); margin-inline: auto; padding-inline: 2rem; }
.section { padding: var(--section-pad) 2rem; }
.section.alt { background: var(--sand); }
.section.lg { padding: var(--section-pad-lg) 2rem; }
.section-head { margin-bottom: 2.5rem; }
[id] { scroll-margin-top: 96px; }

.eyebrow {
  display: inline-block; font-weight: 700;
  font-size: .78rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--green); margin-bottom: .9rem;
}
.eyebrow-gold { color: #7a611c; } /* AA-safe gold-on-paper tone for text */
.lead { font-size: clamp(1.05rem, 1.5vw, 1.25rem); color: rgba(24,39,32,.82); }
.section-head .lead { margin-top: .75rem; }

/* ── Buttons ── */
.btn {
  display: inline-block; padding: .8rem 1.6rem; border-radius: var(--r);
  font-weight: 700; font-size: .95rem; line-height: 1.2;
  border: 1.5px solid transparent; transition: background var(--ease), color var(--ease), border-color var(--ease);
}
.btn:hover { text-decoration: none; }
.btn-green { background: var(--green); color: #FCFAF5; }
.btn-green:hover { background: var(--green-deep); color: #FCFAF5; }
.btn-outline { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-outline:hover { border-color: var(--green); color: var(--green); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: #a8862a; color: #FCFAF5; }
.btn-ghost-light { border-color: rgba(252,250,245,.5); color: #FCFAF5; }
.btn-ghost-light:hover { border-color: #FCFAF5; color: #FCFAF5; }

/* ── Cards ── */
.card {
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--r);
  padding: 1.75rem; transition: border-color var(--ease), transform var(--ease), box-shadow var(--ease);
}
a.card:hover { border-color: var(--green); text-decoration: none; transform: translateY(-3px); box-shadow: 0 10px 28px rgba(24,39,32,.08); }
.card h3 { margin-bottom: .5rem; }
.card p { color: rgba(24,39,32,.78); }
.card .more { font-weight: 700; color: var(--green); font-size: .9rem; }
.card .more::after { content: " →"; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

/* ── Skip link ── */
.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 200;
  background: var(--green); color: #FCFAF5; padding: .7rem 1.2rem;
  border-radius: var(--r); font-weight: 700; transition: top var(--ease);
}
.skip-link:focus { top: 1rem; color: #FCFAF5; text-decoration: none; }

/* ── Header ── */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(252,250,245,.92); backdrop-filter: blur(10px);
  border-bottom: 1.5px solid transparent;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); box-shadow: 0 4px 18px rgba(24,39,32,.05); }
.header-inner {
  max-width: var(--container); margin-inline: auto; padding: .85rem 2rem;
  display: flex; align-items: center; gap: 1.5rem;
}
.brand { display: flex; align-items: center; gap: .7rem; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand img, .brand svg { height: 40px; width: auto; }
.brand-wordmark { font-family: var(--font-serif); font-weight: 600; letter-spacing: -0.015em; font-size: 1.3rem; line-height: 1.05; }
.brand-wordmark small { display: block; font-family: var(--font-sans); font-weight: 500; font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; color: var(--green); margin-top: .15rem; }

.main-nav { margin-left: auto; }
.main-nav ul { list-style: none; padding: 0; margin: 0; display: flex; gap: .35rem; flex-wrap: wrap; }
.main-nav a {
  display: block; padding: .5rem .8rem; font-weight: 500; font-size: .92rem;
  color: var(--ink); border-radius: 6px; border-bottom: 2px solid transparent;
}
.main-nav a:hover { color: var(--green); text-decoration: none; }
.main-nav .current-menu-item > a,
.main-nav .current_page_item > a { color: var(--green); border-bottom-color: var(--gold); }

.header-actions { display: flex; align-items: center; gap: .9rem; }
.header-actions .chrome-link { font-size: .88rem; font-weight: 700; color: var(--ink); display: inline-flex; align-items: center; gap: .35rem; }
.header-actions .chrome-link:hover { color: var(--green); text-decoration: none; }
.header-actions .btn { padding: .55rem 1.1rem; font-size: .88rem; }

.hamburger {
  display: none; padding: .5rem .9rem; border: 1.5px solid var(--line);
  border-radius: var(--r); font-weight: 700; font-size: .9rem; color: var(--ink);
}
.mobile-nav { display: none; }

@media (max-width: 980px) {
  .main-nav, .header-actions .chrome-link { display: none; }
  .hamburger { display: inline-block; margin-left: auto; }
  .header-actions { margin-left: auto; }
  .main-nav { margin-left: 0; }
  .mobile-nav.open { display: block; }
  .mobile-nav {
    border-top: 1.5px solid var(--line); background: var(--ground);
  }
  .mobile-nav ul { list-style: none; padding: .75rem 2rem 1.25rem; margin: 0; }
  .mobile-nav li + li { border-top: 1.5px solid var(--line); }
  .mobile-nav a { display: block; padding: .85rem .25rem; font-weight: 500; color: var(--ink); }
}

/* ── Hero ── */
.hero { padding: calc(var(--section-pad-lg)) 2rem var(--section-pad); }
.hero-inner { max-width: var(--container); margin-inline: auto; }
.hero h1 .accent { font-style: italic; color: var(--green); }
.hero-desc { margin-top: 1.25rem; }
.hero-spirit {
  margin-top: 1.5rem; padding: 1.25rem 1.5rem;
  border-left: 3px solid var(--gold); background: var(--sand); border-radius: 0 var(--r) var(--r) 0;
}
.hero-spirit p { font-size: .98rem; color: rgba(24,39,32,.82); max-width: 58ch; }
.hero-spirit p + p { margin-top: .5rem; }
.hero-btns { margin-top: 1.75rem; display: flex; gap: .9rem; flex-wrap: wrap; }

/* ── Section markers / stats ── */
.num-marker {
  font-family: var(--font-serif); font-weight: 600; font-size: 1.1rem;
  color: var(--ink); background: var(--gold); border-radius: 6px;
  width: 2.6rem; height: 2.6rem; display: grid; place-items: center; flex: none;
}
.stat-item { display: flex; gap: 1.1rem; align-items: flex-start; padding: 1.4rem 0; border-bottom: 1.5px solid var(--line); }
.stat-item:last-child { border-bottom: none; }
.stat-item p { font-size: 1.05rem; font-weight: 500; margin: 0; max-width: 52ch; }

/* ── Event / update cards ── */
.meta-line { font-size: .8rem; letter-spacing: .06em; text-transform: uppercase; color: rgba(24,39,32,.55); font-weight: 700; }
.card .meta-line { margin-bottom: .6rem; }
.card .excerpt { margin: 0; }

/* ── Shop teaser cards (typographic, people-light) ── */
.shop-card-tag {
  display: inline-block; font-size: .7rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--green); border: 1.5px solid var(--gold);
  border-radius: 99px; padding: .18rem .7rem; margin-bottom: .9rem;
}
.shop-card .arabic { font-family: var(--font-arabic); font-size: 1.5rem; color: var(--green); margin-bottom: .4rem; }
.shop-card-cta {
  display: flex; flex-direction: column; justify-content: center;
  background: var(--sand); border: 1.5px dashed var(--green); text-align: left;
}

/* ── Quote / testimonials ── */
.stars { color: var(--gold); font-size: 1.2rem; letter-spacing: .22rem; margin-bottom: .8rem; }
.testimonial blockquote { font-family: var(--font-serif); font-style: italic; font-size: 1.12rem; color: var(--ink); margin: 0; }
.testimonial cite { display: block; margin-top: .8rem; font-style: normal; font-weight: 700; font-size: .88rem; color: rgba(24,39,32,.65); }

/* ── Dark bands (CTA) ── */
.cta-band { background: var(--green-deep); color: #FCFAF5; padding: var(--section-pad-lg) 2rem; }
.cta-band .container { text-align: center; }
.cta-band h2 { color: #FCFAF5; max-width: 22ch; margin-inline: auto; }
.cta-band p { color: rgba(252,250,245,.82); margin: 1rem auto 0; max-width: 58ch; }
.cta-band .hero-btns { justify-content: center; }
.cta-band .btn-outline { border-color: rgba(252,250,245,.4); color: #FCFAF5; }
.cta-band .btn-outline:hover { border-color: #FCFAF5; }

/* ── Page hero (interior pages) ── */
.page-hero { padding: var(--section-pad) 2rem calc(var(--section-pad)*.6); background: var(--sand); }
.page-hero-inner { max-width: var(--container); margin-inline: auto; }
.breadcrumbs { font-size: .8rem; letter-spacing: .05em; color: rgba(24,39,32,.55); margin-bottom: .9rem; }
.breadcrumbs a { color: var(--green); }

/* ── Forms (theme classes; CF7 forms authored to use them — see readme.txt) ── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.field { display: flex; flex-direction: column; gap: .4rem; }
.field.full { grid-column: 1 / -1; }
.field label { font-weight: 700; font-size: .88rem; }
.field .req { color: var(--green); }
.field input, .field textarea, .field select {
  padding: .75rem .9rem; border: 1.5px solid var(--line); border-radius: var(--r);
  background: #fff; width: 100%;
}
.field input:focus, .field textarea:focus { border-color: var(--green); outline: none; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.proto-form-note { font-size: .9rem; color: rgba(24,39,32,.65); }

/* Contact info rows */
.contact-row { display: flex; gap: 1rem; align-items: flex-start; padding: 1rem 0; border-bottom: 1.5px solid var(--line); }
.contact-row:last-child { border-bottom: none; }
.cic { color: var(--green); flex: none; margin-top: .15rem; }
.contact-row h3 { font-size: 1rem; margin-bottom: .15rem; }

/* ── Blog listing (updates/events) ── */
.post-card { display: flex; flex-direction: column; }
.post-card .meta-line { margin-bottom: .6rem; }
.post-card h2 { font-size: 1.45rem; }
.post-card h2 a { color: var(--ink); }
.post-card h2 a:hover { color: var(--green); text-decoration: none; }
.post-card .excerpt { color: rgba(24,39,32,.75); margin: .6rem 0 1.1rem; }
.pagination, .nav-links { margin-top: 2.5rem; display: flex; gap: .8rem; flex-wrap: wrap; justify-content: center; }
.nav-links a, .nav-links span.current {
  padding: .45rem .9rem; border: 1.5px solid var(--line); border-radius: var(--r); font-size: .9rem; font-weight: 700;
}
.nav-links span.current { background: var(--green); color: #FCFAF5; border-color: var(--green); }

/* ── Footer ── */
.site-footer { background: var(--green-deep); color: rgba(252,250,245,.82); padding: var(--section-pad) 2rem 2rem; }
.footer-inner {
  max-width: var(--container); margin-inline: auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2.5rem;
}
.footer-brand .brand-wordmark { color: #FCFAF5; }
.footer-brand .brand-wordmark small { color: var(--gold); }
.footer-brand p { margin-top: 1rem; font-size: .92rem; max-width: 40ch; }
.footer-col h4 { color: #FCFAF5; font-size: .85rem; letter-spacing: .14em; text-transform: uppercase; font-family: var(--font-sans); font-weight: 700; margin-bottom: 1rem; }
.footer-col a { display: block; color: rgba(252,250,245,.82); padding: .28rem 0; font-size: .95rem; }
.footer-col a:hover { color: #FCFAF5; text-decoration: none; }
.footer-bottom {
  max-width: var(--container); margin: 3rem auto 0; padding-top: 1.5rem;
  border-top: 1.5px solid rgba(252,250,245,.18); font-size: .85rem; color: rgba(252,250,245,.6);
}
@media (max-width: 800px) { .footer-inner { grid-template-columns: 1fr; gap: 2rem; } }

/* ── Scroll reveal (motion: subtle; JS-gated, noscript-safe) ── */
.js [data-reveal] { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.js [data-reveal].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ── Alignment / WP core classes ── */
.alignwide { max-width: calc(var(--container) + 12rem); }
.alignfull { max-width: none; }
.wp-block-image img { border-radius: var(--r); }
.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(1px,1px,1px,1px); clip-path: inset(50%); white-space: nowrap;
}
