/* ============================================
   LearnPro LMS — Design System
   ============================================ */

/* ---------- DaisyUI Theme Tokens (DaisyUI v4 OKLCH) ---------- */
[data-theme="learnpro"] {
    color-scheme: light;
    --p: 49.12% 0.237 264.4;
    --pf: 42% 0.23 264.4;
    --pc: 100% 0 0;
    --s: 27.81% 0.033 256.8;
    --sf: 23% 0.03 256.8;
    --sc: 100% 0 0;
    --a: 62.3% 0.188 259.8;
    --af: 55% 0.18 259.8;
    --ac: 100% 0 0;
    --n: 98.4% 0.004 247.9;
    --nf: 93% 0.008 247.9;
    --nc: 27.81% 0.033 256.8;
    --b1: 100% 0 0;
    --b2: 98.4% 0.004 247.9;
    --b3: 96% 0.008 247.9;
    --bc: 27.81% 0.033 256.8;
    --in: 58.8% 0.158 241.9;
    --inc: 100% 0 0;
    --su: 62.8% 0.194 149.2;
    --suc: 100% 0 0;
    --wa: 74.8% 0.16 73.1;
    --wac: 100% 0 0;
    --er: 57.7% 0.222 27.3;
    --erc: 100% 0 0;
    --rounded-box: 1rem;
    --rounded-btn: 0.5rem;
    --rounded-badge: 1.9rem;
    --animation-btn: 0.25s;
    --animation-input: .2s;
    --btn-focus-scale: 0.95;
    --border-btn: 1px;
    --tab-border: 1px;
    --tab-radius: 0.5rem;
}

/* ---------- Typography & Global Scrolling ---------- */
html {
    overflow-y: auto;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', system-ui, sans-serif;
    letter-spacing: -0.01em;
}

/* ---------- Form Elements ---------- */
.input,
.select,
.textarea {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input:focus,
.select:focus,
.textarea:focus {
    border-color: #1A56DB;
    box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.1);
}

/* ---------- Buttons ---------- */
.btn {
    transition: all 0.2s ease;
    letter-spacing: 0.01em;
}

.btn-primary {
    background-color: #1A56DB !important;
    color: #FFFFFF !important;
    border-color: #1A56DB !important;
    box-shadow: 0 2px 8px rgba(26, 86, 219, 0.25);
}

.btn-primary:hover {
    background-color: #1544B0 !important;
    border-color: #1544B0 !important;
    box-shadow: 0 4px 16px rgba(26, 86, 219, 0.35);
    transform: translateY(-1px);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-success {
    background-color: #16A34A !important;
    color: #FFFFFF !important;
    border-color: #16A34A !important;
}
.btn-success:hover {
    background-color: #15803D !important;
    border-color: #15803D !important;
}

.btn-warning {
    background-color: #D97706 !important;
    color: #FFFFFF !important;
    border-color: #D97706 !important;
}
.btn-warning:hover {
    background-color: #B45309 !important;
    border-color: #B45309 !important;
}

.btn-error {
    background-color: #DC2626 !important;
    color: #FFFFFF !important;
    border-color: #DC2626 !important;
}
.btn-error:hover {
    background-color: #B91C1C !important;
    border-color: #B91C1C !important;
}

/* ---------- Badges High-Contrast ---------- */
.badge {
    border-width: 1px;
}
.badge-primary {
    background-color: #1A56DB !important;
    color: #FFFFFF !important;
    border-color: #1A56DB !important;
}
.badge-success {
    background-color: #DCFCE7 !important;
    color: #15803D !important;
    border-color: #BBF7D0 !important;
}
.badge-warning {
    background-color: #FEF3C7 !important;
    color: #B45309 !important;
    border-color: #FDE68A !important;
}
.badge-error {
    background-color: #FEE2E2 !important;
    color: #B91C1C !important;
    border-color: #FECACA !important;
}
.badge-info {
    background-color: #DBEAFE !important;
    color: #1D4ED8 !important;
    border-color: #BFDBFE !important;
}
.badge-ghost {
    background-color: #F1F5F9 !important;
    color: #334155 !important;
    border-color: #CBD5E1 !important;
}

/* ---------- Gradient Text ---------- */
.gradient-text {
    background: linear-gradient(135deg, #1A56DB 0%, #3B82F6 50%, #60A5FA 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ---------- Glass Effect ---------- */
.glass-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* ---------- Course Card ---------- */
.course-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-top: 3px solid transparent;
}

.course-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(26, 86, 219, 0.12);
    border-top-color: #1A56DB;
}

.course-card figure img {
    transition: transform 0.5s ease;
}

.course-card:hover figure img {
    transform: scale(1.08);
}

/* ---------- Icon Circle Utility ---------- */
.icon-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    flex-shrink: 0;
}

.icon-circle-sm {
    width: 2rem;
    height: 2rem;
}

.icon-circle-md {
    width: 2.5rem;
    height: 2.5rem;
}

.icon-circle-lg {
    width: 3.5rem;
    height: 3.5rem;
}

.icon-circle-xl {
    width: 5rem;
    height: 5rem;
}

/* ---------- Material Icons Sizing ---------- */
.material-symbols-outlined.icon-sm { font-size: 18px; }
.material-symbols-outlined.icon-md { font-size: 22px; }
.material-symbols-outlined.icon-lg { font-size: 28px; }
.material-symbols-outlined.icon-xl { font-size: 36px; }

/* ---------- Page Header Banner ---------- */
.page-header {
    background: linear-gradient(135deg, #1E293B 0%, #1A56DB 100%);
    color: white;
    padding: 2.5rem 0;
}

.page-header h1 {
    font-size: 1.875rem;
    font-weight: 700;
}

.page-header p {
    color: rgba(255, 255, 255, 0.7);
    margin-top: 0.25rem;
}

/* ---------- Auth Pages Background ---------- */
.auth-bg {
    background: linear-gradient(135deg, #f0f4ff 0%, #e8eeff 50%, #f8fafc 100%);
    position: relative;
}

.auth-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 20% 50%, rgba(26, 86, 219, 0.05) 0%, transparent 50%),
                      radial-gradient(circle at 80% 20%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
                      radial-gradient(circle at 50% 80%, rgba(96, 165, 250, 0.04) 0%, transparent 50%);
    pointer-events: none;
}

/* ---------- Sidebar Active Indicator ---------- */
.sidebar-active {
    background-color: rgba(26, 86, 219, 0.08);
    border-left: 3px solid #1A56DB;
    font-weight: 600;
    color: #1A56DB;
}

/* ---------- Progress Bar ---------- */
.progress-fill {
    transition: width 0.6s ease;
}

/* ---------- Entry Animations ---------- */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-up {
    animation: fadeUp 0.5s ease-out forwards;
}

.animate-fade-up-delay-1 { animation-delay: 0.1s; opacity: 0; }
.animate-fade-up-delay-2 { animation-delay: 0.2s; opacity: 0; }
.animate-fade-up-delay-3 { animation-delay: 0.3s; opacity: 0; }

/* ---------- HTMX Transitions ---------- */
.htmx-settling {
    opacity: 0;
}

#main-content {
    transition: opacity 200ms ease-in-out;
}

#main-content.htmx-settling {
    opacity: 0;
}

#main-content.htmx-added {
    opacity: 1;
}

/* ---------- HTMX Loading Indicator ---------- */
.htmx-indicator {
    opacity: 0;
    transition: opacity 200ms ease-in;
}

.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
    opacity: 1;
}

/* ---------- Loading Bar Animation ---------- */
@keyframes slide {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(300%); }
}

/* ---------- Skeleton Loading ---------- */
.skeleton-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: .5; }
}

/* ---------- Notification Badge Bounce ---------- */
@keyframes badge-bounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.badge-bounce {
    animation: badge-bounce 0.3s ease;
}

/* ---------- Custom Scrollbar ---------- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #94a3b8; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #64748b; }

/* ---------- Stat Card ---------- */
.stat-card {
    background: white;
    border-radius: 1rem;
    padding: 1.25rem;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* ---------- Section Divider ---------- */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1E293B;
}

.section-header p {
    color: rgba(30, 41, 59, 0.5);
    margin-top: 0.25rem;
    font-size: 0.875rem;
}

/* ---------- Prose Improvements ---------- */
.prose {
    line-height: 1.8;
}

.prose h3 {
    font-family: 'Outfit', system-ui, sans-serif;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}

.prose p {
    margin-bottom: 1rem;
}

/* ---------- Empty State ---------- */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.empty-state .icon-circle {
    margin: 0 auto 1.5rem;
    background: #f1f5f9;
    color: #94a3b8;
}

.empty-state h3 {
    font-family: 'Outfit', system-ui, sans-serif;
    font-size: 1.125rem;
    font-weight: 600;
    color: #1E293B;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: rgba(30, 41, 59, 0.5);
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
}

/* ---------- Gentle Floating Keyframes ---------- */
@keyframes heroFloat {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-8px);
    }
}

@keyframes heroFloatReverse {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(8px);
    }
}

.animate-float-slow {
    animation: heroFloat 5s ease-in-out infinite;
}

.animate-float-delayed {
    animation: heroFloatReverse 6s ease-in-out 1s infinite;
}

/* Responsive Header Utilities */
@media (max-width: 1023px) {
    .header-get-started-btn {
        display: none !important;
    }
}

