:root {
    --vmh-panel-color: #EFF1F5;
    --vmh-reading-mask-size: 40px;
}

#vmh-accessibility-button {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--vmh-button-background-color);
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 2000;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    -webkit-animation: heartbeat 5s ease-in-out infinite both;
    animation: heartbeat 2s ease-in-out infinite both;
}

#vmh-accessibility-button.vmh-button-position-bottom-right {
    top: auto;
    right: 20px;
    bottom: 20px;
    left: auto;
}

#vmh-accessibility-button.vmh-button-position-bottom-left {
    top: auto;
    right: auto;
    bottom: 20px;
    left: 20px;
}

#vmh-accessibility-button.vmh-button-position-top-right {
    top: 20px;
    right: 20px;
    bottom: auto;
    left: auto;
}

#vmh-accessibility-button.vmh-button-position-top-left {
    top: 20px;
    right: auto;
    bottom: auto;
    left: 20px;
}

#vmh-accessibility-button.vmh-effects-indicator-border #vmh-accessibility-button-checkmark{
    opacity: 0;
}

#vmh-accessibility-button.vmh-effects-indicator-check #vmh-accessibility-button-border{
    opacity: 0;
}

#vmh-accessibility-button > img{
    width: calc(100% - 20px);
    height: calc(100% - 20px);
    transition: all 0.2s ease-in-out;
    opacity: 1 !important;
}

#vmh-accessibility-button:active {
    opacity: 0.75;
}

#vmh-accessibility-button-border {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    position: absolute;
    top: 0;
    left: 0;
    visibility: hidden;
}

#vmh-accessibility-button-border:after{
    content: '';
    position: absolute;
    top: -6px;
    left: -6px;
    right: -6px;
    bottom: -6px;
    border-color: var(--vmh-active-notification-color);
    border-width: 3px;
    border-radius: 35px;
    border-style: solid;
}

#vmh-accessibility-button-checkmark {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--vmh-active-notification-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    opacity: 1;
}

#vmh-accessibility-button-checkmark img {
    width: 10px;
    height: 10px;
}

@-webkit-keyframes heartbeat {
    from {
        -webkit-transform: scale(1);
        transform: scale(1);
        -webkit-transform-origin: center center;
        transform-origin: center center;
        -webkit-animation-timing-function: ease-out;
        animation-timing-function: ease-out;
    }
    10% {
        -webkit-transform: scale(0.91);
        transform: scale(0.91);
        -webkit-animation-timing-function: ease-in;
        animation-timing-function: ease-in;
    }
    17% {
        -webkit-transform: scale(0.98);
        transform: scale(0.98);
        -webkit-animation-timing-function: ease-out;
        animation-timing-function: ease-out;
    }
    33% {
        -webkit-transform: scale(0.87);
        transform: scale(0.87);
        -webkit-animation-timing-function: ease-in;
        animation-timing-function: ease-in;
    }
    45% {
        -webkit-transform: scale(1);
        transform: scale(1);
        -webkit-animation-timing-function: ease-out;
        animation-timing-function: ease-out;
    }
}
@keyframes heartbeat {
    from {
        -webkit-transform: scale(1);
        transform: scale(1);
        -webkit-transform-origin: center center;
        transform-origin: center center;
        -webkit-animation-timing-function: ease-out;
        animation-timing-function: ease-out;
    }
    10% {
        -webkit-transform: scale(0.91);
        transform: scale(0.91);
        -webkit-animation-timing-function: ease-in;
        animation-timing-function: ease-in;
    }
    17% {
        -webkit-transform: scale(0.98);
        transform: scale(0.98);
        -webkit-animation-timing-function: ease-out;
        animation-timing-function: ease-out;
    }
    33% {
        -webkit-transform: scale(0.87);
        transform: scale(0.87);
        -webkit-animation-timing-function: ease-in;
        animation-timing-function: ease-in;
    }
    45% {
        -webkit-transform: scale(1);
        transform: scale(1);
        -webkit-animation-timing-function: ease-out;
        animation-timing-function: ease-out;
    }
}

#vmh-accessibility-panel {
    height: 0;
    width: 0;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 999999;
    font-family: Helvetica, sans-serif;
}

#vmh-accessibility-panel * {
    user-select: none;
    font-family: Helvetica, sans-serif;
    word-spacing: 0;
    letter-spacing: 0;
    color: #666;
}

#vmh-accessibility-background {
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
}

#vmh-accessibility-content-container {
    width: 0;
    height: 100%;
    position: fixed;
    right: 0;
    top: 0;
    bottom: 0;
    transition: width 0.2s ease-in-out;
    overflow: hidden;
    background-color: var(--vmh-panel-color);
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

#vmh-accessibility-content-container.vmh-panel-position-right{
    right: 0;
    left: auto;
}

#vmh-accessibility-content-container.vmh-panel-position-left{
    right: auto;
    left: 0;
}

#vmh-accessibility-content-container.vmh-accessibility-content-container-opened {
    width: 500px;
}

#vmh-accessibility-content {
    width: 100%;
    height: 100%;
    padding: 15px;
    box-sizing: border-box;
    display: grid;
    grid-template-rows: min-content 1fr;
    gap: 15px;
}

#vmh-accessibility-content-header {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

#vmh-accessibility-content-header h5{
    font-weight: bold;
    padding: 0;
}

#vmh-accessibility-close-button {
    width: 24px;
    height: 24px;
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border: 0;
    outline: 0;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

#vmh-accessibility-close-button:active {
    opacity: 0.75;
}

#vmh-accessibility-close-button img {
    width: 12px;
    height: 12px;
}

#vmh-accessibility-content-body {
    width: 100%;
    height: 100%;
    background-color: white;
    overflow: hidden;
    padding: 15px;
    box-sizing: border-box;
    border-radius: 10px;
    overflow-y: scroll;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#vmh-accessibility-profiles-container {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.vmh-accessibility-profile-container {
    width: 100%;
    padding: 10px;
    box-sizing: border-box;
    border-radius: 10px;
    cursor: pointer;
    background-color: var(--vmh-panel-color);
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 10px;
    align-items: center;
    transition: all 0.2s ease;
}

.vmh-accessibility-profile-container:hover {
    outline: 4px solid var(--vmh-active-opacity-color);
}

.vmh-accessibility-profile-container.vmh-active {
    outline: 4px solid var(--vmh-active-opacity-color);
}

.vmh-accessibility-profile-image-container{
    width: 30px;
    height: 30px;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.vmh-accessibility-profile-image-container img{
    width: 14px;
    height: 14px;
}

.vmh-accessibility-profile-label {
    font-size: 14px;
    font-weight: bold;
    line-height: 1em;
    text-align: start;
}

.vmh-accessibility-cards-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.vmh-accessibility-card {
    width: 100%;
    height: 125px;
    background-color: var(--vmh-panel-color);
    border-radius: 10px;
    display: grid;
    grid-template-rows: 1fr 10px;
    padding: 10px;
    box-sizing: border-box;
    cursor: pointer;
    transition: all 0.2s ease;
}

.vmh-accessibility-card:hover{
    outline: 4px solid var(--vmh-active-opacity-color);
}

.vmh-accessibility-card.vmh-active {
    outline: 4px solid var(--vmh-active-opacity-color);
}

.vmh-accessibility-card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
}

.vmh-accessibility-card-icon {
    width: 36px;
    height: 36px;
    opacity: 0.5 !important;
}

.vmh-accessibility-card.vmh-active  .vmh-accessibility-card-icon {
    opacity: 1 !important;
}

.vmh-accessibility-card-label {
    font-weight: bold;
    font-size: 14px;
    text-align: center;
    line-height: 1em;
}

.vmh-accessibility-card.vmh-active .vmh-accessibility-card-label {
    color: var(--vmh-active-color);
}

.vmh-accessibility-card-footer {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 5px;
}

.vmh-accessibility-card-indicator {
    width: 6px;
    height: 6px;
    border-radius: 3px;
    background-color: var(--vmh-active-opacity-color);
}

.vmh-card-indicator-active {
    background-color: var(--vmh-active-color);
    width: 10px;
}

#vmh-reading-mask-overlay {
    display: none;
}

#vmh-reading-mask-overlay::before {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1000000;
    pointer-events: none;
    border-color: rgba(0, 0, 0, 0.5);
    border-style: solid;
    border-width: calc(var(--vmh-cursor-y-pos) - var(--vmh-reading-mask-size)) 0 calc(100vh - var(--vmh-cursor-y-pos) - var(--vmh-reading-mask-size)) 0;
    content: '';
}

#vmh-big-cursor {
    display: none;
    width: auto;
    height: 50px;
    position: fixed;
    pointer-events: none;
    z-index: 1000001;
}

#vmh-big-cursor img {
    width: 100%;
    height: 100%;
}

#vmh-accessibility-reading-guide-arrow {
    display: none;
    position: fixed;
    pointer-events: none;
    z-index: 1000001;
    transform: translate(-14px, -45px);
}

#vmh-accessibility-reading-guide-arrow::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 14px solid transparent;
    border-right: 14px solid transparent;
    border-bottom: 14px solid black;
}

#vmh-accessibility-reading-guide-bar {
    display: none;
    position: fixed;
    pointer-events: none;
    z-index: 1000001;
    width: 400px;
    height: 6px;
    background-color: black;
    transform: translate(-50%, -12px);
    border-radius: 3px;
}

.vmh-accessibility-long-button {
    width: 100%;
    height: auto;
    padding: 15px 50px;
    background-color: var(--vmh-active-color);
    color: white !important;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    position: relative;
    font-size: 14px;
    margin-top: 15px;
    font-weight: bold;
}

.vmh-accessibility-long-button:active {
    opacity: 0.75;
}

.vmh-accessibility-long-button img {
    width: 20px;
    height: 20px;
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    filter: invert(100%) sepia(1%) saturate(7500%) hue-rotate(256deg) brightness(104%) contrast(101%);
}

#vmh-accessibility-voice-panel {
    display: none;
    width: 100%;
    height: auto;
    padding: 15px 15px 15px 50px;
    background-color: var(--vmh-panel-color);
    border-radius: 10px;
    border: none;
    position: relative;
    margin-top: 15px;
    font-size: 14px;
}

#vmh-accessibility-voice-panel img {
    width: 20px;
    height: 20px;
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
}

#vmh-accessibility-voice-chooser-container {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

#vmh-accessibility-voice-chooser-container h5 {
    font-size: 12px;
    line-height: 14px;
    text-transform: uppercase;
    font-weight: bold;
    padding: 0;
    margin-left: 2px;
}

#vmh-accessibility-voice-selector {
    width: 100%;
    background-color: transparent;
    border: none;
    padding: 0;
    font-size: 16px;
    cursor: pointer;
}

@media screen and (max-width: 600px) {
    #vmh-accessibility-content-container.vmh-accessibility-content-container-opened {
        width: 100%;
    }

    .vmh-accessibility-cards-container {
        grid-template-columns: repeat(2, 1fr);
    }
}