.ppb-review-attachments-field {
	margin-top: 10px;
}

.ppb-review-attachments-field label {
	display: block;
	margin-bottom: 6px;
}

.ppb-review-attachments-field .ppb-optional {
	font-weight: normal;
	color: #6b6259;
}

/*
 * The native file input looks inconsistent with the rest of the site (a
 * plain OS-styled "Choose files" button). `::file-selector-button` lets us
 * reskin just the button part as the site's usual black pill, while leaving
 * the browser's own "No file chosen" / "3 files" text alone.
 */
.ppb-review-attachments-field input[type='file'] {
	display: block;
	font-size: 14px;
	color: #6b6259;
}

.ppb-review-attachments-field input[type='file']::file-selector-button {
	background: #000;
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 10px 20px;
	margin-right: 12px;
	font-weight: 700;
	font-size: 14px;
	cursor: pointer;
}

.ppb-review-attachments-hint {
	display: block;
	font-size: 12px;
	color: #6b6259;
	margin-top: 8px;
}

.ppb-review-attachments-hint.is-error {
	color: #c0392b;
}

.ppb-review-attachments-previews {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 10px;
}

.ppb-review-attachment-preview {
	position: relative;
	width: 72px;
	height: 72px;
	border-radius: 10px;
	overflow: hidden;
	background: #f3f2ed;
	border: 1px solid #9a9a9a45;
}

/*
 * WooCommerce ships `.woocommerce img, .woocommerce-page img { height:
 * auto; }` at the same specificity as a plain `.foo img` rule — same
 * specificity ties resolve by source order, and WooCommerce's stylesheet
 * isn't guaranteed to load before this one. Matching its specificity with
 * an extra `.woocommerce` ancestor is what actually wins reliably (same
 * pattern used for the additional-information label and heading-size
 * fixes elsewhere in this project) — without it, `height:auto` overrides
 * our fixed square box and non-square photos render squashed with visible
 * background showing through instead of a proper cover-cropped square.
 */
.woocommerce .ppb-review-attachment-preview img,
.woocommerce-page .ppb-review-attachment-preview img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ppb-review-attachment-remove {
	position: absolute;
	top: 2px;
	right: 2px;
	width: 20px;
	height: 20px;
	line-height: 18px;
	padding: 0;
	border: none;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.65);
	color: #fff;
	font-size: 14px;
	cursor: pointer;
}

.ppb-review-attachments {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 12px 0 20px;
}

.ppb-review-attachment {
	position: relative;
	display: block;
	width: 100px;
	height: 100px;
	border-radius: 10px;
	overflow: hidden;
	background: #f3f2ed;
	border: 1px solid #9a9a9a45;
	cursor: pointer;
}

.woocommerce .ppb-review-attachment img,
.woocommerce-page .ppb-review-attachment img,
.woocommerce .ppb-review-attachment video,
.woocommerce-page .ppb-review-attachment video {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ppb-review-attachment-play {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 34px;
	height: 34px;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.55);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 13px;
	pointer-events: none;
}

/* Lightbox styles are shared — see ppb-lightbox.css. */
