/* Base styles — design-system.css provides font, colors, buttons, forms */

html, body {
    font-family: var(--forge-font);
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* GLOBAL: Force all lesson images to be smaller */
.lesson-content img,
.learner-content img,
.card-body img,
.module-section img {
    max-height: 200px !important;
    max-width: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
}

/* Crane images even smaller */
.crane-image,
.crane-card img {
    max-height: 120px !important;
}

/* Flip cards */
.flip-card {
    min-height: 200px;
    height: auto !important;
    max-height: none !important;
}
.flip-card-inner {
    min-height: 200px;
}
.flip-card-front,
.flip-card-back {
    min-height: 200px;
    height: auto;
    overflow: visible;
}

/* ==============================
   TLILIC0003 FORKLIFT COURSE STYLES
   ============================== */

/* Lesson Container */
.lesson-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
    font-family: 'Segoe UI', system-ui, sans-serif;
    line-height: 1.7;
    color: #333;
}

/* Header */
.lesson-container .lesson-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid #2196F3;
}

.lesson-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: white;
    font-size: 1.25rem;
    font-weight: bold;
    border-radius: 50%;
    flex-shrink: 0;
}

.lesson-container .lesson-title {
    font-size: 2rem;
    color: #1a1a2e;
    margin: 0;
}

/* Objectives Panel */
.objectives-panel {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border-left: 5px solid #2196F3;
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    border-radius: 0 8px 8px 0;
}

.objectives-panel h3 {
    color: #1565C0;
    margin-top: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.objectives-panel ul {
    margin-bottom: 0;
}

.objectives-panel li {
    margin: 0.5rem 0;
}

/* Content Sections */
.content-section {
    margin: 2rem 0;
}

.content-section h2 {
    color: #1a1a2e;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

/* 3D Model Viewer */
.model-viewer-section {
    margin: 2rem 0;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
}

.model-viewer-section h3 {
    color: #1565C0;
    margin-top: 0;
}

.model-viewer-container {
    position: relative;
    width: 100%;
    height: 400px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

model-viewer {
    width: 100%;
    height: 100%;
    background-color: #f0f0f0;
}

.model-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: #f8f9fa;
}

.model-controls {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.btn-control {
    background: rgba(255,255,255,0.95);
    border: 1px solid #ddd;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-control:hover {
    background: #2196F3;
    color: white;
    border-color: #2196F3;
}

/* Flip Cards - Enhanced */
.flip-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.lesson-container .flip-card {
    height: 280px;
    perspective: 1000px;
    cursor: pointer;
}

.lesson-container .flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.lesson-container .flip-card.flipped .flip-card-inner {
    transform: rotateY(180deg);
}

.lesson-container .flip-card-front,
.lesson-container .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.lesson-container .flip-card-front {
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    border: 2px solid #e0e0e0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.flip-card-front .card-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #2196F3, #1976D2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.flip-card-front .card-icon i {
    font-size: 1.75rem;
    color: white;
}

.flip-card-front h4 {
    margin: 0 0 0.5rem 0;
    color: #1a1a2e;
}

.click-hint {
    font-size: 0.8rem;
    color: #888;
    margin: 0;
}

.lesson-container .flip-card-back {
    background: linear-gradient(135deg, #2196F3 0%, #1565C0 100%);
    color: white;
    transform: rotateY(180deg);
    overflow-y: auto;
}

.flip-card-back h4 {
    margin-top: 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid rgba(255,255,255,0.3);
}

.flip-card-back ul {
    padding-left: 1.25rem;
    margin: 0;
}

.flip-card-back li {
    margin: 0.5rem 0;
    font-size: 0.9rem;
}

/* Info Boxes */
.info-box {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 8px;
    border-left: 5px solid;
}

.info-box.warning {
    background: #fff8e1;
    border-color: #ffc107;
}

.info-box.danger {
    background: #ffebee;
    border-color: #dc3545;
}

.info-box.key-points {
    background: #e8f5e9;
    border-color: #28a745;
}

.info-box.info {
    background: #e3f2fd;
    border-color: #2196F3;
}

.info-icon {
    flex-shrink: 0;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.info-box.warning .info-icon {
    background: #ffc107;
    color: #333;
}

.info-box.danger .info-icon {
    background: #dc3545;
    color: white;
}

.info-box.key-points .info-icon {
    background: #28a745;
    color: white;
}

.info-box.info .info-icon {
    background: #2196F3;
    color: white;
}

.info-content h4 {
    margin-top: 0;
    color: #1a1a2e;
}

.info-content ul {
    margin-bottom: 0;
}

/* Summary Box */
.summary-box {
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
    border: 2px solid #ddd;
    border-radius: 12px;
    padding: 1.5rem 2rem;
    margin: 2rem 0;
}

.summary-box h3 {
    color: #1565C0;
    margin-top: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Lesson Navigation (in content) */
.lesson-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid #e0e0e0;
}

.btn-nav {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}

.btn-prev {
    background: #f5f5f5;
    color: #666;
}

.btn-prev:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-next {
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: white;
}

.btn-next:hover {
    transform: translateX(3px);
    box-shadow: 0 4px 15px rgba(33, 150, 243, 0.4);
}

/* Lesson Images - Large and prominent */
.lesson-image {
    max-width: 100%;
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
    margin: 2rem 0;
}

/* All images in lesson content - make prominent */
.content-section img,
.lesson-container img,
.lesson-content img,
.sanitized-content img {
    max-width: 100%;
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
    margin: 2rem 0;
    display: block;
}

/* Image section styling */
.image-section {
    margin: 2rem 0;
    text-align: center;
}

.image-section img {
    max-width: 800px;
    width: 100%;
}

/* Interactive Slider Section */
.slider-section {
    margin: 2rem 0;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
}

.slider-container {
    margin: 1rem 0;
}

.slider-container input[type="range"] {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: #ddd;
    outline: none;
}

/* Responsive */
@media (max-width: 768px) {
    .lesson-container {
        padding: 1rem;
    }

    .lesson-container .lesson-title {
        font-size: 1.5rem;
    }

    .flip-cards-container {
        grid-template-columns: 1fr 1fr;
    }

    .model-viewer-container {
        height: 300px;
    }
}

@media (max-width: 480px) {
    .flip-cards-container {
        grid-template-columns: 1fr;
    }

    .info-box {
        flex-direction: column;
        text-align: center;
    }
}

/* ==============================
   NOTIFICATION HUB STYLES
   ============================== */

/* Notification Bell Component */
.notification-bell-container {
    position: relative;
    display: inline-block;
}

.notification-bell-btn {
    background: transparent;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    position: relative;
    color: inherit;
    font-size: 1.25rem;
    transition: transform 0.2s;
}

.notification-bell-btn:hover {
    transform: scale(1.1);
}

.notification-bell-btn.animate-bell {
    animation: bell-ring 0.5s ease-in-out;
}

@keyframes bell-ring {
    0%, 100% { transform: rotate(0); }
    20%, 60% { transform: rotate(15deg); }
    40%, 80% { transform: rotate(-15deg); }
}

.notification-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: #dc3545;
    color: white;
    font-size: 0.65rem;
    padding: 0.15rem 0.4rem;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    font-weight: 600;
    line-height: 1.2;
}

/* Notification Dropdown */
.notification-dropdown-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999;
}

.notification-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    width: 360px;
    max-width: 90vw;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    z-index: 1000;
    overflow: hidden;
}

.notification-dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #e9ecef;
    background: #f8f9fa;
}

.notification-dropdown-body {
    max-height: 400px;
    overflow-y: auto;
}

.notification-dropdown-footer {
    padding: 0.75rem;
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
}

/* Notification Items */
.notification-item {
    display: flex;
    align-items: flex-start;
    padding: 1rem 1.25rem;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s;
    position: relative;
}

.notification-item:hover {
    background: #f8f9fa;
}

.notification-item.notification-unread {
    background: #f0f7ff;
}

.notification-item.notification-unread:hover {
    background: #e3f2fd;
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
    min-width: 0;
    margin-left: 0.75rem;
}

.notification-title {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
    color: #1a1a2e;
}

.notification-message {
    font-size: 0.8rem;
    color: #666;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.notification-time {
    font-size: 0.75rem;
    color: #999;
    margin-top: 0.25rem;
}

.notification-unread-dot {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background: #0d6efd;
    border-radius: 50%;
}

.notification-loading,
.notification-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: center;
}

/* Notification Center Page */
.notification-card {
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid #e9ecef;
}

.notification-card:hover {
    border-color: #0d6efd;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.notification-unread-card {
    border-left: 4px solid #0d6efd;
    background: linear-gradient(to right, #f0f7ff, #fff);
}

.notification-type-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: white;
    flex-shrink: 0;
}

.notification-details {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Achievement/Purple badge color */
.bg-purple {
    background-color: #7c3aed !important;
}

.btn-purple {
    background-color: #7c3aed;
    border-color: #7c3aed;
    color: white;
}

.btn-purple:hover {
    background-color: #6d28d9;
    border-color: #6d28d9;
    color: white;
}

.btn-outline-purple {
    color: #7c3aed;
    border-color: #7c3aed;
}

.btn-outline-purple:hover {
    background-color: #7c3aed;
    border-color: #7c3aed;
    color: white;
}

/* Notification Template Preview */
.notification-preview-mini {
    border: 1px solid #e9ecef;
}

/* Admin Notification Forms */
.selected-users .badge {
    display: inline-flex;
    align-items: center;
}

.selected-users .btn-close {
    padding: 0;
    margin-left: 0.25rem;
}

/* Responsive adjustments for notifications */
@media (max-width: 576px) {
    .notification-dropdown {
        width: 100vw;
        right: -1rem;
        border-radius: 0;
        border-top-left-radius: 12px;
        border-top-right-radius: 12px;
    }

    .notification-type-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}