@import url('https://fonts.googleapis.com/css2?family=IM+Fell+English&family=Zen+Maru+Gothic:wght@300;400;700&display=swap');

:root {
    /* Palette */
    --bg-paper: #f4f1ea;
    --bg-warm-gray: #e8e6e1;
    --bg-charcoal: #1a1a1a;

    --text-main: #2b2b2b;
    --text-faint: #888888;
    --text-light: #f4f1ea;

    /* Accents */
    --acc-blood: #8a3324;
    --acc-purple: #7a6a8f;
    --acc-teal: #5f8a8b;
    --acc-yellow: #d4b483;

    /* Spacing */
    --spacing-loose: 12vh;
    --spacing-tight: 2rem;
}

* {
    box-sizing: border-box;
}

body {
    background-color: var(--bg-paper);
    color: var(--text-main);
    font-family: 'Zen Maru Gothic', sans-serif;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    line-height: 1.8;
    font-size: 16px;
    transition: background-color 1s ease;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: 'IM Fell English', serif;
    font-weight: 400;
    margin: 0;
    line-height: 1.1;
}

h1 {
    font-size: 4rem;
    color: var(--acc-blood);
    letter-spacing: -2px;
}

h2 {
    font-size: 2.5rem;
    color: var(--bg-charcoal);
}

a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease, color 0.3s ease;
}

a:hover {
    border-bottom: 1px solid var(--acc-blood);
    color: var(--acc-blood);
}

/* Layout Utilities */
.floating-section {
    position: relative;
    max-width: 800px;
    /* Constraints reading width but allows free positioning */
    margin: var(--spacing-loose) 5vw;
    padding: 2rem;
}

.floating-section:nth-child(even) {
    margin-left: auto;
    /* Push to right */
    margin-right: 15vw;
    text-align: right;
}

.floating-section:nth-child(odd) {
    margin-left: 10vw;
    text-align: left;
}

.offset-text {
    display: inline-block;
    transform: translateY(10px);
}

.vertical-text {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    position: absolute;
    right: -2rem;
    top: 0;
    font-size: 1.5rem;
    color: var(--acc-purple);
    opacity: 0.7;
}

/* Specific Sections */
#intro-scene {
    margin-top: 20vh;
}

.intro-text {
    font-size: 1.4rem;
    max-width: 500px;
    margin-top: 2rem;
}

.status-badge {
    font-size: 0.9rem;
    font-family: 'IM Fell English', serif;
    color: var(--acc-teal);
    border: 1px solid var(--acc-teal);
    padding: 0.2rem 0.5rem;
    display: inline-block;
    margin-bottom: 1rem;
    transform: rotate(-2deg);
}

/* Quotes */
.quote-container {
    font-size: 2rem;
    font-family: 'IM Fell English', serif;
    color: var(--text-faint);
    max-width: 60%;
    margin: 0 auto;
    text-align: center;
}

/* Projects */
.project-list {
    display: flex;
    flex-direction: column;
    gap: 4rem;
}

.project-item {
    display: block;
    position: relative;
    transition: transform 0.3s ease;
}

.project-item:hover {
    transform: translateX(10px);
}

.project-title {
    font-size: 2rem;
    display: block;
    color: var(--bg-charcoal);
}

.project-desc {
    font-size: 1rem;
    color: var(--acc-purple);
    font-style: italic;
}

/* Logs */
.log-list {
    list-style: none;
    padding: 0;
}

.log-item {
    margin-bottom: 1.5rem;
}

.log-link {
    font-size: 1.5rem;
    color: var(--acc-blood);
}

/* Stream / Tumblr */
#tumblr-posts {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    justify-content: center;
}

.tumblr-post {
    width: 300px;
    background: #fff;
    padding: 1.5rem;
    box-shadow: 5px 5px 0px var(--acc-yellow);
    border: 1px solid var(--text-main);
    font-size: 0.9rem;
    text-align: left;
    /* Reset text align */
}

.tumblr-post img {
    filter: grayscale(100%);
    transition: filter 0.5s ease;
}

.tumblr-post:hover img {
    filter: grayscale(0%);
}

.post-meta {
    font-size: 0.8rem;
    color: var(--acc-teal);
    margin-bottom: 0.5rem;
    font-family: monospace;
}

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 1.5s ease, transform 1.5s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Decorations */
.scribble {
    position: absolute;
    z-index: -1;
    pointer-events: none;
    opacity: 0.5;
}

.scribble-1 {
    top: -50px;
    left: -50px;
    width: 200px;
}

.circle-shape {
    position: absolute;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background-color: var(--acc-yellow);
    opacity: 0.2;
    z-index: -1;
    filter: blur(40px);
}

/* UI Elements */
button {
    background: transparent;
    border: none;
    font-family: 'IM Fell English', serif;
    font-size: 1.2rem;
    cursor: pointer;
    border-bottom: 2px solid var(--acc-blood);
    padding-bottom: 2px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(244, 241, 234, 0.95);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    width: 90%;
    max-width: 500px;
    padding: 2rem;
    border: 1px solid var(--text-main);
    background: var(--bg-paper);
    box-shadow: 10px 10px 0 var(--acc-blood);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {

    .floating-section,
    .floating-section:nth-child(even),
    .floating-section:nth-child(odd) {
        margin: 5rem 1rem;
        text-align: left;
        /* Reset alignment for mobile readability */
        max-width: 100%;
    }

    h1 {
        font-size: 3rem;
    }

    .vertical-text {
        display: none;
        /* Hide vertical decorations on tiny screens */
    }
}