fieldset {
    clear: both;
    border-color: #0063AC;
    border-width: 1px 0px 0px 0px;
    border-style: solid none none none;
    padding: 5px 0px 0px 20px; /* 5px to clear the legend and 20px for the top line to the left of the legend */
    margin: 10px 0px 0px 0px;
}

    fieldset > legend {
        font-size: 120%;
        font-weight: normal;
        color: #0063AC;
        margin: 0 0 0 0;
        padding: 0 10px 0 10px;
    }

/* ------------------------------------------------------- notes blocks */
.notes {
    float: right;
    width: 158px;
    height: auto;
    padding: 5px;
    border: 1px solid #666666;
    background-color: #F4FAFF;
    color: #666666;
    font-size: 80%;
}

    .notes h1, .notes h4 {
        padding: 0px 0 3px 0px;
        border-width: 0 0 1px 0;
        border-style: solid;
        border-color: #666666;
        font-size: 110%;
    }

    .notes p {
        margin: 0.7em 0em 0em 0em;
        line-height: 1.4em;
    }

/* -------------------------------------------------------  Individual Fields and Labels */
fieldset > div {
    clear: left;
    padding: 0 0 5px 10px;
    margin: 0 0 5px 0;
    float: left;
    width: 483px;
}

form div label {
    display: block;
    float: left;
    line-height: 1.2em;
    margin-right: 10px;
    margin-top: 4px;
    padding-right: 20px;
    width: 150px;
}

label {
    color: #444444;
}

input, select, textarea {
    color: #000000;
}

textarea {
    overflow: auto;
}

input, select, textarea {
    width: 200px;
    padding: 1px 3px 1px 3px;
    margin: 0 0 0 0;
}

select {
    width: 210px;
}

form > fieldset > p {
    clear: both;
}

/* ------------------------------------------------------- Single Checkboxes */
form div.CheckBox {
    margin-left: 170px;
    width: 303px;
}

    form div.CheckBox label {
        margin-left: 30px;
        margin-right: 0;
        padding-right: 0;
        text-indent: -20px;
        width: 200px;
    }

/* ------------------------------------------------------- Nested Fieldsets (checkboxes, radiobuttons)*/
form fieldset div fieldset {
    clear: none;
    border-width: 1px;
    border-style: solid;
    border-color: #666666;
    margin: 0 0 0 180px;
    padding: 0 5px 5px 5px;
    width: 198px;
}

    form fieldset div fieldset legend {
        padding: 0 3px 0 9px;
        font-size: 100%;
        font-weight: normal;
        color: #666666;
    }

    form fieldset div fieldset label {
        text-indent: -20px;
        margin-left: 30px;
    }

form fieldset div.required fieldset legend {
    font-weight: bold;
}

fieldset legend label input[type="checkbox"] {
    margin: 0;
}

input[type="checkbox"], input[type="radio"] {
    display: inline;
    width: 14px;
    background-color: transparent;
    border-width: 0;
    padding: 0 0 0 0;
    margin: 0 6px 0 0;
}

fieldset div fieldset div {
    width: 197px;
}

/* ------------------------------------------------------- Required Fields Display */
div.required label {
    background-image: url(../images/flag.gif);
    background-position: top right;
    background-repeat: no-repeat;
    font-weight: bold;
}

/* ------------------------------------------------------- error message display  */
p.error, label.error {
    background-color: #FFFFFF;
    background-image: url(/images/error.png);
    background-repeat: no-repeat;
    background-position: 0px 5px;
    color: #FF0000;
    margin: 0 0 0 200px;
    padding: 0px 0px 0px 15px;
}

form div.error {
    background-color: #ffffe1;
    color: #666666;
    border: 1px solid #CC0000;
}

    form div.error p.error {
        background-color: transparent;
        border-style: none;
        font-size: 88%;
        margin: 0 0 0 180px;
        width: 288px;
        color: #DD0000;
    }

/* ------------------------------------------------------- Single Column Display */
div.onecolumn {
    margin: 0 0 0 10px;
    padding: 0;
    width: auto;
}

    div.onecolumn label {
        width: auto;
        float: none;
        text-indent: -18px;
        padding-left: 18px;
    }

/* ------------------------------------------------------- Three Column Display */
div.threecolumn {
    margin: 0;
    padding: 0;
    width: auto;
}

    div.threecolumn div {
        clear: left;
    }

    div.threecolumn label {
        width: 169px;
        float: left;
        text-indent: -20px;
        margin-left: 0px;
        margin-bottom: 0em;
        padding-left: 30px;
        padding-right: 0;
        line-height: 1.2em;
    }

        div.threecolumn label:first_child {
            clear: left
        }

/* ------------------------------------------------------- Submit Buttons */
input[type="submit"], 
input[type="reset"], 
input[type="button"] {
    background-color: #0063AC;
    color: #FFFFFF;
    width: auto;
    padding: 0 6px;
    margin-right: 20px;
}

fieldset div input[type="submit"],
fieldset div input[type="reset"],
fieldset div input[type="button"] {
    display: block;
    margin-left: 180px;
}

input[type="submit"][disabled] {
    background-color: gray;
}

/* ------------------------------------------------------- Expanding/Collapsing Fieldsets */
img .expandCollapseButton {
    cursor: pointer;
    margin-right: 11px;
}

fieldset.collapsedFieldset > * {
    visibility: hidden;
    display: none;
}

fieldset.collapsedFieldset > legend {
    visibility: visible;
    display: inline;
}

img.expandCollapseButton {
}

fieldset.collapsedFieldset > legend > img.expandCollapseButton {
    background-color: #006600;
    background-image: url(/images/Collapsed.png);
    visibility: visible;
    display: inline;
}

fieldset.expandedFieldset > legend > img.expandCollapseButton {
    background-color: #660000;
    background-image: url(/images/Expanded.png);
}

fieldset.expandedFieldset {
    border-width: 1px 0px 0px 1px;
    border-style: solid none none solid;
    padding: 5px 0 0 19px;
}

fieldset.collapsedFieldset {
    border-width: 1px 0px 0px 0px;
    border-style: solid none none none;
    padding: 5px 0 0 20px;
}

fieldset > * {
    margin-left: 10px;
}

.date {
    width: 90px;
}

select.date {
    width: 106px;
    font-size: xx-small;
    margin-bottom: 1px;
}
