:root {
  /* Backgrounds */
  --background: #F8F9FB;
  --surface: #FFFFFF;
  --surface-muted: #F1F3F5;

  /* Text */
  --text-primary: #111827;
  --text-secondary: #64748B;

  /* Borders */
  --border: #E5E7EB;

  /* Brand / Accent */
  --primary: #08153c;
  --primary-light: #7DB3FF;
  /* --primary-dark: #1D4ED8; */

  /* Optional effects */
  --accent-gradient: linear-gradient(
    135deg,
    #08153c,
    #7DB3FF
  );
    --accent-gradient-rev: linear-gradient(
    225deg, 
    #7DB3FF,
    #08153c
);


  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 10px 30px rgba(15, 23, 42, 0.08);
}

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Manrope', sans-serif;
}


header{
    position:fixed;
    top:1rem;
    left:50%; /* header into centre of page */
    transform:translateX(-50%); /* centre within div */
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5rem;
    /* background-color: var(--primary-light); */
    backdrop-filter: blur(8px);
    color: var(--surface);
    padding: 0.5rem 1.5rem;
    border-radius: 3rem;
    z-index: 10000; /* remains at top of page */
    border-bottom: 1px solid var(--border);
    transition: background-color 0.3s ease-in-out;

}

header.nav-solid{
    background-color: var(--surface);
}

header.nav-solid #menu-icon{
    color: var(--text-primary);
}

/* .logo{
    background: var(--accent-gradient);
    background-clip: text;
    color: transparent;
    font-size: 1.3rem;
    font-weight: 600;
    transition: 0.3s ease-in-out;
} */

.logo img {
    height: clamp(60px, 5vw, 60px);
    width: auto;
    transform:translateX(40%);
    border-radius:1rem;
}

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

.section-links{
    display: flex;
    gap: 2rem;    
    list-style: none;

}

a {
    text-decoration: none;
    text-wrap: nowrap;
    position: relative;

}

.section-links a{
    /* color: var(--text-secondary); */
    color:black;
    font-weight: 700;
}

.section-links a::before{
    position: absolute;
    content: '';
    width:0;
    left:0;
    height: 5px;
    top: 25px;
    border-radius: 1rem;
    transition: 0.3s ease-in-out;
    background: var(--accent-gradient);

}

.section-links li a:hover::before{
    width:100%;
}
.visit-btn{
    padding: 0.8rem 1.5rem;
    border-radius: 3rem;
    border: none;
    font-weight:500;
    font-size:1rem;
    cursor:pointer;
    text-wrap: nowrap;
    transition: 0.3s ease-in-out;
    color:var(--background);
    background: var(--primary);
}
.visit-btn:hover{
    background: var(--primary-light);
    transform:scale(1.03);
}

.btn-group a:visited {
  color: inherit;
}

#menu-icon{
    font-size: 2rem;
    display: none;
} 

body{
    background-color: var(--background);
    color: var(--text-primary);
}

section{
    min-height: 100vh;
    padding: 8rem 12%;
    width: 100%;
    position: relative;

}

.about{
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 12%;
    overflow: hidden;
    z-index: 5;
}

.section-bg{
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
}

.blob{
    position: absolute;
    border-radius: 50%;
    background: var(--accent-gradient);
    filter: blur(90px) grayscale(100%);
    opacity: 0.5;
}

.blob-color{
    filter: blur(90px);
    opacity: 0.35;
    -webkit-mask-image: radial-gradient(340px circle at var(--mx, 50%) var(--my, 50%), black 0%, transparent 100%);
    mask-image: radial-gradient(340px circle at var(--mx, 50%) var(--my, 50%), black 0%, transparent 100%);
}

.blob-1{
    width: 28vw;
    height: 28vw;
    top: -5%;
    left: -8%;
}

.blob-2{
    width: 22vw;
    height: 22vw;
    bottom: -10%;
    right: -6%;
}

.blob-5{
    width: 14vw;
    height: 14vw;
    top: 15%;
    right: 8%;
}

.blob-6{
    width: 18vw;
    height: 18vw;
    bottom: 5%;
    left: 30%;
}

.blob-7{
    width: 12vw;
    height: 12vw;
    top: 55%;
    right: 25%;
}

.blob-15{
    width: 20vw;
    height: 20vw;
    top: 35%;
    left: -10%;
}

.blob-16{
    width: 16vw;
    height: 16vw;
    top: 0%;
    left: 55%;
}

.blob-17{
    width: 10vw;
    height: 10vw;
    bottom: 20%;
    right: 5%;
}

.about .about-container{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10rem;
}

.about-img-container{
    position: relative;
    width: 30vw;
    height: 60vh;
}

.about-photo{
    position: absolute;
    top: 0;
    left: 0;
    width: 110%;
    height: 70vh;
    border-radius: 50%;
    background: var(--accent-gradient);
    padding-top: 5%;
}

.about-photo-mono{
    filter: grayscale(100%);
}

.about-photo-color{
    -webkit-mask-image: radial-gradient(280px circle at var(--mx, 50%) var(--my, 50%), black 0%, transparent 100%);
    mask-image: radial-gradient(280px circle at var(--mx, 50%) var(--my, 50%), black 0%, transparent 100%);
}

.info-box{
    display: flex;
    flex-direction: column;
    text-align:center;
    align-items: center;
    justify-content: center;
    gap:1.5rem;
}

.info-box h3{
    font-size:1.8rem;
    font-weight: 500;
}
.info-box h1{
    font-size: 4rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}
.info-box span{
    background: var(--accent-gradient);
    background-clip: text;
    color: transparent;
    font-size: 2rem;
}

.btn-group{
    display: flex;
    gap: 1rem;
}
.btn, .btn:visited{
    padding: 0.5rem 1.5rem;
    border-radius: 3rem;
    background-color: var(--background);
    color: inherit;
    cursor: pointer;
    font-weight: 500;
    text-wrap: nowrap;
    transition: 0.2s ease-in-out;
    position:relative;
    display:flex;
    align-items: center;
    justify-content: center;
}
.btn::after{
    content: "";
    position: absolute;
    height:110%;
    width: 103%;
    border-radius: 3rem;
    background-image:var(--accent-gradient);
    z-index:-1;

}
.btn:hover{
    z-index:0;
    color:var(--background)

}
.btn i{
    margin-left: 0.3rem;
}


.socials{
    display:flex;
    gap:2rem;
}
.socials i{
    font-size: 2.5rem; 
    cursor: pointer;
    transition: 0.2s ease-in-out;
}
.socials i:hover{
    transform: scale(1.1) ;
}

.section-title{
    text-align:center;
    font-size:4rem;
    font-weight: 600;
    margin-bottom: 3rem;
}

.tech-stack{
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    color: var(--text-primary);

    width: min(90%, 1000px);

    padding: 1.2rem 1.3rem;

    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.2rem;

    background: var(--primary-light);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 2rem;

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

 .tech-item {
    flex: 1;
    min-width: 0;

    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: auto auto;
    column-gap: 0.5rem;
    align-items: center;
    
}

.tech-item i {
    width: 110%;
    height: auto;
    object-fit: contain;
    grid-row: span 2;
} 

/* .tech-item span {
    font-size: 0.75rem;
    font-weight: 600;
    color: white;
    margin-bottom: 4px;
}

.progress {
    height: 4px;
    width: 100%;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #75B5FF, #6366F1);
    border-radius: 10px;
} */

.tech-expand-wrap{
    position: relative;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tech-tooltip{
    position: absolute;
    bottom: calc(100% + 0.75rem);
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: var(--background);
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    padding: 0.4rem 0.9rem;
    border-radius: 3rem;
    box-shadow: var(--shadow-md);
    animation: tech-tooltip-bounce 1.6s ease-in-out infinite;
    pointer-events: none;
}

.tech-tooltip::after{
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--primary);
}

@keyframes tech-tooltip-bounce{
    0%, 100%{ transform: translateX(-50%) translateY(0); }
    50%{ transform: translateX(-50%) translateY(-6px); }
}

.tech-expand-btn{
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 50%;
    border: none;
    background: var(--primary);
    color: var(--background);
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s ease-in-out;
}

.tech-expand-btn:hover{
    background: var(--background);
    color: var(--primary);
    transform: scale(1.08);
}

.tech-expand-btn i{
    transition: transform 0.3s ease-in-out;
}

.tech-expand-btn.open i{
    transform: rotate(180deg);
}

.tech-expand-panel{
    position: absolute;
    top: 55px;
    left: 50%;
    transform: translateX(-50%);
    width: min(92%, 1100px);
    z-index: 8;
    display: none;
    flex-direction: column;
    gap: 1rem;
    background: var(--primary-light);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 1.5rem;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.tech-expand-panel.open{
    display: flex;
}

.tech-expand-row{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
}

.tech-chip{
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.5);
    color: var(--text-primary);
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    white-space: nowrap;
}

.tech-chip i{
    font-size: 1.1rem;
}

/****************** WHO I AM ****************/

.whoami{
    background: var(--background);
    color: var(--text-primary);
    position: relative;
    overflow: hidden;
}

.whoami-inner{
    max-width: 900px;
    margin: 0 auto 5rem;
    text-align: center;
}

.whoami-text{
    font-size: clamp(1.4rem, 2.6vw, 2.1rem);
    font-weight: 600;
    line-height: 1.55;
}

.whoami-text .word{
    color: var(--border);
}

.whoami-pillars{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto 5rem;
}

.pillar-card{
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 1.5rem;
    padding: 2rem;
    text-align: left;
    transition: transform 0.15s ease-out, box-shadow 0.3s ease, border-color 0.3s ease;
    will-change: transform;
}

.pillar-card:hover{
    box-shadow: var(--shadow-md);
    border-color: var(--primary-light);
}

.pillar-card i{
    font-size: 1.6rem;
    color: var(--primary-light);
    margin-bottom: 1rem;
    display: block;
}

.pillar-card h3{
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.pillar-card span{
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary-light);
    margin-bottom: 0.75rem;
}

.pillar-card p{
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.whoami-stat{
    text-align: center;
}

.stat-number{
    font-size: clamp(3rem, 8vw, 5rem);
    font-weight: 800;
    background: var(--accent-gradient);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

.whoami-stat > span{
    font-size: clamp(3rem, 8vw, 5rem);
    font-weight: 800;
    background: var(--accent-gradient);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

.whoami-stat p{
    color: var(--text-secondary);
    font-weight: 500;
    margin-top: 0.5rem;
}

/****************** EXPERIENCE ****************/

.experience{
    background: var(--primary);
    color: var(--background);
    min-height: auto;
    padding-bottom: 3rem;
}

.experience-info{
    display:flex;
    align-items:center;
    justify-content: center;
    gap: 5rem;
}

/* .experience img{
    width:24vw;
    border-radius: 3rem;
} */
.grid{
    position: relative;
    height: 800px;
    max-width: 1280px;
    margin: 9rem auto -420px;
}

.fan-title{
    position: absolute;
    bottom: 480px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    white-space: nowrap;
    z-index: 1;
}

.fan-title .section-title{
    margin: 0;
}

.fan-hint{
    margin-top: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--primary-light);
    text-align: center;
}

.grid-card-wrap{
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 270px;
    margin-left: -135px;
    z-index: 1;
}

.grid-card-wrap:hover{
    z-index: 6;
}

.grid-card{
    --hover-scale: 1;
    width: 100%;
    height: 330px;
    transform-origin: 50% 100%;
    transform: rotate(var(--angle)) translateY(-690px) scale(var(--hover-scale));
    border: 2px solid var(--primary-light);
    border-radius: 2rem;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    align-items:baseline;
    justify-content: left;
    cursor: pointer;
    transition: 0.15s ease-in-out;
    background: var(--primary);
    overflow: hidden;
}

.grid-card:hover{
    --hover-scale: 1.05;
    background-color:var(--primary-light);
    color: var(--text-primary);
}

.grid-card i {
    font-size: 1.65rem;
    margin-bottom: 1rem;
}

.grid-card span{
    font-size: 1.25rem;
    font-weight: 500;
}

.grid-card h3{
    font-style: italic;
}
.grid-card p, h3 {
    margin-top: 0.5rem;
}

.grid-card .card-text{
    font-size: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more-btn{
    margin-top: 0.75rem;
    background: none;
    border: none;
    padding: 0;
    color: inherit;
    text-decoration: underline;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
}

.card-modal{
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.card-modal.open{
    opacity: 1;
    pointer-events: all;
}

.card-modal-content{
    position: relative;
    background: var(--primary);
    color: var(--background);
    border: 2px solid var(--primary-light);
    border-radius: 2rem;
    padding: 3rem;
    width: min(90vw, 600px);
    max-height: 80vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    align-items: baseline;
}

.card-modal-icon{
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.card-modal-title{
    font-size: 1.4rem;
    font-weight: 500;
}

.card-modal-duration{
    font-style: italic;
    margin-top: 0.5rem;
}

.card-modal-text{
    margin-top: 1rem;
}

.card-modal-close{
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: var(--background);
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
}

::-webkit-scrollbar{
    width: 1vw;
}
::-webkit-scrollbar-track{
    background-color: var(--surface-muted);
}
::-webkit-scrollbar-thumb{
    background: var(--primary-light);
    border-radius: 5rem;
}


.projects{
    overflow-x: hidden;
}

.projects-header{
    overflow: hidden;
}

.carousel{
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.carousel-track{
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 1rem 0.5rem;
    scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar{
    display: none;
}

.carousel-btn{
    flex: 0 0 auto;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    border: 2px solid var(--primary);
    background: var(--background);
    color: var(--primary);
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s ease-in-out;
    z-index: 2;
}

.carousel-btn:hover{
    background: var(--primary);
    color: var(--background);
}

.carousel-dots{
    display: flex;
    justify-content: center;
    gap: 0.6rem;
    margin-top: 1.5rem;
}

.carousel-dot{
    width: 0.6rem;
    height: 0.6rem;
    border-radius: 50%;
    background: var(--border);
    cursor: pointer;
    transition: 0.2s ease-in-out;
}

.carousel-dot.active{
    background: var(--primary);
    width: 1.5rem;
    border-radius: 1rem;
}

.project-card{
    flex: 0 0 min(85vw, 380px);
    scroll-snap-align: center;
    padding: 3rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 1.5rem;
    border: 2px solid var(--primary);
    border-radius: 3rem;
    cursor: pointer;
    transition: 0.3s ease-in-out;
}

.project-card:hover{
    background-color: var(--primary);
    color:var(--surface-muted);
    transform:translateY(-10px)scale(1.02)
}

.project-card:hover .btn{
    background-color: var(--primary);
    color:var(--surface-muted);
}

.project-card img{
    width: 100%;
    border-radius: 1rem;
}

.project-card h3{
    font-size: 2rem;
    font-weight: 500;

}

footer{
    width: 100%;
    padding: 6rem 1.5rem 2.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--primary);
    color: var(--background);
}

.footer-cta{
    text-align: center;
    max-width: 600px;
}

.footer-heading{
    background: linear-gradient(100deg, var(--background) 30%, var(--primary-light) 50%, var(--background) 70%);
    background-size: 250% auto;
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    margin-bottom: 1rem;
    animation: footer-shimmer 5s ease-in-out infinite;
}

@keyframes footer-shimmer{
    0%{ background-position: 200% center; }
    100%{ background-position: -50% center; }
}

.footer-subtitle{
    color: var(--primary-light);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

.input-box{
    display: flex;
    justify-content: center;
}

.input{
    position: relative;
    display: flex;
    align-items: center;
    width: min(90vw, 480px);
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 3rem;
    padding: 0.5rem 0.5rem 0.5rem 1.5rem;
    transition: 0.25s ease-in-out;
}

.input:focus-within{
    border-color: var(--primary-light);
    box-shadow: 0 0 0 4px rgba(125, 179, 255, 0.15);
}

.input i{
    color: var(--primary-light);
    font-size: 1.2rem;
    margin-right: 0.75rem;
}

.input input{
    flex: 1;
    min-width: 0;
    align-self: stretch;
    padding: 0.5rem 0;
    background: none;
    border: none;
    outline: none;
    color: var(--background);
    font-size: 1rem;
}

.input input:-webkit-autofill,
.input input:-webkit-autofill:hover,
.input input:-webkit-autofill:focus,
.input input:-webkit-autofill:active{
    -webkit-text-fill-color: var(--background);
    -webkit-box-shadow: 0 0 0px 1000px rgb(23, 35, 72) inset;
    box-shadow: 0 0 0px 1000px rgb(23, 35, 72) inset;
    transition: background-color 9999s ease-in-out 0s;
    caret-color: var(--background);
}

.input input::placeholder{
    color: rgba(255,255,255,0.4);
}

.footer-submit{
    border: none;
    background: var(--accent-gradient);
    color: var(--background);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.75rem 1.5rem;
    border-radius: 3rem;
    cursor: pointer;
    transition: 0.2s ease-in-out;
    white-space: nowrap;
}

.footer-submit:hover{
    background: var(--accent-gradient-rev);
    transform: scale(1.03);
}

.footer-submit:disabled{
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.form-status{
    min-height: 1.2rem;
    margin-top: 0.75rem;
    font-size: 0.85rem;
    font-weight: 500;
    text-align: center;
}

.form-status.success{
    color: #4ADE80;
}

.form-status.error{
    color: #F87171;
}

.footer-divider{
    width: min(90%, 900px);
    height: 1px;
    background: rgba(255,255,255,0.12);
    margin: 3rem auto 0;
}

.footer-bottom{
    width: min(90%, 900px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
    padding-top: 2rem;
}

.footer-links{
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.footer-links a{
    color: var(--primary-light);
    font-weight: 500;
    font-size: 0.95rem;
    transition: 0.2s ease-in-out;
}

.footer-links a:hover{
    color: var(--background);
}

.footer-socials{
    display: flex;
    gap: 1.2rem;
}

.footer-socials a{
    color: var(--primary-light);
    font-size: 1.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 50%;
    transition: 0.2s ease-in-out;
}

.footer-socials a:hover{
    color: var(--primary);
    background: var(--primary-light);
    transform: translateY(-3px);
}

.copyright{
    font-size: 0.85rem;
    font-weight: 300;
    color: rgba(255,255,255,0.5);
    margin: 0;
}

/* ============================================================
   MOBILE RESPONSIVE
   ============================================================ */
@media (max-width: 768px){

    body{
        overflow-x: hidden;
    }

    section{
        padding: 6rem 6% 4rem;
    }

    .section-title{
        font-size: 2.4rem;
    }

    /* ---- Header / mobile nav ---- */
    header{
        width: 90vw;
        max-width: 360px;
        gap: 0.75rem;
        padding: 0.5rem 1rem;
        justify-content: space-between;
    }

    .logo img{
        height: 40px;
        transform: translateX(0);
    }

    #menu-icon{
        display: block;
        font-size: 1.5rem;
        cursor: pointer;
    }

    .section-links{
        position: fixed;
        top: 5.5rem;
        left: 50%;
        transform: translateX(-50%);
        width: 80vw;
        max-width: 320px;
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
        background: var(--surface);
        padding: 2rem;
        border-radius: 1.5rem;
        box-shadow: var(--shadow-md);
        display: none;
        z-index: 1;
    }

    header.nav-open .section-links{
        display: flex;
    }

    .visit-btn{
        padding: 0.6rem 1.1rem;
        font-size: 0.85rem;
    }

    /* ---- About ---- */
    .about{
        padding-top: 7rem;
    }

    .about .about-container{
        flex-direction: column;
        gap: 2.5rem;
        width: 100%;
    }

    .info-box{
        width: 100%;
    }

    .info-text{
        width: 100%;
    }

    .about-img-container{
        width: 65vw;
        height: 65vw;
        max-width: 300px;
        max-height: 300px;
    }

    .about-photo{
        width: 100%;
        height: 100%;
        padding-top: 0;
    }

    .info-box h3{
        font-size: 1.2rem;
    }

    .info-box h1{
        font-size: 2.4rem;
    }

    .info-box span{
        font-size: 1.1rem;
        max-width: 100%;
        text-wrap: balance;
    }

    .btn-group{
        flex-direction: column;
        width: 100%;
        align-items: stretch;
    }

    .btn-group .btn{
        width: 100%;
    }

    /* ---- Tech stack ---- */
    .tech-stack{
        width: 92vw;
        overflow-x: auto;
        justify-content: flex-start;
        gap: 1.5rem;
        -webkit-overflow-scrolling: touch;
    }

    .tech-item{
        flex: 0 0 auto;
        min-width: 90px;
    }

    /* ---- Who I Am ---- */
    .whoami-inner{
        margin-bottom: 3rem;
    }

    .whoami-pillars{
        grid-template-columns: 1fr;
        margin-bottom: 3rem;
    }

    /* ---- Experience: fan becomes a stacked list ---- */
    .experience-info{
        gap: 2rem;
    }

    .grid{
        position: static;
        height: auto;
        max-width: 100%;
        margin: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 1.75rem;
    }

    .fan-title{
        position: static;
        transform: none;
        order: -1;
        margin-bottom: 0.5rem;
    }

    .grid-card-wrap{
        position: static;
        width: 100%;
        max-width: 340px;
        margin: 0;
    }

    .grid-card{
        transform: none;
        height: auto;
        min-height: 280px;
    }

    /* ---- Recent Projects ---- */
    .carousel-btn{
        display: none;
    }

    .carousel{
        gap: 0;
    }

    .project-card{
        flex-basis: 85vw;
        padding: 2rem 1.5rem;
    }

    .project-card h3{
        font-size: 1.5rem;
    }

    /* ---- Read-more modal ---- */
    .card-modal-content{
        padding: 2rem;
    }

    /* ---- Footer ---- */
    footer{
        padding: 4rem 1.2rem 2rem;
    }

    .input{
        padding: 0.4rem 0.4rem 0.4rem 1rem;
    }

    .input input{
        font-size: 0.9rem;
    }

    .footer-submit{
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }

    .footer-bottom{
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
}

@media (max-width: 420px){
    .info-box h1{
        font-size: 2rem;
    }

    .section-title{
        font-size: 2rem;
    }
}