/* ============================================================
   KAMI OS — CYCLE 6 · FRICTIONLESS LOGGING (.c6- namespace)
   Retro-log sheet · streak shields · vacation mode · CSV import
   · end-of-day catch-up. Mobile-first, 393px primary surface.
   ============================================================ */

/* ---------- Streak shields: hollow-ring dot states ---------- */
.c5h-cell.shielded {
  background: transparent;
  box-shadow: inset 0 0 0 2px var(--accent);
  opacity: 0.9;
}
.c5h-cell.paused {
  background: transparent;
  box-shadow: inset 0 0 0 1px rgba(255, 176, 32, 0.5);
  opacity: 0.55;
}
.hab4-dot.shielded {
  background: transparent;
  box-shadow: inset 0 0 0 1.5px var(--accent);
}

/* ---------- Retro-log "⋯" button (≥44px touch target) ---------- */
.c5h-more {
  flex-shrink: 0;
  min-width: 44px; min-height: 44px;
  margin: -8px -8px -10px 0;
  background: none; border: none; border-radius: var(--radius-sm);
  color: var(--text-faint); font-size: 18px; line-height: 1;
  cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.c5h-more:hover, .c5h-more:active { color: var(--accent); background: rgba(0, 229, 255, 0.06); }

/* ---------- Retro modal ---------- */
.c6-retro-name { font-size: 14px; font-weight: 600; margin-bottom: 12px; }
.c6-retro-yday { width: 100%; min-height: 46px; }
.c6-retro-or {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 1px;
  text-transform: uppercase; color: var(--text-faint);
  text-align: center; margin: 12px 0 8px;
}

/* ---------- Vacation mode badge ---------- */
.c6-paused-badge {
  display: inline-flex; align-items: center; align-self: center;
  padding: 4px 10px; border-radius: 999px;
  border: 1px solid rgba(255, 176, 32, 0.45); background: var(--warn-dim);
  color: var(--warn); font-family: var(--font-mono);
  font-size: 10.5px; letter-spacing: 1px;
}

/* ---------- CSV import modal ---------- */
.c6-imp-hint { font-size: 12.5px; line-height: 1.55; margin-bottom: 10px; }
.c6-imp-file { padding: 10px; min-height: 44px; }
.c6-imp-counts { font-size: 12.5px; color: var(--text-dim); margin-bottom: 8px; }
.c6-imp-scroll { max-height: 300px; overflow: auto; border: 1px solid var(--glass-border); border-radius: var(--radius-sm); }
.c6-imp-table { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.c6-imp-table th {
  position: sticky; top: 0; text-align: left; padding: 7px 8px;
  background: rgba(7, 11, 18, 0.95); color: var(--text-faint);
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 1px; text-transform: uppercase;
}
.c6-imp-table td { padding: 6px 8px; border-top: 1px solid rgba(255, 255, 255, 0.05); color: var(--text-dim); white-space: nowrap; }
.c6-imp-desc { max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
.c6-imp-more { font-size: 11px; color: var(--text-faint); margin-top: 6px; }
.c6-imp-bad { font-family: var(--font-mono); font-size: 10.5px; color: var(--warn); margin-top: 4px; }

/* ---------- End-of-day catch-up banner (toast can't take handlers) ---------- */
.c6-catchup {
  position: fixed; left: 14px; right: 14px;
  bottom: calc(74px + env(safe-area-inset-bottom, 0px));
  z-index: 90; /* under modals (100) and toasts (200) */
  display: flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 10px 8px 10px 14px;
  border: 1px solid rgba(255, 176, 32, 0.45); border-radius: var(--radius);
  background: linear-gradient(135deg, var(--warn-dim), rgba(7, 11, 18, 0.95));
  color: var(--text); font-size: 13px; cursor: pointer;
  box-shadow: var(--shadow); animation: slidein 0.25s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
@media (min-width: 681px) { .c6-catchup { left: auto; right: 22px; bottom: 22px; max-width: 380px; } }
.c6-catchup-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--warn); box-shadow: 0 0 8px var(--warn); }
.c6-catchup-text { flex: 1; }
.c6-catchup-x {
  flex: none; min-width: 44px; min-height: 44px; margin: -10px 0;
  background: none; border: none; color: var(--text-faint);
  font-size: 18px; cursor: pointer;
}

/* ---------- Catch-up sheet ---------- */
.c6-cu-q { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; margin: 14px 0 8px; }
.c6-cu-q:first-child { margin-top: 0; }
.c6-cu-n {
  width: 20px; height: 20px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: rgba(0, 229, 255, 0.12); color: var(--accent);
  font-family: var(--font-mono); font-size: 11px;
}
.c6-cu-habits { display: flex; flex-direction: column; gap: 6px; }
.c6-cu-habit {
  display: flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 8px 12px;
  border: 1px solid var(--glass-border); border-radius: var(--radius-sm);
  background: rgba(4, 8, 14, 0.4); font-size: 13px; cursor: pointer;
}
.c6-cu-habit input { width: 18px; height: 18px; accent-color: var(--accent); }
.c6-cu-habit:has(input:checked) { border-color: rgba(46, 230, 166, 0.4); background: var(--good-dim); }
.c6-cu-habit:has(input:disabled) { opacity: 0.55; }
