/* FONTS */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@700&family=Spline+Sans+Mono:wght@300;400;500;600;700&display=swap');

/* VARIABLES */
:root {
    --black: #000000;
    --cream: #f9f8ed;
    --font-display: 'Space Grotesk', sans-serif;
    --font-body: 'Spline Sans Mono', monospace;
}

/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--cream);
    color: var(--black);
    overflow-x: hidden;
}

body.index-page {
    overflow: hidden;
    height: 100vh;
}

a {
    text-decoration: none;
    color: inherit;
}

/* NAVIGATION */
#nav-menu {
    position: fixed;
    top: 40px;
    right: 40px;
    display: flex;
    gap: 40px;
    font-family: var(--font-body);
    font-size: 16px;
    letter-spacing: 1px;
    z-index: 1000;
    transition: opacity 0.3s ease;
}

#nav-menu.hidden {
    opacity: 0;
    pointer-events: none;
}

#nav-menu a {
    transition: opacity 0.3s ease;
}

#nav-menu a:hover {
    opacity: 0.6;
}

/* HEADER */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 30px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background-color: var(--black);
}

.logo {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: normal;
    letter-spacing: 2px;
    color: var(--cream);
    white-space: nowrap;
}

header nav {
    display: flex;
    gap: 40px;
    font-family: var(--font-body);
    font-size: 16px;
    letter-spacing: 1px;
    color: var(--cream);
}

header nav a {
    transition: opacity 0.3s ease;
}

header nav a:hover,
header nav a.active {
    opacity: 0.6;
}

/* DARK THEME */
.dark-theme {
    background-color: var(--black);
    color: var(--cream);
}

/* BORING BUTTON */
.boring-button {
    position: fixed;
    top: 40px;
    right: 40px;
    font-family: var(--font-body);
    font-size: 16px;
    letter-spacing: 1px;
    cursor: pointer;
    z-index: 1000;
    transition: opacity 0.3s ease;
    white-space: nowrap;
}

.boring-button:hover {
    opacity: 0.6;
}

/* REFRESH POPUP */
.refresh-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    transition: opacity 0.3s ease;
}

.refresh-popup.hidden {
    opacity: 0;
    pointer-events: none;
}

.refresh-popup-content {
    background-color: var(--cream);
    color: var(--black);
    padding: 40px 60px;
    position: relative;
    max-width: 400px;
    text-align: center;
}

.refresh-popup-content p {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    margin: 0;
}

.refresh-popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 32px;
    cursor: pointer;
    color: var(--black);
    line-height: 1;
    padding: 0;
    transition: opacity 0.3s ease;
}

.refresh-popup-close:hover {
    opacity: 0.6;
}

/* HOME PAGE */
.home-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 60px;
    position: relative;
    overflow: hidden;
}

.main-title {
    font-family: var(--font-display);
    font-size: clamp(40px, 7vw, 240px);
    font-weight: normal;
    letter-spacing: 4px;
    text-align: center;
    line-height: 1;
    position: fixed;
    top: calc(50% - 100px);
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
    pointer-events: none;
    white-space: nowrap;
}

.subtitle {
    font-family: var(--font-body);
    font-size: clamp(20px, 3.5vw, 120px);
    letter-spacing: 3px;
    text-align: center;
    line-height: 1;
    position: fixed;
    z-index: 1;
    pointer-events: none;
    top: calc(50% - 100px + clamp(40px, 7vw, 240px) / 2 + 0.5em);
    left: 50%;
    transform: translate(-50%, -50%);
    white-space: nowrap;
}

/* BLOB NAVIGATION */
.blob-nav {
    position: relative;
    width: 100%;
    height: 100vh;
    pointer-events: none;
}

/* Home page squares - same size and color as circles were */
.index-page .square-blob {
    width: 200px;
    height: 200px;
    background-color: var(--black);
    color: var(--cream);
    transition: background-color 0.3s ease;
}

.index-page .square-blob:hover {
    background-color: #EB4E2D;
    opacity: 1;
}

.index-page .square-blob.work-square:hover {
    color: var(--black) !important;
}

.blob {
    cursor: pointer;
    position: absolute;
    pointer-events: all;
    will-change: transform, top, left;
    z-index: 100;
}

.blob img {
    display: block;
    width: auto;
    height: 200px;
    pointer-events: none;
}

.circle-blob {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background-color: var(--black);
    color: var(--cream);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-body);
    font-size: 19px;
    letter-spacing: 1px;
    pointer-events: all;
    position: relative;
    z-index: 2;
    transition: opacity 0.3s ease;
}

.circle-blob:hover {
    opacity: 0.6;
}

.blob:hover {
    z-index: 1001 !important;
}

.blob:hover img {
    transform: scale(1.08);
}

/* ABOUT PAGE */
.about-container {
    min-height: 100vh;
    padding: 150px 80px 80px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
    align-items: center;
    max-width: 1800px;
    margin: 0 auto;
}

.about-content h1 {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: normal;
    letter-spacing: 3px;
    margin-bottom: 40px;
}

.about-text p {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 20px;
}

.about-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.photo-stack {
    position: relative;
    width: 100%;
    max-width: 750px;
}

.photo-stack img {
    width: 100%;
    height: auto;
    display: block;
}

/* WORK PAGE */
.work-page,
.apps-page {
    overflow: hidden;
    height: 100vh;
}

.work-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0;
    position: relative;
    overflow: hidden;
}

.square-blob {
    width: 350px;
    height: 350px;
    background-color: var(--cream);
    color: var(--black);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-body);
    font-size: 19px;
    letter-spacing: 1px;
    pointer-events: all;
    position: relative;
    z-index: 2;
    transition: background-color 0.3s ease, opacity 0.3s ease;
}

.square-blob:hover {
    background-color: #EB4E2D;
    opacity: 1;
}

.square-blob-logo {
    width: 50%;
    max-width: 50%;
    height: auto;
    max-height: 50%;
    object-fit: contain;
}

@media (max-width: 768px) {
    .square-blob {
        width: 140px;
        height: 140px;
        font-size: 16px;
        text-align: center;
    }

    .index-page .square-blob {
        width: 135px;
        height: 135px;
        font-size: 14px;
    }

    .square-blob-logo {
        width: 50%;
        max-width: 50%;
        max-height: 50%;
    }
}

/* PROJECT PAGE */
.project-container {
    min-height: 100vh;
    padding: 150px 80px 80px;
}

.project-detail {
    max-width: 1000px;
    margin: 0 auto;
}

.project-title {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: normal;
    letter-spacing: 3px;
    margin-bottom: 20px;
}

.project-description {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 30px;
}

.project-description p {
    margin-bottom: 10px;
}

.project-description a {
    text-decoration: underline;
    transition: opacity 0.3s ease;
}

.project-description a:hover {
    opacity: 0.6;
}

.project-hero {
    margin-bottom: 30px;
}

.project-hero img,
.project-hero video {
    width: 100%;
    height: auto;
    display: block;
}

@media (max-width: 1024px) {
    .project-title {
        font-size: 32px;
    }

    .project-gallery {
        display: flex;
        flex-direction: column;
        gap: 30px;
    }

    .gallery-row-2,
    .gallery-row-1 {
        display: flex;
        flex-direction: column;
        gap: 30px;
    }

    .gallery-item {
        width: 100%;
    }
}

.project-section {
    margin-top: 0;
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: 1px solid var(--cream);
}

.project-section:not([open]) {
    margin-bottom: 0;
    padding-bottom: 0;
}

.project-section:first-of-type {
    margin-top: 20px;
}

.project-section:last-child {
    border-bottom: none;
}

.project-section-title {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: normal;
    letter-spacing: 2px;
    margin: 20px 0;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-transform: uppercase;
    padding-left: 0.8em;
    text-indent: -0.8em;
}


.project-section-title::-webkit-details-marker {
    display: none;
}

.project-section-title::after {
    content: '◀';
    font-size: 20px;
    font-family: var(--font-body);
    font-style: normal;
    transition: transform 0.3s ease;
}

.project-section[open] > .project-section-title::after {
    content: '▼';
}

.project-video {
    margin-bottom: 30px;
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
}

.project-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.project-gallery {
    column-count: 2;
    column-gap: 30px;
    margin-bottom: 30px;
}

.gallery-item {
    background-color: transparent;
    break-inside: avoid;
    margin-bottom: 20px;
}

.gallery-item p {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 10px;
}

.gallery-item img,
.gallery-item video {
    width: 100%;
    height: auto;
    display: block;
}

.gallery-row-2,
.gallery-row-1 {
    display: contents;
}

.full-width-gallery {
    column-count: 1;
}

.full-width-gallery .gallery-item {
    margin-bottom: 30px;
}


/* ART PAGE */
.art-page {
    overflow: hidden;
    height: 100vh;
}

.art-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0;
    position: relative;
    overflow: hidden;
}

/* RESUME PAGE */
.resume-container {
    min-height: 100vh;
    padding: 150px 80px 80px;
    max-width: 1200px;
    margin: 0 auto;
}

.resume-container h1 {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: normal;
    letter-spacing: 3px;
    margin-bottom: 20px;
}

.resume-container h1 a {
    color: var(--cream);
    text-decoration: underline;
    transition: opacity 0.3s ease;
}

.resume-container h1 a:hover {
    opacity: 0.6;
}

.resume-contact {
    font-family: var(--font-body);
    font-size: 16px;
    margin-bottom: 30px;
}

.resume-contact a {
    color: var(--cream);
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.resume-contact a:hover {
    opacity: 0.6;
}

.contact-label {
    font-family: var(--font-display);
    font-weight: 700;
}

.resume-content {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.8;
}

.resume-section {
    margin-bottom: 40px;
}

.resume-section h2 {
    font-family: var(--font-display);
    font-size: 36px;
    font-weight: normal;
    letter-spacing: 2px;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.resume-item {
    margin-bottom: 30px;
}

.resume-item h3 {
    font-size: 21px;
    font-weight: normal;
    margin-bottom: 5px;
}

.resume-item h3 strong {
    font-weight: bold;
}

.resume-meta {
    font-size: 16px;
    opacity: 0.7;
    margin-bottom: 10px;
}

@media (max-width: 768px) {
    .resume-container {
        padding: 120px 20px 40px;
    }

    .resume-contact {
        display: flex;
        flex-direction: column;
        gap: 5px;
    }

    .resume-contact .separator {
        display: none;
    }
}

/* AWARDS PAGE */
.awards-container {
    min-height: 100vh;
    padding: 150px 80px 80px;
}

.awards-detail {
    max-width: 1000px;
    margin: 0 auto;
}

.awards-container h1 {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: normal;
    letter-spacing: 3px;
    margin-bottom: 30px;
}

.awards-list {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 2;
}

/* CONTACT PAGE */
.contact-container {
    min-height: 100vh;
    padding: 150px 80px 80px;
    max-width: 1200px;
    margin: 0 auto;
}

.contact-container h1 {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: normal;
    letter-spacing: 3px;
    margin-bottom: 20px;
}

.contact-container p {
    font-family: var(--font-body);
    font-size: 16px;
    margin-bottom: 40px;
}

.contact-content {
    width: 100%;
    max-width: 600px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-form input,
.contact-form textarea {
    background-color: transparent;
    border: 2px solid var(--cream);
    color: var(--cream);
    padding: 15px 20px;
    font-family: var(--font-body);
    font-size: 16px;
    letter-spacing: 1px;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--cream);
    opacity: 0.6;
}

.contact-form button {
    background-color: var(--cream);
    color: var(--black);
    border: none;
    padding: 15px 40px;
    font-family: var(--font-body);
    font-size: 16px;
    letter-spacing: 2px;
    cursor: pointer;
    transition: opacity 0.3s ease;
    align-self: flex-start;
}

.contact-form button:hover {
    opacity: 0.8;
}

.contact-success {
    font-family: var(--font-body);
    font-size: 16px;
    text-align: left;
    padding: 40px 0;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .about-container {
        grid-template-columns: 1fr;
    }

    .about-image {
        order: -1;
    }
}

@media (max-width: 768px) {
    header {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
    }

    .logo {
        font-size: 24px;
    }

    header nav {
        gap: 15px;
        font-size: 14px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .home-container {
        padding: 0;
    }

    .circle-blob {
        width: 160px;
        height: 160px;
        font-size: 16px;
        background-color: var(--black);
    }

    .boring-button {
        top: 20px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        font-size: 14px;
    }

    #nav-menu {
        top: 20px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        font-size: 14px;
        gap: 15px;
        max-width: 90vw;
        justify-content: center;
    }

    .about-container {
        padding: 120px 40px 40px;
        gap: 60px;
    }

    .project-container,
    .awards-container,
    .contact-container {
        padding: 120px 20px 40px;
    }

    .gallery-row-2 {
        grid-template-columns: 1fr;
    }

    .art-gallery {
        flex-direction: column;
    }

    .art-item {
        width: 280px;
        height: 280px;
    }
}
