/* ============================================
   HOMESTAY.MA — Design System
   Aesthetic: Editorial, warm-earthy, refined
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300..900;1,9..144,300..900&family=Instrument+Serif:ital@0;1&family=DM+Sans:opsz,wght@9..40,300..700&display=swap');

:root {
  --clay: #9C3D1F;
  --clay-deep: #6E2811;
  --terracotta: #B5533C;
  --ochre: #C68E3B;
  --sand: #E8D4B0;
  --cream: #F5EFE6;
  --ivory: #FAF7F0;
  --ink: #1E1410;
  --ink-soft: #3D2B21;
  --stone: #8A7563;
  --mist: #D4C4B0;

  --font-display: 'Fraunces', Georgia, serif;
  --font-serif: 'Fraunces', Georgia, serif;
  --font-serif-italic: 'Instrument Serif', Georgia, serif;
  --font-body: 'DM Sans', -apple-system, sans-serif;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 8rem;

  --wide: 1400px;
  --max: 1200px;
  --narrow: 780px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font-body); color: var(--ink); background: var(--ivory); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }

h1, h2, h3, h4, h5 { font-family: var(--font-display); font-weight: 400; line-height: 1.05; letter-spacing: -0.02em; color: var(--ink); }
h1 { font-size: clamp(3rem, 8vw, 7rem); font-variation-settings: "opsz" 144, "SOFT" 20; }
h2 { font-size: clamp(2.25rem, 5vw, 4rem); font-variation-settings: "opsz" 144, "SOFT" 30; }
h3 { font-size: clamp(1.5rem, 2.5vw, 2rem); font-variation-settings: "opsz" 48; }
em, .italic { font-family: var(--font-serif-italic); font-style: italic; font-weight: 400; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(250, 247, 240, 0.85);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(30, 20, 16, 0.08);
  transition: all 0.4s ease;
}
.nav-inner { max-width: var(--wide); margin: 0 auto; padding: 1.25rem 2.5rem; display: flex; justify-content: space-between; align-items: center; gap: 2rem; }
.logo { font-family: var(--font-display); font-size: 1.5rem; font-weight: 500; font-variation-settings: "opsz" 144, "SOFT" 50; letter-spacing: -0.03em; color: var(--ink); display: flex; align-items: baseline; gap: 0.15rem; }
.logo-mark { color: var(--clay); font-family: var(--font-serif-italic); font-style: italic; }
.logo-dot { width: 6px; height: 6px; background: var(--clay); border-radius: 50%; display: inline-block; margin: 0 0.1rem 0.15rem; }
.nav-links { display: flex; gap: 1.5rem; list-style: none; align-items: center; }
.nav-links a { font-size: 0.9rem; font-weight: 500; color: var(--ink-soft); position: relative; padding: 0.25rem 0; transition: color 0.3s; }
.nav-links a::after { content: ''; position: absolute; bottom: -2px; left: 0; width: 0; height: 1px; background: var(--clay); transition: width 0.3s ease; }
.nav-links a:hover { color: var(--clay); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-cta {
  background: var(--ink);
  color: var(--ivory) !important;
  padding: 0.65rem 1.5rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  box-shadow: 0 2px 12px rgba(30,20,16,0.18), inset 0 1px 0 rgba(255,255,255,0.06);
  transition: background 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
  position: relative;
  overflow: hidden;
}
.nav-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255,255,255,0.08) 0%, transparent 60%);
  pointer-events: none;
}
.nav-cta:hover {
  background: var(--clay) !important;
  color: var(--ivory) !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(156,61,31,0.32), inset 0 1px 0 rgba(255,255,255,0.1);
}
.nav-cta:active { transform: translateY(0); }
.nav-cta:hover .nav-cta-arrow { transform: translateX(3px); }
.nav-cta::after { display: none !important; }
/* ── Nav Search ── */
.nav-search-btn { background:none; border:1px solid rgba(30,20,16,.15); border-radius:50%; width:36px; height:36px; display:flex; align-items:center; justify-content:center; cursor:pointer; color:var(--ink); font-size:.85rem; transition:background .15s,border-color .15s; }
.nav-search-btn:hover { background:var(--cream); border-color:rgba(30,20,16,.3); }

/* ── Search Overlay ── */
.search-overlay { position:fixed; inset:0; z-index:2000; background:rgba(20,14,10,.6); backdrop-filter:blur(4px); opacity:0; visibility:hidden; transition:opacity .25s,visibility .25s; display:flex; align-items:flex-start; justify-content:center; padding-top:5rem; }
.search-overlay.open { opacity:1; visibility:visible; }
.search-overlay-inner { background:#fff; border-radius:16px; padding:1.5rem; width:min(700px,94vw); box-shadow:0 20px 60px rgba(0,0,0,.2); transform:translateY(-16px); transition:transform .25s; }
.search-overlay.open .search-overlay-inner { transform:translateY(0); }
.search-overlay-form { display:flex; align-items:center; gap:.75rem; border:1.5px solid var(--border); border-radius:999px; padding:.4rem .4rem .4rem 1.25rem; margin-bottom:1rem; }
.search-overlay-icon { color:var(--text-muted); font-size:1rem; flex-shrink:0; }
.search-overlay-input { flex:1; border:none; outline:none; font-size:1.05rem; font-family:var(--font-body); color:var(--ink); background:transparent; min-width:0; }
.search-overlay-close { background:none; border:none; color:var(--text-muted); font-size:1rem; cursor:pointer; padding:.4rem .6rem; border-radius:50%; flex-shrink:0; }
.search-overlay-close:hover { background:var(--cream); }
.search-overlay-links { display:flex; flex-wrap:wrap; gap:.5rem .75rem; align-items:center; font-size:.82rem; }
.search-overlay-links a { color:var(--clay); text-decoration:none; font-weight:500; }
.search-overlay-links a:hover { text-decoration:underline; }

/* ── Language Switcher ── */
.lang-switcher { position: relative; }
.lang-btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: none; border: 1px solid rgba(30,20,16,0.15); border-radius: 999px;
  padding: 0.45rem 0.9rem; cursor: pointer; font-family: var(--font-body);
  font-size: 0.82rem; font-weight: 500; color: var(--ink-soft);
  transition: all 0.2s ease; white-space: nowrap;
}
.lang-btn:hover { border-color: var(--clay); color: var(--clay); }
.lang-flag { font-size: 1rem; line-height: 1; }
.lang-code { letter-spacing: 0.05em; }
.lang-chevron { font-size: 0.6rem; transition: transform 0.25s ease; opacity: 0.6; }
.lang-switcher.open .lang-chevron { transform: rotate(180deg); }
.lang-switcher.open .lang-btn { border-color: var(--clay); color: var(--clay); }

.lang-dropdown {
  position: absolute; top: calc(100% + 10px); right: 0;
  background: #fff; border: 1px solid rgba(30,20,16,0.1);
  border-radius: 12px; padding: 0.5rem;
  box-shadow: 0 8px 32px rgba(30,20,16,0.12), 0 2px 8px rgba(30,20,16,0.06);
  min-width: 160px; z-index: 200;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}
.lang-switcher.open .lang-dropdown { opacity: 1; visibility: visible; transform: translateY(0); }

.lang-option {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.55rem 0.85rem; border-radius: 8px;
  font-size: 0.875rem; color: var(--ink-soft); text-decoration: none;
  transition: background 0.15s, color 0.15s; position: relative;
}
.lang-option:hover { background: var(--cream); color: var(--ink); }
.lang-option--active { background: var(--cream); color: var(--ink); font-weight: 600; }
.lang-option-flag { font-size: 1.1rem; flex-shrink: 0; }
.lang-option-label { flex: 1; }
.lang-option-check { color: var(--clay); font-size: 0.7rem; }

.mobile-toggle { display: none; background: none; border: none; cursor: pointer; padding: 0.5rem; z-index: 110; }
.mobile-toggle span { display: block; width: 24px; height: 1.5px; background: var(--ink); margin: 5px 0; transition: all 0.3s; }

/* ============================================
   BUTTONS
   ============================================ */
.btn { display: inline-flex; align-items: center; gap: 0.6rem; padding: 1rem 2rem; font-family: var(--font-body); font-size: 0.95rem; font-weight: 500; border-radius: 999px; cursor: pointer; transition: all 0.3s ease; border: none; text-decoration: none; }
.btn-primary { background: var(--ink); color: var(--ivory); }
.btn-primary:hover { background: var(--clay); transform: translateY(-2px); box-shadow: 0 12px 30px rgba(156, 61, 31, 0.25); }
.btn-outline { background: transparent; color: var(--ink); border: 1px solid var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--ivory); }
.btn-arrow { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; font-weight: 500; color: var(--clay); border-bottom: 1px solid currentColor; padding-bottom: 2px; transition: gap 0.3s; }
.btn-arrow:hover { gap: 0.8rem; }

/* ============================================
   LAYOUT
   ============================================ */
.container { max-width: var(--max); margin: 0 auto; padding: 0 2rem; }
.container-wide { max-width: var(--wide); margin: 0 auto; padding: 0 2rem; }
.container-narrow { max-width: var(--narrow); margin: 0 auto; padding: 0 2rem; }
section { padding: var(--space-xl) 0; }

.eyebrow { display: inline-block; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--clay); margin-bottom: 1.5rem; position: relative; padding-left: 2.5rem; }
.eyebrow::before { content: ''; position: absolute; left: 0; top: 50%; width: 2rem; height: 1px; background: var(--clay); }
.section-label { font-family: var(--font-serif-italic); font-style: italic; font-size: 1.1rem; color: var(--stone); margin-bottom: 0.5rem; }

/* ============================================
   HERO
   ============================================ */
.hero { min-height: 100vh; padding-top: 8rem; padding-bottom: 4rem; position: relative; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; z-index: -1; }
.hero-bg::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at top right, rgba(198, 142, 59, 0.15), transparent 60%), radial-gradient(ellipse at bottom left, rgba(156, 61, 31, 0.08), transparent 60%); }
.hero-grain { position: absolute; inset: 0; opacity: 0.4; pointer-events: none; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E"); }

.hero-grid { max-width: var(--wide); margin: 0 auto; padding: 0 2.5rem; display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 4rem; align-items: center; }
.hero-text .eyebrow { animation: fadeInUp 0.8s ease both; }
.hero h1 { font-size: clamp(3rem, 8vw, 7.5rem); line-height: 0.95; letter-spacing: -0.035em; margin-bottom: 2rem; animation: fadeInUp 0.9s 0.1s ease both; }
.hero h1 .italic-word { font-family: var(--font-serif-italic); font-style: italic; font-weight: 400; color: var(--clay); display: inline-block; }
.hero-lead { font-size: 1.2rem; line-height: 1.6; color: var(--ink-soft); max-width: 520px; margin-bottom: 2.5rem; animation: fadeInUp 1s 0.2s ease both; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; animation: fadeInUp 1.1s 0.3s ease both; }

.hero-visual { position: relative; height: 600px; animation: fadeIn 1.4s 0.4s ease both; }
.hero-img-main { position: absolute; top: 0; right: 0; width: 85%; height: 480px; background: linear-gradient(135deg, var(--clay) 0%, var(--ochre) 100%); border-radius: 220px 220px 20px 20px; overflow: hidden; box-shadow: 0 30px 80px -20px rgba(110, 40, 17, 0.4); }
.hero-img-main img { width: 100%; height: 100%; object-fit: cover; }
.hero-img-accent { position: absolute; bottom: 0; left: 0; width: 55%; height: 220px; border-radius: 12px; overflow: hidden; border: 8px solid var(--ivory); box-shadow: 0 20px 50px -10px rgba(30, 20, 16, 0.25); }
.hero-img-accent img { width: 100%; height: 100%; object-fit: cover; }

.hero-stats { display: flex; gap: 3rem; margin-top: 5rem; padding-top: 3rem; border-top: 1px solid rgba(30, 20, 16, 0.1); max-width: var(--wide); margin-left: auto; margin-right: auto; padding-left: 2.5rem; padding-right: 2.5rem; animation: fadeInUp 1.3s 0.5s ease both; }
.stat { flex: 1; min-width: 140px; }
.stat-num { font-family: var(--font-display); font-size: clamp(2rem, 3vw, 2.75rem); font-weight: 400; color: var(--ink); display: block; line-height: 1; margin-bottom: 0.4rem; font-variation-settings: "opsz" 144; }
.stat-num .italic { color: var(--clay); }
.stat-label { font-size: 0.85rem; color: var(--stone); letter-spacing: 0.02em; }

/* ============================================
   SEARCH CARD
   ============================================ */
.search-card { max-width: var(--max); margin: -3rem auto 0; padding: 2rem; background: var(--ink); color: var(--ivory); border-radius: 20px; box-shadow: 0 30px 80px -20px rgba(30, 20, 16, 0.3); position: relative; z-index: 5; }
.search-form { display: grid; grid-template-columns: 1.5fr 1fr 1fr auto; gap: 1.5rem; align-items: end; }
.search-field label { display: block; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--mist); margin-bottom: 0.6rem; }
.search-field select, .search-field input { width: 100%; background: transparent; border: none; border-bottom: 1px solid rgba(245, 239, 230, 0.2); color: var(--ivory); padding: 0.5rem 0; font-size: 1rem; font-family: var(--font-body); outline: none; transition: border 0.3s; }
.search-field select { cursor: pointer; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3e%3cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23E8D4B0' stroke-width='1.5'/%3e%3c/svg%3e"); background-repeat: no-repeat; background-position: right 0 center; }
.search-field select option { background: var(--ink); color: var(--ivory); }
.search-field input::placeholder { color: var(--stone); }
.search-field input:focus, .search-field select:focus { border-color: var(--ochre); }
.search-field input[type="date"] { color-scheme: dark; }
.search-submit { background: var(--clay); color: var(--ivory); border: none; padding: 1rem 2rem; border-radius: 12px; font-family: var(--font-body); font-weight: 500; cursor: pointer; transition: all 0.3s; white-space: nowrap; }
.search-submit:hover { background: var(--ochre); transform: translateY(-2px); }

/* ============================================
   SECTION HEADERS
   ============================================ */
.section-header { max-width: 800px; margin-bottom: 4rem; }
.section-header.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-header.center .eyebrow { padding-left: 0; }
.section-header.center .eyebrow::before { left: -3rem; top: 50%; }
.section-header.center .eyebrow::after { content: ''; position: absolute; right: -3rem; top: 50%; width: 2rem; height: 1px; background: var(--clay); }

/* ============================================
   PROMISE
   ============================================ */
.promise { background: var(--cream); position: relative; }
.promise-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3rem; }
.promise-item { position: relative; padding-top: 2rem; }
.promise-item::before { content: ''; position: absolute; top: 0; left: 0; width: 40px; height: 1px; background: var(--clay); }
.promise-num { font-family: var(--font-serif-italic); font-style: italic; font-size: 1rem; color: var(--clay); margin-bottom: 1rem; display: block; }
.promise-item h3 { font-size: 1.35rem; margin-bottom: 1rem; line-height: 1.2; }
.promise-item p { color: var(--ink-soft); font-size: 0.95rem; line-height: 1.7; }

/* ============================================
   REGIONS
   ============================================ */
.regions { background: var(--ivory); }
.regions-header { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: end; margin-bottom: 4rem; }
.regions-header p { color: var(--ink-soft); font-size: 1.05rem; line-height: 1.7; }
.regions-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 1.5rem; }
.region-card { position: relative; overflow: hidden; border-radius: 8px; cursor: pointer; transition: transform 0.5s ease; background: var(--ink); }
.region-card:nth-child(1) { grid-column: span 7; height: 500px; }
.region-card:nth-child(2) { grid-column: span 5; height: 500px; }
.region-card:nth-child(3) { grid-column: span 5; height: 420px; }
.region-card:nth-child(4) { grid-column: span 7; height: 420px; }
.region-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s ease; opacity: 0.85; }
.region-card:hover img { transform: scale(1.05); opacity: 1; }
.region-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(30, 20, 16, 0.85) 0%, transparent 60%); padding: 2rem; display: flex; flex-direction: column; justify-content: flex-end; color: var(--ivory); }
.region-overlay h3 { color: var(--ivory); font-size: clamp(1.5rem, 3vw, 2.25rem); margin-bottom: 0.4rem; }
.region-overlay p { font-size: 0.95rem; opacity: 0.9; max-width: 400px; }
.region-count { font-family: var(--font-serif-italic); font-style: italic; font-size: 0.9rem; color: var(--ochre); margin-bottom: 0.5rem; }

/* ============================================
   HOW IT WORKS
   ============================================ */
.how { background: var(--ink); color: var(--ivory); position: relative; }
.how h2 { color: var(--ivory); }
.how .eyebrow { color: var(--ochre); }
.how .eyebrow::before { background: var(--ochre); }
.how .section-label { color: var(--sand); }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3rem; margin-top: 4rem; position: relative; }
.steps::before { content: ''; position: absolute; top: 25px; left: 12%; right: 12%; height: 1px; background: repeating-linear-gradient(to right, var(--stone) 0, var(--stone) 6px, transparent 6px, transparent 12px); z-index: 0; }
.step { position: relative; z-index: 1; }
.step-num { width: 50px; height: 50px; border-radius: 50%; background: var(--ink); border: 1px solid var(--ochre); display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-size: 1.25rem; color: var(--ochre); margin-bottom: 1.5rem; }
.step h4 { color: var(--ivory); font-size: 1.3rem; margin-bottom: 0.8rem; }
.step p { color: var(--mist); font-size: 0.95rem; line-height: 1.7; }

/* ============================================
   LISTINGS
   ============================================ */
.listings { background: var(--cream); }
.listings-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }
.listing-card { background: var(--ivory); border-radius: 12px; overflow: hidden; transition: transform 0.4s ease, box-shadow 0.4s ease; cursor: pointer; }
.listing-card:hover { transform: translateY(-6px); box-shadow: 0 20px 50px -15px rgba(30, 20, 16, 0.2); }
.listing-image { position: relative; height: 280px; overflow: hidden; }
.listing-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.listing-card:hover .listing-image img { transform: scale(1.05); }
.listing-badge { position: absolute; top: 1rem; left: 1rem; background: var(--ivory); color: var(--ink); padding: 0.4rem 0.9rem; border-radius: 999px; font-size: 0.75rem; font-weight: 500; letter-spacing: 0.02em; }
.listing-content { padding: 1.5rem; }
.listing-location { font-family: var(--font-serif-italic); font-style: italic; color: var(--clay); font-size: 0.9rem; margin-bottom: 0.3rem; }
.listing-card h3 { font-size: 1.35rem; margin-bottom: 0.8rem; }
.listing-meta { display: flex; justify-content: space-between; align-items: center; padding-top: 1rem; border-top: 1px solid rgba(30, 20, 16, 0.08); }
.listing-price { font-family: var(--font-display); font-size: 1.35rem; font-weight: 500; }
.listing-price span { font-family: var(--font-body); font-size: 0.85rem; font-weight: 400; color: var(--stone); }
.listing-rating { font-size: 0.85rem; color: var(--ink-soft); display: flex; align-items: center; gap: 0.3rem; }
.listings-footer { text-align: center; margin-top: 4rem; }

/* ============================================
   STORY
   ============================================ */
.story { background: var(--ivory); }
.story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 5rem; align-items: center; }
.story-image { position: relative; height: 600px; border-radius: 8px; overflow: hidden; }
.story-image img { width: 100%; height: 100%; object-fit: cover; }
.story-image-alt { position: absolute; bottom: -3rem; right: -3rem; width: 200px; height: 260px; border: 10px solid var(--ivory); border-radius: 4px; overflow: hidden; box-shadow: 0 20px 40px rgba(30, 20, 16, 0.2); }
.story-image-alt img { width: 100%; height: 100%; object-fit: cover; }
.story-text h2 { margin-bottom: 2rem; }
.story-text .lead { font-family: var(--font-serif-italic); font-style: italic; font-size: 1.4rem; line-height: 1.5; color: var(--clay); margin-bottom: 2rem; padding-left: 1.5rem; border-left: 2px solid var(--clay); }
.story-text p { color: var(--ink-soft); font-size: 1.05rem; line-height: 1.8; margin-bottom: 1.5rem; }
.story-text .btn-arrow { margin-top: 1rem; }

/* ============================================
   FEATURE SPLIT (image left / content right)
   ============================================ */
.feature-split { display: grid; grid-template-columns: 1fr 1fr; min-height: 560px; }
.feature-split-image { background-size: cover; background-position: center; min-height: 400px; }
.feature-split-content { padding: 5rem 4rem; display: flex; flex-direction: column; justify-content: center; }
.feature-split-content h2 { margin-bottom: 0; }
.feature-split-content .btn { align-self: flex-start; }

@media (max-width: 900px) {
  .feature-split { grid-template-columns: 1fr; }
  .feature-split-image { min-height: 320px; }
  .feature-split-content { padding: 3rem 2rem; }
}

/* ============================================
   COOPERATIVES SECTION
   ============================================ */
.coops-section { padding: 5rem 0; background: var(--ivory); }
.coops-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.coop-card { background: #fff; border-radius: 12px; padding: 1.5rem; display: flex; gap: 1rem; align-items: flex-start; box-shadow: 0 1px 8px rgba(0,0,0,.06); transition: box-shadow .2s, transform .2s; text-decoration: none; color: inherit; }
.coop-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,.12); transform: translateY(-3px); }
.coop-logo { width: 56px; height: 56px; border-radius: 10px; overflow: hidden; flex-shrink: 0; background: var(--clay); display: flex; align-items: center; justify-content: center; }
.coop-logo img { width: 100%; height: 100%; object-fit: cover; }
.coop-logo-placeholder { color: #fff; font-size: 1.5rem; font-weight: 700; font-family: var(--font-serif); }
.coop-info { flex: 1; min-width: 0; }
.coop-info h4 { font-size: .95rem; margin: .2rem 0 .25rem; font-family: var(--font-serif); }
.coop-desc { font-size: .8rem; color: var(--text-muted); margin: 0; line-height: 1.4; }
@media (max-width: 900px) { .coops-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .coops-grid { grid-template-columns: 1fr; } }

/* ============================================
   TESTIMONIALS
   ============================================ */
.testimonials { background: var(--sand); position: relative; overflow: hidden; }
.testimonials::before { content: '"'; position: absolute; top: -3rem; left: 5%; font-family: var(--font-display); font-size: 30rem; color: rgba(156, 61, 31, 0.08); line-height: 1; font-weight: 400; }
.testimonials-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; position: relative; z-index: 1; }
.testimonial { background: var(--ivory); padding: 2.5rem; border-radius: 12px; position: relative; }
.testimonial-quote { font-family: var(--font-display); font-size: 1.1rem; line-height: 1.6; color: var(--ink); margin-bottom: 2rem; font-variation-settings: "opsz" 48; }
.testimonial-stars { color: var(--clay); font-size: 0.9rem; letter-spacing: 0.15em; margin-bottom: 1rem; }
.testimonial-author { padding-top: 1.5rem; border-top: 1px solid rgba(30, 20, 16, 0.1); }
.testimonial-name { font-family: var(--font-display); font-size: 1rem; font-weight: 500; color: var(--ink); margin-bottom: 0.2rem; }
.testimonial-location { font-family: var(--font-serif-italic); font-style: italic; color: var(--stone); font-size: 0.85rem; }

/* ============================================
   CTA BAND
   ============================================ */
.cta-band { background: var(--clay); color: var(--ivory); text-align: center; padding: 6rem 2rem; position: relative; overflow: hidden; }
.cta-band h2 { color: var(--ivory); margin-bottom: 1.5rem; max-width: 900px; margin-left: auto; margin-right: auto; }
.cta-band h2 .italic { color: var(--sand); }
.cta-band p { font-size: 1.1rem; opacity: 0.9; max-width: 600px; margin: 0 auto 2.5rem; }
.cta-band .btn-primary { background: var(--ivory); color: var(--ink); }
.cta-band .btn-primary:hover { background: var(--ink); color: var(--ivory); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2); }

/* ============================================
   FOOTER
   ============================================ */
.footer { background: var(--ink); color: var(--mist); padding: 6rem 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 1fr; gap: 3rem; margin-bottom: 4rem; }
.footer-brand h3 { color: var(--ivory); font-family: var(--font-display); font-size: 2rem; margin-bottom: 1rem; }
.footer-brand p { font-family: var(--font-serif-italic); font-style: italic; font-size: 1.1rem; line-height: 1.6; color: var(--sand); max-width: 380px; }
.footer h5 { color: var(--ivory); font-family: var(--font-body); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.15em; margin-bottom: 1.5rem; }
.footer ul { list-style: none; }
.footer ul li { margin-bottom: 0.8rem; }
.footer ul a { color: var(--mist); font-size: 0.95rem; transition: color 0.3s; }
.footer ul a:hover { color: var(--ochre); }
.footer-bottom { padding-top: 2rem; border-top: 1px solid rgba(212, 196, 176, 0.15); display: flex; justify-content: space-between; align-items: center; font-size: 0.85rem; color: var(--stone); flex-wrap: wrap; gap: 1rem; }
.footer-social { display: flex; gap: 1.5rem; }
.footer-social a { color: var(--mist); transition: color 0.3s; }
.footer-social a:hover { color: var(--ochre); }

/* ============================================
   PAGE HEADER
   ============================================ */
.page-header { padding: 12rem 0 6rem; background: var(--cream); position: relative; overflow: hidden; }
.page-header::before { content: ''; position: absolute; top: 0; right: 0; width: 40%; height: 100%; background: radial-gradient(ellipse at right, rgba(198, 142, 59, 0.15), transparent 70%); }
.page-header-content { position: relative; z-index: 1; max-width: 900px; }
.page-header h1 { font-size: clamp(3rem, 7vw, 6rem); line-height: 0.95; margin-bottom: 2rem; }
.page-header h1 .italic { color: var(--clay); }
.page-header .lead { font-size: 1.3rem; color: var(--ink-soft); max-width: 650px; line-height: 1.6; }
/* Page header with photo background */
.page-header--image { background-size: cover; background-position: center; }
.page-header--image::before { display: none; }
.page-header--image::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to right, rgba(15,10,5,.72) 0%, rgba(15,10,5,.45) 55%, rgba(15,10,5,.15) 100%); z-index: 0; }
.page-header--image .page-header-content { z-index: 2; }
.page-header--image h1 { color: #fff; }
.page-header--image h1 .italic { color: var(--ochre); }
.page-header--image .lead { color: rgba(255,255,255,.82); }
.page-header--image .eyebrow { color: var(--ochre); border-color: var(--ochre); background: transparent; }
.page-header--image .breadcrumb { color: rgba(255,255,255,.6); }
.page-header--image .breadcrumb a { color: rgba(255,255,255,.85); }
.page-header--image .breadcrumb span { color: rgba(255,255,255,.4); }
.page-header--image .btn-outline { border-color: rgba(255,255,255,.6); color: #fff; }
.page-header--image .btn-outline:hover { background: rgba(255,255,255,.12); border-color: #fff; }
.breadcrumb { font-size: 0.85rem; color: var(--stone); margin-bottom: 2rem; }
.breadcrumb a { color: var(--clay); transition: opacity 0.3s; }
.breadcrumb a:hover { opacity: 0.7; }
.breadcrumb span { margin: 0 0.5rem; color: var(--stone); }

/* ============================================
   EDITORIAL
   ============================================ */
.editorial { padding: var(--space-xl) 0; background: var(--ivory); }
.editorial-content { max-width: var(--narrow); margin: 0 auto; padding: 0 2rem; }
.editorial-content p { font-size: 1.15rem; line-height: 1.8; color: var(--ink-soft); margin-bottom: 2rem; }
.editorial-content p:first-of-type::first-letter { font-family: var(--font-display); font-size: 5rem; line-height: 0.9; float: left; padding: 0.3rem 0.8rem 0 0; color: var(--clay); font-weight: 500; }
.editorial-content h2 { margin: 3rem 0 1.5rem; }
.editorial-content h3 { margin: 2.5rem 0 1rem; color: var(--clay); }
.editorial-content blockquote { border-left: 3px solid var(--clay); padding: 1rem 0 1rem 2rem; margin: 2.5rem 0; font-family: var(--font-serif-italic); font-style: italic; font-size: 1.4rem; line-height: 1.5; color: var(--ink); }

/* ============================================
   FAQ
   ============================================ */
.faq-list { max-width: var(--narrow); margin: 0 auto; }
.faq-item { border-bottom: 1px solid rgba(30, 20, 16, 0.12); padding: 1.5rem 0; cursor: pointer; }
.faq-item summary { list-style: none; display: flex; justify-content: space-between; align-items: center; cursor: pointer; font-family: var(--font-display); font-size: 1.3rem; color: var(--ink); line-height: 1.3; transition: color 0.3s; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--clay); }
.faq-icon { flex-shrink: 0; width: 32px; height: 32px; border: 1px solid var(--ink); border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all 0.3s; margin-left: 2rem; }
.faq-item[open] .faq-icon { background: var(--clay); border-color: var(--clay); color: var(--ivory); transform: rotate(45deg); }
.faq-answer { padding: 1rem 0 0; font-size: 1.05rem; line-height: 1.7; color: var(--ink-soft); max-width: 90%; }

/* ============================================
   CONTACT
   ============================================ */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 5rem; }
.contact-info h3 { font-size: 1.8rem; margin-bottom: 2rem; }
.contact-method { padding: 1.5rem 0; border-bottom: 1px solid rgba(30, 20, 16, 0.1); }
.contact-method h5 { font-family: var(--font-body); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.15em; color: var(--stone); margin-bottom: 0.5rem; }
.contact-method p, .contact-method a { font-family: var(--font-display); font-size: 1.15rem; color: var(--ink); }
.contact-form { background: var(--cream); padding: 3rem; border-radius: 8px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 1.5rem; }
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--ink-soft); margin-bottom: 0.5rem; }
.form-group input, .form-group select, .form-group textarea { width: 100%; background: var(--ivory); border: 1px solid rgba(30, 20, 16, 0.15); border-radius: 6px; padding: 0.9rem 1rem; font-family: var(--font-body); font-size: 1rem; color: var(--ink); transition: border 0.3s; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--clay); }
.form-group textarea { resize: vertical; min-height: 150px; }

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; gap: 3rem; }
  .hero-visual { height: 450px; }
  .promise-grid { grid-template-columns: repeat(2, 1fr); gap: 2.5rem; }
  .regions-header { grid-template-columns: 1fr; gap: 2rem; }
  .regions-grid { grid-template-columns: 1fr; }
  .region-card:nth-child(n) { grid-column: span 12; height: 380px; }
  .steps { grid-template-columns: repeat(2, 1fr); gap: 3rem; }
  .steps::before { display: none; }
  .listings-grid { grid-template-columns: repeat(2, 1fr); }
  .story-grid { grid-template-columns: 1fr; gap: 3rem; }
  .testimonials-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }
  .contact-grid { grid-template-columns: 1fr; gap: 3rem; }
}
@media (max-width: 768px) {
  .nav { padding: 1rem 1.5rem; }
  .nav-links { position: fixed; top: 0; right: -100%; width: 75%; height: 100vh; background: var(--ivory); flex-direction: column; justify-content: center; align-items: flex-start; padding: 3rem; gap: 2rem; transition: right 0.4s ease; box-shadow: -10px 0 40px rgba(0,0,0,0.1); }
  .nav-links.open { right: 0; }
  .nav-links a { font-size: 1.5rem; font-family: var(--font-display); }
  .mobile-toggle { display: block; }
  .mobile-toggle.active span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
  .mobile-toggle.active span:nth-child(2) { opacity: 0; }
  .mobile-toggle.active span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }
  section { padding: 4rem 0; }
  .hero { padding-top: 6rem; min-height: 90vh; }
  .hero-stats { gap: 1.5rem; flex-wrap: wrap; margin-top: 3rem; padding-top: 2rem; }
  .hero-img-main { border-radius: 150px 150px 12px 12px; height: 380px; }
  .hero-img-accent { width: 50%; height: 160px; }
  .promise-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .listings-grid { grid-template-columns: 1fr; }
  .search-form { grid-template-columns: 1fr; gap: 1.5rem; }
  .search-card { padding: 1.5rem; margin: -2rem 1rem 0; }
  .footer-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .form-row { grid-template-columns: 1fr; }
  .page-header { padding: 8rem 0 4rem; }
  .contact-form { padding: 2rem; }
  .container, .container-wide, .container-narrow { padding: 0 1.25rem; }
}

/* ============================================
   COOPERATIVE DETAIL PAGE
   ============================================ */
.coop-card--link { text-decoration:none; color:inherit; cursor:pointer; transition:transform .2s,box-shadow .2s; display:flex; }
.coop-card--link:hover { transform:translateY(-3px); box-shadow:0 6px 24px rgba(0,0,0,.12); }

/* Hero */
.coop-detail-hero { position:relative; min-height:340px; display:flex; align-items:flex-end; background-size:cover; background-position:center; }
.coop-detail-hero-overlay { position:absolute; inset:0; background:linear-gradient(to top, rgba(0,0,0,.65) 0%, rgba(0,0,0,.15) 60%); }
.coop-detail-hero-content { position:relative; z-index:1; padding:2.5rem 0; display:flex; align-items:center; gap:1.5rem; }
.coop-detail-logo { width:80px; height:80px; object-fit:contain; border-radius:12px; background:#fff; padding:6px; flex-shrink:0; box-shadow:0 2px 16px rgba(0,0,0,.25); }

/* Layout */
.coop-detail-layout { display:grid; grid-template-columns:280px 1fr; gap:3rem; padding-top:2rem; padding-bottom:4rem; align-items:start; }
.coop-detail-aside  { position:sticky; top:5rem; }
.coop-detail-section { margin-bottom:0; }
.coop-detail-section + .coop-detail-section { margin-top:2rem; padding-top:2rem; border-top:1px solid var(--border); }

/* Info card */
.coop-info-card { background:var(--ivory); border-radius:14px; padding:1.5rem; }
.coop-info-row  { display:flex; gap:.75rem; align-items:flex-start; padding:.45rem 0; border-bottom:1px solid var(--border); font-size:.875rem; line-height:1.4; }
.coop-info-row:last-child { border-bottom:none; }
.coop-info-row i { color:var(--clay); width:16px; flex-shrink:0; margin-top:.15rem; }
.coop-info-row a { color:var(--clay); text-decoration:none; }
.coop-info-row a:hover { text-decoration:underline; }

/* Section headings */
.coop-section-title { font-family:var(--font-serif); font-size:clamp(1.3rem,2.5vw,1.7rem); font-weight:400; margin:0 0 1.1rem; letter-spacing:-.02em; }

/* Description */
.coop-detail-desc { font-size:1rem; line-height:1.85; color:var(--text); }

/* CTA */
.coop-detail-cta { background:var(--ivory); border-radius:14px; padding:2rem; text-align:center; margin-top:1rem; }
.coop-detail-cta p { margin:0 0 1rem; color:var(--text-muted); }

/* Product grid */
.prod-cats { display:flex; flex-wrap:wrap; gap:.5rem; }
.prod-grid  { display:grid; grid-template-columns:repeat(3,1fr); gap:1.5rem; }
.prod-card  { background:#fff; border-radius:14px; overflow:hidden; box-shadow:0 1px 8px rgba(0,0,0,.07); transition:transform .2s,box-shadow .2s; display:flex; flex-direction:column; }
.prod-card:hover { transform:translateY(-3px); box-shadow:0 6px 24px rgba(0,0,0,.12); }
.prod-card-img  { position:relative; height:180px; overflow:hidden; background:#f4f0eb; }
.prod-card-img img { width:100%; height:100%; object-fit:cover; transition:transform .3s; }
.prod-card:hover .prod-card-img img { transform:scale(1.04); }
.prod-card-img-placeholder { width:100%; height:100%; display:flex; align-items:center; justify-content:center; color:#c8b89a; font-size:2rem; }
.prod-card-cat  { position:absolute; top:.6rem; left:.6rem; background:var(--clay); color:#fff; font-size:.68rem; font-weight:600; text-transform:uppercase; letter-spacing:.06em; padding:.25rem .6rem; border-radius:99px; }
.prod-card-sold { position:absolute; top:.6rem; right:.6rem; background:rgba(0,0,0,.55); color:#fff; font-size:.68rem; padding:.25rem .6rem; border-radius:99px; }
.prod-card-body { padding:1.1rem; flex:1; display:flex; flex-direction:column; }
.prod-card-body h4 { font-size:.95rem; margin:0 0 .35rem; font-family:var(--font-serif); line-height:1.3; }
.prod-card-body p  { font-size:.8rem; color:var(--text-muted); line-height:1.5; flex:1; margin:0 0 .75rem; }
.prod-card-price   { font-size:.9rem; font-weight:700; color:var(--clay); margin-top:auto; }
.prod-card-price span { font-weight:400; color:var(--text-muted); font-size:.78rem; }

@media (max-width: 1024px) {
  .coop-detail-layout { grid-template-columns:240px 1fr; gap:2rem; }
  .prod-grid { grid-template-columns:repeat(2,1fr); }
}
@media (max-width: 768px) {
  .coop-detail-layout { grid-template-columns:1fr; }
  .coop-detail-aside { position:static; }
  .prod-grid { grid-template-columns:repeat(2,1fr); gap:1rem; }
}
@media (max-width: 480px) {
  .prod-grid { grid-template-columns:1fr; }
}

/* ============================================
   BLOG — LISTING
   ============================================ */
.blog-cats { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2.5rem; }
.blog-cat-pill { padding: .35rem .9rem; border-radius: 99px; border: 1.5px solid var(--border); font-size: .8rem; font-weight: 500; color: var(--text-muted); text-decoration: none; transition: all .18s; }
.blog-cat-pill:hover, .blog-cat-pill.active { background: var(--clay); border-color: var(--clay); color: #fff; }

.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.blog-card { background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 1px 8px rgba(0,0,0,.07); text-decoration: none; color: inherit; transition: transform .2s, box-shadow .2s; display: flex; flex-direction: column; }
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 8px 32px rgba(0,0,0,.12); }
.blog-card > img { width: 100%; height: 220px; object-fit: cover; }
.blog-card-body { padding: 1.5rem; flex: 1; display: flex; flex-direction: column; }
.blog-cat { display: inline-block; font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--clay); margin-bottom: .6rem; }
.blog-card-body h3 { font-size: 1.1rem; margin: 0 0 .6rem; line-height: 1.4; font-family: var(--font-serif); }
.blog-card-body p { font-size: .875rem; color: var(--text-muted); margin: 0 0 1rem; line-height: 1.6; flex: 1; }
.blog-meta { font-size: .78rem; color: var(--text-muted); margin-top: auto; }
.blog-date { font-weight: 500; }

@media (max-width: 900px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .blog-grid { grid-template-columns: 1fr; } }

/* ============================================
   BLOG — DETAIL
   ============================================ */
.blog-detail-layout { display: grid; grid-template-columns: 1fr 320px; gap: 3rem; padding-top: 3rem; padding-bottom: 4rem; align-items: start; }

.blog-cover { width: 100%; max-height: 480px; object-fit: cover; border-radius: 14px; margin-bottom: 2.5rem; }

/* Rich HTML content styling */
.blog-content { font-size: 1.05rem; line-height: 1.85; color: var(--text); }
.blog-content h1,
.blog-content h2,
.blog-content h3,
.blog-content h4 { font-family: var(--font-serif); color: var(--ink); margin: 2rem 0 .75rem; line-height: 1.3; }
.blog-content h2 { font-size: 1.6rem; }
.blog-content h3 { font-size: 1.25rem; }
.blog-content h4 { font-size: 1.05rem; }
.blog-content p { margin: 0 0 1.25rem; }
.blog-content a { color: var(--clay); text-underline-offset: 3px; }
.blog-content a:hover { color: var(--clay-deep); }
.blog-content ul,
.blog-content ol { margin: 0 0 1.25rem 1.5rem; padding: 0; }
.blog-content li { margin-bottom: .4rem; }
.blog-content blockquote { border-left: 4px solid var(--clay); margin: 2rem 0; padding: 1rem 1.5rem; background: var(--ivory); border-radius: 0 8px 8px 0; font-style: italic; color: var(--text-muted); }
.blog-content blockquote p { margin: 0; }
.blog-content img { max-width: 100%; border-radius: 10px; margin: 1.5rem 0; }
.blog-content hr { border: none; border-top: 1px solid var(--border); margin: 2.5rem 0; }
.blog-content pre { background: #f4f0eb; border-radius: 8px; padding: 1.25rem; overflow-x: auto; font-size: .9rem; margin: 1.5rem 0; }
.blog-content table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: .9rem; }
.blog-content th { background: var(--ivory); padding: .6rem 1rem; text-align: left; border-bottom: 2px solid var(--border); font-weight: 600; }
.blog-content td { padding: .6rem 1rem; border-bottom: 1px solid var(--border); }

.blog-tags { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.tag { padding: .3rem .8rem; background: var(--ivory); border-radius: 99px; font-size: .78rem; color: var(--text-muted); }

/* Breadcrumb */
.breadcrumb { font-size: .85rem; color: var(--text-muted); margin-bottom: .75rem; }
.breadcrumb a { color: var(--clay); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* Sidebar */
.blog-sidebar { display: flex; flex-direction: column; gap: 1.5rem; position: sticky; top: 5rem; }
.blog-sidebar-widget { background: var(--ivory); border-radius: 12px; padding: 1.5rem; }
.blog-sidebar-widget h4 { font-family: var(--font-serif); font-size: 1rem; margin: 0 0 1rem; }
.recent-post { display: flex; gap: .75rem; align-items: center; text-decoration: none; color: inherit; margin-bottom: .85rem; font-size: .88rem; line-height: 1.4; }
.recent-post img { width: 56px; height: 48px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.recent-post:hover { color: var(--clay); }
.blog-cta { background: var(--clay); border-radius: 12px; padding: 1.5rem; color: #fff; }
.blog-cta h4 { color: #fff; margin: 0 0 1rem; font-family: var(--font-serif); }
.btn-block { display: block; text-align: center; }

@media (max-width: 900px) {
  .blog-detail-layout { grid-template-columns: 1fr; }
  .blog-sidebar { position: static; }
}
