/* toto.css - Site styling */

/*** Global font selection and page layout ***/

.stocking-background {
    background-image: url(/resource/christmas-stocking.svg);
    background-size: 64px;
    background-position-x: -20px;
    background-position-y: -20px;
    background-blend-mode: darken;
}

@media only screen and (min-width : 640px) {
    dialog {
        width: auto;
        max-width: 60%;
    }
}

dialog form {
    padding: 0px;
}


dialog .modal-controls .length-indicator {
    flex: 1;
}

dialog p {
    padding-bottom: 12px;
}


.contents {
    flex: 1;

    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    padding: 0px 8px 0px 8px;

    display: flex;
    flex-direction: column;
}

@media only screen and (max-width : 640px) {
    .contents {
        margin-bottom: 30px;
    }
}

.contents::-webkit-scrollbar {
    display: none;
}


.toolbar {
    margin: 6px 0px 6px 0px;
    padding: 6px;

    right: 0px;

    text-align: center;

    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
}

.toolbar A {
    display: inline-flex;
    padding-right: 10px;
    min-height: 40px;
    align-items: center;
    border: 1px solid var(--accent-color);
    color: var(--text-color);
    background-color: var(--main-page-color);
    padding: 6px;
    margin: 4px;
}


/*** Toplevel list styling ***/

.toplevel-list {
    width: 100%;
    box-sizing: border-box;

    flex-wrap: wrap;
    display: flex;
}

.toplevel-list .list-view-section:not(:first-child) {
    border-top: 1px solid #f0f0f0;
    padding-top: 16px;
}

.toplevel-list h2 {
    margin: 0px;
    padding: 0px;
    padding-left: 12px;

    font-size: 14px;
}

.toplevel-list .list-view-section h2 .other-item-count {
    font-weight: normal;
    font-style: italic;
}

.toplevel-list h2:not(:first-child) {
    padding-top: 18px;
}

.toplevel-list h2 A {
    color: black;
}

@media only screen and (min-width : 640px) {
    .toplevel-list {
        padding-left: 0px;
        padding-right: 0px;
    }
}

.order-drop-target.drop-hover {
    background: #d0d0d0;
}

/* Pill common component */


.stocking-editor-header {
    display: flex;
    flex-direction: column;
}

.stocking-editor-header h2 {
    margin: 0px;
}

.stocking-editor-header{
    flex: 1;
    margin-top: 16px;
    margin-bottom: 16px;
}

.header-row {
    display: flex;
    flex: 1;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

.header-row h2 a {
    color: var(--text-color);
}

.header-row h2 a .fa {
    margin-right: 4px;
}

.stocking-editor-header .header-row .name-info {
    margin-top: 8px;
}

.stocking-editor-header .header-row .name-info label {
    font-weight: bold;
    margin-right: 4px;
}

.editing .right {
    display: none;
}

.deleted-stocking-warning {
    flex: 1;
    text-align: center;

    margin: 4px;
    padding: 8px;

    background-color: var(--deleted-color);
}

.list-tile {
    display: flex;
    flex-direction: row;
    align-items: center;

    border: 1px solid var(--accent-color);
    width: 160px;
    height: 120px;

    white-space: nowrap;

    padding: 0px;

    margin: 0px 15px 15px 0px;
    box-shadow: var(--default-shadow);

    display: inline-flex;
    flex-direction: column;
    white-space: pre-wrap;

    background-color: var(--main-page-color);
}

.list-tile.deleted {
    background-color: #e0e0e0;
    border-color: var(--shadow-color);
}

.list-tile.control-tile {
    border: 1px dashed var(--accent-color);
    box-shadow: none;
    background-color: white;
}

.list-tile.control-tile A {
    background-color: transparent;
    color: var(--accent-color);
    font-size: 20px;
    font-weight: bold;
    text-align: center;
}

@media only screen and (min-width : 640px) {
    .item-row {
        padding-bottom: 4px;
    }
}

.list-tile .tile-contents {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-around;

    color: var(--main-page-text-color);
    margin: 1px;
    padding: 6px;

    box-sizing: border-box;
    width: 100%;
}

.list-tile .tile-contents label {
    font-weight: bold;
}

.list-tile .tile-contents h3 {
    text-align: center;
    margin: 2px;
}

.list-tile .tile-contents A {
    color: var(--main-page-color);
}

.list-tile .tile-contents:hover {
    background: #e0e0e0;
}

.list-tile .tile-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;

    padding: 6px 2px 2px 2px;

    box-sizing: border-box;
    width: 100%;
}

.list-tile .drag-handle {
    width: 25px;
    min-width: 25px;
}

@media only screen and (min-width : 640px) {
    .list-tile .drag-handle {
        padding: 3px 6px 3px 3px;
        font-size: inherit;
    }
}


.item-description-editor {
    display: flex;
    flex-direction: row;
}

.item-description-editor textarea {
    flex: 1;
}

.item-description-editor .item-preview {
    width: 50%;
    flex: 1;
    margin: 2px;
    padding: 2px;

    overflow-x: hidden;
}

.item-description-editor .item-preview img {
    max-width: 80%;
    display: block;
    margin: auto;
}

@media only screen and (max-device-width : 640px) {
    .item-description-editor .item-preview {
        display: none;
    }
}

.item-description-editor .item-preview p:first-child {
    margin-top: 0px;
}

/*** List Configuration Controls ***/

.stocking-item .description {
    padding: 20px;
    border: 1px solid gren
}

.stocking-item .controls .nav-link {
    width: 200px;
    display: inline-block;
    padding: 20px;
}

.stocking-item .gift-block {
    display: flex;
    flex-direction: column;

    margin: 20px 60px 20px 60px;
    background-color: white;
    height: 70vh;
    color: var(--main-page-text-color);

    border: 8px solid var(--second-highlight-color);

    box-shadow: 3px 2px 2px var(--shadow-color);
}

.stocking-item .gift-block img {
    max-width: 80%;
    display: block;
    margin: auto;
}

.config-panel .scroll-column {
    max-height: 40vh;
}

.stocking-item .stocking-names {
    display: flex;
    flex-direction: row;
}

.stocking-item .stocking-names label {
    font-weight: bold;
    margin-right: 4px;
}

.stocking-item .stocking-names {
    justify-content: center;
    font-size: 16px;
}

.stocking-item .stocking-names .name-info:not(:first-child) {
    margin-left: 20px;
}

.gift-block A {
    color: var(--main-page-text-color);
}

@media only screen and (max-device-width : 640px) {
    .stocking-item .gift-block {
        margin: 20px 20px 20px 20px;
    }
}

.stocking-item .gift-block .details {
    display: flex;
    flex-direction: column;
    flex: 1;

    height: 60vh;
    max-height: 60vh;

    border: 1px solid purple;
    overflow: auto;
    word-break: break-word;
}

.stocking-item .gift-block .details A {
    color: blue;
}

.stocking-item .gift-block .details A:visited {
    color: purple;
}

.stocking-item .gift-block .details.hidden {
    font-size: 120px;

    justify-content: center;
    align-items: center;
}

.stocking-item .gift-block .details.hidden img {
    max-width: 30vw;
}

.stocking-item .gift-block .details .description {
    flex: 1;
    padding: 20px;
}

.stocking-item .gift-block .details h2 {
    text-align: center;
}

.stocking-item .controls {
    flex: 0;
    display: flex;
    justify-content: space-evenly;
    color: var(--main-page-color);

    border-top: 4px solid var(--second-highlight-color);
}

.stocking-item .controls .nav-link {
    width: 200px;
    display: inline-block;
    padding: 20px;
    text-align: center;
    color: var(--text-color);
}

.stocking-item h1 {
    text-align: center;
}

.list-heading {
    padding: 12px;
    width: 100%;
    background: white;
}

.list-heading h1 {
    text-align: center;
    margin: 0px;
    width: 100%;
    padding-bottom: 20px;
}
