:root {
  --bg-color: #eaf3f8;
  --primary-blue: #98c3dd;
  --dark-blue: #2c4960;
  --locker-color: #a4cae1;
  --locker-shadow: #7ba3bc;
  --accent-lime: #d8f533;
  --accent-blue: #2348f3;
  --accent-red: #ff4757;
  --accent-yellow: #ffd000;
  --text-main: #1d2b36;
  --text-muted: #5e7a8f;
  --card-bg: rgba(255, 255, 255, 0.95);
  --border-radius: 20px;
}

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

body, html {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "WenQuanYi Micro Hei", sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
}

/* 3D Canvas Canvas Container */
#webgl-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

/* Top Navigation Bar */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 40px;
  z-index: 50;
  pointer-events: none;
}

.brand-badge {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  padding: 8px 18px 8px 10px;
  border-radius: 50px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.9);
  pointer-events: auto;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.brand-badge:hover {
  transform: scale(1.04);
}

.brand-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff9a9e, #fad0c4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.brand-text {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1.5px;
  color: var(--dark-blue);
  text-transform: uppercase;
}

nav {
  display: flex;
  gap: 28px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  padding: 10px 28px;
  border-radius: 50px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.9);
  pointer-events: auto;
}

.nav-link {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1.5px;
  color: var(--dark-blue);
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  transition: color 0.2s, transform 0.2s;
  padding: 4px 0;
}

.nav-link:hover {
  color: var(--accent-blue);
  transform: translateY(-1px);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-blue);
  border-radius: 2px;
}

.header-actions {
  display: flex;
  gap: 12px;
  pointer-events: auto;
}

.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--dark-blue);
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.icon-btn:hover {
  transform: scale(1.08);
  background: #fff;
  color: var(--accent-blue);
}

/* Bottom Hint & Controls */
.bottom-hints {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  padding: 8px 22px;
  border-radius: 40px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.8);
  z-index: 40;
  pointer-events: auto;
  animation: floatHint 3s ease-in-out infinite;
}

@keyframes floatHint {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, -4px); }
}

.hint-pill {
  font-size: 13px;
  font-weight: 600;
  color: var(--dark-blue);
  display: flex;
  align-items: center;
  gap: 8px;
}

.hint-badge {
  background: var(--accent-lime);
  color: #111;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.btn-reset-view {
  background: var(--accent-blue);
  color: #fff;
  border: none;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.2s;
}

.btn-reset-view:hover {
  transform: scale(1.05);
}

/* 3D Tooltip Hover Indicator */
#hover-tooltip {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  background: rgba(20, 32, 45, 0.92);
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.2);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0;
  transform: translate(-50%, -130%) scale(0.9);
  transition: opacity 0.2s, transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid rgba(255,255,255,0.2);
}

#hover-tooltip.active {
  opacity: 1;
  transform: translate(-50%, -140%) scale(1);
}

#hover-tooltip .dot {
  width: 8px;
  height: 8px;
  background: var(--accent-lime);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent-lime);
}

/* ============================================================
   MODALS & DETAIL PANELS
   ============================================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(28, 45, 60, 0.45);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: var(--card-bg);
  border-radius: 28px;
  box-shadow: 0 25px 60px rgba(15, 30, 45, 0.25);
  position: relative;
  max-width: 92%;
  max-height: 90vh;
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.8);
  transform: scale(0.92) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal-card {
  transform: scale(1) translateY(0);
}

.close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.06);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--text-main);
  transition: all 0.2s;
  z-index: 10;
}

.close-btn:hover {
  background: var(--accent-red);
  color: #fff;
  transform: rotate(90deg);
}

/* --- ABOUT ME (ID CARD MODAL) --- */
.id-card-wrap {
  width: 400px;
  padding: 32px;
  background: #ffffff;
  border-radius: 24px;
  border: 2px solid #e1edf5;
  box-shadow: 0 20px 40px rgba(0, 70, 120, 0.08);
  position: relative;
  text-align: center;
}

.id-badge-hole {
  width: 50px;
  height: 10px;
  background: #e2eaf0;
  border-radius: 10px;
  margin: -10px auto 20px auto;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.15);
}

.id-avatar-box {
  width: 140px;
  height: 140px;
  border-radius: 24px;
  margin: 0 auto 16px auto;
  background: linear-gradient(135deg, #a1c4fd 0%, #c2e9fb 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 70px;
  box-shadow: 0 10px 20px rgba(161, 196, 253, 0.4);
  position: relative;
}

.id-speech-bubble {
  position: absolute;
  top: -12px;
  right: -30px;
  background: #fff;
  border: 2px solid var(--primary-blue);
  padding: 4px 10px;
  border-radius: 14px;
  font-size: 11px;
  font-weight: 700;
  color: var(--dark-blue);
  box-shadow: 0 4px 10px rgba(0,0,0,0.06);
}

.id-title-cn {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 4px;
  color: #0d3b66;
  margin-bottom: 2px;
}

.id-title-en {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 13px;
  letter-spacing: 3px;
  color: #1d72b8;
  font-weight: 700;
  margin-bottom: 20px;
}

.id-info-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  margin-bottom: 20px;
}

.id-info-table td {
  padding: 8px 12px;
  border-bottom: 1px dashed #d8e5ef;
  font-size: 13px;
}

.id-info-table td.label {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  color: #8da4b5;
  width: 35%;
  text-transform: uppercase;
}

.id-info-table td.value {
  font-weight: 700;
  color: var(--dark-blue);
}

.id-bio {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
  text-align: left;
  background: #f5f9fc;
  padding: 14px;
  border-radius: 14px;
  margin-top: 10px;
}

/* --- SKILLS MODAL (STACKED CASSETTE CARDS) --- */
.skills-container {
  width: 680px;
  padding: 40px;
}

.skills-header {
  margin-bottom: 24px;
}

.skills-header h2 {
  font-family: 'Syne', 'Noto Sans SC', sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: var(--dark-blue);
  display: flex;
  align-items: center;
  gap: 12px;
}

.skills-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.skill-card-item {
  border-radius: 20px;
  padding: 24px 30px;
  color: #ffffff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
  cursor: pointer;
}

.skill-card-item:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.12);
}

.skill-card-item.card-lime {
  background: #b5e80d;
  color: #132205;
}

.skill-card-item.card-blue {
  background: #2348f3;
  color: #ffffff;
}

.skill-card-item.card-white {
  background: #ffffff;
  color: var(--dark-blue);
  border: 2px solid #e1edf5;
}

.card-num-badge {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2px;
  opacity: 0.8;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.card-title-main {
  font-size: 26px;
  font-weight: 900;
  margin-bottom: 6px;
}

.card-subtitle {
  font-size: 13px;
  opacity: 0.9;
  margin-bottom: 18px;
  line-height: 1.5;
}

.skill-pills-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-pill {
  padding: 6px 14px;
  border-radius: 30px;
  font-size: 12px;
  font-weight: 700;
  backdrop-filter: blur(5px);
}

.card-lime .skill-pill {
  background: rgba(0, 0, 0, 0.08);
  color: #111;
}

.card-blue .skill-pill {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.card-white .skill-pill {
  background: #f0f5fa;
  color: #2c4960;
  border: 1px solid #d9e6f0;
}

/* ============================================================
   SELECTED WORK: FOLDER EXPLORER & 4 CATEGORY SHOWCASES
   ============================================================ */
.works-modal-wrap {
  width: 1080px;
  min-height: 640px;
  padding: 40px;
  background: #f9fcfe;
}

.works-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.works-header h2 {
  font-family: 'Syne', 'Noto Sans SC', sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: var(--dark-blue);
}

/* 4 Category Folder Tabs */
.category-folders-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 32px;
}

.folder-tab-btn {
  border: none;
  border-radius: 20px;
  padding: 22px 18px;
  cursor: pointer;
  text-align: left;
  position: relative;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 10px 20px rgba(0,0,0,0.04);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 120px;
}

.folder-tab-btn:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 16px 30px rgba(0,0,0,0.1);
}

.folder-tab-btn.active {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 16px 32px rgba(0,0,0,0.15);
  outline: 3px solid #111;
}

.folder-graphic {
  background: #b5e80d;
  color: #0c1800;
}

.folder-illustration {
  background: #2348f3;
  color: #ffffff;
}

.folder-infographic {
  background: #111111;
  color: #ffffff;
}

.folder-livestream {
  background: #ff4757;
  color: #ffffff;
}

.folder-en-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.folder-cn-title {
  font-size: 19px;
  font-weight: 900;
  margin-top: 4px;
}

.folder-count-badge {
  align-self: flex-end;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 12px;
  background: rgba(255,255,255,0.25);
}

.folder-graphic .folder-count-badge {
  background: rgba(0,0,0,0.12);
}

/* Works Items Container */
.works-content-area {
  min-height: 400px;
}

/* 1. Graphic Design: Poster 3D Tilt Carousel / Grid */
.graphic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.poster-card {
  background: #fff;
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.06);
  border: 1px solid #eef3f7;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
}

.poster-card:hover {
  transform: translateY(-8px) rotate(-1deg);
  box-shadow: 0 20px 40px rgba(0,0,0,0.12);
}

.poster-img-box {
  width: 100%;
  height: 260px;
  border-radius: 14px;
  overflow: hidden;
  background: #f0f4f8;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.poster-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.poster-meta {
  margin-top: 14px;
}

.poster-meta h4 {
  font-size: 16px;
  font-weight: 800;
  color: var(--dark-blue);
}

.poster-meta p {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* 2. Illustration Design: IP Character & Art Grid */
.illustration-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.illustration-card {
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0,0,0,0.06);
  border: 1px solid #eef3f7;
  transition: transform 0.3s, box-shadow 0.3s;
  cursor: pointer;
}

.illustration-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(35, 72, 243, 0.15);
}

.illus-img-box {
  width: 100%;
  height: 240px;
  background: #eef5fc;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.illus-info {
  padding: 16px;
}

.illus-tag {
  display: inline-block;
  background: #eef2ff;
  color: var(--accent-blue);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 8px;
  margin-bottom: 6px;
}

/* 3. Long-form / Infographics: Scrollable Phone/Tall View */
.longform-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.longform-card {
  background: #fff;
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.06);
  border: 1px solid #eef3f7;
}

.longform-scroll-box {
  width: 100%;
  height: 320px;
  overflow-y: auto;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  position: relative;
  scrollbar-width: thin;
}

.longform-scroll-box::-webkit-scrollbar {
  width: 5px;
}

.longform-scroll-box::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 10px;
}

.longform-preview-content {
  width: 100%;
}

.scroll-hint-banner {
  font-size: 11px;
  font-weight: 700;
  text-align: center;
  color: #64748b;
  padding: 6px 0;
  background: #f1f5f9;
  border-radius: 8px;
  margin-top: 10px;
}

/* 4. Livestream Overlays & Elements Grid */
.livestream-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.live-card {
  background: #fff;
  border-radius: 20px;
  padding: 18px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.06);
  border: 1px solid #eef3f7;
  cursor: pointer;
  transition: transform 0.3s;
}

.live-card:hover {
  transform: translateY(-6px);
}

.live-preview-box {
  width: 100%;
  height: 200px;
  border-radius: 14px;
  background: #0f172a;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.live-badge-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: #ff4757;
  color: #fff;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Lightbox Image Preview */
#lightbox-modal {
  z-index: 300;
}

.lightbox-content {
  max-width: 90vw;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.lightbox-img {
  max-width: 100%;
  max-height: 75vh;
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.3);
}

.lightbox-caption {
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
}

/* ============================================================
   CONTACT & CORKBOARD GUESTBOOK MODAL
   ============================================================ */
.contact-modal-wrap {
  width: 920px;
  padding: 40px;
  background: #c89d6b; /* Corkboard wood texture background */
  border: 12px solid #8d633c;
  border-radius: 28px;
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.4), 0 30px 60px rgba(0,0,0,0.3);
  position: relative;
  background-image: radial-gradient(#b88e5d 15%, transparent 16%);
  background-size: 16px 16px;
}

.corkboard-title {
  text-align: center;
  color: #ffffff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.4);
  font-size: 28px;
  font-weight: 900;
  margin-bottom: 24px;
  letter-spacing: 2px;
}

.contact-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 28px;
}

/* Vintage Typewriter Input Card */
.typewriter-card {
  background: #fdfbf7;
  padding: 24px;
  border-radius: 20px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.2);
  border: 2px solid #e2dcd2;
  position: relative;
}

.typewriter-header {
  font-family: 'Space Grotesk', monospace;
  font-size: 12px;
  font-weight: 700;
  color: #8c8275;
  border-bottom: 2px dashed #e2dcd2;
  padding-bottom: 8px;
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
}

.typewriter-input {
  width: 100%;
  height: 110px;
  background: transparent;
  border: none;
  font-family: 'Space Grotesk', 'Noto Sans SC', monospace;
  font-size: 14px;
  line-height: 1.6;
  color: #2b251f;
  resize: none;
  outline: none;
}

.typewriter-name-input {
  width: 100%;
  border: 1px solid #e0d8cc;
  background: #f5f0e6;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #333;
  margin-bottom: 12px;
  outline: none;
}

.typewriter-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.btn-type-submit {
  background: #382d24;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 12px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.btn-type-submit:hover {
  background: #111;
  transform: translateY(-2px);
}

/* Sticky Notes Corkboard Grid */
.sticky-notes-wall {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  max-height: 380px;
  overflow-y: auto;
  padding: 10px;
}

.sticky-note {
  padding: 18px;
  border-radius: 4px;
  box-shadow: 0 10px 20px rgba(0,0,0,0.18);
  font-size: 13px;
  line-height: 1.5;
  color: #2c251e;
  position: relative;
  transition: transform 0.2s;
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.sticky-note:hover {
  transform: scale(1.05) rotate(0deg) !important;
  z-index: 5;
}

.pin-dot {
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #e63946;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.sticky-yellow { background: #fff3a8; }
.sticky-pink { background: #ffd6df; }
.sticky-blue { background: #cce7ff; }
.sticky-green { background: #d7f7c4; }

.sticky-author {
  font-size: 11px;
  font-weight: 700;
  opacity: 0.7;
  text-align: right;
  margin-top: 8px;
}

/* Loading Screen */
#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #ffffff;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s ease, visibility 0.4s;
  pointer-events: none;
}

#loading-screen.fade-out {
  opacity: 0;
  visibility: hidden;
  display: none !important;
}

.loading-title {
  font-family: 'Syne', sans-serif;
  font-size: 48px;
  font-weight: 800;
  color: #b8d8ea;
  letter-spacing: 6px;
  margin-bottom: 24px;
}

.loading-spinner-ring {
  width: 64px;
  height: 64px;
  border: 5px solid #eef5fa;
  border-top-color: #2348f3;
  border-radius: 50%;
  animation: spin 0.9s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite;
}

.loading-text {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-top: 18px;
}

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

/* Responsive adjustments */
@media (max-width: 900px) {
  header { padding: 16px 20px; }
  nav { display: none; }
  .works-modal-wrap, .contact-modal-wrap, .skills-container { width: 95vw; padding: 20px; }
  .category-folders-grid { grid-template-columns: repeat(2, 1fr); }
  .graphic-grid, .illustration-grid, .longform-grid { grid-template-columns: 1fr; }
  .contact-layout { grid-template-columns: 1fr; }
}
