body.loading-active { overflow: hidden; }
.loading-overlay{
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 100;
    top: 0;
    width: 100%;
    height: 100vh;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    transition: all 0.3s ease;
}
.loading-overlay.hidden{
  display: none;
}
.loader-container {
    position: relative;
    width: 128px;
    height: 128px;
  }

  .la-line-spin-clockwise-fade, .la-line-spin-clockwise-fade > li {
    position: relative;
    box-sizing: border-box;
  }

  .la-line-spin-clockwise-fade {
    display: block;
    font-size: 0;
    color: #fff;
    width: 100%;
    height: 100%;
  }

  .la-line-spin-clockwise-fade > li {
    display: inline-block;
    float: none;
    background-color: currentColor;
    border: 0 solid currentColor;
  }

  .la-line-spin-clockwise-fade > li {
    position: absolute;
    width: 40px;
    height: 55px;
    margin: 2px;
    margin-top: -5px;
    margin-left: -1px;
    border-radius: 30px;
    animation: line-spin-clockwise-fade 3.5s infinite ease-in-out;
  }

  /* 新增殘影效果 */
  .la-line-spin-clockwise-fade > li::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 30px;
    opacity: 0.5;
    filter: blur(5px);
    z-index: -1;
  }

  .la-line-spin-clockwise-fade > li:nth-child(1) {
    top: 15%;
    left: 50%;
    background-color: rgba(255, 170, 1, 0.8);
    /* border: 2px solid #ffd42a; */
    border:1px solid rgba(255, 255, 255, 0.5);
    transform: rotate(0deg);
    animation-delay: -1.2s;
    --rotation: 0deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(1)::before {
    background-color: rgba(255, 170, 1, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(2) {
    top: 25.2512626585%;
    left: 74.7487373415%;
    background-color: rgba(241, 234, 12, 0.8);
    border:1px solid rgba(255, 255, 255, 0.5);
    /* border: 2px solid #f1ea0c; */
    transform: rotate(45deg);
    animation-delay: -1.0s;
    --rotation: 45deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(2)::before {
    background-color: rgba(241, 234, 12, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(3) {
    background-color: rgba(102, 169, 3, 0.8);
    border: 2px solid #66a903;
    top: 50%;
    left: 85%;
    transform: rotate(90deg);
    animation-delay: -0.8s;
    --rotation: 90deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(3)::before {
    background-color: rgba(102, 169, 3, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(4) {
    background-color: rgba(2, 177, 118, 0.8);
    border: 2px solid #02b176;
    top: 74.7487373415%;
    left: 74.7487373415%;
    transform: rotate(135deg);
    animation-delay: -0.6s;
    --rotation: 135deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(4)::before {
    background-color: rgba(2, 177, 118, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(5) {
    background-color: rgba(0, 177, 227, 0.8);
    border: 2px solid #00b1e3;
    top: 84.9999999974%;
    left: 50.0000000004%;
    transform: rotate(180deg);
    animation-delay: -0.4s;
    --rotation: 180deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(5)::before {
    background-color: rgba(0, 177, 227, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(6) {
    background-color: rgba(144, 68, 199, 0.8);
    border: 2px solid #9044c7;
    top: 74.7487369862%;
    left: 25.2512627193%;
    transform: rotate(225deg);
    animation-delay: -0.2s;
    --rotation: 225deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(6)::before {
    background-color: rgba(144, 68, 199, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(7) {
    background-color: rgba(207, 0, 110, 0.8);
    border: 2px solid #cf006e;
    top: 49.9999806189%;
    left: 15.0000039834%;
    transform: rotate(270deg);
    animation-delay: 0s;
    --rotation: 270deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(7)::before {
    background-color: rgba(207, 0, 110, 0.4);
  }

  .la-line-spin-clockwise-fade > li:nth-child(8) {
    background-color: rgba(255, 0, 0, 0.8);
    border: 2px solid #ff0000;
    top: 25.2506949798%;
    left: 25.2513989292%;
    transform: rotate(315deg);
    animation-delay: 0.2s;
    --rotation: 315deg;
  }
  .la-line-spin-clockwise-fade > li:nth-child(8)::before {
    background-color: rgba(255, 0, 0, 0.4);
  }

  /* 修改動畫關鍵幀，新增殘影效果 */
  @keyframes line-spin-clockwise-fade {
    0%, 100% {
      opacity: 1;
      transform: translate(-50%, -50%) rotate(var(--rotation)) scale(1);
      filter: blur(0);
    }
    25% {
      opacity: 0.7;
      transform: translate(-50%, -50%) rotate(calc(var(--rotation) + 90deg)) scale(1.1);
      filter: blur(2px);
    }
    50% {
      opacity: 0.4;
      transform: translate(-50%, -50%) rotate(calc(var(--rotation) + 180deg)) scale(1.2);
      filter: blur(4px);
    }
    75% {
      opacity: 0.7;
      transform: translate(-50%, -50%) rotate(calc(var(--rotation) + 270deg)) scale(1.1);
      filter: blur(2px);
    }
  }

  /* 新增載入文字樣式 */
  .loading-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 18px;
    font-weight: 500;
    text-shadow: 0 0 8px rgba(0, 0, 0, 0.8), 
                 0 0 12px rgba(255, 255, 255, 0.5);
    z-index: 10;
    white-space: nowrap;
  }

  /* 逐字動畫效果 - 使用steps()實現逐字效果 */
  .loading-text {
    width: 5.5em;
    overflow: hidden;
    animation: typing 2s steps(6, end) infinite, blink-caret 0.75s step-end infinite;
    /* border-right: 2px solid white; */
  }

  @keyframes typing {
    0% { width: 0; }
    50% { width: 5.5em; }
    90%, 100% { width: 5.5em; }
  }

  @keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: white; }
  }