/* ===========================================================================
   Partners archive — the main directory page
   Forest-green editorial hero + filterable, logo-forward partner grid.
   Uses the committed Dovetail tokens (var(--dovetail-*), var(--font-*)).
   =========================================================================== */

.pa-dd-page {
  background: var(--dovetail-bg);
  color: var(--dovetail-text);
}

.pa-dd-container {
  width: 100%;
  max-width: 1400px;          /* match the detail-page container (projects + header) */
  margin: 0 auto;
  padding-inline: 10px;
}

/* ── Hero (forest-green band; sits under the transparent header) ── */
.pa-dd-hero {
  background: var(--dovetail-green-950);
  color: var(--dovetail-white);
  min-height: 72vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-top: clamp(100px, 14vh, 160px);
  padding-bottom: clamp(56px, 8vw, 104px);
  /* soft top vignette so the transparent header text stays legible */
  position: relative;
  overflow: hidden;
}
.pa-dd-hero::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 220px;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.28), transparent);
  pointer-events: none;
}
.pa-dd-hero > .pa-dd-container { position: relative; }

.pa-dd-hero-kicker {
  margin: 0 0 18px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dovetail-green-200);
}

.pa-dd-hero-title {
  margin: 0;
  max-width: none;        /* let the headline run its natural two lines */
  text-wrap: balance;
}
.pa-dd-hero-cal {
  display: block;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.01em;
  color: var(--dovetail-white);
}
.pa-dd-hero-ott {
  display: block;
  font-family: var(--font-heading);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(2.1rem, 4.6vw, 3.7rem);
  line-height: 1.05;
  color: var(--dovetail-taupe-300);
}

.pa-dd-hero-lede {
  margin: clamp(22px, 3vw, 34px) 0 0;
  max-width: 68ch;
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.2vw, 1.125rem);
  line-height: 1.8;
  color: rgba(252, 250, 245, 0.82);
  text-wrap: pretty;
}

/* ── List section ── */
.pa-dd-list-section {
  padding-top: clamp(40px, 5vw, 64px);
  padding-bottom: clamp(64px, 9vw, 120px);
}

/* ── Type group section ── */
.pa-dd-group { margin-bottom: clamp(52px, 7vw, 96px); }
.pa-dd-group:last-child { margin-bottom: 0; }
.pa-dd-group-head { margin-bottom: clamp(22px, 2.6vw, 34px); }
.pa-dd-group-kicker {
  display: block;
  margin-bottom: 10px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dovetail-taupe-700);
}
.pa-dd-group-title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.9rem, 3.2vw, 2.6rem);
  font-weight: 500;
  line-height: 1.05;
  color: var(--dovetail-text);
}

/* ── Bordered matrix of text cells (no images) ── */
.pa-dd-matrix {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--dovetail-border);
  border-left: 1px solid var(--dovetail-border);
}
.pa-dd-cell {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: clamp(24px, 2.2vw, 34px);
  background: var(--dovetail-bg);
  border-right: 1px solid var(--dovetail-border);
  border-bottom: 1px solid var(--dovetail-border);
  cursor: pointer;
  transition: background 0.3s ease;
}
.pa-dd-cell:hover {
  background: var(--dovetail-dark);
}
/* Empty cells — subtle dot grid so an incomplete row reads as a considered
   pattern, not a missing card. */
.pa-dd-cell--empty {
  background-color: rgba(31, 30, 27, 0.012);
  background-image: radial-gradient(circle, rgba(31, 30, 27, 0.12) 1px, transparent 1.6px);
  background-size: 16px 16px;
  background-position: center;
  cursor: default;
  transition: border-color 0.3s ease;
}
.pa-dd-cell--empty:hover {
  background-color: rgba(31, 30, 27, 0.012) !important;
  background-image: radial-gradient(circle, rgba(31, 30, 27, 0.12) 1px, transparent 1.6px) !important;
  background-size: 16px 16px !important;
  background-position: center !important;
  border-color: rgba(31, 30, 27, 0.25);
}

.pa-dd-cell-disc {
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dovetail-taupe-700);
  transition: color 0.3s ease;
}
.pa-dd-cell:hover .pa-dd-cell-disc {
  color: rgba(213, 200, 175, 0.55);
}
.pa-dd-cell-name {
  margin: 0 0 14px;
  font-family: var(--font-heading);
  font-size: clamp(1.3rem, 1.5vw, 1.55rem);
  font-weight: 500;
  line-height: 1.18;
}
.pa-dd-cell-name a,
.pa-dd-cell-link {
  color: var(--dovetail-text);
  text-decoration: none;
  transition: color 0.3s ease;
}
/* Stretched block link — covers the entire card */
.pa-dd-cell-link::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
}
.pa-dd-cell:hover .pa-dd-cell-name a,
.pa-dd-cell:hover .pa-dd-cell-link { color: #d5c8af; }
.pa-dd-cell-desc {
  margin: 0 0 24px;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--dovetail-text-soft);
  transition: color 0.3s ease;
}
.pa-dd-cell:hover .pa-dd-cell-desc {
  color: #e5dccb;
}
.pa-dd-cell-action {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  width: fit-content;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dovetail-accent-strong);
  text-decoration: none;
  transition: gap 0.25s ease, color 0.3s ease;
}
.pa-dd-cell:hover .pa-dd-cell-action {
  color: #d5c8af;
}
.pa-dd-cell-action span { border-bottom: 1px solid currentColor; padding-bottom: 3px; }
.pa-dd-cell-action svg { flex: 0 0 auto; }
.pa-dd-cell-action:hover { gap: 12px; }
.pa-dd-cell-loc {
  margin-top: auto;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dovetail-text-muted);
}

/* ── Empty state ── */
.pa-dd-empty {
  max-width: 560px;
  margin: clamp(20px, 4vw, 48px) auto;
  text-align: center;
}
.pa-dd-empty h2 {
  margin: 0 0 14px;
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 500;
  color: var(--dovetail-text);
}
.pa-dd-empty p {
  margin: 0 0 26px;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--dovetail-text-soft);
}
.pa-dd-empty-link {
  display: inline-block;
  padding: 14px 32px;
  background: var(--dovetail-dark);
  color: var(--dovetail-white);
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color 0.3s ease;
}
.pa-dd-empty-link:hover { background: var(--dovetail-accent-strong); }

@media (prefers-reduced-motion: reduce) {
  .pa-dd-cell-name a,
  .pa-dd-cell-action { transition: none; }
}

/* ── Responsive ── */
@media (max-width: 980px) {
  .pa-dd-matrix { grid-template-columns: 1fr 1fr; }
  .pa-dd-cell--empty { display: none; }
}
@media (max-width: 880px) {
  .pa-dd-container { padding-inline: 24px; }
}
@media (max-width: 620px) {
  .pa-dd-matrix { grid-template-columns: 1fr; }
  .pa-dd-cell--empty { display: none; }
}
