/* ============================================================
   灵感工坊 · AI 作品实验场
   Global stylesheet
   ============================================================ */
:root {
  --bg: #0a0e1a;
  --bg-soft: #111827;
  --bg-card: rgba(17, 24, 39, 0.72);
  --panel: rgba(13, 18, 32, 0.86);
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(96, 165, 250, 0.45);
  --text: #e5e7eb;
  --text-muted: #9ca3af;
  --accent: #38bdf8;
  --accent-2: #a78bfa;
  --accent-3: #f472b6;
  --gold: #fbbf24;
  --ok: #34d399;
  --radius: 18px;
  --max-width: 1180px;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --font-sans: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC",
    "Source Han Sans SC", system-ui, -apple-system, sans-serif;
  --font-serif: "Noto Serif CJK SC", "Songti SC", "SimSun", serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 800px at 85% -10%, rgba(120, 80, 220, 0.18), transparent 60%),
    radial-gradient(1000px 700px at -10% 20%, rgba(14, 165, 233, 0.14), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #7dd3fc;
}

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

.container {
  width: min(var(--max-width), 92%);
  margin-inline: auto;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 14, 26, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 1px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #05101f;
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  gap: 6px;
  align-items: center;
}

.nav-links a {
  color: var(--text-muted);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
  background: rgba(56, 189, 248, 0.12);
}

.nav-cta {
  margin-left: 8px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #04101f !important;
  font-weight: 700;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  color: var(--text);
  width: 42px;
  height: 42px;
  border-radius: 10px;
  font-size: 1.2rem;
  cursor: pointer;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 12px;
  border: 1px solid var(--line-strong);
  background: rgba(56, 189, 248, 0.1);
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(56, 189, 248, 0.22);
  color: var(--text);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border: none;
  color: #04101f;
}

.btn-primary:hover {
  color: #04101f;
  box-shadow: 0 10px 30px rgba(139, 92, 246, 0.35);
}

.btn-ghost {
  background: transparent;
  border-color: var(--line);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 110px 0 90px;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, transparent 0%, rgba(56, 189, 248, 0.08) 45%, transparent 70%),
    radial-gradient(900px 460px at 70% 120%, rgba(167, 139, 250, 0.16), transparent 65%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  position: relative;
}

.hero-kicker {
  display: inline-block;
  font-size: 0.9rem;
  letter-spacing: 2px;
  color: var(--accent);
  border: 1px solid var(--line-strong);
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.06);
  margin-bottom: 22px;
}

.hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1.18;
  margin: 0 0 20px;
  background: linear-gradient(120deg, #f8fafc 0%, #7dd3fc 45%, #c4b5fd 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p.lead {
  font-size: 1.14rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 0 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 34px;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.hero-visual {
  position: relative;
}

.hero-visual .scroll-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: #0b1020;
  aspect-ratio: 4 / 3;
}

.hero-visual canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.hero-visual .scroll-card figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 44px 18px 14px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.82));
  font-size: 0.88rem;
  color: #cbd5e1;
}

.hero-visual .placeholder-visual {
  display: grid;
  place-items: center;
  text-align: center;
  padding: 40px 24px;
  aspect-ratio: 4 / 3;
  background:
    radial-gradient(120% 120% at 20% 10%, rgba(30, 58, 138, 0.55) 0%, rgba(11, 16, 32, 0.9) 50%),
    repeating-linear-gradient(45deg, rgba(148, 163, 184, 0.06) 0 8px, transparent 8px 16px);
}

.placeholder-inner {
  max-width: 320px;
}

.placeholder-icon {
  font-size: 3rem;
  margin-bottom: 10px;
  filter: drop-shadow(0 0 18px rgba(167, 139, 250, 0.4));
}

.placeholder-inner p {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  margin: 0 0 10px;
}

.placeholder-inner span {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.placeholder-inner code {
  background: rgba(148, 163, 184, 0.14);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 2px 6px;
}

/* ---------- Sections ---------- */
.section {
  padding: 84px 0;
}

.section-alt {
  background: rgba(17, 24, 39, 0.42);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-head {
  margin-bottom: 42px;
  max-width: 760px;
}

.section-head .eyebrow {
  color: var(--accent);
  letter-spacing: 3px;
  font-size: 0.86rem;
  text-transform: uppercase;
}

.section-head h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  margin: 8px 0 12px;
}

.section-head p {
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 22px;
}

.card {
  display: block;
  position: relative;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--bg-card);
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-6px);
  border-color: var(--line-strong);
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.45);
  color: var(--text);
}

.card-thumb {
  aspect-ratio: 16 / 10;
  position: relative;
  overflow: hidden;
  background: #0d1424;
}

.card-thumb .thumb-art {
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 120% at 20% 10%, #1e3a8a 0%, #0f172a 45%, #312e81 100%);
}

.card-thumb .thumb-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(148, 163, 184, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.08) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.6;
}

.card-thumb .thumb-label {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 0.78rem;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(10, 14, 26, 0.72);
  color: #e2e8f0;
  border: 1px solid var(--line);
  backdrop-filter: blur(6px);
}

.card-thumb .status-badge {
  position: absolute;
  top: 12px;
  right: 12px;
}

.card-body {
  padding: 18px 20px 22px;
}

.card-body h3 {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.card-body p {
  margin: 0 0 14px;
  color: var(--text-muted);
  font-size: 0.94rem;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.92rem;
  font-weight: 600;
}

/* Art variants for placeholder cards */
.art-neon { background: radial-gradient(130% 130% at 85% 15%, #701a75 0%, #0f172a 55%, #164e63 100%); }
.art-gods { background: radial-gradient(130% 130% at 20% 80%, #b45309 0%, #111827 55%, #1e3a8a 100%); }
.art-fish { background: radial-gradient(130% 130% at 10% 20%, #0e7490 0%, #082f49 55%, #1e1b4b 100%); }
.art-ink { background: radial-gradient(130% 130% at 50% 90%, #334155 0%, #0f172a 60%, #172554 100%); }
.art-city { background: radial-gradient(130% 130% at 80% 80%, #7c3aed 0%, #0f172a 55%, #0c4a6e 100%); }

/* ---------- Feature / Info ---------- */
.feature-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
  margin-top: 10px;
}

.feature {
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--bg-card);
}

.feature .icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  margin-bottom: 16px;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid var(--line-strong);
}

.feature h3 {
  margin: 0 0 8px;
  font-size: 1.08rem;
}

.feature p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(7, 10, 18, 0.72);
  padding: 40px 0 28px;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 28px;
}

.footer-grid h4 {
  margin: 0 0 12px;
  font-size: 1rem;
}

.footer-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.93rem;
}

.footer-brand p {
  color: var(--text-muted);
  margin: 10px 0 0;
  max-width: 380px;
  font-size: 0.95rem;
}

.footer-beian {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.footer-beian a {
  color: var(--text-muted);
  margin-left: 12px;
}

.footer-beian a:hover {
  color: var(--text);
}

/* ---------- Work page ---------- */
.work-hero {
  padding: 70px 0 40px;
}

.work-hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 3.2rem);
  margin: 8px 0 14px;
}

.breadcrumb {
  color: var(--text-muted);
  font-size: 0.92rem;
}

.breadcrumb a {
  color: var(--text-muted);
}

.breadcrumb a:hover {
  color: var(--text);
}

.canvas-frame {
  margin: 30px 0;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #050810;
}

.canvas-frame canvas {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  background: #050810;
}

.canvas-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-top: 1px solid var(--line);
  background: rgba(13, 18, 32, 0.9);
}

.canvas-toolbar .hint {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.canvas-toolbar .btn {
  padding: 9px 16px;
  font-size: 0.9rem;
}

.work-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin: 26px 0 34px;
}

.meta-item {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg-card);
  padding: 16px 18px;
}

.meta-item .label {
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.meta-item .value {
  font-size: 1.02rem;
  margin-top: 6px;
  font-weight: 600;
}

.prose {
  color: #d1d5db;
  font-size: 1rem;
}

.prose h2 {
  font-family: var(--font-serif);
  color: var(--text);
  margin: 36px 0 12px;
  font-size: 1.6rem;
}

.prose h3 {
  color: var(--text);
  margin: 28px 0 8px;
}

.prose p {
  margin: 12px 0;
}

.prose code {
  background: rgba(148, 163, 184, 0.12);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 2px 7px;
  font-size: 0.9em;
}

.prose ul {
  padding-left: 1.2rem;
}

.prompt-box {
  border-left: 3px solid var(--accent-2);
  background: rgba(167, 139, 250, 0.08);
  border-radius: 0 14px 14px 0;
  padding: 18px 22px;
  margin: 22px 0;
  color: #e2e8f0;
  font-style: italic;
}

/* ---------- Gallery filters ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.filter-btn {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.92rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-btn:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.filter-btn.active {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-color: transparent;
  color: #04101f;
  font-weight: 700;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
}

/* ---------- Work detail ---------- */
.work-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-top: 24px;
}

.status-badge {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  border: 1px solid var(--line);
  background: rgba(148, 163, 184, 0.12);
  color: var(--text-muted);
  white-space: nowrap;
}

.status-online {
  background: rgba(52, 211, 153, 0.14);
  border-color: rgba(52, 211, 153, 0.45);
  color: #6ee7b7;
}

.status-pending {
  background: rgba(251, 191, 36, 0.12);
  border-color: rgba(251, 191, 36, 0.45);
  color: #fde68a;
}

.status-maintenance {
  background: rgba(244, 114, 182, 0.12);
  border-color: rgba(244, 114, 182, 0.45);
  color: #f9a8d4;
}

.preview-placeholder {
  min-height: 240px;
  display: grid;
  place-content: center;
  text-align: center;
  gap: 8px;
  padding: 36px 20px;
  color: var(--text-muted);
}

.preview-placeholder p {
  font-size: 1.15rem;
  color: var(--text);
  margin: 0;
}

.preview-placeholder code {
  background: rgba(148, 163, 184, 0.14);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 2px 7px;
}

/* ---------- Page hero (gallery/about) ---------- */
.page-hero {
  padding: 80px 0 50px;
}

.page-hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  margin: 8px 0 16px;
}

.page-hero p {
  color: var(--text-muted);
  max-width: 720px;
  font-size: 1.06rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: rgba(10, 14, 26, 0.96);
    border-bottom: 1px solid var(--line);
    padding: 14px 4%;
    gap: 4px;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    border-radius: 10px;
  }

  .nav-toggle {
    display: inline-grid;
    place-items: center;
  }
}

@media (max-width: 560px) {
  .section {
    padding: 56px 0;
  }

  .hero {
    padding: 70px 0 56px;
  }

  .footer-beian {
    flex-direction: column;
  }
}

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.muted { color: var(--text-muted); }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 34px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 34px; }
.gap-2 { gap: 14px; }
/* Cover images in cards and hero */
.card-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-visual .scroll-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}