/* Basic Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body Style */
body {
    font-family: 'Arial', sans-serif;
    background-color: #f4f4f4;
    color: #333;
    transition: background-color 0.3s ease, color 0.3s ease;
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Dark Mode */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

/* Header Style */
header {
    text-align: center;
    margin-bottom: 20px;
    padding: 80px 20px;
    position: relative;
    overflow: hidden;
    background: #f4f4f4;
    color: #333;
    border-radius: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    animation: fadeIn 2s ease-out;
}

/* Wave Background Style */
header .wave-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    background: linear-gradient(135deg, #a2c2e3, #f7a8b7, #f9f585);
    background-size: 400% 400%;
    animation: waveAnimation 15s ease-in-out infinite;
    z-index: 0;
}

/* Keyframe Animations */
@keyframes waveAnimation {
    0% { background-position: 0% 0%; }
    50% { background-position: 100% 100%; }
    100% { background-position: 0% 0%; }
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: #333 }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Header Title Style */
header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    font-weight: 300;
    overflow: hidden;
    white-space: nowrap;
    letter-spacing: .15em;
    display: inline-block;
    border-right: .15em solid #333;
    position: relative;
    z-index: 1;
    animation: typing 4s steps(40, end), blink-caret 1s step-end infinite;
    max-width: 80%;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    header {
        padding: 60px 15px; /* Adjust padding for tablets and small screens */
    }

    header h1 {
        font-size: 1em;
        font-style: bold; /* Adjust font size for tablets and small screens */
    }
}

@media (max-width: 480px) {
    header {
        padding: 40px 10px; /* Further adjust padding for very small screens */
    }

    header h1 {
        font-size: 1em;
        font-style: bold; /* Further adjust font size for very small screens */
    }
}

/* Navbar Style */
.navbar {
    background-color: #333;
    padding: 10px;
    border-radius: 20px;
    margin-bottom: 30px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    animation: fadeIn 2s ease-out;
}

.navbar ul {
    list-style-type: none;
    display: flex;
    justify-content: center;
    margin: 0;
    padding: 0;
}

.navbar ul li {
    margin: 0 10px;
}

.navbar ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease, transform 0.3s ease;
}

.navbar ul li a:hover {
    color: #cfbf0a;
    transform: scale(1.05);
}

/* Section Styles */
section {
    margin-bottom: 20px;
    animation: fadeIn 1.5s ease-out;
}

.home-content,
.project-intro-box,
.project-overview {
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: justify;
}

.home-content:hover,
.project-intro-box:hover,
.project-overview:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

#github {
    text-align: justify;
}

/* Image Gallery Styles */
.image-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* Two images per row */
    gap: 20px;
    margin-bottom: 20px;
}

.gallery-item {
    text-align: center;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item img {
    width: 100%;
    height: auto; /* Maintain aspect ratio */
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-text {
    margin-top: 10px; /* Space between image and text */
    color: #333; /* Ensure text color is readable */
    font-size: 1em; /* Adjust font size as needed */
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-text {
    opacity: 0.8;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .image-gallery {
        grid-template-columns: repeat(2, 1fr); /* Maintain two images per row on tablets */
    }

    .gallery-text {
        font-size: 0.9em; /* Adjust font size for tablets */
    }
}

@media (max-width: 480px) {
    .image-gallery {
        grid-template-columns: repeat(1, 1fr); /* One image per row on mobile screens */
    }

    .gallery-text {
        font-size: 0.8em; /* Adjust font size for mobile screens */
    }
}

#github ul {
    list-style-type: none;
}

#github ul li {
    margin: 10px 0;
}

#github ul li a {
    color: #333;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease, transform 0.3s ease;
}

#github ul li a:hover {
    color: #cfbf0a;
    transform: scale(1.05);
}

/* Footer Styles */
footer {
    text-align: center;
    padding: 10px;
    background-color: #333;
    color: #fff;
    margin-top: auto;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    animation: fadeIn 2s ease-out;
}

/* Additional Styles */
/* Power BI Report Styles */
.powerbi-report {
    width: 100%;
    overflow: hidden; /* Prevents overflow issues */
    padding: 0;
    margin-bottom: 20px;
    animation: fadeIn 1.5s ease-out;
}

.powerbi-report iframe {
    width: 100%;
    height: 100%;
    min-height: 500px; /* Ensure a minimum height */
    border-radius: 10px;
    border: none; /* Removes border for a cleaner look */
}

/* Responsive Power BI Report */
@media (max-width: 768px) {
    .powerbi-report iframe {
        min-height: 400px; /* Adjust height for smaller screens */
    }
}

@media (max-width: 480px) {
    .powerbi-report iframe {
        min-height: 300px; /* Further adjust height for very small screens */
    }
}

/* Common Styles for Section Headings */
section h2, .project-intro-box h3, .project-overview h3, .powerbi-report h3 {
    font-family: 'Arial', sans-serif;
    color: #333;
    text-align: center;
    margin: 30px 0 20px; /* Space between heading and content */
    font-weight: bold;
    letter-spacing: 0.05em;
    position: relative;
    padding-bottom: 10px;
    border-bottom: 3px solid #cfbf0a; /* Underline for emphasis */
    transition: color 0.3s ease, border-color 0.3s ease;
}

/* Hover Effect for Headings */
section h2:hover, .project-intro-box h3:hover, .project-overview h3:hover, .powerbi-report h3:hover {
    color: #cfbf0a;
    border-bottom-color: #333;
}

section h3 {
    font-family: 'Arial', sans-serif;
    color: #333;
    text-align: center;
    margin: 30px 0 20px; /* Space between heading and content */
    font-weight: bold;
    letter-spacing: 0.05em;
    position: relative;
    padding-bottom: 10px;
    border-bottom: 3px solid #098cef; /* Underline for emphasis */
    transition: color 0.3s ease, border-color 0.3s ease;
}

section h3:hover {
    color: #098cef;
    border-bottom-color: #333;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    section h2, h3, .project-intro-box h3, .project-overview h3, .powerbi-report h3 {
        font-size: 1.8em; /* Slightly smaller font size on tablets */
    }
}

@media (max-width: 480px) {
    section h2, h3, .project-intro-box h3, .project-overview h3, .powerbi-report h3 {
        font-size: 1.5em; /* Further reduce font size on mobile screens */
    }
}