/*
 * Copyright (C) 2026 Fluxer Contributors
 *
 * This file is part of Fluxer.
 *
 * Fluxer is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * Fluxer is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with Fluxer. If not, see <https://www.gnu.org/licenses/>.
 */

.relativeWrapper {
	position: relative;
	width: 100%;
	max-width: min(100%, var(--message-media-max-width, var(--attachment-media-max-width, 550px)));
}

.singleMediaContainer {
	position: relative;
	width: 100%;
	max-width: min(100%, var(--message-media-max-width, var(--attachment-media-max-width, 550px)));
	max-height: var(--attachment-media-max-height, 400px);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.cropIndicator {
	position: absolute;
	top: 8px;
	right: 8px;
	padding: 4px 8px;
	background: rgba(0, 0, 0, 0.7);
	color: var(--text-on-brand-primary);
	font-size: 0.75rem;
	font-weight: 600;
	border-radius: 4px;
	display: flex;
	align-items: center;
	gap: 4px;
	z-index: 10;
	line-height: 1;
}

.cropIndicator svg {
	flex-shrink: 0;
}

@media (max-width: 640px) {
	.relativeWrapper,
	.singleMediaContainer {
		max-width: 100%;
		max-height: min(var(--attachment-media-max-height, 400px), 300px);
	}
}
