index.css 4.97 KB
@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
  /* ===== Light theme (clean, enterprise) ===== */
  :root {
    --background: 215 18% 97%;
    --foreground: 222 24% 13%;
    --card: 0 0% 100%;
    --card-foreground: 222 24% 13%;
    --popover: 0 0% 100%;
    --popover-foreground: 222 24% 13%;
    --primary: 152 48% 38%;
    --primary-foreground: 0 0% 100%;
    --secondary: 215 16% 95%;
    --secondary-foreground: 222 24% 20%;
    --muted: 215 14% 94%;
    --muted-foreground: 215 12% 44%;
    --accent: 215 16% 92%;
    --accent-foreground: 222 24% 20%;
    --destructive: 0 72% 51%;
    --destructive-foreground: 0 0% 100%;
    --border: 215 16% 88%;
    --input: 215 16% 86%;
    --ring: 152 48% 38%;
    --radius: 0.85rem;
  }

  /* ===== Dark theme (premium, neutral graphite) ===== */
  .dark {
    --background: 220 16% 5%;
    --foreground: 215 18% 91%;
    --card: 220 13% 12%;
    --card-foreground: 215 18% 91%;
    --popover: 220 14% 10%;
    --popover-foreground: 215 18% 91%;
    --primary: 152 45% 48%;
    --primary-foreground: 220 24% 8%;
    --secondary: 220 11% 17%;
    --secondary-foreground: 215 18% 91%;
    --muted: 220 9% 15%;
    --muted-foreground: 215 12% 64%;
    --accent: 220 12% 19%;
    --accent-foreground: 215 18% 91%;
    --destructive: 0 72% 58%;
    --destructive-foreground: 0 0% 100%;
    --border: 220 10% 20%;
    --input: 220 10% 20%;
    --ring: 152 45% 48%;
  }
}

@layer base {
  * {
    @apply border-border;
  }
  html {
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }
  body {
    @apply bg-background text-foreground;
    margin: 0;
    font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI',
      Roboto, 'Helvetica Neue', Arial, 'PingFang SC', 'Microsoft YaHei', sans-serif;
    font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
  }

  /* Ambient background: extremely faint neutral haze (no colored glow) */
  body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
      radial-gradient(
        900px 500px at 12% -8%,
        hsl(215 14% 55% / 0.05),
        transparent 60%
      ),
      radial-gradient(
        800px 500px at 100% 0%,
        hsl(205 12% 50% / 0.04),
        transparent 55%
      );
  }
  .dark body::before {
    background:
      radial-gradient(
        900px 520px at 10% -10%,
        hsl(215 12% 50% / 0.06),
        transparent 60%
      ),
      radial-gradient(
        820px 520px at 100% -5%,
        hsl(200 10% 45% / 0.05),
        transparent 55%
      );
  }
}

@layer components {
  /* Brand surface: single-hue emerald, weighted depth (no rainbow gradient) */
  .brand-gradient {
    background-image: linear-gradient(
      135deg,
      hsl(152 44% 34%) 0%,
      hsl(152 50% 50%) 100%
    );
  }
  .brand-text {
    color: hsl(152 48% 32%);
  }
  .dark .brand-text {
    color: hsl(152 46% 58%);
  }
  .glass {
    @apply backdrop-blur-xl;
  }
  .glass-dark {
    background: hsl(222 14% 9% / 0.7);
  }

  /* Shimmering skeleton / pulse */
  .shimmer {
    background: linear-gradient(
      90deg,
      transparent,
      hsl(220 22% 92% / 0.4),
      transparent
    );
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
  }
  @keyframes shimmer {
    0% {
      background-position: -200% 0;
    }
    100% {
      background-position: 200% 0;
    }
  }

  /* Connection pulse ring */
  .pulse-ring {
    position: relative;
  }
  .pulse-ring::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 9999px;
    border: 2px solid currentColor;
    opacity: 0.6;
    animation: pulse-ring 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite;
  }
  @keyframes pulse-ring {
    0% {
      transform: scale(0.8);
      opacity: 0.7;
    }
    80%,
    100% {
      transform: scale(2.1);
      opacity: 0;
    }
  }

  .animate-fade-in {
    animation: fade-in 0.4s ease both;
  }
  @keyframes fade-in {
    from {
      opacity: 0;
      transform: translateY(6px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  .animate-slide-up {
    animation: slide-up 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
  }
  @keyframes slide-up {
    from {
      opacity: 0;
      transform: translateY(14px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
}

@layer utilities {
  .scrollbar-thin {
    scrollbar-width: thin;
    scrollbar-color: hsl(var(--border)) transparent;
  }
  .scrollbar-thin::-webkit-scrollbar {
    width: 8px;
    height: 8px;
  }
  .scrollbar-thin::-webkit-scrollbar-thumb {
    background: hsl(var(--border));
    border-radius: 9999px;
  }
  .scrollbar-thin::-webkit-scrollbar-thumb:hover {
    background: hsl(var(--muted-foreground) / 0.5);
  }
  .scrollbar-thin::-webkit-scrollbar-track {
    background: transparent;
  }
}

/* 日志终端 */
.log-terminal {
  font-family: ui-monospace, SFMono-Regular, 'JetBrains Mono', Menlo, Consolas,
    'Liberation Mono', monospace;
  font-size: 12.5px;
  line-height: 1.65;
}