/* ==========================================================================
 * Tray Surface — the sliding sheet that hosts applet content
 * ========================================================================== */
.-tray {
	flex: 1;
	inset: 0;
	width: 100%;
	height: 100%;
	display: flex;
	min-height: 0;
	position: relative;
	flex-flow: column;
	pointer-events: none;
	align-items: stretch;
	overflow: hidden auto;
	scroll-behavior: smooth;
	scroll-snap-type: y mandatory;
}

.-tray-hero-overlay {
	width: 100%;
	display: flex;
	min-height: 100%;
	position: relative;
	pointer-events: none;
	scroll-behavior: smooth;
	scroll-snap-stop: always;
	scroll-snap-align: center;
	overscroll-behavior-inline: contain;
}

.---hero-full .-tray-hero-overlay {
	min-height: 100%;
}

.---hero-full .-tray-surface .-horizontal-divider {
	display: none;
}

.-tray-surface {
	z-index: 2;
	width: 100%;
	display: flex;
	min-height: 100%;
	position: relative;
	pointer-events: auto;
	scroll-behavior: smooth;
	scroll-snap-stop: always;
	scroll-snap-align: center;
	scroll-snap-type: x mandatory;
	background: var(--app-theme);
	isolation: isolate;
}

.-tray-surface-box {
	width: 100%;
	gap: 3.125vw;
	display: flex;
	position: relative;
	align-items: center;
	padding: 3.125vw 0 0;
	flex-direction: column;
	overflow: hidden auto;
	scroll-snap-stop: always;
	scroll-snap-align: center;
	justify-content: flex-start;
	height: -webkit-fill-available;
}

/* Soft fade where content first appears beneath the pull-handle divider,
 * so text doesn't feel like it starts abruptly under the grabber. */


.-tray-placeholder {
	width: 93.75vw;
	min-height: 50vw;
	display: flex;
	gap: 2.1875vw;
	position: relative;
	flex-flow: column;
	align-items: center;
	aspect-ratio: 1/1;
	justify-content: center;
	clip-path: var(--squircle);
	background: var(--surface);
}

.-tray-placeholder .material-symbols-rounded {
	width: 15.625vw;
	height: 15.625vw;
	display: grid;
	place-items: center;
	color: var(--app-muted);
	font-size: 8.75vw;
	clip-path: var(--squircle);
	background: var(--dimmer);
}

.-tray-placeholder small {
	color: var(--app-muted);
	font-size: 3.4375vw;
	font-weight: 700;
	text-align: center;
}

.-tray-surface > .-horizontal-divider {
	top: -0.625vw;
}

.-tray-surface > .-horizontal-divider::before {
	top: 0;
	content: "";
	z-index: 40;
	height: 25vw;
	position: relative;
	border-radius: 50%;
	aspect-ratio: 1/1;
	pointer-events: auto;
}

.-tray-surface > .-horizontal-divider::after {
	top: 0;
	content: "";
	z-index: 40;
	height: 2.5vw;
	width: 9.375vw;
	position: absolute;
	pointer-events: none;
	border-radius: 6.25vw;
	background: var(--app-accent);
	margin: -0.9375vw auto;
	transition: margin 0.3s, background 0.3s;
	box-shadow: -0.3125vw -0.3125vw 0.9375vw #00000055;
}

.---horizontal-scroll .-tray-surface > .-horizontal-divider::after {
	margin: -1.5625vw auto;
	background: var(--app-blue);
}

.---horizontal-scroll .-tray-surface > .-horizontal-divider {
	top: 0;
	background: linear-gradient(90deg,#0000,color-mix(in srgb,var(--app-blue) 62%,transparent),#0000);
}

.-foot.---tray-at-top .-foot-lever {
	opacity: 1;
	pointer-events: auto;
}

.-tray-ripple {
	left: 50%;
	top: 50%;
	z-index: 85000;
	width: 25vw;
	height: 25vw;
	opacity: 0;
	position: fixed;
	border-radius: 50%;
	pointer-events: none;
	transform: translate(-50%, -50%) scale(1);
	border: 0.9375vw solid var(--tray-ripple-color, rgb(21 87 151 / 80%));
	box-shadow: 0 0 2.5vw var(--tray-ripple-color, rgb(21 87 151 / 80%));
}

.-tray-ripple.---ripple-go {
	animation: hivergo-tray-ripple 0.6s ease-out forwards;
}

.-hiver-gallery-tray-image {
	width: 93.75vw;
	min-height: 125vw;
	margin: 3.125vw auto;
	clip-path: var(--squircle);
	background-size: cover;
	background-repeat: no-repeat;
	background-position: center;
}

.-tray-tabbar {
	width: 93.75vw;
	display: flex;
	gap: 1.5625vw;
	padding: 1.5625vw;
	clip-path: var(--squircle);
	background: var(--dimmer);
}

.-tray-tab {
	flex: 1;
	display: grid;
	color: var(--app-muted);
	font-weight: 900;
	font-size: 3.125vw;
	min-height: 12.5vw;
	place-items: center;
	clip-path: var(--squircle);
	transition: color 0.2s ease, background 0.2s ease;
}

.-tray-tab.---active {
	color: #fff;
	background: var(--app-accent);
	box-shadow: 0 0.625vw 1.875vw color-mix(in srgb, var(--app-accent) 35%, transparent);
}

.-tray-content-widget {
	width: 93.75vw;
	flex: none;
	margin: 0;
}

.-tray-activity-item .-widget-label small {
	display: block;
	margin-top: .9375vw;
	color: var(--app-muted);
	font-size: 3.125vw;
	font-weight: 700;
}
