@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600&display=swap');
:root {
    --global-paragraph-font-size: 1.5rem;
    --global-h3-font-size: 2rem;
}


@font-face {
    font-family: "SuperBouncer";
    src: url('../Fonts/Super Bouncer.ttf');
}

 

    @font-face {
    font-family: 'PialaRegular';
  
    font-style: normal;
    font-weight: bold;
   
    src: local('Piala Regular'), url('../Fonts/Piala-Regular.otf') format('woff');
    }
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    font-family: 'PialaRegular', sans-serif;
  

}
 
body {
 
    width: 100%;
    min-height: 100vh;
    height: 100vh;
    overflow-x: hidden;
    /* background-color: #0b0f0b;*/
    color: #c0cfb2;
    position: relative;
}


.bg-container {
    animation: moveIt 60s linear infinite; 
    margin-top: -10rem;
    width: 100%;
    height: 100%;
    --color1: #0b0f0b;
    --color2: #c0cfb2;

    background-color: var(--color1);
    background-image: linear-gradient(45deg, var(--color2) 27%, transparent 25%, transparent 75%, var(--color2) 75%, var(--color2)),
        linear-gradient(45deg, var(--color2) 27%, var(--color1) 25%, var(--color1) 75%, var(--color2) 75%, var(--color2));
    background-size: 60px 60px;
    background-position: 0 0, 30px 30px;
    z-index: -1;
    position: fixed;

    


}


@keyframes moveIt {
    from {
        
        background-position: 0 0, 30px 30px;
    }
    to {
     
 
        background-position: -1030px 1000px, -1000px 1030px;
    }
}

/* ── Header ── */
header {
    
    transition: background-color 0.5s ease;
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1rem 9%;
    background-color: transparent;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1;
    background-color: #0b0f0b;
   

}

/* ── Scrolled header state ── */
header.scrolled nav {
    display: none;
}

header.scrolled .hamburger {
    display: flex;
    
}

header.scrolled nav.active {
    
     
    align-items: center;
    display: grid;
}

header.scrolled {
   
    background-color: rgba(11, 15, 11, 1);
}



/* ── Nav ── */

nav {
      display: grid;  
}
nav a {
    font-family: "SuperBouncer";
    font-size: 2rem;
    color: #324935;
    margin-left: 4rem;
    font-weight: 500;
    transition: 0.3s ease;
    border-bottom: 3px solid transparent;
}

nav a:hover,
nav a.active {
    color: #c0cfb2;
    border-bottom: 3px solid #44624a;
    font-size: 2.5rem;
    display: grid;
    
}
 
.logo {
    font-family: "SuperBouncer";
    font-size: 3.5rem;
    color: #c0cfb2;
    font-weight: 800;
    cursor: pointer;
    transition: 0.5s ease;
    margin-right: 70rem;
    margin-left: 0.5rem;
   
  
}

.logo:hover {
    transform: scale(1.1);
}



/* ── Hamburger ── */
.hamburger {
    display: flex;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding-left: 12rem;
}

.hamburger span {
    display: flex;
    width: 2.5rem;
    height: 0.2rem;
    background: #c0cfb2;
    
    transition: 0.3s ease;
}

.hamburger.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
 
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
}

.hamburger.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
    
}

/* Hide hamburger on desktop when not scrolled */
@media (min-width: 751px) {
    header:not(.scrolled) .hamburger {
        display: none;
    }
}

/* ── Mobile nav ── */
@media (max-width: 750px) {
    nav {
        position: fixed;
        display: none;
        top: 0;
        right: 0;
        width: 60%;
        max-width: 260px;
        height: 100vh;
        background-color: #111811;
        border-left: 2px solid #44624a;
        padding: 8rem 3rem 3rem;
        flex-direction: column;
        z-index: 150;
    }

    nav.active {
        display: flex;
        
    }

    nav a {
        display: block;
        font-size: 2rem;
        margin: 0 0 2.5rem 0;
        padding-bottom: 1rem;
        border-bottom: 1px solid rgba(68, 98, 74, 0.3);
    }

    nav a:hover,
    nav a.active {
        color: #8ba888;
        border-bottom: 1px solid #44624a;
    }
}



/* ── Sections ── */
section {


    scroll-margin-top: 70px;






}

/* ── Home ── */
.home {
    
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8rem;
    max-width: 82%;

    background-color: #0b0f0b;





    margin: 0 auto;
    margin-top: 15rem;
    padding: 5rem;

}



.home .home-content h1 {
    font-family: 'PialaRegular';
    
    font-size: 4rem;
    line-height: 1.3;
    background-color: #0b0f0b;
}

span {
    font-family: 'SuperBouncer';
    font-size: 4rem;
    margin: auto;
    color: #8ba888;
}

 

.home-content p {
   
    font-family: 'PialaRegular';

    font-size: var(--global-paragraph-font-size);
    margin-right: 10rem;
}



.home-img img {
    position: relative;
    width: 30vw;
    cursor: pointer;
    transition: 0.2s linear;
    margin-top: -8rem;
 
}

/* ── Social icons ── */
.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 3rem;
    height: 3rem;
    background-color: transparent;
    border: 0.2rem solid #c0cfb2;
    font-size: var(--global-paragraph-font-size);
    border-radius: 50%;
    margin: 3rem 1.5rem 3rem 0;
    transition: 0.3s ease;
    color: #8ba888;
 
}

.social-icons a:hover {
    color: #8ba888;
  
    background-color: #c0cfb2;
    box-shadow: 0 0 25px #c0cfb2;
}

/* ── Button ── */
.btn {
    display: inline-block;
    padding: 1rem 1.5rem;
    background-color: transparent;
    border-radius: 5rem;
    font-size: var(--global-paragraph-font-size);
    color: #8ba888;
    letter-spacing: 0.3rem;
    font-weight: 600;
    border: 2px solid #8ba888;
    transition: 0.3s ease;
    cursor: pointer;
    margin-bottom: 1rem;
    
}

.btn:hover {
    transform: scale(1.03);
    background-color: #c0cfb2;
    color: black;
    box-shadow: 0 0 25px #c0cfb2;
}

/* ── Home responsive ── */
@media (max-width: 1000px) {
    .home {
        gap: 4rem;
    }
}

@media (max-width: 995px) {
    .home {
        flex-direction: column;
        margin: 5rem 4rem;
    }

    .home .home-content h3 {
        font-size: 2.5rem;
    }

    .home-content h1 {
        font-size: 5rem;
    }

    .home-img img {
        width: 70vw;
    }
}

/* ── Projects section ── */
.projects {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 2rem;
    padding-left: 9%;
    margin-right: 9%;
    margin-top: 5%
    

}

.game-projects {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(25rem, 1fr));
    gap: 2rem;
     
    
    background-color: #0b0f0b;
    border-color: #0b0f0b;
 
    padding: 1.5rem;
    

}

.projects-header h1 {
    font-size: 6rem;
    font-weight: 700;
    line-height: 1.3;
    background-color: #0b0f0b;
    padding-left: 1rem;
    padding-right: 1rem;
    margin-bottom: -2rem;
    
}

/* ── Card container ── */
.projects .card-container {
    text-align: left;
    color: transparent;
  
 
 


}

/* ── Card ── */
.projects .card-container .card,
.projects>.card {
   
    max-height: 50rem;
    min-height: 45rem;
    background-color: rgba(23, 32, 15, 0.527);
    border-radius: 8px;
    box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    contain: layout paint;
    /* will-change only applied on hover, not all the time —
       having it on every card permanently creates too many GPU layers */
    transition: transform 0.2s ease, box-shadow 0.2s ease;
 
   

}

.projects .card-container .card:hover {
    transform: translateY(-4px);
    box-shadow: 0px 8px 20px rgba(0, 0, 0, 0.4);
    will-change: transform;
}

/* ── Card image and video ── */
.projects .card-container .card img,
.projects .card-container .card video {
    width: 100%;
    height: 220px;
    object-fit: cover;
    filter: saturate(0.7) brightness(0.9);
    transition: filter 0.3s ease;
}

.projects .card-container .card img:hover,
.projects .card-container .card video:hover {
    filter: saturate(1) brightness(1.25);
}

/* ── Lazy placeholder (shown before image/video loads) ── */
img.lazy,
video.lazy-video {
    background-color: rgba(23, 32, 15, 0.5);
    min-height: 220px;
}

/* ── Card legend ── */
.projects .card-container .card-legend {
    display: flex;
    flex-direction: row;
    background-color: #44624aa8;
    padding: 4px 8px;
}

.card-legend h1 {
    color: white;
    margin: 0;
    font-size: 1.4rem;
    white-space: nowrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-right: 12px;
}

.legend-item img {
    max-width: 28px;
    max-height: 28px;
    object-fit: contain;
}

/* ── Card content ── */
.projects .card-container .card-content,
.projects>.card .card-content {
    padding: 10px;
    overflow: hidden;
    flex: 1;
    font-size: 1.2rem;
    
    
}

.card-content h1 {
    
    padding-top: 2rem;
    color: #44624a;
 
    white-space: normal;
    word-break: break-word;
   
}

.card-content h2 {
    padding: 1rem 0 1px 0;
    color: #8ba888;
    
    white-space: normal;
}

.card-content h3 {
    padding: 1rem 0 1px 0;
    color: #c0cfb2;
    
    white-space: normal;
    box-sizing: border-box;
    line-height: 1.6;
}

.card-content span{
    font-size: 1rem;
}
 
#education .card {
     background-color: #0b0f0b;
     margin-top: 0rem;
     border-radius: 0rem;
     margin-left: 0rem;
     min-height: 0;
     margin-bottom: 5rem;
     padding-left: 1rem;
             
}
 
 
 