/* 全局样式 */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

h1 {
    color: #2c3e50;
}

h2 {
    color: #3498db;
    margin-bottom: 15px;
}

/* 表单样式 */
.task-form {
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 15px;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

input[type="text"],
input[type="datetime-local"],
textarea,
select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

textarea {
    height: 100px;
    resize: vertical;
}

button {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #2980b9;
}

/* 控制区域样式 */
.task-controls {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 5px;
}

.sort-controls,
.filter-controls {
    display: flex;
    align-items: center;
}

.sort-controls label,
.filter-controls label {
    margin-right: 10px;
    margin-bottom: 0;
}

.sort-controls select,
.filter-controls select {
    width: auto;
}

/* 任务列表样式 */
.task-list {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background-color: #3498db;
    color: white;
}

th, td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

tr:hover {
    background-color: #f5f5f5;
}

/* 优先级样式 */
.priority-high {
    color: #e74c3c;
    font-weight: bold;
}

.priority-medium {
    color: #f39c12;
}

.priority-low {
    color: #27ae60;
}

.priority-urgent {
    color: #e74c3c;
    font-weight: bold;
    animation: blink 1s infinite;
}

@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

/* 操作按钮样式 */
.action-btn {
    margin-right: 5px;
    padding: 5px 10px;
    font-size: 14px;
}

.edit-btn {
    background-color: #f39c12;
}

.delete-btn {
    background-color: #e74c3c;
}

.complete-btn {
    background-color: #27ae60;
}

/* 通知权限提示 */
.notification-permission {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #3498db;
    color: white;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
}

.hidden {
    display: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .task-controls {
        flex-direction: column;
    }
    
    .sort-controls,
    .filter-controls {
        margin-bottom: 10px;
    }
    
    th, td {
        padding: 8px 10px;
    }
    
    .action-btn {
        padding: 4px 8px;
        font-size: 12px;
    }
}