/* Gym-friendly: big text, big tap targets, dark background. */
body {
  font-family: system-ui, sans-serif;
  font-size: 18px;
  background: #111;
  color: #eee;
  margin: 0 auto;
  padding: 16px 16px 96px; /* extra bottom space so the "Powered by Netlify" badge never hides the last card */
  max-width: 480px;
}

form, section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

[hidden] {
  display: none;
}

input, button {
  font-size: 18px;
  min-height: 56px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid #444;
  background: #1c1c1c;
  color: #eee;
}

button {
  background: #2e7d32;
  border: none;
  font-weight: bold;
}

button.secondary {
  background: #333;
}

.error {
  color: #ff6b6b;
}

/* Today's workout */
h2 { margin: 0; font-size: 22px; }
h3 { margin: 0 0 6px; font-size: 20px; }
p { margin: 4px 0; }
.muted { color: #999; font-size: 15px; }
.block { background: #1c1c1c; border-radius: 12px; padding: 12px; }
.badge { color: #66bb6a; font-weight: bold; }
.card { background: #1c1c1c; border: 1px solid #333; border-radius: 12px; padding: 14px; margin: 10px 0; }
.load { font-size: 20px; font-weight: bold; color: #fff; }
details { margin: 12px 0; }
summary { min-height: 48px; line-height: 48px; cursor: pointer; }

/* Start workout + save status */
button.start { width: 100%; min-height: 72px; font-size: 22px; margin: 8px 0; }
button:disabled { opacity: 0.6; }
.sync { font-size: 15px; }
.sync.ok { color: #66bb6a; }
.sync.waiting { color: #ffb74d; }

/* Logging a set */
.log-area { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.stepper { display: flex; align-items: center; gap: 8px; }
.stepper .value { flex: 1; text-align: center; font-size: 24px; font-weight: bold; }
button.step { width: 72px; min-height: 64px; font-size: 32px; background: #333; }
.logged { color: #66bb6a; margin: 0; }

/* Rest timer: stays at the top of the screen while scrolling */
.rest { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 8px;
        background: #1b5e20; padding: 10px 12px; border-radius: 12px; }
.rest[hidden] { display: none; }
.rest.over { background: #b71c1c; }
#rest-clock { flex: 1; font-size: 40px; font-weight: bold; font-variant-numeric: tabular-nums; }
.rest button { min-height: 56px; min-width: 64px; padding: 0 10px; }

/* Week screen */
.day-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 64px; margin: 6px 0;
           text-align: left; background: #1c1c1c; border: 1px solid #333; font-weight: normal; }
.day-row .when { width: 64px; color: #999; font-size: 15px; flex-shrink: 0; }
.day-row .what { flex: 1; font-weight: bold; }
.day-row .status { color: #66bb6a; font-size: 15px; flex-shrink: 0; }
.day-row.today { border: 2px solid #66bb6a; }
.day-row.today .when { color: #66bb6a; font-weight: bold; }
.day-row.past { opacity: 0.5; }
button.back { align-self: flex-start; min-height: 48px; background: none; border: none; color: #66bb6a; padding: 0; }

/* "Workout finished" → opens the log */
button.done { width: 100%; min-height: 56px; margin: 8px 0; text-align: left; background: #1b3a1d;
              border: 1px solid #66bb6a; color: #66bb6a; }

/* Editing a logged set */
button.logged { display: block; width: 100%; background: none; border: none; color: #66bb6a; text-align: left; min-height: 44px; padding: 0; font-weight: normal; }
.edit-panel { display: flex; flex-direction: column; gap: 8px; padding: 12px; border: 1px solid #555; border-radius: 12px; }
button.danger { background: #7f1d1d; }
