/*
 * modern.css — Phase 4 single-page scroll experience
 * Layered on top of style.css; overrides only what's needed.
 * Space Grotesk typography · GSAP-ready · Accessibility-first
 */

/* ══════════════════════════════════════════════════════════════════════
   TYPOGRAPHY — Space Grotesk
   ══════════════════════════════════════════════════════════════════════ */
:root,
html[data-theme="dark"] {
    --font-display: 'Space Grotesk', system-ui, -apple-system, sans-serif;
    --page-bg: #09090f;
    --page-bg-soft: #0d0d15;
    --surface: rgba(16, 16, 26, 0.9);
    --surface-solid: #10101a;
    --surface-raised: #151522;
    --surface-soft: rgba(255, 255, 255, 0.04);
    --surface-hover: rgba(255, 255, 255, 0.08);
    --border-soft: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --text-strong: #f0f0f8;
    --text-body: rgba(240, 240, 248, 0.82);
    --text-muted: rgba(240, 240, 248, 0.56);
    --text-faint: rgba(240, 240, 248, 0.34);
    --nav-bg: rgba(9, 9, 15, 0.92);
    --shadow-soft: 0 24px 80px rgba(0, 0, 0, 0.26);
    --cover-shadow: 0 28px 70px rgba(0, 0, 0, 0.45);
    --button-text: #08080f;
    --divider-gradient: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.07), transparent);

    --smoky-black: var(--page-bg);
    --eerie-black-1: var(--surface-raised);
    --eerie-black-2: var(--surface-solid);
    --onyx: #1b1b28;
    --jet: rgba(255, 255, 255, 0.12);
    --white-1: #ffffff;
    --white-2: var(--text-strong);
    --light-gray: var(--text-body);
    --light-gray-70: var(--text-muted);
    --shadow-1: -4px 8px 24px rgba(0, 0, 0, 0.18);
    --shadow-5: var(--shadow-soft);
}

html[data-theme="light"] {
    --orange-yellow-crayola: hsl(38, 82%, 42%);
    --page-bg: #f5f3ee;
    --page-bg-soft: #ebe7de;
    --surface: rgba(255, 252, 245, 0.92);
    --surface-solid: #fffaf0;
    --surface-raised: #ffffff;
    --surface-soft: rgba(28, 26, 22, 0.045);
    --surface-hover: rgba(28, 26, 22, 0.08);
    --border-soft: rgba(28, 26, 22, 0.12);
    --border-strong: rgba(28, 26, 22, 0.22);
    --text-strong: #17140f;
    --text-body: rgba(23, 20, 15, 0.78);
    --text-muted: rgba(23, 20, 15, 0.56);
    --text-faint: rgba(23, 20, 15, 0.36);
    --nav-bg: rgba(255, 250, 240, 0.88);
    --shadow-soft: 0 24px 70px rgba(70, 53, 27, 0.13);
    --cover-shadow: 0 26px 62px rgba(70, 53, 27, 0.16);
    --button-text: #fffaf0;
    --divider-gradient: linear-gradient(90deg, transparent, rgba(28, 26, 22, 0.13), transparent);

    --smoky-black: var(--page-bg);
    --eerie-black-1: var(--surface-raised);
    --eerie-black-2: var(--surface-solid);
    --onyx: #eee8dc;
    --jet: rgba(28, 26, 22, 0.14);
    --white-1: #11100d;
    --white-2: var(--text-strong);
    --light-gray: var(--text-body);
    --light-gray-70: var(--text-muted);
    --shadow-1: -4px 8px 24px rgba(70, 53, 27, 0.1);
    --shadow-5: var(--shadow-soft);
}

html {
    color-scheme: dark;
}

html[data-theme="light"] {
    color-scheme: light;
}

body,
.h1,
.h2,
.h3,
.h4,
.h5,
.article-title,
.name,
.navbar-link,
.timeline-item-title,
.hero-name,
.hero-eyebrow,
.hero-desc {
    font-family: var(--font-display);
}

body {
    background: var(--page-bg);
    color: var(--text-body);
    transition: background-color 0.18s ease, color 0.18s ease;
}

.h2,
.h3,
.h4,
.h5,
.article-title,
.timeline-item-title,
.service-item-title {
    color: var(--text-strong);
}

.about-text,
.service-item-text,
.timeline-text,
.contact-headline-copy {
    color: var(--text-body);
}

/* ══════════════════════════════════════════════════════════════════════
   SINGLE-PAGE SCROLL — Show all articles (override display:none)
   ══════════════════════════════════════════════════════════════════════ */
article {
    display: block;
}

article.active {
    display: block;
    animation: none;
}

/* Consistent spacing between stacked sections */
.main-content article+article {
    margin-top: 24px;
}

/* ══════════════════════════════════════════════════════════════════════
   SCROLL PROGRESS BAR
   ══════════════════════════════════════════════════════════════════════ */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    width: 100%;
    z-index: 9999;
    pointer-events: none;
}

.scroll-progress::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--orange-yellow-crayola);
    transform: scaleX(var(--scroll, 0));
    transform-origin: left center;
    transition: transform 0.05s linear;
}

/* ══════════════════════════════════════════════════════════════════════
   HERO SECTION
   ══════════════════════════════════════════════════════════════════════ */
.hero {
    padding: 80px 24px 64px;
    background: var(--page-bg);
    overflow: hidden;
    position: relative;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--divider-gradient);
}

.hero-inner {
    max-width: 1200px;
    margin-inline: auto;
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 56px;
    align-items: center;
}

/* Avatar block */
.hero-avatar-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.hero-avatar-wrap img {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    border: 2px solid var(--border-soft);
    object-fit: cover;
    box-shadow: 0 0 0 8px rgba(255, 255, 255, 0.02), 0 8px 32px rgba(0, 0, 0, 0.4);
}

.hero-status {
    font-family: var(--font-display);
    font-size: 11px;
    font-weight: 500;
    color: #4ade80;
    background: rgba(74, 222, 128, 0.08);
    border: 1px solid rgba(74, 222, 128, 0.22);
    border-radius: 20px;
    padding: 4px 14px;
    letter-spacing: 0.6px;
    text-align: center;
    white-space: nowrap;
}

/* Hero text block */
.hero-content {
    max-width: 700px;
}

.hero-eyebrow {
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 600;
    color: var(--orange-yellow-crayola);
    letter-spacing: 1.2px;
    text-transform: uppercase;
    margin-bottom: 14px;
    opacity: 0.9;
}

.hero-name {
    font-family: var(--font-display);
    font-size: clamp(2.2rem, 4.5vw, 3.8rem);
    font-weight: 700;
    line-height: 1.1;
    color: var(--text-strong);
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.hero-role {
    color: var(--orange-yellow-crayola);
    font-size: clamp(1.3rem, 2.2vw, 2rem);
    font-weight: 500;
    display: block;
}

.hero-desc {
    font-family: var(--font-display);
    font-size: clamp(0.95rem, 1.4vw, 1.05rem);
    line-height: 1.75;
    color: var(--light-gray);
    margin-top: 16px;
    margin-bottom: 28px;
    max-width: 580px;
}

/* CTA buttons */
.hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 32px;
}

.btn-primary,
.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 26px;
    border-radius: 8px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--orange-yellow-crayola);
    color: var(--button-text);
}

.btn-primary:hover,
.btn-primary:focus-visible {
    background: hsl(45, 100%, 68%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(247, 201, 72, 0.35);
}

.btn-ghost {
    background: transparent;
    color: var(--light-gray);
    border: 1px solid var(--border-strong);
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
    border-color: var(--orange-yellow-crayola);
    color: var(--orange-yellow-crayola);
    transform: translateY(-2px);
}

/* Tech tag row */
.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span {
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 500;
    padding: 5px 13px;
    border-radius: 6px;
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    color: var(--light-gray-70, #a6a6b8);
    letter-spacing: 0.2px;
    white-space: nowrap;
}

/* ══════════════════════════════════════════════════════════════════════
   NAVBAR — sticky on mobile (override fixed-bottom)
   At 1024px+ the original CSS positions it at top-right of main-content
   ══════════════════════════════════════════════════════════════════════ */
@media (max-width: 1023px) {
    .navbar {
        position: sticky;
        top: 0;
        bottom: auto;
        border-radius: 0;
        z-index: 50;
    }
}

/* Anchor links inside navbar (was buttons) */
.navbar-link {
    display: inline-block;
    text-decoration: none;
}

.theme-toggle {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 34px;
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid var(--border-soft);
    background: var(--surface-soft);
    color: var(--text-body);
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
    background: var(--surface-hover);
    border-color: var(--border-strong);
    color: var(--text-strong);
    outline: none;
}

.theme-toggle-icon,
.theme-toggle-text {
    display: inline-block;
}

/* ══════════════════════════════════════════════════════════════════════
   SKILL GROUPS — grouped chip cloud (replaces broken marquee)
   ══════════════════════════════════════════════════════════════════════ */
.skill-groups {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 4px;
}

.skill-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.skill-group-label {
    font-family: var(--font-display);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-faint);
}

.skill-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.skill-chip {
    display: inline-flex;
    align-items: center;
    height: 30px;
    padding: 0 13px;
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    border-radius: 7px;
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 500;
    color: var(--text-body);
    white-space: nowrap;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.skill-chip:hover {
    background: var(--surface-hover);
    border-color: var(--border-strong);
}

/* filter-panel styles — see end of file */

/* ══════════════════════════════════════════════════════════════════════
   CONTACT FORM — remove inline styles
   ══════════════════════════════════════════════════════════════════════ */
.contact-form .input-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 32px;
}

.contact-form .form-btn {
    margin: auto;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    min-width: 220px;
}

/* ══════════════════════════════════════════════════════════════════════
   PUBLICATIONS — link styling fix (replace inline style="color:white")
   ══════════════════════════════════════════════════════════════════════ */
.timeline-item-title a {
    color: var(--white-2);
    text-decoration: none;
    transition: color 0.2s ease;
}

.timeline-item-title a:hover,
.timeline-item-title a:focus-visible {
    color: var(--orange-yellow-crayola);
}

/* ══════════════════════════════════════════════════════════════════════
   A11Y / LINT FIXES

   1. backdrop-filter prefix order (webkit must come first)
   2. user-select for project-initial
   3. standard line-clamp alongside webkit
   ══════════════════════════════════════════════════════════════════════ */

/* Re-declare with correct prefix order */
.sidebar,
article {
    background: var(--surface);
    border-color: var(--border-soft);
    box-shadow: var(--shadow-soft);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    backdrop-filter: blur(20px) saturate(160%);
}

.content-card,
.service-item {
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    box-shadow: none;
}

.content-card::before,
.service-item::before {
    background: var(--surface-raised);
}

.timeline-item:not(:last-child)::before {
    background: var(--border-soft);
}

.timeline-item::after {
    background: var(--orange-yellow-crayola);
    box-shadow: 0 0 0 4px var(--surface-raised);
}

/* user-select fix */
.project-initial {
    -webkit-user-select: none;
    user-select: none;
}

/* line-clamp fix: add standard property after -webkit- */
.project-desc {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    overflow: hidden;
}

/* ══════════════════════════════════════════════════════════════════════
   PROJECT CARDS — featured card image enhancement
   ══════════════════════════════════════════════════════════════════════ */
.project-img {
    overflow: hidden;
    border-radius: 10px;
}

.project-img img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.project-item:hover .project-img img {
    transform: scale(1.04);
}

/* SVG images: fit contain so nothing gets cropped */
.project-img img[src$=".svg"] {
    object-fit: cover;
    background: var(--page-bg-soft);
}

/* ══════════════════════════════════════════════════════════════════════
   GSAP ANIMATION STATES
   (Elements start invisible; GSAP makes them visible on scroll)
   ══════════════════════════════════════════════════════════════════════ */
.gsap-hidden {
    opacity: 0;
    transform: translateY(30px);
    will-change: transform, opacity;
}

/* Reduced motion: skip all transforms */
@media (prefers-reduced-motion: reduce) {
    .gsap-hidden {
        opacity: 1;
        transform: none;
    }

    .btn-primary:hover,
    .btn-ghost:hover,
    .project-item:hover .project-img img {
        transform: none;
    }
}

/* ══════════════════════════════════════════════════════════════════════
   RESPONSIVE — Hero section
   ══════════════════════════════════════════════════════════════════════ */
@media (max-width: 599px) {
    .hero {
        padding: 48px 18px 40px;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 28px;
        text-align: center;
    }

    .hero-avatar-wrap {
        margin: 0 auto;
    }

    .hero-avatar-wrap img {
        width: 110px;
        height: 110px;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-tags {
        justify-content: center;
    }

    .hero-desc {
        margin-inline: auto;
    }
}

@media (min-width: 600px) and (max-width: 1023px) {
    .hero-inner {
        gap: 36px;
    }

    .hero-avatar-wrap img {
        width: 130px;
        height: 130px;
    }
}

@media (min-width: 1024px) and (max-width: 1249px) {
    .hero-inner {
        gap: 48px;
    }
}

/* ══════════════════════════════════════════════════════════════════════
   SECTION SPACING — main content padding at top on desktop
   ══════════════════════════════════════════════════════════════════════ */
@media (min-width: 1250px) {
    main {
        padding-top: 0;
    }

    .main-content {
        /* keep sidebar + content side by side */
    }
}

/* ══════════════════════════════════════════════════════════════════════
   SKILLS SECTION TITLE
   ══════════════════════════════════════════════════════════════════════ */
.skills-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

/* ══════════════════════════════════════════════════════════════════════
   CURRENTLY BUILDING — compact banner between hero and main
   ══════════════════════════════════════════════════════════════════════ */
.currently-building {
    padding: 24px;
    background: var(--surface-soft);
    border-bottom: 1px solid var(--border-soft);
    border-top: 1px solid var(--border-soft);
}

.building-inner {
    max-width: 1200px;
    margin-inline: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 28px;
}

.building-heading {
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 700;
    color: var(--text-faint);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    white-space: nowrap;
    margin: 0;
}

.building-copy {
    font-family: var(--font-display);
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
    flex: 1;
    min-width: 180px;
    margin: 0;
}

.building-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.chip {
    font-family: var(--font-display);
    font-size: 10px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    color: var(--text-muted);
    letter-spacing: 0.3px;
}

/* ══════════════════════════════════════════════════════════════════════
   CONTACT CTA — replaces old contact-info-block + form
   ══════════════════════════════════════════════════════════════════════ */
.contact-headline-copy {
    font-size: 15px;
    color: var(--light-gray);
    margin-bottom: 32px;
    line-height: 1.7;
    max-width: 520px;
}

.contact-cta-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 40px;
}

.contact-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: 8px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    color: var(--light-gray);
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.contact-cta-btn:hover,
.contact-cta-btn:focus-visible {
    background: var(--surface-hover);
    border-color: var(--orange-yellow-crayola);
    color: var(--orange-yellow-crayola);
    transform: translateY(-1px);
    outline: none;
}

.contact-cta-btn--primary {
    background: var(--orange-yellow-crayola);
    color: var(--button-text);
    border-color: transparent;
}

.contact-cta-btn--primary:hover,
.contact-cta-btn--primary:focus-visible {
    background: hsl(45, 100%, 68%);
    color: var(--button-text);
    border-color: transparent;
}

/* Remove border from map iframe via CSS */
.mapbox-frame {
    border: 0;
    display: block;
}

/* ══════════════════════════════════════════════════════════════════════
   PROJECT IMAGE ASPECT RATIO — consistent 16:9, SVG vs bitmap
   ══════════════════════════════════════════════════════════════════════ */
.project-img {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    width: 100%;
    position: relative;
    height: auto !important;
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

/* SVG covers: contain so the full composition is visible */
.project-img img[src$=".svg"] {
    object-fit: contain;
    background: var(--page-bg-soft);
}

/* filter-panel duplicate — see end of file */


#project-filter:focus-visible {
    outline: 2px solid var(--orange-yellow-crayola);
    outline-offset: 2px;
}

/* ══════════════════════════════════════════════════════════════════════
   ARCHIVE TOGGLE — collapsed GitHub-discovered projects
   ══════════════════════════════════════════════════════════════════════ */
.archive-toggle-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: 1px solid var(--border-soft);
    color: var(--text-muted);
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    margin: 24px 0 0;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.archive-toggle-btn:hover,
.archive-toggle-btn:focus-visible {
    border-color: var(--orange-yellow-crayola);
    color: var(--orange-yellow-crayola);
    outline: none;
}

.archive-toggle-btn ion-icon {
    transition: transform 0.3s ease;
}

.archive-toggle-btn[aria-expanded="true"] ion-icon {
    transform: rotate(180deg);
}

.archive-collapsed {
    display: none;
    margin-top: 8px;
}

.archive-collapsed.open {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

/* ══════════════════════════════════════════════════════════════════════
   PROJECT REEL — Dotconor-inspired case-study covers, no sticky overlay
   ══════════════════════════════════════════════════════════════════════ */
.project-reel {
    margin-bottom: 64px;
}

.project-reel-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--border-soft);
    padding-bottom: 16px;
}

.project-reel-kicker {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: var(--text-faint);
    margin: 0;
}

.project-reel-title {
    font-size: clamp(1.8rem, 4vw, 3rem);
    color: var(--text-strong);
    line-height: 1;
    margin: 0;
    letter-spacing: 0;
}

.project-reel-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
    gap: clamp(24px, 5vw, 54px);
    align-items: start;
}

.project-reel-list {
    display: flex;
    flex-direction: column;
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px solid var(--border-soft);
}

.project-reel-item {
    border-bottom: 1px solid var(--border-soft);
}

.project-reel-button {
    width: 100%;
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 18px;
    align-items: start;
    padding: 18px 0;
    border: 0;
    background: transparent;
    color: var(--text-faint);
    cursor: pointer;
    transition: color 0.18s ease, padding-left 0.18s ease;
}

.project-reel-button:hover,
.project-reel-button.active {
    color: var(--text-strong);
    padding-left: 8px;
    outline: none;
}

.project-reel-button:focus-visible {
    outline: 2px solid var(--orange-yellow-crayola);
    outline-offset: -2px;
}

.project-reel-button.active {
    box-shadow: inset 3px 0 0 var(--orange-yellow-crayola);
}

.project-reel-item-number {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--orange-yellow-crayola);
    padding-top: 6px;
}

.project-reel-item-label {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.project-reel-item-title {
    font-size: clamp(1.25rem, 3vw, 2.15rem);
    font-weight: 700;
    line-height: 1.05;
    color: currentColor;
}

.project-reel-item-subtitle {
    font-size: 13px;
    line-height: 1.45;
    color: var(--text-muted);
}

.project-reel-button:not(.active) .project-reel-item-subtitle {
    opacity: 0.62;
}

.project-reel-frame {
    width: 100%;
}

.project-reel-cover {
    width: min(100%, 360px);
    margin-left: auto;
    border: 1px solid var(--border-soft);
    border-radius: 10px;
    overflow: hidden;
    background: var(--surface-raised);
    box-shadow: var(--cover-shadow);
}

.project-reel-image-wrap {
    position: relative;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    background: var(--reel-cover-bg, var(--page-bg-soft));
    border-bottom: 1px solid var(--border-soft);
}

.project-reel-motif {
    position: absolute;
    inset: 0;
    opacity: 0.28;
}

.project-reel-image {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.project-reel-image[data-fit="contain"] {
    object-fit: contain;
    padding: 18px;
}

.project-reel-meta {
    padding: 16px 18px 18px;
}

.project-reel-index {
    font-family: monospace;
    font-size: 11px;
    letter-spacing: 1.8px;
    color: var(--text-faint);
    margin-bottom: 12px;
}

.project-reel-name {
    font-size: clamp(1.3rem, 3vw, 2rem);
    line-height: 1;
    color: var(--text-strong);
    margin: 0 0 8px;
}

.project-reel-subtitle,
.project-reel-summary {
    color: var(--text-muted);
    line-height: 1.55;
    margin: 0;
}

.project-reel-subtitle {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-body);
    margin-bottom: 10px;
}

.project-reel-summary {
    font-size: 13px;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    overflow: hidden;
}

.project-reel-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 16px;
}

.project-reel-tech span {
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 5px;
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    color: var(--text-muted);
}

.project-reel-link {
    display: inline-flex;
    margin-top: 18px;
    color: var(--orange-yellow-crayola);
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
}

.project-reel-link:hover,
.project-reel-link:focus-visible {
    text-decoration: underline;
    outline: none;
}

@media (max-width: 899px) {
    .project-reel-heading {
        align-items: start;
        flex-direction: column;
    }

    .project-reel-layout {
        grid-template-columns: 1fr;
    }

    .project-reel-cover {
        margin-inline: auto;
    }
}

@media (max-width: 599px) {
    .currently-building {
        padding: 18px;
    }

    .building-inner {
        gap: 10px 20px;
    }
}

/* ══════════════════════════════════════════════════════════════════════
   PHASE 6 — EDITORIAL LAYOUT SYSTEM
   ══════════════════════════════════════════════════════════════════════ */

/* — Hide sidebar vCard — */
aside.sidebar {
    display: none !important;
}

/* — Override flex layout from style.css @1250px — */
@media (min-width: 1250px) {
    main {
        display: block;
        max-width: 960px;
        margin-inline: auto;
        padding-inline: 24px;
    }

    .main-content {
        min-width: unset;
        width: 100%;
        margin: 0;
    }
}

@media (max-width: 1249px) {
    main {
        display: block;
    }

    .main-content {
        width: 100%;
    }
}

/* — Navbar full-width sticky — */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--nav-bg);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-color: var(--border-soft);
    border-bottom: 1px solid var(--border-soft);
    box-shadow: none;
    padding-inline: 10px;
}

.navbar-list {
    flex: 1;
    min-width: 0;
    padding-inline: 0;
}

.navbar-link {
    color: var(--text-muted);
}

.navbar-link:hover,
.navbar-link:focus-visible,
.navbar-link.active {
    color: var(--orange-yellow-crayola);
}

.theme-toggle {
    flex-shrink: 0;
}

/* — Currently building: inline, no chips — */
.building-chips {
    display: none;
}

.building-inner {
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 8px 24px;
}

.building-copy {
    flex: 1;
}

/* — Hide map iframe — */
.mapbox {
    display: none;
}

/* ══════════════════════════════════════════════════════════════════════
   TYPOGRAPHIC PROJECT TILES
   ══════════════════════════════════════════════════════════════════════ */
.project-tile {
    aspect-ratio: 16 / 9;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 18px 20px;
    border-radius: 8px 8px 0 0;
    position: relative;
    overflow: hidden;
    background: var(--tile-bg, linear-gradient(135deg, #0d1117 0%, #161b22 100%));
}

.project-tile-number {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--orange-yellow-crayola);
    opacity: 0.75;
    margin-bottom: 8px;
    font-family: var(--font-display);
}

.project-tile-title {
    font-family: var(--font-display);
    font-size: clamp(1rem, 2vw, 1.4rem);
    font-weight: 700;
    color: var(--text-strong);
    margin: 0;
    line-height: 1.2;
}

.project-tile-cat {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    margin-top: 5px;
    font-family: var(--font-display);
}

/* — Project card layout — */
.project-item {
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    overflow: hidden;
    background: var(--surface-soft);
    transition: border-color 0.2s ease, transform 0.2s ease;
    display: flex;
    flex-direction: column;
}

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

.project-item>a {
    display: flex;
    flex-direction: column;
    flex: 1;
    text-decoration: none;
}

.project-info {
    padding: 14px 16px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.project-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 3px;
}

.project-title {
    font-family: var(--font-display);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-strong);
    margin: 0;
}

.project-category {
    font-size: 12px;
    color: var(--text-muted);
    margin: 0 0 10px;
    line-height: 1.4;
}

/* Hide long descriptions from cards — too noisy */
.project-desc {
    display: none;
}

/* Hide "Featured" badge — redundant in new layout */
.project-status-badge {
    display: none;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: auto;
}

.project-tag {
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 4px;
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    color: var(--text-muted);
    font-family: var(--font-display);
    white-space: nowrap;
}

/* — Project list grid — */
.project-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.project-section-label {
    grid-column: 1 / -1;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-faint);
    padding: 8px 0 12px;
    border-bottom: 1px solid var(--border-soft);
    margin-bottom: 4px;
    font-family: var(--font-display);
    list-style: none;
}

/* — GitHub link — */
.github-all-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 24px;
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.github-all-link:hover {
    color: var(--orange-yellow-crayola);
}

/* — Hide archive toggle (replaced by static link) — */
.archive-toggle-btn {
    display: none;
}

.archive-collapsed {
    display: none !important;
}

/* — Old .project-img (for static fallback items) — */
.project-img {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px 8px 0 0;
    height: auto !important;
    background: var(--page-bg-soft);
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: var(--page-bg-soft);
}

/* ══════════════════════════════════════════════════════════════════════
   GLOBAL OVERFLOW + FOCUS STATES
   ══════════════════════════════════════════════════════════════════════ */
body {
    overflow-x: hidden;
}

/* Keyboard focus — project cards */
.project-item>a:focus-visible,
.project-tile:focus-visible {
    outline: 2px solid var(--orange-yellow-crayola);
    outline-offset: 2px;
    border-radius: 12px;
}

/* Keyboard focus — nav links */
.navbar-link:focus-visible {
    outline: 2px solid var(--orange-yellow-crayola);
    outline-offset: 4px;
    border-radius: 4px;
}

/* Keyboard focus — skill chip */
.skill-chip:focus-visible {
    outline: 2px solid var(--orange-yellow-crayola);
    outline-offset: 2px;
    border-radius: 7px;
}

/* Mobile grid: single column */
@media (max-width: 480px) {
    .project-list {
        grid-template-columns: 1fr;
    }

    .skill-group-label {
        font-size: 9px;
    }
}

/* ══════════════════════════════════════════════════════════════════════
   GITHUB MORE SECTION — collapsed auto-discovered repos
   ══════════════════════════════════════════════════════════════════════ */
.github-more-section {
    margin-top: 20px;
    border-top: 1px solid var(--border-soft);
    padding-top: 16px;
}

.github-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 8px 16px;
    font-family: var(--font-display);
    font-size: 12.5px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease;
}

.github-more-btn:hover,
.github-more-btn.open {
    border-color: var(--border-strong);
    color: var(--text-strong);
}

.github-more-count {
    font-size: 11px;
    color: var(--text-faint);
}

.github-more-chevron {
    font-size: 12px;
    transition: transform 0.2s ease;
}

.github-more-btn.open .github-more-chevron {
    transform: rotate(180deg);
}

.github-repos-list {
    list-style: none;
    padding: 0;
    margin: 12px 0 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* Ensure [hidden] attribute wins over display:flex */
.github-repos-list[hidden] {
    display: none;
}

.github-repo-item {
    border-radius: 7px;
    transition: background 0.15s ease;
}

.github-repo-item:hover {
    background: var(--surface-soft);
}

.github-repo-link {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding: 10px 12px;
    text-decoration: none;
    border-radius: 7px;
}

.github-repo-name {
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 600;
    color: var(--text-strong);
    white-space: nowrap;
    text-transform: capitalize;
}

.github-repo-desc {
    font-family: var(--font-display);
    font-size: 12px;
    color: var(--text-muted);
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.github-repo-meta {
    font-size: 11px;
    color: var(--text-faint);
    white-space: nowrap;
}

@media (max-width: 599px) {
    .github-repo-link {
        flex-wrap: wrap;
        gap: 4px 12px;
    }

    .github-repo-desc {
        white-space: normal;
    }
}

/* ══════════════════════════════════════════════════════════════════════
   FILTER PANEL — cleaner inline style
   ══════════════════════════════════════════════════════════════════════ */
.filter-panel {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.filter-panel label {
    font-family: var(--font-display);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-faint);
    white-space: nowrap;
}

.filter-copy {
    flex-basis: 100%;
    margin: 0;
    color: var(--text-muted);
    font-family: var(--font-display);
    font-size: 12.5px;
    line-height: 1.5;
}

#project-filter {
    background: var(--surface-soft);
    border: 1px solid var(--border-soft);
    border-radius: 7px;
    padding: 6px 12px;
    font-size: 12.5px;
    font-family: var(--font-display);
    color: var(--text-body);
    cursor: pointer;
    appearance: auto;
}