* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Pretendard', sans-serif; }
body { background: #f6f7fb; color: #222; }
header { background: linear-gradient(135deg, #52c234, #2f8f2f); color: white; padding: 50px 20px; text-align: center; }
header h1 { font-size: 42px; }
header p { margin-top: 10px; opacity: .9; font-size: 18px; }
.container { width: 90%; max-width: 1200px; margin: 40px auto 0; }
.search-box { background: white; padding: 35px; border-radius: 18px; box-shadow: 0 10px 30px rgba(0, 0, 0, .08); }
.search-box h2 { margin-bottom: 20px; }
input, select { width: 100%; padding: 16px 18px; font-size: 17px; border: 2px solid #ddd; border-radius: 10px; outline: none; }
input + input { margin-top: 12px; }
input:focus, select:focus { border-color: #3ca34b; }
.button-group { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
button { padding: 14px 22px; border: none; border-radius: 10px; cursor: pointer; font-size: 16px; transition: .2s; }
#recommendBtn { background: #3ca34b; color: white; }
#recommendBtn:hover { background: #2d8a39; }
.filter { background: #efefef; }
.filter:hover { background: #ddd; }
#sortSelect { width: auto; min-width: 150px; }
#loading { display: none; font-size: 20px; text-align: center; padding: 30px; }
.result-title { margin: 40px 0 20px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 25px; }
.card { background: white; border-radius: 18px; overflow: hidden; box-shadow: 0 8px 20px rgba(0, 0, 0, .08); transition: .2s; cursor: pointer; animation: fadeIn .4s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
.card:hover { transform: translateY(-6px); }
.card img { width: 100%; height: 180px; object-fit: cover; }
.card-body { padding: 20px; }
.card-body h3 { margin-bottom: 10px; }
.tag { display: inline-block; padding: 6px 12px; background: #dff5df; color: #2b7a2b; border-radius: 30px; margin-bottom: 10px; }
.info { color: #666; line-height: 1.8; }
.empty-message { grid-column: 1 / -1; background: white; padding: 40px; text-align: center; font-size: 20px; border-radius: 18px; box-shadow: 0 8px 20px rgba(0, 0, 0, .06); }
footer { text-align: center; padding: 40px; color: #888; }
.modal { display: none; position: fixed; left: 0; top: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, .6); z-index: 999; overflow: auto; }
.modal-content { background: white; width: 80%; max-width: 700px; margin: 50px auto; padding: 30px; border-radius: 18px; animation: fade .3s; }
.modal-content img { width: 100%; height: 280px; object-fit: cover; border-radius: 14px; margin-bottom: 20px; }
.close { float: right; font-size: 32px; cursor: pointer; }
.modalInfo { display: flex; gap: 20px; margin: 15px 0; flex-wrap: wrap; }
#modalIngredients, #modalSteps { padding-left: 22px; line-height: 1.8; }
#nutritionBox { margin-top: 10px; }
.nutri { margin-bottom: 15px; }
.nutriBar { width: 100%; height: 12px; background: #ddd; border-radius: 20px; margin-top: 6px; }
.nutriFill { height: 100%; background: #43a047; border-radius: 20px; }
@keyframes fade { from { transform: translateY(-20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@media (max-width: 768px) { header { padding: 35px 20px; } header h1 { font-size: 32px; } .search-box { padding: 25px; } button, #sortSelect { width: 100%; } .modal-content { width: 92%; padding: 22px; } }