/* Dropdown modern look */
.dropdown {
    position: relative;
    display: flex;
    align-self: stretch;
}

.dropdown-content {
    display: none;
    position: absolute;
    min-width: 240px;
    background: #fff;
    color: #222;
    box-shadow: 0 6px 32px #0002;
    border-radius: 0.7em;
    padding: 0.6em 0.1em;
    top: calc(100% + 8px);
    /* adds 8px visible gap */
    left: 0;
    z-index: 10;
    border: 1px solid #ececec;
}

.dropdown-right .dropdown-content {
    left: auto;
    right: 0;
}

.dropdown::after {
    content: "";
    display: block;
    position: absolute;
    left: 0;
    top: 100%;
    width: 100%;
    height: 12px;
    /* same or slightly more than the gap */
    pointer-events: auto;
    /* background: rgba(255,0,0,0.08);  /* Uncomment for debugging bridge position */
}

.dropdown:hover .dropdown-content,
.dropdown:focus-within .dropdown-content,
.dropdown:hover::after,
.dropdown:focus-within::after {
    display: block;
}


.dropdown-content a {
    display: flex;
    align-items: center;
    padding: 0.9em 1.1em;
    color: #1a1a1a;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.18s;
    border-radius: 0.4em;
    font-size: 1em;
    white-space: nowrap;
}

.dropdown-content a:hover {
    background: #f2f2fa;
}

.dropdown-content hr {
    margin: 0.5em 0;
    border: none;
    border-top: 1px solid #eee;
}



@media (max-width: 700px) {
    .dropdown-content {
        position: fixed !important;
        left: 8px !important;
        right: 8px !important;
        top: unset !important;
        /* Place below the button: */
        transform: none !important;
        margin-top: 1em;
        min-width: unset !important;
        width: auto !important;
        max-width: 96vw;
        border-radius: 1em;
        z-index: 50;
        box-shadow: 0 8px 32px #0003;
        border: 1.5px solid #ececec;
        padding: 0.8em 0.1em;
    }

    /* .dropdown-right .dropdown-content {
        left: 8px !important;
        right: 8px !important;
    } */
}