/* ============================================================
   PRODUCERS.CSS — homepage network section (light, airy grid)
   ============================================================ */

.producers-section {
  background: var(--brand-50);
  border-top: 1px solid var(--brand-100);
  border-bottom: 1px solid var(--brand-100);
  padding-block: var(--space-16);
}

.producers-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-8);
  margin-bottom: var(--space-8);
}
.producers-heading { max-width: 650px; }
.producers-subtitle {
  margin-top: 8px;
  font-size: var(--text-sm);
  line-height: var(--line-height-loose);
  color: var(--text-muted);
}

.producers-head-side {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-3);
}
.producers-count {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-size: var(--text-sm);
  color: var(--text-muted);
  white-space: nowrap;
}
.producers-count strong {
  font-size: var(--text-2xl);
  font-weight: var(--font-weight-bold);
  line-height: 1;
  color: var(--brand-700);
  font-variant-numeric: tabular-nums;
}
.producers-head-side .btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.producers-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-4);
}

.producer-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: var(--space-4);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  color: inherit;
  text-decoration: none;
  transition: border-color var(--transition-base), box-shadow var(--transition-base), transform var(--transition-base);
}
.producer-tile:hover {
  border-color: var(--brand-200);
  box-shadow: 0 12px 26px -18px rgba(22, 69, 22, 0.35);
  transform: translateY(-2px);
}
.producer-tile:focus-visible {
  outline: 2px solid var(--border-focus);
  outline-offset: 2px;
}

.producer-avatar {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  color: var(--brand-700);
  font-size: var(--text-sm);
  font-weight: var(--font-weight-bold);
}

.producer-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.producer-name {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--neutral-900);
}
.producer-name > span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.producer-verified {
  flex: none;
  width: 15px;
  height: 15px;
  color: var(--brand-600);
}
.producer-province,
.producer-response {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: var(--text-xs);
  color: var(--neutral-600);
  line-height: 1.5;
  min-width: 0;
}
.producer-province svg,
.producer-response svg {
  flex: none;
  width: 12px;
  height: 12px;
  color: var(--brand-600);
}
.producer-response span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.producer-arrow {
  flex: none;
  display: grid;
  place-items: center;
  color: var(--neutral-400);
  transition: color var(--transition-base), transform var(--transition-base);
}
.producer-tile:hover .producer-arrow {
  color: var(--brand-600);
  transform: translateX(-3px);
}

@media (max-width: 1100px) {
  .producers-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .producers-section { padding-block: var(--space-12); }
  .producers-head {
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-5);
  }
  .producers-head-side {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
  }
  .producers-grid {
    display: flex;
    gap: var(--space-3);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 6px;
    margin-inline: calc(-1 * var(--space-4));
    padding-inline: var(--space-4);
    scrollbar-width: thin;
  }
  .producer-tile {
    flex: 0 0 258px;
    scroll-snap-align: start;
  }
}
@media (max-width: 420px) {
  .producer-tile { flex-basis: 230px; }
  .producers-head-side { flex-wrap: wrap; }
}

/* ============================================================
   PRODUCERS — Phase 2B: polished cards + profile page
   ============================================================ */

/* ── Producer Card (partners / profile listings) ──────────── */
.producer-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--transition-base), transform var(--transition-base), border-color var(--transition-base);
  position: relative;
  isolation: isolate;
}
.producer-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); border-color: var(--brand-200); }
.producer-card:focus-within { border-color: var(--brand-300); box-shadow: 0 0 0 3px rgba(46,142,46,0.12), var(--shadow-md); }
.producer-card-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}
.producer-card-avatar {
  width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-100), var(--brand-200));
  color: var(--brand-700);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 800; flex-shrink: 0;
  border: 2px solid var(--surface-raised);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.producer-card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.producer-card-avatar--placeholder { background: var(--surface-sunken); color: var(--text-muted); border-style: dashed; }
.producer-card-title {
  font-size: 14px; font-weight: 800; color: var(--text); line-height: 1.35;
  display: flex; gap: 8px; align-items: center; flex-wrap: wrap;
}
.producer-card-meta { font-size: 11.5px; color: var(--text-muted); margin-top: 2px; }
.producer-card-bio { font-size: 12.5px; color: var(--text-muted); line-height: 1.85; }
.producer-card-body { padding: 14px 16px; flex: 1; display: flex; flex-direction: column; gap: 10px; }
.producer-card-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: var(--surface-sunken);
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: space-between;
}
.producer-card-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.producer-card-actions .btn { position: relative; z-index: 1; }
.producer-card-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
}
.producer-stat {
  background: var(--surface-sunken); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 10px 8px; text-align: center;
}
.producer-stat-num { display: block; font-size: 13px; font-weight: 800; color: var(--brand-700); font-variant-numeric: tabular-nums; }
.producer-stat-label { font-size: 11px; color: var(--text-muted); }
.producer-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.producer-chip {
  font-size: 11px; padding: 3px 8px; border-radius: var(--radius-full);
  background: var(--surface-sunken); border: 1px solid var(--border); color: var(--text-muted);
}
.producer-chip--primary { background: var(--brand-50); color: var(--brand-700); border-color: var(--brand-200); }
.producer-link { color: inherit; text-decoration: none; }
.producer-link:focus-visible { outline: none; }
.producer-link:focus-visible .producer-card-title { color: var(--color-primary); text-decoration: underline; text-underline-offset: 3px; }

/* ── Producer Profile Page ────────────────────────────────── */
.producer-profile-wrap { max-width: 1180px; margin: 0 auto; padding: 18px 16px 32px; }
.producer-breadcrumb { font-size: 12.5px; color: var(--text-muted); margin: 10px 0 14px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.producer-breadcrumb a { color: var(--color-info); text-decoration: none; }
.producer-breadcrumb a:hover { text-decoration: underline; }
.producer-breadcrumb-sep { opacity: 0.4; }
.producer-profile-hero {
  background: var(--surface-raised); border: 1px solid var(--border);
  border-radius: var(--radius-xl); box-shadow: var(--shadow-sm);
  padding: 22px; display: grid; grid-template-columns: auto 1fr auto; gap: 18px; align-items: start;
}
@media (max-width: 900px) { .producer-profile-hero { grid-template-columns: 1fr; } }
.producer-hero-avatar {
  width: 88px; height: 88px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-100), var(--brand-200));
  color: var(--brand-700); display: flex; align-items: center; justify-content: center;
  font-size: 32px; font-weight: 800; flex-shrink: 0;
  border: 3px solid var(--surface-raised); box-shadow: var(--shadow-md); overflow: hidden;
}
.producer-hero-avatar--placeholder { background: var(--surface-sunken); color: var(--text-muted); border-style: dashed; }
.producer-hero-title { font-size: 20px; font-weight: 800; color: var(--text); display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.producer-hero-location { font-size: 12.5px; color: var(--text-muted); margin-top: 4px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.producer-hero-bio { font-size: 13px; color: var(--text-muted); line-height: 1.9; margin-top: 8px; }
.producer-hero-actions { display: flex; flex-direction: column; gap: 8px; min-width: 180px; }
@media (max-width: 900px) { .producer-hero-actions { flex-direction: row; flex-wrap: wrap; } }
.producer-profile-layout { display: grid; grid-template-columns: 1.55fr 0.9fr; gap: 18px; align-items: start; margin-top: 18px; }
@media (max-width: 900px) { .producer-profile-layout { grid-template-columns: 1fr; } }
.producer-profile-main, .producer-profile-side { display: flex; flex-direction: column; gap: 14px; }
.producer-panel { background: var(--surface-raised); border: 1px solid var(--border); border-radius: var(--radius-xl); box-shadow: var(--shadow-sm); overflow: hidden; }
.producer-panel-pad { padding: 16px; }
.producer-panel-title { font-size: 14px; font-weight: 800; color: var(--text); margin-bottom: 10px; display: flex; gap: 8px; align-items: center; }
.producer-panel-title::before { content: ""; width: 3px; height: 16px; border-radius: 999px; background: var(--brand-500); }
.producer-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 600px) { .producer-info-grid { grid-template-columns: 1fr; } }
.producer-info-item { display: flex; justify-content: space-between; gap: 10px; padding: 10px 12px; background: var(--surface-sunken); border: 1px solid var(--border); border-radius: var(--radius-md); font-size: 12.5px; }
.producer-info-item dt { color: var(--text-muted); }
.producer-info-item dd { font-weight: 700; color: var(--text); text-align: left; }
.producer-ads-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.producer-products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.producer-empty { text-align: center; padding: 18px; background: var(--surface-sunken); border: 1px dashed var(--border-strong); border-radius: var(--radius-lg); color: var(--text-muted); font-size: 12.5px; line-height: 1.8; }
.producer-review { display: flex; flex-direction: column; gap: 6px; padding: 12px; background: var(--surface-sunken); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.producer-review-head { display: flex; justify-content: space-between; gap: 8px; align-items: center; font-size: 12.5px; }
.producer-review-author { font-weight: 700; color: var(--text); }
.producer-review-stars { color: var(--color-warning); font-size: 12px; letter-spacing: 1px; }
.producer-review-text { font-size: 12.5px; color: var(--text-muted); line-height: 1.7; }
@media (max-width: 480px) {
  .producer-profile-wrap { padding-inline: 12px; }
  .producer-profile-hero { padding: 16px; }
  .producer-hero-avatar { width: 72px; height: 72px; font-size: 26px; }
  .producer-card-head { padding: 14px; }
  .producer-card-body, .producer-card-footer { padding-inline: 14px; }
}
