* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}
header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 0;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
h1 {
    text-align: center;
    font-size: 2.5em;
    margin-bottom: 10px;
}
.subtitle {
    text-align: center;
    opacity: 0.9;
    font-size: 1.1em;
}

/* 上半部分 - 查询和添加区域 */
.control-panel {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}
.panel-title {
    font-size: 1.3em;
    color: #4a5568;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e2e8f0;
}
.form-group {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: end;
}
.input-group {
    flex: 1;
    min-width: 200px;
}
label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #4a5568;
}
input, textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
}
input:focus, textarea:focus {
    outline: none;
    border-color: #667eea;
}
textarea {
    min-height: 80px;
    resize: vertical;
}
button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: transform 0.2s;
}
button:hover {
    transform: translateY(-2px);
}
.btn-refresh {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
}
.btn-search {
    background: linear-gradient(135deg, #ed8936 0%, #dd6b20 100%);
}

/* 下半部分 - 数据表格 */
.data-panel {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
.table-container {
    overflow-x: auto;
}
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}
th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}
th {
    background-color: #f7fafc;
    font-weight: 600;
    color: #4a5568;
    position: sticky;
    top: 0;
}
tr:hover {
    background-color: #f7fafc;
}
.action-buttons {
    display: flex;
    gap: 8px;
}
.btn-edit {
    background: linear-gradient(135deg, #38a169 0%, #2f855a 100%);
    padding: 8px 12px;
    font-size: 12px;
}
.btn-delete {
    background: linear-gradient(135deg, #e53e3e 0%, #c53030 100%);
    padding: 8px 12px;
    font-size: 12px;
}
.message-content {
    max-width: 300px;
    word-wrap: break-word;
}
.no-data {
    text-align: center;
    padding: 40px;
    color: #a0aec0;
    font-style: italic;
}
.loading {
    text-align: center;
    padding: 20px;
    color: #4a5568;
}
.timestamp {
    font-size: 0.9em;
    color: #718096;
}

@media (max-width: 768px) {
    .form-group {
        flex-direction: column;
    }
    .input-group {
        width: 100%;
    }
    th, td {
        padding: 10px 8px;
        font-size: 14px;
    }
}