/* ===========================================================
   BALBA Portfolio
   Premium UI Design
   Part 1
=========================================================== */

/* ===========================
   Root Variables
=========================== */

:root{

    --bg-color:#080808;
    --bg-secondary:#111111;
    --card-bg:#181818;

    --text-color:#ececec;
    --text-secondary:#bdbdbd;

    --accent-color:#c5a059;
    --accent-hover:#ddb86b;

    --border-color:#2f2f2f;

    --shadow:
        0 12px 40px rgba(0,0,0,.45);

    --radius:18px;

    --transition:.35s ease;

    --font-main:
    "Segoe UI",
    Tahoma,
    Geneva,
    Verdana,
    sans-serif;

}

/* ===========================
   Reset
=========================== */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

html{

    scroll-behavior:smooth;

}

body{

    font-family:var(--font-main);

    background:
        radial-gradient(circle at top right,#222 0%,transparent 30%),
        radial-gradient(circle at bottom left,#171717 0%,transparent 35%),
        var(--bg-color);

    color:var(--text-color);

    line-height:1.8;

    overflow-x:hidden;

}

/* Scrollbar */

::-webkit-scrollbar{

    width:11px;

}

::-webkit-scrollbar-track{

    background:#111;

}

::-webkit-scrollbar-thumb{

    background:var(--accent-color);

    border-radius:20px;

}

::-webkit-scrollbar-thumb:hover{

    background:var(--accent-hover);

}

/* ===========================
   Navbar
=========================== */

.navbar{

    position:sticky;

    top:18px;

    z-index:999;

    width:95%;

    margin:20px auto;

    padding:18px 35px;

    display:flex;

    justify-content:space-between;

    align-items:center;

    border-radius:18px;

    border:1px solid rgba(255,255,255,.08);

    background:rgba(15,15,15,.82);

    backdrop-filter:blur(14px);

    box-shadow:var(--shadow);

    transition:var(--transition);

}

.navbar:hover{

    border-color:rgba(197,160,89,.45);

}

.logo{

    font-size:1.7rem;

    font-weight:700;

    letter-spacing:1px;

    color:var(--accent-color);

    user-select:none;

}

.nav-links{

    display:flex;

    align-items:center;

    list-style:none;

    gap:35px;

}

.nav-links li{

    margin:0;

}

.nav-links a{

    color:var(--text-color);

    text-decoration:none;

    font-size:1rem;

    font-weight:500;

    transition:var(--transition);

    position:relative;

}

.nav-links a::after{

    content:"";

    position:absolute;

    left:0;

    bottom:-7px;

    width:0;

    height:2px;

    background:var(--accent-color);

    transition:var(--transition);

}

.nav-links a:hover{

    color:var(--accent-color);

}

.nav-links a:hover::after{

    width:100%;

}

/* ===========================
   Language Buttons
=========================== */

.lang-switch{

    display:flex;

    gap:10px;

}

.lang-switch button{

    cursor:pointer;

    border:none;

    outline:none;

    padding:10px 18px;

    border-radius:10px;

    background:#222;

    color:white;

    font-weight:600;

    transition:var(--transition);

}

.lang-switch button:hover{

    background:var(--accent-color);

    color:#111;

    transform:translateY(-2px);

}
/* ===========================================================
   Hero Section
=========================================================== */

.hero{

    position:relative;

    display:flex;

    justify-content:center;

    align-items:center;

    min-height:90vh;

    text-align:center;

    overflow:hidden;

    padding:120px 20px 100px;

}

/* طبقة شفافة فوق الخلفية */

.hero-overlay{

    position:absolute;

    inset:0;

    background:
        radial-gradient(circle at top,#c5a05918,transparent 40%),
        linear-gradient(to bottom,
            rgba(0,0,0,.15),
            rgba(0,0,0,.55));

    z-index:0;

}

/* المحتوى */

.hero-content{

    position:relative;

    z-index:5;

    max-width:900px;

}

/* SOFTWARE ENGINEER */

.hero-tag{

    display:inline-block;

    padding:10px 22px;

    margin-bottom:25px;

    border-radius:50px;

    border:1px solid rgba(197,160,89,.35);

    background:rgba(255,255,255,.04);

    color:var(--accent-color);

    font-size:.9rem;

    letter-spacing:3px;

    font-weight:600;

    backdrop-filter:blur(10px);

}

/* الاسم */

.hero h1{

    font-size:4.3rem;

    font-weight:800;

    color:#ffffff;

    margin-bottom:18px;

    line-height:1.15;

    text-shadow:

        0 0 15px rgba(197,160,89,.25);

}

/* الوصف */

.subtitle{

    font-size:1.35rem;

    color:var(--text-secondary);

    margin-bottom:45px;

}

/* الأزرار */

.hero-buttons{

    display:flex;

    justify-content:center;

    gap:18px;

    flex-wrap:wrap;

}

/* الزر الأساسي */

.btn{

    margin-top: auto;
    display:inline-flex;

    justify-content:center;

    align-items:center;

    padding:14px 34px;

    border-radius:12px;

    border:1px solid var(--accent-color);

    color:var(--accent-color);

    text-decoration:none;

    font-weight:700;

    transition:var(--transition);

    background:transparent;

}

/* Hover */

.btn:hover{

    background:var(--accent-color);

    color:#111;

    transform:translateY(-4px);

    box-shadow:

        0 10px 25px rgba(197,160,89,.25);

}

/* الزر الثاني */

.secondary-btn{

    border-color:#444;

    color:#ffffff;

}

.secondary-btn:hover{

    border-color:var(--accent-color);

}

/* ===========================================================
   Floating Circles
=========================================================== */

.hero-circle{

    position:absolute;

    border-radius:50%;

    filter:blur(8px);

    opacity:.25;

    animation:floatCircle 8s ease-in-out infinite;

}

.hero-circle-1{

    width:320px;

    height:320px;

    background:var(--accent-color);

    top:-120px;

    right:-120px;

}

.hero-circle-2{

    width:240px;

    height:240px;

    background:#444;

    bottom:-80px;

    left:-80px;

    animation-delay:2s;

}

.hero-circle-3{

    width:120px;

    height:120px;

    background:#ffffff22;

    top:45%;

    right:15%;

    animation-delay:4s;

}

/* حركة الدوائر */

@keyframes floatCircle{

    0%{

        transform:translateY(0px);

    }

    50%{

        transform:translateY(-25px);

    }

    100%{

        transform:translateY(0px);

    }

}
/* ===========================================================
   About Section
=========================================================== */

.about-section{

    position:relative;

    background:linear-gradient(145deg,#171717,#101010);

    border:1px solid rgba(255,255,255,.08);

    border-radius:22px;

    box-shadow:0 20px 60px rgba(0,0,0,.45);

    padding:70px 50px;

    margin:80px auto;

    transition:var(--transition);

}

.about-section:hover{

    transform:translateY(-6px);

    border-color:rgba(197,160,89,.35);

}

.about-section h2{

    font-size:2.4rem;

    color:var(--accent-color);

    margin-bottom:35px;

    text-align:center;

    position:relative;

}

.about-section h2::after{

    content:"";

    width:90px;

    height:3px;

    background:var(--accent-color);

    display:block;

    margin:18px auto 0;

    border-radius:20px;

}

.bio-text{

    font-size:1.18rem;

    color:var(--text-secondary);

    text-align:justify;

    line-height:2.2;

}



/* ===========================================================
   Projects Section
=========================================================== */

.projects-container{

    margin-top:90px;

}

.projects-container h2{

    text-align:center;

    font-size:2.5rem;

    color:var(--accent-color);

    margin-bottom:60px;

    position:relative;

}

.projects-container h2::after{

    content:"";

    width:110px;

    height:3px;

    background:var(--accent-color);

    display:block;

    margin:18px auto;

}



/* ===========================================================
   Projects Grid
=========================================================== */

.grid-wrapper{

    display:grid;

    grid-template-columns:repeat(auto-fit,minmax(370px,1fr));

    gap:35px;

    padding:20px;

}



/* ===========================================================
   Project Card
=========================================================== */

.project-card{

     background: #161616;

    padding: 20px;

    border: 1px solid #333;

    transition: 0.4s;

    text-align: center;

    display: flex;
    flex-direction: column;

    position:relative;

    overflow:hidden;

    background:linear-gradient(145deg,#1a1a1a,#111);

    border:1px solid rgba(255,255,255,.08);

    border-radius:22px;

    transition:.45s ease;

    box-shadow:

        0 12px 35px rgba(0,0,0,.35);

}

.project-card:hover{

    transform:

        translateY(-12px)

        scale(1.02);

    border-color:rgba(197,160,89,.45);

    box-shadow:

        0 25px 60px rgba(0,0,0,.55);

}



/* ===========================================================
   Images
=========================================================== */

.project-card img{

    width:100%;

    display:block;

    transition:.6s;

    background:#000;

}

.project-card:hover img{

    transform:scale(1.05);

}

.project-card img.full-img {

    width: 100%;

    height: 275px;      /* اختر ارتفاعًا يناسب جميع الصور */

    object-fit: contain;

    background-color: #000;

}


/* ===========================================================
   Card Content
=========================================================== */

.project-content{

    padding:25px;

}

.project-card h3{

    color:#fff;

    font-size:1.45rem;

    margin-bottom:15px;

}

.project-card p{

    color:var(--text-secondary);

    line-height:1.9;

    min-height:75px;

}



/* ===========================================================
   Button Inside Card
=========================================================== */

.project-card .btn{

    width:100%;

    margin-top:25px;

    padding:14px;

    border-radius:12px;

    text-align:center;

    justify-content:center;

}



/* ===========================================================
   Golden Line Animation
=========================================================== */

.project-card::before{

    content:"";

    position:absolute;

    top:0;

    left:-120%;

    width:80%;

    height:100%;

    background:

        linear-gradient(

            120deg,

            transparent,

            rgba(255,255,255,.18),

            transparent

        );

    transition:.8s;

}

.project-card:hover::before{

    left:130%;

}
/* ===========================================================
   Footer
=========================================================== */

footer{

    position:relative;

    background:linear-gradient(180deg,#121212,#090909);

    border-top:1px solid rgba(255,255,255,.08);

    margin-top:100px;

    padding:70px 20px 40px;

    text-align:center;

}

footer h2{

    font-size:2.2rem;

    color:var(--accent-color);

    margin-bottom:20px;

}

footer p{

    color:var(--text-secondary);

    line-height:1.8;

}

.contact-links{

    margin-top:35px;

    display:flex;

    justify-content:center;

    align-items:center;

    gap:30px;

    flex-wrap:wrap;

}

.contact-links a{

    color:#fff;

    text-decoration:none;

    padding:14px 22px;

    border-radius:12px;

    border:1px solid rgba(255,255,255,.08);

    background:#181818;

    transition:var(--transition);

    font-weight:600;

}

.contact-links a:hover{

    transform:translateY(-5px);

    border-color:var(--accent-color);

    background:#202020;

    box-shadow:0 12px 30px rgba(0,0,0,.35);

}



/* ===========================================================
   Smooth Animation
=========================================================== */

.project-card,
.about-section,
.navbar,
.hero-content{

    animation:fadeUp .9s ease both;

}

@keyframes fadeUp{

    from{

        opacity:0;

        transform:translateY(30px);

    }

    to{

        opacity:1;

        transform:translateY(0);

    }

}



/* ===========================================================
   Selection
=========================================================== */

::selection{

    background:var(--accent-color);

    color:#111;

}



/* ===========================================================
   Mobile Responsive
=========================================================== */

@media (max-width:992px){

    .navbar{

        width:96%;

        padding:18px;

    }

    .hero h1{

        font-size:3rem;

    }

    .subtitle{

        font-size:1.15rem;

    }

    .grid-wrapper{

        grid-template-columns:1fr;

    }

}



@media (max-width:768px){

    body{

        padding:0;

    }

    .navbar{

        flex-direction:column;

        gap:18px;

        text-align:center;

        top:0;

        border-radius:0;

        width:100%;

        margin:0;

    }

    .nav-links{

        flex-wrap:wrap;

        justify-content:center;

        gap:20px;

    }

    .hero{

        min-height:80vh;

        padding:100px 20px 70px;

    }

    .hero h1{

        font-size:2.4rem;

    }

    .hero-tag{

        font-size:.8rem;

        letter-spacing:2px;

    }

    .hero-buttons{

        flex-direction:column;

        align-items:center;

    }

    .hero-buttons .btn{

        width:100%;

        max-width:300px;

    }

    .about-section{

        padding:40px 25px;

        margin:50px 15px;

    }

    .projects-container{

        padding:0 15px;

    }

    .project-content{

        padding:20px;

    }

}



@media (max-width:480px){

    .hero h1{

        font-size:2rem;

    }

    .subtitle{

        font-size:1rem;

    }

    .logo{

        font-size:1.4rem;

    }

    .about-section h2,

    .projects-container h2,

    footer h2{

        font-size:1.8rem;

    }

}



/* ===========================================================
   Small Hover Effects
=========================================================== */

img{

    user-select:none;

    -webkit-user-drag:none;

}

button{

    font-family:inherit;

}

a{

    transition:var(--transition);

}

section{

    scroll-margin-top:120px;

}