/* GNSH V47 — clean three-column accessibility sidebar and compact language selector */

/* Circular launcher: strong double ring, clear human accessibility mark. */
body.government-v47 .gh46-accessibility__launcher {
    width: 54px;
    height: 54px;
    border: 3px solid #fff;
    background: #075fca;
    box-shadow: 0 0 0 2px #075fca, 0 9px 22px rgba(4, 55, 121, .28);
}

body.government-v47 .gh46-accessibility__launcher::before {
    inset: 4px;
    border: 1.5px solid #fff;
    opacity: 1;
}

body.government-v47 .gh46-accessibility__launcher svg {
    width: 31px;
    height: 31px;
    stroke: #fff;
    stroke-width: 2.1;
}

body.government-v47 .gh46-accessibility__launcher svg circle {
    fill: #fff;
    stroke: none;
}

body.government-v47 .gh46-accessibility__active-badge {
    display: none !important;
}

body.government-v47 .gh46-accessibility__launcher:hover,
body.government-v47 .gh46-accessibility__launcher:focus-visible {
    background: #064fae;
    box-shadow: 0 0 0 2px #064fae, 0 12px 28px rgba(4, 55, 121, .36);
}

body.government-v47 .gh46-accessibility {
    width: 54px;
}

/* Accessibility sidebar */
body.government-v47 .gh47-accessibility__panel {
    width: min(400px, calc(100vw - 20px));
    border-right: 1px solid #c8d3df;
    border-radius: 0;
    background: #eef1f5;
    box-shadow: 18px 0 48px rgba(5, 36, 78, .22);
}

body.government-v47 .gh47-accessibility__header {
    min-height: 84px;
    align-items: center;
    padding: 15px 18px;
    border-bottom: 3px solid #e5283c;
    background: linear-gradient(135deg, #0759b9 0%, #0879d2 66%, #108b9d 100%);
}

body.government-v47 .gh47-accessibility__title {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 11px;
}

body.government-v47 .gh47-accessibility__title-icon {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .5);
    border-radius: 10px;
    background: rgba(255, 255, 255, .12);
}

body.government-v47 .gh47-accessibility__title-icon svg {
    width: 25px;
    height: 25px;
    fill: none;
    stroke: #fff;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

body.government-v47 .gh47-accessibility__header h2 {
    margin: 0;
    color: #fff;
    font-size: 1.16rem;
    font-weight: 850;
    line-height: 1.25;
}

body.government-v47 .gh47-accessibility__header .gh46-accessibility__header-actions {
    gap: 8px;
}

body.government-v47 .gh47-accessibility__header .gh46-accessibility__header-reset,
body.government-v47 .gh47-accessibility__header .gh46-accessibility__close {
    width: 42px;
    height: 42px;
    min-height: 42px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, .62);
    border-radius: 10px;
    background: rgba(0, 40, 92, .12);
}

body.government-v47 .gh47-accessibility__body {
    padding: 20px 20px 28px;
    background: #e9e9e9;
}

body.government-v47 .gh47-accessibility__intro {
    display: none;
}

body.government-v47 .gh47-tool-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

body.government-v47 .gh47-tool-card {
    appearance: none;
    position: relative;
    min-width: 0;
    min-height: 105px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 10px 8px 8px;
    overflow: hidden;
    border: 1.5px solid transparent;
    border-radius: 9px;
    background: #fff;
    color: #050a10;
    font: inherit;
    text-align: center;
    box-shadow: 0 1px 2px rgba(12, 50, 93, .025);
    transition: border-color .16s ease, background-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

body.government-v47 button.gh47-tool-card {
    cursor: pointer;
}

body.government-v47 button.gh47-tool-card:hover,
body.government-v47 button.gh47-tool-card:focus-visible {
    border-color: #207ff0;
    background: #fbfdff;
    box-shadow: 0 8px 20px rgba(11, 74, 143, .09);
    transform: translateY(-2px);
}

body.government-v47 button.gh47-tool-card[aria-pressed="true"] {
    border-color: #0877ed;
    background: #fff;
    box-shadow: inset 0 0 0 1px #0877ed, 0 7px 18px rgba(8, 92, 179, .1);
}

body.government-v47 button.gh47-tool-card:disabled {
    opacity: .52;
    cursor: not-allowed;
    transform: none;
}

body.government-v47 .gh47-tool-card__icon {
    min-width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    color: #252b33;
}

body.government-v47 .gh47-tool-card__icon svg {
    width: 41px;
    height: 41px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.05;
    stroke-linecap: round;
    stroke-linejoin: round;
}

body.government-v47 .gh47-tool-card__icon svg .is-fill {
    fill: currentColor;
    stroke: none;
}

body.government-v47 .gh47-tool-card__icon svg .is-soft-fill {
    fill: #ffb5bd;
    stroke: none;
}

body.government-v47 .gh47-tool-card > strong {
    max-width: 100%;
    overflow-wrap: anywhere;
    color: #050a10;
    font-size: .81rem;
    font-weight: 850;
    line-height: 1.22;
}

body.government-v47 .gh47-tool-card__info {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 16px;
    height: 16px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #dcecec;
    color: #397378;
    font-size: .58rem;
    font-weight: 900;
}

body.government-v47 .gh47-tool-card > .gh47-tool-card__status {
    position: absolute;
    top: 8px;
    right: 8px;
    max-width: calc(100% - 16px);
    overflow: hidden;
    padding: 2px 5px;
    border-radius: 999px;
    background: #eef5fd;
    color: #075fae;
    font-size: .52rem;
    font-weight: 850;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.government-v47 .gh47-text-size-icon {
    position: relative;
    font-family: Georgia, serif;
    font-size: 2rem;
    line-height: 1;
}

body.government-v47 .gh47-spacing-icon {
    position: relative;
    color: #20262d;
    font-size: 1.65rem;
    line-height: 1;
}

body.government-v47 .gh47-spacing-icon small {
    position: absolute;
    right: 0;
    bottom: -12px;
    left: 0;
    font-size: 1rem;
}

body.government-v47 .gh47-text-size-icon small {
    margin-left: 2px;
    font-size: 1.35rem;
}

body.government-v47 .gh47-font-icon,
body.government-v47 .gh47-dyslexia-icon {
    position: relative;
    color: #20262d;
    font-size: 1.65rem;
    line-height: 1;
}

body.government-v47 .gh47-saturation-icon {
    display: flex;
    align-items: center;
}

body.government-v47 .gh47-saturation-icon i {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    opacity: .92;
}

body.government-v47 .gh47-saturation-icon i:nth-child(1) { background: #ff4264; }
body.government-v47 .gh47-saturation-icon i:nth-child(2) { margin-left: -5px; background: #24c780; }
body.government-v47 .gh47-saturation-icon i:nth-child(3) { margin-left: -5px; background: #3e5bea; }

body.government-v47 .gh47-tool-card--levels::after {
    content: "";
    width: 100px;
    height: 5px;
    margin-top: 3px;
    border-radius: 999px;
    background: linear-gradient(to right, #cacccd 0 28%, transparent 28% 36%, #cacccd 36% 64%, transparent 64% 72%, #cacccd 72% 100%);
}

body.government-v47 .gh47-tool-card--levels[aria-pressed="true"]::after {
    background: linear-gradient(to right, #1681df 0 28%, transparent 28% 36%, #1681df 36% 64%, transparent 64% 72%, #1681df 72% 100%);
}

body.government-v47 .gh47-tool-card--levels-four::after {
    background: linear-gradient(to right, #cacccd 0 22%, transparent 22% 28%, #cacccd 28% 50%, transparent 50% 56%, #cacccd 56% 78%, transparent 78% 84%, #cacccd 84% 100%);
}

body.government-v47 .gh47-tool-card--levels-four[aria-pressed="true"]::after {
    background: linear-gradient(to right, #1681df 0 22%, transparent 22% 28%, #1681df 28% 50%, transparent 50% 56%, #1681df 56% 78%, transparent 78% 84%, #1681df 84% 100%);
}

body.government-v47 .gh47-tool-card--text-size { order: 1; }
body.government-v47 .gh47-tool-card--high-contrast { order: 2; }
body.government-v47 .gh47-tool-card--text-align { order: 3; }
body.government-v47 .gh47-tool-card--colour-filter { order: 4; }
body.government-v47 .gh47-tool-card--text-spacing { order: 5; }
body.government-v47 .gh47-tool-card--line-height { order: 6; }
body.government-v47 .gh47-tool-card--font-selection { order: 7; }
body.government-v47 .gh47-tool-card--saturation { order: 8; }
body.government-v47 .gh47-tool-card--dyslexia { order: 9; }
body.government-v47 .gh47-tool-card--cursor { order: 10; }
body.government-v47 .gh47-tool-card--hide-images { order: 11; }
body.government-v47 .gh47-tool-card--pause { order: 12; }

body.government-v47 .gh47-font-icon {
    padding: 0 4px 4px;
    border-bottom: 1px solid #20262d;
    font-family: Georgia, serif;
    font-size: 1.15rem;
}

body.government-v47 .gh47-dyslexia-icon {
    font-size: 2.1rem;
    letter-spacing: -.08em;
}

body.government-v47 .gh47-font-controls {
    display: grid;
    grid-template-columns: minmax(88px, 1fr) repeat(3, 48px);
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    padding: 8px;
    border: 1px solid #cbd9e8;
    border-radius: 9px;
    background: #fff;
}

body.government-v47 .gh47-font-controls > span {
    color: #173b66;
    font-size: .69rem;
    font-weight: 850;
}

body.government-v47 .gh47-font-controls button {
    min-height: 34px;
    padding: 0;
    border: 1px solid #cbd9e8;
    border-radius: 8px;
    background: #f7faff;
    color: #075cae;
    font: inherit;
    font-size: .72rem;
    font-weight: 900;
    cursor: pointer;
}

body.government-v47 .gh47-font-controls button:hover,
body.government-v47 .gh47-font-controls button:focus-visible {
    border-color: #0877ed;
    background: #edf6ff;
}

/* Advanced tools stay available without crowding the main tile grid. */
body.government-v47 .gh47-advanced-tools {
    display: none;
    margin-top: 12px;
    overflow: hidden;
    border: 1px solid #cbd7e4;
    border-radius: 10px;
    background: #fff;
}

body.government-v47 .gh47-advanced-tools > summary {
    list-style: none;
    min-height: 64px;
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 26px;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    color: #10365f;
    cursor: pointer;
}

body.government-v47 .gh47-advanced-tools > summary::-webkit-details-marker { display: none; }

body.government-v47 .gh47-advanced-tools > summary > span:nth-child(2) strong,
body.government-v47 .gh47-advanced-tools > summary > span:nth-child(2) small {
    display: block;
}

body.government-v47 .gh47-advanced-tools > summary > span:nth-child(2) strong {
    font-size: .82rem;
}

body.government-v47 .gh47-advanced-tools > summary > span:nth-child(2) small {
    margin-top: 2px;
    color: #71839a;
    font-size: .65rem;
}

body.government-v47 .gh47-advanced-tools__icon {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: #e8f3ff;
    color: #0766bd;
    font-weight: 900;
}

body.government-v47 .gh47-advanced-tools__chevron {
    font-size: 1.1rem;
    text-align: center;
    transition: transform .18s ease;
}

body.government-v47 .gh47-advanced-tools[open] .gh47-advanced-tools__chevron { transform: rotate(180deg); }

body.government-v47 .gh47-advanced-tools__body {
    padding: 12px;
    border-top: 1px solid #dce5ee;
    background: #f8fafc;
}

body.government-v47 .gh47-preset-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
}

body.government-v47 .gh47-preset-grid button {
    min-height: 68px;
    display: grid;
    place-items: center;
    gap: 4px;
    padding: 7px 4px;
    border: 1px solid #cbd9e8;
    border-radius: 9px;
    background: #fff;
    color: #163a65;
    font: inherit;
    cursor: pointer;
}

body.government-v47 .gh47-preset-grid button > span {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #e9f3ff;
    color: #0765bd;
    font-size: .7rem;
    font-weight: 900;
}

body.government-v47 .gh47-preset-grid button strong {
    font-size: .67rem;
    line-height: 1.2;
}

body.government-v47 .gh47-preset-grid button[aria-pressed="true"] {
    border-color: #0874d6;
    background: #edf6ff;
}

body.government-v47 .gh47-secondary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
    margin-top: 8px;
}

body.government-v47 .gh47-secondary-grid button {
    min-height: 54px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border: 1px solid #cbd9e8;
    border-radius: 9px;
    background: #fff;
    color: #173b66;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

body.government-v47 .gh47-secondary-grid button > span:first-child {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #eaf3fd;
    color: #0966bc;
    font-weight: 900;
}

body.government-v47 .gh47-secondary-grid strong,
body.government-v47 .gh47-secondary-grid small { display: block; }
body.government-v47 .gh47-secondary-grid strong { font-size: .69rem; }
body.government-v47 .gh47-secondary-grid small { margin-top: 2px; color: #71829a; font-size: .59rem; }
body.government-v47 .gh47-secondary-grid button[aria-pressed="true"] { border-color: #0874d6; background: #edf6ff; }

body.government-v47 .gh47-speech {
    margin-top: 9px;
    padding: 11px;
    border: 1px solid #cbd9e8;
    border-radius: 9px;
    background: #fff;
}

body.government-v47 .gh47-speech__heading {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 9px;
}

body.government-v47 .gh47-speech__heading > span {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #eaf3fd;
    color: #0966bc;
    font-weight: 900;
}

body.government-v47 .gh47-speech__heading strong,
body.government-v47 .gh47-speech__heading small { display: block; }
body.government-v47 .gh47-speech__heading strong { color: #12375f; font-size: .78rem; }
body.government-v47 .gh47-speech__heading small { margin-top: 2px; color: #70829a; font-size: .63rem; }

body.government-v47 .gh47-accessibility__footer {
    display: none;
}

/* Compact ENG / NEP selector */
body.government-v47 .gh47-language {
    z-index: 1300;
}

body.government-v47 .gh47-language .v10-language__button {
    min-height: 30px;
    gap: 5px;
    padding: 2px 4px;
    color: #18283b;
    font-size: .76rem;
    font-weight: 850;
}

body.government-v47 .gh47-language .gh47-language__current {
    min-width: 30px;
    color: inherit;
    font-size: .76rem;
    font-weight: 850;
    letter-spacing: .01em;
}

body.government-v47 .gh47-language .v10-language__chevron {
    margin: 0;
    color: #6f7d8f;
    font-size: .66rem;
}

body.government-v47 .gh47-language .v10-language__menu {
    top: calc(100% + 4px);
    right: 0;
    min-width: 78px;
    padding: 0;
    overflow: hidden;
    border: 1px solid #d8dee7;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(16, 42, 77, .13);
}

body.government-v47 .gh47-language .v10-language__menu::before { display: none; }

body.government-v47 .gh47-language .v10-language__menu a {
    min-height: 40px;
    display: flex;
    align-items: center;
    padding: 8px 16px;
    border-radius: 0;
    color: #202a36;
    font-size: .75rem;
    font-weight: 750;
}

body.government-v47 .gh47-language .v10-language__menu a + a { border-top: 1px solid #edf0f4; }
body.government-v47 .gh47-language .v10-language__menu a:hover,
body.government-v47 .gh47-language .v10-language__menu a:focus-visible { background: #f4f7fa; color: #075db4; }
body.government-v47 .gh47-language .v10-language__menu a.is-active { background: #eef5fc; color: #075db4; }

@media (max-width: 430px) {
    body.government-v47 .gh47-accessibility__panel { width: calc(100vw - 18px); }
    body.government-v47 .gh47-accessibility__body { padding: 11px; }
    body.government-v47 .gh47-tool-grid { gap: 8px; }
    body.government-v47 .gh47-tool-card { min-height: 108px; padding-inline: 6px; }
    body.government-v47 .gh47-tool-card__icon { height: 40px; }
    body.government-v47 .gh47-tool-card__icon svg { width: 39px; height: 39px; }
    body.government-v47 .gh47-tool-card > strong { font-size: .71rem; }
    body.government-v47 .gh47-accessibility__title-icon { display: none; }
    body.government-v47 .gh47-accessibility__header { padding-inline: 12px; }
    body.government-v47 .gh47-accessibility__header h2 { font-size: 1rem; }
    body.government-v47 .gh47-secondary-grid { grid-template-columns: 1fr; }
    body.government-v47 .gh47-language .v10-language__menu {
        position: absolute;
        top: calc(100% + 4px);
        right: 0;
        left: auto;
        min-width: 78px;
    }
}

@media (max-width: 390px) {
    body.government-v47 .gh47-tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
    body.government-v47 .gh47-tool-card { min-height: 112px; }
}

@media (max-width: 280px) {
    body.government-v47 .gh47-tool-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    body.government-v47 .gh47-tool-card,
    body.government-v47 .gh47-advanced-tools__chevron { transition: none !important; }
}
