:root {
    --primary: #6c5ce7;
    --text-main: #1a1a1a;
    --bg-color: #f8f9fa;
    --glass: rgba(255, 255, 255, 0.8);
    --card-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

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

body.dark-mode {
    --text-main: #f4f4f5;
    --bg-color: #0d0d0d;
    --glass: rgba(25, 25, 25, 0.9);
    --card-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    transition: all 0.4s ease;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

#theme-toggle {
    position: fixed; top: 20px; right: 20px; z-index: 3000;
    padding: 10px 20px; border-radius: 50px;
    border: 1px solid var(--primary); background: var(--glass);
    color: var(--text-main); font-weight: 600; cursor: pointer;
}

/* NAVIGATION - Still has hover pop */
.navbar { padding: 30px 0; background: var(--bg-color); }
.navbar-brand { 
    font-weight: 800; letter-spacing: 4px; font-size: 1.8rem; 
    color: var(--text-main) !important; text-decoration: none;
    transition: transform 0.3s ease;
    display: inline-block;
}
.navbar-brand:hover { transform: scale(1.05); color: var(--primary) !important; }

.nav-link-sub {
    font-weight: 600; font-size: 0.7rem; letter-spacing: 2px;
    color: var(--text-main) !important; text-decoration: none;
    opacity: 0.5; transition: 0.3s;
    display: inline-block;
}
.nav-link-sub:hover { opacity: 1; transform: scale(1.1); color: var(--primary) !important; }

/* BENTO CARDS - Removed Hover Jump */
.bento-card {
    background: var(--glass);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    padding: 2.5rem;
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: var(--card-shadow);
    text-decoration: none; color: inherit;
    display: block;
    transition: border 0.3s ease, box-shadow 0.3s ease;
}
.bento-card:hover {
    border: 1px solid var(--primary);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

/* MLA FORMATTING */
.mla-format {
    text-align: left;
    line-height: 2;
    font-family: 'Times New Roman', serif;
    background: white;
    color: black;
    border-radius: 8px;
    font-size: 0.95rem;
    padding: 40px 60px;
    margin: 20px auto;
    max-width: 95%;
}

body.dark-mode .mla-format {
    background: #1a1a1a;
    color: #f4f4f5;
    border: 1px solid #333;
}

.revision-mark {
    background-color: var(--primary);
    color: white; padding: 2px 8px; border-radius: 4px;
}

.scroll-watcher {
    position: fixed; top: 0; width: 100%; height: 4px;
    background: var(--primary); z-index: 4000;
    transform-origin: left; scale: 0 1;
    animation: scroll-progress linear;
    animation-timeline: scroll();
}

html {
    scroll-behavior: smooth;
}

/* Subtle reveal animation for sections */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

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

@keyframes scroll-progress { to { scale: 1 1; } }

@media (max-width: 768px) {
    .mla-format { padding: 20px 25px; }
}