/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: #222;
    scroll-behavior: smooth;
    background-color: #fff;
    transition: background-color 0.4s ease, color 0.4s ease;
    padding-top: 4.5rem;
    padding-bottom: 0;
    overflow-x: hidden;
}

@media (max-width: 768px) {
    body {
        padding-top: 4rem;
        /* For cat at top */
        padding-bottom: 6rem;
        /* Space for bottom navbar */
    }
}

/* Dark Mode Styles */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

body.dark-mode #navbar {
    background-color: rgba(18, 18, 18, 0.8);
}

body.dark-mode #navbar a {
    color: #b0b0b0;
}

body.dark-mode #navbar a:hover,
body.dark-mode #navbar a.active {
    color: #ffffff;
}

body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3 {
    color: #ffffff;
}

body.dark-mode p {
    color: #cccccc;
}

body.dark-mode .timeline-item::before {
    background-color: #ffffff;
}

body.dark-mode .project-link {
    color: #ffffff;
}

body.dark-mode .hobby-title {
    color: #ffffff;
}

body.dark-mode input,
body.dark-mode textarea {
    color: #f2f2f2;
}

/* Theme Toggle Button */
#theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    align-self: center;
}

#theme-toggle:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

body.dark-mode #theme-toggle:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.theme-icon {
    transition: transform 0.4s ease;
}

#theme-toggle:hover .theme-icon {
    transform: rotate(20deg);
}

body.dark-mode #theme-toggle .theme-icon {
    color: #ffd700;
}

/* Navigation */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0;
    z-index: 1000;
    height: 4.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#navbar ul {
    display: flex;
    justify-content: center;
    list-style: none;
    gap: 1.65rem;
    margin: 0 auto;
    width: 100%;
    max-width: 800px;
    padding: 0 1.5rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: #666;
    font-weight: 400;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    position: relative;
    padding: 0.5rem 0;
}

.nav-icon {
    display: none;
}

#navbar a:hover,
#navbar a.active {
    color: #000;
}

/* Mobile Navbar - Floating Bottom Dock */
@media (max-width: 768px) {
    #navbar {
        top: auto;
        bottom: 2rem;
        left: 50%;
        transform: translateX(-50%);
        width: calc(100% - 2rem);
        max-width: 500px;
        height: 4.2rem;
        border-radius: 2.1rem;
        border: 1px solid rgba(0, 0, 0, 0.1);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
        padding: 0 1rem;
    }

    #navbar ul {
        gap: 0;
        justify-content: space-around;
        padding: 0;
    }

    .nav-icon {
        display: block;
        width: 22px;
        height: 22px;
    }

    .nav-text {
        font-size: 0.65rem;
        font-weight: 500;
    }

    #navbar a.active::after {
        display: none;
    }

    #navbar a.active {
        color: #000;
        background: rgba(0, 0, 0, 0.05);
        padding: 0.6rem 0.8rem;
        border-radius: 1.5rem;
    }

    body.dark-mode #navbar a.active {
        color: #fff;
        background: rgba(255, 255, 255, 0.1);
    }
}

@media (max-width: 480px) {
    #navbar {
        bottom: 1.5rem;
        width: calc(100% - 1.5rem);
        height: 4.2rem;
    }

    .nav-text {
        display: none;
    }

    #navbar {
        padding: 0 0.5rem;
    }
}

#toggle-music {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.6rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

#toggle-music svg {
    color: #333;
    transition: color 0.3s ease;
}

#toggle-music:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

body.dark-mode #toggle-music svg {
    color: #b0b0b0;
}

body.dark-mode #toggle-music:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode #toggle-music:hover svg {
    color: #ffffff;
}

.music-playing #toggle-music svg {
    color: #007acc;
}

/* Vinyl Player Styles */
.music-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.vinyl-icon {
    transition: all 0.5s ease;
}

.record-body {
    transform-origin: 12px 12px;
}

.stylus-arm {
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-origin: 21px 3px;
}

/* Animation when music is playing */
.music-playing .record-body {
    animation: vinyl-spin 2s linear infinite;
}

.music-playing .stylus-arm {
    transform: rotate(15deg);
    color: #007acc;
}

@keyframes vinyl-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Dark mode adjustments */
body.dark-mode .vinyl-icon {
    color: #b0b0b0;
}

body.dark-mode .music-playing .vinyl-icon {
    color: #4db8ff;
}

/* ASCII Cat Original Style */
.ascii-cat {
    position: absolute;
    left: max(1.5rem, calc((100vw - 1180px) / 2 + 1.5rem));
    top: 50%;
    transform: translateY(-50%);
    font-family: monospace;
    font-size: 0.8rem;
    line-height: 1;
    color: #000;
    z-index: 1001;
    pointer-events: none;
    white-space: pre;
    transition: color 0.4s ease;
}

.floating-cat {
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0% {
        transform: translateY(-50%) translateX(0);
    }

    50% {
        transform: translateY(-50%) translateX(2px);
    }

    100% {
        transform: translateY(-50%) translateX(0);
    }
}

body.dark-mode .ascii-cat {
    color: #e0e0e0;
}

.mobile-only {
    display: none;
}

@media (max-width: 768px) {
    .navbar-only {
        display: none;
    }

    .mobile-only {
        display: block;
        position: static;
        transform: none;
        margin: 0 auto 1.5rem auto;
        font-size: 1.1rem;
        text-align: left;
        width: fit-content;
        pointer-events: auto;
    }

    @keyframes moveUp {
        0% {
            transform: translateY(0);
        }

        50% {
            transform: translateY(-8px);
        }

        100% {
            transform: translateY(0);
        }
    }

    .mobile-only.floating-cat {
        animation: moveUp 2.5s ease-in-out infinite;
    }
}

/* Sections */
.section {
    min-height: auto;
    padding: 4.5rem 1rem 2.5rem;
    display: flex;
    align-items: flex-start;
    scroll-margin-top: 5rem;
}

#intro.section {
    min-height: auto;
    padding-top: 6rem;
    padding-bottom: 4rem;
}

/* Adjust for mobile screens */
@media (max-width: 768px) {
    .section {
        min-height: auto;
        padding: 3.5rem 1rem 2rem;
        scroll-margin-top: 1rem;
        /* Space for cat at top */
    }

    #intro.section {
        min-height: auto;
        padding-top: 6rem;
        padding-bottom: 3rem;
    }
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

#intro .container {
    max-width: 1240px;
}

h1 {
    font-size: 2.8rem;
    margin-bottom: 1.5rem;
    font-weight: 400;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

h2 {
    font-size: 1.5rem;
    margin: 0 0 2.1rem;
    font-weight: 700;
    position: relative;
    letter-spacing: 0.1em;
    line-height: 1.15;
    text-transform: uppercase;
}

.intro-content {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    text-align: left;
    min-width: 0;
}

.intro-text-and-image {
    display: grid;
    grid-template-columns: minmax(0, 0.88fr) minmax(420px, 1fr);
    align-items: center;
    gap: clamp(3.5rem, 7vw, 6.5rem);
    width: 100%;
}

.intro-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    min-width: 0;
    max-width: 39rem;
}

.intro-right-gif {
    width: 100%;
    min-width: 0;
    justify-self: end;
}

.intro-mobile-gif {
    display: none;
}

.right-gif {
    width: 100%;
    max-width: 560px;
    aspect-ratio: 16 / 9;
    height: auto;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#intro h1 {
    font-size: 4rem;
    line-height: 1.08;
    margin-bottom: 1.25rem;
    white-space: nowrap;
}

#intro p {
    max-width: 33rem;
    font-size: 1.08rem;
    overflow-wrap: break-word;
}

p {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: #444;
    line-height: 1.7;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.social-link {
    color: #000;
    text-decoration: none;
    font-weight: 400;
    font-size: 0.95rem;
    padding: 0.5rem 0;
    transition: all 0.3s ease;
    position: relative;
}

.social-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #000;
    transition: width 0.3s ease;
}

.social-link:hover::after {
    width: 100%;
}

.social-link:hover {
    color: #666;
}

body.dark-mode .social-link {
    color: #e0e0e0;
}

body.dark-mode .social-link::after {
    background-color: #e0e0e0;
}

body.dark-mode .social-link:hover {
    color: #aaa;
}

.spotify-now-playing {
    width: fit-content;
    max-width: min(100%, 28rem);
    margin-top: 2rem;
    padding: 0.85rem 0;
    display: grid;
    grid-template-columns: 3.4rem minmax(0, 1fr);
    gap: 0.85rem;
    align-items: center;
    text-align: left;
    justify-self: start;
}

.spotify-now-playing[hidden] {
    display: none;
}

.spotify-album-frame {
    position: relative;
    width: 3.4rem;
    height: 3.4rem;
}

.spotify-album-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    background: linear-gradient(135deg, #191414, #1db954);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
    position: relative;
    z-index: 1;
}

.spotify-album-frame img:not([src]) {
    opacity: 0;
}

.spotify-disc {
    position: absolute;
    inset: 0.35rem -0.35rem 0.35rem 0.35rem;
    border-radius: 50%;
    background:
        radial-gradient(circle at center, #fff 0 10%, #111 11% 38%, #282828 39% 100%);
    transform: translateX(0.45rem);
    opacity: 0.16;
}

.spotify-copy {
    min-width: 0;
}

.spotify-eyebrow {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: #666;
    font-size: 0.75rem;
    line-height: 1;
    margin-bottom: 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.spotify-pulse {
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    background: #8a8a8a;
}

.spotify-now-playing[data-status="playing"] .spotify-pulse {
    background: #1db954;
    box-shadow: 0 0 0 rgba(29, 185, 84, 0.4);
    animation: spotify-pulse 1.7s ease-out infinite;
}

.spotify-track {
    display: block;
    color: #111;
    font-size: 0.98rem;
    font-weight: 600;
    line-height: 1.25;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-decoration: none;
}

.spotify-track:hover {
    color: #007acc;
}

.spotify-artist {
    color: #666;
    font-size: 0.85rem;
    line-height: 1.35;
    margin-top: 0.2rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.dark-mode .spotify-eyebrow,
body.dark-mode .spotify-artist {
    color: #bdbdbd;
}

body.dark-mode .spotify-track {
    color: #fff;
}

body.dark-mode .spotify-track:hover {
    color: #62b4ff;
}

@keyframes spotify-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(29, 185, 84, 0.42);
    }

    70% {
        box-shadow: 0 0 0 0.45rem rgba(29, 185, 84, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(29, 185, 84, 0);
    }
}

/* Timeline for experience */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.timeline-item {
    position: relative;
    padding-left: 0;
    margin-bottom: 1.5rem;
}

.timeline-date {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.2rem;
    font-weight: 500;
}

.timeline-title {
    font-size: 1.3rem;
    margin: 0.3rem 0 0.3rem;
    font-weight: 600;
    color: #000;
}

body.dark-mode .timeline-title {
    color: #fff;
}

.timeline-company {
    font-size: 1.1rem;
    color: #222;
    margin-bottom: 0.3rem;
    font-weight: 500;
}

body.dark-mode .timeline-company {
    color: #e0e0e0;
}

.timeline-location {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 0.5rem;
    font-weight: 400;
}

.timeline-summary {
    font-size: 1rem;
    color: #444;
    margin-bottom: 0.8rem;
    font-weight: 400;
}

body.dark-mode .timeline-summary {
    color: #cccccc;
}

.timeline-details {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 0.3rem;
    flex-wrap: wrap;
}

.timeline-header-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 1.2rem;
    margin-bottom: 0.5rem;
}

.company-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: 10px;
    background: #fff;
    padding: 4px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.company-logo:hover {
    transform: scale(1.05);
}

.timeline-header-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 48px;
    /* Match logo height */
}

.timeline-header-content .timeline-title {
    margin: 0;
    line-height: 1.2;
}

.timeline-header-content .timeline-company {
    margin: 2px 0 0 0;
    line-height: 1.2;
}

body.dark-mode .company-logo {
    background: #f0f0f0;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Projects grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.8rem;
}

.project-card {
    background: transparent;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: border-color 0.3s ease;
}

.project-card:last-child {
    border-bottom: none;
}

.project-card:hover {
    border-color: rgba(0, 0, 0, 0.15);
}

.project-title {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.project-description {
    color: #666;
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

.project-link {
    color: #000;
    text-decoration: none;
    font-weight: 400;
    font-size: 0.95rem;
    position: relative;
}

.project-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #000;
    transition: width 0.3s ease;
}

.project-link:hover::after {
    width: 100%;
}

/* Writing */
.section-header-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1.5rem;
    margin: 0 0 2.1rem;
}

.section-header-row h2 {
    margin: 0;
}

.writing-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.8rem;
}

.writing-card {
    display: block;
    max-width: 44rem;
    padding: 0 0 1.25rem;
    color: inherit;
    text-decoration: none;
    transition: transform 0.25s ease;
}

.writing-card:hover {
    transform: translateY(-2px);
}

.writing-card:hover .writing-title {
    color: #007acc;
}

.writing-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    color: #666;
    font-size: 0.85rem;
    margin-bottom: 0.55rem;
}

.writing-meta span + span::before {
    content: '/';
    margin-right: 0.7rem;
    color: #999;
}

.writing-title {
    font-size: 1.35rem;
    line-height: 1.3;
    margin-bottom: 0.55rem;
    font-weight: 600;
}

.writing-description {
    color: #666;
    margin-bottom: 0.9rem;
    font-size: 0.98rem;
}

.writing-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-bottom: 1rem;
}

.writing-tags span {
    color: #555;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 999px;
    padding: 0.18rem 0.55rem;
    font-size: 0.78rem;
    line-height: 1.4;
}

body.dark-mode .writing-tags span {
    border-color: rgba(255, 255, 255, 0.14);
}

body.dark-mode .writing-card:hover .writing-title {
    color: #62b4ff;
}

body.dark-mode .writing-meta,
body.dark-mode .writing-description,
body.dark-mode .writing-tags span {
    color: #cfcfcf;
}

/* Life content */
.life-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2.5rem;
}

.hobby-card {
    flex: 1;
    min-width: 250px;
    background: transparent;
}

.hobby-title {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 500;
    color: #000;
}

/* Guestbook */
.guestbook-section {
    align-items: flex-start;
}

.guestbook-header {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    align-items: flex-end;
    margin-bottom: 2.5rem;
}

.guestbook-header h2 {
    margin-bottom: 0.5rem;
}

.guestbook-header p {
    max-width: 28rem;
}

.visitor-pill {
    border-bottom: 1px solid rgba(0, 0, 0, 0.12);
    padding-bottom: 0.35rem;
    display: flex;
    gap: 0.4rem;
    align-items: baseline;
    color: #666;
    white-space: nowrap;
    font-size: 0.9rem;
}

#visitor-count {
    color: #111;
    font-weight: 600;
}

.guestbook-shell {
    display: grid;
    grid-template-columns: minmax(260px, 0.9fr) minmax(280px, 1.1fr);
    gap: 2.5rem;
    align-items: start;
}

.guestbook-form {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 1.2rem;
}

.guestbook-fields {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.guestbook-form label {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    color: #555;
    font-size: 0.86rem;
}

.guestbook-form input,
.guestbook-form textarea {
    width: 100%;
    border: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.16);
    border-radius: 0;
    background: transparent;
    font: inherit;
    padding: 0.65rem 0;
    resize: vertical;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.guestbook-form input:focus,
.guestbook-form textarea:focus {
    border-color: #007acc;
    box-shadow: 0 1px 0 #007acc;
}

.guestbook-actions {
    margin-top: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

#guestbook-status {
    margin: 0;
    min-height: 1.4rem;
    font-size: 0.86rem;
    color: #666;
}

.guestbook-actions button {
    border: 0;
    border-bottom: 1px solid #111;
    border-radius: 0;
    background: transparent;
    color: #111;
    padding: 0.15rem 0;
    font: inherit;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s ease, opacity 0.2s ease, border-color 0.2s ease;
}

.guestbook-actions button:hover {
    color: #007acc;
    border-color: #007acc;
}

.guestbook-actions button:disabled {
    cursor: wait;
    opacity: 0.65;
}

.guestbook-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-height: 29rem;
    overflow-y: auto;
    padding: 0;
    scrollbar-width: thin;
}

.guestbook-entry {
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding: 1rem 0;
    background: transparent;
    animation: guestbook-entry-in 0.45s ease both;
    animation-delay: calc(var(--entry-index, 0) * 60ms);
    transition: border-color 0.2s ease;
}

.guestbook-entry:hover {
    border-color: rgba(0, 0, 0, 0.15);
}

.guestbook-entry-meta {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.4rem;
}

.guestbook-entry-meta strong {
    font-weight: 600;
    color: #111;
}

.guestbook-entry-meta time {
    color: #777;
    font-size: 0.82rem;
    white-space: nowrap;
}

.guestbook-entry p {
    margin: 0;
    color: #444;
    overflow-wrap: anywhere;
}

.guestbook-empty {
    color: #666;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding-bottom: 1rem;
}

body.dark-mode .visitor-pill,
body.dark-mode .guestbook-form input,
body.dark-mode .guestbook-form textarea,
body.dark-mode .guestbook-entry,
body.dark-mode .guestbook-empty {
    border-color: rgba(255, 255, 255, 0.14);
}

body.dark-mode #visitor-count,
body.dark-mode .guestbook-entry-meta strong {
    color: #fff;
}

body.dark-mode .visitor-pill,
body.dark-mode .guestbook-form label,
body.dark-mode #guestbook-status,
body.dark-mode .guestbook-entry p,
body.dark-mode .guestbook-empty {
    color: #cfcfcf;
}

body.dark-mode .guestbook-actions button {
    color: #f2f2f2;
    border-color: #f2f2f2;
}

body.dark-mode .guestbook-actions button:hover {
    color: #62b4ff;
    border-color: #62b4ff;
}

@keyframes guestbook-entry-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

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

@media (prefers-reduced-motion: reduce) {
    .guestbook-entry {
        animation: none;
    }

}

/* Accomplishments section */
.accomplishments-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.8rem;
}

.accomplishment-card {
    background: transparent;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: border-color 0.3s ease;
}

.accomplishment-card:last-child {
    border-bottom: none;
}

.accomplishment-card:hover {
    border-color: rgba(0, 0, 0, 0.15);
}

.accomplishment-title {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.accomplishment-description {
    color: #666;
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

/* Responsive design */
@media (max-width: 900px) {
    #intro h1 {
        white-space: normal;
    }

    .intro-content {
        transform: none;
    }

    .intro-text-and-image {
        grid-template-columns: 1fr;
        text-align: center;
        align-items: center;
        gap: 2rem;
    }

    .intro-text {
        align-items: center;
        margin-bottom: 0;
        max-width: 38rem;
    }

    .intro-right-gif {
        margin-top: 1rem;
        width: min(100%, 460px);
        justify-self: center;
    }

    .social-links {
        justify-content: center;
    }

    .spotify-now-playing {
        justify-self: center;
    }
}

@media (max-width: 768px) {
    h1,
    #intro h1 {
        font-size: 2.2rem;
    }

    h2 {
        font-size: 1.24rem;
        margin: 0 0 1.7rem;
    }

    .section-header-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.6rem;
        margin: 0 0 1.7rem;
    }

    .container {
        padding: 0 1rem;
    }

    .intro-right-gif {
        display: none;
    }

    .intro-mobile-gif {
        display: block;
        width: min(100%, 420px);
        margin: -0.25rem auto 1.5rem;
    }

    .right-gif {
        max-width: 420px;
        aspect-ratio: auto;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .accomplishments-list {
        grid-template-columns: 1fr;
    }

    .guestbook-header,
    .guestbook-actions {
        align-items: flex-start;
        flex-direction: column;
    }

    .guestbook-shell {
        grid-template-columns: 1fr;
    }

    .guestbook-list {
        max-height: none;
        overflow: visible;
        padding-bottom: 6rem;
    }

    .writing-card {
        max-width: none;
    }

    .timeline-item {
        padding-left: 0;
    }
}

@media (max-width: 480px) {
    h1,
    #intro h1 {
        font-size: 1.85rem;
    }

    h2 {
        font-size: 1.08rem;
    }

    .right-gif {
        max-width: 360px;
    }
}
