/* =============================================================================
   Athlete Condition — Home Canvas Widgets (Phase 3)
   Five widgets, five CSS prefixes.
   border-radius: 0 everywhere. Teal #14b8a6. Coach #0F6E56. Athlete #185FA5.
   ============================================================================= */

/* ----- Shared loading / error / confirmation states ----- */
.dw-container, .qlw-container, .qlbp-container, .qlrhr-container, .acw-container {
  font-size: 13px;
  color: #1a1a18;
}
.dw-loading, .qlw-loading, .qlbp-loading, .qlrhr-loading, .acw-loading {
  text-align: center;
  padding: 20px 0;
  color: #9ca3af;
}
.dw-error, .qlw-error, .qlbp-error, .qlrhr-error, .acw-error {
  padding: 12px;
  background: #FCEBEB;
  border: 0.5px solid #f5c0c0;
  font-size: 12px;
  color: #791F1F;
}

/* =============================================================================
   1. DAILY WELLNESS WIDGET (dw-)
   ============================================================================= */

.dw-state-meta {
  font-size: 11px;
  color: #888;
  margin-bottom: 10px;
}
.dw-row {
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 0.5px solid #e0e0dc;
}
.dw-row:last-of-type { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.dw-row-label {
  font-size: 11px;
  color: #555;
  margin-bottom: 5px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.dw-row-value {
  font-size: 12px;
  font-weight: 500;
  color: #14b8a6;
}
.dw-face-row { display: flex; gap: 3px; }
.dw-fb {
  flex: 1;
  padding: 7px 0;
  border: 0.5px solid #e0e0dc;
  background: transparent;
  font-size: 18px;
  cursor: pointer;
  text-align: center;
  line-height: 1;
  border-radius: 0;
  font-family: inherit;
}
.dw-fb.sel { border-color: #14b8a6; background: #E1F5EE; }
.dw-face-scale {
  display: flex;
  justify-content: space-between;
  font-size: 9px;
  color: #888;
  margin-top: 2px;
}
.dw-num-row { display: flex; gap: 2px; }
.dw-nb {
  flex: 1;
  height: 26px;
  border: 0.5px solid #e0e0dc;
  background: transparent;
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  border-radius: 0;
  font-family: inherit;
}
.dw-nb.sel { border-color: #14b8a6; background: #E1F5EE; color: #085041; font-weight: 500; }
.dw-note-link {
  font-size: 10px;
  color: #14b8a6;
  cursor: pointer;
  margin-top: 5px;
  display: inline-block;
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
}
.dw-note-exp { margin-top: 6px; display: none; }
.dw-note-exp.open { display: block; }
.dw-note-exp textarea {
  width: 100%;
  padding: 5px 8px;
  border: 0.5px solid #e0e0dc;
  font-size: 11px;
  font-family: inherit;
  resize: none;
  height: 36px;
  background: transparent;
  color: #1a1a18;
  border-radius: 0;
}
.dw-sharing-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
}
.dw-sharing-label { font-size: 10px; color: #888; }
.dw-tt {
  width: 26px; height: 14px;
  border-radius: 7px;
  position: relative;
  cursor: pointer;
}
.dw-tt.on { background: #14b8a6; }
.dw-tt.off { background: #bbb; }
.dw-tt-thumb {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #fff;
  position: absolute;
  top: 2px;
  transition: left 0.15s ease;
}
.dw-tt.on .dw-tt-thumb { left: 14px; }
.dw-tt.off .dw-tt-thumb { left: 2px; }
.dw-save-btn {
  width: 100%;
  padding: 9px;
  background: #14b8a6;
  color: #fff;
  border: none;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  border-radius: 0;
  margin-top: 10px;
}
.dw-save-btn:hover { background: #0F6E56; }
.dw-save-btn:disabled { background: #b2c8c0; cursor: not-allowed; }

.dw-confirmed {
  text-align: center;
  padding: 14px;
  color: #0F6E56;
  font-size: 13px;
}

/* Summary state */
.dw-summary-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.dw-edit-btn {
  font-size: 11px;
  color: #14b8a6;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
}
.dw-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 0.5px solid #e0e0dc;
}
.dw-summary-row:last-child { border-bottom: none; }
.dw-summary-label { font-size: 11px; color: #666; }
.dw-summary-val { font-size: 13px; font-weight: 500; }
.dw-summary-val.warn { color: #BA7517; }
.dw-summary-val.danger { color: #E24B4A; }

/* =============================================================================
   2. QUICK LOG: WEIGHT (qlw-)
   ============================================================================= */

.qlw-last { font-size: 11px; color: #888; margin-bottom: 10px; }
.qlw-last strong { color: #1a1a18; font-weight: 500; }
.qlw-input {
  width: 100%;
  text-align: center;
  font-size: 28px;
  font-weight: 500;
  padding: 12px;
  border: 0.5px solid #ccc;
  background: transparent;
  font-family: inherit;
  border-radius: 0;
  color: #1a1a18;
}
.qlw-unit-toggle {
  display: flex;
  border: 0.5px solid #ccc;
  margin-top: 8px;
}
.qlw-ut {
  flex: 1;
  padding: 6px;
  font-size: 12px;
  cursor: pointer;
  background: transparent;
  border: none;
  color: #666;
  font-family: inherit;
  border-radius: 0;
}
.qlw-ut.act { background: #f0f0ee; color: #1a1a18; font-weight: 500; }
.qlw-save-btn {
  width: 100%;
  padding: 9px;
  background: #14b8a6;
  color: #fff;
  border: none;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  border-radius: 0;
  margin-top: 10px;
}
.qlw-save-btn:hover { background: #0F6E56; }
.qlw-save-btn:disabled { background: #b2c8c0; cursor: not-allowed; }

/* =============================================================================
   3. QUICK LOG: BLOOD PRESSURE (qlbp-)
   ============================================================================= */

.qlbp-tab-sel {
  display: flex;
  border: 0.5px solid #ccc;
  margin-bottom: 12px;
}
.qlbp-tab {
  flex: 1;
  padding: 6px;
  font-size: 12px;
  cursor: pointer;
  background: transparent;
  border: none;
  color: #666;
  font-family: inherit;
  border-radius: 0;
}
.qlbp-tab.act { background: #f0f0ee; color: #1a1a18; font-weight: 500; }
.qlbp-row {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  margin-bottom: 8px;
}
.qlbp-col { flex: 1; }
.qlbp-label { font-size: 10px; color: #888; margin-bottom: 4px; }
.qlbp-input {
  padding: 10px;
  border: 0.5px solid #ccc;
  font-size: 22px;
  font-weight: 500;
  font-family: inherit;
  text-align: center;
  background: transparent;
  color: #1a1a18;
  width: 100%;
  border-radius: 0;
}
.qlbp-sep {
  font-size: 22px;
  color: #888;
  font-weight: 300;
  align-self: flex-end;
  padding-bottom: 8px;
}
.qlbp-unit {
  font-size: 12px;
  color: #888;
  align-self: flex-end;
  padding-bottom: 8px;
  white-space: nowrap;
}
.qlbp-last { font-size: 10px; color: #888; }
.qlbp-save-btn {
  width: 100%;
  padding: 9px;
  background: #14b8a6;
  color: #fff;
  border: none;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  border-radius: 0;
  margin-top: 10px;
}
.qlbp-save-btn:hover { background: #0F6E56; }
.qlbp-save-btn:disabled { background: #b2c8c0; cursor: not-allowed; }

/* =============================================================================
   4. QUICK LOG: RESTING HR (qlrhr-)
   ============================================================================= */

.qlrhr-last { font-size: 11px; color: #888; margin-bottom: 10px; }
.qlrhr-last strong { color: #1a1a18; font-weight: 500; }
.qlrhr-input {
  width: 100%;
  text-align: center;
  font-size: 28px;
  font-weight: 500;
  padding: 12px;
  border: 0.5px solid #ccc;
  background: transparent;
  font-family: inherit;
  border-radius: 0;
  color: #1a1a18;
}
.qlrhr-unit-label {
  text-align: center;
  font-size: 12px;
  color: #888;
  margin-top: 6px;
}
.qlrhr-save-btn {
  width: 100%;
  padding: 9px;
  background: #14b8a6;
  color: #fff;
  border: none;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  border-radius: 0;
  margin-top: 10px;
}
.qlrhr-save-btn:hover { background: #0F6E56; }
.qlrhr-save-btn:disabled { background: #b2c8c0; cursor: not-allowed; }

/* =============================================================================
   5. ATHLETE CONDITION SUMMARY (acw-)
   ============================================================================= */

.acw-athlete-sel {
  width: 100%;
  padding: 6px 10px;
  border: 0.5px solid #ccc;
  font-size: 12px;
  font-family: inherit;
  background: transparent;
  margin-bottom: 12px;
  border-radius: 0;
  color: #1a1a18;
}
.acw-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 0.5px solid #e0e0dc;
  gap: 8px;
}
.acw-row:last-child { border-bottom: none; }
.acw-label { font-size: 11px; color: #666; flex-shrink: 0; }
.acw-val { font-size: 13px; font-weight: 500; }
.acw-val.warn { color: #BA7517; }
.acw-val.danger { color: #E24B4A; }
.acw-link {
  font-size: 12px;
  color: #14b8a6;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
}
.acw-vbar-mini {
  height: 3px;
  background: #e0e0dc;
  margin-top: 3px;
  width: 70px;
  overflow: hidden;
}
.acw-vfill-good { background: #14b8a6; height: 3px; }
.acw-vfill-warn { background: #EF9F27; height: 3px; }
.acw-vfill-exp  { background: #E24B4A; height: 3px; }
.acw-vmini-meta { font-size: 9px; color: #888; margin-top: 2px; }
.acw-vmini-meta.warn { color: #BA7517; }
.acw-rdns {
  display: inline-flex;
  padding: 2px 6px;
  font-size: 10px;
  font-weight: 500;
}
.acw-r-ready    { background: #E1F5EE; color: #085041; }
.acw-r-normal   { background: #E6F1FB; color: #0C447C; }
.acw-r-caution  { background: #FAEEDA; color: #633806; }
.acw-r-suppress { background: #FCEBEB; color: #791F1F; }
.acw-r-insufficient_data { background: #f0f0ee; color: #888; }
.acw-footer {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.acw-btn-secondary {
  flex: 1;
  padding: 8px;
  background: transparent;
  border: 0.5px solid #aaa;
  font-size: 12px;
  cursor: pointer;
  font-family: inherit;
  border-radius: 0;
  color: #1a1a18;
}
.acw-btn-primary {
  flex: 1;
  padding: 8px;
  background: #0F6E56;
  color: #fff;
  border: none;
  font-size: 12px;
  cursor: pointer;
  font-family: inherit;
  border-radius: 0;
}
.acw-btn-primary.athlete { background: #14b8a6; }
.acw-flag {
  font-size: 11px;
  color: #14b8a6;
  cursor: pointer;
  margin-left: 4px;
}
