/* Enhanced CSS with All Improvements */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #1a252f;
    --shadow: 0 10px 20px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Poppins', Arial, sans-serif;
    background-color: #f4f4f9;
    margin: 0;
    padding: 0;
    padding-top: 80px;
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

/* Enhanced Navbar */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--dark-color));
    color: white;
    padding: 15px 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: var(--shadow);
    border-bottom: 3px solid var(--secondary-color);
}

nav ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 5px;
}

nav ul li {
    position: relative;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 12px 20px;
    border-radius: 6px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    font-size: 15px;
    position: relative;
    overflow: hidden;
}

nav ul li a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--secondary-color);
    transition: width 0.3s ease;
}

nav ul li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

nav ul li a:hover::before {
    width: 60%;
}

nav ul li a i {
    margin-right: 10px;
    font-size: 18px;
    transition: transform 0.3s ease;
}

nav ul li a:hover i {
    transform: scale(1.1);
}

/* Active Nav Link */
nav ul li a.active {
    background-color: rgba(52, 152, 219, 0.15);
    border: 1px solid rgba(52, 152, 219, 0.4);
    box-shadow: inset 0 0 10px rgba(52, 152, 219, 0.2);
}

nav ul li a.active::before {
    width: 80%;
    background: var(--accent-color);
}

/* Main Content */
main {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Container Styles */
.container {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
    transition: var(--transition);
}

.container:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

h1, h2, h3 {
    margin-top: 0;
    color: var(--primary-color);
    text-align: center;
    position: relative;
    padding-bottom: 10px;
}

h1::after, h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--secondary-color);
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--primary-color);
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    outline: none;
}

/* Button Styles */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: white;
}

.btn-primary:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(41, 128, 185, 0.4);
}

.btn-success {
    background-color: #4CAF50;
    color: white;
}

.btn-success:hover {
    background-color: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(76, 175, 80, 0.4);
}

/* Card Styles */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

/* Video Section */
.video-section {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.video-item {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
}

.video-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.video-container {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Footer Styles */
footer {
    background: linear-gradient(135deg, var(--primary-color), var(--dark-color));
    color: white;
    text-align: center;
    padding: 25px 0;
    position: relative;
    margin-top: 50px;
    width: 100%; /* Ensure footer takes full width */
    box-sizing: border-box; /* Include padding in width calculation */
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--secondary-color);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Responsive Adjustments for Footer */
@media (max-width: 768px) {
    footer {
        padding: 20px 0; /* Adjust padding for smaller screens */
    }
    
    .footer-content {
        padding: 0 10px; /* Reduce padding for smaller screens */
    }
}

@media (max-width: 480px) {
    footer {
        padding: 15px 0; /* Further adjust padding for very small screens */
    }
    
    .footer-content {
        padding: 0 5px; /* Minimal padding for very small screens */
    }
}


/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
    100% { transform: translateY(0px); }
}

.float {
    animation: float 2s ease-in-out infinite;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    nav ul li a {
        padding: 10px 15px;
    }
    
    .container {
        padding: 1.5rem;
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 70px;
    }
    
    nav ul {
        justify-content: space-around;
        gap: 2px;
    }
    
    nav ul li a {
        padding: 8px 10px;
        font-size: 14px;
    }
    
    .container {
        padding: 1rem;
    }
    
    .video-section {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    nav ul li a {
        padding: 6px 8px;
        font-size: 13px;
    }
    
    nav ul li a i {
        font-size: 14px;
    }
    
    h1 {
        font-size: 1.8rem;
    }
}
