/* ==========================================================================
   Teleport — фірмовий вигляд адмінки. Статичний CSS: зібраний CSS Filament
   не бачить наших Blade-файлів, тож класи Tailwind у своїх віджетах не працюють.
   Палітра з логотипа: вогняний помаранч #ff4100, чорнильний фіолет #2e2447.
   ========================================================================== */

.fi-body { font-feature-settings: 'ss01'; }
.fi-sidebar { background: #fafafa; }
.dark .fi-sidebar { background: linear-gradient(180deg, #1b1430 0%, #140f22 100%); }
.fi-sidebar-item-active > a, .fi-sidebar-item.fi-active > a { box-shadow: inset 3px 0 0 #ff4100; }
.fi-header-heading { font-family: 'Unbounded', 'Manrope', sans-serif; letter-spacing: -.01em; }
.fi-section { border-radius: 18px; }
.tp-tour-btn { color: #52525b; }

/* Головна кнопка — фірмовий помаранч з білим текстом (як у кабінеті учасника). */
.fi-btn.fi-color-primary:not(.fi-outlined):not(.fi-link) {
    color: #fff;
    background: linear-gradient(135deg, #ff5a1a 0%, #e03500 60%, #c93000 100%);
    box-shadow: 0 8px 20px -10px rgba(255, 65, 0, .7), inset 0 1px 0 rgba(255, 255, 255, .2);
}
.fi-btn.fi-color-primary:not(.fi-outlined):not(.fi-link) .fi-icon { color: #fff; }
.fi-btn.fi-color-primary:not(.fi-outlined):not(.fi-link):hover { filter: brightness(1.05); }

/* Кнопки вибору (ToggleButtons): помаранчева лише обрана, решта — світлі. Інакше не видно, що обрано. */
.fi-fo-toggle-buttons-input:not(:checked) + .fi-btn.fi-color-primary:not(.fi-outlined):not(.fi-link),
.fi-fo-toggle-buttons-input:not(:checked) + .fi-btn {
    color: #3f3f46; background: #fff; box-shadow: inset 0 0 0 1px #e4e4e7; filter: none;
}
.fi-fo-toggle-buttons-input:not(:checked) + .fi-btn:hover { background: #fff7f3; box-shadow: inset 0 0 0 1px #ffb999; }
.fi-fo-toggle-buttons-input:not(:checked) + .fi-btn .fi-icon { color: #71717a; }
.fi-fo-toggle-buttons-input:checked + .fi-btn { box-shadow: 0 0 0 2px #fff, 0 0 0 4px #ff4100; }
.fi-fo-toggle-buttons-input:focus-visible + .fi-btn { outline: 2px solid #ff4100; outline-offset: 2px; }
/* Темна тема: невибрані — темні з тонкою рамкою, а не білі плями на чорному. */
.dark .fi-fo-toggle-buttons-input:not(:checked) + .fi-btn.fi-color-primary:not(.fi-outlined):not(.fi-link),
.dark .fi-fo-toggle-buttons-input:not(:checked) + .fi-btn {
    color: #e4e4e7; background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
}
.dark .fi-fo-toggle-buttons-input:not(:checked) + .fi-btn:hover { background: rgba(255, 65, 0, .12); box-shadow: inset 0 0 0 1px rgba(255, 65, 0, .5); }
.dark .fi-fo-toggle-buttons-input:not(:checked) + .fi-btn .fi-icon { color: #a1a1aa; }
.dark .fi-fo-toggle-buttons-input:checked + .fi-btn { box-shadow: 0 0 0 2px rgb(24 24 27), 0 0 0 4px #ff4100; }

/* ---------- Інфопанель ---------- */
.tp-hero {
    position: relative; overflow: hidden; border-radius: 22px; padding: 26px; color: #fff;
    background:
        radial-gradient(120% 90% at 100% 0%, rgba(255, 65, 0, .55) 0%, transparent 55%),
        radial-gradient(90% 80% at 0% 100%, rgba(139, 120, 196, .55) 0%, transparent 60%),
        linear-gradient(145deg, #2e2447 0%, #1e1731 100%);
    box-shadow: 0 18px 40px -20px rgba(46, 36, 71, .7);
}
.tp-hero__date { font-size: 13px; color: rgba(255, 255, 255, .7); }
.tp-hero__title { font-family: 'Unbounded', 'Manrope', sans-serif; font-size: 26px; font-weight: 700; margin-top: 4px; line-height: 1.15; }
.tp-hero__note { margin-top: 10px; max-width: 640px; font-size: 14px; line-height: 1.5; color: rgba(255, 255, 255, .82); }
.tp-hero__btns { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin-top: 20px; }
.tp-hero__btn {
    display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 12px 14px; border-radius: 14px;
    background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); font-weight: 700; font-size: 14px;
    transition: background-color .2s, transform .15s;
}
.tp-hero__btn:hover { background: rgba(255, 255, 255, .18); }
.tp-hero__btn:active { transform: scale(.98); }
.tp-hero__btn--ghost { background: transparent; border-style: dashed; color: rgba(255, 255, 255, .8); }
.tp-hero__btn--ghost:hover { background: rgba(255, 255, 255, .08); }
.tp-hero__icon { width: 22px; height: 22px; flex: none; }

.tp-card { background: #fff; border: 1px solid rgba(24, 24, 27, .08); border-radius: 18px; padding: 20px; box-shadow: 0 1px 2px rgba(30, 23, 49, .04), 0 8px 24px -14px rgba(46, 36, 71, .18); }
.dark .tp-card { background: #211a38; border-color: rgba(232, 224, 255, .08); }
.tp-card__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.tp-card__head .tp-bar { width: 40%; }
.tp-card__title { font-family: 'Unbounded', 'Manrope', sans-serif; font-weight: 600; font-size: 17px; margin-top: 2px; }
.tp-eyebrow { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #71717a; }
.tp-muted { color: #71717a; }

.tp-bar { height: 8px; border-radius: 999px; background: rgba(24, 24, 27, .08); overflow: hidden; }
.dark .tp-bar { background: rgba(232, 224, 255, .1); }
.tp-bar > i { display: block; height: 100%; width: var(--w, 0); border-radius: inherit; background: linear-gradient(90deg, #ff9763, #ff4100); transition: width 1s cubic-bezier(.2, .8, .2, 1); }
.tp-bar.is-full > i { background: linear-gradient(90deg, #8b78c4, #4f4182); }

.tp-check { margin-top: 14px; display: grid; gap: 8px; }
.tp-check__row { display: flex; align-items: flex-start; gap: 12px; padding: 12px; border-radius: 14px; background: rgba(255, 65, 0, .05); }
.tp-check__row.is-done { background: transparent; padding-block: 6px; }
.tp-check__icon { width: 22px; height: 22px; flex: none; color: #ff4100; margin-top: 1px; }
.tp-check__row.is-done .tp-check__icon { color: #1f9d68; }
.tp-check__text { flex: 1; min-width: 0; }
.tp-check__title { font-weight: 700; font-size: 14px; }
.tp-check__row.is-done .tp-check__title { font-weight: 500; color: #71717a; }
.tp-check__why { font-size: 13px; color: #52525b; margin-top: 2px; line-height: 1.45; }
.dark .tp-check__why { color: #a1a1aa; }
.tp-check__cta { flex: none; align-self: center; min-height: 36px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 10px; background: #ff4100; color: #fff; font-weight: 700; font-size: 13px; }

.tp-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.tp-stat { background: #fff; border: 1px solid rgba(24, 24, 27, .08); border-radius: 16px; padding: 16px; }
.dark .tp-stat { background: #211a38; border-color: rgba(232, 224, 255, .08); }
.tp-stat__label { font-size: 12px; font-weight: 700; color: #71717a; }
.tp-stat__value { font-family: 'Unbounded', 'Manrope', sans-serif; font-size: 28px; font-weight: 700; margin-top: 4px; }
.tp-stat.is-alert { border-color: rgba(229, 72, 77, .35); background: rgba(229, 72, 77, .06); }
.tp-stat.is-alert .tp-stat__value { color: #e5484d; }
.tp-stat.is-warn .tp-stat__value { color: #e03500; }

.tp-grid2 { display: grid; gap: 12px; margin-top: 12px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .tp-grid2 { grid-template-columns: 1fr 1fr; } }
.tp-funnel { display: grid; gap: 12px; margin-top: 14px; }
.tp-funnel__row { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; margin-bottom: 6px; }
.tp-funnel__row small { display: block; font-size: 12px; color: #71717a; }
.tp-funnel__row b { font-variant-numeric: tabular-nums; }

/* ---------- Попап туру ---------- */
/* ==========================================================================
   Тур по системі: плаваюча кнопка «?» і стиль підказок driver.js
   ========================================================================== */

.driver-popover.tp-pop {
    border-radius: 1.1rem !important;
    padding: 1.15rem 1.25rem 1rem !important;
    max-width: 27rem !important;
    min-width: 21rem !important;
    background: #fff !important;
    box-shadow: 0 24px 55px -14px rgba(3, 7, 18, .45), 0 0 0 1px rgba(3, 7, 18, .05) !important;
}
.dark .driver-popover.tp-pop {
    background: #1c1c1f !important;
    box-shadow: 0 24px 55px -14px rgba(0, 0, 0, .7), 0 0 0 1px rgba(255, 255, 255, .08) !important;
}
/* --- Шапка: іконка + група/розділ + номер розділу --- */
.tp-pop__eyebrow {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: .8rem;
    padding-bottom: .7rem;
    border-bottom: 1px solid rgba(3, 7, 18, .07);
}
.dark .tp-pop__eyebrow { border-color: rgba(255, 255, 255, .09); }
.tp-pop__icon {
    flex: none;
    display: grid;
    place-items: center;
    width: 2.15rem; height: 2.15rem;
    border-radius: .7rem;
    color: #fff;
    background: linear-gradient(135deg, #ff9763, #e03500);
    box-shadow: 0 6px 14px -6px rgba(224, 53, 0, .8);
}
.tp-pop__icon svg { width: 1.2rem; height: 1.2rem; }
.tp-pop__eyebrow-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.tp-pop__group {
    font-size: .63rem;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: #e03500;
}
.tp-pop__section {
    font-size: .82rem;
    font-weight: 600;
    color: #6b7280;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.dark .tp-pop__section { color: #a1a1aa; }
.tp-pop__section-no {
    margin-inline-start: auto;
    flex: none;
    font-size: .68rem;
    font-weight: 700;
    color: #9ca3af;
    background: rgba(3, 7, 18, .04);
    border-radius: .45rem;
    padding: .18rem .45rem;
    white-space: nowrap;
}
.dark .tp-pop__section-no { background: rgba(255, 255, 255, .07); color: #a1a1aa; }
/* --- Заголовок і текст --- */
.tp-pop .driver-popover-title {
    font-size: 1.12rem !important;
    font-weight: 800 !important;
    letter-spacing: -.015em !important;
    line-height: 1.3 !important;
    color: #111827 !important;
    margin-bottom: .4rem !important;
}
.dark .tp-pop .driver-popover-title { color: #f9fafb !important; }
.tp-pop .driver-popover-description {
    font-size: .875rem !important;
    line-height: 1.55 !important;
    color: #4b5563 !important;
    margin-bottom: 0 !important;
}
.dark .tp-pop .driver-popover-description { color: #c4c4c8 !important; }
/* --- Блок «Навіщо це вам» --- */
.tp-pop__why {
    display: block;
    margin-top: .8rem;
    padding: .7rem .85rem;
    border-radius: .7rem;
    border-inline-start: 3px solid #ff4100;
    background: linear-gradient(90deg, rgba(255, 65, 0, .1), rgba(255, 65, 0, .03));
}
.dark .tp-pop__why { background: linear-gradient(90deg, rgba(255, 65, 0, .16), rgba(255, 65, 0, .05)); }
.tp-pop__why-label {
    display: flex;
    align-items: center;
    gap: .3rem;
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .07em;
    text-transform: uppercase;
    color: #b52a02;
    margin-bottom: .25rem;
}
.tp-pop__why-label svg { width: .95rem; height: .95rem; }
.dark .tp-pop__why-label { color: #ff9763; }
.tp-pop__why-text {
    display: block;
    font-size: .845rem;
    line-height: 1.5;
    color: #4b5563;
}
.dark .tp-pop__why-text { color: #d4d4d8; }
/* --- Прогрес: смуга + два лічильники --- */
.tp-pop .driver-popover-footer {
    margin-top: .95rem !important;
    display: block !important;
}
.tp-pop .driver-popover-progress-text {
    display: block !important;
    width: 100% !important;
    margin-bottom: .7rem !important;
}
.tp-pop__bar {
    display: block;
    height: 5px;
    border-radius: 999px;
    background: rgba(3, 7, 18, .08);
    overflow: hidden;
}
.dark .tp-pop__bar { background: rgba(255, 255, 255, .1); }
.tp-pop__bar-fill {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #ff9763, #e03500);
    transition: width .35s ease;
}
.tp-pop__meta {
    display: flex;
    justify-content: space-between;
    gap: .75rem;
    margin-top: .4rem;
    font-size: .7rem;
    color: #9ca3af;
}
.tp-pop__meta-page { font-weight: 600; color: #6b7280; }
.dark .tp-pop__meta-page { color: #a1a1aa; }
/* --- Кнопки --- */
.tp-pop .driver-popover-navigation-btns {
    display: flex !important;
    justify-content: flex-end !important;
    gap: .45rem !important;
}
.tp-pop .driver-popover-navigation-btns button {
    border-radius: .55rem !important;
    padding: .42rem .95rem !important;
    font-size: .82rem !important;
    font-weight: 700 !important;
    text-shadow: none !important;
    transition: background .15s ease, color .15s ease;
}
.tp-pop .driver-popover-prev-btn {
    background: transparent !important;
    border: 1px solid rgba(3, 7, 18, .12) !important;
    color: #6b7280 !important;
}
.tp-pop .driver-popover-prev-btn:hover { background: rgba(3, 7, 18, .04) !important; }
.dark .tp-pop .driver-popover-prev-btn { border-color: rgba(255,255,255,.14) !important; color: #a1a1aa !important; }
.dark .tp-pop .driver-popover-prev-btn:hover { background: rgba(255,255,255,.06) !important; }
.tp-pop .driver-popover-next-btn {
    background: linear-gradient(135deg, #ff4100, #e03500) !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 6px 14px -6px rgba(224, 53, 0, .9) !important;
}
.tp-pop .driver-popover-next-btn:hover { filter: brightness(1.06); }
.tp-pop .driver-popover-close-btn { color: #9ca3af !important; }
.dark .tp-pop .driver-popover-close-btn { color: #71717a !important; }
.tp-pop .driver-popover-arrow { border-width: 8px !important; }
/* Обкладинка розділу — коли крок не прив’язаний до елемента */
.tp-pop--cover .tp-pop__icon { width: 2.5rem; height: 2.5rem; border-radius: .8rem; }
.tp-pop--cover .tp-pop__icon svg { width: 1.4rem; height: 1.4rem; }
.tp-pop--cover .driver-popover-title { font-size: 1.25rem !important; }
.driver-popover.tp-pop { min-width: 0 !important; max-width: 92vw !important; }
.tp-pop__meta { flex-direction: column; align-items: flex-start; gap: .1rem; text-align: left; }
/* ---------- Телефон ---------- */
@media (max-width: 640px) {
    .tp-hero { padding: 20px; border-radius: 18px; }
    .tp-hero__title { font-size: 21px; }
    .tp-hero__btns { grid-template-columns: 1fr 1fr; }
    .tp-hero__btn { font-size: 13px; padding: 10px 12px; }
    .tp-card { padding: 16px; }
    .tp-card__head { flex-direction: column; align-items: stretch; }
    .tp-card__head .tp-bar { width: 100%; }
    .tp-stats { grid-template-columns: 1fr 1fr; }
    .tp-stat__value { font-size: 24px; }
    .tp-check__row { flex-wrap: wrap; }
    .tp-check__text { flex-basis: calc(100% - 34px); }
    .tp-check__cta { margin-left: 34px; }
    /* Дії таблиці притиснуті праворуч — не їдуть за край. */
    .fi-ta-actions { justify-content: flex-end; }
}

/* Есе в адмінці: картинки в межах колонки, посилання помітні. */
.tp-essay img { max-width: 100%; height: auto; border-radius: 12px; margin: 10px 0; }
.tp-essay a { color: #ff4100; text-decoration: underline; word-break: break-all; }

/* ---------- Звіт сценарію ---------- */
.sc-hint { font-size: 12.5px; color: #7D766E; line-height: 1.45; margin: 0; }
.sc-muted { color: #8C857D; font-size: 12.5px; }
.sc-badge { font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 99px; }
.sc-badge-start { background: #FF4100; color: #fff; text-transform: uppercase; letter-spacing: .06em; }
.sc-report { display: flex; flex-direction: column; gap: 14px; }
.sc-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.sc-stat { border: 1px solid #E7E2DC; border-radius: 14px; background: #fff; padding: 12px 14px; }
.sc-stat-v { font-size: 26px; font-weight: 800; color: #1F1D1B; } .sc-stat-v small { font-size: 13px; color: #1f9d68; }
.sc-table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid #E7E2DC; border-radius: 14px; overflow: hidden; font-size: 14px; }
.sc-table th { text-align: left; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: #8C857D; padding: 10px 12px; background: #FBFAF8; }
.sc-table td { padding: 10px 12px; border-top: 1px solid #F0ECE7; vertical-align: top; }
.sc-bar { height: 8px; width: 120px; border-radius: 99px; background: #F0ECE7; overflow: hidden; display: inline-block; vertical-align: middle; margin-right: 6px; } .sc-bar i { display: block; height: 100%; background: #FF4100; }
@media (max-width: 767px) {
    .sc-table thead { display: none; }
    .sc-table, .sc-table tbody, .sc-table tr, .sc-table td { display: block; }
    .sc-table tr { padding: 12px 14px; border-top: 1px solid #F0ECE7; }
    .sc-table tr:first-child { border-top: 0; }
    .sc-table td { padding: 3px 0; border: 0; }
    .sc-table td.sc-td-title { padding-bottom: 6px; font-size: 15px; }
    .sc-table td[data-label] { display: flex; gap: 12px; justify-content: space-between; align-items: baseline; text-align: right; }
    .sc-table td[data-label]::before { content: attr(data-label); color: #8C857D; font-size: 12.5px; text-align: left; flex-shrink: 0; }
    .sc-table .sc-bar { width: 80px; }
    .sc-table td.sc-td-buttons { display: block; text-align: left; padding-top: 6px; }
    .sc-table td.sc-td-buttons::before { display: block; margin-bottom: 2px; }
    .sc-table td.sc-td-buttons > div { padding: 2px 0 2px 10px; border-left: 2px solid #F0ECE7; }
}
.dark .sc-stat, .dark .sc-table { background: rgba(255, 255, 255, .04); border-color: rgba(255, 255, 255, .1); }
.dark .sc-stat-v { color: #f4f4f5; }
.dark .sc-table th { background: rgba(255, 255, 255, .05); color: #a1a1aa; }
.dark .sc-table td, .dark .sc-table tr { border-color: rgba(255, 255, 255, .08); }
.dark .sc-bar { background: rgba(255, 255, 255, .1); }
.dark .sc-muted, .dark .sc-hint { color: #a1a1aa; }

/* ---------- Кабінет тренера «Моя група» ---------- */
.tp-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tp-chipbtn { min-height: 40px; display: inline-flex; align-items: center; padding: 0 16px; border-radius: 999px; background: rgba(24, 24, 27, .05); font-weight: 700; font-size: 14px; }
.tp-chipbtn.is-on { background: #ff4100; color: #fff; }
.dark .tp-chipbtn { background: rgba(232, 224, 255, .08); }
.dark .tp-chipbtn.is-on { background: #ff4100; color: #fff; }
.tp-signals { display: grid; gap: 8px; margin-top: 14px; }
.tp-signal { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: rgba(24, 24, 27, .03); }
.dark .tp-signal { background: rgba(232, 224, 255, .05); }
.tp-signal__dot { width: 10px; height: 10px; border-radius: 999px; flex: none; background: #a1a1aa; }
.tp-signal.is-help .tp-signal__dot, .tp-signal.is-energy .tp-signal__dot { background: #e5484d; }
.tp-signal.is-silent .tp-signal__dot { background: #e03500; }
.tp-signal.is-plan .tp-signal__dot { background: #8b78c4; }
.tp-signal.is-skip .tp-signal__dot { background: #38bdf8; }
.tp-signal.is-help { background: rgba(229, 72, 77, .07); }
.tp-signal__text { flex: 1; min-width: 0; font-size: 14px; line-height: 1.4; }
.tp-signal__text b { display: block; }
/* Телефон: кнопка під текстом, щоб текст не стискався у вузьку колонку. */
@media (max-width: 640px) { .tp-signal { flex-wrap: wrap; align-items: flex-start; } .tp-signal__dot { margin-top: 6px; } .tp-signal__text { flex-basis: calc(100% - 22px); } .tp-signal > :last-child:not(.tp-signal__text) { margin-left: 22px; } }
.tp-table-wrap { overflow-x: auto; margin-top: 12px; }
.tp-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.tp-table th { text-align: left; font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #71717a; padding: 8px 10px; border-bottom: 1px solid rgba(24, 24, 27, .08); white-space: nowrap; }
.tp-table td { padding: 10px; border-bottom: 1px solid rgba(24, 24, 27, .06); vertical-align: middle; }
.dark .tp-table th, .dark .tp-table td { border-color: rgba(232, 224, 255, .08); }
.tp-num { font-variant-numeric: tabular-nums; }
.tp-pill { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px; font-weight: 700; background: rgba(24, 24, 27, .06); white-space: nowrap; }
.dark .tp-pill { background: rgba(232, 224, 255, .08); }
.tp-pill.is-ok { background: rgba(34, 160, 107, .14); color: #1f9d68; }
.tp-pill.is-alert { background: rgba(229, 72, 77, .12); color: #e5484d; }
.tp-warn { color: #e03500; font-weight: 700; }
.tp-link { color: #ff4100; font-weight: 700; }
.tp-list { display: grid; gap: 4px; margin-top: 12px; }
.tp-list > li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid rgba(24, 24, 27, .06); font-size: 14px; }
.tp-list > li:last-child { border-bottom: 0; }
.tp-list > li small { display: block; }
.tp-list > li.is-past { opacity: .8; }
.tp-brief { font-size: 14px; line-height: 1.5; padding: 12px 14px; border-radius: 14px; background: rgba(24, 24, 27, .03); }
.tp-brief__list { list-style: decimal; padding-left: 18px; margin-top: 6px; display: grid; gap: 6px; }
.tp-brief__list span.tp-muted { display: block; font-size: 13px; }
.tp-brief__list .tp-pill { margin-left: 6px; height: 20px; font-size: 11px; }
.tp-mcards { display: none; margin-top: 12px; }
.tp-mcards > li { padding: 12px 0; border-bottom: 1px solid rgba(24, 24, 27, .06); display: grid; gap: 6px; }
.tp-mcards > li:last-child { border-bottom: 0; }
.tp-mcards__head { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; }
.tp-mcards__head .tp-num { font-family: 'Unbounded', 'Manrope', sans-serif; font-weight: 700; }
.tp-mcards__row { display: flex; flex-wrap: wrap; gap: 6px; }
@media (max-width: 639px) { .tp-mcards { display: grid; } .tp-table-wrap { display: none; } }

/* Лише на телефоні: дубль колонки, прихованої на вузькому екрані. */
.tp-mobile-only { display: none; }
@media (max-width: 767px) { .tp-mobile-only { display: inline; } }
/* Таблиці, де рядок відкриває запис, а кожна кнопка рядка має інший шлях: на телефоні кнопки ховаємо, щоб не різались краєм. */
@media (max-width: 767px) {
    .tp-rowtap .fi-ta-actions-header-cell,
    .tp-rowtap .fi-ta-row > td:last-child:has(.fi-ta-actions) { display: none; }
    /* Де кнопка рядка ніде більше не продубльована — лишаємо лише значки (назва схована візуально, диктор її читає). */
    .tp-icononly .fi-ta-actions { gap: 4px; }
    .tp-icononly .fi-ta-actions a[href$="/edit"] { display: none; } /* «Змінити» = тап по рядку */
    .tp-icononly .fi-ta-actions .fi-link { padding: 10px; }
    .tp-icononly .fi-ta-actions .fi-link .fi-icon { width: 20px; height: 20px; }
    .tp-icononly .fi-ta-actions .fi-link-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* Плитка-посилання: видно, що натискається. */
a.tp-stat { display: block; color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s; }
a.tp-stat:hover { transform: translateY(-1px); box-shadow: 0 8px 20px -12px rgba(24, 24, 27, .35); }

/* Вибір карткою (card-picker): стилі в шаблоні інлайнові, тож темна тема — з !important. */
.dark .tp-pick { background: rgba(255, 255, 255, .05) !important; outline-color: rgba(255, 255, 255, .12) !important; box-shadow: none !important; }
.dark .tp-pick.is-on { outline: 2px solid #ff4100 !important; outline-offset: -2px !important; }
.dark .tp-pick__title { color: #f4f4f5 !important; }
.dark .tp-pick__sub { color: #a1a1aa !important; }
.dark .tp-pick__icon { background: rgba(255, 65, 0, .16) !important; }
.dark .tp-pick__empty { background: rgba(255, 255, 255, .05) !important; color: #a1a1aa !important; }

/* Листування в питанні учасника: учасник ліворуч, команда праворуч. */
.tp-thread { display: grid; gap: 10px; margin-top: 12px; }
.tp-thread__row { display: flex; justify-content: flex-start; }
.tp-thread__row.is-staff { justify-content: flex-end; }
.tp-thread__bubble { max-width: min(560px, 88%); border-radius: 16px; padding: 10px 14px; background: #f4f4f5; }
.tp-thread__row.is-staff .tp-thread__bubble { background: #fff1ea; }
.tp-thread__who { font-size: 12px; color: #71717a; font-weight: 600; }
.tp-thread__text { margin-top: 3px; white-space: pre-line; overflow-wrap: anywhere; line-height: 1.5; }
.dark .tp-thread__bubble { background: rgba(255, 255, 255, .06); }
.dark .tp-thread__row.is-staff .tp-thread__bubble { background: rgba(255, 65, 0, .14); }
.dark .tp-thread__who { color: #a1a1aa; }

/* Як учасник просив з ним зв'язатися — під сигналом «мовчить». */
.tp-signal__pref { display: block; margin-top: 4px; font-size: 12.5px; font-weight: 600; color: #7c3aed; }
.dark .tp-signal__pref { color: #c4b5fd; }

/* Памятка ролі тренера й куратора. */
.tp-roleguide { display: grid; gap: 16px; margin-top: 14px; }
@media (min-width: 768px) { .tp-roleguide { grid-template-columns: 1fr 1fr; } }
.tp-roleguide__h { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #71717a; }
.tp-roleguide__h.is-yes { color: #16a34a; }
.tp-roleguide ul { margin-top: 8px; display: grid; gap: 6px; padding-left: 18px; list-style: disc; font-size: 14px; line-height: 1.45; }
.dark .tp-roleguide__h { color: #a1a1aa; }
.dark .tp-roleguide__h.is-yes { color: #4ade80; }

/* Огляд тижня тренера «3 людини — 3 дії». */
.tp-trio { display: grid; gap: 10px; margin-top: 12px; }
@media (min-width: 900px) { .tp-trio { grid-template-columns: repeat(3, 1fr); } }
.tp-trio__item { border-radius: 16px; padding: 14px; background: #f8f7fb; border-left: 4px solid #a1a1aa; }
.tp-trio__item.is-hard { border-left-color: #ef4444; background: #fef6f6; }
.tp-trio__item.is-decide { border-left-color: #f59e0b; background: #fffaf0; }
.tp-trio__item.is-praise { border-left-color: #16a34a; background: #f3fbf6; }
.tp-trio__kind { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #71717a; }
.tp-trio__name { margin-top: 4px; font-weight: 700; }
.tp-trio__why { margin-top: 4px; font-size: 14px; line-height: 1.45; }
.tp-trio__do { margin-top: 8px; font-size: 13.5px; font-weight: 600; color: #3f3f46; }
.dark .tp-trio__item { background: rgba(255, 255, 255, .04); }
.dark .tp-trio__item.is-hard { background: rgba(239, 68, 68, .1); }
.dark .tp-trio__item.is-decide { background: rgba(245, 158, 11, .1); }
.dark .tp-trio__item.is-praise { background: rgba(22, 163, 74, .1); }
.dark .tp-trio__kind { color: #a1a1aa; }
.dark .tp-trio__do { color: #e4e4e7; }

/* Підготовка тренера до зустрічі. */
.tp-prep { display: grid; gap: 14px; }
.tp-prep__block { border-radius: 14px; padding: 12px 14px; background: #f8f7fb; }
.tp-prep__h { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: #71717a; margin-bottom: 6px; }
.tp-prep ul { display: grid; gap: 8px; padding-left: 16px; list-style: disc; font-size: 14px; line-height: 1.45; }
.dark .tp-prep__block { background: rgba(255, 255, 255, .05); }
.dark .tp-prep__h { color: #a1a1aa; }

/* «Хто застряг на шляху» (куратор) */
.tp-stuck__sum { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.tp-stuck__chip { font-size: 12.5px; padding: 4px 10px; border-radius: 999px; background: rgba(24, 24, 27, .05); }
.dark .tp-stuck__chip { background: rgba(232, 224, 255, .08); }
.tp-stuck__chip.is-question, .tp-stuck__chip.is-revision { background: rgba(229, 72, 77, .1); }
.tp-stuck.is-question .tp-signal__dot, .tp-stuck.is-revision .tp-signal__dot { background: #e5484d; }
.tp-stuck.is-essay .tp-signal__dot { background: #e03500; }
.tp-stuck.is-group .tp-signal__dot, .tp-stuck.is-group_chat .tp-signal__dot { background: #8b78c4; }
.tp-stuck__name { color: inherit; text-decoration: none; }
.tp-stuck__name:hover { text-decoration: underline; }
.tp-stuck__q { display: block; margin-top: 3px; font-size: 13px; opacity: .75; }
.tp-stuck__more { margin-top: 10px; width: 100%; min-height: 44px; border-radius: 12px; font-weight: 600; font-size: 14px; background: rgba(24, 24, 27, .04); }
.dark .tp-stuck__more { background: rgba(232, 224, 255, .06); }

/* Банк кейсів */
.tp-seg { display: inline-flex; padding: 3px; border-radius: 12px; background: rgba(24, 24, 27, .05); }
.dark .tp-seg { background: rgba(232, 224, 255, .07); }
.tp-seg__btn { min-height: 40px; padding: 0 14px; border-radius: 9px; font-weight: 600; font-size: 14px; }
.tp-seg__btn.is-on { background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .1); }
.dark .tp-seg__btn.is-on { background: rgba(232, 224, 255, .14); }
.tp-case__search { flex: 1; min-width: 200px; min-height: 42px; padding: 0 14px; border-radius: 12px; border: 1px solid rgba(24, 24, 27, .12); background: transparent; font-size: 15px; }
.dark .tp-case__search { border-color: rgba(232, 224, 255, .15); }
.tp-cases { display: grid; gap: 12px; }
@media (min-width: 900px) { .tp-cases { grid-template-columns: repeat(2, 1fr); } }
.tp-case__h { margin-top: 12px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; opacity: .6; }
.tp-case__t { margin-top: 4px; font-size: 14.5px; line-height: 1.55; white-space: pre-line; }

/* Що змінилось */
.tp-changes { display: grid; gap: 12px; }
@media (min-width: 900px) { .tp-changes { grid-template-columns: repeat(2, 1fr); } }
.tp-ch-list { margin-top: 6px; display: grid; gap: 6px; font-size: 14px; line-height: 1.45; }

/* Ім’я учасника — кнопка, що відкриває бічну панель «Учасник» (контакти й історія). */
.tp-namebtn { padding: 0; background: none; border: 0; text-align: left; color: inherit; cursor: pointer; border-bottom: 1px dashed rgba(255, 65, 0, .45); }
.tp-namebtn:hover { color: #ff4100; }

/* Старт учасників (OnboardingPage) */
.tp-onb-alert { padding: 12px 16px; border-radius: 14px; background: rgba(229, 72, 77, .08); color: #b4232a; font-weight: 600; }
.tp-onb-stat { text-align: left; cursor: pointer; transition: transform .15s, box-shadow .15s, border-color .15s; }
.tp-onb-stat:hover { transform: translateY(-1px); box-shadow: 0 8px 20px -12px rgba(24, 24, 27, .35); }
.tp-onb-stat.is-on { border-color: #ff4100; box-shadow: 0 0 0 2px rgba(255, 65, 0, .25); }
.tp-onb-stat.is-ok .tp-stat__value { color: #1f9d55; }
.tp-onb-filters { display: flex; flex-direction: column; gap: 10px; }
.tp-onb-label { font-size: 12px; font-weight: 700; color: #71717a; margin-top: 4px; }
.tp-onb-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; }
.tp-onb-search { position: relative; flex: 1 1 260px; max-width: 360px; }
.tp-onb-search__i { position: absolute; left: 12px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: #a1a1aa; }
.tp-onb-search input { width: 100%; min-height: 40px; padding: 0 14px 0 38px; border-radius: 999px; border: 1px solid rgba(24, 24, 27, .12); background: transparent; font-size: 14px; }
.tp-onb-search input:focus { outline: none; border-color: #ff4100; box-shadow: 0 0 0 3px rgba(255, 65, 0, .15); }
.tp-onb-hint { font-size: 13px; color: #71717a; line-height: 1.5; }
.tp-onb-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: none; }
.tp-onb-stagechip { gap: 7px; }
.tp-onb-stagechip.is-danger .tp-onb-dot, .tp-onb-stage.is-danger { color: #d93036; }
.tp-onb-stagechip.is-warning .tp-onb-dot, .tp-onb-stage.is-warning { color: #e03500; }
.tp-onb-stagechip.is-info .tp-onb-dot, .tp-onb-stage.is-info { color: #6b5bb5; }
.tp-onb-stagechip.is-success .tp-onb-dot, .tp-onb-stage.is-success { color: #1f9d55; }
.tp-onb-stagechip.is-gray .tp-onb-dot, .tp-onb-stage.is-gray { color: #71717a; }
.tp-onb-stagechip.is-on .tp-onb-dot { color: #fff; }
.tp-onb-bulk { position: sticky; top: 72px; z-index: 20; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; padding: 12px 16px; border-radius: 16px; background: #1e1731; color: #fff; box-shadow: 0 12px 30px -14px rgba(30, 23, 49, .6); }
.tp-onb-bulk span { opacity: .8; }
.tp-onb-bulk__btns { display: flex; flex-wrap: wrap; gap: 8px; }
.tp-onb-list { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.tp-onb-item { display: grid; grid-template-columns: 28px 1fr auto; gap: 12px; align-items: start; padding: 14px; border-radius: 16px; background: rgba(24, 24, 27, .03); border: 1px solid transparent; transition: background .15s, border-color .15s; }
.tp-onb-item.is-picked { background: rgba(255, 65, 0, .06); border-color: rgba(255, 65, 0, .3); }
.dark .tp-onb-item { background: rgba(232, 224, 255, .05); }
.tp-onb-check { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; cursor: pointer; }
.tp-onb-check input { width: 20px; height: 20px; border-radius: 6px; accent-color: #ff4100; cursor: pointer; }
.tp-onb-main { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.tp-onb-name { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 16px; }
.tp-onb-pkg { font-size: 11px; font-weight: 800; letter-spacing: .04em; padding: 2px 8px; border-radius: 999px; background: rgba(139, 120, 196, .14); color: #6b5bb5; }
.tp-onb-stage { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: 14px; }
.tp-onb-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: #52525b; }
.dark .tp-onb-meta { color: #c4bfd6; }
.tp-onb-meta a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.tp-onb-meta .is-bad { color: #d93036; font-weight: 600; }
.tp-onb-flags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.tp-onb-flags span { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 8px; }
.tp-onb-flags .is-yes { background: rgba(31, 157, 85, .1); color: #1a7f46; }
.tp-onb-flags .is-no { background: rgba(24, 24, 27, .06); color: #71717a; }
.tp-onb-last { font-size: 13px; color: #71717a; margin-top: 2px; }
.tp-onb-last.is-waiting { color: #6b5bb5; } .tp-onb-last.is-answered { color: #1a7f46; } .tp-onb-last.is-unreachable { color: #e03500; } .tp-onb-last.is-refused { color: #d93036; }
.tp-onb-actions { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.tp-onb-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 32px 12px; text-align: center; color: #71717a; }
.tp-onb-empty__i { width: 36px; height: 36px; color: #1f9d55; }
@media (max-width: 640px) {
    .tp-onb-item { grid-template-columns: 28px 1fr; }
    .tp-onb-actions { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; }
    .tp-onb-actions > * { flex: 1 1 auto; }
    .tp-onb-bulk { top: 64px; }
    .tp-onb-search { max-width: none; }
}
