:root {
  --page-bg: #f5f5f5;
  --surface: #ffffff;
  --surface-soft: #fafafa;
  --text-primary: #111827;
  --text-muted: #6b7280;
  --line-color: #e5e7eb;
  --action: #2563eb;
  --action-hover: #1d4ed8;
  --action-active: #1e40af;
  --action-shadow: rgba(37, 99, 235, 0.24);
}
body {
  background: var(--page-bg);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.bi {
  line-height: 1;
  vertical-align: -0.125em;
}
.navbar-clean {
  background-color: #ffffff !important;
  border-bottom: 1px solid var(--line-color);
}
.navbar-clean .navbar-brand {
  color: var(--text-primary);
}
.page-main {
  flex: 1 0 auto;
  padding-top: 4.8rem;
  padding-bottom: 2rem;
}
.page-shell {
  margin-top: 4.6rem;
  padding-bottom: 2rem;
  flex: 1 0 auto;
}
.card {
  background: #ffffff;
  border: 1px solid var(--line-color) !important;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.04) !important;
}
.card-header {
  background: transparent !important;
  border-bottom-color: var(--line-color) !important;
}
.card-header-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.section-card {
  background: #ffffff;
  border: 1px solid var(--line-color);
  border-radius: 14px;
  padding: 1rem;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.04);
}
.section-box {
  border: 1px solid var(--line-color);
  border-radius: 10px;
  background: var(--surface);
  padding: 0.75rem 0.85rem;
}
.section-muted {
  color: var(--text-muted);
}
.compact-tool-shell {
  display: grid;
  gap: 0.85rem;
}
.compact-field {
  display: grid;
  gap: 0.4rem;
}
.compact-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
}
.fuhao-search {
  position: relative;
}
.fuhao-search .bi-search {
  position: absolute;
  top: 50%;
  left: 0.9rem;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}
.fuhao-search .form-control {
  border-color: #d1d5db;
  border-radius: 999px;
  padding-left: 2.4rem;
  height: 2.6rem;
}
.fuhao-search .form-control:focus {
  border-color: #9ca3af;
  box-shadow: 0 0 0 0.2rem rgba(17, 24, 39, 0.08);
}
.sym-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.sym-cat {
  border: 1px solid var(--line-color);
  background: #ffffff;
  color: var(--text-primary);
  border-radius: 999px;
  padding: 0.32rem 0.8rem;
  font-size: 0.84rem;
  line-height: 1.4;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background-color 0.15s ease,
    color 0.15s ease;
}
.sym-cat:hover {
  border-color: #bfdbfe;
  color: var(--action);
}
.sym-cat.is-active {
  background: var(--action);
  border-color: var(--action);
  color: #ffffff;
  font-weight: 600;
}
.sym-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(56px, 1fr));
  gap: 0.4rem;
}
.sym-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.25rem;
  border: 1px solid var(--line-color);
  border-radius: 10px;
  background: #ffffff;
  color: var(--text-primary);
  font-size: 1.35rem;
  line-height: 1.2;
  cursor: pointer;
  user-select: none;
  transition:
    border-color 0.15s ease,
    background-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}
.sym-btn:hover,
.sym-btn:focus-visible {
  border-color: #93c5fd;
  background: #f8fbff;
  box-shadow: 0 6px 14px rgba(37, 99, 235, 0.12);
  transform: translateY(-1px);
  outline: none;
}
.sym-btn.is-long {
  grid-column: span 2;
  font-size: 0.86rem;
  letter-spacing: 0.02em;
  padding: 0.25rem 0.4rem;
}
.sym-btn.is-copied {
  border-color: #86efac;
  background: #f0fdf4;
}
.sym-count {
  color: var(--text-muted);
  font-size: 0.82rem;
}
.sym-preview {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  border: 1px solid #bfdbfe;
  background: #f8fbff;
  color: var(--action-active);
  font-size: 0.86rem;
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.sym-empty {
  padding: 1.2rem 0.5rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.88rem;
}
.sym-tip {
  color: var(--text-muted);
  font-size: 0.8rem;
  line-height: 1.6;
}
.tool-card {
  background: #ffffff;
  border: 1px solid var(--line-color);
  border-radius: 14px;
  padding: 1rem;
  height: 100%;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.04);
}
.tool-icon {
  width: 2.5rem;
  height: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #f3f4f6;
  color: var(--text-primary);
  font-size: 1.1rem;
  flex: 0 0 2.5rem;
}
.tool-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}
.section-heading {
  margin: 0 0 0.75rem;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}
.category-tab {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.category-tab .nav-link {
  border: 1px solid var(--line-color);
  border-radius: 999px;
  background: #ffffff;
  color: var(--text-primary);
  padding: 0.36rem 0.9rem;
  font-size: 0.88rem;
  line-height: 1.4;
}
.category-tab .nav-link:hover {
  border-color: #bfdbfe;
  color: var(--action);
}
.category-tab .nav-link.active {
  background: var(--action);
  border-color: var(--action);
  color: #ffffff;
  font-weight: 600;
}
main .card.tool-card {
  height: 100%;
  border: 1px solid var(--line-color);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(17, 24, 39, 0.05);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}
main .card.tool-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.1);
}
main .card.tool-card h6 {
  color: var(--text-primary);
}
.home-card-count {
  display: block;
  margin-top: 0.15rem;
  color: var(--text-muted);
  font-size: 0.72rem;
}
.sym-result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 0.45rem;
}
.sym-result {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.1rem;
  padding: 0.5rem 0.4rem;
  border: 1px solid var(--line-color);
  border-radius: 10px;
  background: #ffffff;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background-color 0.15s ease,
    transform 0.15s ease;
}
.sym-result:hover,
.sym-result:focus-visible {
  border-color: #93c5fd;
  background: #f8fbff;
  transform: translateY(-1px);
  outline: none;
}
.sym-result.is-copied {
  border-color: #86efac;
  background: #f0fdf4;
}
.sym-result-symbol {
  font-size: 1.3rem;
  line-height: 1.25;
  color: var(--text-primary);
  word-break: break-all;
  text-align: center;
}
.sym-result.is-long .sym-result-symbol {
  font-size: 0.82rem;
}
.sym-result-name {
  font-size: 0.72rem;
  color: var(--text-muted);
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.sym-result-cat {
  font-size: 0.68rem;
  color: #9ca3af;
}
.compact-input {
  width: 100%;
  border: 1px solid var(--line-color);
  border-radius: 10px;
  background: #ffffff;
  padding: 0.7rem 0.8rem;
  color: var(--text-primary);
  line-height: 1.6;
  resize: vertical;
}
.compact-input:focus {
  border-color: #9ca3af;
  box-shadow: 0 0 0 0.2rem rgba(17, 24, 39, 0.08);
  outline: none;
}
.compact-input.single-line {
  height: 2.75rem;
  padding: 0.4rem 0.8rem;
  font-size: 1rem;
  font-weight: 500;
  resize: none;
}
.style-list {
  display: grid;
  gap: 0.55rem;
}
.style-row {
  border: 1px solid var(--line-color);
  border-radius: 10px;
  background: var(--surface-soft);
  padding: 0.55rem 0.7rem;
}
.style-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.3rem;
}
.style-name {
  font-weight: 600;
  font-size: 0.85rem;
  flex: 0 0 auto;
}
.style-note {
  flex: 1 1 auto;
  min-width: 0;
  color: var(--text-muted);
  font-size: 0.75rem;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.style-value {
  font-size: 1rem;
  line-height: 1.7;
  word-break: break-word;
  min-height: 1.7rem;
  color: var(--text-primary);
}
.compact-copy-btn {
  flex: 0 0 auto;
  height: 1.6rem;
  padding: 0 0.55rem;
  border: 1px solid rgba(209, 213, 219, 0.95);
  border-radius: 8px;
  background: #ffffff;
  color: #475569;
  font-size: 0.72rem;
  line-height: 1;
  cursor: pointer;
}
.compact-copy-btn:hover,
.compact-copy-btn:focus-visible {
  border-color: rgba(148, 163, 184, 0.95);
  color: #1f2937;
  outline: none;
}
.compact-copy-btn.is-copied {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #15803d;
}
.tool-hint {
  color: var(--text-muted);
  font-size: 0.8rem;
  line-height: 1.6;
}
.tool-hint.is-error {
  color: #b91c1c;
}
.fuhao-toast {
  position: fixed;
  left: 50%;
  top: 5.4rem;
  transform: translateX(-50%);
  z-index: 3000;
  padding: 0.5rem 0.9rem;
  border-radius: 10px;
  background: rgba(17, 24, 39, 0.9);
  color: #ffffff;
  font-size: 0.85rem;
  line-height: 1.5;
  pointer-events: none;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.2);
}
/* layer 提示不拦截点击 */
.layui-layer-msg,
.layui-layer-tips {
  pointer-events: none !important;
}
.footer-muted-link {
  color: var(--text-primary);
  text-decoration: none;
}
.footer-muted-link:hover {
  color: var(--action);
  text-decoration: none;
}
.empty-404 {
  min-height: calc(100vh - 140px);
  display: flex;
  align-items: center;
}
.btn-dark {
  background-color: var(--action) !important;
  border-color: var(--action) !important;
  color: #fff !important;
}
.btn-outline-secondary {
  color: var(--text-primary);
  background: #fff;
  border-color: #d1d5db;
}
.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
  color: var(--text-primary);
  background: #f3f4f6;
  border-color: #c7cdd4;
}
@media (max-width: 575.98px) {
  .page-main {
    padding-top: 5rem;
  }
  .sym-grid {
    grid-template-columns: repeat(auto-fill, minmax(48px, 1fr));
  }
  .sym-btn {
    min-height: 2.7rem;
    font-size: 1.2rem;
  }
}
