/* Dashboard 大屏样式 */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  min-height: 100vh;
  color: #333;
  padding: 12px;
  overflow: hidden;
  position: relative;
  background: #f0f4f8; /* Fresh base color */
}

/* --- Fresh Tech Background Ambience --- */
.bg-shapes {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  overflow: hidden;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

.shape {
  position: absolute;
  filter: blur(60px);
  opacity: 0.6;
  animation: floatShape 25s infinite alternate ease-in-out;
}

.shape-1 {
  top: -10%;
  left: -5%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, rgba(78, 205, 196, 0.15), transparent 70%);
  animation-delay: 0s;
}

.shape-2 {
  bottom: -10%;
  right: -5%;
  width: 45vw;
  height: 45vw;
  background: radial-gradient(circle, rgba(93, 173, 226, 0.15), transparent 70%);
  animation-delay: -5s;
}

.shape-3 {
  top: 30%;
  right: 20%;
  width: 30vw;
  height: 30vw;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.4), transparent 70%);
  animation-delay: -10s;
}

.shape-4 {
  bottom: 20%;
  left: 10%;
  width: 25vw;
  height: 25vw;
  background: radial-gradient(circle, rgba(68, 189, 158, 0.1), transparent 70%);
  animation-delay: -15s;
}

@keyframes floatShape {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 60px) scale(1.1); }
}

.background-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

/* Removed old stars and nebula styles */

/* Visual Core (Background Watermark) - Adapted for Light Theme */
.reactor-container-bg {
  position: absolute;
  top: 50%;
  width: 800px;
  height: 800px;
  opacity: 0.6; /* Increased opacity for light theme visibility */
  pointer-events: none;
}

.reactor-container-bg.position-left {
  left: -200px;
  transform: translateY(-50%);
}

.reactor-container-bg.position-right {
  right: -200px;
  transform: translateY(-50%);
}

/* Core removed, keeping only rings for cleaner look */
.reactor-core { display: none; }

.reactor-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  background: transparent;
  transform: translate(-50%, -50%);
}

/* Thinner, cleaner rings for fresh style */
.ring-1 { 
  width: 350px; 
  height: 350px; 
  border: 1px dashed rgba(78, 205, 196, 0.3);
  animation: spin 30s linear infinite; 
}
.ring-2 { 
  width: 550px; 
  height: 550px; 
  border: 1px solid rgba(78, 205, 196, 0.15);
  animation: spin 45s linear infinite reverse; 
}
.ring-3 { 
  width: 750px; 
  height: 750px; 
  border: 40px solid rgba(255, 255, 255, 0.2); /* Soft white halo ring */
  animation: pulseNebula 8s ease-in-out infinite;
}

/* 3D Decoration Layers */
.decoration-3d {
  position: absolute;
  top: 50%;
  width: 180px;
  height: 180px;
  perspective: 1000px;
  pointer-events: none;
  z-index: -1;
  opacity: 0.6;
}

.decoration-3d.left {
  left: 2%;
  top: 45%;
  transform: translateY(-50%);
}

.decoration-3d.right {
  right: 2%;
  top: 55%;
  transform: translateY(-50%);
}

.tech-cube { display: none; } /* Legacy cleanup */

/* 3D Model Styles */
.model-3d-container {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: floatModel 6s ease-in-out infinite;
}

.model-3d {
  position: relative;
  transform-style: preserve-3d;
  /* Continuous full rotation */
  animation: spin360 30s linear infinite;
}

.cube {
  position: absolute;
  transform-style: preserve-3d;
}

.face {
  position: absolute;
  border: 1px solid rgba(78, 205, 196, 0.15); /* Very subtle border */
  background: rgba(78, 205, 196, 0.05); /* Highly transparent base */
  box-shadow: 0 0 15px rgba(78, 205, 196, 0.05); /* Soft glow instead of inner shadow */
}

/* Face Lighting Simulation - Very subtle variations */
.face.front  { background: rgba(78, 205, 196, 0.08); }
.face.right  { background: rgba(68, 189, 158, 0.08); }
.face.left   { background: rgba(93, 173, 226, 0.08); }
.face.top    { background: rgba(122, 221, 216, 0.1); }
.face.bottom { background: rgba(52, 168, 140, 0.1); }
.face.back   { background: rgba(78, 205, 196, 0.08); }

/* --- 3D Chat Bubble Configuration --- */
/* Main Body: 60x40x20 */
.chat-bubble .cube.main {
  width: 80px;
  height: 60px;
  transform: translate3d(-40px, -30px, 0); /* Center it */
}

.chat-bubble .main .face { width: 80px; height: 60px; } /* Default front/back */
.chat-bubble .main .face.front  { transform: rotateY(0deg) translateZ(15px); display: flex; align-items: center; justify-content: center; font-weight: bold; color: white; font-size: 24px; letter-spacing: 2px; }
.chat-bubble .main .face.back   { transform: rotateY(180deg) translateZ(15px); }
.chat-bubble .main .face.right  { width: 30px; height: 60px; transform: rotateY(90deg) translateZ(65px); } /* W=Depth, Z=Width/2 + offset? No. translateZ = Width/2 */
/* Correct cube logic:
   Front/Back: W x H, Z = D/2
   Right/Left: D x H, Z = W/2
   Top/Bottom: W x D, Z = H/2
*/
.chat-bubble .main .face.right { width: 30px; transform: rotateY(90deg) translateZ(40px); }
.chat-bubble .main .face.left  { width: 30px; transform: rotateY(-90deg) translateZ(40px); }
.chat-bubble .main .face.top   { height: 30px; transform: rotateX(90deg) translateZ(30px); }
.chat-bubble .main .face.bottom{ height: 30px; transform: rotateX(-90deg) translateZ(30px); }

/* Tail: 15x15x30, offset to bottom right */
.chat-bubble .cube.tail {
  width: 20px;
  height: 20px;
  transform: translate3d(20px, 20px, 0) rotateZ(45deg); /* Position relative to center */
}
.chat-bubble .tail .face { width: 20px; height: 20px; }
.chat-bubble .tail .face.front  { transform: rotateY(0deg) translateZ(15px); }
.chat-bubble .tail .face.back   { transform: rotateY(180deg) translateZ(15px); }
.chat-bubble .tail .face.right  { width: 30px; transform: rotateY(90deg) translateZ(10px); }
.chat-bubble .tail .face.left   { width: 30px; transform: rotateY(-90deg) translateZ(10px); }
.chat-bubble .tail .face.top    { height: 30px; transform: rotateX(90deg) translateZ(10px); }
.chat-bubble .tail .face.bottom { height: 30px; transform: rotateX(-90deg) translateZ(10px); }


/* --- 3D Phone Configuration --- */
/* 
   Structure:
   - Handle: Vertical bar
   - Ear Piece: Top box
   - Mouth Piece: Bottom box
*/

/* Handle: 25W x 60H x 20D */
.phone .cube.handle {
  width: 25px;
  height: 60px;
  transform: translate3d(-12.5px, -30px, 0);
}
.phone .handle .face.front  { width: 25px; height: 60px; transform: translateZ(10px); }
.phone .handle .face.back   { width: 25px; height: 60px; transform: rotateY(180deg) translateZ(10px); }
.phone .handle .face.right  { width: 20px; height: 60px; transform: rotateY(90deg) translateZ(12.5px); }
.phone .handle .face.left   { width: 20px; height: 60px; transform: rotateY(-90deg) translateZ(12.5px); }
.phone .handle .face.top    { width: 25px; height: 20px; transform: rotateX(90deg) translateZ(30px); }
.phone .handle .face.bottom { width: 25px; height: 20px; transform: rotateX(-90deg) translateZ(30px); }

/* Ear Piece: 40W x 35H x 30D. Offset Y -40, Z 10 */
.phone .cube.ear-piece {
  width: 40px;
  height: 35px;
  transform: translate3d(-20px, -55px, 15px) rotateX(-15deg); /* Slight tilt */
}
.phone .ear-piece .face.front  { width: 40px; height: 35px; transform: translateZ(15px); }
.phone .ear-piece .face.back   { width: 40px; height: 35px; transform: rotateY(180deg) translateZ(15px); }
.phone .ear-piece .face.right  { width: 30px; height: 35px; transform: rotateY(90deg) translateZ(20px); }
.phone .ear-piece .face.left   { width: 30px; height: 35px; transform: rotateY(-90deg) translateZ(20px); }
.phone .ear-piece .face.top    { width: 40px; height: 30px; transform: rotateX(90deg) translateZ(17.5px); }
.phone .ear-piece .face.bottom { width: 40px; height: 30px; transform: rotateX(-90deg) translateZ(17.5px); }

/* Mouth Piece: 40W x 35H x 30D. Offset Y +30, Z 10 */
.phone .cube.mouth-piece {
  width: 40px;
  height: 35px;
  transform: translate3d(-20px, 20px, 15px) rotateX(15deg);
}
.phone .mouth-piece .face.front  { width: 40px; height: 35px; transform: translateZ(15px); }
.phone .mouth-piece .face.back   { width: 40px; height: 35px; transform: rotateY(180deg) translateZ(15px); }
.phone .mouth-piece .face.right  { width: 30px; height: 35px; transform: rotateY(90deg) translateZ(20px); }
.phone .mouth-piece .face.left   { width: 30px; height: 35px; transform: rotateY(-90deg) translateZ(20px); }
.phone .mouth-piece .face.top    { width: 40px; height: 30px; transform: rotateX(90deg) translateZ(17.5px); }
.phone .mouth-piece .face.bottom { width: 40px; height: 30px; transform: rotateX(-90deg) translateZ(17.5px); }


@keyframes floatModel {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

@keyframes spin360 {
  0% { transform: rotateX(-10deg) rotateY(0deg); }
  100% { transform: rotateX(-10deg) rotateY(360deg); }
}

/* Animations */
@keyframes spin { 0% { transform: translate(-50%, -50%) rotate(0deg); } 100% { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes pulseNebula { 0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.5; } 50% { transform: translate(-50%, -50%) scale(1.02); opacity: 0.8; } }
@keyframes scanline { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }

.main-container {
  height: calc(100vh - 24px);
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}

/* Remove old top scanline */
.card::before {
  display: none;
}

/* --- Continuous Circuit Flow Animation (20s Cycle) --- */
/* 
   Cycle Time: 20s
   Speed: ~1 unit/2s (Height=1u, AgentWidth=1u, SummaryWidth=3u)
   
   Sequence:
   1. Summary Top (L->R): 0-6s (3u)
   2. Summary Right (T->B): 6-8s (1u) -> SPLIT
   
   Branch A (Bus Left):
   3. Agent Top (R->L): 8-10s (1u)
   4. Status Top (R->L): 10-12s (1u)
   5. KPI Top (R->L): 12-14s (1u)
   
   Branch B (Card Loops):
   3. Agent Right (T->B): 8-10s
      Agent Bottom (R->L): 10-12s
      Agent Left (B->T): 12-14s
      
   4. Status Right (T->B): 10-12s
      Status Bottom (R->L): 12-14s
      Status Left (B->T): 14-16s
      
   5. KPI Right (T->B): 12-14s
      KPI Bottom (R->L): 14-16s
      KPI Left (B->T): 16-18s -> CONNECT TO SOURCE
   
   Return:
   6. Summary Left (B->T): 18-20s (1u) -> Loop to Start
*/

.running-border {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
  border-radius: 12px;
}

.running-border span {
  position: absolute;
  opacity: 0;
}

/* --- 1. Summary Card --- */
/* Top: L->R (0-6s) */
.card-summary .running-border span:nth-child(1) {
  top: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(90deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-ltr-30 20s linear infinite;
  animation-delay: 0s;
}
/* Right: T->B (6-8s) */
.card-summary .running-border span:nth-child(2) {
  top: 0; right: 0; width: 2px; height: 100%;
  background: linear-gradient(180deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-ttb-10 20s linear infinite;
  animation-delay: 6s;
}
/* Left: B->T (18-20s) - Return Path */
.card-summary .running-border span:nth-child(4) {
  display: block; /* Enable Left */
  top: 0; left: 0; width: 2px; height: 100%;
  background: linear-gradient(0deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-btt-10 20s linear infinite;
  animation-delay: 18s;
}
.card-summary .running-border span:nth-child(3) { display: none; }


/* --- 2. Agent Card --- */
/* Top: R->L (8-10s) */
.card-agent .running-border span:nth-child(1) {
  top: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(270deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-rtl-10 20s linear infinite;
  animation-delay: 8s;
}
/* Right: T->B (8-10s) */
.card-agent .running-border span:nth-child(2) {
  top: 0; right: 0; width: 2px; height: 100%;
  background: linear-gradient(180deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-ttb-10 20s linear infinite;
  animation-delay: 8s;
}
/* Bottom: R->L (10-12s) */
.card-agent .running-border span:nth-child(3) {
  bottom: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(270deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-rtl-10 20s linear infinite;
  animation-delay: 10s;
}
/* Left: B->T (12-14s) */
.card-agent .running-border span:nth-child(4) {
  top: 0; left: 0; width: 2px; height: 100%;
  background: linear-gradient(0deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-btt-10 20s linear infinite;
  animation-delay: 12s;
}


/* --- 3. Status Card --- */
/* Top: R->L (10-12s) */
.card-status .running-border span:nth-child(1) {
  top: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(270deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-rtl-10 20s linear infinite;
  animation-delay: 10s;
}
/* Right: T->B (10-12s) */
.card-status .running-border span:nth-child(2) {
  top: 0; right: 0; width: 2px; height: 100%;
  background: linear-gradient(180deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-ttb-10 20s linear infinite;
  animation-delay: 10s;
}
/* Bottom: R->L (12-14s) */
.card-status .running-border span:nth-child(3) {
  bottom: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(270deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-rtl-10 20s linear infinite;
  animation-delay: 12s;
}
/* Left: B->T (14-16s) */
.card-status .running-border span:nth-child(4) {
  top: 0; left: 0; width: 2px; height: 100%;
  background: linear-gradient(0deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-btt-10 20s linear infinite;
  animation-delay: 14s;
}


/* --- 4. KPI Card --- */
/* Top: R->L (12-14s) */
.card-kpi .running-border span:nth-child(1) {
  top: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(270deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-rtl-10 20s linear infinite;
  animation-delay: 12s;
}
/* Right: T->B (12-14s) */
.card-kpi .running-border span:nth-child(2) {
  top: 0; right: 0; width: 2px; height: 100%;
  background: linear-gradient(180deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-ttb-10 20s linear infinite;
  animation-delay: 12s;
}
/* Bottom: R->L (14-16s) */
.card-kpi .running-border span:nth-child(3) {
  bottom: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(270deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 20% 100%; background-repeat: no-repeat;
  animation: snake-rtl-10 20s linear infinite;
  animation-delay: 14s;
}
/* Left: B->T (16-18s) - Leads to Summary Left */
.card-kpi .running-border span:nth-child(4) {
  top: 0; left: 0; width: 2px; height: 100%;
  background: linear-gradient(0deg, transparent 0%, #4ecdc4 50%, transparent 100%);
  background-size: 100% 20%; background-repeat: no-repeat;
  animation: snake-btt-10 20s linear infinite;
  animation-delay: 16s;
}


/* --- Keyframes (Percentage based on 20s) --- */

/* 30% duration (6s) */
@keyframes snake-ltr-30 {
  0% { background-position: -20% 0; opacity: 1; }
  30% { background-position: 120% 0; opacity: 1; }
  30.1% { opacity: 0; }
  100% { opacity: 0; }
}

/* 10% duration (2s) */
@keyframes snake-ttb-10 {
  0% { background-position: 0 -20%; opacity: 1; }
  10% { background-position: 0 120%; opacity: 1; }
  10.1% { opacity: 0; }
  100% { opacity: 0; }
}

@keyframes snake-rtl-10 {
  0% { background-position: 120% 0; opacity: 1; }
  10% { background-position: -20% 0; opacity: 1; }
  10.1% { opacity: 0; }
  100% { opacity: 0; }
}

@keyframes snake-btt-10 {
  0% { background-position: 0 120%; opacity: 1; }
  10% { background-position: 0 -20%; opacity: 1; }
  10.1% { opacity: 0; }
  100% { opacity: 0; }
}


/* --- Corner Flashes (Sync Points) --- */
/* Summary TL (0s) */
.card-summary .running-border::before {
  content: ""; position: absolute; top: -4px; left: -4px;
  width: 8px; height: 8px; background: #fff; border-radius: 50%;
  box-shadow: 0 0 10px #4ecdc4;
  animation: flash-dot 20s infinite; animation-delay: 0s; z-index: 2;
}
/* Summary BR / Agent TR (6s) */
.card-summary .running-border::after {
  content: ""; position: absolute; bottom: -4px; right: -4px;
  width: 8px; height: 8px; background: #fff; border-radius: 50%;
  box-shadow: 0 0 10px #4ecdc4;
  animation: flash-dot 20s infinite; animation-delay: 6s; z-index: 2;
}
/* Agent TL / Status TR (8s) */
.card-agent .running-border::before {
  content: ""; position: absolute; top: -4px; left: -4px;
  width: 8px; height: 8px; background: #fff; border-radius: 50%;
  box-shadow: 0 0 10px #4ecdc4;
  animation: flash-dot 20s infinite; animation-delay: 8s; z-index: 2;
}
/* Status TL / KPI TR (10s) */
.card-status .running-border::before {
  content: ""; position: absolute; top: -4px; left: -4px;
  width: 8px; height: 8px; background: #fff; border-radius: 50%;
  box-shadow: 0 0 10px #4ecdc4;
  animation: flash-dot 20s infinite; animation-delay: 10s; z-index: 2;
}
/* KPI TL (12s) */
.card-kpi .running-border::before {
  content: ""; position: absolute; top: -4px; left: -4px;
  width: 8px; height: 8px; background: #fff; border-radius: 50%;
  box-shadow: 0 0 10px #4ecdc4;
  animation: flash-dot 20s infinite; animation-delay: 12s; z-index: 2;
}
/* KPI BL (16s) - Start of Upward Return */
.card-kpi .running-border::after {
  content: ""; display: block; position: absolute; bottom: -4px; left: -4px;
  width: 8px; height: 8px; background: #fff; border-radius: 50%;
  box-shadow: 0 0 10px #4ecdc4;
  animation: flash-dot 20s infinite; animation-delay: 16s; z-index: 2;
}
/* Summary BL (18s) - Handover from KPI Left to Summary Left */
/* We can add a pseudo on a different element or just rely on Summary Left start */
/* Let's add ::after on KPI Top Left? No, occupied. 
   Use an extra span or just visual timing. 
   Summary Left starts at 18s. 
*/

.card-agent .running-border::after,
.card-status .running-border::after { display: none; }

@keyframes flash-dot {
  0% { transform: scale(0); opacity: 0; }
  1% { transform: scale(1.5); opacity: 1; }
  5% { transform: scale(0); opacity: 0; }
  100% { opacity: 0; }
}

.card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* 顶部筛选区域 */
.header-bar {
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.page-title {
  font-size: 22px;
  font-weight: 600;
  color: #2c3e50;
  display: flex;
  align-items: center;
  gap: 10px;
}

.page-title::before {
  content: "";
  width: 4px;
  height: 22px;
  background: linear-gradient(180deg, #4ecdc4, #44bd9e);
  border-radius: 2px;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 15px;
}

.fullscreen-btn {
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(78, 205, 196, 0.3);
  color: #7f8c8d;
  border-radius: 50%; /* Make circular */
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.4s ease;
  backdrop-filter: blur(4px);
}

.fullscreen-btn:hover {
  border-color: #4ecdc4;
  color: #4ecdc4;
  background: linear-gradient(135deg, rgba(78, 205, 196, 0.1), rgba(68, 189, 158, 0.1));
  box-shadow: 0 0 15px rgba(78, 205, 196, 0.3);
  transform: rotate(180deg); /* Subtle interaction */
}

.fullscreen-btn svg {
  width: 18px;
  height: 18px;
}

.filter-label {
  color: #7f8c8d;
  font-size: 14px;
}

.filter-sep {
  color: #4ecdc4;
  font-weight: 600;
}

.fresh-input {
  background: #f8f9fa;
  border: 1px solid #e0e0e0;
  color: #495057;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  outline: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

.fresh-input:focus {
  border-color: #4ecdc4;
  box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.15);
}

.fresh-btn {
  background: linear-gradient(135deg, #4ecdc4 0%, #44bd9e 100%);
  border: none;
  color: white;
  padding: 8px 24px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.fresh-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(78, 205, 196, 0.4);
}

/* 第一行区域 */
.summary-section {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 14px;
}

.section-header {
  display: flex;
  align-items: center;
  margin-bottom: 16px;
  flex-shrink: 0;
}

.section-header .bar {
  width: 4px;
  height: 24px;
  background: linear-gradient(to bottom, #4ecdc4, #44bd9e);
  margin-right: 12px;
  border-radius: 2px;
}

.section-title {
  font-size: 18px;
  font-weight: 600;
  color: #2c3e50;
}

.summary-content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 12px;
  flex: 1;
  min-height: 0;
}

.kpi-sidebar {
  min-width: 0;
  overflow-y: auto;
  padding-right: 10px;
}

.kpi-item {
  background: linear-gradient(135deg, #f8fffe 0%, #f0faf8 100%);
  border: 1px solid #e8f5f3;
  border-left: 3px solid #4ecdc4;
  border-radius: 8px;
  padding: 8px 14px;
  margin-bottom: 8px;
  transition: all 0.2s ease;
}

.kpi-item:hover {
  background: #e8f8f5;
  border-color: #4ecdc4;
  box-shadow: 0 2px 8px rgba(78, 205, 196, 0.15);
}

.kpi-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.data-label {
  color: #7f8c8d;
  font-size: 14px;
}

.data-value {
  font-size: 24px;
  font-weight: 600;
  color: #4ecdc4;
}

.progress-bar {
  height: 6px;
  background: rgba(232, 245, 243, 0.6);
  border-radius: 3px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, #4ecdc4, #44bd9e);
  position: relative;
  width: 0; /* Default to 0 for animation */
  transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 0 8px rgba(78, 205, 196, 0.4);
}

/* Shimmer Effect */
.progress-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.4) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: translateX(-100%);
  animation: shimmer 2s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

/* Striped Pattern */
.progress-fill::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background-image: linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.15) 25%,
    transparent 25%,
    transparent 50%,
    rgba(255, 255, 255, 0.15) 50%,
    rgba(255, 255, 255, 0.15) 75%,
    transparent 75%,
    transparent
  );
  background-size: 1rem 1rem;
  z-index: 1;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.chart-area {
  flex: 1;
  min-height: 0;
}

#monthlyChart,
#agentChart {
  width: 100%;
  height: 100%;
}

/* 第二行三列 */
.bottom-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  flex: 1;
  min-height: 0;
}

.bottom-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 14px;
  overflow: hidden;
}

.card-title {
  text-align: center;
  padding-bottom: 10px;
  margin-bottom: 14px;
  border-bottom: 1px solid #e8f5f3;
  flex-shrink: 0;
  font-size: 16px;
  font-weight: 600;
  color: #2c3e50;
}

.card-content {
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.card-content.custom-scrollbar {
  overflow-y: auto;
  overflow-x: hidden;
}

/* 坐席列表 */
.agent-item {
  background: #fafafa;
  border: 1px solid #f0f0f0;
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 8px;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.agent-item:hover, .agent-item.highlight-update {
  background: #f0faf8;
  border-color: #4ecdc4;
  box-shadow: 0 2px 8px rgba(78, 205, 196, 0.15);
}

@keyframes highlight-pulse {
  0% { background-color: #f0faf8; border-color: #4ecdc4; box-shadow: 0 2px 8px rgba(78, 205, 196, 0.15); }
  50% { background-color: rgba(78, 205, 196, 0.15); border-color: #4ecdc4; }
  100% { background-color: #f0faf8; border-color: #4ecdc4; box-shadow: 0 2px 8px rgba(78, 205, 196, 0.15); }
}

.agent-item.highlight-update {
  animation: highlight-pulse 1.5s ease-out;
}

.agent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
}

.agent-info {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 120px;
}

.agent-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #e8f8f5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  color: #4ecdc4;
  border: 1.5px solid #b2ece5;
}

.agent-name {
  color: #2c3e50;
  font-weight: 500;
  font-size: 14px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.agent-status {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 80px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.status-online {
  background: #4ecdc4;
}

.status-idle {
  background: #5dade2;
}

.status-rest {
  background: #f7dc6f;
}

.status-text {
  color: #95a5a6;
  font-size: 13px;
}

.agent-time {
  color: #4ecdc4;
  font-family: "SF Mono", Monaco, monospace;
  font-size: 13px;
  font-weight: 500;
  width: 70px;
  text-align: right;
}

/* 自定义滚动条 */
.custom-scrollbar::-webkit-scrollbar {
  width: 4px;
}

.custom-scrollbar::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 2px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
  background: #4ecdc4;
  border-radius: 2px;
}

/* 暂无数据样式 */
.no-data-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  color: #95a5a6;
  padding: 20px;
  animation: fadeIn 0.8s ease-out;
}

.no-data-icon {
  width: 100px;
  height: 100px;
  margin-bottom: 10px;
  opacity: 0.9;
}

/* SVG 内部动画类 */
.tech-circle-outer {
  transform-origin: center;
  animation: spin 20s linear infinite;
}

.tech-circle-inner {
  transform-origin: center;
  animation: pulse-ring 3s ease-in-out infinite;
}

.tech-phone-group {
  transform-origin: center;
  animation: float-phone 4s ease-in-out infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.95); opacity: 0.5; }
  50% { transform: scale(1.05); opacity: 0.8; }
  100% { transform: scale(0.95); opacity: 0.5; }
}

@keyframes float-phone {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.no-data-text {
  font-size: 14px;
  color: #7f8c8d;
  letter-spacing: 2px;
  font-weight: 500;
  margin-top: 5px;
  background: linear-gradient(90deg, #4ecdc4, #44bd9e);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0.8;
}

/* 全屏样式 */
body.fullscreen {
  padding: 0;
}

body.fullscreen .main-container {
  max-width: none;
  height: 100vh;
  padding: 12px;
}

/* Flatpickr 清新风格 */
.flatpickr-calendar {
  background: #fff !important;
  border: 1px solid #e9ecef !important;
  border-radius: 12px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12) !important;
}

.flatpickr-current-month {
  color: #2c3e50 !important;
  font-weight: 600 !important;
}

.flatpickr-weekday {
  color: #7f8c8d !important;
  font-weight: 600 !important;
}

.flatpickr-day {
  color: #2c3e50 !important;
  border-radius: 8px !important;
}

.flatpickr-day:hover {
  background: #e8f8f5 !important;
  border-color: #4ecdc4 !important;
}

.flatpickr-day.today {
  border-color: #4ecdc4 !important;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
  background: #4ecdc4 !important;
  border-color: #4ecdc4 !important;
  color: white !important;
}

.flatpickr-day.inRange {
  background: rgba(78, 205, 196, 0.2) !important;
  border-color: rgba(78, 205, 196, 0.3) !important;
}

.flatpickr-months .flatpickr-prev-month,
.flatpickr-months .flatpickr-next-month {
  fill: #4ecdc4 !important;
}
