/* WP DiskPay 前端样式 - 增强版 */

/* 下载按钮容器 */
.wp-diskpay-download-container {
    margin: 20px 0;
    padding: 20px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: linear-gradient(135deg, #f9f9f9 0%, #ffffff 100%);
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.wp-diskpay-download-container:hover {
    border-color: #0073aa;
    box-shadow: 0 4px 20px rgba(0,115,170,0.2);
}

/* 价格显示 */
.wp-diskpay-payment-info .price {
    font-size: 28px;
    font-weight: bold;
    color: #e74c3c;
    margin: 0 0 15px 0;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* 下载按钮 */
.wp-diskpay-download-btn {
    display: inline-block;
    padding: 15px 35px;
    font-size: 16px;
    font-weight: bold;
    text-decoration: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 180px;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.wp-diskpay-download-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.wp-diskpay-download-btn:hover::before {
    left: 100%;
}

/* 已付费的下载按钮 */
.wp-diskpay-download-btn.paid {
    background: linear-gradient(45deg, #27ae60, #2ecc71);
    color: white;
    box-shadow: 0 4px 15px rgba(39, 174, 96, 0.3);
}

.wp-diskpay-download-btn.paid:hover {
    background: linear-gradient(45deg, #229954, #27ae60);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(39, 174, 96, 0.4);
}

/* 支付按钮 */
.wp-diskpay-download-btn.payment {
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: white;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.wp-diskpay-download-btn.payment:hover {
    background: linear-gradient(45deg, #2980b9, #3498db);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
}

/* 禁用状态 */
.wp-diskpay-download-btn:disabled {
    background: #bdc3c7 !important;
    color: #7f8c8d !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

/* OAuth登录相关 */
.wp-diskpay-oauth-login, .wp-diskpay-oauth-status {
    margin: 20px 0;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.wp-diskpay-oauth-login {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
}

.oauth-authorized {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    border-radius: 5px;
    padding: 10px;
}

.oauth-not-authorized {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 5px;
    padding: 10px;
}

.wp-diskpay-oauth-btn {
    display: inline-block;
    padding: 12px 24px;
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    margin: 10px;
    transition: all 0.3s ease;
}

.wp-diskpay-oauth-btn:hover {
    background: linear-gradient(45deg, #ee5a24, #ff6b6b);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
    color: white;
    text-decoration: none;
}

/* 模态框 */
.wp-diskpay-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9998;
    backdrop-filter: blur(2px);
}

.wp-diskpay-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    z-index: 9999;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    animation: wp-diskpay-modal-appear 0.3s ease-out;
}

@keyframes wp-diskpay-modal-appear {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

.wp-diskpay-modal-header {
    padding: 25px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.wp-diskpay-modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
}

.wp-diskpay-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: rgba(255,255,255,0.8);
    cursor: pointer;
    padding: 0;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.wp-diskpay-modal-close:hover {
    background: rgba(255,255,255,0.2);
    color: white;
}

.wp-diskpay-modal-body {
    padding: 25px;
    max-height: 500px;
    overflow-y: auto;
}

.wp-diskpay-modal-footer {
    padding: 20px 25px;
    border-top: 1px solid #e0e0e0;
    text-align: right;
    background: #f8f9fa;
}

/* 按钮样式 */
.wp-diskpay-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    display: inline-block;
    transition: all 0.2s ease;
    margin: 0 5px;
}

.wp-diskpay-btn-primary {
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: white;
}

.wp-diskpay-btn-primary:hover {
    background: linear-gradient(45deg, #2980b9, #3498db);
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(52, 152, 219, 0.3);
}

.wp-diskpay-btn-secondary {
    background: #95a5a6;
    color: white;
}

.wp-diskpay-btn-secondary:hover {
    background: #7f8c8d;
}

.wp-diskpay-btn-success {
    background: linear-gradient(45deg, #27ae60, #2ecc71);
    color: white;
}

.wp-diskpay-btn-success:hover {
    background: linear-gradient(45deg, #229954, #27ae60);
}

/* 加载中提示 */
.wp-diskpay-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(2px);
}

.wp-diskpay-loading-content {
    text-align: center;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.wp-diskpay-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #3498db;
    border-radius: 50%;
    animation: wp-diskpay-spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes wp-diskpay-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 消息提示 */
.wp-diskpay-message {
    padding: 15px 20px;
    margin: 15px 0;
    border-radius: 8px;
    border-left: 4px solid;
    font-weight: 500;
    position: relative;
    animation: wp-diskpay-slide-in 0.3s ease-out;
}

@keyframes wp-diskpay-slide-in {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.wp-diskpay-message.success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    border-left-color: #27ae60;
}

.wp-diskpay-message.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    border-left-color: #e74c3c;
}

.wp-diskpay-message.info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    color: #0c5460;
    border-left-color: #3498db;
}

/* 分享链接显示 */
.wp-diskpay-share-info {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 25px;
    border-radius: 10px;
    margin: 20px 0;
    border: 1px solid #dee2e6;
}

.wp-diskpay-share-info h4 {
    margin-top: 0;
    color: #2c3e50;
    font-size: 18px;
}

.wp-diskpay-share-url {
    display: flex;
    align-items: center;
    margin: 15px 0;
    gap: 10px;
}

.wp-diskpay-share-url input {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 14px;
    background: white;
    transition: border-color 0.2s ease;
}

.wp-diskpay-share-url input:focus {
    outline: none;
    border-color: #3498db;
}

.wp-diskpay-copy-btn {
    background: linear-gradient(45deg, #6c757d, #5a6268);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
    font-weight: 500;
    transition: all 0.2s ease;
}

.wp-diskpay-copy-btn:hover {
    background: linear-gradient(45deg, #5a6268, #6c757d);
    transform: translateY(-1px);
}

.wp-diskpay-copy-btn.copied {
    background: linear-gradient(45deg, #27ae60, #2ecc71);
}

/* 用户面板样式 */
.wp-diskpay-dashboard-page {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.wp-diskpay-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.wp-diskpay-stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
    transition: transform 0.3s ease;
}

.wp-diskpay-stat-card:hover {
    transform: translateY(-5px);
}

.wp-diskpay-stat-number {
    font-size: 32px;
    font-weight: bold;
    margin-bottom: 5px;
}

.wp-diskpay-stat-label {
    font-size: 14px;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* 文件浏览器 */
.wp-diskpay-file-browser {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    background: white;
}

.wp-diskpay-file-toolbar {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 20px;
    border-bottom: 1px solid #dee2e6;
}

.wp-diskpay-file-toolbar h3 {
    margin: 0 0 5px 0;
    color: #2c3e50;
}

.wp-diskpay-file-item {
    padding: 15px 20px;
    border-bottom: 1px solid #f1f1f1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background-color 0.2s ease;
}

.wp-diskpay-file-item:hover {
    background-color: #f8f9fa;
}

.wp-diskpay-file-item:last-child {
    border-bottom: none;
}

.wp-diskpay-file-info {
    display: flex;
    align-items: center;
    flex: 1;
}

.wp-diskpay-file-icon {
    margin-right: 15px;
    font-size: 24px;
}

.wp-diskpay-file-actions {
    display: flex;
    gap: 10px;
}

.wp-diskpay-empty-state {
    padding: 40px;
    text-align: center;
    color: #6c757d;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .wp-diskpay-modal {
        width: 95%;
        margin: 20px;
    }
    
    .wp-diskpay-download-container {
        margin: 15px 0;
        padding: 15px;
    }
    
    .wp-diskpay-download-btn {
        width: 100%;
        padding: 15px;
        font-size: 16px;
    }
    
    .wp-diskpay-share-url {
        flex-direction: column;
        align-items: stretch;
    }
    
    .wp-diskpay-share-url input {
        margin-bottom: 10px;
    }
    
    .wp-diskpay-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .wp-diskpay-file-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .wp-diskpay-file-actions {
        align-self: stretch;
        justify-content: flex-end;
    }
}

/* 自动添加的按钮区域 */
.wp-diskpay-auto-button {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px dashed #e0e0e0;
}

/* 新的下载段样式 */
.wp-diskpay-download-section {
    margin: 20px 0;
}

.wp-diskpay-download-section .card {
    box-shadow: 0 4px 15px rgba(0,123,255,0.15);
    border: 1px solid #007bff;
    transition: all 0.3s ease;
}

.wp-diskpay-download-section .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,123,255,0.25);
}

.wp-diskpay-download-section .card-header {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    border-bottom: none;
    color: white;
    font-weight: 600;
}

.wp-diskpay-download-section .card-header h6 {
    margin: 0;
    font-size: 16px;
    display: flex;
    align-items: center;
}

.wp-diskpay-download-section .card-body {
    padding: 20px;
}

.wp-diskpay-download-section .btn-primary {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    border: none;
    padding: 12px 20px;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.wp-diskpay-download-section .btn-primary:hover {
    background: linear-gradient(135deg, #0056b3 0%, #004085 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0,123,255,0.3);
}

.wp-diskpay-download-section .btn-primary:active {
    transform: translateY(0);
}

.wp-diskpay-download-section .btn-primary.loading {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.wp-diskpay-download-section .diskpay-result {
    display: none;
    margin-top: 15px;
    padding: 15px;
    border-radius: 8px;
}

.wp-diskpay-download-section .diskpay-result.show {
    display: block;
    animation: wp-diskpay-fadeIn 0.3s ease-in;
}

.wp-diskpay-download-section .diskpay-result.success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border: 1px solid #28a745;
    color: #155724;
}

.wp-diskpay-download-section .diskpay-result.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border: 1px solid #dc3545;
    color: #721c24;
}

.wp-diskpay-download-section .text-muted {
    font-size: 13px;
    line-height: 1.4;
}

/* 动画效果 */
.wp-diskpay-fade-in {
    animation: wp-diskpay-fadeIn 0.3s ease-in;
}

@keyframes wp-diskpay-fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 支付状态样式 */
.payment-status {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.payment-status.status-completed {
    background: linear-gradient(45deg, #d4edda, #c3e6cb);
    color: #155724;
}

.payment-status.status-pending {
    background: linear-gradient(45deg, #fff3cd, #ffeaa7);
    color: #856404;
}

.payment-status.status-failed {
    background: linear-gradient(45deg, #f8d7da, #f5c6cb);
    color: #721c24;
}

.payment-status.status-cancelled {
    background: linear-gradient(45deg, #e2e3e5, #d1d3d4);
    color: #6c757d;
}

/* 表格增强 */
.wp-list-table {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.wp-list-table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
}

.wp-list-table tbody tr:hover {
    background-color: #f8f9fa;
}

/* 仪表板选项卡 */
.wp-diskpay-dashboard-tabs {
    border-bottom: 3px solid #e9ecef;
    margin-bottom: 25px;
    display: flex;
    gap: 5px;
}

.wp-diskpay-tab-btn {
    background: none;
    border: none;
    padding: 15px 25px;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
    font-weight: 500;
    color: #6c757d;
    transition: all 0.2s ease;
    position: relative;
}

.wp-diskpay-tab-btn:hover {
    background: #f8f9fa;
    color: #495057;
}

.wp-diskpay-tab-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
}

.wp-diskpay-tab-content {
    display: none;
    animation: wp-diskpay-tab-appear 0.3s ease-out;
}

.wp-diskpay-tab-content.active {
    display: block;
}

@keyframes wp-diskpay-tab-appear {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

 / *   ~v^QvΘ<hvRN~g>f:y  * / 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . a l e r t - s u c c e s s   . r o w   { 
         m a r g i n :   0 ; 
 } 
 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . a l e r t - s u c c e s s   . c o l - m d - 8 , 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . a l e r t - s u c c e s s   . c o l - m d - 4   { 
         p a d d i n g :   0   5 p x ; 
 } 
 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . f o r m - l a b e l   { 
         m a r g i n - b o t t o m :   3 p x ; 
         f o n t - w e i g h t :   6 0 0 ; 
         c o l o r :   # 6 c 7 5 7 d ; 
 } 
 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . i n p u t - g r o u p - s m   . f o r m - c o n t r o l   { 
         f o n t - s i z e :   1 2 p x ; 
         f o n t - f a m i l y :   m o n o s p a c e ; 
         b a c k g r o u n d :   # f 8 f 9 f a ; 
         b o r d e r :   1 p x   s o l i d   # d e e 2 e 6 ; 
 } 
 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . i n p u t - g r o u p - s m   . b t n   { 
         f o n t - s i z e :   1 1 p x ; 
         p a d d i n g :   0 . 2 5 r e m   0 . 5 r e m ; 
 } 
 
 . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . a l e r t - s u c c e s s   h 6   { 
         c o l o r :   # 1 5 5 7 2 4 ; 
         f o n t - w e i g h t :   6 0 0 ; 
         m a r g i n - b o t t o m :   1 5 p x ; 
 } 
 
 @ m e d i a   ( m a x - w i d t h :   7 6 8 p x )   { 
         . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . a l e r t - s u c c e s s   . c o l - m d - 8 , 
         . w p - d i s k p a y - d o w n l o a d - s e c t i o n   . a l e r t - s u c c e s s   . c o l - m d - 4   { 
                 m a r g i n - b o t t o m :   1 0 p x ; 
         } 
 }  
 