/* Viviano product page: what this page needs beyond site.css. Phone first, in the order the page is read. */

:root {
  --enclosure-width: 10rem;
  --spec-term-width: 8.75rem;
}
@media (min-width: 56em) {
  :root {
    --enclosure-width: 12rem;
  }
}

/* The opening block: bar, enclosure card, the sentence, then the words. Stacked on a phone; card beside the sentence, bottoms level, when there is room. */
.vis-front {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}
.vis-front .vis-enclosure {
  width: var(--enclosure-width);
  margin: 0.25rem 0 1rem;
  padding: 0.6rem 0.65rem;
  font-size: 0.9rem;
  line-height: 1.35;
}
.vis-front .vis-say-first { min-width: 0; }
.vis-words { margin-top: 1rem; }
.vis-tag { margin-top: 0.9rem; font-size: var(--read-size); }
.vis-tag span { margin-right: 0.6rem; color: var(--sunflower); }
.vis-photo[data-state="ready"] img { cursor: zoom-in; }
.vis-photo .vis-action { margin-top: 0.15rem; }
@media (min-width: 36em) {
  .vis-front {
    grid-template-columns: var(--enclosure-width) minmax(0, 1fr);
    column-gap: 1.25rem;
  }
  .vis-front .vis-bar { grid-column: 1 / -1; }
  .vis-front .vis-enclosure {
    grid-column: 1;
    grid-row: 2;
    align-self: end;
    margin-bottom: 0;
  }
  .vis-front .vis-say-first {
    grid-column: 2;
    grid-row: 2;
    align-self: end;
    padding-bottom: 0.55rem;
  }
  .vis-words { grid-column: 1 / -1; grid-row: 3; margin-top: 1.1rem; }
}
@media (min-width: 56em) {
  .vis-front .vis-enclosure {
    padding: 0.9rem 1rem;
    font-size: var(--small-size);
    line-height: 1.45;
  }
}

/* Body paragraphs sit side by side when the window is wide. */
.vis-twin { display: grid; gap: 1rem 2.5rem; margin-top: 0.9rem; }
.vis-twin p { max-width: var(--read-wide); }
@media (min-width: 56em) {
  .vis-twin { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* The specs: DM Mono rows, each term set hard against its value. */
.vis-rows { display: grid; gap: 1.1rem 2.5rem; margin-top: 1.25rem; font-size: var(--read-size); line-height: 1.5; }
.vis-spec { display: grid; gap: 0.1rem 1rem; min-width: 0; }
.vis-spec dt { color: var(--sunflower); }
@media (min-width: 56em) {
  .vis-rows { grid-template-columns: repeat(2, minmax(0, 28rem)); justify-content: start; }
  .vis-spec { grid-template-columns: var(--spec-term-width) minmax(0, 1fr); }
  .vis-spec dt { text-align: right; }
}

/* The order slip: a sunflower strip written as the sentence to say aloud. */
.vis-strip {
  display: grid;
  gap: 0.4rem 2rem;
  margin-top: 1.25rem;
  padding: 1.1rem 1.25rem 0.9rem;
  background: var(--sunflower);
  color: var(--blackberry);
  line-height: 1.5;
}
.vis-said { font-size: 1.125rem; line-height: 1.45; }
.vis-reach { display: flex; flex-wrap: wrap; gap: 0 1.75rem; }
.vis-strip a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  text-decoration-color: var(--blackberry);
}
.vis-strip a:hover { color: var(--raspberry); }
.vis-strip a:focus-visible { outline-color: var(--blackberry); }
.vis-after { margin-top: 1.25rem; }
.vis-asks { display: grid; gap: 1rem 2.5rem; margin-top: 0.5rem; }
.vis-asks li { max-width: var(--read-wide); }
.vis-asks strong { display: block; color: var(--sunflower); font-weight: 400; }
@media (min-width: 56em) {
  .vis-strip { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 1.1rem 1.5rem; }
  .vis-said { font-size: 1.375rem; }
  .vis-asks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Other flowers: one leads with its picture, the next two follow as plain lines beside it. */
.vis-more { display: flex; flex-direction: column; gap: 2rem; margin-top: 1.25rem; }
.vis-other { display: block; min-width: 0; text-decoration: none; }
.vis-other:hover { color: inherit; }
.vis-other img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.vis-title {
  margin-top: 0.7rem;
  font-family: var(--sign-face);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: underline;
  text-decoration-color: var(--sunflower);
  text-decoration-thickness: 0.12em;
  text-underline-offset: 0.2em;
}
.vis-other:hover .vis-title { color: var(--sunflower); }
.vis-cost { margin-top: 0.3rem; font-size: var(--small-size); line-height: 1.45; }
.vis-lines { display: grid; gap: 1.25rem; min-width: 0; }
.vis-linename {
  font-family: var(--sign-face);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}
.vis-linename a { display: inline-flex; align-items: center; min-height: 2.75rem; }
.vis-lines .vis-cost { margin-top: 0; }
@media (min-width: 56em) {
  .vis-more {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 4fr);
    gap: 2.5rem;
    align-items: end;
  }
}

/* The picture opened large: a dialog the page script builds. */
.vis-enlarged {
  width: min(96vw, 80rem);
  max-width: 96vw;
  max-height: 94vh;
  padding: 0;
  border: 0;
  background: var(--raspberry);
  color: var(--enclosure-white);
  overflow: auto;
}
.vis-enlarged::backdrop {
  background: var(--blackberry);
  background: color-mix(in srgb, var(--blackberry) 90%, transparent);
}
.vis-enlarged-body { display: grid; gap: 0.5rem; justify-items: start; padding: 1rem; }
.vis-enlarged img {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 72vh;
  object-fit: contain;
}
.vis-enlarged .vis-trace { max-width: var(--read-wide); margin: 0; }
