/**
 * App.html Specific Styles
 * Additional styles for the SPA that don't conflict with other pages
 */

/* ========================================
   SPA LAYOUT & NAVIGATION
   ======================================== */

.app-section {
    min-height: 100vh;
    padding: 2rem 0;
    display: none;
}

.app-section.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

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

.app-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.app-content {
    margin-top: 80px;
}

/* ========================================
   LOADING STATES
   ======================================== */

.loading-spinner {
    display: none;
    text-align: center;
    padding: 2rem;
}

.loading-spinner.active {
    display: block;
}

/* ========================================
   PREGNANCY HERO SECTION
   ======================================== */

.pregnancy-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 1.5rem;
    padding: 2rem;
    margin-bottom: 2rem;
    color: white;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.3);
}

.pregnancy-week-circle {
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.pregnancy-week-circle .week-number {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1;
    color: white;
}

.pregnancy-week-circle .week-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

/* ========================================
   HIDDEN ELEMENTS (Dynamic Display)
   ======================================== */

#userMenu[style*="display: none"],
#welcomeLoggedUser[style*="display: none"],
#dashboardContent[style*="display: none"],
#profileContent[style*="display: none"] {
    /* Inline styles override, but adding here for clarity */
    display: none !important;
}

#userMenu.active,
#welcomeLoggedUser.active,
#dashboardContent.active,
#profileContent.active {
    display: block !important;
}

/* ========================================
   APP-SPECIFIC OVERRIDES
   ======================================== */

/* Quick action cards inherit from v2-enhancements.css */
.quick-action-card {
    cursor: pointer !important;
}

/* Feature cards use v2-enhancements.css styles */
.feature-card {
    cursor: default;
}

/* ========================================
   APP WEEK BADGE
   ======================================== */

#appWeekBadgeContainer {
    display: flex;
    align-items: center;
}

#appWeekBadge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 2rem;
    font-weight: 700;
    font-size: 0.95rem;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    white-space: nowrap;
}

#appWeekBadge:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

#appWeekBadge i {
    margin-left: 0.25rem;
}

/* ========================================
   DROPDOWN ENHANCEMENTS FOR APP NAV
   ======================================== */

.app-nav .dropdown-menu {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    padding: 0.75rem;
    margin-top: 0.5rem;
}

.app-nav .dropdown-item {
    border-radius: 0.75rem;
    padding: 0.9rem 1.2rem;
    margin-bottom: 0.25rem;
    transition: all 0.2s ease;
    font-weight: 500;
}

.app-nav .dropdown-item:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.15) 0%, rgba(118, 75, 162, 0.15) 100%);
    color: #667eea;
    transform: translateX(-5px);
}

.app-nav .dropdown-item .badge {
    margin-right: 0.5rem;
}

/* ========================================
   NAV PILLS OVERRIDE FOR APP
   ======================================== */

.app-nav .nav-pills .nav-link {
    border-radius: 0.75rem;
    padding: 0.75rem 1.25rem;
    margin: 0 0.25rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.app-nav .nav-pills .nav-link:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    color: #667eea;
}

.app-nav .nav-pills .nav-link.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* ========================================
   RESPONSIVE ADJUSTMENTS
   ======================================== */

@media (max-width: 991px) {
    #appWeekBadge {
        font-size: 0.8rem;
        padding: 0.5rem 1rem;
    }
    
    .pregnancy-week-circle {
        width: 100px;
        height: 100px;
    }
    
    .pregnancy-week-circle .week-number {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .app-content {
        margin-top: 70px;
    }
    
    .pregnancy-hero {
        padding: 1.5rem;
    }
    
    #appWeekBadgeContainer {
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 576px) {
    #appWeekBadge {
        font-size: 0.75rem;
        padding: 0.4rem 0.8rem;
    }
    
    #appWeekBadge i {
        display: none; /* Hide icon on very small screens */
    }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

@media (prefers-reduced-motion: reduce) {
    .app-section.active,
    #appWeekBadge,
    .app-nav .nav-pills .nav-link,
    .app-nav .dropdown-item {
        animation: none;
        transition: none;
    }
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {
    .app-nav {
        position: static;
        box-shadow: none;
    }
    
    .app-content {
        margin-top: 0;
    }
    
    #appWeekBadge {
        background: #667eea !important;
        color: white !important;
    }
}
