/* =========================================================
   Reset-3-2-1 — day pages
   Shared by day-1.html, day-2.html and day-3.html.
   Depends on reset-3-2-1.css for tokens, header, footer,
   buttons and the safety note.
   ========================================================= */

/* ---------- Active day in the header ---------- */

.day-nav__link--active,
.day-nav__link--active:hover {
  background-color: var(--secondary);
  color: var(--foreground);
}

.day-nav__link--active .day-nav__dot {
  background-color: var(--primary);
}

/* ---------- Day hero ---------- */

.day-hero {
  display: grid;
  gap: 32px;
  align-items: center;
  padding-top: 40px;
}

.day-hero__kicker {
  color: var(--primary);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.day-hero h1 {
  margin-top: 12px;
  font-size: 48px;
  line-height: 1.05;
}

.day-hero__subtitle {
  margin-top: 8px;
  color: var(--muted-foreground);
  font-family: var(--font-display);
  font-size: 20px;
}

.day-hero__intro {
  max-width: 640px;
  margin-top: 24px;
  color: rgba(12, 43, 25, 0.8);
  line-height: 1.6;
}

.day-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 24px;
  color: var(--muted-foreground);
  font-size: 14px;
}

.day-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.day-meta svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.day-note {
  margin-top: 16px;
  color: var(--muted-foreground);
  font-size: 13px;
}

.day-hero__image {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 1px 2px rgba(12, 43, 25, 0.08);
}

/* ---------- Exercise cards ---------- */

.exercise-list {
  display: grid;
  gap: 24px;
  margin-top: 56px;
}

.exercise-card {
  display: grid;
  gap: 24px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-panel);
  background-color: var(--card);
  transition: border-color 0.25s ease, background-color 0.25s ease;
}

.exercise-card:has(.done-toggle input:checked) {
  border-color: rgba(67, 148, 88, 0.55);
  background-color: #f4fbf4;
}

.exercise-card__main {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.exercise-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.exercise-card__number {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--secondary);
  color: var(--secondary-foreground);
  font-family: var(--font-display);
  font-size: 18px;
}

.exercise-card h2 {
  font-size: 24px;
  line-height: 1.25;
}

.exercise-card__time {
  margin-top: 2px;
  color: var(--muted-foreground);
  font-size: 14px;
}

.exercise-card__why {
  color: rgba(12, 43, 25, 0.8);
  font-size: 14px;
  line-height: 1.55;
}

.exercise-card__why strong {
  font-weight: 600;
}

.exercise-card__steps {
  display: grid;
  gap: 8px;
  font-size: 14px;
  line-height: 1.5;
}

.exercise-card__steps li {
  display: flex;
  gap: 8px;
}

.exercise-card__steps li > span {
  flex-shrink: 0;
  color: var(--primary);
  font-weight: 600;
}

/* ---------- Mark as done ---------- */

.done-toggle {
  position: relative;
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  background-color: var(--primary);
  color: var(--primary-foreground);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.done-toggle svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.done-toggle input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.done-toggle:has(input:focus-visible) {
  box-shadow: var(--ring-shadow);
}

.done-toggle:has(input:checked) {
  background-color: var(--secondary);
  color: var(--secondary-foreground);
}

.done-toggle__on {
  display: none;
}

.done-toggle:has(input:checked) .done-toggle__off {
  display: none;
}

.done-toggle:has(input:checked) .done-toggle__on {
  display: inline;
}

/* ---------- Practice panel ---------- */

.exercise-card__practice {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  min-width: 0;
  padding: 16px;
  border-radius: 16px;
  background-color: var(--background);
}

.practice__hint {
  color: var(--muted-foreground);
  font-size: 13px;
  line-height: 1.5;
}

.practice__label {
  font-size: 14px;
  font-weight: 500;
}

/* Form fields */

.practice-field {
  display: grid;
  gap: 6px;
  font-size: 14px;
}

.practice-field > span {
  font-weight: 500;
}

.practice-field input,
.practice-field textarea,
.practice-field select {
  width: 100%;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background-color: var(--card);
  color: var(--foreground);
  font-family: inherit;
  font-size: 14px;
  line-height: 1.4;
}

.practice-field textarea {
  min-height: 96px;
  resize: vertical;
}

.practice-field input:focus-visible,
.practice-field textarea:focus-visible,
.practice-field select:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 1px;
}

.practice-field input[type="time"] {
  max-width: 160px;
}

/* Checkboxes */

.sense-list {
  display: grid;
  gap: 8px;
  font-size: 14px;
}

.sense-list label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.sense-list input {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  accent-color: var(--primary);
}

.sense-list__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  border-radius: 50%;
  background-color: var(--secondary);
  color: var(--secondary-foreground);
  font-family: var(--font-display);
  font-size: 14px;
}

/* Chip groups (radio / checkbox pills) */

.chip-group {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.chip-group legend {
  padding: 0;
  font-size: 14px;
  font-weight: 500;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  position: relative;
  display: inline-flex;
}

.chip input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.chip span {
  display: inline-block;
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background-color: var(--card);
  font-size: 13px;
  line-height: 1.4;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.chip input:checked + span {
  border-color: var(--ring);
  background-color: var(--secondary);
  color: var(--secondary-foreground);
}

.chip input:focus-visible + span {
  box-shadow: var(--ring-shadow);
}

/* Pattern puzzles */

.puzzle {
  border: 1px solid var(--border);
  border-radius: 10px;
  background-color: var(--card);
}

.puzzle summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.puzzle summary::-webkit-details-marker {
  display: none;
}

.puzzle summary::after {
  content: "Reveal";
  color: var(--primary);
  font-size: 12px;
  font-weight: 500;
}

.puzzle[open] summary::after {
  content: "Answer";
}

.puzzle p {
  padding: 0 14px 12px;
  color: var(--muted-foreground);
  font-size: 13px;
  line-height: 1.5;
}

/* Breathing pacer */

.breath-pacer {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 8px 0;
}

.breath-pacer__ring {
  display: grid;
  place-items: center;
  width: 180px;
  height: 180px;
  border: 2px dashed rgba(19, 119, 56, 0.25);
  border-radius: 50%;
}

.breath-pacer__circle {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background-color: var(--secondary);
  animation: breathe 16s ease-in-out infinite;
}

@keyframes breathe {
  0%,
  100% {
    transform: scale(0.62);
  }

  25%,
  50% {
    transform: scale(1);
  }

  75% {
    transform: scale(0.62);
  }
}

/* ---------- Suggestions ---------- */

.suggestions {
  margin-top: 64px;
}

.suggestions h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 30px;
}

.suggestions h2 svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--terracotta);
}

.suggestions > p {
  margin-top: 8px;
  color: var(--muted-foreground);
}

.suggestion-grid {
  display: grid;
  gap: 16px;
  margin-top: 24px;
}

.suggestion {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background-color: var(--card);
}

.suggestion h3 {
  font-size: 18px;
}

.suggestion p {
  margin-top: 4px;
  color: var(--muted-foreground);
  font-size: 14px;
  line-height: 1.5;
}

/* ---------- Closing ---------- */

.day-closing {
  margin-top: 64px;
}

.day-closing__panel {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 32px;
  border-radius: var(--radius-panel);
  background-color: rgba(212, 241, 212, 0.6);
}

.day-closing h2 {
  font-size: 24px;
}

.day-closing p {
  max-width: 640px;
  margin-top: 8px;
  color: var(--muted-foreground);
}

.day-closing__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.day-closing .safety-note {
  margin-top: 24px;
}

/* Small call-to-action buttons */

.button--small {
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  background-color: var(--primary);
  color: var(--primary-foreground);
  font-size: 14px;
}

.button--small:hover {
  background-color: var(--primary-hover);
}

.button--small svg {
  width: 16px;
  height: 16px;
}

.button--secondary {
  background-color: var(--secondary);
  color: var(--secondary-foreground);
}

.button--secondary:hover {
  background-color: #c6eac6;
}

/* ---------- Responsive ---------- */

@media (min-width: 640px) {
  .suggestion-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .day-hero {
    grid-template-columns: 1.1fr 1fr;
    padding-top: 64px;
  }

  .day-hero h1 {
    font-size: 60px;
  }

  .exercise-card {
    grid-template-columns: 1fr 1.4fr;
    padding: 32px;
  }

  .exercise-card__practice {
    padding: 24px;
  }

  .day-closing__panel {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 40px;
  }

  .day-closing h2 {
    font-size: 30px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .breath-pacer__circle {
    animation: none;
    transform: scale(0.8);
  }
}
