.cookbook-page {
    padding-bottom: 2rem;
}

.cookbook-panel {
    padding-top: 0.25rem;
}

.cookbook-section-title {
    margin: 0 0 1rem;
    font-size: clamp(1.35rem, 2.5vw, 1.75rem);
    color: var(--green-dark, #0e5d24);
}

.cookbook-block-title {
    margin: 0 0 0.85rem;
    font-size: 1.15rem;
    color: var(--green, #0d5922);
}

.cookbook-intro {
    margin-bottom: 1.5rem;
}

.cookbook-quick-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.cookbook-filter {
    margin-bottom: 1.5rem;
}

.cookbook-filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.cookbook-pill {
    display: inline-block;
    padding: 0.45rem 0.95rem;
    border-radius: 999px;
    border: 1px solid var(--cream-dark, #e8e0d0);
    background: #fff;
    color: var(--text, #333);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.cookbook-pill:hover {
    background: var(--cream, #f7f3ea);
    color: var(--green-dark, #0e5d24);
}

.cookbook-pill.is-active {
    background: var(--green, #0d5922);
    border-color: var(--green, #0d5922);
    color: #fff;
}

.cookbook-recipe-grid {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.25rem;
}

.cookbook-recipe-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
    color: inherit;
    border: 1px solid var(--cream-dark, #e8e0d0);
    border-radius: var(--radius, 10px);
    overflow: hidden;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.cookbook-recipe-card-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
    border-color: rgba(13, 89, 34, 0.25);
}

.cookbook-recipe-card-media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--cream, #f7f3ea);
}

.cookbook-recipe-card-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.25s ease;
}

.cookbook-recipe-card-link:hover .cookbook-recipe-card-image {
    transform: scale(1.04);
}

.cookbook-recipe-card-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--cream, #f7f3ea), #ece4d4);
}

.cookbook-recipe-badge {
    position: absolute;
    left: 0.65rem;
    bottom: 0.65rem;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--green-dark, #0e5d24);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.cookbook-recipe-badge--inline {
    position: static;
    display: inline-block;
}

.cookbook-recipe-card-body {
    padding: 0.9rem 1rem 1.1rem;
    flex: 1;
}

.cookbook-recipe-card-title {
    margin: 0 0 0.35rem;
    font-size: 1.05rem;
    line-height: 1.35;
    color: var(--green-dark, #0e5d24);
}

.cookbook-recipe-card-link:hover .cookbook-recipe-card-title {
    color: var(--green, #0d5922);
}

.cookbook-recipe-card-meta {
    margin: 0;
    font-size: 0.88rem;
    color: var(--muted, #666);
}

.cookbook-recipe-detail {
    max-width: 1080px;
}

.cookbook-recipe-back {
    margin: 0 0 0.5rem;
    font-size: 0.92rem;
}

.cookbook-recipe-back a {
    text-decoration: none;
    font-weight: 600;
}

.cookbook-recipe-hero {
    display: grid;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

.cookbook-recipe-title {
    margin-bottom: 0.65rem;
}

.cookbook-recipe-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1rem;
    margin-bottom: 0.75rem;
    color: var(--muted, #666);
    font-size: 0.92rem;
}

.cookbook-recipe-meta-item {
    display: inline-flex;
    align-items: center;
}

.cookbook-recipe-summary {
    margin: 0;
}

.cookbook-recipe-hero-image {
    margin: 0;
    border-radius: var(--radius, 10px);
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.cookbook-recipe-hero-image img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 420px;
    object-fit: cover;
}

.cookbook-recipe-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    padding: 0.85rem 1rem;
    background: var(--cream, #f7f3ea);
    border: 1px solid var(--cream-dark, #e8e0d0);
    border-radius: var(--radius, 10px);
}

.cookbook-servings-label {
    font-weight: 600;
    color: var(--green-dark, #0e5d24);
}

.cookbook-servings-input {
    width: 5.5rem;
    padding: 0.45rem 0.55rem;
    border: 1px solid var(--cream-dark, #e8e0d0);
    border-radius: var(--radius, 6px);
    font: inherit;
}

.cookbook-recipe-columns {
    display: grid;
    gap: 1.5rem 2rem;
}

.cookbook-section {
    margin-bottom: 1.75rem;
}

.cookbook-section--ingredients,
.cookbook-section--instructions {
    margin-bottom: 0;
}

.cookbook-ingredient-list,
.cookbook-instruction-list {
    padding: 0;
    margin: 0;
    list-style: none;
}

.cookbook-ingredient-list {
    background: #fff;
    border: 1px solid var(--cream-dark, #e8e0d0);
    border-radius: var(--radius, 10px);
    overflow: hidden;
}

.cookbook-ingredient {
    border-bottom: 1px solid var(--cream-dark, #e8e0d0);
}

.cookbook-ingredient:last-child {
    border-bottom: none;
}

.cookbook-instruction-list {
    counter-reset: cookbook-step;
}

.cookbook-instruction-list > .cookbook-instruction {
    counter-increment: cookbook-step;
    margin-bottom: 0.85rem;
    padding: 0.85rem 0.95rem;
    background: #fff;
    border: 1px solid var(--cream-dark, #e8e0d0);
    border-radius: var(--radius, 10px);
}

.cookbook-check-label {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    cursor: pointer;
    padding: 0.85rem 0.95rem;
}

.cookbook-instruction .cookbook-check-label {
    padding: 0;
}

.cookbook-check-label input {
    margin-top: 0.2rem;
    flex-shrink: 0;
    width: 1.05rem;
    height: 1.05rem;
    accent-color: var(--green, #0d5922);
}

.cookbook-instruction-text::before {
    content: counter(cookbook-step) ". ";
    font-weight: 700;
    color: var(--green, #0d5922);
}

.cookbook-ingredient.is-done .cookbook-ingredient-text,
.cookbook-instruction.is-done .cookbook-instruction-text {
    text-decoration: line-through;
    opacity: 0.62;
}

.cookbook-notes {
    padding: 1rem 1.1rem;
    background: var(--cream, #f7f3ea);
    border-radius: var(--radius, 10px);
    border: 1px solid var(--cream-dark, #e8e0d0);
}

.cookbook-notes-body {
    margin: 0;
    line-height: 1.65;
}

.cookbook-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--cream-dark, #e8e0d0);
    border-radius: var(--radius, 10px);
}

.cookbook-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.cookbook-table th,
.cookbook-table td {
    border-bottom: 1px solid var(--cream-dark, #e8e0d0);
    padding: 0.65rem 0.85rem;
    text-align: left;
    vertical-align: top;
}

.cookbook-table tr:last-child th,
.cookbook-table tr:last-child td {
    border-bottom: none;
}

.cookbook-table thead th,
.cookbook-table th[scope="row"] {
    background: var(--cream, #f7f3ea);
    font-weight: 600;
}

.cookbook-measurement-list {
    columns: 2;
    column-gap: 2rem;
    margin-bottom: 1.5rem;
    padding-left: 1.1rem;
}

.cookbook-measurement-list li {
    margin-bottom: 0.35rem;
}

.cookbook-section-heading {
    margin-top: 2rem;
    font-size: 1.15rem;
    color: var(--green-dark, #0e5d24);
}

.cookbook-empty {
    color: var(--muted, #666);
    padding: 1rem 0;
}

@media (min-width: 900px) {
    .cookbook-recipe-hero {
        grid-template-columns: minmax(0, 1fr) minmax(280px, 42%);
        align-items: start;
    }

    .cookbook-recipe-columns {
        grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
        align-items: start;
    }
}

@media (max-width: 640px) {
    .cookbook-measurement-list {
        columns: 1;
    }

    .cookbook-filter-pills {
        gap: 0.4rem;
    }

    .cookbook-pill {
        font-size: 0.85rem;
        padding: 0.4rem 0.75rem;
    }
}

@media print {
    .camp-tabs,
    .cookbook-recipe-toolbar,
    .cookbook-recipe-back,
    .site-header,
    .site-footer,
    .cookbook-check-label input {
        display: none !important;
    }

    .cookbook-ingredient.is-done .cookbook-ingredient-text,
    .cookbook-instruction.is-done .cookbook-instruction-text {
        text-decoration: line-through;
    }
}
