/* Perustaulukko */
.table_jm {
    width: 100%;
    border-collapse: collapse;
}

/* Solujen perusmuotoilu (valinnainen mutta yleensä hyvä) */
.table_jm th,
.table_jm td {
    padding: 8px;
    text-align: left;
    vertical-align: top;
}

/* Raitaus: joka toinen rivi */
.table_jm-striped tbody tr:nth-child(even) {
    background-color: #f2f2f2; /* vaalean harmaa */
}

.table_jm-striped tbody tr:nth-child(odd) {
    background-color: #ffffff; /* valkoinen */
}

/* Hover-efekti */
.table_jm-hover tbody tr:hover {
    background-color: #d6d6d6; /* tummempi harmaa hoverissa */
}

/* Oikealle tasattu sisältö */
.table_jm td.text-right,
.table_jm th.text-right {
    text-align: right;
}

/* Keskitys (usein myös hyödyllinen) */
.table_jm td.text-center,
.table_jm th.text-center {
    text-align: center;
}

/* Jos haluat vain numerot oikealle automaattisesti */
.table_jm td.number {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.img-box {
    width: 100%;
    max-width: 600px;   /* halutessasi yläraja */
    border: 1px solid #ccc;
}

.img-box img {
    width: 100%;
    height: auto;
    display: block;
}

.box {
    width: 100%;
    background: #ffffff;

    border: 1px solid #ced0b7;
    border-radius: 10px;

    padding: 15px 18px;
    margin-bottom: 20px;

    box-sizing: border-box;
}

.push-right {
    float: right;
    margin-left: 12px;
}

input[type="checkbox"],
input[type="radio"] {
    appearance: auto !important;
    -webkit-appearance: auto !important;
    -moz-appearance: auto !important;

    width: auto !important;
    height: auto !important;

    margin-right: 6px;
}

.show-viesti {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);

    min-width: 320px;
    max-width: 700px;

    padding: 14px 20px;
    border-radius: 10px;

    background: #ffffff;
    color: #283121;

    border: 1px solid #ced0b7;
    box-shadow: 0 10px 30px rgba(0,0,0,0.12);

    z-index: 99999;

    font-size: 0.95em;
    text-align: center;

    animation: fadeInOut 4s ease forwards;
}

@keyframes fadeInOut {
    0%   { opacity:0; transform:translate(-50%, -20px); }
    10%  { opacity:1; transform:translate(-50%, 0); }
    85%  { opacity:1; }
    100% { opacity:0; transform:translate(-50%, -20px); }
}

.button-sm {
    display: inline-block;

    padding: 6px 12px;
    font-size: 0.9em;

    border-radius: 6px;

    background-color: #007b9d;
    color: #fff;

    text-decoration: none;
    border: solid 1px #006e8b;

    box-shadow: inset 0px 0px 0px 1px #18a8c8;
}

.button-sm:hover {
    background-color: #118eb1;
    box-shadow: inset 0px 0px 0px 1px #3ecceb;
}

.button-sm-light {
    display: inline-block;

    padding: 5px 10px;
    font-size: 0.85em;

    border-radius: 6px;

    background: transparent;
    color: #007b9d;

    border: 1px solid #ced0b7;

    text-decoration: none;
}

.button-sm-light:hover {
    background: #f4f8f9;
    border-color: #007b9d;
}

/* Yleinen selected-tila */
.button-sm-light.selected {
    background: #28a745;
    color: #fff;
    border-color: #28a745;
}

/* Hover selectedille (hieman tummempi) */
.button-sm-light.selected:hover {
    background: #218838;
    border-color: #1e7e34;
}

img.center {
    display: block;
    margin-left: auto;
    margin-right: auto;
    max-width: 100%;
    height: auto;
}