body {
    font-size: 100%;
    margin: 0px;
    width: 100%;
    overflow-x: hidden;
}

/* Could use window.matchMedia() instead */
#mediaTypeDiv {
    font-weight: normal;
    display: none;
}

#tunesDiv {
    position: absolute;
    font-size: 100%;
    margin-top: 4em;
    margin-bottom: 4em;
    margin-left: 0.5em;
    margin-right: 0.5em;
    left: 20em;
    right: 0px;
}

#tuneTable {
    width: 100%;
    table-layout: fixed;
}

#sideDiv {
    position: fixed;
    top: 4em;
    left: 0px;
    bottom: 0px;
    width: 19em;
    padding: 0.5em;
    border-right: 1px solid gray;
    z-index: 1;
}

#newActionUserDiv {
    display: none;
}

#navActions {
    display: none;
}

@media screen  and (max-device-width: 480px) and (orientation: portrait) {
    #mediaTypeDiv {
        font-weight: bold;
    }

    #tunesDiv {
        position: static;
        padding-bottom: 2.5em;
    }

    #sideDiv {
        position: static;
        width: auto;
        border-right: 0px;
    }

    #navActions {
        display: block;
    }

    #newAction {
        display: none;
    }

    #newActionUserDiv {
        display: block;
        float: right;
    }
}

#tuneLevelCol {
    width: 2em;
}

#tuneRefsCol {
    width: 15em;
}

#tuneNameCol {
    width: auto;
}

#tuneSinceCol {
    width: 5em;
}

#tuneFlagsCol {
    width: 2.5em;
}

.tune-flags {
    text-align: right;
    padding-right: 0.5em;
}

:link {
    color: #AA2222;
    text-decoration: none;
}

:visited {
    color: #884444;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

#tuneTable tr:hover {
    background: #ffeecc;
}

#tuneTable .selected-row, #tuneTable tr.selected-row:hover {
    background: #0088aa;
    color: white;
}

#tuneTable tr:active {
    background: #ffeecc;
}

#tuneTable tr {
    -moz-user-select: none;
    -webkit-user-select: none;
}

#headerDiv {
    font-size: 100%;
    position: fixed;
    top: 0px;
    left: 0px;
    right: 0px;
    padding: 0.5em;
    background: white;
    height: 3em;
    border-bottom: 1px solid gray;
    z-index: 1;
}

#userDiv {
    position: absolute;
    top: 0px;
    left: 0px;
    height: 3em;
    width: 19em;
    padding: 0.5em;
    border-right: 1px solid gray;
}

#filterDiv {
    position: absolute;
    top: 0px;
    left: 20em;
    right: 0px;
    padding: 0.5em;
}

#filterInput {
    width: 40em;
}

#filterRhythm {
    position: absolute;
    left: 42em;
    width: 10em;
}

@media screen and (max-device-width: 480px) and (orientation: portrait) {
    #userDiv {
        position: fixed;
        top: auto;
        bottom: 0px;
        right: 0px;
        width: auto;
        height: 1.75em;
        padding: 0.25em;
        border-top: 1px solid gray;
        background: white;
        border-right: 0px;
    }

    #filterInput {
        width: 100%;
    }

    #filterInputDiv {
        position: relative;
        margin-right: 10em;
    }

    #filterDiv {
        left: 0px;
    }

    #filterRhythm {
        position: static;
        float: right;
    }
}

#sideBarButtons {
    position: fixed;
    background: white;
    left: 0px;
    right: 0px;
    bottom: 0px;
    height: 1.75em;
    padding: 0.25em;
    border-top: 1px solid gray;
}

#tuneActions {
    float: left;
}

#navActions {
    float: right;
}

#infoDiv, #editDiv {
    width: 100%;
    padding-bottom: 1.75em;
}

.section-header {
}

.section-header th {
    border: 1px solid gray;
    background: #cceeaa;
    text-align: left;
}

.rhythm-header th {
    background: #aabb88;
}

.level-outer {
    position: relative;
    width: 1em;
    height: 1em;
    vertical-align: middle;
}

.level {
    width: 1em;
    height: 1em;
    position: absolute;
    top: -0.2em;
    left: 0px;
    text-align: center;
}

.symbol-maxlevel {
    display: inline-block;
    position: relative;
    top: -0.1em;
    color: #ffaa00;
    width: 0px;
}

.symbol-level {
    position: relative;
    top: -0.1em;
}

.info-name {
    font-size: 140%;
    font-weight: bold;
    margin-top: 0.25em;
    margin-bottom: 0.25em;
}

.info-name .symbol-level, .info-name .symbol-maxlevel {
    font-size: 120%;
}

.info-aka {
    font-size: 120%;
    font-weight: bold;
    margin-top: 0.25em;
    margin-bottom: 0.25em;
}

.info-details {
    font-size: 120%;
    font-weight: bold;
    margin-top: 0.25em;
    margin-bottom: 0.75em;
    color: #444444;
}

.info-label {
    font-weight: bold;
}

.info-refs, .info-since, .info-incipit {
    margin-top: 0.25em;
    margin-bottom: 0.25em;
}

.info-notes {
    width: 100%;
    margin-top: 0.5em;
    padding-top: 0.5em;
    border-top: 1px solid #cccccc;
}

.study-name {
    font-weight: bold;
}

#rhythmDiv :link {
    color: black;
}

#rhythmDiv .selected {
    font-weight: bold;
}

.edit-item {
    clear: both;
    margin-bottom: 0.5em;
}

.edit-label {
    font-weight: bold;
}

.edit-value {
    width: 100%;
}

.edit-left-column {
    display: block;
    float: left;
    font-weight: bold;
    width: 9em;
    margin-bottom: 0.5em;
}

.edit-right-column {
    display: block;
    float: right;
    right: 0px;
    width: 10em;
    margin-bottom: 0.5em;
}

#levelSelectTable td {
    padding-right: 1em;
}

.level-select, .max-level-select {
    display: inline-block;
    width: 1em;
    height: 1em;
    border: 1px solid black;
    vertical-align: top;
    overflow: hidden;
    color: black;
}

.level-select:hover, .max-level-select {
    text-decoration: none;
}

.level-select-selected {
    background: black;
    color: white;
}

.level-select-contents {
    position: relative;
    top: -0.2em;
}

#editNotes  {
   width: 100%;
   height: 15em;
}

#dialogDiv {
}

#dialogDiv {
    position: fixed;
    top: 0px;
    left: 0px;
    right: 0px;
    bottom: 0px;
    z-index: 2;
}

#dialogBackgroundDiv {
    position: absolute;
    width: 100%;
    height: 100%;
    background: black;
    opacity: 0.5;
    z-index: -1;
}

#dialogContentsDiv {
    background: white;
    border: 1px solid black;
    padding: 1em;
}

#dialogDiv table {
    margin-left: auto;
    margin-right: auto;
    height: 100%;
}

#dialogDiv tr {
}

#dialogMessageDiv {
    margin-bottom: 0.75em;
}

#dialogButtonDiv {
    float: right;
}

#dialogBottomDiv {
    clear: both;
}

#editPageBody {
    margin-left: auto;
    margin-right: auto;
    width: 30em;
}

#editPageUserDiv {
    position: absolute;
    top: 0.5em;
    right: 0.5em;
    text-align: right;
}

#editPageBody #tuneActions {
    position: static;
    float: right;
}

#loginPageTable {
    height: 100%;
    margin-left: auto;
    margin-right: auto;
    padding: 1em;
}

#loginTable {
    border: 1px solid black;
    padding: 0.5em;
}

#loginButtonCell {
    text-align: right;
    padding-top: 0.5em;
}

#infoIncipitMusic {
    width: 100%;
}

#infoIncipitMusic > svg {
    width: 100%;
}
