/* ==========================================
   COMPLETE CONSOLIDATED STYLE.CSS
   Luke Oladejo Portfolio Website
   ========================================== */

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
}

:root {
    --primary-color: #b17a50;
    --dark-bg: #080808;
    --dark-accent: #262626;
    --light-text: #fff;
    --gray-text: #ababab;
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--dark-bg);
    color: var(--light-text);
    line-height: 1.6;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--light-text);
    position: relative;
    display: inline-block;
    margin-bottom: 15px;
}

.title-underline {
    height: 4px;
    width: 80px;
    background: var(--primary-color);
    margin: 0 auto;
    border-radius: 2px;
}

.row {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 16px;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--light-text);
    border: 2px solid var(--primary-color);
}

.btn-secondary {
    background: transparent;
    color: var(--light-text);
    border: 2px solid var(--primary-color);
}

.btn-primary:hover {
    background: transparent;
    color: var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--light-text);
}

/* Menu Button Styles */
.fa-bars, .fa-xmark {
    display: none;  /* Hide by default on larger screens */
    font-size: 24px;
    cursor: pointer;
    color: var(--light-text);
}

/* Default menu styles for desktop */
#sidemenu {
    display: flex;
    align-items: center;
    gap: 30px;
}

#sidemenu li {
    list-style: none;
}

#sidemenu li a {
    color: var(--light-text);
    font-size: 1.1rem;
    font-weight: 500;
    transition: 0.3s;
    display: block;
    padding: 10px 20px;
}

/* Ensure menu buttons are hidden on desktop */
@media screen and (min-width: 769px) {
    .fa-bars, .fa-xmark {
        display: none !important; /* Force hide on desktop */
    }
    
    #sidemenu {
        display: flex !important; /* Force show on desktop */
        position: static !important;
        width: auto !important;
        height: auto !important;
        background: transparent !important;
    }
}

/* Preloader Styles */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-bg);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.hide {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loader {
    width: 50px;
    height: 50px;
    border: 5px solid var(--card-bg);
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(to right, var(--primary-color), #f3a683);
    width: 0%;
    z-index: 1000;
    transition: width 0.2s ease;
}

/* Header */
#header {
    width: 100%;
    min-height: 100vh;
    padding: 20px 0;
    position: relative;
    overflow: hidden;
}

nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 10px 0;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-container img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--light-text);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 80px;
    gap: 40px;
}

.header-text {
    flex: 1;
}

.header-image {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.shape-bg {
    width: 400px;
    height: 400px;
    background-color: var(--primary-color);
    opacity: 0.1;
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    position: relative;
    animation: morph 8s ease-in-out infinite;
}

@keyframes morph {
    0% {
        border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    }
    50% {
        border-radius: 70% 30% 30% 70% / 70% 70% 30% 30%;
    }
    100% {
        border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    }
}

.header-text p {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.header-text h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 10px;
    line-height: 1.2;
}

.header-text h1 span {
    color: var(--primary-color);
}

.header-text h2 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.header-description {
    margin-bottom: 30px;
    color: var(--gray-text) !important;
    font-size: 1rem !important;
    max-width: 600px;
}

.header-cta {
    display: flex;
    gap: 20px;
}

/* Custom Cursor */
.cursor {
    position: fixed;
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    transition: width 0.3s, height 0.3s, border-color 0.3s;
    z-index: 9999;
    mix-blend-mode: difference;
}

.cursor-dot {
    position: fixed;
    width: 8px;
    height: 8px;
    background-color: var(--primary-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    transition: width 0.3s, height 0.3s, background-color 0.3s;
    z-index: 9999;
}

.cursor-hover {
    width: 60px;
    height: 60px;
    border-color: var(--light-text);
    background-color: rgba(177, 122, 80, 0.1);
}

/* Floating Icons */
.floating-icons {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.icon-item {
    position: absolute;
    background: rgba(177, 122, 80, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: float 4s ease-in-out infinite;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.icon-item:nth-child(1) {
    top: 20%;
    left: 20%;
    width: 60px;
    height: 60px;
    animation-delay: 0s;
}

.icon-item:nth-child(2) {
    top: 60%;
    left: 15%;
    width: 50px;
    height: 50px;
    animation-delay: 0.5s;
}

.icon-item:nth-child(3) {
    top: 25%;
    left: 75%;
    width: 70px;
    height: 70px;
    animation-delay: 1s;
}

.icon-item:nth-child(4) {
    top: 70%;
    left: 70%;
    width: 55px;
    height: 55px;
    animation-delay: 1.5s;
}

.icon-item:nth-child(5) {
    top: 10%;
    left: 50%;
    width: 65px;
    height: 65px;
    animation-delay: 2s;
}

.icon-item:nth-child(6) {
    top: 85%;
    left: 40%;
    width: 55px;
    height: 55px;
    animation-delay: 2.5s;
}

.icon-item:nth-child(7) {
    top: 55%;
    left: 50%;
    width: 58px;
    height: 58px;
    animation-delay: 3s;
}

.icon-item i {
    font-size: 24px;
    color: var(--primary-color);
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* About Section */
#about {
    background-color: rgba(20, 20, 20, 0.8);
}

.about-col-1 {
    flex: 1;
    position: relative;
}

.about-col-1 img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.about-social {
    position: absolute;
    bottom: 20px;
    left: 20px;
    display: flex;
    gap: 15px;
}

.about-social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light-text);
    font-size: 1.2rem;
    transition: var(--transition);
}

.about-social a:hover {
    transform: translateY(-5px);
    background: var(--light-text);
    color: var(--primary-color);
}

.about-col-2 {
    flex: 1;
}

.about-intro {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.about-col-2 p {
    margin-bottom: 20px;
    color: var(--gray-text);
}

.about-info {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.info-item {
    flex: 1;
    min-width: 200px;
    background: var(--dark-accent);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.info-item h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.info-item p {
    margin-bottom: 5px;
}

.info-item i {
    color: var(--primary-color);
    margin-right: 10px;
}

/* About Section Tabs */
.about-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.tab-btn {
    padding: 10px 25px;
    border: none;
    background: transparent;
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.tab-btn::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.tab-btn:hover::after,
.tab-btn.active::after {
    width: 100%;
}

.tab-btn.active {
    color: var(--primary-color);
}

.tab-content {
    position: relative;
    min-height: 400px; /* Ensure consistent height */
}

.tab-pane {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    position: absolute;
    width: 100%;
    top: 0;
    left: 0;
}

.tab-pane.active {
    display: block;
    opacity: 1;
    position: relative;
}

/* Video Container Styles */
.video-container {
    max-width: 800px;
    margin: 0 auto;
    background: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Skills Section */
#skills {
    background-color: var(--dark-bg);
}

/* Skills Counters */
.skills-counters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.counter-item {
    background: var(--dark-accent);
    padding: 30px 20px;
    border-radius: 10px;
    text-align: center;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.counter-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.counter-icon {
    width: 70px;
    height: 70px;
    background: rgba(177, 122, 80, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.counter-icon i {
    font-size: 30px;
    color: var(--primary-color);
}

.skill-counter {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.counter-item h3 {
    font-size: 1rem;
    margin-top: 10px;
    color: var(--gray-text);
}

.skills-content {
    display: flex;
    flex-direction: column;
    gap: 50px;
}

.skills-category h3 {
    font-size: 1.5rem;
    margin-bottom: 30px;
    color: var(--primary-color);
    text-align: center;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.skill-item {
    background: var(--dark-accent);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    transition: var(--transition);
}

.skill-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.skill-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.skill-item h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.skill-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin-top: 15px;
    overflow: hidden;
}

.skill-progress {
    height: 100%;
    background: var(--primary-color);
    border-radius: 4px;
}

/* Services Section */
#services {
    background-color: rgba(20, 20, 20, 0.8);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background: var(--dark-accent);
    border-radius: 10px;
    padding: 30px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.service-card::before {
    content: "";
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color) 0%, rgba(177, 122, 80, 0.2) 100%);
    transition: var(--transition);
    z-index: -1;
}

.service-card:hover::before {
    top: 0;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.service-icon {
    width: 70px;
    height: 70px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.service-icon i {
    font-size: 30px;
    color: var(--light-text);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--light-text);
}

.service-card p {
    margin-bottom: 20px;
    color: var(--gray-text);
}

.service-features {
    list-style: none;
}

.service-features li {
    padding: 8px 0;
    color: var(--gray-text);
    position: relative;
    padding-left: 25px;
}

.service-features li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

/* Projects Section */
#projects {
    background-color: var(--dark-bg);
}

.project-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 20px;
    background: transparent;
    border: 2px solid var(--dark-accent);
    color: var(--light-text);
    border-radius: 30px;
    cursor: pointer;
    font-size: 14px;
    transition: var(--transition);
}

.filter-btn.active, .filter-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    perspective: 1000px;
    height: 450px;
    margin-bottom: 30px;
}

.project-flipper {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.project-front, .project-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 10px;
    overflow: hidden;
}

.project-front {
    background: var(--dark-accent);
}

.project-back {
    background: var(--dark-accent);
    transform: rotateY(180deg);
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    overflow-y: auto;
}

.project-back h3 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

.project-back p {
    margin-bottom: 15px;
    color: var(--gray-text);
}

.project-back ul {
    margin-bottom: 20px;
    padding-left: 20px;
}

.project-back ul li {
    margin-bottom: 8px;
    color: var(--gray-text);
}

.project-media {
    margin-top: auto;
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    padding-top: 20px;
}

.project-media .btn {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    margin: 5px;
}

.project-media .btn i {
    font-size: 18px;
}

.project-card:hover .project-flipper {
    transform: rotateY(180deg);
}

.project-img {
    position: relative;
    overflow: hidden;
    height: 200px;
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-img img {
    transform: scale(1.1);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-links {
    display: flex;
    gap: 15px;
}

.project-link {
    width: 45px;
    height: 45px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light-text);
    font-size: 18px;
    transition: var(--transition);
}

.project-link:hover {
    background: var(--light-text);
    color: var(--primary-color);
}

.project-info {
    padding: 20px;
    height: calc(100% - 200px);
    display: flex;
    flex-direction: column;
}

.project-info h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.project-info p {
    color: var(--gray-text);
    margin-bottom: 15px;
    flex-grow: 1;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: auto;
}

.project-tags span {
    padding: 5px 12px;
    background: rgba(177, 122, 80, 0.1);
    border-radius: 30px;
    font-size: 12px;
    color: var(--primary-color);
}

/* See More Projects Button for Homepage */
.see-more-projects {
    text-align: center;
    margin-top: 50px;
}

.see-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.see-more-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--primary-color);
    transition: left 0.3s ease;
    z-index: -1;
}

.see-more-btn:hover::before {
    left: 0;
}

.see-more-btn:hover {
    color: var(--light-text);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(177, 122, 80, 0.3);
}

.see-more-btn i {
    transition: transform 0.3s ease;
}

.see-more-btn:hover i {
    transform: translateX(5px);
}

/* Update the projects section title for featured projects */
#projects .section-title h2 {
    background: linear-gradient(135deg, var(--light-text) 0%, var(--primary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Enhanced hover effects for homepage project cards */
#projects .project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

/* Testimonials Section */
.testimonials {
    position: relative;
    padding: 80px 0;
    background: rgba(20, 20, 20, 0.8);
    overflow: hidden;
}

.testimonial-container {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.testimonial-slider {
    display: flex;
    transition: transform 0.5s ease;
}

.testimonial-slide {
    min-width: 100%;
    padding: 0 20px;
    box-sizing: border-box;
}

.testimonial-card {
    background: var(--dark-accent);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    position: relative;
}

.testimonial-card::before {
    content: '\201C';
    font-size: 80px;
    font-family: serif;
    color: rgba(177, 122, 80, 0.2);
    position: absolute;
    top: 10px;
    left: 20px;
}

.testimonial-content {
    position: relative;
    z-index: 1;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 20px;
    color: var(--gray-text);
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author .author-img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: rgba(177, 122, 80, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
}

.testimonial-author .author-img i {
    font-size: 24px;
    color: var(--primary-color);
}

.author-info h4 {
    margin-bottom: 5px;
}

.author-info p {
    color: var(--primary-color);
    font-size: 14px;
}

.testimonial-controls {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 15px;
}

.testimonial-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--dark-accent);
    border: none;
    color: var(--primary-color);
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
}

.testimonial-btn:hover {
    background: var(--primary-color);
    color: var(--light-text);
}

/* Contact Section */
#contact {
    background-color: rgba(20, 20, 20, 0.8);
    position: relative;
}

.contact-left, .contact-right {
    flex: 1;
    min-width: 300px;
}

.contact-left h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.contact-left p {
    margin-bottom: 30px;
    color: var(--gray-text);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.contact-item i {
    font-size: 20px;
    color: var(--primary-color);
    margin-top: 5px;
}

.contact-item h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--dark-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 18px;
    transition: var(--transition);
}

.social-icons a:hover {
    background: var(--primary-color);
    color: var(--light-text);
    transform: translateY(-5px);
}

/* Contact Form Animation Effects */
.contact-form .form-group {
    position: relative;
    margin-bottom: 30px;
}

.contact-form .form-group label {
    position: absolute;
    left: 15px;
    top: 17px;
    color: var(--gray-text);
    transition: all 0.3s ease;
    pointer-events: none;
}

.contact-form .form-group input:focus ~ label,
.contact-form .form-group textarea:focus ~ label,
.contact-form .form-group input:valid ~ label,
.contact-form .form-group textarea:valid ~ label {
    top: -10px;
    left: 0;
    font-size: 12px;
    color: var(--primary-color);
    background: var(--dark-accent);
    padding: 0 5px;
}

.contact-form .form-group .focus-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: 0.4s;
}

.contact-form .form-group input:focus ~ .focus-border,
.contact-form .form-group textarea:focus ~ .focus-border {
    width: 100%;
}

.contact-right form {
    background: var(--dark-accent);
    padding: 30px;
    border-radius: 10px;
}

.contact-section {
    padding: 100px 0;
    background: var(--bg-color);
}

.contact-section .section-title {
    text-align: center;
    margin-bottom: 50px;
}

.contact-form-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px;
    background: var(--dark-accent);
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.contact-form {
    width: 100%;
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    color: var(--light-text);
    font-size: 16px;
    transition: var(--transition);
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.btn-submit {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
    width: 100%;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 500;
}

.btn-submit .btn-text {
    position: relative;
    z-index: 1;
}

.btn-submit .btn-icon {
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.btn-submit:hover .btn-icon {
    transform: translateX(5px);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

#msg {
    display: block;
    margin-top: 20px;
    text-align: center;
    color: var(--light-text);
}

/* Particles for Contact Section */
.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.particle {
    position: absolute;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background-color: rgba(177, 122, 80, 0.3);
    pointer-events: none;
    animation: float 20s linear infinite;
}

/* Footer */
footer {
    background: var(--dark-accent);
    padding: 40px 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.footer-logo img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.footer-logo p {
    font-size: 1.5rem;
    font-weight: 600;
}

.footer-nav ul {
    display: flex;
    list-style: none;
    gap: 20px;
    flex-wrap: wrap;
}

.footer-nav ul li a {
    color: var(--gray-text);
    text-decoration: none;
    transition: var(--transition);
}

.footer-nav ul li a:hover {
    color: var(--primary-color);
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--gray-text);
}

/* Scroll to top button */
#scroll-top-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: var(--light-text);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 99;
    opacity: 0;
    display: none;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

#scroll-top-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

/* Social Icon Hover Effect */
.social-hover {
    position: relative;
    overflow: hidden;
}

.social-hover::before {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary-color);
    transition: all 0.3s ease;
}

.social-hover:hover::before {
    top: 0;
}

.social-hover i {
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

.social-hover:hover i {
    color: var(--light-text) !important;
}

/* Highlight text */
.highlight-text {
    position: relative;
    color: var(--primary-color);
    z-index: 1;
}

.highlight-text::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 30%;
    bottom: 0;
    left: 0;
    background-color: rgba(177, 122, 80, 0.2);
    z-index: -1;
    transform: skewX(-15deg);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate {
    animation: fadeIn 1s ease forwards;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Typed text */
.typed-text {
    border-right: 2px solid var(--primary-color);
}

/* Active Navigation Link */
#sidemenu li a.active {
    color: var(--primary-color);
}

#sidemenu li a.active::after {
    width: 50%;
}

/* ==========================================
   PROJECTS PAGE SPECIFIC STYLES
   ========================================== */

/* Projects Header */
.projects-header {
    background: var(--dark-bg);
    padding: 20px 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Projects Hero Section */
.projects-hero {
    background: linear-gradient(135deg, var(--dark-bg) 0%, rgba(177, 122, 80, 0.1) 100%);
    padding: 120px 0 80px;
    text-align: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(135deg, var(--light-text) 0%, var(--primary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-content p {
    font-size: 1.2rem;
    color: var(--gray-text);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.6;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 40px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--gray-text);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Projects Main Section */
.projects-main {
    background: var(--dark-bg);
    padding: 80px 0;
}

/* Enhanced Project Grid */
.projects-main .projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

/* Load More Section */
.load-more-section {
    text-align: center;
    padding: 60px 0;
    background: var(--dark-accent);
    border-radius: 15px;
    margin-top: 40px;
}

.load-more-text {
    font-size: 1.2rem;
    color: var(--gray-text);
    margin-bottom: 30px;
}

.load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.load-more-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(177, 122, 80, 0.3);
}

/* Enhanced Project Cards for Projects Page */
.projects-main .project-card {
    height: 500px;
    transition: all 0.3s ease;
}

.projects-main .project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Project Image Enhancements */
.projects-main .project-img {
    height: 250px;
}

.projects-main .project-info {
    height: calc(100% - 250px);
    padding: 25px;
}

.projects-main .project-info h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--light-text);
}

.projects-main .project-info p {
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 20px;
}

/* Enhanced Project Tags */
.projects-main .project-tags {
    margin-top: auto;
}

.projects-main .project-tags span {
    padding: 6px 14px;
    font-size: 0.8rem;
    font-weight: 500;
    background: rgba(177, 122, 80, 0.15);
    border: 1px solid rgba(177, 122, 80, 0.3);
    border-radius: 20px;
    color: var(--primary-color);
}

/* Project Back Enhancements */
.projects-main .project-back {
    padding: 35px;
}

.projects-main .project-back h3 {
    font-size: 1.4rem;
    margin-bottom: 18px;
    color: var(--primary-color);
}

.projects-main .project-back p {
    margin-bottom: 18px;
    line-height: 1.6;
}

.projects-main .project-back ul {
    margin-bottom: 25px;
    padding-left: 0;
    list-style: none;
}

.projects-main .project-back ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
    color: var(--gray-text);
}

.projects-main .project-back ul li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

/* Project Media Section */
.projects-main .project-media {
    margin-top: auto;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.projects-main .project-media .btn {
    padding: 10px 20px;
    font-size: 0.9rem;
    border-radius: 25px;
}

/* ==========================================
   RESPONSIVE DESIGN
   ========================================== */

/* Mobile Menu Styles */
@media screen and (max-width: 768px) {
    .fa-bars {
        display: block;  /* Show menu button on mobile */
    }
    
    #sidemenu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: var(--dark-bg);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.3s;
        z-index: 100;
    }

    #sidemenu.active {
        right: 0;
    }
    
    #sidemenu .fa-xmark {
        display: block;  /* Show close button only when menu is active */
        position: absolute;
        top: 20px;
        right: 20px;
        cursor: pointer;
        font-size: 24px;
        color: var(--light-text);
    }
    
    #sidemenu li {
        margin: 15px 0;
        opacity: 0;
        transform: translateY(20px);
        transition: all 0.3s ease;
    }

    #sidemenu.active li {
        opacity: 1;
        transform: translateY(0);
        transition-delay: calc(0.1s * var(--i));
    }
    
    #sidemenu li a {
        color: var(--light-text);
        font-size: 1.2rem;
        font-weight: 500;
        transition: 0.3s;
    }

    #sidemenu li a:hover {
        color: var(--primary-color);
    }
    
    /* Projects Page Mobile */
    .projects-header {
        position: relative;
    }
    
    .projects-hero {
        padding: 80px 0 60px;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-content p {
        font-size: 1rem;
        padding: 0 20px;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 30px;
    }
    
    .projects-main .projects-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .projects-main .project-card {
        height: auto;
        min-height: 450px;
    }
    
    .load-more-section {
        padding: 40px 20px;
    }
    
    .see-more-btn {
        padding: 12px 25px;
        font-size: 1rem;
    }
    
    /* Sections */
    section {
        padding: 60px 0;
    }
    
    .section-title h2 {
        font-size: 2rem;
    }
    
    /* About section */
    .about-col-1, .about-col-2 {
        flex: 100%;
    }
    
    .about-col-1 {
        margin-bottom: 30px;
    }
    
    .about-info {
        flex-direction: column;
    }
    
    /* Skills section */
    .skills-counters {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    /* Projects and Services */
    .services-grid, .projects-grid, .gallery-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    /* Project card modifications for mobile */
    .project-card {
        height: auto;
        min-height: 450px;
    }
    
    .project-flipper {
        transition: none;
        transform-style: flat;
    }
    
    .project-front, .project-back {
        position: relative;
        backface-visibility: visible;
        height: auto;
        min-height: 450px;
    }
    
    .project-back {
        transform: none !important;
        display: none;
    }
    
    /* Special class for mobile interaction */
    .project-card.active .project-front {
        display: none;
    }
    
    .project-card.active .project-back {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1000;
        overflow-y: auto;
        padding: 60px 20px 20px;
    }

    /* Show close button only on mobile */
    .project-back .close-card {
        display: flex;
        position: fixed;
        top: 15px;
        right: 15px;
        background: var(--primary-color);
        color: var(--light-text);
        width: 40px;
        height: 40px;
        border-radius: 50%;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        z-index: 1001;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    }

    .project-card:hover .project-flipper {
        transform: none;
    }
    
    /* Testimonials */
    .testimonial-card {
        padding: 20px;
    }
    
    .testimonial-author {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .testimonial-author .author-img {
        margin: 0 0 15px 0;
    }
    
    /* Contact section */
    .contact-left, .contact-right {
        flex: 100%;
    }
    
    .contact-right {
        margin-top: 40px;
    }
    
    .contact-info {
        gap: 15px;
    }
    
    .contact-form-container {
        padding: 30px 20px;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 12px;
    }
    
    /* Hide custom cursor on mobile */
    .cursor, .cursor-dot {
        display: none;
    }
    
    /* Adjust floating icons for mobile */
    .icon-item {
        width: 40px !important;
        height: 40px !important;
    }
    
    .icon-item i {
        font-size: 18px;
    }
    
    /* Services section mobile adjustments */
    .service-card {
        transform: none !important;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    }
    
    .service-card::before {
        top: 0;
        opacity: 0;
        transition: opacity 0.3s ease;
    }
    
    .service-card:hover::before {
        opacity: 1;
    }
    
    .service-card:hover {
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    }
    
    /* Add active state for touch devices */
    .service-card:active {
        transform: scale(0.98);
    }
    
    /* Responsive Styles for Tabs */
    .about-tabs {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .tab-btn {
        width: 100%;
        max-width: 300px;
        text-align: center;
    }
    
    .video-container {
        margin: 0 20px;
    }

    .tab-content {
        min-height: 300px;
    }
    
    .video-wrapper {
        padding-bottom: 75%;
    }
}

@media screen and (max-width: 480px) {
    /* Hero content for projects page */
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .projects-main .project-card {
        min-height: 400px;
    }
    
    .projects-main .project-img {
        height: 200px;
    }
    
    .projects-main .project-info {
        height: calc(100% - 200px);
        padding: 20px;
    }
    
    .projects-main .project-back {
        padding: 25px;
    }
    
    /* Header */
    .header-text h1 {
        font-size: 1.8rem;
    }
    
    .header-text h2 {
        font-size: 1.5rem;
    }
    
    /* Skills section */
    .skills-counters {
        grid-template-columns: 1fr;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .skill-counter {
        font-size: 2rem;
    }
    
    /* Buttons */
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .header-cta {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }
    
    .see-more-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    /* Social icons */
    .social-icons {
        gap: 10px;
        justify-content: center;
    }
    
    /* Shape background in header */
    .shape-bg {
        width: 250px;
        height: 250px;
    }
}

/* Responsive Styles */
@media screen and (max-width: 991px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }
    
    .header-cta {
        justify-content: center;
    }
    
    .header-description {
        margin: 0 auto 30px;
    }
}

/* Ensure content is visible if preloader fails */
body.preloader-failed {
    overflow: auto;
}

/* Hide preloader on small screens if it gets stuck */
@media (max-width: 480px) {
    .preloader {
        display: none;
    }
    
    body {
        overflow: auto;
    }
}

/* Accessibility Improvements */
:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Default state - close button hidden */
.project-back .close-card {
    display: none;
}

/* Prevent body scroll when project is open */
body.project-open {
    overflow: hidden;
}

/* Specific style change for Next.js icon in skill item */
.skill-item .devicon-nextjs-original {
    background: #000000;
    border-radius: 8px;
    padding: 6px;
    color: #000 !important; /* Ensures the icon is visible */
    width: 40px;
    height: 40px;
    font-size: 32px;
    margin-bottom: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.nextjs-icon {
    background: #fff;
    border-radius: 8px;
    padding: 6px;
    width: 40px;
    height: 40px;
    margin-bottom: 15px;
    object-fit: contain;
    display: inline-block;
}