/* reskin-today.css — Today (check-in) surface reskinned to the finished mockup.
   Everything is scoped under #surface-checkin; tokens fall back to the mockup
   hex values so the look holds even if a theme variable is absent or differs. */

#surface-checkin {
  --rk-bg: var(--surface, #f1f2ee);
  --rk-ink: var(--ink, #233039);
  --rk-muted: var(--ink-muted, #3f4f5a);
  --rk-subtle: var(--ink-subtle, #647179);
  --rk-line: var(--border, #d0d2cc);
  --rk-azure: var(--accent, #2c6e9c);
  --rk-azure-tint: #dbe6ee;
  --rk-azure-hover: var(--accent-hover, #225777);
  --rk-azure-ink: var(--accent-ink, #f3f8fc);
  --rk-sage: var(--done, #5f8a74);
  --rk-gold: var(--exam, #ae8a3f);
  --rk-head: var(--font-head, "Newsreader", Georgia, serif);
  --rk-body: var(--font-body, "Inter", system-ui, sans-serif);
  --rk-data: var(--font-data, "JetBrains Mono", ui-monospace, monospace);
}

#surface-checkin .rk-today {
  max-width: 980px;
  margin: 0 auto;
  font-family: var(--rk-body);
  color: var(--rk-ink);
}

/* Visually-hidden helper that keeps #checkin-sub in the DOM for retention.js. */
#surface-checkin .rk-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---- Greeting band -------------------------------------------------------- */

#surface-checkin .rk-greet {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 180px;
  gap: 20px;
  align-items: center;
  padding: 30px 34px;
  border: 1px solid var(--rk-line);
  border-radius: 14px;
  background: linear-gradient(115deg, #f4f5f1, #eceee8);
  box-shadow: 0 1px 2px rgba(35, 48, 57, 0.06), 0 8px 22px rgba(35, 48, 57, 0.06);
  overflow: hidden;
}

#surface-checkin .rk-greet-eyebrow {
  margin: 0 0 12px;
  font-family: var(--rk-data);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--rk-azure);
}

#surface-checkin .rk-greet-line {
  margin: 0;
  font-family: var(--rk-head);
  font-weight: 600;
  font-size: 36px;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--rk-ink);
}

#surface-checkin .rk-greet-line em {
  font-style: italic;
}

#surface-checkin .rk-greet-sub {
  margin: 14px 0 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--rk-muted);
  max-width: 48ch;
}

#surface-checkin .rk-greet-tree {
  height: 184px;
  width: auto;
  object-fit: contain;
  justify-self: center;
  filter: drop-shadow(0 6px 14px rgba(35, 48, 57, 0.12));
}

/* ---- Review-due band ------------------------------------------------------ */

#surface-checkin .rk-review {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 18px;
  padding: 18px 22px;
  border: 1px solid var(--rk-line);
  border-radius: 12px;
  background: var(--rk-bg);
}

#surface-checkin .rk-review-count {
  flex: none;
  font-family: var(--rk-head);
  font-size: 32px;
  font-weight: 600;
  line-height: 1;
  color: var(--rk-sage);
}

#surface-checkin .rk-review-text {
  flex: 1;
  min-width: 0;
}

#surface-checkin .rk-review-line {
  font-weight: 600;
  font-size: 15px;
  color: var(--rk-ink);
}

#surface-checkin .rk-review-sub {
  margin-top: 3px;
  font-family: var(--rk-data);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--rk-subtle);
}

#surface-checkin .rk-review.is-calm .rk-review-line {
  color: var(--rk-ink);
}

#surface-checkin .rk-review-btn {
  flex: none;
  font-family: var(--rk-body);
  font-size: 13.5px;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 6px;
  border: 1px solid var(--rk-azure);
  background: var(--rk-azure-tint);
  color: var(--rk-azure-hover);
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease;
}

#surface-checkin .rk-review-btn:hover {
  background: var(--rk-azure);
  color: var(--rk-azure-ink);
}

#surface-checkin .rk-review-btn:focus-visible {
  outline: 2px solid var(--rk-azure-hover);
  outline-offset: 2px;
}

/* ---- Per-course pacing grid ----------------------------------------------- */

#surface-checkin .rk-courses {
  margin-top: 26px;
}

#surface-checkin .rk-courses-label {
  margin: 0 0 12px;
  font-family: var(--rk-data);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--rk-subtle);
}

#surface-checkin .rk-course-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

#surface-checkin .rk-course {
  position: relative;
  border: 1px solid var(--rk-line);
  border-radius: 12px;
  background: var(--rk-bg);
  padding: 18px 20px;
  overflow: hidden;
}

#surface-checkin .rk-course-sprig {
  position: absolute;
  right: -6px;
  bottom: -8px;
  height: 96px;
  width: auto;
  object-fit: contain;
  opacity: 0.5;
  pointer-events: none;
}

#surface-checkin .rk-course-body {
  position: relative;
}

#surface-checkin .rk-course-status {
  font-family: var(--rk-data);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--rk-subtle);
}

#surface-checkin .rk-pace-on .rk-course-status {
  color: var(--rk-sage);
}

#surface-checkin .rk-pace-behind .rk-course-status {
  color: var(--rk-gold);
}

#surface-checkin .rk-pace-neutral .rk-course-status {
  color: var(--rk-subtle);
}

#surface-checkin .rk-course-name {
  margin-top: 4px;
  font-family: var(--rk-head);
  font-size: 19px;
  font-weight: 600;
  color: var(--rk-ink);
}

#surface-checkin .rk-course-rec {
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--rk-muted);
  max-width: 30ch;
}

/* ---- Responsive ----------------------------------------------------------- */

@media (max-width: 720px) {
  #surface-checkin .rk-greet {
    grid-template-columns: 1fr;
    padding: 24px 24px;
  }

  #surface-checkin .rk-greet-tree {
    display: none;
  }

  #surface-checkin .rk-greet-line {
    font-size: 30px;
  }

  #surface-checkin .rk-course-grid {
    grid-template-columns: 1fr;
  }

  #surface-checkin .rk-course-sprig {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  #surface-checkin .rk-review-btn {
    transition: none;
  }
}
