/* ===== GLOBAL FONT IMPORT ===== */
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=Quicksand:wght@400;500;600;700&display=swap');

/* ===== ROOT VARIABLES - NEUMORPHISM ===== */
:root {
  --font-display: 'Syne', system-ui, sans-serif;
  --font-main: 'Quicksand', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  
  /* Neumorphism Color Palette */
  --bg: #e0e5ec;
  --bg-dark: #d4d9e0;
  --surface: #e0e5ec;
  --surface-soft: #e0e5ec;
  --text: #4a4a4a;
  --text-muted: #6b7280;
  --accent: #7c3aed;
  --accent-soft: rgba(124, 58, 237, 0.15);
  
  /* Neumorphism Shadows */
  --shadow-light: #ffffff;
  --shadow-dark: #a3b1c6;
  --shadow-inset-light: rgba(255,255,255,0.7);
  --shadow-inset-dark: rgba(163,177,198,0.6);
  
  /* Neumorphism Shadow Presets */
  --neo-shadow-raised: 8px 8px 16px var(--shadow-dark), -8px -8px 16px var(--shadow-light);
  --neo-shadow-raised-sm: 4px 4px 8px var(--shadow-dark), -4px -4px 8px var(--shadow-light);
  --neo-shadow-raised-lg: 12px 12px 24px var(--shadow-dark), -12px -12px 24px var(--shadow-light);
  --neo-shadow-inset: inset 4px 4px 8px var(--shadow-inset-dark), inset -4px -4px 8px var(--shadow-inset-light);
  --neo-shadow-inset-sm: inset 2px 2px 4px var(--shadow-inset-dark), inset -2px -2px 4px var(--shadow-inset-light);
  
  --radius-lg: 1.5rem;
  --radius-md: 1rem;
  --radius-sm: 0.5rem;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-main);
  min-height: 100vh;
  position: relative;
  /* Subtle texture for neumorphism */
  background-image: linear-gradient(135deg, #e2e6ec 0%, #dde3eb 50%, #e0e5ec 100%);
}

/* Home page darker background */
body[data-bg="home"] {
  --bg: #d4d9e0;
  --surface: #d8dde4;
  background: var(--bg);
  background-image: linear-gradient(135deg, #d2d7de 0%, #cdd3db 50%, #d4d9e0 100%);
}

/* Playground uses same background as other pages */
body[data-bg="playground"] {
  background: var(--bg);
  background-image: linear-gradient(135deg, #e2e6ec 0%, #dde3eb 50%, #e0e5ec 100%);
}

body.custom-cursor-active {
  cursor: none;
}

body.custom-cursor-active a,
body.custom-cursor-active button,
body.custom-cursor-active [role="button"],
body.custom-cursor-active label {
  cursor: none;
}

body.custom-cursor-active a *,
body.custom-cursor-active button *,
body.custom-cursor-active [role="button"] *,
body.custom-cursor-active label *,
body.custom-cursor-active .clickable,
body.custom-cursor-active .clickable *,
body.custom-cursor-active [data-interactive="true"],
body.custom-cursor-active [data-interactive="true"] *,
body.custom-cursor-active video,
body.custom-cursor-active video * {
  cursor: none;
}

body.custom-cursor-active input,
body.custom-cursor-active textarea,
body.custom-cursor-active select,
body.custom-cursor-active [contenteditable="true"] {
  cursor: text;
}

/* ===== NEUMORPHIC BUTTON ===== */
.neo-btn {
  position: relative;
  display: inline-block;
  text-decoration: none;
  padding: 0.85rem 1.8rem;
  border-radius: 50px;
  border: none;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  font-family: var(--font-main);
  color: var(--text);
  background: var(--surface);
  box-shadow: var(--neo-shadow-raised);
  transition: all 0.2s ease;
  cursor: pointer;
  z-index: 1;
}

.neo-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--neo-shadow-raised-lg);
  color: var(--accent);
}

.neo-btn:active {
  transform: translateY(0);
  box-shadow: var(--neo-shadow-inset);
}

/* ===== HEADER / LAYOUT ===== */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.4rem 0.5rem;
  position: relative;
  z-index: 2;
}

.site-title {
  font-size: 1.4rem;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.top-nav {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.top-nav a {
  color: var(--text);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 500;
  background: var(--surface);
  padding: 0.55rem 1rem;
  border-radius: 50px;
  box-shadow: var(--neo-shadow-raised-sm);
  transition: all 0.2s ease;
}

.top-nav a:hover,
.top-nav a:focus {
  transform: translateY(-2px);
  box-shadow: var(--neo-shadow-raised);
  color: var(--accent);
}

.top-nav a:active {
  transform: translateY(0);
  box-shadow: var(--neo-shadow-inset-sm);
}

.top-nav a.active {
  background: var(--accent-soft);
  color: var(--accent);
  box-shadow: var(--neo-shadow-inset-sm);
}

.page {
  max-width: 900px;
  margin: 0 auto;
  padding: 1.2rem 1.4rem 3.5rem;
  position: relative;
  z-index: 1;
}

/* Desktop: Add generous margins for background visibility */
@media (min-width: 1100px) {
  .page {
    max-width: 860px;
    padding: 2rem 2.5rem 4rem;
  }
}

@media (min-width: 1400px) {
  .page {
    max-width: 920px;
  }
}

/* particle canvas layer remains click-through */
#particle-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
}
#rainbow-cursor-layer {
  position: fixed;
  top: 0;
  left: 0;
  width: 128px;
  height: 128px;
  pointer-events: none;
  z-index: 220;
  mix-blend-mode: screen;
  opacity: 0;
  transform: translate3d(-999px, -999px, 0);
  transition: opacity 0.14s ease;
  will-change: transform, opacity;
}

#rainbow-cursor-layer.is-visible {
  opacity: 1;
}

.neo-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--neo-shadow-raised-lg);
}

/* ===== TYPOGRAPHY - Display font for headings ===== */
h1, h2, h3, h4, h5, h6,
.hero-title,
.section-heading,
.exhibition-title {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
}

.site-title {
  font-family: var(--font-display);
  font-weight: 700;
}

/* headings that use accent */
.gradient-text {
  background: linear-gradient(135deg, var(--accent) 0%, #a855f7 50%, #6366f1 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.media-slot,
.text-slot,
.extra-slot {
  background: rgba(0,0,0,0.05);
  border: 1px dashed rgba(255,255,255,0.03);
  border-radius: 1rem;
  min-height: 90px;
  padding: 0.5rem 0.75rem;
  margin-bottom: 0.8rem;
  font-size: 0.78rem;
  opacity: 0.75;
}

/* profile video defaults for subpages */
.profile-video-wrap {
  position: relative;
  width: 130px;
  height: 130px;
}

.profile-video {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--surface);
  object-fit: cover;
  border: 4px solid var(--surface);
  box-shadow: var(--neo-shadow-raised);
  cursor: pointer;
  transition: all 0.3s ease;
}

.profile-video:hover {
  box-shadow: var(--neo-shadow-raised-lg);
  transform: scale(1.02);
}

.video-hint {
  position: absolute;
  bottom: -1.2rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.6rem;
  opacity: 0.5;
}

@media (max-width: 950px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .profile-video-wrap {
    margin-top: 0.6rem;
  }
}

@media (max-width: 600px) {
  .page {
    padding-inline: 1rem;
  }
  .top-nav {
    gap: 0.4rem;
  }
  .top-nav a {
    font-size: 0.7rem;
  }
}

.lightbox {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1.6rem, 5vw, 3rem);
  background: rgba(224, 229, 236, 0.92);
  backdrop-filter: blur(12px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0s linear 0.35s;
  z-index: 200;
}

.lightbox.is-visible {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.35s ease;
}

.lightbox__img {
  max-width: min(1200px, 92vw);
  max-height: 90vh;
  border-radius: var(--radius-lg);
  box-shadow: var(--neo-shadow-raised-lg);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.35s ease;
  will-change: transform, opacity;
}

.lightbox__close {
  position: absolute;
  top: clamp(1.2rem, 3vw, 2.2rem);
  right: clamp(1.2rem, 3vw, 2.2rem);
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: none;
  background: var(--surface);
  color: var(--text);
  font-size: 1.1rem;
  font-weight: 600;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: var(--neo-shadow-raised);
  transition: all 0.2s ease;
}

.lightbox__close:hover,
.lightbox__close:focus-visible {
  transform: translateY(-2px);
  box-shadow: var(--neo-shadow-raised-lg);
  color: var(--accent);
}

.lightbox__close:active {
  box-shadow: var(--neo-shadow-inset);
}

/* ===== PLAYGROUND NAV BUTTON ===== */
.playground-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-left: 0.8rem;
  padding: 0.55rem 1rem;
  border-radius: 50px;
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, var(--accent-soft), rgba(99, 102, 241, 0.1));
  color: var(--accent);
  box-shadow: var(--neo-shadow-raised-sm);
  transition: all 0.2s ease;
  will-change: transform;
}

.playground-nav-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--neo-shadow-raised);
}

.playground-nav-btn:active {
  box-shadow: var(--neo-shadow-inset-sm);
}

.playground-nav-btn .btn-icon {
  font-size: 1rem;
}

.playground-nav-btn.active {
  background: var(--accent-soft);
  box-shadow: var(--neo-shadow-inset-sm);
}

/* ===== MOBILE HAMBURGER MENU ===== */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 8px;
  background: var(--surface);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  box-shadow: var(--neo-shadow-raised-sm);
  transition: all 0.2s ease;
  z-index: 101;
}

.mobile-menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.2s ease;
}

.mobile-menu-toggle:hover {
  transform: translateY(-2px);
  box-shadow: var(--neo-shadow-raised);
}

.mobile-menu-toggle:active {
  box-shadow: var(--neo-shadow-inset-sm);
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 800px) {
  .mobile-menu-toggle {
    display: flex;
  }
  
  .site-header {
    flex-wrap: wrap;
  }
  
  .top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    background: rgba(224, 229, 236, 0.97);
    backdrop-filter: blur(12px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s linear 0.3s;
    z-index: 100;
    padding: 2rem;
  }
  
  .top-nav.mobile-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease;
  }
  
  .top-nav a {
    font-size: 1rem;
    padding: 0.75rem 1.5rem;
    text-align: center;
    min-width: 180px;
  }
  
  .playground-nav-btn {
    margin-left: 0;
    font-size: 1rem;
    padding: 0.75rem 1.5rem;
  }
}

@media (max-width: 480px) {
  .site-title {
    font-size: 1.2rem;
  }
  
  .top-nav a {
    font-size: 0.9rem;
    padding: 0.65rem 1.25rem;
    min-width: 160px;
  }
}

/* ===== CONTENT VISIBILITY ===== */
/* Content is visible by default - no page transition animations */

/* Clickable images - subtle hover effect */
[data-interactive="true"],
[data-lightbox] {
  cursor: pointer;
  transition: opacity 0.3s ease, box-shadow 0.4s ease;
}

[data-interactive="true"]:hover,
[data-lightbox]:hover {
  opacity: 0.9;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

[data-interactive="true"]:active,
[data-lightbox]:active {
  opacity: 0.8;
}
