:root {
    --pads: clamp(24px, 5vw, 64px);
    --innerpads: clamp(12px, 5vw, 32px);
    --max-width: 1200px;
}

html, body {
    background-color: #000;
}

h1 /* titles */ {
    font-family: 'Neug Asia', 'sk-modernist', system-ui, -apple-system, sans-serif;
    font-weight: normal;
    font-size: clamp(3.5rem, 12vw, 6rem);
}

h2 /* subtitles */ {
    font-family: 'sk-modernist', system-ui, -apple-system, sans-serif;
    font-size: clamp(1.3rem, 2vw, 2rem);
    display: inline-block;
    /* line-height: clamp(1.2rem, 6vw, 3rem); */
    overflow-y: hidden;
}

h3 /* descriptions */ {
    font-family: 'sk-modernist', system-ui, -apple-system, sans-serif;
    color: #084999;
    font-size: clamp(1rem, 1.2vw, 1.3rem);
}

/* navbar ---------------------------------------------------------------- */

/* navbar stuff------------------------------- */
.navbar-links {
    color: #6ac8ff;
}

.navbar-links:hover {
    color: #0d0433;
}

/* Change navbar hover color to white when past projects section */
body.past-projects .navbar-links:hover {
    color: #fff;
}

/* landing --------------------------------------------------------------- */

.landing {
    position: relative;
    width: 100%;
    min-height: 100vh;

    background-image: url('../../assets/images/global/index-backdrop.webp');
    background-size: max(700px, 100%) auto;
    background-position: top center;
    background-repeat: no-repeat;

    overflow: hidden;

    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;

    min-height: 100vh;   /* fallback */
    min-height: 100svh;
    min-height: 100dvh;
}

/* Swap backdrop on smaller screens */
@media screen and (min-height: 1000px),
       screen and (max-width: 800px) {
    .landing {
        background-image: url('../../assets/images/global/index-small.webp');
    }
}

@media screen and (max-width: 400px) {
    .landing {
        padding: 0 clamp(24px, 5vw, 64px);
    }
}


.landing-container {
    position: relative;
    z-index: 1;
    color: white;
    padding: 0 clamp(24px, 5vw, 64px);       /* prevents edge touching on small screens */
    max-width: 1200px;
}

.landing-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    margin: 0 auto;
    padding-top: 24vh;
}

.landing-text{
    text-align: center;
    display: flex;
    flex-direction: column;
    margin: 0 auto;         /*THIS centers it horizontally */
    padding-top: 1rem;
    gap: 1rem;
    justify-content: center;
    overflow: hidden;
}

.landing-text h2 {
    color: #001B80;
    padding-bottom: var(--innerpads)
}

/* top padding swap for smaller screens */
@media screen and (min-height: 1000px),
       screen and (max-width: 800px) {
    .landing-content {
        padding-top: 0;
    }
        .landing-title {
        padding-top: 20dvh;
    }
}

.landing-title h1 {
    background: linear-gradient(190deg,#000, #532cbf);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* typing + text animation!!-------------------------------------------- */

#typing-text::after {
    content: "|";
    margin-left: 4px;
    animation: blink 1s infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

.landing-text h2,
.landing-text h3 {
    opacity: 0;
    transform: translateY(20px);
    will-change: transform, opacity;
}

/* h2 appears first */
.landing-text h2 {
    animation: fadeUp 0.7s ease-out forwards;
    animation-delay: 1.2s;
}

/* h3 appears slightly later */
.landing-text h3 {
    animation: fadeUp 0.7s ease-out forwards;
    animation-delay: 1.5s;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* projects -------------------------------------------------------------------- */

.project-link {
    text-decoration: none;
    color: inherit;
    display: block; /* important for full-card click */
}

.projects {
    padding-top: clamp(50vh, 45vw, 160vh);
    height: fit-content;
    margin: 100px 0;
    /* padding-left: var(--pads);
    padding-right: var(--pads); */
    display: column;
    align-items: center;
}

.projects h1 {
    background: linear-gradient(190deg,#F2FFFC, #C7FBFF);
    font-size: clamp(2.5rem, 4vw, 5rem);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
    padding-bottom: clamp(3rem, 4vw, 5rem)
}

.project-container .project-content {
    border-radius: 1rem;
    padding: var(--innerpads);
    height: fit-content;
    background: var(--box-bg);
}

/* project cards ------------------------------------------------------- */

.project-content {
    display: flex;
    align-items: center;
    gap: 3rem;
    width: 100%;
    max-width: 1200px; /* 👈 card width anchor */
    margin: 0 auto 2rem;
}

.project-media {
    flex: 0 0 clamp(260px, 35%, 420px);
    display: flex;
    align-items: center;
}

.project-pic {
    width: 100%;
    height: auto;
    align-items: center;
    object-fit: contain; /* 👈 no cropping */
    transform: scale(0.85);
    transition: transform 0.3s ease;
}

/* project text ------------------------------------ */

.project-title {
    color: rgba(4, 0, 45, 0.6);
    padding-bottom: 0.5rem;
    transition: transform 0.3s ease;
    text-transform: uppercase;
}

.project-description {
    color: var(--box-text);
    padding-bottom: 2rem;
}

.project-tags {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.project-tag {
    background-color: var(--box-text);
    padding: 0.5rem 0.5rem;
    border-radius: 1rem;
    white-space: nowrap;
}

/* text and box custom colours --------------------- */
.box-pink {
  --box-bg: #FFF0F0;
  --box-text: #BE3A4C;
}

.box-blue {
  --box-bg: #F0F9FF;
  --box-text: #3854B1;
}

.box-green {
  --box-bg: #F7FFF0;
  --box-text: #368B32;
}

.box-orange {
  --box-bg: #FFF6E7;
  --box-text: #A7773D;
}

@media screen and (max-width: 750px) {

    .project-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
        height: fit-content;
    }

    .project-tags {
        justify-content: center;
    }

}

/* end message ----------------------------------- */

.end-message {
    padding-top: 4rem;
}

.end-message h2 {
    color: #fff;
    
}
    

/* project transitions and stuff ------------------------------------- */
.projects h1 {
    opacity: 0;
    transform: translateY(1rem);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.projects h1.show {
    opacity: 1;
    transform: translateY(0);
}

.project-content {
    opacity: 0;
    transform: translateY(2rem);
    transition: opacity 1s ease, transform 1s ease;
}

.project-content.show {
    opacity: 1;
    transform: translateY(0);
}

.project-pic {
    transform: scale(0.85);
    transition: transform 0.5s ease;
}




/* extras -------------------------------------- */

.inline-link {
    color: #C1E9FF;
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-thickness: 2px;
    transition: color 0.2s ease;
  }
  
  .inline-link:hover {
    color: var(--box-mid);
  }

.extra {
    line-height: 3rem;
    padding-bottom: 4rem;
}
/* footer --------------------------------------------- */

.divider {
    width: 100%;
    height: 2px;
    background-color: #fff;
    opacity: 0.6;
    margin: 4rem 0;
  }
  
.footer {
    padding-top: 4rem;
    padding-bottom: clamp(6rem, 4vw, 10rem);
}

.footer h1 {
    font-size: clamp(2rem, 4vw, 5rem);
}

.footer h2 {
    padding-top: 1rem;
}

.foot-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin-top: 3rem;
    align-items: start;
}

.foot-item {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.foot-item p {
    margin-top: 0;
    padding-top: 0;
    font-weight: 600;
    opacity: 0.9;
    font-size: clamp(1.2rem, 1vw, 1.5rem);
}

.foot-links {
    text-decoration: none;
    transition: color 0.2s ease;
    color: #C1E9FF;
    font-size: clamp(1rem, 1vw, 1.2rem);
}

.foot-link {
    display: flex;
    flex-direction: row;
    gap: clamp(1rem, 2vw, 2rem);

}
  
.foot-links:hover {
    color: #fff;
    font-weight: bold;
}

@media screen and (max-width: 750px) {
    .foot-container {
        display: flex;
        flex-direction: column;
    }
}
  
  