/* ==================== 弹窗样式 ==================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(5px);
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.modal-content {
    background: linear-gradient(145deg, #1e2d4a 0%, #152238 100%);
    border: 2px solid rgba(255, 215, 0, 0.4);
    border-radius: 20px;
    padding: 30px;
    max-width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    color: #fff;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: modalIn 0.3s ease;
    position: relative;
    z-index: 10000;
    -webkit-overflow-scrolling: touch;
}

@keyframes modalIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.modal-title {
    font-size: 24px;
    color: #ffd700;
    text-align: center;
    margin-bottom: 25px;
}

.close-modal-btn {
    width: 100%;
    margin-top: 25px;
    padding: 12px;
    background: linear-gradient(135deg, #ffd700 0%, #ff9500 100%);
    color: #1a1a2e;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    min-height: 44px;
}

.close-modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 215, 0, 0.4);
}

/* 比牌选择 */
.compare-options {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.compare-options .action-btn {
    min-width: 140px;
}

/* ==================== 消息提示 ==================== */
.toast-message {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: linear-gradient(135deg, rgba(30, 40, 60, 0.95) 0%, rgba(20, 30, 50, 0.95) 100%);
    color: #fff;
    padding: 15px 30px;
    border-radius: 30px;
    font-size: 15px;
    z-index: 1000;
    display: none;
    border: 1px solid rgba(255, 215, 0, 0.3);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    animation: toastIn 0.3s ease forwards;
}

@keyframes toastIn {
    to { transform: translateX(-50%) translateY(0); }
}

/* ==================== 弹幕消息 ==================== */
.barrage-container {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    height: 40px;
    overflow: hidden;
    pointer-events: none;
    z-index: 50;
}

.barrage-item {
    position: absolute;
    right: -200px;
    background: rgba(255, 215, 0, 0.2);
    border: 1px solid rgba(255, 215, 0, 0.4);
    padding: 5px 15px;
    border-radius: 20px;
    color: #ffd700;
    font-size: 14px;
    white-space: nowrap;
    animation: barrageMove 4s linear forwards;
}

@keyframes barrageMove {
    0% { right: -200px; opacity: 1; }
    90% { opacity: 1; }
    100% { right: 110%; opacity: 0; }
}
