/* cbdc.studio - Sovereign Monetary Laboratory */

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

:root{
    --obsidian:#0A0E14;
    --vault:#141B24;
    --pale:#E8ECF1;
    --slate:#8A9BB0;
    --deep:#3A4B5C;
    --mint:#00E5A0;
    --gold:#D4A843;
    --blue:#1E6FD9;
}

html{scroll-behavior:smooth}

body{
    background:var(--obsidian);
    color:var(--slate);
    font-family:'IBM Plex Sans',sans-serif;
    font-weight:300;
    font-size:clamp(0.95rem,1.1vw,1.15rem);
    line-height:1.7;
    letter-spacing:0.01em;
    overflow-x:hidden;
}

/* Guilloche background */
.guilloche-layer{
    position:fixed;
    inset:0;
    z-index:0;
    pointer-events:none;
    display:flex;
    align-items:center;
    justify-content:center;
    opacity:0.04;
}

.guilloche-svg{
    width:min(100vw,100vh);
    height:min(100vw,100vh);
    animation:guillocheRotate 120s linear infinite;
}

@keyframes guillocheRotate{
    from{transform:rotate(0deg)}
    to{transform:rotate(360deg)}
}

/* Pip navigation */
.pip-nav{
    position:fixed;
    right:24px;
    top:50%;
    transform:translateY(-50%);
    z-index:100;
    display:flex;
    flex-direction:column;
    gap:12px;
}

.pip{
    width:8px;height:8px;
    border-radius:50%;
    border:1px solid var(--deep);
    background:transparent;
    cursor:pointer;
    padding:0;
    transition:background 300ms ease,border-color 300ms ease;
}

.pip.active{
    background:var(--mint);
    border-color:var(--mint);
}

/* Sections */
.sec{
    min-height:100vh;
    position:relative;
    z-index:5;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    padding:clamp(4rem,8vh,10rem) clamp(24px,6vw,80px);
}

.sec-inner{
    max-width:900px;
    width:100%;
    text-align:left;
}

.sec-narrow{
    max-width:620px;
}

/* Reveal */
.reveal-el{
    opacity:0;
    transform:translateY(16px);
    transition:opacity 800ms cubic-bezier(0.25,0.1,0.25,1),transform 800ms cubic-bezier(0.25,0.1,0.25,1);
}

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

/* Hero */
.hero-title{
    font-family:'DM Serif Display',serif;
    font-size:clamp(2.5rem,6vw,7rem);
    letter-spacing:0.15em;
    line-height:1.1;
    color:var(--pale);
    text-align:center;
}

.hero-title .hchar{
    display:inline-block;
    opacity:0;
    transition:opacity 600ms cubic-bezier(0.25,0.1,0.25,1);
}

.hero-title .hchar.show{
    opacity:1;
}

.hero-sub{
    font-family:'IBM Plex Sans',sans-serif;
    font-weight:300;
    font-size:clamp(0.9rem,1.2vw,1.15rem);
    color:var(--slate);
    text-align:center;
    margin-top:1.5rem;
}

/* Gold rule */
.gold-rule{
    width:60px;
    height:1px;
    background:var(--gold);
    opacity:0.2;
    margin:0 auto 3rem;
}

.body-text{
    margin-bottom:1.5rem;
    max-width:620px;
}

/* Section headings */
.sec-heading{
    font-family:'DM Serif Display',serif;
    font-size:clamp(1.4rem,2.5vw,2.8rem);
    letter-spacing:0.02em;
    line-height:1.1;
    color:var(--pale);
    margin-bottom:1rem;
}

/* Ledger graph */
.ledger-graph{
    width:100%;
    max-width:600px;
    height:auto;
    display:block;
    margin:0 auto;
}

.lg-node{
    fill:var(--mint);
}

.lg-edge{
    stroke:var(--blue);
    stroke-width:1;
    opacity:0.15;
    transition:opacity 800ms ease;
}

.ledger-graph.visible .lg-edge{
    opacity:0.5;
}

.lg-pulse{
    fill:none;
    stroke:var(--mint);
    stroke-width:1;
    opacity:0;
    animation:lgPulse 3s ease-out infinite;
}

.lg-pulse:nth-child(8){animation-delay:0s}
.lg-pulse:nth-child(9){animation-delay:1s}
.lg-pulse:nth-child(10){animation-delay:2s}

@keyframes lgPulse{
    0%{r:4;opacity:0.6}
    100%{r:20;opacity:0}
}

/* Architecture blocks */
.arch-block{
    margin-bottom:clamp(2rem,4vh,4rem);
    position:relative;
    padding-left:60px;
}

.arch-left{
    transform:translateX(-20px);
}

.arch-right{
    transform:translateX(20px);
}

.arch-block.visible{
    transform:translateX(0);
}

.arch-num{
    position:absolute;
    left:0;top:0;
    font-family:'DM Mono',monospace;
    font-size:clamp(0.8rem,0.95vw,1rem);
    letter-spacing:0.05em;
    color:var(--mint);
}

/* Sovereignty statement */
.sovereignty-statement{
    font-family:'DM Serif Display',serif;
    font-size:clamp(2rem,4.5vw,5rem);
    line-height:1.3;
    color:var(--pale);
    text-align:center;
    max-width:16ch;
    margin:0 auto;
}

/* Angle divider */
.angle-divider{
    width:200px;
    height:1px;
    background:var(--deep);
    opacity:0.3;
    transform:rotate(15deg);
    margin:0 auto 3rem;
}

/* Seal */
.seal-content{
    text-align:center;
    display:flex;
    flex-direction:column;
    align-items:center;
}

.seal-rosette{
    width:120px;height:120px;
    margin-bottom:2rem;
}

.seal-text{
    font-family:'DM Mono',monospace;
    font-size:0.85rem;
    letter-spacing:0.05em;
    color:var(--deep);
}

/* Responsive */
@media(max-width:768px){
    .pip-nav{
        right:12px;
    }

    .arch-left,.arch-right{
        transform:translateX(0);
    }

    .sovereignty-statement{
        font-size:clamp(1.5rem,4vw,3rem);
    }
}
