/* Enhanced Typography for Riddle Website */
:root {
  --primary-font: 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', sans-serif;
  --heading-font: 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', sans-serif;
  --body-color: #333333;
  --heading-color: #222222;
}

body {
  font-family: var(--primary-font);
  font-weight: 500;
  color: var(--body-color);
  letter-spacing: 0.01em;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Headings */
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--heading-font);
  font-weight: 600;
  color: var(--heading-color);
  line-height: 1.3;
  margin-bottom: 0.5em;
  letter-spacing: -0.01em;
}

h1, .h1 {
  font-size: 2.25rem;
  letter-spacing: -0.02em;
}

h2, .h2 {
  font-size: 1.875rem;
}

h3, .h3 {
  font-size: 1.5rem;
}

h4, .h4 {
  font-size: 1.25rem;
}

h5, .h5 {
  font-size: 1.125rem;
}

h6, .h6 {
  font-size: 1rem;
  letter-spacing: 0.01em;
}

/* Chinese text specific styles */
:lang(zh), 
:lang(zh-CN), 
:lang(zh-Hans) {
  font-weight: 500;
  letter-spacing: 0.05em;
}

/* Card titles and important elements */
.card-title, .nav-link, .btn {
  letter-spacing: 0.02em;
}

/* Riddle text styling */
.riddle-text {
  font-size: 1.125rem;
  line-height: 1.8;
  letter-spacing: 0.03em;
}

.riddle-answer {
  font-weight: 600;
  color: #0d6efd;
}

/* Font weight utilities */
.font-light {
  font-weight: 400;
}

.font-medium {
  font-weight: 500;
}

.font-bold {
  font-weight: 700;
}

/* Additional typography enhancements */
.lead {
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.7;
}

blockquote {
  font-style: italic;
  border-left: 4px solid #0d6efd;
  padding-left: 1rem;
  margin-left: 0;
  color: #555;
}

.text-small {
  font-size: 0.875rem;
  letter-spacing: 0.02em;
}

/* Improve readability on dark backgrounds */
.bg-dark, .bg-primary, .bg-secondary {
  letter-spacing: 0.02em;
}

/* Navbar brand styling */
.navbar-brand {
  font-weight: 600;
  letter-spacing: 0.02em;
}

/* Footer text */
footer {
  font-size: 0.9rem;
  letter-spacing: 0.01em;
}
