/* =========================================
   1. 基础重置与变量 (Base & Variables)
   ========================================= */
:root {
    --brand: #ff5914;
    --brand-hover: #e04e0e;
    --slate-50: #f8fafc; --slate-100: #f1f5f9; --slate-200: #e2e8f0;
    --slate-300: #cbd5e1; --slate-400: #94a3b8; --slate-500: #64748b;
    --slate-600: #475569; --slate-700: #334155; --slate-800: #1e293b;
    --slate-900: #0f172a;
    --orange-50: #fff7ed; --orange-100: #ffedd5; --orange-200: #fed7aa;
    --orange-500: #f97316; --orange-600: #ea580c;
    --blue-50: #eff6ff; --blue-100: #dbeafe; --blue-200: #bfdbfe;
    --blue-500: #3b82f6; --blue-600: #2563eb;
}

*, ::before, ::after { box-sizing: border-box; border-width: 0; border-style: solid; border-color: var(--slate-200); margin: 0; padding: 0; }
html { line-height: 1.5; -webkit-text-size-adjust: 100%; tab-size: 4; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }
body { background-color: var(--slate-50); color: var(--slate-800); -webkit-font-smoothing: antialiased; padding-bottom: 3rem; }
a { color: inherit; text-decoration: inherit; }
button, input, textarea { font-family: inherit; font-size: 100%; line-height: inherit; margin: 0; padding: 0; background: transparent; }
button { cursor: pointer; }
input:focus, textarea:focus { outline: 2px solid transparent; outline-offset: 2px; }

.max-w-7xl { max-width: 80rem; }
.mx-auto { margin-left: auto; margin-right: auto; }
.w-full { width: 100%; }
.min-w-0 { min-width: 0; }
.flex-1 { flex: 1 1 0%; }
.flex-none { flex: none; }

@media (min-width: 1536px) { .max-w-7xl { max-width: 85vw; } html { font-size: 17px; } }
@media (min-width: 2560px) { .max-w-7xl { max-width: 75vw; } html { font-size: 20px; } }

.flex { display: flex; } .grid { display: grid; } .hidden { display: none; }
.flex-col { flex-direction: column; } .items-center { align-items: center; }
.justify-between { justify-content: space-between; } .justify-center { justify-content: center; }
.gap-2 { gap: 0.5rem; } .gap-4 { gap: 1rem; } .gap-8 { gap: 2rem; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }

.sticky { position: sticky; } .fixed { position: fixed; } .absolute { position: absolute; } .relative { position: relative; }
.top-0 { top: 0px; } .top-24 { top: 6rem; } .inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.z-40 { z-index: 40; } .z-50 { z-index: 50; } .z-\[1200\] { z-index: 1200; }

.p-2 { padding: 0.5rem; } .p-3 { padding: 0.75rem; } .p-4 { padding: 1rem; } .p-5 { padding: 1.25rem; } .p-6 { padding: 1.5rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; } .px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; } .px-8 { padding-left: 2rem; padding-right: 2rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; } .py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; } .py-3\.5 { padding-top: 0.875rem; padding-bottom: 0.875rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; } .py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.mb-1 { margin-bottom: 0.25rem; } .mb-2 { margin-bottom: 0.5rem; } .mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; } .mb-5 { margin-bottom: 1.25rem; } .mb-6 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.25rem; } .mt-4 { margin-top: 1rem; } .ml-1 { margin-left: 0.25rem; }
.pt-4 { padding-top: 1rem; } .pt-6 { padding-top: 1.5rem; }
.space-y-2 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.5rem; }
.space-y-3 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.75rem; }
.space-y-4 > :not([hidden]) ~ :not([hidden]) { margin-top: 1rem; }
.space-y-6 > :not([hidden]) ~ :not([hidden]) { margin-top: 1.5rem; }
.max-w-sm { max-width: 24rem; } .max-w-xs { max-width: 20rem; } .max-w-\[120px\] { max-width: 120px; }
.w-12 { width: 3rem; } .h-12 { height: 3rem; } .h-20 { height: 5rem; }

.text-xs { font-size: 0.75rem; line-height: 1rem; } .text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; } .text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; } .text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; } .text-\[10px\] { font-size: 10px; }
.font-medium { font-weight: 500; } .font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; } .font-black { font-weight: 900; }
.text-center { text-align: center; } .text-right { text-align: right; } .text-left { text-align: left; }
.uppercase { text-transform: uppercase; } .tracking-tight { letter-spacing: -0.025em; }
.tracking-tighter { letter-spacing: -0.05em; } .tracking-widest { letter-spacing: 0.1em; }
.whitespace-nowrap { white-space: nowrap; } .truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.outline-none { outline: 2px solid transparent; outline-offset: 2px; }

.text-white { color: #fff; } .text-brand { color: var(--brand); }
.text-slate-400 { color: var(--slate-400); } .text-slate-500 { color: var(--slate-500); }
.text-slate-700 { color: var(--slate-700); } .text-slate-800 { color: var(--slate-800); }
.text-slate-900 { color: var(--slate-900); } .text-orange-500 { color: var(--orange-500); }
.text-orange-600 { color: var(--orange-600); } .text-blue-500 { color: var(--blue-500); }
.text-blue-600 { color: var(--blue-600); } .text-green-500 { color: #22c55e; }
.text-\[\#1677FF\] { color: #1677FF; }

.bg-white { background-color: #fff; } .bg-brand { background-color: var(--brand); }
.bg-slate-50 { background-color: var(--slate-50); } .bg-slate-100 { background-color: var(--slate-100); }
.bg-slate-900 { background-color: var(--slate-900); } .bg-slate-900\/20 { background-color: rgb(15 23 42 / 0.2); }
.bg-slate-900\/60 { background-color: rgb(15 23 42 / 0.6); } .bg-orange-50 { background-color: var(--orange-50); }
.bg-orange-100 { background-color: var(--orange-100); } .bg-blue-50 { background-color: var(--blue-50); }
.bg-blue-100 { background-color: var(--blue-100); } .bg-\[\#1677FF\] { background-color: #1677FF; }

.border { border-width: 1px; } .border-t { border-top-width: 1px; } .border-b { border-bottom-width: 1px; }
.border-transparent { border-color: transparent; } .border-slate-50 { border-color: var(--slate-50); }
.border-slate-100 { border-color: var(--slate-100); } .border-slate-200 { border-color: var(--slate-200); }
.border-dashed { border-style: dashed; }

.rounded { border-radius: 0.25rem; } .rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; } .rounded-2xl { border-radius: 1rem; }
.rounded-3xl { border-radius: 1.5rem; } .rounded-full { border-radius: 9999px; }
.shadow-sm { box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); }
.shadow-lg { box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1); }
.shadow-2xl { box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25); }
.shadow-inner { box-shadow: inset 0 2px 4px 0 rgb(0 0 0 / 0.05); }
.shadow-orange-200 { --tw-shadow-color: var(--orange-200); --tw-shadow: var(--tw-shadow-colored); }
.shadow-blue-200 { --tw-shadow-color: var(--blue-200); --tw-shadow: var(--tw-shadow-colored); }
.shadow-slate-200 { --tw-shadow-color: var(--slate-200); --tw-shadow: var(--tw-shadow-colored); }
.backdrop-blur-sm { backdrop-filter: blur(4px); }

.cursor-pointer { cursor: pointer; }
.transition { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-all { transition-property: all; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-transform { transition-property: transform; }
.duration-200 { transition-duration: 200ms; } .duration-300 { transition-duration: 300ms; }
.hover\:text-slate-600:hover { color: var(--slate-600); } .hover\:text-slate-800:hover { color: var(--slate-800); }
.hover\:bg-slate-200:hover { background-color: var(--slate-200); } .hover\:bg-black:hover { background-color: #000; }
.hover\:bg-orange-50:hover { background-color: var(--orange-50); } .hover\:bg-blue-50:hover { background-color: var(--blue-50); }
.hover\:bg-\[\#1677FF\]\/90:hover { background-color: rgb(22 119 255 / 0.9); }
.hover\:border-slate-300:hover { border-color: var(--slate-300); }
.hover\:border-orange-200:hover { border-color: var(--orange-200); } .hover\:border-blue-200:hover { border-color: var(--blue-200); }
.focus\:border-orange-500:focus { border-color: var(--orange-500); }
.focus\:ring-2:focus { box-shadow: 0 0 0 2px var(--orange-500); }
.active\:scale-95:active { transform: scale(.95); } .active\:scale-\[0\.98\]:active { transform: scale(.98); }
.group:hover .group-hover\:scale-110 { transform: scale(1.1); } .last\:border-0:last-child { border-width: 0; }

.overflow-hidden { overflow: hidden; } .overflow-x-auto { overflow-x: auto; } .overflow-y-auto { overflow-y: auto; }
.max-h-60 { max-height: 15rem; }
@keyframes spin { to { transform: rotate(360deg); } } .animate-spin { animation: spin 1s linear infinite; }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
.animate-in { animation-duration: 150ms; animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1); animation-fill-mode: both; }
.fade-in { animation-name: fade-in; }
@keyframes zoomIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
.zoom-in { animation-name: zoomIn; }

@media (min-width: 640px) { .sm\:inline { display: inline; } .sm\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 768px) { .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .md\:col-span-2 { grid-column: span 2 / span 2; } }
@media (min-width: 1024px) {
    .lg\:flex-row { flex-direction: row; } .lg\:flex-col { flex-direction: column; } .lg\:flex { display: flex; }
    .lg\:hidden { display: none; } .lg\:w-1\/5 { width: 20%; } .lg\:w-1\/4 { width: 25%; }
    .lg\:overflow-x-visible { overflow-x: visible; } .lg\:pb-0 { padding-bottom: 0px; } .lg\:opacity-40 { opacity: 0.4; }
}

.category-tab.active { background-color: white; color: var(--brand); border-color: var(--slate-200); box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1); }
.config-panel { display: none; } .config-panel.active { display: block; animation: slideUp 0.3s ease-out; }
@keyframes slideUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.custom-select-wrapper { position: relative; width: 100%; }
.select-dropdown { position: absolute; top: 105%; left: 0; right: 0; z-index: 50; background: white; border: 1px solid var(--slate-200); border-radius: 0.75rem; box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1); max-height: 300px; overflow: hidden; display: none; }
.select-dropdown.show { display: block; }
.period-option.active { border-color: var(--brand); background-color: var(--orange-50); color: var(--brand); }