/*
 * Sport-Buddy app landing pages (Cheer4Me, Fuel-Buddy, future apps).
 * Shared layout: hero, phone mockup, marquee, feature rows, steps, feature
 * grid, CTA, beta-notify popup. Loaded only by app landing templates:
 *   {% block css %}<link href="/css/sb-app-landing.css" rel="stylesheet">{% endblock %}
 * Markup helpers: templates/app_landing/_macros.html.twig, _notify.html.twig.
 *
 * The phone mockups render the real shared components (sb-components.css)
 * at a smaller font-size, so the mockup shows the actual app widgets.
 * Only var(--sb-*) colours.
 */

.sb-al * { box-sizing: border-box; }

/* ── Typography ── */
.sb-al-eyebrow {
	font-family: var(--sb-font-condensed);
	font-size: .6875rem;
	font-weight: 700;
	letter-spacing: .22em;
	text-transform: uppercase;
	color: var(--sb-color-orange);
	display: inline-flex;
	align-items: center;
	gap: .6rem;
	margin-bottom: 1rem;
}
.sb-al-eyebrow::before { content: ''; width: 2rem; height: 2px; background: var(--sb-color-orange); display: inline-block; }
.sb-al-eyebrow--center { justify-content: center; }
.sb-al-title {
	font-family: var(--sb-font-heading);
	color: var(--sb-color-navy);
	line-height: 1.05;
	font-size: clamp(1.9rem, 4vw, 3rem);
	margin: 0 0 1rem;
}
.sb-al-lead { color: var(--sb-color-text-body); font-size: 1.0625rem; line-height: 1.7; text-align: left; }
.sb-al-bullets { padding-left: 1.1rem; margin-top: 1rem; }

/* ── Hero ── */
.sb-al-hero {
	background: var(--sb-color-navy-dark);
	position: relative;
	overflow: hidden;
	padding: 4.5rem 0 5rem;
}
.sb-al-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	pointer-events: none;
	background:
		radial-gradient(ellipse 70% 60% at 80% 30%, rgba(var(--sb-color-orange-rgb), .12) 0%, transparent 60%),
		radial-gradient(ellipse 60% 70% at 0% 100%, rgba(var(--sb-color-navy-rgb), .7) 0%, transparent 55%);
}
.sb-al-hero > .container { position: relative; }
.sb-al-hero__title {
	font-family: var(--sb-font-heading);
	color: var(--sb-color-on-brand);
	line-height: 1.02;
	font-size: clamp(2.5rem, 6.5vw, 4.75rem);
	letter-spacing: -.01em;
	margin-bottom: 1.5rem;
}
.sb-al-hero__title em { font-style: normal; color: var(--sb-color-orange); position: relative; }
.sb-al-hero__title em::after {
	content: ''; position: absolute; left: 0; bottom: -4px; width: 100%; height: 3px;
	background: var(--sb-color-orange); border-radius: 2px;
}
.sb-al-hero__sub { color: rgba(255, 255, 255, .7); font-size: 1.0625rem; line-height: 1.7; max-width: 460px; margin-bottom: 2rem; text-align: inherit; }
.sb-al-hero .sb-al-stores { margin-bottom: 1.25rem; }
.sb-al-hero__note { color: rgba(255, 255, 255, .45); font-size: .8125rem; text-align: inherit; }
.sb-al-hero__note .fas { color: var(--sb-color-orange); }

/* ── Store buttons ── */
.sb-al-stores { display: flex; flex-wrap: wrap; gap: .75rem; }
.sb-al-store {
	display: inline-flex;
	align-items: center;
	gap: .7rem;
	text-decoration: none;
	border-radius: 1rem;
	padding: .7rem 1.25rem;
	background: rgba(255, 255, 255, .08);
	color: var(--sb-color-on-brand);
	border: 1px solid rgba(255, 255, 255, .18);
	backdrop-filter: blur(8px);
	transition: transform .15s, background-color .2s;
}
.sb-al-store:hover { transform: translateY(-3px); color: var(--sb-color-on-brand); background: rgba(255, 255, 255, .14); }
.sb-al-store .fab { font-size: 1.9rem; line-height: 1; }
.sb-al-store__sm { font-size: .625rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(255, 255, 255, .55); display: block; }
.sb-al-store__lg { font-family: var(--sb-font-heading); font-size: 1.1rem; line-height: 1.1; }

/* ── Phone mockup (renders shared components small) ── */
.sb-phone {
	width: 300px;
	max-width: 78vw;
	margin: 0 auto;
	position: relative;
	border-radius: 2.6rem;
	padding: .65rem;
	background: #0c0c1f;
	box-shadow: 0 30px 70px rgba(0, 0, 0, .4), inset 0 0 0 2px rgba(255, 255, 255, .06);
}
.sb-phone::before { /* notch */
	content: ''; position: absolute; top: .95rem; left: 50%; transform: translateX(-50%);
	width: 38%; height: 1.4rem; background: #0c0c1f; border-radius: 0 0 1rem 1rem; z-index: 3;
}
.sb-phone__screen {
	font-size: 11px; /* scale for the shared components inside */
	text-align: left; /* the app UI never inherits the centred mobile hero */
	border-radius: 2rem;
	overflow: hidden;
	background: var(--sb-color-background);
	aspect-ratio: 9 / 19.2;
	display: flex;
	flex-direction: column;
	color: var(--sb-color-ink);
}
.sb-phone__appbar {
	background: linear-gradient(90deg, var(--sb-color-navy), var(--sb-color-navy-light));
	color: var(--sb-color-on-brand);
	padding: 3.4em 1.2em 1em;
	display: flex;
	align-items: center;
	gap: .8em;
}
.sb-phone__appbar--web { background: linear-gradient(90deg, var(--sb-color-ink), var(--sb-color-text-body)); }
.sb-phone__avatar {
	width: 2.6em; height: 2.6em; border-radius: 50%;
	background: rgba(255, 255, 255, .25);
	display: flex; align-items: center; justify-content: center;
}
.sb-phone__title { font-weight: 700; font-size: 1.3em; letter-spacing: -.01em; }
.sb-phone__body { padding: 1em; display: flex; flex-direction: column; gap: .8em; overflow: hidden; flex: 1; }
.sb-phone__body > .sb-card,
.sb-phone__body .sb-metric-tile { box-shadow: none; }
.sb-phone .sb-card { padding: 1em 1.1em; }

/* Mockup-only helpers */
.sb-mock-hero {
	border-radius: var(--sb-radius-lg-em);
	padding: 1em 1.1em;
	color: var(--sb-color-on-brand);
	background: linear-gradient(135deg, var(--sb-color-navy), var(--sb-color-navy-light));
}
.sb-mock-hero--success { background: linear-gradient(135deg, var(--sb-color-success-dark), var(--sb-color-success)); }
.sb-mock-hero--green { background: linear-gradient(135deg, var(--sb-color-success-dark), var(--sb-color-green)); }
.sb-mock-hero__row { display: flex; align-items: center; justify-content: space-between; gap: .5em; }
.sb-mock-hero__name { font-weight: 800; font-size: 1.15em; }
.sb-mock-hero__big { font-size: 2.3em; font-weight: 800; letter-spacing: -.02em; margin-top: .2em; }
.sb-mock-hero__big small { font-size: .5em; font-weight: 600; opacity: .8; }
.sb-mock-hero__meta { font-size: .85em; opacity: .8; }
.sb-mock-label { font-size: .85em; color: var(--sb-color-text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; margin-bottom: .3em; }
.sb-mock-row { display: flex; align-items: center; gap: .75em; padding: .45em 0; border-bottom: 1px solid var(--sb-color-divider); }
.sb-mock-row:last-child { border-bottom: 0; }
.sb-mock-row .sb-icon-badge { --sb-badge-size: 2.3em; }
.sb-mock-row__name { flex: 1; font-weight: 700; font-size: 1em; }
.sb-mock-row__sub { font-size: .8em; color: var(--sb-color-text-muted); font-weight: 400; }
.sb-mock-row__value { font-weight: 800; font-variant-numeric: tabular-nums; }
.sb-mock-row__value--muted { font-weight: 400; color: var(--sb-color-text-muted); font-size: .9em; }
.sb-mock-dashed { border-style: dashed !important; }
.sb-mock-map {
	border-radius: var(--sb-radius-md-em);
	aspect-ratio: 16 / 10;
	position: relative;
	overflow: hidden;
	border: 1px solid var(--sb-color-divider);
	background:
		linear-gradient(90deg, var(--sb-color-border-strong) 1px, transparent 1px) 0 0 / 25% 25%,
		linear-gradient(var(--sb-color-border-strong) 1px, transparent 1px) 0 0 / 25% 25%,
		var(--sb-color-surface-alt);
}
.sb-mock-map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.sb-mock-chips { display: flex; align-items: center; gap: .5em; }
.sb-mock-hist { display: flex; align-items: flex-end; gap: 3px; height: 5em; padding: .2em 0; }
.sb-mock-hist > span { flex: 1; background: var(--sb-color-border-strong); border-radius: 3px 3px 0 0; }
.sb-mock-hist > span.is-me { background: var(--sb-color-orange); }

/* ── Marquee ── */
.sb-al-marquee { background: var(--sb-color-orange); padding: .8rem 0; overflow: hidden; white-space: nowrap; }
.sb-al-marquee__in { display: inline-flex; animation: sb-al-marquee 28s linear infinite; }
.sb-al-marquee__item {
	font-family: var(--sb-font-heading); font-size: .85rem; color: var(--sb-color-on-brand);
	text-transform: uppercase; letter-spacing: .06em; padding: 0 2.25rem;
	display: inline-flex; align-items: center; gap: .9rem;
}
.sb-al-marquee__item::after { content: ''; width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, .55); }
@keyframes sb-al-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .sb-al-marquee__in { animation: none; } }

/* ── Sections ── */
.sb-al-section { padding: 5rem 0; }
.sb-al-section--alt { background: var(--sb-color-surface-alt); }

/* ── Steps & feature cards (page-sized SbCard) ── */
.sb-al-steps { counter-reset: sb-step; }
.sb-al-card { font-size: 1rem; height: 100%; padding: 1.75rem; }
.sb-al-card .sb-icon-badge { margin-bottom: 1rem; }
.sb-al-step__num {
	counter-increment: sb-step;
	font-family: var(--sb-font-heading);
	font-size: 1.1rem;
}
.sb-al-step__num::before { content: counter(sb-step); }
.sb-al-card__title { font-family: var(--sb-font-heading); color: var(--sb-color-navy); font-size: 1.2rem; margin-bottom: .4rem; }
.sb-al-card__body { color: var(--sb-color-text-body); font-size: .95rem; line-height: 1.6; margin: 0; }

/* ── Final CTA ── */
.sb-al-cta { background: var(--sb-color-navy-dark); padding: 6rem 0; position: relative; overflow: hidden; text-align: center; }
.sb-al-cta::before {
	content: ''; position: absolute; top: -40%; left: -10%; width: 55%; aspect-ratio: 1; border-radius: 50%;
	background: radial-gradient(circle, rgba(var(--sb-color-orange-rgb), .1) 0%, transparent 65%);
}
.sb-al-cta__title { font-family: var(--sb-font-heading); color: var(--sb-color-on-brand); font-size: clamp(2rem, 4.5vw, 3.25rem); line-height: 1.05; margin-bottom: 1rem; position: relative; }
.sb-al-cta__body { text-align: inherit; color: rgba(255, 255, 255, .65); font-size: 1.0625rem; line-height: 1.65; max-width: 520px; margin: 0 auto 2.5rem; position: relative; }
.sb-al-cta .sb-al-stores { justify-content: center; position: relative; }

/* ── Beta-notify popup (fancybox content) ── */
.sb-al-notify { background: var(--sb-color-surface); border-radius: var(--sb-radius-lg); padding: 2rem; max-width: 440px; }
.fancybox-content.sb-al-notify { max-width: 440px; } /* fancybox sets max-width:100% after us */
.sb-al-notify__title { font-family: var(--sb-font-heading); color: var(--sb-color-navy); font-size: 1.4rem; margin: .25rem 0 .6rem; }
.sb-al-notify__body { color: var(--sb-color-text-body); font-size: .95rem; line-height: 1.6; margin-bottom: 1.25rem; }
.sb-al-notify .form-label { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--sb-color-navy); }
.sb-al-notify__help { color: var(--sb-color-text-muted); font-size: .78rem; margin: .45rem 0 1.1rem; }
.sb-al-notify__status { font-size: .85rem; margin: .9rem 0 0; min-height: 1.1rem; }
.sb-al-notify__status.is-ok { color: var(--sb-color-success); }
.sb-al-notify__status.is-error { color: var(--sb-color-danger); }
.sb-al-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

@media (max-width: 991px) {
	.sb-al-hero { padding: 3rem 0 3.5rem; text-align: center; }
	.sb-al-hero__sub { margin-left: auto; margin-right: auto; }
	.sb-al-hero .sb-al-stores, .sb-al-hero .sb-al-eyebrow { justify-content: center; }
	.sb-al-hero__visual { margin-top: 3rem; }
}

/* ── Card CTA line (e.g. homepage service cards) ── */
.sb-al-card__cta {
	font-size: .75rem;
	font-weight: 700;
	letter-spacing: .1em;
	text-transform: uppercase;
	color: var(--sb-color-orange);
}
.sb-card--link:hover .sb-al-card__cta { color: var(--sb-color-orange-dark); }

/* ── Showcase: navy panel with a tag, a headline and on-dark metric tiles ── */
.sb-al-showcase {
	position: relative;
	overflow: hidden;
	border-radius: var(--sb-radius-xl);
	padding: 2.25rem;
	color: var(--sb-color-on-brand);
	background: linear-gradient(135deg, var(--sb-color-navy-dark), var(--sb-color-navy-light));
	box-shadow: 0 24px 60px rgba(var(--sb-color-navy-rgb), .25);
}
.sb-al-showcase::before {
	content: '';
	position: absolute;
	top: -30%;
	right: -20%;
	width: 60%;
	aspect-ratio: 1;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(var(--sb-color-orange-rgb), .18) 0%, transparent 65%);
	pointer-events: none;
}
.sb-al-showcase > * { position: relative; }
.sb-al-showcase__tag {
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	font-size: .7rem;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--sb-color-orange);
	margin-bottom: .75rem;
}
.sb-al-showcase__title {
	font-family: var(--sb-font-heading);
	font-size: clamp(1.4rem, 2.6vw, 1.9rem);
	line-height: 1.15;
	margin-bottom: 1.5rem;
}
.sb-al-showcase .sb-metric-grid { gap: .875rem; font-size: 1.1rem; }
