22301009 | 3a876cc | 2025-04-14 16:22:20 +0800 | [diff] [blame^] | 1 | /* 设置整个兴趣小组页面的背景色和布局 */ |
| 2 | .interest-group-container { |
| 3 | background-color: #f8f1f1; /* 粉色背景 */ |
| 4 | width: 100%; |
| 5 | } |
| 6 | |
| 7 | /* 页面标题样式 */ |
| 8 | h1 { |
| 9 | text-align: center; |
| 10 | color: #5c3f31; /* 深棕色 */ |
| 11 | font-size: 2rem; |
| 12 | margin-bottom: 30px; |
| 13 | } |
| 14 | |
| 15 | /* 筛选部分样式 */ |
| 16 | .filter, .search, .sort { |
| 17 | margin-bottom: 20px; |
| 18 | text-align: center; |
| 19 | } |
| 20 | |
| 21 | .filter select, |
| 22 | .search input, |
| 23 | .sort select { |
| 24 | padding: 10px; |
| 25 | width: 200px; |
| 26 | border-radius: 6px; |
| 27 | border: 1px solid #e0c4a1; /* 浅棕色 */ |
| 28 | background-color: #fff5f5; /* 浅粉色 */ |
| 29 | color: #5c3f31; |
| 30 | font-size: 1rem; |
| 31 | } |
| 32 | |
| 33 | /* 激活时的输入框样式 */ |
| 34 | .filter select:focus, |
| 35 | .search input:focus, |
| 36 | .sort select:focus { |
| 37 | border-color: #b38867; /* 较深的棕色 */ |
| 38 | outline: none; |
| 39 | } |
| 40 | |
| 41 | /* 小组列表样式 */ |
| 42 | .group-list { |
| 43 | display: flex; |
| 44 | flex-wrap: wrap; |
| 45 | gap: 20px; |
| 46 | justify-content: space-between; |
| 47 | } |
| 48 | |
| 49 | /* 每个小组的容器 */ |
| 50 | .group-item { |
| 51 | width: 30%; |
| 52 | border: 1px solid #e0c4a1; /* 浅棕色边框 */ |
| 53 | border-radius: 8px; |
| 54 | overflow: hidden; |
| 55 | background-color: #fff; |
| 56 | box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); |
| 57 | transition: transform 0.3s ease-in-out; |
| 58 | } |
| 59 | |
| 60 | .group-item:hover { |
| 61 | transform: translateY(-5px); /* 鼠标悬停时小组项上升效果 */ |
| 62 | } |
| 63 | |
| 64 | /* 小组封面图样式 */ |
| 65 | .group-cover { |
| 66 | width: 100%; |
| 67 | height: 180px; |
| 68 | object-fit: cover; |
| 69 | transition: opacity 0.3s ease; |
| 70 | } |
| 71 | |
| 72 | /* 小组信息区域 */ |
| 73 | .group-info { |
| 74 | padding: 15px; |
| 75 | background-color: #f8f1f1; /* 浅粉色背景 */ |
| 76 | } |
| 77 | |
| 78 | .group-info h2 { |
| 79 | font-size: 1.2em; |
| 80 | color: #5c3f31; |
| 81 | margin-bottom: 10px; |
| 82 | } |
| 83 | |
| 84 | /* 小组描述部分 */ |
| 85 | .group-info p { |
| 86 | font-size: 1rem; |
| 87 | color: #5c3f31; |
| 88 | } |
| 89 | |
| 90 | /* 分页按钮 */ |
| 91 | .pagination { |
| 92 | text-align: center; |
| 93 | margin-top: 30px; |
| 94 | } |
| 95 | |
| 96 | button { |
| 97 | padding: 10px 20px; |
| 98 | margin: 0 10px; |
| 99 | background-color: #5c3f31; /* 深棕色 */ |
| 100 | color: white; |
| 101 | border: none; |
| 102 | border-radius: 6px; |
| 103 | cursor: pointer; |
| 104 | font-size: 1rem; |
| 105 | transition: background-color 0.3s ease; |
| 106 | } |
| 107 | |
| 108 | button:disabled { |
| 109 | background-color: #d6d6d6; |
| 110 | cursor: not-allowed; |
| 111 | } |
| 112 | |
| 113 | button:hover { |
| 114 | background-color: #b38867; /* 深棕色的 hover 效果 */ |
| 115 | } |
| 116 | |
| 117 | /* 错误信息的样式 */ |
| 118 | .error { |
| 119 | color: #ff6f61; /* 红色 */ |
| 120 | text-align: center; |
| 121 | margin-top: 20px; |
| 122 | } |
| 123 | |
| 124 | /* 加载中的提示 */ |
| 125 | .loading { |
| 126 | color: #5c3f31; |
| 127 | text-align: center; |
| 128 | margin-top: 20px; |
| 129 | font-size: 1.2rem; |
| 130 | } |
| 131 | |
| 132 | /* 响应式设计: 确保在小屏幕下布局能适应 */ |
| 133 | @media (max-width: 768px) { |
| 134 | .group-item { |
| 135 | width: 48%; |
| 136 | } |
| 137 | |
| 138 | .filter select, |
| 139 | .search input, |
| 140 | .sort select { |
| 141 | width: 100%; |
| 142 | margin-bottom: 10px; |
| 143 | } |
| 144 | } |
| 145 | |
| 146 | @media (max-width: 480px) { |
| 147 | .group-item { |
| 148 | width: 100%; |
| 149 | } |
| 150 | |
| 151 | .filter select, |
| 152 | .search input, |
| 153 | .sort select { |
| 154 | width: 100%; |
| 155 | font-size: 0.9rem; |
| 156 | } |
| 157 | } |
| 158 | |