/* --- Global --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    background: #22311d;
    color: #d0c8a8;
}

a {
    text-decoration: none;
}

/* --- Header --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(34, 49, 29, 0.85);
    backdrop-filter: blur(4px);
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1200px;
    margin: auto;
}

nav .logo {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.8rem;
    color: #d0c8a8;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

nav ul li a {
    font-weight: 600;
    color: #d0c8a8;
    transition: 0.3s;
}

nav ul li a:hover {
    color: #9a542e;
}

/* --- Sections --- */
section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem;
    position: relative;
    opacity: 0;
    transform: translateY(30px);
    transition: 0.8s ease-in-out;
    overflow: hidden;
}

section.visible {
    opacity: 1;
    transform: translateY(0);
}

h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    margin-bottom: 1rem;
    position: relative;
    color: #d0c8a8;
}

h2::after {
    content: "";
    display: block;
    width: 80px;
    height: 3px;
    background: #9a542e;
    margin-top: 0.5rem;
    border-radius: 2px;
}

/* --- Organic line-art behind headers --- */
h2::before {
    content: "";
    position: absolute;
    width: 150px;
    height: 50px;
    background: url("assets/leafLineArt.png") no-repeat center;
    background-size: contain;
    top: -20px;
    left: -20px;
    opacity: 1;
}

/* --- Section backgrounds --- */
#home {
    background: #22311d;
    flex-direction: column;
    text-align: center;
}

/* --- About --- */
#about {
    background: #22311d;
    /* green background */
    display: flex;
    justify-content: center;
    align-items: center;
}

#experience {
    background: #22311d;
    flex-direction: column;
    max-width: 800px;
    margin: auto;
    padding: 4rem 2rem;
    text-align: center;
}

#projects {
    background: #d0c8a8;
    color: #303a45;
    flex-direction: column;
    text-align: center;
}

#skills {
    background: #8f9779;
    color: #22311d;
    flex-direction: column;
    text-align: center;
}

#contact {
    background: #22311d;
    color: #d0c8a8;
    flex-direction: column;
    text-align: center;
}

/* --- Hero --- */
#home h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #d0c8a8;
}

#home p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: #d0c8a8;
}

.about-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    max-width: 1000px;
    gap: 2rem;
}

.about-image img {
    flex: 1 1 300px;
    /* base width */
    max-width: 300px;
    border-radius: 50% 50% 0 0;
    overflow: hidden;
    border: 30px solid #738678;
    object-fit: cover;
    display: block;
}

.about-content h2 {
    margin-bottom: 1rem;
    color: #d0c8a8;
}

.about-content p {
    color: #d0c8a8;
    margin-bottom: 1rem;
    line-height: 1.5;
}

/* Mobile responsiveness */
@media (max-width:768px) {
    .about-container {
        flex-direction: column;
        align-items: center;
    }

    .about-content {
        text-align: center;
    }
}


/* --- Experience --- */
.resume-section h2 {
    text-align: center;
    margin-bottom: 2rem;
}

.resume-section .resume-item {
    margin-bottom: 2rem;
}

.resume-section .resume-item h3,
.resume-section .resume-item span {
    text-align: center;
    color: #d0c8a8;
}

.resume-section .resume-item h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
}

.resume-section .resume-item span {
    font-size: 1rem;
    color: #9a542e;
}

.resume-section .resume-item p {
    display: none;
}

/* --- Projects --- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: auto;
}

.project-card {
    background: rgba(208, 200, 168, 0.85);
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
}

.project-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://www.transparenttextures.com/patterns/xv.png') no-repeat center;
    background-size: cover;
    opacity: 0.12;
    border-radius: 15px;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.project-card img {
    height: 200px;
    object-fit: cover;
    position: relative;
    z-index: 1;
    border-bottom: 1px solid #9a542e;
}

.project-card .info {
    padding: 1rem;
    position: relative;
    z-index: 2;
}

.project-card .info h3 {
    font-family: 'Playfair Display', serif;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
    color: #9a542e;
}

.project-card .info p {
    font-size: 0.9rem;
    color: #303a45;
}

/* --- Skills --- */
.skills-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
}

.skill {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 120px;
    padding: 1rem;
}

.skill i {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    transition: transform 0.3s;
}

.skill i:hover {
    transform: scale(1.2) rotate(5deg);
    color: #bf935c;
}

/* --- Contact --- */
form {
    display: flex;
    flex-direction: column;
    max-width: 400px;
    width: 100%;
    margin: auto;
    gap: 1rem;
}

form input,
form textarea {
    padding: 0.8rem;
    border-radius: 8px;
    border: 1px solid #bf935c;
    font-size: 1rem;
    background: rgba(208, 200, 168, 0.1);
    color: #d0c8a8;
}

form button {
    background: #493124;
    color: #d0c8a8;
    padding: 0.8rem;
    border-radius: 50px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: 0.3s;
}

form button:hover {
    background: #bf935c;
}

footer {
    text-align: center;
    padding: 1.5rem 0;
    color: #d0c8a8;
}

/* --- Body texture --- */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://www.transparenttextures.com/patterns/xv.png');
    opacity: 0.05;
    z-index: -1;
}

@media(max-width:768px) {
    #about {
        flex-direction: column;
        border-radius: 50% 50% 0 0;
    }
}