/* Training Platform Styles */

/* Navigation Improvements */
.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link:focus {
    color: white;
}

.navbar-dark .navbar-nav .nav-link.active {
    color: white;
    font-weight: 600;
}

.navbar-brand img {
    transition: transform 0.3s ease;
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

/* Demo Notice */
.alert {
    border-radius: 0;
    border: none;
    margin-bottom: 0;
}

/* Hero Section */
.training-hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 120px 0 80px;
    position: relative;
    overflow: hidden;
}

.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.hero-shapes {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    z-index: -1;
}

.hero-shapes .shape {
    position: absolute;
    opacity: 0.1;
    animation: float 6s ease-in-out infinite;
}

.shape-1 {
    top: 20%;
    left: 10%;
    width: 60px;
    height: 60px;
    background: white;
    border-radius: 50%;
    animation-delay: 0s;
}

.shape-2 {
    top: 60%;
    right: 15%;
    width: 80px;
    height: 80px;
    background: white;
    transform: rotate(45deg);
    animation-delay: 2s;
}

.shape-3 {
    bottom: 20%;
    left: 20%;
    width: 0;
    height: 0;
    border-left: 40px solid transparent;
    border-right: 40px solid transparent;
    border-bottom: 70px solid white;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Access Overlay */
.access-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.access-overlay.show {
    opacity: 1;
}

.access-content {
    max-width: 600px;
    width: 90%;
    padding: 2rem;
}

.access-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    text-align: center;
    animation: slideInUp 0.5s ease-out;
}

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

.access-card h2 {
    color: #333;
    margin-bottom: 1rem;
    font-weight: 700;
}

.access-card .lead {
    color: #666;
    margin-bottom: 2rem;
}

.access-card .btn {
    border-radius: 12px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

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

.access-card .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.access-card .btn:hover::before {
    left: 100%;
}

.access-card ul {
    text-align: left;
    margin: 1.5rem 0;
}

.access-card li {
    padding: 0.5rem 0;
    font-size: 1.05rem;
}

.access-card li i {
    color: #28a745;
    margin-right: 0.75rem;
}

/* Enhanced button loading states */
.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
}

.btn .fa-spinner {
    animation: spin 1s linear infinite;
}

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

/* Enhanced Dashboard Elements */
#mainContent {
    opacity: 0;
    transition: opacity 0.5s ease;
}

#mainContent.show {
    opacity: 1;
}

.welcome-header {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid #e9ecef;
}

.study-streak {
    background: linear-gradient(135deg, #fff3cd, #ffeaa7);
    border: 1px solid #ffd93d;
    border-radius: 25px;
    padding: 10px 20px;
    font-size: 0.95rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
}

.training-nav {
    background: white;
    border-radius: 20px;
    padding: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.training-nav .nav-pills .nav-link {
    border-radius: 15px;
    padding: 15px 25px;
    font-weight: 600;
    color: var(--gray);
    background: transparent;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    margin: 0 5px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.training-nav .nav-pills .nav-link.active {
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    color: white;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(177, 141, 77, 0.3);
}

.training-nav .nav-pills .nav-link:hover:not(.active) {
    background: rgba(177, 141, 77, 0.1);
    border-color: var(--primary);
    transform: translateY(-1px);
}

/* Quick Actions */
.quick-actions {
    margin-bottom: 30px;
}

.quick-actions .action-card {
    background: white;
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    height: 100%;
    border: 1px solid #e9ecef;
    position: relative;
    overflow: hidden;
}

.quick-actions .action-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.quick-actions .action-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.quick-actions .action-card:hover::before {
    transform: scaleX(1);
}

.action-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    margin: 0 auto 20px;
    transition: all 0.3s ease;
}

.quick-actions .action-card:hover .action-icon {
    transform: scale(1.1) rotate(5deg);
}

.action-content h5 {
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--secondary);
}

.action-content p {
    color: var(--gray);
    margin-bottom: 15px;
    font-size: 0.9rem;
}

/* Enhanced Progress Card */
.progress-card {
    background: white;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid #e9ecef;
}

.progress-card h3 {
    color: var(--secondary);
    font-weight: 700;
    margin-bottom: 25px;
}

.progress-items {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.progress-item {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 15px;
    border: 1px solid #e9ecef;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.progress-label {
    font-weight: 600;
    color: var(--secondary);
    font-size: 1rem;
}

.progress-percentage {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.1rem;
}

.progress {
    height: 10px;
    border-radius: 10px;
    background-color: #e9ecef;
    overflow: hidden;
}

.progress-bar {
    border-radius: 10px;
    transition: width 0.6s ease;
}

/* Enhanced Stat Cards */
.stat-card.enhanced {
    background: white;
    border-radius: 20px;
    padding: 30px 25px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    border: 1px solid #e9ecef;
    height: 100%;
}

.stat-card.enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.stat-card.enhanced:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

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

.stat-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: white;
    margin: 0 auto 20px;
    transition: all 0.3s ease;
}

.stat-card.enhanced:hover .stat-icon {
    transform: scale(1.1);
    box-shadow: 0 10px 25px rgba(177, 141, 77, 0.3);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
    line-height: 1;
}

.stat-label {
    color: var(--gray);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 10px;
}

.stat-trend {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 5px 10px;
    border-radius: 15px;
    background: #f8f9fa;
    display: inline-block;
}

/* Activity & Recommendations Cards */
.activity-card, .recommendations-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    height: 100%;
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.activity-card .card-header,
.recommendations-card .card-header {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-bottom: 1px solid #dee2e6;
    border-radius: 20px 20px 0 0;
    padding: 25px;
}

.activity-card .card-header h5,
.recommendations-card .card-header h5 {
    margin: 0;
    font-weight: 700;
    color: var(--secondary);
    display: flex;
    align-items: center;
}

.activity-card .card-body,
.recommendations-card .card-body {
    padding: 25px;
}

/* Activity Timeline */
.activity-timeline {
    padding: 10px 0;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 15px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.activity-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.activity-item:last-child {
    margin-bottom: 0;
}

.activity-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    margin-right: 15px;
    flex-shrink: 0;
    font-size: 0.9rem;
}

.activity-content {
    flex: 1;
}

.activity-content h6 {
    margin: 0 0 5px;
    font-weight: 700;
    color: var(--secondary);
    font-size: 1rem;
}

.activity-content p {
    margin: 0 0 5px;
    color: var(--gray);
    font-size: 0.9rem;
}

.activity-time {
    font-size: 0.8rem;
    color: var(--gray);
    font-style: italic;
}

/* Recommendations */
.recommendation-item {
    display: flex;
    align-items: flex-start;
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.recommendation-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
}

.recommendation-item.priority-high {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.1), rgba(220, 53, 69, 0.05));
    border-left: 4px solid #dc3545;
    border-color: rgba(220, 53, 69, 0.3);
}

.rec-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    margin-right: 15px;
    flex-shrink: 0;
    font-size: 0.9rem;
}

.recommendation-item.priority-high .rec-icon {
    background: #dc3545;
}

.rec-content {
    flex: 1;
}

.rec-content h6 {
    margin: 0 0 8px;
    font-weight: 700;
    color: var(--secondary);
    font-size: 1rem;
}

.rec-content p {
    margin: 0 0 10px;
    color: var(--gray);
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Toast Notifications */
.toast-container {
    z-index: 9999;
}

.toast {
    border-radius: 15px;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    margin-bottom: 10px;
}

.toast .toast-body {
    padding: 15px;
    font-weight: 500;
}

/* Enhanced Authentication Modal Styles */
.auth-modal .modal-dialog {
    max-width: 500px;
    margin: 2rem auto;
}

.auth-modal .modal-content {
    border-radius: 20px;
    border: none;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    overflow: hidden;
}

.auth-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 3rem 2.5rem 2rem;
    text-align: center;
    border-radius: 0;
}

.auth-header h4 {
    font-weight: 700;
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.auth-header p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin: 0;
}

.auth-body {
    padding: 2.5rem;
    background: white;
}

.auth-tabs {
    display: flex;
    margin-bottom: 2.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 6px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

.auth-tab {
    flex: 1;
    padding: 1rem 1.5rem;
    text-align: center;
    border: none;
    background: transparent;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 1rem;
    color: #6c757d;
    cursor: pointer;
}

.auth-tab.active {
    background: white;
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    transform: translateY(-1px);
}

.auth-tab:hover:not(.active) {
    background: rgba(255,255,255,0.7);
    color: var(--primary);
}

#authAlert {
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 2rem;
}

.form-group:last-of-type {
    margin-bottom: 2.5rem;
}

.form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.form-control {
    border-radius: 12px;
    border: 2px solid #e9ecef;
    padding: 1rem 1.25rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(177, 141, 77, 0.25);
    background: white;
    transform: translateY(-1px);
}

.form-control::placeholder {
    color: #adb5bd;
    font-weight: 400;
}

.form-text {
    font-size: 0.85rem;
    color: #6c757d;
    margin-top: 0.5rem;
}

.form-check {
    margin: 1.5rem 0;
    padding-left: 0;
}

.form-check-input {
    margin-right: 0.75rem;
    border-radius: 4px;
    border: 2px solid #dee2e6;
    width: 1.25rem;
    height: 1.25rem;
}

.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.form-check-label {
    font-size: 0.95rem;
    color: #495057;
    cursor: pointer;
}

.auth-submit {
    width: 100%;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border: none;
    color: white;
    box-shadow: 0 4px 15px rgba(177, 141, 77, 0.3);
}

.auth-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(177, 141, 77, 0.4);
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
}

.auth-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
}

.auth-divider {
    text-align: center;
    margin: 2rem 0;
    position: relative;
    color: #6c757d;
    font-weight: 500;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e9ecef;
    z-index: 1;
}

.auth-divider span {
    background: white;
    padding: 0 1.5rem;
    position: relative;
    z-index: 2;
    font-size: 0.9rem;
}

.google-signin-btn {
    width: 100%;
    padding: 1rem 1.5rem;
    border: 2px solid #e9ecef;
    background: white;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 1rem;
    color: #495057;
    cursor: pointer;
}

.google-signin-btn:hover {
    border-color: #4285f4;
    background: #f8f9ff;
    color: #4285f4;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.2);
}

.btn-link {
    color: var(--primary);
    font-weight: 500;
    text-decoration: none;
    font-size: 0.95rem;
}

.btn-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Enhanced alerts */
.alert {
    border-radius: 12px;
    border: none;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.alert-success {
    background: rgba(40, 167, 69, 0.1);
    color: #155724;
    border-left: 4px solid #28a745;
}

.alert-danger {
    background: rgba(220, 53, 69, 0.1);
    color: #721c24;
    border-left: 4px solid #dc3545;
}

.alert-warning {
    background: rgba(255, 193, 7, 0.1);
    color: #856404;
    border-left: 4px solid #ffc107;
}

.alert i {
    margin-right: 0.5rem;
}

/* Loading spinner animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fa-spinner {
    animation: spin 1s linear infinite;
}

/* Responsive Design */
@media (max-width: 991px) {
    .access-card {
        padding: 30px 25px;
    }
    
    .welcome-header {
        padding: 25px;
        text-align: center;
    }
    
    .training-nav .nav-pills .nav-link {
        padding: 12px 15px;
        font-size: 0.9rem;
    }
    
    .quick-actions .action-card {
        padding: 20px;
        margin-bottom: 15px;
    }
    
    .action-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .stat-card.enhanced {
        padding: 25px 20px;
        margin-bottom: 20px;
    }
    
    .progress-card,
    .activity-card .card-body,
    .recommendations-card .card-body {
        padding: 25px 20px;
    }
}

@media (max-width: 767px) {
    .access-content {
        width: 95%;
    }
    
    .access-card {
        padding: 25px 20px;
    }
    
    .access-actions .btn {
        min-width: auto;
        width: 100%;
        margin: 5px 0;
    }
    
    .training-nav {
        padding: 10px;
    }
    
    .training-nav .nav-pills .nav-link {
        padding: 10px 12px;
        margin: 2px;
        font-size: 0.85rem;
    }
    
    .training-nav .nav-pills .nav-link i {
        margin-right: 5px;
    }
    
    .welcome-header h2 {
        font-size: 1.5rem;
    }
    
    .study-streak {
        margin-top: 15px;
        font-size: 0.85rem;
    }
    
    .quick-actions .action-card {
        text-align: center;
        margin-bottom: 15px;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .activity-item,
    .recommendation-item {
        flex-direction: column;
        text-align: center;
        padding: 15px;
    }
    
    .activity-icon,
    .rec-icon {
        margin-right: 0;
        margin-bottom: 10px;
    }
}
