/* ClickPinDownloader Downloader – component styles. Theme tokens are used when present, with fallbacks. */
.pmd, .pmc {
	--pmd-primary: var(--pm-primary, #E60023);
	--pmd-primary-hover: var(--pm-primary-hover, #E60023);
	--pmd-accent: var(--pm-accent, #E60023);
	--pmd-text: var(--pm-text, #1C2430);
	--pmd-muted: var(--pm-muted, #5B6678);
	--pmd-border: var(--pm-border, #E9E6E3);
	--pmd-soft: var(--pm-soft, #FDEFF1);
	--pmd-surface: var(--pm-surface, #FFFFFF);
	--pmd-bg: var(--pm-bg, #FAF8F5);
	--pmd-radius: 18px;
	--pmd-focus: 0 0 0 4px rgba(230, 0, 35, .18);
	color: var(--pmd-text);
	font-family: var(--pm-font-ui, Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);
	text-align: left;
}
.pmd *, .pmc * { box-sizing: border-box; }
.pmd { width: 100%; max-width: 760px; margin-inline: auto; }
.pmd-sr, .pmd .screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* Form */
.pmd-form {
	display: flex; gap: 10px; align-items: stretch;
	background: var(--pmd-surface);
	border: 1px solid rgba(230, 0, 35, .35);
	border-radius: 22px; padding: 10px;
	box-shadow: 0 1px 2px rgba(28, 36, 48, .04), 0 18px 48px -12px rgba(230, 0, 35, .22);
	transition: box-shadow .2s ease, border-color .2s ease;
}
.pmd-form:focus-within { border-color: var(--pmd-accent); box-shadow: var(--pmd-focus), 0 18px 48px -12px rgba(230, 0, 35, .28); }
.pmd-field { position: relative; flex: 1 1 auto; display: flex; align-items: center; min-width: 0; }
.pmd-field-icon { position: absolute; left: 14px; color: var(--pmd-accent); pointer-events: none; }
.pmd .pmd-input {
	flex: 1 1 auto; min-width: 0; width: 100%; height: 56px; margin: 0;
	padding: 0 12px 0 44px; border: 0; background: transparent; outline: none; box-shadow: none; line-height: normal;
	font: inherit; font-size: 16px; color: var(--pmd-text);
	border-radius: 14px;
}
.pmd .pmd-input::placeholder { color: #8A94A4; opacity: 1; }
.pmd .pmd-input[aria-invalid="true"] { box-shadow: inset 0 0 0 2px #E60023; }
.pmd .pmd-icon-btn {
	flex: 0 0 auto; display: inline-grid; place-items: center; width: 40px; height: 40px; margin-right: 6px;
	border: 0; border-radius: 12px; background: transparent; color: var(--pmd-muted); cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.pmd .pmd-icon-btn:hover, .pmd .pmd-icon-btn:focus { background: var(--pmd-bg); color: var(--pmd-text); }

.pmd .pmd-btn, .pmc .pmd-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 48px; padding: 0 20px; border-radius: 14px; border: 1px solid transparent;
	font: inherit; font-size: 15px; font-weight: 600; line-height: 1; text-decoration: none; white-space: nowrap;
	cursor: pointer; transition: transform .15s ease, box-shadow .2s ease, background-color .2s ease, color .2s ease;
	-webkit-tap-highlight-color: transparent;
}
.pmd-btn:focus-visible, .pmd-icon-btn:focus-visible, .pmd-link-btn:focus-visible, .pmd a:focus-visible, .pmc a:focus-visible { outline: 3px solid var(--pmd-primary); outline-offset: 2px; }
.pmd .pmd-btn-primary, .pmc .pmd-btn-primary {
	background: var(--pmd-primary);
	color: #fff !important; box-shadow: 0 8px 20px -8px rgba(230, 0, 35, .65), inset 0 1px 0 rgba(255, 255, 255, .18);
}
.pmd .pmd-btn-primary:hover, .pmd .pmd-btn-primary:focus, .pmc .pmd-btn-primary:hover, .pmc .pmd-btn-primary:focus { transform: translateY(-1px); box-shadow: 0 12px 24px -8px rgba(230, 0, 35, .7), inset 0 1px 0 rgba(255, 255, 255, .2); }
.pmd .pmd-btn-primary:active { transform: translateY(0); }
.pmd .pmd-btn-primary[disabled], .pmc .pmd-btn-primary[disabled] { opacity: .8; cursor: progress; transform: none; }
.pmd .pmd-btn-soft { background: var(--pmd-soft); color: var(--pmd-primary); min-height: 40px; padding: 0 14px; font-size: 14px; margin-right: 4px; }
.pmd .pmd-btn-soft:hover, .pmd .pmd-btn-soft:focus { background: #FCE1E5; }
.pmd .pmd-submit { min-height: 56px; padding: 0 26px; font-size: 16px; border-radius: 16px; }
.pmd-submit-icon { transition: transform .2s ease; }
.pmd-submit:hover .pmd-submit-icon { transform: translateX(3px); }

.pmd-spinner {
	display: none; width: 18px; height: 18px; border-radius: 50%;
	border: 2.5px solid rgba(255, 255, 255, .4); border-top-color: #fff; animation: pmd-spin .8s linear infinite;
}
.is-busy .pmd-spinner { display: inline-block; }
.is-busy .pmd-submit-icon { display: none; }
@keyframes pmd-spin { to { transform: rotate(360deg); } }

.pmd-hint { margin: 14px 4px 0; font-size: 14px; color: var(--pmd-muted); text-align: center; }
.pmd-notice { margin: 10px 4px 0; font-size: 13px; color: var(--pmd-muted); text-align: center; display: flex; gap: 6px; align-items: center; justify-content: center; flex-wrap: wrap; }
.pmd-notice svg { color: var(--pmd-accent); }
.pmd-notice a { color: var(--pmd-primary); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

/* Status */
.pmd-status:empty { display: none; }
.pmd-status, .pmc-status {
	margin: 14px 0 0; padding: 12px 16px; border-radius: 14px; font-size: 14.5px; line-height: 1.5;
	background: var(--pmd-bg); border: 1px solid var(--pmd-border); color: var(--pmd-text);
	display: flex; gap: 10px; align-items: flex-start;
}
.pmc-status:empty { display: none; }
.pmd-status.is-error, .pmc-status.is-error { background: #FEF0F2; border-color: #F9C3CB; color: #E60023; }
.pmd-status.is-success, .pmc-status.is-success { background: #EEF8F2; border-color: #C5E7D3; color: #1E6B43; }
.pmd-status.is-info { background: #F2F6FB; border-color: #D6E1EE; color: #2D4A6B; }
.pmd-status.is-loading::before {
	content: ""; flex: 0 0 auto; width: 16px; height: 16px; margin-top: 2px; border-radius: 50%;
	border: 2px solid rgba(230, 0, 35, .25); border-top-color: var(--pmd-primary); animation: pmd-spin .8s linear infinite;
}

/* Results */
.pmd-results { margin-top: 18px; }
.pmd-card {
	display: grid; grid-template-columns: minmax(0, 240px) minmax(0, 1fr); gap: 22px;
	background: var(--pmd-surface); border: 1px solid var(--pmd-border); border-radius: 22px; padding: 18px;
	box-shadow: 0 20px 50px -24px rgba(28, 36, 48, .25);
	animation: pmd-in .35s ease both;
}
@keyframes pmd-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.pmd-media {
	border-radius: 16px; overflow: hidden; background: linear-gradient(135deg, #FEF4F6, #FCE3E7);
	display: grid; place-items: center; max-height: 420px; aspect-ratio: 3 / 4;
}
.pmd-media img, .pmd-media video { width: 100%; height: 100%; object-fit: contain; display: block; background: #111; }
.pmd-media img { background: transparent; }
.pmd-body { min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.pmd-badge {
	display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 999px;
	font-size: 12px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase;
	background: var(--pmd-soft); color: var(--pmd-primary);
}
.pmd-badge-image { background: #EEF4FB; color: #2B5A8A; }
.pmd-badge-gif { background: #F4EEFB; color: #6A3FA0; }
.pmd-title {
	margin: 8px 0 0; font-family: var(--pm-font-heading, inherit); font-size: 18px; line-height: 1.35; font-weight: 700; color: var(--pmd-text);
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere;
}
.pmd-author { margin: 4px 0 0; font-size: 14px; color: var(--pmd-muted); }
.pmd-options { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 10px; }
.pmd-option {
	display: flex; align-items: center; justify-content: space-between; gap: 12px;
	padding: 12px 12px 12px 16px; border: 1px solid var(--pmd-border); border-radius: 16px; background: var(--pmd-bg);
	transition: border-color .2s ease, background-color .2s ease;
}
.pmd-option:hover { border-color: rgba(230, 0, 35, .55); background: #fff; }
.pmd-option-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pmd-option-label { font-weight: 600; font-size: 15px; }
.pmd-option-meta { font-size: 13px; color: var(--pmd-muted); font-variant-numeric: tabular-nums; }
.pmd .pmd-dl { min-height: 44px; padding: 0 16px; flex: 0 0 auto; }
.pmd-expire { margin: 0; font-size: 12.5px; color: var(--pmd-muted); }
.pmd .pmd-link-btn {
	align-self: flex-start; background: none; border: 0; padding: 4px 0; color: var(--pmd-primary);
	font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px;
}

/* Skeleton */
.pmd-skeleton { pointer-events: none; }
.pmd-sk { background: linear-gradient(90deg, #F3F0ED 25%, #FBF9F7 50%, #F3F0ED 75%); background-size: 200% 100%; animation: pmd-shimmer 1.3s ease-in-out infinite; border-radius: 12px; }
.pmd-sk-media { aspect-ratio: 3 / 4; border-radius: 16px; }
.pmd-sk-body { display: flex; flex-direction: column; gap: 12px; padding-top: 6px; }
.pmd-sk-line { height: 16px; }
.pmd-sk-line.w70 { width: 70%; height: 20px; }
.pmd-sk-line.w40 { width: 40%; }
.pmd-sk-row { height: 64px; border-radius: 16px; }
@keyframes pmd-shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* Ad placements (only rendered once configured) */
.pm-ad { margin: 32px auto; max-width: 970px; min-height: 280px; text-align: center; }
.pm-ad-label { display: block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: #8A94A4; margin-bottom: 6px; }
.pm-ad-inactive { min-height: 0; padding: 14px; border: 1.5px dashed #D9D4CF; border-radius: 14px; color: #8A94A4; font-size: 13px; background: repeating-linear-gradient(45deg, transparent, transparent 8px, rgba(0,0,0,.015) 8px, rgba(0,0,0,.015) 16px); }

/* Contact form */
.pmc { display: grid; gap: 18px; }
.pmc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.pmc-field label { display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 8px; }
.pmc-field label span { color: var(--pmd-primary); }
.pmc .pmc-field input, .pmc .pmc-field textarea {
	width: 100%; font: inherit; font-size: 16px; color: var(--pmd-text);
	padding: 14px 16px; border-radius: 14px; border: 1px solid var(--pmd-border); background: #fff;
	transition: border-color .2s ease, box-shadow .2s ease;
}
.pmc textarea { resize: vertical; min-height: 110px; height: 120px; }
.pmc .pmc-field input:focus, .pmc .pmc-field textarea:focus { outline: none; border-color: var(--pmd-accent); box-shadow: var(--pmd-focus); }
.pmc .pmc-field [aria-invalid="true"] { border-color: #E60023; }
.pmc-err { margin: 6px 0 0; font-size: 13px; color: #E60023; }
.pmc-err:empty { display: none; }
.pmc-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.pmc-submit { justify-self: start; min-width: 180px; }
.pmc-note { margin: 0; font-size: 13px; color: var(--pmd-muted); }
.pmc-note a { color: var(--pmd-primary); }

@media (max-width: 640px) {
	.pmd-form { flex-direction: column; padding: 8px; border-radius: 20px; }
	.pmd .pmd-input { height: 52px; }
	.pmd .pmd-submit { width: 100%; min-height: 54px; }
	.pmd-card { grid-template-columns: 1fr; padding: 14px; gap: 16px; }
	.pmd-media { max-height: 360px; }
	.pmd-option { flex-wrap: wrap; }
	.pmd .pmd-dl { width: 100%; }
	.pmc-grid { grid-template-columns: 1fr; }
	.pmc .pmc-submit { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
	.pmd *, .pmc * { animation: none !important; transition: none !important; }
	.pmd-spinner, .pmd-status.is-loading::before { animation: pmd-spin 1.6s linear infinite !important; }
}

/* Neutralize generic theme button/input resets (e.g. Hello Elementor) inside components */
.pmd .pmd-icon-btn, .pmd .pmd-link-btn { box-shadow: none; }
.pmd .pmd-link-btn:hover, .pmd .pmd-link-btn:focus { background: none; color: var(--pmd-primary-hover); }
.pmd .pmd-btn-primary:hover, .pmd .pmd-btn-primary:focus, .pmc .pmd-btn-primary:hover, .pmc .pmd-btn-primary:focus { color: #fff; background: var(--pmd-primary-hover); }
.pmd .pmd-btn-soft:hover, .pmd .pmd-btn-soft:focus { color: var(--pmd-primary); }
.pmd .pmd-icon-btn:hover, .pmd .pmd-icon-btn:focus { color: var(--pmd-text); }
.pmd [hidden], .pmc [hidden] { display: none !important; }

/* Mode switch (Download Pin / Explore Profile) */
.pmd-modes { display: inline-flex; gap: 4px; padding: 4px; margin: 0 0 12px; background: rgba(255, 255, 255, .75); border: 1px solid var(--pmd-border); border-radius: 14px; box-shadow: 0 1px 2px rgba(17, 17, 17, .04); }
.pmd .pmd-mode {
	display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 0 16px; margin: 0;
	border: 0; border-radius: 10px; background: transparent; color: var(--pmd-muted);
	font: inherit; font-size: 14.5px; font-weight: 600; line-height: 1; cursor: pointer; transition: background-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.pmd .pmd-mode:hover, .pmd .pmd-mode:focus { background: var(--pmd-soft); color: var(--pmd-primary); }
.pmd .pmd-mode[aria-pressed="true"] { background: var(--pmd-primary); color: #fff; box-shadow: 0 6px 14px -6px rgba(230, 0, 35, .55); }
.pmd .pmd-mode:focus-visible { outline: 3px solid var(--pmd-primary); outline-offset: 2px; }

/* Profile / board view */
.pmd-collection { display: grid; gap: 18px; }
.pmd-profile { grid-template-columns: 64px minmax(0, 1fr); gap: 16px; align-items: start; }
.pmd-avatar { width: 64px; height: 64px; border-radius: 50%; overflow: hidden; background: var(--pmd-soft); color: var(--pmd-primary); display: grid; place-items: center; font-weight: 800; font-size: 24px; box-shadow: 0 0 0 3px #fff, 0 0 0 5px rgba(230, 0, 35, .25); }
.pmd-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pmd-profile-info { min-width: 0; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.pmd-profile-info .pmd-title { margin: 0; }
.pmd-profile-info .pmd-author { margin: 0; }
.pmd-stats { margin: 4px 0 0; font-size: 14px; font-weight: 600; color: var(--pmd-text); }
.pmd-about { margin: 4px 0 0; font-size: 14px; color: var(--pmd-muted); line-height: 1.55; overflow-wrap: anywhere; }
.pmd .pmd-ext-link { margin-top: 6px; font-size: 14px; font-weight: 600; color: var(--pmd-primary); text-decoration: underline; text-underline-offset: 3px; }
.pmd-detail:empty { display: none; }
.pmd-grid-head h4 { margin: 4px 0 2px; font-size: 16px; font-weight: 700; color: var(--pmd-text); }
.pmd-grid-head p { margin: 0; font-size: 13px; color: var(--pmd-muted); }
.pmd-grid { list-style: none; margin: 0; padding: 0; columns: 4 150px; column-gap: 12px; }
.pmd-tile { break-inside: avoid; margin: 0 0 12px; }
.pmd .pmd-tile-btn {
	position: relative; display: block; width: 100%; padding: 0; margin: 0; border: 0; border-radius: 16px; overflow: hidden;
	background: #F2EFEC; cursor: pointer; box-shadow: 0 1px 2px rgba(17, 17, 17, .06); transition: transform .2s ease, box-shadow .2s ease;
}
.pmd .pmd-tile-btn img { display: block; width: 100%; height: auto; }
.pmd .pmd-tile-btn:hover, .pmd .pmd-tile-btn:focus-visible { transform: translateY(-2px); box-shadow: 0 14px 28px -14px rgba(17, 17, 17, .45); background: #F2EFEC; }
.pmd .pmd-tile-btn:focus-visible { outline: 3px solid var(--pmd-primary); outline-offset: 2px; }
.pmd-tile-badge { position: absolute; top: 8px; left: 8px; padding: 3px 8px; border-radius: 999px; background: rgba(17, 17, 17, .72); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.pmd-tile-cta {
	position: absolute; left: 8px; right: 8px; bottom: 8px; display: flex; align-items: center; justify-content: center; gap: 6px;
	min-height: 36px; border-radius: 12px; background: var(--pmd-primary); color: #fff; font-size: 13px; font-weight: 700;
	opacity: 0; transform: translateY(6px); transition: opacity .18s ease, transform .18s ease;
}
.pmd .pmd-tile-btn:hover .pmd-tile-cta, .pmd .pmd-tile-btn:focus-visible .pmd-tile-cta { opacity: 1; transform: none; }
@media (hover: none) { .pmd-tile-cta { opacity: 1; transform: none; min-height: 32px; font-size: 12px; } }
.pmd-tile-btn.is-loading::after { content: ""; position: absolute; inset: 0; background: rgba(255, 255, 255, .6) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='9' fill='none' stroke='%23E60023' stroke-width='3' stroke-dasharray='40 20'/%3E%3C/svg%3E") center / 28px no-repeat; }
.pmd-skeleton-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.pmd-sk-tile { height: 180px; border-radius: 16px; }
.pmd-sk-tile:nth-child(3n) { height: 240px; }
@media (max-width: 640px) {
	.pmd-modes { display: flex; width: 100%; }
	.pmd .pmd-mode { flex: 1; justify-content: center; padding: 0 10px; font-size: 14px; }
	.pmd-grid { columns: 2; column-gap: 10px; }
	.pmd-skeleton-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.pmd-profile { grid-template-columns: 52px minmax(0, 1fr); }
	.pmd-avatar { width: 52px; height: 52px; }
}

/* Creator actions under a Pin result */
.pmd-creator { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding: 12px 14px; border-radius: 16px; background: var(--pmd-soft); border: 1px solid rgba(230, 0, 35, .14); }
.pmd .pmd-btn-outline { min-height: 42px; padding: 0 16px; font-size: 14.5px; background: #fff; color: var(--pmd-primary); border: 1.5px solid var(--pmd-primary); box-shadow: none; }
.pmd .pmd-btn-outline:hover, .pmd .pmd-btn-outline:focus { background: var(--pmd-primary); color: #fff; border-color: var(--pmd-primary); }
.pmd .pmd-creator .pmd-ext-link { margin: 0; font-size: 14px; }
.pmd-results, .pmd-detail, .pmd-status { scroll-margin-top: 96px; }
@media (max-width: 640px) { .pmd .pmd-explore { width: 100%; } }

/* ---- v1.2: elegant centered profile header ---- */
.pmd .pmd-profile {
	position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; text-align: center;
	gap: 0; padding: 0 24px 30px; grid-template-columns: none;
}
.pmd-profile-cover {
	position: absolute; left: 0; right: 0; top: 0; height: 104px;
	background: radial-gradient(420px 140px at 20% 0%, rgba(230, 0, 35, .16), transparent 70%), radial-gradient(420px 160px at 90% 10%, rgba(230, 0, 35, .18), transparent 70%), linear-gradient(180deg, #FEF0F2, #FFFFFF);
}
.pmd .pmd-profile .pmd-avatar {
	position: relative; margin-top: 40px; width: 120px; height: 120px; font-size: 44px;
	box-shadow: 0 0 0 5px #fff, 0 14px 30px -12px rgba(17, 17, 17, .35);
}
.pmd .pmd-profile .pmd-profile-info { position: relative; align-items: center; gap: 0; margin-top: 16px; max-width: 560px; }
.pmd-profile-name { margin: 0; font-family: var(--pm-font-heading, inherit); font-size: clamp(24px, 3vw, 32px); line-height: 1.15; font-weight: 750; letter-spacing: -.02em; color: var(--pmd-text); overflow-wrap: anywhere; }
.pmd-handle { margin: 6px 0 0; font-size: 15px; color: var(--pmd-muted); }
.pmd .pmd-profile .pmd-badge { margin-bottom: 10px; }
.pmd .pmd-profile .pmd-stats { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 8px; margin: 14px 0 0; font-size: 15.5px; font-weight: 500; color: var(--pmd-text); }
.pmd-stat strong { font-weight: 750; }
.pmd-dot { color: var(--pmd-muted); }
.pmd .pmd-profile .pmd-about { margin: 12px 0 0; font-size: 15px; color: var(--pmd-text); opacity: .85; }
.pmd-profile-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 20px; }
.pmd .pmd-pill {
	display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; margin: 0;
	border: 0; border-radius: 24px; font: inherit; font-size: 16px; font-weight: 700; line-height: 1; text-decoration: none; cursor: pointer;
	transition: background-color .15s ease, transform .15s ease;
}
.pmd .pmd-pill-red { background: var(--pmd-primary); color: #fff; }
.pmd .pmd-pill-red:hover, .pmd .pmd-pill-red:focus { background: var(--pmd-primary-hover); color: #fff; }
.pmd .pmd-pill-grey { background: #E9E9E4; color: #111; }
.pmd .pmd-pill-grey:hover, .pmd .pmd-pill-grey:focus { background: #DCDCD6; color: #111; }
.pmd .pmd-pill:focus-visible { outline: 3px solid var(--pmd-primary); outline-offset: 2px; }

/* Grid fills the available width */
.pmd-grid { columns: 6 170px; column-gap: 14px; }
.pmd-tile { margin-bottom: 14px; }
.pmd-grid-head { text-align: center; }
.pmd-grid-head h4 { font-size: 18px; }
.pmd-skeleton-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
@media (max-width: 640px) {
	.pmd .pmd-profile { padding: 0 16px 24px; }
	.pmd .pmd-profile .pmd-avatar { width: 96px; height: 96px; margin-top: 36px; }
	.pmd-grid { columns: 2; column-gap: 10px; }
	.pmd .pmd-pill { flex: 1; }
}

/* ---- v1.4: multiple links, bulk selection, ZIP ---- */
.pmd .pmd-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; padding: 14px 18px; grid-template-columns: none; }
.pmd-toolbar-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pmd-toolbar-info strong { font-size: 15.5px; color: var(--pmd-text); }
.pmd-toolbar-info span { font-size: 13px; color: var(--pmd-muted); }
.pmd-toolbar-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.pmd .pmd-toolbar .pmd-pill { min-height: 44px; font-size: 14.5px; }
.pmd .pmd-zip { min-height: 44px; }
.pmd .pmd-zip[disabled] { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }
.pmd-multi { display: grid; gap: 14px; }
.pmd-multi-list { display: grid; gap: 14px; }
.pmd .pmd-result--compact { grid-template-columns: 140px minmax(0, 1fr); gap: 16px; padding: 14px; }
.pmd .pmd-result--compact .pmd-media { max-height: 200px; }
.pmd .pmd-result--compact .pmd-title { font-size: 16px; }
.pmd .pmd-result--compact .pmd-creator { display: none; }
.pmd .pmd-multi-error { display: flex; flex-direction: column; gap: 4px; padding: 14px 18px; grid-template-columns: none; background: #FEF0F2; border-color: #FAC9D0; }
.pmd-multi-error strong { font-size: 13.5px; color: #E60023; overflow-wrap: anywhere; }
.pmd-multi-error span { font-size: 14px; color: #E60023; }
.pmd .pmd-skeleton.pmd-sk-row { display: block; height: 120px; padding: 0; border-radius: 22px; }
.pmd-tile { position: relative; }
.pmd .pmd-tile-check {
	position: absolute; top: 8px; right: 8px; z-index: 2; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; margin: 0;
	border-radius: 50%; border: 2px solid #fff; background: rgba(17, 17, 17, .45); color: transparent; cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, .25); transition: background-color .15s ease, color .15s ease, transform .15s ease;
}
.pmd .pmd-tile-check:hover, .pmd .pmd-tile-check:focus { background: rgba(17, 17, 17, .65); color: rgba(255, 255, 255, .8); }
.pmd .pmd-tile-check[aria-pressed="true"] { background: var(--pmd-primary); color: #fff; transform: scale(1.05); }
.pmd .pmd-tile-check:focus-visible { outline: 3px solid var(--pmd-primary); outline-offset: 2px; }
.pmd-tile.is-selected .pmd-tile-btn { box-shadow: 0 0 0 3px var(--pmd-primary); }
@media (max-width: 640px) {
	.pmd .pmd-result--compact { grid-template-columns: 96px minmax(0, 1fr); }
	.pmd-toolbar-btns, .pmd-toolbar-btns > * { width: 100%; }
	.pmd .pmd-toolbar .pmd-zip { width: 100%; }
}
.pmd .pmd-pill-outline { gap: 8px; background: #fff; color: var(--pmd-primary); border: 1.5px solid var(--pmd-primary); }
.pmd .pmd-pill-outline:hover, .pmd .pmd-pill-outline:focus { background: var(--pmd-primary); color: #fff; }

/* Bulk ZIP: live progress right next to the download button */
.pmd .pmd-toolbar .pmd-progress { flex: 1 1 100%; display: grid; gap: 8px; padding: 14px 16px; border-radius: 14px; background: #FEF7F8; border: 1px solid #FBD3D9; }
.pmd-progress-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: 14px; }
.pmd-progress-label { font-weight: 650; color: var(--pmd-text); }
.pmd-progress-count { font-variant-numeric: tabular-nums; font-weight: 700; color: #E60023; white-space: nowrap; }
.pmd-progress-track { height: 10px; border-radius: 999px; background: #FBD3D9; overflow: hidden; }
.pmd-progress-fill { height: 100%; width: 0; border-radius: inherit; background: #E60023 linear-gradient(45deg, rgba(255,255,255,.22) 25%, transparent 25%, transparent 50%, rgba(255,255,255,.22) 50%, rgba(255,255,255,.22) 75%, transparent 75%) 0 0 / 18px 18px; transition: width .35s ease; animation: pmdStripes .8s linear infinite; }
.pmd-progress-sub { font-size: 12.5px; color: var(--pmd-muted); }
.pmd-progress.is-done .pmd-progress-fill, .pmd-progress.is-failed .pmd-progress-fill { animation: none; background-image: none; }
.pmd-progress.is-done { background: #fff; }
.pmd-progress.is-done .pmd-progress-label::before { content: "✓ "; color: #E60023; }
.pmd-progress.is-failed .pmd-progress-fill { opacity: .35; }
@keyframes pmdStripes { to { background-position: 18px 0; } }
.pmd .pmd-zip.is-working { opacity: 1 !important; cursor: progress; }
.pmd .pmd-zip.is-working svg { display: none; }
.pmd .pmd-zip.is-working::before { content: ""; width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid rgba(255,255,255,.45); border-top-color: #fff; animation: pmdSpin .7s linear infinite; }
@keyframes pmdSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .pmd-progress-fill, .pmd .pmd-zip.is-working::before { animation: none; } }

/* MP3 (audio only) option */
.pmd .pmd-option--mp3 { border-style: dashed; border-color: #FBD3D9; background: #FEF7F8; }
.pmd .pmd-option--mp3 .pmd-option-label::before { content: "♪ "; color: #E60023; font-weight: 800; }
.pmd .pmd-mp3 { min-width: 172px; justify-content: center; }
.pmd .pmd-mp3.is-working { opacity: 1 !important; cursor: progress; font-variant-numeric: tabular-nums; }
.pmd .pmd-mp3.is-working svg { display: none; }
.pmd .pmd-mp3.is-working::before { content: ""; width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid rgba(255,255,255,.45); border-top-color: #fff; animation: pmdSpin .7s linear infinite; }
