/* ==============================================================
   DHRITIRAJ KARMAKAR — PORTFOLIO STYLING (SASWAT DASH ALIGNMENT)
   Aesthetics: Rich dark mode, Bebas Neue headings, DM Sans body, 
   fluid spacing pacing, and advanced CSS-animated SVGs.
   ============================================================== */

:root {
  /* Inverted Premium Dark Palette */
  --bg: #0b0b0d;            /* Pure ink black */
  --bg-alt: #141316;        /* Warm charcoal-zinc */
  --ink: #f5f5f7;           /* Warm white */
  --ink-2: #d4d4d8;         /* Zinc-200 secondary body */
  --muted: #71717a;         /* Zinc-500 muted metadata */
  --rule: rgba(255, 255, 255, .08);       /* Delicate separator */
  --rule-strong: rgba(255, 255, 255, .15); /* Strong separator */
  --accent: #c8513a;        /* Saswat's signature terracotta rust-orange */
  --charcoal: #070709;      /* Ultra-dark canvas background */
  --on-dark-muted: #a1a1aa;

  /* Custom Spacing */
  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 32px;
  --space-lg: 56px;
  --space-xl: 96px;
  --space-xxl: 120px;

  /* Typography Scales */
  --font-heading: 'Bebas Neue', sans-serif;
  --font-body: 'DM Sans', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'Space Mono', monospace;

  /* Timing Curves */
  --ease-editorial: cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: 0.2s ease;
  --transition-medium: 0.4s var(--ease-editorial);
  --transition-slow: 0.8s var(--ease-editorial);
}

/* Make the first project span 2 columns like a hero case study */
.projects-grid .project-card:first-child {
  grid-column: span 2;
}
.projects-grid .project-card:first-child .project-card-img {
  height: 500px;
}
.projects-grid .project-card-img {
  height: 380px; /* square-ish for the rest */
}
@media (max-width: 900px) {
  .projects-grid .project-card:first-child {
    grid-column: span 1;
  }
  .projects-grid .project-card:first-child .project-card-img {
    height: 340px;
  }
}


/* Reset & Basic Resets */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  min-height: 100vh;
  cursor: none;
}

/* 3 Cols Grid Responsive */
@media (max-width: 900px) {
  .three-cols-grid {
    grid-template-columns: 1fr !important;
    gap: 64px !important;
  }
}

/* Custom Cursors - Liquid physics & Magic Wand */
.custom-cursor,
.custom-cursor-follower {
  position: fixed;
  top: 0;
  left: 0;
  border-radius: 50%;
  pointer-events: none;
  z-index: 999999;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s ease;
  opacity: 0;
}

/* Magic Wand Cursor */
.custom-cursor {
  width: 32px;
  height: 32px;
  background-color: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  transform: translate(-4px, -24px); /* Offset to place wand tip at pointer */
}
.custom-cursor::after {
  content: '';
  display: block;
  width: 24px;
  height: 24px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m21 3-6 6'/%3E%3Cpath d='m15 9-9 9a2 2 0 0 0 2.8 2.8l9-9'/%3E%3Cpath d='m14.5 8.5 1 1'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  filter: drop-shadow(0 0 5px rgba(255,255,255,0.8));
}

/* Lumos Glow Follower */
.custom-cursor-follower {
  width: 40px;
  height: 40px;
  background: radial-gradient(circle, rgba(255,255,255,1) 0%, rgba(200,230,255,0.6) 40%, rgba(100,200,255,0) 80%);
  border: none;
  box-shadow: 0 0 30px 15px rgba(100, 200, 255, 0.3);
  mix-blend-mode: screen;
  transition: transform 0.15s ease-out, opacity 0.3s ease, width 0.2s ease, height 0.2s ease, background 0.2s ease, border-radius 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg);
  font-size: 11px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  white-space: nowrap;
  font-weight: 600;
  text-align: center;
  overflow: hidden;
}

/* Show lumos light only when mouse is moving */
body.is-moving .custom-cursor-follower {
  opacity: 1;
}

body.force-hide-cursor .custom-cursor-follower {
  display: none !important;
}

/* Active Hover states */
body.cursor-hovering .custom-cursor-follower {
  opacity: 0 !important; /* Hide the lumos light on normal buttons */
}

body.cursor-hovering .custom-cursor-follower.has-text {
  opacity: 1 !important; /* Ensure tooltip shows up */
  width: auto;
  height: auto;
  padding: 8px 16px;
  border-radius: 20px;
  background: var(--ink);
  box-shadow: 0 0 20px rgba(100, 200, 255, 0.4);
  mix-blend-mode: normal;
  border: 1px solid var(--ink);
  transform: translate(-50%, -50%) scale(1);
}

body.cursor-active .custom-cursor {
  transform: translate(-4px, -24px) scale(0.8) rotate(-15deg);
}

@media (pointer: coarse) {
  .custom-cursor, .custom-cursor-follower {
    display: none;
  }
}

/* Lumos Sparkles */
.lumos-sparkle {
  position: fixed;
  width: 4px;
  height: 4px;
  background: white;
  border-radius: 50%;
  pointer-events: none;
  box-shadow: 0 0 8px 2px rgba(100, 200, 255, 0.8);
  animation: sparkle-fade 0.8s forwards;
  z-index: 9997;
}

@keyframes sparkle-fade {
  0% { transform: scale(1) translateY(0); opacity: 1; }
  100% { transform: scale(0) translateY(30px); opacity: 0; }
}

/* Text Micro-animation (Alive Feel) */
@keyframes text-breathe {
  0%, 100% { transform: translateY(0); text-shadow: 0 0 0 rgba(255,255,255,0); }
  50% { transform: translateY(-3px); text-shadow: 0 8px 20px rgba(100, 200, 255, 0.2); }
}

.hero-h1, .about-head h2, .project-head h3, .testi-head h2 {
  animation: text-breathe 4s ease-in-out infinite;
  will-change: transform, text-shadow;
}

/* Scroll Progress Bar */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background-color: var(--accent);
  z-index: 1001;
  width: 0%;
  transition: width 0.1s linear;
}

/* Content Width Containment */
.inner {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  padding-left: var(--space-lg);
  padding-right: var(--space-lg);
}

@media (max-width: 768px) {
  .inner {
    padding-left: 24px;
    padding-right: 24px;
  }
  
}

::selection {
  background: var(--accent);
  color: #fff;
}

/* Typography elements */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 400;
  margin: 0;
}

p {
  line-height: 1.6;
  color: var(--ink-2);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

/* Sticky Navigation bar */
.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--rule);
  position: fixed;
  left: 0;
  width: 100%;
  top: 0;
  z-index: 50;
  background: rgba(11, 11, 13, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.nav .inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  padding-bottom: 24px;
}

.logo {
  font-family: var(--font-heading);
  font-size: 24px;
  letter-spacing: .04em;
  text-decoration: none;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-logo-mark {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--ink);
  opacity: 0.85;
  transition: transform 1.2s var(--ease-editorial);
}

.logo:hover .nav-logo-mark {
  transform: rotate(360deg);
  color: var(--accent);
}

.nav .links {
  display: flex;
  gap: 8px;
  align-items: center;
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 999px;
  transition: background .2s, color .2s;
}

.nav-link:hover {
  background: var(--bg-alt);
  color: var(--ink);
}

.nav-link.active {
  color: var(--accent);
}

.nav-cta {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  background: var(--ink);
  color: var(--bg);
  padding: 10px 20px;
  border-radius: 999px;
  cursor: pointer;
  border: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: transform .2s, background .2s, color .2s;
}

.nav-cta:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

/* Staggered Scroll entrance reveals */
.reveal {
  opacity: 0;
  transform: translateY(64px);
  transition: opacity .9s var(--ease-editorial), transform .9s var(--ease-editorial);
}

.revealed {
  opacity: 1;
  transform: translateY(0);
}

.reveal-child {
  opacity: 0;
  transform: translateY(52px);
  transition: opacity .8s var(--ease-editorial), transform .8s var(--ease-editorial);
}

.revealed .reveal-child {
  opacity: 1;
  transform: translateY(0);
}

.revealed .reveal-child:nth-child(1) { transition-delay: .05s; }
.revealed .reveal-child:nth-child(2) { transition-delay: .18s; }
.revealed .reveal-child:nth-child(3) { transition-delay: .32s; }
.revealed .reveal-child:nth-child(4) { transition-delay: .46s; }

.reveal-left {
  opacity: 0;
  transform: translateX(-32px);
  transition: opacity .7s var(--ease-editorial), transform .7s var(--ease-editorial);
  transition-delay: .1s;
}

.revealed .reveal-left {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(.88) translateY(20px);
  transition: opacity .75s var(--ease-editorial), transform .75s var(--ease-editorial);
  transition-delay: .25s;
}

.revealed .reveal-scale {
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* Eyebrows / Meta Labels */
.eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 12px;
}

html, body {
  overflow-x: hidden;
  max-width: 100vw;
}

/* Hero Section layout */
.hero {
  padding: 24px 0 20px 0;
  position: relative;
  background: var(--bg);
  overflow: visible;
}

.hero-h1 {
  font-family: var(--font-heading);
  font-size: clamp(68px, 8.2vw, 120px);
  line-height: .88;
  letter-spacing: -.005em;
  margin: 0;
  color: var(--ink);
  height: 3.5em; /* Force a fixed block of empty space so the layout NEVER jumps */
}

@media (max-width: 768px) {
  .hero-h1 {
    font-size: clamp(40px, 10vw, 60px);
    height: 200px; /* Reduced height to perfectly match the smaller font size */
  }
}

.hero-h1 .it {
  color: var(--accent);
  font-style: italic;
  display: inline-block;
  transform: skewX(-6deg);
}

.hero-swapper {
  color: var(--accent);
  font-style: italic;
  display: inline-block;
  transform: skewX(-6deg);
  will-change: opacity, transform, filter;
}

.hero-swapper.swap-out {
  opacity: 0;
  transform: skewX(-6deg) translateY(-20px) scale(0.95);
  filter: blur(10px);
  transition: opacity 0.3s ease-in, transform 0.3s ease-in, filter 0.3s ease-in;
}

.hero-swapper.swap-in {
  opacity: 1;
  transform: skewX(-6deg) translateY(0) scale(1);
  filter: blur(0px);
  transition: opacity 0.5s ease-out, transform 0.9s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.5s ease-out;
}

.hero-line {
  display: block;
  overflow: visible;
  will-change: transform, opacity, filter;
}

.hero-strap {
  will-change: transform, opacity, filter;
}

.hero-line span {
  display: inline-block;
}

.hero-line.in span {
  transform: translateY(0);
}

.hero-line:nth-child(2) span { transition-delay: .12s; }
.hero-line:nth-child(3) span { transition-delay: .24s; }

.opinion-swapper {
  cursor: pointer;
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
  transition: color var(--transition-fast);
}
.opinion-swapper:hover {
  color: var(--accent);
}

.hero-strap {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 64px;
  margin-top: 56px;
  align-items: start;
  border-top: 1px solid var(--rule);
  padding-top: 36px;
}

.hero-strap p {
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0;
  max-width: 620px;
  font-weight: 400;
  letter-spacing: -.005em;
}

.hero-strap p em {
  font-style: italic;
  color: var(--accent);
  font-weight: 500;
}

.hero-meta {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.7;
  border-left: 1px solid var(--rule-strong);
  padding-left: 20px;
}

.hero-meta b {
  display: block;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 2px;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.hero-meta .row + .row {
  margin-top: 14px;
}

.hero-ctas {
  display: flex;
  gap: 12px;
  margin-top: 40px;
  align-items: center;
}

.cta-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--ink);
  color: var(--bg);
  border: 0;
  padding: 16px 28px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  letter-spacing: -.01em;
  transition: background .2s, transform .2s, color .2s;
}

.cta-primary:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

.cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--ink);
  padding: 14.5px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  letter-spacing: -.01em;
  transition: background .2s, color .2s;
}

.cta-secondary:hover {
  background: var(--ink);
  color: var(--bg);
}

@media (max-width: 900px) {
  .hero-strap {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .hero-meta {
    border-left: none;
    border-top: 1px solid var(--rule);
    padding-left: 0;
    padding-top: 20px;
  }
}

/* Roles Section Layout */
.roles {
  padding: var(--space-xxl) 0;
  background: var(--bg-alt);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.roles-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 48px;
  gap: 32px;
}

.roles h2 {
  font-size: 88px;
  line-height: .92;
  letter-spacing: .005em;
}

.roles-sub {
  font-size: 15px;
  color: var(--ink-2);
  max-width: 340px;
  line-height: 1.55;
  margin: 0;
}

.roles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 900px) {
  .roles-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .roles-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

.role-card {
  position: relative;
  background-color: var(--bg-alt);
  border: 1px solid var(--rule);
  border-radius: 16px;
  padding: 36px 32px 32px 32px;
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  cursor: pointer;
  overflow: hidden;
  transition: transform .35s var(--ease-editorial), box-shadow .35s, border-color .25s;
  will-change: transform;
}

.role-card > div {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.role-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 48px rgba(0,0,0,0.5), 0 0 0 1.5px var(--ink);
  border-color: var(--ink);
}

.role-card.featured {
  background-color: #000000; /* Solid Black featured discover card */
  border-color: var(--rule-strong);
}

.role-card.featured:hover {
  border-color: var(--accent);
  box-shadow: 0 24px 48px rgba(0,0,0,0.6), 0 0 0 1.5px var(--accent);
}

.role-card.featured .role-num {
  color: var(--accent);
}

.role-card.featured .role-desc {
  color: var(--ink-2);
}

.role-num {
  font-family: var(--font-heading);
  font-size: 60px;
  line-height: 1;
  color: var(--accent);
  letter-spacing: .005em;
  margin-bottom: 24px;
}

.role-card h3 {
  font-family: var(--font-heading);
  font-size: 48px;
  line-height: .95;
  letter-spacing: .005em;
  margin: 0 0 14px 0;
}

.role-desc {
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0 0 22px 0;
  max-width: 280px;
}

/* Rounded Pill Card Buttons (Screenshot 1 Alignment) */
.modal-close-btn span {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

/* ── Pitch Black Theme Overrides ── */
.case-study-modal-overlay.theme-pitch-black {
  background: #000000;
}
.case-study-modal-overlay.theme-pitch-black .modal-editorial-container {
  background: #000000;
}
.case-study-modal-overlay.theme-pitch-black .modal-nav-bar {
  background: rgba(0,0,0,0.9);
}

.role-btn {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--rule-strong);
  padding: 8px 16px;
  border-radius: 999px;
  align-self: flex-start;
  cursor: pointer;
  margin-top: 16px;
  transition: transform .25s var(--ease-editorial), background .25s, color .25s, border-color .25s;
}

.role-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: translateY(-2px);
}

.role-card.featured .role-btn {
  background: rgba(255, 255, 255, .05);
  color: #fff;
  border-color: rgba(255, 255, 255, .15);
}

.role-card.featured .role-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.role-viz {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 64px;
  height: 44px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(255, 255, 255, .03);
}

.role-card.featured .role-viz {
  background: rgba(255, 255, 255, .12);
}

.role-viz svg {
  width: 100%;
  height: 100%;
}

/* ── Card 01: Magnifying glass (Understand / Find the Real Problem) ── */
.viz-search .search-ring {
  stroke: var(--accent);
  stroke-width: 1.5;
  fill: none;
  transform-box: fill-box;
  transform-origin: center;
  animation: searchPulse 2.8s ease-in-out infinite;
}

.role-card.featured .viz-search .search-ring {
  stroke: #fff;
}

.viz-search .search-handle {
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linecap: round;
  animation: searchSwing 2.8s ease-in-out infinite;
  transform-origin: 33px 27px;
}

.role-card.featured .viz-search .search-handle {
  stroke: #fff;
}

.viz-search .search-dot {
  fill: var(--accent);
  transform-box: fill-box;
  transform-origin: center;
  animation: searchDotPulse 2.8s ease-in-out infinite;
}

.role-card.featured .viz-search .search-dot {
  fill: #fff;
}

@keyframes searchPulse {
  0%, 100% { transform: scale(1);    opacity: .65; }
  40%       { transform: scale(1.14); opacity: 1;   }
  70%       { transform: scale(.92); opacity: .8;   }
}

@keyframes searchSwing {
  0%, 100% { transform: rotate(0deg);  }
  40%       { transform: rotate(10deg); }
  70%       { transform: rotate(-6deg); }
}

@keyframes searchDotPulse {
  0%, 100% { transform: scale(1);   opacity: 1;  }
  50%       { transform: scale(.3); opacity: .2; }
}

/* ── Card 02: Rising bars (Build / Give Ideas a Shape) ── */
.viz-shape .shape-bar {
  fill: var(--accent);
  transform-box: fill-box;
  transform-origin: bottom;
  opacity: .85;
}

.viz-shape .shape-bar-1 { animation: barRise 2.2s ease-in-out infinite 0s;    }
.viz-shape .shape-bar-2 { animation: barRise 2.2s ease-in-out infinite 0.22s; }
.viz-shape .shape-bar-3 { animation: barRise 2.2s ease-in-out infinite 0.44s; }

@keyframes barRise {
  0%, 100% { transform: scaleY(.2); opacity: .25; }
  55%       { transform: scaleY(1); opacity: .9;  }
}

/* ── Card 03: Nodes + traveling pulse (Connect / Human Connection) ── */
.viz-connect .connect-node {
  fill: none;
  stroke-width: 1.5;
  transform-box: fill-box;
  transform-origin: center;
}

.viz-connect .connect-node-l {
  stroke: var(--accent);
  animation: nodePulse 2.4s ease-in-out infinite 0s;
}

.viz-connect .connect-node-r {
  stroke: var(--accent);
  animation: nodePulse 2.4s ease-in-out infinite 1.2s;
}

.viz-connect .connect-line {
  stroke: var(--accent);
  stroke-width: 1.2;
  stroke-dasharray: 30;
  stroke-dashoffset: 30;
  animation: lineGrow 2.4s ease-in-out infinite;
}

.viz-connect .connect-pulse {
  fill: var(--accent);
  animation: travelPulse 2.4s ease-in-out infinite;
}

@keyframes nodePulse {
  0%, 100% { transform: scale(1);   opacity: .55; }
  50%       { transform: scale(1.4); opacity: 1;  }
}

@keyframes lineGrow {
  0%   { stroke-dashoffset: 30;  opacity: .2; }
  45%  { stroke-dashoffset: 0;   opacity: 1;  }
  75%  { stroke-dashoffset: 0;   opacity: .8; }
  100% { stroke-dashoffset: -30; opacity: .2; }
}

@keyframes travelPulse {
  0%   { transform: translateX(-15px); opacity: 0; }
  18%  { opacity: 1; }
  82%  { opacity: 1; }
  100% { transform: translateX(15px);  opacity: 0; }
}


/* Projects Section Styling */
.projects {
  padding: 0;
}

.project {
  padding: var(--space-xl) 0 88px 0;
  border-bottom: 1px solid var(--rule);
}

.project:nth-child(even) {
  background: var(--bg-alt);
}

.ph {
  position: relative;
  aspect-ratio: 2 / 1;
  border-radius: 14px;
  overflow: hidden;
  background-color: var(--charcoal);
  border: 1px solid var(--rule-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  cursor: pointer;
}

.ph::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(135deg, rgba(255,255,255,.02) 0 1px, transparent 1px 12px);
  z-index: 2;
  pointer-events: none;
}

.ph .lbl {
  position: absolute;
  bottom: 24px;
  right: 24px;
  z-index: 3;
  background: rgba(11, 11, 13, 0.8);
  padding: 8px 16px;
  border-radius: 4px;
  letter-spacing: .06em;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink);
  border: 1px solid var(--rule-strong);
  backdrop-filter: blur(4px);
  transition: opacity 0.3s ease;
  opacity: 0;
}

.ph:hover .lbl {
  opacity: 1;
}

.poster-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(95%) brightness(85%);
  transition: transform 1s var(--ease-editorial), filter 1s var(--ease-editorial);
}

.ph:hover .poster-img {
  transform: scale(1.03);
  filter: contrast(100%) brightness(95%);
}

.project-head {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 40px;
  align-items: flex-end;
  margin-top: 36px;
  margin-bottom: 24px;
}

.project-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 14px;
  display: block;
}

.project h3 {
  font-size: 110px;
  line-height: .88;
  letter-spacing: .002em;
}

.project-meta {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.7;
}

.project-meta b {
  display: block;
  font-weight: 600;
  color: var(--ink);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 2px;
}

.project-meta .row + .row {
  margin-top: 12px;
}

.project-meta a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}

.project-meta a:hover {
  text-decoration: underline;
}

.project-row {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 48px;
  margin-top: 32px;
  align-items: start;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: var(--bg);
  border: 1px solid var(--rule-strong);
  padding: 7px 12px;
  border-radius: 999px;
  color: var(--ink-2);
}

.tag.solid {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.project-desc {
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-2);
  margin: 0;
  max-width: 680px;
  letter-spacing: -.005em;
}

@media (max-width: 900px) {
  .project .inner {
    display: flex;
    flex-direction: column;
  }
  .project-head, .project-row {
    display: contents;
  }
  .ph {
    order: 1;
    margin-bottom: 24px;
  }
  .project-head > div:first-child {
    order: 2;
    margin-bottom: 16px;
  }
  .tags {
    order: 3;
    margin-bottom: 16px;
  }
  .project-desc {
    order: 4;
    margin-bottom: 24px;
  }
  .project-meta {
    order: 5;
    padding-top: 24px;
    border-top: 1px dashed var(--rule);
  }
  .project h3 {
    font-size: 64px;
  }
}

/* Unsolicited Opinions Blockquote Slider */
.testi {
  padding: var(--space-xxl) 0;
  background: var(--bg-alt);
  color: #fff;
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.testi-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 56px;
  gap: 32px;
}

.testi-head h2 {
  font-size: 64px;
  line-height: .95;
  letter-spacing: .005em;
  color: #fff;
}

.testi-viewport {
  overflow: hidden;
  position: relative;
}

.testi-track {
  display: flex;
  transition: transform .65s var(--ease-editorial);
  width: 500%; /* 5 slides */
}

.testi-slide {
  flex: 0 0 20%; /* 1/5 width */
  min-width: 0;
  padding-right: 32px;
}

.testi-slide > div {
  max-width: 780px;
}

.testi blockquote {
  font-family: var(--font-body);
  font-size: 38px;
  line-height: 1.25;
  margin: 0 0 28px 0;
  font-weight: 400;
  letter-spacing: -.015em;
  color: #fff;
}

.testi blockquote em {
  font-style: italic;
  color: var(--accent);
  font-weight: 500;
}

.testi .full-quote {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--on-dark-muted);
  max-width: 560px;
  margin: 0 0 32px 0;
}

.testi-who {
  display: flex;
  align-items: center;
  gap: 14px;
}

.testi-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1c1916, #070709);
  border: 1px solid var(--rule-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  font-weight: bold;
}

.testi-cite {
  font-size: 13px;
  color: var(--on-dark-muted);
  line-height: 1.45;
}

.testi-cite b {
  display: block;
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 2px;
}

.testi-ctrls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 56px;
  gap: 24px;
}

.testi-counter {
  font-size: 13px;
  color: var(--on-dark-muted);
  font-variant-numeric: tabular-nums;
}

.testi-counter .cur {
  color: #fff;
  font-weight: 600;
}

.testi-dots {
  display: flex;
  gap: 6px;
  align-items: center;
}

.testi-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .22);
  border: 0;
  padding: 0;
  cursor: pointer;
  transition: width .3s, background .3s;
}

.testi-dot.active {
  width: 32px;
  border-radius: 4px;
  background: #fff;
}

.testi-arrows {
  display: flex;
  gap: 8px;
}

.testi-arrow {
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: background .2s, color .2s, border-color .2s;
}

.testi-arrow:hover {
  background: #fff;
  color: var(--bg);
  border-color: #fff;
}

@media (max-width: 768px) {
  .testi-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .testi blockquote {
    font-size: 26px;
  }
}

/* About Section layouts */
.ab-intro-wrap {
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
}

.ab-intro {
  display: grid;
  grid-template-columns: 560px 1fr;
  gap: 64px;
  padding: 0 0 80px 0;
  align-items: start;
}

.ab-intro-text {
  padding-bottom: 20px;
}

.ab-portrait-sandbox {
  height: 460px;
  width: 100%;
}

.ab-tag {
  font-size: 28px;
  line-height: 1.3;
  color: var(--ink);
  margin: 0 0 28px 0;
  font-weight: 600;
  letter-spacing: -.01em;
}

.ab-tag em {
  font-style: italic;
  color: var(--accent);
}

.ab-bio {
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink-2);
  margin: 0 0 28px 0;
}

/* Portfolio Carousel Styles */
.portfolio-carousel {
  padding: var(--space-xl) 0;
  border-top: 1px solid var(--rule);
  background: var(--bg);
  position: relative;
  overflow: hidden;
}

.pc-header {
  margin-bottom: 60px;
}

.pc-main-title {
  font-family: var(--font-heading);
  font-size: 72px;
  line-height: .92;
  letter-spacing: .005em;
  margin: 0;
  text-transform: uppercase;
  color: var(--ink);
}

/* Progress Bar */
.pc-progress-bar {
  width: 100%;
  height: 2px;
  background: var(--surface);
  margin-bottom: 60px;
  position: relative;
  overflow: hidden;
}

.pc-progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: var(--primary);
  transition: width 0.1s linear; /* Smooth progress update */
}

/* Controls Bar */
.pc-controls-bar {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 40px;
}

.pc-controls {
  display: flex;
  gap: 8px;
}

.pc-btn {
  background: var(--surface);
  border: 1px solid var(--rule);
  color: var(--ink);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pc-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.pc-progress-bar {
  flex: 1;
  height: 2px;
  background: var(--surface);
  position: relative;
  overflow: hidden;
  margin: 0;
}

.pc-progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: var(--primary);
  transition: width 0.1s linear;
}

/* Layout */
.pc-layout {
  display: grid;
  grid-template-columns: 200px 1fr 340px;
  gap: 60px;
  align-items: start;
}

/* Left: Sidebar Navigation */
.pc-sidebar {
  display: flex;
  flex-direction: column;
}

.pc-years-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.pc-year-item {
  font-family: var(--font-heading);
  font-size: 24px;
  color: var(--ink-2);
  cursor: pointer;
  transition: all 0.3s ease;
  padding-left: 16px;
  border-left: 2px solid transparent;
  opacity: 0.5;
}

.pc-year-item:hover {
  opacity: 0.8;
  color: var(--ink);
}

.pc-year-item.active {
  opacity: 1;
  color: var(--primary);
  border-left-color: var(--primary);
}

/* Center: Narrative Content */
.pc-content {
  position: relative;
  min-height: 480px;
}

/* Cinematic Blur Transition */
.pc-card {
  transition: opacity 0.5s ease, filter 0.5s ease, transform 0.5s ease;
  opacity: 1;
  filter: blur(0);
  transform: translateX(0);
}
.pc-card.fade-out {
  opacity: 0;
  filter: blur(12px);
  transform: translateX(-20px);
}
.pc-card.fade-in {
  opacity: 0;
  filter: blur(12px);
  transform: translateX(20px);
}

.pc-eyebrow {
  color: var(--primary);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 12px;
}

.pc-title {
  font-family: var(--font-heading);
  font-size: 36px;
  margin-bottom: 24px;
  color: var(--ink);
}

.pc-desc p {
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink-2);
  margin-bottom: 16px;
}
.pc-desc p:last-child {
  margin-bottom: 0;
}

.pc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 32px;
}

.pc-tags span {
  font-size: 11px;
  font-family: var(--font-mono);
  padding: 6px 12px;
  border-radius: 4px;
  background: var(--surface);
  border: 1px solid var(--rule);
  color: var(--on-surface-variant);
  transition: all 0.3s ease;
}
.pc-tags span:hover {
  border-color: var(--primary);
  color: var(--ink);
}

/* Right: Visual */
.pc-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pc-portrait-wrap {
  width: 240px;
  height: 240px;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid var(--rule-strong);
}

.pc-portrait {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(20%);
  transition: filter 0.5s ease;
}

.pc-portrait-wrap:hover .pc-portrait {
  filter: grayscale(0%);
}

@media (max-width: 1024px) {
  .portfolio-carousel .inner {
    display: flex;
    flex-direction: column;
  }
  .pc-header { order: 1; }
  .pc-visual { order: 2; margin-bottom: 32px; }
  .pc-controls-bar { order: 3; justify-content: center; width: 100%; margin-bottom: 24px; }
  
  .pc-layout {
    display: contents; /* Makes children flex items of .inner */
  }
  
  .pc-sidebar {
    order: 4;
    display: flex;
    overflow-x: auto;
    width: 100%;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 8px;
    margin-bottom: 24px;
  }
  .pc-sidebar::-webkit-scrollbar {
    display: none;
  }
  .pc-years-list {
    flex-direction: row;
    gap: 32px;
  }
  .pc-year-item {
    border-left: none;
    padding-left: 0;
    padding-bottom: 8px;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
  }
  .pc-year-item.active {
    border-bottom-color: var(--primary);
    border-left-color: transparent;
  }
  
  .pc-content {
    order: 5;
    min-height: 620px;
  }
  
  .pc-main-title {
    font-size: 56px;
  }
}

.ab-socials {
  display: flex;
  gap: 10px;
  align-items: center;
}

.ab-soc {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--rule-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--ink);
  background: var(--bg);
  cursor: pointer;
  text-decoration: none;
  transition: background .2s, color .2s, border-color .2s;
  font-weight: 600;
}

.ab-soc:hover {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.ab-tagline {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 64px;
  padding: 80px 0 100px 0;
  align-items: center;
}

.ab-tagline h2 {
  font-size: 64px;
  line-height: 1.05;
  letter-spacing: .005em;
  color: var(--ink);
  max-width: 880px;
}

.ab-tagline h2 em {
  color: var(--accent);
  font-style: italic;
}

.ab-statcard {
  background: var(--bg-alt);
  border: 1px solid var(--rule-strong);
  border-radius: 14px;
  padding: 28px 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.ab-statcard .num {
  font-family: var(--font-heading);
  font-size: 56px;
  line-height: 1;
  color: var(--ink);
}

.ab-statcard .lbl {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 8px;
}

@media (max-width: 1024px) {

  .ab-intro {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .ab-tagline {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

/* Figma Sandbox inside about section */
.figma-sandbox {
  border: 1px solid var(--rule-strong);
  border-radius: 16px;
  background-color: #1a1a1f;
  box-shadow: 0 20px 50px rgba(0,0,0,0.6);
  display: flex;
  flex-direction: column;
  height: 440px;
}

.sandbox-header {
  background-color: #25252b;
  border-bottom: 1px solid #141418;
  padding: 10px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
}

.sandbox-title-bar {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sandbox-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.sandbox-dot.red { background-color: #ff5555; }

.sandbox-title {
  color: #c7c7d5;
  font-weight: 500;
}

.sandbox-tools {
  display: flex;
  gap: 12px;
}

.tool-btn {
  background-color: transparent;
  border: none;
  color: #a6a6b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7rem;
}

.tool-btn.active {
  color: var(--accent);
  font-weight: 600;
}

.sandbox-workspace {
  position: relative;
  flex: 1;
  overflow: hidden;
}

.sandbox-canvas {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 0);
  background-size: 20px 20px;
  padding: var(--space-sm);
  overflow: hidden;
}

.sandbox-component {
  background-color: var(--bg);
  border: 1.5px solid var(--accent);
  border-radius: 8px;
  width: 250px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
  position: absolute;
  left: 20px;
  top: 30px;
  cursor: grab;
  user-select: none;
  z-index: 10;
}

.sandbox-component:active {
  cursor: grabbing;
}

.component-header {
  background-color: rgba(200, 81, 58, 0.1);
  padding: 6px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.65rem;
  font-family: var(--font-mono);
  color: var(--accent);
  border-bottom: 1px solid rgba(200, 81, 58, 0.2);
}

.component-layer-icon {
  font-weight: bold;
}

.component-body {
  padding: var(--space-sm);
}

.component-body p {
  color: var(--ink);
  font-size: 0.85rem;
  line-height: 1.45;
  margin-bottom: var(--space-sm);
  font-style: italic;
}

.component-btn {
  background-color: var(--accent);
  color: white;
  border: none;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  width: 100%;
  cursor: pointer;
}

.translator-box {
  background-color: #25252b;
  border: 1px solid var(--rule-strong);
  border-radius: 12px;
  width: 280px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.5);
  padding: var(--space-sm);
  position: absolute;
  right: 20px;
  top: 30px;
  z-index: 9;
}

.translator-header {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--muted);
  margin-bottom: var(--space-sm);
  text-transform: uppercase;
}

.translator-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.translator-input-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.translator-input-group label {
  font-size: 0.75rem;
  color: var(--muted);
}

.translator-input-group select {
  background-color: #1a1a1f;
  border: 1px solid var(--rule);
  border-radius: 4px;
  color: var(--ink);
  padding: 6px;
  font-size: 0.75rem;
  width: 100%;
  outline: none;
}

.translator-arrow {
  text-align: center;
  font-size: 1.1rem;
  color: var(--accent);
  font-weight: bold;
}

.translator-output {
  background-color: #0f0f13;
  border: 1px dashed var(--rule-strong);
  padding: var(--space-sm);
  border-radius: 6px;
  font-size: 0.85rem;
  color: var(--accent);
  font-family: var(--font-mono);
  line-height: 1.4;
  min-height: 60px;
  display: flex;
  align-items: center;
}

.sandbox-user-cursor {
  position: absolute;
  left: 140px;
  bottom: 40px;
  pointer-events: none;
  display: flex;
  align-items: center;
  gap: 4px;
  z-index: 12;
  transition: transform 3s ease;
}

.cursor-tag {
  background-color: var(--accent);
  color: white;
  font-family: var(--font-mono);
  font-size: 0.55rem;
  padding: 2px 6px;
  border-radius: 2px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.sandbox-footer {
  background-color: #141418;
  border-top: 1px solid #0b0b0d;
  padding: 6px 16px;
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: #5a5a6a;
}

@media (max-width: 768px) {
  .figma-sandbox {
    height: 380px;
  }
  .sandbox-canvas {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    overflow-y: auto;
  }
  .sandbox-component, .translator-box {
    position: relative !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    width: 100% !important;
  }
}

/* Scroll-locked contact section */
.contact-scroll-container {
  position: relative;
  background-color: var(--bg-alt);
}

/* Footer layout */
.foot {
  position: relative;
  background: var(--bg-alt);
  border-top: 1px solid var(--rule);
  color: var(--ink);
  display: flex;
  flex-direction: column;
  padding: 80px 0 40px 0;
  box-sizing: border-box;
}

.foot h2 {
  font-size: clamp(48px, 9vw, 110px);
  line-height: .92;
  letter-spacing: .002em;
  margin: 0 0 64px 0;
  color: #fff;
  max-width: 1100px;
}

.foot h2 em {
  color: var(--accent);
  font-style: italic;
}

/* ── Orchid-style footer top row ── */
.foot-top-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 24px;
  border-bottom: none;
  padding-bottom: 0;
}

.foot-eyebrow {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 140px;
}

.foot-title-wrap {
  overflow: hidden;
  margin: 8px 0 16px 0;
  width: 100%;
}

.foot-title {
  font-family: var(--font-heading);
  font-size: clamp(48px, 6vw, 80px);
  line-height: 1.0;
  color: #fff;
  margin: 0;
  transform: translateY(100%);
  transition: transform 0.8s var(--ease-editorial);
}

.foot-top-row.revealed .foot-title {
  transform: translateY(0);
}

@keyframes soberShine {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.animated-contact-title {
  background: linear-gradient(90deg, #ffffff 0%, var(--accent) 50%, #ffffff 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  animation: soberShine 8s linear infinite;
}

.foot-sub {
  font-size: clamp(20px, 2.5vw, 28px);
  line-height: 1.45;
  color: var(--on-dark-muted);
  max-width: 100%;
  margin: 0;
  font-weight: 400;
}

.foot-sub .industry-hl {
  color: var(--accent);
  font-style: italic;
  font-weight: 500;
}

/* ── Services grid ── */
.foot-services-grid {
  display: grid;
  grid-template-columns: 60px 1fr 42%;
  gap: 0 48px;
  align-items: start;
  margin-top: 48px;
  margin-bottom: 24px;
}

.skill-num-col {
  padding-top: 14px;
}

.skill-num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: .1em;
  transition: color .3s;
}

/* ── Image panel ── */
.skill-media-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.skill-images-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 6px;
  overflow: hidden;
  background: var(--bg);
}

.skill-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .55s var(--ease-editorial);
}

.skill-img.active {
  opacity: 1;
}

/* ── Minimal footer credit row (soclinks + copyright) ── */
.foot-credit-row {
  display: flex;
  flex-direction: column;
  gap: 64px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 40px 0 0 0;
  margin-top: 80px;
}

.foot-credit-top-line {
  display: flex;
  gap: 32px;
}

.foot-credit-top-line a {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  letter-spacing: .08em;
  text-decoration: none;
  transition: color .2s;
}

.foot-credit-top-line a:hover {
  color: var(--accent);
}

.foot-credit-bottom-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--on-dark-muted);
}

.foot-contact-right {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.foot-location {
  font-size: 13px;
  line-height: 1.6;
  color: var(--on-dark-muted);
  margin: 0;
}

.foot-tz {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  letter-spacing: .08em;
}

.foot-email-link {
  display: inline-block;
  font-size: 13.5px;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid rgba(255,255,255,.2);
  padding-bottom: 2px;
  transition: border-color .2s, color .2s;
  word-break: break-all;
}

.foot-email-link:hover {
  color: #fff;
  border-color: var(--accent);
}

.micro-contact-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.micro-contact-form input {
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(255,255,255,.18);
  color: #fff;
  outline: none;
  font-size: 13px;
  width: 100%;
  padding-bottom: 6px;
  font-family: var(--font-body);
  transition: border-color .2s;
}

.micro-contact-form input:focus {
  border-color: rgba(255,255,255,.5);
}

.micro-contact-form input::placeholder {
  color: var(--muted);
}

.micro-submit-btn {
  align-self: flex-start;
  background: transparent;
  border: 1px solid rgba(255,255,255,.2);
  color: var(--accent);
  cursor: pointer;
  font-size: 11px;
  padding: 6px 14px;
  border-radius: 999px;
  letter-spacing: .08em;
  transition: background .2s, color .2s, border-color .2s;
}

.micro-submit-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.form-feedback-message {
  font-family: var(--font-mono);
  font-size: 10px;
  margin-top: 4px;
  min-height: 14px;
}

.skills-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.skill-item {
  font-family: var(--font-heading);
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1.1;
  color: rgba(255,255,255,.18);

  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
  position: relative;
  transition: color .35s var(--ease-editorial);
  letter-spacing: .005em;
  user-select: none;
  cursor: pointer;
}

.skill-item::before {
  content: '→';
  position: absolute;
  left: -28px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-family: var(--font-body);
  font-size: 16px;
  opacity: 0;
  transition: opacity .3s ease, transform .3s var(--ease-editorial);
  transform: translateY(-50%) translateX(-6px);
}

.skill-item.active {
  color: #fff;
}

.skill-item.active::before {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}


.skill-item:first-child {
  border-top: 1px solid var(--rule);
}

/* Description panel */
.skill-desc-panel {
  padding-top: 14px;
  position: relative;
  min-height: 80px;
}

.skill-desc {
  font-size: 15px;
  line-height: 1.65;
  color: var(--on-dark-muted);
  margin: 0;
  max-width: 340px;
  position: absolute;
  top: 14px;
  left: 0;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .4s var(--ease-editorial), transform .4s var(--ease-editorial);
  pointer-events: none;
}

.skill-desc.active {
  opacity: 1;
  transform: translateY(0);
  position: relative;
  pointer-events: auto;
}

/* Items always visible inside sticky section — no scroll-in stagger needed */
.skill-item {
  opacity: 1;
  transform: none;
}

/* Override: active color post-reveal */
.foot.revealed .skill-item.active { color: #fff; }

@media (max-width: 1024px) {
  .foot-services-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 48px;
  }
  .skill-num-col {
    display: none;
  }
  .skills-list {
    grid-column: 1 / -1;
  }
  .skill-media-col {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 32px;
  }
  .skill-images-wrap {
    width: 50%;
  }
  .skill-desc-panel {
    width: 50%;
  }
}

@media (max-width: 768px) {
  .foot {
    position: relative;
    height: auto;
    padding: 60px 0;
  }
  .contact-scroll-container {
    height: auto !important;
  }
  .foot-top-row {
    margin-bottom: 32px;
  }
  .foot-services-grid {
    grid-template-columns: 1fr;
    gap: 32px;
    margin-bottom: 32px;
  }
  .skill-media-col {
    flex-direction: column;
    gap: 16px;
  }
  .skill-images-wrap {
    width: 100%;
  }
  .skill-desc-panel {
    width: 100%;
  }
  .skill-item {
    font-size: 24px;
    padding: 10px 0;
  }
  .foot-credit-row {
    margin-top: 32px;
    padding-top: 24px;
  }
  .foot-credit-bottom-line {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* Fullscreen Immersive Case Study Overlay */
.case-study-modal-overlay {
  position: fixed;
  inset: 0;
  background-color: var(--bg);
  z-index: 99999;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.65s var(--ease-editorial);
  opacity: 0;
}

.case-study-modal-overlay.active {
  transform: translateY(0);
  opacity: 1;
}

.modal-nav-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1010;
  border-bottom: 1px solid var(--rule);
  background-color: rgba(11, 11, 13, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.modal-nav-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 18px var(--space-lg);
  display: flex;
  align-items: center;
  position: relative;
}

.modal-close-btn {
  background: transparent;
  border: 1px solid var(--rule-strong);
  color: var(--ink);
  padding: 8px 16px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 13px;
  cursor: pointer;
}

.modal-close-btn:hover {
  background-color: var(--ink);
  color: var(--bg);
}

.modal-project-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-heading);
  font-size: 20px;
  letter-spacing: .02em;
}

.modal-progress-bar-container {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: rgba(255,255,255,0.02);
}

.modal-progress-bar {
  height: 100%;
  width: 0%;
  background-color: var(--accent);
}

.modal-content-scroll {
  flex: 1;
  overflow-y: scroll;
  padding-top: 80px;
  scroll-behavior: smooth;
}

.modal-editorial-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--space-lg) var(--space-lg) var(--space-xl) var(--space-lg);
}

.modal-hero-header {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: var(--space-lg);
  align-items: center;
  margin-bottom: var(--space-xl);
}

@media (max-width: 900px) {
  .modal-hero-header {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

.modal-poster-wrapper {
  aspect-ratio: 2 / 1; /* Match widescreen project placeholder */
  width: 100%;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--rule-strong);
  box-shadow: 0 30px 60px rgba(0,0,0,0.6);
}

.modal-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-hero-text {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal-title {
  font-size: clamp(60px, 8vw, 100px);
  line-height: .9;
  letter-spacing: -.02em;
  color: var(--ink);
}

.modal-tagline {
  font-size: 1.3rem;
  font-weight: 300;
  line-height: 1.4;
  color: var(--ink-2);
  font-style: italic;
}

.modal-project-meta-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 64px;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 48px 0;
  margin-bottom: var(--space-xl);
}

@media (max-width: 900px) {
  .modal-project-meta-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

.meta-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.meta-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: .14em;
  text-transform: uppercase;
}

.meta-value {
  font-size: 14.5px;
  color: var(--ink);
}

.meta-lead-intro {
  font-size: 20px;
  color: var(--ink);
  font-weight: 300;
  line-height: 1.55;
}

.modal-narrative-flow {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  max-width: 900px;
  margin: 0 auto;
}

.narrative-block {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: var(--space-lg);
  border-top: 1px solid var(--rule);
  padding-top: 32px;
}

@media (max-width: 768px) {
  .narrative-block {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.block-num {
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: .14em;
}

.narrative-block-content {
  max-width: 620px;
}

.narrative-block-content h2 {
  font-size: 38px;
  margin-bottom: 20px;
  color: var(--ink);
  letter-spacing: .002em;
}

.narrative-block-content p {
  font-size: 15.5px;
  line-height: 1.65;
  margin-bottom: 20px;
  color: var(--ink-2);
}

.narrative-block-content ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: var(--space-sm);
  padding: 0;
}

.narrative-block-content li {
  position: relative;
  padding-left: 20px;
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--ink-2);
}

.narrative-block-content li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}

.modal-footer-nav {
  margin-top: var(--space-xl);
  border-top: 1px solid var(--rule);
  padding-top: var(--space-xl);
  display: flex;
  justify-content: center;
}

.next-project-link-card {
  width: 100%;
  max-width: 700px;
  background-color: var(--bg-alt);
  border: 1px solid var(--rule-strong);
  border-radius: 16px;
  padding: var(--space-lg) var(--space-md);
  text-align: center;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  transition: border-color 0.4s ease, box-shadow 0.4s ease;
}

.next-project-link-card:hover {
  border-color: var(--accent);
  box-shadow: 0 15px 40px rgba(0,0,0,0.6);
}

.next-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: .14em;
  text-transform: uppercase;
}

.next-title {
  font-family: var(--font-heading);
  font-size: 64px;
  color: var(--ink);
  line-height: 1;
}

.next-project-link-card:hover .next-title {
  color: var(--accent);
}

.next-arrow {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  margin-top: 4px;
}

/* Scroll-driven text highlight */
.scroll-highlight-text {
  display: flex;
  flex-wrap: wrap;
  gap: 0 8px;
}

.scroll-highlight-text span {
  color: rgba(255, 255, 255, 0.18);
  transition: color 0.4s ease;
}

.scroll-highlight-text span.highlighted {
  color: #fff;
}

/* Magnifying Lens */
.magnifier-lens {
  position: absolute;
  pointer-events: none;
  width: 250px;
  height: 250px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  background-repeat: no-repeat;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5), inset 0 0 20px rgba(255,255,255,0.05);
  display: none;
  z-index: 1000;
  backdrop-filter: blur(2px);
}

/* Skills Editorial Layout */
.skill-row {
  display: flex;
  gap: 80px;
  align-items: center;
}
.skill-row.reverse {
  flex-direction: row-reverse;
}
.skill-img-wrapper {
  flex: 1.2;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--rule);
}
.skill-text-wrapper {
  flex: 1;
}

@media (max-width: 768px) {
  .skill-row, .skill-row.reverse {
    flex-direction: column;
    gap: 40px;
  }
  .skill-img-wrapper, .skill-text-wrapper {
    flex: none;
    width: 100%;
  }
}

/* Clipboard Copy Feedback */
.highlight-copied {
  color: var(--primary) !important;
  font-weight: 600;
  pointer-events: none;
  transition: all 0.2s ease;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
  .scroll-highlight-text span {
    color: #fff !important;
  }
  .foot-title {
    transform: translateY(0) !important;
  }
}

/* Image loading skeleton animation */
img[loading="lazy"] {
  background: linear-gradient(90deg, var(--surface-container) 25%, var(--surface-container-highest) 50%, var(--surface-container) 75%);
  background-size: 400% 100%;
  animation: skeleton-loading 1.5s infinite;
  color: transparent; 
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.ab-personal-works-btn {
  align-self: flex-start;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--rule-strong);
  background: transparent;
  color: var(--ink);
  padding: 12px 24px;
  border-radius: 4px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  transition: background 0.3s ease, color 0.3s ease;
}
.ab-personal-works-btn:hover {
  background: var(--ink);
  color: var(--bg);
}
.ab-social-link {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink);
  text-decoration: none;
  position: relative;
  padding-bottom: 2px;
}
.ab-social-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.ab-social-link:hover::after {
  transform: scaleX(1);
}

/* Personal Works Gallery Styles */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
  width: 100%;
}

.video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  background: var(--surface-container);
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  width: 100%;
}

.gallery-item {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: var(--surface-container);
}

.gallery-item img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.gallery-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

/* Social Icons */
.ab-social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--surface-container);
  color: var(--ink);
  border: 1px solid var(--rule);
  transition: all 0.3s ease;
}
.ab-social-icon svg {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease;
}
.ab-social-icon:hover {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.ab-social-icon:hover svg {
  transform: scale(1.1);
}

/* Lightbox Modal */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.95);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  backdrop-filter: blur(10px);
}

.lightbox-modal.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox-content-wrapper {
  position: relative;
  width: 90%;
  height: 90%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 8px;
  transform: scale(0.95);
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.lightbox-modal.active .lightbox-img {
  transform: scale(1);
  opacity: 1;
}

/* Lightbox Controls */
.lightbox-btn {
  position: absolute;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.2);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10000;
}

.lightbox-btn:hover {
  background: #fff;
  color: #000;
  transform: scale(1.1);
}

.lightbox-btn svg {
  width: 24px;
  height: 24px;
}

.lightbox-close {
  top: 24px;
  right: 24px;
  position: fixed;
}

.lightbox-prev {
  left: 24px;
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-prev:hover {
  transform: translateY(-50%) scale(1.1);
}

.lightbox-next {
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-next:hover {
  transform: translateY(-50%) scale(1.1);
}

body.lightbox-open {
  overflow: hidden;
}

@media (max-width: 768px) {
  .lightbox-prev, .lightbox-next {
    top: auto;
    bottom: 24px;
    transform: none;
  }
  .lightbox-prev { left: 24px; }
  .lightbox-next { right: 24px; }
  .lightbox-prev:hover { transform: scale(1.1); }
  .lightbox-next:hover { transform: scale(1.1); }
  .lightbox-content-wrapper { height: 80%; }
}
\nbody.lightbox-open { cursor: default !important; }\nbody.lightbox-open * { cursor: default; }\nbody.lightbox-open .lightbox-btn, body.lightbox-open .lightbox-btn * { cursor: pointer !important; }\n

/* --- New Featured Work Grid Layout --- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  padding-bottom: var(--space-xl);
}

@media (max-width: 900px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

.project-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-alt);
  border: 1px solid var(--rule);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.6s ease, border-color 0.4s ease;
  transform: perspective(1000px) translateZ(0);
}

/* Glass sweeping overlay effect */
.project-card::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 50%; height: 100%;
  background: linear-gradient(to right, transparent, rgba(255,255,255,0.06), transparent);
  transform: skewX(-25deg);
  transition: none;
  pointer-events: none;
  z-index: 10;
}

.project-card:hover::after {
  animation: glass-sweep 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes glass-sweep {
  0% { left: -100%; }
  100% { left: 200%; }
}

.project-card:hover {
  transform: perspective(1000px) translateY(-12px) scale(1.02);
  box-shadow: 0 40px 80px -15px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.15);
  border-color: rgba(255,255,255,0.1);
}

.project-card-img {
  width: 100%;
  height: 380px;
  overflow: hidden;
  position: relative;
  border-bottom: 1px solid var(--rule);
}

.project-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform-origin: center;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1.2s ease;
  filter: brightness(0.9) contrast(1.05);
}

.project-card:hover .project-card-img img {
  transform: scale(1.08) rotate(-1deg);
  filter: brightness(1.05) contrast(1);
}

.project-card-content {
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  background: linear-gradient(to bottom, var(--bg-alt), #050505);
}

.project-card-content h3 {
  font-family: var(--font-heading);
  font-size: 44px;
  line-height: .95;
  letter-spacing: .005em;
  margin: 12px 0 16px;
  transition: color 0.4s ease;
}

.project-card:hover .project-card-content h3 {
  color: #fff;
}

.project-card-content .project-desc {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-2);
  margin: 0 0 32px;
  flex-grow: 1;
}

.project-card-content .tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.project-card-content .cta-sm {
  padding: 14px 28px;
  font-size: 13px;
  align-self: flex-start;
  transition: background 0.4s ease, color 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .cta-sm {
  background: #fff;
  color: var(--bg);
  transform: translateY(-2px);
}




/* --- Rich Animated Featured Work Grid Layout --- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  padding-bottom: var(--space-xl);
}

@media (max-width: 900px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

/* 1 Large + 2 Small Layout */
.projects-grid .project-card:first-child {
  grid-column: span 2;
}

.project-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-alt);
  border: 1px solid var(--rule);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.6s ease, border-color 0.4s ease;
  transform: perspective(1000px) translateZ(0);
}

/* Glass sweeping overlay effect */
.project-card::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 50%; height: 100%;
  background: linear-gradient(to right, transparent, rgba(255,255,255,0.06), transparent);
  transform: skewX(-25deg);
  transition: none;
  pointer-events: none;
  z-index: 10;
}

.project-card:hover::after {
  animation: glass-sweep 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes glass-sweep {
  0% { left: -100%; }
  100% { left: 200%; }
}

.project-card:hover {
  transform: perspective(1000px) translateY(-12px) scale(1.02);
  box-shadow: 0 40px 80px -15px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.15);
  border-color: rgba(255,255,255,0.1);
}

.project-card-img {
  width: 100%;
  height: 380px;
  overflow: hidden;
  position: relative;
  border-bottom: 1px solid var(--rule);
}

.projects-grid .project-card:first-child .project-card-img {
  height: 500px;
}
@media (max-width: 900px) {
  .projects-grid .project-card:first-child { grid-column: span 1; }
  .projects-grid .project-card:first-child .project-card-img { height: 340px; }
}

.project-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform-origin: center;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1.2s ease;
  filter: brightness(0.9) contrast(1.05);
}

.project-card:hover .project-card-img img {
  transform: scale(1.08) rotate(-1deg);
  filter: brightness(1.05) contrast(1);
}

.project-card-content {
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  background: linear-gradient(to bottom, var(--bg-alt), #050505);
}

.project-card-content h3 {
  font-family: var(--font-heading);
  font-size: 44px;
  line-height: .95;
  letter-spacing: .005em;
  margin: 12px 0 16px;
  transition: color 0.4s ease;
}

.project-card:hover .project-card-content h3 {
  color: #fff;
}

.project-card-content .project-desc {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-2);
  margin: 0 0 32px;
  flex-grow: 1;
}

.project-card-content .tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.project-card-content .cta-sm {
  padding: 14px 28px;
  font-size: 13px;
  align-self: flex-start;
  transition: background 0.4s ease, color 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .cta-sm {
  background: #fff;
  color: var(--bg);
  transform: translateY(-2px);
}


/* --- Global Scroll Progress & Fixed Nav --- */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: var(--primary);
  width: 0%;
  z-index: 999999 !important;
  transition: width 0.1s ease-out;
  box-shadow: 0 0 15px rgba(255, 94, 0, 0.8);
}

/* Ensure Nav is truly fixed and glassy everywhere */
.nav {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  z-index: 9999 !important;
  background: rgba(8, 8, 8, 0.7) !important;
  backdrop-filter: blur(24px) !important;
  -webkit-backdrop-filter: blur(24px) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Prevent content from hiding under fixed nav */
body {
  padding-top: 80px; /* Adjust based on nav height */
}

/* ==============================================================
   AWWWARDS-LEVEL PORTFOLIO RESPONSIVE DESIGN SYSTEM
   ============================================================== */

/* Project Card Footer & Explicit Button Separation */
.project-card-footer {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}

.project-card-footer .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 0 !important;
}

.project-card-footer .cta-sm {
  margin-top: 0 !important;
  flex-shrink: 0;
}

/* Nav Left Wrap & Toggle */
.nav-left-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}

.mobile-menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--rule-strong);
  color: var(--ink);
  width: 40px;
  height: 40px;
  border-radius: 8px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  position: relative;
  z-index: 99999;
}
.mobile-menu-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--ink);
}

/* Mobile Sidebar Drawer Overlay */
.mobile-sidebar-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 99990;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.mobile-sidebar-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.mobile-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 300px;
  max-width: 85vw;
  height: 100vh;
  background: #0d0d11;
  border-right: 1px solid var(--rule-strong);
  z-index: 99995;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 32px 24px;
  transform: translateX(-100%);
  transition: transform 0.4s var(--ease-editorial);
  box-shadow: 10px 0 50px rgba(0,0,0,0.9);
}
.mobile-sidebar.active {
  transform: translateX(0);
}

.mobile-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 16px;
  width: 100%;
}
.mobile-sidebar-title {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  color: var(--muted);
}
.mobile-sidebar-close {
  background: transparent;
  border: none;
  color: var(--ink);
  font-size: 22px;
  cursor: pointer;
  padding: 4px 8px;
}
.mobile-sidebar-links {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 32px;
  margin-bottom: auto;
  width: 100%;
}
.mobile-sidebar-link {
  font-family: var(--font-heading);
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: .02em;
  color: var(--ink-2);
  transition: color 0.2s ease, transform 0.2s ease;
  text-align: left;
}
.mobile-sidebar-link:hover {
  color: var(--accent);
  transform: translateX(6px);
}
.mobile-sidebar-footer {
  margin-top: auto;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
}
.mobile-sidebar-footer .nav-cta {
  width: 100% !important;
  text-align: center !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 0 !important;
}

/* -------------------------------------------------------------
   MOBILE VIEWPORT STACK (< 768px): SINGLE-COLUMN FLUID LAYOUT
   ------------------------------------------------------------- */
@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: flex;
  }
  .nav .links {
    display: none !important;
  }
  .logo-lastname {
    display: none !important;
  }

  /* 1. Ways I Contribute (Single-Column Cards) */
  .roles-head h2 {
    font-size: 48px !important;
    line-height: .95 !important;
  }
  .roles-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
  }
  .role-card {
    width: 100% !important;
    padding: 28px 20px 24px 20px !important;
    min-height: auto !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
  }
  .role-card > div {
    display: flex !important;
    flex-direction: column !important;
    flex-grow: 1 !important;
  }
  .role-num {
    font-size: 44px !important;
    margin-bottom: 20px !important;
  }
  .role-card h3 {
    font-size: 30px !important;
    line-height: 1.05 !important;
    margin: 0 0 10px 0 !important;
  }
  .role-desc {
    font-size: 13.5px !important;
    line-height: 1.55 !important;
    margin: 0 0 20px 0 !important;
    max-width: 100% !important;
  }
  .role-btn {
    margin-top: auto !important;
    padding: 10px 20px !important;
    font-size: 10px !important;
    align-self: flex-start !important;
    display: inline-flex !important;
  }
  .role-viz {
    top: 20px !important;
    right: 20px !important;
    width: 52px !important;
    height: 36px !important;
  }

  /* 2. Featured Work (Single-Column Cards with Explicit Footer Spacing) */
  .projects-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 28px !important;
  }
  .projects-grid .project-card:first-child {
    grid-column: span 1 !important;
  }
  .projects-grid .project-card:first-child .project-card-img {
    height: 220px !important;
  }
  .project-card-img {
    height: 200px !important;
  }
  .project-card-content {
    padding: 24px 20px !important;
    display: flex !important;
    flex-direction: column !important;
  }
  .project-card-content h3 {
    font-size: 30px !important;
    margin: 8px 0 10px 0 !important;
    line-height: 1.05 !important;
  }
  .project-card-content .project-desc {
    font-size: 13.5px !important;
    line-height: 1.55 !important;
    margin: 0 0 16px 0 !important;
  }
  
  /* Guarantee Clean Separating Gap Between Tags and Action Button */
  .project-card-footer {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 16px !important;
    margin-top: 16px !important;
    padding-top: 16px !important;
    border-top: 1px solid var(--rule) !important;
    width: 100% !important;
  }
  .project-card-footer .tags {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    margin: 0 !important;
  }
  .project-card-footer .tags .tag {
    font-size: 9.5px !important;
    padding: 5px 10px !important;
  }
  .project-card-footer .cta-sm {
    padding: 12px 22px !important;
    font-size: 11px !important;
    align-self: flex-start !important;
    margin: 0 !important;
    display: inline-flex !important;
    width: auto !important;
  }

  /* 3. About Me Section Stack */
  .ab-intro {
    display: flex !important;
    flex-direction: column !important;
    gap: 36px !important;
    padding-bottom: 40px !important;
  }
  .ab-left-col {
    width: 100% !important;
  }
  .about-head h2 {
    font-size: 48px !important;
  }
  .ab-right-col {
    align-items: center !important;
    width: 100% !important;
    gap: 32px !important;
  }
  .big-portrait {
    max-width: 240px !important;
  }
  .ab-portrait-sandbox {
    height: auto !important;
    max-width: 100% !important;
  }

  /* 4. Beyond the Interface (Single-Column Cards) */
  .skills-editorial-layout {
    display: flex !important;
    flex-direction: column !important;
    gap: 28px !important;
    margin-top: 28px !important;
  }
  .skill-row, .skill-row.reverse {
    flex-direction: column !important;
    gap: 16px !important;
    background: var(--bg-alt);
    border: 1px solid var(--rule);
    border-radius: 16px;
    padding: 24px 20px;
  }
  .skill-text-wrapper h3 {
    font-size: 28px !important;
    line-height: 1.1 !important;
    margin-bottom: 12px !important;
  }
  .skill-text-wrapper p {
    font-size: 13.5px !important;
    line-height: 1.55 !important;
    margin-bottom: 16px !important;
  }
  .skill-text-wrapper .tag {
    font-size: 9.5px !important;
    padding: 4px 8px !important;
  }
}

