/* https://www.smashingmagazine.com/2015/01/designing-for-print-with-css/ */

html > body#guide-page-type-guide {
	background-color: white;
	padding-top: 0;
	padding-bottom: 0;
	padding-left: 0;
	padding-right: 0;
}

html > body > *,
.guide-page .guide-buttons,
#navbar-wrap,
#guide-header,
header.guide-page-topper,
.spons,
.gg-spoiler-overlay,
a.heading-permalink,
.guide-page-nav {
	display: none !important;
}

body > .guide-main-wrap, body > #guide-cover, body > #guide-pdf-info {
	display: block !important;
}

.guide-page-content-body p,
.guide-page-content-body figcaption,
.guide-page-content-body table,
.guide-page-content-body li {
	font-size: smaller;
}

body .guide-main-wrap > article {
	box-shadow: none;
}

.guide-page-content > .guide-page-content-inner .guide-page-content-body > *,
.fit-margins {
	max-width: 100%;
	margin-left: 0;
	margin-right: 0;
}

body .guide-main-wrap.container {
	padding: 0;
}

.guide-main-wrap .guide-page h3, .guide-main-wrap .guide-page span.guide-page-subheader {
	padding: 0;
	margin: 0;
}

#guide-cover {
	page: cover;
	text-align: center;
	background-color: black;
	background-repeat: no-repeat;
	background-size: cover;
	background-position: center center;
	width: 210mm;
	height: 297mm;
}

#guide-cover img {
	width: 210mm;
	height: 297mm;
}

#guide-pdf-info, #guide-cover {
	page-break-after: always;
	page-break-before: always;
	page-break-inside: avoid;
}

#guide-pdf-info {
	margin: 60mm auto 0 auto;
	page: guide-info;
	background-color: white;
}

#guide-pdf-info img {
	max-width: 100%;
	height: auto;
}

#guide-pdf-info h1,
#guide-pdf-info h2 {
	text-align: center;
}
#guide-pdf-info h1 span.official {
	color: red;
}

#guide-pdf-info p {
	white-space: nowrap;
	width: 480px;
	margin: 0 auto;
}
#guide-pdf-info p.info {
	background-color: #f9f9f9;
	padding: 2mm;
}
#guide-pdf-info p.copyright {
	text-align: center;
	font-size: smaller;
	width: 100%;
}
#guide-pdf-info h1 {
	margin: 1em 0;
}


.guide-main-wrap,
.guide-main-wrap .guide-page .guide-page-content {
	width: 100%;
	margin:0;
	border-radius: 0;
	padding: 0;
}

.guide-main-wrap .guide-page .guide-page-content {
	page-break-before: avoid;
}

/* Don't break in the middle of image boxes and such */
.guide-page-content-inner .guide-page-content-body div,
.guide-page-content-inner .guide-page-content-body img,
.guide-page-content-inner .guide-page-content-body h1,
.guide-page-content-inner .guide-page-content-body h2,
.guide-page-content-inner .guide-page-content-body h3,
.guide-page-content-inner .guide-page-content-body h4,
.guide-page-content-inner .guide-page-content-body h5,
.guide-page-content-inner .guide-page-content-body h6,
.guide-page-content-inner .guide-page-content-body tr {
	page-break-inside: avoid;
}

/* Don't show the "Game Overview" header */
.guide-main-wrap > h3 {
	display: none;
}

body .guide-page-content > .guide-page-content-inner .guide-page-content-body > .image-block {
	max-width: 75%;
	margin-left: auto;
	margin-right: auto;
}

.guide-main-wrap .guide-page .guide-page-content .image-block-2 br {
	display: none;
}

.guide-main-wrap .guide-page .guide-page-content .image-block-2 > .image-block-inner > img {
	width: calc(50% - 0.5mm);
	margin-right: 1mm;
	float: left;
}

.guide-main-wrap .guide-page .guide-page-content .image-block-2 > .image-block-inner > img:last-child {
	margin-right: 0;
}

.guide-page-content .image-block img,
.guide-page-content .image-block picture img {
	position: relative !important;
}

.guide-main-wrap .guide-page .guide-page-content .image-block2-multi {
	display: none;
}

.image-block-1.has-caption,
.image-block-2.has-caption,
.image-block-multi.has-caption {
	margin-bottom: 1rem;
}

.has-caption figcaption, .image-block-multi figcaption {
	padding: 1em 2em;
}

figure {
	margin-bottom: 0;
}

.guide-main-wrap h1 {
	font-size: 1rem;
	color: darkgray;
/* 	page-break-before: always; */
	margin-bottom: 0;
	font-weight: normal;
}

.guide-main-wrap h2 {
	font-size: 0.8rem;
	color: darkgray;
	font-weight: normal;
}

.guide-main-wrap h3 {
	text-align: left;
	border-bottom-style: solid;
	border-bottom-color: gray;
	border-bottom-width: 1px;
}

h1, h2, h3, h4, h5, h6 {
	page-break-after: avoid;
}

.guide-main-wrap .guide-page .guide-page-content .achievement.init {
	display: block;
	position: relative;
}

.guide-main-wrap .guide-page .guide-page-content .achievement.init .achievement-desc {
	position: absolute;
	top: 50%;
	left: 110px;
	transform: translateY(-50%);
 }

.guide-main-wrap .guide-page .guide-page-achievement-stats {
	text-align: right;
	margin-left: 1em;
	position: absolute;
	width: 36px;
	height: 36px;
	position: absolute;
	right: 0;
	top: 50%;
	margin-top: -18px;
}
.guide-main-wrap .guide-page .guide-page-achievement-stats img {
	height: 36px;
	width: 36px;
	float: none;
	margin-bottom: 3px;
}
.guide-main-wrap .guide-page .achievement-gamescore {
	font-weight: 600;
	font-size: 18px;
}
.guide-main-wrap .guide-page .achievement-gamescore::before,
.guide-main-wrap .guide-page .achievement-gamescore::before {
	content: "G";
	color: #fff;
	background: #000;
	border-radius: 50%;
	width: 22px;
	height: 22px;
	line-height: 22px;
	display: inline-block;
	text-align: center;
	font-size: 15px;
	margin-right: 3px;
}

.guide-page-content div.video {
	display: none;
}

/* .guide-main-wrap .guide-page .guide-page-content .video.init a {
	display: block;
	overflow: hidden;
}

.guide-main-wrap .guide-page .guide-page-content .video.init a img {
	max-width: 50%;
	opacity: 1;
	float: left;
}

.guide-main-wrap .guide-page .guide-page-content .video.init a .video-desc {
	float: left;
	width: 50%;
} */

.guide-main-wrap .guide-page .guide-page-content div.tip > div > *:last-child,
.guide-main-wrap .guide-page .guide-page-content div.note > div > *:last-child,
.guide-main-wrap .guide-page .guide-page-content div.dyk > div > *:last-child,
.guide-main-wrap .guide-page .guide-page-content div.warning > div > *:last-child,
.guide-main-wrap .guide-page .guide-page-content div.pull-quote > div > *:last-child,
.guide-main-wrap .guide-page .guide-page-content div.info > div > *:last-child,
.guide-main-wrap .guide-page .guide-page-content div.success > div > *:last-child {
	margin-bottom: 0;
}

#toc ul li a {
	color: #0b4d85;
}

#toc ul li a::after {
  content: leader('.') target-counter(attr(href), page);
}

/* Tables aren't processed by footable and so need to have some of its styling
	re-added */
.guide-main-wrap .guide-page .guide-page-content table {
	border-collapse: collapse;
	margin-bottom: 1em;
	width: 100%;
}
.guide-main-wrap .guide-page .guide-page-content table th,
.guide-main-wrap .guide-page .guide-page-content table td {
	padding: 8px;
	border: 1px solid #ddd;
}

/* Disable table niceties */
.guide-main-wrap .guide-page .guide-page-content table thead tr.table-search-row,
.guide-main-wrap .guide-page .guide-page-content table tfoot {
	display: none;
}

/* Show all table rows */
.guide-main-wrap .guide-page .guide-page-content > .gg-table > table > tbody > tr.hide-row {
	display: table-row;
}

/* New header stuff */
.guide-main-wrap header.guide-page-topper {
	background-color: transparent;
}

h3.break-above,
h2.break-above,
h1.break-above {
	page-break-before: always;
}

@page {
	size: a4;
	margin: 1cm;
}

@page:first {
	margin: 0;
}

@page cover {
	@bottom-right {
		content: none;
		margin: 0;
	}
}

@page guide-info {
	margin: 0;
	border-style: solid;
	border-width: 5mm;
	border-color: black;
}

@page:right {
  @bottom-right {
    content: counter(page);
  }
}

@page:left {
  @bottom-left {
    content: counter(page);
  }
}
