:root {
    --primary-color: #07c160;
    --bg-color: #f5f5f5;
    --card-bg: rgba(255, 255, 255, 0.8);
    --text-color: #333;
    --accent-color: #007bff;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: linear-gradient(135deg, #e0eafc, #cfdef3);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 1100px;
    height: 85vh;
    background: var(--card-bg);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    display: grid;
    grid-template-columns: 280px 1fr;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.3);
}

/* 侧边栏 */
.sidebar {
    background: rgba(255, 255, 255, 0.5);
    border-right: 1px solid rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
}

.nav-item {
    padding: 20px;
    cursor: pointer;
    transition: background 0.3s;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-item:hover, .nav-item.active {
    background: rgba(7, 193, 96, 0.1);
    color: var(--primary-color);
}

/* 主内容区 */
.main-content {
    display: flex;
    flex-direction: column;
    padding: 30px;
    position: relative;
    overflow-y: auto;
}

.view {
    display: none;
    height: 100%;
}

.view.active {
    display: flex;
    flex-direction: column;
}

/* 配置页样式 */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    opacity: 0.8;
}

input {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid rgba(0,0,0,0.1);
    background: rgba(255,255,255,0.9);
    outline: none;
    transition: border 0.3s;
}

input:focus {
    border-color: var(--primary-color);
}

button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: opacity 0.3s;
}

button:hover {
    opacity: 0.9;
}

/* 对话页样式 - 仿微信风格 */
.chat-box {
    flex: 1;
    background: #ebebeb;
    border-radius: 12px;
    margin-bottom: 15px;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.msg-wrapper {
    display: flex;
    flex-direction: column;
    max-width: 75%;
}

.msg-wrapper.sent {
    align-self: flex-end;
    align-items: flex-end;
    width: fit-content;
    max-width: 75%;
}

.msg-wrapper.received {
    align-self: flex-start;
    max-width: 75%;
}

.msg-sender {
    font-size: 13px;
    color: #576b95;
    font-weight: 500;
}

.message {
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.5;
    word-break: break-word;
    display: inline-block;
}

.message.sent {
    background: #95ec69;
    color: #000;
    border-top-right-radius: 2px;
}

.message.received {
    background: #fff;
    color: #000;
    border-top-left-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

.chat-input-area {
    display: flex;
    gap: 10px;
}

/* 考勤页样式 */
.filter-bar {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: flex-end;
}

.table-container {
    flex: 1;
    overflow-y: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

th {
    background: #f8f9fa;
    font-weight: 600;
}
