/* /fifty-shades-of-greyhounds: a photo grid running white to black, plus a lightbox. */

.gh-scale {
  height: 14px;
  margin-top: var(--space-5);
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, #f6f6f6, #0e0e0e);
  box-shadow: inset 0 0 0 1px rgba(127,127,127,0.35);
}
.gh-scale__labels {
  display: flex;
  justify-content: space-between;
  margin-top: var(--space-2);
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

.gh-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

.gh-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--color-line);
  border-top: 6px solid var(--sw);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--t-mid) var(--ease), box-shadow var(--t-mid) var(--ease);
}
.gh-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.gh-card__photo {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: var(--color-mist);
  cursor: zoom-in;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.gh-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--pos, 50% 50%);
  transition: transform var(--t-slow) var(--ease);
}
.gh-card:hover .gh-card__photo img { transform: scale(1.04); }
.gh-card__photo:focus-visible { outline: 3px solid var(--color-coral-2); outline-offset: -3px; }

.gh-card__body { padding: var(--space-3) var(--space-4) var(--space-4); }
.gh-card__body p { margin: 0; }
.gh-card__name {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-weight: 600;
  line-height: 1.25;
}
.gh-card__num {
  font-family: var(--font-sans);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-right: 0.3em;
  vertical-align: 0.15em;
}
.gh-card__coat {
  display: flex;
  align-items: center;
  gap: 0.45em;
  margin-top: var(--space-1) !important;
  font-size: var(--fs-sm);
}
.gh-card__chip {
  flex: none;
  width: 0.85em;
  height: 0.85em;
  border-radius: 50%;
  background: var(--sw);
  box-shadow: 0 0 0 1px rgba(127,127,127,0.5);
}
.gh-card__credit {
  margin-top: var(--space-2) !important;
  font-size: var(--fs-xs);
  color: var(--text-muted);
  overflow-wrap: anywhere;
}
.gh-card__credit a { color: inherit; }

/* Jack's card: coral all round, a soft glow and a coral name, so he's easy to spot. */
.gh-card--jack {
  border: 3px solid var(--color-coral);
  border-top-width: 6px;
  background: #FFF4EC;
  box-shadow: 0 0 0 4px rgba(232,154,117,0.28), var(--shadow);
}
.gh-card--jack .gh-card__photo { background: var(--color-coral-3); }
.gh-card--jack .gh-card__name { color: var(--color-coral-2); }
/* Lightbox */
.gh-box {
  margin: auto; /* the site reset zeroes margins, which pins a dialog to the top-left */
  max-width: min(96vw, 1100px);
  max-height: 94vh;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: #111;
  color: #eee;
  overflow: hidden;
}
.gh-box::backdrop { background: rgba(0,0,0,0.82); }
.gh-box img {
  display: block;
  max-width: 100%;
  max-height: calc(94vh - 4.5rem);
  margin: 0 auto;
  width: auto;
  height: auto;
}
.gh-box__bar {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  font-size: var(--fs-sm);
}
.gh-box__cap { flex: 1; margin: 0; }
.gh-box__cap a { color: inherit; }
.gh-box button {
  flex: none;
  min-width: 2.5rem;
  height: 2.5rem;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: var(--radius-pill);
  background: transparent;
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
}
.gh-box button:hover, .gh-box button:focus-visible { background: rgba(255,255,255,0.15); }

/* Phones: two to a row, so fifty dogs aren't a marathon scroll. */
@media (max-width: 559px) {
  .gh-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; }
  .gh-card__body { padding: var(--space-2) var(--space-3) var(--space-3); }
  .gh-card__name { font-size: var(--fs-base); }
  .gh-card__coat { font-size: var(--fs-xs); }
}

@media (prefers-reduced-motion: reduce) {
  .gh-card, .gh-card__photo img { transition: none; }
  .gh-card:hover, .gh-card:hover .gh-card__photo img { transform: none; }
}
/* The title fits on one line on desktop (John 29/11/2026): "Fifty Shades of Greyhounds" at 72px needs ~865px (was "50 Shades…", ~772px),
   the shared page header stops at 760px. This stylesheet is only on this page. */
@media (min-width: 900px) {
  .page-header__inner { max-width: 920px; }
}
