/* 管理端统一样式 */

/* 全局样式 */
* {
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f7fa;
    color: #333;
    padding-top: 80px; /* 为固定导航栏留出空间 */
}

/* 容器样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* 卡片样式 */
.card {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 20px;
    margin-bottom: 20px;
}

/* 标题样式 */
h1, h2, h3, h4, h5, h6 {
    color: #1a73e8;
    margin-top: 0;
}

/* 按钮样式 */
button, .btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: #1a73e8;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
}

button:hover, .btn:hover {
    background-color: #1557b0;
}

/* 表单样式 */
.form-group {
    margin-bottom: 15px;
}

label {
    display: block;
    margin-bottom: 5px;
    color: #333;
}

input, select, textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

/* 表格样式 */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #f5f7fa;
    color: #1a73e8;
    font-weight: bold;
}

tr:hover {
    background-color: #f5f7fa;
}

/* 导航栏样式 */
.navbar {
    background-color: #1a73e8;
    color: white;
    padding: 15px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar h1 {
    margin: 0;
    font-size: 18px;
    color: white;
    font-weight: bold;
}

.navbar .nav-links {
    display: flex;
    gap: 20px;
}

.navbar a {
    color: white;
    text-decoration: none;
}

.navbar a:hover {
    text-decoration: underline;
}

/* 页脚样式 */
.footer {
    background-color: #f5f7fa;
    padding: 20px;
    text-align: center;
    margin-top: 40px;
    border-top: 1px solid #ddd;
}

/* 错误信息样式 */
.error {
    color: red;
    margin-bottom: 15px;
}

/* 成功信息样式 */
.success {
    color: green;
    margin-bottom: 15px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .card {
        padding: 15px;
    }
    
    button, .btn {
        padding: 8px 16px;
        font-size: 14px;
    }
    
    th, td {
        padding: 8px;
    }
}

/* 登录页面样式 */
.login-container {
    max-width: 400px;
    margin: 100px auto;
    padding: 40px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

.login-container h1 {
    margin-bottom: 30px;
    color: #1a73e8;
}

.login-container .form-group {
    text-align: left;
}

.login-container button {
    width: 100%;
    margin-top: 20px;
}

/* 管理端首页样式 */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    text-align: center;
}

.stat-card h3 {
    margin: 0 0 10px 0;
    color: #1a73e8;
    font-size: 16px;
}

.stat-card .stat-value {
    font-size: 24px;
    font-weight: bold;
    color: #333;
}

/* 评估表单样式 */
.assessment-form {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.assessment-form h2 {
    margin-bottom: 20px;
    color: #1a73e8;
}

.question {
    margin-bottom: 20px;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #f9f9f9;
}

.question p {
    margin: 0 0 10px 0;
    font-weight: bold;
}

.answer-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.answer-option {
    display: flex;
    align-items: center;
    gap: 10px;
}

.answer-option input[type="radio"] {
    width: auto;
}

.answer-option label {
    margin: 0;
    cursor: pointer;
}

.submit-btn {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    background-color: #1a73e8;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 20px;
}

.submit-btn:hover {
    background-color: #1557b0;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}

.pagination a {
    padding: 8px 12px;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
}

.pagination a:hover {
    background-color: #f5f7fa;
    border-color: #1a73e8;
    color: #1a73e8;
}

.pagination .active {
    background-color: #1a73e8;
    color: white;
    border-color: #1a73e8;
}

/* 老人详情页面样式 */
.detail-section {
    margin-bottom: 30px;
}

.detail-section h2 {
    margin-bottom: 15px;
    color: #1a73e8;
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 10px;
}

.detail-item {
    display: flex;
    margin-bottom: 10px;
}

.detail-item .label {
    width: 150px;
    font-weight: bold;
    color: #666;
}

.detail-item .value {
    flex: 1;
    color: #333;
}

/* 用户管理页面样式 */
.user-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.user-actions .btn {
    flex: 1;
}

/* 单位管理页面样式 */
.unit-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.unit-actions .btn {
    flex: 1;
}

/* 搜索表单样式 */
.search-form {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    margin-bottom: 20px;
}

.search-form .form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.search-form .form-group {
    flex: 1;
    margin-bottom: 0;
}

.search-form .form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* 评估结论样式 */
.assessment-result {
    background-color: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 20px;
}

.assessment-result h3 {
    margin: 0 0 10px 0;
    color: #1a73e8;
    font-size: 16px;
}

.assessment-result p {
    margin: 0;
    color: #333;
}