/* some of this stuff surely belongs more in a presidents.css or something */

body {
    color: white;
    background: black;
    margin: 0;
    padding: 0;
}

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

body>div {
    width: 800px;
    margin: auto;
    padding: 0;
}

#intro h1 {
    text-align: center;
}

#foot {
    position: relative;
    margin: 0 auto 2em;
    padding: 2em 0 0;
}

#main {
    position: relative;
    width: 950px;
}

#main>* {
    vertical-align: top; /* TBD: temp? */
    /* vertical-align: middle; */
    margin: 0;
    padding: 0;
}
#main.selected>* {
    vertical-align: top; /* temp ? or a way to puss out on some math */
}

#main #timeline {
    position: relative;
    display: inline-block;
/*    background: #111; /* temp */
    width: 450px;
    font-family: sans-serif;
    font-size: 8pt;
    font-weight: 300;
}

#main #timeline span {
    position: absolute;
}

#main #timeline>span.year {
    text-shadow: 1px 1px 1px black;
    left: 156px;
    z-index: 15;
    pointer-events: none;
}

#main #timeline>span.prez {
    left: 374px;
}

#main #timeline>span.vp {
    left: 425px;
}

#main #timeline .entry {
    border: 1px solid #444; /* make 0.5 transp? */
    text-shadow: 1px 1px 0px black;
}

#main #timeline .entry.prez {
    left: 183px;
    width: 185px;
}

#main #timeline .entry.vp {
    left: 392px;
    width: 27px;
}

#main #timeline .entry.current {
    -moz-box-shadow: 0px 0px 8px white;
    -webkit-box-shadow: 0px 0px 8px white;
    box-shadow: 0px 0px 8px white;
    z-index: 10;
    -o-transform: scale(1.025);
    -ms-transform: scale(1.025);
    -moz-transform: scale(1.025);
    -webkit-transform: scale(1.025);
    transform: scale(1.025);
}

#main #timeline .entry.highlight {
    -moz-box-shadow: 0px 0px 8px yellow;
    -webkit-box-shadow: 0px 0px 8px yellow;
    box-shadow: 0px 0px 8px yellow;
    z-index: 20;
}

#main #timeline .entry.current span {
    background: rgba(0,0,0,0.7);
    -moz-box-shadow: 0px 0px 4px black;
    -webkit-box-shadow: 0px 0px 4px black;
    box-shadow: 0px 0px 4px black;
}

#main #timeline .entry.R { background: maroon; }
#main #timeline .entry.D { background: navy; }
#main #timeline .entry.F { background: teal; }
#main #timeline .entry.W { background: olive; }
#main #timeline .entry.DR { background: indigo; }
#main #timeline .entry.I { background: gray; }

#main #timeline .entry .prez {
    top: 2px;
    left: 5px;
}

#main #timeline .entry .vp {
    top: 14px;
    left: 5px;
}

#main #timeline .entry .num {
    top: 2px;
    right: 3px;
    padding: 2px;
    background-color: rgba(0,0,0,0.25);
    border-radius: 4px;
    pointer-events: none;
}

#main #connectors {
    display: inline-block;
    position: absolute;
    top: 0px;
    height: 100%;
    left: 370px; /* to right edge of president timeline boxes */
    width: 134px; /* to left edge of detail boxes */
/*    background: rgba(200,200,200,0.1); /* temp */
}

#main #connectors svg {
    width: 134px;
    position: absolute;
    fill: rgb(255,255,255);
    fill-opacity: 0.1;
    stroke: rgb(255,255,255);
    stroke-opacity: 0.2;
    stroke-width: 1px;
    opacity: 1;
}

#main #connectors svg.vp {
    width: 83px;
    left: 51px;
    opacity: 0.4;
}

#main #connectors svg.current {
    fill: rgb(255,255,255);
    fill-opacity: 0.3;
    stroke: rgb(255,255,255);
    stroke-opacity: 0.5;
    opacity: 1;
}

#main #connectors svg.highlight {
    fill: rgb(255,255,0);
    fill-opacity: 0.4;
}

#main #lifespan {
    display: inline-block;
    position: absolute;
    background: silver;
    border: 2px solid white;
    border-radius: 2px;
    opacity: 0.5;
    left: 461px;
    width: 18px;
    top: 100px; height: 500px; /* temp */
}

#main #lifespan.living {
    border-bottom-color: gold;
}

#main #details {
/*    background: #111; /* temp */
    display: inline-block;
    position: relative;
    max-width: 450px;
    left: 50px;
}

#main #details .detail {
    display: block;
    min-height: 16px;
    border-bottom: 1px dashed #999;
    padding-left: 4px;
}

#main #details .first.detail {
    min-height: 21px;
    margin-top: 1px;
    padding-top: 1px;
    border-top: 1px solid gray;
    border-top: 1px solid maroon;
}

#main #details .last.detail {
    margin-bottom: 1px;
    padding-bottom: 1px;
    border-bottom: 1px solid gray;
    border-bottom: 1px solid navy;
}

#main #details .current.detail {
    background: rgba(255,255,255,0.3);
}

#main #details .highlight.detail {
    background: rgba(255,255,0,0.4);
}

#details .nativity {
    font-size: small;
    margin: 0 2px;
    opacity: 0.6;
}

#main #details .detail .note {
    display: block;
    margin: 0;
    text-indent: 1em;
    cursor: pointer;
    opacity: 0.75;
}

#main #details .detail .note.icon {
    text-indent: 0.5em;
    display: inline-block;
    /*margin: 0 0.5em;*/
    opacity: 1;
}

/* TEMP -- until actually icons, make em look slightly more like it */
#main #details .detail .note.icon:before { content: '[ '; }
#main #details .detail .note.icon:after { content: ' ]'; }

#main #timeline .era {
    position: absolute;
    display: inline-block;
    left: 150px;
    width: 33px;
    background: silver;
    z-index: 0;
}
/* TBD/TODO: an eras.css ? */

#main #timeline .era.CIVILWAR,
#main #timeline .era.REVOLUTIONARYWAR,
#main #timeline .era.WHISKEYREBELLION {
    background: crimson;
}
#main #timeline .era.RECONSTRUCTION {
    background: pink;
}

#main #timeline .event {
    position: absolute;
    display: inline-block;
    z-index: 0;
    overflow: shown;
    border: 1px solid rgba(255,255,255,0.5);
    width: 154px;
}

#main #timeline .event span {
    margin: -8px 1px 0;
    background: black;
    padding: 1px;
    border-radius: 2px;
}

#main #timeline .event:hover {
    z-index: 100 !important;
    border-color: gold;
}

#main #timeline .war.event {
    left: 15px;
    width: 138px;
}

#main #timeline .state.event {
    left: 100px;
    width: 54px;
    z-index: 4;
}

#main #timeline .event span {
}

#main #timeline .event .neg {
    /* kludge -- want to move whole thing over, but CSS classes arranged stupidly */
    /* left: 15px; */
    border: 1px solid #400;
}

#main #timeline .state.event .pos {
    background: gold;
    color: black;
    border: 1px solid black;
}

#main #timeline .state.event .neg {
    background: red;
    color: black;
    border: 1px solid black;
}

#main #timeline .territory.event {
    left: 50px;
    width: 104px;
    z-index: 3;
}

#main #timeline .territory.event span {
    background: orange;
    color: black;
    border: 1px solid black;
}

#main #timeline .territory.event .neg {
    background: red;
}

#main #timeline .amendment.event {
    left: 125px;
    width: 29px;
    z-index: 6;
}


/* TODO: maybe also "alt" classes for more staggering of columns.. */

#main #note {
    position: absolute;
    display: inline-block;
    background: rgba(255,255,255,0.85);
    border: 2px solid gold;
    color: black;
    text-shadow: 1px 1px 0px white;
    z-index: 99;
    padding: 2px;
    max-width: 20em;
    -moz-box-shadow: 0 0 6px black;
    -webkit-box-shadow: 0 0 6px black;
    box-shadow: 0 0 6px black;
}

#main #note>* {
    display: block;
}

#main #note .title {
    font-size: large;
    font-weight: bold;
}

#main #note p {
    margin: 0;
}

#main #note p .date {
    font-weight: bold;
}

.hidden {
    display: none !important;
}
