﻿body {
    padding-top: 50px;
    padding-bottom: 20px;
    overflow-wrap: break-word;  /* Allow long words to break. */
}

/* Wrapping element */
/* Set some basic padding to keep content from hitting the edges */
.body-content {
    padding-left: 15px;
    padding-right: 15px;
}

/* Carousel */
.carousel-caption p {
    font-size: 20px;
    line-height: 1.4;
}

/* QR code generator */
#qrCode {
    margin: 15px;
}

/* Hide/rearrange for smaller screens */
@media screen and (max-width: 767px) {
    /* Hide captions */
    .carousel-caption {
        display: none;
    }
}

/* Set widths on the form inputs since otherwise they're 100% wide */
input,
select,
textarea {
    max-width: 340px;
}

/* small form inputs */
input.input-sm,
select.input-sm,
textarea.input-sm {
    max-width: 120px;
}

/* style for uppercase */
.uppercase {
    text-transform: uppercase;
}

/* Horizontal rule that is smaller */
hr.smallrule {
    margin-top: 8px;
    margin-bottom: 8px;
}

a.uncolored-link {
    color: #333
}

/* sticky header */
.sticky-header {
    position: sticky;
    top: 50px;
    background-color: #fff;
}

/* Styles for the runner's puzzle list*/
.runner-puzzle-name {
    font-weight: bold;
    font-size: 130%;
}

.runner-puzzle-round {
    font-size: 100%;
}


.runner-stamp-location {
    font-size: 100%;
}

#barcode-viewport > canvas, #barcode-viewport > video {
    max-width: 80%;
    width: 80%;
}

#qrcode-viewport {
    max-width: 80%;
    width: 80%;
}

/* Styles for stamping scoring page */

/* table styles */
table.scoring {
    border: solid 1px #e8eef4;
    border-collapse: collapse;
}

table.scoring td {
    padding: 5px;
    border: solid 1px #e8eef4;
}

table.scoring th {
    padding: 6px 5px;
    text-align: left;
    background-color: #e8eef4;
    border: solid 1px #e8eef4;
}

table.scoring tr.pagebreak td {
    border-top-width: 18px;
}

/* Controls for showing stamped/not stamped instead of a checkbox. */

div.notsolved label {
    width: 180px;
    height: 60px;
    padding-top: 20px;
    text-align: center;
    color: #d0d0d0
}

/* Hide the checkbox. */
div.solved input[type=checkbox] {
    display: none;
    margin: 0;
}

/* Style the size and alignment of the label connected to the checkbox */
div.solved input + label {
    width: 180px;
    height: 60px;
    padding-top: 20px;
    text-align: center;
}

/* When checked, green and shows "STAMPED" */
div.solved input:checked + label {
    background-color: #0f3;
}

div.solved input:checked + label::before {
    content: "STAMPED";
}

/* When unchecked, yellow and shows "UNSTAMPED" */
div.solved input:not(:checked) + label {
    background-color: #ffffc0;
}

div.solved input:not(:checked) + label::before {
    content: "UNSTAMPED";
}


td.barcodes-name {
    padding-top: 2.5em;
    padding-bottom: 1em;
    width: 25em;
}

.pagebreak {
    page-break-before: always;
}

/* div for aligning two children left and right */
div.leftright {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* squared for team selection */
td.team-square {
    border: 1px solid #333;
    text-align: center;
    width: 60px;
    height: 45px;
}

td.team-square a {
    font-size: 25px;
    color: #333;
}

/* square for team selection, team already scored */
td.team-square-scored {
    background-color: lightgreen;
}

.round1score {
    background-color: #b2ffff;
}

.round2score {
    background-color: #c8ffc8;
}

/* Voting */

/* Hide radio button */
input.radio-vote
{
    display:none;
}

input.radio-vote + label {
    color: #aaa;
}

input.radio-vote + label {
    padding: 10px;
    min-width: 130px;
}

input.radio-vote-narrow + label {
    padding: 10px;
    min-width: 80px;
}

input.radio-vote:not(:checked) + label {
    border: 1px solid white;
}

input.radio-vote:checked + label {
    border: 1px solid blue;
    border-radius: 5px;
}

input.radio-vote:checked + label.radio-like {
    color: #1ab001;
}

input.radio-vote:checked + label.radio-dislike {
    color: red;
}

input.radio-vote:checked + label.radio-meh {
    color: black;
}

input.radio-vote:checked + label.radio-star {
    color: gold;
}


label.radio-like, label.radio-dislike, label.radio-meh, label.radio-star {
    text-align: center;
    font-weight: normal;
    font-size: 18px;
}

.vote-icon {
    font-size: 64px;
    margin-bottom: 5px;
}

.vote-icon-sm {
    font-size: 24px;
    margin-bottom: 3px;
}

/* The table showing the options. */
table.table-vote {
    margin-top: 1.5em;
    margin-bottom: 1.5em;
}

table.table-vote td.table-vote-spacer {
    padding-left: 10px;
    padding-right: 10px;
    vertical-align: middle;
}

table.table-vote td {
    vertical-align: middle;
    height: 140px;
}

table.table-vote tr.comment-row td {
    height: auto;
}



/* Picture submission */

.pic-file input[type=file] {
    display: none;
}

.width100 {
    width: 100%;
    max-width: 100%;
}

/* Picture scoring */

.picscore-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 0.4fr));
    grid-column-gap: 1rem;
    grid-row-gap: 1rem;
}

.picscore-team {
    font-weight: bold;
    text-align: center;
    margin-bottom: 0.5em;
}

.picscore-starredteam {
    font-weight: bold;
    font-size: 20px;
    text-align: center;
    margin-bottom: 0.5em;
}

.picscore-score {
    margin-top: 0;
    margin-bottom: 0;
}

img.picscore-img {
    width: 100%;
    margin-left: 2px;
    margin-right: 2px;
    margin-bottom: 2.5em;
}

.rotatedm90 {
    text-align: right;
}

.notrotated img {
    width: 100%;
}
.rotated180 img {
    width: 100%;
    transform: rotate(180deg);
}

.rotated90 img {
    transform-origin: top left;
    transform: translate(95vw, 0)  rotate(90deg);
    height: 95vw;
}
.rotatedm90 img {
    transform-origin: top right;
    transform: translate(-95vw, 0) rotate(-90deg);
    height: 95vw;
}

/* Rules */
.image-kind {
    width: 90px;
    height: 90px;
}