* {
    margin: 0;
    padding: 0;
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
}
html{
    scroll-behavior: smooth;
}
/* cntrl+h to change the text from one to another */
html, body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}
/* this above solution the error made me 2hrs an excess space is came in the right side of the responsive view with photo */

body {
    background: #000000;
    color: #fff;
}

#header {
    width: 100%;
    height: 100vh;
    background-image: url('portfolio_photos/background.jpg');
    background-size: cover; 
    background-position: center; 
    
}
.container {
    padding: 10px 10%;
}
.container {
    width: 100%;
    margin: 0 auto;
}



nav{
    display:flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    /* display: flex;: Makes the items inside the nav sit in a row.
align-items: center;: Centers the items vertically.
justify-content: space-between;: Spreads the items out evenly, with space between them.
flex-wrap: wrap;: If there isn't enough space, items move to the next line.*/ 
}
.logo {
    width: 487px;
    src: url('portfolio_photos/logo(#CA0101).jpg'); /* Default logo */
}
nav ul li {
    display: inline-block; /*Makes each list item (li) behave like a block (so you can control its size) but still sit next to each other in a row like inline elements. */
    list-style: none;/*Removes the default bullet points from the list items.*/
    margin: 1px 10px;/*Adds space around the list items — 1px of space at the top and bottom, and 10px on the left and right.*/
}
nav ul li a{
    color: #fff;
    text-decoration: none; /*Removes the default underline from the links. */
    font-size: 18px;
    position :relative;/*position: relative; keeps any extra elements you add (like an underline or icon) "stuck" to the link, like a sticky note on the book.*/
}
nav ul li a::after{ /*If you put a sticky note on the book (this is like adding ::after), the sticky note will stay on the book. This happens because position: relative; makes sure the sticky note stays connected to the book.*/
    content: '';/*This is the sticky note itself, but it's empty for now. You’re just creating space for it.*/
    width:0;/*The sticky note starts out with a width of 0, so it's invisible at first.*/
    height:3px;
    background: #ff0000;
    position:absolute;/*The sticky note (line) will be placed exactly where you tell it to go (with left: 0 and bottom: -6px).*/
    left:0;
    bottom: -6px;
    transition:  0.5s ;

}
nav ul li a:hover::after{ /*This targets the ::after pseudo-element of the a tag inside a li within ul inside nav, but only when the link is hove#CA0101 over.*/
    width: 100%;
}
.header-text{
    margin-top:20%;
    font-size: 35px;
}
.header-text h1{
    font-size: 60px;
    margin-top:20px;
}
.header-text h1 span{
    color:#CA0101;
}
/* -----------------about--------------- */
#about{
    padding: 80px 0;
    color: #ababab;
}
.row{
    display:flex;
    justify-content: space-between;
    flex-wrap:wrap;
}
.about-col-1{
    flex-basis:35%;
}
.about-col-1 img{
    width:100%;
    border-radius: 15px;
    
        transform: translateY(-90px); /* Moves the image 20px upward */
    
    
}
.about-col-2{
    flex-basis: 60%;
    font-size: 20px;
}
.sub-title{
    font-size: 60px;
    font-weight: 600;
    color: #fff;
    transform: translateY(-30px);
}
.tab-titles {
    display: flex;
    margin: 20px 0 40px;
    
}

.tab-links {
    margin-right: 50px;
    font-size: 30px;
    font-weight: 500;
    cursor: pointer;
    position: relative;
}

.tab-links::after {
    content: '';
    width: 0;
    height: 3px;
    background: #CA0101;
    position: absolute;
    left: 0;
    bottom: -8px;
    transition: width 0.5s ease;
}

.tab-links.active-link::after {
    width: 50%;
}

.tab-contents ul li{
    list-style: none;
    margin: 10px 0;

}
.tab-contents ul li span{
    color: #CA0101;
    font-size: 24px;
}
.tab-contents{
    display: none;
    font-size: 20px;

}
.tab-contents.active-tab{
    display:block;
}

/* ----------------services-------- */
#services{
    padding:30px 0;
}
.services-list{
    display:grid;
    grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
    grid-gap: 40px;
    margin-top: 50px;
}
.services-list div{
    background: #262626;
    padding: 40px;
    font-size: 13px;
    font-weight: 300;
    border-radius: 10px;
    transition: background 0.5s,transform 0.5s;

}
.services-list div i{
    font-size: 50px;
    margin-bottom: 30px;
}
.services-list div h2{
    font-size: 30px;
    font-weight: 500;
    margin-bottom: 15px;

}
.services-list div a{
    text-decoration: none;
    color: #fff;
    font-size: 12px;
    margin-top: 20px;
    display: inline-block;

}
.services-list div:hover{
    background: #b4000c;
    transform: translateY(-10px);
}
/* ------------portfolio--------- */
 
#portfolio{
    padding: 50px 0;
}
.work-list{
    display:grid;
    grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
    grid-gap: 40px;
    margin-top: 50px;
}
.work{
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}
.work img{
    width:100%;
    border-radius: 10px;
    display:block;
    transition: transform 0.5s;
    
}
.layer{
    width:100%;
    height:0;
    background: linear-gradient(rgba(0,0,0,0.6),#CA0101);
    border-radius: 10px;
    position: absolute;
    left: 0;
    bottom: 0;
    overflow: hidden;
    display:flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 0 40px;
    text-align: center;
    font-size: 14px;
    transition: height 0.5s;
}
.layer h3{
    font-weight: 500;
    margin-bottom: 20px;
}
.layer a{
    margin-top:20px;
    color: #CA0101;
    text-decoration: none;
    font-size: 18px;
    line-height: 60px;
    background: #fff;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    text-align: center;
}
.work:hover img{
    transform:scale(1.1);
}
.work:hover .layer{
    height: 100%;
}
.btn{
    display: block;
    margin: 50px auto;
    width:fit-content;
    border:1px solid #CA0101;
    padding: 14px 50px;
    border-radius: 6px;
    text-decoration:none;
    color:#fff;
    transition: background 0.5s;
}
.btn:hover{
    background: #CA0101;
}
/* ---------------contact----------- */
.contact-left{
    flex-basis: 35%;
}

.contact-right{
    flex-basis: 60%;
}
.contact-left p{
    margin-top:30px; 
}
.contact-left p i{
    color: #CA0101;
    margin-right: 15px;
    font-size: 25px;
}
.social-icons{
    margin-top:30px;
}
.social-icons a{
    text-decoration:none;
    font-size: 30px;
    margin-right:15px;
    color: #ffffff;
    display: inline-block;
    transition:transform 0.5s;
}
.social-icons a:hover{
    color: #CA0101;
    transform: translateY(-5px);
} 
.btn.btn2{
    display:inline-block;
    background: #CA0101;

}
.contact-right form{
    width:100% ;

}
form input, form textarea{
    width:100%;
    border:0;
    outline: none;
    background: #262626;
    padding: 15px;
    margin:15px 0;
    color:#fff;
    font-size: 18px;
    border-radius:6px;

}
form btn2{
    padding:14px 60px;
    font-size: 18px;
    margin-top:20px;
    cursor:pointer;
}
.copyright{
    width:100%;
    text-align:center;
    padding: 25px 0;
    background: #262626;
    font-weight:300;
    margin-top:20px;
}
.copyright i{
    color:#CA0101;
}
/* ---------------------------css for small screens--------------- */
/* using css media query */
nav .fas{
    display: none;
}

@media only screen and (max-width: 899px) {
    #header {
        position: relative; /* Ensures child elements can be positioned relative to this container */
        width: 100%;
        height: 100vh;
        background-image: url('portfolio_photos/front-image-3.jpg');
        background-size: cover;
        background-position: center;
    }
    
    .header-text {
        position: absolute; /* Allows you to position the text relative to the header */
        bottom: 10%; /* Adjust this value to control the distance from the bottom */
        left: 40%; /* Centers the text horizontally */
         transform: translateX(-36%); /*Corrects the centering after using left: 50%  */
        font-size: 18px;
        text-align: left; /* Ensures the text is cente#CA0101 */
        color: #fff; /* Set text color if needed for visibility on the image */
        white-space: nowrap; /* Prevents text from wrapping to the next line */
    }
    
    .header-text h1 {
        font-size:28px;
        margin: 10;
    }
    

    /* .logo {
        display: block; 
        width: 10px; 
        height: auto; 
        background-image: url('portfolio_photos/mobile-logo(pink).png');
        background-size: 10px;
        background-repeat: no-repeat;
        background-position: left;
    } */
    .logo {
        content: url('portfolio_photos/mobile-logo(red).png'); /* Mobile logo */
        width: 118px;
        padding: 0px 0px; /* Adjust the width for mobile, you can change this as needed */
    }

    /* You might want to adjust the padding or margin for smaller screens as well */
    
    
        .container {
            padding: 10px 10%;
        }
        nav .fas{
            display: block;
            font-size :20px;
        }
        nav ul{
            background: #CA0101;
            position: fixed;
            top:0;
            right:-200px;
            width: 150px;
            height:100vh;
            padding-top:50px;
            z-index: 2;
            transition: right 0.5s;

        }
        nav ul li{
            display: block;
            margin:25px;

        }
        nav ul .fas{
            
            position: absolute;
            top: 25px;
            left:20px;
            cursor:pointer;
        }
        .sub-title{
            font-size: 30px;
        }
        .about-col-1,.about-col-2{
            flex-basis: 100%; 
            }

        .about-col-1{
            margin-top: 1px;
        }
        .about-col-2{
            font-size: 14px;
        }
        .tab-links{
            font-size: 17px;
            margin-right:20px;
        }

        .tab-contents{
            font-size: 16px;
        }
        .tab-contents ul li span{
            font-size: 17px;
        }
        .contact-left,.contact-right{
            flex-basis: 100%;
        }
        .social-icons a{
            font-size: 25px;
        }
        .copyright{
            font-size: 10px;
        }
        .copyright{
            width:100%;
            text-align:center;
            padding: 10px 0;
            background: #262626;
            font-weight:300;
            margin-top:10px;
        }
            
}
#msg{
    color: #61b752;
    margin-top: -40px;
    display: block;

}
        
