/* ==========================================================================
   Content: Gutenberg prose (posts + pages), archives, search, 404
   ========================================================================== */

.container--narrow { max-width: calc(var(--container-narrow) + 2 * var(--gutter)); }

/* ---------- Page header (pages, archives) ---------- */
.entry-header { padding-top: 56px; padding-bottom: 32px; }
.entry-title { font-size: clamp(2rem, 4.6vw, 3.25rem); line-height: 1.08; letter-spacing: var(--tracking-tight); }

.breadcrumbs { margin-bottom: 20px; font-size: .78rem; color: var(--color-text-subtle); }
.breadcrumbs a { color: var(--color-indigo); }

/* ---------- Prose (Gutenberg content) ---------- */
.entry-content {
	padding-bottom: var(--space-2xl);
	font-size: 1.0625rem;
	line-height: 1.78;
	color: var(--color-text-prose);
}
.entry-content > * { margin-top: 0; margin-bottom: 22px; }
.entry-content > *:last-child { margin-bottom: 0; }

.entry-content h2,
.entry-content h3,
.entry-content h4 { color: var(--color-text); scroll-margin-top: calc(var(--header-height) + 32px); }
.entry-content h2 { margin: 52px 0 18px; font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.2; letter-spacing: -.025em; }
.entry-content h3 { margin: 36px 0 12px; font-size: 1.3125rem; letter-spacing: -.02em; }
.entry-content h4 { margin: 28px 0 10px; font-size: 1.125rem; }
.entry-content > h2:first-child { margin-top: 0; }

.entry-content a {
	color: var(--color-indigo);
	font-weight: 600;
	border-bottom: 1.5px solid rgba(83, 74, 183, .3);
	transition: border-color .2s;
}
.entry-content a:hover { border-color: var(--color-indigo); }
.entry-content strong { color: var(--color-text); font-weight: 600; }

.entry-content ul,
.entry-content ol { padding-left: 1.3em; }
.entry-content li + li { margin-top: .5em; }
.entry-content li::marker { color: var(--color-accent); font-weight: 600; }

.entry-content hr,
.entry-content .wp-block-separator { margin: 44px 0; border: 0; border-top: 1px solid var(--color-border); opacity: 1; }

/* Images */
.entry-content figure { margin: 34px 0; }
.entry-content img { height: auto; border-radius: var(--radius-lg); }
.entry-content figcaption,
.entry-content .wp-element-caption {
	margin-top: 12px;
	font-size: .875rem;
	line-height: 1.55;
	color: var(--color-text-subtle);
	text-align: center;
}

/* Quote */
.entry-content blockquote {
	margin: 30px 0;
	padding: 20px 24px;
	border-left: 3px solid var(--color-accent);
	border-radius: 0 var(--radius-md) var(--radius-md) 0;
	background: var(--color-lavender);
	color: var(--color-deep);
}
.entry-content blockquote p:last-child { margin-bottom: 0; }

/* Code */
.entry-content code { padding: 2px 6px; border-radius: 6px; background: var(--color-lavender); font-family: var(--font-mono); font-size: .86em; }
.entry-content pre { overflow-x: auto; padding: 22px 24px; border-radius: var(--radius-md); background: var(--color-dark); color: #e8e5f5; font-family: var(--font-mono); font-size: .875rem; line-height: 1.7; }
.entry-content pre code { padding: 0; background: none; }

/* Tables: horizontal scroll on narrow screens; first row styled as header when there is no <thead> */
.entry-content .wp-block-table {
	overflow-x: auto;
	border: 1px solid var(--color-border);
	border-radius: var(--radius-md);
	background: var(--color-surface);
	-webkit-overflow-scrolling: touch;
}
/* Columns size to their content (max ~240px, then wrap); wide tables scroll horizontally. */
.entry-content table { width: max-content; min-width: 100%; border-collapse: collapse; font-size: .875rem; line-height: 1.5; }
.entry-content .wp-block-table table.has-fixed-layout { table-layout: auto; width: max-content; }
.entry-content .wp-block-table th,
.entry-content .wp-block-table td,
.entry-content th,
.entry-content td {
	max-width: 240px;
	padding: 12px 14px;
	border: 0;
	border-bottom: 1px solid var(--color-border-soft);
	text-align: left;
	vertical-align: top;
	word-break: normal;
	overflow-wrap: normal;
	hyphens: manual;
}
.entry-content tr:last-child td { border-bottom: 0; }
.entry-content thead th,
.entry-content table:not(:has(thead)) tr:first-child td {
	background: var(--color-lavender);
	color: var(--color-deep);
	font-family: var(--font-heading);
	font-weight: 600;
	white-space: nowrap;
}
.entry-content tbody tr:nth-child(even) td { background: rgba(247, 246, 251, .6); }

/* Wide / full alignments */
.entry-content .alignwide { width: min(1044px, 100vw - 2 * var(--gutter)); max-width: none; margin-left: 50%; transform: translateX(-50%); }
.entry-content .alignfull { width: 100vw; max-width: none; margin-left: 50%; transform: translateX(-50%); }

/* ---------- Editorial patterns used in posts (class names from the editor) ---------- */

/* Lead paragraph: <p class="pa-lead"> */
.entry-content .pa-lead { font-size: 1.1875rem; line-height: 1.65; color: var(--color-text-muted); }

/* Info / takeaways box: group "Najważniejsze wnioski" (.pa-box .pa-takeaways) */
.entry-content .pa-box {
	position: relative;
	margin: 12px 0 38px;
	padding: 24px 26px 24px 64px;
	border: 1px solid rgba(127, 119, 221, .3);
	border-radius: var(--radius-md);
	background: var(--color-lavender);
	font-size: 1rem;
	line-height: 1.65;
}
.entry-content .pa-box::before {
	content: "";
	position: absolute;
	top: 26px;
	left: 24px;
	width: 22px;
	height: 22px;
	background: var(--color-indigo);
	-webkit-mask: var(--icon-info) center / contain no-repeat;
	mask: var(--icon-info) center / contain no-repeat;
}
.entry-content .pa-box > * { margin-bottom: 12px; }
.entry-content .pa-box > *:last-child { margin-bottom: 0; }
.entry-content .pa-box h2,
.entry-content .pa-box h3 { margin: 0 0 12px; font-size: 1.125rem; letter-spacing: -.01em; }
.entry-content .pa-box ul { padding-left: 1.1em; }

/* Checklist: <ul class="pa-check"> */
.entry-content ul.pa-check { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; padding: 0; list-style: none; }
.entry-content ul.pa-check li { position: relative; margin: 0; padding-left: 34px; }
.entry-content ul.pa-check li::before {
	content: "";
	position: absolute;
	top: 3px;
	left: 0;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: var(--color-lavender) var(--icon-check) center / 13px no-repeat;
}

/* Prompt: group "Prompt" (.pa-prompt) */
.entry-content .pa-prompt {
	position: relative;
	margin: 26px 0 30px;
	padding: 40px 28px 24px;
	border-radius: var(--radius-md);
	background: var(--color-dark);
	color: #e8e5f5;
	font-family: var(--font-mono);
	font-size: .9rem;
	line-height: 1.75;
}
.entry-content .pa-prompt::before {
	content: "prompt";
	position: absolute;
	top: 14px;
	right: 18px;
	font-size: .6875rem;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--color-on-dark-faint);
}
.entry-content .pa-prompt p { margin: 0; }
.entry-content .pa-prompt p + p { margin-top: 12px; }
.entry-content .pa-prompt strong { color: #e8e5f5; font-weight: 500; }

/* ---------- Rank Math FAQ block ---------- */
.entry-content .rank-math-block { margin: 12px 0 34px; }
.entry-content .rank-math-list { display: flex; flex-direction: column; gap: 12px; }
.entry-content .rank-math-list-item {
	padding: 20px 24px;
	border: 1px solid var(--color-border);
	border-radius: var(--radius-md);
	background: var(--color-surface);
}
.entry-content .rank-math-question { margin: 0 0 8px; font-size: 1.0625rem; line-height: 1.4; letter-spacing: -.01em; }
.entry-content .rank-math-question strong { font-weight: 700; }
.entry-content .rank-math-answer { font-size: .98rem; line-height: 1.7; }
.entry-content .rank-math-answer p { margin: 0; }
.entry-content .rank-math-answer p + p { margin-top: 10px; }

/* ---------- Archives / search / 404 ---------- */
.archive-header { padding-top: 56px; padding-bottom: 40px; }
.archive-title { font-size: var(--fs-h2); letter-spacing: var(--tracking-tight); }
.archive-desc { max-width: 640px; margin-top: 14px; color: var(--color-text-muted); }
.archive-header .search-bar { margin-top: 28px; }
.archive-list { padding-bottom: var(--space-section); }
.archive-empty { color: var(--color-text-muted); }



.error-404 { padding-bottom: var(--space-section); }
.error-404__home { margin-top: 24px; color: var(--color-indigo); }
