  body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overscroll-behavior-y: none; 
    /* Prevent layout shift on mobile Safari */
    padding-bottom: env(safe-area-inset-bottom);
}

/* Glass Navigation */
.glass-nav {
    background: rgba(255,255,255, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}
.dark .glass-nav {
    background: rgba(15, 23, 42, 0.75);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

/* Modern Card */
.ios-card {
    background: #FFFFFF;
    border-radius: 24px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.03);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease, border-color 0.3s ease;
    border: 1px solid rgba(0,0,0,0.02);
}
.dark .ios-card {
    background: #1E293B;
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.05);
}

@media (hover: hover) {
    .ios-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 12px 40px rgba(0,0,0,0.08);
        border-color: rgba(79, 70, 229, 0.2);
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #E2E8F0; border-radius: 10px; }
.dark ::-webkit-scrollbar-thumb { background: #334155; }
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

.h-c-text { color: #0F172A; }
.dark .h-c-text { color: #F8FAFC; }

@keyframes highlightPulse {
    0% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7); border-color: #F59E0B; }
    70% { box-shadow: 0 0 0 10px rgba(245, 158, 11, 0); border-color: #F59E0B; }
    100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0); }
}
.highlight-pulse { animation: highlightPulse 1.5s ease-out; }
.highlight-match {
    background-color: rgba(245, 158, 11, 0.4);
    color: inherit;
    border-radius: 2px;
    padding: 0 2px;
    font-weight: bold;
}
.dark .highlight-match { background-color: rgba(245, 158, 11, 0.6); }

/* CALENDAR STYLES */
.cal-cell {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start; 
    padding-top: 0.5rem; 
    border-radius: 1rem; 
    font-weight: 500;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    min-height: 90px; 
    border: 1px solid transparent;
}
@media (min-width: 640px) { .cal-cell { min-height: 110px; padding-top: 0.75rem; } }
@media (min-width: 768px) { .cal-cell { min-height: 130px; border-radius: 1.25rem; } }

.cal-cell:active { transform: scale(0.97); }
@media (hover: hover) {
    .cal-cell:hover {
        background-color: rgba(79, 70, 229, 0.05);
        transform: scale(1.02);
        z-index: 10;
        box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    }
}
.dark .cal-cell:hover { background-color: rgba(255, 255, 255, 0.05); }

.cal-cell-weekend { background-color: #F1F5F9; }
.dark .cal-cell-weekend { background-color: #1e293b; }
.cal-cell.selected { border-color: #4F46E5; background-color: rgba(79, 70, 229, 0.08); }
.dark .cal-cell.selected { background-color: rgba(79, 70, 229, 0.2); }

/* Mini Task Bars */
.mini-task-bar {
    font-size: 0.6rem; padding: 2px 4px; margin-bottom: 1px; border-radius: 4px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; width: 100%;
    line-height: 1.3; box-shadow: 0 1px 2px rgba(0,0,0,0.05); cursor: pointer;
}
@media (min-width: 640px) { .mini-task-bar { font-size: 0.65rem; padding: 2px 6px; } }

/* Seasonal Themes */
.theme-spring .cal-today { background-color: #DCFCE7; color: #166534; border: 2px solid #22C55E; }
.theme-summer .cal-today { background-color: #FFEDD5; color: #9A3412; border: 2px solid #F97316; }
.theme-monsoon .cal-today { background-color: #CCFBF1; color: #0F766E; border: 2px solid #14B8A6; }
.theme-autumn .cal-today { background-color: #FEF3C7; color: #B45309; border: 2px solid #F59E0B; }
.theme-winter .cal-today { background-color: #E0E7FF; color: #3730A3; border: 2px solid #4F46E5; }

.dark .theme-spring .cal-today { background-color: #052E16; color: #86EFAC; }
.dark .theme-summer .cal-today { background-color: #431407; color: #FDBA74; }
.dark .theme-monsoon .cal-today { background-color: #134E4A; color: #5EEAD4; }
.dark .theme-autumn .cal-today { background-color: #451A03; color: #FCD34D; }
.dark .theme-winter .cal-today { background-color: #312E81; color: #A5B4FC; }

/* --- IMPROVED FOCUS SCORE STYLES --- */
.score-ring-circle {
    transition: stroke-dashoffset 1.5s cubic-bezier(0.22, 1, 0.36, 1);
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
}
.score-glow {
    filter: drop-shadow(0 0 6px rgba(79, 70, 229, 0.4));
}

/* --- CREATIVE STATUS CARD STYLES --- */
.glass-orb-container {
    position: relative;
    width: 100px; height: 100px;
    display: flex; align-items: center; justify-content: center;
}
@media (min-width: 768px) { .glass-orb-container { width: 120px; height: 120px; } }

.orb-ring {
    position: absolute; border-radius: 50%;
    border: 1px dashed rgba(79, 70, 229, 0.2);
}
.dark .orb-ring { border-color: rgba(79, 70, 229, 0.4); }
.orb-glow {
    position: absolute; inset: -10px;
    background: radial-gradient(circle, rgba(79, 70, 229, 0.15) 0%, transparent 70%);
    z-index: -1; filter: blur(10px);
}
.level-badge-overlay {
    position: absolute; bottom: -8px;
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
    color: white; padding: 2px 10px; border-radius: 20px;
    font-size: 0.7rem; font-weight: 800; letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3); border: 1px solid rgba(255,255,255,0.1); z-index: 20;
}
.dark .level-badge-overlay {
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
    color: #0f172a; border-color: rgba(0,0,0,0.1);
}
.progress-bar-shimmer {
    position: relative; overflow: hidden;
}
.progress-bar-shimmer::after {
    content: ''; position: absolute; top: 0; left: 0; width: 50%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.6), transparent);
    transform: skewX(-20deg) translateX(-150%);
    animation: shine 2s infinite;
}
@keyframes shine {
    0% { transform: translateX(-100%) skewX(-15deg); }
    100% { transform: translateX(200%) skewX(-15deg); }
}

/* Filter Pills */
.filter-pill {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative; overflow: hidden; touch-action: manipulation;
}
.filter-pill::after {
    content: ''; position: absolute; bottom: 0; left: 50%; width: 0; height: 2px;
    background-color: #4F46E5; transition: all 0.3s ease; transform: translateX(-50%);
}
.filter-pill.active::after { width: 80%; }
.filter-pill.active {
    background-color: rgba(79, 70, 229, 0.1); color: #4F46E5; font-weight: 700;
}
.dark .filter-pill.active {
    background-color: rgba(99, 102, 241, 0.2); color: #818cf8;
}

/* Modal Transitions */
.modal-overlay {
    transition: opacity 0.3s ease;
}
.modal-content {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* PDF Export Specifics */
@media print {
    .no-print { display: none !important; }
}