/* ==========================================================================
   Carafe & Gilt — shared recipe card
   ONE card, styled once, used by the home "recently added" grid and (later)
   the Browse index. Matches the recipe page's surfaces, borders and gold.
   Loaded after tokens.css.
   ========================================================================== */

.rcard {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: border-color var(--transition), transform var(--transition), background var(--transition);
}
.rcard:hover {
  border-color: var(--gold);
  transform: translateY(-3px);
}
.rcard:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* 4:3 landscape crop — distinct from the recipe hero's 4:5 portrait.
   Placeholder mirrors the recipe photo's diagonal hatch. */
.rcard-figure {
  margin: 0;
  aspect-ratio: 4 / 3;
  background: repeating-linear-gradient(135deg, var(--surface), var(--surface) 13px, var(--surface-2) 13px, var(--surface-2) 26px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.rcard-figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 320ms ease;
}
.rcard:hover .rcard-figure img { transform: scale(1.03); }
.rcard-ph {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: var(--fs-xs); letter-spacing: 0.18em;
  color: var(--text-muted); background: var(--bg);
  padding: 0.5em 0.9em; border: 1px solid var(--border);
}

.rcard-body {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  padding: var(--sp-4);
  flex: 1;
}
/* Extra Gilt: figure-less, text-only card — a little more top room to breathe. */
.rcard--nofigure .rcard-body { padding-top: var(--sp-5); }
.rcard-kicker { margin: 0; }
.rcard-title {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--display-ink);
  font-size: 1.5rem;
  line-height: 1.1;
  margin: 0;
}
.rcard-summary {
  margin: 0;
  color: var(--text-muted);
  font-size: var(--fs-sm);
  line-height: 1.55;
  /* one-line house-voice summary, trimmed to two lines on the card */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.rcard-meta {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: var(--sp-2);
  font-family: var(--font-caption);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: var(--fs-xs);
  color: var(--text-muted);
}
.rcard-dot { color: var(--gold); }

/* Dietary chip (e.g. gluten-free) — small outlined pill, sits above the meta. */
.rcard-diet { margin-top: var(--sp-1); }
.rcard-chip {
  display: inline-flex; align-items: center;
  font-family: var(--font-caption); text-transform: uppercase; letter-spacing: 0.12em;
  font-size: var(--fs-xs); color: var(--text-muted);
  border: 1px solid var(--border-strong); border-radius: 999px; padding: 0.2em 0.7em;
}
