Files
mashangban/static/style.css

473 lines
7.0 KiB
CSS

* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
background-color: #f5f5f5;
color: #333;
line-height: 1.6;
}
.container {
max-width: 100%;
padding: 0 15px;
margin: 0 auto;
}
header {
background-color: #4a90d9;
color: white;
padding: 15px 0;
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
header h1 {
font-size: 24px;
margin-bottom: 10px;
display: flex;
align-items: center;
gap: 15px;
}
header h1 a {
color: white;
text-decoration: none;
}
.header-logo {
height: 40px;
width: auto;
}
header nav ul {
list-style: none;
display: flex;
flex-wrap: wrap;
gap: 15px;
justify-content: space-between;
}
.user-name {
margin-left: auto;
font-size: 14px;
color: #fff;
}
header nav ul li a {
color: white;
text-decoration: none;
font-size: 14px;
}
header nav ul li a:hover {
text-decoration: underline;
}
main {
padding: 20px 0;
min-height: calc(100vh - 140px);
}
h2 {
margin-bottom: 20px;
color: #2c3e50;
}
.flash {
background-color: #d4edda;
color: #155724;
padding: 10px 15px;
margin-bottom: 20px;
border-radius: 4px;
border: 1px solid #c3e6cb;
}
.form {
background: white;
padding: 25px;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.form-group {
margin-bottom: 20px;
}
.form-group label {
display: block;
margin-bottom: 8px;
font-weight: 500;
color: #555;
}
.form-row {
display: flex;
flex-wrap: wrap;
gap: 20px;
margin-bottom: 20px;
align-items: flex-end;
}
.form-group-inline {
flex: 1;
min-width: 200px;
}
.form-group-inline label {
display: block;
margin-bottom: 8px;
font-weight: 500;
color: #555;
}
.checkbox-inline {
display: flex;
align-items: center;
min-width: auto;
}
.checkbox-inline input[type="checkbox"] {
margin-right: 8px;
width: 18px;
height: 18px;
cursor: pointer;
}
.checkbox-inline label {
margin-bottom: 0;
cursor: pointer;
font-weight: normal;
}
.checkbox-group {
display: flex;
align-items: center;
margin-bottom: 20px;
}
.checkbox-group input[type="checkbox"] {
margin-right: 8px;
width: 18px;
height: 18px;
cursor: pointer;
}
.checkbox-group label {
margin-bottom: 0;
cursor: pointer;
font-weight: normal;
}
.form-control {
width: 100%;
padding: 12px;
border: 1px solid #ddd;
border-radius: 4px;
font-size: 14px;
transition: border-color 0.3s;
}
.form-control:focus {
outline: none;
border-color: #4a90d9;
}
.form-control.textarea {
width: 100%;
max-width: 100%;
min-width: 100%;
height: 150px;
max-height: 200px;
min-height: 120px;
resize: none;
}
.btn {
display: inline-block;
padding: 10px 20px;
border: none;
border-radius: 4px;
font-size: 14px;
cursor: pointer;
text-decoration: none;
text-align: center;
transition: background-color 0.3s;
}
.btn-primary {
background-color: #4a90d9;
color: white;
}
.btn-primary:hover {
background-color: #3a80c9;
}
.btn-edit {
background-color: #f39c12;
color: white;
}
.btn-edit:hover {
background-color: #e67e22;
}
.btn-answer {
background-color: #27ae60;
color: white;
}
.btn-answer:hover {
background-color: #2ecc71;
}
.btn-toggle {
background-color: #95a5a6;
color: white;
}
.btn-toggle:hover {
background-color: #7f8c8d;
}
.btn-cancel {
background-color: #ecf0f1;
color: #333;
margin-left: 10px;
}
.btn-cancel:hover {
background-color: #bdc3c7;
}
.question-list {
display: grid;
gap: 20px;
}
.question-item {
background: white;
padding: 20px;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.question-header {
display: flex;
flex-wrap: wrap;
gap: 10px;
margin-bottom: 15px;
align-items: center;
}
.branch {
background-color: #4a90d9;
color: white;
padding: 4px 10px;
border-radius: 4px;
font-size: 12px;
}
.time {
font-size: 12px;
color: #999;
display: block;
margin-bottom: 10px;
}
.status {
font-size: 12px;
padding: 4px 10px;
border-radius: 4px;
}
.status.public {
background-color: #d4edda;
color: #155724;
}
.status.private {
background-color: #f8d7da;
color: #721c24;
}
.status.waiting {
background-color: #fff3cd;
color: #856404;
}
.user {
font-size: 12px;
color: #666;
}
.demand-title {
font-size: 18px;
font-weight: bold;
color: #333;
margin-bottom: 5px;
}
.content {
font-size: 15px;
line-height: 1.8;
margin-bottom: 15px;
color: #444;
}
.question-footer {
border-top: 1px solid #eee;
padding-top: 15px;
}
.contact {
font-size: 14px;
color: #666;
margin-bottom: 10px;
display: block;
}
.answer {
background-color: #f8f9fa;
padding: 15px;
border-radius: 4px;
margin: 10px 0;
}
.answer p {
margin: 10px 0;
color: #333;
}
.answer-time {
font-size: 12px;
color: #999;
}
.answer-toggle {
cursor: pointer;
color: #4a90d9;
font-size: 14px;
user-select: none;
padding: 8px 0;
}
.answer-toggle:hover {
color: #3a80c9;
}
.toggle-icon {
margin-right: 5px;
font-size: 12px;
}
.actions {
margin-top: 15px;
display: flex;
flex-wrap: wrap;
gap: 10px;
}
.empty {
text-align: center;
color: #999;
padding: 40px;
background: white;
border-radius: 8px;
}
.login-required {
text-align: center;
padding: 60px 20px;
background: white;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.login-icon {
font-size: 64px;
margin-bottom: 20px;
}
.login-required h2 {
color: #2c3e50;
margin-bottom: 15px;
}
.login-required p {
color: #666;
margin-bottom: 20px;
}
.login-hint {
background-color: #f8f9fa;
padding: 20px;
border-radius: 4px;
margin-top: 20px;
}
.login-hint p {
margin-bottom: 10px;
}
.url-example {
font-family: monospace;
font-size: 14px;
color: #4a90d9;
background-color: #fff;
padding: 10px;
border-radius: 4px;
border: 1px solid #ddd;
word-break: break-all;
}
.hint {
margin-top: 15px;
padding: 10px;
background-color: #fff3cd;
border-radius: 4px;
font-size: 14px;
color: #856404;
}
.question-preview {
background: #f8f9fa;
padding: 20px;
border-radius: 8px;
margin-bottom: 20px;
}
.question-preview h3 {
margin-bottom: 10px;
color: #2c3e50;
}
.question-preview .meta {
font-size: 14px;
color: #666;
margin-top: 10px;
}
footer {
background-color: #2c3e50;
color: white;
text-align: center;
padding: 15px 0;
font-size: 14px;
}
@media (min-width: 768px) {
.container {
max-width: 720px;
}
}
@media (min-width: 992px) {
.container {
max-width: 960px;
}
}