
/* Prevent the browser from drawing a large focus rectangle around the whole page. */
html {
  -webkit-tap-highlight-color: transparent;
}

#app,
#app:focus,
#app:focus-visible {
  outline: none;
}

:root {
  --background: #050308;
  --background-soft: #0b0710;
  --surface: rgba(20, 12, 29, 0.74);
  --surface-strong: rgba(30, 16, 43, 0.92);
  --surface-hover: rgba(39, 20, 56, 0.95);
  --purple: #a855f7;
  --purple-bright: #c084fc;
  --purple-light: #e9d5ff;
  --purple-dark: #581c87;
  --pink: #ec4899;
  --text: #f8f4fc;
  --muted: #aaa0b5;
  --muted-strong: #c9c0d0;
  --border: rgba(216, 180, 254, 0.16);
  --border-strong: rgba(216, 180, 254, 0.36);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  --radius-large: 26px;
  --radius-medium: 18px;
  --content-width: 1500px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; color-scheme: dark; }
body {
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--text);
  background: var(--background);
  font-family: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Noto Sans SC", "Noto Sans JP", Arial, sans-serif;
  line-height: 1.5;
  font-kerning: normal;
  font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
  text-rendering: optimizeLegibility;
}
body::selection { background: rgba(168, 85, 247, 0.35); color: white; }
a { color: inherit; text-decoration: none; }
button, select { font: inherit; }
img, video, iframe { max-width: 100%; }

h1, h2, h3, h4, .brand-copy strong, .button {
  font-family: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Noto Sans SC", "Noto Sans JP", Arial, sans-serif;
  font-kerning: normal;
  font-feature-settings: "kern" 1, "liga" 1;
  text-rendering: optimizeLegibility;
}

.ambient { position: fixed; z-index: -3; border-radius: 999px; filter: blur(110px); pointer-events: none; }
.ambient-a { width: 480px; height: 480px; left: -160px; top: -120px; background: rgba(126, 34, 206, 0.28); }
.ambient-b { width: 520px; height: 520px; right: -220px; top: 28vh; background: rgba(192, 38, 211, 0.18); }
.grid-overlay {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.95), transparent 92%);
}

.site-header { position: sticky; top: 0; z-index: 100; background: rgba(5, 3, 8, 0.64); border-bottom: 1px solid rgba(255,255,255,.045); backdrop-filter: blur(22px); }
.nav-shell { width: min(var(--content-width), calc(100% - 64px)); min-height: 78px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.devil-mark { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 13px; background: linear-gradient(135deg, var(--purple), var(--pink)); border: 1px solid rgba(255,255,255,.2); box-shadow: 0 0 34px rgba(168,85,247,.32); animation: float 3.5s ease-in-out infinite; }
.brand-copy { display: grid; gap: 2px; }
.brand-copy strong { font-size: 15px; letter-spacing: .08em; }
.brand-copy small { color: var(--muted); font-size: 10px; letter-spacing: .055em; }
.nav-panel { display: flex; align-items: center; justify-content: flex-end; gap: 24px; min-width: 0; }
.nav-links { display: flex; align-items: center; justify-content: flex-end; gap: 5px; flex-wrap: wrap; }
.nav-link { padding: 9px 11px; color: var(--muted); border-radius: 10px; font-size: 13px; transition: .22s ease; }
.nav-link:hover, .nav-link.active { color: var(--purple-light); background: rgba(168,85,247,.09); }
.language-control { display: inline-flex; align-items: center; gap: 8px; padding: 6px 8px 6px 10px; color: var(--purple-light); background: rgba(168,85,247,.08); border: 1px solid var(--border); border-radius: 11px; font-size: 12px; }
.language-control select { color: var(--text); background: transparent; border: 0; outline: 0; cursor: pointer; }
.language-control option { background: #120b19; }
.menu-button { display: none; width: 42px; height: 42px; color: var(--text); background: rgba(255,255,255,.04); border: 1px solid var(--border); border-radius: 12px; cursor: pointer; }

#app { width: min(var(--content-width), calc(100% - 64px)); min-height: calc(100vh - 160px); margin: 0 auto; }
.loading-state, .error-state, .empty-state { min-height: 62vh; display: grid; place-content: center; justify-items: center; gap: 16px; color: var(--muted); text-align: center; }
.loading-devil { font-size: 46px; animation: float 2s ease-in-out infinite; }
.error-state h1 { color: var(--text); font-size: clamp(36px, 6vw, 70px); line-height: 1.16; letter-spacing: -.02em; font-weight: 750; }

.hero { min-height: calc(100vh - 78px); padding: 92px 0 76px; display: grid; align-content: center; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .55fr); gap: 72px; align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; width: fit-content; margin-bottom: 24px; padding: 9px 14px; color: var(--purple-light); background: rgba(168,85,247,.08); border: 1px solid var(--border); border-radius: 999px; font-size: 12px; letter-spacing: .09em; text-transform: uppercase; }
.status-dot { width: 7px; height: 7px; background: var(--purple-light); border-radius: 50%; box-shadow: 0 0 14px var(--purple); animation: pulse 2s ease-in-out infinite; }
.hero h1 {
  max-width: 980px;
  font-size: clamp(54px, 7.2vw, 102px);
  line-height: 1.2;
  letter-spacing: -.025em;
  font-weight: 750;
  text-wrap: balance;
  overflow: visible;
}
.hero-title-lead,
.hero-title-highlight {
  display: block;
}
.hero-title-highlight {
  margin-top: .035em;
  padding-bottom: .1em;
  line-height: 1.2;
}
html[lang="zh-CN"] .hero h1, html[lang="ja"] .hero h1 { line-height: 1.24; letter-spacing: -.015em; }
.gradient-text { color: transparent; background: linear-gradient(100deg, #fff 0%, #e9d5ff 38%, #a855f7 72%, #ec4899 100%); background-clip: text; -webkit-background-clip: text; }
.hero-description { max-width: 720px; margin-top: 30px; color: var(--muted); font-size: clamp(17px, 1.9vw, 21px); line-height: 1.75; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 13px; margin-top: 36px; }
.button { appearance: none; color: var(--text); display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 48px; padding: 0 20px; border: 1px solid var(--border); border-radius: 13px; font-size: 14px; font-weight: 680; cursor: pointer; transition: transform .22s ease, background .22s ease, border-color .22s ease; }
.button:hover { transform: translateY(-3px); border-color: var(--border-strong); }
.button-primary { background: linear-gradient(135deg, #7e22ce, #a855f7); border-color: rgba(216,180,254,.34); box-shadow: 0 16px 50px rgba(126,34,206,.28); }
.button-secondary { background: rgba(255,255,255,.035); }
.hero-orb { position: relative; width: min(100%, 330px); aspect-ratio: 1; margin-inline: auto; display: grid; place-items: center; }
.hero-orb::before, .hero-orb::after { content: ""; position: absolute; inset: 10%; border: 1px solid rgba(216,180,254,.18); border-radius: 50%; animation: spin 18s linear infinite; }
.hero-orb::after { inset: 24%; border-style: dashed; animation-direction: reverse; animation-duration: 13s; }
.orb-core { position: relative; display: grid; place-items: center; width: 48%; aspect-ratio: 1; border-radius: 32%; background: radial-gradient(circle at 30% 25%, #d8b4fe, #7e22ce 48%, #160a22 78%); box-shadow: 0 0 100px rgba(168,85,247,.48); transform: rotate(14deg); }
.orb-core span { font-size: clamp(50px, 7vw, 86px); transform: rotate(-14deg); filter: drop-shadow(0 12px 22px rgba(0,0,0,.34)); }

.section { padding: 92px 0; scroll-margin-top: 96px; }
.section-heading { margin-bottom: 38px; }
.section-label { margin-bottom: 11px; color: var(--purple-light); font-size: 12px; font-weight: 750; letter-spacing: .16em; text-transform: uppercase; }
.section-heading h2 {
  max-width: 850px;
  font-size: clamp(38px, 5.2vw, 64px);
  line-height: 1.16;
  letter-spacing: -.022em;
  font-weight: 750;
  text-wrap: balance;
  overflow: visible;
}
.page-header h1 {
  max-width: 980px;
  font-size: clamp(38px, 5.2vw, 64px);
  line-height: 1.16;
  letter-spacing: -.022em;
  font-weight: 750;
  text-wrap: balance;
  overflow: visible;
}
.section-heading p:last-child, .page-header-description { max-width: 740px; margin-top: 18px; color: var(--muted); font-size: 17px; line-height: 1.75; }

.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.card-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.feature-card, .content-card, .category-card { position: relative; overflow: hidden; min-height: 340px; display: flex; flex-direction: column; justify-content: flex-end; background: linear-gradient(145deg, rgba(168,85,247,.11), rgba(8,5,12,.94)); border: 1px solid var(--border); border-radius: var(--radius-large); box-shadow: 0 18px 70px rgba(0,0,0,.18); transition: transform .32s ease, border-color .32s ease, background .32s ease; }
.feature-card:hover, .content-card:hover, .category-card:hover { transform: translateY(-7px); border-color: var(--border-strong); background: linear-gradient(145deg, rgba(168,85,247,.17), rgba(8,5,12,.96)); }
.card-cover { position: absolute; inset: 0 0 33% 0; width: 100%; height: 67%; object-fit: cover; opacity: .68; transition: transform .55s ease, opacity .4s ease; mask-image: linear-gradient(to bottom, #000 45%, transparent 100%); -webkit-mask-image: linear-gradient(to bottom, #000 45%, transparent 100%); }
.feature-card:hover .card-cover, .content-card:hover .card-cover, .category-card:hover .card-cover { transform: scale(1.045); opacity: .9; }
.card-glow { position: absolute; top: -80px; right: -80px; width: 230px; height: 230px; border-radius: 50%; background: var(--card-accent, #7e22ce); filter: blur(96px); opacity: .25; }
.card-body { position: relative; z-index: 2; padding: 30px; }
.card-topline { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 70px; }
.card-icon { font-size: 34px; filter: drop-shadow(0 0 18px rgba(168,85,247,.5)); }
.card-number { color: rgba(255,255,255,.3); font: 12px ui-monospace, SFMono-Regular, Menlo, monospace; }
.card-body h3 { margin-bottom: 11px; font-size: clamp(24px, 3vw, 31px); line-height: 1.24; letter-spacing: -.012em; font-weight: 700; text-wrap: balance; }
.card-body p { color: var(--muted); line-height: 1.65; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag { padding: 7px 10px; color: var(--purple-light); background: rgba(168,85,247,.08); border: 1px solid rgba(216,180,254,.12); border-radius: 999px; font-size: 11px; }
.card-arrow { display: inline-flex; margin-top: 19px; color: var(--purple-light); font-size: 13px; font-weight: 700; }

.page-header { padding: 92px 0 46px; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; color: var(--muted); font-size: 13px; }
.breadcrumbs a:hover { color: var(--purple-light); }
.breadcrumbs span:not(:last-child)::after { content: "/"; margin-left: 8px; color: rgba(255,255,255,.2); }
.page-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.content-card { min-height: 390px; }
.content-card .card-cover { inset-bottom: 42%; height: 65%; }
.content-card .card-body { padding-top: 150px; }
.content-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 12px; color: var(--muted); font-size: 12px; }

.detail-header { padding: 70px 0 34px; }
.detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 44px; align-items: start; }
.detail-title { font-size: clamp(44px, 7vw, 84px); line-height: 1.14; letter-spacing: -.024em; font-weight: 750; text-wrap: balance; overflow: visible; }
.detail-summary { max-width: 780px; margin-top: 22px; color: var(--muted); font-size: 19px; line-height: 1.72; }
.detail-cover { width: 100%; max-height: 680px; object-fit: cover; margin-top: 34px; border: 1px solid var(--border); border-radius: var(--radius-large); box-shadow: var(--shadow); }
.detail-sidebar { position: sticky; top: 104px; padding: 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-medium); }
.detail-sidebar h3 { margin-bottom: 14px; font-size: 13px; color: var(--purple-light); letter-spacing: .12em; text-transform: uppercase; }
.detail-facts { display: grid; gap: 13px; }
.detail-fact { display: grid; gap: 4px; padding-bottom: 13px; border-bottom: 1px solid rgba(255,255,255,.06); }
.detail-fact:last-child { border-bottom: 0; padding-bottom: 0; }
.detail-fact small { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.detail-fact span { color: var(--muted-strong); font-size: 14px; overflow-wrap: anywhere; }

.detail-section { padding: 56px 0; border-top: 1px solid rgba(255,255,255,.06); }
.detail-section h2 { margin-bottom: 24px; font-size: clamp(29px, 4vw, 44px); line-height: 1.22; letter-spacing: -.016em; font-weight: 720; text-wrap: balance; }
.prose { max-width: 850px; color: var(--muted-strong); font-size: 17px; line-height: 1.85; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--text); line-height: 1.3; letter-spacing: -.008em; font-weight: 700; text-wrap: balance; overflow: visible; }
.prose h1 { margin: 1.6em 0 .7em; font-size: 2.2em; }
.prose h2 { margin: 1.55em 0 .65em; font-size: 1.75em; }
.prose h3 { margin: 1.4em 0 .6em; font-size: 1.3em; }
.prose p { margin: 0 0 1.15em; }
.prose ul, .prose ol { margin: 0 0 1.2em 1.5em; }
.prose blockquote { margin: 1.3em 0; padding: 18px 20px; color: var(--purple-light); background: rgba(168,85,247,.07); border-left: 3px solid var(--purple); border-radius: 0 12px 12px 0; }
.prose a { color: var(--purple-light); text-decoration: underline; text-decoration-color: rgba(216,180,254,.35); text-underline-offset: 3px; }
.prose code { padding: .15em .38em; color: #ead7ff; background: rgba(168,85,247,.09); border: 1px solid rgba(216,180,254,.1); border-radius: 6px; font: .88em ui-monospace, SFMono-Regular, Menlo, monospace; }
.prose pre { overflow: auto; margin: 1.3em 0; padding: 20px; background: #08050c; border: 1px solid var(--border); border-radius: 15px; }
.prose pre code { padding: 0; background: transparent; border: 0; }

.gallery-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 15px; }
.gallery-button { position: relative; overflow: hidden; padding: 0; border: 1px solid var(--border); border-radius: 18px; background: var(--surface); cursor: zoom-in; aspect-ratio: 4 / 3; }
.gallery-button img { width: 100%; height: 100%; display: block; object-fit: cover; transition: transform .45s ease; }
.gallery-button:hover img { transform: scale(1.04); }

.video-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.video-card { overflow: hidden; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; }
.video-frame { width: 100%; aspect-ratio: 16/9; display: block; border: 0; background: #000; }
.video-caption { display: flex; justify-content: space-between; gap: 18px; align-items: center; padding: 15px 17px; }
.video-caption strong { font-size: 14px; }
.source-link { flex-shrink: 0; color: var(--purple-light); font-size: 12px; font-weight: 700; }
.video-fallback { min-height: 220px; display: grid; place-content: center; gap: 12px; padding: 24px; text-align: center; color: var(--muted); }

.link-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.external-link-card { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px; background: rgba(255,255,255,.025); border: 1px solid var(--border); border-radius: 15px; transition: .22s ease; }
.external-link-card:hover { transform: translateY(-3px); border-color: var(--border-strong); background: rgba(168,85,247,.06); }
.external-link-card small { color: var(--muted); }

.code-list { display: grid; gap: 14px; }
.code-block { overflow: hidden; background: #08050c; border: 1px solid var(--border); border-radius: 16px; }
.code-block summary { padding: 15px 18px; color: var(--purple-light); cursor: pointer; font: 13px ui-monospace, SFMono-Regular, Menlo, monospace; }
.code-block pre { overflow: auto; max-height: 620px; padding: 20px; border-top: 1px solid rgba(255,255,255,.06); }
.code-block code { color: #d8cde2; font: 12.5px/1.7 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre; }

.lightbox { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 70px 30px 30px; color: white; background: rgba(4,2,7,.94); border: 0; backdrop-filter: blur(20px); }
.lightbox::backdrop { background: rgba(0,0,0,.6); }
.lightbox[open] { display: grid; place-items: center; align-content: center; gap: 14px; }
.lightbox img { max-width: min(1300px, 92vw); max-height: 78vh; object-fit: contain; border-radius: 14px; }
.lightbox p { color: var(--muted); }
.lightbox-close { position: fixed; top: 24px; right: 28px; width: 44px; height: 44px; color: white; background: rgba(255,255,255,.08); border: 1px solid var(--border); border-radius: 50%; font-size: 28px; cursor: pointer; }

.site-footer { margin-top: 80px; border-top: 1px solid var(--border); }
.footer-inner { width: min(var(--content-width), calc(100% - 64px)); margin: 0 auto; padding: 34px 0 46px; display: flex; justify-content: space-between; gap: 24px; color: var(--muted); font-size: 13px; }

@keyframes float { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-5px) rotate(3deg); } }
@keyframes pulse { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 980px) {
  .hero-grid, .detail-layout { grid-template-columns: 1fr; }
  .hero-orb { width: min(58vw, 300px); }
  .detail-sidebar { position: static; }
  .card-grid.three, .gallery-grid, .link-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

@media (max-width: 820px) {
  .menu-button { display: inline-grid; place-items: center; }
  .nav-panel { position: absolute; left: 20px; right: 20px; top: 70px; display: none; align-items: stretch; padding: 16px; background: rgba(12,7,17,.97); border: 1px solid var(--border); border-radius: 16px; box-shadow: var(--shadow); }
  .nav-panel.open { display: grid; }
  .nav-links { display: grid; justify-content: stretch; }
  .nav-link { padding: 12px; }
  .language-control { justify-content: space-between; }
  .card-grid, .card-grid.three, .video-grid { grid-template-columns: 1fr; }
  .hero { min-height: auto; padding-top: 110px; }
  .hero h1 { font-size: clamp(48px, 13vw, 76px); line-height: 1.2; letter-spacing: -.02em; }
  .page-header h1, .section-heading h2 { line-height: 1.18; letter-spacing: -.016em; }
  .detail-title { line-height: 1.16; letter-spacing: -.018em; }
}

@media (max-width: 560px) {
  #app, .nav-shell, .footer-inner { width: min(100% - 28px, var(--content-width)); }
  .brand-copy small { display: none; }
  .section, .page-header { padding-top: 70px; }
  .feature-card, .content-card, .category-card { min-height: 320px; }
  .gallery-grid, .link-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; }
  .video-caption { align-items: flex-start; flex-direction: column; }
}
