/* ─────────────────────────────────────────────────────────────────────────────
 * Stories — shared by the Stories page feed and the story article.
 * Ported from the React Stories page: its injected stylesheet and inline
 * styles, turned into classes. Gold here is #D4AF37.
 * ───────────────────────────────────────────────────────────────────────────── */

.is-layout-flow > .st-hero,
.is-layout-flow > .st-wrap,
.is-layout-flow > .st-article { margin-block-start: 0; }

/* ── Shared pieces ── */
.st-badge {
	display: inline-block; font-family: Inter, system-ui, sans-serif; font-size: 0.65rem; font-weight: 700;
	letter-spacing: 0.28em; text-transform: uppercase; color: var(--st-cat, #D4AF37);
	border: 1px solid var(--st-cat, #D4AF37); border-radius: 2px; padding: 3px 9px; line-height: 1; opacity: 0.9;
}
.st-author { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.st-author-name { font-family: Inter, system-ui, sans-serif; font-size: 0.76rem; font-weight: 700; color: rgba(248,250,252,0.72); margin: 0; line-height: 1.3; }
.st-author-role { font-family: Inter, system-ui, sans-serif; font-size: 0.65rem; color: rgba(248,250,252,0.48); margin: 1px 0 0; line-height: 1; }
.st-author-sep { width: 1px; height: 24px; background: rgba(255,255,255,0.15); flex-shrink: 0; }
.st-author-meta { font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; color: rgba(248,250,252,0.48); margin: 0; }
.st-author-dot { width: 3px; height: 3px; border-radius: 50%; background: rgba(248,250,252,0.48); flex-shrink: 0; }
.st-read {
	display: inline-flex; align-items: center; gap: 7px; font-family: Inter, system-ui, sans-serif; font-size: 0.72rem;
	font-weight: 700; letter-spacing: 0.24em; text-transform: uppercase; color: #D4AF37; text-decoration: none;
	transition: gap 0.2s ease, opacity 0.2s ease;
}
.st-card:hover .st-read, .st-read:hover { gap: 12px; opacity: 0.80; }
.st-back {
	display: inline-flex; align-items: center; gap: 8px; font-family: Inter, system-ui, sans-serif; font-size: 0.72rem;
	font-weight: 700; letter-spacing: 0.24em; text-transform: uppercase; color: rgba(212,175,55,0.75);
	text-decoration: none; transition: color 0.2s ease, gap 0.2s ease; line-height: 1.5;
}
.st-back:hover { color: #D4AF37; gap: 12px; }

/* ── Stories page hero ── */
.st-hero { position: relative; height: clamp(360px, 52vh, 580px); overflow: hidden; background: #0B1120; }
.st-hero > img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; display: block; }
.st-hero-shade { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(11,17,32,0.50) 0%, rgba(11,17,32,0.30) 40%, rgba(11,17,32,0.85) 100%); }
.st-hero-text { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: clamp(32px, 5vw, 64px); max-width: 88rem; margin: 0 auto; box-sizing: border-box; }
.st-hero-eyebrow { font-family: Inter, system-ui, sans-serif; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.34em; text-transform: uppercase; color: #D4AF37; margin: 0 0 14px; }
.st-hero-title { font-family: 'Cormorant Garamond', Georgia, serif; font-style: italic; font-weight: 700; font-size: clamp(2.8rem, 7vw, 5.5rem); color: #F8FAFC; margin: 0 0 18px; line-height: 1.0; }
.st-hero-body { font-family: Inter, system-ui, sans-serif; font-size: clamp(0.82rem, 1.3vw, 0.96rem); line-height: 1.70; color: rgba(248,250,252,0.62); max-width: 52ch; margin: 0; }
.st-rule { width: 52px; height: 2px; background: linear-gradient(to right, #D4AF37, transparent); border-radius: 2px; margin-top: 24px; }

/* ── Layout ── */
.st-wrap { max-width: 90rem; margin: 0 auto; padding: clamp(48px, 7vw, 80px) clamp(20px, 4vw, 48px); box-sizing: border-box; }
.st-layout { display: flex; gap: clamp(32px, 4vw, 56px); align-items: flex-start; }
.st-feed { flex: 1; min-width: 0; scroll-margin-top: 90px; }
.st-sidebar { width: 100%; max-width: 280px; flex-shrink: 0; }
@media (max-width: 900px) {
	.st-layout { flex-direction: column; }
	.st-sidebar { width: 100%; max-width: 100%; margin-top: 52px; }
	.st-feed { width: 100%; }
}

.st-feed-head { display: flex; align-items: center; gap: 14px; margin-bottom: 28px; flex-wrap: wrap; }
.st-feed-label { font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.34em; text-transform: uppercase; color: rgba(212,175,55,0.55); margin: 0; flex-shrink: 0; }
.st-clear { display: inline-flex; align-items: center; gap: 5px; font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: #0B1120; background: #D4AF37; border: none; border-radius: 3px; padding: 3px 9px; cursor: pointer; flex-shrink: 0; line-height: 1.6; }
.st-feed-line { flex: 1; height: 1px; background: rgba(212,175,55,0.13); }
.st-feed-count { font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; color: rgba(248,250,252,0.36); flex-shrink: 0; }
.st-clear[hidden], .st-feed-count[hidden], .st-card[hidden], .st-more[hidden] { display: none; }

.st-feed-items { transition: opacity 0.35s ease; display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.st-feed-items.is-fading { opacity: 0; }
@media (max-width: 680px) { .st-feed-items { grid-template-columns: 1fr; } }

.st-more { grid-column: 1 / -1; display: flex; align-items: center; gap: 16px; margin: 0; }
.st-more p { font-family: Inter, system-ui, sans-serif; font-size: 0.65rem; font-weight: 700; letter-spacing: 0.30em; text-transform: uppercase; color: rgba(212,175,55,0.45); margin: 0; flex-shrink: 0; }
.st-more div { flex: 1; height: 1px; background: rgba(212,175,55,0.10); }

/* ── Story card (grid) ── */
.st-card {
	display: flex; flex-direction: column; border-radius: 12px; overflow: hidden;
	border: 1px solid rgba(212,175,55,0.14); background: rgba(255,255,255,0.02); cursor: pointer;
	text-decoration: none; color: inherit;
	transition: transform 0.30s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.30s ease, border-color 0.28s ease;
}
.st-card:hover {
	transform: translateY(-4px) scale(1.012);
	box-shadow: 0 18px 48px rgba(0,0,0,0.52), 0 0 0 1px rgba(212,175,55,0.22), 0 6px 20px rgba(212,175,55,0.09);
	border-color: rgba(212,175,55,0.38);
}
.st-card-img { height: 200px; overflow: hidden; flex-shrink: 0; position: relative; }
.st-card-img img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; transition: transform 0.55s ease; }
.st-card-shade { position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 45%, rgba(11,17,32,0.72) 100%); }
.st-card-imgbadge { position: absolute; bottom: 14px; left: 16px; }
.st-card-body { flex: 1; padding: 20px 20px 24px; display: flex; flex-direction: column; gap: 12px; }
.st-card-top { display: none; align-items: center; gap: 12px; flex-wrap: wrap; }
.st-card-featured { font-family: Inter, system-ui, sans-serif; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(248,250,252,0.35); }
.st-card-title { font-family: Inter, system-ui, sans-serif; font-weight: 700; font-size: clamp(0.92rem, 1.5vw, 1.08rem); color: #F8FAFC; margin: 0; line-height: 1.3; }
.st-card-excerpt { font-family: Inter, system-ui, sans-serif; font-size: 0.95rem; line-height: 1.72; color: rgba(248,250,252,0.54); margin: 0; flex: 1; }
.st-card-rule { width: 24px; height: 1px; background: rgba(212,175,55,0.22); }
.st-card-foot { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.st-read-long { display: none; }

/* ── Featured card: the same card, laid out wide ── */
.st-card.is-featured { grid-column: 1 / -1; flex-direction: row; border-radius: 14px; border-color: rgba(212,175,55,0.18); margin-bottom: 8px; }
.st-card.is-featured:hover {
	transform: translateY(-4px);
	box-shadow: 0 22px 56px rgba(0,0,0,0.55), 0 0 0 1px rgba(212,175,55,0.28), 0 8px 24px rgba(212,175,55,0.11);
	border-color: rgba(212,175,55,0.45);
}
.st-card.is-featured .st-card-img { width: 44%; height: auto; min-height: 340px; }
.st-card.is-featured .st-card-shade { background: linear-gradient(to right, transparent 70%, rgba(11,17,32,0.55) 100%); }
.st-card.is-featured .st-card-imgbadge, .st-card.is-featured .st-card-rule, .st-card.is-featured .st-read-short { display: none; }
.st-card.is-featured .st-card-top { display: flex; }
.st-card.is-featured .st-read-long { display: inline; }
.st-card.is-featured .st-card-body { padding: clamp(24px, 3.5vw, 40px); justify-content: center; gap: 16px; }
.st-card.is-featured .st-card-title { font-size: clamp(1.1rem, 2.2vw, 1.55rem); line-height: 1.25; }
.st-card.is-featured .st-card-excerpt { font-size: clamp(0.80rem, 1.2vw, 0.90rem); line-height: 1.75; color: #FFFFFF; flex: none; }
.st-card.is-featured .st-card-foot { flex-direction: column; align-items: flex-start; gap: 16px; }
@media (max-width: 680px) {
	.st-card.is-featured { flex-direction: column; }
	.st-card.is-featured .st-card-img { width: 100%; height: 220px; min-height: 0; }
}

.st-empty { font-family: 'Lora', Georgia, serif; font-size: 1rem; color: rgba(255, 255, 255, 0.82); margin: 0; }

/* ── Pagination ── */
.st-pages { display: flex; align-items: center; gap: 20px; margin-top: 52px; padding-top: 36px; border-top: 1px solid rgba(212,175,55,0.12); }
.st-pages[hidden] { display: none; }
.st-page-btn {
	display: inline-flex; align-items: center; gap: 8px; font-family: Inter, system-ui, sans-serif; font-size: 0.75rem; font-weight: 700;
	letter-spacing: 0.22em; text-transform: uppercase; color: rgba(248,250,252,0.70); background: rgba(255,255,255,0.04);
	border: 1px solid rgba(212,175,55,0.20); border-radius: 4px; padding: 11px 22px; cursor: pointer;
	transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.st-page-btn:hover:not(:disabled) { color: #D4AF37; border-color: rgba(212,175,55,0.55); background: rgba(212,175,55,0.06); }
.st-page-btn:disabled { opacity: 0.28; cursor: not-allowed; }
.st-page-nums { flex: 1; display: flex; justify-content: center; gap: 8px; }
.st-page-num { width: 32px; height: 32px; border-radius: 50%; border: 1px solid rgba(212,175,55,0.22); background: transparent; font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; font-weight: 700; color: rgba(248,250,252,0.42); cursor: pointer; transition: all 0.2s ease; padding: 0; }
.st-page-num.is-current { border-color: #D4AF37; background: rgba(212,175,55,0.14); color: #D4AF37; }

/* ── Sidebar ── */
.st-side-label { font-family: Inter, system-ui, sans-serif; font-size: 0.70rem; font-weight: 700; letter-spacing: 0.38em; text-transform: uppercase; color: #D4AF37; margin: 0 0 20px; }
.st-side-box { background: rgba(255,255,255,0.025); border: 1px solid rgba(212,175,55,0.12); border-radius: 10px; padding: 18px 20px; }
.st-side-box + .st-side-box { margin-top: 28px; }
.st-side-title { font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.30em; text-transform: uppercase; color: rgba(248,250,252,0.32); margin: 0 0 14px; }
.st-cat {
	display: flex; align-items: center; justify-content: space-between; font-family: Inter, system-ui, sans-serif; font-size: 0.72rem;
	color: rgba(248,250,252,0.58); padding: 10px 0; border: none; border-bottom: 1px solid rgba(212,175,55,0.09);
	width: 100%; text-align: left; cursor: pointer; background: none; transition: color 0.2s ease;
}
.st-cat:last-child { border-bottom: none; }
.st-cat:hover:not(:disabled) { color: #D4AF37; }
.st-cat:disabled { cursor: default; }
.st-cat.is-active { background: rgba(212,175,55,0.10); border-radius: 6px; color: #D4AF37; }
.st-cat-name { display: flex; align-items: center; gap: 8px; }
.st-cat-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--st-cat, #D4AF37); flex-shrink: 0; }
.st-cat.is-active .st-cat-dot { background: #D4AF37; }
.st-cat-count { font-family: Inter, system-ui, sans-serif; font-size: 0.72rem; font-weight: 700; color: rgba(212,175,55,0.45); margin-left: 8px; }
.st-cat.is-active .st-cat-count { color: #D4AF37; }
.st-recent { display: block; width: 100%; text-align: left; border-bottom: 1px solid rgba(212,175,55,0.07); padding: 12px 0; text-decoration: none; transition: opacity 0.2s ease; }
.st-recent:last-child { border-bottom: none; }
.st-recent:hover { opacity: 0.75; }
.st-recent-title { font-family: Inter, system-ui, sans-serif; font-size: 0.76rem; font-weight: 600; color: #F8FAFC; margin: 0 0 3px; line-height: 1.35; }
.st-recent-date { font-family: Inter, system-ui, sans-serif; font-size: 0.75rem; color: rgba(248,250,252,0.38); margin: 0; }

/* ── Article ── */
.st-article { background: #0B1120; min-height: 100vh; }
.st-art-hero { position: relative; height: clamp(280px, 45vw, 520px); overflow: hidden; }
.st-art-hero img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }
.st-art-hero-shade { position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 55%, rgba(11,17,32,0.82) 100%); }
.st-art-back { position: absolute; top: 28px; left: clamp(20px, 5vw, 48px); z-index: 5; }
.st-art-col { max-width: 780px; margin: 0 auto; box-sizing: border-box; }
.st-art-head { padding: clamp(32px, 5vw, 52px) clamp(20px, 5vw, 40px) 0; }
.st-art-meta { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.st-art-readtime { font-family: Inter, system-ui, sans-serif; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: rgba(248,250,252,0.38); }
.st-art-title { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 700; font-size: clamp(1.8rem, 4vw, 3rem); line-height: 1.15; color: #F8FAFC; margin: 0 0 28px; }
.st-art-rule { width: 52px; height: 2px; background: linear-gradient(to right, #D4AF37, transparent); margin: 28px 0 36px; }
.st-art-body { padding: 0 clamp(20px, 5vw, 40px) clamp(64px, 10vw, 96px); }

/* The article as written in the classic editor */
.st-content p { font-family: Inter, system-ui, sans-serif; font-size: clamp(0.9rem, 1.5vw, 1.02rem); line-height: 1.9; color: #FFFFFF; margin: 0 0 22px; }
.st-content h2 { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 700; font-size: clamp(1.25rem, 2.5vw, 1.7rem); color: #F8FAFC; margin: 44px 0 18px; line-height: 1.2; }
.st-content h3 { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 700; font-size: clamp(1.1rem, 2vw, 1.35rem); color: #F8FAFC; margin: 36px 0 14px; line-height: 1.25; }
.st-content a { color: #D4AF37; text-decoration: underline; text-underline-offset: 3px; }
/* House standard: Bold in the editor is set in gold. */
.st-content strong, .st-content b { color: #D4AF37; font-weight: 600; }
.st-content ul, .st-content ol { font-family: Inter, system-ui, sans-serif; font-size: clamp(0.9rem, 1.5vw, 1.02rem); line-height: 1.9; color: #fff; margin: 0 0 22px; padding-left: 1.3em; }
/* The global reset strips list markers, so a bulleted list in a story read as
   indented paragraphs with no structure. Gold marker, like every other mark
   on the site. */
.st-content ul { list-style: disc; }
.st-content ol { list-style: decimal; }
.st-content ul ul { list-style: circle; }
.st-content li { margin: 0 0 0.6em; padding-left: 0.2em; }
.st-content li::marker { color: #D4AF37; }
.st-content li > ul, .st-content li > ol { margin: 0.5em 0 0; }
.st-content figure, .st-content .wp-caption { margin: 36px 0; width: auto !important; max-width: 100%; }
/* A photograph in the text is shown whole. It used to be stretched to the
   full width and cropped to 480px, which cut the handshake out of a portrait
   and the sky off a landscape. An upright one is held to a column instead. */
.st-content img { width: 100%; height: auto; display: block; border-radius: 8px; }
.st-content img.is-upright { width: auto; max-width: min(100%, 560px); margin-left: auto; margin-right: auto; }
.st-content figure, .st-content .wp-caption { text-align: center; }
.st-content figcaption, .st-content .wp-caption-text { font-family: Inter, system-ui, sans-serif; font-size: 0.72rem; color: rgba(248,250,252,0.40); margin-top: 10px; text-align: center; font-style: italic; }
.st-content blockquote {
	margin: 36px 0; background: rgba(212,175,55,0.04); border: 1px solid rgba(212,175,55,0.20); border-radius: 8px;
	padding: clamp(20px,3vw,32px) clamp(24px,4vw,40px); position: relative;
}
.st-content blockquote::before { content: '"'; position: absolute; top: 8px; left: 20px; font-family: Georgia, serif; font-size: 3rem; color: rgba(212,175,55,0.20); line-height: 1; }
.st-content blockquote p { font-family: 'Lora', Georgia, serif; font-size: clamp(1rem, 1.8vw, 1.18rem); color: #FFFFFF; line-height: 1.75; margin: 0 0 14px; padding-top: 16px; }
.st-content blockquote p + p { padding-top: 0; }
.st-content blockquote cite { font-family: Inter, system-ui, sans-serif; font-size: 0.68rem; font-style: normal; font-weight: 700; letter-spacing: 0.12em; color: rgba(212,175,55,0.65); }
.st-end { margin: 52px 0 0; display: flex; align-items: center; gap: 18px; }
.st-end span:not(.st-end-dot) { flex: 1; height: 1px; background: rgba(212,175,55,0.18); }
.st-end-dot { width: 6px; height: 6px; border-radius: 50%; background: #D4AF37; opacity: 0.55; }
.st-byline { margin-top: 36px; padding: 24px 28px; background: rgba(212,175,55,0.05); border: 1px solid rgba(212,175,55,0.25); border-radius: 8px; }
.st-byline-name { font-family: Inter, system-ui, sans-serif; font-size: 0.75rem; font-weight: 700; color: #D4AF37; margin: 0 0 4px; }
.st-byline-role { font-family: Inter, system-ui, sans-serif; font-size: 0.72rem; color: rgba(248,250,252,0.52); margin: 0; }
.st-art-foot { margin-top: 48px; }

/* The React read link sits in a 24px line; keep the same height. */
.st-read { min-height: 24px; }

/* ── On a phone ───────────────────────────────────────────────────────────── */

@media (max-width: 639px) {
	/* Both back links stood 17px tall. They are the way out of a story, so
	   they are worth a thumb's width. The padding grows the hit area without
	   moving the text. */
	.st-back {
		display: inline-block;
		padding: 13px 0;
	}
}

/* ── Quotations in a story ────────────────────────────────────────────────── */
/* museum_elmina_story_quotes() has been adding the st-quote class since the
   stories were ported, and nothing has ever styled it, so a quotation in a
   story rendered as two ordinary paragraphs. Reported on 23 October 2026.
   These are the heritage pages' values, so a quotation reads the same wherever
   it appears on the site. */

.st-content .st-quote,
.st-content blockquote {
	position: relative;
	margin: 30px 0;
	background: rgba(234, 179, 8, 0.07);
	border: 1px solid rgba(234, 179, 8, 0.32);
	border-left: 4px solid #EAB308;
	border-radius: 8px;
	padding: clamp(22px, 2.6vw, 30px) clamp(22px, 3vw, 32px) clamp(20px, 2.4vw, 26px);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}

.st-content .st-quote::before,
.st-content blockquote::before {
	content: '\201C';
	position: absolute;
	top: 2px;
	left: 18px;
	font-family: Georgia, serif;
	font-size: 3.4rem;
	color: rgba(234, 179, 8, 0.34);
	line-height: 1;
	user-select: none;
}

.st-content .st-quote p,
.st-content blockquote p {
	font-family: Lora, Georgia, serif;
	font-style: italic;
	font-size: clamp(1rem, 1.25vw, 1.15rem);
	line-height: 1.78;
	color: #FFFFFF;
	margin: 0 0 14px;
	padding-top: 16px;
}

.st-content .st-quote p:first-of-type,
.st-content blockquote p:first-of-type {
	padding-top: 16px;
}

.st-content .st-quote p + p,
.st-content blockquote p + p {
	padding-top: 0;
}

.st-content .st-quote p:last-of-type,
.st-content blockquote p:last-of-type {
	margin-bottom: 0;
}

/* Who said it. */
.st-content .st-quote cite,
.st-content blockquote cite {
	display: block;
	margin-top: 14px;
	font-family: Inter, system-ui, sans-serif;
	font-style: normal;
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: rgba(234, 179, 8, 0.75);
}

@media (max-width: 639px) {
	.st-content .st-quote,
	.st-content blockquote {
		margin: 24px 0;
	}

	.st-content .st-quote cite,
	.st-content blockquote cite {
		letter-spacing: 0.16em;
		line-height: 1.6;
	}
}

/* Searching the stories. Above the feed, so it reads as a way in rather than
   a filter on what is already shown. */
.st-search {
	display: flex;
	align-items: center;
	gap: 10px;
	max-width: 480px;
	margin: 0 0 22px;
	padding: 10px 16px;
	background: rgba(14, 24, 45, 0.92);
	border: 1px solid rgba(255, 255, 255, 0.09);
	border-radius: 999px;
	color: rgba(212, 175, 55, 0.6);
	transition: border-color 0.25s ease;
}

.st-search:focus-within { border-color: rgba(212, 175, 55, 0.4); }

.st-search input {
	flex: 1;
	min-width: 0;
	background: none;
	border: 0;
	outline: none;
	font-family: Inter, system-ui, sans-serif;
	font-size: 0.82rem;
	color: #fff;
}

.st-search input::placeholder { color: rgba(255, 255, 255, 0.4); }
.st-search input::-webkit-search-cancel-button { display: none; }

.st-search-clear {
	background: none;
	border: 0;
	cursor: pointer;
	font-size: 0.7rem;
	color: rgba(255, 255, 255, 0.5);
	padding: 2px 4px;
}

.st-search-clear:hover { color: #D4AF37; }
