/* ========================================
   芝士云龙 - Furry Artist Portfolio
   Global Styles
   ======================================== */

/* ---------- CSS Variables ---------- */
:root {
  /* Colors - Warm purple/pink dark theme */
  --bg-primary: #1a1025;
  --bg-secondary: #231535;
  --bg-tertiary: #2d1d42;
  --bg-card: #2a1a3d;
  --bg-card-hover: #352050;
  --bg-glass: rgba(42, 26, 61, 0.85);
  --bg-glass-light: rgba(60, 35, 90, 0.7);

  --text-primary: #f0e6f6;
  --text-secondary: #c4b0d4;
  --text-muted: #8a7499;
  --text-heading: #ffffff;

  --accent-purple: #a855f7;
  --accent-purple-light: #c084fc;
  --accent-purple-dark: #7c3aed;
  --accent-pink: #ec4899;
  --accent-pink-light: #f472b6;
  --accent-magenta: #d946ef;
  --accent-blue: #818cf8;
  --accent-primary: #a855f7;
  --danger: #ef4444;
  --accent-gradient: linear-gradient(135deg, #a855f7, #ec4899);
  --accent-gradient-hover: linear-gradient(135deg, #c084fc, #f472b6);
  --accent-gradient-soft: linear-gradient(135deg, rgba(168,85,247,0.15), rgba(236,72,153,0.15));

  --border-color: rgba(168, 85, 247, 0.2);
  --border-color-light: rgba(168, 85, 247, 0.1);
  --border-color-hover: rgba(168, 85, 247, 0.5);

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(168, 85, 247, 0.3);
  --shadow-glow-pink: 0 0 20px rgba(236, 72, 153, 0.3);

  --success: #34d399;
  --warning: #fbbf24;
  --error: #f87171;
  --info: #60a5fa;

  /* Fonts */
  --font-primary: 'Noto Sans SC', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-heading: 'Noto Sans SC', 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'Fira Code', 'Cascadia Code', monospace;

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;

  /* Border radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Z-index layers */
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-nav: 500;
  --z-modal-backdrop: 900;
  --z-modal: 1000;
  --z-toast: 1100;
  --z-tooltip: 1200;

  /* Layout */
  --nav-height: 64px;
  --subnav-height: 42px;
  --container-max: 1400px;
  --container-narrow: 900px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: var(--accent-purple-dark);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-purple);
}

a {
  color: var(--accent-purple-light);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: var(--accent-pink-light);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-heading);
  line-height: 1.3;
  font-weight: 700;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

/* ---------- Utility Classes ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.container-narrow {
  max-width: var(--container-narrow);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--accent-purple-light); }

.mt-1 { margin-top: var(--space-sm); }
.mt-2 { margin-top: var(--space-md); }
.mt-3 { margin-top: var(--space-lg); }
.mt-4 { margin-top: var(--space-xl); }
.mb-1 { margin-bottom: var(--space-sm); }
.mb-2 { margin-bottom: var(--space-md); }
.mb-3 { margin-bottom: var(--space-lg); }
.mb-4 { margin-bottom: var(--space-xl); }

.hidden { display: none !important; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

/* ---------- Navigation Bar ---------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  background: var(--bg-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border-color-light);
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-lg);
  transition: background var(--transition-normal);
}

.navbar.scrolled {
  background: rgba(26, 16, 37, 0.95);
  box-shadow: var(--shadow-md);
}

.navbar__logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-heading);
  text-decoration: none;
  flex-shrink: 0;
}

.navbar__logo img {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

.navbar__logo-icon {
  font-size: 1.5rem;
}

.navbar__right {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-shrink: 0;
}

/* 合并的认证按钮 */
.navbar__auth-btn {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 6px 16px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.navbar__auth-btn--login {
  background: var(--accent-gradient);
  color: #fff;
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.3);
}
.navbar__auth-btn--login:hover {
  background: var(--accent-gradient-hover);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.5);
  transform: translateY(-1px);
}
.navbar__auth-btn--login i {
  font-size: 0.85rem;
}

.navbar__auth-btn--user {
  background: rgba(168, 85, 247, 0.12);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}
.navbar__auth-btn--user:hover {
  background: rgba(168, 85, 247, 0.2);
  border-color: var(--accent-purple);
}

.navbar__auth-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.navbar__auth-name {
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.navbar__logout-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-size: 0.9rem;
}
.navbar__logout-btn:hover {
  color: var(--danger);
  border-color: var(--danger);
  background: rgba(239, 68, 68, 0.1);
}

/* 次级导航栏 */
.subnav {
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  height: 42px;
  background: rgba(26, 16, 37, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color-light);
  z-index: calc(var(--z-nav) - 1);
  display: flex;
  align-items: center;
  padding: 0 var(--space-lg);
  gap: var(--space-xs);
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.subnav::-webkit-scrollbar { display: none; }

.subnav__link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}
.subnav__link:hover,
.subnav__link.active {
  color: var(--text-heading);
  background: rgba(168, 85, 247, 0.15);
}
.subnav__link i {
  font-size: 0.8rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 10px 20px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-primary);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-normal);
  white-space: nowrap;
  text-decoration: none;
  line-height: 1.4;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--accent-gradient);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover:not(:disabled) {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--accent-purple-light);
  border: 1px solid var(--border-color);
}
.btn-secondary:hover:not(:disabled) {
  background: rgba(168, 85, 247, 0.1);
  border-color: var(--accent-purple);
}

.btn-highlight {
  background: linear-gradient(135deg, #ec4899, #f97316);
  color: #fff;
  box-shadow: 0 0 15px rgba(236, 72, 153, 0.3);
}
.btn-highlight:hover:not(:disabled) {
  background: linear-gradient(135deg, #f472b6, #fb923c);
  box-shadow: var(--shadow-glow-pink);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  padding: 8px 12px;
}
.btn-ghost:hover:not(:disabled) {
  color: var(--text-heading);
  background: rgba(255,255,255,0.05);
}

.btn-sm {
  padding: 6px 14px;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1.1rem;
}

.btn-icon {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: var(--radius-sm);
}

.btn-block {
  width: 100%;
}

/* ---------- Cards ---------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-normal);
  position: relative;
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-color);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.card__image {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: var(--bg-tertiary);
}

.card__body {
  padding: var(--space-md);
}

.card__title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
  color: var(--text-heading);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-bottom: var(--space-sm);
}

.card__tag {
  font-size: 0.75rem;
  padding: 2px 8px;
  background: rgba(168, 85, 247, 0.15);
  color: var(--accent-purple-light);
  border-radius: var(--radius-full);
}

.card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.card__price {
  color: var(--accent-pink);
  font-weight: 700;
  font-size: 1rem;
}

.card__meta-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.card__fav {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text-muted, #666);
  transition: all 0.2s;
  padding: 0;
  line-height: 1;
}

.card__fav--on, .card__fav:hover { color: #f59e0b; transform: scale(1.15); }
.card__fav--on { color: #f59e0b; }

/* Artwork Grid */
.artwork-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
}

/* ---------- Artwork Filter Bar ---------- */
.filter-bar {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-wrap: wrap;
  margin-bottom: var(--space-xl);
  padding: var(--space-md);
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color-light);
}

.tag-pills {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  flex: 1;
}

.tag-pill {
  padding: 6px 16px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  font-family: var(--font-primary);
}

.tag-pill:hover,
.tag-pill.active {
  background: var(--accent-gradient);
  color: #fff;
  border-color: transparent;
}

.search-input {
  position: relative;
  flex-shrink: 0;
}

.search-input input {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 8px 16px 8px 36px;
  color: var(--text-primary);
  font-size: 0.9rem;
  width: 240px;
  outline: none;
  font-family: var(--font-primary);
  transition: border-color var(--transition-fast);
}

.search-input input:focus {
  border-color: var(--accent-purple);
}

.search-input input::placeholder {
  color: var(--text-muted);
}

.search-input i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* ---------- Hero / Swiper ---------- */
.hero {
  margin-top: calc(var(--nav-height) + var(--subnav-height));
  position: relative;
  padding: var(--space-lg) var(--space-xl);
}

.hero .swiper {
  width: 100%;
  max-width: 960px;
  height: 480px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin: 0 auto;
  box-shadow: 0 4px 24px rgba(0,0,0,0.3);
}

.hero .swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero .swiper-pagination-bullet {
  background: rgba(255,255,255,0.5);
  opacity: 1;
}
.hero .swiper-pagination-bullet-active {
  background: var(--accent-purple);
  width: 24px;
  border-radius: 4px;
}

.hero-text {
  padding: var(--space-3xl) 0;
  text-align: center;
}

.hero-text__content {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: 800px;
  margin: 0 auto;
}

/* ---------- Modal ---------- */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  z-index: var(--z-modal-backdrop);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  width: 90%;
  max-width: 440px;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.9) translateY(20px);
  transition: transform var(--transition-normal);
  box-shadow: var(--shadow-lg);
}

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

.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid var(--border-color-light);
}

.modal__title {
  font-size: 1.25rem;
  font-weight: 700;
}

.modal__close {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all var(--transition-fast);
}

.modal__close:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text-primary);
}

.modal__body {
  padding: var(--space-xl);
}

.modal__footer {
  padding: var(--space-md) var(--space-xl) var(--space-xl);
}

/* ---------- Forms ---------- */
.form-group {
  margin-bottom: var(--space-md);
}

.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: var(--space-xs);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-primary);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--accent-purple);
  box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.15);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--text-muted);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-hint {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: var(--space-xs);
}

.form-row {
  display: flex;
  gap: var(--space-md);
}

.form-row .form-group {
  flex: 1;
}

.input-group {
  display: flex;
  gap: var(--space-sm);
}

.input-group .form-input {
  flex: 1;
}

/* Tabs */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color-light);
  margin-bottom: var(--space-lg);
}

.tab {
  flex: 1;
  padding: var(--space-sm) var(--space-md);
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  font-family: var(--font-primary);
  text-align: center;
}

.tab:hover {
  color: var(--text-secondary);
}

.tab.active {
  color: var(--accent-purple-light);
  border-bottom-color: var(--accent-purple);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* ---------- Rich Text Editor ---------- */
.rich-editor {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-tertiary);
}

.rich-editor__toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  padding: var(--space-sm);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color-light);
}

.rich-editor__btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.85rem;
  transition: all var(--transition-fast);
}

.rich-editor__btn:hover {
  background: rgba(168, 85, 247, 0.15);
  color: var(--text-heading);
}

.rich-editor__btn.active {
  background: var(--accent-purple);
  color: #fff;
}

.rich-editor__separator {
  width: 1px;
  background: var(--border-color);
  margin: 4px 4px;
}

.rich-editor__content {
  min-height: 200px;
  padding: var(--space-md);
  color: var(--text-primary);
  outline: none;
  line-height: 1.7;
}

.rich-editor__content:focus {
  background: rgba(168, 85, 247, 0.03);
}

.rich-editor__content img {
  max-width: 100%;
  border-radius: var(--radius-sm);
}

/* ---------- Toast Notifications ---------- */
.toast-container {
  position: fixed;
  top: calc(var(--nav-height) + var(--space-md));
  right: var(--space-lg);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  pointer-events: none;
}

.toast {
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.9rem;
  min-width: 280px;
  max-width: 400px;
  pointer-events: auto;
  animation: toastIn 0.3s ease forwards;
}

.toast.removing {
  animation: toastOut 0.3s ease forwards;
}

.toast--success { border-left: 3px solid var(--success); }
.toast--error   { border-left: 3px solid var(--error); }
.toast--warning { border-left: 3px solid var(--warning); }
.toast--info    { border-left: 3px solid var(--info); }

.toast__icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}
.toast--success .toast__icon { color: var(--success); }
.toast--error .toast__icon   { color: var(--error); }
.toast--warning .toast__icon { color: var(--warning); }
.toast--info .toast__icon    { color: var(--info); }

@keyframes toastIn {
  from { opacity: 0; transform: translateX(40px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes toastOut {
  from { opacity: 1; transform: translateX(0); }
  to   { opacity: 0; transform: translateX(40px); }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color-light);
  padding: var(--space-2xl) 0 var(--space-xl);
  margin-top: var(--space-3xl);
}

.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-xl);
  flex-wrap: wrap;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: var(--space-sm);
}

.footer__desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 300px;
  line-height: 1.6;
}

.footer__links {
  display: flex;
  gap: var(--space-2xl);
}

.footer__col h4 {
  font-size: 0.95rem;
  margin-bottom: var(--space-md);
  color: var(--text-heading);
}

.footer__col a {
  display: block;
  color: var(--text-muted);
  font-size: 0.9rem;
  padding: var(--space-xs) 0;
  transition: color var(--transition-fast);
}

.footer__col a:hover {
  color: var(--accent-purple-light);
}

.footer__bottom {
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-color-light);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.8rem;
}

.footer__icp {
  margin-top: var(--space-sm);
}

.footer__icp a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.footer__icp a:hover {
  color: var(--accent-primary, #a855f7);
  text-decoration: underline;
}

.footer__copyright {
  margin-top: var(--space-sm);
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* ---------- Page Content ---------- */
.page-content {
  margin-top: calc(var(--nav-height) + var(--subnav-height));
  padding: var(--space-3xl) 0;
  min-height: calc(100vh - var(--nav-height));
}

.page-content h1,
.page-content h2,
.page-content h3 {
  margin: var(--space-lg) 0 var(--space-md);
}

.page-content p {
  margin-bottom: var(--space-md);
  line-height: 1.8;
}

.page-content img {
  border-radius: var(--radius-md);
  margin: var(--space-md) 0;
}

.page-content ul,
.page-content ol {
  padding-left: var(--space-xl);
  margin-bottom: var(--space-md);
}

.page-content li {
  margin-bottom: var(--space-xs);
  list-style: disc;
}

/* ---------- Profile Page ---------- */
.profile-header {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  padding: var(--space-xl);
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-color-light);
  margin-bottom: var(--space-xl);
}

.profile-avatar {
  width: 100px;
  height: 100px;
  border-radius: var(--radius-full);
  border: 3px solid var(--accent-purple);
  object-fit: cover;
  flex-shrink: 0;
}

.profile-info h2 {
  margin-bottom: var(--space-xs);
}

.profile-uid {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color-light);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  text-align: center;
  transition: all var(--transition-normal);
}

.stat-card:hover {
  border-color: var(--border-color);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.stat-card__value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-purple-light);
  margin-bottom: var(--space-xs);
}

.stat-card__label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---------- Points Shop ---------- */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--space-lg);
}

.shop-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-normal);
}

.shop-item:hover {
  border-color: var(--border-color);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.shop-item__image {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--bg-tertiary);
}

.shop-item__body {
  padding: var(--space-md);
}

.shop-item__name {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.shop-item__desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: var(--space-sm);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shop-item__footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.shop-item__cost {
  color: var(--accent-pink);
  font-weight: 700;
}

.shop-item__stock {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Side Panel (user menu) */
.side-panel {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 280px;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-color);
  z-index: var(--z-modal);
  transform: translateX(-100%);
  transition: transform var(--transition-normal);
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.side-panel.active {
  transform: translateX(0);
}

.side-panel__header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-xl) var(--space-lg);
  border-bottom: 1px solid var(--border-color-light);
}

.side-panel__avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  border: 2px solid var(--accent-purple);
  object-fit: cover;
}

.side-panel__name {
  font-weight: 600;
  color: var(--text-heading);
}

.side-panel__overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: calc(var(--z-modal) - 1);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

.side-panel__overlay.active {
  opacity: 1;
  visibility: visible;
}

.side-panel__nav {
  padding: var(--space-md) 0;
}

.side-panel__link {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  color: var(--text-secondary);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.side-panel__link:hover,
.side-panel__link.active {
  color: var(--accent-purple-light);
  background: rgba(168, 85, 247, 0.08);
}

.side-panel__link i {
  width: 20px;
  text-align: center;
  font-size: 1rem;
}

.side-panel__close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-left: auto;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.side-panel__close:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text-primary);
}

/* Side Panel - Expandable Groups */
.side-panel__group .side-panel__subnav {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}

.side-panel__group.expanded .side-panel__subnav {
  max-height: 400px;
}

.side-panel__grouplink {
  position: relative;
}

.side-panel__arrow {
  margin-left: auto;
  font-size: 0.7rem;
  transition: transform 0.25s ease;
}

.side-panel__group.expanded .side-panel__arrow {
  transform: rotate(90deg);
}

.side-panel__sublink {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-sm) var(--space-lg) var(--space-sm) 52px;
  color: var(--text-muted);
  font-size: 0.88rem;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.side-panel__sublink:hover,
.side-panel__sublink.active {
  color: var(--accent-purple-light);
  background: rgba(168, 85, 247, 0.06);
}

.side-panel__sublink i {
  width: 16px;
  text-align: center;
  font-size: 0.85rem;
}

/* ---------- Loading ---------- */
.loading-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 2px solid var(--border-color);
  border-top-color: var(--accent-purple);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

.loading-spinner--lg {
  width: 40px;
  height: 40px;
  border-width: 3px;
}

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

.page-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 300px;
}

/* ---------- Empty State ---------- */
.empty-state {
  text-align: center;
  padding: var(--space-3xl);
  color: var(--text-muted);
}

.empty-state i {
  font-size: 3rem;
  margin-bottom: var(--space-md);
  opacity: 0.5;
}

.empty-state p {
  font-size: 1.1rem;
}

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-top: var(--space-xl);
  flex-wrap: wrap;
}

.pagination__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border-color, rgba(255,255,255,0.1));
  border-radius: 8px;
  background: var(--bg-secondary, #1a1025);
  color: var(--text-primary, #e2e8f0);
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
}

.pagination__btn:hover:not(:disabled) {
  background: var(--accent-primary, #a855f7);
  border-color: var(--accent-primary, #a855f7);
  color: #fff;
}

.pagination__btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.pagination__btn--active {
  background: var(--accent-primary, #a855f7);
  border-color: var(--accent-primary, #a855f7);
  color: #fff;
  font-weight: 600;
}

.pagination__ellipsis {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  color: var(--text-muted, #94a3b8);
  font-size: 0.9rem;
  user-select: none;
}

/* ---------- Section Title ---------- */
.section-title {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.section-title h2 {
  margin-bottom: var(--space-sm);
}

.section-title p {
  color: var(--text-muted);
  font-size: 1rem;
}

/* ---------- AOS overrides ---------- */
[data-aos] {
  pointer-events: none;
}
[data-aos].aos-animate {
  pointer-events: auto;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .artwork-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer__links {
    gap: var(--space-xl);
  }

  .hero {
    padding: var(--space-md) var(--space-md);
  }
  .hero .swiper {
    height: 360px;
  }

  .stats-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 56px;
    --subnav-height: 38px;
  }

  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.5rem; }

  .container {
    padding: 0 var(--space-md);
  }

  .navbar__auth-name {
    display: none;
  }

  .subnav {
    padding: 0 var(--space-md);
  }

  .artwork-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .hero {
    padding: var(--space-sm) var(--space-sm);
  }
  .hero .swiper {
    height: 220px;
    border-radius: var(--radius-lg);
  }

  .hero-text {
    padding: var(--space-xl) 0;
  }

  .filter-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .search-input input {
    width: 100%;
  }

  .modal {
    width: 95%;
    max-height: 85vh;
  }

  .profile-header {
    flex-direction: column;
    text-align: center;
    padding: var(--space-lg);
  }

  .footer__inner {
    flex-direction: column;
    gap: var(--space-xl);
  }

  .footer__links {
    flex-direction: column;
    gap: var(--space-lg);
  }

  .shop-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    flex-direction: column;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .side-panel {
    width: 260px;
  }

  .rich-editor__toolbar {
    gap: 1px;
  }

  .rich-editor__btn {
    width: 28px;
    height: 28px;
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}
