:root {
  --mint: #3eb489;
  --mint-dark: #31997f;
  --bg-light: #d0f0e8;
  --bg-dark: #1c1c1c;
  --text-light: #333;
  --text-dark: #f0f0f0;
}

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

html,
body {
  width: 100%;
  overflow-x: hidden;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.8;
  background: var(--bg-light);
  color: var(--text-light);
  margin: 0;
  padding: 0;
  text-align: left;
  transition: background 0.3s, color 0.3s;
  position: relative;
}

/* 动态背景容器（仅首页） */
body.has-dynamic-bg {
  background: transparent;
}

body.has-dynamic-bg::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: var(--dynamic-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(1.5px);
  opacity: 0.4;
  z-index: -2;
  transition: opacity 1s ease-in-out;
}

body.has-dynamic-bg::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(208, 240, 232, 0.85), rgba(62, 180, 137, 0.15));
  z-index: -1;
}

body.dark-mode.has-dynamic-bg::after {
  background: linear-gradient(135deg, rgba(28, 28, 28, 0.9), rgba(62, 180, 137, 0.2));
}

body.dark-mode {
  background: var(--bg-dark);
  color: var(--text-dark);
}


header {
  background-color: rgba(62, 180, 137, 0); /* 半透明 */
  color: var(--text-light);
  padding: 15px 20px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  width: 100%;
  box-sizing: border-box;
}

/* 隐藏 header 标题 */
header .header-left {
  display: none;
}

/* header 内按钮样式 */
header .base-btn {
  background-color: rgba(62, 180, 137, 0); /* 半透明 */
  color: var(--text-light);
  flex-shrink: 1;
  min-width: auto;
}

/* header 黑夜模式按钮文字 */
body.dark-mode header .base-btn {
  color: var(--text-dark);
}

/* header-right 样式调整 */
header .header-right {
  width: auto;
  gap: 8px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
}



a {
  text-decoration: none;
  color: var(--mint);
}

.header-left {
  width: 100%;
  flex-shrink: 0;
}

.header-left h1 {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-left h1 svg {
  width: 1.2em;
  height: 1.2em;
  flex-shrink: 0;
}

.header-right {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-start;
}

/* 合并按钮基础样式 */
.base-btn {
  padding: 10px 16px;
  border: none;
  background-color: var(--mint);
  color: #fff;
  border-radius: 6px;
  font-size: 15px;
  cursor: pointer;
  transition: background 0.3s, transform 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  line-height: 1.2;
  white-space: nowrap;
  box-sizing: border-box;
}

.base-btn:hover {
  background-color: var(--mint-dark);
  transform: scale(1.05);
}

/* 黑夜模式下按钮文字颜色适配 */
.dark-mode .base-btn {
  color: var(--text-dark);
}

.dark-mode .base-btn:hover {
  color: var(--text-dark);
}

/* 主题切换按钮里的 SVG 图标样式 */
#theme-toggle .mode-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.2em;
  height: 1.2em;
  flex: 0 0 auto;
}

#theme-toggle svg {
  width: 1.2em;
  height: 1.2em;
  display: block;
}

/* 默认浅色：显示太阳，隐藏月亮（图标表示"当前模式"） */
#theme-toggle .icon-moon {
  display: none;
}

#theme-toggle .icon-sun {
  display: block;
}

/* 深色模式：显示月亮，隐藏太阳 */
body.dark-mode #theme-toggle .icon-moon {
  display: block;
}

body.dark-mode #theme-toggle .icon-sun {
  display: none;
}

.api-section {
  margin: 20px auto;
  max-width: 800px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: background 0.3s, color 0.3s;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-sizing: border-box;
  width: 100%;
}

.hero {
  text-align: center;
  padding: 40px 30px;
  background: transparent;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}


.hero-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.hero-title {
  font-family: 'Great Vibes', cursive;
  font-size: 64px;
  line-height: 1.2;
  margin: 0 auto 28px;
  letter-spacing: 2px;
  font-weight: 400;
  text-align: center;
}

.hero-desc {
  font-size: 18px;
  max-width: 680px;
  margin: 0 auto 10px;
  color: inherit;
}

.hero-buttons {
  justify-content: center;
  margin-top: 10px;
}

body.has-dynamic-bg .hero-desc {
  color: rgba(30, 45, 40, 0.88);
}

body.dark-mode.has-dynamic-bg .hero-desc {
  color: rgba(245, 250, 248, 0.86);
}

.dark-mode .api-section {
  background: rgba(43, 43, 43, 0.95);
  color: var(--text-dark);
}

/* 首页暗黑模式：去除主内容卡片背景 */
body.dark-mode.has-dynamic-bg .api-section.hero {
  background: transparent;
  box-shadow: none;
  border: none;
}

img {
  max-width: 100%;
  height: auto;
  margin-top: 15px;
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

footer {
  padding: 20px 15px;
  text-align: center;
  margin-top: 30px;
  box-sizing: border-box;
  width: 100%;
  overflow-x: hidden;
}

footer h4 {
  color: var(--text-light);
  margin: 10px 0;
  font-size: 16px;
}

.dark-mode footer h4 {
  color: var(--text-dark);
}

footer > div > a {
  color: var(--mint);
  text-decoration: none;
  transition: color 0.3s, text-decoration 0.3s;
}

footer > div > a:hover {
  color: var(--mint-dark);
  text-decoration: underline;
}

.dark-mode footer > div > a {
  color: var(--mint-dark);
}

.dark-mode footer > div > a:hover {
  color: var(--mint);
  text-decoration: underline;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  line-height: 1;
  padding: 0 10px;
}

@media (max-width: 480px) {
  .footer-links {
    gap: 10px;
    padding: 0 5px;
  }
}

/* 合并链接样式 */
.footer-links a {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  padding: 2px 0;
  transform: translateY(0.15em);
  color: var(--mint);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s, text-decoration 0.3s;
}

.footer-links a:hover {
  color: var(--mint-dark);
  text-decoration: underline;
}

.dark-mode .footer-links a {
  color: var(--mint-dark);
}

.dark-mode .footer-links a:hover {
  color: var(--mint);
  text-decoration: underline;
}

.footer-links a img {
  width: 1em;
  height: 1em;
  margin-right: 5px;
  display: block;
  flex-shrink: 0;
}

.footer-contact,
.footer-icp,
.footer-sitemap {
  color: var(--mint);
  font-size: 14px;
  margin-top: 15px;
  text-decoration: none;
  transition: color 0.3s, text-decoration 0.3s;
  display: block;
}

.footer-contact a,
.footer-icp a,
.footer-sitemap a {
  color: var(--mint);
  text-decoration: none;
  transition: color 0.3s, text-decoration 0.3s;
}

.footer-contact a:hover,
.footer-icp a:hover,
.footer-sitemap a:hover {
  color: var(--mint-dark);
  text-decoration: underline;
}

.dark-mode .footer-contact,
.dark-mode .footer-icp,
.dark-mode .footer-sitemap {
  color: var(--mint-dark);
}

.dark-mode .footer-contact a,
.dark-mode .footer-icp a,
.dark-mode .footer-sitemap a {
  color: var(--mint-dark);
}

.dark-mode .footer-contact a:hover,
.dark-mode .footer-icp a:hover,
.dark-mode .footer-sitemap a:hover {
  color: var(--mint);
  text-decoration: underline;
}

@media (max-width: 768px) {
  header {
    flex-direction: row;
    gap: 8px;
    justify-content: center;
    padding: 12px 15px;
  }

  .header-left {
    width: 100%;
    display: none;
  }

  .header-right {
    flex-direction: row;
    align-items: center;
    width: 100%;
    justify-content: center;
    gap: 6px;
  }

  .header-right .base-btn {
    padding: 8px 12px;
    font-size: 13px;
    flex-shrink: 1;
    min-width: 0;
  }

  .api-btn {
    width: auto;
  }

  .hero {
    padding: 20px 15px;
  }

  .hero-inner {
    gap: 10px;
  }

  .hero-title {
    font-size: 32px;
    margin-bottom: 20px;
  }

  .hero-desc {
    font-size: 15px;
    margin: 0 auto 8px;
  }

  .cta-buttons {
    flex-direction: column;
    gap: 12px;
  }

  .cta-btn {
    width: 100%;
    padding: 12px 20px;
    font-size: 15px;
  }
}

@media (max-width: 480px) {
  header {
    padding: 10px 12px;
    gap: 6px;
  }

  .header-right .base-btn {
    padding: 7px 10px;
    font-size: 12px;
  }

  .hero {
    padding: 15px 12px;
  }

  .hero-title {
    font-size: 28px;
    margin-bottom: 16px;
  }

  .hero-desc {
    font-size: 14px;
  }

  .cta-btn {
    padding: 10px 16px;
    font-size: 14px;
  }
}
/* 首页功能网格 */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin: 20px 0;
}

.feature-item {
  background: #f5f5f5;
  padding: 20px;
  border-radius: 8px;
  border-left: 4px solid var(--mint);
  transition: transform 0.3s, box-shadow 0.3s;
}

.dark-mode .feature-item {
  background: #2b2b2b;
}

.feature-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.feature-item h4 {
  color: var(--mint);
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 18px;
}

.feature-item p {
  margin: 0;
  line-height: 1.6;
}

/* 功能列表 */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 15px 0;
}

.feature-list li {
  padding: 10px 0;
  border-bottom: 1px solid #e0e0e0;
  line-height: 1.8;
}

.dark-mode .feature-list li {
  border-bottom-color: #444;
}

.feature-list li:last-child {
  border-bottom: none;
}

/* CTA按钮组 */
.cta-buttons {
  display: flex;
  gap: 15px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.cta-btn {
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 首页按钮：仅保留边框，去除阴影与填充 */
body.has-dynamic-bg .cta-btn {
  border-radius: 999px;
  padding: 14px 28px;
  font-weight: 600;
  letter-spacing: 0.2px;
  background: transparent;
  box-shadow: none;
  border: 1px solid var(--mint);
  color: var(--mint-dark);
}

.cta-btn.primary {
  background: linear-gradient(135deg, var(--mint), var(--mint-dark));
  color: white;
}

body.has-dynamic-bg .cta-btn.primary {
  background: transparent;
  color: var(--mint-dark);
}

.cta-btn.secondary {
  background: white;
  color: var(--mint);
  border: 2px solid var(--mint);
}

body.has-dynamic-bg .cta-btn.secondary {
  background: transparent;
  border: 1px solid var(--mint);
  color: var(--mint-dark);
}

.dark-mode .cta-btn.secondary {
  background: #2b2b2b;
  color: var(--text-dark);
}

body.dark-mode.has-dynamic-bg .cta-btn {
  border-color: rgba(255, 255, 255, 0.65);
  color: #e9fff7;
}

.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.cta-btn.primary:hover {
  background: linear-gradient(135deg, var(--mint-dark), var(--mint));
}

.cta-btn.secondary:hover {
  background: var(--mint);
  color: white;
}

/* 状态链接 */
.status-link {
  display: inline-block;
  padding: 12px 24px;
  background: var(--mint);
  color: white;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.3s, transform 0.2s;
  margin-top: 10px;
}

.status-link:hover {
  background: var(--mint-dark);
  transform: scale(1.05);
}

/* 响应式调整 */
@media (max-width: 768px) {
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .cta-buttons {
    flex-direction: column;
  }

  .cta-btn {
    width: 100%;
    justify-content: center;
  }
}

/* SVG 内联样式替代 */
.inline-icon {
  width: 1.2em;
  height: 1.2em;
  vertical-align: text-bottom;
  display: inline-block;
}

.list-icon {
  width: 1em;
  height: 1em;
  vertical-align: text-bottom;
  display: inline-block;
  margin-right: 0.2em;
}

.en-hidden {
  display: none;
}

.inline-icon-svg {
  width: 1.2em;
  height: 1.2em;
  display: inline;
  margin-right: 8px;
  vertical-align: -0.125em;
}

.small-icon {
  width: 1em;
  height: 1em;
  vertical-align: text-bottom;
  display: inline-block;
  margin-right: 0.3em;
}

.small-icon-svg {
  width: 1em;
  height: 1em;
  display: inline;
  margin-right: 5px;
  vertical-align: -0.125em;
}

.query-footer {
  margin-top: 20px;
  font-size: 14px;
  color: #666;
}

.query-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 15px;
}
.api-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin: 30px auto;
  max-width: 800px;
  padding: 0 20px;
}

.api-card {
  background: white;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
  text-align: center;
}

.dark-mode .api-card {
  background: #2b2b2b;
  color: var(--text-dark);
}

.api-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.api-card h2 {
  color: var(--mint);
  margin-top: 0;
  font-size: 24px;
}

.api-card .description {
  font-size: 16px;
  line-height: 1.6;
  margin: 15px 0;
  text-align: left;
}

.api-card .endpoint {
  background: #f5f5f5;
  padding: 10px;
  border-radius: 5px;
  margin: 15px 0;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  word-break: break-all;
  text-align: left;
}

.dark-mode .api-card .endpoint {
  background: #1a1a1a;
  color: #aaa;
}

.api-card .btn-wrapper {
  margin-top: 20px;
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.api-link-btn {
  padding: 12px 24px;
  background-color: var(--mint);
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.3s, transform 0.2s;
}

.api-link-btn:hover {
  background-color: var(--mint-dark);
  transform: scale(1.05);
}

.back-home {
  text-align: center;
  margin: 20px 0;
}

.back-home a {
  color: var(--mint);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s;
}

.back-home a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .api-list {
    grid-template-columns: 1fr;
    padding: 0 10px;
  }

  .api-card {
    padding: 20px;
  }

  .api-card h2 {
    font-size: 20px;
  }
}

/* Image API Page Styles */
.nav-links {
  max-width: 800px;
  margin: 20px auto;
  padding: 0 20px;
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.nav-links a {
  padding: 8px 16px;
  background-color: var(--mint);
  color: white;
  border-radius: 6px;
  text-decoration: none;
  transition: background 0.3s;
}

.nav-links a:hover {
  background-color: var(--mint-dark);
}

.code-block {
  background: #f5f5f5;
  border-left: 4px solid var(--mint);
  padding: 15px;
  margin: 15px 0;
  border-radius: 5px;
  overflow-x: auto;
  font-family: 'Courier New', monospace;
  font-size: 14px;
}

.code-block::-webkit-scrollbar {
  display: none;
}

.code-block {
  -ms-overflow-style: none;
}

.dark-mode .code-block {
  background: #1a1a1a;
  color: #aaa;
}

.parameter-table {
  width: 100%;
  border-collapse: collapse;
  margin: 15px 0;
}

.parameter-table th,
.parameter-table td {
  border: 1px solid #ddd;
  padding: 12px;
  text-align: left;
}

.dark-mode .parameter-table th,
.dark-mode .parameter-table td {
  border-color: #444;
}

.parameter-table th {
  background-color: var(--mint);
  color: white;
}

.dark-mode .parameter-table th {
  background-color: #2a6e5f;
}

.parameter-table tr:nth-child(even) {
  background-color: #f9f9f9;
}

.dark-mode .parameter-table tr:nth-child(even) {
  background-color: #2b2b2b;
}

.example-section {
  background: white;
  border-radius: 10px;
  padding: 20px;
  margin: 20px auto;
  max-width: 800px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.dark-mode .example-section {
  background: #2b2b2b;
}

.example-section h3 {
  color: var(--mint);
  margin-top: 0;
}

.demo-img {
  margin-top: 15px;
}

.response-example {
  background: #f5f5f5;
  border-left: 4px solid var(--mint);
  padding: 15px;
  margin: 15px 0;
  border-radius: 5px;
  overflow-x: auto;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.5;
}

.dark-mode .response-example {
  background: #1a1a1a;
  color: #aaa;
}

.query-input {
  display: flex;
  gap: 10px;
  margin: 15px 0;
  flex-wrap: wrap;
}

.query-input input {
  flex: 1;
  min-width: 200px;
  padding: 10px;
  border: 2px solid var(--mint);
  border-radius: 6px;
  font-size: 14px;
  font-family: 'Courier New', monospace;
}

.dark-mode .query-input input {
  background: #1a1a1a;
  color: var(--text-dark);
  border-color: var(--mint-dark);
}

.query-result {
  background: #f5f5f5;
  border-left: 4px solid var(--mint);
  padding: 15px;
  margin: 15px 0;
  border-radius: 5px;
  overflow-x: auto;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.5;
  display: none;
}

.dark-mode .query-result {
  background: #1a1a1a;
  color: #aaa;
}

.query-result.active {
  display: block;
}

.query-result pre {
  margin: 0;
  white-space: pre-wrap;
  word-wrap: break-word;
}

/* Thank You Page Styles */
.thank-body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: url('https://api.furry.ist/furry-img/') no-repeat center center fixed;
  background-size: cover;
  color: #333;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 10px;
}

.container h1 {
  text-align: center;
  margin-bottom: 20px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.user-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.user-card:hover {
  transform: translateY(-5px);
}

.user-card h2 {
  font-size: 1.2em;
  margin: 0 0 10px;
}

.user-card p {
  margin: 5px 0;
  color: #555;
}

.user-card a {
  color: #3498db;
  text-decoration: none;
  word-break: break-word;
}

.user-card a:hover {
  text-decoration: underline;
}

/* Swagger UI Custom Styles */
.swagger-body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, "Helvetica Neue", Arial, "Noto Sans",
               "PingFang SC", "Hiragino Sans GB", sans-serif;
}

.topbar {
  height: 56px;
  display: flex;
  align-items: center;
  padding: 0 20px;
  background: var(--header);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.topbar .left {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: .3px;
}

#swagger-ui {
  max-width: 1200px;
  margin: 24px auto;
  padding: 0 16px;
}

.swagger-ui {
  color: var(--text);
}

.swagger-ui .scheme-container {
  background: transparent;
  box-shadow: none;
}

.swagger-ui .opblock {
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--bg-soft);
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  overflow: hidden;
}

.swagger-ui .opblock .opblock-summary {
  padding: 14px 16px;
}

.swagger-ui .opblock.opblock-get {
  border-left: 6px solid var(--mint-500);
}

.swagger-ui .opblock.opblock-post {
  border-left: 6px solid var(--mint-600);
}

.swagger-ui .btn {
  border-radius: 10px;
  border: 1px solid var(--mint-600);
  background: transparent;
  color: var(--mint-600);
  transition: all .2s ease;
}

.swagger-ui .btn:hover {
  background: var(--mint-600);
  color: #ffffff;
}

.swagger-ui input,
.swagger-ui textarea,
.swagger-ui select {
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-soft);
  color: var(--text);
}

.swagger-ui .responses-wrapper {
  border-top: 1px dashed var(--border);
}

.swagger-body footer {
  text-align: center;
  font-size: 13px;
  opacity: .6;
  padding: 24px 0;
}
