/* ==============================================================
   FIVE SENSES WALK · page styles
   File: /five-senses-walk/five-senses-walk.css
   Colours, font and buttons come from site.css.
   The "How it helps" section uses shared styles (site.css, section 13).

   Sections:
     1  Meadow colours (used by the drawing)
     2  Layout and intro
     3  The meadow and its flowers
     4  The walk panel
   ============================================================== */


/* --------------------------------------------------------------
   1 · MEADOW COLOURS
   -------------------------------------------------------------- */
:root {
  --meadow-top: #CFE0C4;
  --meadow-bottom: #A9C79A;
  --meadow-grass: #7FA36F;
  --meadow-path: #EADCC0;
  --meadow-path-edge: #D6C4A2;
  --meadow-stone: #C9C3B6;
  --walker: #3B6B74;
}
@media (prefers-color-scheme: dark) {
  :root {
    --meadow-top: #2E3F33;
    --meadow-bottom: #243328;
    --meadow-grass: #3F5A43;
    --meadow-path: #6B6150;
    --meadow-path-edge: #574F41;
    --meadow-stone: #5A5A52;
    --walker: #9CC7CC;
  }
}


/* --------------------------------------------------------------
   2 · LAYOUT AND INTRO
   -------------------------------------------------------------- */
.walk {
  padding-block: clamp(1.5rem, 5vw, 3rem) clamp(3rem, 8vw, 5rem);
  background: linear-gradient(var(--c-sky-top), color-mix(in srgb, var(--meadow-top) 35%, var(--bg)));
}
.walk__intro { max-width: 44rem; margin-bottom: clamp(1.25rem, 3vw, 2rem); }
.walk__title {
  margin-bottom: .35em;
  font-size: clamp(2.4rem, 1.6rem + 3vw, 4rem);
  font-weight: var(--weight-light);
  letter-spacing: -.025em;
}
.walk__lede {
  font-size: var(--step-1);
  font-weight: var(--weight-light);
  line-height: 1.45;
}


/* --------------------------------------------------------------
   3 · THE MEADOW AND ITS FLOWERS
   -------------------------------------------------------------- */
.meadow {
  position: relative;
  aspect-ratio: 16 / 6.5;
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: linear-gradient(var(--meadow-top), var(--meadow-bottom));
}
@media (max-width: 700px) {
  .meadow { aspect-ratio: 4 / 3.3; }
}
.meadow svg { display: block; width: 100%; height: 100%; }

.meadow .grass  { stroke: var(--meadow-grass); stroke-width: 1.6; stroke-linecap: round; fill: none; opacity: .75; }
.meadow .stone  { fill: var(--meadow-stone); }
.meadow .path-edge { stroke: var(--meadow-path-edge); fill: none; stroke-linecap: round; }
.meadow .path   { stroke: var(--meadow-path); fill: none; stroke-linecap: round; }
.meadow .stem   { stroke: #5E8A4F; stroke-linecap: round; fill: none; }

/* The walker: a small glowing marker for "you" */
.meadow .walker-glow { fill: var(--walker); opacity: .22; }
.meadow .walker      { fill: var(--walker); stroke: var(--c-paper); stroke-width: 2; }

/* A flower grows up from the ground when planted */
.meadow .flower {
  transform-box: fill-box;
  transform-origin: 50% 100%;
}
.meadow .flower.is-new { animation: grow .9s cubic-bezier(.34, 1.4, .64, 1) both; }
@keyframes grow {
  from { transform: scale(0); opacity: 0; }
  40%  { opacity: 1; }
  to   { transform: scale(1); }
}
.meadow .flower.is-leaving { animation: wilt .6s ease-in both; }
@keyframes wilt {
  to { transform: scale(0); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .meadow .flower.is-new { animation: fade-in .4s ease both; }
  .meadow .flower.is-leaving { animation: none; opacity: 0; }
  @keyframes fade-in { from { opacity: 0; } }
}


/* --------------------------------------------------------------
   4 · THE WALK PANEL
   -------------------------------------------------------------- */
.walk-panel {
  position: relative;
  max-width: 40rem;
  margin: 1.25rem auto 0;
  padding: clamp(1.25rem, 4vw, 2rem);
  background: var(--surface);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow);
}

.walk-step__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: .25rem 1rem;
  margin-bottom: 1rem;
}
.walk-step__sense {
  font-size: var(--step-1);
  font-weight: var(--weight-regular);
}
.walk-step__count {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.walk-step__ask {
  display: block;
  margin-bottom: .5rem;
  font-size: var(--step-1);
  font-weight: var(--weight-light);
}
.walk-input {
  display: block;
  width: 100%;
  padding: .8rem 1rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-s);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 1.1rem;
}
.walk-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent);
}
.walk-hint {
  margin-top: .5rem;
  font-size: var(--step--1);
  color: var(--muted);
}
.walk-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  margin-top: 1.25rem;
}

.walk-pause {
  display: grid;
  place-items: center;
  min-height: 12rem;
  text-align: center;
}
.walk-pause__text {
  font-size: var(--step-2);
  font-weight: var(--weight-light);
  animation: breathe-text 2.6s ease-in-out both;
}
@keyframes breathe-text {
  0% { opacity: 0; letter-spacing: 0; }
  50% { opacity: 1; letter-spacing: .02em; }
  100% { opacity: .8; letter-spacing: 0; }
}

.walk-done__title {
  margin-bottom: .6rem;
  font-size: var(--step-2);
  font-weight: var(--weight-light);
}
.walk-done__title:focus { outline: none; }
.walk-done > p { color: var(--muted); }

.walk-summary {
  display: grid;
  gap: .75rem;
  margin-top: 1.25rem;
}
.walk-summary h3 {
  font-size: .95rem;
  font-weight: var(--weight-strong);
  margin-bottom: .2rem;
}
.walk-summary p { color: var(--muted); font-size: 1rem; }

/* What you've noticed, as small tags */
.walk-words {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem;
  margin: 1.25rem 0 0;
  padding: 0;
  list-style: none;
}
.walk-words:empty { display: none; }
.walk-words li {
  padding: .2rem .7rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--meadow-bottom) 35%, transparent);
  font-size: .85rem;
}

.walk-toggles {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}
.walk-status {
  min-height: 1.65em;
  margin-top: 1rem;
  color: var(--muted);
}

@media (max-width: 480px) {
  .walk-actions .btn--primary { flex: 1 1 100%; }
}
