/* Variables */
:root {
    --libre: 'Libre Baskerville', 'Times New Roman', Times, serif;
    --white: #FFFFFF;
    --background: #F8F8F8;
    --background-transparent:hsl(0, 0%, 97%, 0.8);
    --border-stroke: #E0E0E0;
    --border-stroke-dark: #8F8F8F;
    --surface: #E8E8E8;
    --surface-dark: #D3D3D3;
    --text: #1C1C1C;
    --text-sub: #606060;
    --blue: #004EB0;
    --lightblue: #93D9FF;
    --yellow: #FFD563;
    --green: #C7FF96;
    --pink: #FFA4D0;
    --purple: #CBAAF9;
    --glide-spring: linear(0, 0.022 2.2%, 0.091 4.9%, 0.508 15.8%, 0.693 21.7%, 0.825 27.7%, 0.874 30.9%, 0.916 34.4%, 0.97 42.1%, 0.996 52%, 1.003 63.7%, 1);
}

@keyframes navbar-scroll {
    from {
        width: 856px;
        padding: 8px 0px;
    }
    to {
        width: 720px;
        padding: 8px 16px;
    }
}

@keyframes enter {
    from {
        transform: translateY(16px);
        opacity: 0.5;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Reset */
*, *::before, *::after {
    box-sizing: border-box;
}

* {
    margin: 0;
}

body {
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    font-family: 'Public Sans', Arial, Helvetica, sans-serif;
}

input, button, textarea, select {
    font: inherit;
}

p, h1, h2, h3, h4, h5, h6 {
    overflow-wrap: break-word;
}
/* End Reset */

body {
    background-color: var(--background);
    color: var(--text);
}

main {
    margin: auto;
    max-width: 856px;
    display: flex;
    flex-direction: column;
    gap: 128px;
    align-items: center;
}

nav {
    z-index: 1;
    position: fixed;
    margin-top: 32px;
    left: 50%;
    width: 856px;
    background-color: var(--background-transparent);
    backdrop-filter: blur(4px);
    border-radius: 8px;
    padding: 8px 0px;
    transform: translate(-50%, 0%);
    animation: navbar-scroll linear forwards;
    animation-timeline: scroll();
    animation-range: 0vh 50vh;
}

nav ul {
    list-style-type: none;
    clear: both;
    padding: 0;
}

.nav-button {
    float: right;
    padding: 6px 12px;
    border-radius: 8px;
    text-decoration: none;
    transition: 100ms ease-out;
}

.nav-button.current {
    background-color: var(--white);
    box-shadow: 0px 1px 4px hsl(0, 0%, 0%, 0.25);
}

.nav-button:hover {
    background-color: var(--white);
    cursor: pointer;
    transform: translateY(-1px);
    transition: 300ms ease-out;
    box-shadow: 0px 2px 6px hsl(0, 0%, 0%, 0.25);
}

.nav-button:active {
    background-color: var(--white);
    box-shadow: inset 0px 1px 4px hsl(0, 0%, 0%, 0.25);
    transform: translateY(2px);
    transition: 100ms ease-out;
}

a, a:hover, a:active, a:visited {
    color: var(--text);
    text-decoration: none;
}

.intro {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 24px;
    height: 40vh;
    margin-top: 180px;
    color: var(--blue);
}

h1 {
    font-family: var(--libre);
    font-weight: 400;
    font-size: 24px;
    line-height: 1.5;
    letter-spacing: -3%;
    text-wrap: balance;
}

.intro {
    width: 100%;
}

.intro-subtitle {
    font-weight: 400;
    font-size: 20px;
}

.intro a:link, .intro a:visited, .intro a:active {
    font-family: var(--libre);
    font-style: italic;
    color: var(--blue);
    text-decoration: underline;
    transition: 100ms ease-in;
}

.intro a:hover {
    font-weight: 600;
    transition: 100ms ease-out;
}

h2 {
    font-weight: 700;
    font-size: 20px;
}

.work {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 128px;
    width: 888px;
}

.work h2 {
    margin-left: 16px;
}

#radio-filter-set {
    border: none;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
}

legend {
    display: none;
}

input[type="radio"] {
    opacity: 0;
    position: absolute;
}

.radio-label {
    display: flex;
    align-items: center;
    height: 24px;
    padding: 0 12px;
    background-color: var(--surface);
    border: 1px solid transparent;
    border-radius: 32px;
    font-size: 14px;
    cursor: pointer;
    transition: 50ms ease-in;
}
.radio-label:hover {
    background-color: var(--surface-dark);
    transition: 50ms ease-out;
}
.radio-label:active {
    transform: scale(0.96);
    transition: 50ms ease-out;
}
.radio-label:has(input[type=radio]:checked) {
    background-color: var(--blue);
    color: var(--white);
}
.radio-label:has(input[type=radio]:focus-visible) {
    border: 2px solid var(--text);
}

.project-list {
    display: flex;
    flex-direction: column;
}

.project-card {
    display: flex;
    flex-direction: row;
    gap: 32px;
    position: relative;
    padding: 16px;
}

.project-card:hover .card-back {
    width: 100%;
    height: 100%;
    opacity: 1;
}

.project-card:hover .thumbnail {
    box-shadow: 0 4px 8px hsl(0, 0%, 0%, 0.25); 
    transition: 200ms ease-in-out;   
}

.thumbnail {
    display: flex;
    overflow: hidden;
    border-radius: 12px;
    height: 137px;
    width: 296px;
    align-items: center;
    box-shadow: 0 1px 4px hsl(0, 0%, 0%, 0.25);
    position: relative;
}

.thumbnail a {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.thumbnail img {
    width: 100%;
    object-fit: cover;
    display: block;
}

.thumbnail::after {
    content: "";
    box-shadow: inset 0 0 0 4px #FFFFFF;
    height: 100%;
    width: 100%;
    position: absolute;
    display: block;
    border-radius: 12px;
}

.card-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 16px;
}

.card-name {
    font-size: 18px;
    font-weight: 500;
    max-width: 400px;
}

.card-subtitle {
    font-size: 14px;
    color: var(--text-sub);
}

.card-back {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: calc(100% - 32px);
    height: calc(100% - 32px);
    padding: 0px;
    border-radius: 20px;
    opacity: 0;
}

.project-card .arrow {
    position: absolute;
    right: 32px;
    top: 32px;
    opacity: 0;
    transform: translateX(8px);
}

.project-card:hover .arrow {
    opacity: 1;
    transform: translateX(0);
}

@media (prefers-reduced-motion: no-preference) {
    .project-card:hover .card-back {
        transition: 200ms ease-in-out;
    }

    .card-back {
        transition: 100ms ease-in;
    }

    .project-card .arrow {
        transition: 100ms ease-in;
    }

    .project-card:hover .arrow {
        transition: 200ms ease-out;
    }
}

.intro-about {
    margin-top: 164px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    color: var(--text);
    align-items: start;
}

.about-img-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 8px;
    width: 100%;
    height: auto;
}

.about-img-grid img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.about-text-container {
    width: 100%; 
    display: flex; 
    flex-direction: column; 
    gap: 24px; 
    justify-content: center;
    font-weight: 300;
}

.about-text-container h1 {
    color: var(--blue);
}

.about-text-container ul {
    padding-left: 0;
    line-height: 1.25;
}

.about-text-container li {
    list-style: none;
}

.about-text-container li::before {
    content: "•";
    font-size: 1em;
    margin-right: 0.5em;
}

.link {
    width: fit-content;
    padding: 6px 8px 6px 12px;
    border-radius: 8px;
    text-decoration: none;
    transition: 100ms ease-out;
    background-color: var(--white);
    box-shadow: 0px 1px 4px hsl(0, 0%, 0%, 0.25);
    display: flex;
    align-items: center;
    gap: 4px;
}

.link:hover {
    background-color: var(--white);
    cursor: pointer;
    transform: translateY(-1px);
    transition: 300ms ease-out;
    box-shadow: 0px 2px 6px hsl(0, 0%, 0%, 0.25);
}

.link:active {
    background-color: var(--white);
    box-shadow: inset 0px 1px 4px hsl(0, 0%, 0%, 0.25);
    transform: translateY(2px);
    transition: 100ms ease-out;
}

.about-links-section {
    position: relative;
    width: 100%;
    height: 400px;
}

.about-links-section-mobile {
    display: none;
}

.about-card {
    position: absolute;
    height: auto;
    padding: 4px 4px 12px 4px;
    border-radius: 12px;
    background-color: var(--white);
    box-shadow: 0px 2px 6px hsl(0, 0%, 0%, 0.25);
    display: flex;
    flex-direction: column;
    gap: 16px;
    transform: var(--default-transform, none) !important;
    transition: 250ms ease-in-out;
}

.vertical {
    width: 196px;
}

.horizontal {
    width: 248px;
}

@media (prefers-reduced-motion: no-preference) {
    .about-card:hover {
        transform: var(--default-transform, none) scale(1.04) translateY(-12px) !important;
        transition: 800ms var(--glide-spring);
    }
}


.about-card:hover .bird-name {
    bottom: 4px;
    opacity: 1;
    transition: 250ms ease-out;
}

.about-links-section a:focus-visible .about-card {
    outline: 2px solid black;
}

.about-card-img-container {
    border-radius: 10px 10px 0 0;
    overflow: hidden;
    height: fit-content;
    position: relative;
}

.about-card-img-container img {
    width: 100%;
    height: auto;
}

.bird-name {
    position: absolute;
    bottom: -4px;
    width: 100%;
    padding: 20px 12px 12px 12px;
    font-weight: 600;
    font-size: 14px;
    color: var(--white);
    opacity: 0;
    text-shadow: 1px 1px 2px rgb(0, 0, 0, 0.25);
    transition: 250ms ease-in;
}

@media (prefers-reduced-motion: reduce) {
    .bird-name, .about-card:hover .bird-name {
        transition: none;
    }
}

.about-card-text-row {
    display: flex;
    justify-content: space-between;
    padding: 0 12px;
    font-family: var(--libre);
    font-size: 16px;
    font-weight: 500;
}

.about-table {
    width: 100%;
}

.about-row {
    display: grid;
    grid-template-columns: 2fr 2fr 1fr;
    gap: 24px;
    padding: 12px 0;
    font-weight: 300;
    border-top: 1px solid var(--border-stroke);
}

.about-cell {
    display: flex;
    align-items: center;
}

.about-row .about-cell:nth-child(3) {
    justify-content: end;
    text-align: right;
}

.pwd-form {
    margin-top: 212px;
    width: 368px;
    display: flex;
    flex-direction: column;
}

input[type="password"] {
    height: 48px;
    padding: 0px 16px;
    border-radius: 4px;
    border: 1px solid var(--border-stroke-dark);
}

#error {
    margin-top: 8px;
    color: #FF0000;
}

#loginbutton {
    margin-top: 24px;
    height: 36px;
    padding: 0px 12px;
    width: fit-content;
    background-color: var(--white);
    border-radius: 8px;
    border: 1px solid var(--border-stroke-dark) ;
    box-shadow: 0px 1px rgb(0, 0, 0, 0.25);
}

#loginbutton:hover {
    cursor: pointer;
    background-color: var(--background);
}

#loginbutton:active {
    border: 1px solid transparent;
    box-shadow: inset 0px 1px 4px rgb(0, 0, 0, 0.25);
}

footer {
    text-align: center;
    font-size: 12px;
    padding: 16px 0;
    color: var(--text-sub);
}

.intro-project {
    margin-top: 212px;
    display: flex;
    flex-direction: column;
    gap: 32px;
    color: var(--text);
}

.details-project {
    padding: 16px 16px 32px 16px;
    border: 1px solid var(--border-stroke);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.details-table {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 0 16px;
}

.details-row {
    display: grid;
    grid-template-columns: 136px 1fr;
}

.details-cell-label {
    font-weight: 500;
    color: var(--text-sub);
}

.cover-project {
    overflow: hidden;
    border-radius: 12px;
}

.cover-project img {
    display: block;
    width: 100%;
    object-fit: cover;
}

.body-project {
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin-bottom: 128px;
}

.section {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin: 24px 0;
}

h3 {
    font-size: 20px;
    font-weight: 400;
}

.body-text {
    font-weight: 300;
    line-height: 1.8;
}

.body-text a, .details-row a {
    text-decoration: underline;
    font-weight: 500;
    transition: 100ms ease-in;
}

.body-text a:hover, .details-row a:hover {
    font-weight: 700;
    transition: 100ms ease-out;
}

.single-image {
    text-align: center;
    padding: 16px 0;
}

.multiple-images {
    display: flex;
    gap: 16px;
    padding-top: 16px;
}

.single-image img, .multiple-images img {
    width: 100%;
    object-fit: cover;
    max-width: 700px;
}

.video-container video {
    width: 100%;
    clip-path: inset(2px 2px round 8px);
    overflow: hidden;
}

.caption {
    padding-top: 8px;
    font-size: 14px;
    font-weight: 400;
    width: 100%;
    text-align: center;
}

.multi-container {
    display: flex;
    flex-direction: column;
    padding-bottom: 16px;
}

.bit-title-row {
    display: flex;
    flex-direction: row;
    width: 100%;
    justify-content: space-between;
    align-items: center;
}

.banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 16px 0px;
    padding: 16px 24px;
    font-family: var(--libre);
    font-size: 14px;
    line-height: 1.8;
    background-color: var(--white);
    border: 1px solid var(--border-stroke);
    border-radius: 8px;
    transition: 250ms ease-in-out;
}

a .banner:hover {
    padding: 16px 32px;
    background-color: var(--blue);
    border: 1px solid transparent;
    color: var(--white);
}

hr {
    border: 1px solid var(--border-stroke);
}

.interaction-container {
    width: 100%;
    background-color: var(--white);
    border: 1px solid var(--border-stroke);
    border-radius: 8px;
    padding: 64px 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sound-effect-btn-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    width: 80px;
}

.sound-effect-btn {
    width: 56px;
    height: 56px;
    border: 1px solid var(--white);
    border-radius: 12px;
    background: linear-gradient(to bottom, #F8F8F8, #EDEDED);
    color: var(--text-sub);
    box-shadow: 0 1px 1px 0 hsl(0, 0%, 33%, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 100ms ease-out;
}

.sound-effect-btn:hover {
    transform: scale(1.04);
    transition: transform 150ms var(--glide-spring);
    cursor: pointer;
}

.sound-effect-btn:active {
    box-shadow: inset 0 2px 3px 0 hsl(0, 0%, 0%, 0.2);
    transform: scale(1);
    transition: transform 150ms var(--glide-spring);
}

/* Responsive */
@media (max-width: 856px) {
    main {
        margin: auto 16px;
    }

    nav {
        width: 100%;
        padding: 16px 16px;
        animation: none;
        margin-top: 0;
        border-radius: 0;
    }

    .work {
        width: 100%;
    }

    .work h2 {
        margin-left: 0;
    }

    #radio-filter-set {
        flex-wrap: wrap;
        padding: 0;
    }

    .project-list {
        gap: 16px;
    }

    .project-card {
        width: 100%;
        flex-direction: column;
        gap: 16px;
        border-radius: 20px;
        padding: 16px 0;
    }

    .project-card:hover .arrow {
        display: none;
    }

    .project-card:hover .card-back {
        opacity: 0;
    }

    .card-text {
        margin: 0;
    }

    .thumbnail {
        width: 100%;
        height: 160px;
    }

    .project-card:hover .thumbnail {
        box-shadow: 0 1px 4px hsl(0, 0%, 0%, 0.25);
    }

    .thumbnail img {
        object-fit: cover;
        height: 100%;
    }

    .intro-about {
        margin-top: 128px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .about-text-container {
        width: 100%;
    }

    .about-links-section {
        display: none;
    }

    .about-links-section-mobile {
        display: block;
        width: 100vw;
        height: fit-content;
        overflow-x: scroll;
        
    }

    .about-links-mobile-inner {
        display: flex;
        flex-direction: row;
        gap: 16px;
        align-items: center;
        width: fit-content;
        padding: 16px;
    }

    .about-links-section-mobile .about-card {
        position: relative;
    }

    .about-links-section-mobile::-webkit-scrollbar {
        display: none;
    }

    .bird-name {
        bottom: 4px;
        opacity: 1;
    }

    .about-row {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .about-cell {
        align-items: start;
    }

    .multiple-images {
        flex-wrap: wrap;
        text-align: center;
    }

    .pwd-form {
        width: 90vw;
    }

    .details-row {
        display: grid;
        grid-template-columns: 112px 1fr;
    }
}