/* =========================================================
   DHJ Status — light board (distinct identity)
   Left status rail, left-aligned content, corner status seal,
   purple brand + Buy button. Scoped under .dhj-status.
   ========================================================= */

.dhj-status {
	--dhj-purple: #7c3aed;
	--dhj-purple-2: #a855f7;

	--dhj-ink: #3D3D3D;
	--dhj-muted: #5f6572;
	--dhj-faint: #9aa1ad;

	--dhj-surface: #ffffff;
	--dhj-soft: #f6f5fc;
	--dhj-border: #e9e7f2;
	--dhj-border-strong: #d8d4ea;

	--dhj-ok: #16a34a;
	--dhj-warn: #d97706;
	--dhj-bad: #dc2626;

	--dhj-radius: 18px;

	max-width: 1120px;
	margin-inline: auto;
	color: var(--dhj-ink);
	box-sizing: border-box;
	font-family: inherit;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

.dhj-status *,
.dhj-status *::before,
.dhj-status *::after {
	box-sizing: border-box;
}

/* Tone text colours */
.dhj-tone-ok   { color: var(--dhj-ok); }
.dhj-tone-warn { color: var(--dhj-warn); }
.dhj-tone-bad  { color: var(--dhj-bad); }

/* ---------- Header --------------------------------------- */
.dhj-status__head {
	text-align: center;
	margin-bottom: 28px;
}

.dhj-status__title {
	margin: 0;
	font-size: clamp(1.8rem, 4vw, 2.6rem);
	font-weight: 600;
	letter-spacing: -0.02em;
	color: var(--dhj-ink);
}

/* Purple underline accent — a signature the dark plugin doesn't have */
.dhj-status__rule {
	display: block;
	width: 64px;
	height: 4px;
	margin: 14px auto 0;
	border-radius: 999px;
	background: linear-gradient(90deg, var(--dhj-purple), var(--dhj-purple-2));
}

/* ---------- Legend (3 columns of definition chips) ------- */
.dhj-legend {
	list-style: none;
	margin: 0 0 26px;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 12px;
}

.dhj-legend__item {
	padding: 14px 16px;
	border-radius: 14px;
	background: var(--dhj-surface);
	border: 1px solid var(--dhj-border);
	border-left: 4px solid var(--dhj-border-strong);
}

.dhj-legend__item.dhj-tone-ok-card   { border-left-color: var(--dhj-ok); }
.dhj-legend__item.dhj-tone-warn-card { border-left-color: var(--dhj-warn); }
.dhj-legend__item.dhj-tone-bad-card  { border-left-color: var(--dhj-bad); }

.dhj-legend__tag {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	margin-bottom: 6px;
}

.dhj-legend__name {
	font-weight: 600;
	font-size: 0.92rem;
}

.dhj-legend__desc {
	display: block;
	font-size: 0.82rem;
	line-height: 1.45;
	color: var(--dhj-muted);
}

/* ---------- Status dot ----------------------------------- */
.dhj-dot {
	display: inline-block;
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: currentColor;
	flex: none;
}

.dhj-dot.dhj-tone-ok   { color: var(--dhj-ok); }
.dhj-dot.dhj-tone-warn { color: var(--dhj-warn); }
.dhj-dot.dhj-tone-bad  { color: var(--dhj-bad); }

/* ---------- Grid & cards --------------------------------- */
.dhj-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
	gap: 18px;
}

.dhj-card {
	position: relative;
	display: flex;
	flex-direction: column;
	padding: 22px 22px 22px 26px;
	border-radius: var(--dhj-radius);
	background: var(--dhj-surface);
	border: 1px solid var(--dhj-border);
	box-shadow: 0 2px 4px rgba(30, 26, 60, 0.04);
	transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

/* Coloured vertical rail on the left edge (the distinct signature) */
.dhj-card::before {
	content: "";
	position: absolute;
	inset: 14px auto 14px 0;
	width: 4px;
	border-radius: 999px;
	background: var(--dhj-border-strong);
}

.dhj-card.dhj-tone-ok-card::before   { background: var(--dhj-ok); }
.dhj-card.dhj-tone-warn-card::before { background: var(--dhj-warn); }
.dhj-card.dhj-tone-bad-card::before  { background: var(--dhj-bad); }

.dhj-card:hover {
	transform: translateY(-3px);
	border-color: var(--dhj-border-strong);
	box-shadow: 0 18px 34px -20px rgba(60, 40, 120, 0.4);
}

.dhj-card__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 16px;
}

.dhj-card__title {
	margin: 0;
	font-size: 1.18rem;
	font-weight: 600;
	line-height: 1.2;
	color: var(--dhj-ink);
}

/* Corner status seal */
.dhj-card__badge {
	flex: none;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 5px 11px;
	border-radius: 999px;
	font-weight: 600;
	font-size: 0.78rem;
	white-space: nowrap;
}

.dhj-card__badge.dhj-tone-ok   { color: var(--dhj-ok);   background: rgba(22, 163, 74, 0.1); }
.dhj-card__badge.dhj-tone-warn { color: var(--dhj-warn); background: rgba(217, 119, 6, 0.1); }
.dhj-card__badge.dhj-tone-bad  { color: var(--dhj-bad);  background: rgba(220, 38, 38, 0.1); }

/* Facts (definition list) */
.dhj-card__facts {
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.dhj-fact {
	margin: 0;
}

.dhj-fact dt {
	font-size: 0.72rem;
	letter-spacing: 0.02em;
	color: var(--dhj-faint);
	margin-bottom: 2px;
}

.dhj-fact dd {
	margin: 0;
	font-size: 0.92rem;
	font-weight: 500;
	color: var(--dhj-ink);
	line-height: 1.4;
}

/* ---------- Buy button ----------------------------------- */
.dhj-buy {
	margin-top: auto;   /* pin to the bottom so buttons align across a row */
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 11px 16px;
	border-radius: 12px;
	font-size: 0.92rem;
	font-weight: 600;
	text-decoration: none;
	background: linear-gradient(135deg, var(--dhj-purple), var(--dhj-purple-2));
	box-shadow: 0 10px 22px -12px rgba(124, 58, 237, 0.9);
	transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

/* Guaranteed gap above the button when it follows the facts */
.dhj-card__facts:not(:last-child) {
	margin-bottom: 20px;
}

/* Force white label in every state (beats any theme a:hover colour) */
.dhj-status .dhj-buy,
.dhj-status .dhj-buy:link,
.dhj-status .dhj-buy:visited,
.dhj-status .dhj-buy:hover,
.dhj-status .dhj-buy:focus,
.dhj-status .dhj-buy:active {
	color: #fff !important;
}

.dhj-buy:hover {
	transform: translateY(-2px);
	filter: brightness(1.05);
	box-shadow: 0 14px 26px -12px rgba(124, 58, 237, 1);
}

.dhj-buy:active {
	transform: translateY(0);
}

.dhj-buy:focus-visible {
	outline: 2px solid var(--dhj-purple);
	outline-offset: 2px;
}

.dhj-buy__arrow {
	transition: transform 0.15s ease;
}

.dhj-buy:hover .dhj-buy__arrow {
	transform: translateX(3px);
}

/* ---------- Footer note ---------------------------------- */
.dhj-status__foot {
	margin-top: 30px;
	text-align: center;
	color: var(--dhj-faint);
	font-size: 0.9rem;
	line-height: 1.6;
}

/* ---------- Empty state ---------------------------------- */
.dhj-empty {
	padding: 26px;
	border: 1px dashed var(--dhj-border-strong);
	border-radius: var(--dhj-radius);
	color: var(--dhj-muted);
	text-align: center;
}

/* ---------- Responsive ----------------------------------- */
@media (max-width: 820px) {
	.dhj-legend {
		grid-template-columns: 1fr;
	}
}

/* ---------- Reduced motion ------------------------------- */
@media (prefers-reduced-motion: reduce) {
	.dhj-card,
	.dhj-buy,
	.dhj-buy__arrow { transition: none; }
	.dhj-card:hover,
	.dhj-buy:hover { transform: none; }
	.dhj-buy:hover .dhj-buy__arrow { transform: none; }
}
