/* Surf City Apps modern showcase assets. Loaded after the legacy Grizzly CSS. */

.sca-modern-device #device-box {
	width: 285px !important;
	margin-left: 100px !important;
}

.sca-modern-device #device {
	position: relative;
	height: 589px !important;
	background: none !important;
	background-image: none !important;
}

.sca-clay-device {
	position: relative;
	width: 285px;
	height: 589px;
	isolation: isolate;
	overflow: visible;
}

.sca-clay-screen {
	position: absolute;
	z-index: 1;
	left: 5.447%;
	top: 3.247%;
	width: 89.105%;
	height: 93.553%;
	overflow: hidden;
	display: block;
}

.sca-clay-layer {
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	object-fit: contain;
	pointer-events: none;
}

.sca-clay-body { z-index: 2; }

/* Preserve Grizzly's separate floor shadow; only the mockup's own long shadow is omitted. */
.sca-modern-device #device-box .shadow-body {
	width: 150px !important;
}

.sca-modern-device #device-box .shadow {
	left: 50%;
	width: 270px;
	margin-left: -135px;
}

.sca-app-icon,
#apps-icon,
.app-icon > a > img,
.app-frame .app-info > img,
.apps-icon-list img {
	object-fit: cover;
	-webkit-mask-image: url("../images/app-icons-modern/squircle-mask.svg");
	-webkit-mask-position: center;
	-webkit-mask-repeat: no-repeat;
	-webkit-mask-size: 100% 100%;
	mask-image: url("../images/app-icons-modern/squircle-mask.svg");
	mask-position: center;
	mask-repeat: no-repeat;
	mask-size: 100% 100%;
}

/* The legacy icons included transparent space beneath the artwork. Preserve
 * that visual lift now that the modern icons use the full image canvas. */
#app-dock .app-balloon-toggle-link > img {
	position: relative;
	top: -10px;
}

@media only screen and (max-width: 767px) {
	/* The menu plugin owns the mobile hamburger. Collapse the legacy empty
	 * navigation row so it does not leave a large blank band below the logo. */
	#header-content {
		padding: 15px 0;
	}

	#branding {
		padding: 6px 0;
		margin-bottom: 0;
	}

	#primary-menu-container {
		line-height: 0;
	}

	#social-list:not(:has(li)) {
		display: none;
		margin: 0;
	}

	/* A 64px icon felt undersized beside the mobile app title. */
	#application-info-box #apps-icon {
		display: inline-block;
		width: 96px;
		height: 96px;
		margin-bottom: 16px;
	}

	/* Keep the English app title at the same mobile scale already used by the
	 * localized sites. The legacy media query otherwise forces it to 24px. */
	.single-app #apps-title {
		font-size: 34px;
		line-height: 1.25;
	}

	/* English pages can have several store buttons; their inherited 20px
	 * right margin shifts the entire group left. Center every button in the
	 * full information column without changing the button artwork itself. */
	.single-app #application-info-box .application-market-link {
		width: 100%;
		margin: 0 0 10px;
		text-align: center;
	}
}

/* Grizzly keeps its 720px tablet container through 1140px. Match that full
 * interval so the device does not switch to desktop offsets too early. */
@media only screen and (min-width: 768px) and (max-width: 1140px) {
	/* Remove the empty social-link line and the excess vertical padding that
	 * separated the tablet logo from the primary navigation. */
	#header-content {
		padding: 10px 10px 0;
	}

	#branding {
		padding: 5px 0;
	}

	#site-title img {
		padding-top: 0;
		padding-bottom: 0;
	}

	#social-list:not(:has(li)) {
		display: none;
		margin: 0;
	}

	.sca-modern-device #device-box {
		width: 280px !important;
		margin-left: 25px !important;
	}

	.sca-modern-device #device,
	.sca-modern-device .sca-clay-device {
		height: 579px !important;
	}

	.sca-modern-device .sca-clay-device {
		width: 280px;
	}

	.sca-modern-device #application-info-box {
		width: 360px;
		margin-right: 10px;
		margin-bottom: 48px;
	}
}
