/* coffee.html: the ledger. Pair of columns, second one line lower; entries with photo, name, kind, price. */

/* Opening: headline and one sentence at left, bag crop at right. */
.hero { padding-top: calc(var(--line) * 2); row-gap: var(--line); }
.hero__text .lead { margin-bottom: 0; }
.hero__shot { max-width: 32rem; }
.hero__shot .shot__img { aspect-ratio: 5 / 2; object-position: 50% 30%; }
.hero__shot figcaption a { font-family: var(--ff-display); font-weight: 700; }
@media (min-width: 56em) {
  .hero__text { grid-column: 1 / span 6; }
  .hero__shot { grid-column: 8 / span 5; max-width: none; }
  .hero__shot .shot__img { aspect-ratio: 4 / 5; object-position: 50% 40%; }
}

/* Toolbar: heading and sentence, then the sort switch. */
.tools { padding-top: calc(var(--line) * 2); row-gap: var(--line); }
.tools__text h2 { max-width: 20em; }
.sort { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
html:not(.js) .sort { display: none; }
@media (min-width: 56em) {
  .tools__text { grid-column: 1 / span 7; }
  .sort { grid-column: 9 / span 4; align-self: end; margin-bottom: var(--line); }
}

/* Ledger: reuses the .pair offset; stacks on narrow screens. */
.ledger-wrap { padding-top: calc(var(--line) * 1.5); }
.ledger { row-gap: calc(var(--line) * 2); }
.ledger[hidden], .byprice[hidden] { display: none; }
@media (max-width: 55.99em) {
  .ledger { grid-template-columns: minmax(0, 1fr); }
  .ledger > :nth-child(2) { margin-top: 0; }
}
.col__head { margin: 0 0 var(--line); }
.col__head .plate { margin-top: 0; font: 700 var(--t-h3)/1.25 var(--ff-display); padding: .4rem 1.5rem .45rem .8rem; }
.col__intro { max-width: 30em; margin-bottom: calc(var(--line) * 1.5); }

/* Entries. */
.entries { display: grid; gap: calc(var(--line) * 1.5); }
.entry {
  position: relative; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: .9rem var(--gap); align-items: stretch;
}
.entry__img { width: 100%; height: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--pink-deep); }
.entry__body { display: flex; flex-direction: column; align-items: flex-start; gap: .4rem; min-width: 0; }
.entry .plate { margin-top: 0; padding-block: .15rem .2rem; }
.entry__name {
  font: 700 clamp(1.05rem, .95rem + .4vw, 1.25rem)/1.25 var(--ff-display);
  overflow-wrap: anywhere;
}
/* The name link stretches to the whole entry, so photo and text both press through. */
.entry__name::after { content: ""; position: absolute; inset: 0; }
.entry__price {
  align-self: flex-end; margin-top: auto; padding-top: .5rem; text-align: right;
  font: 700 1.35rem/1.2 var(--ff-display);
}
.entry__price--ask { font: 400 var(--t-small)/1.35 var(--ff-text); }

/* By price: one column of the same nine. */
.byprice { max-width: 46rem; }
.byprice > p { margin-bottom: var(--line); }
.byprice .entries { gap: calc(var(--line) * 1.5); }

/* Promo line: cyan plate on the blends. */
.deal { margin-top: calc(var(--line) * 2.5); max-width: 46rem; padding: 1.1rem 2.5rem 1.1rem 1.25rem; background: var(--cyan); color: var(--plum); }
.deal p { margin: 0; }
.deal a:hover { background: var(--plum); color: var(--cyan); }

/* Closing note. */
.note { row-gap: 0; }
.note__head { max-width: 14em; }
@media (min-width: 56em) {
  .note__head { grid-column: 1 / span 5; }
  .note__text { grid-column: 7 / span 5; }
}
