/*
 * Daily poetry and comment streaks (includes/streak.inc.php).
 *
 * Poetry streaks are gold (the site's #ccad6c button gold, #ffcc2f at 30+
 * days) with a flame; comment streaks are karma green (#b5e48c on #1a2a12,
 * the same pair as .pvr-badge--karma on read_poetry.php) with a speech
 * bubble, so the two differ in shape as well as colour.
 *
 * Loaded once per page by sk_stylesheet(): in the <head> of the pages that
 * show chips, and from the login box on every other page that includes it.
 */

.pv-sr {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---- The chip beside a name --------------------------------------------- */

.pv-streak {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-left: 6px;
  padding: 0 7px 0 5px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: 700 11px/17px Helvetica, Verdana, Arial, sans-serif;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
  vertical-align: middle;
  box-sizing: border-box;
}
.pv-streak__icon { display: block; flex-shrink: 0; }

.pv-streak--poem.pv-streak--low  { border-color: #ccad6c; color: #ccad6c; background: transparent; }
.pv-streak--poem.pv-streak--mid  { border-color: #ccad6c; color: #000; background: #ccad6c; }
.pv-streak--poem.pv-streak--high { border-color: #ffcc2f; color: #000; background: #ffcc2f; box-shadow: 0 0 0 2px #000, 0 0 0 3px #ffcc2f; margin-left: 8px; }

.pv-streak--comment.pv-streak--low  { border-color: #b5e48c; color: #b5e48c; background: transparent; }
.pv-streak--comment.pv-streak--mid  { border-color: #3f5a2c; color: #b5e48c; background: #1a2a12; }
.pv-streak--comment.pv-streak--high { border-color: #b5e48c; color: #000; background: #b5e48c; box-shadow: 0 0 0 2px #000, 0 0 0 3px #b5e48c; margin-left: 8px; }

/* On the corner of a large avatar (read_poetry.php poet header). */
.pv-streak-avatar { position: relative; display: inline-block; line-height: 0; }
.pv-streak-avatar .pv-streak { position: absolute; right: -6px; bottom: -4px; margin: 0; box-shadow: 0 0 0 2px #000; }
.pv-streak-avatar .pv-streak--high { box-shadow: 0 0 0 2px #000, 0 0 0 3px #ffcc2f; }

.pv-streak-line { margin: 4px 0 0; font-size: 13px; font-weight: 700; color: #ccad6c; }

/* ---- The login box ------------------------------------------------------ */
/* main.css turns every span in #login-box into a padded block; these
   selectors carry the same two ids so the streak markup is left alone. */

#right-col #login-box .pv-streak-box span,
#login-box .pv-streak-box span { display: inline-flex; padding: 0; margin: 0; clear: none; }

.pv-streak-box__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  font-family: Helvetica, Verdana, Arial, sans-serif;
}
#right-col #login-box .pv-streak-box__top span.pv-streak-box__hi,
#login-box .pv-streak-box__top span.pv-streak-box__hi,
.pv-streak-box__hi { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; color: #a8a8a8; }
.pv-streak-box__hi a { color: #d3b06b; }
.pv-streak-box__hi a:hover { color: #ffcc2f; }

a.pv-streak-pill {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 11px 0 9px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: 700 13px/1 Helvetica, Verdana, Arial, sans-serif;
  text-decoration: none;
  box-sizing: border-box;
  white-space: nowrap;
}
a.pv-streak-pill--today { background: #ffcc2f; border-color: #ffcc2f; color: #000; }
a.pv-streak-pill--today:hover { background: #ffdb66; color: #000; }
a.pv-streak-pill--alive { border: 1px dashed #ffcc2f; color: #ffcc2f; }
a.pv-streak-pill--alive:hover { background: #2a2414; color: #ffcc2f; }
a.pv-streak-pill--none { border-color: #555; color: #c8c8c8; }
a.pv-streak-pill--none:hover { border-color: #ccad6c; color: #fff; }
a.pv-streak-pill:focus-visible { outline: 2px solid #ffcc2f; outline-offset: 2px; }

.pv-streak-box { margin: 8px 0 4px; }
.pv-streak-box__caption { margin: 6px 0 0; font: 11px/1.3 Helvetica, Verdana, Arial, sans-serif; color: #a8a8a8; text-align: right; }
.pv-streak-box--alive .pv-streak-box__caption { font-size: 12px; font-weight: 700; color: #ffcc2f; }

/* ---- The 7-day bar ------------------------------------------------------- */

.pv-streak-week { display: flex; gap: 4px; }
#right-col #login-box .pv-streak-week span.pv-streak-week__day,
#login-box .pv-streak-week span.pv-streak-week__day,
.pv-streak-week__day { display: block; flex: 1 1 0; height: 6px; border-radius: 3px; box-sizing: border-box; }
.pv-streak-week__day--off { border: 1px solid #444; }
.pv-streak-week--poem .pv-streak-week__day--on        { background: #ffcc2f; }
.pv-streak-week--poem .pv-streak-week__day--pending   { border: 1px dashed #ffcc2f; }
.pv-streak-week--comment .pv-streak-week__day--on      { background: #b5e48c; }
.pv-streak-week--comment .pv-streak-week__day--pending { border: 1px dashed #b5e48c; }

/* With day letters (poetry_entry.php). */
.pv-streak-week--letters .pv-streak-week__day { height: auto; border: 0; background: none; display: flex; flex-direction: column; align-items: stretch; gap: 3px; text-align: center; }
.pv-streak-week__letter { font-size: 10px; line-height: 1; color: #9a9a9a; }
.pv-streak-week--letters .pv-streak-week__day--today .pv-streak-week__letter { color: #ffcc2f; font-weight: 700; }
.pv-streak-week__bar { display: block; height: 18px; border-radius: 4px; box-sizing: border-box; border: 1px solid #444; }
.pv-streak-week--letters .pv-streak-week__day--on .pv-streak-week__bar { background: #ffcc2f; border-color: #ffcc2f; }
.pv-streak-week--letters .pv-streak-week__day--pending .pv-streak-week__bar { border: 1px dashed #ffcc2f; }

/* ---- poetry_entry.php ---------------------------------------------------- */

.pv-streak-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 270px;
  max-width: 100%;
  padding: 14px 16px;
  border: 1px solid #444;
  border-radius: 8px;
  background: #151515;
  box-sizing: border-box;
}
.pv-streak-card--alive { border: 1px dashed #ffcc2f; background: #1a1608; }
.pv-streak-card--today { border-color: #ffcc2f; background: #1a1608; }
.pv-streak-card__head { display: flex; align-items: center; gap: 10px; }
.pv-streak-card__head .pv-streak__icon { color: #ffcc2f; }
.pv-streak-card--none .pv-streak-card__head .pv-streak__icon { color: #a8a8a8; }
.pv-streak-card__count { display: block; font-size: 22px; font-weight: 700; line-height: 1.1; color: #ffcc2f; }
.pv-streak-card--none .pv-streak-card__count { color: #fff; }
.pv-streak-card__sub { display: block; font-size: 12px; color: #c9c9c9; }
.pv-streak-card__foot { margin: 0; font-size: 11px; color: #9a9a9a; }

.pv-streak-intro { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.pv-streak-hint { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 13px; color: #ffcc2f; }
.pve-submit .pv-streak-hint { flex: 1 1 100%; }

.pv-streak-done {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 14px;
  padding: 16px 18px;
  border-radius: 8px;
  background: #ffcc2f;
  color: #000;
}
.pv-streak-done__count { display: block; font-size: 24px; font-weight: 700; line-height: 1.1; }
.pv-streak-done__sub { display: block; font-size: 13px; }
.pv-streak-done--same { background: transparent; border: 1px solid #303030; color: #d6d6d6; }
.pv-streak-done--same .pv-streak-done__count { font-size: 15px; color: #ffcc2f; }
.pv-streak-done--same .pv-streak__icon { color: #ffcc2f; }
.pv-streak-done--milestone { box-shadow: 0 0 0 2px #000, 0 0 0 4px #ffcc2f; }

/* ---- read_poetry.php comments -------------------------------------------- */

.pv-streak-nudge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 12px;
  padding: 4px 10px 4px 8px;
  border: 1px solid #b5e48c;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #b5e48c;
}
/* read_poetry.css zeroes paragraph margins inside .pvr; keep the gap. */
.pvr p.pv-streak-nudge, #pv-read .pvr p.pv-streak-nudge { margin: 0 0 14px; }
.pv-streak-nudge--alive { border-style: dashed; }
.pv-streak-nudge--today { background: #1a2a12; border-color: #3f5a2c; }
.pv-streak-nudge--none  { border-color: #3f5a2c; color: #a8c98a; font-weight: 400; }

.pv-streak-posted {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 0;
  padding: 12px 16px;
  border: 1px solid #3f5a2c;
  border-radius: 8px;
  background: #1a2a12;
  color: #d6e8c6;
  font-size: 13px;
}
.pv-streak-posted[hidden] { display: none; }
.pv-streak-posted .pv-streak__icon { color: #b5e48c; flex-shrink: 0; }
.pv-streak-posted strong { display: block; font-size: 17px; color: #b5e48c; }

@media (max-width: 600px) {
  .pv-streak-card { width: 100%; }
}
