body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 10px;
    background-color: #fff;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* 登录表单样式 */
#login-form {
    max-width: 400px;
    width: 100%;
    margin: 20px auto;
    padding: 30px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: #f9f9f9;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

#login-form h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #555;
}

.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px; /* 增大字体以便触摸 */
    box-sizing: border-box;
}

.password-field-container {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    user-select: none;
    font-size: 16px;
}

.captcha-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.captcha-container input {
    flex: 1;
}

.captcha-img {
    width: 100px;
    height: 40px; /* 增加高度 */
    background-color: #eee;
    border: 1px solid #ccc;
    border-radius: 4px;
    text-align: center;
    line-height: 40px; /* 调整行高 */
    font-weight: bold;
    cursor: pointer;
    user-select: none;
    font-size: 16px; /* 增大字体 */
}

.login-btn {
    width: 100%;
    padding: 15px; /* 增加内边距 */
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 18px; /* 增大字体 */
    font-weight: bold;
    cursor: pointer;
    margin-top: 10px;
}

.login-btn:hover {
    background-color: #45a049;
}

.change-password-link {
    text-align: center;
    margin-top: 15px;
    font-size: 16px; /* 增大字体 */
}

.change-password-link a {
    color: #2196F3;
    text-decoration: none;
    cursor: pointer;
}

.change-password-link a:hover {
    text-decoration: underline;
}

/* 修改密码表单样式 */
#change-password-form {
    max-width: 400px;
    width: 100%;
    margin: 20px auto; /* 调整外边距 */
    padding: 30px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: #f9f9f9;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    display: none;
}

#change-password-form h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.back-link {
    text-align: center;
    margin-top: 15px;
    font-size: 16px; /* 增大字体 */
}

.back-link a {
    color: #2196F3;
    text-decoration: none;
    cursor: pointer;
}

.error-message {
    color: red;
    font-size: 16px; /* 增大字体 */
    margin-top: 10px;
    text-align: center;
}

.success-message {
    color: green;
    font-size: 16px; /* 增大字体 */
    margin-top: 10px;
    text-align: center;
}

/* 主要内容区域样式 */
#main-content {
    max-width: 90%;
    width: 90%;
    display: none;
}

.top-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin: 20px auto;
    padding: 15px;
    background-color: #f5f5f5;
    border-radius: 5px;
    max-width: 100%;
    width: calc(100% - 20px);
}

.selectors {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 15px;
}

.area-selector select, .street-selector select {
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #ccc;
    background-color: white;
    font-size: 16px;
    min-width: 120px;
}

.date-time-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.date-time-container label {
    margin: 0 10px 0 0;
}

.date-time-container input {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
}

.date-time-container input[type="datetime-local"] {
    width: auto;
}

.datetime-display {
    margin-top: 10px;
    width: 100%;
    font-size: 16px;
    font-weight: bold;
    color: #333;
}

.datetime-display span {
    margin: 5px 0;
    font-size: 16px;
    color: #333;
}

.controls {
    margin: 0;
    text-align: right;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

button {
    padding: 12px 16px;
    margin: 5px;
    cursor: pointer;
    background: linear-gradient(to bottom, #4CAF50, #45a049);
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    white-space: nowrap;
    font-size: 16px;
    min-width: 100px;
    transition: all 0.3s ease;
}

button:hover {
    background: linear-gradient(to bottom, #45a049, #4CAF50);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.change-pwd-btn {
    background: linear-gradient(to bottom, #2196F3, #1976D2);
    padding: 12px 16px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    border: none;
    border-radius: 4px;
    min-width: 100px;
}

.change-pwd-btn:hover {
    background: linear-gradient(to bottom, #1976D2, #2196F3);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.logout-btn {
    background: linear-gradient(to bottom, #f44336, #d32f2f);
    padding: 12px 16px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    border: none;
    border-radius: 4px;
    min-width: 100px;
}

.logout-btn:hover {
    background: linear-gradient(to bottom, #d32f2f, #f44336);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.content-area {
    margin: 20px auto;
    max-width: 100%;
    width: calc(100% - 20px);
    padding: 0 10px;
}

.text-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.text-header h3 {
    margin: 0;
    color: #333;
}

.edit-btn {
    background: linear-gradient(to bottom, #FF9800, #F57C00);
    color: white;
    border: none;
    border-radius: 4px;
    padding: 12px 16px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    min-width: 100px;
}

.edit-btn:hover {
    background: linear-gradient(to bottom, #F57C00, #FF9800);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.text-display {
    width: 100%;
    min-height: 400px;
    padding: 15px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-family: Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    white-space: pre-wrap;
    background-color: #f9f9f9;
}

.text-display[readonly] {
    background-color: #f0f0f0;
    cursor: not-allowed;
}

.text-display:not([readonly]) {
    background-color: white;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.1);
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px;
    background-color: #4CAF50;
    color: white;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    display: none;
    font-size: 16px;
}

.button-controls {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.copy-btn {
    padding: 12px 16px;
    background: linear-gradient(to bottom, #2196F3, #1976D2);
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    min-width: 100px;
}

.copy-btn:hover {
    background: linear-gradient(to bottom, #1976D2, #2196F3);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* 添加遮罩层样式 */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: none;
}

.loading-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 24px;
    font-weight: bold;
}

/* 响应式设计 */
@media screen and (max-width: 768px) {
    body {
        margin: 5px;
        padding: 5px;
        font-size: 16px;
    }

    .top-controls {
        flex-direction: column;
        align-items: stretch;
        width: calc(100% - 10px);
    }

    .selectors {
        flex-direction: column;
        align-items: stretch;
    }

    .date-time-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .date-time-container input {
        width: 100%;
    }

    .controls {
        justify-content: center;
        margin-top: 10px;
    }

    .text-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .edit-btn {
        align-self: flex-end;
    }
    
    /* 移动端按钮适配 */
    button {
        padding: 14px 20px;
        font-size: 16px;
        min-width: 120px;
        margin: 5px;
    }
    
    .button-controls {
        flex-direction: column;
        align-items: center;
    }
    
    .edit-btn, .copy-btn {
        width: 100%;
        max-width: 200px;
    }
    
    .content-area {
        width: calc(100% - 10px);
    }
}