
/* Resetting default browser styles for consistency */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Setting up the body with a radial gradient background and smooth font */
body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    background: radial-gradient(circle, rgba(10, 91, 158, 0.8), rgba(255, 255, 255, 0.9));
    color: #333333;
    padding: 20px;
    transition: background 0.5s ease;
}

/* Styling the header with fixed navigation and gradient background */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background: linear-gradient(90deg, rgba(10, 91, 158, 0.9), rgba(255, 193, 7, 0.9));
    padding: 20px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

header .logo {
    font-size: 24px;
    font-weight: bold;
    color: #ffffff;
    text-decoration: none;
}

nav a {
    margin-left: 20px;
    text-decoration: none;
    color: #ffffff;
    font-weight: 500;
    transition: color 0.3s ease;
}

nav a:hover {
    color: #FFC107;
}

/* Main content area with top padding to avoid overlap with fixed header */
.main-content {
    padding-top: 100px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Styling articles with proper spacing and typography */
article {
    margin-bottom: 50px;
}

article h2 {
    font-size: 32px;
    color: #0A5B9E;
    margin-bottom: 20px;
}

article h3 {
    font-size: 24px;
    color: #0A5B9E;
    margin-top: 30px;
    margin-bottom: 15px;
}

article h4 {
    font-size: 20px;
    color: #0A5B9E;
    margin-top: 20px;
    margin-bottom: 10px;
}

article p {
    font-size: 16px;
    margin-bottom: 15px;
    color: #555555;
}

/* Styling tables with a clean and minimalistic look */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

table th, table td {
    border: 1px solid #dddddd;
    padding: 12px 15px;
    text-align: left;
}

table th {
    background-color: #0A5B9E;
    color: #ffffff;
}

table tr:nth-child(even) {
    background-color: #f9f9f9;
}

/* Styling code blocks with syntax highlighting and scroll prevention */
pre {
    background-color: #272822;
    color: #f8f8f2;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    font-family: 'Courier New', Courier, monospace;
    margin-bottom: 20px;
}

pre code {
    display: block;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Styling buttons with hover effects */
.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #FFC107;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.button:hover {
    background-color: #FF9800;
    transform: scale(1.05);
}

/* Footer styling with subtle background and text */
footer {
    background: linear-gradient(90deg, rgba(10, 91, 158, 0.9), rgba(255, 193, 7, 0.9));
    color: #ffffff;
    text-align: center;
    padding: 30px 20px;
    margin-top: 50px;
    border-radius: 10px;
}

/* Styling images to be responsive and fitting within content */
img {
    max-width: 100%;
    height: auto;
    margin: 20px 0;
    border-radius: 10px;
}

/* Styling for the visual impact section with dynamic lines */
.line-animation {
    width: 100%;
    height: 200px;
    background: linear-gradient(270deg, #0A5B9E, #FFC107, #0A5B9E);
    background-size: 600% 600%;
    animation: gradientMove 15s linear infinite;
    border-radius: 10px;
    margin: 40px 0;
}

@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Responsive design for various screen sizes */

/* Extra small devices (320px and up) */
@media (max-width: 320px) {
    header {
        padding: 15px 20px;
    }
    
    header .logo {
        font-size: 20px;
    }
    
    nav a {
        margin-left: 10px;
        font-size: 14px;
    }

    .main-content {
        padding: 80px 10px 20px 10px;
    }
}

/* Small devices (480px and up) */
@media (max-width: 480px) {
    header {
        padding: 15px 20px;
    }
    
    header .logo {
        font-size: 20px;
    }
    
    nav a {
        margin-left: 10px;
        font-size: 14px;
    }

    .line-animation {
        height: 150px;
    }
}

/* Medium devices (768px and up) */
@media (max-width: 768px) {
    header {
        padding: 18px 30px;
    }
    
    .main-content {
        padding: 100px 20px 20px 20px;
    }

    article h2 {
        font-size: 28px;
    }

    article h3 {
        font-size: 22px;
    }

    article h4 {
        font-size: 18px;
    }

    .line-animation {
        height: 180px;
    }
}

/* Large devices (1024px and up) */
@media (max-width: 1024px) {
    header {
        padding: 20px 40px;
    }
    
    .main-content {
        padding: 120px 40px 40px 40px;
    }

    article h2 {
        font-size: 30px;
    }

    article h3 {
        font-size: 20px;
    }

    article h4 {
        font-size: 18px;
    }
}

/* Extra large devices (1200px and up) */
@media (max-width: 1200px) {
    header {
        padding: 25px 60px;
    }
    
    .main-content {
        padding: 140px 60px 60px 60px;
    }
}

/* Ultra large devices (1440px and up) */
@media (max-width: 1440px) {
    header {
        padding: 30px 80px;
    }
    
    .main-content {
        padding: 160px 80px 80px 80px;
    }
}

/* Ensuring no horizontal scroll on code blocks */
pre {
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Additional elements styling for better user experience */
.highlight {
    background-color: #FFECB3;
    padding: 2px 4px;
    border-radius: 3px;
}

ul {
    list-style-type: disc;
    margin-left: 20px;
    margin-bottom: 20px;
}

ol {
    list-style-type: decimal;
    margin-left: 20px;
    margin-bottom: 20px;
}

a {
    color: #0A5B9E;
    text-decoration: none;
}

a:hover {
    color: #FFC107;
    text-decoration: underline;
}

/* Tooltip styling for interactive elements */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 200px;
    background-color: #555555;
    color: #ffffff;
    text-align: center;
    border-radius: 6px;
    padding: 5px 0;
    position: absolute;
    z-index: 1;
    bottom: 125%; 
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

