body { font-family: Arial, sans-serif; background-color: #f4f4f4; margin: 0; padding: 0; } .container { width: 80%; margin: 0 auto; padding: 20px; background-color: white; box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); margin-top: 50px; } h1, h2 { color: #333; } form { margin-bottom: 20px; } .form-group { margin-bottom: 10px; } label { display: block; margin-bottom: 5px; font-weight: bold; } input[type="text"], input[type="file"], input[type="date"] { width: 100%; padding: 8px; margin: 5px 0; border-radius: 4px; border: 1px solid #ddd; } button[type="submit"] { padding: 10px 20px; background-color: #4CAF50; color: white; border: none; border-radius: 4px; cursor: pointer; } button[type="submit"]:hover { background-color: #45a049; } table { width: 100%; border-collapse: collapse; margin-top: 20px; } table, th, td { border: 1px solid #ddd; } th, td { padding: 10px; text-align: center; } .btn-edit, .btn-delete { padding: 5px 10px; background-color: #007BFF; color: white; border: none; border-radius: 4px; cursor: pointer; } .btn-edit:hover { background-color: #0056b3; } .btn-delete { background-color: #DC3545; } .btn-delete:hover { background-color: #c82333; } .photo-gallery { display: flex; flex-wrap: wrap; } .photo-item { margin: 10px; width: 200px; height: 200px; overflow: hidden; } .photo-item img { width: 100%; height: 100%; object-fit: cover; } .user-photo { max-width: 100px; /* 设置最大宽度 */ max-height: 100px; /* 设置最大高度 */ width: auto; /* 保持宽高比例 */ height: auto; /* 保持宽高比例 */ }