/* =========================================================================
   BriefNepal Daily Quiz — /play/daily (play-daily.php + js/daily.js)
   Uses the site tokens from style.css. Mobile-first; the card is capped at a
   comfortable reading width on desktop.
   ========================================================================= */

.daily { max-width: 760px; padding-top: 14px; padding-bottom: 40px; }
.daily__crumbs { font-size: .8rem; color: var(--text-faint); margin-bottom: 14px; }
.daily__crumbs a { color: var(--brand); font-weight: 600; }

.daily__head { margin-bottom: 18px; }
.daily__kicker { margin: 0 0 6px; font-size: .78rem; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; color: var(--accent); }
.daily__title { font-family: var(--head); font-size: clamp(1.6rem, 5vw, 2.3rem); color: var(--ink-2); }
.daily__lead { margin: 8px 0 0; color: var(--text-soft); font-size: 1rem; line-height: 1.55; }
.daily__h2 { font-family: var(--head); font-size: 1.25rem; color: var(--ink-2); margin: 0 0 12px; }

/* ---------- no-JS fallback list ---------- */
.daily__list { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; counter-reset: dq; }
.daily-q { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 16px; }
.daily-q__cat { margin: 0 0 6px; font-size: .75rem; font-weight: 700; color: var(--text-faint); text-transform: uppercase; letter-spacing: .4px; }
.daily-q__text { font-size: 1.05rem; line-height: 1.4; color: var(--text); }
.daily-q__opts { margin: 10px 0; padding-left: 20px; color: var(--text-soft); }
.daily-q__ans summary { cursor: pointer; font-weight: 700; color: var(--brand); }
.daily-q__ans p { margin: 8px 0 0; line-height: 1.5; }
.daily-q__ans a { color: var(--brand); font-weight: 600; }

/* ---------- game card ---------- */
.daily__game { margin-bottom: 28px; }
.daily-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  padding: 20px 16px; box-shadow: 0 6px 24px rgba(3, 78, 162, .08);
}
@media (min-width: 640px) { .daily-card { padding: 28px; } }

.daily-card--intro, .daily-card--result { text-align: center; }
.daily-card__emoji { font-size: 3rem; margin: 0; line-height: 1; }
.daily-card__title { font-family: var(--head); font-size: 1.4rem; margin: 10px 0 4px; color: var(--ink-2); }
.daily-card__meta { margin: 0 0 12px; color: var(--text-faint); font-weight: 600; letter-spacing: 1px; }
.daily-card__streak { margin: 0 0 14px; font-weight: 700; color: var(--accent); }
.daily-card__fine { margin: 12px 0 0; font-size: .8rem; color: var(--text-faint); }

.daily-card__top { display: flex; justify-content: space-between; gap: 8px; align-items: center; font-size: .78rem; font-weight: 700; }
.daily-card__label { color: var(--brand); text-transform: uppercase; letter-spacing: .5px; font-size: .78rem; font-weight: 700; margin: 0; }
.daily-card__cat { color: var(--text-faint); }
.daily-card__q { font-size: clamp(1.1rem, 3.6vw, 1.35rem); line-height: 1.4; margin: 6px 0 16px; color: var(--text); outline: none; }

/* ---------- timer ---------- */
.daily-timer { height: 6px; border-radius: 999px; background: var(--border); overflow: hidden; margin-top: 12px; }
.daily-timer__bar {
  display: block; height: 100%; width: 100%; background: var(--brand);
  transform-origin: left center; transition: transform .1s linear, background .3s;
}
.daily-timer__bar.is-low { background: var(--accent); }
.daily-timer__txt { margin: 4px 0 0; text-align: right; font-size: .75rem; font-weight: 700; color: var(--text-faint); font-variant-numeric: tabular-nums; }

/* ---------- options ---------- */
.daily-opts { display: grid; gap: 10px; }
@media (min-width: 640px) { .daily-opts { grid-template-columns: 1fr 1fr; } }
.daily-opt {
  display: flex; align-items: center; gap: 10px; width: 100%;
  min-height: 52px; padding: 10px 14px; text-align: left;
  border: 2px solid var(--border); border-radius: 10px; background: var(--surface);
  font: inherit; font-size: .98rem; font-weight: 600; color: var(--text); cursor: pointer;
  transition: border-color .15s, background .15s, transform .1s;
}
.daily-opt:hover:not(:disabled) { border-color: var(--brand); background: #f3f7fc; }
.daily-opt:active:not(:disabled) { transform: scale(.98); }
.daily-opt:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
.daily-opt:disabled { cursor: default; }
.daily-opt__key {
  flex: none; display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 6px;
  background: var(--bg); color: var(--text-faint); font-size: .78rem; font-weight: 800;
}
.daily-opt.is-right { border-color: #1e8e3e; background: #e8f5ec; }
.daily-opt.is-right .daily-opt__key { background: #1e8e3e; color: #fff; }
.daily-opt.is-wrong { border-color: var(--accent); background: #fdecee; }
.daily-opt.is-wrong .daily-opt__key { background: var(--accent); color: #fff; }

/* ---------- feedback ---------- */
.daily-feedback { margin-top: 16px; padding: 14px; border-radius: 10px; background: var(--bg); animation: daily-in .25s ease; }
.daily-feedback.is-right { background: #e8f5ec; }
.daily-feedback.is-wrong { background: #fdf3f4; }
.daily-feedback__verdict { margin: 0 0 6px; font-weight: 800; }
.daily-feedback__x { margin: 0 0 12px; line-height: 1.55; color: var(--text-soft); }
.daily-feedback__x a { color: var(--brand); font-weight: 700; }

/* ---------- buttons ---------- */
.daily-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 46px; padding: 10px 20px; border-radius: 999px;
  border: 2px solid var(--brand); background: var(--surface); color: var(--brand);
  font: inherit; font-weight: 700; font-size: .95rem; cursor: pointer;
}
.daily-btn:hover { background: #f3f7fc; }
.daily-btn:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
.daily-btn--primary { background: var(--brand); color: #fff; }
.daily-btn--primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); }

/* ---------- result ---------- */
.daily-result__score { margin: 6px 0 0; font-family: var(--head); font-size: 1.6rem; color: var(--text-faint); }
.daily-result__score span { font-size: 3.6rem; color: var(--ink-2); }
.daily-result__squares { margin: 4px 0; font-size: 1.6rem; letter-spacing: 4px; }
.daily-result__msg { margin: 4px 0 16px; color: var(--text-soft); font-weight: 600; }
.daily-result__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 auto 18px; max-width: 380px; }
.daily-result__stats div { background: var(--bg); border-radius: 10px; padding: 10px 4px; }
.daily-result__stats b { display: block; font-size: 1.4rem; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.daily-result__stats span { font-size: .72rem; color: var(--text-faint); text-transform: uppercase; letter-spacing: .4px; font-weight: 700; }
.daily-result__actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.daily-result__next { margin: 16px 0 0; color: var(--text-soft); font-size: .9rem; }
.daily-result__next strong { font-variant-numeric: tabular-nums; color: var(--ink-2); }
.daily-review { margin-top: 18px; text-align: left; }
.daily-review summary { cursor: pointer; font-weight: 700; color: var(--brand); text-align: center; }
.daily-review ol { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 8px; line-height: 1.45; font-size: .92rem; }
.daily-review a { color: var(--brand); font-weight: 600; }

/* ---------- keep playing ---------- */
.daily__more { margin: 8px 0 28px; }
.daily__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (min-width: 640px) { .daily__grid { grid-template-columns: repeat(4, 1fr); } }
.daily-tile {
  display: flex; flex-direction: column; gap: 4px; padding: 14px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.daily-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); border-color: var(--brand); }
.daily-tile:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
.daily-tile__emoji { font-size: 1.8rem; line-height: 1; }
.daily-tile__name { font-weight: 800; color: var(--ink-2); }
.daily-tile__line { font-size: .82rem; color: var(--text-soft); line-height: 1.4; }

.daily__about { color: var(--text-soft); line-height: 1.6; }
.daily__about a { color: var(--brand); font-weight: 600; }

@keyframes daily-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .daily-feedback { animation: none; }
  .daily-timer__bar, .daily-opt, .daily-tile { transition: none; }
}
