/* Custom styles for Filotimo Competition Tracker */

* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Navigation Active State */
.nav-link.active {
    border-bottom-color: #2563eb;
    color: #2563eb;
}

/* Alert Styles */
.alert {
    border-left: 4px solid;
    transition: all 0.3s ease;
}

.alert-critical {
    border-color: #dc2626;
    background-color: #fef2f2;
}

.alert-warning {
    border-color: #f59e0b;
    background-color: #fffbeb;
}

.alert-info {
    border-color: #3b82f6;
    background-color: #eff6ff;
}

/* Progress Bar */
.progress-bar {
    height: 8px;
    background-color: #e5e7eb;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background-color: #10b981;
    transition: width 0.5s ease;
}

.progress-bar-fill.high-risk {
    background-color: #ef4444;
}

.progress-bar-fill.medium-risk {
    background-color: #f59e0b;
}

/* Risk Badge */
.risk-badge {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.risk-low {
    background-color: #d1fae5;
    color: #065f46;
}

.risk-medium {
    background-color: #fef3c7;
    color: #92400e;
}

.risk-high {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Card Hover Effects */
.card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* Task Card Drag & Drop */
.task-card {
    cursor: move;
    background: white;
    padding: 1rem;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border-left: 4px solid #3b82f6;
    transition: all 0.3s ease;
}

.task-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.task-card.dragging {
    opacity: 0.5;
    transform: rotate(3deg);
}

/* Override border for team-colored task cards */
.task-card.team-video { border-left-color: #8B5CF6; }
.task-card.team-theater { border-left-color: #EF4444; }
.task-card.team-dance { border-left-color: #EC4899; }
.task-card.team-music { border-left-color: #F59E0B; }

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.2s;
}

.modal-content {
    background: white;
    border-radius: 0.5rem;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Form Styles */
input[type="text"],
input[type="email"],
input[type="date"],
input[type="number"],
textarea,
select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #3b82f6;
    ring: 2px;
    ring-color: #93c5fd;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #374151;
}

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

    nav ul {
        overflow-x: auto;
        white-space: nowrap;
    }
}

/* Loading Spinner */
.spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ==============================
   V2.0 SPECTACULAR UI ENHANCEMENTS
   ============================== */

/* Animated Gradient Background */
.animated-gradient {
    background: linear-gradient(-45deg, #667eea, #764ba2, #6B8DD6, #8E37D7);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Glassmorphism Effect */
.glass {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

/* Pulse Animation for Important Items */
.pulse-animation {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

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

/* Bounce Animation */
.bounce-animation {
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(-5%); animation-timing-function: cubic-bezier(0.8, 0, 1, 1); }
    50% { transform: translateY(0); animation-timing-function: cubic-bezier(0, 0, 0.2, 1); }
}

/* Glow Effect for Cards */
.glow-effect {
    box-shadow: 0 0 15px rgba(102, 126, 234, 0.4);
    transition: box-shadow 0.3s ease;
}

.glow-effect:hover {
    box-shadow: 0 0 25px rgba(102, 126, 234, 0.6);
}

/* Enhanced Card Styles for v2.0 */
.card-v2 {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.card-v2:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Vibrant Team Colors */
.team-video { border-left: 4px solid #8B5CF6; background: linear-gradient(135deg, #F3E8FF 0%, #EDE9FE 100%); }
.team-theater { border-left: 4px solid #EF4444; background: linear-gradient(135deg, #FEE2E2 0%, #FECACA 100%); }
.team-dance { border-left: 4px solid #EC4899; background: linear-gradient(135deg, #FCE7F3 0%, #FBCFE8 100%); }
.team-music { border-left: 4px solid #F59E0B; background: linear-gradient(135deg, #FEF3C7 0%, #FDE68A 100%); }

/* Achievement Badge */
.achievement-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: fadeIn 0.5s ease;
}

.badge-gold {
    background: linear-gradient(135deg, #FEF3C7, #F59E0B);
    color: #92400E;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.4);
}

.badge-silver {
    background: linear-gradient(135deg, #E5E7EB, #9CA3AF);
    color: #374151;
    box-shadow: 0 2px 4px rgba(156, 163, 175, 0.4);
}

.badge-bronze {
    background: linear-gradient(135deg, #FED7AA, #F97316);
    color: #9A3412;
    box-shadow: 0 2px 4px rgba(249, 115, 22, 0.4);
}

/* Priority Badges with Icons */
.priority-critical {
    background: linear-gradient(135deg, #FEE2E2, #FECACA);
    color: #991B1B;
    border: 2px solid #EF4444;
    font-weight: 700;
}

.priority-high {
    background: linear-gradient(135deg, #FEF3C7, #FDE68A);
    color: #92400E;
    border: 2px solid #F59E0B;
}

.priority-medium {
    background: linear-gradient(135deg, #DBEAFE, #BFDBFE);
    color: #1E40AF;
    border: 2px solid #3B82F6;
}

.priority-low {
    background: linear-gradient(135deg, #D1FAE5, #A7F3D0);
    color: #065F46;
    border: 2px solid #10B981;
}

/* Smooth Page Transitions */
.view-container {
    animation: viewSlideIn 0.4s ease-out;
}

@keyframes viewSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Counter Animation */
.counter-animate {
    animation: countUp 0.8s ease-out;
}

@keyframes countUp {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Floating Action Button */
.fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 6px 10px rgba(102, 126, 234, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 100;
}

.fab:hover {
    transform: scale(1.1) rotate(90deg);
    box-shadow: 0 8px 15px rgba(102, 126, 234, 0.6);
}

/* Confetti Animation for Celebrations */
@keyframes confetti {
    0% { transform: translateY(0) rotateZ(0); opacity: 1; }
    100% { transform: translateY(1000px) rotateZ(720deg); opacity: 0; }
}

.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    animation: confetti 3s ease-in-out infinite;
}

/* Stat Cards with Gradient Borders */
.stat-card {
    position: relative;
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2, #EC4899);
}

.stat-card .number {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Better Button Styles */
.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(102, 126, 234, 0.6);
}

.btn-success {
    background: linear-gradient(135deg, #10B981, #059669);
    color: white;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(16, 185, 129, 0.4);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(16, 185, 129, 0.6);
}

.btn-danger {
    background: linear-gradient(135deg, #EF4444, #DC2626);
    color: white;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(239, 68, 68, 0.4);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(239, 68, 68, 0.6);
}

/* Typography Enhancements */
.heading-gradient {
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
}

/* Input Focus Glow */
input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.3);
}

/* Tooltip */
.tooltip {
    position: relative;
}

.tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background: #1F2937;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.tooltip:hover::after {
    opacity: 1;
}

/* Progress Ring */
.progress-ring {
    transform: rotate(-90deg);
}

.progress-ring-circle {
    transition: stroke-dashoffset 0.5s ease;
    stroke-linecap: round;
}

/* Notification Dot */
.notification-dot {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 12px;
    height: 12px;
    background: #EF4444;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

/* Empty State Illustration */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #9CA3AF;
}

.empty-state svg {
    width: 120px;
    height: 120px;
    margin: 0 auto 1rem;
    opacity: 0.5;
}

/* Dark Mode Support (Optional - for future) */
@media (prefers-color-scheme: dark) {
    .dark-mode-ready {
        /* Future dark mode styles */
    }
}
