@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

html {
    scroll-behavior: smooth;
    scroll-padding-top: 5.5rem;
}

section[id] {
    scroll-margin-top: 5.5rem;
}

:root {
    --bg-primary: hsl(240, 10%, 4%);
    --bg-secondary: hsl(240, 8%, 8%);
    --bg-tertiary: hsl(240, 6%, 13%);
    --accent-red: #7F89FF;
    --accent-red-light: #AEC0FF;
    --accent-red-glow: rgba(127, 137, 255, 0.22);
    --accent-blue: #B0C0FF;
    --accent-blue-glow: rgba(176, 192, 255, 0.18);
    --accent-btn: #5662F6;
    --accent-btn-light: #7480FF;
    --accent-shadow: rgba(86, 98, 246, 0.35);
    --accent-shadow-strong: rgba(86, 98, 246, 0.5);
    --accent-green: hsl(145, 90%, 45%);
    --tag-success: hsl(145, 90%, 45%);
    --tag-success-bg: rgba(16, 185, 129, 0.1);
    --tag-success-border: rgba(16, 185, 129, 0.2);
    --btn-on-accent: #ffffff;
    --text-primary: hsl(0, 0%, 96%);
    --text-secondary: hsl(240, 4%, 75%);
    --text-muted: hsl(240, 4%, 55%);
    --border-color: rgba(255, 255, 255, 0.08);
    --glass-bg: rgba(12, 12, 16, 0.65);
    --glass-border: rgba(255, 255, 255, 0.04);
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;
    --max-width: 1200px;
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

body.light-mode {
    --bg-primary: hsl(240, 20%, 97%);
    --bg-secondary: hsl(240, 15%, 93%);
    --bg-tertiary: hsl(240, 12%, 88%);
    --text-primary: hsl(240, 15%, 8%);
    --text-secondary: hsl(240, 10%, 28%);
    --text-muted: hsl(240, 6%, 45%);
    --border-color: rgba(0, 0, 0, 0.12);
    --glass-bg: rgba(245, 245, 250, 0.75);
    --glass-border: rgba(0, 0, 0, 0.08);
    --accent-red: #060D46;
    --accent-red-light: #0a1560;
    --accent-blue: #5b73c9;
    --accent-red-glow: rgba(6, 13, 70, 0.06);
    --accent-blue-glow: rgba(91, 115, 201, 0.06);
    --accent-btn: #060D46;
    --accent-btn-light: #0a1560;
    --accent-shadow: rgba(6, 13, 70, 0.25);
    --accent-shadow-strong: rgba(6, 13, 70, 0.4);
    --tag-success: hsl(152, 72%, 26%);
    --tag-success-bg: rgba(4, 120, 87, 0.12);
    --tag-success-border: rgba(4, 120, 87, 0.28);
}

body.light-mode header.scrolled {
    background: rgba(245, 245, 250, 0.85);
}

body.light-mode .btn-secondary,
body.light-mode .theme-btn,
body.light-mode .social-icon,
body.light-mode .stack-item {
    background: rgba(0, 0, 0, 0.03);
}

body.light-mode .btn-secondary {
    border-color: rgba(6, 13, 70, 0.22);
    color: var(--accent-red);
}

body.light-mode .btn-secondary:hover,
body.light-mode .theme-btn:hover,
body.light-mode .social-icon:hover,
body.light-mode .stack-item:hover {
    background: rgba(6, 13, 70, 0.06);
    border-color: rgba(6, 13, 70, 0.35);
}

body.light-mode .btn-secondary:hover {
    color: var(--accent-red);
}

body.light-mode .project-card,
body.light-mode .blog-card {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

body.light-mode .project-card:hover,
body.light-mode .blog-card:hover {
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--bg-primary);
    overflow-x: clip;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

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

ul {
    list-style: none;
}

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

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
}

strong, b {
    font-weight: 700;
}

::selection {
    background-color: var(--accent-red);
    color: #fff;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-secondary);
    border: 2px solid var(--bg-primary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--bg-tertiary);
}

.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.section-padding {
    padding: 7rem 0 3rem 0;
}

.text-gradient-red {
    background: linear-gradient(135deg, var(--text-primary) 30%, var(--accent-red) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-blue {
    background: linear-gradient(135deg, var(--text-primary) 30%, var(--accent-blue) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.5rem;
    transition: var(--transition-smooth);
}

.glass-card:hover {
    border-color: rgba(255, 255, 255, 0.08);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.glow-spot {
    position: fixed;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-red-glow) 0%, rgba(0,0,0,0) 70%);
    z-index: -1;
    pointer-events: none;
    opacity: 0.45;
}

.glow-1 {
    top: 10%;
    left: 0;
    transform: translateX(-50%);
}

.glow-2 {
    top: 50%;
    right: 0;
    transform: translateX(50%);
    background: radial-gradient(circle, var(--accent-blue-glow) 0%, rgba(0,0,0,0) 70%);
}

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

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.75rem;
    border-radius: 12px;
    font-family: var(--font-heading);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.btn-primary,
a.btn-primary {
    background: linear-gradient(135deg, var(--accent-btn) 0%, var(--accent-btn-light) 100%);
    color: var(--btn-on-accent);
    box-shadow: 0 8px 24px var(--accent-shadow);
    border: none;
}

.btn-primary:hover,
.btn-primary:active,
.btn-primary:focus-visible,
a.btn-primary:hover,
a.btn-primary:active,
a.btn-primary:focus-visible {
    color: var(--btn-on-accent);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px var(--accent-shadow-strong);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 4px 16px var(--accent-shadow);
}

.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.filter-btn:focus-visible,
.theme-btn:focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 2px;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--tag-success-bg);
    border: 1px solid var(--tag-success-border);
    border-radius: 30px;
    color: var(--tag-success);
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 2rem;
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: var(--tag-success);
    border-radius: 50%;
    position: relative;
}

.status-dot::after {
    content: '';
    position: absolute;
    inset: 0;
    background-color: var(--tag-success);
    border-radius: 50%;
    animation: pulse-ring 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.25rem 0;
    transition: var(--transition-smooth);
}

header.scrolled {
    padding: 0.75rem 0;
    background: rgba(12, 12, 16, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
}

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

.logo {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.5rem;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-secondary);
    position: relative;
    padding: 0.25rem 0;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-primary);
}

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

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-links a.btn::after {
    display: none !important;
}

.nav-links a.btn-primary,
.nav-links a.nav-cta-btn {
    color: var(--btn-on-accent) !important;
    padding: 0.5rem 1.2rem;
    border-radius: 8px;
    font-size: 0.9rem;
}

.nav-links a.btn-secondary,
.nav-links a.nav-resume-btn {
    color: var(--text-primary) !important;
    padding: 0.5rem 1.2rem;
    border-radius: 8px;
    font-size: 0.9rem;
}

body.light-mode .nav-links a.nav-resume-btn {
    color: var(--accent-red) !important;
}

.nav-resume-btn,
.resume-download-btn {
    gap: 0.5rem;
}

.timeline-intro {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 4rem;
}

.timeline-intro .timeline-title {
    margin-bottom: 0;
}

.resume-download-btn {
    font-size: 0.95rem;
}

.nav-links a.btn-primary:hover,
.nav-links a.nav-cta-btn:hover {
    color: var(--btn-on-accent) !important;
}

.nav-links a.nav-resume-btn:hover {
    color: var(--text-primary) !important;
}

body.light-mode .nav-links a.nav-resume-btn:hover {
    color: var(--accent-red) !important;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

.theme-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-smooth);
    padding: 0;
}

.theme-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.theme-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
    transition: var(--transition-smooth);
}

body:not(.light-mode) .theme-btn .moon-icon,
body.light-mode .theme-btn .sun-icon {
    display: none;
}

.hero {
    position: relative;
    padding: 11rem 0 5rem 0;
    min-height: 90vh;
    display: flex;
    align-items: center;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 3rem;
    align-items: stretch;
}

.hero-content h1,
.hero-headline {
    font-family: var(--font-heading);
    font-size: 4.5rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -2px;
    margin-bottom: 1.5rem;
}

.hero-headline-intro,
.hero-headline-tagline {
    display: block;
}

.hero-headline-tagline {
    margin-top: 0.1em;
}

.tagline-line-wrap {
    display: inline-grid;
    max-width: 100%;
    text-align: left;
}

.tagline-line-sizer,
.tagline-line-text {
    grid-area: 1 / 1;
    font: inherit;
    letter-spacing: inherit;
    line-height: inherit;
}

.tagline-line-sizer {
    visibility: hidden;
    pointer-events: none;
    user-select: none;
}

.tagline-line-text {
    min-width: 0;
}

.hero-content p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 580px;
    margin-bottom: 2.5rem;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    margin-bottom: 3.5rem;
}

.social-links {
    display: flex;
    gap: 1.25rem;
}

.social-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-size: 1.25rem;
    transition: var(--transition-smooth);
}

.social-icon:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.hero-avatar {
    position: relative;
    display: flex;
    width: 100%;
    min-height: 100%;
    align-self: stretch;
}

.avatar-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 520px;
    border-radius: 16px;
    overflow: hidden;
}

.avatar-img {
    width: 100%;
    height: 100%;
    min-height: 520px;
    border-radius: 16px;
    object-fit: cover;
    object-position: center 20%;
    display: block;
    filter: grayscale(100%);
    transition: filter 0.4s ease;
}

body.light-mode .avatar-img {
    filter: grayscale(50%);
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .avatar-wrapper {
        animation: none;
    }

    .cursor-glow {
        display: none !important;
    }

    .project-card:hover,
    .work-grid--archive .project-card:hover {
        transform: none;
    }

    .project-card:hover .project-media img,
    .gallery-card:hover .gallery-media img {
        transform: none;
    }

    .gallery-card:hover .gallery-media img {
        transform: none;
    }

    .glass-card:hover {
        transform: none;
    }

    .cs-visual video[autoplay] {
        display: none;
    }
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.75rem;
    font-weight: 700;
    letter-spacing: -1px;
    margin-bottom: 3.5rem;
    text-align: center;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: min-content;
    gap: 1.5rem;
}

.bento-card {
    position: relative;
    overflow: hidden;
}

/* Desktop bento: role top-center (2×2), compact stats flank row 2, stack + philosophy bottom row */
.bento-years {
    grid-column: 1;
    grid-row: 1;
}

.bento-role {
    grid-column: 2 / 4;
    grid-row: 1 / 3;
}

.bento-projects {
    grid-column: 4;
    grid-row: 1;
}

.bento-videos {
    grid-column: 1;
    grid-row: 2;
}

.bento-screens {
    grid-column: 4;
    grid-row: 2;
}

.bento-stack {
    grid-column: 1 / 3;
    grid-row: 3 / 5;
}

.bento-philosophy {
    grid-column: 3 / 5;
    grid-row: 3 / 5;
    display: flex;
    align-items: center;
}

.bento-stat {
    align-self: start;
}

.bento-card.compact {
    padding: 1.25rem 1.75rem;
}

.bento-card.compact .stat-num {
    font-size: 2.75rem;
    margin-bottom: 0.35rem;
}

.bento-card.compact .stat-label {
    font-size: 1.05rem;
    margin-bottom: 0.35rem;
}

.bento-card.compact .stat-desc {
    font-size: 0.85rem;
    line-height: 1.45;
}

.bento-card .stat-num {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-red) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.bento-card .stat-label {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.bento-card .stat-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.bento-card .role-box {
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: space-between;
}

.role-tag {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 1.2rem;
    background: linear-gradient(135deg, var(--accent-red) 0%, var(--accent-btn) 100%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(127, 137, 255, 0.25);
}

.role-tag::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 8px #10B981;
    animation: pulse-ring 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

body.light-mode .role-tag {
    background: linear-gradient(135deg, var(--accent-red) 0%, var(--accent-red-light) 100%);
    border-color: rgba(0, 0, 0, 0.05);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(6, 13, 70, 0.18);
}

.stack-title {
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 1.5rem;
    font-size: 1.35rem;
}

.stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 0.85rem;
}

.stack-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: var(--transition-smooth);
    cursor: default;
}

.stack-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent-red);
    transform: translateY(-2px);
}

.stack-item svg {
    width: 28px;
    height: 28px;
    margin-bottom: 0.5rem;
    fill: var(--text-secondary);
    transition: var(--transition-smooth);
}

.stack-item:hover svg {
    fill: var(--accent-red);
    transform: scale(1.1);
}

.stack-icon-group {
    display: flex;
    gap: 0.35rem;
    margin-bottom: 0.5rem;
    align-items: center;
    justify-content: center;
}

.stack-icon-group .dual-icon {
    width: 22px !important;
    height: 22px !important;
    margin-bottom: 0 !important;
}

.stack-item span {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.career-timeline {
    margin-top: 6rem;
    position: relative;
}

.timeline-title {
    font-family: var(--font-heading);
    font-size: 2.25rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 4rem;
    letter-spacing: -0.5px;
}

.timeline-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding-left: 2.5rem;
    border-left: 2px solid var(--border-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 4rem;
}

.timeline-node {
    position: absolute;
    left: -2.85rem;
    top: 0.4rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-blue);
    box-shadow: 0 0 0 4px var(--bg-primary), 0 0 18px var(--accent-blue);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: baseline;
    margin-bottom: 1rem;
}

.timeline-header h4 {
    font-size: 1.35rem;
    font-weight: 700;
}

.timeline-date {
    color: var(--text-muted);
    font-weight: 600;
    white-space: nowrap;
}

.timeline-desc {
    list-style: disc;
    padding-left: 1.2rem;
    color: var(--text-secondary);
}

.timeline-desc li {
    margin-bottom: 0.55rem;
}

.work-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3.5rem;
    flex-wrap: wrap;
}

.filter-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 0.6rem 1.3rem;
    border-radius: 30px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--accent-btn);
    color: var(--btn-on-accent);
    border-color: var(--accent-btn);
}

.filter-btn:active {
    background: var(--accent-btn-light);
    color: var(--btn-on-accent);
    border-color: var(--accent-btn-light);
}

.work-intro {
    text-align: center;
    color: var(--text-secondary);
    max-width: 640px;
    margin: -2rem auto 3rem auto;
    font-size: 1.1rem;
    line-height: 1.65;
}

.work-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(360px, 100%), 1fr));
    gap: 2rem;
}

.work-grid--featured {
    margin-bottom: 4rem;
}

.work-archive {
    margin-top: 1rem;
    padding-top: 3rem;
    border-top: 1px solid var(--border-color);
}

.work-archive-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 1.75rem;
    text-align: center;
}

.work-grid--archive {
    grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
    gap: 1.25rem;
}

.work-grid--archive .project-card:hover {
    transform: none;
    box-shadow: none;
}

.work-grid--archive .project-details {
    padding: 1.25rem 1.5rem;
}

.work-grid--archive .project-title {
    font-size: 1.2rem;
}

.project-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.project-media {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
    background-color: var(--bg-tertiary);
}

a.project-media {
    display: block;
    color: inherit;
    text-decoration: none;
}

.project-media img,
.project-media video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: top center;
    transition: var(--transition-smooth);
}

.project-overlay {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-blue);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.project-details {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.project-category {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-blue);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.project-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1.25;
}

.project-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.project-link {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-family: var(--font-heading);
    color: var(--text-primary);
    border-bottom: 1px dashed var(--accent-red);
    padding-bottom: 2px;
}

.project-link:hover {
    color: var(--accent-blue);
    border-bottom-style: solid;
}

.project-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 0.25rem;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.blog-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    border-color: var(--accent-red);
    background: rgba(255, 255, 255, 0.04);
    transform: translateY(-4px);
}

.blog-media {
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.blog-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.blog-card:hover .blog-media img {
    transform: scale(1.05);
}

.blog-details {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

.blog-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.blog-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.case-study-hero {
    padding: 10rem 0 5rem 0;
    background: radial-gradient(circle at top, var(--accent-red-glow) 0%, rgba(0,0,0,0) 60%);
    border-bottom: 1px solid var(--border-color);
}

.cs-meta {
    display: flex;
    gap: 1.5rem;
    font-family: var(--font-heading);
    font-weight: 500;
    color: var(--accent-blue);
    margin-bottom: 1rem;
    justify-content: center;
}

.cs-title {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -2px;
    text-align: center;
    max-width: 900px;
    margin: 0 auto 2rem auto;
}

.cs-summary {
    font-size: 1.25rem;
    color: var(--text-secondary);
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.case-study-content {
    padding: 5rem 0;
}

.cs-layout {
    display: grid;
    grid-template-columns: 8fr 4fr;
    gap: 4rem;
}

.cs-body h2 {
    font-family: var(--font-heading);
    font-size: 2.25rem;
    font-weight: 700;
    margin: 3.5rem 0 1.5rem 0;
    letter-spacing: -0.5px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}

.cs-body h2:first-of-type {
    margin-top: 0;
}

.cs-body h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin: 2.5rem 0 1rem 0;
    color: var(--text-primary);
}

.cs-body p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.75;
    margin-bottom: 1.5rem;
}

.cs-body ul,
.cs-body ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
    list-style-type: disc;
}

.cs-body ol {
    list-style-type: decimal;
}

.cs-body li {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.75;
    margin-bottom: 0.75rem;
}

.cs-callout {
    padding: 1.5rem;
    border: 1px solid color-mix(in srgb, var(--accent-red) 28%, transparent);
    border-left: 4px solid var(--accent-red);
    background: color-mix(in srgb, var(--accent-red) 10%, transparent);
    border-radius: 12px;
    margin: 2rem 0;
}

.cs-callout p {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.15rem;
    font-weight: 600;
}

.cs-metrics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 2rem 0;
}

.cs-metric-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
}

.cs-metric-num {
    color: var(--accent-blue);
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.75rem;
}

.cs-metric-lbl {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.4;
}

.cs-visual {
    margin: 2rem 0 2.5rem;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.02);
}

.cs-visual img,
.cs-visual video {
    width: 100%;
    display: block;
}

.cs-visual figcaption {
    padding: 0.85rem 1.1rem;
    font-size: 0.9rem;
    color: var(--text-muted);
    border-top: 1px solid var(--border-color);
    line-height: 1.5;
}

.cs-visual-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin: 2rem 0 2.5rem;
}

.cs-visual-grid .cs-visual {
    margin: 0;
}

.cs-hero-visual {
    max-width: 960px;
    margin: 3rem auto 0;
}

.cs-sidebar-card {
    position: sticky;
    top: 6rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem;
}

.cs-sidebar-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.cs-meta-item {
    border-top: 1px solid var(--border-color);
    padding: 1rem 0;
}

.cs-meta-label {
    color: var(--text-muted);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.25rem;
}

.cs-meta-val {
    color: var(--text-primary);
    font-weight: 600;
}

.cs-external-banner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin: 2rem 0 2.5rem;
    padding: 1.25rem 1.5rem;
    border-radius: 14px;
    border: 1px solid rgba(255, 77, 77, 0.25);
    background: linear-gradient(135deg, rgba(255, 77, 77, 0.08), rgba(255, 255, 255, 0.02));
}

.cs-external-banner-text {
    flex: 1;
    min-width: 220px;
}

.cs-external-banner-text strong {
    display: block;
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.cs-external-banner-text p {
    margin: 0;
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.cs-design-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin: 2rem 0 2.5rem;
}

.cs-design-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.35rem;
}

.cs-design-card h3 {
    font-size: 1rem;
    margin: 0 0 0.5rem;
    color: var(--text-primary);
    font-weight: 700;
}

.cs-design-card p {
    margin: 0;
    font-size: 0.92rem;
}

.cs-link-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.cs-quote-grid {
    margin: 2rem 0;
    display: grid;
    gap: 1rem;
}

.cs-quote-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    border-radius: 12px;
}

.cs-quote-card strong {
    color: var(--accent-blue);
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.cs-quote-card p {
    margin: 0;
    font-size: 0.95rem;
}

.cs-table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    border: 1px solid var(--border-color);
    text-align: left;
}

.cs-table thead tr {
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid var(--border-color);
}

.cs-table th,
.cs-table td {
    padding: 1rem;
    color: var(--text-secondary);
}

.cs-table th {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--text-primary);
}

.cs-table tbody tr {
    border-bottom: 1px solid var(--border-color);
}

.section-divider {
    border-top: 1px solid var(--border-color);
}

.role-title {
    font-size: 2.25rem;
    margin-top: 1.5rem;
    line-height: 1.2;
    font-weight: 700;
}

.role-desc {
    color: var(--text-secondary);
    margin-top: 1rem;
    line-height: 1.6;
}

.role-list {
    color: var(--text-muted);
    margin-top: 1.2rem;
    padding-left: 1.25rem;
    font-size: 0.95rem;
    line-height: 1.7;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    list-style: disc;
}

.role-cta {
    margin-top: 2rem;
}

.role-cta .btn {
    width: 100%;
    justify-content: center;
}

.gallery-header {
    padding-top: 10rem;
    text-align: center;
}

.gallery-header .section-title {
    margin-bottom: 1rem;
}

.gallery-intro {
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 3rem auto;
    font-size: 1.15rem;
}

.footer-social {
    margin: 0;
}

.footer-social a + a {
    margin-left: 1rem;
}

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

@media (max-width: 768px) {
    .cs-design-grid {
        grid-template-columns: 1fr;
    }
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
    gap: 1.5rem;
}

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

.gallery-section-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    text-align: left;
}

.gallery-card {
    margin: 0;
    border-radius: 16px;
    overflow: hidden;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: var(--transition-smooth);
}

.gallery-card:hover {
    border-color: rgba(255, 255, 255, 0.12);
}

.gallery-media {
    aspect-ratio: 16 / 10;
    background-color: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.gallery-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: var(--transition-smooth);
}

.gallery-caption {
    padding: 1rem 1.15rem 1.15rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.gallery-project {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.gallery-context {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Legacy selector — gallery.html now uses .gallery-card */
.gallery-item {
    aspect-ratio: auto;
    border-radius: 16px;
    overflow: hidden;
}

.gallery-item .project-media {
    height: auto;
    aspect-ratio: 16 / 10;
}

.gallery-item .project-media img {
    height: 100%;
    width: 100%;
    object-fit: contain;
    transition: var(--transition-smooth);
}

.gallery-item:hover .project-media img,
.gallery-card:hover .gallery-media img {
    transform: scale(1.02);
}

.lightbox-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(12, 12, 16, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    align-items: center;
    justify-content: center;
}

body.light-mode .lightbox-modal {
    background-color: rgba(245, 245, 250, 0.95);
}

.lightbox-modal.active {
    display: flex;
    flex-direction: column;
}

.lightbox-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90%;
    max-height: 90%;
}

.lightbox-content {
    max-width: 100%;
    max-height: 75vh;
    object-fit: contain;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox-caption {
    margin-top: 1rem;
    text-align: center;
    max-width: 560px;
}

.lightbox-caption .gallery-project {
    display: block;
    font-size: 1.05rem;
    margin-bottom: 0.25rem;
}

.lightbox-caption .gallery-context {
    font-size: 0.9rem;
}

.lightbox-close {
    position: absolute;
    top: 2rem;
    right: 2.5rem;
    color: var(--text-primary);
    font-size: 3rem;
    font-weight: 200;
    cursor: pointer;
    line-height: 1;
    transition: var(--transition-smooth);
}

.lightbox-close:hover {
    color: var(--accent-blue);
    transform: rotate(90deg);
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-primary);
    font-size: 3rem;
    font-weight: 200;
    padding: 1.5rem;
    cursor: pointer;
    user-select: none;
    transition: var(--transition-smooth);
}

.lightbox-prev {
    left: 2rem;
}

.lightbox-next {
    right: 2rem;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    color: var(--accent-blue);
}

.footer-back-link {
    font-weight: 600;
    color: var(--accent-red);
}

footer {
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    padding-bottom: 3rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.footer-left h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.footer-left p,
.footer-bottom {
    color: var(--text-secondary);
}

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

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

@keyframes pulse-ring {
    0% { transform: scale(0.95); opacity: 0.5; }
    50% { transform: scale(1.5); opacity: 0; }
    100% { transform: scale(0.95); opacity: 0; }
}

@keyframes zoomIn {
    from { transform: scale(0.92); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bento-years,
    .bento-role,
    .bento-projects,
    .bento-videos,
    .bento-screens,
    .bento-stack,
    .bento-philosophy {
        grid-column: auto;
        grid-row: auto;
    }

    .bento-role,
    .bento-stack,
    .bento-philosophy {
        grid-column: span 2;
    }

    .hero-content h1 {
        font-size: 3.75rem;
    }

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

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

    .section-padding {
        padding: 5rem 0 2rem 0;
    }

    .hero {
        padding-top: 9rem;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }

    .tagline-line-wrap {
        text-align: center;
    }

    .hero-content p {
        margin: 0 auto 2rem auto;
    }

    .hero-actions {
        justify-content: center;
        flex-wrap: wrap;
    }

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

    .avatar-wrapper,
    .avatar-img {
        min-height: 380px;
    }

    .nav-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--bg-secondary);
        border-bottom: 1px solid var(--border-color);
        padding: 2rem;
        box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    }

    .nav-links.open {
        display: flex;
    }

    .bento-grid,
    .blog-grid,
    .cs-layout {
        grid-template-columns: 1fr;
    }

    .bento-years,
    .bento-role,
    .bento-projects,
    .bento-videos,
    .bento-screens,
    .bento-stack,
    .bento-philosophy {
        grid-column: auto;
        grid-row: auto;
    }

    .cs-sidebar-card {
        position: relative;
        top: 0;
    }

    .cs-title {
        font-size: 2.75rem;
    }

    .cs-metrics-grid {
        grid-template-columns: 1fr;
    }

    .cs-visual-grid {
        grid-template-columns: 1fr;
    }

    .footer-content,
    .footer-bottom {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }

    .lightbox-prev,
    .lightbox-next {
        font-size: 2rem;
        padding: 0.5rem;
    }

    .lightbox-prev {
        left: 0.5rem;
    }

    .lightbox-next {
        right: 0.5rem;
    }

    .lightbox-close {
        top: 1rem;
        right: 1.5rem;
        font-size: 2.5rem;
    }
}

@media (max-width: 520px) {
    .hero-content h1 {
        font-size: 3rem;
    }

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

/* ─── Cursor Glow ─── */
.cursor-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-red-glow) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
    will-change: transform;
    transition: opacity 0.3s ease;
}

body.light-mode .cursor-glow {
    background: radial-gradient(circle, var(--accent-red-glow) 0%, transparent 70%);
}

/* ─── About Philosophy ─── */
.bento-philosophy .about-philosophy {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.75;
    margin: 0;
    text-align: left;
    padding: 0;
    border: none;
    border-radius: 0;
    background: none;
    backdrop-filter: none;
    max-width: none;
}

.about-philosophy em {
    color: var(--text-primary);
    font-style: normal;
    font-weight: 600;
}

/* ─── Project Impact Tag ─── */
.project-impact {
    margin-bottom: 0.75rem;
}

.impact-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    padding: 0.3rem 0.75rem;
    border-radius: 20px;
    background: color-mix(in srgb, var(--accent-red) 14%, transparent);
    color: var(--accent-blue);
    border: 1px solid color-mix(in srgb, var(--accent-red) 26%, transparent);
}

body.light-mode .impact-tag {
    background: color-mix(in srgb, var(--accent-red) 10%, transparent);
    color: var(--accent-blue);
    border-color: color-mix(in srgb, var(--accent-red) 20%, transparent);
}

/* ─── Testimonials ─── */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.testimonial-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.testimonial-quote {
    font-size: 4rem;
    line-height: 1;
    color: var(--accent-blue);
    font-family: Georgia, serif;
    opacity: 0.5;
    margin-bottom: -1rem;
}

.testimonial-text {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.75;
    flex-grow: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: auto;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.testimonial-avatar {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-red), var(--accent-blue));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.1rem;
    color: #fff;
}

.testimonial-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.testimonial-role {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

@media (max-width: 900px) {
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
}

/* ─── Hero Proof Line ─── */
.hero-proof {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.6rem 0.9rem;
    margin: -0.75rem 0 2.25rem 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
}

.hero-proof strong {
    color: var(--text-primary);
    font-weight: 600;
}

.hero-proof-sep {
    color: var(--accent-red);
    opacity: 0.6;
}

/* ─── Trusted By Strip ─── */
.trusted-strip {
    padding: 1rem 0 3rem 0;
}

.trusted-label {
    text-align: center;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.trusted-logos {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.5rem 3.5rem;
}

.trusted-logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: var(--text-secondary);
    opacity: 0.55;
    transition: var(--transition-smooth);
    cursor: default;
}

.trusted-logo:hover {
    opacity: 1;
    color: var(--text-primary);
}

/* ─── Project Outcome Stat Thumbnail ─── */
.project-media-stat {
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--accent-red) 30%, transparent) 0%, transparent 55%),
        linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-primary) 100%);
}

.stat-thumb {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1.5rem 2rem;
}

.stat-thumb-tag {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-blue);
    margin-bottom: 0.5rem;
}

.stat-thumb-num {
    font-family: var(--font-heading);
    font-size: 4.5rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -2px;
    background: linear-gradient(135deg, var(--text-primary) 20%, var(--accent-red) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-thumb-label {
    margin-top: 0.65rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    max-width: 240px;
}

.project-card:hover .project-media-stat .stat-thumb-num {
    transform: scale(1.04);
    transition: var(--transition-smooth);
}

/* ─── Contact Section ─── */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3.5rem;
    align-items: start;
}

.contact-intro p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: 2rem;
}

.contact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.contact-direct {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.contact-direct span {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
}

.contact-direct a {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--accent-blue);
}

.contact-direct a:hover {
    color: var(--accent-red-light);
}

.cal-embed-wrap {
    min-height: 640px;
    padding: 0;
    overflow: auto;
    max-width: 100%;
}

.cal-embed-wrap #my-cal-inline-30min,
.cal-embed-inner {
    min-height: 640px;
    width: 100%;
    height: 100%;
    overflow: auto;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-row {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-row label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.85rem 1rem;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition-smooth);
    resize: vertical;
}

body.light-mode .contact-form input,
body.light-mode .contact-form textarea {
    background: rgba(0, 0, 0, 0.03);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-muted);
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-blue);
    background: rgba(255, 255, 255, 0.05);
}

.contact-submit {
    align-self: flex-start;
    border: none;
}

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

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

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

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

/* ─── Staggered Scroll Reveal Delays ─── */
.bento-card:nth-child(1) { transition-delay: 0ms !important; }
.bento-card:nth-child(2) { transition-delay: 80ms !important; }
.bento-card:nth-child(3) { transition-delay: 160ms !important; }
.bento-card:nth-child(4) { transition-delay: 240ms !important; }
.bento-card:nth-child(5) { transition-delay: 320ms !important; }
.bento-card:nth-child(6) { transition-delay: 400ms !important; }
.bento-card:nth-child(7) { transition-delay: 480ms !important; }

.project-card:nth-child(1) { transition-delay: 0ms !important; }
.project-card:nth-child(2) { transition-delay: 80ms !important; }
.project-card:nth-child(3) { transition-delay: 160ms !important; }
.project-card:nth-child(4) { transition-delay: 240ms !important; }
.project-card:nth-child(5) { transition-delay: 320ms !important; }
.project-card:nth-child(6) { transition-delay: 400ms !important; }
.project-card:nth-child(7) { transition-delay: 480ms !important; }
.project-card:nth-child(8) { transition-delay: 560ms !important; }
.project-card:nth-child(9) { transition-delay: 640ms !important; }
.project-card:nth-child(10) { transition-delay: 720ms !important; }

.testimonial-card:nth-child(1) { transition-delay: 0ms !important; }
.testimonial-card:nth-child(2) { transition-delay: 100ms !important; }
.testimonial-card:nth-child(3) { transition-delay: 200ms !important; }
