/* EXERCISE PRACTICE SESSIONS — practice/exercise-session.js
   The button block under an ARENA exercise heading and the setup dialog.
   Notebook typography is arena-notebook.css's; nothing here restyles a
   `.nbv-*` node. The live clock that replaces the buttons while an attempt is
   timed is practice/exercise-timer.js's, styled in exercise-timer.css. */

/* ── on the notebook page ────────────────────────────────────────── */
.dd-ex-block {
  margin: 10px 0 22px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  background: var(--panel);
  font-size: 14px;
}

/* TWO BUTTONS, THE SAME WEIGHT. Seth, 2026-09-11: "give equal importance to
   the drill or start problem option". Neither is `.primary`, neither is
   `.ghost`; they are two boxes of one size side by side, the way he drew them
   — so the choice reads as a choice and not as an action with an escape
   hatch. Hidden by exercise-timer.css while the block is `is-live`. */
.dd-ex-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
/* The same box for the live row's two buttons (`.dd-ex-live`, written by
   exercise-timer.js): one rule, so the clock's controls cannot drift from the
   buttons they replace. exercise-timer.css adds only what is its own. */
.dd-ex-row > button,
.dd-ex-live > button {
  min-height: 60px;
  padding: 12px 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
  cursor: pointer;
  text-align: center;
}
.dd-ex-row > button:hover:not(:disabled),
.dd-ex-row > button:focus-visible,
.dd-ex-live > button:hover,
.dd-ex-live > button:focus-visible {
  border-color: var(--accent-text);
  color: var(--accent-text);
}
.dd-ex-row > button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
@media (max-width: 620px) {
  .dd-ex-row {
    grid-template-columns: 1fr;
  }
}

/* ── the dialog ──────────────────────────────────────────────────── */
.dd-ex-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgb(0 0 0 / 0.55);
}
.dd-ex-modal.hidden {
  display: none;
}
.dd-ex-card {
  width: min(520px, 100%);
  max-height: 92vh;
  overflow: auto;
  background: var(--panel);
  color: inherit;
  border-radius: 12px;
  padding: 20px 22px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.35);
}
.dd-ex-title {
  margin: 0 0 4px;
  font-size: 20px;
}
.dd-ex-sub {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
}
.dd-ex-field {
  border: 0;
  margin: 0 0 12px;
  padding: 0;
}
.dd-ex-field legend,
.dd-ex-count label {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 6px;
  display: block;
}
.dd-ex-opts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.dd-ex-opt {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 12px;
  cursor: pointer;
  font-size: 13px;
  user-select: none;
}
.dd-ex-opt input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.dd-ex-opt.is-on {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}
.dd-ex-count input {
  width: 72px;
  margin-left: 8px;
  font-size: 15px;
  padding: 4px 6px;
}
.dd-ex-hint {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}
/* Practice until ready (2026-09-23): what the block will do, in order. */
.dd-ex-steps {
  margin: 0;
  padding-left: 20px;
  font-size: 14px;
  line-height: 1.5;
}
.dd-ex-steps li + li {
  margin-top: 2px;
}
.dd-ex-max {
  margin: 10px 0 6px;
  font-weight: 600;
  font-size: 14px;
}
.dd-ex-error {
  margin: 6px 0;
  color: var(--accent-text);
  font-size: 13px;
}
.dd-ex-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.dd-ex-resume-text {
  margin: 0 0 8px;
  font-size: 14px;
}
.dd-ex-back {
  margin-left: 6px;
}

/* ── the practice page during a scoped block ─────────────────────── */
/* The idle clock line is irrelevant while a block that brought its own
   numbers is on screen; the session row already says the phase and the clock. */
#page-practice.dd-exercise-session:not(.session-idle) #session-clock-note {
  display: none;
}
