Fourtris's picture
Commit Project
74d6c39
/* General Styles */
body {
font-family: 'Roboto', sans-serif;
background-color: #111111;
color: #eee;
margin: 0;
padding: 0;
}
.container {
width: 90%;
max-width: 1200px;
margin: 0 auto;
padding: 20px;
}
/* Header */
.header {
background-color: #055470;
padding: 20px 0;
animation: fadeIn 2s ease-in-out;
position: relative;
}
.header-content {
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 80px;
}
.logo {
font-size: 1.8em;
font-weight: 700;
color: #fff;
text-transform: uppercase;
}
.nav-links {
list-style: none;
display: flex;
gap: 20px;
margin: 0;
padding: 0;
}
.nav-links li a {
font-size: 1.2em;
color: #f4eded;
text-decoration: none;
font-weight: 400;
transition: color 0.3s;
}
.nav-links li a:hover {
color: #240606;
}
/* Intro Section */
.intro {
background-image: url('images/1.jpg');
background-size: cover;
color: #fff;
padding: 0; /* 将 padding 设置为 0,以便内容覆盖整个背景 */
text-align: center;
animation: fadeIn 2s ease-in-out;
position: relative;
height: 400px; /* 可以根据需要调整这个高度 */
padding: 40px;
}
.intro-content {
background: rgba(0, 0, 0, 0.8);
padding: 20px; /* 调整内边距,以让文字看起来合适 */
animation: slideIn 2s ease-in-out;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
box-sizing: border-box;
}
.intro h2 {
font-size: 2.5em;
margin-bottom: 20px;
}
/* instruction Section */
.instruction {
background-color:#055470;
color: #f7f4f4;
text-align: left;
animation: fadeIn 2s ease-in-out;
}
.inst-content {
padding: 40px;
border-radius: 10px;
animation: slideIn 2s ease-in-out;
}
.instruction h2 {
font-size: 3.2em;
margin-bottom: 20px;
}
.steps {
text-align: left;
padding-left: 20px;
}
.steps li {
margin-bottom: 10px;
}
/* Upload Section */
.upload-section {
background-color: #222;
color: #eee;
padding: 60px 20px;
text-align: center;
border-radius: 10px;
margin: 20px 0;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
animation: fadeIn 2s ease-in-out;
}
.upload-content h2 {
font-size: 2.2em;
margin-bottom: 20px;
}
form label {
display: block;
margin-bottom: 10px;
font-weight: 700;
}
form input[type="file"] {
margin-bottom: 20px;
padding: 10px;
border-radius: 5px;
border: none;
background-color: #444;
color: #eee;
}
.upload-btn {
background-color: #00e5ff;
color: #000;
border: none;
padding: 15px 30px;
font-size: 1em;
font-weight: 700;
border-radius: 5px;
cursor: pointer;
transition: background-color 0.3s;
}
.upload-btn:hover {
background-color: #00b8cc;
}
.loading-message {
font-style: italic;
color: #00e5ff;
}
/* Result Section */
.result-section {
background-color: #333;
padding: 20px;
margin-top: 20px;
border-radius: 10px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
animation: fadeIn 2s ease-in-out;
}
.result-section h2 {
font-size: 2.2em;
color: #00e5ff;
margin-bottom: 30px;
text-align: center;
}
.result-section ol {
list-style-type: none; /* 隐藏默认的编号 */
padding-left: 0; /* 去除左侧缩进 */
}
.result-section li {
margin-bottom: 10px;
}
/* Footer */
.footer {
background-color: #000;
color: #aaa;
text-align: center;
padding: 20px 0;
margin-top: 40px;
animation: fadeIn 2s ease-in-out;
}
.footer p {
margin: 0;
font-size: 0.9em;
}
/* Animations */
@keyframes fadeIn {
0% { opacity: 0; }
100% { opacity: 1; }
}
@keyframes slideIn {
0% { transform: translateY(20px); opacity: 0; }
100% { transform: translateY(0); opacity: 1; }
}
@media (max-width: 768px) {
.header-content {
flex-direction: column;
align-items: center;
padding: 10px 20px;
}
.nav-links {
flex-direction: column;
gap: 10px;
margin-top: 10px;
}
.nav-links li a {
font-size: 1em;
}
}
.recipe-container {
display: flex;
align-items: flex-start;
gap: 20px; /* Space between image and text */
margin-top: 20px;
}
.recipe-image {
flex: 1; /* Takes up equal space or adjust as needed */
max-width: 50%; /* Ensures the image section doesn't grow too large */
}
.recipe-text {
flex: 2; /* More space for text */
text-align: left; /* Left-align the recipe text */
}
.recipe-text p {
margin: 0;
}
img#recipe-image {
border: 1px solid #ddd;
border-radius: 8px;
}
img.recipe-image-demo {
border: 1px solid #ddd;
border-radius: 8px;
}