/*=============================================
  DESIGN TOKENS
=============================================*/
:root {
    --header-height: 4.25rem;
    /* Every circular identity image site-wide (GitHub avatar, institution/
       company logos) shares this exact size so they read as one system. */
    --logo-size: 104px;

    /* Colors */
    --color-bg: #0a0a0d;
    --color-bg-alt: #0e0e12;
    --color-surface: #131318;
    --color-surface-2: #191a21;
    --color-border: rgba(255, 255, 255, 0.09);
    --color-border-strong: rgba(255, 255, 255, 0.18);

    --color-accent: #d97757;
    --color-accent-alt: #c4633f;
    --color-accent-soft: rgba(217, 119, 87, 0.12);
    --color-secondary: #5ec8ff;

    --color-title: #f5f5f7;
    --color-text: #a3a6b3;
    --color-text-dim: #686b78;

    --shadow-sm: 0 2px 14px rgba(0, 0, 0, 0.28);
    --shadow-glow: 0 0 0 1px rgba(255, 184, 28, 0.22), 0 16px 34px rgba(255, 184, 28, 0.07);

    /* Type */
    --font-display: 'Fraunces', serif;
    --font-body: 'Poppins', sans-serif;
    --font-mono: 'Roboto Mono', monospace;

    --fs-biggest: clamp(3rem, 4.4vw + 1.6rem, 5.75rem);
    --fs-h1: clamp(2.1rem, 2.1vw + 1.3rem, 2.9rem);
    --fs-h2: clamp(1.4rem, 1.2vw + 1rem, 1.7rem);
    --fs-h3: 1.2rem;
    --fs-normal: 1rem;
    --fs-small: 0.9rem;
    --fs-smaller: 0.8rem;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-pill: 999px;

    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);

    --z-header: 1000;
    --z-scrollup: 900;
    --z-progress: 1100;
}

/*=============================================
  RESET / BASE
=============================================*/
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

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

body {
    font-family: var(--font-body);
    font-size: var(--fs-normal);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.65;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    color: var(--color-title);
    font-weight: 600;
    line-height: 1.15;
}

ul { list-style: none; }

a {
    text-decoration: none;
    color: var(--color-text);
    transition: color var(--transition);
}

img { max-width: 100%; height: auto; display: block; }

button, input, textarea {
    font-family: var(--font-body);
    font-size: var(--fs-normal);
    outline: none;
    border: none;
    background: none;
    color: inherit;
}

::selection { background: var(--color-accent); color: #0a0a0f; }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--color-bg); }
::-webkit-scrollbar-thumb { background: var(--color-surface-2); border-radius: var(--radius-pill); }
::-webkit-scrollbar-thumb:hover { background: var(--color-accent-alt); }

/*=============================================
  SCROLL PROGRESS
=============================================*/
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    width: 0%;
    background: linear-gradient(90deg, var(--color-accent), var(--color-secondary));
    z-index: var(--z-progress);
    transition: width 0.1s linear;
}

/*=============================================
  REUSABLE
=============================================*/
.container {
    max-width: 1180px;
    width: calc(100% - 3rem);
    margin: 0 auto;
}

.section { padding: 7rem 0; position: relative; }

.section-header { margin-bottom: 3.5rem; }

.section-eyebrow {
    display: inline-flex;
    align-items: baseline;
    gap: 0.6rem;
    font-family: var(--font-mono);
    font-size: var(--fs-smaller);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--color-text-dim);
    margin-bottom: 0.9rem;
}

.eyebrow-index { color: var(--color-accent); }

.section-title {
    font-family: var(--font-display);
    font-size: var(--fs-h1);
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--color-title);
}

.section-note {
    margin-top: 0.75rem;
    font-family: var(--font-mono);
    font-size: var(--fs-smaller);
    color: var(--color-text-dim);
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.9rem 1.75rem;
    border-radius: var(--radius-pill);
    font-weight: 500;
    font-size: var(--fs-small);
    transition: all var(--transition);
    cursor: pointer;
    white-space: nowrap;
}

.btn svg { width: 17px; height: 17px; }

.primary-btn {
    background: var(--color-accent);
    color: #14140f;
    box-shadow: 0 8px 22px rgba(255, 184, 28, 0.2);
}

.primary-btn:hover {
    background: var(--color-accent-alt);
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(255, 184, 28, 0.28);
}

.secondary-btn {
    background: transparent;
    color: var(--color-title);
    border: 1px solid var(--color-border-strong);
}

.secondary-btn:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
    transform: translateY(-2px);
}

.scroll-down { display: flex; justify-content: center; margin-top: 3.5rem; }

.mouse-wrapper {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-text-dim);
    font-size: var(--fs-smaller);
}

.mouse {
    width: 24px;
    height: 38px;
    border: 2px solid var(--color-border-strong);
    border-radius: var(--radius-pill);
    display: flex;
    justify-content: center;
    padding-top: 6px;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--color-accent);
    border-radius: var(--radius-pill);
    animation: mouse-scroll 1.6s infinite;
}

@keyframes mouse-scroll {
    0% { transform: translateY(0); opacity: 1; }
    70% { transform: translateY(10px); opacity: 0; }
    100% { opacity: 0; }
}

/*=============================================
  HEADER / NAV
=============================================*/
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: var(--z-header);
    background: rgba(10, 10, 13, 0.72);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--color-border);
}

.header-container {
    height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--color-title);
    letter-spacing: 0.01em;
}

.logo-accent { color: var(--color-accent); }

.nav-list { display: flex; gap: 1.9rem; }

.nav-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: var(--fs-small);
    font-weight: 500;
    color: var(--color-text);
    padding: 0.4rem 0.1rem;
}

.nav-index {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    color: var(--color-text-dim);
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: var(--color-accent);
    transition: width var(--transition);
}

.nav-link:hover { color: var(--color-title); }
.nav-link:hover .nav-index { color: var(--color-accent); }

.nav-link.active { color: var(--color-accent); }
.nav-link.active .nav-index { color: var(--color-accent); }
.nav-link.active::after { width: 100%; }

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 0.4rem;
}

.hamburger .bar {
    width: 22px;
    height: 2px;
    background: var(--color-title);
    border-radius: 2px;
    transition: all var(--transition);
}

.hamburger.active .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active .bar:nth-child(2) { opacity: 0; }
.hamburger.active .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/*=============================================
  HOME / HERO
=============================================*/
.home {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: var(--header-height);
    background:
        radial-gradient(50% 45% at 85% 15%, rgba(255, 184, 28, 0.07), transparent 60%),
        radial-gradient(40% 35% at 5% 90%, rgba(94, 200, 255, 0.05), transparent 60%);
}

.home-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    align-items: center;
    gap: 3rem;
    padding: 3rem 0 1rem;
}

.greeting {
    font-family: var(--font-mono);
    color: var(--color-accent);
    font-size: var(--fs-small);
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.name {
    font-family: var(--font-display);
    font-size: var(--fs-biggest);
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 0.98;
    margin-bottom: 1.4rem;
}

.profession {
    font-family: var(--font-mono);
    font-size: var(--fs-h3);
    color: var(--color-text);
    font-weight: 400;
    margin-bottom: 1.5rem;
    min-height: 1.5em;
}

.profession::after {
    content: '|';
    color: var(--color-accent);
    margin-left: 2px;
    animation: blink 1s step-end infinite;
}

@keyframes blink { 50% { opacity: 0; } }

.brief-intro {
    max-width: 46ch;
    color: var(--color-text);
    margin-bottom: 2.25rem;
}

.home-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.home-socials { display: flex; gap: 1rem; }

.home-socials a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--color-border-strong);
    border-radius: 50%;
    color: var(--color-text);
}

.home-socials a:hover {
    color: #14140f;
    background: var(--color-accent);
    border-color: var(--color-accent);
    transform: translateY(-3px);
}

.home-socials svg { width: 18px; height: 18px; }

.home-img { display: flex; justify-content: center; }

/* Same plain hairline-bordered photo-card treatment used everywhere else
   on the site (About, Education) - no circle, no motion, no glow. The
   hero previously stood out as the one flashy/animated exception. */
.home-img-card {
    width: min(360px, 80vw);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.home-img-photo {
    aspect-ratio: 4 / 5;
    object-fit: cover;
    /* Zoom in and anchor toward the bottom: the source photo has a lot of
       empty sky above the subject, so a plain center crop leaves the face
       too small and low in the frame. */
    transform: scale(1.35);
    transform-origin: 50% 78%;
}

/*=============================================
  ABOUT
=============================================*/
.about-container-new {
    display: grid;
    grid-template-columns: 0.75fr 1.25fr;
    gap: 3.5rem;
    align-items: center;
}

.about-img-card {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.about-img { aspect-ratio: 4 / 5; object-fit: cover; }

.about-tagline {
    font-family: var(--font-display);
    font-size: var(--fs-h1);
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.15;
    margin-bottom: 1.3rem;
}

.about-intro { margin-bottom: 2.25rem; }

.highlight { color: var(--color-accent); font-weight: 600; }

.about-stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin-bottom: 2rem;
    border-top: 1px solid var(--color-border);
}

.about-stat-card {
    padding: 1.5rem 1.25rem 0 0;
    border-right: 1px solid var(--color-border);
}

.about-stat-card:last-child { border-right: none; }

.info-title {
    color: var(--color-accent);
    font-weight: 700;
    font-size: 2.1rem;
    font-family: var(--font-display);
    margin-bottom: 0.4rem;
}

.stat-label {
    font-size: var(--fs-smaller);
    color: var(--color-text-dim);
    line-height: 1.4;
}

.about-funfact {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: var(--fs-small);
    color: var(--color-text);
    margin-bottom: 1.75rem;
}

.about-funfact svg { width: 18px; height: 18px; color: var(--color-accent); flex-shrink: 0; }

/*=============================================
  EDUCATION (hairline rows, not boxed cards)
=============================================*/
.education-layout {
    display: grid;
    /* Fixed (not fr-ratio) image column: guarantees the content column gets
       all remaining width so the longer degree/date rows stay on one line,
       regardless of exact container width above the collapse breakpoint.
       280px is the largest width (at a trimmed 2rem gap) that still leaves
       both rows unwrapped at the tightest two-column viewport (just above
       the 1180px breakpoint), confirmed empirically rather than estimated
       from font metrics. */
    grid-template-columns: 1fr 280px;
    gap: 2rem;
    align-items: start;
}

.education-img-card {
    order: 2;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
    position: sticky;
    top: calc(var(--header-height) + 2rem);
}


.education-img {
    aspect-ratio: 3 / 4;
    object-fit: cover;
    /* Zoom in slightly, anchored to the bottom edge: crops in from the top
       and both sides while leaving the bottom of the frame untouched. */
    transform: scale(1.18);
    transform-origin: 50% 100%;
}

.education-container { display: flex; flex-direction: column; order: 1; }

.education-row {
    display: flex;
    gap: 1.75rem;
    padding: 2.25rem 0;
    border-top: 1px solid var(--color-border);
}

.education-container .education-row:last-child { border-bottom: 1px solid var(--color-border); }

.education-mark,
.experience-logo {
    flex-shrink: 0;
    width: var(--logo-size);
    height: var(--logo-size);
    border-radius: 50%;
    /* Institution/company marks are pre-normalized to a shared canvas size
       and fill ratio, overscanned to eliminate any white edge margin (see
       assets/images/logos/) so every logo reads at a consistent visual
       size here regardless of source resolution/aspect. */
    object-fit: cover;
}

.education-title-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.3rem;
}

.education-degree {
    font-family: var(--font-display);
    font-size: var(--fs-h3);
    font-weight: 600;
}

.education-date {
    font-family: var(--font-mono);
    font-size: var(--fs-smaller);
    color: var(--color-accent);
    white-space: nowrap;
}

.education-school {
    color: var(--color-text);
    font-weight: 500;
    margin-bottom: 0.85rem;
}

.education-honors li {
    position: relative;
    padding-left: 1.1rem;
    font-size: var(--fs-small);
    color: var(--color-text-dim);
    margin-bottom: 0.3rem;
}

.education-honors li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--color-accent);
}

/*=============================================
  EXPERIENCE (hairline rows)
=============================================*/
.experience-container { display: flex; flex-direction: column; }

.experience-row {
    padding: 2.5rem 0;
    border-top: 1px solid var(--color-border);
}

.experience-container .experience-row:last-child { border-bottom: 1px solid var(--color-border); }

.experience-header-flex {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    margin-bottom: 1.1rem;
}

.experience-header-flex .experience-header { flex: 1; min-width: 0; }

.experience-logo { margin-top: 2px; }

.experience-title-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.3rem;
}

.experience-title {
    font-family: var(--font-display);
    font-size: var(--fs-h3);
    font-weight: 600;
}

.experience-date {
    font-family: var(--font-mono);
    font-size: var(--fs-smaller);
    color: var(--color-accent);
    white-space: nowrap;
}

.experience-company {
    color: var(--color-text-dim);
    font-weight: 500;
}

.experience-secondary-role {
    font-size: var(--fs-smaller);
    color: var(--color-text-dim);
    font-style: italic;
    margin-top: 0.35rem;
}

.experience-bullets li {
    position: relative;
    padding-left: 1.2rem;
    margin-bottom: 0.55rem;
    font-size: var(--fs-small);
}

.experience-bullets li::before {
    content: '\2192';
    position: absolute;
    left: 0;
    color: var(--color-accent);
}

.experience-bullets li:last-child { margin-bottom: 0; }

/*=============================================
  SKILLS
=============================================*/
.skills-list-new {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
}

.skill-group {
    display: grid;
    grid-template-columns: 190px 1fr;
    gap: 1.5rem;
    align-items: start;
    padding-bottom: 1.6rem;
    border-bottom: 1px solid var(--color-border);
}

.skill-group:last-child { border-bottom: none; padding-bottom: 0; }

.skill-label {
    font-family: var(--font-mono);
    font-size: var(--fs-small);
    color: var(--color-title);
    font-weight: 600;
    letter-spacing: 0.02em;
}

.skill-items-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.skill-item {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-pill);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    font-size: var(--fs-small);
    color: var(--color-text);
    transition: all var(--transition);
}

.skill-item:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
    transform: translateY(-2px);
}

/*=============================================
  GITHUB INTRO STRIP (top of Projects - not a boxed
  "profile card", just an identity line the rest of
  the section visibly hangs off of)
=============================================*/
/* .leetcode-strip shares every rule below with .github-strip - same
   "identity strip" component used twice, so the two profiles read as one
   consistent system rather than two different designs. */
.github-strip,
.leetcode-strip {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding-bottom: 2.5rem;
    margin-bottom: 2.5rem;
    border-bottom: 1px solid var(--color-border);
}

.github-strip-identity,
.leetcode-strip-identity {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    min-width: 0;
}

.github-strip-avatar,
.leetcode-strip-avatar {
    width: var(--logo-size);
    height: var(--logo-size);
    border-radius: 50%;
    flex-shrink: 0;
}

.leetcode-strip-avatar { background: #fff; padding: 16px; }

.github-strip-name-row,
.leetcode-strip-name-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}

.github-strip-name-row svg { width: 16px; height: 16px; color: var(--color-text-dim); }

.github-strip-username,
.leetcode-strip-username {
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: var(--fs-small);
    color: var(--color-title);
}

.leetcode-strip-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: var(--fs-smaller);
    font-weight: 600;
    color: var(--color-accent);
}

.leetcode-strip-badge img { width: 18px; height: 18px; }

.github-strip-note,
.leetcode-strip-note {
    font-size: var(--fs-small);
    color: var(--color-text-dim);
    max-width: 48ch;
    margin-bottom: 0.5rem;
}

.github-strip-link,
.leetcode-strip-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: var(--fs-smaller);
    font-weight: 600;
    color: var(--color-accent);
}

.github-strip-link svg,
.leetcode-strip-link svg { width: 13px; height: 13px; }

.github-strip-link:hover,
.leetcode-strip-link:hover { color: var(--color-accent-alt); }

.github-strip-heatmap,
.leetcode-strip-heatmap {
    width: 100%;
}

.github-strip-heatmap .github-heatmap,
.github-strip-heatmap .github-heatmap svg,
.leetcode-strip-heatmap .leetcode-heatmap-svg svg {
    display: block;
    width: 100%;
    height: auto;
}

/*=============================================
  PROJECTS
=============================================*/
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.75rem;
    margin-bottom: 4.5rem;
}

.project-card {
    position: relative;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 2.25rem 2rem 2rem;
    display: flex;
    transition: all var(--transition);
}

.project-card:hover {
    border-color: var(--color-accent);
    transform: translateY(-6px);
    box-shadow: var(--shadow-glow);
}

.project-index {
    position: absolute;
    top: 1.5rem;
    right: 1.75rem;
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--color-border-strong);
}

.project-info { display: flex; flex-direction: column; width: 100%; }

.project-header-flex {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 0.85rem;
    padding-right: 2.5rem;
}

.project-logo {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    object-fit: cover;
}

.project-icon {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: var(--color-accent-soft);
    color: var(--color-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.project-icon svg { width: 18px; height: 18px; }

.project-title {
    font-family: var(--font-display);
    color: var(--color-title);
    font-weight: 600;
    font-size: 1.2rem;
}

.project-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-bottom: 0.9rem;
}

.badge-pill {
    font-family: var(--font-mono);
    font-size: var(--fs-smaller);
    font-weight: 600;
    padding: 0.3rem 0.7rem;
    border-radius: var(--radius-sm);
    background: var(--color-accent-soft);
    color: var(--color-accent);
}

.project-description {
    font-size: var(--fs-small);
    color: var(--color-text);
    margin-bottom: 1.4rem;
    flex-grow: 1;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.4rem;
}

.tech-tag {
    font-size: var(--fs-smaller);
    padding: 0.3rem 0.7rem;
    border-radius: var(--radius-pill);
    background: var(--color-surface-2);
    color: var(--color-text-dim);
    border: 1px solid var(--color-border);
}

.project-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: var(--fs-smaller);
    font-weight: 500;
    color: var(--color-text);
}

.project-link svg { width: 16px; height: 16px; }

.project-link:hover { color: var(--color-accent); }

.profile-loading {
    width: 100%;
    text-align: center;
    padding: 2.5rem 0;
    color: var(--color-accent);
    font-size: 1.1rem;
}

/* "More on GitHub" - compact, auto-generated, un-curated repo list */
.more-projects { padding-top: 1rem; }

.more-projects-title {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.more-projects-subtitle {
    font-size: var(--fs-small);
    color: var(--color-text-dim);
    margin-bottom: 1.75rem;
}

.repo-list { display: flex; flex-direction: column; }

.repo-row {
    display: grid;
    grid-template-columns: 14px minmax(140px, 220px) 1fr auto;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0.5rem;
    border-top: 1px solid var(--color-border);
    transition: background var(--transition);
}

.repo-list .repo-row:last-child { border-bottom: 1px solid var(--color-border); }

.repo-row:hover { background: var(--color-surface); }

.repo-row-lang {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--color-text-dim);
}

.repo-row-lang[data-lang="Java"] { background: #f89820; }
.repo-row-lang[data-lang="TypeScript"] { background: #3178c6; }
.repo-row-lang[data-lang="JavaScript"] { background: #f1e05a; }
.repo-row-lang[data-lang="Python"] { background: #3572a5; }
.repo-row-lang[data-lang="Go"] { background: #00add8; }
.repo-row-lang[data-lang="C++"] { background: #f34b7d; }
.repo-row-lang[data-lang="C"] { background: #a8b9cc; }
.repo-row-lang[data-lang="HCL"] { background: #844fba; }

.repo-row-name {
    font-family: var(--font-mono);
    font-size: var(--fs-small);
    font-weight: 500;
    color: var(--color-title);
}

.repo-row-desc {
    font-size: var(--fs-smaller);
    color: var(--color-text-dim);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.repo-row-meta {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    font-family: var(--font-mono);
    font-size: var(--fs-smaller);
    color: var(--color-text-dim);
    white-space: nowrap;
}

.repo-row-stars {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.repo-row-stars svg { width: 12px; height: 12px; color: var(--color-accent); }

.repo-row-arrow {
    width: 14px;
    height: 14px;
    transition: transform var(--transition);
}

.repo-row:hover .repo-row-arrow { transform: translate(2px, -2px); color: var(--color-accent); }

/*=============================================
  PROFILES (LeetCode) - same hairline "identity
  strip" + full-width heatmap treatment as the
  GitHub strip atop Projects, plus the About
  section's stat-row style for numbers. No boxed
  dashboard cards.
=============================================*/
.github-heatmap { max-width: 100%; }
.github-heatmap svg { max-width: 100%; height: auto; }

.leetcode-stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    margin-bottom: 2.5rem;
    border-top: 1px solid var(--color-border);
}

.leetcode-stats-row .about-stat-card { padding-top: 1.25rem; }

.leetcode-difficulty-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    padding-top: 1.75rem;
    margin-bottom: 2.5rem;
    border-top: 1px solid var(--color-border);
}

.leetcode-difficulty-header {
    display: flex;
    justify-content: space-between;
    font-size: var(--fs-small);
    margin-bottom: 0.5rem;
}

.leetcode-difficulty-header span:first-child { color: var(--color-text-dim); }

.difficulty-easy-text { color: #4ade80; font-weight: 600; }
.difficulty-medium-text { color: var(--color-accent); font-weight: 600; }
.difficulty-hard-text { color: #f87171; font-weight: 600; }

.difficulty-bar-compact-track {
    width: 100%;
    height: 6px;
    border-radius: var(--radius-pill);
    background: var(--color-surface);
    overflow: hidden;
}

.difficulty-bar-compact-fill {
    height: 100%;
    border-radius: var(--radius-pill);
    transition: width 1s ease;
}

.difficulty-easy { background: #4ade80; }
.difficulty-medium { background: var(--color-accent); }
.difficulty-hard { background: #f87171; }

.leetcode-heatmap-svg {
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: auto;
}

.leetcode-heatmap-svg > div:last-child { width: 100%; }

.leetcode-heatmap-svg svg { max-width: 100%; height: auto; }

.heatmap-tooltip { font-family: var(--font-mono); }

/*=============================================
  CONTACT
=============================================*/
.contact-tiles-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.contact-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 2rem 1.25rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    transition: all var(--transition);
}

.contact-card:hover {
    border-color: var(--color-accent);
    transform: translateY(-5px);
    box-shadow: var(--shadow-sm);
}

.contact-icon {
    width: 42px;
    height: 42px;
    padding: 10px;
    border-radius: 50%;
    background: var(--color-accent-soft);
    color: var(--color-accent);
    margin-bottom: 0.4rem;
}

.contact-title { font-family: var(--font-display); font-size: 1.05rem; }

.contact-data {
    font-size: var(--fs-smaller);
    color: var(--color-text-dim);
    word-break: break-word;
}

.contact-link {
    margin-top: 0.4rem;
    font-size: var(--fs-small);
    font-weight: 600;
    color: var(--color-accent);
}

.contact-link:hover { color: var(--color-accent-alt); }

/*=============================================
  FOOTER / SCROLL UP
=============================================*/
.footer { padding: 3rem 0 2.5rem; text-align: center; border-top: 1px solid var(--color-border); }

.thankyou-message-alt {
    font-family: var(--font-display);
    color: var(--color-title);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.footer-copyright { font-size: var(--fs-smaller); color: var(--color-text-dim); }

.scrollup {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-surface-2);
    border: 1px solid var(--color-border-strong);
    border-radius: 50%;
    color: var(--color-title);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--transition);
    z-index: var(--z-scrollup);
}

.scrollup.show-scroll { opacity: 1; visibility: visible; transform: translateY(0); }

.scrollup:hover { background: var(--color-accent); color: #14140f; border-color: var(--color-accent); }

.scrollup-icon { width: 18px; height: 18px; }

/*=============================================
  SCROLL / FADE ANIMATIONS
=============================================*/
.fade-in { animation: fadeInUp 0.8s var(--ease) forwards; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(22px); }
    to { opacity: 1; transform: translateY(0); }
}

.section-header,
.github-strip,
.leetcode-strip,
.project-card,
.experience-row,
.education-row,
.contact-card,
.about-stat-card,
.repo-row {
    opacity: 0;
}

.section-header.fade-in,
.github-strip.fade-in,
.leetcode-strip.fade-in,
.project-card.fade-in,
.experience-row.fade-in,
.education-row.fade-in,
.contact-card.fade-in,
.about-stat-card.fade-in,
.repo-row.fade-in {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}

/*=============================================
  RESPONSIVE
=============================================*/
/* Education collapses at a wider breakpoint than About: its degree/date
   rows are long enough that the two-column layout gets uncomfortably tight
   well before 1024px, so it drops to single-column earlier. */
@media screen and (max-width: 1180px) {
    .education-layout { grid-template-columns: 1fr; }
    .education-img-card { max-width: 340px; margin: 0 auto 1rem; position: static; order: 0; }
    .education-container { order: 0; }
}

@media screen and (max-width: 1024px) {
    .container { max-width: 920px; }

    .home-content { grid-template-columns: 1fr; text-align: center; gap: 2.5rem; }
    .home-text { order: 1; }
    .home-img { order: 0; }
    .brief-intro { margin-inline: auto; }
    .home-buttons, .home-socials { justify-content: center; }

    .about-container-new { grid-template-columns: 1fr; }
    .about-img-card { max-width: 340px; margin: 0 auto; }

    .contact-tiles-row { grid-template-columns: repeat(2, 1fr); }

    .repo-row { grid-template-columns: 12px minmax(120px, 1fr) auto; }
    .repo-row-desc { display: none; }
}

@media screen and (max-width: 860px) {
    .nav-menu {
        position: fixed;
        top: var(--header-height);
        right: -100%;
        width: min(320px, 80%);
        height: calc(100vh - var(--header-height));
        background: var(--color-bg-alt);
        border-left: 1px solid var(--color-border);
        padding: 2.5rem 2rem;
        transition: right var(--transition);
    }

    .nav-menu.show-menu { right: 0; }

    .nav-list { flex-direction: column; gap: 1.75rem; }

    .hamburger { display: flex; }

    .skill-group { grid-template-columns: 1fr; gap: 0.75rem; }
    .leetcode-stats-row { grid-template-columns: repeat(2, 1fr); }
}

@media screen and (max-width: 640px) {
    .container { width: calc(100% - 2rem); }

    .section { padding: 4.5rem 0; }

    .home-buttons { flex-direction: column; width: 100%; }
    .home-buttons .btn { width: 100%; }

    .about-stats-row { grid-template-columns: 1fr; }
    .about-stat-card { border-right: none; border-bottom: 1px solid var(--color-border); padding: 1.25rem 0; }
    .about-stat-card:last-child { border-bottom: none; }

    .contact-tiles-row { grid-template-columns: 1fr; }

    .education-row, .experience-row { padding: 1.75rem 0; }

    .leetcode-stats-row { grid-template-columns: 1fr; }
    .leetcode-stats-row .about-stat-card { padding-top: 1.25rem; }
    .leetcode-difficulty-row { grid-template-columns: 1fr; gap: 1.25rem; }
}

@media screen and (orientation: landscape) and (max-height: 500px) {
    .home { min-height: auto; padding: 6rem 0 3rem; }
    .mouse-wrapper { display: none; }
}
