/* Work with us, trainer sign-in and trainer portal. Loaded after trainer-claim.css, which supplies the tc-* layout. */

.tc-hero, .tc-body { --tp-available: #12805c; --tp-available-tint: #dff3ea; --tp-busy: #b42318; --tp-busy-tint: #fbe4e2; }

.tp-hero-login { margin: 18px 0 0; color: rgba(255, 255, 255, 0.82); font-size: 0.95rem; }
.tp-hero-login a { color: var(--tc-gold); font-weight: 700; }
.tp-hero-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 18px; color: rgba(255, 255, 255, 0.8); font-size: 0.92rem; }
.tp-signout { padding: 7px 16px; border: 1px solid rgba(255, 255, 255, 0.4); border-radius: 999px; background: transparent; color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.tp-signout:hover { background: rgba(255, 255, 255, 0.12); }

.tp-choice { display: flex; flex-wrap: wrap; gap: 10px; }
.tp-pill { position: relative; display: inline-flex; cursor: pointer; }
.tp-pill input { position: absolute; opacity: 0; pointer-events: none; }
.tp-pill span { display: inline-flex; align-items: center; min-height: 46px; padding: 10px 18px; border: 1px solid var(--tc-line); border-radius: 10px; background: #fff; color: var(--tc-ink); font-weight: 700; font-size: 0.92rem; transition: border-color 0.15s, background-color 0.15s; }
.tp-pill input:checked + span { border-color: var(--tc-navy); background: #e8f0f8; color: var(--tc-navy); box-shadow: inset 0 0 0 1px var(--tc-navy); }
.tp-pill input:focus-visible + span { outline: 3px solid rgba(0, 63, 105, 0.3); outline-offset: 2px; }

.tp-inline-button { display: inline-flex; margin-top: 12px; text-decoration: none; }
.tp-muted { margin: 4px 0 0; color: var(--tc-muted); font-size: 0.9rem; }
.tp-note { margin-bottom: 18px; padding: 12px 16px; border-radius: 10px; background: #e6f4ee; color: #0b5d43; font-weight: 600; }
.tp-empty { margin: 0; padding: 22px; border: 1px dashed var(--tc-line); border-radius: 12px; color: var(--tc-muted); text-align: center; }

.tp-login-card { max-width: 520px; }
.tp-login-form { display: grid; gap: 18px; }
.tp-code-input { font-size: 1.6rem !important; letter-spacing: 0.4em !important; text-align: center; }
.tp-resend { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 18px; }
.tp-link-button { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }

.tp-portal { display: grid; gap: 28px; }
.tp-portal .tc-card { margin-top: 0; width: 100%; max-width: 980px; }
.tp-portal .tc-card:first-child { margin-top: -84px; }
.tp-card-head { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.tp-card-head h2 { margin: 0; color: var(--tc-navy); font-size: 1.35rem; }

.tp-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.tp-mode { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 8px 16px; border: 1px solid var(--tc-line); border-radius: 999px; background: #fff; color: var(--tc-ink); font: inherit; font-weight: 700; font-size: 0.9rem; cursor: pointer; }
.tp-mode.is-active { border-color: var(--tc-navy); background: var(--tc-navy); color: #fff; }
.tp-swatch { width: 14px; height: 14px; border: 1px solid var(--tc-line); border-radius: 4px; background: #fff; }
.tp-swatch.is-available { border-color: var(--tp-available); background: var(--tp-available); }
.tp-swatch.is-busy { border-color: var(--tp-busy); background: var(--tp-busy); }

.tp-calendar { max-width: 620px; }
.tp-cal-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; color: var(--tc-navy); font-size: 1.05rem; }
.tp-cal-arrow { width: 40px; height: 40px; border: 1px solid var(--tc-line); border-radius: 10px; background: #fff; color: var(--tc-navy); font-size: 1.1rem; cursor: pointer; }
.tp-cal-arrow:disabled { opacity: 0.35; cursor: default; }
.tp-cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.tp-cal-head { padding: 4px 0; color: var(--tc-muted); font-size: 0.75rem; font-weight: 700; text-align: center; text-transform: uppercase; letter-spacing: 0.05em; }
.tp-day { position: relative; aspect-ratio: 1 / 1; min-height: 40px; border: 1px solid var(--tc-line); border-radius: 10px; background: #fff; color: var(--tc-ink); font: inherit; font-weight: 700; cursor: pointer; transition: transform 0.1s, background-color 0.15s; }
.tp-day:hover:not(:disabled) { border-color: var(--tc-navy); }
.tp-day:active:not(:disabled) { transform: scale(0.96); }
.tp-day:focus-visible { outline: 3px solid rgba(0, 63, 105, 0.35); outline-offset: 1px; }
.tp-day:disabled { background: #f4f6f8; color: #a3adb8; cursor: default; }
.tp-day.is-available { border-color: var(--tp-available); background: var(--tp-available-tint); color: #0b5d43; }
.tp-day.is-busy { border-color: var(--tp-busy); background: var(--tp-busy-tint); color: #8a1c12; }
.tp-day:disabled.is-available, .tp-day:disabled.is-busy { opacity: 0.55; }
.tp-day.is-today { box-shadow: inset 0 0 0 2px var(--tc-gold); }
.tp-day.is-changed::after { content: ""; position: absolute; top: 5px; right: 5px; width: 6px; height: 6px; border-radius: 50%; background: var(--tc-navy); }

.tp-range { margin-top: 20px; padding: 14px 16px; border: 1px solid var(--tc-line); border-radius: 12px; background: var(--tc-tint); }
.tp-range summary { color: var(--tc-navy); font-weight: 700; cursor: pointer; }
.tp-range-row { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; margin-top: 14px; }
.tp-range-row .tc-field { min-width: 150px; }
.tp-check { display: inline-flex; align-items: center; gap: 8px; min-height: 46px; font-size: 0.9rem; font-weight: 600; }

.tp-secondary { min-height: 44px; padding: 10px 18px; border: 1px solid var(--tc-navy); border-radius: 10px; background: #fff; color: var(--tc-navy); font: inherit; font-weight: 800; cursor: pointer; }
.tp-secondary:hover { background: #e8f0f8; }

.tp-savebar { position: relative; bottom: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 12px 18px; margin: 22px -34px -30px; padding: 16px 34px; border-top: 1px solid var(--tc-line); border-radius: 0 0 16px 16px; background: #fff; }
.tp-savebar.has-pending { position: sticky; z-index: 3; box-shadow: 0 -10px 24px -18px rgba(6, 41, 74, 0.45); }
.tp-savebar .tp-muted { margin: 0; }
.tp-savebar .is-pending { color: var(--tc-navy); font-weight: 700; }

.tp-openings { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.tp-opening { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px 24px; padding: 18px 20px; border: 1px solid var(--tc-line); border-radius: 12px; }
.tp-opening-main { flex: 1 1 380px; min-width: 0; }
.tp-opening h3 { margin: 0 0 6px; color: var(--tc-ink); font-size: 1.05rem; }
.tp-opening-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0; color: var(--tc-muted); font-size: 0.88rem; }
.tp-opening-meta span + span::before { content: "·"; margin-right: 14px; }
.tp-opening-desc { margin: 10px 0 0; color: var(--tc-ink); font-size: 0.92rem; white-space: pre-line; }
.tp-opening-action { display: flex; align-items: center; }
.tp-badge { display: inline-flex; padding: 8px 14px; border-radius: 999px; background: #e6f4ee; color: #0b5d43; font-size: 0.85rem; font-weight: 800; }

@media (max-width: 720px) {
  .tp-savebar { margin: 22px -20px -22px; padding: 14px 20px; }
  .tp-day { min-height: 36px; font-size: 0.85rem; border-radius: 8px; }
  .tp-cal-grid { gap: 4px; }
  .tp-range-row .tc-field { flex: 1 1 100%; }
}
