:root {
    --primary: #1a56db;
    --primary-dark: #1e429f;
    --accent: #ff7f00;
    --success: #057a55;
    --card-shadow: 0 2px 12px rgba(0,0,0,0.10);
}

body {
    background: #f4f6fb;
    font-family: 'Segoe UI', system-ui, sans-serif;
}

/* Navbar */
.navbar { padding-top: 0; padding-bottom: 0; min-height: 80px; }
.navbar-brand { padding: 0; line-height: 1; }
.navbar-brand img { display: block; height: 80px; width: auto; }

/* Cards */
.course-card {
    transition: transform .18s, box-shadow .18s;
    border: none;
    box-shadow: var(--card-shadow);
    height: 100%;
}
.course-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}
.course-card .card-img-top {
    width: 100%;
    height: 216px;
    object-fit: cover;
    background: #f4f6fb;
}
.course-card .course-thumbnail-placeholder {
    width: 100%;
    height: 216px;
    background: linear-gradient(135deg, #1a56db 0%, #6366f1 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
}
.badge-category {
    font-size: .72rem;
    background: var(--primary);
}

/* Progress */
.progress-circle {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: conic-gradient(var(--primary) var(--pct, 0%), #e5eaf5 0%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
.progress-circle::before {
    content: '';
    position: absolute;
    width: 54px;
    height: 54px;
    background: white;
    border-radius: 50%;
}
.progress-circle span {
    position: relative;
    font-size: .85rem;
    font-weight: 700;
    color: var(--primary);
}

/* Quiz */
.quiz-option {
    cursor: pointer;
    border: 2px solid #dee2e6;
    border-radius: .5rem;
    padding: .75rem 1rem;
    margin-bottom: .5rem;
    transition: all .15s;
}
.quiz-option:hover {
    border-color: var(--primary);
    background: #eef2ff;
}
.quiz-option.selected {
    border-color: var(--primary);
    background: #eef2ff;
}
.quiz-option.correct {
    border-color: var(--success);
    background: #f0fdf4;
}
.quiz-option.incorrect {
    border-color: #e02424;
    background: #fff5f5;
}

/* Certificate */
.certificate-preview {
    background: linear-gradient(135deg, #fefefe 0%, #f5f0e8 100%);
    border: 8px solid #c9a227;
    border-radius: 8px;
    padding: 3rem;
    text-align: center;
    position: relative;
    font-family: 'Georgia', serif;
}
.certificate-preview::before,
.certificate-preview::after {
    content: '✦';
    position: absolute;
    font-size: 1.5rem;
    color: #c9a227;
    top: 1rem;
}
.certificate-preview::before { left: 1.5rem; }
.certificate-preview::after { right: 1.5rem; }

/* Admin */
.admin-sidebar {
    min-height: calc(100vh - 56px);
    background: white;
    box-shadow: var(--card-shadow);
}
.admin-sidebar .nav-link {
    color: #374151;
    padding: .6rem 1rem;
    border-radius: .4rem;
}
.admin-sidebar .nav-link:hover,
.admin-sidebar .nav-link.active {
    background: #eef2ff;
    color: var(--primary);
}
.admin-sidebar .nav-link i {
    width: 20px;
}

/* Score ring */
.score-ring {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 800;
    margin: 0 auto;
}
.score-ring.pass {
    background: #f0fdf4;
    color: var(--success);
    border: 6px solid var(--success);
}
.score-ring.fail {
    background: #fff5f5;
    color: #e02424;
    border: 6px solid #e02424;
}

/* Video container */
.video-container {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: .5rem;
    background: #000;
}
.video-container iframe,
.video-container embed {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: none;
}

/* Login */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #1a56db 0%, #6366f1 100%);
}
.login-card {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

/* Misc */
.stat-card {
    border: none;
    border-radius: .75rem;
    box-shadow: var(--card-shadow);
}
.text-accent { color: var(--accent); }
.bg-accent { background: var(--accent); }
