/* ===== tanso.news — Fairycore Carbon News ===== */

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

/* Palette */
:root {
    --morning-mist: #f0f4f0;
    --deep-forest: #2d4a2d;
    --sage-fern: #6b8f71;
    --soft-lavender: #9b8ea8;
    --dawn-pink: #e8d5f0;
    --spring-mint: #c8e6c9;
    --fairy-teal: #06d6a0;
    --charcoal: #4a4a4a;
}

body {
    font-family: 'Lora', Georgia, serif;
    background-color: var(--morning-mist);
    color: var(--charcoal);
    position: relative;
    overflow-x: hidden;
}

/* Fairy circle background */
#fairy-bg {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background-image: radial-gradient(circle, var(--sage-fern) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.04;
}

/* ===== Masthead ===== */
#masthead {
    position: relative;
    z-index: 10;
    background: var(--morning-mist);
    padding: 20px 0 0;
    text-align: center;
}

.masthead-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

.masthead-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.edition-label,
.edition-date {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--soft-lavender);
}

.site-title {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    font-size: 64px;
    color: var(--deep-forest);
    letter-spacing: -1px;
    margin-bottom: 16px;
}

.title-dot {
    color: var(--fairy-teal);
}

.main-nav {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-bottom: 16px;
}

.nav-link {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--charcoal);
    text-decoration: none;
    padding: 4px 0;
    border-bottom: 2px solid transparent;
    transition: color 0.3s, border-color 0.3s;
}

.nav-link:hover,
.nav-link.active {
    color: var(--sage-fern);
    border-bottom-color: var(--sage-fern);
}

/* Vine dividers */
.vine-divider {
    display: block;
    width: 100%;
    height: 30px;
}

.vine-path {
    stroke-dasharray: 1200;
    stroke-dashoffset: 1200;
    animation: drawVine 2s ease forwards;
}

@keyframes drawVine {
    to { stroke-dashoffset: 0; }
}

.vine-leaf {
    opacity: 0;
    animation: fadeLeaf 0.5s ease forwards;
}
.vine-leaf:nth-child(2) { animation-delay: 0.8s; }
.vine-leaf:nth-child(3) { animation-delay: 1.2s; }
.vine-leaf:nth-child(4) { animation-delay: 1.6s; }
.vine-leaf:nth-child(5) { animation-delay: 2.0s; }

@keyframes fadeLeaf {
    to { opacity: 1; }
}

.vine-divider-sm {
    display: block;
    width: 100%;
    height: 15px;
    margin-bottom: 12px;
}

/* ===== Breaking News Bar ===== */
.breaking-bar {
    position: relative;
    z-index: 10;
    background: linear-gradient(90deg, var(--deep-forest), #3a5e3a);
    color: var(--morning-mist);
    padding: 10px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    max-width: 1100px;
    margin: 0 auto;
    border-radius: 4px;
}

.breaking-bar.shake {
    animation: shake 0.4s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-10px); }
    40% { transform: translateX(10px); }
    60% { transform: translateX(-8px); }
    80% { transform: translateX(8px); }
}

.breaking-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 2px;
    background: var(--fairy-teal);
    color: var(--deep-forest);
    padding: 3px 10px;
    border-radius: 3px;
    flex-shrink: 0;
}

.breaking-text {
    font-family: 'Lora', serif;
    font-size: 14px;
    line-height: 1.4;
}

/* ===== Content Grid ===== */
#content {
    position: relative;
    z-index: 5;
    max-width: 1100px;
    margin: 40px auto;
    padding: 0 24px;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 48px;
}

/* ===== Editorial Column ===== */
.editorial-column {
    max-width: 680px;
}

.article {
    margin-bottom: 40px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.6s ease forwards;
}

.article:nth-child(1) { animation-delay: 0.1s; }
.article:nth-child(3) { animation-delay: 0.2s; }
.article:nth-child(5) { animation-delay: 0.3s; }
.article:nth-child(7) { animation-delay: 0.4s; }
.article:nth-child(9) { animation-delay: 0.5s; }

@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}

/* Article thumbnails — 3D pseudo-render */
.article-thumb {
    width: 100%;
    height: 180px;
    border-radius: 8px;
    margin-bottom: 16px;
    overflow: hidden;
    position: relative;
}

.mushroom-thumb {
    background: linear-gradient(135deg, var(--dawn-pink), var(--spring-mint));
}

.thumb-3d.mushroom {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 60px;
    background: radial-gradient(ellipse at 50% 30%, var(--soft-lavender), var(--deep-forest));
    border-radius: 50% 50% 10% 10%;
    box-shadow: 0 8px 24px rgba(45, 74, 45, 0.3), inset 0 -10px 20px rgba(0,0,0,0.15);
}
.thumb-3d.mushroom::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 16px;
    height: 24px;
    background: linear-gradient(to bottom, var(--spring-mint), var(--sage-fern));
    border-radius: 4px;
}

.crystal-thumb {
    background: linear-gradient(135deg, var(--spring-mint), var(--dawn-pink));
}

.thumb-3d.crystal {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) rotate(-5deg);
    width: 40px;
    height: 80px;
    background: linear-gradient(160deg, rgba(6,214,160,0.6), rgba(155,142,168,0.4));
    clip-path: polygon(50% 0%, 100% 35%, 85% 100%, 15% 100%, 0% 35%);
    box-shadow: 0 4px 20px rgba(6,214,160,0.3);
}
.thumb-3d.crystal::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 10px;
    width: 30px;
    height: 65px;
    background: linear-gradient(160deg, rgba(155,142,168,0.5), rgba(200,230,201,0.3));
    clip-path: polygon(50% 0%, 100% 30%, 80% 100%, 20% 100%, 0% 30%);
}

.leaf-thumb {
    background: linear-gradient(135deg, #c8e6c9, #e8d5f0);
}

.thumb-3d.leaf {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%) rotate(15deg);
    width: 70px;
    height: 90px;
    background: radial-gradient(ellipse at 40% 30%, var(--sage-fern), var(--deep-forest));
    border-radius: 50% 50% 50% 0%;
    box-shadow: 0 6px 20px rgba(45,74,45,0.25);
}
.thumb-3d.leaf::after {
    content: '';
    position: absolute;
    top: 20%;
    left: 45%;
    width: 2px;
    height: 60%;
    background: rgba(255,255,255,0.3);
    transform: rotate(-10deg);
}

/* Article meta */
.article-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.category-tag {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--sage-fern);
    background: var(--spring-mint);
    padding: 3px 10px;
    border-radius: 3px;
}

.category-tag.policy { background: var(--dawn-pink); color: var(--soft-lavender); }
.category-tag.tech { background: rgba(6,214,160,0.15); color: #05a87e; }
.category-tag.offsets { background: rgba(155,142,168,0.15); color: var(--soft-lavender); }

.timestamp {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 12px;
    color: var(--soft-lavender);
}

.article-title {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 32px;
    line-height: 1.25;
    color: var(--deep-forest);
    margin-bottom: 16px;
}

.featured .article-title {
    font-size: 42px;
}

.article-body {
    font-family: 'Lora', serif;
    font-size: 19px;
    line-height: 1.8;
    color: var(--charcoal);
    margin-bottom: 16px;
}

/* Drop cap */
.drop-cap {
    float: left;
    font-family: 'Playfair Display', serif;
    font-size: 4em;
    line-height: 0.8;
    padding-right: 8px;
    color: var(--deep-forest);
}

.byline {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 12px;
    color: var(--soft-lavender);
    letter-spacing: 0.5px;
}

/* Fish dividers */
.fish-divider {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 32px 0;
    opacity: 0.7;
}

.fish-svg {
    width: 50px;
    height: 20px;
    animation: fishSwim 4s ease-in-out infinite;
}

.fish-flip {
    transform: scaleX(-1);
}

@keyframes fishSwim {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(8px); }
}

.fish-flip {
    animation-name: fishSwimFlip;
}

@keyframes fishSwimFlip {
    0%, 100% { transform: scaleX(-1) translateX(0); }
    50% { transform: scaleX(-1) translateX(8px); }
}

/* ===== Sidebar ===== */
.sidebar {
    position: sticky;
    top: 24px;
    align-self: start;
}

.sidebar-section {
    margin-bottom: 36px;
    background: rgba(232,213,240,0.15);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(155,142,168,0.15);
}

.sidebar-heading {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 20px;
    color: var(--deep-forest);
    margin-bottom: 8px;
}

/* Market ticker */
.market-ticker {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ticker-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid rgba(107,143,113,0.12);
}

.ticker-item:last-child {
    border-bottom: none;
}

.ticker-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 12px;
    color: var(--charcoal);
}

.ticker-value {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 13px;
}

.ticker-value.up { color: var(--sage-fern); }
.ticker-value.down { color: #c0392b; }

.ticker-change {
    font-size: 11px;
    font-weight: 400;
}

/* Spore notes */
.spore-notes {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.spore-note {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.spore-icon {
    font-size: 18px;
    flex-shrink: 0;
    margin-top: 2px;
}

.spore-note p {
    font-family: 'Lora', serif;
    font-size: 14px;
    line-height: 1.5;
    color: var(--charcoal);
}

/* Canopy links */
.canopy-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.canopy-link {
    font-family: 'Lora', serif;
    font-size: 14px;
    line-height: 1.4;
    color: var(--sage-fern);
    text-decoration: none;
    padding: 6px 0;
    border-bottom: 1px solid rgba(107,143,113,0.1);
    transition: color 0.3s;
}

.canopy-link:hover {
    color: var(--deep-forest);
}

/* ===== Footer ===== */
#footer {
    position: relative;
    z-index: 5;
    margin-top: 60px;
    padding: 0 24px;
}

.footer-vine {
    margin-bottom: 24px;
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
    padding-bottom: 40px;
}

.footer-title {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    font-size: 28px;
    color: var(--deep-forest);
}

.footer-tagline {
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: 14px;
    color: var(--soft-lavender);
    margin-top: 4px;
    margin-bottom: 20px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-bottom: 20px;
}

.footer-links a {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--sage-fern);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--deep-forest);
}

.footer-copy {
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    color: var(--soft-lavender);
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .content-grid {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: static;
    }
    .site-title {
        font-size: 48px;
    }
    .featured .article-title {
        font-size: 32px;
    }
    .article-title {
        font-size: 26px;
    }
}

@media (max-width: 600px) {
    .masthead-top {
        flex-direction: column;
        gap: 4px;
    }
    .main-nav {
        flex-wrap: wrap;
        gap: 16px;
    }
    .site-title {
        font-size: 36px;
    }
    .article-body {
        font-size: 17px;
    }
}
