/* 后台样式 - 注销申请系统 */
:root {
    --primary-color: #e67e22;
    --secondary-color: #2c3e50;
    --success-color: #27ae60;
    --danger-color: #e74c3c;
    --warning-color: #f39c12;
    --text-color: #333;
    --border-color: #e2e8f0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f7fb;
    min-height: 100vh;
}

/* 登录界面 */
.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    width: 100%;
    max-width: 400px;
}

.login-box h2 {
    text-align: center;
    margin-bottom: 30px;
    color: var(--primary-color);
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
}

.login-form input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.login-btn {
    width: 100%;
    padding: 12px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.login-btn:hover {
    background: var(--secondary-color);
}

/* 后台面板 */
.admin-panel {
    display: none;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.admin-header {
    background: white;
    padding: 20px 24px;
    border-radius: 16px;
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    flex-wrap: wrap;
    gap: 15px;
}

.admin-header h1 {
    color: var(--primary-color);
    font-size: 24px;
    margin: 0;
}

.logout-btn {
    padding: 8px 20px;
    background: var(--danger-color);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
    font-size: 14px;
}

.logout-btn:hover {
    background: #c0392b;
}

/* 统计卡片 */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.stat-card h3 {
    color: #7f8c8d;
    font-size: 14px;
    margin-bottom: 10px;
    font-weight: 500;
}

.stat-card .number {
    color: var(--primary-color);
    font-size: 32px;
    font-weight: bold;
}

/* 搜索框 */
.search-box {
    background: white;
    padding: 16px 20px;
    border-radius: 16px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.search-box input {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    font-size: 14px;
    transition: all 0.2s;
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* 表格容器 - 优化滚动 */
.table-container {
    background: white;
    border-radius: 16px;
    overflow-x: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 1000px;
}

th {
    background: #f8f9fa;
    color: #2c3e50;
    padding: 14px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 13px;
    border-bottom: 2px solid var(--border-color);
    white-space: nowrap;
}

td {
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
    font-size: 13px;
    color: #4a5568;
}

/* 长文本处理 - 限制最大宽度，超出显示省略号 */
td:nth-child(2) {  /* 账号列 */
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

td:nth-child(6) {  /* 原因列 */
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 时间列 - 保持不换行 */
td:nth-child(7) {  /* 提交时间列 */
    white-space: nowrap;
    font-size: 12px;
}

/* 操作列 - 按钮不换行 */
td:last-child {
    white-space: nowrap;
    min-width: 140px;
}

tr:hover {
    background: #fafafa;
}

tr.processed {
    background: #f9f9f9;
    opacity: 0.85;
}

/* 状态标签 */
.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.status-pending {
    background: #fff3e0;
    color: #e67e22;
}

.status-processed {
    background: #e8f5e9;
    color: #27ae60;
}

/* 操作按钮 */
.action-btn {
    padding: 5px 12px;
    margin: 0 3px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s;
    display: inline-block;
}

.copy-btn {
    background: #e67e22;
    color: white;
}

.copy-btn:hover {
    background: #d35400;
    transform: translateY(-1px);
}

.process-btn {
    background: #27ae60;
    color: white;
}

.process-btn:hover {
    background: #219a52;
    transform: translateY(-1px);
}

.delete-btn {
    background: #e74c3c;
    color: white;
}

.delete-btn:hover {
    background: #c0392b;
    transform: translateY(-1px);
}

.processed .process-btn {
    display: none;
}

.no-data {
    text-align: center;
    padding: 40px;
    color: #95a5a6;
}

/* 复制成功提示 */
.copy-tooltip {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #27ae60;
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1000;
    font-size: 14px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* 响应式调整 */
@media (max-width: 768px) {
    .admin-panel {
        padding: 12px;
    }
    
    .admin-header {
        flex-direction: column;
        text-align: center;
    }
    
    .stats-container {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }
    
    .stat-card {
        padding: 15px;
    }
    
    .stat-card .number {
        font-size: 24px;
    }
    
    th, td {
        padding: 8px 10px;
        font-size: 12px;
    }
    
    .action-btn {
        padding: 4px 8px;
        font-size: 11px;
        margin: 2px;
    }
}

/* 滚动条美化 */
.table-container::-webkit-scrollbar {
    height: 8px;
}

.table-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb {
    background: #cbd5e0;
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb:hover {
    background: #a0aec0;
}