/* Backdrops */
.jc-backdrop
{
    position: fixed;
    z-index: 999998;
    top: 0px;
    left: 0px;
    width: 100%;
    height: 100%;
}
/* Black backdrop */
.jc-backdrop.jc-black-backdrop
{
    background: rgba(0,0,0,.5);
}
/* White backdrop */
.jc-backdrop.jc-white-backdrop
{
    background: rgba(255,255,255,.5);
}
/* Blur everything in body except the tooltip */
/* @todo: Find a way to NOT blur the clicked element. Turns out that's not easy. */
.jc-blurred-body > *:not(.jc-tooltip)
{
    -webkit-filter: blur(2px);
    filter: blur(2px);
}

/* Confirm tooltip */
.jc-tooltip
{
    position: absolute;
    z-index: 999999;
    background: #444444;
    border-radius: 5px;
    padding: 10px;
    display: flex;
    flex-direction: row;
    box-sizing: border-box;
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
}
/* Centers the tooltip on screens where it won't fit */
.jc-centered
{
    position: fixed;
    top: 50%;
    left: 50%;
}

/* Stacks the question and buttons vertically for mobile and places it wouldn't normally fit */
.jc-tight-fit
{
    flex-direction: column;
}
.jc-tight-fit .jc-question
{
    margin-top: 0px;
    text-align: center;
}
.jc-tight-fit .jc-buttons-wrap
{
    margin-bottom: .3em;
}
.jc-tiny.jc-tight-fit
{
    padding: 2px 15px;
}
.jc-tight-fit .jc-question
{
    margin: 0px 0px 5px 0px;
}
.jc-tiny.jc-tight-fit .jc-buttons-wrap
{
    margin-bottom: 1em;
}
.jc-small.jc-tight-fit .jc-buttons-wrap
{
    margin-bottom: .4em;
}

.jc-question
{
    flex: 1;
    margin: 5px 20px 5px 10px;
    font-size: 1em;
    line-height: 1.6em;
    text-align: center;
    color: #fff;
    font-weight: 800;
    padding: 5px 0px;
    white-space: nowrap;
}

.jc-buttons-wrap
{
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
}

.jc-button-wrap
{
    display: flex;
    flex-direction: column;
    white-space: nowrap;
}

.jc-button,
.jc-button:link,
.jc-button:hover,
.jc-button:active,
.jc-button:focus,
.jc-button:visited
{
    margin: 0px 5px;
    font-size: 1.2em;
    line-height: 1.4em;
    text-decoration: none;
    padding: .25em .8em;
}

/* Arrow */
.jc-arrow {
    border: 15px solid rgba(232, 232, 232, 0);
    content: " ";
    height: 0;
    width: 0;
    position: absolute;
    pointer-events: none;
    margin-left: -15px;
}
/* Arrow - Top */
.jc-arrow-top
{
    border-bottom-color: #444444;
    bottom: 100%;
    left: 50%;
    top: auto;
    right: auto;
}
/* Arrow - Bottom */
.jc-arrow-bottom
{
    border-top-color: #444444;
    top: 100%;
    left: 50%;
    bottom: auto;
    right: auto;
}
/* Arrow - Left */
.jc-arrow-left
{
    border-right-color: #444444;
    border-width: 16px;
    left: -15px;
    right: auto;
    bottom: auto;
    top: 50%;
    margin-top: -15px;
}
/* Arrow - Right */
.jc-arrow-right
{
    border-left-color: #444444;
    right: -30px;
    left: auto;
    bottom: auto;
    border-width: 15px;
    top: 50%;
    margin-top: -15px;
}
/* Arrow - Hug Left */
.jc-arrow-hug-left
{
    left: 30px;
    right: auto;
}
/* Arrow - Hug Right */
.jc-arrow-hug-right
{
    right: 30px;
    left: auto;
}

/* Arrow - Get really close to the left because the button is small */
.jc-arrow-hug-left.jc-arrow-super-hug
{
    left: 15px;
    right: auto;
}
/* Arrow - Get really close to the right because the button is small  */
.jc-arrow-hug-right.jc-arrow-super-hug
{
    right: 1px;
    left: auto;
}
/* Arrow - Get really close to the left because the button is small - need to adjust for border radius */
.jc-arrow-top.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-arrow-top.jc-arrow-hug-right.jc-arrow-super-hug
{
    top: -27px;
}
/* Arrow - Get really close to the left because the button is small - need to adjust for border radius */
.jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug
{
    top: auto;
    bottom: -28px;
}

/* Black theme */
.jc-black-theme .jc-button
{
    text-align: center;
}

.jc-black-theme .jc-button,
.jc-black-theme .jc-button:link,
.jc-black-theme .jc-button:hover,
.jc-black-theme .jc-button:active,
.jc-black-theme .jc-button:focus,
.jc-black-theme .jc-button:visited
{
    color: #dadada;
    border-radius: 5px;
}

.jc-black-theme .jc-button-highlight,
.jc-black-theme .jc-button-highlight:link,
.jc-black-theme .jc-button-highlight:hover,
.jc-black-theme .jc-button-highlight:active,
.jc-black-theme .jc-button-highlight:focus,
.jc-black-theme .jc-button-highlight:visited
{
    background: #23a71b;
    color: #fff;
}
.jc-black-theme .jc-button:hover
{
    background: #3a3a3a;
}
.jc-black-theme .jc-button-highlight:hover
{
    background: #1f9617;
}

/* White theme */
.jc-white-theme
{
    background: #fff;
    border: 2px solid #c7c7c7;
}
.jc-white-theme .jc-question
{
    color: #333;
}
.jc-white-theme .jc-button,
.jc-white-theme .jc-button:link,
.jc-white-theme .jc-button:hover,
.jc-white-theme .jc-button:active,
.jc-white-theme .jc-button:focus,
.jc-white-theme .jc-button:visited
{
    color: #3e3e3e;
    border-radius: 5px;
}

.jc-white-theme .jc-button-highlight,
.jc-white-theme .jc-button-highlight:link,
.jc-white-theme .jc-button-highlight:hover,
.jc-white-theme .jc-button-highlight:active,
.jc-white-theme .jc-button-highlight:focus,
.jc-white-theme .jc-button-highlight:visited
{
    background: #23a71b;
    color: #fff;
}
.jc-white-theme .jc-button:hover
{
    background: #e8e8e8;
}
.jc-white-theme .jc-button-highlight:hover
{
    background: #1f9617;
}
.jc-white-theme .jc-arrow-top
{
    border-bottom-color: #c7c7c7;
}
.jc-white-theme .jc-arrow-bottom
{
    border-top-color: #c7c7c7;
}
.jc-white-theme .jc-arrow-left
{
    border-right-color: #c7c7c7;
}
.jc-white-theme .jc-arrow-right
{
    border-left-color: #c7c7c7;
}

/* Bootstrap 4 theme */
.jc-bootstrap-4-theme .btn
{
    margin: 0px 5px;
}

/* Bootstrap 4 white theme */
.jc-bootstrap-4-white-theme .btn
{
    margin: 0px 5px;
}
.jc-bootstrap-4-white-theme .jc-question
{
    color: #333;
}
.jc-bootstrap-4-white-theme
{
    background: #fff;
    border: 2px solid #c7c7c7;
}
.jc-bootstrap-4-white-theme .jc-arrow-top
{
    border-bottom-color: #c7c7c7;
}
.jc-bootstrap-4-white-theme .jc-arrow-bottom
{
    border-top-color: #c7c7c7;
}
.jc-bootstrap-4-white-theme .jc-arrow-left
{
    border-right-color: #c7c7c7;
}
.jc-bootstrap-4-white-theme .jc-arrow-right
{
    border-left-color: #c7c7c7;
}

.jc-white-theme .jc-arrow-top.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-white-theme .jc-arrow-top.jc-arrow-hug-right.jc-arrow-super-hug,
.jc-bootstrap-4-white-theme .jc-arrow-top.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-bootstrap-4-white-theme .jc-arrow-top.jc-arrow-hug-right.jc-arrow-super-hug
{
    top: -30px;
}
.jc-white-theme .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-white-theme .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug,
.jc-bootstrap-4-white-theme .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-bootstrap-4-white-theme .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug
{
    bottom: -30px;
}

/* Large tooltip */
.jc-large
{
    font-size: 18px;
}

/* Medium tooltip */
.jc-medium
{
    font-size: 14px;
}

/* Small tooltip */
.jc-small
{
    font-size: 12px;
    padding: 5px;
}
.jc-small .jc-question
{
    margin: 2px 8px;
    line-height: 1.9em;
}

/* Tiny tooltip */
.jc-tiny
{
    padding: 2px 5px;
    font-size: 10px;
}
.jc-tiny .jc-question
{
    margin: 4px 7px;
}
.jc-tiny .jc-button
{
    margin: 0px 3px;
}
.jc-tiny .jc-arrow
{
    border-width: 10px;
    margin-left: -10px;
}
.jc-tiny .jc-arrow-left
{
    left: -10px;
    margin-top: -10px;
}
.jc-tiny .jc-arrow-right
{
    right: -20px;
    margin-top: -10px;
}
/**
@todo: Rewrite arrows in JS since they are so complicated in CSS
 */
.jc-tiny .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny .jc-arrow-top.jc-arrow-hug-left.jc-arrow-super-hug
{
    left: 11px;
}
.jc-tiny .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug,
.jc-tiny .jc-arrow-top.jc-arrow-hug-right.jc-arrow-super-hug
{
    right: 1px;
}
.jc-tiny.jc-white-theme .jc-arrow-top.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny.jc-white-theme .jc-arrow-top.jc-arrow-hug-right.jc-arrow-super-hug,
.jc-tiny.jc-bootstrap-4-white-theme .jc-arrow-top.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny.jc-bootstrap-4-white-theme .jc-arrow-top.jc-arrow-hug-right.jc-arrow-super-hug
{
    top: -18px;
}
.jc-tiny.jc-white-theme .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny.jc-white-theme .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug,
.jc-tiny.jc-bootstrap-4-white-theme .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny.jc-bootstrap-4-white-theme .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug
{
    bottom: -21px;
}
.jc-tiny.jc-black-theme .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny.jc-black-theme .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug,
.jc-tiny.jc-bootstrap-4-theme .jc-arrow-bottom.jc-arrow-hug-left.jc-arrow-super-hug,
.jc-tiny.jc-bootstrap-4-theme .jc-arrow-bottom.jc-arrow-hug-right.jc-arrow-super-hug
{
    bottom: -18px;
}