/* Training take 1, "Who's in the room". Class prefix t1-. */

/* ---------- 1 · Hero ---------- */
/* Sam, 17 Nov: the three ways as cards in the hero. The h1 drops to the statement size so the cards sit in the first
   screen at 1440; each card is photo, marks, name and one line, and the whole card is the link (it jumps to its step in
   the room below). The key under the cards names the dots, so none is left to guess. */
.t1-hero { min-height: 100svh; display: flex; padding: calc(var(--tcc-clear) + var(--tcc-space-m)) 0 var(--tcc-space-l); }
.t1-hero__in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, auto); align-content: end; gap: var(--tcc-space-m) var(--tcc-gutter); }
.t1-hero__h1 { align-self: end; font-size: var(--t-statement); line-height: .95; letter-spacing: -.04em; }
.t1-hero__lede { align-self: end; max-width: 34ch; font-size: var(--t-lede); line-height: 1.5; color: var(--c-body); }
.t1-cards { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(12px, 1.3vw, 20px); margin-top: var(--tcc-space-xs); }
.t1-cards > li { display: flex; }
.t1-card { --disc: var(--tcc-brand); position: relative; flex: 1; display: grid; grid-template-rows: auto 1fr; border-radius: var(--tcc-radius-card); overflow: clip;
  background: var(--tcc-surface); box-shadow: inset 0 0 0 1px var(--tcc-border); color: inherit; text-decoration: none;
  transition: box-shadow var(--ui-t) var(--tcc-easing-soft), transform .16s var(--tcc-easing-soft); }
.t1-card__media { display: block; aspect-ratio: 3 / 2; overflow: clip; background: #15181a; }
.t1-card__media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--tcc-easing-arrive); }
/* App: the real app screen in a phone frame, rising out of the bottom edge (no photo shows the app itself) */
.t1-card__media--app { position: relative;
  background: radial-gradient(60% 80% at 50% 100%, rgba(54,174,203,.16), transparent 70%), #15181a; }
/* the phone is taken out of flow so the box keeps its 3:2 (in flow, the tall image stretched the box and hid the text) */
.t1-card__media--app img { position: absolute; left: 50%; top: 9%; translate: -50% 0; width: 34%; height: auto; border-radius: 18px;
  box-shadow: 0 0 0 5px #0b0d0e, 0 0 0 6.5px var(--tcc-brand), 0 30px 70px -24px rgba(54,174,203,.45); }
.t1-card__body { display: grid; align-content: start; gap: 8px; padding: 18px 72px 22px 20px; }
.t1-card .tr-marks { --d: 9px; height: calc(var(--d) * 1.85); margin-bottom: 4px; }   /* fixed: the phone mark is taller than a dot, so the App name sat 8px low */
.t1-card__name { font: 500 var(--t-h3)/1.1 var(--tcc-font-heading); color: var(--c-heading); letter-spacing: -.015em; }
.t1-card__line { font-size: var(--t-meta); line-height: 1.45; color: var(--c-body); max-width: 32ch; }
.t1-card__go { --d: 40px; position: absolute; right: 18px; bottom: 18px; color: var(--tcc-brand); box-shadow: inset 0 0 0 1.5px var(--tcc-brand); }
@media (hover: hover) and (pointer: fine) {
  .t1-card:hover { box-shadow: inset 0 0 0 1px var(--c-accent); }
  .t1-card:hover .t1-card__media img { transform: scale(1.04); }
  .t1-card:hover .t1-card__media--app img { transform: translateY(-4px); }
  .t1-card:hover .btn__ic::before { transform: scale(1); }
  .t1-card:hover .btn__ic > span { transform: translate3d(0,0,0); }
  .t1-card:hover .t1-card__go { color: var(--tcc-ink); }
}
.t1-card:focus-visible .btn__ic::before, .t1-card:active .btn__ic::before { transform: scale(1); }
.t1-card:focus-visible .btn__ic > span, .t1-card:active .btn__ic > span { transform: translate3d(0,0,0); }
.t1-card:focus-visible .t1-card__go, .t1-card:active .t1-card__go { color: var(--tcc-ink); }
.t1-card:active { transform: scale(.985); }
.t1-hero__key { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: var(--t-meta); color: var(--c-meta); }
.t1-hero__key span { display: inline-flex; align-items: center; gap: 8px; }
.t1-hero__key i { width: 9px; height: 9px; border-radius: 50%; background: var(--tcc-brand); }
.t1-hero__key i.k-co { background: #b9bcbd; }
.t1-hero__key i.k-ph { width: 9px; height: 14px; border-radius: 3px; background: none; box-shadow: inset 0 0 0 2px var(--tcc-brand); }
/* tablet: the lede goes under the h1; the cards stay three across */
@media (max-width: 1023px) {
  .t1-hero__in { grid-template-columns: 1fr; }
  .t1-card__body { padding: 16px 60px 18px 16px; }
  .t1-card__go { --d: 36px; right: 14px; bottom: 14px; }
}
/* below 900 (three columns broke the names onto two lines at 768): each card is a row, photo on the left */
@media (max-width: 899px) {
  .t1-cards { grid-template-columns: 1fr; gap: 10px; }
  .t1-card { grid-template-rows: none; grid-template-columns: clamp(108px, 22vw, 180px) minmax(0, 1fr); }
  .t1-card__media { aspect-ratio: auto; height: 100%; min-height: 118px; }
  .t1-card__media--app img { top: 14px; }
  .t1-card__media--app img { width: 52%; border-radius: 9px; box-shadow: 0 0 0 3px #0b0d0e, 0 0 0 4px var(--tcc-brand); }
  .t1-card__body { align-content: center; gap: 4px; padding: 14px 54px 14px 16px; }
  .t1-card .tr-marks { --d: 8px; margin-bottom: 2px; }
  .t1-card__name { font-size: 1.25rem; }
  .t1-card__line { font-size: 14px; }
  .t1-card__go { --d: 34px; right: 12px; bottom: auto; top: 50%; translate: 0 -50%; }
}
@media (max-width: 767px) { .t1-hero { padding-top: calc(var(--tcc-clear) + var(--tcc-space-s)); } }

/* ---------- 2 · The room ---------- */
/* pass 2: the marks grow to about the name's height at 1440 (92px) and to 40px on the phone, where the row had room */
.t1-stage { --dot: clamp(40px, 6.4vw, calc(92px + var(--tcc-up) * .06)); position: relative; background: var(--tcc-ground); }
.t1-pin__in { position: relative; }
.t1-room { display: flex; align-items: center; gap: calc(var(--dot) * .5); height: calc(var(--dot) * 1.9); }
.t1-dot { flex: none; position: relative; width: var(--dot); height: var(--dot); border-radius: 50%; background: var(--tcc-brand);
  transition: transform .7s var(--tcc-easing-move), opacity .45s var(--tcc-easing-soft); }
.t1-dot--co { background: #b9bcbd; margin-right: calc(var(--dot) * .5); }
/* dot 1 is a phone-sized box clipped to a circle: the App step opens the clip into the phone and fades the fill, so the
   fold is transform, opacity and clip-path only (polish standard A5) */
.t1-dot--1 { width: calc(var(--dot) * 1.05); height: calc(var(--dot) * 1.75); border-radius: calc(var(--dot) * .24); background: transparent;
  box-shadow: inset 0 0 0 calc(var(--dot) * .14) var(--tcc-brand);
  clip-path: inset(calc(var(--dot) * .375) calc(var(--dot) * .025) round calc(var(--dot) * .5)); transition: clip-path .75s var(--tcc-easing-move); }
.t1-dot--1::before { content: ''; position: absolute; inset: 0; border-radius: inherit; background: var(--tcc-brand); transition: opacity .35s var(--tcc-easing-soft); }
.t1-stage[data-step="2"] .t1-dot--1 { clip-path: inset(0 0 round calc(var(--dot) * .24)); transition-delay: .18s; }
.t1-stage[data-step="2"] .t1-dot--1::before { opacity: 0; transition: opacity .5s var(--tcc-easing-soft) .35s; }
.t1-key { display: flex; gap: 22px; margin-top: 10px; font-size: var(--t-meta); color: var(--c-meta); }
.t1-key span { display: inline-flex; align-items: center; gap: 8px; }
.t1-key i { width: 9px; height: 9px; border-radius: 50%; background: var(--tcc-brand); }
.t1-key i.k-co { background: #b9bcbd; }

/* step states: 0 = one person, 1 = four, 2 = a phone. Joining (1): the three arrive left to right. Leaving for the app (2):
   they slide into the phone right to left as it opens. Back to one (0): they leave in place. */
.t1-stage[data-step="0"] .t1-dot--p:not(.t1-dot--1) { transform: scale(0); opacity: 0; }
.t1-stage[data-step="2"] .t1-dot--2 { transform: translateX(calc(var(--dot) * -1.55)) scale(.2); opacity: 0; transition-delay: .12s; }
.t1-stage[data-step="2"] .t1-dot--3 { transform: translateX(calc(var(--dot) * -3.05)) scale(.2); opacity: 0; transition-delay: .06s; }
.t1-stage[data-step="2"] .t1-dot--4 { transform: translateX(calc(var(--dot) * -4.55)) scale(.2); opacity: 0; }
.t1-stage[data-step="1"] .t1-dot--2 { transition-delay: .05s; } .t1-stage[data-step="1"] .t1-dot--3 { transition-delay: .12s; } .t1-stage[data-step="1"] .t1-dot--4 { transition-delay: .19s; }

.t1-steps { display: grid; gap: var(--tcc-space-2xl); margin-top: var(--tcc-space-l); }
.t1-step { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: var(--tcc-gutter); align-items: center; }
.t1-step__txt { display: grid; gap: 18px; align-content: start; justify-items: start; }
.t1-step__marks { --d: 10px; }
/* the mode name is the page's statement role (one display-scale line inside the page; only one shows at a time) */
.t1-step__name { font-size: var(--t-statement); line-height: .95; letter-spacing: -.04em; }
.t1-step__line { font-size: var(--t-lede); line-height: 1.5; max-width: 34ch; color: var(--c-body); }
.t1-step__facts { display: grid; gap: 8px; color: var(--c-meta); font-size: var(--t-meta); margin-bottom: 8px; }
.t1-step__facts li { position: relative; padding-left: 26px; }   /* not flex: a flex li spaced out each split-hyphen span */
.t1-step__facts li::before { content: ''; position: absolute; left: 0; top: .72em; width: 14px; height: 1px; background: var(--tcc-brand); }
.t1-step__fig { margin: 0; justify-self: end; width: 100%; max-width: 520px; aspect-ratio: 4 / 5; border-radius: var(--tcc-radius-card); overflow: clip; background: var(--tcc-surface); }
.t1-step__fig img { width: 100%; height: 100%; object-fit: cover; }
.t1-step__fig--phone { max-width: 270px; aspect-ratio: 1284 / 2778; border-radius: 34px; padding: 9px; background: #15181a; box-shadow: inset 0 0 0 1.5px var(--tcc-brand), 0 30px 80px -30px rgba(54,174,203,.35); }
.t1-step__fig--phone img { border-radius: 26px; }
.t1-ticks { display: none; }

/* pinned mode (JS, motion allowed): one full screen, steps cross over at thresholds */
@media (prefers-reduced-motion: no-preference) {
  .js .t1-stage { height: 340svh; }
  .js .t1-pin { position: sticky; top: 0; height: 100svh; overflow: clip; display: flex; align-items: stretch; }
  .js .t1-pin__in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); grid-template-rows: auto auto 1fr auto; column-gap: var(--tcc-gutter);
    padding: calc(var(--tcc-clear) + 3svh) 0 3svh; height: 100%; }
  .js .t1-room { grid-column: 1; grid-row: 1; position: relative; z-index: 2; }
  .js .t1-key { grid-column: 1; grid-row: 2; position: relative; z-index: 2; }
  .js .t1-steps { grid-column: 1 / -1; grid-row: 1 / 4; display: grid; margin: 0; }
  /* the hand-over between steps: the dots move first (they are the subject); the old step clears in .25s, so no frame
     holds two names; the new one's photo fades up while its words rise in, line by line */
  .js .t1-step { grid-area: 1 / 1; grid-template-rows: 1fr; opacity: 0; visibility: hidden; transition: opacity .25s var(--tcc-easing-soft), visibility 0s .25s; }
  .js .t1-step.is-on { opacity: 1; visibility: visible; transition: opacity .4s var(--tcc-easing-soft) .1s, visibility 0s; }
  .js .t1-step__txt { grid-column: 1; grid-row: 1; align-self: end; padding-bottom: 2svh; }
  .js .t1-step__txt > * { transform: translateY(18px); opacity: 0; transition: transform .6s var(--tcc-easing-arrive), opacity .35s var(--tcc-easing-soft); }
  .js .t1-step.is-on .t1-step__txt > * { transform: none; opacity: 1; }
  .js .t1-step.is-on .t1-step__txt > :nth-child(2) { transition-delay: .2s; }
  .js .t1-step.is-on .t1-step__txt > :nth-child(3) { transition-delay: .27s; }
  .js .t1-step.is-on .t1-step__txt > :nth-child(4) { transition-delay: .34s; }
  .js .t1-step.is-on .t1-step__txt > :nth-child(5) { transition-delay: .41s; }
  .js .t1-step__marks { display: none; }
  .js .t1-step__fig { grid-column: 2; grid-row: 1; align-self: center; max-height: calc(100svh - var(--tcc-clear) - 14svh); width: auto; height: 100%; justify-self: end; }
  .js .t1-step__fig img { transform: scale(1.06); transition: transform 1.2s var(--tcc-easing-arrive); }
  .js .t1-step.is-on .t1-step__fig img { transform: none; }
  .js .t1-ticks { grid-column: 1 / -1; grid-row: 4; display: flex; gap: 8px; padding-top: 12px; border-top: 1px solid var(--tcc-border); }
  .js .t1-ticks button { position: relative; display: inline-flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 16px 0 0; border: 0; background: none; color: var(--tcc-on-dark-muted);
    font: 600 var(--t-meta)/1 var(--tcc-font-body); cursor: pointer; transition: color var(--ui-t) var(--tcc-easing-soft); }
  .js .t1-ticks button { color: var(--c-meta); }
  @media (hover: hover) and (pointer: fine) { .js .t1-ticks button:hover { color: var(--tcc-text); } }
  .js .t1-ticks .tr-marks { --d: 7px; opacity: .5; transition: opacity .3s; }
  .js .t1-ticks button[aria-current="true"] { color: var(--tcc-text); }
  .js .t1-ticks button[aria-current="true"] .tr-marks { opacity: 1; }
  .js .t1-ticks li { flex: 1; }
  .js .t1-ticks li button::after { content: ''; position: absolute; left: 0; right: 0; top: -13px; height: 2px; background: var(--tcc-brand); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--tcc-easing-move); }
  .js .t1-ticks button[aria-current="true"]::after { transform: scaleX(1); }

  @media (max-width: 1023px) {
    .js .t1-pin__in { grid-template-columns: 1fr; grid-template-rows: auto auto 1fr auto; }
    .js .t1-steps { grid-row: 3; min-height: 0; }
    .js .t1-step { min-height: 0; }
    .js .t1-step { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) auto; gap: 14px; align-items: stretch; }
    .js .t1-step__fig { grid-column: 1; grid-row: 1; justify-self: start; height: 100%; max-height: none; min-height: 0; aspect-ratio: auto; width: 100%; max-width: none; margin-top: 10px; }
    .js .t1-step__fig--phone { width: auto; aspect-ratio: 1284 / 2778; justify-self: center; border-radius: 26px; padding: 6px; }
    .js .t1-step__fig--phone img { border-radius: 20px; }
    .js .t1-step__txt { grid-column: 1; grid-row: 2; gap: 10px; padding-bottom: 0; }
    .js .t1-step__facts { display: none; }
    .js .t1-step .btn { --h: var(--tcc-control-h-sm); }
    .js .t1-ticks button { padding-right: 6px; gap: 8px; min-width: 44px; }
    .js .t1-ticks .tr-marks { display: none; }
    .js .t1-key { display: none; }
  }
}
@media (max-width: 1023px) and (prefers-reduced-motion: reduce), (max-width: 1023px) {
  html:not(.js) .t1-step { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .t1-step { grid-template-columns: 1fr; } .t1-step__fig { justify-self: start; }
  .t1-room, .t1-key { display: none; }
}

/* ---------- 3 · Always included ---------- */
.t1-always { padding: var(--tcc-space-xl) 0 var(--tcc-space-2xl); }
.t1-always__in { max-width: 1060px; display: grid; gap: var(--tcc-space-m); justify-items: start; }
.t1-always__from { display: inline-flex; align-items: center; gap: 10px; font: 600 var(--t-label)/1.3 var(--tcc-font-body); letter-spacing: .08em; text-transform: uppercase; color: #b9bcbd; }
.t1-always__from i { width: 10px; height: 10px; border-radius: 50%; background: #b9bcbd; }
.t1-always__p { font: 500 var(--tcc-text-3xl)/1.18 var(--tcc-font-heading); letter-spacing: -.02em; max-width: 30ch; }

/* ---------- 4 · Coaches (shared.css), 5 · Quotes, 7 · Ask (components) ---------- */
.t1-coaches .tr-coach__fig { max-width: 310px; }
.t1-ask { padding-bottom: var(--tcc-space-2xl); }

/* the last section paints its own ground: the shared footer is revealed from underneath */
.t1-ask { background: var(--tcc-ground); }
