/* gunsul.studio - Wabi-sabi industrial architecture */

/* Reset */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Palette:
   Void:            #1a1a18
   Surface:         #2d2b28
   Primary Text:    #e8e0d0
   Secondary Text:  #a09888
   Accent Brass:    #c0b49a
   Highlight Patina:#7a9e8e
   Structural:      #3d3d3d
   Shadow:          #6a6258
*/

html {
    scroll-behavior: smooth;
    scroll-snap-type: y mandatory;
}

body {
    background-color: #1a1a18;
    color: #c8c0b0;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.8;
    overflow-x: hidden;
}

/* Formwork texture */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    background-image:
        repeating-linear-gradient(
            to bottom,
            rgba(28, 28, 26, 0.4) 0px,
            rgba(28, 28, 26, 0.4) 1px,
            transparent 1px,
            transparent 4px
        );
}

/* Opening overlay */
#opening-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #1a1a18;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.8s ease;
}

#opening-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

#light-slit {
    width: 100%;
    height: 0px;
    background-color: #2d2b28;
    opacity: 0;
    transition: height 2s cubic-bezier(0.16, 1, 0.3, 1), opacity 1.5s ease;
}

#light-slit.visible {
    opacity: 1;
    height: 8px;
}

#light-slit.expanded {
    height: 100vh;
}

/* Scroll progress */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 2px;
    height: 100vh;
    background-color: transparent;
    z-index: 50;
}

#scroll-progress-fill {
    width: 2px;
    height: 0%;
    background-color: #c0b49a;
    transition: height 150ms ease;
}

/* Navigation */
#nav-trigger {
    position: fixed;
    top: 0;
    left: 0;
    width: 80px;
    height: 100vh;
    z-index: 60;
    cursor: pointer;
}

#nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 200px;
    height: 100vh;
    background-color: rgba(26, 26, 24, 0.95);
    z-index: 55;
    display: flex;
    align-items: center;
    padding-left: 40px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 400ms ease;
}

#nav-overlay.visible {
    opacity: 1;
    pointer-events: auto;
}

.nav-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.nav-item {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 300;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #a09888;
    text-decoration: none;
    transition: color 300ms ease;
}

.nav-item:hover {
    color: #e8e0d0;
}

/* Structural reference lines */
#reference-lines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    background-image:
        repeating-linear-gradient(
            to right,
            transparent 0px,
            transparent calc((100% - 120px) / 6 + 120px / 7 - 1px),
            rgba(42, 42, 42, 0.3) calc((100% - 120px) / 6 + 120px / 7 - 1px),
            rgba(42, 42, 42, 0.3) calc((100% - 120px) / 6 + 120px / 7),
            transparent calc((100% - 120px) / 6 + 120px / 7)
        );
}

/* Scroll Container */
#scroll-container {
    position: relative;
    z-index: 2;
}

/* Bay */
.bay {
    min-height: 100vh;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    padding: 120px;
}

.bay-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 48px;
    align-items: start;
}

/* Bay content positioning */
.bay-col-1-3 {
    grid-column: 1 / span 3;
}

.bay-col-2-4 {
    grid-column: 2 / span 3;
}

.bay-col-3-5 {
    grid-column: 3 / span 3;
}

.bay-col-4-6 {
    grid-column: 4 / span 3;
}

/* Bay content */
.bay-content {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 800ms ease, transform 800ms ease;
}

.bay-content.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Typography */
.site-title {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    font-size: 64px;
    color: #e8e0d0;
    letter-spacing: -0.02em;
    line-height: 1.1;
    margin-bottom: 16px;
}

.subtitle {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: 15px;
    color: #a09888;
    margin-bottom: 48px;
}

.bay-number {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 300;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6a6258;
    display: block;
    margin-bottom: 24px;
}

.bay-title {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    font-size: 48px;
    color: #e8e0d0;
    letter-spacing: -0.02em;
    line-height: 1.1;
    margin-bottom: 32px;
}

.body-text {
    color: #c8c0b0;
    font-weight: 300;
    margin-bottom: 24px;
    max-width: 520px;
}

.body-secondary {
    color: #a09888;
    font-weight: 300;
    margin-bottom: 16px;
    max-width: 520px;
}

.caption {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 300;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6a6258;
}

/* Breathing animation for copper patina accent */
.breathing {
    color: #7a9e8e;
    animation: breathe 6s ease-in-out infinite;
}

@keyframes breathe {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1.0; }
}

/* Light slit dividers */
.light-slit-divider {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 8px;
    background-color: #2d2b28;
    box-shadow: 0 0 40px 10px rgba(200, 192, 176, 0.03);
}

/* Material swatches */
.material-swatch {
    width: 40px;
    height: 40px;
    opacity: 0.6;
    border: none;
}

.swatch-concrete {
    background:
        repeating-linear-gradient(
            to bottom,
            #2d2b28 0px,
            #2d2b28 1px,
            #2a2a2a 1px,
            #2a2a2a 3px
        );
}

.swatch-metal {
    background:
        linear-gradient(
            135deg,
            #3d3d3d 0%,
            #4a4a4a 25%,
            #3d3d3d 50%,
            #4a4a4a 75%,
            #3d3d3d 100%
        );
}

.swatch-patina {
    background:
        radial-gradient(
            circle at 30% 40%,
            #7a9e8e 0%,
            #6a8e7e 40%,
            #5a7e6e 100%
        );
}

/* Contact */
.contact-detail {
    margin-top: 32px;
}

.contact-detail .body-secondary {
    margin-top: 8px;
    margin-bottom: 0;
}

/* Footer */
#site-footer {
    position: relative;
    z-index: 2;
    padding: 96px 120px;
    text-align: center;
    border-top: 1px solid #3d3d3d;
}

.footer-mark {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    font-size: 24px;
    color: #e8e0d0;
    letter-spacing: -0.02em;
    display: block;
    margin-bottom: 12px;
}

.footer-caption {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 300;
    font-size: 11px;
    letter-spacing: 0.08em;
    color: #6a6258;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .bay {
        padding: 60px 24px;
    }

    .bay-grid {
        display: block;
    }

    .site-title {
        font-size: 40px;
    }

    .bay-title {
        font-size: 32px;
    }

    .material-swatch {
        display: none;
    }

    #reference-lines {
        display: none;
    }

    #nav-overlay {
        padding-left: 24px;
    }

    #site-footer {
        padding: 60px 24px;
    }
}
