/* General Body Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #000000; /* Pure black background */
    color: #ffffff; /* Pure white text */
    margin: 0;
    padding: 0;
    line-height: 1.8;
    overflow-y: auto; /* Allow vertical scrolling */
    overflow-x: hidden; /* Prevent horizontal scrolling */
    position: relative;
}

canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1; /* Place behind content */
    opacity: 0.3; /* Dim the background animation */
}

.content-wrapper {
    position: relative;
    z-index: 1; /* Ensure content is above canvas */
    padding: 20px; /* Overall padding from boundaries */
    box-sizing: border-box;
    min-height: calc(100vh - 40px); /* Adjust min-height to account for body padding */
    display: flex;
    flex-direction: column;
}

.content-wrapper {
    position: relative;
    z-index: 1; /* Ensure content is above canvas */
    padding: 20px; /* Overall padding from boundaries */
    box-sizing: border-box;
    min-height: 100vh; /* Ensure wrapper takes full height */
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 25px;
    box-sizing: border-box; /* Include padding in width calculation */
}

.content-wrapper {
    position: relative;
    z-index: 1; /* Ensure content is above canvas */
    padding: 20px; /* Overall padding from boundaries */
    box-sizing: border-box;
    min-height: 100vh; /* Ensure wrapper takes full height */
    display: flex;
    flex-direction: column;
}

/* Header and Navigation */
header {
    background-color: rgba(0, 0, 0, 0.8); /* Semi-transparent background */
    padding: 1.5rem 0;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3), 0 2px 15px rgba(0, 0, 0, 0.7); /* White glow boundary + existing shadow */
    position: sticky;
    top: 20px; /* Not touching top boundary */
    z-index: 1000;
    border-radius: 15px; /* Rounded corners */
    margin-bottom: 20px; /* Space from next section */
    backdrop-filter: blur(5px); /* Frosted glass effect */
}

header .container {
    display: flex;
    justify-content: space-between; /* Distribute items */
    align-items: center;
    gap: 10px; /* Add a gap between the logo and the text */
}

header h1 {
    margin: 0;
    font-size: 2.5rem;
    color: #ffffff; /* White text */
    letter-spacing: 2px;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
    animation: fadeIn 1s ease-out;
    flex-shrink: 0; /* Prevent shrinking */
}

.header-logo {
    max-height: 100px; /* Default size for logo */
    width: auto;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    display: inline-block;
    margin-left: 30px;
}

nav ul li a {
    color: #ffffff;
    text-decoration: none;
    font-size: 1.5rem; /* Increased font size */
    font-weight: 700; /* Bolder font weight */
    font-family: 'Arial Black', Gadget, sans-serif; /* Changed font */
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

nav ul li a:hover {
    color: #bbbbbb;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.9);
}

/* Hero Section */
.hero {
    background: rgba(0, 0, 0, 0.7); /* Dimmed background for hero section */
    padding: 100px 0; /* Adjusted padding */
    text-align: center;
    position: relative;
    overflow: hidden;
    border-radius: 15px; /* Rounded corners */
    margin-bottom: 20px; /* Space from next section */
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3), 0 5px 25px rgba(0, 0, 0, 0.8); /* White glow boundary + existing shadow */
    backdrop-filter: blur(5px); /* Frosted glass effect */
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.03) 0%, transparent 70%);
    animation: pulse 5s infinite alternate;
}

@keyframes pulse {
    from { transform: scale(1); opacity: 0.5; }
    to { transform: scale(1.1); opacity: 0.7; }
}

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

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes rotateIn {
    from { opacity: 0; transform: rotate(-15deg) scale(0.8); }
    to { opacity: 1; transform: rotate(0deg) scale(1); }
}

.hero h2 {
    font-size: 3.8rem;
    color: #ffffff;
    margin-bottom: 20px;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.9);
    position: relative;
    z-index: 1;
    animation: fadeIn 1s ease-out;
}

.hero p {
    font-size: 1.4rem;
    color: #ffffff;
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    animation: fadeIn 1.5s ease-out 0.5s forwards; /* Delayed fade in */
}

/* Section Styling */
section {
    padding: 60px 0; /* Adjusted padding */
    background-color: rgba(0, 0, 0, 0.7); /* Dimmed background for sections */
    margin-top: 0;
    border-radius: 15px; /* Rounded corners */
    margin-bottom: 20px; /* Space from next section */
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3), 0 5px 25px rgba(0, 0, 0, 0.8); /* White glow boundary + existing shadow */
    backdrop-filter: blur(5px); /* Frosted glass effect */
}

section:nth-of-type(even) {
    background-color: rgba(0, 0, 0, 0.75); /* Slightly different dim for even sections */
}

section h3 {
    font-size: 2.8rem;
    color: #ffffff;
    text-align: center;
    margin-bottom: 60px;
    text-shadow: 0 0 12px rgba(255, 255, 255, 0.7);
    animation: fadeIn 1s ease-out;
}

/* Project Section */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.project-item {
    background-color: rgba(10, 10, 10, 0.9); /* Slightly transparent background */
    padding: 30px;
    border-radius: 15px; /* Increased border-radius for more rounded corners */
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.2), 0 5px 25px rgba(0, 0, 0, 0.8); /* White glow boundary + existing shadow */
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    border: 1px solid #111111;
    animation: slideInLeft 1s ease-out; /* Example animation */
}

.project-item:hover {
    transform: translateY(-15px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.9);
}

.project-item h4 {
    font-size: 1.8rem;
    color: #ffffff;
    margin-top: 0;
    margin-bottom: 15px;
    border-bottom: 2px solid #ffffff;
    padding-bottom: 10px;
}

.project-item p {
    font-size: 1.1rem;
    color: #ffffff;
    margin-bottom: 15px;
}

.project-item a {
    color: #ffffff;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.project-item a:hover {
    color: #bbbbbb;
    text-decoration: underline;
}

.steam-button {
    display: inline-block;
    margin-top: 10px; /* Space above the button */
}

.steam-logo {
    width: 100px; /* Adjust size as needed */
    height: auto;
    transition: transform 0.3s ease;
}

.steam-logo:hover {
    transform: scale(1.1); /* Slightly enlarge on hover */
}

.project-item-link {
    display: block; /* Make the entire link block-level */
    height: 100%; /* Ensure it covers the entire project-item */
    width: 100%; /* Ensure it covers the entire project-item */
}

/* About Page Specifics */
.content-section {
    padding: 40px; /* Added padding for better design */
}

.content-section ul {
    list-style: none;
    padding: 0;
    margin-top: 30px;
}

.content-section ul li {
    background-color: #0a0a0a;
    margin-bottom: 15px;
    padding: 20px;
    border-left: 5px solid #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.6);
    animation: slideInRight 1s ease-out; /* Example animation */
}

.content-section ul li strong {
    color: #ffffff;
    font-size: 1.2rem;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

/* Contact Form Styles */
.contact-form-container {
    background-color: rgba(10, 10, 10, 0.9);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.2), 0 5px 25px rgba(0, 0, 0, 0.8);
    max-width: 600px;
    margin: 40px auto 20px auto; /* Center the form and add space */
}

.contact-form .form-group {
    margin-bottom: 20px;
    text-align: left;
}

.contact-form label {
    display: block;
    margin-bottom: 8px;
    font-size: 1.1rem;
    color: #ffffff;
}

.contact-form input[type="email"],
.contact-form input[type="text"],
.contact-form textarea {
    width: calc(100% - 20px); /* Account for padding */
    padding: 12px;
    border: 1px solid #333;
    border-radius: 8px;
    background-color: #1a1a1a;
    color: #ffffff;
    font-size: 1rem;
    box-sizing: border-box; /* Include padding in width */
}

.contact-form textarea {
    resize: vertical; /* Allow vertical resizing */
    min-height: 120px;
}

.contact-form input[type="email"]:focus,
.contact-form input[type="text"]:focus,
.contact-form textarea:focus {
    border-color: #555;
    outline: none;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.contact-form .submit-button {
    background-color: #007bff; /* Blue button */
    color: #ffffff;
    padding: 12px 25px;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.contact-form .submit-button:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
}

/* Footer */
footer {
    background-color: rgba(0, 0, 0, 0.8); /* Semi-transparent background */
    color: #ffffff;
    text-align: center;
    padding: 20px 0; /* Adjusted padding */
    margin-top: auto; /* Push footer to bottom */
    border-radius: 15px; /* Rounded corners */
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3), 0 -2px 15px rgba(0, 0, 0, 0.7); /* White glow boundary + existing shadow */
    backdrop-filter: blur(5px); /* Frosted glass effect */
}

/* Responsive Design */
@media (max-width: 768px) {
    .content-wrapper {
        padding: 10px; /* Reduce overall padding on smaller screens */
    }

    header {
        top: 10px;
        margin-bottom: 10px;
    }

    header .container {
        flex-direction: column;
        text-align: center;
        gap: 15px; /* Increase gap when stacked */
    }

    .header-logo {
        max-height: 80px; /* Smaller logo on medium screens */
    }

    header h1 {
        font-size: 2.2rem; /* Adjust h1 size */
        margin-bottom: 10px; /* Space below h1 when stacked */
    }

    nav ul {
        display: flex; /* Keep nav items in a row for slightly larger mobile */
        flex-wrap: wrap; /* Allow nav items to wrap */
        justify-content: center;
        padding: 0;
    }

    nav ul li {
        margin: 5px 10px; /* Adjust margin for wrapped items */
    }

    .hero {
        padding: 80px 0;
        margin-bottom: 10px;
    }

    .hero h2 {
        font-size: 2.8rem;
    }

    .hero p {
        font-size: 1.2rem;
    }

    section {
        padding: 40px 0;
        margin-bottom: 10px;
    }

    section h3 {
        font-size: 2.2rem;
        margin-bottom: 30px;
    }

    .project-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .project-item {
        padding: 20px;
        margin: 0; /* Remove individual item margins */
    }

    footer {
        padding: 15px 0;
    }
}

@media (max-width: 480px) {
    .header-logo {
        max-height: 60px; /* Even smaller logo on small screens */
    }

    header h1 {
        font-size: 1.8rem; /* Further adjust h1 size */
    }

    nav ul {
        flex-direction: column; /* Stack nav items vertically */
        align-items: center;
    }

    nav ul li {
        margin: 5px 0; /* Adjust margin for stacked items */
    }

    .hero h2 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    section {
        padding: 30px 0;
    }

    section h3 {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }

    .project-item {
        padding: 15px;
    }
}

/* O-shape Animation */
.o-shape-container {
    position: fixed; /* Changed to fixed to ensure it covers the entire viewport */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: -1; /* Behind content */
}

.o-shape {
    position: absolute;
    color: #ffffff; /* White 'O' */
    font-size: 2rem;
    font-weight: bold;
    opacity: 0;
    animation: floatUp 15s linear infinite, rotateO 10s linear infinite, glowO 3s ease-in-out infinite alternate;
    text-shadow: 0 0 5px #ffffff, 0 0 10px #ffffff, 0 0 15px #ffffff; /* Glowing effect */
}

@keyframes floatUp {
    0% {
        transform: translateY(100vh) translateX(0) rotate(0deg);
        opacity: 0;
    }
    20% {
        opacity: 0.1;
    }
    80% {
        opacity: 0.1;
    }
    100% {
        transform: translateY(-10vh) translateX(50px) rotate(360deg);
        opacity: 0;
    }
}

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

@keyframes glowO {
    0% { text-shadow: 0 0 5px #ffffff, 0 0 10px #ffffff, 0 0 15px #ffffff; }
    100% { text-shadow: 0 0 10px #ffffff, 0 0 20px #ffffff, 0 0 30px #ffffff; }
}
