/* Custom styles for KamenRun App */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #007BFF;
    --secondary-color: #4CAF50;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
    --light-gray: #f8f9fa;
    --dark-gray: #343a40;
    --bg-color: #ffffff;
    --card-shadow: 0 4px 12px rgba(0,0,0,0.1);
    --border-radius: 12px;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px 0;
}

.main-container {
    background-color: var(--bg-color);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.header-section {
    background: linear-gradient(135deg, var(--primary-color), #6c5ce7);
    color: white;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.1)"/></svg>') repeat;
    opacity: 0.3;
}

.header-section h1 {
    font-weight: 700;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 2;
}

.motivation-text {
    font-style: italic;
    font-size: 1.1rem;
    opacity: 0.9;
    position: relative;
    z-index: 2;
}

.progress-section {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin: 1.5rem;
    box-shadow: var(--card-shadow);
}

.progress-bar-custom {
    height: 30px;
    border-radius: 15px;
    background: linear-gradient(90deg, #e9ecef 0%, #e9ecef 100%);
    overflow: hidden;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--secondary-color), #81C784);
    border-radius: 15px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    position: relative;
    overflow: hidden;
}

.progress-bar-fill::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.controls-section {
    padding: 1rem 1.5rem;
}

.form-select {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.schedule-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    padding: 1.5rem;
}

.day-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.day-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.day-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.day-card:hover::before {
    transform: scaleX(1);
}

.day-card.completed {
    background: linear-gradient(135deg, #e8f5e9, #f1f8e9);
    border-color: var(--secondary-color);
}

.day-card.completed .task-text {
    text-decoration: line-through;
    color: #757575;
}

.day-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #f8f9fa;
}

.day-title {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.2rem;
    margin: 0;
}

.day-icon {
    color: var(--secondary-color);
    font-size: 1.5rem;
}

.task-container {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.custom-checkbox {
    width: 24px;
    height: 24px;
    border: 2px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    margin-top: 2px;
}

.custom-checkbox:checked {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    position: relative;
}

.custom-checkbox:checked::after {
    content: '✓';
    color: white;
    font-weight: bold;
    font-size: 16px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.task-text {
    flex-grow: 1;
    line-height: 1.5;
    color: var(--dark-gray);
}

.footer-section {
    text-align: center;
    padding: 2rem;
    color: #6c757d;
    font-size: 0.9rem;
}

.notification-settings {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin: 1.5rem;
    box-shadow: var(--card-shadow);
}

.btn-custom {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
    border: none;
}

.btn-primary-custom {
    background: linear-gradient(135deg, var(--primary-color), #6c5ce7);
    color: white;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

.btn-success-custom {
    background: linear-gradient(135deg, var(--secondary-color), #81C784);
    color: white;
}

.btn-success-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.toast-custom {
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
}

.fade-in {
    animation: fadeInUp 0.6s ease-out;
}

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

.rest-day {
    opacity: 0.7;
}

.rest-day .day-icon {
    color: #6c757d;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    body {
        padding: 10px 0;
    }
    
    .header-section h1 {
        font-size: 2rem;
    }
    
    .schedule-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
    }
    
    .day-card {
        padding: 1rem;
    }
    
    .main-container {
        margin: 0 10px;
        border-radius: 16px;
    }
    
    .progress-section,
    .notification-settings {
        margin: 1rem;
        border-radius: 12px;
    }
    
    /* Show bottom nav on mobile */
    .bottom-nav {
        display: flex;
    }
    
    /* Hide desktop tabs on mobile */
    .tabs-section {
        display: none;
    }
    
    .tab-content {
        margin-bottom: 80px;
    }
    
    /* Mobile-specific card styling */
    .card {
        border-radius: 12px;
        margin-bottom: 1rem;
    }
    
    /* Mobile button styling */
    .btn-custom {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }
}

/* Desktop styles */
@media (min-width: 769px) {
    .bottom-nav {
        display: none;
    }
    
    .tabs-section {
        display: block;
    }
    
    .tab-content {
        margin-bottom: 0;
    }
}

/* Mobile-first bottom navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0.5rem 0;
    padding-bottom: calc(0.5rem + env(safe-area-inset-bottom));
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    border-top: 1px solid #f0f0f0;
}

.bottom-nav .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 8px;
    min-width: 60px;
}

.bottom-nav .nav-item i {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
    color: #999;
    transition: all 0.3s ease;
}

.bottom-nav .nav-item span {
    font-size: 0.75rem;
    color: #999;
    font-weight: 500;
    transition: all 0.3s ease;
}

.bottom-nav .nav-item.active {
    background: linear-gradient(135deg, var(--primary-color), #6c5ce7);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

.bottom-nav .nav-item.active i,
.bottom-nav .nav-item.active span {
    color: white;
}

.bottom-nav .nav-item:hover:not(.active) {
    background: rgba(248, 79, 72, 0.1);
}

.bottom-nav .nav-item:hover:not(.active) i,
.bottom-nav .nav-item:hover:not(.active) span {
    color: var(--primary-color);
}

/* Desktop tabs styling (hidden on mobile) */
.tabs-section {
    display: none;
    background: white;
    border-radius: var(--border-radius);
    margin: 1.5rem;
    box-shadow: var(--card-shadow);
    overflow: hidden;
}

.nav-tabs {
    border-bottom: none;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
}

.nav-tabs .nav-item {
    margin-bottom: 0;
}

.nav-tabs .nav-link {
    border: none;
    background: transparent;
    color: var(--dark-gray);
    font-weight: 500;
    padding: 1rem 1.5rem;
    transition: all 0.3s ease;
    border-radius: 0;
}

.nav-tabs .nav-link:hover {
    background: rgba(248, 79, 72, 0.1);
    color: var(--primary-color);
    border-color: transparent;
}

.nav-tabs .nav-link.active {
    background: linear-gradient(135deg, var(--primary-color), #ff6b6b);
    color: white;
    border-color: transparent;
    box-shadow: 0 2px 8px rgba(248, 79, 72, 0.3);
}

.tab-content {
    background: white;
    border-radius: var(--border-radius);
    margin-bottom: 80px; /* Space for bottom nav */
}

.tab-pane {
    padding: 0;
}

/* Enhanced card styles for tabs */
.notification-settings .card {
    border: none;
    box-shadow: var(--card-shadow);
    border-radius: var(--border-radius);
    transition: transform 0.2s ease;
}

.notification-settings .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.card .card-title {
    color: var(--primary-color);
    font-weight: 600;
}

/* Progress badge enhancement */
#progress-badge {
    background: linear-gradient(135deg, var(--secondary-color), #81C784) !important;
    font-size: 1rem;
    padding: 0.5rem 1rem;
    border-radius: 20px;
}

/* PWA specific styles */
.install-prompt {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    padding: 1rem;
    display: none;
    z-index: 1000;
}

.offline-indicator {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--warning-color);
    color: #212529;
    text-align: center;
    padding: 0.5rem;
    font-weight: 500;
    display: none;
    z-index: 1001;
} 