/* roboto-300 - latin */
@font-face {
    font-display: swap;
    font-family: 'Roboto';
    font-style: normal;
    font-weight: 300;
    src: url('../fonts/roboto-v30-latin-300.woff2') format('woff2'),
    url('../fonts/roboto-v30-latin-300.woff') format('woff');
}
/* roboto-300italic - latin */
@font-face {
    font-display: swap;
    font-family: 'Roboto';
    font-style: italic;
    font-weight: 300;
    src: url('../fonts/roboto-v30-latin-300italic.woff2') format('woff2'),
    url('../fonts/roboto-v30-latin-300italic.woff') format('woff');
}
/* roboto-regular - latin */
@font-face {
    font-display: swap;
    font-family: 'Roboto';
    font-style: normal;
    font-weight: 400;
    src: url('../fonts/roboto-v30-latin-regular.woff2') format('woff2'),
    url('../fonts/roboto-v30-latin-regular.woff') format('woff');
}
/* roboto-italic - latin */
@font-face {
    font-display: swap;
    font-family: 'Roboto';
    font-style: italic;
    font-weight: 400;
    src: url('../fonts/roboto-v30-latin-italic.woff2') format('woff2'),
    url('../fonts/roboto-v30-latin-italic.woff') format('woff');
}
/* roboto-700 - latin */
@font-face {
    font-display: swap;
    font-family: 'Roboto';
    font-style: normal;
    font-weight: 700;
    src: url('../fonts/roboto-v30-latin-700.woff2') format('woff2'),
    url('../fonts/roboto-v30-latin-700.woff') format('woff');
}
/* roboto-700italic - latin */
@font-face {
    font-display: swap;
    font-family: 'Roboto';
    font-style: italic;
    font-weight: 700;
    src: url('../fonts/roboto-v30-latin-700italic.woff2') format('woff2'),
    url('../fonts/roboto-v30-latin-700italic.woff') format('woff');
}

/*! HTML5 Boilerplate v8.0.0 | MIT License | https://html5boilerplate.com/ */

/* main.css 2.1.0 | MIT License | https://github.com/h5bp/main.css#readme */
/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
    color: #222;
    font-size: 1em;
    line-height: 1.4;
    background: #555555;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Vendor-prefixed and regular ::selection selectors cannot be combined:
 * https://stackoverflow.com/a/16982510/7133471
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
    background: #b3d4fc;
    text-shadow: none;
}

::selection {
    background: #b3d4fc;
    text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
    vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

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

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
    resize: vertical;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

* {
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body {
    position: relative;
    font-family: 'Roboto', sans-serif;
}

#mandelbrot-wrapper, #pointer-events-capture, #selection-rectangle-container {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}

#pointer-events-capture {
    touch-action: none;
}

#mandelbrot-background {
    position: absolute;
    left: -10000px;
    right: -10000px;
    top: -10000px;
    bottom: -10000px;
    overflow: hidden;
    background-color: #808080;
    background-image: url("../img/checkerboard.png");
    background-repeat: repeat;
}

#mandelbrot-canvas {
    position: absolute;
    left: 0;
    top: 0;
}

#pointer-events-capture.mode-hand { cursor: grab; }
#pointer-events-capture.mode-hand.mouse-cursor-zoom { cursor: ns-resize; }
#pointer-events-capture.mode-hand.mouse-cursor-rotate { cursor: url('../img/icon-cursor-rotate.svg'), auto; }

#selection-rectangle {
    position: absolute;
    left: 100px;
    top: 100px;
    width: 500px;
    height: 300px;
}

.selection-rectangle-background {
    background: rgba(0, 0, 0, 0.5);
    position: absolute;
}

#selection-rectangle-background-left {
    right: 100%;
    width: 10000px;
    top: -10000px;
    bottom: -10000px;
}

#selection-rectangle-background-top {
    left: 0;
    right: 0;
    bottom: 100%;
    height: 10000px;
}

#selection-rectangle-background-right {
    left: 100%;
    width: 10000px;
    top: -10000px;
    bottom: -10000px;
}

#selection-rectangle-background-bottom {
    top: 100%;
    left: 0;
    right: 0;
    height: 10000px;
}

#selection-rectangle-inner-container {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
}

.selection-rectangle-inner {
    background: transparent;
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    border: 1px solid black;
}

#selection-rectangle-inner-2 {
    border-color: white;
    border-width: 2px;
}

#progress-bar {
    display: none;
    position: absolute;
    left: 0;
    bottom: 0;
    right: 0;
    height: 15px;
    background: rgba(128, 128, 128, 0.5);
}

#progress-bar.visible {
    display: block;
}

#progressbar-inner {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 66%;
    background: #FFFFFF;
}

#progressbar-text {
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    width: auto;
    font-size: 12px;
    font-weight: bold;
    line-height: 15px;
    color: black;
}

#gui {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    background: white;
    overflow: visible;
    width: 0;
    padding: 0;
    margin: 0;
    box-shadow: -2px 0 2px rgba(0, 0, 0, 0.25);
}

#gui #sidebar {
    display: none;
}

#gui.sidebar-visible {
    width: 300px;
}

#gui.sidebar-visible #sidebar {
    display: block;
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    overflow: auto;
}

#main-button-container {
    position: absolute;
    top: 0;
    left: -50px;
    width: 50px;
    height: auto;
}

.main-button {
    cursor: pointer;
    display: block;
    width: 100%;
    height: 50px;
    padding: 10px;
    background: white;
    background-repeat: no-repeat;
    background-position: 50% 50%;
    background-size: contain;
    border: 0;
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.3),
    inset 0 -1px 1px rgba(0, 0, 0, 0.3),
    0 0 1px rgba(255, 255, 255, 0.9);
}

.main-button.active, .main-button:hover:active {
    box-shadow: inset 0 1px 6px rgba(0, 0, 0, 0.3);
    background-position: calc(50% + 1px) calc(50% + 1px);
}

.main-button:hover:active {
    background-color: #cccccc;
}

#button-mode-hand {
    background-image: url("../img/icon-mode-hand.svg");
    background-size: 60%;
}

#button-mode-rectangle {
    background-image: url("../img/icon-mode-rectange.svg");
}

#button-fullscreen {
    background-image: url("../img/icon-fullscreen-backup.svg");
    background-size: 55%;
}

#button-open-close {
    background-image: url("../img/icon-arrow-left.svg");
    background-size: 50%;
    height: 35px;
    border-radius: 0 0 0 10px;
}

.sidebar-visible #button-open-close {
    background-image: url("../img/icon-arrow-right.svg");
}

.sidebar-panel {
}

.sidebar-panel-header {
    background: #f9f9f9;
    border-bottom: 2px solid #EEEEEE;
    color: black;
    padding: 5px 15px;
    font-size: 17px;
    line-height: 17px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.sidebar-panel-body {
    padding: 10px 15px;
}

label {
    font-size: 14px;
    line-height: 14px;
}

input[type="number"] {
    font-size: 13px;
    line-height: 14px;
    padding: 3px 5px;
    border: 2px solid #EEEEEE;
    border-radius: 3px;
    width: 180px;
    margin: 5px 0;
}

input[type="number"].number-input-smaller {
    width: 160px;
}

input[type="number"].number-input-small {
    width: 120px;
}

.label-for-number-input {
    display: inline-block;
    width: 60px;
}

.label-for-number-input-wide {
    width: 100px;
}

.label-for-number-input-addendum {
    width: auto;
}

.buttons-container {
    display: flow-root;
    padding: 5px 0;
}

.buttons-container button {
    display: block;
    float: left;
    margin-right: 10px;
    box-shadow: inset 0px 1px 0px 0px #ffffff;
    background: linear-gradient(to bottom, #f9f9f9 5%, #e9e9e9 100%);
    background-color: #f9f9f9;
    border-radius: 3px;
    border: 1px solid #dcdcdc;
    cursor: pointer;
    color: black;
    font-size: 14px;
    padding: 5px 10px;
    text-decoration: none;
    text-shadow: 0px 1px 0px #ffffff;
}

/*.buttons-container button:hover {
    background: linear-gradient(to bottom, #e9e9e9 5%, #f9f9f9 100%);
    background-color: #e9e9e9;
}*/

.buttons-container button:active {
    position: relative;
    top: 1px;
}

.buttons-container button:last-child {
    margin-right: 0;
}

#color-gradients-container {

}

.color-gradient {
    position: relative;
    padding: 2px;
    height: 20px;
    cursor: pointer;
    margin: 7px 0;
    border-radius: 5px;
}

.color-gradient.selected, .color-gradient:hover {
    background: #cccccc;
    box-shadow: 1px 1px 1px 0 rgba(0, 0, 0, 0.75);
}

.color-gradient-canvas {
    position: absolute;
    left: 2px;
    right: 2px;
    top: 2px;
    bottom: 2px;
    width: calc(100% - 4px);
    height: calc(100% - 4px);
    border-radius: 3px;
}

#color-gradient-canvas-2 {
    border: 1px solid #EEEEEE;
}

.legal-information-container a, .legal-information-container a:hover, .legal-information-container a:visited {
    color: black;
    text-decoration: none;
}

.legal-information-container a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden,
[hidden] {
    display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

.sr-only {
    border: 0;
    clip: rect(0, 0, 0, 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
    width: 1px;
    /* 1 */
}

/*
 * Extends the .sr-only class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.sr-only.focusable:active,
.sr-only.focusable:focus {
    clip: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    white-space: inherit;
    width: auto;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
    visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * For modern browsers
 * 1. The space content is one way to avoid an Opera bug when the
 *    `contenteditable` attribute is included anywhere else in the document.
 *    Otherwise it causes space to appear at the top and bottom of elements
 *    that receive the `clearfix` class.
 * 2. The use of `table` rather than `block` is only necessary if using
 *    `:before` to contain the top-margins of child elements.
 */

.clearfix::before,
.clearfix::after {
    content: " ";
    display: table;
}

.clearfix::after {
    clear: both;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
    /* Style adjustments for viewports that meet the condition */
}

@media print,
(-webkit-min-device-pixel-ratio: 1.25),
(min-resolution: 1.25dppx),
(min-resolution: 120dpi) {
    /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   https://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
    *,
    *::before,
    *::after {
        background: #fff !important;
        color: #000 !important;
        /* Black prints faster */
        box-shadow: none !important;
        text-shadow: none !important;
    }

    a,
    a:visited {
        text-decoration: underline;
    }

    a[href]::after {
        content: " (" attr(href) ")";
    }

    abbr[title]::after {
        content: " (" attr(title) ")";
    }

    /*
     * Don't show links that are fragment identifiers,
     * or use the `javascript:` pseudo protocol
     */
    a[href^="#"]::after,
    a[href^="javascript:"]::after {
        content: "";
    }

    pre {
        white-space: pre-wrap !important;
    }

    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    /*
     * Printing Tables:
     * https://web.archive.org/web/20180815150934/http://css-discuss.incutio.com/wiki/Printing_Tables
     */
    thead {
        display: table-header-group;
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}

