 * {
     margin: 0;
     padding: 0;
     box-sizing: border-box;
     font-family: 'Segoe UI', 'Roboto', 'Microsoft YaHei', sans-serif;
 }

 #particle-bg {
     position: fixed;
     top: 0;
     left: 0;
     width: 100vw;
     height: 100vh;
     z-index: 0;
     background: radial-gradient(ellipse at center, #0f1923 0%, #050a10 100%);
 }

 html,
 body {
     width: 100%;
     height: 100%;
 }

 body {
     display: flex;
     justify-content: center;
     align-items: center;
     min-height: 100vh;
     min-height: 100dvh;
     padding: 20px;
     overflow: hidden;
     position: fixed;
     inset: 0;
 }

 .container {
     width: 100%;
     max-width: 420px;
     background: rgba(15, 25, 35, 0.85);
     backdrop-filter: blur(12px);
     border: 1px solid rgba(52, 152, 219, 0.3);
     border-radius: 24px;
     box-shadow:
         0 0 30px rgba(52, 152, 219, 0.2),
         inset 0 1px 0 rgba(255, 255, 255, 0.05);
     transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
     position: relative;
     z-index: 10;
     padding: 40px 30px;
 }

 .container::before {
     content: '';
     position: absolute;
     top: 0;
     left: 0;
     width: 100%;
     height: 4px;
     background: linear-gradient(90deg, #3498db, #2ecc71, #3498db);
     border-radius: 24px 24px 0 0;
     background-size: 200% 100%;
     animation: gradient-flow 3s linear infinite;
 }

 @keyframes gradient-flow {
     0% {
         background-position: 0 0;
     }

     100% {
         background-position: 200% 0;
     }
 }

 h1 {
     font-size: 28px;
     font-weight: 600;
     letter-spacing: 0.5px;
     margin-bottom: 8px;
     background: linear-gradient(90deg, #3498db, #2ecc71, #9b59b6, #3498db);
     background-size: 300% 100%;
     -webkit-background-clip: text;
     -webkit-text-fill-color: transparent;
     background-clip: text;
     text-fill-color: transparent;
     text-shadow: 0 0 10px rgba(52, 152, 219, 0.5), 0 0 20px rgba(46, 204, 113, 0.3);
     animation: text-gradient-flow 4s ease-in-out infinite;
 }

 @keyframes text-gradient-flow {

     0%,
     100% {
         background-position: 0 0;
     }

     50% {
         background-position: 100% 0;
     }
 }

 .subtitle {
     font-size: 14px;
     line-height: 1.5;
     margin-bottom: 40px;
     background: linear-gradient(90deg, #88a0b9, #a5c8e4, #88a0b9);
     background-size: 200% 100%;
     -webkit-background-clip: text;
     -webkit-text-fill-color: transparent;
     background-clip: text;
     text-fill-color: transparent;
     animation: subtitle-glow 5s ease-in-out infinite;
 }

 @keyframes subtitle-glow {

     0%,
     100% {
         background-position: 0 0;
     }

     50% {
         background-position: 100% 0;
     }
 }

 .progress-label {
     font-size: 16px;
     font-weight: 500;
     color: #a5c8e4;
     text-shadow: 0 0 5px rgba(165, 200, 228, 0.3);
 }

 .progress-value {
     font-size: 18px;
     font-weight: 600;
     color: #3498db;
     text-shadow: 0 0 8px rgba(52, 152, 219, 0.6), 0 0 15px rgba(52, 152, 219, 0.3);
 }

 .status-text {
     margin-top: 25px;
     font-size: 15px;
     min-height: 24px;
     line-height: 24px;
     background: linear-gradient(90deg, #88a0b9, #a5c8e4, #88a0b9);
     background-size: 200% 100%;
     -webkit-background-clip: text;
     -webkit-text-fill-color: transparent;
     background-clip: text;
     text-fill-color: transparent;
 }

 .status-text::after {
     content: '';
     display: inline-block;
     width: 8px;
     height: 15px;
     background: linear-gradient(180deg, #3498db, #2ecc71);
     margin-left: 6px;
     border-radius: 1px;
     animation: cursor-blink 1.2s infinite;
 }

 @keyframes cursor-blink {

     0%,
     100% {
         opacity: 1;
     }

     50% {
         opacity: 0;
     }
 }

 .complete-btn {
     color: #ffffff;
     text-shadow: 0 0 5px rgba(255, 255, 255, 0.4);
 }

 .auth-tip {
     color: #ff6b6b;
     text-shadow: 0 0 8px rgba(255, 107, 107, 0.6);
 }

 .idle-tip {
     color: #a5c8e4;
     text-shadow: 0 0 5px rgba(165, 200, 228, 0.3);
 }

 .progress-container {
     width: 100%;
     margin: 30px 0;
     position: relative;
 }

 .progress-info {
     display: flex;
     justify-content: space-between;
     margin-bottom: 12px;
 }

 .progress-bar {
     width: 100%;
     height: 14px;
     background: rgba(0, 15, 30, 0.6);
     border-radius: 10px;
     overflow: hidden;
     position: relative;
     border: 1px solid rgba(52, 152, 219, 0.2);
     box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
 }

 .progress-fill {
     height: 100%;
     width: 0%;
     background: linear-gradient(90deg, #2ecc71, #3498db, #9b59b6);
     background-size: 200% 100%;
     border-radius: 8px;
     transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
     position: relative;
     animation: progress-glow 2s ease-in-out infinite;
 }

 @keyframes progress-glow {

     0%,
     100% {
         background-position: 0 0;
     }

     50% {
         background-position: 100% 0;
     }
 }

 .progress-fill::after {
     content: '';
     position: absolute;
     top: 0;
     left: -50%;
     width: 50%;
     height: 100%;
     background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
     transform: skewX(-20deg);
     animation: progress-shine 1.5s linear infinite;
 }

 @keyframes progress-shine {
     0% {
         left: -50%;
     }

     100% {
         left: 150%;
     }
 }

 .complete-btn {
     display: none;
     width: 100%;
     padding: 18px;
     background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
     border: none;
     border-radius: 12px;
     font-size: 17px;
     font-weight: 600;
     cursor: pointer;
     transition: all 0.3s ease;
     box-shadow:
         0 4px 15px rgba(52, 152, 219, 0.4),
         inset 0 1px 0 rgba(255, 255, 255, 0.1);
     margin-top: 25px;
     position: relative;
     overflow: hidden;
 }

 .complete-btn:hover {
     transform: translateY(-2px);
     box-shadow:
         0 6px 20px rgba(52, 152, 219, 0.6),
         inset 0 1px 0 rgba(255, 255, 255, 0.2);
     background: linear-gradient(135deg, #3d9fdf 0%, #3188c6 100%);
 }

 .complete-btn:active {
     transform: translateY(1px);
 }

 .complete-btn::after {
     content: '';
     position: absolute;
     top: 50%;
     left: 50%;
     width: 0;
     height: 0;
     background: rgba(255, 255, 255, 0.2);
     border-radius: 50%;
     transform: translate(-50%, -50%);
     transition: width 0.6s ease, height 0.6s ease;
 }

 .complete-btn:active::after {
     width: 300px;
     height: 300px;
 }

 .error-tip {
     position: absolute;
     top: 50%;
     left: 50%;
     transform: translate(-50%, -50%);
     font-size: 16px;
     color: #a5c8e4;
     text-align: center;
     line-height: 1.8;
     padding: 30px;
     background: rgba(15, 25, 35, 0.9);
     border: 1px solid rgba(231, 76, 60, 0.3);
     border-radius: 16px;
     box-shadow: 0 0 20px rgba(231, 76, 60, 0.2);
     z-index: 9999;
     min-width: 280px;
     text-shadow: 0 0 5px rgba(165, 200, 228, 0.3);
 }

 .auth-tip {
     position: absolute;
     top: 20px;
     left: 50%;
     transform: translateX(-50%);
     font-size: 14px;
     line-height: 1.6;
     padding: 12px 24px;
     background: rgba(10, 18, 28, 0.9);
     border: 1px solid rgba(255, 107, 107, 0.4);
     border-radius: 12px;
     box-shadow:
         0 0 20px rgba(255, 107, 107, 0.3),
         inset 0 0 10px rgba(255, 107, 107, 0.1);
     z-index: 50;
     display: none;
     animation: auth-tip-pulse 1s ease-in-out infinite;
     backdrop-filter: blur(8px);
     min-width: 200px;
 }

 @keyframes auth-tip-pulse {

     0%,
     100% {
         box-shadow:
             0 0 20px rgba(255, 107, 107, 0.3),
             inset 0 0 10px rgba(255, 107, 107, 0.1);
         opacity: 1;
     }

     50% {
         box-shadow:
             0 0 30px rgba(255, 107, 107, 0.5),
             inset 0 0 15px rgba(255, 107, 107, 0.2);
         opacity: 0.9;
     }
 }

 .idle-tip {
     position: fixed;
     bottom: 30px;
     left: 50%;
     transform: translateX(-50%);
     font-size: 13px;
     background: rgba(15, 25, 35, 0.7);
     padding: 8px 16px;
     border-radius: 20px;
     border: 1px solid rgba(52, 152, 219, 0.2);
     z-index: 50;
     display: none;
     transition: all 0.3s ease;
 }

 @media (max-width: 480px) {
     .container {
         padding: 30px 20px;
         border-radius: 18px;
     }

     h1 {
         font-size: 24px;
     }

     .complete-btn {
         padding: 16px;
         font-size: 16px;
     }

     .idle-tip {
         bottom: 20px;
         font-size: 12px;
         padding: 6px 12px;
     }

     .auth-tip {
         top: 15px;
         font-size: 12px;
         padding: 10px 20px;
         min-width: 180px;
     }

     .auth-tip::before {
         font-size: 18px;
         margin-bottom: 4px;
     }
 }

 /* 到期提醒横幅 */
 .expire-banner {
     position: fixed;
     top: 0;
     left: 0;
     width: 100%;
     z-index: 9999;
     padding: 14px 20px;
     background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
     color: #fff;
     font-size: 15px;
     font-weight: 500;
     text-align: center;
     line-height: 1.6;
     box-shadow: 0 4px 20px rgba(231, 76, 60, 0.4);
     display: none;
     animation: expire-slide-down 0.5s ease-out;
 }

 .expire-banner .expire-icon {
     font-size: 20px;
     margin-right: 8px;
     vertical-align: middle;
 }

 .expire-banner .expire-close {
     position: absolute;
     right: 15px;
     top: 50%;
     transform: translateY(-50%);
     background: rgba(255, 255, 255, 0.2);
     border: none;
     color: #fff;
     width: 28px;
     height: 28px;
     border-radius: 50%;
     cursor: pointer;
     font-size: 16px;
     line-height: 28px;
     text-align: center;
 }

 .expire-banner .expire-close:hover {
     background: rgba(255, 255, 255, 0.3);
 }

 @keyframes expire-slide-down {
     from {
         transform: translateY(-100%);
         opacity: 0;
     }

     to {
         transform: translateY(0);
         opacity: 1;
     }
 }

 /* 过期状态下容器调整 */
 .container.expired-state {
     margin-top: 60px;
     border-color: rgba(231, 76, 60, 0.4);
     box-shadow: 0 0 30px rgba(231, 76, 60, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.05);
 }

 .container.expired-state::before {
     background: linear-gradient(90deg, #e74c3c, #e67e22, #e74c3c);
 }

 .expired-notice {
     display: none;
     background: rgba(231, 76, 60, 0.1);
     border: 1px solid rgba(231, 76, 60, 0.3);
     border-radius: 12px;
     padding: 16px;
     margin-top: 20px;
     color: #e74c3c;
     font-size: 14px;
     line-height: 1.6;
     text-align: center;
 }

 /* iframe 按手机上真正能看见的高度铺满。100vh 含地址栏，底栏会被顶到屏幕外面 */
 #contentFrame {
     position: fixed;
     top: 0;
     left: 0;
     width: 100%;
     height: 100vh;
     height: 100svh;
     height: 100dvh;
     border: none;
     z-index: 20;
     display: none;
     background: #050a10;
     opacity: 0;
     transition: opacity 0.5s ease;
 }

 /* 返回按钮 */
 .back-btn {
     position: fixed;
     top: 25px;
     left: 25px;
     z-index: 30;
     background: rgba(15, 25, 35, 0.9);
     border: 1px solid rgba(52, 152, 219, 0.4);
     border-radius: 50%;
     width: 56px;
     height: 56px;
     font-size: 22px;
     color: #3498db;
     cursor: pointer;
     display: none;
     box-shadow: 0 4px 15px rgba(52, 152, 219, 0.2);
     transition: all 0.3s ease;
     backdrop-filter: blur(8px);
 }

 .back-btn:hover {
     background: rgba(20, 35, 50, 0.95);
     transform: scale(1.05);
     box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
     color: #4aa3df;
 }

 /* 兜底直接打开按钮 */
 .fallback-bar {
     position: fixed;
     bottom: 30px;
     left: 50%;
     transform: translateX(-50%);
     z-index: 9999;
     background: rgba(15, 25, 35, 0.95);
     border: 1px solid rgba(231, 76, 60, 0.4);
     border-radius: 16px;
     padding: 12px 20px;
     display: none;
     align-items: center;
     gap: 12px;
     box-shadow: 0 4px 20px rgba(231, 76, 60, 0.3);
     backdrop-filter: blur(10px);
     animation: fallback-pop 0.4s ease-out;
 }

 .fallback-bar span {
     color: #a5c8e4;
     font-size: 14px;
 }

 .fallback-btn {
     background: linear-gradient(135deg, #e74c3c, #c0392b);
     color: #fff;
     border: none;
     border-radius: 10px;
     padding: 10px 18px;
     font-size: 14px;
     font-weight: 600;
     cursor: pointer;
     transition: all 0.3s ease;
     white-space: nowrap;
 }

 .fallback-btn:hover {
     transform: translateY(-1px);
     box-shadow: 0 4px 15px rgba(231, 76, 60, 0.5);
 }

 @keyframes fallback-pop {
     from {
         transform: translateX(-50%) translateY(20px);
         opacity: 0;
     }

     to {
         transform: translateX(-50%) translateY(0);
         opacity: 1;
     }
 }