/* The Dailies page (docs/adr/0034), in the hub's look on the paper
   (site.css, on games/house/paper.css; ADR 0036): four cards of numbers, the one primary
   (Play next), then a row per daily, its box art at the left like the
   account page's "Your games". */

.dl .kicker { margin: 0 0 var(--s2); }
.dl h1 { margin: 0 0 var(--s2); }
.dl .lead { margin: 0 0 var(--s4); }

/* your numbers: four tiles, then Play next beside its note */
.dl-summary { display: grid; gap: var(--s3); margin-bottom: var(--s4); }
.dl-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.dl-tile { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; background: var(--card); border: var(--edge); border-radius: var(--radius); box-shadow: var(--card-shadow); }
.dl-tile b { font-size: 28px; line-height: 1.15; font-weight: 700; }
.dl-tile span { font-size: var(--t-note); color: var(--ink-soft); }
.dl-next { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s3); min-height: 44px; }
.dl-next .btn { min-height: 44px; }
.dl-note { margin: 0; flex: 1 1 18em; font-size: var(--t-note); color: var(--ink-soft); }
.dl-all-done .dl-note { font-size: var(--t-body); font-weight: 600; color: var(--ink); }
.dl-all-done::before { content: ""; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%23f4efe4' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 20px no-repeat; }

/* a row per daily */
.dl-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
/* two columns of rows where there's room: fourteen rows in one would run long */
@media (min-width: 900px) { .dl-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.dl-row {
  display: grid; grid-template-columns: 112px minmax(0, 1fr) auto; align-items: center;
  background: var(--card); border: var(--edge); box-shadow: var(--card-shadow); border-radius: var(--radius); overflow: hidden;
}
.dl-art { display: block; align-self: stretch; min-height: 84px; overflow: hidden; background: var(--tile); border-right: var(--edge); }
.dl-art svg { width: 100%; height: 100%; display: block; }
.dl-text { min-width: 0; padding: 10px 16px; }
.dl-text h2 { margin: 0; font-size: 18px; line-height: 1.3; }
.dl-play { text-decoration: none; }
.dl-play:hover { text-decoration: underline; text-underline-offset: 3px; }
/* the whole row is the link's target, for a finger */
.dl-play::after { content: ""; position: absolute; inset: 0; }
.dl-row { position: relative; }
.dl-what { margin: 0; font-size: var(--t-note); color: var(--ink-soft); }
.dl-status { margin: 4px 0 0; font-size: var(--t-note); font-weight: 600; font-variant-numeric: tabular-nums; display: flex; align-items: center; gap: 6px; }
.dl-row:not(.is-solved, .is-going) .dl-status { font-weight: 400; color: var(--ink-soft); }
.dl-row.is-going .dl-status { color: var(--ink); }
.dl-tick { flex: none; width: 16px; height: 16px; border-radius: 50%; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%23f4efe4' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat; }
.dl-side { margin: 0; padding: 10px 16px 10px 0; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font-size: var(--t-note); text-align: right; }
.dl-streak { color: var(--ink-soft); white-space: nowrap; font-variant-numeric: tabular-nums; }
.dl-streak:empty { display: none; }
/* (above the row's link, so it's its own target) */
.dl-stats { position: relative; z-index: 1; display: inline-flex; align-items: center; min-height: 36px; padding: 0 4px; color: var(--ink); text-underline-offset: 3px; }
.dl-stats:hover { text-decoration-thickness: 2px; }
.dl-row:has(.dl-play:hover), .dl-row:has(.dl-play:focus-visible) { box-shadow: var(--card-shadow-up); transform: translateY(-3px); }
.dl-row { transition: transform .15s ease, box-shadow .15s ease; }
.dl-row.is-solved { background: color-mix(in srgb, var(--card) 70%, var(--paper)); }
.dl-row.is-solved .dl-art { opacity: .8; }
.dl-empty { padding: var(--s3); border: 1.5px dashed var(--line); border-radius: var(--radius); color: var(--ink-soft); }
.dl .account-line { margin-top: var(--s4); }

@media (prefers-reduced-motion: reduce) { .dl-row { transition: none; } }

/* the full sweep's card (a house result sheet): each daily on a line, its
   tile's color as a mark, its time at the right; Share is the primary */
.dl-all-done [data-share-sweep] { min-height: 44px; }
.dl-sweep-list { list-style: none; margin: 0; padding: 0; width: 100%; display: grid; gap: 4px; text-align: left; }
.dl-sweep-list li { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto auto; align-items: center; gap: 10px; min-height: 32px; padding: 2px 4px; border-bottom: 1px solid var(--paper-edge); }
.dl-sweep-list li:last-child { border-bottom: 0; }
.dl-sweep-mark { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--tile); font-size: 16px; line-height: 1; }
.dl-sweep-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dl-sweep-list b { font-variant-numeric: tabular-nums; font-weight: 700; }
.dl-sweep-tag { grid-column: 4; padding: 1px 8px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--ink); color: var(--paper-2); }
.dl-sweep-list li:not(:has(.dl-sweep-tag)) b { grid-column: 3 / span 2; justify-self: end; }

@media (max-width: 640px) {
  .dl-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .dl-tile { padding: 10px 12px; }
  .dl-tile b { font-size: 24px; }
  .dl-next .btn { flex: 1 1 100%; }
  .dl-row { grid-template-columns: 88px minmax(0, 1fr); }
  .dl-art { grid-row: span 2; }
  .dl-text { padding: 10px 12px 0; }
  .dl-text h2 { font-size: 16px; }
  .dl-side { flex-direction: row; justify-content: space-between; align-items: center; padding: 0 12px 6px; text-align: left; gap: var(--s2); }
  .dl-stats { margin-left: auto; min-height: 36px; }
}
/* A finger's reach on a touch screen (docs/design-language.md, "Fine details"): Stats is 44px square at least. */
@media (pointer: coarse) {
  .dl-stats { min-height: 44px; min-width: 44px; justify-content: center; }
}
