:root {
    --wdb-accent: #1f6b3a;
    --wdb-border: #dfe5e8;
    --wdb-text: #17202a;
    --wdb-muted: #65707a;
    --wdb-soft: #f6f8f7;
}

.wdb-wrapper {
    width: 100%;
    color: var(--wdb-text);
}

.wdb-filter-form {
    margin-bottom: 1.25rem;
}

.wdb-filter-panel {
    border: 0;
    border-radius: 8px;
    background: #fff;
    padding: 1.2rem;
    box-shadow: 0 8px 26px rgba(17, 24, 39, 0.05);
}

.wdb-filter-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.wdb-filter-head h2 {
    margin: 0;
    font-size: 1.25rem;
    line-height: 1.2;
}

.wdb-filter-content {
    margin-top: 1rem;
    padding-top: 1rem;
}

.wdb-filter-content[hidden] {
    display: none;
}

.wdb-tag-search-wrap {
    max-width: 520px;
    margin-bottom: 1.2rem;
}

.wdb-tag-search-wrap label {
    display: block;
    margin-bottom: 0.45rem;
    color: var(--wdb-text);
    font-size: 1rem;
    font-weight: 700;
}

.wdb-tag-search {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--wdb-border);
    border-radius: 6px;
    background: #fff;
    color: var(--wdb-text);
    padding: 0 0.85rem;
    font-size: 0.98rem;
}

.wdb-tag-search:focus {
    border-color: var(--wdb-accent);
    box-shadow: 0 0 0 2px rgba(31, 107, 58, 0.12);
    outline: none;
}

.wdb-filter-groups {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.2rem;
}

.wdb-filter-group {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.wdb-filter-group legend {
    width: 100%;
    margin-bottom: 0.75rem;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--wdb-text);
    font-size: 1rem;
    font-weight: 700;
}

.wdb-options {
    display: grid;
    gap: 0.55rem;
    max-height: 260px;
    overflow: auto;
    padding-right: 0.25rem;
}

.wdb-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    cursor: pointer;
    line-height: 1.25;
}

.wdb-checkbox input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.wdb-box {
    width: 19px;
    height: 19px;
    border: 1.5px solid #b8c0c7;
    border-radius: 4px;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    margin-top: 0.05rem;
}

.wdb-checkbox input:checked + .wdb-box {
    background: var(--wdb-accent);
    border-color: var(--wdb-accent);
}

.wdb-checkbox input:checked + .wdb-box::after {
    content: "✓";
    color: #fff;
    font-size: 0.85rem;
    font-weight: 800;
    line-height: 1;
}

.wdb-checkbox-label {
    color: var(--wdb-text);
    font-size: 0.96rem;
}

.wdb-filter-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.2rem;
    padding-top: 1rem;
}

.wdb-filter-toggle,
.wdb-apply,
.wdb-reset {
    min-height: 42px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    cursor: pointer;
    font-size: 0.96rem;
    font-weight: 700;
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.wdb-filter-toggle {
    border: 1px solid var(--wdb-accent);
    background: #fff;
    color: var(--wdb-accent);
    padding: 0 0.9rem;
}

.wdb-filter-toggle:hover {
    background: var(--wdb-soft);
}

.wdb-filter-toggle-icon {
    width: 9px;
    height: 9px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.15s ease;
}

.wdb-filter-toggle[aria-expanded="true"] .wdb-filter-toggle-icon {
    transform: rotate(225deg) translateY(-2px);
}

.wdb-apply {
    border: 1px solid var(--wdb-accent);
    background: var(--wdb-accent);
    color: #fff;
    padding: 0 1.1rem;
}

.wdb-apply:hover {
    background: #18562f;
    border-color: #18562f;
}

.wdb-reset {
    border: 1px solid var(--wdb-border);
    background: #fff;
    color: var(--wdb-accent);
    padding: 0 0.85rem;
}

.wdb-reset:hover {
    border-color: var(--wdb-accent);
    background: var(--wdb-soft);
}

.wdb-reset-icon {
    font-size: 1.1rem;
    line-height: 1;
}

.wdb-meta-row {
    display: block;
    margin: 1.35rem 0 0.85rem;
}

.wdb-meta-row[hidden] {
    display: none;
}

.wdb-found {
    color: var(--wdb-accent);
    font-weight: 600;
}

.wdb-list {
    display: grid;
    gap: 0.85rem;
}

.wdb-list-item {
    border: 1px solid var(--wdb-border);
    border-radius: 8px;
    background: #fff;
    padding: 1rem 1.1rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.wdb-list-image {
    width: 88px;
    height: 88px;
    border-radius: 6px;
    background: var(--wdb-soft);
    display: block;
    flex: 0 0 88px;
    overflow: hidden;
}

.wdb-list-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.wdb-list-content {
    min-width: 0;
    flex: 1 1 auto;
}

.wdb-list-item h3 {
    margin: 0 0 0.45rem;
    font-size: 1.08rem;
    line-height: 1.3;
}

.wdb-list-item h3 a {
    color: var(--wdb-text);
    text-decoration: none;
}

.wdb-list-item h3 a:hover {
    color: var(--wdb-accent);
    text-decoration: underline;
}

.wdb-list-item p {
    margin: 0 0 0.65rem;
    color: var(--wdb-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

.wdb-list-link {
    color: var(--wdb-accent);
    font-size: 0.92rem;
    font-weight: 700;
    text-decoration: none;
}

.wdb-list-link:hover {
    text-decoration: underline;
}

.wdb-tiles {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.4rem;
}

.wdb-tile-card {
    border: 0;
    border-radius: 0;
    background: #fff;
    overflow: hidden;
    min-width: 0;
}

.wdb-tile-image {
    aspect-ratio: 1.26 / 1;
    background: var(--wdb-soft);
    display: block;
    overflow: hidden;
    text-decoration: none;
}

.wdb-tile-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.wdb-tile-content {
    padding: 1.25rem 1.15rem 1.45rem;
}

.wdb-tile-meta {
    margin-bottom: 0.7rem;
    color: #5d965c;
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 1.3;
}

.wdb-tile-meta a,
.wdb-tile-meta a:visited,
.wdb-tile-meta a:hover,
.wdb-tile-meta a:focus,
.wdb-tile-meta a:active {
    color: inherit;
    text-decoration: none !important;
    border-bottom: 0 !important;
    box-shadow: none !important;
}

.wdb-tile-meta-separator {
    margin: 0 0.35rem;
}

.wdb-tile-card h3 {
    margin: 0 0 0.8rem;
    font-size: 1.18rem;
    line-height: 1.28;
}

.wdb-tile-card h3 a,
.wdb-tile-card h3 a:visited,
.wdb-tile-card h3 a:hover,
.wdb-tile-card h3 a:focus,
.wdb-tile-card h3 a:active {
    color: #df5121;
    text-decoration: underline !important;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.12em;
}

.wdb-tile-card p {
    margin: 0;
    color: #111;
    font-size: 0.94rem;
    line-height: 1.65;
}

.wdb-pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 2rem;
}

.wdb-page-button {
    min-width: 40px;
    height: 40px;
    border: 1px solid var(--wdb-border);
    border-radius: 999px;
    background: #fff;
    color: var(--wdb-text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
}

.wdb-page-button:hover,
.wdb-page-button.is-current {
    border-color: var(--wdb-accent);
    background: var(--wdb-accent);
    color: #fff;
}

.wdb-loading,
.wdb-empty {
    padding: 1rem;
    background: #f7f7f7;
    border-radius: 8px;
}

@media (max-width: 900px) {
    .wdb-filter-groups,
    .wdb-tiles {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .wdb-options {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }

    .wdb-filter-panel {
        padding: 1rem;
    }

    .wdb-filter-head,
    .wdb-filter-actions {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: stretch;
    }

    .wdb-filter-toggle,
    .wdb-reset,
    .wdb-apply {
        width: 100%;
    }

    .wdb-filter-groups,
    .wdb-tiles {
        grid-template-columns: 1fr;
    }

    .wdb-list-item {
        gap: 0.85rem;
        padding: 0.9rem;
    }

    .wdb-list-image {
        width: 72px;
        height: 72px;
        flex-basis: 72px;
    }

    .wdb-tile-content {
        padding: 1rem;
    }

    .wdb-tile-card h3 {
        font-size: 1.08rem;
    }

    .wdb-tile-card p {
        font-size: 0.92rem;
        line-height: 1.55;
    }
}
