:root {
    --font-size: 0.75rem;
    --font-size-big: 0.975rem;
    --font-line-size: 1.2rem;
    --menu-width: 3rem;
    --frame-padding: 3.5rem;
    --border-width: 1px;
    --small-button-width: 2rem;
    --decorative-width: 1rem;
    --decorative-scale: 1;

    --color-back: rgb(35, 39, 43);
    --color-objects: rgb(187, 187, 187);
    --color-mark: #70b1e6;
    --color-active: #cfc78e;
    --color-disabled: gray;
    --color-input: #406380;
    --color-button: rgb(0, 142, 255);
    --color-selection: aqua;
    --color-box: #2d3c48;
    --color-box-half: #2d3c4835;
    --color-removed: #994242;
    --color-checked: #e39f1c;
    --squeezed-size: 1;

    --plyr-color-main: var(--color-input);
    --plyr-video-control-color: var(--color-objects);
    --plyr-control-icon-size: 1.7rem;
    --plyr-font-size-base: var(--font-size);
    --plyr-control-spacing: 1rem;
}

.unsqueezed {
    display: none !important;
}

@media (width <= 1080px) {
    :root {
        --menu-width: 2.5rem;
        --frame-padding: 2.75rem;
        --decorative-width: 0.75rem;
        --decorative-scale: 0.75;
    }

    .optional {
        display: none;
    }
}

@media (width <= 600px) {
    :root {
        --menu-width: 2rem;
        --frame-padding: 2.3rem;
        --decorative-width: 0.5rem;
        --unsqueezed: auto;
        --squeezed-size: 0;
        --decorative-scale: 0.75;
        --font-size-big: 0.85rem;

        .squeezed {
            display: none !important;
        }
        .unsqueezed {
            display: initial !important;
        }
    }
}

@media (height <= 600px) {
    :root {

    }
}

@media (-webkit-min-device-pixel-ratio: 2.1), (min-device-pixel-ratio: 2.1) {
    :root {
        --border-width: 1px
    }
}

@media (pointer:coarse) {
    :root {
        body.fixedScale {
            touch-action: pan-x pan-y;
        }
    }
}

html {
    height: 100%;
    overscroll-behavior: none;
}
body {
    background: var(--color-back);
    color: var(--color-objects);
    font-family: Arimo,Tahoma,Helvetica,sans-serif;
    font-size: var(--font-size);
    padding: 0.6rem;
    box-sizing: border-box;
    height: 100%;
    margin: 0;

    -webkit-text-size-adjust: none;
    -moz-text-size-adjust: none;
    -ms-text-size-adjust: none;

    overscroll-behavior: none;
    touch-action: pan-down;
}

img {
    padding: 0;
    margin: 0;
}

h1 {
    margin-top: 0;
}

#title {
    font-size: var(--menu-width);
}

a {
    color: var(--color-mark);
}

.grid-container {
    align-content: center;
    display: grid;
    grid-column-gap: 12px;
    grid-row-gap: 12px;
    grid-template-columns: repeat(auto-fill, 200px);
    justify-items: center;
    margin-bottom: 24px;
}

.plate {
    width: min-content;
    min-height: 100px;
    max-width: 100%;
}
    .plate.inactive {
        opacity: 0.3;
    }
    .plate .buttons {
        position: absolute;
    }

.photo {
}
    .photo-info {
        overflow-x: hidden;
    }
    .photo-content {
        cursor: pointer;
        font-size: 0;
        text-align: center;
        border: var(--border-width) transparent solid;
        min-height: 100px;
     }

    .cover {
        object-fit: contain;
    }

.selected .photo-content {
    border-color: var(--color-selection) !important;
}
.last-active .photo-content {
    border-style: dashed;
    border-color: var(--color-active);
}

#img_show_full {
}
    .block-fit {
        box-sizing: border-box;
        width: 100%;
        min-height: 100%;
        display: grid;
        grid-template-columns: auto max-content auto;
    }
    .side_up_button {
        position: fixed;
        height: 25%;
        top: 0;
        width: var(--menu-width);
    }
    .side_button {
        position: fixed;
        height: 50%;
        top: 25%;
        width: var(--menu-width);
    }
    .left {
        left: 0
    }
    .right {
        right: 0
    }
    .slider {
        height: 100%;
        background-position: center center;
        background-size: var(--menu-width) var(--menu-width);
        background-repeat: no-repeat;
        cursor: pointer;
        filter: opacity(0.3);
    }
    .cross {
        height: 100%;
        background-position: center top;
        background-size: var(--menu-width) var(--menu-width);
        background-repeat: no-repeat;
        cursor: pointer;
        background-image: url(/graphic/close.svg);
        filter: opacity(0.3);
    }
        .cross:hover {
            filter: none;
        }
        .slider:hover {
            filter: none;
        }
        .left .slider {
            background-image: url(/graphic/go-left.svg);
        }
        .right .slider {
            background-image: url(/graphic/go-right.svg);
        }

    .thumb-hd {
    }

.info {
    padding-top: 1rem;
    padding-bottom: 1rem;
}
    .info span {
        color: var(--color-mark);
    }
    .more {
    }
        .more .key {
            cursor: pointer;
            color: var(--color-mark);
        }
        .more .chest {
            display: none;
        }
            .more .chest.opened {
                display: block;
            }

.popup {
    min-width: 100%;
    min-height: 100%;
    background-color: var(--color-back);
    position: absolute;
    left: 0;
    top: 0;
    display: grid;
}

.modal {
    position: fixed;
    left: 15%;
    width: 70%;
    max-height: 80%;
    overflow-y: auto;
    top: 10%;
    background-color: var(--color-back);
    box-sizing: border-box;
    padding: var(--menu-width);
    border: solid 1px var(--color-objects);
    z-index: 100;
}

@media (max-width: 70rem) {
    .modal {
        left: 5%;
        width: 90%;
    }
}

@media (max-height: 40rem) {
    .modal {
        top: 5%;
        max-height: 90%;
    }
}

/* Common properties */
.disabled {
    opacity: 0.1;
    cursor: default;
}
.inline-block {
    background-color: var(--color-back);
    box-sizing: border-box;
    padding: var(--menu-width);
    border: 1px solid #475159;
}
.hidden-completely {
    display: none; !important;
}
input[type=button].additionalButton {
    background-color: var(--color-input);
    border-color: transparent;
    color: var(--color-objects);
    box-sizing: border-box;
}

.login {
    grid-template-columns: auto 30rem auto;
    padding-top: 20%;
}

.centered {
    font-size: var(--font-size-big);
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    > div {
        flex: 1;
    }
    > .center {
        flex: 3;
        display: flex;
        flex-direction: column;
        max-width: 20rem;

        > div {
            flex: 1;
        }
    }
    .center .center {
        flex: 0;
    }
}
.center {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.actions {
    grid-template-columns: repeat(auto-fill, var(--menu-width));
    grid-template-rows: var(--menu-width);
    width: var(--menu-width);
}
    .icon,.bar {
        width: var(--menu-width);
        height: var(--menu-width);
        cursor: pointer;
        background-size: var(--menu-width) var(--menu-width);
    }
    .logout {
        cursor: pointer;
    }

    .sort_created.inactive {
        background-image: url(/graphic/sort-created-inactive.svg);
    }
    .sort_created.asc {
        background-image: url(/graphic/sort-created-asc.svg);
    }
    .sort_created.desc {
        background-image: url(/graphic/sort-created-desc.svg);
    }

    .selection {
        background-image: url(/graphic/selection.svg);
        text-align: center;
        line-height: var(--menu-width);
        cursor: default;
        opacity: 0.1;
    }
    .selection.non-empty {
        cursor: pointer;
        opacity: unset;
    }
        .selection span {
            color: black;
            background: var(--color-disabled);
            border-radius: 1rem;
            padding: 0.2rem;
            visibility: hidden;
        }
        .selection.non-empty span {
            background: var(--color-mark);
            visibility: visible;
        }
    .share.has-selection {
        background-image: url("/graphic/share-items.svg");
    }

.buttons-holder {
    position: relative;
    width: 100%;
}
.buttons {
    position: absolute;
    right: 0;
    width: auto;
    padding: 2px;
}
.plate .buttons div {
    display: none;
    float: right;
    filter: drop-shadow(0 0 10px #000)
}
.plate .buttons div:hover {
    display: none;
    float: right;
    filter: brightness(1.4) drop-shadow(0 0 10px #000)
}
.plate .buttons .set {
    display: block;
}
.plate:hover .buttons div {
    display: block;
}
    .buttons .icon {
        width: var(--small-button-width);
        height: var(--small-button-width);
        background-size: var(--small-button-width) var(--small-button-width);
    }
    .buttons .favorite {
        background-image: url("/graphic/favorite.svg");
    }
    .buttons .favorite.set {
        background-image: url("/graphic/favorite-set.svg");
    }
    .buttons .edit {
        background-image: url("/graphic/edit.svg");
    }
.subtitle {
    cursor: pointer;
    line-height: var(--font-line-size);
    padding-top: 0.2rem;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.subtitle:hover {
    color: var(--color-mark);
}
    .subtitle .tag-form {
        margin-right: 0;
        padding: 0rem 1rem;
        display: inline-block;
        text-align: center;
        max-width: 100%;
        box-sizing: border-box;
        white-space: normal;
    }
    .subtitle:hover .tag-form {
        background: transparent !important;
        border: solid 1px var(--color-mark);
    }
    .item-type {
        float: left;
        width: calc(var(--font-size)*1.5);
        height: calc(var(--font-size)*1.5);
        margin-right: 0.25rem;
        background-size: calc(var(--font-size)*1.5) calc(var(--font-size)*1.5);
    }
        .item-type.series {
            background-image: url(/graphic/series.svg);
        }
        .item-type.dir {
            background-image: url(/graphic/dir.svg);
        }
        .item-type.video {
            background-image: url(/graphic/video.svg);
        }
        .item-type.doc {
            background-image: url(/graphic/doc.svg);
        }
        .item-type.action-add {
            background-image: url(/graphic/edit.svg);
        }

.navigation {
}
    .navigation .separator {
        height: 0;
        margin: calc(var(--menu-width) / 3) 0;
        border-bottom: dotted 2px var(--color-disabled);
    }
    .navigation .icon {
        height: var(--menu-width);
        width: calc(100% - 0.3rem);
    }
    .navigation .icon:last-child {
        border-bottom-width: 0;
    }
    .navigation .fit {
        width: calc(100% - 0.3rem);
        margin-left: 0.3rem;
    }
    .navigation .icon.selected {
        border-left: solid 0.3rem var(--color-mark);
    }

.hidden {
    display: none !important;
}
div.invisible {
    visibility: hidden;
}

.fit {
    width: 100%;
    height: 100%;
}

.frame {
    padding-left: var(--frame-padding);
    padding-right: var(--frame-padding);
}
.frame.extendable {
    padding-right: calc(var(--squeezed-size) * var(--frame-padding));
}
.frame.extendableLeft {
    padding-left: calc(var(--squeezed-size) * var(--frame-padding));
}

.left-menu {
    position: fixed;
    width: var(--menu-width);
    height: calc(100% - 20px);
    display: grid;
    grid-template-rows: auto min-content;
}
.right-menu {
    right: 10px;
    position: fixed;
    width: var(--menu-width);
    height: calc(100% - 20px);
    display: grid;
    grid-template-rows: auto min-content;
}

input[type=button], input[type=submit], button  {
    background: var(--color-button);
    text-align: center;
    border: var(--border-width) solid var(--color-button);
    padding: 8px 40px;
    color: white;
    width: auto !important;
}

input, select, textarea {
    background-color: transparent;
    border: dashed thin var(--color-input);
    color: white;
    box-sizing: border-box;
    margin: 0;
}
input:focus, select:focus, textarea:focus {
    outline: none;
}
input:required, select:required {
    border: solid thin var(--color-input);
}
::placeholder {
    color: var(--color-disabled);
}
input[disabled] {
    background-color: var(--color-disabled);
    border-color: var(--color-disabled);
}
input::file-selector-button {
    text-align: center;
    background-color: var(--color-input);
    border: solid thin var(--color-input);
    padding: 8px 40px;
    color: white;
    width: auto !important;
    border-collapse: collapse;
}


form div span {
    font-size: calc(var(--font-size) * 1.3);
}
div input,select,textarea  {
    font-size: calc(var(--font-size) * 1.3);
}
input[type=range] {
    border-width: 0;
}
input[type=range]::-moz-range-track, input[type=range]::-webkit-slider-runnable-track {
    height: 0.7rem;
    box-shadow: 1px 1px 1px #000000;
    background: var(--color-input);
    border-radius: 5px;
}
input[type=range]::-moz-range-thumb, input[type=range]::-webkit-slider-thumb {
    border: 1px solid #000000;
    height: 1.2rem;
    width: 1.2rem;
    border-radius: 5px;
    background: var(--color-objects);
}
.form-grid {
    display: grid;
    grid-column-gap: 2rem;
    grid-row-gap: 0.7rem;
    grid-template-columns: 1fr 3fr;
    margin-bottom: 0.7rem;

    .form-grid span {
        font-size: var(--font-size);
    }
}
    .form-grid.extended {
        grid-template-columns: 1fr 2fr 1fr;
        align-items: center;
    }

@media (width <= 1080px) {
    .form-grid {
        grid-template-columns: 1fr;

        .form-grid {
            grid-template-columns: 1fr 3fr;
        }
    }
    .form-grid.extended {
        grid-template-columns: 2fr 1fr;
        grid-column-gap: 0.6rem;
    }
}
    .form-grid input,select  {
        width: 100%;
    }

    .range {
        display: grid;
        grid-template-columns: auto 5rem;
        grid-column-gap: 1rem;
    }
    .color input {
        width: 6rem;
    }

    .form-space {
        display: inline-block;
        width: 1rem;
    }

.for-user {
    display: none;
}

.inline-icon {
    float: right;
    width: var(--font-size);
    height: var(--font-size);
    margin-left: 0.7em;
}

.tags {

}
.tag-form {
    margin-right: 0.65rem;
    margin-bottom: 0.65rem;
    padding: 0.1rem 1rem;
    border: solid 1px transparent;
    border-radius: 0.25rem;
}
    .tags .partially {
        filter: opacity(0.6);
        border-width: 1px;
        border-style: dashed;
    }
    .tags > div {
        float: left;
    }

    .tags > div.inlined {
        padding-right: 0.3rem;
    }

.milestone {
    font-weight: bolder;
    display: grid;
    grid-template-rows: max-content max-content auto max-content;
    grid-template-columns: 1fr;
    text-align: left;
}
    .milestone .month {
        text-transform: uppercase;
        font-size: 4.5rem;
    }
        .milestone .jan::first-letter { color: #8fa4c1; }
        .milestone .feb::first-letter { color: #8fbac1; }
        .milestone .mar::first-letter { color: #babf9e; }
        .milestone .apr::first-letter { color: #b2c18f; }
        .milestone .may::first-letter { color: #a1c18f; }
        .milestone .jun::first-letter { color: #7ca778; }
        .milestone .jul::first-letter { color: #859f72; }
        .milestone .aug::first-letter { color: #a2b080; }
        .milestone .sep::first-letter { color: #bfc18f; }
        .milestone .oct::first-letter { color: #bd967b; }
        .milestone .nov::first-letter { color: #bda881; }
        .milestone .dec::first-letter { color: #9bb3c0; }
    .milestone .year {
        font-size: 2rem;
    }
    .milestone .follow {
        height: 2rem;
        width: 2rem;
        background-image: url("/graphic/follow.svg");
    }

.share-result {
    display: grid;
    grid-template-columns: max-content auto max-content;
    column-gap: 1rem;
    align-items: center;
}

.jconfirm-title {
    font-size: calc(var(--font-size)*2) !important;
    line-height: calc(var(--font-size)*2.2) !important;
    text-align: left;
}

.jconfirm-buttons button.btn {
    font-size: calc(var(--font-size)*1.8) !important;
}

.jconfirm-content {
    font-size: calc(var(--font-size)*1.4) !important;
    line-height: calc(var(--font-size)*1.6) !important;
    text-align: justify;
}

.plyr__control--pressed.plyr__control--overlaid svg {
    display: none !important;
}
.plyr__volume {
    max-width: 200px !important;
}
.plyr__video-wrapper {
    position: static !important;
    padding: 0 !important;
    height: auto !important;
}

.plyr__video-wrapper video {
    position: static !important;
    width: auto !important;
    height: auto !important;
    max-width: 100%;
}

.picker_sample, .picker_done {
    display: none;
}
.picker_wrapper {
    background-color: transparent;
    box-shadow: none;
}
.layout_default.picker_wrapper {
    padding: 0;
    width: 20rem;
}
.picker_sl, .picker_hue {
    box-shadow: none;
}

.clickable {
    cursor: pointer;
}
.disabled {
    cursor: default;
}

.chat {
    .note {
        font-size: var(--font-size);
        line-height: var(--font-size);
    }

    .chatInput {
        padding: 1rem 0 0 0;
    }

    textarea {
        width: 100%;
        height: 5rem;
    }

    /*.chatInput textarea:focus {*/
    /*    outline: none;*/
    /*}*/

    .chatItem {
        font-size: calc(var(--font-size) * 1.3 * var(--decorative-scale));
        margin: 1rem 0;
        padding-top: 1rem;

        .response {
            overflow-x: auto;
        }
    }

    .chatItem > p {
        margin: 0 0 1rem 0;
    }

    .chatItem.request {
        font-size: var(--font-size);
        color: var(--color-objects);
    }

    .chatItem.request::first-letter {
        color: var(--color-mark);
        font-weight: bold;
    }

    .chatItem.request::before {
        content: '#';
        position: absolute;
        margin-left: -0.6rem;
        color: var(--color-mark);
        font-weight: bold;
    }

    .chatItem img {
        max-width: 100%
    }

    .chatWait {
        height: 1rem;
        padding: 1rem 0;
    }

    .chatWait img {
        height: 100%
    }

    .submitType {
        text-align: center;
        padding: 8px 20px;
        color: white;
        width: auto !important;
        border: solid thin var(--color-button);
    }

    .fieldModel {
        margin-top: 0.2rem;
        float: right;
        max-width: 40%;
        text-align: right;

        select {
            margin-top: calc(var(--font-size) / 5);
        }
    }

    .advanced {
        font-size: var(--font-size);
        margin: 0.3rem 0 0 0;
        padding: 0.3rem;
        background-color: rgb(40, 52, 61);
        border: solid var(--border-width) #406380;

        .control {
            text-align: right;
            cursor: pointer;
            padding: 0.2rem;
        }

        .content {
            margin-top: 0.3rem;
        }
    }

    .advanced.collapsed {
        float: right;
        max-width: 40%;
        width: fit-content;

        .content {
            display: none;
        }
    }

    .actionPanel {
        padding: 1rem 0 0 0;
    }

    .options {
        padding: 0.3rem 0;

        .option {
            margin-bottom: 0.1rem;
            background: transparent;
            border: solid thin var(--color-mark);
        }

        .option.selected {
            background-color: var(--color-button);
            border-color: var(--color-button);
            color: white;
        }
    }

    .topItemPanel {
        line-height: var(--font-size);
        font-size: var(--font-size);
        color: var(--color-disabled);
        display: flex;
        justify-content: flex-end;
        gap: 1rem;

        .actions {
            white-space: nowrap;
            width: auto;
        }
    }

    .attachments {
        box-sizing: border-box;
        .attachmentsArea {
        }
    }

    .play.disabled {
        opacity: 1;
        color: var(--color-disabled);
    }
    .play.active {
        color: var(--color-active);
    }
}

/* Upload */

.uploadArea {
    display: flex;
    min-height: 2rem;
    border: dashed thin var(--color-input);
    margin: 0.5rem 0;
    padding: 1rem;
    flex-wrap: wrap;

    .item {
        margin: 0 1rem 0 0;
    }
    div > img {
        box-sizing: border-box;
        margin: auto;
        width: 5rem;
        height: 5rem;
        object-fit: contain;
    }

    .message {
        height: 30%;
        margin: auto;
    }
}

.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    margin-bottom: 1rem;
    box-shadow: 0 0.5rem 0.5rem -0.5rem #0005;

    :first-child {
        flex: 0 1 auto !important;
    }

    .tab {
        padding: calc(0.75 * var(--decorative-width));
        flex: 1 1 auto;
        min-width: calc(7 * var(--decorative-width));
        max-width: calc(10 * var(--decorative-width));
        box-sizing: border-box;
        line-height: calc(var(--font-size) * (1.3 + 0.3 * var(--decorative-width)));
        font-size: calc(var(--font-size) * 1.3);
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .tab .remove {
        display: none;
        z-index: 2;
        position: relative;
    }

    .tab.selected {
        background-color: var(--color-input);
    }

    .tab.selected .remove {
        display: inherit;
    }
}

.empty {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    width: 100%;

    div {
        font-size: var(--font-size);
        color: var(--color-disabled);
        text-align: center;
    }
}

.iconButton {
    background-position: center center;
    background-repeat: no-repeat;
    background-size: auto 100%;
    height: 100%;
    aspect-ratio: 1 / 1;
}

#animation-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 9999;
}
.animation-effect {
    position: absolute;
    transform: translate(-50%, -50%) scale(0.5);
    opacity: 1;
    animation: growFade 0.6s ease-out forwards;
}
@keyframes growFade {
    0% {
        transform: translate(-50%, -50%) scale(0.5);
        opacity: 0.8;
    }
    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}