/* =========================================================================
   iggi.dev — a Victorian bryologist's cabinet
   Palette:
     #f5ead0  aged parchment (primary bg)
     #3b2a1a  deep walnut (sidebar)
     #2e3a2a  moss slate (dark plates)
     #2e1f0f  burnt umber (primary text)
     #3d3024  body text
     #8a7a64  aged brass (secondary text)
     #6b7f4a  living moss (accent primary)
     #c8943e  amber glass (accent warm)
     #c9b896  faded sepia rule
     #5a4a36  hairline rule
     #5a4a3a  code sepia
     #5a6e3a  dark moss stem
   ========================================================================= */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background: #f5ead0;
}

body {
    font-family: 'Jost', 'Futura', 'Avenir Next', sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.75;
    color: #3d3024;
    background: #f5ead0;
    overflow-x: hidden;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Subtle paper texture via repeating radial gradients (flat palette, no big gradients) */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(138, 122, 100, 0.04) 0%, transparent 60%),
        radial-gradient(circle at 75% 70%, rgba(138, 122, 100, 0.03) 0%, transparent 55%);
    mix-blend-mode: multiply;
}

/* ------------------------- Sidebar -------------------------------------- */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background: #3b2a1a;
    color: #f5ead0;
    z-index: 50;
    border-right: 1px solid #2e1f0f;
    box-shadow: 1px 0 0 rgba(201, 184, 150, 0.08) inset;
    transition: transform 400ms cubic-bezier(0.23, 1, 0.32, 1);
}

.sidebar-inner {
    height: 100%;
    padding: 48px 32px 32px 32px;
    display: flex;
    flex-direction: column;
}

.monogram {
    width: 88px;
    height: 88px;
    margin-bottom: 56px;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 800ms ease-out 400ms, transform 800ms ease-out 400ms;
}

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

.monogram svg {
    width: 100%;
    height: 100%;
    display: block;
}

.sidebar-nav {
    flex: 1;
    position: relative;
    display: flex;
    align-items: flex-start;
}

.nav-rail {
    position: relative;
    width: 1px;
    align-self: stretch;
    margin-right: 20px;
    flex-shrink: 0;
}

.nav-rail-line {
    position: absolute;
    top: 12px;
    bottom: 12px;
    left: 0;
    width: 1px;
    background: #5a4a36;
    opacity: 0.6;
}

.nav-indicator {
    position: absolute;
    left: -2.5px;
    top: 12px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #6b7f4a;
    box-shadow: 0 0 8px rgba(107, 127, 74, 0.45);
    transition: transform 220ms cubic-bezier(0.23, 1, 0.32, 1);
    will-change: transform;
}

.nav-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 18px;
    flex: 1;
}

.nav-link {
    display: block;
    font-family: 'Jost', sans-serif;
    font-weight: 500;
    font-size: 11.5px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #c9b896;
    text-decoration: none;
    transition: color 240ms ease;
    padding: 2px 0;
}

.nav-link:hover {
    color: #c8943e;
}

.nav-link.active {
    color: #f5ead0;
}

.sidebar-footer {
    margin-top: auto;
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-style: italic;
    font-weight: 400;
    font-size: 10px;
    letter-spacing: 0.08em;
    color: #8a7a64;
    opacity: 0.9;
    line-height: 1.6;
}

/* ---- Sidebar toggle (mobile) ---- */
.sidebar-toggle {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    width: 44px;
    height: 44px;
    background: #3b2a1a;
    border: 1px solid #5a4a36;
    border-radius: 4px;
    cursor: pointer;
    z-index: 100;
    padding: 12px 10px;
}

.sidebar-toggle span {
    display: block;
    width: 100%;
    height: 1.5px;
    background: #f5ead0;
    margin: 4px 0;
    transition: transform 300ms ease, opacity 300ms ease;
}

.sidebar-toggle.open span:nth-child(1) {
    transform: translateY(5.5px) rotate(45deg);
}

.sidebar-toggle.open span:nth-child(2) {
    opacity: 0;
}

.sidebar-toggle.open span:nth-child(3) {
    transform: translateY(-5.5px) rotate(-45deg);
}

/* ------------------------- Main / Plates -------------------------------- */
.main {
    margin-left: 280px;
    position: relative;
    z-index: 2;
}

.plate {
    position: relative;
    min-height: 100vh;
    padding: 112px 0 84px 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.plate-light {
    background: #f5ead0;
    color: #3d3024;
}

/* Breathing zone between plates — barely-perceptible sepia wash */
.plate-light + .plate-light::before,
.plate-dark + .plate-light::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 84px;
    background: #f8f2e8;
    opacity: 0.3;
    pointer-events: none;
    z-index: 0;
}

.plate-dark {
    background: #2e3a2a;
    color: #c9b896;
}

.plate-inner {
    position: relative;
    display: grid;
    grid-template-columns: 12% minmax(0, 540px) 1fr;
    grid-column-gap: 48px;
    align-items: start;
    width: 100%;
    z-index: 2;
}

.plate-inner-centered {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 70vh;
}

.plate-content {
    grid-column: 2 / 3;
    max-width: 540px;
}

.plate-specimen {
    grid-column: 3 / 4;
    position: relative;
    min-height: 420px;
    padding-left: 48px;
    padding-right: 40px;
}

/* ------------------------- Meta / small caps ---------------------------- */
.plate-meta {
    font-family: 'Jost', sans-serif;
    font-weight: 500;
    font-size: 11.5px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: #8a7a64;
    margin-bottom: 28px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.plate-meta-dark {
    color: #c9b896;
    opacity: 0.75;
}

.meta-dot {
    color: #c9b896;
    opacity: 0.7;
}

/* ------------------------- Titles / Headings ---------------------------- */
.title-main {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-weight: 400;
    font-style: italic;
    font-size: clamp(3rem, 7vw, 5.5rem);
    line-height: 1.05;
    color: #2e1f0f;
    margin-bottom: 20px;
    font-feature-settings: 'liga' 1, 'onum' 1;
    letter-spacing: -0.01em;
}

.title-main em {
    font-style: italic;
}

.title-dot {
    color: #6b7f4a;
    font-style: normal;
}

.subtitle {
    font-family: 'Jost', sans-serif;
    font-weight: 400;
    font-size: 1.2rem;
    letter-spacing: 0.3em;
    color: #8a7a64;
    margin-bottom: 28px;
}

.subtitle-rule {
    margin-bottom: 56px;
}

.subtitle-rule svg {
    width: 160px;
    height: 24px;
    display: block;
}

.frond-path {
    stroke-dasharray: 400;
    stroke-dashoffset: 400;
    transition: stroke-dashoffset 1500ms ease-out;
}

.subtitle-rule.drawn .frond-path {
    stroke-dashoffset: 0;
}

.plate-heading {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-weight: 600;
    font-size: clamp(2rem, 5vw, 4.5rem);
    line-height: 1.12;
    color: #2e1f0f;
    margin-bottom: 36px;
    font-feature-settings: 'liga' 1, 'onum' 1;
    letter-spacing: -0.01em;
}

.plate-heading em {
    font-style: italic;
    font-weight: 400;
    color: #6b7f4a;
}

.plate-dark .plate-heading {
    color: #f5ead0;
}

.plate-dark .plate-heading em {
    color: #8fa66a;
}

/* ------------------------- Body / paragraphs ---------------------------- */
.lede,
.plate-body {
    font-family: 'Jost', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.75;
    color: #3d3024;
    margin-bottom: 28px;
    max-width: 540px;
}

.plate-dark .lede,
.plate-dark .plate-body {
    color: #c9b896;
}

.lede {
    font-size: 1.05rem;
}

.lede-tag {
    margin-top: 28px;
    font-family: 'Jost', sans-serif;
    font-size: 13px;
    color: #8a7a64;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ------------------------- Inline code / blocks ------------------------- */
.inline-code {
    font-family: 'JetBrains Mono', 'Roboto Mono', monospace;
    font-size: 0.85em;
    color: #5a4a3a;
    background: rgba(62, 48, 36, 0.06);
    padding: 2px 8px;
    border-radius: 2px;
    border-left: 2px solid #c9b896;
}

.plate-dark .inline-code {
    color: #c9b896;
    background: rgba(201, 184, 150, 0.08);
    border-left-color: #6b7f4a;
}

.code-marginalia {
    font-family: 'JetBrains Mono', 'Roboto Mono', monospace;
    font-size: 13px;
    line-height: 1.7;
    color: #c9b896;
    background: rgba(245, 234, 208, 0.04);
    border-left: 2px solid #6b7f4a;
    padding: 18px 24px;
    margin: 28px 0;
    max-width: 540px;
    overflow-x: auto;
    white-space: pre;
}

.plate-light .code-marginalia {
    color: #5a4a3a;
    background: rgba(62, 48, 36, 0.06);
    border-left-color: #c9b896;
}

/* ------------------------- Pull quote ----------------------------------- */
.pullquote {
    position: relative;
    margin: 56px 0 56px -4px;
    padding: 0 36px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.pullquote p {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(1.25rem, 2.2vw, 1.65rem);
    line-height: 1.4;
    color: #2e1f0f;
    max-width: 420px;
}

.plate-dark .pullquote p {
    color: #f5ead0;
}

.pullquote-sprig {
    width: 18px;
    height: 36px;
    flex-shrink: 0;
}

.pullquote-sprig-right {
    align-self: flex-end;
}

/* ------------------------- Field notes list ----------------------------- */
.field-notes {
    list-style: none;
    margin: 28px 0 28px 0;
    padding: 0;
    border-top: 1px solid #c9b896;
    border-bottom: 1px solid #c9b896;
    max-width: 520px;
}

.field-notes li {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 10px 0;
    border-bottom: 1px solid rgba(201, 184, 150, 0.4);
    font-size: 14px;
    line-height: 1.6;
}

.field-notes li:last-child {
    border-bottom: none;
}

.field-key {
    font-family: 'Jost', sans-serif;
    font-weight: 500;
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #8a7a64;
}

.field-val {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-style: italic;
    font-size: 15px;
    color: #3d3024;
    text-align: right;
}

/* ------------------------- Principle list ------------------------------- */
.principle-list {
    display: flex;
    flex-direction: column;
    gap: 22px;
    margin-top: 36px;
}

.principle {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 20px;
    align-items: baseline;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(201, 184, 150, 0.25);
}

.principle:last-child {
    border-bottom: none;
}

.principle-no {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: #6b7f4a;
    letter-spacing: 0.08em;
    white-space: nowrap;
}

.principle-body {
    font-family: 'Jost', sans-serif;
    font-size: 15px;
    line-height: 1.65;
    color: #c9b896;
}

.principle-body strong {
    display: block;
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-weight: 600;
    font-style: italic;
    font-size: 1.15rem;
    color: #f5ead0;
    margin-bottom: 4px;
    letter-spacing: -0.005em;
}

/* ------------------------- Moss Illustrations --------------------------- */
.moss-illustration {
    position: relative;
    width: 100%;
    max-width: 320px;
    height: 380px;
    margin-left: auto;
    margin-top: 24px;
}

.moss-illustration > * {
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 600ms ease-out, transform 600ms cubic-bezier(0.23, 1, 0.32, 1);
}

.moss-illustration.assembled > * {
    opacity: 1;
    transform: scale(1);
}

.specimen-label {
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    padding-top: 14px;
    border-top: 1px solid #c9b896;
    font-family: 'Jost', sans-serif;
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #8a7a64;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
}

.specimen-label em {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-style: italic;
    font-size: 14px;
    text-transform: none;
    letter-spacing: 0;
    color: #3d3024;
}

.specimen-label-dark {
    border-top-color: rgba(201, 184, 150, 0.4);
    color: #c9b896;
}

.specimen-label-dark em {
    color: #f5ead0;
}

/* ---- Generic moss shapes ---- */
.moss-stem {
    position: absolute;
    width: 2px;
    background: #5a6e3a;
    border-radius: 1px;
    transform-origin: bottom center;
}

.moss-leaf {
    position: absolute;
    border-radius: 50%;
    background: #6b7f4a;
    opacity: 0.7;
}

.moss-capsule {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6b7f4a;
    box-shadow: 0 0 20px rgba(107, 127, 74, 0.35);
}

/* ---- Illustration 1: Hypnum cupressiforme (plate 1) ---- */
.moss-ill-1 .moss-stem-1 { left: 30%; bottom: 80px; height: 140px; transform: rotate(-5deg); }
.moss-ill-1 .moss-stem-2 { left: 45%; bottom: 80px; height: 180px; transform: rotate(3deg); }
.moss-ill-1 .moss-stem-3 { left: 60%; bottom: 80px; height: 110px; transform: rotate(10deg); }

.moss-ill-1 .moss-leaf-1 { width: 30px; height: 14px; left: 22%; bottom: 170px; transform: rotate(-20deg); }
.moss-ill-1 .moss-leaf-2 { width: 36px; height: 16px; left: 40%; bottom: 210px; transform: rotate(15deg); }
.moss-ill-1 .moss-leaf-3 { width: 28px; height: 13px; left: 55%; bottom: 150px; transform: rotate(-10deg); opacity: 0.6; }
.moss-ill-1 .moss-leaf-4 { width: 32px; height: 14px; left: 32%; bottom: 130px; transform: rotate(25deg); opacity: 0.65; }

.moss-ill-1 .moss-capsule-1 { left: 30%; top: 70px; }
.moss-ill-1 .moss-capsule-2 { left: 47%; top: 40px; width: 10px; height: 10px; }
.moss-ill-1 .moss-capsule-3 { left: 62%; top: 120px; width: 6px; height: 6px; }

/* ---- Illustration 2: Bryum argenteum cluster (plate 2) ---- */
.moss-ill-2 .moss-cluster {
    position: absolute;
    inset: 0;
}

.moss-ill-2 .moss-stem-1 { left: 25%; bottom: 80px; height: 90px; transform: rotate(-15deg); }
.moss-ill-2 .moss-stem-2 { left: 35%; bottom: 80px; height: 110px; transform: rotate(-5deg); }
.moss-ill-2 .moss-stem-3 { left: 50%; bottom: 80px; height: 130px; transform: rotate(8deg); }
.moss-ill-2 .moss-stem-4 { left: 65%; bottom: 80px; height: 100px; transform: rotate(18deg); }

.moss-ill-2 .moss-leaf-1 { width: 26px; height: 14px; left: 18%; bottom: 140px; transform: rotate(-30deg); }
.moss-ill-2 .moss-leaf-2 { width: 32px; height: 16px; left: 30%; bottom: 170px; transform: rotate(-10deg); }
.moss-ill-2 .moss-leaf-3 { width: 36px; height: 18px; left: 45%; bottom: 200px; transform: rotate(10deg); }
.moss-ill-2 .moss-leaf-4 { width: 30px; height: 15px; left: 58%; bottom: 170px; transform: rotate(25deg); opacity: 0.65; }
.moss-ill-2 .moss-leaf-5 { width: 24px; height: 12px; left: 68%; bottom: 140px; transform: rotate(35deg); opacity: 0.55; }

.moss-ill-2 .moss-capsule-1 { left: 34%; top: 90px; }
.moss-ill-2 .moss-capsule-2 { left: 53%; top: 50px; width: 9px; height: 9px; }

/* ---- Illustration 3: Polytrichum sporophytes (plate 3) ---- */
.moss-ill-3 .spore-release { position: absolute; inset: 0; }
.moss-ill-3 .moss-stem-tall-1 { position: absolute; left: 30%; bottom: 80px; width: 1.5px; height: 220px; background: #8fa66a; transform-origin: bottom; transform: rotate(-2deg); border-radius: 1px; }
.moss-ill-3 .moss-stem-tall-2 { position: absolute; left: 48%; bottom: 80px; width: 1.5px; height: 260px; background: #8fa66a; transform-origin: bottom; transform: rotate(4deg); border-radius: 1px; }
.moss-ill-3 .moss-stem-tall-3 { position: absolute; left: 65%; bottom: 80px; width: 1.5px; height: 200px; background: #8fa66a; transform-origin: bottom; transform: rotate(-8deg); border-radius: 1px; }

.moss-ill-3 .moss-capsule-lamp-1 {
    position: absolute; left: 29%; top: 60px;
    width: 14px; height: 18px; border-radius: 50% 50% 40% 40%;
    background: #c8943e; box-shadow: 0 0 24px rgba(200, 148, 62, 0.5), 0 0 48px rgba(200, 148, 62, 0.25);
    transform: rotate(-2deg);
}
.moss-ill-3 .moss-capsule-lamp-2 {
    position: absolute; left: 47%; top: 20px;
    width: 14px; height: 18px; border-radius: 50% 50% 40% 40%;
    background: #c8943e; box-shadow: 0 0 24px rgba(200, 148, 62, 0.5), 0 0 48px rgba(200, 148, 62, 0.25);
    transform: rotate(4deg);
}
.moss-ill-3 .moss-capsule-lamp-3 {
    position: absolute; left: 64%; top: 80px;
    width: 12px; height: 15px; border-radius: 50% 50% 40% 40%;
    background: #c8943e; box-shadow: 0 0 24px rgba(200, 148, 62, 0.4), 0 0 48px rgba(200, 148, 62, 0.2);
    transform: rotate(-8deg);
}

.moss-ill-3 .spore-dot {
    position: absolute; width: 3px; height: 3px; border-radius: 50%;
    background: #c9b896; opacity: 0.55;
    box-shadow: 0 0 6px rgba(201, 184, 150, 0.4);
    animation: drift-spore 9s ease-in-out infinite;
}
.moss-ill-3 .spore-dot-1 { left: 20%; top: 20%; animation-delay: 0s; }
.moss-ill-3 .spore-dot-2 { left: 75%; top: 30%; animation-delay: 1.5s; }
.moss-ill-3 .spore-dot-3 { left: 40%; top: 15%; animation-delay: 3s; }
.moss-ill-3 .spore-dot-4 { left: 80%; top: 50%; animation-delay: 4.5s; width: 4px; height: 4px; }
.moss-ill-3 .spore-dot-5 { left: 15%; top: 50%; animation-delay: 6s; }

.moss-ill-3 .moss-leaf-1 { width: 40px; height: 14px; left: 22%; bottom: 80px; transform: rotate(-25deg); background: #6b7f4a; }
.moss-ill-3 .moss-leaf-2 { width: 44px; height: 16px; left: 42%; bottom: 80px; transform: rotate(5deg); background: #6b7f4a; }
.moss-ill-3 .moss-leaf-3 { width: 38px; height: 14px; left: 60%; bottom: 80px; transform: rotate(20deg); background: #6b7f4a; opacity: 0.65; }

@keyframes drift-spore {
    0%, 100% { transform: translate(0, 0); opacity: 0.55; }
    50% { transform: translate(6px, -14px); opacity: 0.8; }
}

/* ---- Illustration 4: Racomitrium on granite (plate 4) ---- */
.moss-ill-4 .granite-slab {
    position: absolute;
    left: 0; right: 0; bottom: 60px;
    height: 90px;
    background:
        radial-gradient(ellipse at 30% 40%, rgba(90, 74, 54, 0.22) 0%, transparent 55%),
        radial-gradient(ellipse at 70% 60%, rgba(90, 74, 54, 0.18) 0%, transparent 50%),
        #c9b896;
    clip-path: polygon(4% 30%, 18% 18%, 40% 12%, 62% 20%, 82% 14%, 96% 28%, 98% 72%, 86% 86%, 60% 94%, 32% 88%, 10% 92%, 2% 70%);
    opacity: 0.45;
}

.moss-ill-4 .moss-cushion { position: absolute; inset: 0; }

.moss-ill-4 .moss-stem-1 { left: 20%; bottom: 130px; height: 60px; transform: rotate(-15deg); background: #7a8a5c; }
.moss-ill-4 .moss-stem-2 { left: 30%; bottom: 140px; height: 70px; transform: rotate(-5deg); background: #7a8a5c; }
.moss-ill-4 .moss-stem-3 { left: 45%; bottom: 140px; height: 80px; transform: rotate(2deg); background: #7a8a5c; }
.moss-ill-4 .moss-stem-4 { left: 60%; bottom: 135px; height: 65px; transform: rotate(12deg); background: #7a8a5c; }
.moss-ill-4 .moss-stem-5 { left: 75%; bottom: 130px; height: 55px; transform: rotate(22deg); background: #7a8a5c; }

.moss-ill-4 .moss-leaf { background: #8fa66a; opacity: 0.7; }
.moss-ill-4 .moss-leaf-1 { width: 28px; height: 14px; left: 15%; bottom: 175px; transform: rotate(-30deg); }
.moss-ill-4 .moss-leaf-2 { width: 32px; height: 15px; left: 26%; bottom: 195px; transform: rotate(-10deg); }
.moss-ill-4 .moss-leaf-3 { width: 36px; height: 17px; left: 42%; bottom: 210px; transform: rotate(5deg); }
.moss-ill-4 .moss-leaf-4 { width: 32px; height: 15px; left: 56%; bottom: 195px; transform: rotate(18deg); opacity: 0.65; }
.moss-ill-4 .moss-leaf-5 { width: 28px; height: 14px; left: 70%; bottom: 175px; transform: rotate(30deg); opacity: 0.6; }
.moss-ill-4 .moss-leaf-6 { width: 22px; height: 12px; left: 38%; bottom: 160px; transform: rotate(-15deg); opacity: 0.55; }

.moss-ill-4 .moss-capsule-1 { left: 32%; top: 130px; }
.moss-ill-4 .moss-capsule-2 { left: 52%; top: 110px; width: 7px; height: 7px; }

/* ---- Illustration 5: Dicranum column (plate 5) ---- */
.moss-ill-5 .moss-column { position: absolute; inset: 0; }
.moss-ill-5 .moss-stem-1 { left: 28%; bottom: 80px; height: 150px; transform: rotate(-8deg); background: #8fa66a; }
.moss-ill-5 .moss-stem-2 { left: 38%; bottom: 80px; height: 180px; transform: rotate(-3deg); background: #8fa66a; }
.moss-ill-5 .moss-stem-3 { left: 50%; bottom: 80px; height: 210px; transform: rotate(2deg); background: #8fa66a; }
.moss-ill-5 .moss-stem-4 { left: 62%; bottom: 80px; height: 170px; transform: rotate(8deg); background: #8fa66a; }
.moss-ill-5 .moss-stem-5 { left: 72%; bottom: 80px; height: 130px; transform: rotate(15deg); background: #8fa66a; }

.moss-ill-5 .moss-leaf { background: #8fa66a; }
.moss-ill-5 .moss-leaf-1 { width: 24px; height: 12px; left: 20%; bottom: 150px; transform: rotate(-35deg); }
.moss-ill-5 .moss-leaf-2 { width: 30px; height: 14px; left: 30%; bottom: 190px; transform: rotate(-15deg); }
.moss-ill-5 .moss-leaf-3 { width: 34px; height: 16px; left: 42%; bottom: 220px; transform: rotate(0deg); }
.moss-ill-5 .moss-leaf-4 { width: 32px; height: 15px; left: 52%; bottom: 240px; transform: rotate(8deg); }
.moss-ill-5 .moss-leaf-5 { width: 30px; height: 14px; left: 58%; bottom: 210px; transform: rotate(18deg); opacity: 0.6; }
.moss-ill-5 .moss-leaf-6 { width: 28px; height: 13px; left: 66%; bottom: 180px; transform: rotate(28deg); opacity: 0.6; }
.moss-ill-5 .moss-leaf-7 { width: 24px; height: 12px; left: 74%; bottom: 150px; transform: rotate(38deg); opacity: 0.55; }

.moss-ill-5 .moss-capsule { background: #c8943e; box-shadow: 0 0 24px rgba(200, 148, 62, 0.4); }
.moss-ill-5 .moss-capsule-1 { left: 28%; top: 60px; }
.moss-ill-5 .moss-capsule-2 { left: 40%; top: 30px; width: 9px; height: 9px; }
.moss-ill-5 .moss-capsule-3 { left: 52%; top: 10px; width: 10px; height: 10px; }
.moss-ill-5 .moss-capsule-4 { left: 66%; top: 70px; width: 7px; height: 7px; }

/* ------------------------- Bokeh layer ---------------------------------- */
.bokeh-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.bokeh-circle {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at center, rgba(200, 148, 62, 0.12) 0%, rgba(200, 148, 62, 0.06) 45%, transparent 72%);
    opacity: 0;
    transition: opacity 1400ms ease-out;
    will-change: transform, opacity;
    animation: bokeh-drift 12s ease-in-out infinite alternate;
}

.bokeh-layer.active .bokeh-circle {
    opacity: 1;
}

.bokeh-cool .bokeh-circle {
    background: radial-gradient(circle at center, rgba(107, 127, 74, 0.18) 0%, rgba(107, 127, 74, 0.08) 50%, transparent 75%);
}

.bokeh-dense .bokeh-circle {
    /* nothing special; overridden by per-circle inline */
}

@keyframes bokeh-drift {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(8px, -18px, 0); }
}

/* ------------------------- Plate divider -------------------------------- */
.plate-divider {
    position: absolute;
    bottom: 42px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    pointer-events: none;
}

.plate-divider svg {
    width: 240px;
    height: 24px;
    display: block;
}

/* ------------------------- Corner ornaments ----------------------------- */
.corner-ornament {
    position: absolute;
    width: 60px;
    height: 60px;
    pointer-events: none;
    z-index: 3;
}

.corner-ornament svg {
    width: 100%;
    height: 100%;
    display: block;
}

.corner-tl { top: 32px; left: 32px; }
.corner-tr { top: 32px; right: 32px; }
.corner-bl { bottom: 32px; left: 32px; }
.corner-br { bottom: 32px; right: 32px; }

/* ------------------------- Closing plate -------------------------------- */
.plate-closing {
    min-height: 100vh;
}

.closing-content {
    text-align: center;
    max-width: 640px;
    padding: 0 32px;
}

.closing-line {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    line-height: 1.4;
    color: #8a7a64;
    margin-bottom: 48px;
    letter-spacing: 0.01em;
}

.closing-ornament {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
}

.closing-ornament svg {
    width: 200px;
    height: 24px;
}

.colophon {
    font-family: 'Jost', sans-serif;
    font-size: 12px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #c9b896;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
}

.colophon-han {
    font-family: 'Cormorant Garamond', 'Lora', serif;
    font-style: italic;
    font-size: 14px;
    text-transform: none;
    letter-spacing: 0.04em;
    color: #8a7a64;
}

.colophon-sep {
    color: #c9b896;
    opacity: 0.6;
}

/* ------------------------- Reveal animations ---------------------------- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 600ms cubic-bezier(0.23, 1, 0.32, 1),
                transform 600ms cubic-bezier(0.23, 1, 0.32, 1);
    will-change: transform, opacity;
}

.reveal[data-reveal="body"],
.reveal[data-reveal="list"],
.reveal[data-reveal="tag"],
.reveal[data-reveal="code"] {
    transform: translateY(20px);
}

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

/* Link styling (for any inline anchors inside bodies) */
a {
    color: #c8943e;
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-thickness: 1px;
    transition: color 220ms ease, text-decoration-thickness 220ms ease;
}

a:hover {
    color: #d4a44a;
    text-decoration-thickness: 2px;
}

.plate-dark a {
    color: #d4a44a;
}

/* ------------------------- Responsive ----------------------------------- */
@media (max-width: 1100px) {
    .plate-inner {
        grid-template-columns: 8% minmax(0, 520px) 1fr;
        grid-column-gap: 32px;
    }
    .plate-specimen {
        padding-left: 24px;
        padding-right: 24px;
    }
    .moss-illustration {
        max-width: 280px;
        height: 340px;
    }
}

@media (max-width: 900px) {
    .plate-inner {
        grid-template-columns: 8% 1fr;
        grid-column-gap: 24px;
    }
    .plate-content {
        grid-column: 2 / 3;
    }
    .plate-specimen {
        grid-column: 2 / 3;
        padding-left: 0;
        padding-right: 0;
        margin-top: 48px;
        min-height: 320px;
    }
    .moss-illustration {
        margin-left: 0;
        max-width: 320px;
        height: 320px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        width: 260px;
    }
    .sidebar.open {
        transform: translateX(0);
    }
    .sidebar-toggle {
        display: block;
    }
    .main {
        margin-left: 0;
    }
    .plate {
        padding: 96px 24px 84px 24px;
    }
    .plate-inner {
        grid-template-columns: 1fr;
        grid-column-gap: 0;
    }
    .plate-content,
    .plate-specimen {
        grid-column: 1 / 2;
    }
    .plate-specimen {
        padding-left: 0;
        padding-right: 0;
        margin-top: 32px;
    }
    .title-main {
        font-size: clamp(2.5rem, 10vw, 4rem);
    }
    .plate-heading {
        font-size: clamp(1.75rem, 7vw, 3rem);
    }
    .corner-ornament {
        width: 40px;
        height: 40px;
    }
    .corner-tl, .corner-tr { top: 16px; }
    .corner-bl, .corner-br { bottom: 16px; }
    .corner-tl, .corner-bl { left: 16px; }
    .corner-tr, .corner-br { right: 16px; }
}

@media (max-width: 480px) {
    .pullquote {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .pullquote-sprig-right {
        align-self: flex-start;
    }
    .colophon {
        gap: 8px;
        font-size: 11px;
    }
}
