/* tanso.group — styles */

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

:root {
    --bg-primary: #f5ede3;
    --bg-secondary: #1c1815;
    --text-primary: #2d2520;
    --text-secondary: #5a4e44;
    --accent-primary: #c2785c;
    --accent-secondary: #d4a574;
    --accent-tertiary: #b8656a;
    --muted: #a89b8e;
    --light-text: #f5e6d0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Nunito Sans', sans-serif;
    font-weight: 400;
    font-size: clamp(1rem, 1.1vw, 1.15rem);
    line-height: 1.72;
    letter-spacing: 0.005em;
    color: var(--text-secondary);
    background: var(--bg-primary);
    overflow-x: hidden;
}

/* Grain Overlay */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    opacity: 0.035;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
    mix-blend-mode: multiply;
    transition: opacity 0.3s;
}

/* Hero */
#hero {
    position: relative;
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    background: var(--bg-secondary);
    transition: background 1.2s ease;
}

#hero.revealed {
    background: linear-gradient(175deg, #f5ede3 0%, #f0dcc8 45%, #eddacc 100%);
}

#enso {
    opacity: 0;
    transition: opacity 0.6s ease;
}

#enso.visible {
    opacity: 1;
}

#enso-path {
    stroke-dasharray: 600;
    stroke-dashoffset: 600;
    transition: stroke-dashoffset 2.4s ease-out;
}

#enso-path.draw {
    stroke-dashoffset: 0;
}

#hero-title {
    font-family: 'Jost', sans-serif;
    font-weight: 600;
    font-size: clamp(2.2rem, 5vw, 4.5rem);
    letter-spacing: -0.02em;
    line-height: 1.1;
    color: var(--light-text);
    opacity: 0;
    transition: opacity 0.8s ease, color 1.2s ease;
    position: absolute;
}

#hero-title.visible {
    opacity: 1;
}

#hero.revealed #hero-title {
    color: var(--text-primary);
}

/* Navigation */
#nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    opacity: 0;
    transition: opacity 0.6s ease;
}

#nav.visible {
    opacity: 1;
}

.nav-domain {
    font-family: 'Jost', sans-serif;
    font-weight: 400;
    font-size: 0.95rem;
    color: var(--text-primary);
    letter-spacing: 0.01em;
}

.nav-link {
    font-family: 'DM Mono', monospace;
    font-weight: 400;
    font-size: clamp(0.72rem, 0.85vw, 0.85rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-primary);
    cursor: pointer;
}

/* SVG Spine */
#spine {
    position: absolute;
    left: 5%;
    top: 100vh;
    width: 60px;
    height: 2000px;
    z-index: 1;
    pointer-events: none;
}

#spine-path {
    stroke-dasharray: 3000;
    stroke-dashoffset: 3000;
}

/* Content */
#content {
    position: relative;
    z-index: 2;
    padding: 6rem 0;
}

.block {
    max-width: 55%;
    padding: 3rem 3.5rem;
    margin-bottom: 4rem;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out, box-shadow 0.4s ease;
    border-radius: 2px;
}

.block:nth-child(odd) {
    margin-bottom: 8rem;
}

.block.in-view {
    opacity: 1;
    transform: translateY(0) translateX(0);
}

.block:hover {
    box-shadow: 0 4px 24px 0 rgba(194,120,92,0.08);
}

/* Broken grid offsets */
.block-odd {
    margin-left: 12%;
    transform: translateY(30px) translateX(-20px);
}

.block-even {
    margin-left: 30%;
    transform: translateY(30px) translateX(20px);
}

.block-odd.in-view {
    transform: translateY(0) translateX(0);
}

.block-even.in-view {
    transform: translateY(0) translateX(0);
}

/* Light blocks */
.block-light {
    background: var(--bg-primary);
    color: var(--text-primary);
    box-shadow: 0 8px 40px rgba(90, 78, 68, 0.04);
}

/* Dark blocks */
.block-dark {
    background: var(--bg-secondary);
    color: var(--light-text);
    box-shadow: 0 8px 40px rgba(28, 24, 21, 0.15);
}

.block-dark .block-label {
    color: var(--accent-secondary);
}

.block-dark p {
    color: #c8b8a8;
}

/* Block typography */
.block-label {
    font-family: 'DM Mono', monospace;
    font-weight: 400;
    font-size: clamp(0.72rem, 0.85vw, 0.85rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-primary);
    display: block;
    margin-bottom: 1rem;
}

.block h2 {
    font-family: 'Jost', sans-serif;
    font-weight: 600;
    font-size: clamp(1.6rem, 3.5vw, 2.8rem);
    letter-spacing: -0.02em;
    line-height: 1.1;
    margin-bottom: 1.2rem;
}

.block p {
    line-height: 1.72;
    max-width: 540px;
}

/* Link style */
.block-link {
    display: inline-block;
    margin-top: 1.5rem;
    font-family: 'DM Mono', monospace;
    font-size: clamp(0.72rem, 0.85vw, 0.85rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-primary);
    text-decoration: none;
    background-image: linear-gradient(var(--accent-primary), var(--accent-primary));
    background-size: 0% 1px;
    background-repeat: no-repeat;
    background-position: left bottom;
    transition: background-size 0.3s ease;
    padding-bottom: 2px;
}

.block-link:hover {
    background-size: 100% 1px;
}

/* Mon Dividers */
.mon-divider {
    display: flex;
    justify-content: center;
    padding: 2rem 0;
    opacity: 0;
    transition: opacity 0.7s ease;
}

.mon-divider.in-view {
    opacity: 1;
}

/* Closing Stroke */
#closing-stroke {
    width: 80%;
    max-width: 600px;
    margin: 4rem auto 6rem;
    opacity: 0;
    transition: opacity 0.7s ease;
}

#closing-stroke.in-view {
    opacity: 1;
}

#closing-path {
    stroke-dasharray: 700;
    stroke-dashoffset: 700;
    transition: stroke-dashoffset 1.5s ease-out;
}

#closing-stroke.in-view #closing-path {
    stroke-dashoffset: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .block {
        max-width: 85%;
        margin-left: 8% !important;
        padding: 2rem 2rem;
    }

    #nav {
        padding: 1rem 1.5rem;
    }

    #spine {
        display: none;
    }
}
