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

@font-face {
  font-family: 'JetBrains Mono';
  src: url('fonts/jetbrains/variable/JetBrainsMono[wght].ttf') format('truetype');
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'JetBrains Mono';
  src: url('fonts/jetbrains/variable/JetBrainsMono-Italic[wght].ttf') format('truetype');
  font-weight: 100 800;
  font-style: italic;
  font-display: swap;
}

/* 
   OSCAR REGO PORTFOLIO 2026
   MASTER STYLESHEET 
*/
/* 1. RESET & GLOBAL */
/* Cinematic film grain is handled by grain.js — canvas-based, 18fps cinematic */
/* The old body::after TV static (steps(8), opacity:0.12) has been removed    */

/* --- THEME SYSTEM --- */
:root {
    /* Default Dark Mode */
    --bg-main: #050505;
    --bg-page: #000000bc;
    --text-primary: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.5);
    --border-color: rgba(255, 255, 255, 0.1);
    --accent: #d7ff3f;
    --glass-bg: rgba(22, 22, 22, 0.62);
    --grid-line: rgba(255, 255, 255, 0.045);
    --card-bg: rgba(10, 12, 22, 0.65);
    --menu-bg: #f6f6f6;
    --menu-text: #050505;
    --floating-nav-hover: rgba(255, 255, 255, 0.06);
    --timeline-glow: #ffffff;
    --skill-card-bg: linear-gradient(145deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    --timeline-year: rgba(255, 255, 255, 0.04);
    --pad-x: clamp(24px, 6vw, 100px);
    --pad-x-sm: clamp(16px, 4vw, 60px);
    --font-display: 'Bebas Neue', sans-serif;
    --font-body: 'JetBrains Mono', 'Inter', monospace;
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

.theme-light {
    --bg-main: #f5f5f7;
    --bg-page: #f5f5f7;
    --text-primary: #121212;
    --text-muted: rgba(0, 0, 0, 0.5);
    --border-color: rgba(0, 0, 0, 0.08);
    --accent: #2e6ff2; /* Premium blue accent for light mode */
    --glass-bg: rgba(255, 255, 255, 0.75);
    --grid-line: rgba(0, 0, 0, 0.045);
    --card-bg: rgba(255, 255, 255, 0.85);
    --menu-bg: #121212;
    --menu-text: #ffffff;
    --floating-nav-hover: rgba(0, 0, 0, 0.04);
    --timeline-glow: #2e6ff2;
    --skill-card-bg: linear-gradient(145deg, rgba(0, 0, 0, 0.02) 0%, rgba(0, 0, 0, 0.01) 100%);
    --timeline-year: rgba(0, 0, 0, 0.03);
}

body {
    background-color: var(--bg-main) !important;
    transition: background-color 0.4s ease, color 0.4s ease;
}

.theme-light body {
    background: var(--bg-page);
    color: var(--text-primary);
}

.theme-light #works {
    background: var(--bg-main);
}

.theme-light .hero-content h1,
.theme-light .timeline-heading h1,
.theme-light .skills h2,
.theme-light .timeline-left h2 {
    color: var(--text-primary);
}

.theme-light .hero-content h1 {
    text-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.theme-light .floating-nav {
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.theme-light .floating-nav a {
    color: var(--text-muted);
}

.theme-light .floating-nav a:hover,
.theme-light .floating-nav a.active {
    color: var(--text-primary);
    background: var(--floating-nav-hover);
}

.theme-light .works-mode-btn {
    color: var(--text-muted);
}

.theme-light .works-mode-btn.active,
.theme-light .works-mode-btn:hover {
    color: var(--text-primary);
}

.theme-light .works-mode-toggle {
    color: var(--text-primary);
    text-shadow: 0 4px 12px rgba(255,255,255,0.8);
}

.theme-light .works-menu-button {
    background: var(--menu-bg);
    color: var(--menu-text);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

.theme-light body.menu-open .works-menu-button {
    background: rgba(255, 255, 255, 0.98); /* White panel background */
    backdrop-filter: blur(28px) saturate(180%);
    -webkit-backdrop-filter: blur(28px) saturate(180%);
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.theme-light .works-menu-panel {
    background: transparent;
    border: none;
    box-shadow: none;
    color: #000000;
}

.theme-light .works-menu-content p,
.theme-light .works-menu-currently p {
    color: #000000;
}

.theme-light .works-menu-currently-label,
.theme-light .works-menu-footer-email a {
    color: rgba(0, 0, 0, 0.5);
}

.theme-light .works-menu-x {
    background: #000000;
    color: #ffffff;
}

.theme-light .works-menu-social {
    color: #ffffff;
}

.theme-light .works-menu-footer-links a {
    background: #000000;
    color: #ffffff !important;
}

.theme-light .works-menu-footer {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.theme-light .works-menu-scrim {
    background: rgba(255,255,255,0.8);
}

.theme-light .works-grid-bg {
    background-image:
        linear-gradient(var(--grid-line) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
        linear-gradient(rgba(0,0,0,0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,0,0,0.015) 1px, transparent 1px);
    mask-image: linear-gradient(to right, transparent 0%, white 12%, white 84%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, white 12%, white 84%, transparent 100%);
}

.theme-light .works-list a {
    color: rgba(0,0,0,0.85);
}

.theme-light .works-list a:hover {
    color: #000;
}

.theme-light .works-list:hover a {
    opacity: 0.15;
}

.theme-light #works::before {
    background:
        radial-gradient(circle at 50% 42%, rgba(0,0,0,0.02), transparent 30%),
        radial-gradient(circle at 12% 18%, rgba(46,111,242,0.05), transparent 15%),
        radial-gradient(circle at 78% 72%, rgba(80,90,255,0.06), transparent 22%);
}

.theme-light #works::after {
    background:
        radial-gradient(ellipse at center, transparent 34%, rgba(255,255,255,0.4) 72%, rgba(255,255,255,0.9) 100%),
        linear-gradient(to bottom, rgba(255,255,255,0.1), rgba(255,255,255,0.8));
}

.theme-light .work-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    box-shadow: 0 20px 50px rgba(0,0,0,0.12), inset 0 1px 0 rgba(255,255,255,0.8);
}

.theme-light .timeline-line {
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.1) 10%, rgba(0,0,0,0.1) 90%, transparent 100%);
}

.theme-light .timeline-glow {
    background: var(--timeline-glow);
    box-shadow: 0 0 15px var(--accent), 0 0 30px rgba(46,111,242,0.4);
}

.theme-light .timeline-year {
    color: var(--timeline-year);
}

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

.theme-light .timeline-left span {
    color: var(--accent);
}

.theme-light .intro-block p,
.theme-light .intro-main {
    color: var(--text-muted);
}

.theme-light .intro-block .label,
.theme-light .intro-sub {
    color: var(--accent);
}

.theme-light .skill-card {
    background: var(--skill-card-bg);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.theme-light .skill-card span {
    color: var(--text-muted);
}

.theme-light .skill-card:hover span {
    color: var(--text-primary);
}

.theme-light .works-marquee-ring text {
    fill: var(--text-muted);
}

.theme-light .status-dot {
    background: var(--accent);
}

.theme-light .hero-status-line {
    color: var(--text-muted);
}

.theme-light ::selection {
    background: var(--accent);
    color: #fff;
}
.theme-light ::-moz-selection {
    background: var(--accent);
    color: #fff;
}

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

*::before, *::after {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Exceptions: Allow selection inside inputs, textareas, forms, code blocks, or elements explicitly marked selectable */
input, 
textarea, 
select, 
pre, 
code, 
kbd, 
samp, 
[contenteditable="true"], 
.selectable {
    user-select: text;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
}

::selection {
    background: #d7ff3f;
    color: #131313;
}

::-moz-selection {
    background: #d7ff3f;
    color: #131313;
}

html{
    background: #3f3f3f;
}

/* LENIS SMOOTH SCROLL BOILERPLATE */
html.lenis, html.lenis body {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

.lenis.lenis-stopped {
    overflow: hidden;
}

.lenis.lenis-smooth iframe {
    pointer-events: none;
}

/* 2. LIQUID GLASS TOP STRIP */

body::before{
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 15px;
    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0.005) 0%,
        transparent 100%
    );
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 15%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 15%, transparent 100%);
    mask-composite: source-over;
    -webkit-mask-composite: source-over;
    pointer-events: none;
    z-index: 1500;
}

/* CUSTOM CURSOR SYSTEM - DISABLED
.mouse-glow{
    opacity: 0;
}
*/
/* 3. BODY & FONTS */

@font-face{
    font-family: 'PixelOperator';
    src: url('fonts/PixelOperator.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face{
    font-family: 'Mynor';
    src: url('fonts/MynorBookCondensed.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

body {
    margin: 0;
    font-family: 'Mynor', sans-serif;
    background: #000000bc;
    color: white;
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* Desktop-only: custom cursor (fine pointer / real mouse only) */
/* CUSTOM CURSOR SYSTEM - DISABLED
@media (hover: hover) and (pointer: fine) {
    body {
        cursor: none !important;
    }

    a, button, input, textarea, select, [role="button"] {
        cursor: none !important;
    }
}
*/

a{
    text-decoration: none;
    color: inherit;
}

/* 4. FLOATING NAV (PREMIUM LIQUID GLASS) */

.floating-nav{
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;

    padding: 5px 8px;
    border-radius: 999px;

    /* Premium multi-layer glass */
    background: rgba(22, 22, 22, 0.62);
    border: 1px solid rgba(255, 255, 255, 0.10);

    /* Higher blur + saturation for glass depth */
    backdrop-filter: blur(28px) saturate(180%) brightness(1.05);
    -webkit-backdrop-filter: blur(28px) saturate(180%) brightness(1.05);

    /* Multi-layer shadow: depth + top specular highlight + bottom shadow */
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.45),
        0 2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.09),  /* top specular edge */
        inset 0 -1px 0 rgba(0, 0, 0, 0.25);        /* bottom inner shadow */

    z-index: 2000;
    transition: box-shadow 0.4s cubic-bezier(0.2, 0.8, 0.2, 1),
                background 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}



.floating-nav a{
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 18px;
    height: 34px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2px;
    border-radius: 999px;
    position: relative;
    transition: color 0.35s cubic-bezier(0.2, 0.8, 0.2, 1),
                background 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.floating-nav a:hover{
    color: #ffffff;
    background: rgba(255, 255, 255, 0.06);
}

.floating-nav a.active{
    color: #ffffff;
    
}

body.works-in-view .floating-nav{
    opacity: 0;
    pointer-events: none;
    transform: translateX(-50%) translateY(-18px) scale(0.94);
}

/* Active page indicator: subtle accent dot under text */

/* 5. SOCIAL SIDEBAR */

.social-sidebar{
    position: fixed;
    left: 28px;
    bottom: 40px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    z-index: 999;
}

.social-sidebar a{
    color: #777777;
    font-size: 14px;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    transition: 0.3s ease;
}

.social-sidebar a:hover{
    color: #d7ff3f;
}

/* 6. HERO SECTION (GROUNDED EDITORIAL) */

.hero{
    position: relative;
    z-index: 2;

    min-height: 88vh;

    display: flex;
    justify-content: center;
    align-items: center;

    text-align: center;

    padding: 310px 8% 0;
}

.hero-content{
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    transform: translateY(10px);
}

.hero-intro{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 60px;
    margin-bottom: 50px;
    text-align: left;
    width: 100%;
    max-width: 1200px;
}

.intro-block{
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.intro-block .label{
    font-size: 11px;
    letter-spacing: 3px;
    color: rgba(215, 255, 63, 0.7);
    font-weight: 600;
}

.intro-block p{
    font-size: 13px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hero-content h1{
    font-family: 'PixelOperator', monospace;
    font-size: 300px;
    line-height: 0.85;
    font-weight: normal;
    letter-spacing: -4px;
    margin-bottom: 0;
    color: white;
    white-space: nowrap;
    user-select: none;
    -webkit-user-select: none;
    margin-bottom: 160px;
    
}

.hero-status-line{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    font-size: 11px;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
}

.status-dot{
    width: 4px;
    height: 4px;
    background: #d7ff3f;
    border-radius: 50%;
    opacity: 0.6;
}

/* 7. PROJECT SHOWCASE (ORBIT) */

.project-showcase{
    padding: 25px 40px; /* Significantly tighter vertical pacing */
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
}

.project-container{
    display: grid;
    grid-template-columns: 1.8fr 1fr;
    align-items: flex-start; /* Perfect top edge alignment */
}

/* MEDIA WRAPPER */

.project-media-wrapper{
    position: relative;
    /* Width is fluid: 870px removed — now fills grid column naturally */
    width: 100%;
    max-width: 870px;
    aspect-ratio: 870 / 670;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.7);
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
    -webkit-touch-callout: none;
}

.project-media-wrapper:hover{
    transform:none;
}

/* Orbit View Toggle Button */
.orbit-view-toggle {
    position: absolute;
    bottom: 24px;
    right: 24px;

    background: transparent;
    border: none;

    color: rgba(255, 255, 255, 0.795);

    font-family: 'PixelOperator', monospace;
    font-size: 34px;

    width: auto;
    height: auto;

    display: flex;
    align-items: center;
    justify-content: center;

    cursor: pointer;
    z-index: 10;
}

.orbit-view-toggle span {
    display: block;
    color: inherit;
}

.orbit-view-toggle span {
    display: inline-block;
    line-height: 1;
    transform: translateY(-2px); /* Slight vertical nudge for perfect PixelOperator centering */
}



.project-media-placeholder{
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a1a1a 0%, #111111 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.project-media-placeholder::before{
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.03;
}

/* ORBIT SPECIFIC */
.orbit-placeholder{
    background: linear-gradient(135deg, #1a1a1a 0%, #0d1117 100%);
}

/* AUTOSHOOTER SPECIFIC */
.technical-placeholder{
    background: #0a0a0a;
}

/* JSMS SPECIFIC (LUXURY / COMMERCE) */
.jsms-placeholder{
    background: linear-gradient(135deg, #141414 0%, #1a1612 100%); /* Warmer base */
}

.luxury-glow{
    position: absolute;
    width: 50%;
    height: 50%;
    background: radial-gradient(circle, rgba(255, 215, 100, 0.04) 0%, transparent 70%); /* Subtle gold/warm tint */
    filter: blur(60px);
    animation: floatGlowLuxury 12s ease-in-out infinite alternate;
}

@keyframes floatGlowLuxury{
    from { transform: translate(15%, -10%); opacity: 0.5; }
    to { transform: translate(-15%, 15%); opacity: 1; }
}

.placeholder-grid{
    position: absolute;
    width: 100%; height: 100%;
    background-image: 
        linear-gradient(rgba(215, 255, 63, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(215, 255, 63, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.5;
}

.placeholder-scan-line{
    position: absolute;
    top: 0; left: 0; width: 100%; height: 2px;
    background: linear-gradient(to right, transparent, rgba(215, 255, 63, 0.2), transparent);
    box-shadow: 0 0 15px rgba(215, 255, 63, 0.1);
    z-index: 3;
    animation: scanMove 4s linear infinite;
}

@keyframes scanMove{
    0%{ top: 0%; }
    100%{ top: 100%; }
}

.placeholder-content{ text-align: center; z-index: 5; display: flex; flex-direction: column; gap: 8px; }
.placeholder-title{ font-size: 14px; letter-spacing: 4px; color: #fff; font-weight: 600; }
.placeholder-subtitle{ font-size: 10px; letter-spacing: 2px; color: rgba(255,255,255,0.4); text-transform: uppercase; }

.placeholder-glow{
    position: absolute;
    width: 40%; height: 40%;
    background: radial-gradient(circle, rgba(215, 255, 63, 0.05) 0%, transparent 70%);
    filter: blur(40px);
    animation: floatGlow 8s ease-in-out infinite alternate;
}

@keyframes floatGlow{ from {transform: translate(-20%,-20%)} to {transform: translate(20%,20%)} }

.project-info{ display: flex; flex-direction: column; gap: 20px; padding-top: 8px; }
.project-category{ font-size: 10px; letter-spacing: 3px; color: #d7ff3f; font-weight: 600; text-transform: uppercase; }
.project-title{ 
    font-family: 'PixelOperator', monospace; 
    font-size: 30px; line-height: 1.05; color: #fff;
    user-select: none; -webkit-user-select: none;
    letter-spacing: -1.5px;
    margin-bottom: 6px;
}
.project-description{ font-size: 16px; line-height: 1.8; color: rgba(255,255,255,0.5); max-width: 440px; margin-bottom: 12px; }
.project-features{ list-style: none; display: flex; flex-direction: column; gap: 14px; }
.project-features li{ font-size: 14px; color: rgba(255,255,255,0.4); display: flex; align-items: center; gap: 14px; transition: 0.3s; }
.project-features li::before{ content: ""; width: 5px; height: 5px; background: #d7ff3f; border-radius: 50%; opacity: 0.6; box-shadow: 0 0 8px rgba(215, 255, 63, 0.6);}
.project-features li:hover{ color: #fff; transform: translateX(5px); }

/* 8. TIMELINE (ASYMMETRIC) */

.timeline-section{
    position: relative;
    width: 100%;
    padding: 180px 8%;
    
}

.timeline-wrapper{
    position: relative;
    max-width: 1400px;
    margin: 0 auto;
    padding: 80px 0;
}

.timeline-line{
    position: absolute;
    left: 38%; top: 0;
    transform: translateX(-50%);
    width: 1px; height: 100%;
    background: linear-gradient(to bottom, 
        transparent 0%, 
        rgba(255,255,255,0.15) 10%, 
        rgba(255,255,255,0.15) 90%, 
        transparent 100%);
}

.timeline-glow{
    position: absolute;
    left: 38%; top: 0;
    transform: translate(-50%, 0);
    width: 12px; height: 12px;
    border-radius: 50%;
    background: #ffffff;
    z-index: 20;
    box-shadow: 0 0 20px #d7ff3f, 0 0 45px rgba(215,255,63,0.8);
    will-change: transform;
}

.timeline-item{
    display: grid;
    grid-template-columns: 1.4fr 1fr 2.2fr;
    gap: 80px;
    align-items: center;
    margin-bottom: 180px;
    position: relative;
    z-index: 2;
}

.timeline-item:last-child{
    margin-bottom: 0;
}

.timeline-left{ text-align: right; padding-right: 40px; }
.timeline-left h2{ font-size: 38px; line-height: 1.1; color: #ffffff; margin-bottom: 12px; letter-spacing: 0.5px; }
.timeline-left span{ font-size: 14px; color: rgba(215, 255, 63, 0.85); letter-spacing: 2.5px; text-transform: uppercase; font-weight: 600; }
.timeline-year{ font-size: 96px; font-weight: 700; text-align: center; color: rgba(255,255,255,0.04); letter-spacing: -4px; line-height: 1; transform: translateX(-15%); }
.timeline-right{ font-size: 16px; line-height: 1.8; color: rgba(255,255,255,0.6); max-width: 500px; padding-left: 20px; }

/* 9. SKILLS (MARQUEE) */

.skills{
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 165px 0 80px;
    text-align: center;
    position: relative;
    width: min(1600px, 100%);
    margin: 0 auto;
    isolation: isolate;
    z-index: 10;
}

.skills h2{ 
    font-size: 56px; 
    margin-bottom: 50px; 
    letter-spacing: 6px; 
    color: rgb(255, 255, 255); 
    padding: 0 8%;
   
}

.marquee-wrapper{ position: relative; display: flex; flex-direction: column; gap: 24px; width: 100%; padding: 20px 0; z-index: 2; }

.marquee-content{ display: flex; flex-shrink: 0; gap: 24px; min-width: max-content; padding-right: 24px; }

.top-row .marquee-content{ animation: scrollLeft 40s linear infinite; }
.bottom-row .marquee-content{ animation: scrollRight 50s linear infinite; }

@keyframes scrollLeft{ from{transform: translate3d(0,0,0)} to{transform: translate3d(-50%,0,0)} }
@keyframes scrollRight{ from{transform: translate3d(-50%,0,0)} to{transform: translate3d(0,0,0)} }

.skill-card{
    width: 140px; height: 130px; flex-shrink: 0; border-radius: 20px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.04);
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px); display: flex; flex-direction: column;
    justify-content: center; align-items: center; gap: 14px;
    transition: 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); will-change: transform;
    
}

.skill-card:hover {
    transform: translateY(-8px) scale(1.03);
    z-index: 100;
    
}

.skill-card img{ width: 42px; height: 42px; filter: grayscale(0.4) brightness(0.8); transition: 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); }
.skill-card:hover img{ filter: grayscale(0) brightness(1.2) drop-shadow(0 0 10px rgba(227, 227, 227, 0.368)); transform: scale(1.1); }
.skill-card span{ font-size: 13px; font-weight: 500; color: rgba(255,255,255,0.6); transition: 0.3s; }
.skill-card:hover span{ color: #ffffff; }





/* 11. PIXEL CURSOR (ADAPTIVE) */

/* CUSTOM CURSOR SYSTEM - DISABLED
    .mouse-glow{
    position: fixed;
    width: 12px; height: 12px;
    background: #d7ff3f;
    pointer-events: none;
    z-index: 9999999;
    transform: translate(-50%, -50%) scale(1);
    mix-blend-mode: difference;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), border-radius 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    border-radius: 0;
    will-change: transform, border-radius;
}

.mouse-glow.hovering {
    transform: translate(-50%, -50%) scale(2.7);
    border-radius: 2px;
}

.view-tooltip {
    position: fixed;
    top: 0; left: 0;
    pointer-events: none;
    z-index: 9999998;
    background: rgba(30, 30, 30, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 8px 10px;
    color: rgba(255, 255, 255, 0.65);
    font-size: 11px;
    letter-spacing: 2px;
    font-weight: 500;
    opacity: 0;
    transform: translate(15px, -50%) scale(0.8);
    transition: opacity 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform, opacity;
    display: flex;
    align-items: center;
    justify-content: center;
}

.view-tooltip.active {
    opacity: 1;
    transform: translate(18px, -50%) scale(1);
}
*/

/* 12. RESPONSIVE */

@media(max-width: 1100px){
    .project-container, .project-container.reverse{ 
        grid-template-columns: 1fr; 
        gap: 60px; 
    }
    
    .project-media-wrapper{
        order: 1 !important;
    }
    
    .project-info{ 
        order: 2 !important;
        text-align: center; 
        align-items: center; 
    }
    
    .project-description{ margin: 0 auto; }
    .project-features{ align-items: center; }
    /* Fluid h1 scaling — no nowrap overflow at mid sizes */
    .hero-content h1{ 
        font-size: clamp(80px, 13vw, 180px);
        white-space: normal;
        word-break: keep-all;
    }
}

@media(max-width: 900px){
    .hero-intro{ flex-direction: column; gap: 30px; align-items: center; text-align: center; }
    .hero-content h1{ font-size: 80px; }
    .hero-status-line{ flex-direction: column; gap: 10px; }
    .status-dot{ display: none; }
    .timeline-item{ grid-template-columns: 1fr; gap: 20px; padding-left: 60px; }
    .timeline-line, .timeline-glow{ left: 30px; }
    .timeline-year, .timeline-left{ text-align: left; }
    .social-sidebar{ display: none; }
    
    /* Orbit Mobile Toggle Overrides */
    .orbit-view-toggle {
        background: transparent !important;
        border: none !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: none !important;
        width: auto !important;
        height: auto !important;
        right: 13px !important;
        bottom: 5px !important;
        font-size: 8px !important;
        color: rgba(255, 255, 255, 0.6) !important;
        letter-spacing: 1px !important;
        transform: none !important;

    }
    
    .orbit-view-toggle span {
        display: none !important;
    }
    
    @keyframes orbitMobileTextPulse {
        0%, 100% { opacity: 0.55; }
        50% { opacity: 0.85; }
    }

    .orbit-view-toggle::after {
        content: attr(data-mobile-text);
        display: block;
        animation: orbitMobileTextPulse 3s ease-in-out infinite;
    }

    /* Orbit Mobile Video Size Fix - Scaling only the video */
    #orbit-wrapper.is-mobile-video {
        background: #000 !important; /* Premium framing behind scaled video */
    }
    
    #orbit-video.orbit-video-mobile {
    transform: scale(0.92) !important;
}
}


@media(max-width: 900px){

    #orbit-video.orbit-video-mobile{
        border-radius: 10px;
    }

}

/* TOUCH DEVICE OVERRIDES (Cursor & Tooltip Disable) */
/* CUSTOM CURSOR SYSTEM - DISABLED
@media (hover: none), (pointer: coarse) {
    .mouse-glow, .view-tooltip {
        display: none !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }

    body {
        cursor: auto !important;
    }

    a, button, input, textarea, select, [role="button"] {
        cursor: pointer !important;
    }
}
*/

@media(max-width: 600px){
    .hero-content h1{ font-size: 48px; }
    .project-title{ font-size: 32px; }
    .floating-nav{ width: calc(100% - 24px); }
    .footer-content{ flex-direction: column; gap: 40px; }
}

.cinematic-intro{
    display: flex;
    flex-direction: column;
    align-items: center;
transform: translateY(-80px);
    gap: 18px;

    margin-bottom: 24px;

    max-width: 1100px;
    text-align: center;
}

.intro-main{
    max-width: 980px;
    
    font-size:14px;
    line-height: 1.6;

    color: rgba(255,255,255,0.9);

    text-transform: uppercase;
    letter-spacing: 1px;
}

.intro-sub{
    font-size: 13px;

    color: #d7ff3f;

    letter-spacing: 2px;
    text-transform: uppercase;
}

.project-video{
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transform: scale(1.01);

    filter:
        brightness(0.92)
        contrast(1.05)
        saturate(1.05);

    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
    -webkit-touch-callout: none; /* Prevent iOS long-press save menu */
}

.p {
    text-align: justify;
}

.project-description {
    text-align: justify;
}


.project-description {
    border-left: 0.1px dashed rgba(157, 155, 155, 0.4);
    padding-left: 20px;
    margin: 24px 0;
}

.skills{
    padding-bottom: 90px;
}

.timeline-heading{
    text-align: center;
    margin-bottom: 100px;
}

.timeline-heading h1{
    font-size: 90px;   /* Increase this */
    line-height: 0.9;
    color: white;
}

.timeline-heading span{
    color: #d7ff3f;
}

/* Section Counter */
.section-counter {
    display: block;
    font-family: 'PixelOperator', monospace;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}   

/* 14. IMMERSIVE WORKS SHOWCASE */

#works{
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 720px;
    overflow: hidden;
    background: #050505;
    isolation: isolate;
    perspective: 1400px;
    perspective-origin: 50% 50%;
    z-index: 4;
    contain: strict;
}

#works::before{
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 50% 42%, rgba(255,255,255,0.05), transparent 30%),
        radial-gradient(circle at 12% 18%, rgba(215,255,63,0.09), transparent 15%),
        radial-gradient(circle at 78% 72%, rgba(80,90,255,0.12), transparent 22%);
    filter: blur(12px);
    opacity: 0.9;
    pointer-events: none;
    will-change: transform;
}

#works::after{
    content: "";
    position: absolute;
    inset: -1px;
    background:
        radial-gradient(ellipse at center, transparent 34%, rgba(0,0,0,0.42) 72%, rgba(0,0,0,0.88) 100%),
        linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.78));
    pointer-events: none;
    z-index: 2;
    will-change: opacity;
}

.works-grid-bg{
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.045) 1px, transparent 1px),
        linear-gradient(rgba(255,255,255,0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.018) 1px, transparent 1px);
    background-size: 78px 78px, 78px 78px, 26px 26px, 26px 26px;
    mask-image: linear-gradient(to right, transparent 0%, black 12%, black 84%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 12%, black 84%, transparent 100%);
    opacity: 0.55;
    z-index: 0;
    pointer-events: none;
    will-change: opacity;
}

.works-ambient{
    position: absolute;
    width: 34vw;
    aspect-ratio: 1;
    border-radius: 999px;
    filter: blur(70px);
    opacity: 0.33;
    pointer-events: none;
    z-index: 1;
    animation: worksAmbient 11s ease-in-out infinite alternate;
}

.works-ambient-a{
    left: 12%;
    top: 10%;
    background: rgba(215,255,63,0.22);
}

.works-ambient-b{
    right: 12%;
    bottom: 5%;
    background: rgba(57,92,255,0.28);
    animation-delay: -5s;
}

@keyframes worksAmbient{
    from{ transform: translate3d(-3%, -4%, 0) scale(0.9); }
    to{ transform: translate3d(4%, 5%, 0) scale(1.12); }
}

.works-logo-orb{
    position: absolute;
    top: 40px;
    left: 40px;
    width: 78px;
    height: 78px;
    border-radius: 50%;
    background:
        radial-gradient(circle at 35% 25%, #effff3 0 10%, transparent 21%),
        radial-gradient(circle at 55% 62%, #072317 0 16%, transparent 37%),
        conic-gradient(from 140deg, #f1ff57, #5affc6, #0b3b2f, #fbff8f, #f1ff57);
    box-shadow: 0 20px 45px rgba(0,0,0,0.45), inset 0 -18px 28px rgba(0,0,0,0.42);
    z-index: 8;
    cursor: pointer;
}

.works-logo-orb .orb-face {
    position: absolute;
    top: 16%;
    left: 28%;
    right: 12%;
    bottom: 20%;
    width: 60%;
    height: 64%;
    pointer-events: none;
    transform: rotate(-10deg); /* Tilt towards top-right */
}

/* Hide all face states by default */
.works-logo-orb .orb-face .face-state {
    display: none;
}

/* Toggle active states */
.works-logo-orb:not(.emotion-squint):not(.emotion-neutral):not(.emotion-sad) .state-normal {
    display: block;
}
.works-logo-orb.emotion-squint .state-squint {
    display: block;
}
.works-logo-orb.emotion-neutral .state-neutral {
    display: block;
}
.works-logo-orb.emotion-sad .state-sad {
    display: block;
}

/* Style SVG face elements */
.works-logo-orb .orb-face .eye {
    fill: #e6fffb;
    filter: drop-shadow(0 0 3px #1ad1a5) drop-shadow(0 0 6px #1ad1a5);
}

.works-logo-orb .orb-face .mouth-line {
    fill: none;
    stroke: #e6fffb;
    stroke-linejoin: round;
    filter: drop-shadow(0 0 3px #1ad1a5) drop-shadow(0 0 6px #1ad1a5);
}

.works-logo-orb .orb-face .mouth-line-flat {
    fill: #e6fffb;
    filter: drop-shadow(0 0 3px #1ad1a5) drop-shadow(0 0 6px #1ad1a5);
}



.works-mode-toggle{
    position: absolute;
    top: 36px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 18px;
    color: rgba(255,255,255,0.95);
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 400;
    font-size: 18px; /* Reduced by ~15% */
    line-height: 1;
    z-index: 12;
    text-shadow: 0 8px 28px rgba(0,0,0,0.55);
}

.works-mode-btn{
    appearance: none;
    border: 0;
    background: transparent;
    color: rgba(255,255,255,0.32);
    font: inherit;
    padding: 0;
    transition: color 0.3s ease;
    height: 21px; /* Match font-size */
    overflow: hidden;
    cursor: pointer;
}

.mode-text-wrapper{
    display: flex;
    flex-direction: column;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.mode-text-item{
    display: block;
    height: 21px;
    line-height: 21px;
}

.works-mode-btn:hover .mode-text-wrapper{
    transform: translateY(-21px);
}

.works-mode-btn.active,
.works-mode-btn:hover{
    color: #fff;
}

.works-menu-button{
    position: absolute;
    font-weight: 200;
    top: 30px;
    right: 28px;
    width: 86px;
    height: 46px;
    border: 0;
    border-radius: 999px;
    background: #f6f6f6;
    color: #050505;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 530;
    font-size: 19px;
    line-height: 1;
    z-index: 31;
    box-shadow: 0 22px 50px rgba(0,0,0,0.35);
    transform-origin: calc(100% - 30px) 26px;
    transition: 
        width 0.85s cubic-bezier(0.16, 1, 0.3, 1),
        height 0.85s cubic-bezier(0.16, 1, 0.3, 1),
        border-radius 0.85s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.85s cubic-bezier(0.16, 1, 0.3, 1),
        top 0.85s cubic-bezier(0.16, 1, 0.3, 1),
        right 0.85s cubic-bezier(0.16, 1, 0.3, 1);
}

.works-menu-button:hover{
    transform: translateY(-2px) scale(1.03);
}

.menu-close-text,
.works-menu-x{
    display: none;
}

body.menu-open .works-menu-button{
    top: 38px;
    right: 38px;
    width: 480px; /* Reduced panel width */
    max-width: 90vw;
    height: min(854px, calc(100vh - 76px));
    border-radius: 23px;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 16px 28px; /* Moved close controls upward by ~12px */
    gap: 0;
    transform: none;
}

.menu-close-controls{
    display: none;
    align-items: center;
    gap: 16px;
    pointer-events: none; /* Let the button handle clicks or ensure children are clickable */
}

body.menu-open .menu-close-controls{
    display: flex;
    pointer-events: auto;
}

body.menu-open .menu-open-text,
body.menu-open .works-menu-dot{
    display: none;
}

body.menu-open .menu-close-text,
body.menu-open .works-menu-x{
    display: inline-flex;
}

.works-menu-x{
    display: none;
    width: 46px;
    height: 46px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #050505;
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    border: none;
    flex-shrink: 0;
}

.works-menu-scrim{
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.58);
    backdrop-filter: blur(0);
    -webkit-backdrop-filter: blur(0);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease, backdrop-filter 1.1s ease, -webkit-backdrop-filter 1.1s ease;
    z-index: 20;
}

body.menu-open .works-menu-scrim{
    opacity: 1;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    pointer-events: auto;
}

.works-menu-panel{
    position: absolute;
    top: 38px;
    right: 38px;
    width: 480px; /* Reduced panel width */
    max-width: 90vw;
    height: min(854px, calc(100vh - 76px));
    border-radius: 23px;
    color: #050505;
    z-index: 32;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Space content and footer */
    padding: 70px 44px 28px 56px;
    pointer-events: none;
    visibility: hidden;
    
    /* Unified entry/exit state */
    opacity: 0;
    transform: translate3d(0, 20px, 0) scale(0.98);
    transition: 
        opacity 0.65s ease, 
        visibility 0s linear 0.65s,
        transform 0.85s cubic-bezier(0.16, 1, 0.3, 1);
}

body.menu-open .works-menu-panel{
    opacity: 1;
    visibility: visible;
    transform: translate3d(0,0,0) scale(1);
    /* Tiny delay to let button expand slightly first */
    transition-delay: 0.15s;
}

.works-menu-links {
    display: flex;
    flex-direction: column;
    
    gap: 0px;
    flex: 1;
    justify-content: center;
    padding-top: 40px;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.7s ease, transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

body.menu-open .works-menu-links {
    opacity: 1;
    transform: translateY(-20px);
    transform: translateX(-10px);
    transition-delay: 0.35s;
}

.works-menu-links a {
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(46px, 5.2vw, 70px);
    font-weight: 400;
    line-height: 1.15;
    color: #050505;
    text-decoration: none;
    letter-spacing: -0.03em;
    display: flex;
    align-items: center;
    gap: 0;
    padding-right: 30px;
    padding-left: 0px;
    padding-bottom: 0px;
    transition: padding-left 0.45s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.3s ease;
    position: relative;
    cursor: pointer;
}

/* Bullet dot — hidden by default, slides in on hover */
.menu-bullet {
    display: inline-flex;
    align-items: center;
    font-size: 1.3em;
    line-height: 1;
    opacity: 0;
    max-width: 0;
    margin-right: 0;
    overflow: hidden;
    flex-shrink: 0;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                max-width 0.45s cubic-bezier(0.16, 1, 0.3, 1),
                margin-right 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Hover only: bullet slides in, text shifts right smoothly */
.works-menu-links a:hover .menu-bullet {
    opacity: 1;
    max-width: 28px;
    margin-right: 10px;
}

.works-menu-links a:hover {
    padding-left: 2px;
}

.works-menu-footer{
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    color: #050505;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.7s ease, transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
    width: 100%;
    padding-bottom: 8px;
}

body.menu-open .works-menu-footer{
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.5s;
}

.works-menu-footer-email{
    margin-bottom: 10px;
    order: 2;
}

.works-menu-footer-email a{
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
    font-weight: 400;
    color: rgba(5,5,5,0.45);
    text-decoration: none;
    letter-spacing: 0.01em;
    white-space: nowrap;
    transition: color 0.3s ease;
}

.works-menu-footer-email a:hover{
    color: #050505;
}

.works-menu-footer-links{
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 7px;
    order: 1;
}

/* ── CORNER BADGE (bottom-left, fixed) ───────────────────────────────────
   Outer anchor wraps image + rotating SVG ring.
   Only .works-marquee-ring rotates; the image stays perfectly still.
   Badge is pushed into the corner so only the top-right arc is visible,
   matching the Paco Mertant reference proportions.
──────────────────────────────────────────────────────────────────────── */
.works-marquee{
    position: fixed;
    left:   -115px;    /* deep into corner — badge mostly off-screen left */
    bottom: -115px;    /* deep into corner — badge mostly off-screen bottom */
    width:  280px;
    height: 280px;
    z-index: 20;
    display: block;
    pointer-events: none; /* click events pass through transparent areas and text ring */
    text-decoration: none;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.works-marquee-inner{
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transform: rotate(-4deg);
    transform-style: preserve-3d;
    will-change: transform;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.works-marquee-inner:has(.works-corner-link:hover) {
    transform: rotate(-4deg) scale(1.06);
}


.works-stage{
    position: absolute;
    left: 50%;
    top: 50%;
    width: 0;
    height: 0;
    z-index: 5;
    transform-style: preserve-3d;
    will-change: transform;
    /* All card positions are relative to this centre point */
}

.work-card{
    --card-w: 360px;
    --card-h: 248px;
    --backness: 0;
    --brightness: 1;
    position: absolute;
    /* positioned relative to stage center; JS offsets by -CARD_W/2 and -CARD_H/2 */
    left: 0;
    top: 0;
    width: var(--card-w);
    height: var(--card-h);
    border-radius: 24px;
    overflow: hidden;
    background: rgba(10, 12, 22, 0.65);
    border: 1px solid rgba(255,255,255,0.13);
    box-shadow:
        0 28px 70px rgba(0,0,0,0.55),
        inset 0 1px 0 rgba(255,255,255,0.18);
    /* flat context so backdrop-filter on ::before composites correctly */
    transform-origin: center center;
    opacity: 1;
    will-change: transform, opacity, filter;
    cursor: default;        /* JS overrides to pointer for front card only */
    /* Depth-based brightness: front=1.0, back=0.46 — driven by --brightness var */
    filter: brightness(var(--brightness, 1));
    transition:
        opacity 0.44s ease,
        filter 0.28s ease,
        box-shadow 0.44s ease;
}

/* Front face — project image/video */
/* Optimized for maximum sharpness and fidelity */
.work-card img,
.work-card video{
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;

    /* Force high-quality rendering for sharp text and UI in videos */
    image-rendering: high-quality;
    image-rendering: -webkit-optimize-contrast;
    -webkit-font-smoothing: antialiased;

    /* Apply brightness directly to media to keep parent transforms sharp */
    filter: brightness(var(--brightness, 1));

    /* clamp keeps opacity in [0,1]; image disappears by backness ≈ 0.42 */
    opacity: clamp(0, calc(1 - var(--backness, 0) * 2.4), 1);
    transition: opacity 0.14s ease;
    z-index: 2;
    border-radius: inherit;
    transform: scale(1.14); /* Refined cinematic zoom for perfect framing */
}

/* Exception: orbit_demo.mp4 remains at 1:1 scale */
.work-card video[src*="orbit_demo.mp4"] {
    transform: scale(1);
}

/* Premium glass back-face — Apple Vision Pro / Nothing OS aesthetic            */
/* Transparent frosted panel. Fades in after card passes the side (backness>0.44) */
.work-card::before{
    content: "";
    position: absolute;
    inset: 0;
    /* Very subtle cool tint — transparent, NOT gray */
    background:
        linear-gradient(145deg,
            rgba(255,255,255,0.14) 0%,
            rgba(200,225,255,0.05) 50%,
            rgba(170,210,255,0.03) 100%);
    backdrop-filter: blur(28px) saturate(190%) brightness(1.1);
    -webkit-backdrop-filter: blur(28px) saturate(190%) brightness(1.1);
    border-radius: inherit;
    border: 1px solid rgba(255,255,255,0.20);
    /* Inner edge highlights — glass-like depth */
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.38),
        inset 0 -1px 0 rgba(255,255,255,0.06),
        inset 1px 0 0 rgba(255,255,255,0.10),
        inset -1px 0 0 rgba(255,255,255,0.06);
    /* Glass appears only after card passes the equator (backness 0.44→0.72 = full) */
    opacity: clamp(0, calc((var(--backness, 0) - 0.44) * 3.6), 1);
    transition: opacity 0.16s ease;
    z-index: 1;
    pointer-events: none;
}

/* Glass back specular highlights + soft inner glow — premium floating look */
.work-card::after{
    content: "";
    position: absolute;
    inset: 0;
    background:
        /* Edge catch-lights — left and right rim highlights */
        linear-gradient(145deg,
            rgba(255,255,255,0.44) 0%, transparent 26%,
            transparent 74%, rgba(255,255,255,0.10) 100%),
        /* Top specular flash */
        radial-gradient(ellipse at 32% 6%, rgba(255,255,255,0.36), transparent 38%),
        /* Subtle bottom-corner cool tint */
        radial-gradient(ellipse at 72% 90%, rgba(180,215,255,0.10), transparent 36%);
    /* Appears in sync with glass ::before — gates at same threshold */
    opacity: clamp(0, calc((var(--backness, 0) - 0.50) * 4.0), 1);
    transition: opacity 0.16s ease;
    border-radius: inherit;
    z-index: 3;
    pointer-events: none;
}

#works.card-hovered .work-card:not(.is-hovered){
    /* Cylinder: don't dim other cards — they all share the same viewing window */
    opacity: 1;
    filter: none;
}

.work-card.is-hovered{
    /* Hover scale and pause handled in JS for unified motion */
}

.work-card.is-hovered::after{
    background: transparent;
}

/* ── PLACEHOLDER CARD (Coming Soon) ──────────────────────────────────── */
.work-card-placeholder{
    background: rgba(10, 12, 22, 0.80);
    border: 1px solid rgba(255,255,255,0.10);
}

.work-card-placeholder-content{
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    z-index: 4;
    pointer-events: none;
}

.placeholder-label{
    font-family: 'Mynor', sans-serif;
    font-size: 30px;
    font-weight: 400;
    color: rgba(255,255,255,0.72);
    letter-spacing: 2.4px;
    text-transform: uppercase;
}

.placeholder-sub{
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    font-weight: 400;
    color: rgba(255,255,255,0.32);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.works-hover-label{
    position: absolute;
    left: 50%;
    bottom: 50px; /* Moved lower for more breathing room */
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 350px;
    max-width: min(650px, calc(100vw - 44px));
    padding: 8px 20px 8px 8px;
    border-radius: 14px;
    background: rgba(255,255,255,0.96);
    color: #050505;
    z-index: 18;
    opacity: 0;
    filter: blur(8px); /* Reduced initial blur for smoother entrance */
    transform: translate3d(-50%, 25px, 0) scale(0.98); /* Balanced movement */
    transition: 
        opacity 0.45s ease, 
        filter 0.45s ease, 
        transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
    box-shadow: 0 15px 50px rgba(0,0,0,0.22);
}

.works-hover-label.active{
    opacity: 1;
    filter: blur(0);
    transform: translate3d(-50%, 0, 0) scale(1);
}

.works-hover-label img{
    width: 38px;
    height: 38px;
    border-radius: 9px;
    object-fit: cover;
}

.works-hover-label strong{
    display: block;
    font-family: 'Mynor', sans-serif;
    font-size: 20px;
    line-height: 1;
    font-weight: 400;
}

.works-hover-label span{
    display: block;
    margin-top: 2px;
    font-size: 9px;
    letter-spacing: 1.1px;
    text-transform: uppercase;
    color: rgba(0,0,0,0.48);
}

#works.list-mode .works-stage{
    perspective: none;
}

#works.list-mode .work-card{
    border-radius: 28px;
}

@media(max-width: 900px){
    #works{
        min-height: 680px;
    }

    .works-logo-orb{
        width: 58px;
        height: 58px;
        top: 22px;
        left: 20px;
    }

    .works-mode-toggle{
        top: 32px;
        font-size: 22px;
    }
    

    .works-menu-button{
        top: 20px;
        right: 18px;
        width: 86px;
        height: 47px;
        font-size: 22px;
    }

    body.menu-open .works-menu-button,
    .works-menu-panel{
        top: 16px;
        right: 16px;
        width: calc(100vw - 32px);
        height: calc(100vh - 32px);
    }

    .works-menu-panel{
        padding: 108px 30px 32px;
    }

    .works-menu-links{
        padding-top: 20px;
    }

    .works-menu-footer{
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .works-menu-footer-links{
        justify-content: flex-start;
    }

    .work-card{
        --card-w: min(84vw, 430px);
        --card-h: calc(var(--card-w) * 0.68);
    }

    .works-marquee{
        left: -178px;
        bottom: -30px;
        transform: scale(0.7);
    }
}

@media(max-width: 600px){
    .works-mode-toggle{
        left: 48%;
        font-size: 18px;
        gap: 12px;
    }

    .works-logo-orb{
        display: none;
    }

    .works-menu-button{
        width: 78px;
        height: 44px;
        font-size: 19px;
    }

    .works-menu-links a{
        font-size: 48px;
    }

    .works-hover-label{
        bottom: 34px;
    }
}

/* 15. WORKS REDESIGN REFINEMENT */

html,
body{
    background: #050505;
}

body{
    min-height: 100vh;
}

body:has(#works){
    overflow: hidden;
}

.hero,
.floating-nav,
#footer-container,
.image-footer{
    display: none !important;
}

#works{
    min-height: 100vh;
    height: 100dvh;
}

.works-stage{
    opacity: 1;
    transition: opacity 0.55s ease, filter 0.55s ease;
}

#works.list-mode .works-stage{
    opacity: 0;
    filter: blur(18px);
    pointer-events: none;
}

.work-card{
    clip-path: none;
    border-radius: 24px;
    /* Dark semi-transparent body so glass ::before composites correctly */
    background: rgba(10, 12, 22, 0.65);
    filter: brightness(var(--brightness, 1));
    transition:
        opacity 0.44s ease,
        filter 0.28s ease,
        box-shadow 0.44s ease;
}

/* Hovered card: img stays as-is, slight dim */
.work-card.is-hovered img,
.work-card.is-hovered video{
    filter: brightness(0.72) saturate(1.1) contrast(1.05);
}

.works-menu-button{
    z-index: 42;
}

body.menu-open .works-menu-button{
    box-shadow: 0 28px 90px rgba(0,0,0,0.42);
}

.works-menu-panel{
    z-index: 43;
    pointer-events: none;
}

body.menu-open .works-menu-panel{
    pointer-events: none;
}

.works-menu-links,
.works-menu-links a,
.works-menu-footer,
.works-menu-footer a{
    pointer-events: none;
}

body.menu-open .works-menu-links,
body.menu-open .works-menu-links a,
body.menu-open .works-menu-footer,
body.menu-open .works-menu-footer a{
    pointer-events: auto;
}

.works-menu-footer-links a{
    width: 40px;
    min-width: 40px;
    height: 40px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #050505;
    color: #fff !important;
    text-decoration: none;
    transition: transform 0.22s ease, opacity 0.22s ease;
}

.works-menu-footer-links a:hover{
    transform: translateY(-2px) scale(1.06);
    opacity: 0.82;
}

.works-menu-social svg{
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.works-menu-social:hover{
    transform: translateY(-2px) scale(1.04);
}

.hero,
.project-showcase,
.timeline-section,
.skills,
.image-footer{
    content-visibility: auto;
    contain-intrinsic-size: 100vh;
}

/* ── Rotating SVG ring ── */
.works-marquee-ring{
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    /* Only the ring rotates — image is untouched */
    animation: cornerRingSpin 18s linear infinite;
    transform-origin: 50% 50%;
    will-change: transform;
    backface-visibility: hidden;
    pointer-events: none; /* text ring is purely decorative and not clickable */
}

.works-marquee-ring text{
    fill: rgba(255,255,255,0.82);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

/* ── Clickable Link wrapper for static artwork ── */
.works-corner-link{
    position: absolute;
    left:   50%;
    top:    50%;
    transform: translate(-50%, -50%);
    width:  176px;          /* concentric diameter to sit further inside the text ring */
    height: 176px;
    display: block;
    border-radius: 50%;     /* circular badge, matching reference contour */
    overflow: hidden;       /* clips clickable area strictly to the circle */
    pointer-events: auto;   /* triggers navigation on click */
    cursor: pointer;        /* shows hand pointer on hover */
    z-index: 2;             /* sits above text ring */
}

/* ── Static artwork image ── */
.works-corner-img{
    width:  100%;           /* fills the parent link container */
    height: 100%;           /* fills the parent link container */
    display: block;
    border-radius: 50%;     /* matches the circle shape */
    pointer-events: none;   /* mouse events pass directly to the link wrapper */
    user-select: none;
    -webkit-user-drag: none;
    object-fit: cover;      /* crops landscape artwork into a clean circle */
}

/* ring spin — counterclockwise, matching reference direction */
@keyframes cornerRingSpin{
    from { transform: rotate(0deg); }
    to   { transform: rotate(-360deg); }
}

.works-list{
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: clamp(18px, 3.5vh, 34px);
    padding: 100px 8vw 60px;
    opacity: 0;
    transform: translateY(34px) scale(0.985);
    filter: blur(12px);
    pointer-events: none;
    transition: opacity 0.55s ease, transform 0.65s cubic-bezier(.18,1.18,.26,1), filter 0.55s ease;
}

#works.list-mode .works-list{
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
    pointer-events: auto;
}

.works-list a{
    display: block;
    max-width: min(100%, 1180px);
    color: rgba(255,255,255,0.92);
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(54px, 6.8vw, 122px);
    line-height: 0.78;
    letter-spacing: -0.075em;
    text-align: center;
    transition: color 0.35s ease, opacity 0.35s ease, filter 0.35s ease, transform 0.45s cubic-bezier(.18,1.18,.26,1);
}

.works-list:hover a{
    opacity: 0.25;
}

.works-list a:hover{
    opacity: 1;
    color: #fff;
    filter: blur(0);
    transform: scale(1.035);
}

.works-list-preview{
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(410px, 34vw);
    aspect-ratio: 16 / 9;
    border-radius: 22px;
    overflow: hidden;
    z-index: 13;
    opacity: 0;
    transform: translate3d(80px, -50%, 0) scale(0.88) rotate(0deg);
    filter: blur(16px);
    box-shadow: 0 32px 90px rgba(0,0,0,0.6);
    pointer-events: none;
    transition: opacity 0.32s ease, filter 0.32s ease, transform 0.38s cubic-bezier(.18,1.18,.26,1);
}

.works-list-preview.active{
    opacity: 1;
    filter: blur(0);
    transform: translate3d(110px, -50%, 0) scale(1) rotate(0deg);
}

.works-list-preview img{
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.05);
}

#works.list-mode .works-hover-label{
    display: none;
}

@media(max-width: 760px){
    .works-list a{
        font-size: clamp(42px, 12vw, 78px);
        line-height: 0.86;
    }

    .works-list-preview{
        width: min(300px, 74vw);
        top: 68%;
        left: 50%;
    }

    .works-list-preview.active{
        transform: translate3d(-50%, -50%, 0) scale(1);
    }

    .works-marquee{
        left:   -100px;
        bottom: -100px;
        width:  260px;
        height: 260px;
    }

    .works-corner-link{
        width:  162px;
        height: 162px;
    }
}

/* ── PAGE TRANSITIONS ─────────────────────────────────────────────────── */

body {
    opacity: 1;
    transition: opacity 0.38s ease;
}

body.page-leaving {
    opacity: 0;
    pointer-events: none;
}

/* ── Smiley Orb Speech Bubble & Animations ───────────────────────────────── */
.logo-speech-bubble {
    position: absolute;
    top: 5px;
    left: calc(100% + 16px);
    background: #ffffff;
    color: #000000;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 15px;
    font-weight: 900;
    padding: 10px 22px;
    border-radius: 18px 18px 18px 2px; /* Bottom-left point shape */
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
    z-index: 100;
    pointer-events: none;
    white-space: nowrap;
    transform-origin: bottom left;
    animation: bubblePop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

/* Tail/beak triangle */
.logo-speech-bubble::before {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 10px;
    width: 12px;
    height: 12px;
    background: #ffffff;
    transform: rotate(45deg);
    z-index: -1;
}

/* Sparkle SVG */
.bubble-sparkle {
    position: absolute;
    top: -14px;
    right: -14px;
    width: 28px;
    height: 28px;
    animation: sparkleSpin 3s linear infinite;
}

/* Re-trigger pop animation class */
.bubble-pop-anim {
    animation: none;
    animation: bubblePop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

/* Fade out animation class */
.bubble-fade-out {
    animation: bubbleFade 0.35s ease forwards;
}

/* Bounce squish animation for the smiley orb logo */
.orb-bounce {
    animation: orbSquish 0.5s cubic-bezier(0.25, 0.8, 0.25, 1) forwards;
}

@keyframes bubblePop {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes bubbleFade {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(0.85);
        opacity: 0;
    }
}

@keyframes sparkleSpin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes orbSquish {
    0% {
        transform: scale(1);
    }
    15% {
        transform: scale(0.85, 1.15) translateY(-5px);
    }
    30% {
        transform: scale(1.15, 0.85) translateY(2px);
    }
    45% {
        transform: scale(0.95, 1.05) translateY(-1px);
    }
    70% {
        transform: scale(1.02, 0.98);
    }
    100% {
        transform: scale(1);
    }
}

/* ─── SHARED FLOATING NAV PILL (FROM HOMEPAGE) ────────────────────────── */

.pill-nav-container {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translate3d(-50%, 24px, 0);
  z-index: 1000;
  pointer-events: none;
  transition: opacity 0.4s ease;
  will-change: opacity, transform;
  
  /* Entrance animation on page load */
  animation: navPillEntrance 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes navPillEntrance {
  0% {
    opacity: 0;
    transform: translate3d(-50%, 24px, 0);
  }
  100% {
    opacity: 1;
    transform: translate3d(-50%, 0, 0);
  }
}

.pill-nav {
  pointer-events: auto;
  background: #000000;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  display: grid;
  grid-template-rows: auto 0fr;
  width: min(320px, calc(100vw - 32px));
  transition: grid-template-rows 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              border-radius 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.pill-nav.open {
  grid-template-rows: auto 1fr;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.4);
}

.pill-nav-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 12px 12px 24px;
  width: 100%;
}

.pill-nav-logo {
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.pill-nav-trigger {
  background: #ffffff;
  border: none;
  border-radius: 100px;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s;
  min-width: 53px;
  height: 38px;
}

.pill-nav-trigger:hover {
  background: #f0f0f0;
  transform: scale(1.03);
}

/* ── Dots → X morphing animation ─────────────────────── */

.menu-dots-container {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 22px;
  height: 14px;
}

.menu-dot {
  width: 5px;
  height: 5px;
  background: #000000;
  border-radius: 50%;
  position: absolute;
  transition:
    transform 0.38s cubic-bezier(0.4, 0, 0.2, 1),
    opacity   0.28s cubic-bezier(0.4, 0, 0.2, 1),
    width     0.38s cubic-bezier(0.4, 0, 0.2, 1),
    height    0.38s cubic-bezier(0.4, 0, 0.2, 1),
    border-radius 0.38s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Resting positions: left, center, right */
.menu-dot--left  { transform: translateX(-8px); }
.menu-dot--mid   { transform: translateX(0px); }
.menu-dot--right { transform: translateX(8px); }

/* Open state — morph into X */
.pill-nav.open .menu-dot--left {
  transform: translateX(0) rotate(45deg);
  width: 14px;
  height: 2px;
  border-radius: 2px;
  background: #000000;
}
.pill-nav.open .menu-dot--right {
  transform: translateX(0) rotate(-45deg);
  width: 14px;
  height: 2px;
  border-radius: 2px;
  background: #000000;
}
.pill-nav.open .menu-dot--mid {
  opacity: 0;
  transform: translateX(0) translateY(8px);
}

.menu-close-icon {
  display: none; /* hidden — using CSS dot morph instead */
}

/* ─── MENU DROPDOWN & CONTENT ────────────────────────── */

.pill-nav-dropdown {
  grid-row: 2;
  overflow: hidden;
  transition: visibility 0.45s;
  visibility: hidden;
}

.pill-nav.open .pill-nav-dropdown {
  visibility: visible;
}

.pill-nav-dropdown-inner {
  padding: 10px 24px 24px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.menu-card-links {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 16px 0 24px 0;
}

.menu-link {
  font-family: var(--font-body);
  font-size: clamp(32px, 4vw, 42px);
  font-weight: 600;
  letter-spacing: -0.035em;
  color: rgba(255, 255, 255, 0.25); /* Inactive: dark grey */
  text-decoration: none;
  text-transform: capitalize;
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              color 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              font-size 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-block;
  width: fit-content;

  /* Initial state for opening animation */
  opacity: 0;
  transform: translateY(15px);
  filter: blur(4px);
}

.pill-nav.open .menu-link {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Active section link: white + larger */
.pill-nav.open .menu-link.active {
  color: #ffffff;
  font-size: clamp(38px, 4.8vw, 50px);
}

/* Hover: white + slide right (no size change) */
.pill-nav.open .menu-link:hover {
  color: #ffffff;
  transform: translateX(8px);
}

/* Removed: hover-dimming rule that was creating a 3rd colour state */

/* Stagger delays for premium dropdown reveal */
.pill-nav.open .menu-link:nth-child(1) { transition-delay: 0.08s; }
.pill-nav.open .menu-link:nth-child(2) { transition-delay: 0.12s; }
.pill-nav.open .menu-link:nth-child(3) { transition-delay: 0.16s; }
.pill-nav.open .menu-link:nth-child(4) { transition-delay: 0.2s; }
.pill-nav.open .menu-link:nth-child(5) { transition-delay: 0.24s; }

.menu-card-footer {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  
  /* Initial state for footer entrance */
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s cubic-bezier(0.2, 0.8, 0.2, 1),
              transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.pill-nav.open .menu-card-footer {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.28s;
}

.menu-email {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: -0.01em;
  text-decoration: none;
  position: relative;
  transition: color 0.3s ease;
}

.menu-email:hover {
  color: #ffffff;
}

.menu-email::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 1px;
  background: #ffffff;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.menu-email:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.menu-socials {
  display: flex;
  gap: 8px;
}

.social-circle {
  width: 34px;
  height: 34px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: background-color 0.3s, color 0.3s, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.social-circle:hover {
  background-color: var(--accent);
  color: #000000;
  transform: translateY(-4px) scale(1.05);
}

/* ─── MENU SCRIM ────────────────────────────────────── */

.menu-scrim {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 999;
  background: rgba(10, 10, 10, 0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.menu-scrim.open {
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 600px) {
  .pill-nav-container { top: 16px; }
  .menu-card { padding: 32px 24px; border-radius: 24px; }
  .menu-link { font-size: clamp(30px, 8vw, 44px); }
  .menu-card-footer { padding-top: 20px; }
}

/* — Footer redesign — */

.home-footer {
  background: #0a0a0a;
  color: #ffffff;
  padding: 120px clamp(48px, 10vw, 160px) 160px;
  overflow: hidden;
  position: relative;
}

/* Footer entrance animations */
.footer-left {
  opacity: 0;
  filter: blur(12px);
  transform: translateX(-32px);
  transition: opacity 1.1s cubic-bezier(0.16, 1, 0.3, 1), filter 1.1s cubic-bezier(0.16, 1, 0.3, 1), transform 1.1s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, filter, transform;
}

.footer-col-links {
  opacity: 0;
  filter: blur(12px);
  transform: translateX(-32px);
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, filter, transform;
}

#contact {
  opacity: 0;
  filter: blur(12px);
  transform: translateX(-32px);
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, filter, transform;
}

.home-footer.in-view .footer-left,
.home-footer.in-view .footer-col-links,
.home-footer.in-view #contact {
  opacity: 1;
  filter: blur(0);
  transform: translateX(0);
}

.home-footer.in-view .footer-left {
  transition-delay: 0s;
}

.home-footer.in-view .footer-col-links {
  transition-delay: 0.1s;
}

.home-footer.in-view #contact {
  transition-delay: 0.2s;
}

@media (prefers-reduced-motion: reduce) {
  .footer-left,
  .footer-col-links,
  #contact,
  .footer-name {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 60px;
  padding-bottom: 80px;
  flex-wrap: wrap;
  position: relative;
  z-index: 2;
}

.footer-left {
  flex: 1.2;
  min-width: 280px;
}

.footer-tagline {
  font-family: var(--font-body);
  font-size: clamp(32px, 4.5vw, 56px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.035em;
  color: #ffffff;
  margin: 0;
  text-transform: none;
}

.footer-right {
  display: flex;
  gap: 80px;
  flex-wrap: wrap;
  flex: 2;
  justify-content: space-between;
}

@media (max-width: 900px) {
  .footer-right {
    justify-content: flex-start;
  }
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 180px;
}

.footer-col-links {
  align-items: flex-start;
  text-align: left;
}

.footer-col-label {
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: #ffffff;
  text-transform: none;
}

.footer-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 320px;
  justify-content: flex-start;
}

.footer-pill {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: #0a0a0a;
  background: #ffffff;
  text-decoration: none;
  border: 1px solid #ffffff;
  border-radius: 8px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  height: 38px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-pill span {
  display: inline-block;
  transition: transform 0.4s cubic-bezier(0.76, 0, 0.24, 1);
}

.footer-pill::after {
  content: attr(data-text);
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.76, 0, 0.24, 1);
  color: #0a0a0a;
  font-weight: 500;
}

.footer-pill:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.footer-pill:hover span {
  transform: translateY(-150%);
}

.footer-pill:hover::after {
  transform: translateY(0);
}

.footer-contact-link {
  font-family: var(--font-body);
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: all 0.3s var(--ease-out);
  display: block;
}

.footer-contact-link:hover {
  color: #ffffff;
  transform: translateX(4px);
}

.footer-gmail-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s var(--ease-out), transform 0.3s var(--ease-out);
  margin-bottom: 8px;
  width: fit-content;
  display: block;
}

.footer-gmail-link:hover {
  color: #ffffff;
}

.footer-gmail-text {
  position: relative;
}

.footer-gmail-text::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 1px;
  background-color: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-gmail-link:hover .footer-gmail-text::after {
  transform: scaleX(1);
}

.footer-arrow-icon {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  transform: rotate(-60deg);
  transition: transform 0.3s var(--ease-out);
  display: inline-block;
  vertical-align: middle;
  margin-left: 4px;
}

.footer-gmail-link:hover .footer-arrow-icon {
  transform: translate(2px, -2px) rotate(-60deg);
}


.footer-socials {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 4px;
}

.footer-social-icon {
  color: #000000;
  background: #ffffff;
  border: 1px solid #ffffff;
  border-radius: 50%;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  overflow: hidden;
  background-clip: padding-box;
}

.footer-social-icon-inner {
  display: block;
  position: relative;
  width: 20px;
  height: 20px;
  overflow: hidden;
}

.footer-social-icon-inner svg {
  display: block;
  width: 20px;
  height: 20px;
  fill: currentColor;
  flex-shrink: 0;
  transition: transform 0.4s cubic-bezier(0.76, 0, 0.24, 1);
}

.footer-social-icon:hover {
  color: #000000;
  background-color: #e4e4e7;
  border-color: #e4e4e7;
}

.footer-social-icon:hover .footer-social-icon-inner svg {
  transform: translateY(-20px);
}

.theme-light .footer-social-icon:hover {
  color: #000000;
  background-color: #e4e4e7;
  border-color: #e4e4e7;
  box-shadow: none;
}


/* Giant name at the bottom — positioned absolutely behind content */
.footer-name-wrap {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  z-index: 1;
  pointer-events: none;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  height: auto;
  line-height: 0.8;
  overflow: hidden;
}

.footer-name {
  font-family: var(--font-body);
  font-size: clamp(140px, 24vw, 420px);
  font-weight: 900;
  letter-spacing: -0.05em;
  color: rgba(255, 255, 255, 0.015);
  white-space: nowrap;
  user-select: none;
  line-height: 0.8;
  display: block;
  text-transform: uppercase;
  
  /* Initial transition state */
  opacity: 0;
  transform: translate(0, calc(35% + 60px));
  transition: opacity 1.5s cubic-bezier(0.16, 1, 0.3, 1), transform 1.5s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.home-footer.in-view .footer-name,
.footer-name.in-view {
  opacity: 1;
  transform: translate(0, 35%);
}

.home-footer.in-view .footer-name {
  transition-delay: 0.3s;
}



