
/* ==========================================================================
   IHTIMAM TEACHER PORTAL - PREMIUM 3D RESPONSIVE STYLESHEET
   ========================================================================== */

:root {
    --iht-navy-dark: #0B192C;
    --iht-navy-light: #1E293B;
    --iht-green: #0B7C46;
    --iht-green-light: #10B981;
    --iht-green-bg: #ecfdf5;
    --iht-green-border: #a7f3d0;
    --iht-gold: #d97706;
    --iht-red: #dc2626;
    --iht-bg-gray: #f8fafc;
    --iht-border: #e2e8f0;
    --iht-card-shadow: 0 10px 30px rgba(11, 25, 44, 0.07), 0 1px 3px rgba(0, 0, 0, 0.03);
    --iht-card-hover-shadow: 0 16px 36px rgba(11, 25, 44, 0.11), 0 2px 6px rgba(0, 0, 0, 0.04);
}

.iht-teacher-portal-root {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: var(--iht-navy-dark);
    max-width: 1140px;
    margin: 24px auto;
    padding: 0 16px;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
}

.iht-teacher-portal-root * {
    box-sizing: border-box;
}

/* Header Card */
.iht-tch-header {
    background: #ffffff;
    border: 1px solid var(--iht-border);
    border-radius: 18px;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    box-shadow: var(--iht-card-shadow);
    position: relative;
    overflow: hidden;
}
.iht-tch-header::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3.5px;
    background: linear-gradient(90deg, var(--iht-navy-dark) 0%, var(--iht-green) 50%, var(--iht-green-light) 100%);
}
.iht-tch-header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}
.iht-tch-logo {
    max-height: 46px !important;
    max-width: 140px !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    display: block !important;
    flex-shrink: 0;
}
.iht-tch-title-block h1 {
    font-size: 18px;
    font-weight: 900;
    margin: 0;
    color: var(--iht-navy-dark);
    letter-spacing: 0.5px;
    line-height: 1.15;
}
.iht-tch-title-block span {
    font-size: 11.5px;
    color: var(--iht-green);
    font-weight: 700;
    display: block;
    margin-top: 2px;
    letter-spacing: 0.2px;
}
.iht-tch-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}
.iht-tch-user-pill {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--iht-bg-gray);
    border: 1px solid var(--iht-border);
    border-radius: 12px;
    padding: 6px 14px 6px 8px;
}
.iht-tch-avatar {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--iht-green) 0%, #056434 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    box-shadow: 0 3px 8px rgba(11, 124, 70, 0.3);
}
.iht-tch-user-meta {
    display: flex;
    flex-direction: column;
}
.iht-tch-user-name {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--iht-navy-dark);
    line-height: 1.2;
}
.iht-tch-user-sub {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    margin-top: 2px;
}
.iht-tch-user-sub code {
    color: var(--iht-green);
    font-family: inherit;
    font-weight: 800;
}
.iht-btn-tch-logout {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
    padding: 8px 16px;
    border-radius: 9px;
    font-size: 12.5px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.iht-btn-tch-logout:hover {
    background: #fee2e2;
    color: #991b1b;
    transform: translateY(-1px);
}

/* Navigation Bar */
.iht-tch-nav {
    background: linear-gradient(135deg, var(--iht-navy-dark) 0%, #152238 100%);
    border-radius: 14px;
    padding: 6px;
    margin-bottom: 24px;
    box-shadow: 0 8px 24px rgba(11, 25, 44, 0.12);
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.iht-tch-nav-link {
    padding: 10px 18px;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 700;
    color: #cbd5e1;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}
.iht-tch-nav-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    transform: translateY(-1px);
}
.iht-tch-nav-link.active {
    background: linear-gradient(135deg, var(--iht-green) 0%, #056434 100%);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(11, 124, 70, 0.4);
}

/* 3D Cards */
.iht-tch-card {
    background: #ffffff;
    border: 1px solid var(--iht-border);
    border-radius: 18px;
    padding: 24px;
    margin-bottom: 22px;
    box-shadow: var(--iht-card-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.iht-tch-card:hover {
    box-shadow: var(--iht-card-hover-shadow);
}
.iht-tch-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 14px;
    margin-bottom: 18px;
    border-bottom: 1.5px solid #f1f5f9;
}
.iht-tch-card-title {
    font-size: 16.5px;
    font-weight: 800;
    color: var(--iht-navy-dark);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 3D Stat Grid */
.iht-tch-stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 22px;
}
.iht-tch-stat-box {
    background: #ffffff;
    border: 1px solid var(--iht-border);
    border-radius: 14px;
    padding: 16px 18px;
    box-shadow: 0 4px 12px rgba(11, 25, 44, 0.03);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.iht-tch-stat-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(11, 25, 44, 0.07);
}
.iht-tch-stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.iht-tch-stat-info {
    display: flex;
    flex-direction: column;
}
.iht-tch-stat-val {
    font-size: 21px;
    font-weight: 900;
    color: var(--iht-navy-dark);
    line-height: 1.15;
}
.iht-tch-stat-lbl {
    font-size: 11.5px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-top: 3px;
}

/* Modal Popup */
.iht-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(11, 25, 44, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    padding: 20px;
}
.iht-modal-content {
    background: #ffffff;
    border-radius: 20px;
    max-width: 520px;
    width: 100%;
    padding: 28px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    position: relative;
}
.iht-video-preview {
    width: 100%;
    max-height: 280px;
    background: #000000;
    border-radius: 12px;
    object-fit: cover;
    margin: 12px 0;
}

/* Responsive */
@media (max-width: 880px) {
    .iht-tch-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .iht-tch-header-right {
        width: 100%;
        justify-content: space-between;
    }
}
@media (max-width: 640px) {
    .iht-tch-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding: 6px 8px;
    }
    .iht-tch-nav-link {
        white-space: nowrap;
        padding: 8px 14px;
        font-size: 12.5px;
    }
}
