#hero-image{
    width: 124px;
    height: 124px;
    border-radius: 24px;
   
}

#hero, #about, #footer-text{
    max-width: 600px;
}
.projects {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 2 equal columns */
    grid-template-rows: repeat(2, auto);   /* 2 rows (height adjusts to content) */
    row-gap: 40px;
    column-gap: 24px;
}


.project{
    width: 100%;
    padding: 8px 8px 24px 8px;
    border-radius: 16px;
    background-color: #FAFAFA;
    border: 1px solid var(--outline);
}

.project-logo{
    width: 44px;
    height: 44px;
    border-radius: 8px;
}

.project-image-container{
    width: 100%;
    overflow: hidden;
    border-radius: 16px;
    position: relative;
}

.project-image{
    transition: transform 0.5s ease-out;
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
}
.project:hover{
    box-shadow: 0 10px 25px rgba(211, 211, 211, 0.3);
}
.project-description{
    padding: 0 24px 0px 8px;
}

.project:hover .project-image{
    transform: scale(1.1);
    background-color: white;
}
#photo-stack{
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
}
.white-text{
    color: #ffffff;
}
#about-me-image-1,
#about-me-image-2{
    max-width: 280px;
    border-radius: 16px;
    position: absolute;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    transition: transform 1.5s ease, box-shadow 0.3s ease;
    cursor: pointer;
}
/* Initial state: overlapping with no rotation */
#about-me-image-1{
    transform: rotate(0deg) translate(0, 0);
    z-index: 1;
}
#about-me-image-2{
    transform: rotate(0deg) translate(0, 0);
    z-index: 2;
}
/* Animated state: final positions and rotations */
#photo-stack.animated #about-me-image-1{
    transform: rotate(-6deg) translate(-80px, 0);
}
#photo-stack.animated #about-me-image-2{
    transform: rotate(10deg) translate(80px, 0);
}
/* Hover animation - rotate to 0deg and scale up */
#about-me-image-1.animated {
    transform: scale(1.08) rotate(0deg) translate(0, 0);
    z-index: 10;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}
#about-me-image-2.animated {
    transform: scale(1.08) rotate(0deg) translate(0, 0);
    z-index: 11;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}
/* Override when photo stack is animated and image is hovered */
#photo-stack.animated #about-me-image-1.animated {
    transform: scale(1.08) rotate(0deg) translate(0, 0);
    z-index: 10;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}
#photo-stack.animated #about-me-image-2.animated {
    transform: scale(1.08) rotate(0deg) translate(0, 0);
    z-index: 11;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}
#hero{
    padding-top: 80px;
}

.container-m{
    max-width: 600px;
    margin: 0 auto;

}
.container-l{
    width: 900px;
    margin: 0 auto;
}
.container-xl{
    width: 1240px;
    margin: 0 auto;
}
.image-container{
    padding: 40px;
    border-radius: 16px;
    background-color: #F9F9F9;
}
ul,ol{
    padding-left: 16px;
}
.rev-option-image{
    width: 280px;
    border-radius: 16px;
}

.complexity-container{
    display: flex;
    flex-direction: row;
    column-gap: 4px;
}
.circle{
    width: 16px;
    height: 16px;
    border-radius: 16px;
    background-color: white;
    border: 1px solid #E4E4E7;
}
.complexity-container.easy :nth-child(-n+2){
    background-color: var(--success)
}
.complexity-container.medium :nth-child(-n+3){
    background-color: var(--secondary)
}
.complexity-container.high :nth-child(-n+5){
    background-color: var(--danger)
}
.success-dark{
    color: var(--success-dark);
}
.secondary-dark{
    color: var(--secondary-dark);
}
.danger-dark{
    color: var(--danger-dark);
}
.case-study-footer{
    background-color: #000000;
    padding: 80px 0;
    margin-top: 164px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.case-study-footer.visible{
    opacity: 1;
    transform: translateY(0);
}
.case-study-footer-image{
    width: 300px;
    transition: transform 0.1s ease-out;
}

.case-study-footer:hover .case-study-footer-image.visible{
    transform: translateY(0) rotate(3deg);
}

/* Initially hidden elements */
.initially-hidden{
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.initially-hidden.visible{
    opacity: 1;
    transform: translateY(0);
}

/* Slide up blur animation on scroll */
.slide-up-blur{
    opacity: 0;
    transform: translateY(40px);
    filter: blur(10px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out, filter 0.8s ease-out;
}

.slide-up-blur.visible{
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
}

/* Slide up animation on scroll (without blur) */
.slide-up{
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.slide-up.visible{
    opacity: 1;
    transform: translateY(0);
}

/* Arrow icon animation */
.arrow-icon, .arrow-left{
    transition: transform 0.3s ease-out;
}

.case-study-footer:hover .arrow-icon{
    transform: translateX(8px);
}

/* Next project label hover effect */
.next-project-label{
    transition: color 0.3s ease-out;
}

.case-study-footer:hover .next-project-label{
    color: var(--secondary-text);
}

/* Next project title hover effect */
#next-project-title{
    transition: color 0.3s ease-out;
}

.case-study-footer:hover #next-project-title{
    color: #ffffff;
}

.case-study-footer:hover .arrow-icon{
    transform: translateX(8px);
}
.case-study-header:hover .arrow-left{
    transform: translateX(-4px);
}
.primary-button{
    background-color: #000000;
    color: white;
    display: flex;
    flex-direction: row;
    column-gap: 8px;
    align-items: center;
    padding: 16px 32px;
    border-radius: 48px;
    width: fit-content;
    border: none;
    cursor: pointer;
}
.primary-button:hover:not(:disabled){
    background-color: #353535;
}

.primary-button:disabled {
    background-color: #666666;
    cursor: not-allowed;
    opacity: 0.7;
}
#fig-marathon-logo{
    width: 24px;
    height: 24px;
    border-radius: 4px;
}
#figma-link{
    display: inline-flex;
    align-items: baseline;
    column-gap: 8px;
    vertical-align: baseline;
    width: fit-content;
    background-color: #F9F9F9;
    border-radius: 4px;
    border: 1px solid var(--outline);
    padding: 4px 8px;
    align-items: center;
}

#figma-link:hover{
    background-color: var(--surface-2);
}

@keyframes arrowBounceUp {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(4px);
    }
    100% {
        transform: translateY(0);
    }
}
@keyframes arrowBounceLeft {
    0% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(-4px);
    }
    100% {
        transform: translateX(0);
    }
}

.primary-button img{
    transition: transform 0.3s ease-out;
}
.primary-button:hover img{
    animation: arrowBounceUp 0.6s ease-in-out infinite;
}
.secondary-button{
    display: flex;
    flex-direction: row;
    column-gap: 8px;
    align-items: center;
    padding: 16px 32px;
    border-radius: 48px;
    width: fit-content;
    border: 1px solid var(--outline)
}
.secondary-button:hover{
    background-color: #F9F9F9;
}
.secondary-button img{
    transition: transform 0.3s ease-out;
}
.secondary-button:hover img{
    animation: arrowBounceUp 0.6s ease-in-out infinite;
}
.secondary-button.back:hover img{
    animation: arrowBounceLeft 0.6s ease-in-out infinite;
}
.underlined-link{
    color: black;
    text-decoration: underline;
    font-weight: 500;
}

/* Password Protection Styles */
.password-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--surface);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 24px;
}

.password-form {
    max-width: 400px;
    width: 100%;
    padding: 40px;
    background-color: var(--surface-1);
    border-radius: var(--border-radius-m);
    border: 1px solid var(--outline);
}

.password-form .primary-button {
    width: 100%;
    justify-content: center;
}

.password-input {
    width: 100%;
    padding: 16px 24px;
    border: 1px solid var(--outline);
    border-radius: var(--border-radius-m);
    font-family: "Geist", sans-serif;
    font-size: 18px;
    line-height: 26px;
    color: var(--primary-text);
    background-color: var(--surface);
    transition: border-color 0.3s ease, background-color 0.3s ease;
}

.password-input:focus {
    outline: none;
    border-color: var(--primary);
    background-color: var(--surface);
}

.password-input:disabled {
    background-color: var(--surface-2);
    color: var(--secondary-text);
    cursor: not-allowed;
    opacity: 0.6;
}

.password-input::placeholder {
    color: var(--secondary-text);
}

.error-message {
    color: var(--danger);
    font-size: 16px;
    line-height: 24px;
    margin-top: -8px;
}
.passw-label{
    position: absolute;
    top: 16px;
    left: 16px;
    background-color: rgba(255, 255, 255, 0.8);
    padding: 4px 12px;
}
body{
    position: relative;
}

.case-study > .container-xl,
.case-study > #main-content {
    position: relative;
    z-index: 1; /* Ensure content is above bg-lines */
}
.bg-lines{
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    position: absolute;
    z-index: 0;
    flex-wrap: nowrap;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    pointer-events: none; /* Allow clicks to pass through */
}
.bg-line{
    height: 100%;
    background-color: #f7f7f7;
    width: 1px;
}
.bg-line-horizontal{
    width: 100%;
    background-color: #f7f7f7;
    height: 1px;
}

@media (max-width: 500px) {
    .container-m,
    .container-l,
    .container-xl{
        max-width: 100%;
        width: 100%;
        margin: 0 auto;
    }
  
   
    .projects{
        grid-template-columns: repeat(1, 1fr)
    }
    .project-logo{
        width: 40px;
        height: 40px;
        border-radius: 4px;
    }
    
    #about-me-image-1,
    #about-me-image-2{
        max-width: 164px;
    }
    #photo-stack{
        height: 300px;
        align-items: flex-end;
    }
    .image-container{
        padding: 32px 16px;
    }
    .case-study-header{
        padding: 24px 0;
    }
    .case-study-footer{
        padding: 40px 16px;
        margin-top: 64px;
    }
    .case-study-footer-image{
        width: 240px;
    }
    
    .password-form {
        padding: 32px 24px;
    }

}