/* ========== Tokens ========== */
:root {
    --bg: #ffffff;
    --panel: #f6f9fc;
    --text: #1f2937;
    --muted: #6b7280;
    --line: #e5e7eb;
    --card: #f3f6f9;
    --card-line: #e6ecf2;
    --shadow: 0 8px 30px rgba(2, 6, 23, .08);
}

.hc :root,
.hc {
    --bg: #ffffff;
    --panel: #ffffff;
    --text: #000;
    --muted: #000;
    --line: #000;
    --card: #fff;
    --card-line: #000;
    --shadow: none;
}

/* ========== Header ========== */
.mh {
    position: sticky;
    top: 0;
    z-index: 40;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 10px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
}

.mh-logo img {
    height: 28px;
    display: block;
}

.mh-btn {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fafafa;
    color: var(--text);
}

.mh-btn .i-x {
    display: none;
}

.mh-btn.open .i-bars {
    display: none;
}

.mh-btn.open .i-x {
    display: block;
}

/* ========== Drawer + Backdrop ========== */
.mh-wrap {
    position: fixed;
    inset: 0;
    display: block;
    background: rgba(0, 0, 0, .32);
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
    z-index: 39;
}

.mh-wrap.open {
    opacity: 1;
    pointer-events: auto;
}

.mh-drawer {
    position: absolute;
    inset: 0;
    background: var(--bg);
    transform: translateX(100%);
    transition: transform .3s ease;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}

.mh-wrap.open .mh-drawer {
    transform: translateX(0);
}

/* Top row */
.mh-top {
    align-items: center;
    padding: 65px 5px 5px 5px;
    border-bottom: 1px solid var(--line);
}

.mh-top-logo {
    height: 18px;
}

.mh-close {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fafafa;
    color: var(--text);
}

/* Search pill */
.mh-search {
    position: relative;
    display: flex;
    margin-bottom: 0;
}

.mh-search input {
    width: 100%;
    height: 36px;
    border-radius: 999px;
    border: 1px solid var(--line);
    padding: 0 38px 0 14px;
    font-size: 15px;
    background: var(--panel);
    color: var(--text);
}

.mh-sbtn {
    position: absolute;
    right: 4px;
    top: 40%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: var(--muted);
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
}

/* Cards list */
.mh-nav ul {
    list-style: none;
    margin: 5px;
    padding: 0;
    display: grid;
    gap: 5px;
}

.mh-nav li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
    color: var(--text);
    background: var(--card);
    border: 1px solid var(--card-line);
    border-radius: 10px;
    padding: 10px;
    font-weight: 600;
}

.mh-nav .chev {
    width: 18px;
    height: 18px;
}

/* Divider + meta area */
.mh-divide {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 12px;
}

.mh-meta {
    display: grid;
    gap: 12px;
    margin: 0 12px 16px;
}

.mh-lang summary {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    color: var(--text);
    font-weight: 500;
}

.mh-lang[open] summary {
    margin-bottom: 8px;
}

.mh-lang ul {
    list-style: none;
    margin: 0;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
    display: grid;
    gap: 4px;
}

.mh-lang a {
    text-decoration: none;
    color: var(--text);
    padding: 6px 8px;
    border-radius: 6px;
}

.mh-lang a:active {
    background: #eef2f7;
}

/* High contrast toggle */
.mh-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    user-select: none;
}

.mh-switch input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.mh-switch .track {
    width: 44px;
    height: 24px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: #e5e7eb;
    position: relative;
    display: inline-block;
    vertical-align: middle;
}

.mh-switch .track::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
    transition: left .2s ease;
}

.mh-switch input:checked+.track {
    background: #c7d2fe;
}

.mh-switch input:checked+.track::after {
    left: 22px;
}

.mh-switch .lbl {
    color: var(--muted);
    font-weight: 500;
}

.mh-login {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
}

/* Desktop hide/show */
@media (min-width:991px) {
    .mh {
        display: none;
    }

    .mh-wrap {
        display: none;
    }
}

@media (max-width:992px) {
    #header {
        display: none;
    }
}
/* Prevent body scroll when menu open */
body.mh-lock {
    overflow: hidden;
}

@media (max-width: 768px) {
    #middle-pages .main-pages-mid .middle-wrapper
    {
        padding: 10px;
    }
    .breadcrumb{
        margin: 0;
    }
}