* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    text-align: center;
    margin-bottom: 2rem;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.recipe-container {
    width: 100%;
    max-width: 600px;
}

.recipe-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    overflow: hidden;
    margin-bottom: 2rem;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.recipe-header {
    padding: 1.5rem;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
}

.recipe-header h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.recipe-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.time-badge, .difficulty-badge {
    background: rgba(255,255,255,0.2);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    backdrop-filter: blur(10px);
}

.recipe-image-container {
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.recipe-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.recipe-image-container img:hover {
    transform: scale(1.05);
}

.recipe-content {
    padding: 2rem;
}

.ingredients-section, .instructions-section {
    margin-bottom: 2rem;
}

.ingredients-section h3, .instructions-section h3 {
    color: #ee5a24;
    margin-bottom: 1rem;
    font-size: 1.3rem;
    border-bottom: 2px solid #ee5a24;
    padding-bottom: 0.5rem;
}

.ingredients-section ul {
    list-style: none;
    padding-left: 0;
}

.ingredients-section li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #eee;
    position: relative;
    padding-left: 1.5rem;
}

.ingredients-section li:before {
    content: "🥄";
    position: absolute;
    left: 0;
}

.instructions-section ol {
    padding-left: 1.5rem;
}

.instructions-section li {
    padding: 0.8rem 0;
    border-bottom: 1px solid #eee;
}

.recipe-footer {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 2px solid #eee;
    color: #666;
}

.controls {
    text-align: center;
    margin-bottom: 1rem;
}

.primary-btn, .secondary-btn {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(238, 90, 36, 0.3);
    margin: 0.5rem;
}

.secondary-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.primary-btn:hover, .secondary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.primary-btn:active, .secondary-btn:active {
    transform: translateY(0);
}

.primary-btn:disabled, .secondary-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.loading {
    text-align: center;
    padding: 3rem;
    color: white;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255,255,255,0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error {
    text-align: center;
    padding: 2rem;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
    color: white;
    margin-bottom: 2rem;
}

.server-info {
    text-align: center;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
    margin-top: 1rem;
    padding: 0.5rem;
    background: rgba(255,255,255,0.1);
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

.hidden {
    display: none;
}

footer {
    text-align: center;
    color: white;
    opacity: 0.8;
    margin-top: 2rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .recipe-content {
        padding: 1.5rem;
    }
    
    .primary-btn, .secondary-btn {
        padding: 0.8rem 1.5rem;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 1.8rem;
    }
    
    .recipe-content {
        padding: 1rem;
    }
    
    .recipe-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .primary-btn, .secondary-btn {
        width: 100%;
        margin: 0.25rem 0;
    }
}
