/* The Pointe School of Dance: the classes page. The age line and the roll of classes. Order: layout, type, colour, motion. Desk first. */

/* ================= LAYOUT ================= */

.hall { padding: 0.75rem var(--tda-edge) var(--tda-edge); }
.studio .scene:first-child { padding-top: 0.75rem; }

/* The photograph stays pinned under the header for the whole length of the split. */
@media (min-width: 48.0625rem) {
  .doorway > .hall-held { position: sticky; top: var(--tda-lintel); align-self: start; }
}

/* The age line: one row of tiles, scrolling sideways inside its own box. The kind line is a quiet
   inline row of underlined links, two rows at most, so it reads as a line of text and not a wall of boxes. */
.agetape { position: relative; display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.3rem; scrollbar-width: thin; }
.kindtape { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 1.35rem; padding-inline: 0; }
.agemark { position: relative; flex: none; width: 5rem; aspect-ratio: 16 / 9; padding: 0; }
.kindmark { flex: none; max-width: 100%; }

/* The roll: a ruled index. Every year-round row shares one tile width and one title size; the picked
   row is the only one that grows, and the price sits at title size in the right-hand column. */
.rollcall { display: flex; flex-direction: column; gap: 0; border-bottom: var(--tda-tread) solid; }
.turn-link { display: grid; gap: 0.3rem 1.25rem; padding: 1.4rem 0; border-top: var(--tda-tread) solid; }
.turn-large .turn-link { grid-template-columns: 9rem 1fr; align-items: start; }
.turn-short .turn-link { grid-template-columns: 1fr auto; gap: 0.35rem 1rem; align-items: start; }
.turn-ages { display: flex; align-items: center; justify-content: center; width: 9rem; aspect-ratio: 16 / 9; padding: 0 0.4rem; }
.turn-body { min-width: 0; }
.turn-body > * + * { margin-top: 0.35rem; }
.turn-other { display: inline-block; padding: 0.1rem 0.6rem; border: var(--tda-tread) solid; }
.turn-price { justify-self: end; }

.bow-lead > * + * { margin-top: var(--tda-beat); }
.bow-way { flex-wrap: wrap; }
.bow-address { min-width: 0; overflow-wrap: anywhere; }

@media (max-width: 48rem) {
  .hall { padding-bottom: 0; }
  .studio .scene:first-child { padding-top: 1.5rem; }
  .turn-large .turn-link { grid-template-columns: 6rem 1fr; gap: 0.3rem 1rem; padding: 1.1rem 0; }
  .turn-ages { width: 6rem; }
  .turn-short .turn-link { grid-template-columns: 1fr; }
  .turn-price { justify-self: start; }
}

/* ================= TYPE ================= */

.agemark { font-family: var(--tda-voice); font-weight: 650; font-size: 1.375rem; line-height: 1; }
.kindmark {
  font-family: var(--tda-counting);
  font-size: 0.9375rem;
  line-height: 1.3;
  min-height: 2.75rem;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 0.0625rem;
  text-underline-offset: 0.22em;
  cursor: pointer;
}
.kindmark:hover { text-decoration-thickness: 0.125rem; }
.kindmark[aria-pressed="true"] { text-decoration-thickness: 0.125rem; text-decoration-color: var(--tda-blue); }
.tally { font-size: 0.9375rem; line-height: 1.5; }

.turn-link { text-decoration: none; }
.turn-name { font-family: var(--tda-voice); font-weight: 650; line-height: 1.1; }
.turn-large .turn-name, .turn-short .turn-name { font-size: clamp(1.75rem, 2.6vw, 2.25rem); }
.turn-lifted .turn-name { font-size: clamp(2.25rem, 3.4vw, 2.875rem); line-height: 1.05; }
.turn-ages { font-family: var(--tda-voice); font-weight: 650; font-size: 1.25rem; line-height: 1; text-align: center; }
.turn-price {
  font-family: var(--tda-voice);
  font-weight: 650;
  font-size: clamp(1.75rem, 2.6vw, 2.25rem);
  line-height: 1.12;
  text-align: right;
}
.turn-price-line { display: block; white-space: nowrap; }
.turn-meta, .turn-other { font-size: 0.9375rem; line-height: 1.4; }
.turn-line { line-height: 1.55; }

.bow-address { font-family: var(--tda-counting); font-weight: 400; font-size: 0.9375rem; line-height: 1.4; }

@media (max-width: 48rem) {
  .turn-price { text-align: left; font-size: 1.625rem; }
  .turn-large .turn-name, .turn-short .turn-name, .turn-lifted .turn-name { font-size: 1.625rem; line-height: 1.12; }
  .turn-ages { font-size: 1rem; }
}

/* ================= COLOUR ================= */

.hall-held { background: var(--tda-straw); }

.rollcall { border-color: var(--tda-bark); }
.turn-link { background: var(--tda-straw); color: var(--tda-bark); border-color: var(--tda-bark); }
.turn-link:hover { border-color: var(--tda-blue); }
.turn-link:hover .turn-name { text-decoration: underline; text-decoration-color: var(--tda-blue); text-decoration-thickness: 0.125rem; text-underline-offset: 0.22em; }
.turn-ages { background: var(--tda-bark); color: var(--tda-straw); }
.turn-other { border-color: var(--tda-bark); }
.turn-lifted .turn-link { border-color: var(--tda-blue); }
.turn-lifted .turn-ages { background: var(--tda-blue); }
.kindmark[aria-pressed="true"] { color: var(--tda-blue); }

.bow-address { color: inherit; }

/* ================= MOTION ================= */

.turn { transition: transform 200ms ease-out; }
.turn-link, .turn-ages { transition: border-color 150ms linear, background-color 150ms linear, color 150ms linear; }
.kindmark { transition: color 150ms linear, text-decoration-color 150ms linear; }
