/* ============================================================
   SABCS Program – Print / PDF Stylesheet
   Shared between:
     - Browser preview page  (/program-print/)
     - mPDF PDF generation   (/download-program/)

   Brand tokens (explicit hex — mPDF does not support CSS custom properties):
     #004799  sabcs-blue
     #ff7640  sabcs-orange
	 #ffa480  sabcs-orange-light (added for a11y contrast)
     #12181f  sabcs-black
     #5c6773  sabcs-gray
     #d8e1eb  sabcs-gray-light
     #a4c5eb  sabcs-blue-light
   ============================================================ */

/* ---- mPDF named @page rules -------------------------------------------- */
/* Browsers silently ignore the proprietary header:/footer: descriptors,     */
/* so these rules are harmless on screen.                                    */
@page cover {
	margin: 0;
	header: _blank;
	footer: _blank;
}

@page content {
	margin-top: 28mm;
	margin-bottom: 20mm;
	margin-left: 18mm;
	margin-right: 18mm;
	header: html_program-header;
	footer: html_program-footer;
}

/* ---- Reset / base -------------------------------------------------------- */
* {
	box-sizing: border-box;
}

body {
	font-family: Arial, Helvetica, sans-serif;
	font-size: 9pt;
	color: #12181f;
	line-height: 1.45;
	margin: 0;
	padding: 0;
	background: #ffffff;
}

h1,
h2,
h3,
h4,
p {
	margin: 0;
	padding: 0;
}

img {
	border: none;
}

/* Hide mPDF page-break elements when rendered in a browser */
pagebreak,
pagebr {
	display: none !important;
}

/* ============================================================
   COVER PAGE
   ============================================================ */
.cover-logo-band {
	background-color: #ffffff;
	text-align: center;
	padding: 20mm 25mm 14mm;
	border-bottom: 3pt solid #ff7640;
}

.cover-logo {
	max-width: 220px;
	height: auto;
}

.cover-content-band {
	background-color: #004799;
	text-align: center;
	padding: 22mm 25mm 24mm;
	color: #ffffff;
}

.cover-eyebrow {
	font-size: 15pt;
	letter-spacing: 3px;
	text-transform: uppercase;
	color: #ffa480;
	margin-bottom: 6mm;
}

.cover-title {
	font-size: 21pt;
	font-weight: bold;
	color: #ffffff;
	line-height: 1.25;
	margin-bottom: 8mm;
}

.cover-year {
	font-size: 44pt;
	font-weight: bold;
	color: #ffffff;
	line-height: 1;
}

.cover-print-date {
	font-size: 11pt;
	font-weight: bold;
	margin: 9mm 0 4mm;
}

.cover-disclaimer {
	font-size: 9pt;
	line-height: 1.4;
	margin: 0 auto;
	max-width: 140mm;
}

/* ============================================================
   PROGRAM CONTENT
   ============================================================ */

/* ---- Day sections ---- */
.day-section {
	margin-bottom: 8mm;
}

.day-heading-table {
	width: 100%;
	border-collapse: collapse;
	border-bottom: 2pt solid #ff7640;
	margin-bottom: 2mm;
}

.day-heading-text-cell,
.day-heading-logo-cell {
	vertical-align: middle;
	padding-bottom: 2mm;
}

.day-heading-logo-cell {
	text-align: right;
}

.day-heading-logo {
	width: 100px;
	height: auto;
}

.day-heading {
	font-size: 14pt;
	font-weight: bold;
	color: #004799;
	margin: 0;
}

.day-date {
	font-size: 9.5pt;
	color: #5c6773;
	font-style: italic;
	margin-top: 2mm;
	margin-bottom: 5mm;
}

/* ---- Running page header / footer (mPDF) ---- */
.header-table {
	width: 100%;
	border-collapse: collapse;
}

.header-page-info-cell {
	vertical-align: middle;
	text-align: right;
	font-size: 7.5pt;
	color: #5c6773;
	padding: 0;
}

.header-rule {
	border: none;
	border-top: 1.5pt solid #004799;
	margin: 2.5mm 0 0;
}

.footer-rule {
	border: none;
	border-top: 0.5pt solid #d8e1eb;
	margin: 0 0 2mm;
}

.footer-text {
	font-size: 7.5pt;
	color: #5c6773;
	text-align: center;
}

/* ---- Session cards ---- */
.session-card {
	border: 0.5pt solid #d8e1eb;
	padding: 3.5mm 4.5mm;
	margin-bottom: 3.5mm;
	background-color: #ffffff;
	page-break-inside: avoid;
}

.session-title {
	font-size: 10pt;
	font-weight: bold;
	color: #12181f;
	margin-bottom: 2.5mm;
}

.session-meta-table {
	width: 100%;
	border-collapse: collapse;
}

.session-meta-table td {
	font-size: 8.5pt;
	padding: 0.8mm 0;
	vertical-align: top;
}

.session-meta-table td.meta-label {
	font-weight: bold;
	color: #004799;
	width: 26mm;
	white-space: nowrap;
	padding-right: 3mm;
}

.meta-value {
	color: #12181f;
}

/* ---- Presenters ---- */
.presenters-section {
	border-top: 0.5pt solid #d8e1eb;
	margin-top: 2.5mm;
	padding-top: 2.5mm;
	font-size: 8.5pt;
}

.presenters-heading {
	font-weight: bold;
	color: #004799;
	font-size: 8.5pt;
	margin-bottom: 1.5mm;
}

.presenters-group {
	margin-bottom: 1.5mm;
}

.presenters-group > strong,
.presenter-names {
	font-size: 8.5pt;
}

/* ---- Empty state ---- */
.no-sessions {
	font-size: 10pt;
	color: #5c6773;
	font-style: italic;
	text-align: center;
	padding: 20mm;
}

/* ============================================================
   BROWSER SCREEN STYLES — /program-print/ preview page
   ============================================================ */
@media screen {
	body.sabcs-program-print {
		max-width: 215.9mm;
		margin: 0 auto;
		background-color: #f2f5f7;
	}

	.program-cover {
		margin-bottom: 8mm;
	}

	.program-content {
		padding: 8mm 18mm;
		background-color: #ffffff;
	}
}

/* ============================================================
   BROWSER PRINT MEDIA — Ctrl+P / print dialog
   ============================================================ */
@media print {
	.program-cover {
		page-break-after: always;
	}

	.day-section {
		page-break-inside: avoid;
	}

	.session-card {
		page-break-inside: avoid;
	}

	/* Force background colours through browser print */
	.cover-content-band {
		-webkit-print-color-adjust: exact;
		print-color-adjust: exact;
	}
}
