/*
 * Cupcake Cult Theme - Purple and pink pastry colors
 */

:root {
    /* Primary colors */
    --color-primary: #a034b5;
    --color-primary-light: #c44ad7;
    --color-section-bg: #f3ecde;

    /* Gradients */
    --gradient-primary: linear-gradient(90deg, #a034b5, #c44ad7);
    --gradient-sidebar: linear-gradient(180deg, #a034b5 0%, #c44ad7 100%);
    --gradient-button: linear-gradient(135deg, #a034b5, #c44ad7);
    --gradient-welcome: linear-gradient(135deg, #fce4ec 0%, #f8bbd0 100%);

    /* Tooltip */
    --color-tooltip-bg: rgba(160, 52, 181, 0.95);
}

/* Filter visibility rules */
.filter-container:has(#filter-recipes:checked) ~ .content .section[data-tags*="recipes"] {
    display: block;
}

.filter-container:has(#filter-tips:checked) ~ .content .section[data-tags*="tips"] {
    display: block;
}

.filter-container:has(#filter-chocolate:checked) ~ .content .section[data-tags*="chocolate"] {
    display: block;
}

.filter-container:has(#filter-festive:checked) ~ .content .section[data-tags*="festive"] {
    display: block;
}

.filter-container:has(#filter-kid-friendly:checked) ~ .content .section[data-tags*="kid-friendly"] {
    display: block;
}

/* Filter chip active states */
#filter-all:checked ~ .quick-filter-bar label[for="filter-all"],
#filter-recipes:checked ~ .quick-filter-bar label[for="filter-recipes"],
#filter-tips:checked ~ .quick-filter-bar label[for="filter-tips"],
#filter-chocolate:checked ~ .quick-filter-bar label[for="filter-chocolate"],
#filter-festive:checked ~ .quick-filter-bar label[for="filter-festive"],
#filter-kid-friendly:checked ~ .quick-filter-bar label[for="filter-kid-friendly"] {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 2px 8px rgba(27, 39, 123, 0.3);
}

#filter-all:checked ~ .quick-filter-bar label[for="filter-all"] .chip-count,
#filter-recipes:checked ~ .quick-filter-bar label[for="filter-recipes"] .chip-count,
#filter-tips:checked ~ .quick-filter-bar label[for="filter-tips"] .chip-count,
#filter-chocolate:checked ~ .quick-filter-bar label[for="filter-chocolate"] .chip-count,
#filter-festive:checked ~ .quick-filter-bar label[for="filter-festive"] .chip-count,
#filter-kid-friendly:checked ~ .quick-filter-bar label[for="filter-kid-friendly"] .chip-count {
    background: rgba(255, 255, 255, 0.25);
    color: white;
}

/* TOC sync rules */
body:has(#filter-recipes:checked) .toc-sidebar .toc-link[href="#baking-tips"],
body:has(#filter-recipes:checked) .toc-sidebar .toc-link[href="#welcome"] {
    opacity: 0.3;
    pointer-events: none;
    text-decoration: line-through;
}

body:has(#filter-tips:checked) .toc-sidebar .toc-link[href="#chocolate-classic"],
body:has(#filter-tips:checked) .toc-sidebar .toc-link[href="#gingerbread-eggnog"],
body:has(#filter-tips:checked) .toc-sidebar .toc-link[href="#vanilla-sprinkle"],
body:has(#filter-tips:checked) .toc-sidebar .toc-link[href="#welcome"] {
    opacity: 0.3;
    pointer-events: none;
    text-decoration: line-through;
}

body:has(#filter-chocolate:checked) .toc-sidebar .toc-link[href="#baking-tips"],
body:has(#filter-chocolate:checked) .toc-sidebar .toc-link[href="#gingerbread-eggnog"],
body:has(#filter-chocolate:checked) .toc-sidebar .toc-link[href="#vanilla-sprinkle"],
body:has(#filter-chocolate:checked) .toc-sidebar .toc-link[href="#welcome"] {
    opacity: 0.3;
    pointer-events: none;
    text-decoration: line-through;
}

body:has(#filter-festive:checked) .toc-sidebar .toc-link[href="#chocolate-classic"],
body:has(#filter-festive:checked) .toc-sidebar .toc-link[href="#baking-tips"],
body:has(#filter-festive:checked) .toc-sidebar .toc-link[href="#vanilla-sprinkle"],
body:has(#filter-festive:checked) .toc-sidebar .toc-link[href="#welcome"] {
    opacity: 0.3;
    pointer-events: none;
    text-decoration: line-through;
}

body:has(#filter-kid-friendly:checked) .toc-sidebar .toc-link[href="#chocolate-classic"],
body:has(#filter-kid-friendly:checked) .toc-sidebar .toc-link[href="#baking-tips"],
body:has(#filter-kid-friendly:checked) .toc-sidebar .toc-link[href="#gingerbread-eggnog"],
body:has(#filter-kid-friendly:checked) .toc-sidebar .toc-link[href="#welcome"] {
    opacity: 0.3;
    pointer-events: none;
    text-decoration: line-through;
}
