@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500&family=Noto+Serif+SC:wght@400;600;700&display=swap');

:root {
  --background: 0 0% 5%;
  --foreground: 0 0% 100%;
  --text: 0 0% 96%;
  --card: 0 0% 10%;
  --card-foreground: 0 0% 96%;
  --popover: 0 0% 5%;
  --popover-foreground: 0 0% 96%;
  --primary: 39 46% 61%;
  --primary-foreground: 0 0% 0%;
  --secondary: 0 0% 10%;
  --secondary-foreground: 0 0% 100%;
  --muted: 0 0% 10%;
  --muted-foreground: 0 0% 66%;
  --accent: 46 65% 52%;
  --accent-foreground: 0 0% 0%;
  --destructive: 0 84.2% 60.2%;
  --destructive-foreground: 0 0% 100%;
  --border: 0 0% 10%;
  --input: 0 0% 20%;
  --ring: 46 65% 52%;
  --radius: 0.25rem;
  --success: 196 52% 74%;
  --warning: 34 89% 85%;
  --error: 10 100% 86%;

  --brand-primary: 39 46% 61%;
  --brand-secondary: 0 0% 10%;
  --brand-background: 0 0% 5%;
  --brand-accent: 46 65% 52%;
  --brand-text: 0 0% 96%;
  --brand-header-bg: 0 0% 5%;
  --brand-footer-bg: 0 0% 5%;
  --brand-headline: 39 46% 61%;
  --brand-muted: 0 0% 66%;
}

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

html {
  font-size: clamp(0.875rem, 1vw + 0.5rem, 1rem);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-weight: 400;
  line-height: 1.75;
  letter-spacing: 0.01em;
  color: hsl(var(--text));
  background-color: hsl(var(--background));
}

img,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Noto Serif SC', 'Songti SC', 'SimSun', serif;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.03em;
  color: hsl(var(--text));
}

h1 {
  font-size: clamp(2rem, 4vw + 1rem, 2.5rem);
  font-weight: 700;
}

h2 {
  font-size: clamp(1.5rem, 3vw + 0.5rem, 1.75rem);
}

h3 {
  font-size: clamp(1.125rem, 2vw + 0.25rem, 1.375rem);
}

p {
  max-width: 40rem;
  line-height: 1.8;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease-out;
}

a:hover {
  color: hsl(var(--accent));
}

.container {
  width: 100%;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

@media (min-width: 768px) {
  .container {
    max-width: 720px;
  }
}

@media (min-width: 1024px) {
  .container {
    max-width: 960px;
  }
}

@media (min-width: 1440px) {
  .container {
    max-width: 1200px;
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  font-family: 'Noto Sans SC', sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.02em;
  border: none;
  border-radius: 0.25rem;
  cursor: pointer;
  transition: all 0.2s ease-out;
  text-decoration: none;
}

.btn-primary {
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}

.btn-primary:hover {
  background-color: hsl(46 65% 57%);
  color: hsl(var(--accent-foreground));
}

.btn-secondary {
  background-color: transparent;
  color: hsl(var(--text));
  border: 1px solid hsl(var(--text));
}

.btn-secondary:hover {
  background-color: hsl(0 0% 96% / 0.08);
  color: hsl(var(--text));
}

.card {
  background-color: hsl(var(--card));
  border: 1px solid hsl(0 0% 10% / 0.2);
  border-radius: 0.5rem;
  padding: 1.5rem;
  color: hsl(var(--card-foreground));
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.input {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: 'Noto Sans SC', sans-serif;
  font-size: 0.9375rem;
  font-weight: 400;
  line-height: 1.5;
  color: hsl(var(--text));
  background-color: hsl(var(--background));
  border: 1px solid hsl(0 0% 20%);
  border-radius: 0.25rem;
  outline: none;
  transition: border-color 0.2s ease-out, box-shadow 0.2s ease-out;
}

.input::placeholder {
  color: hsl(var(--muted-foreground));
}

.input:focus {
  border-color: hsl(var(--accent));
  box-shadow: 0 0 0 2px hsl(var(--accent) / 0.15);
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.625rem;
  font-family: 'Noto Sans SC', sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  line-height: 1;
  color: hsl(var(--accent));
  background-color: hsl(var(--accent) / 0.1);
  border-radius: 0.25rem;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 76px;
  display: flex;
  align-items: center;
  background-color: hsl(var(--brand-header-bg));
  border-bottom: 1px solid hsl(0 0% 100% / 0.06);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header a {
  color: hsl(0 0% 100%);
  font-size: 0.9375rem;
  font-weight: 400;
  transition: opacity 0.2s ease-out, color 0.2s ease-out;
}

.site-header a:hover {
  color: hsl(var(--accent));
}

.site-header nav a {
  opacity: 0.65;
}

.site-header nav a:hover {
  opacity: 1;
}

.site-footer {
  background-color: hsl(var(--brand-footer-bg));
  padding-block: 4rem 3rem;
  border-top: 1px solid hsl(0 0% 100% / 0.06);
}

.site-footer,
.site-footer a {
  color: hsl(0 0% 100% / 0.6);
  font-size: 0.875rem;
  transition: color 0.2s ease-out;
}

.site-footer a:hover {
  color: hsl(var(--accent));
}

.site-footer h4 {
  color: hsl(0 0% 100% / 0.9);
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.site-footer hr {
  border: none;
  border-top: 1px solid hsl(0 0% 100% / 0.15);
  margin-block: 2rem;
}

.bg-background {
  background-color: hsl(var(--background));
}

.bg-primary {
  background-color: hsl(var(--primary));
}

.bg-secondary {
  background-color: hsl(var(--secondary));
}

.bg-accent {
  background-color: hsl(var(--accent));
}

.bg-card {
  background-color: hsl(var(--card));
}

.text-foreground {
  color: hsl(var(--foreground));
}

.text-primary {
  color: hsl(var(--primary));
}

.text-secondary {
  color: hsl(var(--secondary-foreground));
}

.text-accent {
  color: hsl(var(--accent));
}

.text-muted {
  color: hsl(var(--muted-foreground));
}

.text-headline {
  color: hsl(var(--brand-headline));
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

.prose {
  --tw-prose-body: hsl(var(--text));
  --tw-prose-headings: hsl(var(--text));
  --tw-prose-lead: #4b5563;
  --tw-prose-links: #111827;
  --tw-prose-bold: #111827;
  --tw-prose-counters: #6b7280;
  --tw-prose-bullets: #d1d5db;
  --tw-prose-hr: #e5e7eb;
  --tw-prose-quotes: #111827;
  --tw-prose-quote-borders: #e5e7eb;
  --tw-prose-captions: #6b7280;
  --tw-prose-kbd: #111827;
  --tw-prose-kbd-shadows: rgb(17 24 39/10%);
  --tw-prose-code: #111827;
  --tw-prose-pre-code: #e5e7eb;
  --tw-prose-pre-bg: #1f2937;
  --tw-prose-th-borders: #d1d5db;
  --tw-prose-td-borders: #e5e7eb;
  --tw-prose-invert-body: #d1d5db;
  --tw-prose-invert-headings: #fff;
  --tw-prose-invert-lead: #9ca3af;
  --tw-prose-invert-links: #fff;
  --tw-prose-invert-bold: #fff;
  --tw-prose-invert-counters: #9ca3af;
  --tw-prose-invert-bullets: #4b5563;
  --tw-prose-invert-hr: #374151;
  --tw-prose-invert-quotes: #f3f4f6;
  --tw-prose-invert-quote-borders: #374151;
  --tw-prose-invert-captions: #9ca3af;
  --tw-prose-invert-kbd: #fff;
  --tw-prose-invert-kbd-shadows: rgb(255 255 255/10%);
  --tw-prose-invert-code: #fff;
  --tw-prose-invert-pre-code: #d1d5db;
  --tw-prose-invert-pre-bg: rgb(0 0 0/50%);
  --tw-prose-invert-th-borders: #4b5563;
  --tw-prose-invert-td-borders: #374151;
  font-size: 1rem;
  line-height: 1.75;
}
.posts-archive-grid img {
  aspect-ratio: 16/9;
}
