/**
 * Mine Brief front-end styles for shortcodes and blocks.
 * Scoped to .mb-* classes to avoid clashing with theme styles.
 */

:root {
	--mb-navy: #1a3a5c;
	--mb-navy-dark: #12283f;
	--mb-accent: #e8a13a;
	--mb-text: #1f2d3d;
	--mb-muted: #5b6b7b;
	--mb-border: #e3e8ee;
	--mb-bg-soft: #f7f9fc;
	--mb-radius: 10px;
}

/* ------------------------------------------------------------------ */
/* Buttons                                                             */
/* ------------------------------------------------------------------ */

.mb-btn,
.mb-modal-trigger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 12px 22px;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	color: #fff;
	background: var(--mb-navy);
	border: 1px solid var(--mb-navy);
	border-radius: var(--mb-radius);
	cursor: pointer;
	text-decoration: none;
	transition: background .15s ease, transform .05s ease, box-shadow .15s ease;
	box-shadow: 0 1px 2px rgba(16, 35, 56, .15);
}

.mb-btn:hover,
.mb-modal-trigger:hover {
	background: var(--mb-navy-dark);
	border-color: var(--mb-navy-dark);
	color: #fff;
}

.mb-btn:active,
.mb-modal-trigger:active {
	transform: translateY(1px);
}

.mb-btn:focus-visible,
.mb-modal-trigger:focus-visible {
	outline: 3px solid rgba(26, 58, 92, .35);
	outline-offset: 2px;
}

/* ------------------------------------------------------------------ */
/* Modal                                                               */
/* ------------------------------------------------------------------ */

.mb-modal-wrap {
	display: inline-block;
}

/* Overlay sits above virtually everything, including sticky theme headers. */
.mb-modal-overlay {
	position: fixed;
	inset: 0;
	z-index: 2147483646;
	background: rgba(10, 22, 36, .65);
	-webkit-backdrop-filter: blur(2px);
	backdrop-filter: blur(2px);
	align-items: center;
	justify-content: center;
	padding: 20px;
	box-sizing: border-box;
}

.mb-modal-dialog {
	position: relative;
	background: #fff;
	border-radius: 14px;
	padding: 32px;
	max-width: 800px;
	width: 100%;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
	box-sizing: border-box;
}

.mb-modal-close {
	position: absolute;
	top: 12px;
	right: 14px;
	width: 36px;
	height: 36px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 1.6rem;
	line-height: 1;
	color: var(--mb-muted);
	background: none;
	border: none;
	border-radius: 8px;
	cursor: pointer;
}

.mb-modal-close:hover {
	background: var(--mb-bg-soft);
	color: var(--mb-text);
}

/* ------------------------------------------------------------------ */
/* Widget / content                                                    */
/* ------------------------------------------------------------------ */

.mb-widget {
	color: var(--mb-text);
	font-size: 15px;
	line-height: 1.55;
}

.mb-widget-header {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 18px;
	margin-bottom: 12px;
	color: var(--mb-navy);
}

.mb-asx {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .3px;
	background: var(--mb-navy);
	color: #fff;
	padding: 3px 8px;
	border-radius: 5px;
}

.mb-snapshot-brief {
	color: var(--mb-muted);
	margin-bottom: 16px;
}

.mb-announcements .mb-ann-list,
.mb-faq-list,
.mb-timeline-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.mb-ann-item {
	padding: 14px 0;
	border-bottom: 1px solid var(--mb-border);
}

.mb-ann-item:last-child {
	border-bottom: none;
}

.mb-ann-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin-bottom: 4px;
}

.mb-date {
	font-size: 13px;
	color: var(--mb-muted);
}

.mb-badge {
	display: inline-block;
	font-size: 11px;
	font-weight: 600;
	text-transform: capitalize;
	padding: 2px 8px;
	border-radius: 999px;
	background: var(--mb-bg-soft);
	color: var(--mb-muted);
	border: 1px solid var(--mb-border);
}

.mb-badge--positive { background: #e7f6ec; color: #1a7f4b; border-color: #bce6cb; }
.mb-badge--neutral  { background: #eef1f5; color: #4b5b6b; border-color: #dbe2ea; }
.mb-badge--cautionary,
.mb-badge--negative { background: #fdecec; color: #b4322b; border-color: #f3c9c6; }
.mb-badge--mixed    { background: #fdf3e3; color: #9a6212; border-color: #f3dfb8; }

.mb-ann-title {
	display: inline-block;
	font-size: 16px;
	font-weight: 600;
	color: var(--mb-navy);
	text-decoration: none;
	margin: 2px 0;
}

.mb-ann-title:hover {
	text-decoration: underline;
}

.mb-ann-summary {
	margin: 4px 0 0;
	color: var(--mb-muted);
}

.mb-widget-footer {
	margin-top: 18px;
	padding-top: 14px;
	border-top: 1px solid var(--mb-border);
}

.mb-disclaimer {
	font-size: 12px;
	color: var(--mb-muted);
	margin: 0 0 8px;
}

.mb-kb-link {
	display: inline-block;
	font-weight: 600;
	color: var(--mb-navy);
	text-decoration: none;
}

.mb-kb-link:hover {
	text-decoration: underline;
}

/* Snapshot */
.mb-snapshot-title {
	font-size: 18px;
	color: var(--mb-navy);
	margin: 0 0 10px;
}

/* FAQs */
.mb-faq-list dt {
	font-weight: 600;
	color: var(--mb-navy);
	margin-top: 12px;
}

.mb-faq-list dd {
	margin: 4px 0 0;
	color: var(--mb-muted);
}

/* Timeline */
.mb-timeline-item {
	display: flex;
	gap: 14px;
	padding: 10px 0;
	border-bottom: 1px solid var(--mb-border);
}

.mb-timeline-item:last-child {
	border-bottom: none;
}

.mb-timeline-date {
	flex: 0 0 100px;
	font-size: 13px;
	color: var(--mb-muted);
}

/* States */
.mb-empty,
.mb-unavailable {
	color: var(--mb-muted);
	font-style: italic;
}

@media (max-width: 600px) {
	.mb-modal-dialog { padding: 22px; }
	.mb-timeline-item { flex-direction: column; gap: 2px; }
	.mb-timeline-date { flex-basis: auto; }
}
