:root {
  --primary-color: #3498db;
  --secondary-color: #2c3e50;
  --accent-color: #e74c3c;
  --success-color: #27ae60;
  --text-color: #333;
  --text-light: #555;
  --text-muted: #7f8c8d;
  --bg-color: #f5f5f5;
  --white: #fff;
  --border-color: #ecf0f1;
  --shadow: 0 2px 8px rgba(0,0,0,0.1);
  --shadow-hover: 0 4px 16px rgba(0,0,0,0.15);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background: var(--bg-color);
  font-size: 16px;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease, transform 0.3s ease;
}

a:hover {
  transform: translateY(-2px);
}

ul, ol {
  list-style: none;
}

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

.header {
  background: var(--white);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
}

.logo {
  font-size: 24px;
  font-weight: bold;
  color: var(--secondary-color);
  transition: color 0.3s;
}

.logo:hover {
  color: var(--primary-color);
}

.nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 30px;
}

.nav a {
  color: var(--text-light);
  font-weight: 500;
  white-space: nowrap;
  position: relative;
  padding: 5px 0;
}

.nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  transition: width 0.3s ease;
}

.nav a:hover {
  color: var(--primary-color);
  transform: translateY(0);
}

.nav a:hover::after {
  width: 100%;
}

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 30px 20px;
  min-height: calc(100vh - 200px);
}

h1 {
  font-size: 32px;
  color: var(--secondary-color);
  margin-bottom: 20px;
  line-height: 1.4;
}

h2 {
  font-size: 26px;
  color: var(--secondary-color);
  margin-bottom: 20px;
  line-height: 1.3;
}

h3 {
  font-size: 18px;
  color: var(--secondary-color);
  margin-bottom: 10px;
}

p {
  line-height: 1.8;
  color: var(--text-light);
}

.card {
  background: var(--white);
  padding: 20px;
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: block;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.badge {
  display: inline-block;
  background: var(--primary-color);
  color: var(--white);
  padding: 3px 10px;
  border-radius: 3px;
  font-size: 12px;
  font-weight: 500;
}

.btn {
  display: inline-block;
  padding: 10px 24px;
  background: var(--primary-color);
  color: var(--white);
  border-radius: 6px;
  font-weight: 500;
  transition: background 0.3s ease, transform 0.3s ease;
  border: none;
  cursor: pointer;
}

.btn:hover {
  background: #2980b9;
  transform: translateY(-2px);
}

.grid {
  display: grid;
  gap: 20px;
}

.grid-2 {
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

@media (max-width: 768px) {
  .header-inner {
    padding: 0 10px;
    height: 50px;
  }

  .logo {
    font-size: 18px;
  }

  .nav {
    flex: 1;
    justify-content: space-between;
    gap: 0;
    margin-left: 15px;
  }

  .nav a {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
    font-size: 13px;
    padding: 0 2px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  main {
    padding: 20px 15px;
  }

  h1 {
    font-size: 24px;
  }

  h2 {
    font-size: 20px;
  }

  .grid {
    gap: 15px;
  }

  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .nav a {
    font-size: 11px;
  }

  h1 {
    font-size: 22px;
  }

  .card {
    padding: 15px;
  }
}

.ui-style-0 { --primary-color: #3498db; }
.ui-style-1 { --primary-color: #9b59b6; }
.ui-style-2 { --primary-color: #1abc9c; }
.ui-style-3 { --primary-color: #e67e22; }
.ui-style-4 { --primary-color: #e74c3c; }
.ui-style-5 { --primary-color: #34495e; }
.ui-style-6 { --primary-color: #16a085; }
.ui-style-7 { --primary-color: #27ae60; }
.ui-style-8 { --primary-color: #2980b9; }
.ui-style-9 { --primary-color: #8e44ad; }
.ui-style-10 { --primary-color: #2c3e50; }
.ui-style-11 { --primary-color: #f39c12; }
.ui-style-12 { --primary-color: #d35400; }
.ui-style-13 { --primary-color: #c0392b; }
.ui-style-14 { --primary-color: #7f8c8d; }
.ui-style-15 { --primary-color: #2ecc71; }

footer {
  background: var(--secondary-color);
  color: #ecf0f1;
  padding: 30px 20px;
  text-align: center;
  margin-top: 50px;
}

footer p {
  color: #ecf0f1;
  margin-bottom: 10px;
}

.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s, transform 0.3s;
  z-index: 999;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-5px);
}
