/* ===============================
    Variables & Base
    =============================== */
:root{
    --pink: #ff7ad9;
    --soft-pink: #ffd6f3;
    --blue: #4d8eff;
    --mint: #b6f27c;
    --bg: #fef6ff;
    --muted: #515151;
    --max-width: 1100px;
}

*{
    box-sizing: border-box;
}
html{
    scroll-behavior: smooth;
}
body{
    margin: 0;
    font-family: "Poppins", sans-serif;
    background: var(--bg);
    color: #222;
    -webkit-font-smoothing: antialiased;
}

/* ===============================
    Typography & Helpers
    =============================== */
.container{
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}
.section{
    padding: 90px 20px;
    position: relative;
}
.section-title, h2{
    margin: .2rem 0 0;
    font-size: clamp(1.3rem, 2.4vw, 1.9rem);
}
.lead{
    color: #444;
    margin: 14px 0 18px;
}
.dashed-divider{
    border: none;
    border-top: 3px dashed #ff7ad9;
    margin: 10px auto;
    width: 45%;
}

.highlight, .highlight-inline{
    font-family: "Momo Signature", cursive;
    color: var(--pink);
    font-size: 1.3em;
}

/* Text Gradient utility */
.text-gradient {
    background: linear-gradient(45deg, var(--pink), #6c63ff); /* Using the pink variable */
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent; /* Fallback for browsers */
    -webkit-text-fill-color: transparent;
}

/* Simplified Font Classes (Keep only essential for specific styling) */
.poppins-medium { font-weight: 500; }
.poppins-semibold { font-weight: 600; }

/* ===============================
 Home Section (Adjusted to Center Image Only)
 =============================== */
.home{
 display: flex;
 align-items: center;
 justify-content: center;
 min-height: 100vh;
 background: linear-gradient(135deg, #ffb8ec, #b6f8ff);
 background-size: cover;
 overflow: hidden;
 padding-top: 100px;
 overflow: hidden;
 padding-top: 100px;
}
.home-inner{
display: flex;
align-items: center;
justify-content: center;
width: 100%;
}
.home-image{
 flex: 0 0 auto;
 max-width: 100%;
 display: flex;
 align-items: center;
 justify-content: center;
 position: relative;
}

.image-stack {
    position: relative;
    width: 100%; 
    max-width: 1500px;
}

.image-stack img {
    width: 100%; 
    height: auto;
    display: block;
}

.back-img {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 0;
    animation: float-reverse 6s ease-in-out infinite;
    width: 30%;
    height: auto;
}

.front-img {
    position: relative;
    z-index: 1;
    animation: float 6s ease-in-out infinite;
}

/* ===============================
    Media Queries
    =============================== */
@media (max-width: 900px){
    .home-inner{
        flex-direction: column-reverse; 
        align-items: center;
        text-align: center;
        padding-top: 150px; 
    }
    .home-text{
        /* Reset positioning for mobile stacking */
        text-align: center; 
        flex: auto; 
        width: 100%;
        margin-right: 0; /* Remove negative margin on mobile */
    }
    .home-image {
        flex: auto;
        width: 100%;
        max-width: 400px;
    }
    .home-text h1 { 
        font-size: clamp(3rem, 10vw, 4.5rem); 
    }
    .home-subtitle {
        font-size: 1rem;
    }
}

/* ===============================
    Buttons
    =============================== */
.btn{
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    border-radius: 28px;
    text-decoration: none;
    font-weight: 700;
    transition: all .2s ease;
}
.btn-primary{
    background: linear-gradient(90deg, var(--pink), var(--blue));
    color: #fff;
    box-shadow: 0 10px 30px rgba(77, 142, 255, 0.12);
}
.btn-primary:hover{
    background: #6c63ff; /* Solid fallback/hover color */
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(108, 99, 255, 0.4);
}

/* ===============================
    Navbar
    =============================== */
.site-header{
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    z-index: 60;
}
.nav-wrap{
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 3rem;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 18px rgba(0,0,0,0.04);
}
.nav-left{
    display: flex;
    align-items: center;
    gap: 12px;
}
.logo{
    width: 44px;
    height: 44px;
    object-fit: cover;
    border-radius: 8px;
    background: transparent;
}
.site-title{
    font-weight: 700;
    color: var(--muted);
    font-size: 1rem;
    white-space: nowrap;
}
.nav-right{
    display: flex;
    gap: 20px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav-right a{
    text-decoration: none;
    color: var(--muted);
    font-weight: 600;
    padding: 8px 10px;
    border-radius: 8px;
    transition: all .18s;
}
.nav-right a:hover{
    color: var(--blue);
    transform: translateY(-2px);
}
.nav-toggle{
    display: none;
    background: none;
    border: 0;
    padding: 8px;
    cursor: pointer;
}
.hamburger{
    width: 22px;
    height: 2px;
    background: var(--muted);
    display: block;
    position: relative;
}
.hamburger::before, .hamburger::after{
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--muted);
}
.hamburger::before{ top: -6px; }
.hamburger::after{ top: 6px; }

/* ===============================
    About Section
    =============================== */
.about-section{
    background: linear-gradient(180deg, #fff, #fffdf6);
}
.about-inner{
    display: flex;
    gap: 28px;
    align-items: flex-start;
}
.about-image{
    flex: 0 0 320px;
}
.about-image img{
    width: 100%;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 12px 30px rgba(0,0,0,0.06);
}
.about-content{
    flex: 1;
}

/* subsections */
.subsections{
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 12px;
}
.subcard{
    background: #fff;
    padding: 14px;
    border-radius: 12px;
    box-shadow: 0 8px 18px rgba(0,0,0,0.04);
    flex: 1;
    min-width: 220px;
}

/* ===============================
Projects Section (Updated to .project-card)
=============================== */

/* --- General container and Layout --- */
.projects-section .container {
padding-top: 50px;
width: 100%;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column; 
}

.project-cards-container {
width: 100%;
display: flex;
justify-content: center;
align-items: center;
flex-wrap: wrap; 
gap: 30px; 
padding-top: 30px;
padding-bottom: 50px; 
}

/* --- Base Project Card Styles --- */
.project-card {
position: relative;
width: 500px;
height: 230px;
padding: 15px;
background: linear-gradient(60deg, #151516 0%, #1d2229 100%); 
overflow: hidden;
margin-bottom: 15px; 
border-radius: 20px;
box-shadow: 0 0 15px rgba(0, 0, 0, 0.3); 
cursor: pointer;
}

/* Card Heading */
.project-card h2 {
z-index: 99;
position: absolute;
bottom: 25px;
right: 130px;
font-size: 50px;
font-weight: 70 0;
color: #fff;
pointer-events: none;
transition: 0.2s ease;
text-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
margin: 0;
}

/* Paragraph Description */
.project-card p {
z-index: 99;
position: absolute;
bottom: 30px;
right: 130px;
width: 150px;
color: #fff;
opacity: 0;
font-size: 12px;
text-align: right;
letter-spacing: 1px;
transition: 0.2s ease;
margin: 0;
}

/* Hover Span */
.project-card span {
z-index: 99;
position: absolute;
top: 60px;
right: 35px;
color: #fff;
font-size: 12px;
letter-spacing: 1px;
writing-mode: vertical-lr;
transition: 0.2s ease;
opacity: 0.7;
}

/* Image Placeholder (.pic) - Applies to Card 1 */
.project-card .pic {
z-index: 100;
width: 395px;
height: 200px;
background-image: url(images/img1.jpg); 
background-size: cover;
background-position: center;
border-radius: 12px;
filter: grayscale(100%);
transition: 0.3s ease;
}

/* Action Button (Applies to Card 1) */
.project-card button {
position: absolute;
right: 30px;
bottom: 40px;
width: 30px;
height: 30px;
/* Color from snippet */
background-color: #772a9b; 
border: none;
border-radius: 30px;
cursor: pointer;
outline: none;
opacity: 1;
transition: 0.3s ease;
}

/* --- HOVER EFFECTS --- */

.project-card:hover button {
transform: scale(16.5);
opacity: 0.5;
}

.project-card:hover h2 {
bottom: 80px;
right: 50px;
}

.project-card:hover p {
opacity: 1;
right: 60px;
}

.project-card:hover span {
opacity: 0;
top: 80px;
}

.project-card:hover .pic {
filter: grayscale(0);
width: 470px;
}

/* --- UNIQUE STYLING PER CARD (Updated to use .cardX class alongside .project-card) --- */

/* Card 2 */
.project-card.card2 .pic {
background-image: url(images/img2.jpg); 
transition: 0.3s ease;
}

.project-card.card2 button {
background-color: #26c3a1; 
}

/* Card 3 - ADD YOUR COLORS AND IMAGE PATHS HERE */
.project-card.card3 .pic {
background-image: url(images/img3.jpg); 
}

.project-card.card3 button {
background-color: #fce4ec; /* Placeholder color */
}

/* Card 4 */
.project-card.card4 .pic {
background-image: url(images/img4.jpg); 
}

.project-card.card4 button {
background-color: #40c0cb; /* Placeholder color */
}

/* Card 5 */
.project-card.card5 .pic {
background-image: url(images/img5.jpg); 
}

.project-card.card5 button {
background-color: #ff69b4; /* Placeholder color */
}

/* Card 6 */
.project-card.card6 .pic {
background-image: url(images/img6.jpg); 
}

.project-card.card6 button {
background-color: #ff6f91; /* Placeholder color */
}

/* Card 7 */
.project-card.card7 .pic {
background-image: url(images/img7.jpg); 
}

.project-card.card7 button {
background-color: #3b5998; /* Placeholder color */
}

/* Card 8 */
.project-card.card8 .pic {
background-image: url(images/img8.jpg); 
}

.project-card.card8 button {
background-color: #ffa500; /* Placeholder color */
}

/* --- Media Queries --- */
@media (max-width: 850px) {
/* Adjust container padding */
.project-cards-container {
gap: 20px;
padding: 20px 0; /* Reduced horizontal padding */
flex-direction: column; /* Optional: ensures stacking, though width usually forces it */
}

/* Card takes up 90% of the viewport width */
.project-card {
width: 90%; 
max-width: 450px; /* Limits size on very wide tablets */
height: 180px; /* Reduced height */
margin-bottom: 20px;
padding: 10px;
}

/* Image sizing adjusted for the narrower card */
.project-card .pic {
width: 95%; 
height: 160px;
margin-left: 2%; 
}

/* Heading size and position */
.project-card h2 {
font-size: 36px;
right: 15px;
bottom: 15px;
}

/* Paragraph positioning */
.project-card p {
width: 120px;
font-size: 11px;
right: 15px;
bottom: 50px; 
}

/* Button position */
.project-card button {
right: 20px;
bottom: 30px;
}

/* HOVER ADJUSTMENTS */
.project-card:hover h2 {
bottom: 60px; 
right: 40px;
}

.project-card:hover p {
right: 50px;
}

/* Scale button less on hover to fit the smaller card */
.project-card:hover button {
transform: scale(11); 
}
}

/* ===============================
    Contact (Envelope) Section
    =============================== */
.contact-section {
    text-align: center;
}
.fa-arrow-down{
    color: #6c63ff;
    font-size: 3rem;
    margin-top: 20px;
    animation: float-reverse 6s ease-in-out infinite;
}
/* ===============================
 Envelope & Letter Styles (Wider)
 =============================== */
.envlope-wrapper {
 height: 300px;
 display: flex;
 justify-content: center;
 align-items: center;
 margin-top: 50px;
}
#envelope {
 position: relative;
 width: 450px;
 height: 260px;
 border-bottom-left-radius: 6px;
 border-bottom-right-radius: 6px;
 box-shadow: 0 6px 24px rgba(0,0,0,0.0);
}
.flap {
 position: absolute;
 top: 0;
 left: 0;
 width: 0;
 height: 0;
 border-left: 225px solid transparent; 
 border-right: 225px solid transparent; 
 border-bottom: 100px solid transparent;
 border-top: 130px solid var(--pink);
 transform-origin: top;
 pointer-events: none;
 transition: transform 0.4s ease, z-index 0.6s;
 z-index: 3;
}
.pocket {
 position: absolute;
 top: 0;
 left: 0;
 width: 0;
 height: 0;
 border-left: 225px solid var(--soft-pink);
 border-right: 225px solid var(--soft-pink);
 border-bottom: 120px solid var(--pink);
 border-top: 130px solid transparent;
 border-bottom-left-radius: 6px;
 border-bottom-right-radius: 6px;
 z-index: 2;
}
.letter {
 position: relative;
 background-color: #fff;
 width: 95%;
 height: 85%;
 margin: auto;
 top: 5%;
 border-radius: 6px;
 box-shadow: 0 2px 26px rgba(0,0,0,0.12);
 transition: transform 0.4s 0.6s ease, z-index 0.6s;
 z-index: 1;
 padding: 30px 20px;
 display: flex;
 flex-direction: column; 
 justify-content: center;
 align-items: center;
}
.open .flap { transform: rotateX(180deg); z-index: 0; }
.close .flap { transform: rotateX(0deg); z-index: 3; }
.close .letter { transform: translateY(0px); }
.open .letter { transform: translateY(-120px); }

/* Buttons inside letter */
.contact-actions {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    gap: 7px;
    padding-bottom: 40px;
    width: 100%;
}
.contact-btn {
    padding: 10px 18px;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    transition: all 0.2s ease;
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.contact-btn.wa { background: #25d366; }
.contact-btn.mail { background: var(--pink); }
.contact-btn.li { background: #6c63ff; }
.contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

/* Reset button */
.reset button {
    font-weight: 700;
    border-radius: 28px;
    padding: 10px 18px;
    font-size: 0.9rem;
    text-transform: uppercase;
    cursor: pointer;
    border: 2px solid var(--pink);
    color: var(--pink);
    background: transparent;
    transition: all 0.2s ease;
    margin: 15px 0 0;
}
.reset button:hover {
    background: var(--pink);
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255, 122, 217, 0.3);
}

/* Scroll to top arrow */
.fa-arrow-up {
    font-size: 2rem;
    margin: 10px auto;
}
.scroll-to-top-wrap {
    list-style: none;
    position: fixed; 
    right: 30px;
    bottom: 50px;
    z-index: 999; 
}

/* ===============================
    Footer
    =============================== */
.site-footer{
    background: linear-gradient(90deg, #ff7ad9, #0066ff);
    color: #fff;
    padding: 5px 5px;
    text-align: center;
    margin: auto;
}

/* ===============================
    Animations
    =============================== */
/* General floating animation (used by home image and project cards) */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(30px); }
    100% { transform: translateY(0px); }
}

/* Reverse floating animation (used by background image and arrow) */
@keyframes float-reverse {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

/* Bubble drifting animation */
.bubbles-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 3;
}
.bubble {
  position: absolute;
  object-fit: contain;
  animation: drift 10s infinite linear;
  border-radius: 50%;
  opacity: 0.22;
  mix-blend-mode: screen;
}
/* Keyframes for the drifting animation */
@keyframes drift {
  0% { transform: translateY(0) scale(1); opacity: 1; }
  100% { transform: translateY(-60vh) scale(0.9); opacity: 0; }
}

/* ===============================
    Media Queries (Responsiveness)
    =============================== */
@media (max-width: 900px){
    /* Home Section */
    .home-inner{
        flex-direction: column-reverse;
        align-items: center;
        text-align: center;
        padding: 20px;
    }
    .home-text{
        text-align: center;
    }
    .image-stack {
        width: 100%;
    }

    /* Navbar */
    .nav-wrap {
        padding: 1rem 2rem;
    }
    .nav-right{
        display: none;
        position: absolute;
        right: 16px;
        top: 60px;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(8px);
        flex-direction: column;
        padding: 12px;
        border-radius: 8px;
        box-shadow: 0 12px 24px rgba(0,0,0,0.06);
    }
    .nav-right.open{
        display: flex;
    }
    .nav-toggle{
        display: block;
    }

    /* About Section */
    .about-inner{
        flex-direction: column;
    }
    .about-image{
        flex: 0 0 100%;
    }
    .subcard{
        min-width: 100%;
    }

    /* Projects Section */
    .projects-grid{
        grid-template-columns: 1fr;
    }

    /* Modal */
    html.modal-open main{
        filter: blur(6px) !important;
    }
}