:root {
    --bg-color: #0a0a0a;
    --text-color: #f0f0f0;
    --accent-color: #ffffff;
    --secondary-text: #888888;
    --font-heading: 'Noto Serif KR', 'Playfair Display', serif;
    --font-body: 'Pretendard', 'Inter', sans-serif;
    --transition-speed: 0.6s;
    --container-padding: 5vw;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    cursor: none;
    /* Custom cursor implementation */
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--bg-color);
    color: var(--text-color);
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    word-break: keep-all;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
    height: auto;
}

/* --- Custom Cursor --- */
.cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 10px;
    height: 10px;
    background-color: var(--accent-color);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    mix-blend-mode: difference;
    transition: transform 0.1s ease;
}

.cursor-follower {
    position: fixed;
    top: 0;
    left: 0;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    transition: transform 0.15s ease, width 0.3s ease, height 0.3s ease;
}

.cursor-hover .cursor {
    transform: translate(-50%, -50%) scale(0.5);
}

.cursor-hover .cursor-follower {
    transform: translate(-50%, -50%) scale(1.5);
    background-color: rgba(255, 255, 255, 0.1);
    border-color: transparent;
}

/* --- Navigation --- */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 2rem var(--container-padding);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    mix-blend-mode: difference;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
}

/* Nav always visible now, just simpler layout for mobile if needed */
.nav {
    display: block;
}

.nav-list {
    display: flex;
    gap: 1.5rem;
    /* Slightly smaller gap/text for mobile safety if needed */
}

.nav-link {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    font-weight: 500;
}

/* Desktop Styles enhancement */
@media (min-width: 768px) {
    .nav-list {
        gap: 3rem;
    }

    .nav-link {
        font-size: 0.9rem;
    }
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* --- Hero Section --- */
.hero {
    position: relative;
    height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    animation: zoomOut 20s infinite alternate linear;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
}

.hero-content {
    text-align: center;
    z-index: 2;
    padding: 0 1rem;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 10vw, 8rem);
    /* Responsive typography */
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-subtitle {
    font-size: 1rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 4rem;
}

.scroll-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.7;
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-text {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.line {
    width: 1px;
    height: 60px;
    background-color: var(--accent-color);
    animation: scrollLine 2s infinite ease-in-out;
}

/* --- Gallery Section --- */
.gallery {
    padding: 10rem var(--container-padding);
}

.section-header {
    margin-bottom: 5rem;
    display: flex;
    align-items: center;
    gap: 2rem;
}

.section-header h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 400;
}

.line-separator {
    flex-grow: 1;
    height: 1px;
    background-color: rgba(255, 255, 255, 0.2);
}

/* New Gallery Layout: Dual Columns for Parallax */
.gallery-columns {
    display: flex;
    flex-direction: column;
    gap: 4rem;
}

@media (min-width: 768px) {
    .gallery-columns {
        flex-direction: row;
        gap: 4rem;
        align-items: flex-start;
        /* Important for independent scrolling */
        justify-content: center;
    }

    .gallery-column {
        flex: 1;
        display: flex;
        flex-direction: column;
        gap: 8rem;
        /* Large vertical gap */
    }

    /* Start the right column lower to create offset */
    .col-right {
        margin-top: 15rem;
    }
}

.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: none;
}

.img-wrapper {
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.gallery-item img {
    cursor: none;
    width: 100%;
    transition: transform 1s cubic-bezier(0.19, 1, 0.22, 1), filter 0.5s ease;
    filter: grayscale(100%);
}

.gallery-item:hover img {
    transform: scale(1.1);
    filter: grayscale(0%);
}

.caption h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.5s ease;
}

.caption p {
    color: var(--secondary-text);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.5s ease 0.1s;
}

.gallery-item:hover .caption h3,
.gallery-item:hover .caption p {
    transform: translateY(0);
    opacity: 1;
}


/* --- About Section --- */
.about {
    padding: 5rem var(--container-padding);
    background-color: #0f0f0f;
}

.about-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4rem;
    align-items: center;
}

@media (min-width: 900px) {
    .about-container {
        grid-template-columns: 1fr 1fr;
    }

    .about-text {
        padding-left: 4rem;
    }
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 2rem;
}

.about-text .lead {
    font-size: 1.25rem;
    color: var(--accent-color);
    margin-bottom: 1.5rem;
}

.about-text p {
    color: var(--secondary-text);
    margin-bottom: 2rem;
}

.signature {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-style: italic;
    margin-top: 2rem;
}

/* --- Contact Section --- */
.contact {
    padding: 8rem var(--container-padding);
    display: flex;
    justify-content: center;
}

.contact-wrapper {
    width: 100%;
    max-width: 600px;
    text-align: center;
}

.contact-wrapper h2 {
    font-family: var(--font-heading);
    font-size: 3rem;
    margin-bottom: 3rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.form-group {
    position: relative;
}

.form-group input,
.form-group textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding: 1rem 0;
    color: white;
    font-size: 1rem;
    font-family: var(--font-body);
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: white;
}

.form-group label {
    position: absolute;
    top: 1rem;
    left: 0;
    color: var(--secondary-text);
    transition: 0.3s ease all;
    pointer-events: none;
}

.form-group input:focus~label,
.form-group input:not(:placeholder-shown)~label,
.form-group textarea:focus~label,
.form-group textarea:not(:placeholder-shown)~label {
    top: -1.25rem;
    font-size: 0.75rem;
    color: white;
}

.btn-submit {
    margin-top: 2rem;
    background: white;
    color: black;
    border: none;
    padding: 1rem 3rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    align-self: center;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.btn-submit:hover {
    background-color: #ddd;
    transform: translateY(-3px);
}

/* --- Footer --- */
.footer {
    padding: 3rem var(--container-padding);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.875rem;
    color: var(--secondary-text);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

@media(min-width: 768px) {
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
    }
}

.socials {
    display: flex;
    gap: 2rem;
}

/* --- Animations --- */
@keyframes zoomOut {
    from {
        transform: scale(1.1);
    }

    to {
        transform: scale(1);
    }
}

@keyframes scrollLine {
    0% {
        transform: scaleY(0);
        transform-origin: top;
    }

    50% {
        transform: scaleY(1);
        transform-origin: top;
    }

    51% {
        transform: scaleY(1);
        transform-origin: bottom;
    }

    100% {
        transform: scaleY(0);
        transform-origin: bottom;
    }
}

/* Reveal Animations Classes (Triggered by JS) */
.reveal-text {
    display: block;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease, transform 1s ease;
}

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

.scale-up {
    transform: scale(1.1);
}