
/* ==========================================================================
   DAILY WORKOUTS — a section inside My Rhythm → Routines
   Personal movement rituals, not a fitness tracker. Prefix dw- (verified free).
   ========================================================================== */
#dwRoot{
  --dw-navy:#243447; --dw-ink:#2B2B2B; --dw-muted:#657482; --dw-line:#E8E4DC;
  --dw-sage:#5F7350; --dw-sage-soft:#EEF4EC; --dw-olive:#7D9E77;
  --dw-blush:#F6EDE7; --dw-oat:#F5F0E6; --dw-gold:#CF9E3F;
  --dw-page:#5B8A8F;                     /* My Rhythm page background */
  font-family:'Nunito',system-ui,-apple-system,sans-serif; margin-top:28px;
}
#dwRoot *{ box-sizing:border-box; }
#dwRoot [hidden]{ display:none !important; }

.dw-sec{ margin-bottom:28px; }
.dw-eyebrow{ font-size:.64rem; font-weight:800; letter-spacing:.18em; text-transform:uppercase; margin:0 0 8px;
  color:var(--dw-sage) !important; -webkit-text-fill-color:var(--dw-sage) !important; }
.dw-h2{ font-family:'Playfair Display',Georgia,serif; font-weight:700; font-size:clamp(1.2rem,2.2vw,1.55rem);
  line-height:1.2; margin:0 0 6px;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-h3{ font-family:'Playfair Display',Georgia,serif; font-weight:700; font-size:1.05rem; margin:0;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-sub{ font-size:.9rem; line-height:1.65; margin:0 0 16px; max-width:68ch;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-fine{ font-size:.8rem; line-height:1.55;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }

.dw-card{ background:#fff; border:1px solid var(--dw-line); border-radius:22px; padding:20px; }
.dw-card--soft{ background:var(--dw-sage-soft); border-color:#DCE7D8; }
.dw-card--oat{ background:var(--dw-oat); border-color:#E7DFCE; }

/* buttons */
.dw-btn{ display:inline-flex; align-items:center; justify-content:center; gap:8px; cursor:pointer;
  font-family:inherit; font-size:.86rem; font-weight:800; border-radius:999px; padding:12px 20px;
  min-height:44px; border:1px solid rgba(18,33,58,.18); background:#fff;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important;
  transition:background .16s, border-color .16s, transform .16s; }
.dw-btn:hover{ background:var(--dw-sage-soft); border-color:var(--dw-olive); transform:translateY(-1px); }
.dw-btn--primary{ background:var(--dw-navy) !important; border-color:var(--dw-navy) !important;
  color:#fff !important; -webkit-text-fill-color:#fff !important; }
.dw-btn--primary:hover{ background:#31465F !important; }
.dw-btn--sm{ min-height:44px; padding:9px 15px; font-size:.79rem; }
.dw-btn--ghost{ background:none; border:0; text-decoration:underline; padding:9px;
  color:var(--dw-sage) !important; -webkit-text-fill-color:var(--dw-sage) !important; }
.dw-btn:focus-visible,.dw-opt:focus-visible,.dw-day:focus-visible,.dw-menu-btn:focus-visible,
.dw-chip:focus-visible{ outline:3px solid var(--dw-gold); outline-offset:2px; }
.dw-acts{ display:flex; gap:10px; flex-wrap:wrap; }

/* landing */
.dw-landing{ display:flex; align-items:flex-end; justify-content:space-between; gap:20px; flex-wrap:wrap;
  margin-bottom:20px; }

/* today */
.dw-today{ display:grid; grid-template-columns:auto minmax(0,1fr) auto; gap:16px; align-items:center; }
.dw-ic{ width:56px; height:56px; border-radius:18px; display:grid; place-items:center; font-size:1.5rem;
  background:var(--dw-sage-soft); flex:none; }
.dw-meta{ display:flex; flex-wrap:wrap; gap:10px; margin-top:5px; font-size:.82rem;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-meta span{ display:inline-flex; align-items:center; gap:5px; }

/* option pills (completion, feelings) */
.dw-opts{ display:flex; gap:8px; flex-wrap:wrap; }
.dw-opt{ cursor:pointer; font-family:inherit; font-size:.82rem; font-weight:700; border-radius:999px;
  padding:10px 15px; min-height:44px; border:1px solid var(--dw-line); background:#fff;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-opt:hover{ background:var(--dw-sage-soft); border-color:var(--dw-olive); }
.dw-opt[aria-pressed="true"]{ background:var(--dw-navy); border-color:var(--dw-navy);
  color:#fff !important; -webkit-text-fill-color:#fff !important; }
.dw-block{ margin-top:16px; padding-top:16px; border-top:1px dashed var(--dw-line); }
.dw-lbl{ display:block; font-size:.66rem; font-weight:800; letter-spacing:.11em; text-transform:uppercase;
  margin-bottom:8px; color:var(--dw-sage) !important; -webkit-text-fill-color:var(--dw-sage) !important; }

/* my workouts */
.dw-grid{ display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:16px; }
.dw-w{ position:relative; background:#fff; border:1px solid var(--dw-line); border-radius:22px; padding:18px;
  display:flex; flex-direction:column; gap:8px; }
.dw-w-top{ display:flex; align-items:flex-start; gap:12px; }
/* Pills sized so the text sits comfortably rather than touching the edges, and
   filled with the page's own teal. White label at 3.83:1 — see the note in chat. */
.dw-tag{ display:inline-flex; align-items:center; border-radius:999px !important; padding:7px 15px !important; min-height:28px;
  font-size:.7rem; font-weight:800; letter-spacing:.06em; text-transform:uppercase; line-height:1.35;
  background:var(--dw-page) !important; border:1px solid rgba(0,0,0,.06);
  color:#fff !important; -webkit-text-fill-color:#fff !important; }
.dw-tag--done{ background:var(--dw-page) !important; border-color:rgba(0,0,0,.06);
  color:#fff !important; -webkit-text-fill-color:#fff !important; }
.dw-menu{ margin-left:auto; position:relative; }
.dw-menu-btn{ width:44px; height:44px; border-radius:50%; border:1px solid transparent; background:none;
  cursor:pointer; font-size:1.05rem;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-menu-btn:hover{ background:#F4F4F1; }
.dw-menu-pop{ position:absolute; right:0; top:46px; z-index:30; background:#fff; border:1px solid var(--dw-line);
  border-radius:14px; padding:6px; min-width:158px; box-shadow:0 14px 34px rgba(36,52,71,.14); }
.dw-menu-pop button{ display:block; width:100%; text-align:left; background:none; border:0; cursor:pointer;
  font-family:inherit; font-size:.84rem; padding:10px; border-radius:9px; min-height:44px;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-menu-pop button:hover{ background:var(--dw-sage-soft); }
.dw-w-foot{ margin-top:auto; padding-top:6px; display:flex; gap:8px; flex-wrap:wrap; align-items:center; }

/* weekly rhythm */
.dw-week{ display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:8px; }
.dw-day{ background:#fff; border:1px solid var(--dw-line); border-radius:16px; padding:12px 6px;
  text-align:center; font-family:inherit; cursor:default; }
.dw-day b{ display:block; font-size:.66rem; font-weight:800; letter-spacing:.08em; text-transform:uppercase;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-day i{ display:block; margin-top:7px; font-style:normal; font-size:1.05rem;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-day.is-done{ background:var(--dw-sage-soft); border-color:#DCE7D8; }
.dw-day.is-done i{ color:var(--dw-sage) !important; -webkit-text-fill-color:var(--dw-sage) !important; }
.dw-day.is-today{ border-color:var(--dw-navy); border-width:2px; }
.dw-tally{ display:flex; gap:22px; flex-wrap:wrap; margin-top:16px; }
.dw-tally div b{ display:block; font-size:1.5rem; font-weight:800; line-height:1.1;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-tally div span{ font-size:.78rem; color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }

/* steps */
.dw-step{ display:flex; align-items:center; gap:12px; background:#fff; border:1px solid var(--dw-line);
  border-radius:16px; padding:12px 14px; }
.dw-step + .dw-step{ margin-top:9px; }
.dw-step-n{ width:30px; height:30px; border-radius:50%; background:var(--dw-sage-soft); display:grid;
  place-items:center; font-size:.8rem; font-weight:800; flex:none;
  color:var(--dw-sage) !important; -webkit-text-fill-color:var(--dw-sage) !important; }
.dw-step-b{ flex:1; min-width:0; }
.dw-step-b b{ display:block; font-size:.9rem;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-step-b span{ font-size:.78rem; color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-move{ display:flex; flex-direction:column; gap:2px; }
.dw-move button{ width:30px; height:22px; border:1px solid var(--dw-line); background:#fff; cursor:pointer;
  border-radius:7px; font-size:.6rem; line-height:1;
  color:var(--dw-muted) !important; -webkit-text-fill-color:var(--dw-muted) !important; }
.dw-move button:hover{ background:var(--dw-sage-soft); }
.dw-thumb{ width:74px; height:52px; border-radius:11px; overflow:hidden; flex:none; background:var(--dw-oat); }
.dw-thumb img{ width:100%; height:100%; object-fit:cover; display:block; }

/* timer */
.dw-timer{ text-align:center; padding:10px 0; }
.dw-timer b{ display:block; font-size:2.6rem; font-weight:800; line-height:1;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }

/* forms */
.dw-fld{ margin-bottom:13px; }
.dw-in,.dw-ta,.dw-sel{ width:100%; border:1.5px solid var(--dw-line); border-radius:13px; padding:11px 14px;
  font-family:inherit; font-size:.92rem; background:#FDFCFA; color:var(--dw-navy); min-height:44px; }
.dw-in:focus,.dw-ta:focus,.dw-sel:focus{ outline:none; border-color:var(--dw-olive); background:#fff; }
.dw-ta{ min-height:76px; resize:vertical; }
.dw-err{ margin:6px 0 0; font-size:.8rem; font-weight:700;
  color:#A4453A !important; -webkit-text-fill-color:#A4453A !important; }
.dw-days{ display:flex; gap:6px; flex-wrap:wrap; }
.dw-day-t{ cursor:pointer; font-family:inherit; font-size:.78rem; font-weight:700; border-radius:12px;
  width:52px; min-height:44px; border:1px solid var(--dw-line); background:#fff;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-day-t[aria-pressed="true"]{ background:var(--dw-navy); border-color:var(--dw-navy);
  color:#fff !important; -webkit-text-fill-color:#fff !important; }
.dw-addrow{ display:flex; gap:8px; flex-wrap:wrap; margin:12px 0; }
.dw-addrow button{ font-size:.78rem; padding:9px 13px; min-height:44px; border-radius:12px;
  border:1px dashed var(--dw-line); background:#FDFCFA; cursor:pointer; font-family:inherit;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-addrow button:hover{ background:var(--dw-sage-soft); border-color:var(--dw-olive); }
.dw-range{ width:100%; accent-color:var(--dw-sage); min-height:44px; }
.dw-scale{ display:flex; align-items:center; gap:12px; }
.dw-scale output{ font-weight:800; min-width:1.5em;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }

/* insight */
.dw-insight{ background:var(--dw-sage-soft); border:1px solid #DCE7D8; border-radius:20px; padding:18px 20px;
  font-size:.9rem; line-height:1.65;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }

/* modal */
.dw-modal-bg{ position:fixed; inset:0; background:rgba(20,30,40,.46); z-index:200000; display:flex;
  align-items:center; justify-content:center; padding:20px; }
.dw-modal{ background:#fff; border-radius:24px; width:100%; max-width:620px; max-height:88vh;
  overflow-y:auto; padding:26px; }
.dw-modal-h{ display:flex; align-items:flex-start; justify-content:space-between; gap:14px; margin-bottom:12px; }
.dw-x{ cursor:pointer; border:1px solid var(--dw-line); background:#fff; border-radius:50%;
  width:44px; height:44px; font-size:1.1rem; flex:none;
  color:var(--dw-navy) !important; -webkit-text-fill-color:var(--dw-navy) !important; }
.dw-modal-foot{ display:flex; gap:10px; flex-wrap:wrap; margin-top:18px; }
.dw-empty{ text-align:center; padding:34px 20px; }

@media (max-width:1024px){ .dw-grid{ grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:760px){
  .dw-grid{ grid-template-columns:minmax(0,1fr); }
  .dw-today{ grid-template-columns:auto minmax(0,1fr); }
  .dw-today > .dw-acts{ grid-column:1/-1; }
  .dw-week{ grid-template-columns:repeat(4,minmax(0,1fr)); }
  .dw-modal{ max-width:none; border-radius:22px 22px 0 0; align-self:flex-end; max-height:92vh; }
  .dw-modal-bg{ padding:0; align-items:flex-end; }
}
@media (prefers-reduced-motion:reduce){ #dwRoot *{ transition:none !important; } }
