
:root {
    --ginger-size: 2.8rem;
    --site-bg: #fbf1dc;
    --link-underline: #0a0600;
    --link-color: #000;
    --header-h: 6rem; /* fallback; JS sets exact value */
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-h);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--site-bg);
    color: #000;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
}

/* =============================================================
   1. FOCUS & ACCESSIBILITY
   ============================================================= */

/* Skip navigation link — visually hidden until focused */
.skip-link {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
    z-index: 100000;
    text-decoration: none;
}

.skip-link:focus {
    position: fixed;
    top: 0;
    left: 1rem;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0.75rem 1.5rem;
    overflow: visible;
    clip: auto;
    white-space: normal;
    background: #000;
    color: #fff;
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    border-radius: 0 0 8px 8px;
}

/* Visible focus ring for keyboard users */
:focus-visible {
    outline: 2px solid #4a6fa5;
    outline-offset: 2px;
}

/* Remove focus ring for mouse users */
:focus:not(:focus-visible) {
    outline: none;
}

/* =============================================================
   2. LAYOUT
   ============================================================= */

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 2rem;
    text-align: center;
    position: relative;
    z-index: 2;
}

/* Legacy one-pager layout (kept for backward compat) */
main.one-pager {
    align-items: stretch;
    justify-content: flex-start;
    max-width: none;
    width: 100%;
    margin: 0 auto;
    padding: 0 12rem;
    text-align: left;
}

@media (max-width: 1200px) {
    main.one-pager {
        padding: 0 6rem;
    }
}

@media (max-width: 768px) {
    main.one-pager {
        padding: 0 1.25rem;
    }
}

/* Page sections */
.page-section {
    padding-top: 1rem;
    padding-bottom: 2rem;
}

.page-section#about {
    min-height: calc(100vh - var(--header-h));
    display: flex;
    flex-direction: column;
    justify-content: center;
    scroll-margin-top: var(--header-h);
}

.page-section#experience {
    scroll-margin-top: var(--header-h);
}

.subsection-header[id] {
    scroll-margin-top: var(--header-h);
}

.page-section .aboutme-wrapper {
    padding: 2.5rem 0;
    min-height: calc(100vh - var(--header-h));
    align-items: center;
}

.section-note {
    font-size: 1.15rem;
    color: #999;
    font-style: italic;
    font-family: 'Courier New', monospace;
    white-space: nowrap;
}

/* =============================================================
   3. HEADER & NAVIGATION
   ============================================================= */

#site-header {
    position: sticky;
    top: 0;
    z-index: 9999;
    background-color: var(--site-bg);
}

header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 3rem;
    background-color: var(--site-bg);
    position: relative;
}

nav {
    display: flex;
}

/* Pill-shaped navigation container */
.nav-pill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1440px;
    background-color: transparent;
    border-radius: 50px;
    padding: 0.5rem 2rem;
    position: relative;
}

/* Sliding highlight bar */
.nav-highlight {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: rgba(215, 198, 168, 0.38);
    border-radius: 50px;
    z-index: 1;
    pointer-events: none;
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                width 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                top 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Nav item base styles */
.nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.85rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    color: #333;
    font-family: 'Inter', sans-serif;
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: none;
    position: relative;
    background-color: transparent;
    z-index: 2;
}

/* Remove underline for nav-pill items */
.nav-pill .nav-item::before {
    display: none;
}

.nav-pill .nav-item:hover,
.connect-menu a:hover,
.footer-nav a:hover {
    color: #333;
}

/* Home link */
.nav-item.home-link {
    padding: 0.85rem 1.2rem;
}

.ginger-logo {
    font-weight: 800;
    font-size: 2.2rem;
    letter-spacing: 0.06em;
    color: #222;
    font-family: 'Inter', sans-serif;
    text-transform: none;
}

.nav-item.home-link svg {
    stroke: #333;
}

.logo-link {
    text-decoration: none;
    color: inherit;
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
}

/* Caret above 'about' link on hover */
.nav-item.about-link {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.nav-item.about-link .about-caret {
    position: absolute;
    left: 50%;
    top: 0;
    transform: translate(-180%, -20%) rotate(-20deg);
    width: 28px;
    height: 28px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 140ms ease, transform 180ms cubic-bezier(.2, .9, .2, 1);
}

.nav-item.about-link:hover .about-caret {
    opacity: 1;
    transform: translate(-180%, -20%) rotate(-25deg);
}

/* Briefcase + award icons above 'experience' on hover */
.nav-item.experience-link {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.nav-item.experience-link .experience-icon {
    position: absolute;
    left: 35%;
    top: 0;
    transform: translate(-95%, -20%) rotate(-8deg);
    width: 22px;
    height: 22px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 140ms ease, transform 180ms cubic-bezier(.2, .9, .2, 1);
}

.nav-item.experience-link:hover .experience-icon {
    opacity: 1;
    transform: translate(-95%, -35%) rotate(-20deg);
}

.nav-item.experience-link .award-icon {
    position: absolute;
    right: 25%;
    top: 0;
    transform: translate(50%, -20%) rotate(8deg);
    width: 18px;
    height: 18px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 160ms ease 40ms, transform 200ms cubic-bezier(.2, .9, .2, 1) 40ms;
}

.nav-item.experience-link:hover .award-icon {
    opacity: 1;
    transform: translate(50%, -35%) rotate(15deg);
}

/* Connect dropdown */
.connect-dropdown {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.connect-dropdown .connect-coffee {
    position: absolute;
    left: 50%;
    top: 0;
    transform: translate(-50%, -15%);
    width: 20px;
    height: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 140ms ease, transform 180ms cubic-bezier(.2, .9, .2, 1);
}

.connect-dropdown:hover .connect-coffee {
    opacity: 1;
    transform: translate(-50%, -30%);
}

#connect-btn {
    background: none;
    border: none;
    color: #444;
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: none;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: background-color 0.2s ease;
    padding: 0;
    position: relative;
}

#connect-btn::before {
    display: none;
}

#connect-btn:hover {
    opacity: 1;
}

.connect-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--site-bg);
    border: none;
    padding: 1rem;
    gap: 1rem;
    margin-top: 0.5rem;
    flex-direction: column;
    z-index: 1000;
}

.connect-menu.active {
    display: flex;
}

.connect-menu a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--link-color);
    text-decoration: none;
    transition: opacity 0.2s;
    padding: 0.5rem;
    position: relative;
    font-size: 1.2rem;
}

.connect-menu a,
.footer-nav a {
    text-decoration: none;
    color: #333;
    font-size: 0.85rem;
    font-weight: 500;
    position: relative;
}

.connect-menu a::before,
.footer-nav a::before {
    content: "";
    position: absolute;
    width: 0;
    height: 4px;
    background-color: var(--link-underline);
    bottom: -6px;
    left: 0;
    transition: width 0.4s;
    border-radius: 2px;
}

.connect-menu a:hover::before,
.footer-nav a:hover::before {
    width: 100%;
}

.connect-menu a:hover {
    opacity: 0.7;
}

.connect-menu a[aria-label="Google Scholar"] svg {
    width: 20px;
    height: 20px;
    display: inline-block;
    vertical-align: middle;
    fill: currentColor;
}

/* Clear drawing button */
#clear-btn {
    background: none;
    border: none;
    color: #5b5342;
    cursor: pointer;
    font-size: 1.2rem;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-decoration: underline;
    opacity: 0.6;
    transition: opacity 0.2s;
    padding: 0.85rem 2rem;
    text-transform: none;
}

#clear-btn:hover {
    opacity: 1;
    color: #888;
}

/* Mobile hamburger toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    margin-left: auto;
    z-index: 2;
}

.nav-toggle-bar {
    display: block;
    width: 24px;
    height: 2px;
    background: #333;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Hamburger → X animation */
.nav-pill.nav-open .nav-toggle .nav-toggle-bar:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-pill.nav-open .nav-toggle .nav-toggle-bar:nth-child(2) {
    opacity: 0;
}

.nav-pill.nav-open .nav-toggle .nav-toggle-bar:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* =============================================================
   4. ABOUT ME SECTION
   ============================================================= */

.aboutme-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 0;
    max-width: 1440px;
    width: 100%;
    margin: 0 auto;
    padding: 2.5rem 1rem;
}

.aboutme-content {
    margin: 0 auto;
    text-align: left;
    max-width: 86ch;
    width: min(86ch, 62%);
    padding-left: clamp(1rem, 4vw, 2rem);
    transform: translateX(-6vw);
}

@media (max-width: 1200px) {
    .aboutme-content {
        transform: translateX(-4vw);
        width: min(68ch, 70%);
    }
}

main h1 {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    animation: float 6s ease-in-out infinite;
    will-change: transform;
}

.subtitle {
    font-size: 1rem;
    color: #666;
    margin-bottom: 2rem;
}

/* Use monospace for about-me text */
.aboutme-content p,
.aboutme-content .subtitle,
.aboutme-content .icon-row p {
    font-family: 'Courier New', monospace;
    font-size: 1.4rem;
}

/* Profile image + layout */
.profile-container {
    flex: 0 0 260px;
    transform: translateX(-4rem);
    will-change: transform;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
    width: 260px;
    position: relative;
    z-index: 6;
}

.profile-face {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
    object-fit: cover;
}

.profile-caption {
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    color: #666;
    margin-top: 0.45rem;
}

.profile-frame {
    width: 240px;
    padding: 0.5rem;
    border-radius: 12px;
    background: #fff7ef;
    border: 4px solid #f6ece0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 10;
}

/* Movable profile card */
.movable-card {
    width: 240px;
    pointer-events: auto;
    cursor: grab;
    user-select: none;
    transition: transform 160ms ease, box-shadow 160ms ease;
    border-radius: 12px;
    position: absolute;
    z-index: 5;
}

.movable-card-inner {
    background: #fff7ef;
    padding: 0.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    border: 4px solid #f6ece0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.movable-profile-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
    object-fit: cover;
}

.movable-caption {
    margin-top: 0.45rem;
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    color: #c14b3a;
}

/* Dashed placeholder for initial docked position */
.movable-placeholder {
    position: absolute;
    width: 272px;
    height: 280px;
    border-radius: 18px;
    border: 4px dashed rgba(56, 118, 255, 0.95);
    background: transparent;
    pointer-events: auto;
    z-index: 4;
    box-shadow: none;
    transform-origin: center center;
    transform: rotate(8deg);
    transition: opacity 220ms ease, transform 220ms ease;
}

.movable-placeholder .placeholder-label {
    position: absolute;
    right: 10px;
    bottom: 8px;
    font-family: 'Courier New', monospace;
    font-size: 1.15rem;
    color: rgba(56, 118, 255, 0.95);
    background: transparent;
    pointer-events: none;
}

.movable-placeholder .placeholder-label-top {
    position: absolute;
    right: 10px;
    top: 8px;
    font-family: 'Courier New', monospace;
    font-size: 1.05rem;
    color: rgba(56, 118, 255, 0.95);
    background: transparent;
    pointer-events: none;
}

@media (max-width: 768px) {
    .aboutme-wrapper {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 1rem;
    }

    .aboutme-content {
        transform: none;
        width: 100%;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        text-align: left;
    }

    .profile-container {
        flex: none;
        margin-bottom: 1rem;
        transform: none;
        overflow: visible;
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .profile-img {
        width: 180px;
        height: 180px;
    }

    .movable-placeholder {
        position: relative;
        left: auto !important;
        top: auto !important;
        transform: rotate(8deg) !important;
        width: 272px !important;
        height: 310px !important;
        margin-top: 1.5rem;
        margin-left: auto;
        margin-right: auto;
    }

    .movable-card {
        position: relative;
        left: auto !important;
        top: auto !important;
        transform: rotate(8deg) !important;
        margin-top: -306px;
        margin-left: auto;
        margin-right: auto;
        cursor: grab;
    }
}

/* =============================================================
   5. SKILLS SECTION
   ============================================================= */

.skills-section.page-section {
    padding: 0;
    padding-bottom: 2rem;
    width: 100vw;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    scroll-margin-top: var(--header-h);
}

/* Full-width lines above and below the skills header */
.skills-line {
    border: none;
    border-top: 1px solid rgba(0, 0, 0, 0.8);
    margin: 0;
    width: 100vw;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
}

.skills-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 3rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
}

.skills-grid {
    display: flex;
    flex-direction: column;
    gap: 2.2rem;
    margin: 2.5rem auto 1.5rem auto;
    padding-left: 3rem;
    padding-right: 3rem;
    max-width: 1440px;
    text-align: left;
}

.skills-row {
    display: grid;
    grid-template-columns: 200px 1fr;
    align-items: baseline;
    gap: 2rem;
}

@media (max-width: 768px) {
    .skills-row {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }
}

.skills-category {
    font-size: 1.15rem;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.skill-tag {
    display: inline-block;
    padding: 0.35rem 0.85rem;
    border: 1.5px solid #000;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 1.08rem;
    color: #000;
    background: transparent;
    white-space: nowrap;
    transition: background 180ms ease, color 180ms ease;
}

.skill-tag:hover {
    background: #000;
    color: var(--site-bg);
}

@media (max-width: 768px) {
    .skills-category {
        font-size: 1rem;
    }

    .skills-header {
        gap: 0.5rem;
        padding-left: 1.5rem;
    }

    .skills-grid {
        padding-left: 1rem;
        padding-right: 1rem;
        gap: 1.5rem;
    }

    .skill-tag {
        font-size: 1.0rem;
        padding: 0.3rem 0.65rem;
        white-space: normal;
        word-break: break-word;
    }
}

/* =============================================================
   6. EXPERIENCE SECTION
   ============================================================= */

.experience-section.page-section {
    padding: 0;
    padding-bottom: 2rem;
    width: 100vw;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    scroll-margin-top: var(--header-h);
}

.experience-subsections {
    padding: 0.75rem 3rem;
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: left;
}

@media (max-width: 768px) {
    .experience-subsections {
        padding: 1rem 1.25rem;
    }
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.section-meta {
    font-size: 1rem;
    color: #222;
}

.divider {
    border: none;
    border-top: 1px solid rgba(0, 0, 0, 0.8);
    margin: 1rem 0 1.2rem;
}

.divider.short {
    width: 100%;
    opacity: 0.15;
}

/* Full-width divider that breaks out of main padding */
.divider.full-width {
    margin-left: -12rem;
    margin-right: -12rem;
}

@media (max-width: 1200px) {
    .divider.full-width {
        margin-left: -6rem;
        margin-right: -6rem;
    }
}

@media (max-width: 768px) {
    .divider.full-width {
        margin-left: -1.25rem;
        margin-right: -1.25rem;
    }
}

.subsection-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: #333;
}

/* Google Scholar button in Publications header */
.scholar-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-family: 'Courier New', monospace;
    font-size: 0.95rem;
    font-weight: 600;
    color: #4a6fa5;
    background: transparent;
    border: 1.5px solid #4a6fa5;
    border-radius: 2rem;
    padding: 0.3rem 0.85rem 0.3rem 0.65rem;
    text-decoration: none;
    transition: background 180ms ease, color 180ms ease;
    white-space: nowrap;
    margin-bottom: 0.4rem;
}

.scholar-btn:hover {
    background: #4a6fa5;
    color: var(--site-bg);
}

.scholar-btn::before {
    display: none;
}

.scholar-icon {
    width: 16px;
    height: 16px;
    fill: currentColor;
    flex-shrink: 0;
}

.experience-list {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
}

.list-block {
    margin: 1rem 0;
}

.exp-item {
    display: block;
    padding: 0.2rem 0.5rem;
    background: var(--site-bg);
}

.exp-item.exp-partner {
    padding-left: 1.6rem;
    border-left: 2px solid rgba(0, 0, 0, 0.03);
}

.exp-item.exp-partner .exp-title {
    font-size: 1.2rem;
}

.exp-honors {
    color: #ce9308;
    font-weight: 600;
    font-size: 0.95em;
    font-style: italic;
}

.exp-conference {
    font-size: 0.98em;
    color: #3a4a6a;
    margin: 0.1em 0 0.2em 0;
    font-weight: 500;
    font-style: italic;
}

.exp-conference .conf-label {
    font-weight: 600;
    color: #2a3a5a;
    margin-right: 0.3em;
}

.exp-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.exp-content {
    flex: 1;
}

.exp-title {
    font-weight: 700;
    font-size: 1.2rem;
}

.exp-subtitle {
    font-style: italic;
    color: #666;
    margin-top: 0.125rem;
    margin-bottom: 0.25rem;
}

.exp-location {
    color: #777;
    margin-top: 0.125rem;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.exp-year {
    color: #666;
    margin-left: 1rem;
    white-space: nowrap;
    font-weight: 600;
}

.exp-meta {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.exp-arrow {
    color: #bbb;
    font-size: 1.25rem;
    transition: transform 180ms ease, color 180ms ease, opacity 180ms ease;
    display: inline-flex;
    align-items: center;
    margin-left: 0.25rem;
}

.exp-arrow .exp-arrow-icon {
    transform-origin: center;
    transition: transform 180ms ease, opacity 180ms ease, stroke 180ms ease;
    stroke: currentColor;
}

.exp-arrow.open .exp-arrow-icon {
    transform: rotate(90deg);
    color: #000;
}

.exp-arrow.disabled {
    opacity: 0.35;
    cursor: default;
}

/* Expanding detail area */
.exp-detail {
    overflow: hidden;
    max-height: 0;
    transition: max-height 260ms ease, padding 180ms ease, background-color 220ms ease;
    background: var(--site-bg);
}

.exp-detail-inner {
    padding: 0.5rem 1.2rem 0.75rem 0;
    color: #333;
}

.exp-item.open .exp-detail {
    padding-top: 0.5rem;
}

@media (max-width: 768px) {
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .exp-item {
        gap: 0.75rem;
    }

    .exp-year {
        display: none;
    }

    .list-block {
        margin: 2rem 0;
    }
}

/* Legacy experience-page layout (backward compat) */
body.experience-page main {
    align-items: stretch;
    max-width: none;
    width: 100%;
    margin: 0 auto;
    padding: 4rem 12rem;
    text-align: left;
}

@media (max-width: 1200px) {
    body.experience-page main {
        padding: 3rem 6rem;
    }
}

@media (max-width: 768px) {
    body.experience-page main {
        padding: 2rem 1.25rem;
    }
}

/* =============================================================
   7. HOBBIES / BEYOND THE SCREEN
   ============================================================= */

.hobbies-section.page-section {
    padding: 0;
    padding-bottom: 8rem;
    width: 100vw;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    scroll-margin-top: var(--header-h);
}

.hobbies-section .skills-header {
    margin-bottom: 0;
    padding: 0.75rem 3rem;
}

.hobbies-row {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: flex-start;
    gap: 4.5rem;
    margin: 18rem 0 10rem 0;
    position: relative;
    flex-wrap: wrap;
    z-index: 1;
}

.hobby-item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 120px;
}

.hobby-interactive {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    cursor: pointer;
    z-index: 2;
}

a.hobby-interactive {
    text-decoration: none;
    color: inherit;
}

.hobby-icon-img {
    width: 48px;
    height: 48px;
    margin-bottom: 0.1rem;
    display: block;
    pointer-events: none;
    user-select: none;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.07));
}

.hobby-title {
    font-size: 1.3rem;
    font-family: 'Courier New', monospace;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.1rem;
    z-index: 2;
    position: relative;
}

/* Handwritten circle effect */
.hobby-circle-svg {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: 158px;
    height: 158px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.18s, transform 0.18s;
    z-index: 3;
}

.hobby-circle-svg-lg {
    width: 120px;
    height: 120px;
}

.hobby-interactive:hover .hobby-circle-svg,
.hobby-interactive:focus-within .hobby-circle-svg {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.08) rotate(-2deg);
}

/* Expandable description and line */
.hobby-desc-container {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s;
    width: max-content;
    min-width: 220px;
    max-width: 500px;
    z-index: 10;
    text-align: center;
}

.hobby-item[data-align="left"] .hobby-desc-container {
    left: auto;
    right: 100%;
    transform: translateX(-10%) translateY(0);
    align-items: flex-end;
    text-align: right;
}

.hobby-item[data-align="right"] .hobby-desc-container {
    left: 100%;
    right: auto;
    transform: translateX(10%) translateY(0);
    align-items: flex-start;
    text-align: left;
}

.hobby-item[data-pos="above"] .hobby-desc-container {
    bottom: 110%;
    flex-direction: column-reverse;
}

.hobby-item[data-pos="below"] .hobby-desc-container {
    top: 110%;
}

.hobby-interactive:hover ~ .hobby-desc-container,
.hobby-interactive:focus-within ~ .hobby-desc-container {
    opacity: 1;
    pointer-events: auto;
}

.hobby-line {
    width: 2px;
    height: 32px;
    background: #b36a2e;
    margin: 0 auto;
    border-radius: 2px;
    opacity: 0.7;
}

.hobby-desc {
    background: none;
    color: #333;
    border: none;
    border-radius: 0;
    padding: 0.2rem 0.5rem;
    font-size: 2.1rem;
    line-height: 1.25;
    box-shadow: none;
    margin: 0.7rem 0 0.2rem 0;
    min-width: 200px;
    max-width: 540px;
    text-align: center;
    font-family: 'Reenie Beanie', cursive;
    letter-spacing: 0.01em;
    z-index: 10;
}

/* Painting preview photos */
.painting-preview {
    display: flex;
    flex-direction: row;
    gap: 0.7rem;
    justify-content: center;
    margin-top: 0.5rem;
}

.painting-preview-img {
    width: 280px;
    max-width: 40vw;
    height: auto;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.10);
}

/* Hobbies grid (flip cards — kept for backward compat) */
.hobbies-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (max-width: 600px) {
    .hobbies-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* Flip card container */
.flip-card {
    background-color: transparent;
    perspective: 1000px;
    height: 280px;
    cursor: pointer;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front,
.flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.5rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border: 3px solid #f6ece0;
}

.flip-card-front {
    background: linear-gradient(135deg, #fff7ef 0%, #fef5eb 100%);
}

.hobby-icon {
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hobby-icon svg {
    width: 80px;
    height: 80px;
}

.flip-card-front h3 {
    font-size: 1.3rem;
    font-weight: 500;
    color: #333;
    margin: 0;
    letter-spacing: 0.05em;
    font-family: 'Courier New', monospace;
}

.flip-card-back {
    background: rgba(56, 118, 255, 0.95);
    transform: rotateY(180deg);
}

.flip-card-back p {
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #fff;
    margin: 0;
    text-align: center;
}

/* Hobbies mobile: descriptions always visible, column layout */
@media (max-width: 700px) {
    .hobbies-row {
        flex-direction: column;
        align-items: center;
        gap: 3rem;
        margin: 4rem 0 3rem 0;
    }

    .hobby-item {
        min-width: 0;
        width: 100%;
        max-width: 400px;
        align-items: center;
    }

    .hobby-circle-svg {
        width: 90px;
        height: 90px;
    }

    .hobby-circle-svg-lg {
        width: 120px;
        height: 120px;
    }

    /* Show descriptions by default on touch devices */
    .hobby-desc-container {
        position: static;
        transform: none;
        opacity: 1;
        pointer-events: auto;
        min-width: auto;
        max-width: 98vw;
        width: 100%;
    }

    .hobby-item[data-pos="above"] .hobby-desc-container,
    .hobby-item[data-pos="below"] .hobby-desc-container {
        position: static;
        bottom: auto;
        top: auto;
    }

    .hobby-item[data-align="left"] .hobby-desc-container,
    .hobby-item[data-align="right"] .hobby-desc-container {
        left: auto;
        right: auto;
        transform: none;
        text-align: center;
        align-items: center;
    }

    .hobby-desc {
        font-size: 1.6rem;
        min-width: 0;
        max-width: 100%;
    }

    .painting-preview {
        flex-direction: column;
        align-items: center;
    }

    .painting-preview-img {
        width: 100%;
        max-width: 280px;
    }
}

/* =============================================================
   8. PHOTO GALLERY
   ============================================================= */

.gallery-section.page-section {
    padding: 0;
    padding-bottom: 6rem;
    width: 100vw;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    scroll-margin-top: var(--header-h);
}

.gallery-section .skills-header {
    margin-bottom: 0;
    padding: 0.75rem 3rem;
}

.gallery-sneak-peek {
    font-family: 'Fira Mono', 'Menlo', 'Monaco', monospace;
    font-size: 1.05em;
    color: #6a4a3a;
    margin-left: 2.5rem;
    vertical-align: middle;
    letter-spacing: 0.03em;
    text-transform: lowercase;
    opacity: 0.85;
    display: inline-block;
    font-weight: 500;
    white-space: nowrap;
}

@media (max-width: 700px) {
    .gallery-sneak-peek {
        display: block;
        margin-left: 0;
        margin-top: 0.5rem;
        font-size: 0.95em;
        text-align: left;
    }
}

/* Centered inner wrapper */
.gallery-inner {
    max-width: 1440px;
    margin: 0 auto;
    overflow: hidden;
    position: relative;
}

.gallery-slider-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    cursor: grab;
    padding: 3rem 0 1.5rem 0;
    -webkit-user-select: none;
    user-select: none;
}

.gallery-slider-wrapper:active {
    cursor: grabbing;
}

/* Track — flex row of cards */
.gallery-track {
    display: flex;
    gap: 2.5rem;
    padding: 0;
    transition: transform 0.35s cubic-bezier(.25, .8, .25, 1);
    will-change: transform;
    align-items: flex-start;
}

.gallery-track.is-dragging {
    transition: none;
}

/* Freeze card animations during instant loop-teleport */
.gallery-card.no-transition,
.gallery-card.no-transition .gallery-card-img {
    transition: none !important;
}

/* Individual card — frameless, coverflow driven by JS */
.gallery-card {
    flex: 0 0 240px;
    display: flex;
    flex-direction: column;
    align-items: center;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    border: none;
    overflow: visible;
    transition: transform 0.45s cubic-bezier(.25, .8, .25, 1),
                opacity 0.45s ease;
    cursor: pointer;
    position: relative;
    will-change: transform, opacity;
}

.gallery-card-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
    border-radius: 14px;
    background: #e8dcc8;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    transition: transform 0.3s cubic-bezier(.25, .8, .25, 1),
                box-shadow 0.3s cubic-bezier(.25, .8, .25, 1);
}

.gallery-card:hover .gallery-card-img {
    transform: scale(1.04) translateY(-6px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

.gallery-card-info {
    padding: 0.6rem 0.2rem 0 0.2rem;
    width: 100%;
    text-align: center;
}

.gallery-card-location {
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    font-weight: 500;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    letter-spacing: 0.02em;
}

.gallery-card-location svg {
    flex-shrink: 0;
    opacity: 0.6;
}

/* Progress bar */
.gallery-progress-wrapper {
    width: 200px;
    height: 4px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
}

.gallery-progress-bar {
    height: 100%;
    width: 30%;
    background: #333;
    border-radius: 4px;
    transition: width 0.3s ease, margin-left 0.3s ease;
}

/* Navigation */
.gallery-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem 0 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: #333;
    background: transparent;
    border: 1.5px solid rgba(0, 0, 0, 0.2);
    border-radius: 2rem;
    padding: 0.55rem 1.4rem;
    cursor: pointer;
    transition: background 180ms ease, border-color 180ms ease;
}

.gallery-nav-btn:hover {
    background: rgba(0, 0, 0, 0.06);
    border-color: rgba(0, 0, 0, 0.4);
}

/* Lightbox overlay */
.gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 200000;
    background: rgba(0, 0, 0, 0.92);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: default;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.gallery-lightbox.is-open {
    opacity: 1;
    visibility: visible;
}

.gallery-lightbox img {
    max-width: 90vw;
    max-height: 78vh;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    object-fit: contain;
    transition: transform 0.3s ease;
}

.gallery-lightbox.is-open img {
    transform: scale(1);
}

.lightbox-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #fff;
    transition: background 180ms ease;
    z-index: 2;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.lightbox-location {
    margin-top: 1rem;
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.85);
    letter-spacing: 0.04em;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

@media (max-width: 768px) {
    .gallery-card {
        flex: 0 0 200px;
    }

    .gallery-card-img {
        height: 250px;
    }

    .gallery-track {
        gap: 1.5rem;
        padding: 0 1.25rem;
    }

    .gallery-nav {
        padding: 1.2rem 1.25rem 0 1.25rem;
    }

    .gallery-section .skills-header {
        padding: 0.75rem 1.25rem;
    }
}

@media (max-width: 480px) {
    .gallery-card {
        flex: 0 0 150px;
    }

    .gallery-card-img {
        height: 190px;
    }

    .gallery-card-location {
        font-size: 0.75rem;
    }
}

/* =============================================================
   9. FOOTER & LIKE BUTTON
   ============================================================= */

footer {
    padding: 2rem 3rem;
    background-color: #000;
    color: #fff;
    border-top: none;
    --link-color: #fff;
    --link-underline: #fff;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.footer-logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--site-bg);
}

.footer-logo p {
    color: #aaa;
    font-weight: 400;
}

.footer-copyright {
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    color: #aaa;
    margin-top: 0.5rem;
}

.footer-nav {
    display: flex;
    gap: 2rem;
}

.footer-nav a {
    text-decoration: none;
    color: #aaa;
    font-size: 1rem;
    transition: color 0.2s;
}

.footer-nav a:hover {
    color: #fff;
}

.footer-right {
    display: flex;
    gap: 1.5rem;
}

.footer-right a {
    color: #aaa;
    transition: color 0.2s;
}

.footer-right a:hover {
    color: #fff;
}

/* Like heart button */
.like-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.like-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    color: #aaa;
    transition: color 0.2s, transform 0.2s;
}

.like-btn .heart-filled {
    display: none;
}

.like-btn .heart-outline {
    display: block;
}

.like-btn:hover {
    color: #ff6b8a;
}

.like-btn:hover .heart-outline {
    stroke: #ff6b8a;
}

.like-btn.liked .heart-outline {
    display: none;
}

.like-btn.liked .heart-filled {
    display: block;
}

.like-btn.liked {
    color: #ff6b8a;
}

.like-btn.pop {
    animation: heart-pop 0.4s ease;
}

/* Speech-bubble like count */
.like-bubble {
    position: relative;
    background: var(--site-bg);
    color: #000;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    line-height: 1.4;
    white-space: nowrap;
    user-select: none;
}

.like-bubble::before {
    content: '';
    position: absolute;
    left: -5px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 5px 6px 5px 0;
    border-style: solid;
    border-color: transparent var(--site-bg) transparent transparent;
}

/* Floating heart particles */
.heart-particles {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
    width: 0;
    height: 0;
}

.heart-particle {
    position: absolute;
    font-size: 1rem;
    color: #ff6b8a;
    opacity: 0;
    pointer-events: none;
    animation: float-heart var(--d, 600ms) ease-out forwards;
    transform: scale(var(--s, 1));
}

@media (max-width: 768px) {
    footer {
        padding: 2rem 1.5rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 2rem;
        align-items: flex-start;
    }

    .footer-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
}

/* =============================================================
   10. COMPONENTS (ginger icon, buttons)
   ============================================================= */

/* Ginger emoji control */
.ginger-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: var(--ginger-size);
    width: var(--ginger-size);
    height: var(--ginger-size);
    line-height: 1;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    vertical-align: middle;
    position: relative;
    transform-origin: center;
    transition: transform 120ms ease, filter 120ms ease;
    will-change: transform;
    transform: translateZ(0);
    z-index: 9998;
}

.ginger-icon.active {
    transform: scale(1.12);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.12));
    z-index: 9998;
}

.ginger-icon:focus {
    outline: none;
}

#click-me-text {
    font-family: 'Courier New', monospace;
    font-size: 1.05rem;
    color: #999;
    margin: 0;
    position: relative;
    white-space: nowrap;
    z-index: 9998;
}

.icon-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    margin-top: 0.5rem;
    min-height: calc(var(--ginger-size) * 1.4);
}

.button-group {
    display: flex;
    gap: 1rem;
}

.btn-primary,
.btn-secondary {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    border: 2px solid #000;
    cursor: pointer;
    transition: all 0.3s;
    border-radius: 0.5rem;
}

.btn-primary {
    background-color: #000;
    color: #fff;
}

.btn-primary:hover {
    background-color: #333;
}

.btn-secondary {
    background-color: #fff;
    color: #000;
}

.btn-secondary:hover {
    background-color: #f0f0f0;
}

@media (max-width: 480px) {
    .ginger-icon {
        font-size: 2.4rem;
        width: 2.4rem;
        height: 2.4rem;
        z-index: 9998;
    }
}

/* =============================================================
   11. CANVAS & CUSTOM CURSOR
   ============================================================= */

#draw-canvas {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 9998;
    pointer-events: none;
}

#mouse-spot-canvas {
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* Smooth follower cursor */
.sf-container {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 99999;
}

.sf-dot {
    position: absolute;
    left: 0;
    top: 0;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #000;
    transform: translate3d(0, 0, 0) translate(-50%, -50%);
    will-change: transform;
    transition: background 160ms ease;
}

.sf-border {
    position: absolute;
    left: 0;
    top: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 2px solid #000;
    transform: translate3d(0, 0, 0) translate(-50%, -50%);
    will-change: transform, width, height;
    transition: width 180ms cubic-bezier(.2, .9, .2, 1),
                height 180ms cubic-bezier(.2, .9, .2, 1),
                border-color 160ms ease,
                box-shadow 180ms ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

/* Invert follower over dark footer */
.sf-container.sf-inverted .sf-dot {
    background: var(--site-bg);
}

.sf-container.sf-inverted .sf-border {
    border-color: var(--site-bg);
}

/* Hide follower on touch devices */
@media (pointer: coarse),
(max-width: 768px) {
    .sf-container {
        display: none !important;
    }
}

/* Hide native cursor on fine-pointer devices */
@media (pointer: fine) {
    html,
    body {
        cursor: none;
    }
}

/* =============================================================
   12. ANIMATIONS
   ============================================================= */

@keyframes float {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
    100% {
        transform: translateY(0);
    }
}

@keyframes heart-pop {
    0% {
        transform: scale(1);
    }
    30% {
        transform: scale(1.35);
    }
    60% {
        transform: scale(0.9);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes float-heart {
    0% {
        opacity: 1;
        transform: translate(0, 0) scale(var(--s, 1));
    }
    100% {
        opacity: 0;
        transform: translate(var(--x, 0px), var(--y, -50px)) scale(0.2);
    }
}

/* =============================================================
   13. RESPONSIVE — Tablet (max-width: 1024px)
   ============================================================= */

@media (max-width: 1024px) {
    .hobbies-row {
        gap: 2.5rem;
        margin: 12rem 0 6rem 0;
    }
}

/* =============================================================
   14. RESPONSIVE — Mobile (max-width: 768px)
   ============================================================= */

@media (max-width: 768px) {
    /* Header & Nav: hamburger toggle */
    header {
        padding: 1rem;
    }

    .nav-pill {
        flex-wrap: wrap;
        padding: 0.4rem 1rem;
        max-width: 100%;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-highlight {
        display: none;
    }

    .nav-item:not(.home-link) {
        order: 10;
        flex-basis: 100%;
        display: none;
        justify-content: flex-start;
        padding: 0.75rem 1rem;
        font-size: 1rem;
        border-radius: 8px;
    }

    .nav-pill.nav-open .nav-item:not(.home-link) {
        display: flex;
    }

    .ginger-logo {
        font-size: 1.8rem;
    }

    #clear-btn {
        font-size: 1rem;
        padding: 0.75rem 1rem;
        text-decoration: none;
        opacity: 1;
        color: #333;
    }

    #connect-btn {
        font-size: 1rem;
        color: #333;
    }

    .logo {
        font-size: 1.5rem;
    }

    nav {
        gap: 1rem;
    }

    /* Layout */
    main h1 {
        font-size: 2rem;
    }

    .button-group {
        flex-direction: column;
        width: 100%;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
    }

    /* Hide decorative hover icons on mobile nav */
    .nav-item.about-link .about-caret,
    .nav-item.experience-link .experience-icon,
    .nav-item.experience-link .award-icon,
    .connect-dropdown .connect-coffee {
        display: none;
    }

    /* Hobbies — reduce spacing for tablets */
    .hobbies-row {
        gap: 3rem;
        margin: 8rem 0 5rem 0;
    }

    .hobbies-section.page-section {
        padding-bottom: 6rem;
    }
}

/* =============================================================
   15. RESPONSIVE — Small Mobile (max-width: 480px)
   ============================================================= */

@media (max-width: 480px) {
    .aboutme-content p,
    .aboutme-content .subtitle,
    .aboutme-content .icon-row p {
        font-size: 1.15rem;
    }

    main h1 {
        font-size: 1.6rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .subsection-title {
        font-size: 1.25rem;
    }

    .hobbies-row {
        gap: 2rem;
        margin: 2rem 0;
    }

    .hobbies-section.page-section {
        padding-bottom: 4rem;
    }

    .gallery-section.page-section {
        padding-bottom: 3rem;
    }

    .gallery-nav-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.75rem;
    }

    .gallery-progress-wrapper {
        width: 120px;
    }
}

/* =============================================================
   16. RESPONSIVE — Extra Small (max-width: 320px)
   ============================================================= */

@media (max-width: 320px) {
    main h1 {
        font-size: 1.4rem;
    }

    .aboutme-content p,
    .aboutme-content .subtitle,
    .aboutme-content .icon-row p {
        font-size: 1rem;
    }

    .skill-tag {
        font-size: 0.85rem;
        padding: 0.25rem 0.5rem;
    }

    .skills-grid {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .nav-pill {
        padding: 0.3rem 0.5rem;
    }

    .ginger-logo {
        font-size: 1.5rem;
    }

    .exp-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .gallery-card {
        flex: 0 0 130px;
    }

    .gallery-card-img {
        height: 160px;
    }

    .hobby-desc {
        font-size: 1.3rem;
    }

    .painting-preview-img {
        max-width: 200px;
    }

    footer {
        padding: 1.5rem 1rem;
    }
}
