/* OG Preview tool shell - components come from /rtf6x/css/ui-kit.css,
   this file only lays out the page. */

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	background: var(--uk-bg);
	color: var(--uk-text);
	font-family: var(--uk-font-body);
	font-size: 15px;
	line-height: 1.55;
}

.container {
	max-width: 860px;
	margin: 0 auto;
	padding: 28px 20px 64px;
	display: flex;
	flex-direction: column;
	gap: 18px;
}

/* ---------- header ---------- */

.header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
}

.brand {
	display: flex;
	align-items: center;
	gap: 12px;
}

.logo {
	display: block;
	border-radius: 8px;
}

.titles h1 {
	margin: 0;
	font-family: var(--uk-font-heading);
	font-size: 26px;
	font-weight: 700;
	letter-spacing: 0.02em;
	line-height: 1.1;
}

.titles .sub {
	margin: 2px 0 0;
	color: var(--uk-muted);
	font-size: 13.5px;
	max-width: 46ch;
}

/* ---------- scan form ---------- */

.scan-panel {
	gap: 12px;
}

/* Tool-local tint of the kit's status row (the kit itself has no
   semantic variants) */
#status.uk-status--danger {
	border-color: var(--uk-danger-border);
}

#status.uk-status--danger .uk-status__dot {
	background: var(--uk-danger);
}

#status.uk-status--warning {
	border-color: var(--uk-warning-border);
}

#status.uk-status--warning .uk-status__dot {
	background: var(--uk-warning);
}

.scan-form {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 12px;
	align-items: end;
}

.scan-form .uk-field {
	margin: 0;
}

.scan-form .uk-btn {
	height: 42px;
	white-space: nowrap;
}

/* ---------- results ---------- */

/* display:flex would beat the UA's [hidden] rule - keep hidden working */
#results[hidden],
#inspectorPanel[hidden] {
	display: none;
}

#results {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.panel-title {
	margin: 0;
	font-family: var(--uk-font-heading);
	font-size: 16px;
	font-weight: 700;
	letter-spacing: 0.02em;
}

.result-head {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
}

.final-url {
	font-family: var(--uk-font-mono);
	font-size: 12.5px;
	color: var(--uk-muted);
	text-decoration: none;
	overflow-wrap: anywhere;
}

.final-url:hover {
	color: var(--uk-accent);
}

.effective {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.effective .uk-field {
	gap: 4px;
	margin: 0;
}

.effective__value {
	margin: 0;
	font-size: 14.5px;
	overflow-wrap: anywhere;
}

.effective__value--empty {
	color: var(--uk-faint);
	font-style: italic;
}

.effective__value--mono {
	font-family: var(--uk-font-mono);
	font-size: 12.5px;
}

/* ---------- tag table ---------- */

.tag-table {
	display: flex;
	flex-direction: column;
}

.tag-row {
	display: grid;
	grid-template-columns: 190px 1fr auto;
	gap: 10px;
	align-items: center;
	padding: 8px 0;
	border-bottom: 1px solid var(--uk-panel-border);
}

.tag-row:last-child {
	border-bottom: 0;
}

.tag-row__name {
	font-family: var(--uk-font-mono);
	font-size: 12px;
	color: var(--uk-muted);
	overflow-wrap: anywhere;
}

.tag-row__value {
	font-size: 13px;
	margin: 0;
	overflow-wrap: anywhere;
}

.tag-row__value--empty {
	color: var(--uk-faint);
	font-style: italic;
}
/* ---------- inspector ---------- */

.panel-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
}

.issue-filters {
	display: flex;
	gap: 6px;
}

.issue-filter {
	cursor: pointer;
	transition: box-shadow 0.15s ease;
}

.issue-filter--active {
	box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.4);
}

.issue-list {
	display: flex;
	flex-direction: column;
	margin-top: 4px;
}

.issue {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 10px 0;
	border-bottom: 1px solid var(--uk-panel-border);
}

.issue:last-child {
	border-bottom: 0;
}

.issue__mark {
	flex: none;
	width: 22px;
	height: 22px;
	padding: 0;
	justify-content: center;
	border-radius: 50%;
	font-size: 11px;
}

.issue__body {
	min-width: 0;
	flex: 1;
}

.issue__head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
}

.issue__label {
	font-size: 13.5px;
	font-weight: 600;
}

.issue__tag {
	flex: none;
	font-family: var(--uk-font-mono);
	font-size: 10.5px;
	color: var(--uk-faint);
}

.issue__detail {
	margin: 3px 0 0;
	font-size: 12.5px;
	line-height: 1.5;
	color: var(--uk-muted);
	overflow-wrap: anywhere;
}

.issue-empty {
	margin: 6px 0 0;
	font-size: 12.5px;
	font-style: italic;
	color: var(--uk-faint);
}

/* ---------- previews ---------- */

#previewPane {
	display: flex;
	justify-content: center;
	width: 100%;
	margin-top: 4px;
}

/* Each card reproduces what the platform itself renders: type scale, spacing
   and colors. Platform font stacks are deliberate - X, Facebook, LinkedIn and
   WhatsApp use the system UI font, Discord uses Helvetica - and the light
   surfaces are the point: a preview that looks like our dark theme is not a
   preview of the platform. */

.og-card {
	font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
	-webkit-font-smoothing: antialiased;
}

.og-card__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	background: #e4e6eb;
}

.og-card__media {
	position: relative;
	width: 100%;
	aspect-ratio: 1.91;
	overflow: hidden;
	background: #e4e6eb;
}

/* X: image with the title burned in as a chip, domain printed underneath */

.og-card--x {
	width: 100%;
	max-width: 438px;
	margin: 0 auto;
}

.og-card__frame {
	overflow: hidden;
	border: 1px solid #e1e8ed;
	border-radius: 16px;
	background: #fff;
	color: #0f1419;
}

.og-card__chip {
	position: absolute;
	bottom: 12px;
	left: 12px;
	max-width: calc(100% - 24px);
	padding: 0 8px;
	border-radius: 4px;
	background: rgba(0, 0, 0, 0.75);
	color: #fff;
	font-size: 13px;
	line-height: 20px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.og-card__x-body {
	padding: 12px;
}

.og-card__x-title {
	font-size: 15px;
	font-weight: 700;
	line-height: 20px;
}

.og-card__x-desc {
	margin-top: 2px;
	font-size: 15px;
	line-height: 20px;
	color: #536471;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.og-card__x-domain {
	margin-top: 8px;
	font-size: 15px;
	line-height: 20px;
	color: #536471;
}

/* Sits on our dark page, not on the card, so it uses the kit's muted tone
   instead of the platform's light-surface gray. */
.og-card__from {
	margin-top: 4px;
	font-size: 13px;
	color: var(--uk-muted);
}

/* Facebook: image above an uppercase-domain footer */

.og-card--fb {
	width: 100%;
	max-width: 524px;
	margin: 0 auto;
	overflow: hidden;
}

.og-card__fb-foot {
	padding: 10px 16px 6px;
	background: #f0f2f5;
	color: #080809;
}

.og-card__fb-domain {
	margin-bottom: 4px;
	font-size: 13px;
	line-height: 12px;
	color: #65686c;
	text-transform: uppercase;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.og-card__fb-title {
	font-size: 17px;
	line-height: 21px;
	font-weight: 600;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.og-card__fb-desc {
	margin-top: 2px;
	font-size: 14px;
	line-height: 19px;
	color: #65686c;
	display: -webkit-box;
	-webkit-line-clamp: 1;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* LinkedIn: 128x72 thumb beside the title, no description */

.og-card--li {
	display: flex;
	align-items: stretch;
	gap: 12px;
	width: 100%;
	max-width: 526px;
	margin: 0 auto;
	padding: 12px;
	border: 1px solid rgba(140, 140, 140, 0.2);
	border-radius: 8px;
	background: #fff;
	color: #000;
}

.og-card__li-thumb {
	flex: none;
	width: 128px;
	height: 72px;
	border-radius: 8px;
	overflow: hidden;
	background: #e9e9e9;
}

.og-card__li-body {
	display: flex;
	flex-direction: column;
	justify-content: center;
	min-width: 0;
	flex: 1;
}

.og-card__li-title {
	margin-bottom: 4px;
	font-size: 14px;
	line-height: 20px;
	font-weight: 600;
	color: rgba(0, 0, 0, 0.9);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.og-card__li-domain {
	font-size: 12px;
	line-height: 16px;
	color: rgba(0, 0, 0, 0.6);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* WhatsApp: green outgoing-message bubble, image on top of the text */

.og-card--wa {
	width: 100%;
	max-width: 340px;
	margin: 0 auto;
	overflow: hidden;
	border-radius: 7.5px;
	background: #daf0cb;
	color: #111b21;
}

.og-card__wa-body {
	padding: 10px 12px;
}

.og-card__wa-title {
	margin-bottom: 6px;
	font-size: 13px;
	line-height: 19px;
	font-weight: 600;
	overflow-wrap: anywhere;
	display: -webkit-box;
	-webkit-line-clamp: 5;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.og-card__wa-desc {
	margin-bottom: 6px;
	font-size: 12px;
	line-height: 17px;
	font-weight: 500;
	color: #727f6e;
	overflow-wrap: anywhere;
	display: -webkit-box;
	-webkit-line-clamp: 5;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.og-card__wa-foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.og-card__wa-domain {
	min-width: 0;
	font-size: 11px;
	line-height: 16px;
	font-weight: 500;
	color: #727f6e;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.og-card__wa-icon {
	flex: none;
	width: 16px;
	height: 16px;
	object-fit: contain;
}

/* Discord: site name, blue link title and description, image below the text */

.og-card--dc {
	width: 100%;
	max-width: 432px;
	margin: 0 auto;
	overflow: hidden;
	border: 1px solid #dfdfe1;
	border-left: 4px solid #dfdfe1;
	border-radius: 3px;
	background: #fff;
	color: #2c2d32;
	font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.og-card__dc-body {
	padding: 16px 16px 16px 12px;
}

.og-card__dc-site {
	font-size: 12px;
	line-height: 1.4;
}

.og-card__dc-title {
	margin-top: 8px;
	font-size: 16px;
	font-weight: 600;
	color: #3a68db;
	overflow-wrap: anywhere;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.og-card__dc-desc {
	margin-top: 8px;
	font-size: 14px;
	line-height: 1.4;
}

.og-card__dc-media {
	width: calc(100% - 24px);
	margin: 0 12px 16px;
	border-radius: 3px;
	overflow: hidden;
	aspect-ratio: 1.91;
	background: #e4e6eb;
}

@media (max-width: 640px) {
	.scan-form {
		grid-template-columns: 1fr;
	}

	.scan-form .uk-btn {
		width: 100%;
	}

	.tag-row {
		grid-template-columns: 1fr auto;
	}

	.tag-row__value {
		grid-column: 1 / -1;
	}
}
