/*
 * public/home/perch-bird.css
 * The hummingbird mascot perched on the calendar filters: on the "Shopping" button on wide
 * screens, on the top-right corner of the dropdown on phones. Decoration only: it ignores
 * clicks and is hidden from screen readers.
 *
 * The bird's feet sit at about 80% of the image height, so pulling it up by 80% of its
 * height puts the feet on the edge and lets the tail hang over the front.
 */

.etw-perch-bird {
    position: absolute;
    z-index: 2;
    height: auto;
    pointer-events: none;
    user-select: none;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.15));
}

/* ---- Phones: on the dropdown ---- */
.etw-filter-select-wrap {
    position: relative;
}

.etw-perch-bird--select {
    width: 46px;
    top: -45px;          /* 80% of the bird's 56px height */
    right: 14px;
}

.etw-perch-bird--bar {
    display: none;
}

/* ---- Tablets: 4 columns of buttons, perch on "Drink" (top row, far right) ---- */
@media (min-width: 600px) {
    .etw-filter-select-wrap {
        display: none;
    }

    .etw-filters {
        position: relative;
        margin-top: 48px;    /* headroom so the bird clears the "Upcoming events" label */
    }

    .etw-perch-bird--bar {
        display: block;
        width: 42px;
        top: -41px;      /* 80% of the bird's 51px height */
        /* column 4 of 4 with 10px gaps, a bit right of the button's middle */
        left: calc(3 * ((100% - 30px) / 4 + 10px) + (100% - 30px) / 4 * 0.45);
    }
}

/* ---- Desktop: 8 columns in one row, perch on "Shopping" (column 7) ---- */
@media (min-width: 900px) {
    .etw-filters {
        margin-top: 0;
    }

    .etw-perch-bird--bar {
        left: calc(6 * ((100% - 70px) / 8 + 10px) + (100% - 70px) / 8 * 0.3);
    }
}

/* ---- Wide desktop: a bigger bird so it doesn't look lost on a large screen ---- */
@media (min-width: 1200px) {
    .etw-perch-bird--bar {
        width: 60px;
        top: -58px;      /* 80% of the bird's 73px height */
        left: calc(6 * ((100% - 70px) / 8 + 10px) + (100% - 70px) / 8 * 0.22);
    }
}
