/* ==========================================
   FG CREATIVE PLANNING — Portfolio Styles
   Inspired by jasonbergh.com
   ========================================== */

/* ---------- Cookie Banner ---------- */
#cookie-banner { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: flex-end; justify-content: center; padding: 24px; opacity: 1; transition: opacity 0.4s ease; }
#cookie-banner.cb-hide { opacity: 0; pointer-events: none; }
.cb-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.4); }
.cb-dialog {
  position: relative; z-index: 1;
  background: var(--bg); color: var(--text);
  border: 1px solid rgba(128,128,128,0.15);
  border-radius: 16px; padding: 32px;
  max-width: 520px; width: 100%;
  box-shadow: 0 12px 48px rgba(0,0,0,0.2);
  font-family: 'Space Mono', monospace;
}
.cb-title { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 18px; font-weight: 700; margin: 0 0 12px; }
.cb-text { font-size: 12px; line-height: 1.7; opacity: 0.7; margin: 0 0 24px; }
.cb-options { margin-bottom: 24px; }
.cb-option {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0; border-bottom: 1px solid rgba(128,128,128,0.12);
  cursor: pointer; gap: 16px;
}
.cb-option--disabled { cursor: default; opacity: 0.6; }
.cb-option-info { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.cb-option-info strong { font-size: 13px; }
.cb-option-info span { font-size: 11px; opacity: 0.6; }
.cb-badge { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.5; white-space: nowrap; }
.cb-option input[type="checkbox"] { display: none; }
.cb-toggle {
  width: 42px; height: 24px; border-radius: 12px; flex-shrink: 0;
  background: rgba(128,128,128,0.3); position: relative; transition: background 0.2s;
}
.cb-toggle::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--bg); transition: transform 0.2s; box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.cb-option input:checked + .cb-toggle { background: var(--accent); }
.cb-option input:checked + .cb-toggle::after { transform: translateX(18px); }
.cb-buttons-wrap { margin-bottom: 16px; }
.cb-btn--full { width: 100%; margin-bottom: 8px; }
.cb-buttons-row { display: flex; gap: 8px; }
.cb-buttons { display: flex; gap: 8px; margin-bottom: 16px; }
.cb-btn {
  flex: 1; padding: 12px 16px; border-radius: 8px; border: none;
  font-family: 'Space Mono', monospace; font-size: 12px; font-weight: 700;
  letter-spacing: 0.05em; text-transform: uppercase; cursor: pointer;
  transition: all 0.2s;
}
.cb-btn--primary { background: #1C1C1A; color: #FFFCF2; }
[data-theme="dark"] .cb-btn--primary { background: #FFFCF2; color: #1C1C1A; }
.cb-btn--primary:hover { opacity: 0.85; }
.cb-btn--outline { background: transparent; border: 1px solid rgba(128,128,128,0.3); color: inherit; }
.cb-btn--outline:hover { border-color: currentColor; }
.cb-btn--outline:hover { border-color: var(--text); }
.cb-privacy-link { display: block; text-align: center; font-size: 11px; opacity: 0.4; text-decoration: underline; }

@media (max-width: 600px) {
  #cookie-banner { padding: 0; align-items: flex-end; }
  .cb-overlay { background: rgba(0,0,0,0.3); }
  .cb-dialog {
    padding: 16px;
    border-radius: 14px 14px 0 0;
    max-width: 100%;
    width: 100%;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.15);
  }
  .cb-title { font-size: 14px; margin-bottom: 4px; }
  .cb-text { font-size: 10px; line-height: 1.4; margin-bottom: 10px; }
  .cb-buttons-wrap { margin-bottom: 8px; }
  .cb-buttons-row { display: flex; gap: 6px; margin-bottom: 6px; }
  .cb-btn { padding: 10px 8px; font-size: 9px; flex: 1; }
  .cb-btn--full { padding: 12px; font-size: 10px; }
  .cb-privacy-link { font-size: 9px; margin-top: 4px; }
  .cb-option-info strong { font-size: 12px; }
  .cb-option-info span { font-size: 10px; }
  .cb-option { padding: 10px 0; }
}

/* ---------- Cookie Music Prompt ---------- */
.cookie-music-prompt {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9998;
  background: var(--bg);
  color: var(--text);
  border: 1px solid rgba(128,128,128,0.2);
  border-radius: 12px;
  padding: 16px 24px;
  max-width: 400px;
  width: calc(100% - 48px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.15);
  font-family: 'Space Mono', monospace;
  animation: cmpSlideUp 0.3s ease;
}
@keyframes cmpSlideUp {
  from { transform: translateX(-50%) translateY(20px); opacity: 0; }
  to { transform: translateX(-50%) translateY(0); opacity: 1; }
}
.cookie-music-prompt p {
  font-size: 12px;
  line-height: 1.6;
  margin: 0 0 12px;
  opacity: 0.8;
}
.cookie-music-btns {
  display: flex;
  gap: 8px;
}
.cmp-btn {
  padding: 8px 16px;
  border-radius: 6px;
  border: none;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
}
.cmp-btn--accept {
  background: var(--text);
  color: var(--bg);
}
.cmp-btn--close {
  background: transparent;
  border: 1px solid rgba(128,128,128,0.3);
  color: var(--text);
}

/* ---------- Variables ---------- */
:root {
  --bg: #252422;
  --bg-raise: #2e2c2a;
  --cream: #FFFCF2;
  --muted: rgba(255, 252, 242, 0.58);
  --very-muted: rgba(255, 252, 242, 0.1);
  --border: rgba(255, 252, 242, 0.08);
  --accent: #E5383B;

  --font-display: 'Inter', sans-serif;
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Inter', -apple-system, sans-serif;
  --font-mono: 'Inconsolata', monospace;

  --ease: cubic-bezier(0.75, 0, 0.25, 1);
  --duration: 0.6s;

  --nav-h: 80px;

  /* Neumorphism dark */
  --neo-raise:
    -5px -5px 12px rgba(255,255,255,0.04),
     5px  5px 18px rgba(0,0,0,0.75);
  --neo-raise-lg:
    -8px -8px 20px rgba(255,255,255,0.05),
     8px  8px 28px rgba(0,0,0,0.8);
  --neo-press:
    inset -3px -3px 8px rgba(255,255,255,0.04),
    inset  3px  3px 10px rgba(0,0,0,0.65);
  --neo-subtle:
    -3px -3px 8px rgba(255,255,255,0.03),
     3px  3px 10px rgba(0,0,0,0.55);
  --radius: 18px;
  --radius-sm: 10px;
  --radius-pill: 100px;
}

/* ---------- Light Mode ---------- */
/*
 * Logica: la HERO ha sempre sfondo scuro (foto blurrata), quindi
 * testo e CDJ restano chiari. Solo le sezioni SOTTO la hero
 * (work, about, contact, footer) usano colori scuri su sfondo chiaro.
 */
[data-theme="light"] {
  --bg: #FFFCF2;
  --bg-raise: #F5F2E8;
  --cream: #252422;
  --muted: rgba(37, 36, 34, 0.58);
  --very-muted: rgba(37, 36, 34, 0.1);
  --border: rgba(37, 36, 34, 0.1);
  --neo-raise:
    -5px -5px 12px rgba(255,255,255,0.85),
     5px  5px 18px rgba(0,0,0,0.10);
  --neo-raise-lg:
    -8px -8px 20px rgba(255,255,255,0.9),
     8px  8px 28px rgba(0,0,0,0.12);
  --neo-press:
    inset -3px -3px 8px rgba(255,255,255,0.7),
    inset  3px  3px 10px rgba(0,0,0,0.06);
  --neo-subtle:
    -3px -3px 8px rgba(255,255,255,0.7),
     3px  3px 10px rgba(0,0,0,0.08);
}

/* ---- Light mode hero ---- */
[data-theme="light"] .hero {
  background: var(--bg);
}
[data-theme="light"] .hero-heading {
  color: var(--cream);
}
[data-theme="light"] .hero-role {
  color: var(--cream);
}

/* ---- Nav light mode ---- */
/* Light mode: logo scuro (no invert), tutto usa le variabili */
[data-theme="light"] .nav-logo img {
  filter: none;
  opacity: 0.85;
}
[data-theme="light"] .nav.scrolled {
  background: var(--bg);
  box-shadow: 0 1px 0 var(--border);
}

/* ---- Card folder glass → tono caldo chiaro ---- */
[data-theme="light"] .card-folder {
  background: rgba(240,234,214,0.52);
  border-color: rgba(28,28,26,0.13);
  box-shadow:
    inset 0  1px 0 rgba(255,255,255,0.5),
    inset 0 -1px 0 rgba(0,0,0,0.04),
    0  6px 32px rgba(0,0,0,0.13),
    0  2px  8px rgba(0,0,0,0.07);
}
[data-theme="light"] .project-card:hover .card-folder {
  box-shadow:
    inset 0  1px 0 rgba(255,255,255,0.6),
    inset 0 -1px 0 rgba(0,0,0,0.04),
    0 16px 52px rgba(0,0,0,0.16),
    0  4px 14px rgba(0,0,0,0.09);
}
[data-theme="light"] .card-tab {
  background: rgba(28,28,26,0.06);
  border-color: rgba(28,28,26,0.11);
}
[data-theme="light"] .card-ghost-letter {
  color: rgba(28,28,26,0.09);
}

/* Overlay progetto */
[data-theme="light"] .overlay {
  background: var(--bg);
}

/* Ambient bg meno invadente in light */
[data-theme="light"] .ambient-bg {
  opacity: 0.2;
}

/* Grain più sottile */
[data-theme="light"] .grain-overlay {
  opacity: 0.03;
}

/* Preloader */
[data-theme="light"] .preloader {
  background: var(--bg);
}

/* ---- Services popover ---- */
[data-theme="light"] .services-popover {
  background: var(--bg-raise);
  box-shadow: var(--neo-raise-lg), 0 0 0 1px rgba(28,28,26,0.08);
}
[data-theme="light"] .services-popover::after {
  border-top-color: var(--bg-raise);
}
[data-theme="light"] .service-tag {
  background: var(--bg);
  border-color: rgba(28,28,26,0.08);
}

/* ---- Theme toggle button (base — su sfondo scuro hero) ---- */
.theme-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 5px 12px;
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
  margin-left: 8px;
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--muted);
}
.theme-toggle:hover {
  border-color: var(--muted);
  color: var(--cream);
}

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

html {
  overflow-x: hidden;
  background-color: var(--bg);
}

body {
  background-color: transparent;
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

@media (hover: hover) and (pointer: fine) {
  body { cursor: none; }
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ---------- Cursor (dot) ---------- */
.cursor {
  position: fixed;
  width: 9px;
  height: 9px;
  background: var(--cream);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  top: 0; left: 0;
  transform: translate(-50%, -50%);
  transition: width 0.35s var(--ease), height 0.35s var(--ease);
  mix-blend-mode: difference;
  will-change: transform;
}

.cursor.is-hovering {
  width: 48px;
  height: 48px;
}

.cursor.is-lens {
  width: 340px;
  height: 210px;
  border-radius: 0;
  background: transparent;
  border: none;
  mix-blend-mode: normal;
}

/* ---------- Preloader ---------- */
.preloader {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 24px;
}

.preloader-logo {
  width: 72px;
  height: 72px;
  filter: invert(1) sepia(1) saturate(0) brightness(10);
  opacity: 0;
}

.preloader-bar {
  width: 120px;
  height: 1px;
  background: var(--border);
  overflow: hidden;
}

.preloader-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--cream);
  transition: width 0.8s var(--ease);
}

/* ---------- Navigation ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  z-index: 100;
  transition: background 0.5s var(--ease), box-shadow 0.5s var(--ease);
}

.nav.scrolled {
  background: var(--bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}

.nav-logo {
  display: flex;
  align-items: center;
}

.nav-logo img {
  height: 80px;
  width: auto;
  filter: invert(1) sepia(1) saturate(0) brightness(10);
  opacity: 0.9;
  transition: opacity var(--duration);
}

.nav-logo img:hover { opacity: 1; }

/* Links centrati assoluti */
.nav-links {
  display: flex;
  gap: 40px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

/* Gruppo destra: lingua + tema */
.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-link {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--muted);
  transition: color var(--duration) var(--ease);
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 1px;
  background: var(--cream);
  transition: width var(--duration) var(--ease);
}

.nav-link:hover { color: var(--cream); }
.nav-link:hover::after { width: 100%; }

/* ---- Hamburger Button ---- */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 201;
}
.hamburger span {
  display: block;
  width: 100%;
  height: 1.5px;
  background: var(--text);
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
  transform-origin: center;
}
.hamburger.is-open span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.hamburger.is-open span:nth-child(2) {
  opacity: 0;
}
.hamburger.is-open span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ---- Mobile Menu Overlay ---- */
.mobile-menu {
  position: fixed;
  top: 0; right: 0;
  width: 100%;
  height: 100dvh;
  background: var(--bg);
  z-index: 199;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s var(--ease), visibility 0.35s var(--ease);
}
.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
}
.mobile-menu-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
}
.mobile-menu-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  padding: 0;
  margin: 0;
}
.mobile-menu-link {
  font-family: 'Space Mono', monospace;
  font-size: 28px;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
.mobile-menu-link:hover {
  color: var(--accent);
}
.mobile-menu-cta {
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.05em;
  color: var(--bg);
  background: var(--text);
  padding: 14px 32px;
  border-radius: 0;
  text-decoration: none;
  transition: opacity 0.2s var(--ease);
}
.mobile-menu-cta:hover { opacity: 0.85; }
.mobile-menu-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

/* ---- Hero CTA ---- */
.hero-cta {
  display: inline-block;
  margin-top: 28px;
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--bg);
  background: var(--text);
  padding: 14px 36px;
  text-decoration: none;
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}
.hero-cta:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

/* ---- Section CTA (end of Work / About) ---- */
.section-cta-wrap {
  display: flex;
  justify-content: center;
  padding: 48px 0 0;
}
.section-cta {
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text);
  border: 1px solid var(--text);
  padding: 12px 32px;
  text-decoration: none;
  transition: background 0.25s var(--ease), color 0.25s var(--ease);
}
.section-cta:hover {
  background: var(--text);
  color: var(--bg);
}

/* ---------- Hero — mssrgalleria inspired ---------- */
.hero {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 48px;
  position: relative;
  overflow: hidden;
  z-index: 1;
  background: var(--bg);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 55%;
}

/* Main heading — Inter, clean, no uppercase */
.hero-heading {
  font-family: 'Inter', sans-serif;
  font-size: clamp(32px, 4.5vw, 56px);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--cream);
  margin: 0;
}

.hero-line {
  display: block;
}

/* Typewriter role — bold */
.hero-role {
  font-weight: 700;
  color: var(--cream);
}

/* Blinking cursor */
.hero-cursor {
  font-weight: 300;
  color: var(--accent);
  animation: blink 1s steps(1) infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Role line — fixed height to prevent layout shift during typewriter */
.hero-line--role {
  min-height: 1.1em;
}

/* Hero bottom — scroll label */
.hero-bottom {
  position: absolute;
  bottom: 32px;
  left: 48px;
  z-index: 1;
}

.hero-scroll-label {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* ---------- Hero Reveal Lens Effect ---------- */
/* Hero reveal effect — DISABLED */
.hero-reveal-photo,
.hero-reveal-canvas {
  display: none !important;
}

/* hero-content must be above the reveal layers */
.hero-content { z-index: 1; position: relative; }
.hero-bottom { z-index: 1; }
.hero-vinyl-wrap { z-index: 1; }

/* ---------- Logo spin on click ---------- */
.nav-logo-link img {
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-logo-link.spinning img {
  transform: rotate(360deg);
}

/* ---------- Services Marquee ---------- */
.services-marquee {
  overflow: hidden;
  padding: 28px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.marquee-track {
  display: flex;
  gap: 0;
  white-space: nowrap;
  animation: marqueeScroll 30s linear infinite;
  width: max-content;
}

.marquee-track span {
  font-family: 'Inter', sans-serif;
  font-size: clamp(14px, 1.6vw, 20px);
  font-weight: 400;
  color: var(--cream);
  padding: 0 12px;
}

.marquee-sep {
  color: var(--accent) !important;
  font-size: clamp(10px, 1vw, 14px) !important;
  opacity: 0.6;
  vertical-align: middle;
  display: inline-flex;
  align-items: center;
}

@keyframes marqueeScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ---------- Section Header ---------- */
.section-header {
  padding: 0 48px 48px;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.section-num {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.6;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(42px, 5.5vw, 80px);
  font-weight: 800;
  font-style: normal;
  text-transform: uppercase;
  color: var(--cream);
  line-height: 0.9;
  letter-spacing: -0.02em;
  margin: 0;
}

/* Work category label */
/* Category labels — same style for both sections */
.work-category-label {
  font-family: 'Space Mono', monospace;
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 40px 48px;
  padding: 0;
  opacity: 0.9;
}

/* ---------- Film grain overlay — DISABLED for performance ---------- */
.grain-overlay {
  display: none !important;
}

@keyframes grain-shift {
  0%   { transform: translate(0, 0); }
  10%  { transform: translate(-2%, -3%); }
  20%  { transform: translate(3%, 1%); }
  30%  { transform: translate(-1%, 4%); }
  40%  { transform: translate(4%, -2%); }
  50%  { transform: translate(-3%, 3%); }
  60%  { transform: translate(2%, -4%); }
  70%  { transform: translate(4%, 2%); }
  80%  { transform: translate(-2%, -1%); }
  90%  { transform: translate(1%, 3%); }
}

/* ---------- Work Section ---------- */
.work { padding-top: 120px; position: relative; z-index: 1; }

/* ---------- Ambient background (Bloom colors wash — full site) ---------- */
.ambient-bg {
  position: fixed;
  inset: 0;
  background-image: url('bloom/foto/IMG_4997.JPG');
  background-size: cover;
  background-position: center;
  filter: blur(40px) saturate(1.8) brightness(1.4);
  transform: scale(1.18);
  z-index: 0;
  opacity: 0.55;
  transition: opacity 0.8s ease;
}

/* ---------- Work Grid — wrap, riempie la pagina ---------- */
.work-grid {
  display: flex;
  flex-wrap: nowrap;
  gap: 20px;
  padding: 60px 32px 100px;
  overflow: visible;
  justify-content: center;
  align-items: flex-start;
  user-select: none;
}

/* ---------- Project Card — badge style ---------- */
.project-card {
  flex-shrink: 0;
  cursor: none;
}

/* ---- Project badge logo — small, bottom-left ---- */
.badge-watermark--logo {
  bottom: 10px;
  left: 11px;
  transform: none;
  width: auto;
  height: 20px;
  font-size: 0;
  opacity: 1;
}
.badge-watermark--logo img {
  height: 20px;
  width: auto;
  max-width: 60px;
  opacity: 0.55;
  display: block;
  pointer-events: none;
  user-select: none;
}

/* ---- Folder TAB (top of folder, like macOS) ---- */
.card-tab {
  width: 100px;
  height: 22px;
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.16);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  position: relative;
  z-index: 1;
  transition: background 0.5s var(--ease);
}

.project-card:hover .card-tab {
  background: rgba(255,255,255,0.12);
}

.card-tab--concept {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.09);
}

/* ---- Folder BODY ---- */
.card-folder {
  width: 260px;
  height: 316px;
  position: relative;
  overflow: hidden;
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.16);
  /* Top-left corner flat (connects to tab), rest rounded */
  border-radius: 0 18px 18px 18px;
  box-shadow:
    inset 0  1px 0 rgba(255,255,255,0.18),
    inset 0 -1px 0 rgba(0,0,0,0.10),
    0  6px 32px rgba(0,0,0,0.50),
    0  2px  8px rgba(0,0,0,0.25);
  transition:
    transform 0.5s var(--ease),
    box-shadow 0.5s var(--ease),
    background 0.5s var(--ease);
}

.project-card:hover .card-folder {
  transform: translateY(-5px);
  background: rgba(255,255,255,0.11);
  box-shadow:
    inset 0  1px 0 rgba(255,255,255,0.24),
    inset 0 -1px 0 rgba(0,0,0,0.10),
    0 16px 52px rgba(0,0,0,0.60),
    0  4px 14px rgba(0,0,0,0.35);
}

/* Photo bleeding through glass */
.card-folder-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(10px) brightness(0.28) saturate(0.6);
  transform: scale(1.14);
  transition: filter 0.7s var(--ease);
  will-change: transform;
}

.project-card:hover .card-folder-bg {
  filter: blur(10px) brightness(0.28) saturate(0.6);
}

/* Glass top highlight */
.card-folder::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 48%;
  background: linear-gradient(
    175deg,
    rgba(255,255,255,0.09) 0%,
    transparent 100%
  );
  pointer-events: none;
  z-index: 1;
}

/* Inner layout */
.card-folder-inner {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px;
}

.card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-num {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: rgba(245,237,214,0.32);
}

.card-arrow {
  font-size: 16px;
  color: rgba(245,237,214,0.38);
  transition: transform 0.4s var(--ease), color 0.4s;
}

.project-card:hover .card-arrow {
  transform: translate(3px, -3px);
  color: var(--cream);
}

/* Ghost letter — big watermark inside folder */
.card-mid {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.card-ghost-letter {
  font-family: var(--font-display);
  font-size: clamp(80px, 12vw, 120px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
  color: rgba(245,237,214,0.18);
  transition: color 0.5s var(--ease), transform 0.5s var(--ease);
  display: block;
  user-select: none;
}

.project-card:hover .card-ghost-letter {
  color: rgba(245,237,214,0.28);
  transform: scale(1.06);
}

/* Bottom row: logo + name/cat */
.card-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
}

.card-logo {
  height: 28px;
  width: auto;
  max-width: 110px;
  object-fit: contain;
  opacity: 1;
  flex-shrink: 0;
}

.card-logo--large {
  height: 32px;
  max-width: 180px;
  opacity: 1;
}

/* Logo orizzontale/wordmark — riduce la larghezza massima */
.card-logo--narrow {
  max-width: 80px;
}

/* Logo icona — dopo crop viewBox il contenuto riempie lo spazio */
.card-logo--icon {
  height: 44px;
  max-width: 56px;
}

.card-logo--xlarge {
  height: 60px;
  max-width: 200px;
  opacity: 0.9;
}

.card-logo--invert {
  filter: invert(1) sepia(1) saturate(0) brightness(10);
}

/* For logos with solid black background — screen blend removes black on dark cards */
.card-logo--screen {
  mix-blend-mode: screen;
  opacity: 0.9;
}

.card-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}

.card-name {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 300;
  letter-spacing: -0.01em;
  color: var(--cream);
  line-height: 1;
}

.card-cat {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(245,237,214,0.38);
}

.card-folder--concept {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.08);
}

/* Work-in-progress cards — slightly warmer tint */
.card-folder--wip {
  background: rgba(245,237,214,0.05);
  border-color: rgba(245,237,214,0.1);
}

.card-folder--wip .card-ghost-letter {
  color: rgba(245,237,214,0.12);
}

.card-wip-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-family: var(--font-body);
  font-size: 7.5px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(245,237,214,0.4);
  border: 1px solid rgba(245,237,214,0.15);
  border-radius: 100px;
  padding: 3px 9px;
  pointer-events: none;
}

.project-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}

.project-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(18, 18, 16, 0.58);
}

.project-item:hover .project-bg {
  opacity: 1;
  transform: scale(1);
}

.project-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 44px 48px 44px;
  transition: padding var(--duration) var(--ease);
  min-height: 140px;
}

.project-item:hover .project-inner {
  padding: 60px 48px;
}

.project-left {
  display: flex;
  align-items: baseline;
  gap: 28px;
  flex: 1;
}

.project-num {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
  min-width: 20px;
  transition: color var(--duration);
}

.project-item:hover .project-num { color: var(--cream); }

.project-name-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.project-name {
  font-family: var(--font-display);
  font-size: clamp(36px, 5.5vw, 88px);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1;
  transition: color var(--duration);
}

.project-tagline {
  font-size: 13px;
  color: var(--muted);
  letter-spacing: 0.03em;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}

.project-item:hover .project-tagline {
  opacity: 1;
  transform: translateY(0);
}

.project-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
  margin-left: 48px;
}

.project-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
  opacity: 0;
  transform: translateX(12px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}

.project-item:hover .project-tags {
  opacity: 1;
  transform: translateX(0);
}

.project-tags span {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  background: var(--bg);
  box-shadow: var(--neo-subtle);
  color: var(--muted);
}

.project-arrow {
  font-size: 22px;
  color: var(--muted);
  transition: transform var(--duration) var(--ease), color var(--duration);
  line-height: 1;
}

.project-item:hover .project-arrow {
  transform: translate(4px, -4px);
  color: var(--cream);
}

/* ---------- Concepts Collection Overlay ---------- */
.concepts-page-header {
  margin-bottom: 64px;
}

.concepts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 20px;
}

.concept-card {
  background: var(--bg-raise);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--neo-raise);
  cursor: pointer;
  transition:
    box-shadow var(--duration) var(--ease),
    transform var(--duration) var(--ease);
  position: relative;
  overflow: hidden;
}

.concept-card:hover {
  box-shadow: var(--neo-raise-lg);
  transform: translateY(-3px);
}

.concept-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.concept-card-num {
  font-size: 11px;
  letter-spacing: 0.15em;
  color: var(--muted);
}

.concept-card-badge {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: var(--bg);
  box-shadow: var(--neo-subtle);
  color: var(--muted);
}

.concept-card-name {
  font-family: var(--font-display);
  font-size: clamp(32px, 4vw, 56px);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 8px;
}

.concept-card-sub {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 20px;
  font-style: italic;
  font-family: var(--font-display);
}

.concept-card-desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.8;
  margin-bottom: 24px;
}

.concept-card-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.concept-card-tags span {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: var(--bg);
  box-shadow: var(--neo-subtle);
  color: var(--muted);
}

.concept-card-arrow {
  position: absolute;
  bottom: 32px;
  right: 32px;
  font-size: 20px;
  color: var(--muted);
  transition: transform var(--duration) var(--ease), color var(--duration);
}

.concept-card:hover .concept-card-arrow {
  transform: translate(3px, -3px);
  color: var(--cream);
}

/* ---------- Concept Section ---------- */
.concepts { padding-top: 80px; }

.project-item--concept .project-name {
  font-size: clamp(28px, 4vw, 64px);
  color: var(--muted);
  transition: color var(--duration);
}

.project-item--concept:hover .project-name {
  color: var(--cream);
}

.concept-badge {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--border);
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 16px;
  display: inline-block;
}

/* ---------- Service Tooltip ---------- */
.service-tooltip {
  position: fixed;
  background: var(--cream);
  color: var(--bg);
  font-size: 12px;
  line-height: 1.5;
  padding: 10px 16px;
  border-radius: 6px;
  max-width: 240px;
  pointer-events: none;
  z-index: 9997;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.service-tooltip.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- About Section ---------- */
.about {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
  content-visibility: auto;
  contain-intrinsic-size: auto 800px;
  padding: 140px 48px;
  border-top: 1px solid var(--border);
  position: relative;
  z-index: 1;
}

.about-image-wrap {
  position: sticky;
  top: calc(var(--nav-h) + 32px);
  overflow: hidden;
  aspect-ratio: 3/4;
}

.about-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: grayscale(15%);
  transition: transform 1s var(--ease);
}

.about-image-wrap:hover .about-image {
  transform: scale(1.04);
}

.about-content { padding-top: 8px; }

.about-title {
  font-family: var(--font-display);
  font-size: clamp(48px, 6vw, 100px);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  margin-bottom: 48px;
}

.about-title em {
  font-style: normal;
  color: var(--accent);
}

.about-bio {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: var(--muted);
  line-height: 1.9;
  margin-bottom: 20px;
  max-width: 500px;
}

.about-skills {
  margin-top: 64px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  border-top: 1px solid var(--border);
  padding-top: 40px;
}

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

.skill-label {
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cream);
  margin-bottom: 10px;
  display: block;
}

.skill-group span:not(.skill-label) {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.9;
}

/* --- Pass Card Scene --- */
.passcard-scene {
  display: grid;
  grid-template-columns: 150px 1fr 150px;
  align-items: center;
  width: 100%;
  max-width: 900px;
}

/* --- Annotation columns --- */
.passcard-anns {
  display: flex;
  flex-direction: column;
  gap: 34px;
  padding: 32px 0;
}

.ann {
  display: flex;
  align-items: center;
  gap: 0;
}

.ann-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-shrink: 0;
}

/* Letter in bordered box — identical to HP reference */
.ann-idx {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: rgba(245,237,214,0.75);
  border: 1px solid rgba(245,237,214,0.35);
  padding: 1px 4px;
  line-height: 1.5;
  display: inline-block;
  align-self: flex-start;
}

/* Skill label — monospace, small, faded */
.ann-text {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(245,237,214,0.45);
  line-height: 1.5;
  white-space: nowrap;
}

/* Thin 1px line */
.ann-line {
  flex: 1;
  height: 1px;
  background: rgba(245,237,214,0.25);
  min-width: 8px;
}

/* Perpendicular tick at card edge — like technical diagram */
.ann-dot {
  width: 1px;
  height: 14px;
  background: rgba(245,237,214,0.4);
  flex-shrink: 0;
}

/* Left: content → line → tick */
.passcard-anns--left .ann { flex-direction: row; }
.passcard-anns--left .ann-content { text-align: left; }

/* Right: tick → line → content */
.passcard-anns--right .ann { flex-direction: row; }
.passcard-anns--right .ann-content { text-align: left; }

/* --- Pass Card — HP style --- */
.passcard {
  background: #F3EFE8;
  border-radius: 6px;
  border: 1px solid rgba(0,0,0,0.14);
  box-shadow:
    0 2px 6px rgba(0,0,0,0.18),
    0 12px 40px rgba(0,0,0,0.4),
    0 32px 80px rgba(0,0,0,0.28);
  display: flex;
  flex-direction: row;
  overflow: hidden;
  font-family: var(--font-body);
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

/* Vertical "Portrait" strip on left edge */
.passcard-portrait-strip {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(10,10,8,0.38);
  padding: 14px 5px;
  border-right: 1px solid rgba(0,0,0,0.1);
  background: #E8E4DC;
  flex-shrink: 0;
  user-select: none;
}

/* Photo column */
.passcard-photo-col {
  width: 210px;
  flex-shrink: 0;
  border-right: 1px solid rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
}

.passcard-photo-wrap {
  flex: 1;
  overflow: hidden;
  min-height: 210px;
}

.passcard-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: grayscale(25%) contrast(1.05);
  display: block;
}

/* Orange accent tag — bottom of photo */
.passcard-event-tag {
  background: var(--accent);
  padding: 7px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(0,0,0,0.15);
}

.passcard-event-tag span {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #F3EFE8;
  text-transform: uppercase;
}

.passcard-event-num {
  font-size: 22px !important;
  font-weight: 900 !important;
  line-height: 1;
  background: rgba(0,0,0,0.15);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex !important;
  align-items: center;
  justify-content: center;
}

.passcard-barcode {
  padding: 8px 10px 10px;
  background: #E8E4DC;
  border-top: 1px solid rgba(0,0,0,0.08);
}

.pc-barcode-bars {
  height: 28px;
  background: repeating-linear-gradient(
    90deg,
    #0A0A08 0, #0A0A08 2px,
    transparent 2px, transparent 4px,
    #0A0A08 4px, #0A0A08 6px,
    transparent 6px, transparent 9px,
    #0A0A08 9px, #0A0A08 10px,
    transparent 10px, transparent 13px,
    #0A0A08 13px, #0A0A08 15px,
    transparent 15px, transparent 17px,
    #0A0A08 17px, #0A0A08 19px,
    transparent 19px, transparent 22px,
    #0A0A08 22px, #0A0A08 24px,
    transparent 24px, transparent 26px,
    #0A0A08 26px, #0A0A08 29px,
    transparent 29px, transparent 31px,
    #0A0A08 31px, #0A0A08 32px,
    transparent 32px, transparent 35px,
    #0A0A08 35px, #0A0A08 37px,
    transparent 37px, transparent 40px
  );
}

.pc-barcode-num {
  font-size: 6px;
  letter-spacing: 0.05em;
  color: rgba(10,10,8,0.32);
  display: block;
  margin-top: 4px;
  font-family: var(--font-mono);
}

/* Data column */
.passcard-data-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 18px 20px;
  min-width: 0;
}

/* Title header area */
.passcard-data-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 12px;
  border-bottom: 1.5px solid rgba(10,10,8,0.12);
  margin-bottom: 10px;
}

.passcard-title-main {
  display: block;
  font-family: var(--font-body);
  font-size: 30px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #0A0A08;
  line-height: 1;
}

.passcard-serial {
  display: block;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(10,10,8,0.38);
  margin-top: 5px;
}

/* FG© circle stamp */
.passcard-hp-stamp {
  width: 42px;
  height: 42px;
  border: 2px solid #0A0A08;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #0A0A08;
  flex-shrink: 0;
}

/* Data fields */
.passcard-fields {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.passcard-field {
  display: flex;
  gap: 14px;
  align-items: baseline;
  padding: 8px 0;
  border-bottom: 1px solid rgba(10,10,8,0.08);
}

/* Italic serif key — like HP's "Brand:", "Season:" */
.pf-key {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 15px;
  font-weight: 400;
  color: #0A0A08;
  min-width: 70px;
  flex-shrink: 0;
  letter-spacing: 0.01em;
}

.pf-val {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: #0A0A08;
  letter-spacing: 0.01em;
}

/* Handwritten signature line */
.passcard-signature {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 22px;
  font-weight: 600;
  color: rgba(10,10,8,0.5);
  margin: 10px 0 6px;
  letter-spacing: 0.02em;
  border-bottom: 1px solid rgba(10,10,8,0.1);
  padding-bottom: 8px;
}

/* Cert marks row */
.passcard-certmarks {
  margin-top: auto;
  display: flex;
  gap: 8px;
  align-items: center;
  padding-top: 10px;
}

.passcard-cert-square {
  width: 13px;
  height: 13px;
  background: var(--accent);
  border-radius: 2px;
  flex-shrink: 0;
}

.passcard-certmarks span:not(.passcard-cert-square) {
  font-family: var(--font-body);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(10,10,8,0.3);
  text-transform: uppercase;
}

/* Full Body strip — right edge */
.passcard-fullbody-col {
  width: 58px;
  flex-shrink: 0;
  border-left: 1px solid rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.passcard-fullbody-wrap {
  flex: 1;
  overflow: hidden;
}

.passcard-fullbody-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: grayscale(50%) contrast(1.1);
  display: block;
}

.passcard-fullbody-label {
  writing-mode: vertical-rl;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(10,10,8,0.35);
  padding: 8px 5px;
  border-top: 1px solid rgba(0,0,0,0.08);
  background: #E8E4DC;
  text-align: center;
  flex-shrink: 0;
  user-select: none;
}

/* ---------- Contact Section ---------- */
.contact {
  padding: 120px 48px 140px;
  border-top: 1px solid var(--border);
  content-visibility: auto;
  contain-intrinsic-size: auto 600px;
  display: flex;
  flex-direction: row;
  align-items: flex-end;
  gap: 60px;
  position: relative;
  z-index: 1;
}

.contact-title {
  flex-shrink: 0;
  position: sticky;
  top: calc(var(--nav-h) + 48px);
}

.contact-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 4.5vw, 70px);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-transform: uppercase;
}

.contact-title em { font-style: italic; }

.contact-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 24px;
}

.contact-cta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 16px 36px;
  border-radius: var(--radius-pill);
  background: var(--bg-raise);
  box-shadow: var(--neo-raise);
  transition:
    color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease),
    transform var(--duration) var(--ease);
}

.contact-cta:hover {
  color: var(--cream);
  box-shadow: var(--neo-press);
  transform: scale(0.98);
}

.cta-arrow {
  font-size: 16px;
  transition: transform var(--duration) var(--ease);
}

.contact-cta:hover .cta-arrow { transform: translate(3px, -3px); }

/* CTA button under vinyls — link to contact form */
.contact-cta-btn {
  display: inline-block;
  margin-top: 48px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--text);
  text-decoration: none;
  padding: 16px 36px;
  border: 1px solid var(--muted);
  border-radius: 100px;
  transition: all 0.3s ease;
  text-align: center;
}
.contact-cta-btn:hover {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.contact-domain {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

/* ---------- Contact Badges ---------- */
.badges-row {
  flex: 1;
  display: flex;
  gap: 44px;
  align-items: flex-start;
  justify-content: flex-end;
}

/* Wrapper — the whole cord+card unit swings */
.badge-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  transform-origin: top center;
  animation: badge-swing var(--swing-dur, 4.5s) ease-in-out var(--swing-delay, 0s) infinite;
  cursor: none;
  text-decoration: none;
}

.badge-wrap:hover {
  animation-play-state: paused;
}

/* Badge internal elements inherit inverted colors */
.badge .badge-brand,
.badge .badge-pass-type,
.badge .badge-meta span,
.badge .badge-role span,
.badge .badge-category,
.badge .badge-watermark {
  color: var(--bg);
}
.badge .badge-reg-dot {
  background: var(--bg);
}
.badge .badge-clip-hole {
  background: var(--bg);
}

/* ---- Flat black lanyard ---- */
.badge-cord {
  width: 12px;
  height: 70px;
  position: relative;
  flex-shrink: 0;
  background: #1a1a1a;
  border-radius: 1px;
}

/* Silver D-ring at top */
.badge-cord::before {
  content: '';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 14px;
  height: 16px;
  border-radius: 50% 50% 0 0 / 60% 60% 0 0;
  border: 3px solid #B8B4AE;
  background: transparent;
  box-shadow:
    0 1px 4px rgba(0,0,0,0.5),
    inset 0 1px 0 rgba(255,255,255,0.35);
}

/* Silver clip bottom */
.badge-cord::after {
  content: '';
  position: absolute;
  bottom: -9px;
  left: 50%;
  transform: translateX(-50%);
  width: 18px;
  height: 10px;
  border-radius: 2px;
  background: linear-gradient(180deg, #D8D4CE 0%, #A8A4A0 100%);
  box-shadow:
    0 1px 3px rgba(0,0,0,0.45),
    inset 0 1px 0 rgba(255,255,255,0.4);
}

/* ---- Badge card — ID PASS ---- */
/* Photo badge — the PNG IS the full badge with cord */
.badge-wrap--photo {
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.badge-photo-img {
  height: 310px;
  width: auto;
  filter: drop-shadow(0 8px 24px rgba(0,0,0,0.35));
  transition: transform 0.4s var(--ease), filter 0.4s var(--ease);
  pointer-events: auto;
}

.badge-wrap--photo:hover .badge-photo-img {
  transform: translateY(-10px) scale(1.04) rotate(1deg);
  filter: drop-shadow(0 16px 40px rgba(0,0,0,0.45));
}

/* Hide cord for photo badges */
.badge-wrap--photo .badge-cord {
  display: none;
}

.badge {
  width: 160px;
  min-height: 230px;
  background: var(--cream);
  color: var(--bg);
  border-radius: 9px;
  border: 1px solid var(--border);
  box-shadow:
    0 4px 16px rgba(0,0,0,0.35),
    0 16px 40px rgba(0,0,0,0.3),
    0 32px 64px rgba(0,0,0,0.2);
  display: flex;
  flex-direction: column;
  position: relative;
  text-decoration: none;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
  cursor: none;
  overflow: hidden;
}

/* Badge flip + zoom animation on click */
.badge-wrap.is-flipping {
  z-index: 999;
  pointer-events: none;
}

.badge-wrap.is-flipping .badge {
  animation: badgeFlipZoom 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.badge-wrap.is-flipping .badge-cord {
  animation: cordFade 0.3s ease forwards;
}

@keyframes badgeFlipZoom {
  0%   { transform: perspective(800px) rotateY(0deg) scale(1); opacity: 1; }
  25%  { transform: perspective(800px) rotateY(180deg) scale(1); opacity: 1; }
  45%  { transform: perspective(800px) rotateY(180deg) rotate(90deg) scale(1.3); opacity: 1; }
  70%  { transform: perspective(800px) rotateY(180deg) rotate(90deg) scale(4); opacity: 0.6; }
  100% { transform: perspective(800px) rotateY(180deg) rotate(90deg) scale(12); opacity: 0; }
}

@keyframes cordFade {
  to { opacity: 0; height: 0; }
}

.badge-wrap:hover .badge {
  transform: translateY(-10px) scale(1.04) rotate(1deg);
  box-shadow:
    0 8px 24px rgba(0,0,0,0.4),
    0 24px 56px rgba(0,0,0,0.38),
    0 48px 80px rgba(0,0,0,0.25);
}

/* ---- Clip hole ---- */
.badge-clip-hole {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg);
  box-shadow:
    inset 0 1px 3px rgba(0,0,0,0.25),
    0 0 0 1px var(--border);
  z-index: 3;
}

/* ---- Top row: FG© | barcode | ID PASS ---- */
.badge-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 10px 6px;
  border-bottom: 1.5px solid var(--bg);
  position: relative;
  z-index: 2;
}

.badge-brand,
.badge-pass-type {
  font-family: var(--font-body);
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bg);
}

.badge-barcode-strip {
  flex: 1;
  height: 18px;
  margin: 0 6px;
  background-image: repeating-linear-gradient(
    90deg,
    var(--bg) 0px, var(--bg) 2px,
    transparent 2px, transparent 4px,
    var(--bg) 4px, var(--bg) 5px,
    transparent 5px, transparent 8px,
    var(--bg) 8px, var(--bg) 11px,
    transparent 11px, transparent 13px,
    var(--bg) 13px, var(--bg) 14px,
    transparent 14px, transparent 17px
  );
}

/* ---- Badge body ---- */
.badge-body {
  display: flex;
  flex-direction: column;
  padding: 8px 12px 10px;
  flex: 1;
  position: relative;
  z-index: 2;
}

/* ---- Registration dots ---- */
.badge-dots-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4px;
}

.badge-dots-row--bottom {
  margin-top: auto;
  margin-bottom: 0;
  padding-top: 6px;
}

.badge-reg-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--bg);
  flex-shrink: 0;
}

/* ---- Meta line: year / location ---- */
.badge-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
}

.badge-meta span {
  font-family: var(--font-body);
  font-size: 7px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bg);
}

/* ---- Hero name — huge red ---- */
.badge-name-hero {
  font-family: var(--font-body);
  font-size: 54px;
  font-weight: 900;
  color: var(--accent);
  line-height: 0.85;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

/* ---- Role lines ---- */
.badge-role {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin-bottom: 4px;
}

.badge-role span {
  font-family: var(--font-body);
  font-size: 7.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bg);
}

/* ---- Category ---- */
.badge-category {
  font-family: var(--font-body);
  font-size: 6.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bg);
  margin-bottom: 4px;
}

/* ---- FG watermark — bleeds off bottom ---- */
.badge-watermark {
  position: absolute;
  bottom: -16px;
  left: -6px;
  font-family: var(--font-body);
  font-size: 88px;
  font-weight: 900;
  color: var(--bg);
  opacity: 0.07;
  line-height: 1;
  letter-spacing: -0.05em;
  pointer-events: none;
  z-index: 1;
  user-select: none;
}

/* ---- Swing animation ---- */
@keyframes badge-swing {
  0%, 100% { transform: rotate(calc(-1 * var(--swing-amp, 5deg))); }
  50%       { transform: rotate(var(--swing-amp, 5deg)); }
}

/* ---------- Vinyl Contact Cards ---------- */
.vinyl-row {
  flex: 1;
  display: flex;
  gap: 14px;
  align-items: flex-end;
  justify-content: flex-end;
  padding-top: 0;
  overflow: visible;
}

.vinyl-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
  max-width: 160px;
  display: block;
  text-decoration: none;
  cursor: none;
}

/* ---- Vinyl disc (CSS-only) ---- */
/* Vinyl disc — now a real PNG image */
img.vinyl-disc {
  position: absolute;
  top: 0;
  left: 50%;
  width: 96%;
  z-index: 0;
  transform: translateX(-50%) translateY(6%);
  transition: transform 0.65s cubic-bezier(0.34, 1.4, 0.64, 1);
  filter: drop-shadow(0 4px 20px rgba(0,0,0,0.5));
  pointer-events: none;
}

/* Disc slides up on hover */
.vinyl-wrap:hover img.vinyl-disc {
  transform: translateX(-50%) translateY(-52%) rotate(-9deg);
}

/* ---- Cover ---- */
.vinyl-cover {
  position: relative;
  z-index: 1;
  width: 100%;
  aspect-ratio: 1;
  background: var(--vc-bg, #F2EEE6);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px 16px 12px;
  box-shadow:
    0 2px 8px rgba(0,0,0,0.25),
    0 8px 24px rgba(0,0,0,0.2);
  transition: transform 0.4s var(--ease);
}

.vinyl-wrap:hover .vinyl-cover {
  transform: scale(1.03);
}

.vc-brand {
  font-family: var(--font-body);
  font-size: 7.5px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--vc-muted, rgba(10,10,8,0.4));
  flex-shrink: 0;
}

.vc-name {
  font-family: var(--font-body);
  font-size: 94px;
  font-weight: 900;
  line-height: 0.82;
  letter-spacing: -0.04em;
  color: var(--vc-text, #0A0A08);
  text-transform: uppercase;
  flex: 1;
  display: block;
  padding-top: 8px;
  overflow: visible;
}

.vc-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-shrink: 0;
}

.vc-series {
  font-family: var(--font-body);
  font-size: 7px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--vc-muted, rgba(10,10,8,0.4));
}

.vc-cta {
  font-family: var(--font-body);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--vc-text, #0A0A08);
  opacity: 0.7;
  text-transform: uppercase;
}

/* ---------- Overlay Progress Bar ---------- */
.overlay-progress {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--cream);
  z-index: 210;
  transition: width 0.1s linear;
  opacity: 0.6;
  pointer-events: none;
}

/* ---------- Project Intro (Synergy-style converging letters + photos) ---------- */
/* ---- Scroll-driven project intro ---- */
.project-intro {
  position: fixed;
  inset: 0;
  z-index: 250;
  display: none; /* shown by JS as flex */
  align-items: center;
  justify-content: center;
  overflow: hidden;
  will-change: opacity;
  touch-action: none; /* prevent browser swipe/scroll interference on mobile */
}

[data-theme="light"] .project-intro { background: #1C1C1A; color: #FFFCF2; }
[data-theme="dark"] .project-intro { background: #FFFCF2; color: #1C1C1A; }

.project-intro-sticky {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  isolation: isolate; /* create stacking context — reduces paint overhead */
}

/* Horizontal converging lines */
.project-intro-line {
  position: absolute;
  left: 10%;
  right: 10%;
  height: 1px;
  z-index: 0;
  will-change: transform, opacity;
}
[data-theme="light"] .project-intro-line { background: rgba(255,252,242,0.25); }
[data-theme="dark"] .project-intro-line  { background: rgba(28,28,26,0.25); }

/* Stage: holds letters + gap photo containers in a row */
.project-intro-stage {
  position: relative;
  width: 100%;
  height: 100%;
  z-index: 1;
  will-change: transform;
  contain: layout style paint; /* reduce paint overhead on all browsers */
}

/* Individual letter */
.pi-letter {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1;
  white-space: nowrap;
  will-change: transform, opacity;
  transform-origin: center center;
  flex-shrink: 0;
  position: relative;
  z-index: 2;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

[data-theme="light"] .pi-letter { color: #FFFCF2; }
[data-theme="dark"]  .pi-letter { color: #1C1C1A; }

/* Photo gap container between letters */
.pi-gap {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  contain: strict;
  flex-shrink: 0;
  transform-origin: center center;
  z-index: 1;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  pointer-events: none;
}

.pi-gap-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.15s ease;
  will-change: opacity;
  pointer-events: none; /* no hit testing on gap images */
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

.pi-gap-img.is-visible {
  opacity: 1;
}

/* Scroll hint */
.project-intro-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0;
  will-change: opacity;
  z-index: 3;
}
[data-theme="light"] .project-intro-hint { color: rgba(255,252,242,0.5); }
[data-theme="dark"]  .project-intro-hint { color: rgba(28,28,26,0.5); }

/* Intro hint mobile */
@media (max-width: 560px) {
  .project-intro-hint {
    bottom: 28px;
    font-size: 10px;
    letter-spacing: 0.12em;
  }
}

/* ---------- Project Overlay ---------- */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.92);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-overflow-scrolling: touch;
}

/* Inverted colors: same as intro for continuity */
[data-theme="light"] .overlay {
  background: #1C1C1A;
  color: #FFFCF2;
  --overlay-bg: #1C1C1A;
  --overlay-text: #FFFCF2;
  --overlay-muted: rgba(255,252,242,0.5);
  --overlay-border: rgba(255,252,242,0.12);
  --overlay-accent: #E8431A;
}

[data-theme="dark"] .overlay {
  background: #FFFCF2;
  color: #1C1C1A;
  --overlay-bg: #FFFCF2;
  --overlay-text: #1C1C1A;
  --overlay-muted: rgba(28,28,26,0.5);
  --overlay-border: rgba(28,28,26,0.12);
  --overlay-accent: #E8431A;
}

.overlay.is-open {
  opacity: 1;
  pointer-events: all;
  transform: scale(1);
}

/* Persistent project title bar at top of overlay */
.overlay-title-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 202;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(12px, 1.2vw, 16px);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  padding: 18px 48px;
  color: var(--overlay-text);
  background: var(--overlay-bg);
  border-bottom: 1px solid var(--overlay-border);
  opacity: 0;
  transition: opacity 0.4s ease;
}

/* Ambient gradient — disabled for clean minimal look */
.overlay-ambient {
  display: none;
}

.overlay-nav {
  position: fixed;
  top: 52px;
  left: 0;
  right: 0;
  z-index: 203;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 48px;
  pointer-events: none;
}

.overlay-back,
.overlay-close {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--overlay-muted);
  background: none;
  border: none;
  cursor: none;
  pointer-events: all;
  transition: color var(--duration), opacity var(--duration);
  padding: 0;
}

.overlay-back:hover,
.overlay-close:hover { color: var(--overlay-text); }

.overlay-back {
  opacity: 0;
  pointer-events: none;
}

.overlay-back.is-visible {
  opacity: 1;
  pointer-events: all;
}

.overlay-inner {
  padding: 80px 48px 100px;
  max-width: 1360px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* Overlay: hero block — clean minimal layout */
.overlay-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
  margin-bottom: 80px;
  padding-bottom: 80px;
  border-bottom: 1px solid var(--overlay-border);
}

.overlay-hero-left {
  position: sticky;
  top: 120px;
}

.overlay-logo {
  height: 100px;
  width: auto;
  margin-bottom: 32px;
  max-width: 240px;
  object-fit: contain;
}

/* Logo invert: reactive to theme changes via CSS classes
   Overlay/project-page bg is INVERTED: light theme = dark bg, dark theme = light bg
   --dark-source = logo is originally dark; needs invert on dark bg (light theme)
   --light-source = logo is originally light; needs invert on light bg (dark theme) */
[data-theme="light"] .overlay-logo--dark-source,
[data-theme="dark"] .overlay-logo--light-source {
  filter: invert(1) brightness(2);
}
[data-theme="light"] .overlay-logo--light-source,
[data-theme="dark"] .overlay-logo--dark-source {
  filter: none;
}

.overlay-note {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--overlay-muted);
  margin-bottom: 20px;
}

.overlay-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(56px, 7.5vw, 120px);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.025em;
  color: var(--overlay-text);
}

.overlay-title em { font-style: italic; }

.overlay-tagline {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(20px, 2.5vw, 36px);
  font-weight: 300;
  color: var(--overlay-muted);
  margin-bottom: 28px;
  line-height: 1.3;
}

.overlay-description {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--overlay-muted);
  line-height: 1.7;
  max-width: 550px;
}

.overlay-description + .overlay-description {
  margin-top: 16px;
}

/* Overlay: stats */
.overlay-stats {
  display: flex;
  gap: 20px;
  padding: 48px 0;
  border-bottom: 1px solid var(--overlay-border);
  margin-bottom: 64px;
  flex-wrap: wrap;
  overflow: visible;
}

.overlay-stat {
  display: flex;
  flex-direction: column;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--overlay-border);
  border-radius: 12px;
  padding: 28px 36px;
  min-width: 160px;
}

.overlay-stat strong {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(44px, 5.5vw, 80px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--overlay-text);
}

.overlay-stat span {
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--overlay-muted);
  margin-top: 10px;
}

/* Overlay: images */
.overlay-cover {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  margin-bottom: 16px;
  border-radius: 12px;
}

/* ---------- Folder Gallery ---------- */
.folder-gallery {
  margin-bottom: 64px;
}

/* ---- Document card ---- */
.folder-doc {
  width: 100%;
  background: rgba(128,128,128,0.15);
  border: 1px solid var(--overlay-border, rgba(255,255,255,0.12));
  border-radius: 12px;
  padding: 36px 44px 32px 64px;
  position: relative;
  cursor: pointer;
  box-shadow: 0 4px 24px rgba(0,0,0,0.15);
  user-select: none;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.folder-gallery.is-open .folder-doc {
  transform: translateY(-6px);
  box-shadow:
    0 8px 24px rgba(0,0,0,0.5),
    0 24px 60px rgba(0,0,0,0.4);
}

/* ---- Chrome clip ---- */
.folder-clip {
  position: absolute;
  left: -11px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 120px;
  background: linear-gradient(
    90deg,
    #484846 0%,
    #929090 10%,
    #d4d2ce 22%,
    #f0eeea 34%,
    #d0cecc 46%,
    #e8e6e0 58%,
    #bcbab6 72%,
    #8a8886 86%,
    #5e5e5c 100%
  );
  border-radius: 2px;
  box-shadow:
    3px 0 10px rgba(0,0,0,0.55),
    inset 1px 0 1px rgba(255,255,255,0.25);
}

.folder-clip::before,
.folder-clip::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 32%,
    rgba(255,255,255,0.6),
    rgba(160,156,152,0.95) 55%,
    rgba(70,68,64,0.9) 100%
  );
  box-shadow: 0 1px 4px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.25);
}

.folder-clip::before { top: 14px; }
.folder-clip::after  { bottom: 14px; }

/* ---- Doc body ---- */
.fdc-body {
  position: relative;
}

.fdc-toprow {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--bg);
  margin-bottom: 22px;
}

.fdc-logo {
  display: inline-block;
  border: 1.5px solid var(--bg);
  border-radius: 50%;
  padding: 4px 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--bg);
  margin-bottom: 14px;
}

.fdc-dept {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--bg);
  line-height: 1.7;
  margin-bottom: 22px;
}

.fdc-title {
  font-family: var(--font-mono);
  font-size: clamp(28px, 4.5vw, 52px);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bg);
  line-height: 1.0;
  margin-bottom: 20px;
}

.fdc-from {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  color: var(--bg);
  margin-bottom: 22px;
}

.fdc-note {
  font-family: var(--font-mono);
  font-size: 8px;
  line-height: 1.7;
  letter-spacing: 0.06em;
  color: var(--bg);
  max-width: 400px;
}

.fdc-note strong {
  display: block;
  font-weight: 700;
  margin-bottom: 3px;
}

.fdc-cta {
  display: inline-block;
  margin-top: 20px;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--bg);
  border-bottom: 1.5px solid var(--bg);
  padding-bottom: 1px;
  opacity: 0.6;
  transition: opacity 0.2s;
}

.folder-doc:hover .fdc-cta {
  opacity: 1;
}

.folder-gallery.is-open .fdc-cta {
  opacity: 0.4;
  text-decoration: line-through;
}

/* Small photo pinned top-right */
.fdc-preview {
  position: absolute;
  top: 0;
  right: 0;
  width: 110px;
  height: 120px;
  object-fit: cover;
  box-shadow:
    2px 3px 0 rgba(0,0,0,0.08),
    3px 5px 12px rgba(0,0,0,0.28);
  filter: contrast(1.05);
}

/* Red stamp bottom-right */
.fdc-stamp {
  position: absolute;
  right: 8px;
  bottom: 52px;
  border: 2px solid var(--accent);
  padding: 6px 10px;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.6;
  color: var(--accent);
  transform: rotate(-5deg);
  opacity: 0.85;
}

.fdc-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 44px;
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ---- Photo grid (clean, no background) ---- */
.folder-sheet {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.75s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
}

.folder-gallery.is-open .folder-sheet {
  max-height: 5000px;
  opacity: 1;
}

.sheet-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding-top: 12px;
}

.sheet-photo {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.45s ease, transform 0.45s ease;
  transition-delay: 0s;
}

.folder-gallery.is-open .sheet-photo {
  opacity: 1;
  transform: translateY(0);
  transition-delay: var(--d, 0s);
}

.sheet-photo img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  display: block;
}

.sheet-photo--full img {
  aspect-ratio: unset;
  object-fit: contain;
  height: auto;
}

/* Overlay: gadget section */
.overlay-gadget {
  margin-top: 80px;
  padding-top: 64px;
  border-top: 1px solid var(--border);
}

.overlay-gadget-section {
  margin-top: 80px;
  padding-top: 64px;
  border-top: 1px solid var(--border);
}

.overlay-gadget-section .folder-gallery {
  margin-top: 0;
}

/* ---------- Social & Platforms section ---------- */
.overlay-social {
  margin-top: 80px;
  padding-top: 64px;
  border-top: 1px solid var(--border);
  margin-bottom: 80px;
}

.social-mockup-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  margin-top: 32px;
}

.social-mockup-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.social-mockup-label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg);
  font-weight: 500;
}

.social-mockup-note {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ======= iPhone Mockup — PNG images with sway ======= */
.social-mockup-item {
  perspective: 800px;
}

.iphone-mockup {
  width: 100%;
  max-width: 700px;
  animation: iphoneSway 6s ease-in-out infinite;
  will-change: transform;
}

.iphone-mockup img {
  width: 100%;
  height: auto;
  display: block;
}

/* Clickable social mockups — hover zoom */
a.social-mockup-link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
a.social-mockup-link .iphone-mockup {
  transition: transform 0.4s cubic-bezier(0.16,1,0.3,1);
}
a.social-mockup-link:hover .iphone-mockup {
  animation: none !important;
  transform: scale(1.12) rotateY(0deg) rotateX(0deg) !important;
}
a.social-mockup-link:hover .social-mockup-label {
  opacity: 1;
}
/* Also scale non-linked mockups on hover */
.social-mockup-item:hover .iphone-mockup {
  animation: none !important;
  transform: scale(1.08) !important;
  transition: transform 0.4s cubic-bezier(0.16,1,0.3,1);
}

@keyframes iphoneSway {
  0%   { transform: rotateY(-8deg) rotateX(2deg); }
  50%  { transform: rotateY(8deg)  rotateX(-2deg); }
  100% { transform: rotateY(-8deg) rotateX(2deg); }
}

@media (max-width: 960px) {
  .social-mockup-grid { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .iphone-mockup { max-width: 500px; }
}

@media (max-width: 560px) {
  .social-mockup-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .iphone-mockup { max-width: 100%; }
}

/* Coming-soon edition: not clickable, dimmed CTA */
.folder-gallery--soon {
  pointer-events: none;
  opacity: 0.72;
}
.folder-gallery--soon .fdc-cta--soon {
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--cream);
  opacity: 0.5;
  text-decoration: none;
  pointer-events: none;
}

.overlay-gadget-header { max-width: 640px; }

.overlay-gadget-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
  margin-bottom: 64px;
}

.overlay-gadget-item {
  position: relative;
  overflow: hidden;
}

.overlay-gadget-item img {
  width: 100%;
  display: block;
  object-fit: contain;
  transition: transform 0.8s var(--ease);
}

.overlay-gadget-item img:hover { transform: scale(1.03); }

.overlay-gadget-item span {
  display: block;
  margin-top: 10px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Overlay: services (artists lineup) */
.overlay-services {
  margin-bottom: 40px;
}

/* Scope of Work — stat card style */
.services-folder-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--bg-raise);
  border-radius: var(--radius);
  padding: 28px 36px;
  box-shadow: var(--neo-raise);
  min-width: 160px;
  cursor: none;
  transition: box-shadow 0.3s var(--ease);
}

.services-folder-wrap:hover,
.services-folder-wrap.is-open {
  box-shadow: var(--neo-raise-lg);
}

.services-folder-wrap strong {
  font-family: var(--font-display);
  font-size: clamp(44px, 5.5vw, 80px);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.02em;
}

.services-folder-wrap > span:not(.folder-open-hint) {
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 10px;
}

.folder-open-hint {
  font-size: 9px;
  letter-spacing: 0.15em;
  color: var(--muted);
  margin-top: 6px;
  opacity: 0.5;
  transition: opacity 0.2s;
}

.services-folder-wrap:hover .folder-open-hint,
.services-folder-wrap.is-open .folder-open-hint {
  opacity: 1;
}

/* Skills vertical list — opens on click */
.services-popover {
  position: absolute;
  bottom: calc(100% + 14px);
  left: 0;
  min-width: 220px;
  background: var(--bg-raise);
  border-radius: var(--radius);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  box-shadow: var(--neo-raise-lg), 0 0 0 1px var(--border);
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.35s var(--ease);
  z-index: 10;
}

.services-popover::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 30px;
  border: 7px solid transparent;
  border-top-color: var(--bg-raise);
}

.services-folder-wrap.is-open .services-popover {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.service-tag {
  font-size: 11px;
  letter-spacing: 0.07em;
  padding: 9px 16px;
  border-radius: 8px;
  background: transparent;
  border: 1px solid var(--overlay-border, var(--border));
  color: var(--overlay-muted, var(--muted));
  cursor: none;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  display: block;
  white-space: nowrap;
}

.service-tag:hover {
  color: var(--overlay-text, var(--cream));
  border-color: var(--overlay-muted, rgba(245,237,214,0.3));
  background: rgba(128,128,128,0.08);
}

/* Lineup list (Decibel artists) stays as flat list */
.overlay-services-title {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--overlay-muted, var(--muted));
  margin-bottom: 24px;
}

.overlay-services-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.overlay-services-list span {
  font-size: 11px;
  letter-spacing: 0.06em;
  padding: 8px 18px;
  border-radius: 20px;
  background: rgba(128,128,128,0.08);
  border: 1px solid var(--overlay-border, var(--border));
  color: var(--overlay-muted, var(--muted));
  cursor: default;
}

/* ---------- Footer ---------- */
.footer {
  padding: 40px 48px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}

.footer-logo {
  position: absolute;
  left: 48px;
  height: 52px;
  width: auto;
  filter: invert(1) sepia(1) saturate(0) brightness(10);
  opacity: 0.35;
}

.footer-center {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.06em;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.footer-legal {
  font-size: 9px;
  color: var(--muted);
  letter-spacing: 0.1em;
}
.footer-links {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer-links a {
  font-size: 9px;
  color: var(--muted);
  text-decoration: underline;
  opacity: 0.7;
  transition: opacity 0.2s;
  letter-spacing: 0.05em;
}
.footer-links a:hover { opacity: 1; }
.footer-sep { font-size: 8px; color: var(--muted); opacity: 0.4; }
.footer-credit { font-size: 9px; color: var(--muted); opacity: 0.5; letter-spacing: 0.05em; }

.footer-top {
  position: absolute;
  right: 48px;
  background: none;
  border: 1px solid var(--border);
  color: var(--muted);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.25s, color 0.25s, transform 0.25s;
}

.footer-top:hover {
  border-color: var(--cream);
  color: var(--cream);
  transform: translateY(-3px);
}

/* ---------- Card hover preview ---------- */
.card-folder {
  position: relative;
}

.card-hover-tag {
  position: absolute;
  top: 58px;
  left: 16px;
  right: 16px;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--cream);
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
  text-align: center;
}

.project-card:hover .card-hover-tag {
  opacity: 0.7;
  transform: translateY(0);
}


/* ---------- Scroll reveal (initial hidden state) ---------- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ========================
   Vinyl Player (Hero) — yejis.world style
   ======================== */
.hero-vinyl-wrap {
  position: absolute;
  right: 80px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  z-index: 1;
}

.hero-vinyl-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--muted);
  text-transform: uppercase;
  pointer-events: none;
  text-align: center;
}

.hero-vinyl-moods {
  display: flex;
  gap: 6px;
}

.hero-vinyl-mood {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid var(--border);
  background: none;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 20px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  white-space: nowrap;
}

.hero-vinyl-mood.active {
  border-color: var(--cream);
  color: var(--cream);
  background: rgba(255,252,242,0.08);
}

.hero-vinyl-mood:hover:not(.active) {
  border-color: var(--muted);
  color: var(--cream);
}

/* Track name — between moods and disc */
.hero-vinyl-track-name {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--muted);
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 260px;
  transition: color 0.3s;
}

/* Disc — full circle with cover art like yejis.world */
.hero-vinyl-disc-wrap {
  position: relative;
  width: 220px;
  height: 220px;
}

.hero-vinyl-disc {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

.hero-vinyl-disc.is-spinning {
  animation: hero-vinyl-spin 3s linear infinite;
}

@keyframes hero-vinyl-spin {
  to { transform: rotate(360deg); }
}

/* Full-disc cover art — gradient default, replaced by SC artwork */
.hero-vinyl-cover {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, #1a1a2e 0%, #E5383B 100%);
  background-size: cover;
  background-position: center;
  transition: background 0.5s ease;
}

.hero-vinyl-cover[data-mood="hiphop"] {
  background: linear-gradient(135deg, #1a1a2e 0%, #E5383B 60%, #1a1a2e 100%);
}
.hero-vinyl-cover[data-mood="afro"] {
  background: linear-gradient(135deg, #ff6b35 0%, #f7c948 60%, #252422 100%);
}
.hero-vinyl-cover[data-mood="tech"] {
  background: linear-gradient(135deg, #0f3443 0%, #34e89e 60%, #252422 100%);
}
.hero-vinyl-cover[data-mood="hard"] {
  background: linear-gradient(135deg, #252422 0%, #E5383B 50%, #000 100%);
}

/* Center hole */
.hero-vinyl-hole {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid rgba(255,255,255,0.08);
  z-index: 1;
}

/* Controls row — prev / play / next */
.hero-vinyl-controls {
  position: absolute;
  bottom: -24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 2;
}

.hero-vinyl-play {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--muted);
  background: var(--bg);
  color: var(--muted);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 0 0 2px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, box-shadow 0.2s;
}

.hero-vinyl-play:hover {
  border-color: var(--cream);
  color: var(--cream);
}

.hero-vinyl-play.is-playing {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 14px rgba(229,56,59,0.4);
}

.hero-vinyl-skip {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--muted);
  font-size: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}

.hero-vinyl-skip:hover {
  border-color: var(--cream);
  color: var(--cream);
}

/* Vinyl mobile — reposition below hero text on small screens */
@media (max-width: 760px) {
  .hero {
    min-height: calc(100svh - 60px); /* leave room for marquee bar (~60px) */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding-top: calc(var(--nav-h) + 16px);
    padding-bottom: 16px;
    gap: 16px;
  }
  .hero-content {
    max-width: 100%;
    text-align: center;
  }
  /* Hide "Scroll Down" on mobile */
  .hero-bottom {
    display: none;
  }
  .hero-vinyl-wrap {
    position: relative;
    right: auto;
    top: auto;
    transform: none;
    margin-top: 0;
    align-items: center;
    width: 100%;
  }
  .hero-vinyl-moods {
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
  }
  .hero-vinyl-mood {
    font-size: 9px;
    padding: 5px 10px;
  }
  .hero-vinyl-disc-wrap {
    width: 170px;
    height: 170px;
    margin-bottom: 20px;
  }
  .hero-vinyl-track-name {
    font-size: 9px;
    max-width: 220px;
  }
  .hero-vinyl-play {
    width: 34px;
    height: 34px;
    font-size: 11px;
  }
  .hero-vinyl-skip {
    width: 22px;
    height: 22px;
    font-size: 8px;
  }
  .hero-vinyl-controls {
    bottom: -16px;
  }

  /* Marquee compatta su mobile — entrambe le righe visibili */
  .services-marquee {
    padding: 14px 0;
  }
  .marquee-track span {
    font-size: 13px;
    padding: 0 8px;
  }
  .marquee-sep {
    font-size: 9px !important;
  }
}

/* ---- Language Toggle ---- */
.lang-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 5px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: border-color 0.2s;
  margin-left: 8px;
}

.lang-toggle:hover {
  border-color: var(--muted);
}

.lang-opt {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--muted);
  transition: color 0.2s;
}

.lang-opt.active {
  color: var(--cream);
}

.lang-sep {
  font-size: 10px;
  color: var(--muted);
}

/* ---------- Project Page (full-page mode) ---------- */
.project-page {
  min-height: 100vh;
  padding-top: 80px;
}

/* Project page colors — INVERTED from homepage (badge color = page bg) */
/* Light mode homepage (dark badges) → dark project page */
[data-theme="light"] .project-page {
  background: #1C1C1A;
  color: #FFFCF2;
  --overlay-bg: #1C1C1A;
  --overlay-text: #FFFCF2;
  --overlay-muted: rgba(255,252,242,0.5);
  --overlay-border: rgba(255,252,242,0.12);
  --overlay-accent: #E8431A;
  --fg: #FFFCF2;
  --bg: #1C1C1A;
  --muted: rgba(255,252,242,0.5);
}
/* Dark mode homepage (light badges) → light project page */
[data-theme="dark"] .project-page {
  background: #FFFCF2;
  color: #1C1C1A;
  --overlay-bg: #FFFCF2;
  --overlay-text: #1C1C1A;
  --overlay-muted: rgba(28,28,26,0.5);
  --overlay-border: rgba(28,28,26,0.12);
  --overlay-accent: #E8431A;
  --fg: #1C1C1A;
  --bg: #FFFCF2;
  --muted: rgba(28,28,26,0.5);
}

.project-page .overlay-inner {
  position: relative;
  max-width: 1320px;
  margin: 0 auto;
  padding: 48px 24px 96px;
}

/* Performance: defer rendering of off-screen project sections */
.project-page .folder-gallery,
.project-page .overlay-social,
.project-page .overlay-gadget-section {
  content-visibility: auto;
  contain-intrinsic-size: auto 600px;
}

/* ========== New Project Layout — Clean page, no card ========== */

.proj-header {
  max-width: 1100px;
  margin: 0 auto 32px;
  padding: 48px 56px 0;
}
[data-theme="light"] .project-page .overlay-title-bar { color: #FFFCF2; }
[data-theme="dark"] .project-page .overlay-title-bar { color: #1C1C1A; }

/* ---------- Project Prev/Next Navigation ---------- */
.project-prevnext {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  max-width: 1100px;
  margin: 64px auto 80px;
  padding: 0 48px;
  gap: 24px;
}

.project-nav-link {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  text-decoration: none;
  color: inherit;
  padding: 24px 32px;
  border-radius: 16px;
  border: 1px solid currentColor;
  border-color: rgba(128,128,128,0.15);
  transition: all 0.4s cubic-bezier(0.16,1,0.3,1);
  flex: 1;
  max-width: 48%;
  position: relative;
  overflow: hidden;
}
.project-nav-next { align-items: flex-end; text-align: right; }

.project-nav-link:hover {
  border-color: rgba(128,128,128,0.3);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}

.project-nav-direction {
  font-family: 'Inconsolata', monospace;
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0.35;
}

.project-nav-arrow {
  font-size: 18px;
  font-weight: 300;
  opacity: 0.5;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.project-nav-prev:hover .project-nav-arrow { transform: translateX(-4px); opacity: 1; }
.project-nav-next:hover .project-nav-arrow { transform: translateX(4px); opacity: 1; }

.project-nav-label {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0;
  line-height: 1.2;
}

@media (max-width: 560px) {
  .project-prevnext { padding: 0 16px; margin: 32px auto 48px; }
  .project-nav-link { padding: 12px 20px; gap: 8px; }
  .project-nav-label { font-size: 12px; }
}

/* Extra section outside the card */
.proj-extra {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

/* ---- Logo Square (enlarged with subtle glow) ---- */
.proj-logo-square {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: #1C1C1A;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 32px;
  overflow: hidden;
  flex-shrink: 0;
}
[data-theme="dark"] .proj-logo-square {
  background: #FFFCF2;
}
.proj-logo-square img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}
/* Override overlay-logo sizing inside the square */
.proj-logo-square .overlay-logo {
  height: 36px;
  width: 36px;
  max-width: 36px;
  margin-bottom: 0;
}

/* ---- Note ---- */
.proj-note {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.5;
  margin-bottom: 8px;
}

/* ---- Title + Description Row ---- */
.proj-info-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  margin-bottom: 32px;
}
.proj-info-left {
  flex: 0 0 55%;
}
.proj-info-right {
  flex: 0 0 40%;
}

.proj-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin: 0 0 8px;
}
.proj-title em { font-style: italic; }

.proj-subtitle {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px;
  font-weight: 300;
  font-style: italic;
  opacity: 0.5;
  line-height: 1.3;
}

/* Project external link */
.proj-link {
  display: inline-block;
  margin-top: 12px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: none;
  opacity: 0.8;
  transition: opacity 0.3s;
}
.proj-link:hover {
  opacity: 1;
}

/* Decorative line between title area and description */
.proj-info-divider {
  width: 1px;
  align-self: stretch;
  background: currentColor;
  opacity: 0.12;
  flex-shrink: 0;
}

.proj-desc {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  line-height: 1.7;
  opacity: 0.7;
  margin: 0;
}
.proj-desc + .proj-desc {
  margin-top: 14px;
}

/* ---- Blob Section ---- */
.proj-blob-section {
  position: relative;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 24px;
}
.proj-blob-wrap {
  flex: 1;
  position: relative;
  min-width: 0;
}

.proj-blob-mask {
  width: 100%;
  height: clamp(200px, 25vw, 300px);
  background: #1C1C1A;
  border-radius: 40% 60% 55% 45% / 50% 40% 60% 50%;
  overflow: hidden;
  position: relative;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}
[data-theme="dark"] .proj-blob-mask {
  background: #111;
}

.proj-blob-track {
  display: flex;
  height: 100%;
  -webkit-animation: blobScroll var(--blob-duration, 20s) linear infinite;
  animation: blobScroll var(--blob-duration, 20s) linear infinite;
  will-change: transform;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

@-webkit-keyframes blobScroll {
  0%   { -webkit-transform: translateX(0); transform: translateX(0); }
  100% { -webkit-transform: translateX(var(--blob-scroll-distance, -50%)); transform: translateX(var(--blob-scroll-distance, -50%)); }
}
@keyframes blobScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(var(--blob-scroll-distance, -50%)); }
}

.proj-blob-slide {
  flex: 0 0 auto;
  height: 100%;
  min-width: 340px;
}

.proj-blob-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  -webkit-user-drag: none;
  user-select: none;
}

/* ---- Stat to the right of blob ---- */
.proj-stat-side {
  flex-shrink: 0;
  text-align: left;
  min-width: 80px;
}

/* ---- Stats row — dramatic counter style ---- */
.proj-stats-row {
  display: flex;
  justify-content: center;
  gap: 56px;
  padding: 40px 0 8px;
}
.proj-stat-item {
  text-align: center;
  position: relative;
}
.proj-stat-item + .proj-stat-item::before {
  content: '';
  position: absolute;
  left: -28px;
  top: 15%;
  height: 70%;
  width: 1px;
  background: currentColor;
  opacity: 0.1;
}

/* Shared stat styles */
.proj-stat-value {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  overflow: hidden;
}
.proj-stat-label {
  font-family: 'Cormorant Garamond', serif;
  font-size: 13px;
  font-style: italic;
  letter-spacing: 0.06em;
  opacity: 0.45;
  margin-top: 8px;
  white-space: nowrap;
}

/* ---- Section Divider ---- */
.proj-section-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 1100px;
  margin: 48px auto 32px;
  padding: 0 48px;
}
.proj-section-divider::before,
.proj-section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: currentColor;
  opacity: 0.08;
}
.proj-section-num {
  font-family: 'Inconsolata', monospace;
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.35;
  white-space: nowrap;
}

/* ---- Photo Ticker Rows (abhijitrout-style) ---- */
.photo-ticker-section {
  max-width: 100%;
  overflow: hidden;
  padding: 32px 0 16px;
}

.photo-ticker-row {
  overflow: hidden;
  white-space: nowrap;
  margin-bottom: 12px;
}

.photo-ticker-track {
  display: inline-flex;
  gap: 12px;
  will-change: transform;
}

/* Left scroll */
.photo-ticker-row--left .photo-ticker-track {
  animation: tickerLeft var(--ticker-speed, 30s) linear infinite;
}
/* Right scroll */
.photo-ticker-row--right .photo-ticker-track {
  animation: tickerRight var(--ticker-speed, 35s) linear infinite;
}

@keyframes tickerLeft {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-33.333%); }
}
@keyframes tickerRight {
  0%   { transform: translateX(-33.333%); }
  100% { transform: translateX(0); }
}

.ticker-fig {
  flex: 0 0 auto;
  width: clamp(180px, 20vw, 240px);
  height: clamp(180px, 20vw, 240px);
  border-radius: 0;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.ticker-fig:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}
.ticker-fig img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
}

.photo-ticker-hint {
  text-align: center;
  margin-top: 8px;
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0.4;
}

/* ---- Lightbox ---- */
.photo-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  cursor: zoom-out;
}
.photo-lightbox.is-open {
  opacity: 1;
  pointer-events: all;
}
.photo-lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 12px 60px rgba(0,0,0,0.5);
  transform: scale(0.9);
  transition: transform 0.3s cubic-bezier(0.16,1,0.3,1);
}
.photo-lightbox.is-open img {
  transform: scale(1);
}

/* Ticker keeps scrolling on hover — click to view full image */

/* ---- Services Tags (outside card) ---- */
/* --- Services Typewriter --- */
.proj-services-typewriter {
  margin: 48px 0 56px;
  text-align: center;
}

.proj-services-phrase {
  font-family: var(--font-heading);
  font-size: clamp(20px, 3vw, 36px);
  font-weight: 400;
  color: var(--fg);
  line-height: 1.4;
}

.proj-services-phrase strong {
  font-weight: 700;
  color: var(--accent, #E8431A);
}

.typewriter-cursor {
  font-weight: 300;
  color: var(--accent, #E8431A);
  animation: cursorBlink 0.7s step-end infinite;
}

@keyframes cursorBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.proj-services-showall {
  margin-top: 20px;
  background: none;
  border: 1px solid var(--muted);
  color: var(--fg);
  padding: 10px 24px;
  border-radius: 60px;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s, color 0.3s;
}

.proj-services-showall:hover {
  background: var(--fg);
  color: var(--bg);
}

.proj-services-all {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}

.proj-service-pill {
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 8px 20px;
  border: 1px solid var(--muted);
  border-radius: 60px;
  color: var(--fg);
}

/* ========== End New Project Layout ========== */

/* Project page nav */
.project-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 48px;
}

.project-nav-back {
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
  opacity: 0.6;
  transition: opacity 0.3s;
}
.project-nav-back:hover { opacity: 1; }

/* Nav colors + background — inverted to match project page */
[data-theme="light"] .project-nav {
  background: #1C1C1A;
  color: #FFFCF2;
}
[data-theme="light"] .project-nav-back { color: #FFFCF2; }
[data-theme="light"] .project-nav .lang-toggle,
[data-theme="light"] .project-nav .theme-toggle { color: #FFFCF2; border-color: rgba(255,252,242,0.3); }
[data-theme="light"] .project-nav .lang-opt { color: rgba(255,252,242,0.5); }
[data-theme="light"] .project-nav .lang-opt.active { color: #FFFCF2; }
[data-theme="light"] .project-nav .lang-sep { color: rgba(255,252,242,0.3); }

[data-theme="dark"] .project-nav {
  background: #FFFCF2;
  color: #1C1C1A;
}
[data-theme="dark"] .project-nav-back { color: #1C1C1A; }
[data-theme="dark"] .project-nav .lang-toggle,
[data-theme="dark"] .project-nav .theme-toggle { color: #1C1C1A; border-color: rgba(28,28,26,0.3); }
[data-theme="dark"] .project-nav .lang-opt { color: rgba(28,28,26,0.5); }
[data-theme="dark"] .project-nav .lang-opt.active { color: #1C1C1A; }
[data-theme="dark"] .project-nav .lang-sep { color: rgba(28,28,26,0.3); }

/* Title bar at top */
.project-title-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 24px;
  z-index: 99;
  pointer-events: none;
}

/* Project page progress bar */
#project-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--accent);
  z-index: 200;
  transition: width 0.1s linear;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .nav { padding: 0 24px; }
  /* Nav: links assoluti → flow normale per tablet */
  .nav-links {
    position: static;
    transform: none;
    gap: 28px;
  }

  .hero { padding: 0 24px; }
  .hero-bottom { margin-top: 24px; }

  /* Hero logo + testo: ridotto su tablet */
  .hero-logo-big {
    height: clamp(100px, 30vh, 220px);
    top: 60px;
    left: 24px;
  }
  .hero-text {
    font-size: clamp(56px, 9vw, 120px);
  }

  /* Vinyl contact: stack verticale */
  .contact {
    flex-direction: column;
    padding: 80px 24px 100px;
    gap: 48px;
  }
  .vinyl-row {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    padding-top: 100px;
    gap: 16px;
    width: 100%;
  }
  .vinyl-wrap {
    flex: 0 0 calc(50% - 8px);
    max-width: 240px;
  }

  /* Work grid su tablet */
  .work-grid {
    padding: 40px 24px 80px;
    gap: 20px;
  }

  .section-header { padding: 0 24px 32px; }

  .project-inner { padding: 32px 24px; min-height: 110px; }
  .project-item:hover .project-inner { padding: 48px 24px; }
  .project-right { display: none; }
  .project-left { gap: 16px; }

  .about {
    grid-template-columns: 1fr;
    padding: 80px 24px;
    gap: 40px;
  }
  .about-image-wrap { position: static; aspect-ratio: 4/3; }
  .about-skills { grid-template-columns: repeat(2, 1fr); }

  .contact {
    padding: 80px 0 100px;
    gap: 60px;
    flex-direction: column;
    overflow: visible;
  }
  .contact-title {
    padding: 0 24px;
  }
  .badges-row {
    flex-direction: row;
    justify-content: center;
    gap: 24px;
    overflow: visible;
    padding-bottom: 40px;
    width: 100%;
  }
  .badge-wrap {
    margin-top: 0 !important;
    flex-shrink: 0;
  }
  .badge {
    width: 118px;
    min-height: 170px;
  }
  .badge-cord {
    height: 56px;
  }
  .badge-name-hero {
    font-size: 32px !important;
    line-height: 1;
  }
  .badge-role span,
  .badge-category,
  .badge-meta span {
    font-size: 6px;
  }
  .badge-brand {
    font-size: 9px;
  }

  .overlay-inner { padding: 100px 24px 80px; }
  .overlay-nav { padding: 24px 24px; }
  .overlay-hero { grid-template-columns: 1fr; gap: 40px; }
  .overlay-stats {
    flex-direction: row;
    flex-wrap: wrap;
    overflow: visible;
    gap: 12px;
    padding: 28px 0;
  }
  .overlay-stat,
  .services-folder-wrap {
    padding: 18px 20px;
    min-width: calc(50% - 6px);
    flex: 1;
    box-sizing: border-box;
  }
  .overlay-stat strong,
  .services-folder-wrap strong {
    font-size: 36px;
  }
  .overlay-stat span,
  .services-folder-wrap > span:not(.folder-open-hint) {
    font-size: 8px;
  }
  .services-popover {
    bottom: auto;
    top: calc(100% + 8px);
  }
  .services-popover::after {
    top: auto;
    bottom: 100%;
    border-top-color: transparent;
    border-bottom-color: var(--bg-raise);
  }
  .sheet-grid { grid-template-columns: 1fr 1fr; }
  .fdc-title { font-size: 28px; }

  .overlay-social { margin-top: 48px; padding-top: 48px; margin-bottom: 48px; }
  .social-mockup-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }

  .footer {
    padding: 32px 24px;
    text-align: center;
  }
  .footer-logo {
    position: static;
    display: none;
  }
}

@media (max-width: 560px) {
  .about-skills { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .skill-group { gap: 6px; }
  .skill-group span:not(.skill-label) { font-size: 11px; }
  .sheet-grid { grid-template-columns: 1fr 1fr; }
  .fdc-preview { width: 80px; height: 90px; }
  .footer-top { right: 24px; }

  /* Nav mobile: nascondi links, mostra hamburger */
  .nav-links { display: none; }
  .nav-right { gap: 8px; }
  .hamburger { display: flex; }

  /* Hero mobile */
  .hero { padding: 0 20px; padding-top: calc(var(--nav-h) + 12px); padding-bottom: 12px; gap: 12px; }
  .hero-content { max-width: 100%; }
  .hero-heading { font-size: 26px; line-height: 1.15; }
  .hero-bottom { display: none; } /* hidden on mobile */
  .hero-vinyl-wrap { margin-top: 0; }
  .hero-vinyl-disc-wrap { width: 160px; height: 160px; }
  .hero-vinyl-label { font-size: 8px; letter-spacing: 0.15em; }
  .hero-vinyl-mood { font-size: 8px; padding: 4px 8px; }
  .hero-vinyl-track-name { font-size: 8px; max-width: 200px; }
  .hero-vinyl-play { width: 32px; height: 32px; font-size: 10px; }
  .hero-vinyl-skip { width: 22px; height: 22px; font-size: 7px; }
  .hero-vinyl-controls { bottom: -20px; gap: 8px; }
  .hero-logo-big {
    height: clamp(80px, 22vh, 160px);
    top: 56px;
    left: 20px;
  }
  .hero-text {
    font-size: clamp(44px, 12vw, 80px);
  }
  .hero-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
  .hero-divider { display: none; }

  /* Vinyl mobile: 3 in a row, smaller */
  .vinyl-row {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: flex-end;
    justify-content: center;
    padding-top: 32px;
    gap: 8px;
  }
  .vinyl-wrap {
    flex: 1 1 0;
    min-width: 0;
    max-width: 110px;
  }
  .vinyl-cover {
    padding: 8px 10px 8px;
  }
  .vc-brand {
    font-size: 5.5px;
  }
  .vc-name {
    font-size: 18px !important;
    line-height: 0.85;
  }
  .vc-footer {
    gap: 2px;
  }
  .vc-series {
    font-size: 5px;
  }
  .vc-cta {
    font-size: 6px;
  }

  /* Contact title mobile — same size as vinyl covers */
  .contact-title {
    font-size: clamp(20px, 6vw, 28px);
    line-height: 1;
    text-align: center;
    padding: 0 20px;
  }
  .contact {
    align-items: center;
  }

  /* Section header mobile */
  .section-header { padding: 0 20px 28px; }
  .section-title { font-size: clamp(36px, 9vw, 60px); }

  /* Work grid mobile — horizontal scroll */
  .work-grid {
    padding: 32px 16px 64px;
    gap: 16px;
    justify-content: flex-start;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    scroll-padding: 16px;
  }
  .work-grid::-webkit-scrollbar { display: none; }
  .work-grid { -ms-overflow-style: none; scrollbar-width: none; }
  .badge-wrap {
    scroll-snap-align: center;
  }
}

/* ---------- Project Page — Tablet (max 960px) ---------- */
@media (max-width: 960px) {
  .project-nav { padding: 16px 24px; }
  .project-title-bar { font-size: 10px; padding: 18px 24px; }
  .project-page { padding-top: 64px; }
  .project-page .overlay-inner { padding: 32px 24px 80px; }

  /* New layout — tablet */
  .proj-card {
    padding: 32px 24px;
    border-radius: 20px;
    margin: 0 16px 36px;
  }
  .proj-extra {
    padding: 0 24px;
  }
  .proj-info-row {
    flex-direction: column;
    gap: 24px;
  }
  .proj-info-left,
  .proj-info-right {
    flex: none;
    width: 100%;
  }
  .proj-blob-section {
    flex-direction: column;
    gap: 20px;
  }
  .proj-stat-side {
    text-align: center;
  }
  .proj-stats-row {
    gap: 32px;
    justify-content: center;
  }
}

/* ---------- Project Page — Mobile (max 560px) ---------- */
@media (max-width: 560px) {
  /* Nav */
  .project-nav {
    padding: 12px 16px;
    gap: 8px;
  }
  .project-nav-back {
    font-size: 10px;
    letter-spacing: 0.1em;
  }
  .project-nav .nav-right { gap: 6px; }
  .project-nav .lang-toggle {
    padding: 4px 10px;
    margin-left: 4px;
  }
  .project-nav .lang-opt { font-size: 9px; }

  /* Title bar */
  .project-title-bar {
    font-size: 9px;
    letter-spacing: 0.15em;
    padding: 14px 16px;
  }

  /* Page layout */
  .project-page { padding-top: 52px; }
  .project-page .overlay-inner {
    padding: 20px 16px 64px;
    max-width: 100%;
  }

  /* Hero section */
  .project-page .overlay-hero {
    grid-template-columns: 1fr;
    gap: 28px;
    margin-bottom: 48px;
    padding-bottom: 48px;
  }
  .project-page .overlay-logo {
    height: 64px;
    max-width: 180px;
    margin-bottom: 20px;
  }
  .project-page .overlay-note {
    font-size: 9px;
    letter-spacing: 0.14em;
    margin-bottom: 14px;
  }
  .project-page .overlay-title {
    font-size: clamp(40px, 11vw, 64px);
    line-height: 0.95;
  }
  .project-page .overlay-tagline {
    font-size: clamp(16px, 4.5vw, 22px);
    margin-bottom: 20px;
  }
  .project-page .overlay-description {
    font-size: 14px;
    line-height: 1.8;
    max-width: 100%;
  }

  /* Stats */
  .project-page .overlay-stats {
    gap: 10px;
    padding: 28px 0;
    margin-bottom: 40px;
  }
  .project-page .overlay-stat,
  .project-page .services-folder-wrap {
    padding: 16px 16px;
    min-width: calc(50% - 5px);
    flex: 1;
  }
  .project-page .overlay-stat strong,
  .project-page .services-folder-wrap strong {
    font-size: clamp(28px, 8vw, 40px);
  }
  .project-page .overlay-stat span,
  .project-page .services-folder-wrap > span:not(.folder-open-hint) {
    font-size: 7px;
    letter-spacing: 0.15em;
    margin-top: 6px;
  }

  /* Cover image */
  .project-page .overlay-cover {
    border-radius: 8px;
    margin-bottom: 12px;
  }

  /* Social section */
  .project-page .overlay-social {
    margin-top: 36px;
    padding-top: 36px;
    margin-bottom: 36px;
  }
  .project-page .social-mockup-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .project-page .social-mockup-label {
    font-size: 10px;
  }
  .project-page .social-mockup-note {
    font-size: 8px;
  }

  /* Folder gallery */
  .project-page .folder-gallery {
    margin-bottom: 40px;
  }
  .project-page .folder-doc {
    padding: 24px 20px 20px 40px;
    border-radius: 10px;
  }
  .project-page .folder-clip {
    width: 18px;
    left: -9px;
    height: 90px;
  }
  .project-page .folder-clip::before,
  .project-page .folder-clip::after {
    width: 10px;
    height: 10px;
  }
  .project-page .folder-clip::before { top: 10px; }
  .project-page .folder-clip::after  { bottom: 10px; }
  .project-page .fdc-toprow {
    font-size: 7px;
    margin-bottom: 16px;
  }
  .project-page .fdc-logo {
    font-size: 9px;
    padding: 3px 9px;
    margin-bottom: 10px;
  }
  .project-page .fdc-dept {
    font-size: 7px;
  }
  .project-page .fdc-title {
    font-size: 22px;
  }
  .project-page .fdc-from {
    font-size: 7px;
  }
  .project-page .fdc-from span {
    font-size: 7px;
  }
  .project-page .fdc-note {
    font-size: 7px;
  }
  .project-page .fdc-cta {
    font-size: 8px;
    padding: 6px 14px;
  }
  .project-page .fdc-stamp {
    font-size: 7px;
  }
  .project-page .fdc-footer {
    font-size: 6px;
  }

  /* Sheet grid on mobile */
  .project-page .sheet-grid {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 12px;
  }
  .project-page .sheet-photo--full img {
    border-radius: 6px;
  }

  /* Gadget section */
  .project-page .overlay-gadget-section {
    margin-top: 36px;
  }
  .project-page .overlay-gadget-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  /* Services / Artists lineup */
  .project-page .overlay-services {
    margin-bottom: 28px;
  }
  .project-page .overlay-services-title {
    font-size: 11px;
  }
  .project-page .overlay-services-list span {
    font-size: 12px;
  }

  /* Services popover on mobile */
  .project-page .services-popover {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    top: auto;
    border-radius: 16px 16px 0 0;
    max-width: 100vw;
    width: 100%;
    padding: 24px 20px 32px;
    z-index: 1000;
  }
  .project-page .services-popover::after {
    display: none;
  }

  /* New layout — mobile */
  .proj-card {
    padding: 24px 16px;
    border-radius: 16px;
    margin: 0 12px 28px;
  }
  .proj-extra {
    padding: 0 16px;
  }
  .proj-logo-square {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    margin-bottom: 28px;
  }
  .proj-logo-square img,
  .proj-logo-square .overlay-logo {
    width: 24px;
    height: 24px;
    max-width: 24px;
  }
  .proj-title {
    font-size: clamp(28px, 8vw, 40px);
  }
  .proj-subtitle {
    font-size: 14px;
  }
  .proj-desc {
    font-size: 13px;
  }
  .proj-info-row {
    margin-bottom: 32px;
    gap: 20px;
  }
  .proj-blob-mask {
    height: clamp(160px, 40vw, 220px);
    border-radius: 36% 64% 56% 44% / 42% 36% 64% 58%;
  }
  .proj-blob-slide {
    min-width: 240px;
  }
  .proj-blob-section {
    gap: 16px;
    margin-bottom: 16px;
  }
  /* Stats in 2x2 grid on mobile */
  .proj-stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    padding-top: 16px;
  }
  .proj-stat-item {
    text-align: center;
  }
  .proj-stat-side {
    text-align: center;
  }
  .proj-stat-value {
    font-size: clamp(24px, 7vw, 36px);
  }
  .proj-stat-label {
    font-size: 9px;
    letter-spacing: 0.1em;
  }

  .proj-services {
    margin-bottom: 36px;
    padding-bottom: 32px;
  }
  .proj-services-tags {
    gap: 6px;
    margin-top: 14px;
  }
  .proj-service-tag {
    font-size: 9px;
    padding: 6px 12px;
  }

  /* Footer on project page mobile */
  .project-page ~ .footer {
    padding: 24px 16px;
  }
}

/* ---------- Project Page — Small phones (max 375px) ---------- */
@media (max-width: 375px) {
  .project-page .overlay-inner { padding: 16px 12px 56px; }
  .project-page .overlay-title {
    font-size: clamp(32px, 10vw, 48px);
  }
  .project-page .overlay-stat,
  .project-page .services-folder-wrap {
    min-width: 100%;
  }
  .project-page .overlay-stats {
    flex-direction: column;
  }
  .project-page .social-mockup-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .project-page .folder-doc {
    padding: 20px 16px 16px 36px;
  }

  /* Small phone new layout */
  .proj-card {
    padding: 20px 14px;
    margin: 0 8px 24px;
  }
  .proj-stats-row {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .proj-title {
    font-size: clamp(24px, 8vw, 36px);
  }
}

/* ---------- Touch devices — restore real cursor ---------- */
@media (hover: none) and (pointer: coarse) {
  body { cursor: auto; }
  .cursor { display: none; }
  a, button, .project-card, .concept-card,
  .folder-doc, .badge-wrap, .vinyl-wrap { cursor: pointer; }

  /* Zoom social mockup al tap su touch */
  .social-mockup-item:active img {
    transform: scale(1.08);
    transition: transform 0.15s ease;
  }

  /* Vinyl two-tap: first tap shows disc, second tap follows link */
  .vinyl-wrap img.vinyl-disc {
    transition: transform 0.5s cubic-bezier(0.34, 1.4, 0.64, 1);
  }
  .vinyl-wrap.vinyl-tapped img.vinyl-disc {
    transform: translateX(-50%) translateY(-52%) rotate(-9deg);
  }
  .vinyl-wrap.vinyl-tapped .vinyl-cover {
    transform: scale(1.03);
  }
}

/* ==========================================
   PASSWORD GATE — MONOCHROME layout
   ========================================== */

.fg-gate {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  transition: opacity 0.8s var(--ease);
}

.fg-gate--exit {
  opacity: 0;
  pointer-events: none;
}

.fg-gate-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: min(420px, 88vw);
}

/* ---- Shaped block ---- */
/* Diagonal notch top-right — mirrors MONOCHROME's block shape */
.fg-gate-block {
  position: relative;
  width: 100%;
  height: 175px;
  background: var(--cream);
  clip-path: polygon(0 0, 57% 0, 100% 44%, 100% 100%, 0 100%);
  margin-bottom: 22px;
  flex-shrink: 0;
}

/* "FG" — top-left, large bold sans (mirrors MONO) */
.fg-gate-top {
  position: absolute;
  top: 14px;
  left: 20px;
  font-family: var(--font-body);
  font-size: clamp(56px, 14vw, 72px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--bg);
  text-transform: uppercase;
}

/* ® — positioned at the diagonal junction, above CREATIVE PLANNING */
.fg-gate-reg {
  position: absolute;
  right: 20px;
  top: 76px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  color: var(--bg);
  line-height: 1;
}

/* "CREATIVE" — bottom-right, large bold sans (mirrors CHROME top line) */
.fg-gate-cp-top {
  position: absolute;
  right: 20px;
  bottom: 48px;
  font-family: var(--font-body);
  font-size: clamp(22px, 5.5vw, 30px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--bg);
  text-transform: uppercase;
}

/* "PLANNING" — bottom-right second line (mirrors CHROME bottom line) */
.fg-gate-cp-bot {
  position: absolute;
  right: 20px;
  bottom: 14px;
  font-family: var(--font-body);
  font-size: clamp(22px, 5.5vw, 30px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--bg);
  text-transform: uppercase;
}

/* ---- Below-block tagline — mirrors MONOCHROME's two-column caption ---- */
.fg-gate-tagline {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  width: 100%;
  margin-bottom: 32px;
}

.fg-gate-tag-left,
.fg-gate-tag-right {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cream);
  line-height: 1.7;
}

.fg-gate-tag-right {
  text-align: right;
}

/* ---- Password reveal ---- */
.fg-gate-pw {
  width: 100%;
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.5s var(--ease), opacity 0.4s ease;
}

.fg-gate-pw.is-visible {
  max-height: 80px;
  opacity: 1;
}

.fg-gate-pw-label {
  font-family: var(--font-body);
  font-size: 9px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(245, 237, 214, 0.45);
  display: block;
  margin-bottom: 10px;
}

.fg-gate-input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(245, 237, 214, 0.2);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 300;
  letter-spacing: 0.4em;
  padding: 6px 0;
  outline: none;
  caret-color: var(--cream);
  transition: border-color 0.3s ease;
}

.fg-gate-input:focus {
  border-bottom-color: rgba(245, 237, 214, 0.6);
}

.fg-gate-input::placeholder {
  color: rgba(245, 237, 214, 0.18);
  font-size: 10px;
  letter-spacing: 0.3em;
}

/* Wrong password shake */
@keyframes fg-shake {
  0%, 100% { transform: translateX(0); }
  20%       { transform: translateX(-9px); }
  40%       { transform: translateX(9px); }
  60%       { transform: translateX(-6px); }
  80%       { transform: translateX(5px); }
}

.fg-gate-inner.is-shaking {
  animation: fg-shake 0.5s ease;
}

/* Mobile */
@media (max-width: 480px) {
  .fg-gate-block { height: 148px; }
  .fg-gate-reg   { top: 62px; right: 16px; }
}

/* ==============================================
   PERFORMANCE — GPU compositing & cross-browser
   ============================================== */

/* Forza layer GPU su elementi animati frequentemente */
.hero-bg,
.hero-physics-canvas,
.ambient-bg {
  will-change: transform;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

/* Riduce blur backdrop-filter su Safari (blur alto = lento) */
@supports (-webkit-backdrop-filter: blur(1px)) and (not (backdrop-filter: blur(1px))) {
  /* Solo webkit senza standard = Safari < 15 */
  .card-folder,
  .card-tab,
  .nav.scrolled {
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
  }
}


/* ==========================================
   ANTI-COPIA — Protezione contenuti
   ========================================== */

/* Blocca selezione testo su tutto il sito */
body, body * {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

/* Permetti selezione solo negli input */
input, textarea {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
}

/* Blocca drag immagini */
img {
  -webkit-user-drag: none;
  user-drag: none;
  pointer-events: none;
}

/* Ripristina pointer-events per link e bottoni */
a, button, [role="button"],
.project-card, .badge-wrap, .vinyl-wrap,
.nav-link, .overlay-back, .overlay-close,
.theme-toggle, .lang-toggle,
.project-nav-back, .folder-doc, .services-folder-wrap,
.fg-gate, .fg-gate-inner, #pw-input {
  pointer-events: auto;
}

/* Hero accent chars (il punto arancione nel nome) */
.hero-accent-char {
  color: var(--accent);
}

/* ---------- SC Mini-Player (resume bar on project pages) ---------- */
.sc-mini-player {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: auto;
}
.sc-mini-player.is-visible {
  transform: translateY(0);
}
.sc-mini-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: var(--bg-raise, #2e2c2a);
  border-top: 1px solid var(--border, rgba(255,252,242,0.08));
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
[data-theme="light"] .sc-mini-inner {
  background: rgba(255,255,255,0.92);
  border-top-color: rgba(0,0,0,0.08);
}
.sc-mini-icon {
  font-size: 18px;
  color: var(--accent, #E5383B);
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(229,56,59,0.12);
}
.sc-mini-text {
  flex: 1;
  font-family: var(--font-body, 'Inter', sans-serif);
  font-size: 13px;
  font-weight: 500;
  color: var(--cream, #FFFCF2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
[data-theme="light"] .sc-mini-text {
  color: var(--bg, #252422);
}
.sc-mini-cta {
  font-family: var(--font-body, 'Inter', sans-serif);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent, #E5383B);
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  animation: sc-mini-pulse 2s ease-in-out infinite;
}
@keyframes sc-mini-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
.sc-mini-close {
  background: none;
  border: none;
  color: var(--muted, rgba(255,252,242,0.58));
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 2px;
  flex-shrink: 0;
}
[data-theme="light"] .sc-mini-close {
  color: rgba(0,0,0,0.4);
}
.sc-mini-close:hover {
  color: var(--cream, #FFFCF2);
}
[data-theme="light"] .sc-mini-close:hover {
  color: var(--bg, #252422);
}
@media (max-width: 600px) {
  .sc-mini-inner { padding: 12px 16px; gap: 10px; }
  .sc-mini-text { font-size: 12px; }
  .sc-mini-cta { font-size: 11px; }
}

/* ========== Digital Communication & Web Development Section ========== */
.digital-comm {
  padding: 0 0 80px;
  position: relative;
  border-top: 1px solid rgba(128,128,128,0.15);
  margin-top: 40px;
}
.digital-comm .section-header {
  margin-bottom: 65px;
  padding: 0;
  border-bottom: none;
}
.digital-comm .section-title {
  font-family: 'Space Mono', monospace;
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0.9;
  line-height: 1.4;
  margin-left: 48px;
}
.digital-comm-grid {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 48px;
  padding-left: 48px;
  flex-wrap: wrap;
}

/* --- Glass Folder (dark, with screenshot docs) --- */
.glass-folder-link {
  display: block;
  text-decoration: none;
  cursor: pointer;
}
.glass-folder {
  position: relative;
  width: 280px;
  height: 220px;
  margin: 0 auto;
  animation: glassFloat 4s ease-in-out infinite;
  transition: transform 0.4s cubic-bezier(0.16,1,0.3,1);
}
.glass-folder:hover {
  transform: scale(1.04) translateY(-6px);
}

/* Back panel */
.glass-folder-back {
  position: absolute;
  inset: 0;
}
.glass-folder-back-tab {
  position: absolute;
  top: 0;
  left: 20px;
  width: 80px;
  height: 28px;
  background: #2a2a2a;
  border-radius: 10px 10px 0 0;
}
.glass-folder-back-body {
  position: absolute;
  top: 22px;
  left: 0;
  right: 0;
  bottom: 0;
  background: #2a2a2a;
  border-radius: 4px 14px 14px 14px;
}

/* Documents (screenshots) peeking out */
.glass-folder-docs {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 140px;
  z-index: 1;
}
.glass-folder-doc {
  position: absolute;
  width: 80px;
  height: 110px;
  background-color: #f5f5f5;
  background-size: cover;
  background-position: top center;
  background-repeat: no-repeat;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  overflow: hidden;
  transition: transform 0.5s cubic-bezier(0.16,1,0.3,1);
}
.glass-folder-doc.doc-1 {
  left: 30px;
  top: 10px;
  transform: rotate(-6deg) translateY(0);
  background-image: url('../projects/pesenti/img/hero.jpg');
}
.glass-folder-doc.doc-2 {
  right: 30px;
  top: 5px;
  transform: rotate(4deg) translateY(0);
  background-image: url('../projects/pesenti/img/services.jpg');
}
.glass-folder-doc.doc-fgweb-1 {
  background-image: url('../projects/fgweb/img/hero.jpg');
}
.glass-folder-doc.doc-fgweb-2 {
  background-image: url('../projects/fgweb/img/badges.jpg');
}

/* Fan out on hover */
.glass-folder:hover .doc-1 {
  transform: rotate(-14deg) translateY(-28px) translateX(-12px);
}
.glass-folder:hover .doc-2 {
  transform: rotate(12deg) translateY(-32px) translateX(12px);
}

/* Doc text lines (fallback if no bg image) */
.doc-line {
  height: 4px;
  background: #ddd;
  border-radius: 2px;
  margin: 6px 8px;
}
.doc-line.w40 { width: 40%; }
.doc-line.w50 { width: 50%; }
.doc-line.w60 { width: 60%; }
.doc-line.w70 { width: 70%; }
.doc-line.w80 { width: 80%; }
.doc-line.w85 { width: 85%; }

/* Front panel (glass) */
.glass-folder-front {
  position: absolute;
  top: 55%;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    160deg,
    rgba(60,60,60,0.85) 0%,
    rgba(40,40,40,0.92) 50%,
    rgba(30,30,30,0.95) 100%
  );
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 0 0 14px 14px;
  z-index: 2;
  display: flex;
  align-items: center;
  padding: 0 24px;
}

/* Label on front */
.glass-folder-label {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.glass-folder-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: #FFFCF2;
  letter-spacing: 0.04em;
}
.glass-folder-sub {
  font-family: 'Space Mono', monospace;
  font-size: 9px;
  color: rgba(255,252,242,0.5);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* Glass reflection */
.glass-folder-shine {
  position: absolute;
  top: 55%;
  left: 0;
  right: 0;
  height: 30%;
  background: linear-gradient(
    180deg,
    rgba(255,255,255,0.08) 0%,
    transparent 100%
  );
  border-radius: 0 0 14px 14px;
  z-index: 3;
  pointer-events: none;
}

/* Shadow under folder */
.glass-folder::after {
  content: '';
  position: absolute;
  bottom: -16px;
  left: 15%;
  right: 15%;
  height: 20px;
  background: radial-gradient(ellipse, rgba(0,0,0,0.2) 0%, transparent 70%);
  filter: blur(6px);
  z-index: -1;
}

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

@media (max-width: 600px) {
  .digital-comm { padding: 0 0 60px; }
  .digital-comm-grid { gap: 32px; justify-items: center; }
  .glass-folder { width: 220px; height: 175px; }
  .glass-folder-back-tab { width: 64px; height: 22px; left: 16px; }
  .glass-folder-doc { width: 64px; height: 88px; }
  .glass-folder-docs { width: 160px; height: 110px; }
  .glass-folder-name { font-size: 12px; }
  .glass-folder-sub { font-size: 8px; }
}

/* ---- Lead Popup ---- */
.lead-popup {
  position: fixed;
  bottom: 32px;
  right: 32px;
  z-index: 9000;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 28px 32px;
  max-width: 360px;
  width: calc(100% - 64px);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 8px 40px rgba(0,0,0,0.12);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}
.lead-popup.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.lead-popup-close {
  position: absolute;
  top: 12px; right: 16px;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--muted);
  cursor: pointer;
  line-height: 1;
}
.lead-popup-title {
  font-family: 'Space Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 6px;
}
.lead-popup-text {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 18px;
}
.lead-popup-form {
  display: flex;
  gap: 8px;
}
.lead-popup-input {
  flex: 1;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  outline: none;
}
.lead-popup-input:focus {
  border-color: var(--accent);
}
.lead-popup-btn {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  padding: 10px 20px;
  background: var(--text);
  color: var(--bg);
  border: none;
  cursor: pointer;
  transition: opacity 0.2s;
}
.lead-popup-btn:hover { opacity: 0.85; }
.lead-popup-thanks {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  color: var(--accent);
  margin: 0;
}

/* ---- Contact form fieldset reset ---- */
.services-fieldset {
  border: none;
  margin: 0;
  padding: 0;
}

/* ---- Accessibility ---- */

/* Skip to content link */
.skip-link {
  position: fixed;
  top: -100%;
  left: 16px;
  z-index: 10000;
  background: var(--text);
  color: var(--bg);
  padding: 10px 20px;
  font-family: 'Space Mono', monospace;
  font-size: 13px;
  text-decoration: none;
  transition: top 0.2s ease;
}
.skip-link:focus {
  top: 16px;
}

/* Focus visible for keyboard navigation */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}
