/* Base styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background: #f5f5f5;
    color: #333;
    overflow-x: hidden; /* Prevents horizontal overflow */
}

/* Header with gradient and shadow */
header {
    background: linear-gradient(to right, #007bff, #6610f2);
    color: #ffffff;
    padding: 20px 0;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16);
    text-align: center;
}

/* Improved navigation bar */
nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    background-color: #343a40;
    overflow: hidden;
}

nav ul li {
    display: inline-block;
}

nav ul li a {
    display: block;
    padding: 15px 20px;
    color: white;
    text-decoration: none;
    transition: background 0.3s ease;
}

nav ul li a:hover, nav ul li a:focus {
    background-color: #007bff;
}

/* Content section with padding and dynamic margins */
section {
    padding: 20px;
    margin: 20px;
    background-color: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,0.12);
    border-radius: 8px;
    overflow-y: auto; /* Allows vertical scrolling within sections if content overflows */
}

/* Footer with fixed positioning */
footer {
    background-color: #343a40;
    color: white;
    text-align: center;
    padding: 10px;
    position: fixed;
    bottom: 0;
    width: 100%;
}

/* Responsive design adjustments */
@media (max-width: 768px) {
    nav ul li {
        display: block;
    }

    section, footer {
        margin-left: 10px;
        margin-right: 10px;
    }
}

/* Enhancements for aesthetics */
h1, h2, h3, h4, h5, h6 {
    color: #343a40;
}

a {
    color: #007bff;
    transition: color 0.2s ease-in-out;
}

a:hover, a:focus {
    color: #0056b3;
}
