/* E3 « Plat à cuisiner » (B_Plat): the header, what to do ahead, the shopping
   list and the owner's actions. */
.dish-header {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-wrap: anywhere;
}

.dish-header__when {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0 var(--space-md);
}

.dish-header__date {
  display: flex;
  align-items: center;
  min-height: var(--target-min);
  font-size: var(--text-button);
  font-weight: 600;
  color: var(--color-blue);
}

.dish-date[open] { flex-basis: 100%; }

.dish-date__toggle {
  display: flex;
  align-items: center;
  min-height: var(--target-min);
  font-size: var(--text-md);
  color: var(--color-muted);
  text-decoration: underline;
  list-style: none;
  cursor: pointer;
}

.dish-date__toggle::-webkit-details-marker,
.dish-cooked > summary::-webkit-details-marker { display: none; }

.dish-header h1 {
  font-size: 2.25rem;
  line-height: 1.05;
}

.dish-header__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-md);
  font-size: var(--text-md);
  color: var(--color-muted);
}

.dish-header__recipe { font-weight: 600; }

.dish-header__note {
  font-size: var(--text-md);
  font-weight: 600;
  color: var(--color-muted);
}

.dish-section {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.dish-section h2,
.verdicts__title { font-size: 1.5rem; }

.prep {
  list-style: none;
  margin: 0 0 0 var(--space-xs);
  padding: 0;
  border-left: 2px solid var(--color-ink);
}

.prep__task {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0 0 var(--space-lg) 18px;
  overflow-wrap: anywhere;
}

.prep__task:last-child { padding-bottom: 0; }

.prep__task::before {
  content: "";
  position: absolute;
  top: 4px;
  left: -7px;
  width: 12px;
  height: 12px;
  background: var(--color-yellow);
  border: 2px solid var(--color-blue);
  border-radius: 50%;
}

.prep__task--next::before { background: var(--color-blue); }

.prep__time {
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-muted);
}

.prep__task--next .prep__time { color: var(--color-blue); }

.prep__text { line-height: 1.4; }

.shopping-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-md);
}

.shopping-heading__left {
  font-size: var(--text-md);
  color: var(--color-muted);
}

.shopping {
  list-style: none;
  margin: 0;
  padding: 0;
  background: var(--color-white);
  border-radius: var(--radius-card);
}

.shopping__item { border-bottom: 1px solid var(--color-line); }

.shopping__item:last-child { border-bottom: 0; }

.shopping__line {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  width: 100%;
  min-height: 48px;
  padding: var(--space-xs) 14px;
  background: transparent;
  border: 0;
  text-align: left;
  overflow-wrap: anywhere;
}

button.shopping__line { cursor: pointer; }

.shopping__box {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border: 2px solid var(--color-muted);
  border-radius: 7px;
}

.shopping__item--done .shopping__box {
  color: var(--color-white);
  background: var(--color-blue);
  border-color: var(--color-blue);
}

.shopping__label { min-width: 0; }

.shopping__item--done .shopping__label {
  color: var(--color-muted);
  text-decoration: line-through;
}

.dish-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--color-ink);
}

.dish-cooked > summary { list-style: none; }

.dish-cooked[open] > summary { display: none; }

.dish-cooked__panel {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  padding: var(--space-lg);
  background: var(--color-white);
  border-radius: var(--radius-card);
}

.verdicts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-sm);
  margin: 0;
  padding: 0;
  border: 0;
}

.verdicts__title {
  margin-bottom: var(--space-md);
  padding: 0;
  font-family: var(--font-title);
  font-size: var(--title-row);
  text-transform: uppercase;
}

.verdicts__choice {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: var(--target-min);
  font-size: var(--text-button);
  border: 1px solid var(--color-ink);
  border-radius: 10px;
  cursor: pointer;
}

.verdicts__choice:has(:checked) {
  color: var(--color-white);
  background: var(--color-ink);
}

.verdicts__choice:has(:focus-visible) {
  outline: 2px solid var(--color-blue);
  outline-offset: 2px;
}

.dish-cooked__word {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  font-size: var(--text-md);
  color: var(--color-muted);
}

.dish-cooked__input {
  min-height: var(--target-min);
  padding: 0 var(--space-md);
  font-size: var(--text-base);
  color: var(--color-ink);
  background: var(--color-yellow);
  border: 1px solid var(--color-ink);
  border-radius: var(--radius-control);
}

.dish-remove { color: var(--color-danger); }

/* The date form sits on the yellow page, like the other fields. */
.dish-date .stack { margin-top: var(--space-sm); }
