﻿.topheader {
    position: relative;
    background: #f1f1f1;
    width: 65%;
    float: right;
    height: 1.8vw;
    clip-path: polygon( 25px 0, 100% 0, 100% 100%, 25px 100%, 0 50% );
    box-shadow: 0 3px 10px rgba(0,0,0,.08);
}

    .topheader ul li {
        float: left;
    }

        .topheader ul li a {
            font-size: 0.9vw;
            color: #000;
            font-weight: 500;
            padding: 0 6px;
            text-decoration: none;
            outline: none;
        }

            .topheader ul li a:hover {
                background: #444;
                color: #fff;
                border: 1px solid #444;
                border-radius: 10px;
            }


.top-head {
    text-decoration: none;
    float: right;
    width: 98%;
}

/* keep icons consistent and small spacing for top header z-index contexts */
.top-head > li {
    position: relative;
}

.verbar {
    color: #000;
}

/* Panel */
.accessiblelinks {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 360px;
    max-width: calc(100vw - 24px);
    background: var(--acc-panel-bg);
    border: 1px solid var(--acc-border);
    box-shadow: var(--acc-shadow);
    border-radius: var(--acc-radius);
    padding: 12px 12px 16px 12px;
    box-sizing: border-box;
    display: none;
    z-index: 9999;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    color: var(--acc-text);
}

    /* open state */
    .accessiblelinks.open {
        display: block;
    }

    /* Header */
    .accessiblelinks .acc-header {
        text-align: center;
        font-weight: 600;
        margin-bottom: 10px;
        font-size: 15px;
        color: var(--acc-text);
    }

    /* Section heading */
    .accessiblelinks .access-section + .access-section {
        margin-top: 10px;
    }

    .accessiblelinks .access-section .section-title {
        font-size: 13px;
        color: var(--acc-muted);
        margin: 8px 6px;
    }

    /* grid of tiles */
    .accessiblelinks .access-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
        padding: 6px;
    }

    /* tile button */
    .accessiblelinks .access-btn {
        background: var(--acc-tile-bg);
        border: 1px solid var(--acc-tile-border);
        border-radius: 8px;
        padding: 10px 8px;
        min-height: 58px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 8px;
        text-align: center;
        cursor: pointer;
        transition: transform .06s ease, box-shadow .06s;
        position: relative;
        color: var(--acc-text);
        font-size: 13px;
    }

        /* hover/focus styles */
        .accessiblelinks .access-btn:hover,
        .accessiblelinks .access-btn:focus {
            transform: translateY(-2px);
            box-shadow: 0 6px 18px rgba(22,34,50,0.06);
            outline: none;
        }

        /* icon inside tile (keeps existing FontAwesome icons working) */
        .accessiblelinks .access-btn .fa,
        .accessiblelinks .access-btn .fas,
        .accessiblelinks .access-btn .em {
            font-size: 18px;
            display: block;
            margin-bottom: 2px;
            color: #111827;
        }

        /* label */
        .accessiblelinks .access-btn .label {
            font-size: 12px;
            line-height: 1.05;
            color: var(--acc-text);
            display: block;
        }

        /* selected tile -> show green circular check at top-right */
        .accessiblelinks .access-btn.selected {
            border-color: rgba(22,163,74,0.18);
            box-shadow: 0 8px 20px rgba(22,163,74,0.06);
            /* small safe reset for tile selected state */
            border-color: rgba(22,163,74,0.18);
        }

            .accessiblelinks .access-btn.selected::after {
                content: "✓";
                color: #fff;
                background: var(--acc-accent);
                width: 20px;
                height: 20px;
                font-size: 12px;
                font-weight: 600;
                display: inline-flex;
                align-items: center;
                justify-content: center;
                border-radius: 50%;
                position: absolute;
                top: -8px;
                right: -8px;
                box-shadow: 0 3px 6px rgba(16,24,40,0.12);
            }

        /* make larger tiles for Text Size section (optional) */
        .accessiblelinks .access-btn.access-large {
            min-height: 68px;
        }


/* Search box styling */
.search-container {
    position: relative;
    display: inline-block;
    padding: 0px 5px;
}

.search-trigger {
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 1rem;
}

.search-box {
    position: fixed !important;
    right: 0;
    top: calc(100% + 8px);
    display: none;
    min-width: 260px;
    max-width: 420px;
    background: #fff;
    border: 1px solid #e6e6e6;
    padding: 5px;
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(18,24,40,0.06);
    z-index: 99999;
    box-sizing: border-box;
    align-items: center;
    gap: 6px;
    width: 50%;
}

/* TEMP FORCE-VISIBILITY — add and test, then remove */
#searchBox {
    right: 25%;
    top: 5%;
    z-index: 999999;
    background: #fff;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    -webkit-mask: none;
    mask: none;
    mix-blend-mode: normal;
    outline: 3px solid rgba(131,132,133,0.85);
}

/* Temporary debug: force visible and high z-index so we see it */
.search-box.open {
    display: flex !important;
}

/* used by JS fallback if clipped */
.search-box input[type="search"] {
    flex: 1 1 auto;
    border: 1px solid #ddd;
    padding: 2% 4%;
    font-size: .95rem;
    height: 50px;
    width: 80%;
}

.search-box button[type="submit"] {
    background: #880000; /* a soft blue, consistent with your border tone */
    color: #fff;
    border: none;
    padding: 3% 4%;
    font-size: 0.95rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s ease;
}

    .search-box button[type="submit"]:hover {
        background: #005ea6;
    }


#toggleAccessibility {
    padding: 0 50%;
    font-size: 1rem;
}



@media (min-width: 1150px) and (max-width: 1349px) {
    .topheader {
        width: 60%;
        height: 4.2vw;
    }

    .top-head {
        width: 95%;
        padding: 0% 0% 0% 3%;
    }

    .topheader ul li a {
        font-size: 1.3vw;
    }
    .main-menu {       
        margin-left: -15%;
    }

    .parent-menu {       
        font-size: 1.2em;
    }


   }

@media (min-width: 1000px) and (max-width: 1100px) {
    .topheader {
        width: 56%;
        height: 2vw;
    }

    .top-head {
        width: 95%;
    }
}

@media (max-width: 992px) {

    .topheader {
        width: 70%;
        height: 2.5vw;
    }

        .topheader ul li a {
            font-size: 1vw;
            padding: 0 5px;
        }
}


@media (max-width: 775px) {
    .topheader {
        width: 100%;
        height: 4vw;
        border-top-left-radius: 0px;
        border-bottom-left-radius: 0px;
        clip-path: none;
        margin-top: 0% !important
    }

    .top-head {
        width: 100%;
    }

    .topheader ul li a {
        font-size: 0.8rem;
        padding: 0 0.3em;
    }

    .hudco-citylogo {
        margin-top: 1.5vw;
    }
}

@media (max-width: 650px) {

    .topheader ul li.change-color a span {
        width: 11px;
        height: 9px;
        float: left;
    }

    .menu-container {
        margin-top: -5%;
        left: 45%;
    }

    .topheader ul li a {
        font-size: 0.6rem;
        padding: 0 0.4em;
    }

    .top-skip {
        display: none;
    }
}


@media (max-width: 480px) {

    .topheader {
        height: 12vw;
        border-bottom: 1px solid #cdcdcd;
    }

        .topheader ul li a {
            font-size: 0.55rem;
            padding: 0 0.3em;
        }
}

@media (max-width: 430px) {
    .topheader {
        height: 6vw
    }

        .topheader ul li a {
            font-size: 0.50rem;
            padding: 0 0.3em;
        }
}
