/*
 * htdocs/assets/style.css
 *
 * Copyright (C) 2011  Chris Howie <me@chrishowie.com>
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as
 * published by the Free Software Foundation, either version 3 of the
 * License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

html {
    overflow-y: scroll;
    margin: 0;
    padding: 0;
}

body {
    font: 10pt sans-serif;
    color: #bbb;
    background-color: #222;
    margin: 0;
    padding: 0;
}

h1 {
    font-weight: bold;
    font-size: 240%;

    text-align: center;

    margin-top: 0.5em;
    margin-bottom: 0;
}

table.data {
    border-collapse: collapse;
    cursor: default;
}

table.data,
table.data td,
table.data th {
    border: 1px solid #bbb;
}

table.data td,
table.data th {
    padding: 0.5em;
}

table.data th {
    background-color: #444;
}

table.data tr:hover {
    background-color: #333;
}

table.data tr.rejected,
table.data tr.disabled,
table.data tr.alert {
    background-color: #522;
}

table.data tr.rejected:hover,
table.data tr.disabled:hover,
table.data tr.alert:hover {
    background-color: #633;
}

#footer {
    text-align: center;

    position: fixed;
    bottom: 0px;
    left: 0px;

    width: 100%;

    padding: 0.5em 0;

    background-color: #222;
}

#content {
    padding-bottom: 7.5em;
}

.centered {
    margin-left: auto;
    margin-right: auto;
}

#dashboard {
    text-align: center;
}

#about {
    width: 55em;
    max-width: 100%;

    margin-left: auto;
    margin-right: auto;
}

#recent-submissions,
#recent-failed-submissions,
#worker-status,
#pool-status {
    margin: 0 1em;
    padding: 0;

    display: inline-block;
    text-align: left;
}

#navmenu {
    list-style: none;
    margin: 1.5em 0;
    padding: 0;
    text-align: center;
}

#navmenu li {
    margin: 0;
    padding: 0;
    display: inline;
}

#navmenu li a {
    color: inherit;
    text-decoration: none;

    padding: 0.25em 0.5em;
    border: 1px solid transparent;
}

#navmenu li.active a {
    background-color: #333;
}

#navmenu li a span {
    padding-left: 20px;
    min-height: 16px;

    background-repeat: no-repeat;
    background-position: left center;
}

#navmenu #nav-dashboard a span {
    background-image: url('icons/report.png');
}

#navmenu #nav-pools a span {
    background-image: url('icons/server.png');
}

#navmenu #nav-workers a span {
    background-image: url('icons/cog.png');
}

#navmenu #nav-about a span {
    background-image: url('icons/information.png');
}

.dashboard-warning span,
.dashboard-error span {
    display: block;
    padding-left: 20px;
    background-repeat: no-repeat;
    background-position: left top;
}

.dashboard-warning,
.dashboard-error {
    width: 50%;
    margin: 0 auto;

    border: 2px solid;

    padding: 0.5em;

    margin-bottom: 0.5em;
}

.dashboard-warning {
    color: #ffe;
    background-color: #440;
    border-color: #880;
}

.dashboard-error {
    color: #fee;
    background-color: #600;
    border-color: #c00;
}

#old-schema span {
    background-image: url('icons/database_error.png');
}

#url-fopen-disabled span {
    background-image: url('icons/exclamation.png');
}

#recent-submissions h2,
#recent-failed-submissions h2,
#worker-status h2,
#pool-status h2 {
    padding-left: 22px;
    background-repeat: no-repeat;
    background-position: left center;
}

#recent-submissions h2 {
    background-image: url('icons/page_go.png');
}

#recent-failed-submissions h2 {
    background-image: url('icons/page_error.png');
}

#worker-status h2 {
    background-image: url('icons/cog.png');
}

#pool-status h2 {
    background-image: url('icons/server.png');
}

.enabled-column {
    text-align: center;
}

a:link, a:active, a:visited, a:hover {
    color: inherit;
}

a:hover {
    color: #fff;
}

table.entry,
table.entry td,
table.entry th {
    border: none;
}

table.entry th {
    font-weight: normal;
    text-align: right;
}

table.entry tr.submit {
    text-align: center;
}

input[type='submit'],
#navmenu li a:hover {
    color: #bbb;
    border: 1px outset #777;
    background-color: #333;
}

form {
    display: inline;
}

img,
input[type='image'] {
    border: none;
    vertical-align: bottom;
}

tr:hover .row-hover-hide {
    display: none;
}

tr .row-hover-show {
    display: none;
}

tr:hover .row-hover-show {
    display: inline;
}

fieldset {
    border: none;
    padding: 0;
    margin: 0;
    display: inline;
}

.errors,
.info {
    margin: 1em auto;

    display: table;
}

.errors ul,
.info ul {
    padding: 0;
    padding-left: 1.5em;

    display: table-cell;

    font-weight: bold;
}

.errors ul {
    color: #f44;
}

.info ul {
    color: #4f4;
}

.image-button {
    border: none;
    padding: 0;
    margin: 0;

    width: 16px;
    height: 16px;

    background-color: transparent;
    background-position: center center;
    background-repeat: no-repeat;

    vertical-align: top;

    cursor: pointer;
}

.image-button span {
    display: none;
}

.image-button-edit-pool-assignment {
    background-image: url('icons/server_edit.png');
}

.image-button-delete-pool-assignment {
    background-image: url('icons/server_delete.png');
}

.image-button-create-pool-assignment {
    background-image: url('icons/server_add.png');
}

.image-button-disabled {
    background-image: url('icons/flag_red.png');
}

.image-button-enabled {
    background-image: url('icons/flag_green.png');
}

.image-button-manage-pools {
    background-image: url('icons/server_go.png');
}

.image-button-edit-pool {
    background-image: url('icons/server_edit.png');
}

.image-button-delete-pool {
    background-image: url('icons/server_delete.png');
}

.image-button-new-pool {
    background-image: url('icons/server_add.png');
}

.image-button-edit-worker {
    background-image: url('icons/cog_edit.png');
}

.image-button-delete-worker {
    background-image: url('icons/cog_delete.png');
}

.image-button-new-worker {
    background-image: url('icons/cog_add.png');
}

