/* ====================================================
   Test Flow — Student Learning Path (4-screen flow)
   Dark theme, adapted to Ataca y Alemana branding
   ==================================================== */

.tf-page {
    padding: 40px 48px;
    max-width: 1100px;
    margin: 0 auto;
    font-family: 'Open Sans', sans-serif;
    color: #e8e4e0;
}

/* ---- Header ---- */
.tf-header {
    margin-bottom: 36px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
}
.tf-eyebrow {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #f2090b;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.tf-eyebrow::before {
    content: '';
    width: 20px;
    height: 1px;
    background: rgba(242,9,11,0.45);
}
.tf-title {
    font-family: 'Raleway', sans-serif;
    font-size: 32px;
    font-weight: 300;
    color: #e8e4e0;
    margin: 0 0 6px;
    letter-spacing: 0.02em;
}
.tf-subtitle {
    font-size: 13px;
    color: #7a7676;
    margin: 0;
}

/* ---- Breadcrumb ---- */
.tf-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #7a7676;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.tf-breadcrumb a {
    color: #f2090b;
    text-decoration: none;
    transition: color 0.12s;
}
.tf-breadcrumb a:hover { color: #ff3b3d; text-decoration: none; }
.tf-breadcrumb-sep { color: #4e4a4c; }

/* ---- Loading ---- */
.tf-loading {
    color: #7a7676;
    font-size: 13px;
    padding: 48px 0;
}

/* ====================================================
   SCREEN 1 — LIBRARY (product grid)
   ==================================================== */
.tf-product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.tf-product-card {
    border: 1px solid rgba(255,255,255,0.09);
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: border-color 0.15s, transform 0.12s;
    text-decoration: none;
    display: block;
    background: #181415;
}
.tf-product-card:hover {
    border-color: rgba(242,9,11,0.35);
    transform: translateY(-2px);
    text-decoration: none;
}
.tf-product-thumb {
    height: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    padding: 12px;
    text-align: center;
}
.tf-thumb-1 { background: linear-gradient(135deg, #1a1210, #231a0e); }
.tf-thumb-2 { background: linear-gradient(135deg, #111a19, #142220); }
.tf-thumb-3 { background: linear-gradient(135deg, #1a1012, #25131a); }
.tf-thumb-4 { background: linear-gradient(135deg, #0e1218, #121826); }
.tf-thumb-5 { background: linear-gradient(135deg, #161212, #201a1a); }
.tf-thumb-6 { background: linear-gradient(135deg, #121618, #161e24); }

.tf-product-badge {
    font-size: 9px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(232,228,224,0.42);
}
.tf-product-name-thumb {
    font-size: 15px;
    font-weight: 400;
    color: #e8e4e0;
    letter-spacing: 0.03em;
}
.tf-product-info {
    padding: 12px 14px;
}
.tf-product-title {
    font-size: 13px;
    font-weight: 600;
    color: #e8e4e0;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.tf-product-meta {
    font-size: 11px;
    color: #7a7676;
    display: flex;
    align-items: center;
    gap: 6px;
}
.tf-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #4e4a4c;
    display: inline-block;
    flex-shrink: 0;
}
.tf-active-badge { color: #6baa7a; font-weight: 600; }

/* ====================================================
   SCREEN 2 — COURSE CATALOGUE
   ==================================================== */
.tf-cat-header { margin-bottom: 20px; }
.tf-cat-title {
    font-family: 'Raleway', sans-serif;
    font-size: 22px;
    font-weight: 300;
    color: #e8e4e0;
    margin: 0 0 4px;
}
.tf-cat-desc {
    font-size: 12px;
    color: #7a7676;
    margin: 0 0 16px;
}

/* Level filter tabs */
.tf-filter-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.tf-filter-tab {
    font-size: 11px;
    font-weight: 600;
    padding: 5px 14px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.10);
    color: #7a7676;
    cursor: pointer;
    background: none;
    transition: all 0.14s;
    font-family: 'Open Sans', sans-serif;
}
.tf-filter-tab:hover { border-color: rgba(255,255,255,0.2); color: #e8e4e0; }
.tf-filter-tab.active {
    background: rgba(242,9,11,0.10);
    border-color: rgba(242,9,11,0.35);
    color: #f2090b;
}

/* Course grid */
.tf-course-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
.tf-course-card {
    border: 1px solid rgba(255,255,255,0.09);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: border-color 0.14s;
    text-decoration: none;
    display: block;
    background: #181415;
}
.tf-course-card:hover { border-color: rgba(255,255,255,0.22); text-decoration: none; }
.tf-course-thumb {
    height: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    font-size: 11px;
    font-weight: 600;
    text-align: center;
    line-height: 1.4;
    color: #e8e4e0;
}
.tf-course-body { padding: 10px 12px; }
.tf-course-name {
    font-size: 11px;
    font-weight: 600;
    color: #e8e4e0;
    line-height: 1.4;
    margin-bottom: 6px;
}
.tf-pills { display: flex; flex-wrap: wrap; gap: 4px; }
.tf-pill {
    font-size: 9px;
    padding: 2px 7px;
    border-radius: 3px;
    border: 1px solid rgba(255,255,255,0.10);
    color: #7a7676;
}
.tf-pill-beg { border-color: rgba(107,170,122,0.3); color: #6baa7a; background: rgba(107,170,122,0.08); }
.tf-pill-int { border-color: rgba(242,9,11,0.25); color: #f2090b; background: rgba(242,9,11,0.06); }
.tf-pill-adv { border-color: rgba(200,112,112,0.3); color: #c87070; background: rgba(200,112,112,0.06); }

/* ====================================================
   SCREEN 3 — INSIDE COURSE (lesson list + progress)
   ==================================================== */
.tf-course-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}
.tf-course-info { flex: 1; }
.tf-course-info-title {
    font-size: 14px;
    font-weight: 600;
    color: #e8e4e0;
    margin-bottom: 10px;
}
.tf-progress-wrap {
    height: 4px;
    background: rgba(255,255,255,0.07);
    border-radius: 2px;
    margin-bottom: 6px;
    overflow: hidden;
}
.tf-progress-fill {
    height: 100%;
    border-radius: 2px;
    background: #f2090b;
    transition: width 0.4s ease;
}
.tf-progress-label { font-size: 11px; color: #7a7676; }
.tf-back-btn {
    font-size: 11px;
    color: #7a7676;
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 4px;
    padding: 7px 14px;
    white-space: nowrap;
    background: #211c1e;
    text-decoration: none;
    display: inline-block;
    transition: color 0.14s, border-color 0.14s;
}
.tf-back-btn:hover { color: #e8e4e0; border-color: rgba(255,255,255,0.2); text-decoration: none; }

/* Lesson rows */
.tf-lesson-list { border: 1px solid rgba(255,255,255,0.07); border-radius: 8px; overflow: hidden; }
.tf-lesson-row {
    display: grid;
    grid-template-columns: 1fr 100px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    cursor: pointer;
    transition: background 0.12s;
    text-decoration: none;
}
.tf-lesson-row:hover { background: rgba(255,255,255,0.025); text-decoration: none; }
.tf-lesson-row:last-child { border-bottom: none; }
.tf-lesson-left { padding: 14px 12px 14px 16px; }
.tf-lesson-title {
    font-size: 12px;
    font-weight: 600;
    color: #e8e4e0;
    margin-bottom: 4px;
    line-height: 1.4;
}
.tf-lesson-status { font-size: 11px; color: #7a7676; }
.tf-lesson-status.completed { color: #6baa7a; }
.tf-lesson-status.current   { color: rgba(242,9,11,0.8); }
.tf-lesson-right {
    padding: 12px 14px 12px 10px;
    display: flex;
    align-items: center;
    border-left: 1px solid rgba(255,255,255,0.06);
}
.tf-lesson-thumb {
    width: 82px;
    height: 48px;
    border-radius: 5px;
    background: #211c1e;
    border: 1px solid rgba(255,255,255,0.08);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #4e4a4c;
    flex-shrink: 0;
}
.tf-lesson-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ====================================================
   SCREEN 4 — INSIDE LESSON (player + sidebar)
   ==================================================== */
.tf-lesson-layout {
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 20px;
    align-items: start;
}
.tf-video-wrap {
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.07);
    margin-bottom: 16px;
}
.tf-video-wrap > div { display: block; width: 100% !important; }
.tf-lesson-meta { font-size: 12px; color: #7a7676; margin-bottom: 4px; }
.tf-lesson-main-title { font-size: 17px; font-weight: 600; color: #e8e4e0; margin-bottom: 4px; }
.tf-lesson-duration { font-size: 11px; color: #4e4a4c; }

/* Sidebar */
.tf-sidebar {
    background: #181415;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 8px;
    overflow: hidden;
    position: sticky;
    top: 20px;
}
.tf-sidebar-header {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #4e4a4c;
}
.tf-sidebar-list { max-height: 520px; overflow-y: auto; }
.tf-sidebar-list::-webkit-scrollbar { width: 3px; }
.tf-sidebar-list::-webkit-scrollbar-track { background: transparent; }
.tf-sidebar-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.09); border-radius: 2px; }

.tf-sidebar-item {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    cursor: pointer;
    transition: background 0.12s;
    text-decoration: none;
    border-left: 2px solid transparent;
}
.tf-sidebar-item:hover { background: rgba(255,255,255,0.03); text-decoration: none; }
.tf-sidebar-item.current { background: rgba(242,9,11,0.07); border-left-color: #f2090b; }
.tf-sidebar-item:last-child { border-bottom: none; }

.tf-sb-thumb {
    width: 40px;
    height: 26px;
    border-radius: 3px;
    background: #211c1e;
    border: 1px solid rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 8px;
    color: #4e4a4c;
    overflow: hidden;
}
.tf-sb-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tf-sb-dot { width: 7px; height: 7px; border-radius: 50%; background: #f2090b; }
.tf-sb-check { font-size: 10px; color: #6baa7a; }
.tf-sb-info { flex: 1; min-width: 0; }
.tf-sb-name {
    font-size: 11px;
    font-weight: 600;
    color: #e8e4e0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}
.tf-sb-status { font-size: 10px; color: #7a7676; }
.tf-sb-status.current { color: #f2090b; }

/* Auto-advance banner */
.tf-advance-banner {
    background: rgba(242,9,11,0.07);
    border: 1px solid rgba(242,9,11,0.2);
    border-radius: 6px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
    font-size: 12px;
    color: #e8e4e0;
}
.tf-advance-banner button {
    font-size: 11px;
    color: #f2090b;
    background: none;
    border: 1px solid rgba(242,9,11,0.3);
    border-radius: 4px;
    padding: 5px 12px;
    cursor: pointer;
    font-family: 'Open Sans', sans-serif;
    white-space: nowrap;
    transition: background 0.12s;
}
.tf-advance-banner button:hover { background: rgba(242,9,11,0.10); }

/* ====================================================
   RESPONSIVE
   ==================================================== */
@media (max-width: 900px) {
    .tf-page { padding: 28px 20px; }
    .tf-product-grid { grid-template-columns: repeat(2, 1fr); }
    .tf-lesson-layout { grid-template-columns: 1fr; }
    .tf-sidebar { position: static; }
}
@media (max-width: 560px) {
    .tf-product-grid { grid-template-columns: 1fr; }
    .tf-course-grid  { grid-template-columns: 1fr; }
    .tf-course-top   { flex-direction: column; }
}
