:root {
    --tp-dark: #1F2533;
    --tp-dark-2: #171c27;
    --tp-gold: #ECBA05;
    --tp-gold-soft: #fff6d4;
    --tp-bg: #f6f7f9;
    --tp-card: #ffffff;
    --tp-border: #e8eaf0;
    --tp-text: #1f2533;
    --tp-muted: #747b89;
    --tp-success: #1e8e5a;
    --tp-danger: #d94b4b;
    --tp-radius: 18px;
    --tp-shadow: 0 12px 35px rgba(31, 37, 51, 0.07);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--tp-text);
    background: var(--tp-bg);
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input {
    font: inherit;
}

button {
    cursor: pointer;
}

/* ------------------------------
   Shared
------------------------------ */
.tp-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.tp-brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    background: var(--tp-gold);
    color: var(--tp-dark);
    font-weight: 900;
    box-shadow: 0 8px 24px rgba(236, 186, 5, 0.22);
}

.tp-brand-text small {
    display: block;
    margin-top: 2px;
    color: #aeb4c0;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.tp-btn {
    min-height: 46px;
    border: 0;
    border-radius: 12px;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    font-weight: 700;
    transition: 0.2s ease;
}

.tp-btn-primary {
    background: var(--tp-gold);
    color: var(--tp-dark);
}

.tp-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 9px 22px rgba(236, 186, 5, 0.22);
}

.tp-btn-dark {
    background: var(--tp-dark);
    color: #fff;
}

.tp-btn-dark:hover {
    background: var(--tp-dark-2);
}

.tp-btn-light {
    background: #fff;
    border: 1px solid var(--tp-border);
    color: var(--tp-dark);
}

.tp-btn-light:hover {
    border-color: #d6d9e1;
    background: #fafafa;
}

.tp-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.tp-badge-online {
    color: #805f00;
    background: var(--tp-gold-soft);
}

.tp-badge-inperson {
    color: #2d5c81;
    background: #eaf4fc;
}

.tp-status-upcoming {
    color: #805f00;
    background: var(--tp-gold-soft);
}

.tp-status-scheduled {
    color: #206b4b;
    background: #eaf8f1;
}

/* ------------------------------
   Login page
------------------------------ */
.tp-login-page {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(320px, 0.9fr) minmax(520px, 1.1fr);
    background: #fff;
}

.tp-login-visual {
    position: relative;
    overflow: hidden;
    padding: 48px;
    background: var(--tp-dark);
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.tp-login-visual::before,
.tp-login-visual::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
}

.tp-login-visual::before {
    width: 360px;
    height: 360px;
    right: -120px;
    top: -80px;
    background: rgba(236, 186, 5, 0.13);
}

.tp-login-visual::after {
    width: 220px;
    height: 220px;
    left: -60px;
    bottom: 30px;
    border: 1px solid rgba(255, 255, 255, .12);
}

.tp-login-visual .tp-brand {
    position: relative;
    z-index: 1;
}

.tp-login-copy {
    position: relative;
    z-index: 1;
    max-width: 520px;
}

.tp-login-copy .eyebrow {
    margin: 0 0 15px;
    color: var(--tp-gold);
    font-weight: 800;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.tp-login-copy h1 {
    margin: 0;
    max-width: 500px;
    font-size: clamp(36px, 4.7vw, 64px);
    line-height: 1.05;
    letter-spacing: -0.045em;
}

.tp-login-copy p {
    margin: 22px 0 0;
    max-width: 480px;
    color: #c6cad3;
    font-size: 16px;
    line-height: 1.75;
}

.tp-login-note {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #c6cad3;
    font-size: 13px;
}

.tp-login-note span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--tp-gold);
}

.tp-login-form-side {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 56px 30px;
    background: #fbfbfc;
}

.tp-login-card {
    width: min(100%, 470px);
    background: #fff;
    border: 1px solid var(--tp-border);
    border-radius: 24px;
    padding: 42px;
    box-shadow: var(--tp-shadow);
}

.tp-login-card h2 {
    margin: 0;
    font-size: 31px;
    letter-spacing: -0.035em;
}

.tp-login-card>p {
    margin: 10px 0 30px;
    color: var(--tp-muted);
    line-height: 1.7;
}

.tp-field {
    margin-bottom: 18px;
}

.tp-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 800;
}

.tp-input-wrap {
    position: relative;
}

.tp-input-wrap i {
    position: absolute;
    top: 50%;
    left: 16px;
    transform: translateY(-50%);
    color: #9097a4;
    pointer-events: none;
}

.tp-input-wrap input {
    width: 100%;
    height: 50px;
    border: 1px solid var(--tp-border);
    border-radius: 12px;
    padding: 0 46px 0 44px;
    outline: none;
    color: var(--tp-text);
    background: #fff;
    transition: .2s ease;
}

.tp-input-wrap input:focus {
    border-color: #d8ad10;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .1);
}

.tp-password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 34px;
    height: 34px;
    border: 0;
    background: transparent;
    color: #8c93a0;
    border-radius: 8px;
}

.tp-password-toggle:hover {
    background: #f5f6f8;
    color: var(--tp-dark);
}

.tp-login-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    margin: 3px 0 24px;
    font-size: 13px;
}

.tp-check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--tp-muted);
}

.tp-check input {
    accent-color: var(--tp-gold);
}

.tp-link {
    color: var(--tp-dark);
    font-weight: 800;
}

.tp-link:hover {
    text-decoration: underline;
}

.tp-login-card .tp-btn {
    width: 100%;
}

.tp-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    color: var(--tp-muted);
    font-size: 13px;
}

/* ------------------------------
   Dashboard layout
------------------------------ */
.tp-dashboard-page {
    min-height: 100vh;
    background: var(--tp-bg);
}

.tp-sidebar {
    position: fixed;
    z-index: 40;
    inset: 0 auto 0 0;
    width: 276px;
    background: var(--tp-dark);
    color: #fff;
    padding: 24px 18px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    transition: transform .25s ease;
}

.tp-sidebar-head {
    padding: 0 8px 22px;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.tp-sidebar .tp-brand-text {
    font-size: 15px;
}

.tp-nav {
    padding: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.tp-nav-link {
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 13px;
    border-radius: 11px;
    color: #c8ccd5;
    font-size: 14px;
    font-weight: 650;
    transition: .2s ease;
}

.tp-nav-link i {
    width: 19px;
    text-align: center;
    color: #8f96a5;
}

.tp-nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, .06);
}

.tp-nav-link.active {
    color: var(--tp-dark);
    background: var(--tp-gold);
    font-weight: 800;
}

.tp-nav-link.active i {
    color: var(--tp-dark);
}

.tp-sidebar-footer {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, .08);
}

.tp-user-mini {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 8px;
    margin-bottom: 8px;
}

.tp-avatar {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    background: #fff;
    color: var(--tp-dark);
    font-weight: 900;
}

.tp-user-mini strong {
    display: block;
    font-size: 13px;
}

.tp-user-mini span {
    display: block;
    margin-top: 3px;
    color: #939aa7;
    font-size: 11px;
}

.tp-main {
    margin-left: 276px;
    min-height: 100vh;
}

.tp-topbar {
    position: sticky;
    top: 0;
    z-index: 25;
    height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 0 34px;
    background: rgba(246, 247, 249, .94);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(226, 228, 233, .8);
}

.tp-topbar-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.tp-mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 11px;
    border: 1px solid var(--tp-border);
    background: #fff;
    color: var(--tp-dark);
}

.tp-page-title {
    margin: 0;
    font-size: 20px;
    letter-spacing: -0.02em;
}

.tp-page-subtitle {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 12px;
}

.tp-topbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tp-icon-btn {
    position: relative;
    width: 42px;
    height: 42px;
    border-radius: 11px;
    border: 1px solid var(--tp-border);
    background: #fff;
    color: var(--tp-dark);
}

.tp-icon-btn .dot {
    position: absolute;
    top: 9px;
    right: 9px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--tp-gold);
    box-shadow: 0 0 0 3px #fff;
}

.tp-top-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-left: 6px;
}

.tp-top-profile .tp-avatar {
    width: 40px;
    height: 40px;
    border: 1px solid var(--tp-border);
    background: #fff;
}

.tp-top-profile strong {
    display: block;
    font-size: 13px;
}

.tp-top-profile span {
    display: block;
    margin-top: 2px;
    color: var(--tp-muted);
    font-size: 11px;
}

.tp-content {
    padding: 34px;
}

.tp-welcome {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 26px;
}

.tp-welcome h1 {
    margin: 0;
    font-size: clamp(27px, 3vw, 36px);
    letter-spacing: -0.04em;
}

.tp-welcome p {
    margin: 9px 0 0;
    color: var(--tp-muted);
    line-height: 1.6;
}

.tp-date-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 11px;
    background: #fff;
    border: 1px solid var(--tp-border);
    color: var(--tp-muted);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.tp-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 26px;
}

.tp-stat-card {
    background: var(--tp-card);
    border: 1px solid var(--tp-border);
    border-radius: var(--tp-radius);
    padding: 22px;
    box-shadow: 0 5px 20px rgba(31, 37, 51, .035);
}

.tp-stat-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
}

.tp-stat-icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    background: var(--tp-gold-soft);
    color: #8f6900;
}

.tp-stat-card .label {
    color: var(--tp-muted);
    font-size: 13px;
    font-weight: 700;
}

.tp-stat-number {
    margin: 0;
    font-size: 34px;
    line-height: 1;
    letter-spacing: -0.045em;
}

.tp-stat-foot {
    margin-top: 10px;
    color: var(--tp-muted);
    font-size: 11px;
}

.tp-section-card {
    background: #fff;
    border: 1px solid var(--tp-border);
    border-radius: var(--tp-radius);
    box-shadow: 0 5px 20px rgba(31, 37, 51, .035);
    overflow: hidden;
}

.tp-section-head {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 18px 22px;
    border-bottom: 1px solid var(--tp-border);
}

.tp-section-head h2 {
    margin: 0;
    font-size: 18px;
    letter-spacing: -0.025em;
}

.tp-section-head p {
    margin: 5px 0 0;
    color: var(--tp-muted);
    font-size: 12px;
}

.tp-table-wrap {
    overflow-x: auto;
}

.tp-table {
    width: 100%;
    min-width: 900px;
    border-collapse: collapse;
}

.tp-table th,
.tp-table td {
    padding: 16px 18px;
    border-bottom: 1px solid var(--tp-border);
    text-align: left;
    vertical-align: middle;
}

.tp-table th {
    background: #fafbfc;
    color: var(--tp-muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.tp-table td {
    font-size: 13px;
}

.tp-table tbody tr:last-child td {
    border-bottom: 0;
}

.tp-table tbody tr:hover {
    background: #fffdfa;
}

.tp-class-name {
    font-weight: 800;
}

.tp-class-course {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 11px;
}

.tp-actions {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-wrap: wrap;
}

.tp-action-btn {
    min-height: 32px;
    border: 1px solid var(--tp-border);
    border-radius: 8px;
    padding: 0 10px;
    background: #fff;
    color: var(--tp-dark);
    font-size: 11px;
    font-weight: 800;
}

.tp-action-btn:hover {
    border-color: #d5a90a;
    background: var(--tp-gold-soft);
}

.tp-action-btn.primary {
    border-color: var(--tp-dark);
    background: var(--tp-dark);
    color: #fff;
}

.tp-action-btn.primary:hover {
    background: var(--tp-dark-2);
}

.tp-quick-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.tp-quick-card {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 17px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: #fff;
    transition: .2s ease;
}

.tp-quick-card:hover {
    transform: translateY(-2px);
    border-color: #e2bb2f;
    box-shadow: 0 9px 22px rgba(31, 37, 51, .05);
}

.tp-quick-card .icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #8b6800;
    background: var(--tp-gold-soft);
}

.tp-quick-card strong {
    display: block;
    font-size: 13px;
}

.tp-quick-card span {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 11px;
}

.tp-overlay {
    position: fixed;
    z-index: 35;
    inset: 0;
    display: none;
    background: rgba(20, 24, 32, .46);
}

body.tp-menu-open {
    overflow: hidden;
}

body.tp-menu-open .tp-overlay {
    display: block;
}

/* ------------------------------
   Responsive
------------------------------ */
@media (max-width: 1199px) {
    .tp-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 991px) {
    .tp-login-page {
        grid-template-columns: 1fr;
    }

    .tp-login-visual {
        min-height: 340px;
        padding: 36px 28px;
    }

    .tp-login-copy h1 {
        font-size: 42px;
    }

    .tp-login-note {
        display: none;
    }

    .tp-login-form-side {
        min-height: auto;
        padding: 36px 20px 50px;
    }

    .tp-sidebar {
        transform: translateX(-100%);
        box-shadow: 12px 0 35px rgba(0, 0, 0, .12);
    }

    body.tp-menu-open .tp-sidebar {
        transform: translateX(0);
    }

    .tp-main {
        margin-left: 0;
    }

    .tp-mobile-toggle {
        display: inline-grid;
        place-items: center;
    }

    .tp-topbar {
        padding: 0 20px;
    }

    .tp-content {
        padding: 26px 20px;
    }
}

@media (max-width: 767px) {
    .tp-login-visual {
        min-height: 300px;
    }

    .tp-login-copy h1 {
        font-size: 36px;
    }

    .tp-login-card {
        padding: 30px 22px;
        border-radius: 18px;
    }

    .tp-top-profile>div:not(.tp-avatar) {
        display: none;
    }

    .tp-welcome {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-stat-grid {
        grid-template-columns: 1fr;
    }

    .tp-quick-grid {
        grid-template-columns: 1fr;
    }

    .tp-section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-content {
        padding: 22px 15px 30px;
    }

    .tp-page-subtitle {
        display: none;
    }
}

@media (max-width: 520px) {
    .tp-login-visual {
        min-height: 250px;
        padding: 28px 20px;
    }

    .tp-login-copy p {
        font-size: 14px;
    }

    .tp-login-options {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-topbar {
        height: 68px;
        padding: 0 14px;
    }

    .tp-page-title {
        font-size: 17px;
    }
}


/* =========================================================
   My Classes + Class Details
   ========================================================= */
.tp-page-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.tp-page-head h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 34px);
    letter-spacing: -0.04em;
}

.tp-page-head p {
    margin: 8px 0 0;
    color: var(--tp-muted);
    line-height: 1.6;
    font-size: 14px;
}

.tp-page-head-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.tp-filterbar {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 190px 190px auto;
    gap: 12px;
    padding: 16px;
    margin-bottom: 18px;
    background: #fff;
    border: 1px solid var(--tp-border);
    border-radius: 16px;
    box-shadow: 0 5px 20px rgba(31, 37, 51, .025);
}

.tp-search-box,
.tp-select-wrap {
    position: relative;
}

.tp-search-box i,
.tp-select-wrap i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9299a6;
    pointer-events: none;
    font-size: 13px;
}

.tp-search-box input,
.tp-select-wrap select {
    width: 100%;
    height: 44px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--tp-text);
    outline: none;
    padding: 0 14px 0 40px;
    font-size: 13px;
}

.tp-search-box input:focus,
.tp-select-wrap select:focus {
    border-color: #d5ad1b;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .08);
}

.tp-select-wrap select {
    appearance: none;
    padding-right: 34px;
}

.tp-filter-reset {
    min-height: 44px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--tp-muted);
    padding: 0 14px;
    font-size: 12px;
    font-weight: 800;
}

.tp-filter-reset:hover {
    color: var(--tp-dark);
    border-color: #d8dbe2;
}

.tp-results-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 12px;
    color: var(--tp-muted);
    font-size: 12px;
}

.tp-results-line strong {
    color: var(--tp-dark);
}

.tp-class-link {
    color: var(--tp-dark);
    font-weight: 850;
}

.tp-class-link:hover {
    color: #8c6900;
}

.tp-action-link {
    min-height: 33px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: 1px solid var(--tp-border);
    border-radius: 8px;
    padding: 0 10px;
    background: #fff;
    color: var(--tp-dark);
    font-size: 11px;
    font-weight: 800;
    transition: .2s ease;
}

.tp-action-link:hover {
    border-color: #d5a90a;
    background: var(--tp-gold-soft);
}

.tp-action-link.primary {
    border-color: var(--tp-dark);
    background: var(--tp-dark);
    color: #fff;
}

.tp-action-link.primary:hover {
    background: var(--tp-dark-2);
}

.tp-status-active {
    color: #206b4b;
    background: #eaf8f1;
}

.tp-status-completed {
    color: #5e6572;
    background: #f0f1f3;
}

.tp-class-cards {
    display: none;
    gap: 12px;
}

.tp-class-card {
    display: block;
    padding: 18px;
    background: #fff;
    border: 1px solid var(--tp-border);
    border-radius: 16px;
    box-shadow: 0 5px 20px rgba(31, 37, 51, .03);
}

.tp-class-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 15px;
}

.tp-class-card h3 {
    margin: 0;
    font-size: 16px;
    letter-spacing: -0.025em;
}

.tp-class-card .course {
    display: block;
    margin-top: 5px;
    color: var(--tp-muted);
    font-size: 12px;
}

.tp-class-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.tp-class-card-grid div {
    padding: 11px;
    border-radius: 11px;
    background: #fafbfc;
}

.tp-class-card-grid span {
    display: block;
    margin-bottom: 5px;
    color: var(--tp-muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.tp-class-card-grid strong {
    font-size: 12px;
}

.tp-class-card-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tp-empty-state {
    display: none;
    padding: 44px 22px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--tp-border);
    border-radius: 16px;
}

.tp-empty-state i {
    width: 54px;
    height: 54px;
    display: inline-grid;
    place-items: center;
    border-radius: 16px;
    background: var(--tp-gold-soft);
    color: #8b6800;
    margin-bottom: 13px;
}

.tp-empty-state h3 {
    margin: 0;
    font-size: 18px;
}

.tp-empty-state p {
    margin: 8px auto 0;
    max-width: 420px;
    color: var(--tp-muted);
    font-size: 13px;
    line-height: 1.7;
}

/* Class details */
.tp-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    color: var(--tp-muted);
    font-size: 12px;
}

.tp-breadcrumb a {
    font-weight: 800;
    color: var(--tp-dark);
}

.tp-breadcrumb a:hover {
    color: #8b6800;
}

.tp-class-hero {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 22px;
    padding: 24px;
    margin-bottom: 18px;
    border-radius: 18px;
    background: var(--tp-dark);
    color: #fff;
    overflow: hidden;
    position: relative;
}

.tp-class-hero::after {
    content: "";
    position: absolute;
    width: 240px;
    height: 240px;
    right: -90px;
    top: -100px;
    border-radius: 50%;
    background: rgba(236, 186, 5, .12);
}

.tp-class-hero>* {
    position: relative;
    z-index: 1;
}

.tp-class-hero .eyebrow {
    color: var(--tp-gold);
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.tp-class-hero h2 {
    margin: 7px 0 0;
    font-size: clamp(25px, 3vw, 36px);
    letter-spacing: -0.04em;
}

.tp-class-hero p {
    margin: 9px 0 0;
    max-width: 640px;
    color: #c9ced8;
    font-size: 13px;
    line-height: 1.7;
}

.tp-class-hero-badges {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.tp-class-hero-actions {
    display: flex;
    gap: 9px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.tp-class-hero .tp-btn-light {
    background: #fff;
}

.tp-info-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    margin-bottom: 18px;
    background: var(--tp-border);
    border: 1px solid var(--tp-border);
    border-radius: 16px;
    overflow: hidden;
}

.tp-info-item {
    min-height: 92px;
    padding: 17px;
    background: #fff;
}

.tp-info-item span {
    display: block;
    margin-bottom: 8px;
    color: var(--tp-muted);
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.tp-info-item strong {
    display: block;
    font-size: 13px;
    line-height: 1.45;
}

.tp-tabs-wrap {
    position: sticky;
    top: 78px;
    z-index: 18;
    margin-bottom: 18px;
    padding: 8px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: rgba(255, 255, 255, .96);
    backdrop-filter: blur(12px);
    overflow-x: auto;
}

.tp-tabs {
    display: flex;
    gap: 6px;
    min-width: max-content;
}

.tp-tab-btn {
    min-height: 38px;
    border: 0;
    border-radius: 9px;
    padding: 0 13px;
    background: transparent;
    color: var(--tp-muted);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}

.tp-tab-btn:hover {
    color: var(--tp-dark);
    background: #f6f7f9;
}

.tp-tab-btn.active {
    color: var(--tp-dark);
    background: var(--tp-gold);
}

.tp-tab-panel {
    display: none;
}

.tp-tab-panel.active {
    display: block;
}

.tp-detail-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
    gap: 18px;
}

.tp-detail-stack {
    display: grid;
    gap: 18px;
}

.tp-card-body {
    padding: 20px 22px;
}

.tp-card-body p {
    margin: 0;
    color: var(--tp-muted);
    font-size: 13px;
    line-height: 1.75;
}

.tp-overview-list {
    display: grid;
    gap: 10px;
    margin-top: 16px;
}

.tp-overview-row {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    padding: 12px;
    border: 1px solid var(--tp-border);
    border-radius: 12px;
}

.tp-overview-row i {
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 10px;
    color: #8b6800;
    background: var(--tp-gold-soft);
}

.tp-overview-row strong {
    display: block;
    font-size: 12px;
}

.tp-overview-row span {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 11px;
    line-height: 1.55;
}

.tp-quick-action-list {
    display: grid;
    gap: 9px;
}

.tp-quick-action-list a {
    min-height: 45px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 13px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    font-size: 12px;
    font-weight: 800;
}

.tp-quick-action-list a:hover {
    border-color: #d5a90a;
    background: var(--tp-gold-soft);
}

.tp-student-cell {
    display: flex;
    align-items: center;
    gap: 9px;
}

.tp-student-avatar {
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #f1f2f5;
    color: var(--tp-dark);
    font-size: 10px;
    font-weight: 900;
}

.tp-progress {
    min-width: 110px;
}

.tp-progress-track {
    height: 6px;
    overflow: hidden;
    border-radius: 999px;
    background: #eef0f3;
}

.tp-progress-bar {
    height: 100%;
    border-radius: inherit;
    background: var(--tp-gold);
}

.tp-progress small {
    display: block;
    margin-top: 5px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-note {
    padding: 13px 14px;
    border-radius: 11px;
    background: #fff9e8;
    color: #715600;
    font-size: 12px;
    line-height: 1.65;
}

.tp-placeholder {
    padding: 38px 22px;
    text-align: center;
}

.tp-placeholder i {
    width: 54px;
    height: 54px;
    display: inline-grid;
    place-items: center;
    margin-bottom: 12px;
    border-radius: 16px;
    background: var(--tp-gold-soft);
    color: #8b6800;
}

.tp-placeholder h3 {
    margin: 0;
    font-size: 17px;
}

.tp-placeholder p {
    margin: 7px auto 0;
    max-width: 520px;
    color: var(--tp-muted);
    font-size: 12px;
    line-height: 1.7;
}

.tp-feedback-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    padding: 20px 22px;
}

.tp-feedback-form .tp-field {
    margin: 0;
}

.tp-feedback-form .full {
    grid-column: 1 / -1;
}

.tp-feedback-form select,
.tp-feedback-form input,
.tp-feedback-form textarea {
    width: 100%;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--tp-text);
    outline: none;
    padding: 0 13px;
}

.tp-feedback-form select,
.tp-feedback-form input {
    height: 44px;
}

.tp-feedback-form textarea {
    min-height: 110px;
    padding-top: 12px;
    resize: vertical;
}

.tp-feedback-form select:focus,
.tp-feedback-form input:focus,
.tp-feedback-form textarea:focus {
    border-color: #d5ad1b;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .08);
}

.tp-online-card {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 22px;
}

.tp-online-card h3 {
    margin: 0;
    font-size: 18px;
}

.tp-online-card p {
    margin: 7px 0 0;
    color: var(--tp-muted);
    font-size: 12px;
    line-height: 1.65;
}

@media (max-width: 1199px) {
    .tp-filterbar {
        grid-template-columns: 1fr 170px 170px;
    }

    .tp-filter-reset {
        grid-column: 1 / -1;
    }

    .tp-info-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tp-detail-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767px) {
    .tp-page-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-filterbar {
        grid-template-columns: 1fr;
    }

    .tp-filter-reset {
        grid-column: auto;
    }

    .tp-desktop-classes {
        display: none;
    }

    .tp-class-cards {
        display: grid;
    }

    .tp-info-grid {
        grid-template-columns: 1fr;
    }

    .tp-class-hero {
        flex-direction: column;
    }

    .tp-class-hero-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .tp-tabs-wrap {
        top: 68px;
    }

    .tp-feedback-form {
        grid-template-columns: 1fr;
    }

    .tp-feedback-form .full {
        grid-column: auto;
    }

    .tp-online-card {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .tp-class-card-grid {
        grid-template-columns: 1fr;
    }

    .tp-class-hero-actions .tp-btn {
        width: 100%;
    }
}


/* =========================================================
   Attendance + Grades
   ========================================================= */

.tp-context-card {
    margin-bottom: 18px;
    overflow: hidden;
}

.tp-context-grid {
    display: grid;
    grid-template-columns: minmax(220px, 1.15fr) minmax(220px, 1.15fr) minmax(160px, .7fr);
    gap: 14px;
    padding: 18px 20px 20px;
}

.tp-context-field label,
.tp-inline-field label {
    display: block;
    margin-bottom: 7px;
    color: var(--tp-muted);
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.tp-context-field select,
.tp-context-field input,
.tp-inline-field select,
.tp-inline-field input,
.tp-row-note,
.tp-grade-note {
    width: 100%;
    height: 44px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--tp-text);
    outline: none;
    padding: 0 13px;
    transition: .2s ease;
}

.tp-context-field select:focus,
.tp-context-field input:focus,
.tp-inline-field select:focus,
.tp-inline-field input:focus,
.tp-row-note:focus,
.tp-grade-note:focus {
    border-color: #d5ad1b;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .08);
}

.tp-context-field input[readonly] {
    background: #f8f9fb;
    color: #5f6673;
}

.tp-context-hint {
    display: block;
    margin-top: 6px;
    color: var(--tp-muted);
    font-size: 10px;
    line-height: 1.5;
}

.tp-page-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.tp-page-toolbar-left,
.tp-page-toolbar-right {
    display: flex;
    align-items: center;
    gap: 9px;
    flex-wrap: wrap;
}

.tp-mini-action {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 1px solid var(--tp-border);
    border-radius: 10px;
    background: #fff;
    color: var(--tp-dark);
    padding: 0 12px;
    font-size: 11px;
    font-weight: 800;
}

.tp-mini-action:hover {
    border-color: #d5ad1b;
    background: var(--tp-gold-soft);
}

.tp-mini-action.danger:hover {
    border-color: #efcaca;
    background: #fff1f1;
    color: #b53a3a;
}

.tp-summary-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}

.tp-summary-chip {
    min-height: 76px;
    padding: 14px 15px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: #fff;
}

.tp-summary-chip span {
    display: block;
    margin-bottom: 6px;
    color: var(--tp-muted);
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.tp-summary-chip strong {
    font-size: 23px;
    letter-spacing: -.04em;
}

.tp-summary-chip.present strong {
    color: #1e8e5a;
}

.tp-summary-chip.late strong {
    color: #9a7200;
}

.tp-summary-chip.absent strong {
    color: #c64646;
}

.tp-summary-chip.excused strong {
    color: #52627a;
}

.tp-attendance-table td {
    vertical-align: middle;
}

.tp-attendance-table th:not(:first-child),
.tp-attendance-table td:not(:first-child) {
    text-align: center;
}

.tp-attendance-student {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 165px;
}

.tp-attendance-student .tp-student-avatar {
    border-radius: 999px;
}

.tp-attendance-student strong {
    display: block;
    font-size: 12px;
}

.tp-attendance-student small {
    display: block;
    margin-top: 3px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-attendance-option {
    display: inline-flex;
    position: relative;
}

.tp-attendance-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.tp-attendance-option span {
    min-width: 38px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--tp-border);
    border-radius: 9px;
    background: #fff;
    color: #8a909c;
    font-size: 12px;
    font-weight: 900;
    transition: .18s ease;
    cursor: pointer;
}

.tp-attendance-option:hover span {
    border-color: #d7d9df;
    background: #fafafa;
}

.tp-attendance-option input:checked+span {
    color: var(--tp-dark);
    border-color: var(--tp-gold);
    background: var(--tp-gold);
    box-shadow: 0 5px 16px rgba(236, 186, 5, .18);
}

.tp-attendance-option[data-status="absent"] input:checked+span {
    color: #a93434;
    border-color: #f0c1c1;
    background: #fff0f0;
    box-shadow: none;
}

.tp-attendance-option[data-status="excused"] input:checked+span {
    color: #4e607b;
    border-color: #d5dce7;
    background: #f0f4f9;
    box-shadow: none;
}

.tp-attendance-option[data-status="late"] input:checked+span {
    color: #795c00;
    border-color: #ead488;
    background: #fff7dc;
    box-shadow: none;
}

.tp-row-note {
    min-width: 210px;
    height: 38px;
    font-size: 11px;
}

.tp-save-bar {
    position: sticky;
    bottom: 14px;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
    padding: 14px 16px;
    border: 1px solid var(--tp-border);
    border-radius: 15px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 12px 35px rgba(31, 37, 51, .10);
    backdrop-filter: blur(12px);
}

.tp-save-bar p {
    margin: 0;
    color: var(--tp-muted);
    font-size: 11px;
    line-height: 1.5;
}

.tp-save-bar p strong {
    color: var(--tp-dark);
}

.tp-save-actions {
    display: flex;
    align-items: center;
    gap: 9px;
    flex-wrap: wrap;
}

/* Mobile attendance cards */
.tp-attendance-cards {
    display: none;
    gap: 12px;
}

.tp-attendance-card {
    padding: 16px;
    border: 1px solid var(--tp-border);
    border-radius: 15px;
    background: #fff;
}

.tp-attendance-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.tp-attendance-card-options {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 7px;
    margin-bottom: 10px;
}

.tp-attendance-card-options .tp-attendance-option,
.tp-attendance-card-options .tp-attendance-option span {
    width: 100%;
}

.tp-attendance-card-options .tp-attendance-option span {
    min-width: 0;
}

/* Grades */
.tp-assessment-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}

.tp-assessment-card {
    min-height: 82px;
    padding: 14px 15px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: #fff;
}

.tp-assessment-card span {
    display: block;
    margin-bottom: 7px;
    color: var(--tp-muted);
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.tp-assessment-card strong {
    font-size: 20px;
    letter-spacing: -.035em;
}

.tp-grade-score-wrap {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tp-grade-score {
    width: 82px;
    height: 38px;
    border: 1px solid var(--tp-border);
    border-radius: 9px;
    outline: none;
    text-align: center;
    font-weight: 800;
}

.tp-grade-score:focus {
    border-color: #d5ad1b;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .08);
}

.tp-grade-score.is-invalid {
    border-color: #e29a9a;
    background: #fff5f5;
}

.tp-grade-max {
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-grade-letter {
    min-width: 38px;
    height: 30px;
    display: inline-grid;
    place-items: center;
    border-radius: 8px;
    background: var(--tp-gold-soft);
    color: #7b5d00;
    font-size: 12px;
    font-weight: 900;
}

.tp-grade-letter.empty {
    background: #f1f2f5;
    color: #8c929d;
}

.tp-grade-note {
    min-width: 230px;
    height: 38px;
    font-size: 11px;
}

.tp-grade-status {
    min-width: 74px;
    justify-content: center;
}

.tp-grade-status.draft {
    color: #5f6673;
    background: #f0f1f3;
}

.tp-grade-status.ready {
    color: #206b4b;
    background: #eaf8f1;
}

.tp-grade-status.error {
    color: #aa3737;
    background: #fff0f0;
}

.tp-grade-help {
    margin-top: 5px;
    color: #b44242;
    font-size: 9px;
    display: none;
}

.tp-grade-help.show {
    display: block;
}

.tp-grades-table td {
    vertical-align: middle;
}

.tp-grade-cards {
    display: none;
    gap: 12px;
}

.tp-grade-card {
    padding: 16px;
    border: 1px solid var(--tp-border);
    border-radius: 15px;
    background: #fff;
}

.tp-grade-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.tp-grade-card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 12px;
}

.tp-grade-card-grid .tp-inline-field:last-child {
    grid-column: 1 / -1;
}

.tp-grade-card .tp-grade-score {
    width: 100%;
}

.tp-grade-card .tp-grade-note {
    min-width: 0;
}

.tp-save-feedback {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #1e8e5a;
    font-size: 11px;
    font-weight: 800;
    opacity: 0;
    transform: translateY(2px);
    transition: .2s ease;
}

.tp-save-feedback.show {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1199px) {
    .tp-context-grid {
        grid-template-columns: 1fr 1fr;
    }

    .tp-context-field:last-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 767px) {
    .tp-context-grid {
        grid-template-columns: 1fr;
    }

    .tp-context-field:last-child {
        grid-column: auto;
    }

    .tp-summary-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tp-assessment-summary {
        grid-template-columns: 1fr;
    }

    .tp-page-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-attendance-desktop,
    .tp-grades-desktop {
        display: none;
    }

    .tp-attendance-cards,
    .tp-grade-cards {
        display: grid;
    }

    .tp-save-bar {
        align-items: stretch;
        flex-direction: column;
        bottom: 8px;
    }

    .tp-save-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .tp-save-actions .tp-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .tp-attendance-card-options {
        grid-template-columns: repeat(2, 1fr);
    }

    .tp-grade-card-grid {
        grid-template-columns: 1fr;
    }

    .tp-grade-card-grid .tp-inline-field:last-child {
        grid-column: auto;
    }

    .tp-save-actions {
        grid-template-columns: 1fr;
    }
}


/* =========================================================
   Student Records + Teaching Plan + Schedule
   ========================================================= */

/* Shared filter / toolbar helpers */
.tp-filter-row {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 190px 190px auto;
    gap: 12px;
    padding: 16px;
    margin-bottom: 16px;
    border: 1px solid var(--tp-border);
    border-radius: 16px;
    background: #fff;
}

.tp-filter-row .tp-search-box,
.tp-filter-row .tp-select-wrap {
    margin: 0;
}

.tp-filter-row .tp-filter-reset {
    min-height: 44px;
}

.tp-table-subtext {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 10px;
    line-height: 1.4;
}

/* Student Records */
.tp-record-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
}

.tp-record-detail {
    display: none;
    overflow: hidden;
    border: 1px solid var(--tp-border);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 35px rgba(31, 37, 51, .05);
}

.tp-record-detail.active {
    display: block;
}

.tp-record-detail-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px;
    border-bottom: 1px solid var(--tp-border);
    background: linear-gradient(135deg, #fff, #fbfbfc);
}

.tp-record-person {
    display: flex;
    align-items: center;
    gap: 13px;
}

.tp-record-avatar {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 16px;
    background: var(--tp-dark);
    color: #fff;
    font-size: 15px;
    font-weight: 900;
}

.tp-record-person h3 {
    margin: 0;
    font-size: 18px;
    letter-spacing: -.025em;
}

.tp-record-person p {
    margin: 5px 0 0;
    color: var(--tp-muted);
    font-size: 11px;
}

.tp-record-close {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid var(--tp-border);
    border-radius: 10px;
    background: #fff;
    color: var(--tp-dark);
}

.tp-record-close:hover {
    background: #f5f6f8;
}

.tp-record-tabs-wrap {
    padding: 10px 14px 0;
    overflow-x: auto;
}

.tp-record-tabs {
    display: flex;
    gap: 6px;
    min-width: max-content;
}

.tp-record-tab {
    min-height: 38px;
    border: 0;
    border-radius: 9px;
    padding: 0 12px;
    background: transparent;
    color: var(--tp-muted);
    font-size: 11px;
    font-weight: 800;
}

.tp-record-tab.active {
    background: var(--tp-gold);
    color: var(--tp-dark);
}

.tp-record-panel {
    display: none;
    padding: 20px 22px 24px;
}

.tp-record-panel.active {
    display: block;
}

.tp-record-info-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.tp-record-info-item {
    padding: 13px 14px;
    border: 1px solid var(--tp-border);
    border-radius: 12px;
    background: #fff;
}

.tp-record-info-item span {
    display: block;
    margin-bottom: 6px;
    color: var(--tp-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.tp-record-info-item strong {
    font-size: 12px;
    line-height: 1.45;
}

.tp-timeline {
    display: grid;
    gap: 10px;
}

.tp-timeline-item {
    display: grid;
    grid-template-columns: 110px 1fr auto;
    gap: 14px;
    align-items: center;
    padding: 13px 14px;
    border: 1px solid var(--tp-border);
    border-radius: 12px;
}

.tp-timeline-item time {
    color: var(--tp-muted);
    font-size: 10px;
    font-weight: 800;
}

.tp-timeline-item strong {
    display: block;
    font-size: 12px;
}

.tp-timeline-item small {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-progress-lg {
    display: grid;
    gap: 12px;
}

.tp-progress-lg-item {
    padding: 14px;
    border: 1px solid var(--tp-border);
    border-radius: 12px;
}

.tp-progress-lg-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 9px;
}

.tp-progress-lg-head strong {
    font-size: 12px;
}

.tp-progress-lg-head span {
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-progress-lg .tp-progress-track {
    height: 8px;
}

.tp-record-cards {
    display: none;
    gap: 12px;
}

.tp-record-card {
    padding: 16px;
    border: 1px solid var(--tp-border);
    border-radius: 15px;
    background: #fff;
}

.tp-record-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.tp-record-card h3 {
    margin: 0;
    font-size: 15px;
}

.tp-record-card small {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-record-card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
    margin-bottom: 14px;
}

.tp-record-card-grid div {
    padding: 10px;
    border-radius: 10px;
    background: #f8f9fb;
}

.tp-record-card-grid span {
    display: block;
    margin-bottom: 5px;
    color: var(--tp-muted);
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
}

.tp-record-card-grid strong {
    font-size: 11px;
}

/* Teaching Plan */
.tp-plan-context {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(220px, 1fr) auto;
    gap: 14px;
    padding: 18px 20px;
}

.tp-plan-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.tp-plan-week {
    font-weight: 900;
    color: var(--tp-dark);
}

.tp-plan-table td {
    vertical-align: top;
}

.tp-plan-table .tp-plan-topic {
    min-width: 150px;
}

.tp-plan-table .tp-plan-topic strong {
    display: block;
    font-size: 12px;
}

.tp-plan-table .tp-plan-topic small {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-plan-table .tp-plan-cell {
    min-width: 140px;
    line-height: 1.6;
    font-size: 11px;
}

.tp-plan-cards {
    display: none;
    gap: 12px;
}

.tp-plan-card {
    overflow: hidden;
    border: 1px solid var(--tp-border);
    border-radius: 15px;
    background: #fff;
}

.tp-plan-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 15px;
    border-bottom: 1px solid var(--tp-border);
    background: #fafbfc;
}

.tp-plan-card-head h3 {
    margin: 0;
    font-size: 14px;
}

.tp-plan-card-body {
    display: grid;
    gap: 10px;
    padding: 14px 15px;
}

.tp-plan-card-row {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 10px;
    font-size: 11px;
}

.tp-plan-card-row span {
    color: var(--tp-muted);
    font-weight: 800;
}

.tp-plan-card-row strong {
    line-height: 1.55;
}

/* Schedule */
.tp-schedule-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.tp-schedule-summary-card {
    padding: 14px 15px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: #fff;
}

.tp-schedule-summary-card span {
    display: block;
    margin-bottom: 6px;
    color: var(--tp-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.tp-schedule-summary-card strong {
    font-size: 21px;
}

.tp-schedule-row-date {
    white-space: nowrap;
    font-weight: 850;
}

.tp-schedule-time {
    white-space: nowrap;
}

.tp-location-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 29px;
    border-radius: 8px;
    padding: 0 9px;
    background: #f4f5f7;
    color: #59616f;
    font-size: 10px;
    font-weight: 800;
}

.tp-location-chip.online {
    background: #eef4ff;
    color: #355c9b;
}

.tp-schedule-cards {
    display: none;
    gap: 12px;
}

.tp-schedule-card {
    padding: 16px;
    border: 1px solid var(--tp-border);
    border-radius: 15px;
    background: #fff;
}

.tp-schedule-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.tp-schedule-card h3 {
    margin: 0;
    font-size: 15px;
}

.tp-schedule-card .course {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-schedule-card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
    margin-bottom: 14px;
}

.tp-schedule-card-grid div {
    padding: 10px;
    border-radius: 10px;
    background: #f8f9fb;
}

.tp-schedule-card-grid span {
    display: block;
    margin-bottom: 4px;
    color: var(--tp-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.tp-schedule-card-grid strong {
    font-size: 11px;
    line-height: 1.4;
}

@media (max-width: 1199px) {
    .tp-filter-row {
        grid-template-columns: 1fr 170px 170px;
    }

    .tp-filter-row .tp-filter-reset {
        grid-column: 1 / -1;
    }

    .tp-record-info-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tp-plan-context {
        grid-template-columns: 1fr 1fr;
    }

    .tp-plan-context>*:last-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 767px) {
    .tp-filter-row {
        grid-template-columns: 1fr;
    }

    .tp-filter-row .tp-filter-reset {
        grid-column: auto;
    }

    .tp-records-desktop,
    .tp-plan-desktop,
    .tp-schedule-desktop {
        display: none;
    }

    .tp-record-cards,
    .tp-plan-cards,
    .tp-schedule-cards {
        display: grid;
    }

    .tp-record-info-grid {
        grid-template-columns: 1fr;
    }

    .tp-timeline-item {
        grid-template-columns: 1fr;
    }

    .tp-record-detail-head {
        align-items: flex-start;
    }

    .tp-plan-context {
        grid-template-columns: 1fr;
    }

    .tp-plan-context>*:last-child {
        grid-column: auto;
    }

    .tp-schedule-summary {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {

    .tp-record-card-grid,
    .tp-schedule-card-grid {
        grid-template-columns: 1fr;
    }

    .tp-plan-card-row {
        grid-template-columns: 1fr;
    }
}

/* APPEND TO teacher-panel.css */
.tp-comms-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px
}

.tp-comms-stat {
    padding: 14px 15px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: #fff
}

.tp-comms-stat span {
    display: block;
    margin-bottom: 6px;
    color: var(--tp-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .05em
}

.tp-comms-stat strong {
    font-size: 22px
}

.tp-comms-stat.warning strong {
    color: #9a7200
}

.tp-platform-chip,
.tp-link-state {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 29px;
    padding: 0 9px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 800
}

.tp-platform-chip {
    background: #f3f4f7;
    color: #505866
}

.tp-platform-chip.zoom {
    background: #edf4ff;
    color: #3561a7
}

.tp-platform-chip.meet {
    background: #eef8f0;
    color: #2b6d45
}

.tp-platform-chip.teams {
    background: #f1efff;
    color: #5d4bb0
}

.tp-link-state.active {
    background: #eaf8f1;
    color: #206b4b
}

.tp-link-state.missing,
.tp-status-missing {
    background: #fff0f0;
    color: #b13a3a
}

.tp-side-panel {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none
}

.tp-side-panel.active {
    display: block
}

.tp-side-panel-overlay {
    position: absolute;
    inset: 0;
    background: rgba(17, 21, 29, .38)
}

.tp-side-panel-card {
    position: absolute;
    top: 0;
    right: 0;
    width: min(440px, 92vw);
    height: 100%;
    background: #fff;
    box-shadow: -20px 0 50px rgba(31, 37, 51, .15);
    display: flex;
    flex-direction: column
}

.tp-side-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 15px;
    padding: 20px;
    border-bottom: 1px solid var(--tp-border)
}

.tp-side-panel-head h3 {
    margin: 0;
    font-size: 18px
}

.tp-side-panel-head p {
    margin: 5px 0 0;
    color: var(--tp-muted);
    font-size: 11px
}

.tp-side-panel-body {
    display: grid;
    gap: 14px;
    padding: 20px;
    overflow: auto
}

.tp-side-panel-body input,
.tp-side-panel-body select {
    width: 100%;
    height: 44px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    padding: 0 13px;
    background: #fff
}

.tp-side-panel-footer {
    margin-top: auto;
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    padding: 15px 20px;
    border-top: 1px solid var(--tp-border);
    background: #fafbfc
}

.tp-optional {
    color: var(--tp-muted);
    font-weight: 500
}

.tp-modal-lite {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    place-items: center;
    padding: 20px
}

.tp-modal-lite.active {
    display: grid
}

.tp-modal-lite-overlay {
    position: absolute;
    inset: 0;
    background: rgba(17, 21, 29, .42)
}

.tp-modal-lite-card {
    position: relative;
    z-index: 1;
    width: min(600px, 94vw);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 24px 65px rgba(31, 37, 51, .18)
}

.tp-modal-lite-body {
    padding: 20px
}

.tp-modal-lite-body p {
    font-size: 13px;
    line-height: 1.8
}

.tp-ann-author {
    font-size: 10px;
    color: var(--tp-muted)
}

.tp-discussion-detail {
    display: none;
    margin-top: 18px;
    border: 1px solid var(--tp-border);
    border-radius: 18px;
    background: #fff;
    overflow: hidden
}

.tp-discussion-detail.active {
    display: block
}

.tp-discussion-detail-head {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    padding: 20px 22px;
    border-bottom: 1px solid var(--tp-border)
}

.tp-discussion-detail-head h3 {
    margin: 9px 0 0;
    font-size: 18px
}

.tp-discussion-detail-head p {
    margin: 5px 0 0;
    color: var(--tp-muted);
    font-size: 11px
}

.tp-discussion-question {
    padding: 20px 22px;
    background: #fafbfc;
    border-bottom: 1px solid var(--tp-border)
}

.tp-discussion-question span {
    display: block;
    margin-bottom: 8px;
    color: var(--tp-muted);
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase
}

.tp-discussion-question p {
    margin: 0;
    font-size: 13px;
    line-height: 1.75
}

.tp-discussion-reply {
    padding: 20px 22px
}

.tp-discussion-reply textarea {
    width: 100%;
    min-height: 130px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    padding: 12px 13px;
    resize: vertical
}

.tp-discussion-form-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px
}

.tp-file-upload {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 11px;
    border: 1px solid var(--tp-border);
    border-radius: 9px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer
}

.tp-file-name {
    color: var(--tp-muted);
    font-size: 10px
}

.tp-discussion-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    margin-top: 16px
}

@media(max-width:767px) {
    .tp-comms-summary {
        grid-template-columns: 1fr
    }

    .tp-discussion-form-row {
        align-items: flex-start;
        flex-direction: column
    }
}

/* =========================================================
   APPEND TO teacher-panel.css
   Teacher Profile + Educational Feedback
   ========================================================= */

.tp-profile-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 24px;
    margin-bottom: 18px;
    border-radius: 18px;
    background: var(--tp-dark);
    color: #fff;
}

.tp-profile-identity {
    display: flex;
    align-items: center;
    gap: 18px;
}

.tp-profile-photo-wrap {
    position: relative;
    flex: 0 0 auto;
}

.tp-profile-photo {
    width: 84px;
    height: 84px;
    display: grid;
    place-items: center;
    border-radius: 22px;
    background: #fff;
    color: var(--tp-dark);
    font-size: 23px;
    font-weight: 900;
}

.tp-photo-edit {
    position: absolute;
    right: -5px;
    bottom: -5px;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border: 3px solid var(--tp-dark);
    border-radius: 10px;
    background: var(--tp-gold);
    color: var(--tp-dark);
    cursor: pointer;
}

.tp-profile-eyebrow {
    color: var(--tp-gold);
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.tp-profile-identity h2 {
    margin: 6px 0 0;
    font-size: 28px;
    letter-spacing: -.04em;
}

.tp-profile-identity p {
    margin: 6px 0 0;
    color: #cfd4dd;
    font-size: 12px;
}

.tp-profile-tags {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.tp-profile-tags span {
    padding: 6px 9px;
    border-radius: 8px;
    background: rgba(255, 255, 255, .08);
    color: #fff;
    font-size: 9px;
    font-weight: 800;
}

.tp-profile-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(95px, 1fr));
    gap: 8px;
}

.tp-profile-stats div {
    min-width: 100px;
    padding: 13px;
    border-radius: 12px;
    background: rgba(255, 255, 255, .07);
}

.tp-profile-stats span {
    display: block;
    color: #bac1cd;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
}

.tp-profile-stats strong {
    display: block;
    margin-top: 6px;
    color: #fff;
    font-size: 20px;
}

.tp-profile-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
    gap: 18px;
    margin-bottom: 18px;
}

.tp-profile-side {
    display: grid;
    align-content: start;
    gap: 18px;
}

.tp-profile-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    padding: 20px 22px;
}

.tp-profile-form .full {
    grid-column: 1/-1;
}

.tp-profile-form input,
.tp-profile-form select,
.tp-profile-form textarea {
    width: 100%;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--tp-text);
    outline: none;
    padding: 0 13px;
}

.tp-profile-form input,
.tp-profile-form select {
    height: 44px;
}

.tp-profile-form textarea {
    min-height: 115px;
    padding-top: 12px;
    resize: vertical;
}

.tp-profile-form input:focus,
.tp-profile-form select:focus,
.tp-profile-form textarea:focus {
    border-color: #d5ad1b;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .08);
}

.tp-field-help {
    display: block;
    margin-top: 6px;
    color: var(--tp-muted);
    font-size: 9px;
    line-height: 1.5;
}

.tp-form-save-row {
    grid-column: 1/-1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 4px;
}

.tp-profile-list {
    display: grid;
    gap: 0;
    padding: 4px 20px 16px;
}

.tp-profile-list div {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    padding: 12px 0;
    border-bottom: 1px solid var(--tp-border);
}

.tp-profile-list div:last-child {
    border-bottom: 0;
}

.tp-profile-list span {
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-profile-list strong {
    max-width: 60%;
    text-align: right;
    font-size: 11px;
}

.tp-profile-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    padding: 8px 20px 20px;
}

.tp-profile-chip-list span {
    padding: 7px 9px;
    border-radius: 9px;
    background: var(--tp-gold-soft);
    color: #775b00;
    font-size: 9px;
    font-weight: 800;
}

.tp-profile-assigned {
    margin-bottom: 18px;
}

.tp-profile-class-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    padding: 0 20px 20px;
}

.tp-profile-class-card {
    padding: 15px;
    border: 1px solid var(--tp-border);
    border-radius: 14px;
    background: #fff;
    transition: .2s ease;
}

.tp-profile-class-card:hover {
    transform: translateY(-2px);
    border-color: #d8b52f;
    box-shadow: 0 10px 24px rgba(31, 37, 51, .06);
}

.tp-profile-class-card h3 {
    margin: 12px 0 0;
    color: var(--tp-dark);
    font-size: 14px;
}

.tp-profile-class-card p {
    margin: 5px 0 12px;
    color: var(--tp-muted);
    font-size: 10px;
}

.tp-profile-class-card div {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    color: #666d79;
    font-size: 9px;
    font-weight: 800;
}

.tp-security-section {
    margin-bottom: 10px;
}

.tp-security-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 0 20px 20px;
}

.tp-security-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 15px;
    border: 1px solid var(--tp-border);
    border-radius: 13px;
}

.tp-security-item strong {
    display: block;
    font-size: 11px;
}

.tp-security-item span {
    display: block;
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: 9px;
}

.tp-switch {
    position: relative;
    flex: 0 0 auto;
}

.tp-switch input {
    position: absolute;
    opacity: 0;
}

.tp-switch>span {
    width: 42px;
    height: 24px;
    display: block;
    border-radius: 999px;
    background: #dfe2e7;
    cursor: pointer;
    position: relative;
}

.tp-switch>span::after {
    content: "";
    position: absolute;
    width: 18px;
    height: 18px;
    left: 3px;
    top: 3px;
    border-radius: 50%;
    background: #fff;
    transition: .2s ease;
}

.tp-switch input:checked+span {
    background: var(--tp-gold);
}

.tp-switch input:checked+span::after {
    transform: translateX(18px);
}

/* Feedback */
.tp-feedback-help {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin-top: 16px;
    padding: 14px 15px;
    border: 1px solid #ead999;
    border-radius: 12px;
    background: #fff9e6;
}

.tp-feedback-help>div {
    width: 30px;
    height: 30px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: #ffeaa1;
    color: #806000;
}

.tp-feedback-help p {
    margin: 0;
    color: #6f5b16;
    font-size: 10px;
    line-height: 1.65;
}

.tp-feedback-help a {
    color: #5e4900;
    font-weight: 900;
    text-decoration: underline;
}

.tp-side-panel-body textarea {
    width: 100%;
    min-height: 130px;
    border: 1px solid var(--tp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--tp-text);
    outline: none;
    padding: 12px 13px;
    resize: vertical;
}

.tp-side-panel-body textarea:focus {
    border-color: #d5ad1b;
    box-shadow: 0 0 0 4px rgba(236, 186, 5, .08);
}

.tp-feedback-view-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tp-feedback-view-meta span {
    padding: 6px 8px;
    border-radius: 8px;
    background: #f3f4f6;
    color: #626a77;
    font-size: 9px;
    font-weight: 800;
}

.tp-feedback-table-card {
    overflow: hidden;
}

@media(max-width:1199px) {
    .tp-profile-layout {
        grid-template-columns: 1fr;
    }

    .tp-profile-class-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media(max-width:767px) {
    .tp-profile-hero {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-profile-identity {
        align-items: flex-start;
    }

    .tp-profile-stats {
        width: 100%;
    }

    .tp-profile-form {
        grid-template-columns: 1fr;
    }

    .tp-profile-form .full,
    .tp-form-save-row {
        grid-column: auto;
    }

    .tp-profile-class-grid {
        grid-template-columns: 1fr;
    }

    .tp-security-grid {
        grid-template-columns: 1fr;
    }
}

@media(max-width:480px) {
    .tp-profile-identity {
        flex-direction: column;
    }

    .tp-profile-stats {
        grid-template-columns: 1fr;
    }

    .tp-profile-class-card div {
        align-items: flex-start;
        flex-direction: column;
    }

    .tp-form-save-row {
        align-items: stretch;
        flex-direction: column;
    }

    .tp-form-save-row .tp-btn {
        width: 100%;
    }
}