/* General Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #000;
    color: #fff;
    text-align: center;
}

h1,
h2 {
    font-weight: bold;
    color: #B22222;
}

button {
    padding: 10px 20px;
    background-color: #B22222;
    color: #fff;
    border: none;
    cursor: pointer;
    margin: 5px;
    transition: background 0.3s ease;
    border-radius: 5px;
}

button:hover {
    background-color: #FF4500;
}

/* Navigation Bar */
.main-nav {
    background-color: #1a1a1a;
    padding: 15px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.main-nav a {
    color: #fff;
    text-decoration: none;
    margin: 0 15px;
    transition: color 0.3s ease;
    position: relative;
}

.main-nav a:hover {
    color: #B22222;
}

.main-nav a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background-color: #B22222;
    bottom: -5px;
    left: 0;
    transition: width 0.3s ease;
}

.main-nav a:hover::after {
    width: 100%;
}

.main-nav .logo {
    font-family: 'Arial', sans-serif;
    font-size: 2em;
    margin-left: 20px;
    font-weight: normal;
    cursor: pointer;
}

.main-nav .nav-links {
    margin-right: 20px;
}

/* Hero Section */
.hero {
    height: 100vh;
    background: url('../img/hero2.jpg') no-repeat center center/cover; /* Adjusted path for img folder */
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background-color: #1a1a1a;
}

.hero h1,
.hero h2 {
    color: #fff;
}

/* Skills and Experience Sections */
.skills,
.experience,
.my-work,
.about {
    margin: 50px 0;
    padding: 20px 0;
}

.skills {
    background-color: #000;
}

.experience {
    background-color: #1a1a1a;
}

.my-work {
    background-color: #262626;
}

.about {
    background-color: #262626;
}

.services-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    justify-items: center;
    margin: 20px auto;
    max-width: 80%;
}

.service-card {
    background-color: #555;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    cursor: pointer; /* Added this for visual feedback */
    transition: transform 0.3s ease, background-color 0.3s ease;
    width: 200px;
    height: 150px;
    position: relative;
    box-shadow: 0 0 10px rgba(255, 69, 0, 0);
    outline: 2px solid transparent;
}

.service-card:hover {
    transform: translateY(-10px);
    background-color: #B22222;
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 69, 0, 0.5);
    outline: 2px solid #B22222;
}

.service-card img {
    width: 80px;
    height: 80px;
    margin-bottom: 10px;
    border-radius: 5px;
    object-fit: cover;
    transition: filter 0.3s ease;
    background-color: transparent;
}

.service-card:hover img {
    filter: brightness(1.5);
}

.service-card h3 {
    font-size: 1.2rem;
}

.service-card:hover::after {
    content: attr(data-level);
    display: block;
    margin-top: 10px;
    font-size: 1rem;
    color: #fff;
    text-align: center;
    padding: 5px;
    border-radius: 5px;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: none;
}

/* Popup Styles */
.popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.popup-content {
    background-color: #363737;
    padding: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    max-width: 800px;
    width: 80%;
    text-align: left;
    position: relative;
}

.popup-content img {
    width: 150px;
    height: auto;
    margin-right: 20px;
    margin-top: 10px;
}

.popup-content h3 {
    margin: 0;
    color: #fff;
}

.popup-content p {
    margin: 10px 0 0;
}

.popup-images {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    justify-content: center;
}

.popup-images img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.popup-images img:hover {
    transform: scale(1.2);
}

.popup-image-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1001;
}

.popup-image-container img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 10px;
    transition: transform 0.3s ease;
}

.popup-image-container img:hover {
    transform: scale(1);
}

/* Footer Styles */
footer {
    background-color: #1a1a1a;
    padding: 20px 0;
    text-align: center;
}

footer p {
    margin: 20px auto;
    font-size: 1.1rem;
    max-width: 600px;
}

.contact-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px auto;
}

.contact-container img {
    width: 50px;
    height: 50px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.contact-container img:hover {
    transform: scale(1.2);
}

/* About Me Section */
.about {
    margin: 50px auto;
    padding: 20px;
    max-width: 800px;
    text-align: left;
    display: flex;
    gap: 20px;
    align-items: center;
    background-color: #262626;
    border-radius: 10px;
}

.about img {
    width: 300px;
    border-radius: 10px;
}

.about h2 {
    margin-bottom: 20px;
}

.about p {
    line-height: 1.6;
}

/* Video Popup Styles */
.video-popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1001;
}

.video-popup-content {
    background-color: #363737;
    padding: 20px;
    border-radius: 10px;
    max-width: 80%;
    max-height: 80%;
    overflow: auto;
    position: relative;
}

.video-popup-content video {
    width: 100%;
    max-height: 600px;
}

.video-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    color: #fff;
    font-size: 24px;
    border: none;
    cursor: pointer;
}

.video-popup-controls {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.video-popup-controls button {
    background-color: #B22222;
    color: #fff;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 5px;
}

.video-popup-controls button:hover {
    background-color: #FF4500;
}

/* Mobile Styles */
@media (max-width: 768px) {
    .main-nav {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        text-align: center;
    }

    .main-nav .logo {
        margin-left: 0;
        margin-bottom: 10px;
    }

    .main-nav .nav-links {
        display: none;
        width: 100%;
        padding: 10px 0;
    }

    .main-nav .nav-links a {
        display: block;
        margin: 5px 0;
        text-align: center;
    }

    .hamburger {
        display: block;
        font-size: 2em;
        color: #fff;
        margin-right: 10px;
        cursor: pointer;
        position: absolute;
        top: 10px;
        right: 10px;
    }

    .hero {
        height: auto;
        padding: 50px 20px;
    }

    .about {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .about img {
        width: 80%;
        max-width: 300px;
    }

    .services-container {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .service-card {
        width: 100%;
        height: auto;
    }

    .popup-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .popup-content img {
        margin-right: 0;
        margin-bottom: 10px;
    }

    .contact-container {
        flex-direction: column;
        align-items: center;
    }

    .contact-container img {
        margin: 10px 0;
    }
}

.hamburger {
    display: none;
}

/* Desktop View for My Work Section */
@media (min-width: 769px) {
    #my-work .services-container {
        grid-template-columns: repeat(3, 1fr);
    }

    #skills .services-container {
        grid-template-columns: repeat(3, 1fr);
    }
}
