/* Shared behavioral styles for ClawCenter Web 1.0 */

:root {
  color-scheme: light;
}

html[data-theme='dark'] {
  color-scheme: dark;
}

html[data-theme='dark'] body {
  background: #0b1220 !important;
  color: #e5e7eb !important;
}

html[data-theme='dark'] .bg-white {
  background-color: #111827 !important;
}

html[data-theme='dark'] .bg-gray-50 {
  background-color: #0b1220 !important;
}

html[data-theme='dark'] .bg-slate-50 {
  background-color: #0b1220 !important;
}

html[data-theme='dark'] .bg-gray-100 {
  background-color: #1e293b !important;
}

html[data-theme='dark'] .bg-gray-200 {
  background-color: #334155 !important;
}

html[data-theme='dark'] .bg-gray-300 {
  background-color: #475569 !important;
}

html[data-theme='dark'] .bg-slate-100 {
  background-color: #1e293b !important;
}

html[data-theme='dark'] .bg-slate-200 {
  background-color: #334155 !important;
}

html[data-theme='dark'] .bg-slate-900 {
  background-color: #020617 !important;
}

html[data-theme='dark'] .bg-white\/10 {
  background-color: rgba(30, 41, 59, 0.58) !important;
}

html[data-theme='dark'] .bg-white\/15 {
  background-color: rgba(30, 41, 59, 0.64) !important;
}

html[data-theme='dark'] .bg-white\/20 {
  background-color: rgba(51, 65, 85, 0.72) !important;
}

html[data-theme='dark'] .bg-blue-50,
html[data-theme='dark'] .bg-cyan-50,
html[data-theme='dark'] .bg-green-50,
html[data-theme='dark'] .bg-purple-50,
html[data-theme='dark'] .bg-amber-50,
html[data-theme='dark'] .bg-yellow-50,
html[data-theme='dark'] .bg-red-50,
html[data-theme='dark'] .bg-amber-50\/40,
html[data-theme='dark'] .bg-cyan-50\/40 {
  background-color: #1e293b !important;
}

html[data-theme='dark'] .bg-blue-100,
html[data-theme='dark'] .bg-cyan-100,
html[data-theme='dark'] .bg-green-100,
html[data-theme='dark'] .bg-purple-100,
html[data-theme='dark'] .bg-amber-100,
html[data-theme='dark'] .bg-yellow-100,
html[data-theme='dark'] .bg-red-100,
html[data-theme='dark'] .bg-orange-100,
html[data-theme='dark'] .bg-emerald-100 {
  background-color: #334155 !important;
}

html[data-theme='dark'] .from-blue-50,
html[data-theme='dark'] .from-cyan-50,
html[data-theme='dark'] .from-green-50,
html[data-theme='dark'] .from-purple-50,
html[data-theme='dark'] .from-amber-50,
html[data-theme='dark'] .from-yellow-50,
html[data-theme='dark'] .from-red-50,
html[data-theme='dark'] .from-orange-50,
html[data-theme='dark'] .from-emerald-50 {
  --tw-gradient-from: #1e293b var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgb(30 41 59 / 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

html[data-theme='dark'] .to-blue-100,
html[data-theme='dark'] .to-cyan-100,
html[data-theme='dark'] .to-green-100,
html[data-theme='dark'] .to-purple-100,
html[data-theme='dark'] .to-amber-100,
html[data-theme='dark'] .to-yellow-100,
html[data-theme='dark'] .to-red-100,
html[data-theme='dark'] .to-orange-100,
html[data-theme='dark'] .to-emerald-100 {
  --tw-gradient-to: #334155 var(--tw-gradient-to-position) !important;
}

html[data-theme='dark'] .text-gray-900,
html[data-theme='dark'] .text-slate-900 {
  color: #f8fafc !important;
}

html[data-theme='dark'] .text-gray-800,
html[data-theme='dark'] .text-slate-800 {
  color: #f1f5f9 !important;
}

html[data-theme='dark'] .text-gray-700,
html[data-theme='dark'] .text-slate-700 {
  color: #e2e8f0 !important;
}

html[data-theme='dark'] .text-gray-600,
html[data-theme='dark'] .text-slate-600 {
  color: #cbd5e1 !important;
}

html[data-theme='dark'] .text-gray-500,
html[data-theme='dark'] .text-slate-500,
html[data-theme='dark'] .text-gray-400,
html[data-theme='dark'] .text-slate-400 {
  color: #94a3b8 !important;
}

html[data-theme='dark'] .text-blue-600,
html[data-theme='dark'] .text-blue-700,
html[data-theme='dark'] .text-blue-800,
html[data-theme='dark'] .text-indigo-600 {
  color: #93c5fd !important;
}

html[data-theme='dark'] .text-green-500,
html[data-theme='dark'] .text-green-600,
html[data-theme='dark'] .text-green-700,
html[data-theme='dark'] .text-emerald-600,
html[data-theme='dark'] .text-emerald-700 {
  color: #86efac !important;
}

html[data-theme='dark'] .text-yellow-600,
html[data-theme='dark'] .text-yellow-700,
html[data-theme='dark'] .text-yellow-800,
html[data-theme='dark'] .text-amber-700,
html[data-theme='dark'] .text-orange-600,
html[data-theme='dark'] .text-orange-800 {
  color: #fcd34d !important;
}

html[data-theme='dark'] .text-red-500,
html[data-theme='dark'] .text-red-600,
html[data-theme='dark'] .text-red-700,
html[data-theme='dark'] .text-red-800 {
  color: #fca5a5 !important;
}

html[data-theme='dark'] .text-purple-600,
html[data-theme='dark'] .text-purple-700 {
  color: #c4b5fd !important;
}

html[data-theme='dark'] .border,
html[data-theme='dark'] .border-t,
html[data-theme='dark'] .border-r,
html[data-theme='dark'] .border-b,
html[data-theme='dark'] .border-l,
html[data-theme='dark'] .border-slate-200,
html[data-theme='dark'] .border-gray-200,
html[data-theme='dark'] .border-gray-300 {
  border-color: #334155 !important;
}

html[data-theme='dark'] .border-blue-300,
html[data-theme='dark'] .border-blue-400,
html[data-theme='dark'] .border-blue-500,
html[data-theme='dark'] .border-blue-600,
html[data-theme='dark'] .border-blue-700,
html[data-theme='dark'] .border-cyan-100,
html[data-theme='dark'] .border-cyan-200,
html[data-theme='dark'] .border-cyan-400,
html[data-theme='dark'] .border-amber-100,
html[data-theme='dark'] .border-amber-200,
html[data-theme='dark'] .border-purple-300,
html[data-theme='dark'] .border-red-300,
html[data-theme='dark'] .border-green-500,
html[data-theme='dark'] .border-orange-500,
html[data-theme='dark'] .border-purple-500,
html[data-theme='dark'] .border-red-500 {
  border-color: #475569 !important;
}

html[data-theme='dark'] .shadow-sm,
html[data-theme='dark'] .shadow,
html[data-theme='dark'] .shadow-lg,
html[data-theme='dark'] .shadow-xl {
  box-shadow: 0 12px 24px rgba(2, 6, 23, 0.45) !important;
}

html[data-theme='dark'] .hover\:bg-gray-50:hover {
  background-color: #1e293b !important;
}

html[data-theme='dark'] .hover\:bg-gray-300:hover {
  background-color: #475569 !important;
}

html[data-theme='dark'] input,
html[data-theme='dark'] select,
html[data-theme='dark'] textarea {
  background-color: #0f172a !important;
  color: #e2e8f0 !important;
  border-color: #475569 !important;
}

html[data-theme='dark'] input::placeholder,
html[data-theme='dark'] textarea::placeholder {
  color: #94a3b8 !important;
}

html[data-theme='dark'] select option {
  background-color: #0f172a !important;
  color: #e2e8f0 !important;
}

html[data-theme='dark'] .bg-blue-600.text-white,
html[data-theme='dark'] .bg-gray-900.text-white {
  color: #f8fafc !important;
}

.cc-brand-link {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  min-width: 0;
  width: auto;
  line-height: 0;
}

.cc-brand-logo {
  height: 34px;
  max-width: min(220px, 26vw);
  width: auto;
  display: block;
  object-fit: contain;
  object-position: left center;
  transform: translateY(-1px);
}

.cc-brand-logo-dark {
  display: none;
}

html[data-theme='dark'] .cc-brand-logo-light {
  display: none;
}

html[data-theme='dark'] .cc-brand-logo-dark {
  display: block;
}

.cc-nav-links {
  display: flex;
  align-items: center;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}

.cc-nav-links::-webkit-scrollbar {
  display: none;
}

.cc-nav-links a[data-nav-route] {
  flex: 0 0 auto;
}

[data-cc-nav][data-lang='zh'] .cc-nav-links {
  gap: 0.2rem;
}

[data-cc-nav][data-lang='zh'] a[data-nav-route] {
  font-size: 0.8rem;
  padding-left: 0.4rem;
  padding-right: 0.4rem;
}

[data-cc-nav][data-lang='en'] .cc-nav-links {
  gap: 0.2rem;
}

[data-cc-nav][data-lang='en'] a[data-nav-route] {
  font-size: 0.76rem;
  padding-left: 0.35rem;
  padding-right: 0.35rem;
}

@media (max-width: 640px) {
  .cc-brand-logo {
    height: 30px;
    max-width: 180px;
    transform: translateY(0);
  }
}

@media (min-width: 1024px) {
  [data-cc-nav][data-lang='zh'] .cc-nav-links {
    gap: 0.65rem;
  }

  [data-cc-nav][data-lang='en'] .cc-nav-links {
    gap: 0.3rem;
  }

  [data-cc-nav][data-lang='en'] a[data-nav-route] {
    font-size: 0.8rem;
    padding-left: 0.42rem;
    padding-right: 0.42rem;
  }
}

@media (min-width: 768px) and (max-width: 1280px) {
  [data-cc-nav][data-lang='en'] a[data-nav-route] {
    font-size: 0.72rem;
    padding-left: 0.28rem;
    padding-right: 0.28rem;
  }

  [data-cc-nav][data-lang='en'] .cc-nav-links {
    gap: 0.14rem;
  }
}

.nav-link-active {
  color: #2563eb !important;
  border-bottom: 2px solid #2563eb;
}

html[data-theme='dark'] .nav-link-active {
  color: #93c5fd !important;
  border-bottom-color: #93c5fd !important;
}

html[data-theme='dark'] #skills-category-filters .category-btn {
  border: 1px solid #475569;
}

html[data-theme='dark'] #skills-category-filters .category-btn.bg-gray-200 {
  background-color: #334155 !important;
  color: #e2e8f0 !important;
}

html[data-theme='dark'] #skills-category-filters .category-btn.bg-purple-600 {
  background-color: #7c3aed !important;
  color: #ffffff !important;
  border-color: #8b5cf6;
}

.section-hidden {
  display: none !important;
}

.card-hidden {
  display: none !important;
}

.no-results {
  border: 1px dashed #cbd5e1;
  border-radius: 0.75rem;
  padding: 1rem;
  text-align: center;
  color: #64748b;
  background: #f8fafc;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
}

.status-pill--ok {
  background: #dcfce7;
  color: #166534;
}

.status-pill--warn {
  background: #fef3c7;
  color: #92400e;
}

.status-pill--error {
  background: #fee2e2;
  color: #991b1b;
}

.doc-link-active {
  background: #eff6ff !important;
  color: #2563eb !important;
  font-weight: 600;
}

html[data-theme='dark'] .doc-link-active {
  background: #1e3a8a !important;
  color: #bfdbfe !important;
}

.doc-copy-btn {
  transition: all 0.2s ease;
}

.doc-copy-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.18);
}
