:root[data-theme="mocha"] {
    --base: #1e1e2e;
    --mantle: #181825;
    --crust: #11111b;
    --text: #cdd6f4;
    --subtext0: #a6adc8;
    --subtext1: #bac2de;
    --surface0: #313244;
    --surface1: #45475a;
    --surface2: #585b70;
    --overlay0: #6c7086;
    --blue: #89b4fa;
    --lavender: #b4befe;
    --sapphire: #74c7ec;
    --sky: #89dceb;
    --teal: #94e2d5;
    --green: #a6e3a1;
    --yellow: #f9e2af;
    --peach: #fab387;
    --maroon: #eba0ac;
    --red: #f38ba8;
    --mauve: #cba6f7;
    --pink: #f5c2e7;
    --flamingo: #f2cdcd;
    --rosewater: #f5e0dc;
}

:root[data-theme="latte"] {
    --base: #eff1f5;
    --mantle: #e6e9ef;
    --crust: #dce0e8;
    --text: #4c4f69;
    --subtext0: #6c6f85;
    --subtext1: #5c5f77;
    --surface0: #ccd0da;
    --surface1: #bcc0cc;
    --surface2: #acb0be;
    --overlay0: #9ca0b0;
    --blue: #1e66f5;
    --lavender: #7287fd;
    --sapphire: #209fb5;
    --sky: #04a5e5;
    --teal: #179299;
    --green: #40a02b;
    --yellow: #df8e1d;
    --peach: #fe640b;
    --maroon: #e64553;
    --red: #d20f39;
    --mauve: #8839ef;
    --pink: #ea76cb;
    --flamingo: #dd7878;
    --rosewater: #dc8a78;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--base);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 2rem;
    overflow-x: hidden;
}

.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, var(--surface0) 0%, var(--base) 100%);
    z-index: -1;
    opacity: 0.5;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(4, minmax(100px, auto));
    gap: 1.5rem;
    max-width: 1200px;
    width: 100%;

    flex: 1 1 auto;
}

.card {
    background-color: var(--mantle);
    border: 1px solid var(--surface0);
    border-radius: 1.5rem;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border-color: var(--mauve);
}

h1,
h2,
h3 {
    font-family: 'JetBrains Mono', monospace;
    color: var(--mauve);
    margin-bottom: 0.5rem;
}

p {
    color: var(--subtext0);
    line-height: 1.6;
}

.profile-card {
    grid-column: span 2;
    grid-row: span 2;
    justify-content: space-between;
    background: linear-gradient(145deg, var(--mantle), var(--crust));
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.avatar-container {
    position: relative;
}

.avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid var(--blue);
}

.status-indicator {
    position: absolute;
    bottom: 5px;
    right: 5px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 3px solid var(--mantle);
    background-color: var(--overlay0);
}

.status-indicator.online {
    background-color: var(--green);
}

.status-indicator.idle {
    background-color: var(--yellow);
}

.status-indicator.dnd {
    background-color: var(--red);
}

.status-indicator.offline {
    background-color: var(--overlay0);
}

.tagline {
    font-size: 1.1rem;
    color: var(--subtext1);
}

.bio-card {
    grid-column: span 2;
    grid-row: span 1;
}

.socials-card {
    grid-column: span 1;
    grid-row: span 2;
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.social-btn {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    text-decoration: none;
    color: var(--text);
    padding: 0.8rem;
    border-radius: 0.8rem;
    background-color: var(--surface0);
    transition: background-color 0.2s, color 0.2s;
}

.social-btn:hover {
    background-color: var(--surface1);
    color: var(--blue);
}

.social-btn.discord:hover {
    color: #5865F2;
}

.social-btn.github:hover {
    color: var(--text);
}

.social-btn.steam:hover {
    color: #171a21;
    background-color: #66c0f4;
}

.social-btn.spotify:hover {
    color: #1DB954;
}

.skills-card {
    grid-column: span 1;
    grid-row: span 2;
}

.skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 1rem;
}

.skill-item {
    background-color: var(--surface0);
    padding: 0.5rem 0.8rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.skill-item i {
    color: var(--yellow);
}

.projects-card {
    grid-column: span 2;
    grid-row: span 2;
}

.projects-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-top: 1rem;
}

.project-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background-color: var(--surface0);
    border-radius: 1rem;
    text-decoration: none;
    color: var(--text);
    transition: background-color 0.2s, transform 0.2s;
}

.project-item:hover {
    background-color: var(--surface1);
    transform: translateX(5px);
}

.project-icon {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--mauve), var(--blue));
    border-radius: 0.8rem;
    font-size: 1.2rem;
    color: var(--base);
    flex-shrink: 0;
}

.project-info {
    flex: 1;
}

.project-info h3 {
    font-size: 1rem;
    margin-bottom: 0.2rem;
    color: var(--text);
}

.project-info p {
    font-size: 0.85rem;
    color: var(--subtext0);
    line-height: 1.3;
}

.project-link-icon {
    color: var(--overlay0);
    font-size: 0.9rem;
    transition: color 0.2s;
}

.project-item:hover .project-link-icon {
    color: var(--blue);
}

.timeline-card {
    grid-column: span 2;
    grid-row: span 2;
    overflow-y: auto;
}

.timeline {
    margin-top: 1rem;
    border-left: 2px solid var(--surface1);
    padding-left: 1.5rem;
}

.timeline-item {
    margin-bottom: 1.5rem;
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -1.9rem;
    top: 0.3rem;
    width: 12px;
    height: 12px;
    background-color: var(--blue);
    border-radius: 50%;
    border: 2px solid var(--base);
}

.timeline-item .date {
    font-size: 0.85rem;
    color: var(--overlay0);
    margin-bottom: 0.3rem;
}

.bigrat-card {
    grid-column: span 1;
    grid-row: span 1;
    background: var(--red);
    color: var(--base);
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    cursor: pointer;
    border: none;
}

.bigrat-card:hover {
    background: var(--maroon);
    transform: scale(1.02);
}

.bigrat-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    font-weight: bold;
    font-size: 1.2rem;
}

.toggle-card {
    grid-column: span 1;
    grid-row: span 1;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    font-size: 2rem;
    color: var(--yellow);
}

.toggle-card .moon-icon {
    display: none;
}

[data-theme="latte"] .toggle-card .sun-icon {
    display: none;
}

[data-theme="latte"] .toggle-card .moon-icon {
    display: block;
    color: var(--blue);
}

.time-card {
    grid-column: span 1;
    grid-row: span 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: var(--surface0);
}

.time-display {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text);
    font-family: 'JetBrains Mono', monospace;
}

.date-display {
    color: var(--subtext0);
}

@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .profile-card {
        grid-column: span 3;
    }

    .bio-card {
        grid-column: span 3;
    }

    .timeline-card {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .bento-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .card {
        grid-column: span 1 !important;
        grid-row: span 1 !important;
    }

    body {
        padding: 1rem;
    }
}

.site-footer {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    width: 100%;
    padding: 0; /* reset any left padding */
}
.site-footer .footer-inner {
    color: var(--subtext0);
    font-size: 0.9rem;
    display: flex;
    gap: 0.5rem;
    align-items: center;
    max-width: 1200px;
    width: 100%;
    padding: 0.8rem 1rem; /* match card padding style */
    justify-content: center; /* center content inside container */
    margin: 0 auto;
    background: linear-gradient(145deg, var(--mantle), var(--crust));
    border: 1px solid var(--surface0);
    border-radius: 1rem;
    box-shadow: 0 6px 24px rgba(0,0,0,0.12);
}
.site-footer a {
    color: var(--text);
    text-decoration: underline dotted;
}
.site-footer .sep { color: var(--overlay0); margin: 0 0.25rem; }