.reader {
    display: flex;
    flex-direction: column;
    align-content: space-between;
    justify-content: space-between;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    font-family: 'Open Sans', sans-serif;
    background: #FFFFFF;
    color: #000000;
}

.reader .header,
.reader .footer {
    flex: 0 0 auto;
    display: flex;
    flex-direction: row;
    align-content: space-between;
    justify-content: space-between;
    height: 30px;
    line-height: 30px;
    font-size: 14px;
}

.reader .header .material-icons,
.reader .footer .material-icons {
    display: inline-block;
    font-size: 20px;
    line-height: 30px;
    width: 30px;
    text-align: center;
}

@media only screen and (max-width: 500px) {
    .nomobile {
        display: none !important;
    }
}

@media only screen and (min-height: 500px) and (min-width: 500px) {
    .reader .header,
    .reader .footer {
        height: 50px;
        line-height: 50px;
    }
    .reader .header .material-icons,
    .reader .footer .material-icons {
        line-height: 50px;
        width: 50px;
    }
}

.reader .header .left,
.reader .header .right,
.reader .footer .left,
.reader .footer .right {
    flex: 0 0 auto;
}

.reader .header .center,
.reader .footer .center {
    flex: 1;
    text-align: center;
}

.reader .header .item,
.reader .footer .item,
.reader .header .item:link,
.reader .footer .item:link,
.reader .header .item:visited,
.reader .footer .item:visited {
    display: inline-block;
    color: inherit;
    opacity: 0.65;
    text-decoration: none;
}

.reader .header .item:link,
.reader .footer .item:link {
    cursor: pointer;
}

.reader .header .item:hover,
.reader .footer .item:hover {
    opacity: 1.0;
}

.reader .header .item:active,
.reader .footer .item:active {
    transform: scale(1.02);
}

.reader .main {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-content: flex-start;
    justify-content: flex-start;
}

.reader .main .content {
    flex: 1;
    display: flex;
}

.reader .main .content :first-child {
    flex: 1;
}

.reader .main .content .welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.reader .main .content .welcome .welcome-inner {
    flex: 0 0 auto;
    padding-bottom: 200px;
}

.reader .main .content .welcome .welcome-inner .title {
    font-size: 40px;
    font-weight: 300;
    display: block;
    padding: 20px;
}

.reader .main .content .welcome .welcome-inner .menu {
    display: block;
    text-align: center;
}

.reader .main .content .welcome .welcome-inner .menu .big-item,
.reader .main .content .welcome .welcome-inner .menu .big-item:link,
.reader .main .content .welcome .welcome-inner .menu .big-item:visited {
    display: inline-block;
    width: 150px;
    max-width: 100%;
    font-size: 20px;
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    margin: auto;
    color: inherit;
    text-decoration: none;
    margin: 20px;
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.reader .main .content .welcome .welcome-inner .menu .big-item:hover,
.reader .main .content .welcome .welcome-inner .menu .big-item:active {
    background: rgba(0, 0, 0, 0.1);
}

.reader .main .content .welcome .welcome-inner .menu .big-item:active {
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-bottom: 3px solid rgba(0, 0, 0, 0.2);
}

.reader .main .sidebar {
    flex: 0 0 auto;
    max-width: 250px;
    overflow-y: auto;
    border-right: 1px solid rgba(0,0,0,0.1);
    font-size: 14px;
    min-width: 200px;
}

.reader .main .sidebar.hidden {
    display: none;
}

.reader .main .sidebar.visible {
    display: block;
}

.reader .main .sidebar.hidden {
    display: none;
}

.reader .main .sidebar.visible {
    display: block;
}

.reader .main .sidebar.overlay {
    position: fixed;
    top: 30px;
    left: 0;
    bottom: 30px;
    background: inherit;
    z-index: 1000000;
    transition: transform 0.2s ease-in-out;
}

.reader .main .sidebar.overlay.hidden {
    display: block !important;
    transform: translateX(-100%);
}

.reader .main .sidebar.overlay.visible {
    display: block !important;
    transform: none;
}

@media only screen and (min-height: 500px) and (min-width: 500px) {
    .reader .main .sidebar.overlay {
        top: 50px;
        bottom: 50px;
    }
}

.reader .main .sidebar .sidebar-inner {
    display: block;
    display: flex;
    height: 100%;
    flex-direction: column;
}

.reader .main .sidebar .sidebar-inner .sidebar-contents {
    flex: 1;
    height: 100%;
    overflow-y: auto;
}

.reader .main .sidebar .sidebar-header {
    display: block;
    padding: 5px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    margin-bottom: 5px;
    font-size: 130%;
    flex: 0 0 auto;
}

.reader .main .sidebar .sidebar-header .x {
    display: block;
    float: right;
    font-size: 100%;
    background: rgba(0, 0, 0, 0.001);
    color: inherit;
}

.reader .main .sidebar .sidebar-inner {
    display: none;
}

.reader .main .sidebar .toc-sidebar .toc {
    display: block;
}

.reader .main .sidebar .toc-sidebar .toc .toc-entry,
.reader .main .sidebar .toc-sidebar .toc .toc-entry:link,
.reader .main .sidebar .toc-sidebar .toc .toc-entry:visited {
    display: block;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: inherit;
    text-decoration: none;
    overflow: hidden;
    padding: 7px 3px;
    margin-right: 3px;
}

.reader .main .sidebar .toc-sidebar .toc .toc-entry:hover {
    background: rgba(0, 0, 0, 0.1);
}

.reader .main .sidebar .book-info {
    display: block;
    margin: 5px;
}

.reader .main .sidebar .book-info .cover {
    display: block;
    max-width: 90px;
    margin: 10px auto;
}

.reader .main .sidebar .book-info .cover img {
    width: 100%;
}

.reader .main .sidebar .book-info .meta {
    display: block;
    text-align: center;
}

.reader .main .sidebar .book-info .meta .book-title {
    display: block;
    text-align: center;
    font-size: 125%;
}

.reader .main .sidebar .progress-info {
    display: block;
    margin: 5px auto;
    max-width: 70%;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    text-align: center;
}

.reader .main .sidebar .progress-info>div {
    display: block;
    margin: 3px auto;
}

.reader .main .sidebar .search-sidebar .search-bar {
    display: flex;
}

.reader .main .sidebar .search-sidebar .search-bar .search-box,
.reader .main .sidebar .search-sidebar .search-bar button {
    border-radius: 0 !important;
    padding: 3px !important;
    border-color: rgba(0,0,0,0.3);
    outline: 0;
}

.reader .main .sidebar .search-sidebar .search-bar .search-box {
    width: auto;
    flex: 1;
    cursor: text;
}
.reader .main .sidebar .search-sidebar .search-bar button {
    flex: 0 0 30px;
}

.reader .main .sidebar .search-sidebar .search-results {
    display: block;
}

.reader .main .sidebar .search-sidebar .search-results a.result,
.reader .main .sidebar .search-sidebar .search-results a.result:link,
.reader .main .sidebar .search-sidebar .search-results a.result:visited {
    display: block;
    text-decoration: none;
    color: inherit;
    padding: 14px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    font-size: 85%;
}

.reader .main .sidebar .search-sidebar .search-results a.result:hover {
    background: rgba(0,0,0,0.05);
}

.reader .main .sidebar .search-sidebar .search-results a.result:active {
    background: rgba(0,0,0,0.10);
}

body.dark .reader .main .sidebar .search-sidebar .search-results a.result,
body.dark .reader .main .sidebar .search-sidebar .search-results a.result:link,
body.dark .reader .main .sidebar .search-sidebar .search-results a.result:visited {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

body.dark .reader .main .sidebar .search-sidebar .search-results a.result:hover {
    background: rgba(255,255,255,0.05);
}

body.dark .reader .main .sidebar .search-sidebar .search-results a.result:active {
    background: rgba(255,255,255,0.10);
}

.reader .main .sidebar .control {
    display: flex;
    margin: 5px 2px;
}

.reader .main .sidebar .control .label {
    flex: 1;
    text-align: left;
    font-size: 14px;
}

.reader .main .sidebar .control select,
.reader .main .sidebar .control input,
.reader .main .sidebar .control button {
    flex: 1;
}

select,
button,
input[type="text"] {
    background: transparent;
    width: 130px;
    padding: 5px;
    font-size: 16px;
    border: 1px solid rgba(0,0,0,0.5);
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.8);
    border-radius: 5px;
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    user-select: text !important;
}

select {
    padding: 5px 35px 5px 5px;
}

select:hover,
button:hover,
input[type="text"]:hover {
    background: rgba(0,0,0,0.45);
    cursor: pointer;
}

body.light select,
body.light button ,
body.light input[type="text"]{
    background: rgba(255,255,255,0.3);
    color: rgba(0,0,0,0.8);
}

body.light select:hover,
body.light button:hover,
body.light input[type="text"]:hover {
    background: rgba(255,255,255,0.45);
}

select::-ms-expand { 
    display: none; /* remove default arrow in IE 10 and 11 */
}

.reader .main .sidebar div.visible {
    display: block;
    display: flex;
}

.reader * {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.reader .hidden {
    display: none !important;
}

.error.banner {
    display: none;
    position: fixed;
    z-index: 1000000000;
    top: 0;
    left: 0;
    right: 0;
    color: #FFFFFF;
    background: #a94442;
    padding: 20px;
    font-family: 'Open Sans', 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
}

html.no-flex .error.banner.incompatible-browser {
    display: block;
    z-index: 1000000005;
}

html.load-error .error.banner.load-error {
    display: block;
    z-index: 1000000004;
}

::-webkit-scrollbar-track {
	background-color: transparent;
}

::-webkit-scrollbar {
	width: 6px;
    background-color: rgba(0,0,0,0.07);
}

::-webkit-scrollbar:hover {
    background-color: rgba(0,0,0,0.1);
}

::-webkit-scrollbar-thumb {
    background-color: rgba(0,0,0,0.3);
}

::-webkit-scrollbar-thumb:hover{
    background-color: rgba(0,0,0,0.4);
}
