X-Git-Url: http://git.plutz.net/?p=clickslide;a=blobdiff_plain;f=clickslide.css;h=2f5ca873257156f7a560c2e1e5acf196996a23f2;hp=e5452086ffeb458a87983499391b2443e7601e3f;hb=HEAD;hpb=c2772fd3bec6c84a3bfdcd90b2008d9381c10876 diff --git a/clickslide.css b/clickslide.css index e545208..2f5ca87 100644 --- a/clickslide.css +++ b/clickslide.css @@ -1,24 +1,82 @@ +/* === Colors === */ + +footer, +body a.toplevel:before, +body span.count, +div.slide:target:after, +div.slide:target + a, div.slide:target + a + a, +:target + a:before, :target + a + a:before +{ color: #888; } + +body +{ background-color: #AAA; + background-image: repeating-linear-gradient( to bottom right, #AAA, #999 8px); +} + +div.slide +{ background-color: #FFF; + background-image: repeating-linear-gradient( #FFF, #EEE 4px); +} + +div.slide:target:after, +footer:before, body:after +{ background-color: #EEE; + background-image: repeating-linear-gradient(#EEE, #DDD 8px); +} + +div.slide h1, div.slide h2 +{ background-color: #EEE; + background-image: repeating-linear-gradient(#EEE, #DDD 8px); +} + +div.slide pre, div.slide code +{ background-color: #DDD; + background-image: repeating-linear-gradient(#CCC, #DDD 4px); +} + +div.slide:after /* slide number on overview screen */ +{ color: #AAA; } + +/* === Overall Layout === */ + * { box-sizing: border-box; margin: 0; padding: 0; + background-position: center; + background-repeat: no-repeat; + background-size: cover; } +/* min-height: 240px */ body { font-size: 9px; } +@media(min-height: 320px) { body { font-size: 12px; } } +@media(min-height: 480px) { body { font-size: 19px; } } +@media(min-height: 720px) { body { font-size: 28px; } } +@media(min-height: 768px) { body { font-size: 30px; } } +@media(min-height: 800px) { body { font-size: 32px; } } +@media(min-height: 960px) { body { font-size: 38px; } } +@media(min-height: 1024px) { body { font-size: 41px; } } +@media(min-height: 1080px) { body { font-size: 43px; } } +@media(min-height: 2160px) { body { font-size: 86px; } } + body { font-family: sans-serif; padding: 2em 1em 6em 1em; - background-color: #555; + #background-color: #555; text-align: center; overflow-x: hidden; } -body * { text-align: left; } +body * { + text-align: left; + font-size: inherit; +} body:after { position: fixed; bottom: 0; left: 0; width: 100%; - background-color: #EEE; - height: 30pt; + height: 1.25em; content: ' '; + #background: #EEE repeating-linear-gradient(#EEE, #DDD 8px); } a.previous, a.next ,a.toplevel { @@ -29,20 +87,20 @@ footer { position: fixed; bottom: 0; left: 0; width: 100%; - font-size: 14pt; line-height: 14pt; + font-size: .75em; padding: .5em 4em .5em 12em; text-align: center; - #background-color: #EEE; - color: #888; - z-index: 3; + #color: #888; + z-index: 4; + /* footer must not have background, so slide number is not covered */ } -footer:before { +footer:before { /* fake background in case footer spans multiple lines */ content: ' '; position: absolute; top: 0; left: 0; - bottom: 28pt; + bottom: 1.5em; width: 100%; - background-color: #EEE; + #background: #EEE repeating-linear-gradient(#EEE, #DDD 8px); z-index: -1; } @@ -50,35 +108,49 @@ body a.toplevel { position: fixed; bottom: 0; left: 8em; width: 2ex; overflow: hidden; - font-size: 18pt; + font-size: .875em; padding-bottom: .25em; - color: #EEE; - z-index: 4; + color: transparent; + z-index: 5; } body a.toplevel:before { - color: #888; - content: '\2ba4' + #color: #888; + content: '\2196'; } body span.count { position: fixed; bottom: 0; left: 6.25em; - font-size: 18pt; + font-size: .875em; padding-bottom: .125em; - color: #888; - z-index: 4; + #color: #888; + z-index: 5; } /* ==== Overview Screen ==== */ +div.slide, a.nextslide { + font-size: .15625em; +} + div.slide { position: relative; display: inline-block; overflow: hidden; - width: 20em; height: 15em; - margin-left: -20em; + width: 48em; height: 30em; + margin-left: -48em; border: 1px solid black; - font-size: 6pt; +} + +div.slide:after { /* slide number */ + position: absolute; + bottom: 0; left: 0; + font-size: 15em; + line-height: 1em; + text-align: left; + content: attr(count); + padding-left: .125em; + #color: #DDD; } div.slide + a { display: none; } @@ -86,96 +158,136 @@ a.nextslide { display: inline-block; position: relative; vertical-align: top; - font-size: 6pt; - width: 20em; line-height: 15em; - color: rgba(0, 0, 0, 0); - z-index: 1; + width: 48em; line-height: 30em; + color: transparent; + z-index: 2; } -div.slide:nth-of-type(1) { margin-right: .5em; } +#div.slide:nth-of-type(1) { margin-right: .5em; } /* ==== Slide Appearance ==== */ div.slide { - background: #FFF no-repeat center; + #background: #FFF no-repeat center; text-align: center; line-height: 1.5em; } -div.slide:after { - position: absolute; - bottom: 0; left: 0; - width: 100%; - font-size: .75em; - line-height: 1.5em; - text-align: left; - content: attr(count) " /"; - padding-left: 4em; - background-color: #EEE; - color: #888; -} - div.slide > * { margin-top: 1em; - text-align: left; - max-width: 100%; - z-index: 3; + max-width: 85%; + margin-left: auto; + margin-right: auto; +} + +div.slide > *:first-child:last-child, +div.slide > h2:first-child + :last-child { + margin-top: 20%; + transform: translate(0, -50%); } div.slide h1, div.slide h2 { display: block; - background-color: #EEE; text-align: center; font-size: 1.5em; margin-top: 0; margin-bottom: 1em; - width: 100%; + width: 100%; max-width: 100%; + #background: #EEE repeating-linear-gradient(#EEE, #DDD 8px); } -div.slide h1 { - position: absolute; - top: 50%; left: 0; right: 0; - transform: translate(0, -50%); +div.slide h1, +div.slide > h1:first-child:last-child { + margin-top: 25%; + margin-bottom: 0; padding: .5em 2em; - z-index: 0; } div.slide h2 { padding: .25em 1em; } -div.slide ul, -div.slide ol { +div.slide > table { + width: 85%; +} +div.slide * table { + width: 100%; +} + +div.slide ul li { + list-style-type: square; + margin-left: 2em; +} + +div.slide ul ul, div.slide ul ol, +div.slide ol ul, div.slide ol ol { + margin-left: -1em; +} + +div.slide > ul, +div.slide > ol { width: fit-content; margin: .25em auto; } +div.slide li pre { + margin-bottom: .25em; +} + +div.slide pre, div.slide code { + #background-color: rgba(224,224,224,128); + font-family: monospace; +} +div.slide pre { + padding: 1ex; + text-align: left; + overflow: hidden; +} +div.slide code { + padding: 0 .5em; +} + /* ==== Slide Display ==== */ div.slide:target { position: fixed; - z-index: 2; + z-index: 3; top: 0; bottom: 0; left: 0; right: 0; width: auto; height: 100%; margin: 0; border: none; - font-size: 24pt; + font-size: inherit; +} + +/* slide number, footer bar*/ +div.slide:target:after { + position: absolute; + bottom: 0; left: 0; + width: 100%; + font-size: .875em; + line-height: 1.5em; + text-align: left; + content: attr(count) " /"; + padding-left: 4em; + #color: #888; + #background: #EEE repeating-linear-gradient(#EEE, #DDD 8px); } + +/* back and forth link buttons */ div.slide:target + a, div.slide:target + a + a { position: static; display: block; - font-size: 18pt; + font-size: inherit; line-height: 1em; - color: #888; + #color: #888; } :target + a:before, :target + a + a:before { display: block; position: fixed; bottom: 0; - font-size: 18pt; - color: #888; + #color: #888; padding: 0 1em .25em 1em; - z-index: 3; + z-index: 4; } :target + a:before { left: 0; } :target + a:before { content: '\22d8'; } @@ -190,6 +302,7 @@ div.slide:target + a + a { top: 0; bottom: 0; left: 0; right: 0; width: 100%; height: 100%; opacity: 0; + z-index: 1; } .uncover[type="checkbox"] + * + .uncover[type="checkbox"] { display: none; }