p {
	margin: 1em 0;
}

p.img-attribution {
	margin-top: -1em;
	text-transform: uppercase;
}

@media screen {
	body {
		margin: 12px 27px;
		background: #d5d6d7 url('images/strip.png');
	}

	h1, h2 {
		margin: 0px;
		padding: 0px;
	}

	h1, h2, h3 {
		font-weight: bold;
		font-size: medium;
	}

	a, a:link, a:visited {
		color: #003366;
		text-decoration: none;
	}

	a:active, a:hover {
		color: #003366;
		text-decoration: underline;
	}

	a.hidden {
		color: #666;
	}

	blockquote {
		background-color: #f9f9f9;
		padding: 2mm;
		border-left: 5px solid #ccc;
	}

	pre {
		background: #f9f9f9;
		padding: 5px;
		border-top: 1px solid #ccc;
		border-bottom: 1px solid #ccc;
		font-family: monospace;
		/* overflow: auto; */
	}

	img {
		border: 1px #999999 solid;
		padding: 4px;
		background: #f7f7f7;
	}

	p.img-attribution {
		font-size: x-small;
		color: #999;
	}

	.img-attribution a {
		color: #666;
	}
}

@media only screen and (max-width: 800px) {
	body {
		margin: 0px;
		background: #fff;
	}
}

@media only screen and (max-width: 540px) {
	pre {
		white-space: pre-wrap;
	}

	img {
		padding: 0px;
		max-width: 100%;
		height: auto !important;
	}
}

@media print {
	a, a:link, a:visited {
		text-decoration: none;
		color: #000;
	}

	blockquote {
		padding: 2mm;
		border-left: 5px solid #000;
	}

	pre {
		padding: 5px 10px 5px 10px;
		margin-left: 15px;
		border: 1px dashed #000;
		font-family: monospace;
		/* overflow: auto; */
	}

	img {
		border: 1px #000 solid;
		padding: 4px;
	}

	p.img-attribution {
		font-size: small;
	}
}

/* Used by jsmath */

.typeset img {
	border: none;
	padding: 0px;
	background: none;
}

/* Navigation header */

.navigation {
	text-align: center;
	margin-bottom: 13px;
}

@media screen {
	.navigation {
		width: 84%;
		padding: 30px 30px 15px 30px;
		font-family:sans-serif;
		font-size: small;
	}

	.navigation .left {
		float: left;
	}

	.navigation .right {
		float: right;
	}
}

@media only screen and (max-width: 800px) {
	.navigation {
		padding: 30px 20px 15px 20px;
	}
}

@media only screen and (max-width: 540px) {
	.navigation {
		width: auto;
		padding: 30px 10px 15px 10px;
	}
}

@media print {
	.navigation .left, .navigation .right {
		display: none;
	}
}

/* Collection of entries */

#content.draft {
	background: #fff url('images/draft.png');
}

@media screen {
	#content {
		float: left;
		width: 72%;
		padding-bottom:10px;
		background: #fff;
	}

	.blog {
		width: 86%;
		margin: 23px;
		font-family: sans-serif;
		font-size:small;
	}

	.post-count {
		font-size: x-small;
	}

	.index {
		padding-left: 7px;
		margin-top: 30px;
	}
}

@media only screen and (max-width: 800px) {
	.blog {
		margin: 13px;
	}

	.index {
		margin-top: 20px;
	}
}

@media only screen and (max-width: 540px) {
	#content {
		width: auto;
		float: none;
	}

	.blog {
		width: auto;
		margin: 3px;
	}

	.index {
		margin-top: 10px;
	}
}

/* Entry */

.entry {
	line-height:130%;
	text-align: justify;
	padding: 7px;
	margin-bottom: 23px;
}

.body a {
	text-decoration: underline;
}

h2.title, h3.title {
	color: #000;
	text-transform: uppercase;
	text-align: left;
	margin: 0px;
}

.title a {
	color: #000;
	text-decoration: none;
}

.body table {
	border-spacing: 0px;
	text-align: left;
}

.body tr:nth-child(even) {
	background: #f7f7f7;
}

.body td {
	padding: 3px 12px;
}

.body th {
	padding: 3px 12px;
}

.float-left {
	float: left;
	margin: 0 20px 20px 0;
}

.float-right {
	float: right;
	margin: 0 0 20px 20px;
}

@media screen {
	.entry {
		color:#333;
	}

	h2.title, h3.title {
		font-size: large;
		font-weight: bold;
	}

	.title a:hover {
		color: #003366;
		text-decoration: underline;
	}

	.date {
		color: #666;
		font-weight: normal;
		margin-bottom: 15px;
	}

	.posted	{
		color: #666;

		margin-top: 25px;
		margin-bottom: 13px;

		text-align: center;
	}

	.posted-via {
		font-size: x-small;
	}
}

@media only screen and (max-width: 540px) {
	.entry {
		font-size: small;
		line-height: normal;
	}

	h2.title, h3.title {
		font-size: medium;
	}

	.date {
		font-size: small;
	}

	.posted {
		font-size: small;
	}

	.posted a {
		white-space: nowrap;
	}

	.float-left {
		max-width: 40%;
	}

	.float-right {
		max-width: 40%;
	}
}

@media print {
	.body p {
		text-indent: 15px;
	}

	h2.title, h3.title {
		margin-bottom: 5px;
		font-size: x-large;
	}

	.date {
		margin-bottom: 30px;
	}

	.posted	{
		margin-top: 25px;
		margin-bottom: 60px;

		text-align: center;
	}
}

/* Video embeds */

div.video > a {
	display: inline-block;
	position: relative;
}

span.play-button {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: url('images/play-button.png') no-repeat center;
}

span.play-button:hover {
	background-image: url('images/play-button-hover.png');
}

@media only screen and (max-width: 540px) {
	div.video > a {
		width: 100%;
	}
}

@media print {
	span.play-button {
		display: none;
	}

	div.video > p {
		display: none;
	}
}

/* Sidebar */

#sidebar img {
	border: none;
}

@media screen {
	#sidebar {
		float: right;
		position: relative;
		padding: 15px 21px 20px 15px;

		margin-left:0px;
		margin-right:0px;

		width:20%;

		background: #f7f7f7;

		font-family: sans-serif;
	}

	#sidebar h2 {
		color: #000;
		font-size: small;
		font-weight: normal;

		padding: 2px;
		margin-top: 10px;

		letter-spacing: .1em;
		border-bottom: 1px solid #999;

		text-align: center;
		text-transform: lowercase;
	}

	#sidebar ul {
		color: #333;
		font-size: small;
		font-weight: normal;

		line-height: 150%;
		padding: 2px;
		margin: 0px;

		list-style: none;
	}

	.license {
		margin-top: 10px;

		font-size: x-small;
		line-height: 120%;
	}

	.feed-icon {
		vertical-align: bottom;
		padding: 4px 7px 4px 0;
	}
}

@media only screen and (max-width: 540px) {
	#sidebar {
		float: none;
		padding: 20px;
		width: auto;
	}

	#sidebar h2, #sidebar ul, .license img {
		display: none;
	}

	#sidebar .sb-mobile {
		display: block;
	}

	.license {
		font-size: small;
		line-height: normal;
	}

	.license p {
		margin: 0px;
	}
}

@media print {
	#sidebar h2, #sidebar ul {
		display: none;
	}

	.license {
		padding-top: 10px;
		border-top: 1px solid #000;
	}

	.license p a:link:after, .license p a:visited:after {
		content: " (" attr(href) ")";
	}
}

/* Top menu */

#top-menu {
	display: none;
}

@media screen and (max-width: 540px) {
	#top-menu {
		border-top: solid 1px #ccc;
		background: #f7f7f7;
		padding: 2px;
		display: block;
		font-family: sans-serif;
		font-size: small;
		margin: 0;
	}

	#top-menu li {
		display: inline;
		padding: 0 1em 0 1em;
	}
}

/* Header */

#header h1 a {
	font-weight: bold;
	text-decoration: none;
	color: #000;
}

#header .description {
	font-family: sans-serif;
	padding-bottom: 2px;
}

@media screen {
	#header {
		border-bottom: solid 1px #ccc;
		margin-top: 0px;
		text-align: center;
	}

	#header h1 {
		font-family: 'Trebuchet MS', 'Lucida Grande', Verdana, Arial, Sans-Serif;
		font-size: 2em;
		padding-top: 2px;
	}

	#header .description {
		font-size: small;
		color: #333;
	}
}

@media only screen and (max-width: 540px) {
	#header h1 {
		font-size: 1.7em;
		padding-top: 0px;
	}
}

@media print {
	#header {
		border-bottom: solid 1px;
		text-align: center;
		padding-bottom: 15px;
		margin-bottom: 15px;
	}

	#header h1 {
		font-family: 'Trebuchet MS', 'Lucida Grande', Verdana, Arial, Sans-Serif;
		font-size: xx-large;
		margin: 0px;
	}
}

/* Comments */

@media screen {
	h3.comments	{
		font-size: small;
		border-bottom:1px solid #999;
		font-weight:bold;
		margin: 30px 7px 10px 7px;
	}

	.comment .body {
		margin-top: -1em;
	}

	#comment_error {
		color:#a00;
		border: 2px solid #f00;
		background-color: #fee;
		padding: 7px;
	}

	#comment_error p {
		margin: 0;
	}

	#comment_error p.short {
		font-size: medium;
		font-weight: bold;
		margin: 0 0 10px 0;
	}

	#comment_form {
		color:#000;
		font-weight:normal;
		line-height:120%;
		padding: 0 7px;
	}

	#comment_form input {
		border: 1px solid #ccc;
		padding: 4px;
		background: #f7f7f7;
	}

	#comment_form textarea {
		padding: 4px;
		border: 1px solid #ccc;
		background: #f7f7f7;
		width: 97%;

		font-family: sans-serif;
		color:#000;
		font-size:small;
		font-weight:normal;
		line-height:120%;
	}
}

@media only screen and (max-width: 540px) {
	h3.comments {
		font-size: medium;
	}

	#comment_form {
		line-height: normal;
	}
}

@media print {
	#comment_form, .comments {
		display: none;
	}
}

:target.entry {
	background: #faefd4;
}

/* Frames */

@media screen {
	#frame {
		background: #ffffff;
		border: 1px solid #909090;
		padding: 12px;
		position: relative;
		box-shadow: 0px 0px 3px 0px #777;
		overflow: hidden;
	}

	#banner {
		background: url('images/zxhead.png') center no-repeat #ffffff;
		height: 128px;
		box-shadow: 0px 0px 1px 0px #000 inset;
	}
}

@media only screen and (max-width: 800px) {
	#frame {
		border: none;
		padding: 0px;
	}

	#banner {
		background-position: -32px 0px;
		height: 112px;
		box-shadow: none;
		border-bottom: solid 1px #ccc;
	}
}

@media only screen and (max-width: 540px) {
	#banner {
		background-position: -86px -72px;
		height: 48px;
	}

	#frame > br {
		display: none;
	}
}

/* Search */

.search-result .posted {
	margin-bottom: 0;
	margin-top: 5px;
	text-align: left;
}

.search-result.entry {
	margin-bottom: 1px;
}

.search-result .date {
	margin-bottom: 5px;
}

@media screen {
	.search {
		border: 1px solid #ccc;
		background: #fff url('images/search.png') no-repeat center right;
		padding: 4px 25px 4px 4px;
	}

	.search input {
		background: none;
		border: none;
		width: 100%;
	}

	.search-result .body {
		font-size: small;
	}
}

@media print {
	.search {
		display: none;
	}
}
