/*
 *  Copyright 2020 wixette@gmail.com
 *
 *  Licensed under the Apache License, Version 2.0 (the "License");
 *  you may not use this file except in compliance with the License.
 *  You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 *  Unless required by applicable law or agreed to in writing, software
 *  distributed under the License is distributed on an "AS IS" BASIS,
 *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *  See the License for the specific language governing permissions and
 *  limitations under the License.
 */

body {
    background-color: #eee;
    border: 0;
    font-family: "PingFang SC", "Lantinghei SC", "Microsoft Yahei", "Hiragino Sans GB", "Segoe UI", Roboto, "Helvetica Neue", Arial,sans-serif;
    margin: 0;
    padding: 0;
}

div {
    border: 0;
    margin: 0;
    padding: 0;
}

img {
    border: 0;
    margin: 0;
    padding: 0;
}

#input-container {
    margin: 20px;
}

#input-container p {
    font-size: 14px;
    line-height: 18px;
}

#input-container input {
    background-color: #fcfcfc;
    border: #ccc solid 1px;
    font-size: 14px;
}

#input-text {
    background-color: #fcfcfc;
    border: #ccc solid 1px;
    font-size: 14px;
}

#option-container {
    text-align: center;
}

#button-container {
    text-align: center;
}

#paper-container {
    background-color: #fcfcfc;
    border: #ccc solid 1px;
    overflow: auto;
    padding: 30px;
}

.paper-canvas {
    background-color: #fff;
    border: #eee solid 1px;
    box-shadow: 1px 1px 1px #ccc;
    height: 1280px;
    margin: 20px;
    width: 960px;
}

@media screen and (min-width: 768px) {
    #desktop {
        display: flex;
        flex-direction: row;
    }

    #input-container {
        display: flex;
        flex-direction: column;
    }

    #button-container {
        display: flex;
        flex-direction: row;
    }

    #button-container > div {
        flex: auto;
    }

    #paper-container {
        display: flex;
        flex-direction: column;
        flex-grow: 1;
        margin: 20px 20px 20px 0;
    }
}

@media screen and (max-width: 767px) {
    #desktop {
        display: flex;
        flex-direction: column;
    }

    #input-container {
        align-items: center;
        display: flex;
        flex-direction: row;
    }

    #text-container {
        margin-right: 20px;
    }

    #button-container {
        display: flex;
        flex-direction: column;
        height: 90px;
        margin-top: 30px;
    }

    #button-container > div {
        flex: auto;
    }

    #paper-container {
        display: flex;
        flex-direction: column;
        flex-grow: 1;
        margin: 20px;
    }
}

@media print {
    #input-container {
        display: none;
    }

    #paper-container {
        border: 0;
        margin: 0;
        padding: 0;
    }

    .paper-canvas {
        border: 0;
        box-shadow: none;
        height: 250mm; /* A4 measures 210 × 297 millimeters */
        margin: 0;
        page-break-after: always;
        width: 185mm; /* A4 measures 210 × 297 millimeters */
    }
}
