/* ==========================================================================
   BookieFinder — Page & article content
   Loaded on every front-end view (it used to live in single.css, which only
   loaded for single post types, so generic pages such as Responsible
   Gambling rendered as unstyled browser defaults).

   Reading measure ~68ch, serif headings with a rule above each section,
   real list markers, styled tables, and a .bf-callout block for helplines.
   ========================================================================== */

.bf-page-body { padding: 40px 24px 72px; }

.bf-page-article { max-width: 820px; margin: 0 auto; }
.bf-page-article .bf-page-header { padding-bottom: 20px; margin-bottom: 28px; border-bottom: 2px solid var(--bf-brand); }
.bf-page-header { margin-bottom: 20px; }
.bf-page-header h1 { font-size: clamp(30px, 4.4vw, 44px); margin-bottom: 0; }
.bf-archive-sub { color: var(--bf-muted); font-size: 16px; max-width: 70ch; }

/* ---- Prose ---- */
.bf-page-content { font-size: 17px; line-height: 1.75; color: var(--bf-ink); }
.bf-page-content > * { max-width: 68ch; }
.bf-page-content > table,
.bf-page-content > .wp-block-table,
.bf-page-content > figure,
.bf-page-content > pre,
.bf-page-content > .alignwide { max-width: none; }

.bf-page-content p { margin: 0 0 18px; }
.bf-page-content > p:first-child { font-size: 19px; line-height: 1.65; color: var(--bf-ink); }
.bf-page-content strong { font-weight: 700; }
.bf-page-content a { color: var(--bf-brand); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.bf-page-content a:hover { color: var(--bf-brand-deep); text-decoration-thickness: 2px; }

.bf-page-content h2 {
	font-size: clamp(22px, 2.8vw, 28px);
	margin: 52px 0 16px;
	padding-top: 24px;
	border-top: 1px solid var(--bf-border);
	color: var(--bf-brand);
}
.bf-page-content > h2:first-child { margin-top: 0; padding-top: 0; border-top: none; }
.bf-page-content h3 { font-size: 20px; margin: 32px 0 10px; }
.bf-page-content h4 { font-size: 17px; margin: 24px 0 8px; }

/* The shop page embeds content inside an already-ruled section */
.bf-shop-section .bf-page-content { font-size: 16px; }
.bf-shop-section .bf-page-content h2 { font-size: 22px; margin-top: 32px; }

/* ---- Lists (the global reset removes markers; restore them in content) ---- */
.bf-page-content ul,
.bf-page-content ol { margin: 0 0 22px; padding: 0 0 0 1.4em; }
.bf-page-content ul { list-style: disc; }
.bf-page-content ol { list-style: decimal; }
.bf-page-content li { margin: 0 0 8px; padding-left: 4px; }
.bf-page-content li::marker { color: var(--bf-brand); }
.bf-page-content li > ul,
.bf-page-content li > ol { margin: 8px 0 0; }

/* ---- Tables ---- */
.bf-page-content table {
	width: 100%;
	margin: 8px 0 28px;
	border-collapse: collapse;
	font-size: 15.5px;
	line-height: 1.55;
	background: var(--bf-white);
	border: 1px solid var(--bf-border);
}
.bf-page-content thead th {
	text-align: left;
	font-family: var(--bf-font);
	font-size: 13px;
	font-weight: 700;
	color: var(--bf-white);
	background: var(--bf-brand);
	padding: 12px 16px;
}
.bf-page-content tbody th,
.bf-page-content tbody td { padding: 14px 16px; text-align: left; vertical-align: top; border-top: 1px solid var(--bf-border-light); }
.bf-page-content tbody tr:first-child th,
.bf-page-content tbody tr:first-child td { border-top: none; }
.bf-page-content tbody tr:nth-child(even) { background: rgba(18, 61, 44, 0.035); }
.bf-page-content tbody td:first-child,
.bf-page-content tbody th { font-weight: 700; color: var(--bf-brand); min-width: 11em; }
.bf-page-content td:last-child { overflow-wrap: anywhere; }

/* ---- Callouts & quotes ---- */
.bf-page-content .bf-callout,
.bf-page-content blockquote {
	margin: 0 0 28px;
	padding: 18px 22px;
	background: var(--bf-brand-soft);
	border-left: 4px solid var(--bf-brand);
	border-radius: 0 var(--bf-radius-md) var(--bf-radius-md) 0;
}
.bf-page-content .bf-callout > :last-child,
.bf-page-content blockquote > :last-child { margin-bottom: 0; }
.bf-page-content .bf-callout--warn { background: var(--bf-accent-soft); border-left-color: var(--bf-accent-dark); }

.bf-page-content hr { border: 0; border-top: 1px solid var(--bf-border); margin: 36px 0; }
.bf-page-content img { height: auto; border-radius: var(--bf-radius-md); }

@media (max-width: 720px) {
	.bf-page-body { padding: 28px 18px 56px; }
	.bf-page-content { font-size: 16.5px; }
	.bf-page-content > p:first-child { font-size: 18px; }
	.bf-page-content h2 { margin-top: 40px; }
	/* Wide tables scroll sideways inside themselves instead of breaking the layout */
	.bf-page-content table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
	.bf-page-content tbody td:first-child, .bf-page-content tbody th { min-width: 9em; }
}
