/**
 * 转账功能样式
 * 参考QQ/微信转账设计，提供专业的转账体验
 */

/* ==================== 转账输入弹窗 ==================== */
.transfer-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.transfer-modal.show {
    display: flex;
}

.transfer-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.transfer-content {
    position: relative;
    width: 90%;
    max-width: 400px;
    background: #fff;
    border-radius: 16px;
    padding: 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
    overflow: hidden;
}

/* 转账顶部 */
.transfer-header {
    position: relative;
    padding: 30px 20px 20px;
    text-align: center;
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    color: #fff;
}

.transfer-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.transfer-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 8px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.transfer-subtitle {
    font-size: 14px;
    opacity: 0.9;
}

/* 转账输入区域 */
.transfer-body {
    background: #fff;
    padding: 30px 20px;
}

.transfer-input-group {
    margin-bottom: 20px;
}

.transfer-label {
    display: block;
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
    font-weight: 500;
}

.transfer-amount-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.transfer-amount-symbol {
    font-size: 32px;
    font-weight: 700;
    color: #1890ff;
    margin-right: 8px;
}

.transfer-amount-input {
    font-size: 48px;
    font-weight: 700;
    color: #1890ff;
    border: none;
    outline: none;
    text-align: center;
    width: 200px;
    background: transparent;
}

.transfer-amount-input::placeholder {
    color: #d9d9d9;
}

.transfer-amount-hint {
    text-align: center;
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}

.transfer-note-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.transfer-note-input:focus {
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.1);
}

.transfer-note-input::placeholder {
    color: #bfbfbf;
}

/* 转账按钮 */
.transfer-footer {
    padding: 0 20px 20px;
}

.transfer-btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none;
}

.transfer-btn-send {
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(24, 144, 255, 0.3);
}

.transfer-btn-send:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(24, 144, 255, 0.4);
}

.transfer-btn-send:active {
    transform: translateY(0);
}

/* ==================== 聊天中的转账卡片 ==================== */
.transfer-card {
    position: relative;
    width: 280px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
}

.transfer-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #1890ff 0%, #096dd9 100%);
}

.transfer-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.transfer-card-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.transfer-card-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-right: 12px;
    color: #fff;
}

.transfer-card-info {
    flex: 1;
}

.transfer-card-title {
    font-size: 15px;
    font-weight: 600;
    color: #262626;
    margin-bottom: 4px;
}

.transfer-card-note {
    font-size: 13px;
    color: #8c8c8c;
}

.transfer-card-amount {
    font-size: 28px;
    font-weight: 700;
    color: #262626;
    text-align: center;
    margin: 10px 0;
}

.transfer-card-amount-unit {
    font-size: 16px;
    margin-right: 4px;
    color: #595959;
}

.transfer-card-status {
    text-align: center;
    font-size: 13px;
    color: #8c8c8c;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0;
}

/* 转账状态样式 */
.transfer-card.pending {
    /* 待确认状态 - 默认样式 */
}

.transfer-card.received {
    background: #f6ffed;
    border-color: #b7eb8f;
}

.transfer-card.received::before {
    background: linear-gradient(90deg, #52c41a 0%, #389e0d 100%);
}

.transfer-card.received .transfer-card-icon {
    background: linear-gradient(135deg, #52c41a 0%, #389e0d 100%);
}

.transfer-card.received:hover {
    box-shadow: 0 4px 12px rgba(82, 196, 26, 0.2);
}

.transfer-card.returned {
    background: #fafafa;
    border-color: #d9d9d9;
}

.transfer-card.returned::before {
    background: linear-gradient(90deg, #8c8c8c 0%, #595959 100%);
}

.transfer-card.returned .transfer-card-icon {
    background: linear-gradient(135deg, #8c8c8c 0%, #595959 100%);
}

.transfer-card.returned:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* ==================== 转账详情弹窗 ==================== */
.transfer-detail-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10001;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.transfer-detail-modal.show {
    display: flex;
}

.transfer-detail-content {
    position: relative;
    width: 90%;
    max-width: 400px;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

.transfer-detail-header {
    padding: 30px 20px;
    text-align: center;
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    color: #fff;
}

.transfer-detail-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

.transfer-detail-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.transfer-detail-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.transfer-detail-body {
    padding: 30px 20px;
}

.transfer-detail-amount {
    text-align: center;
    margin-bottom: 30px;
}

.transfer-detail-amount-value {
    font-size: 48px;
    font-weight: 700;
    color: #262626;
    margin-bottom: 10px;
}

.transfer-detail-amount-unit {
    font-size: 24px;
    margin-right: 8px;
    color: #595959;
}

.transfer-detail-amount-label {
    font-size: 14px;
    color: #8c8c8c;
}

.transfer-detail-info {
    background: #fafafa;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.transfer-detail-info-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
}

.transfer-detail-info-label {
    color: #8c8c8c;
}

.transfer-detail-info-value {
    color: #262626;
    font-weight: 500;
}

.transfer-detail-actions {
    display: flex;
    gap: 10px;
}

.transfer-detail-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.transfer-detail-btn-receive {
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    color: #fff;
}

.transfer-detail-btn-receive:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(24, 144, 255, 0.3);
}

.transfer-detail-btn-return {
    background: #fff;
    color: #595959;
    border: 1px solid #d9d9d9;
}

.transfer-detail-btn-return:hover {
    border-color: #1890ff;
    color: #1890ff;
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 768px) {
    .transfer-content,
    .transfer-detail-content {
        width: 95%;
        max-width: none;
    }
    
    .transfer-card {
        width: 260px;
    }
    
    .transfer-amount-input {
        font-size: 40px;
        width: 180px;
    }
}

/* ==================== 动画 ==================== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}