/* Custom CSS for layout and components */

/* Navigation */
nav .current {
    color: var(--pico-primary);
    font-weight: bold;
}

.logo {
    text-decoration: none !important;
    color: var(--pico-primary) !important;
}

/* Hero section */
.hero {
    text-align: center;
    margin-bottom: 2rem;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--pico-primary);
}

.hero p {
    font-size: 1.2rem;
    color: var(--pico-muted-color);
    margin-bottom: 2rem;
}

/* Search form */
.search-form {
    margin: 2rem 0;
}

.search-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto;
    gap: 1rem;
    align-items: end;
}

@media (max-width: 768px) {
    .search-grid {
        grid-template-columns: 1fr;
    }
}

/* Recipe grid */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
    width: 100%;
}

@media (max-width: 768px) {
    .recipe-grid {
        grid-template-columns: 1fr;
    }
}

.recipe-card {
    border: 1px solid var(--pico-border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    background: var(--pico-background-color);
    height: fit-content;
}

.recipe-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.recipe-card.featured {
    border-color: var(--pico-primary);
}

.recipe-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.recipe-info {
    padding: 1rem;
}

.recipe-info h3 {
    margin: 0 0 0.5rem 0;
}

.recipe-info h3 a {
    text-decoration: none;
    color: var(--pico-color);
}

.recipe-info h3 a:hover {
    color: var(--pico-primary);
}

.recipe-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: var(--pico-muted-color);
    margin-top: 0.5rem;
}

.category {
    background: var(--pico-primary);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    text-transform: uppercase;
}

/* Recipe detail page */
.recipe-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--pico-border-color);
}

.recipe-description {
    font-size: 1.1rem;
    color: var(--pico-muted-color);
    margin: 1rem 0;
}

.recipe-meta-detail {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.category-badge {
    background: var(--pico-primary);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    text-transform: uppercase;
    font-size: 0.9rem;
    font-weight: bold;
}

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

.recipe-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

@media (max-width: 768px) {
    .recipe-content {
        grid-template-columns: 1fr;
    }
}

.recipe-image img {
    width: auto;
    border-radius: 8px;
    max-height: 400px;
}

.ingredients ul, .instructions ol {
    padding-left: 1.5rem;
}

.ingredients li, .instructions li {
    margin-bottom: 0.5rem;
}

.recipe-footer {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid var(--pico-border-color);
}

/* Form layouts */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.recipe-form {
    max-width: 800px;
    margin: 0 auto;
}

/* About section */
.about {
    background: var(--pico-background-color);
    border-radius: 8px;
    margin: 2rem 0;
    text-align: center;
}

/* Utility classes */
.text-center { text-align: center; }
.mt-2 { margin-top: 2rem; }
.mb-2 { margin-bottom: 2rem; }