@import url('https://fonts.googleapis.com/css2?family=Courier+Prime:ital,wght@0,400;0,700;1,400;1,700&display=swap');

:root {
/* ===== COLOR ===== */
    --blue-color: #1D2D50;
    --purple-color: #6A4C93;
    --yellow-color: #FFD166;
    --gray-color: #CBD3DC;
    --white-color: #f9fafb;
    --black-text-color: #1A1A1A;
/* ===== FONT ===== */
    --main-font: "Courier Prime", monospace;
}

html, body {
    width: 100%;
    overflow-x: hidden;
    background-color: var(--white-color);
}

* {
   margin: 0;
   padding: 0;
   box-sizing: border-box;
   scroll-behavior: smooth;
}

header {
    background-color: var(--white-color);
    height: fit-content;
    width: 100%;
    position: fixed; /* لجعل الهيدر ثابت */
    z-index: 10000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 100px;
}

.logo {
    height: 90px;
    border-radius: 50%;
}

.nav_link{
    text-decoration: none;
    color: #7d8a96;
    font-weight: 500;
    font-size: 1.4em;
    position: relative;
    transition: all 0.4s;
    padding: 0 10px 0 10px;
    font-family: var(--main-font);
}

.nav_link:hover {
    color: var(--blue-color);
}

.menu-toggle {
    display: none;
    font-size: 28px;
    cursor: pointer;
    color: #7d8a96;
}

/*==== Home Section ====*/
.home {
    display: flex;
    position: relative;
    width: 100%;
    min-height: 100vh;
    overflow: hidden;
    align-items: center;
    background-color: var(--white-color);
    transition: all 0.5s ease;
    padding: 90px 100px 0;
    flex-direction: row-reverse;
    justify-content: space-between;
    gap: 30px;
}

.img-container {
    width: 750px;
    height: 750px;
    overflow: hidden;
    position: absolute;
    right: 0;
    flex: 1;
    display: flex;
    justify-content: center;
}

.img-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.text-container {
    flex: 1;
}

.name {
    font-family: var(--main-font);
    color: var(--purple-color);
    font-size: 50px;
}

.my-job {
    font-family: var(--main-font);
    font-size: 25px;
    color: var(--blue-color);
    margin-bottom: 18px;
}

.my-job span {
    position: relative;
}

.my-job span::before {
    content: 'Developer';
    color: var(--purple-color);
    animation: words 20s infinite;
}

.my-job span::after {
    content: '';
    position: absolute;
    width: calc(100% + 8px);
    height: 100%;
    background-color: var(--white-color);
    border-left: 2px solid var(--purple-color);
    right: -8px;
    animation: cursor .8s infinite, typing 20s steps(14) infinite;
}

@keyframes cursor {
    to{
        border-left: 2px solid #00a8cc00;
    }
}

@keyframes words {
    0%,20% {
        content: 'Developer';
    }
}

@keyframes typing {
    10%,15%,30%,35%,50%,55%,70%,75%,90%,95%{
        width: 0;
    }
    5%,20%,25%,40%,45%,60%,65%,80%,85%{
        width: calc(100% + 8px);
    }
}

.about-me1 {
    font-family: var(--main-font);
    text-align: left;
    color: var(--blue-color);
    width: 550px;
    line-height: 1.3;
    font-size: 20px;
}

.about-me2 {
    font-family: var(--main-font);
    text-align: left;
    color: var(--blue-color);
    width: 550px;
    line-height: 1.3;
    margin-bottom: 70px;
    font-size: 20px;
}

.about-me2 span {
    color: var(--purple-color);
    font-weight: 800;
}

.download-btn {
    font-family: var(--main-font);
    height: 50px;
    width: 100%;
    transition: 0.3s;
    font-weight: 500;
    margin-bottom: 35px;
}

.download-content{
    background-color: var(--yellow-color);
    height: 100%;
    width: fit-content;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 10px;
    padding: 20px;
    transition: 0.3s;
}

.download-content span,
.download-content .download-txt {
    text-decoration: none;
    font-size: 22px;
    font-weight: 500;
    color: var(--blue-color);
}

.download-txt {
    margin-left: 8px;
}

.download-content:hover {
    box-shadow: 0 0 0 4px var(--white-color),
    0 0 0 8px var(--yellow-color);
}

/*==== About Section ====*/
.about {
    position: relative;
    width: 100vw;
    height: fit-content;
    overflow: hidden;
    background-color: var(--gray-color);
    transition: all 0.5s ease;
    z-index: 1;
    padding: 0 100px;
}

.title {
    display: flex;
    justify-content: center;
    font-family: var(--main-font);
    font-size: 40px;
    font-weight: 900;
    color: var(--purple-color);
    margin-top: 30px;
    margin-bottom: 30px;
}

.container {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    margin-top: 80px;
}

.left-section, .right-section {
    width: 50%;
}

.content {
    display: flex;
    flex-direction: column;
    margin-top: 110px;
    width: 80%;
}

.content h4 {
    padding-bottom: 16px;
    font-family: var(--main-font);
    font-size: 19px;
}

.prime {
    color: var(--purple-color);
    font-size: 28px;
    font-weight: 900;
}

.lang-en {
    margin-left: 22.3%;
}

.date {
    font-size: 15px;
}

.right-section {
    display: flex;
    flex-direction: column;

}

.skill{
    padding: 45px;
    margin-bottom: 35px;
    background-color: var(--white-color);
    border-radius: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.technecal {
    flex: 2;
}

.bar {
    font-size: 23px;
}

.technical-bars .bar {
    margin: 20px 0;
}

.technical-bars .bar:first-child {
    margin-top: 0;
}

.technical-bars .bar:last-child {
    margin: 0;
}

.technical-bars .bar .info {
    margin-bottom: 5px;
}

.technical-bars .bar .info span {
    font-family: var(--main-font);
    font-size: 17px;
    font-weight: 500;
    animation: showText 0,5 1s linear forwards;
    color: var(--blue-color);
}

.technical-bars .bar .progress-line {
    position: relative;
    border-radius: 10px;
    width: 100%;
    height: 5px;
    background-color: var(--gray-color);
    animation: animates 1s 2s cubic-bezier(1,0,0.5,1) forwards;
    transform: scaleX(0);
    transform-origin: left;
}

@keyframes animates{
    100%{
        transform: scaleX(1);
    }
}

.technical-bars .bar .progress-line span {
    height: 100%;
    background-color: var(--yellow-color);
    position: absolute;
    border-radius: 10px;
    animation: animates 1s 3s cubic-bezier(1,0,0.5,1) forwards;
    transform: scaleX(0);
    transform-origin: left;
}

.progress-line.html span {
    width: 90%;
}

.progress-line.css3 span {
    width: 50%;
}

.progress-line.javascript span {
    width: 20%;
}

.progress-line.nodejs span {
    width: 5%;
}

.progress-line span::after {
    position: absolute;
    padding: 1px 8px;
    background-color: var(--yellow-color);
    color: var(--blue-color);
    font-family: var(--main-font);
    font-size: 12px;
    border-radius: 3px;
    top: -28px;
    right: -20px;
    animation: showText 0.5s 1.5s linear forwards;
    opacity: 0;
}

.progress-line.html span::after {
    content: "90%";
}

.progress-line.css3 span::after {
    content: "50%";
}

.progress-line.javascript span::after {
    content: "20%";
}

.progress-line.nodejs span::after {
    content: "5%";
}

.progress-line span::before {
    content: "";
    position: absolute;
    width: 0;
    height: 0;
    border: 7px solid transparent;
    border-bottom-width: 0px;
    border-right-width: 0px;
    border-top-color: var(--gray-color);
    top: -10px;
    right: 0;
    animation: showText 0.5s 1.5s linear forwards;
    opacity: 0;
}

@keyframes showText{
    100%{
        opacity: 1;
    }
}

.radial-bars {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    align-items: flex-start;
}

.radial-bars .radial-bar {
    width: 30%;
    position: relative;
}

.radial-bars .radial-bar svg {
    margin-top: 20px;
}

.radial-bars .radial-bar .progress-bar {
    stroke-width: 10;
    stroke: var(--gray-color);
    fill: transparent;
    stroke-dasharray: 502;
    stroke-dashoffset: 502;
    stroke-linecap: round;
    animation: animate-bar 1s 2s linear forwards;
}

@keyframes animate-bar{
    100%{
        stroke-dashoffset: -1;
    }
}

.path{
    stroke-width: 10;
    stroke: var(--yellow-color);
    fill: transparent;
    stroke-dasharray: 502;
    stroke-dashoffset: 502;
    stroke-linecap: round;
}
.path-1{animation: animate-path1 1s 3s linear forwards;}
.path-2{animation: animate-path2 1s 3s linear forwards;}
.path-3{animation: animate-path3 1s 3s linear forwards;}

@keyframes animate-path1{
    100%{
        stroke-dashoffset: 60;
    }
}

@keyframes animate-path2{
    100%{
        stroke-dashoffset: 140;
    }
}

@keyframes animate-path3{
    100%{
        stroke-dashoffset: 180;
    }
}

.radial-bar .percentage {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--main-font);
    font-size: 17px;
    font-weight: 500;
    animation: showText 0.5 1s linear forwards;
}

.radial-bar .text-circle{
    font-family: var(--main-font);
    font-size: 17px;
    font-weight: 500;
    display: flex;
    justify-content: center;
}

/*==== Credentials Section ====*/
.credentials {
    width: 100%;
    height: fit-content;
    padding: 10px 150px;
    background-color: var(--white-color);
    gap: 10px;
}

.main-title2 {
    color: var(--purple-color);
    font-family: var(--main-font);
    font-size: 23px;
    font-weight: 800;
    text-decoration: underline;
    text-underline-offset: 10px;
    display: flex;
    padding-bottom: 50px;
}

.card-wrapper {
    margin: 0 60px 35px;
    padding: 20px 10px;
    overflow: hidden;
}

.card-list .card-item {
    list-style: none;
}

.card-list .card-item .card-link {
    user-select: none;
    display: block;
    background-color: var(--gray-color);
    padding: 18px;
    border-radius: 12px;
    text-decoration: none;
    border: 2px solid transparent;
    box-shadow: 0 10px rgba(0, 0, 0, 0.05);
    transition: 0.2s ease;
}

.card-list .card-item .card-link:active {
    cursor: grabbing;
}

.card-list .card-item .card-link:hover {
    border-color: var(--yellow-color);
}

.card-list .card-link .card-image {
    width: 100%;
    aspect-ratio: 16 / 16;
    object-fit: cover;
    border-radius: 10px;
}

.card-list .card-link .badge {
    color: var(--blue-color);
    padding: 8px 16px;
    font-family: var(--main-font);
    font-size: 0.95rem;
    font-weight: 500;
    margin: 16px 0 18px;
    background-color: var(--yellow-color);
    width: fit-content;
    border-radius: 50px;
}

.card-list .card-link .card-title1 {
    font-family: var(--main-font);
    font-size: 1.19rem;
    font-weight: 600;
    color: var(--blue-color);
}

.card-list .card-link .card-button {
    height: 35px;
    width: 35px;
    color: var(--yellow-color);
    border-radius: 50%;
    margin: 30px 0 5px;
    background: none;
    cursor: pointer;
    border: 2px solid var(--yellow-color);
    font-size: 20px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.4s ease;
}

.card-list .card-link .card-soon {
    height: 35px;
    width: 45px;
    color: var(--yellow-color);
    border-radius: 30px;
    margin: 30px 0 5px;
    background: none;
    border: 2px solid var(--yellow-color);
    font-family: "Roboto", serif;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-list .card-link:hover .card-button {
    color: var(--blue-color);
    background: var(--yellow-color);
}

.card-wrapper .swiper-pagination-bullet {
    height: 13px;
    width: 13px;
    opacity: 0.5;
    background: var(--yellow-color);
}

.card-wrapper .swiper-pagination-bullet-active {
    opacity: 1;
}

.card-wrapper .swiper-slide-button {
    color: var(--yellow-color);
    margin-top: -35px;
}

/*==== Project Section ====*/
.projects {
    height: fit-content;
    padding: 20px 150px;
    background-color: var(--gray-color);
}

.projects .card-list .card-item .card-link {
    background-color: var(--white-color);
}

/*==== Contact Section ====*/
.contact {
    height: fit-content;
    position: relative;
    padding: 0 150px 35px;
    background-color: var(--white-color);
}

.container2 {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

.social, .message {
    width: 50%;
}

.message h2{
    margin-bottom: 40px;
    font-family: var(--main-font);
    color: var(--purple-color);
}


.input-group {
    position: relative;
    margin: 20px 0;
}

.input-group label {
    position: absolute;
    top: 50%;
    left: 5px;
    transform: translateY(-50%);
    font-size: 16px;
    font-family: var(--main-font);
    color: var(--blue-color);
    padding: 0 5px;
    pointer-events: none;
    transition: 0.5s;
}

.input-group input {
    width: 420px;
    height: 40px;
    font-size: 15px;
    font-family: var(--main-font);
    color: var(--blue-color);
    padding: 0 10px;
    background-color: transparent;
    border: 1.2px solid var(--yellow-color);
    outline: none;
    border-radius: 5px;
}

.input-group input:focus~label,
.input-group input:valid~label {
    top: 0;
    font-size: 15px;
    background-color: var(--white-color);
}

.input-group textarea {
    width: 420px;
    font-size: 15px;
    font-family: var(--main-font);
    color: var(--blue-color);
    padding: 10px 10px;
    background-color: transparent;
    border: 1.2px solid var(--yellow-color);
    outline: none;
    border-radius: 5px;
}

.input-group textarea:focus~label,
.input-group textarea:valid~label {
    top: 0;
    font-size: 15px;
    background-color: var(--white-color);
}

.message button {
    padding: 10px;
    font-family: var(--main-font);
    font-size: 16px;
    font-weight: 500;
    color: var(--blue-color);
    background-color: var(--yellow-color);
    border: none;
    border-radius: 5px;
    width: 25%;
    cursor: pointer;
    margin-top: 16px;
    transition: 0.3s;
}

.message button:hover {
    box-shadow: 0 0 0 4px var(--white-color),
    0 0 0 8px var(--yellow-color);
}

.social {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 50px;
}

.contact-container {
    display: flex;
    align-items: center;
}

.contact-container i {
    padding: 15px;
    margin: 10px;
    font-size: 25px;
    border-radius: 20%;
    background-color: var(--yellow-color);
    color: var(--blue-color);
    align-items: center;
    justify-content: center;
}

.contact-container p {
    font-family: var(--main-font);
    font-size: 20px;
    font-weight: 400;
    margin-left: 13px;
    color: var(--blue-color);
}

.social-social ul {
    padding: 0;
    margin: 0;
    display: flex;
}

.social-social ul li {
    list-style: none;
    margin: 0 15px 0 0;
}

.social-social ul li .bx {
    font-size: 30px;
    line-height: 60px;
    transition: 0,6s;
    color: var(--blue-color);
}

.social-social ul li .bx:hover {
    color: var(--white-color);
}

.social-social ul li a {
    position: relative;
    display: block;
    width: 60px;
    height: 60px;
    border-radius: 20%;
    background-color: var(--yellow-color);
    text-align: center;
    transition: 0.6s;
}

.social-social ul li a:hover {
    transform: translate(0, -10px);
}

.social-social ul li:nth-child(1) a:hover {
    background-color: #0A66C2;
}

.social-social ul li:nth-child(2) a:hover {
    background-color: #000000;
}

.social-social ul li:nth-child(3) a:hover {
    background-color: #E64771;
}


@media (max-width: 1030px) {
    header {
        padding: 15px 50px;
    }

    .logo {
    height: 100px;
    }

    /* إخفاء القائمة في البداية */
    .content-section nav {
        display: flex;
        flex-direction: column;
        background-color: var(--white-color);
        position: absolute;
        top: 79px; /* ضع الارتفاع المناسب */
        inset-inline-end: 0;
        max-width: 50%;
        box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
        inset-inline-end: 50px;
      
        /* إعدادت الانتقال */
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-in-out;
    }

    .content-section nav.active {
        display: flex;
        max-height: 300px;
        flex-direction: column;
    }
      
    .content-section nav a {
        padding: 12px;
        transition: background-color 0.3s ease-in-out;
        display: flex;
        align-items: center;
        margin-left: 0;
    }
      
    .content-section nav a:hover {
        color: var(--blue-color);
    }
      
    .nav_link {
        font-size: 16px;
        font-weight: 500;
    }
      
    .nav_link i {
        display: inline-block;
        font-size: 20px;
        font-weight: 500;
        margin-right: 10px;
    }
      
    .menu-toggle {
        display: block;
    }
      
    .menu-toggle i {
        transition: transform 0.3s ease-in-out;
    }
      
    .menu-toggle i.bx-x {
        transform: rotate(180deg); /* لتدوير الايقونة */
        color: #7d8a96;
    }

    .home {
        display: flex;
        align-items: center;
        justify-content: center;
        padding:90px 200px 0;
        min-height: 50vh;
        margin-top: 20px;
    }

    .img-container {
        display: none;
    }

    .text-container{
        width: 100%;
        text-align: center;
    }

    .about-me1, .about-me2{
        text-align: center;
        width: 100%;
    }

    .about {
        padding: 0 180px;
        height: fit-content;
    }

    .download-btn {
        display: flex;
        justify-content: center;
    }

    .container {
        flex-direction: column;
        display: flex;
        margin-top: 0px;
    }

    .left-section {
        width: 100%;
    }

    .content {
        display: flex;
        flex-direction: column;
        margin-top: 50px;
        width: 100%;
    }

    .right-section {
        width: 100%;
        margin-bottom: 20px;
    }

    .skill {
        display: flex;
        justify-content: center;
        width: 100%;
    }

    .credentials {
        padding: 0px 50px 35px;
    }

    .projects {
        padding: 10px 50px 35px;
    }

    .contact {
        padding: 10px 50px 35px;
    }

    .social {
        margin-top: 60px;
    }

    .container2 {
        flex-direction: column;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .message {
        margin-top: 40px;
    }

}

@media (max-width: 820px) {
    header {
        padding: 15px 50px;
    }

    /* إخفاء القائمة في البداية */
    .content-section nav {
        display: flex;
        flex-direction: column;
        background-color: var(--white-color);
        position: absolute;
        top: 77px; /* ضع الارتفاع المناسب */
        inset-inline-end: 0;
        max-width: 50%;
        box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
        inset-inline-end: 50px;
      
        /* إعدادت الانتقال */
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-in-out;
    }

    .content-section nav.active {
        display: flex;
        max-height: 300px;
        flex-direction: column;
    }
      
    .content-section nav a {
        padding: 12px;
        transition: background-color 0.3s ease-in-out;
        display: flex;
        align-items: center;
        margin-left: 0;
    }
      
    .content-section nav a:hover {
        color: var(--blue-color);
    }
      
    .nav_link {
        font-size: 16px;
        font-weight: 500;
        font-family: var(--main-font);
        color: #7d8a96;
    }
      
    .nav_link i {
        display: inline-block;
        font-size: 20px;
        font-weight: 500;
        margin-right: 10px;
    }
      
    .menu-toggle {
        display: block;
    }
      
    .menu-toggle i {
        transition: transform 0.3s ease-in-out;
    }
      
    .menu-toggle i.bx-x {
        transform: rotate(180deg); /* لتدوير الايقونة */
        color: var(--text-color);
    }

    .title {
        padding-bottom: 20px;
    }

    .home {
        margin-top: 100px;
        padding: 0 130px;
    }

    .about {
        padding: 0 100px;
        height: fit-content;
    }

    .about .title {
        margin-bottom: 0;
    }

    .container {
        flex-direction: column;
        display: flex;
    }

    .left-section {
        width: 100%;
    }

    .content {
        display: flex;
        flex-direction: column;
        margin-top: 50px;
    }

    .right-section {
        width: 100%;
    }

    .skill {
        display: flex;
        justify-content: center;
        width: 100%;
        margin-bottom: 20px;
    }

    .credentials {
        padding: 10px 20px;
        height: fit-content;
    }

    .projects {
        padding: 10px 20px;
        height: fit-content;
        margin-top: 30px;
    }

    .contact {
        padding: 10px 50px 35px;
    }

    .social {
        margin-top: 60px;
    }

    .container2 {
        flex-direction: column;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .message {
        margin-top: 40px;
    }

}

@media screen and (max-width: 768px) {
    .card-wrapper {
        margin: 0 10px 25px;
    }

    .card-wrapper .swiper-slide-button {
        display: none;
    }

    .home {
        height: 60vh;
        padding: 0 100px;
    }
}

@media (max-width: 430px) {
    header {
        padding: 15px 30px;
    }

    .logo {
    height: 70px;
    }

    .home {
        display: flex;
        align-items: center;
        height: fit-content;
        padding:0 40px;
        margin-top: 100pxpx;
    }

    .name {
        font-size: 30px !important;
    }

    .my-job {
        font-size: 20px;
    }

    .about-me1, .about-me2 {
        font-size:  15px;
    }

    .download-btn {
        height: 40px;
        width: 100%;
    }

    .download-content i,
    .download-content .download-txt {
        font-size: 17px;
    }

    .about {
        padding: 10px 40px;
    }

    .title {
        font-size: 35px;
        padding-bottom: 20px;
    }

    .prime {
        font-size: 19px;
    }

    .content h4 {
        font-size: 14px;
    }

    .date {
        font-size: 10px;
    }

    .credentials {
        padding: 10px 40px;
    }

    .main-title {
        font-size: 25px;
    }

    .contact {
        padding: 10px 40px 35px;
    }

    .input-group input,
    .input-group textarea {
        width: 100%;
    }

    .social, .message {
        width: 100%;
    }

    .social {
        margin-top: 30px;
    }
}
