.gcapp-card {
	position: fixed; z-index: 9999; left: 50%; bottom: 16px;
	width: min(560px, calc(100% - 24px));
	display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
	background: #000; color: #e2e1e1;
	border: 1px solid #2a2a2a; border-top: 3px solid #f90f14; border-radius: 6px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, .45);
	padding: 14px 16px;
	transform: translate(-50%, 140%); opacity: 0;
	transition: transform .3s ease, opacity .3s ease;
	font-size: 15px; line-height: 1.4;
}
.gcapp-card.is-on { transform: translate(-50%, 0); opacity: 1; }
.gcapp-card img { flex: 0 0 auto; border-radius: 8px; }
.gcapp-card__text { flex: 1 1 220px; min-width: 0; }
.gcapp-card__text strong { display: block; color: #fff; font-family: var(--gc-font-display, inherit); font-size: 1.08em; text-transform: uppercase; letter-spacing: .02em; }
.gcapp-card__text span { display: block; color: #bdbcbc; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; font-size: .95em; }
.gcapp-card__btns { display: flex; gap: 8px; margin-left: auto; }
.gcapp-card button { font: inherit; font-family: var(--gc-font-display, inherit); font-size: 1.05em; letter-spacing: .01em; font-weight: 700; border-radius: 4px; padding: .55em 1em; cursor: pointer; border: 0; }
.gcapp-yes { background: #d50b11; color: #fff; }
.gcapp-yes:hover { background: #f90f14; }
.gcapp-no { background: transparent; color: #bdbcbc; border: 1px solid #444 !important; }
.gcapp-no:hover { color: #fff; border-color: #888 !important; }
.gcapp-card button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.gcapp-alerts-btn { font: inherit; font-weight: 700; background: #d50b11; color: #fff; border: 0; border-radius: 4px; padding: .6em 1.1em; cursor: pointer; }
.gcapp-alerts-btn[data-state="on"] { background: #2f6b3a; cursor: default; }
.gcapp-link { font: inherit; background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; cursor: pointer; }
@media (prefers-reduced-motion: reduce) { .gcapp-card { transition: none; } }

/* ===================== App shell (home-screen app only) ===================== */
html.gcapp-standalone { --gcapp-tab-h: 62px; --gcapp-safe-b: env(safe-area-inset-bottom, 0px); }
html.gcapp-standalone body {
	padding-bottom: calc(var(--gcapp-tab-h) + var(--gcapp-safe-b));
	padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px);
	-webkit-tap-highlight-color: transparent; overscroll-behavior-y: none;
}
html.gcapp-lock, html.gcapp-lock body { overflow: hidden; }

/* Header stays reachable; the website's Menu/Advertise buttons give way to the tab bar on phones. */
html.gcapp-standalone .gc-header { position: sticky; top: 0; z-index: 9980; padding-top: env(safe-area-inset-top, 0px); }
html.gcapp-standalone .gc-skip { display: none; }
@media (max-width: 900px) {
	html.gcapp-standalone .gc-nav-toggle,
	html.gcapp-standalone .gc-header__cta,
	html.gcapp-standalone .gc-nav { display: none !important; }
	html.gcapp-standalone .gc-header__bar { min-height: 56px; }
	html.gcapp-standalone .gc-header .gc-brand img { height: 36px; width: auto; }
}

/* Back button */
html.gcapp-standalone .gcapp-back {
	display: inline-flex; align-items: center; gap: .15rem; flex: 0 0 auto;
	background: none; border: 0; color: #e2e1e1; cursor: pointer;
	font-family: var(--gc-font-display, system-ui); font-weight: 700; font-size: 1rem;
	padding: .4rem .55rem .4rem .1rem; margin-right: .35rem; min-height: 44px; border-radius: 6px;
}
html.gcapp-standalone .gcapp-back svg { width: 26px; height: 26px; }
html.gcapp-standalone .gcapp-back:active { background: #1a1a1a; }
html.gcapp-standalone .gcapp-back.is-hidden { display: none; }
html.gcapp-standalone .gcapp-back:not(.is-inline) {
	position: fixed; z-index: 9985; top: calc(8px + env(safe-area-inset-top, 0px)); left: 8px;
	background: rgba(0, 0, 0, .85); padding-right: .8rem;
}
@media (max-width: 400px) { html.gcapp-standalone .gcapp-back span { display: none; } }

/* Bottom tab bar */
html.gcapp-standalone .gcapp-tabbar {
	display: flex; position: fixed; z-index: 9990; left: 0; right: 0; bottom: 0;
	height: calc(var(--gcapp-tab-h) + var(--gcapp-safe-b)); padding: 0 env(safe-area-inset-right, 0px) var(--gcapp-safe-b) env(safe-area-inset-left, 0px);
	background: #000; border-top: 1px solid #262626;
}
@media (min-width: 901px) {
	html.gcapp-standalone .gcapp-tabbar { display: none; }
	html.gcapp-standalone body { padding-bottom: 0; }
}
.gcapp-tab {
	flex: 1 1 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
	background: none; border: 0; color: #9d9c9c; text-decoration: none; cursor: pointer; position: relative;
	font-family: var(--gc-font-display, system-ui); font-size: 12px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase;
	min-width: 0; padding: 6px 2px 4px;
}
.gcapp-tab svg { width: 24px; height: 24px; }
.gcapp-tab.is-active, .gcapp-tab[aria-expanded="true"] { color: #fff; }
.gcapp-tab.is-active::before { content: ""; position: absolute; top: 0; left: 28%; right: 28%; height: 3px; background: #f90f14; border-radius: 0 0 3px 3px; }
.gcapp-tab[data-tab="alerts"][data-state="on"] { color: #e2e1e1; }
.gcapp-tab[data-tab="alerts"][data-state="on"] svg { fill: #f90f14; stroke: #f90f14; }
.gcapp-tab:active { background: #111; }
.gcapp-tab:focus-visible { outline: 2px solid #fff; outline-offset: -4px; }

/* Bottom sheets */
html.gcapp-standalone .gcapp-sheet:not([hidden]) {
	display: block; position: fixed; inset: 0; z-index: 9995; background: rgba(0, 0, 0, 0); transition: background .25s ease;
}
html.gcapp-standalone .gcapp-sheet.is-open { background: rgba(0, 0, 0, .55); }
.gcapp-sheet__panel {
	position: absolute; left: 0; right: 0; bottom: 0; max-height: 82vh; display: flex; flex-direction: column;
	background: #0c0c0c; color: #e2e1e1; border-top: 3px solid #f90f14; border-radius: 14px 14px 0 0;
	padding-bottom: calc(var(--gcapp-tab-h) + var(--gcapp-safe-b) + 8px);
	transform: translateY(100%); transition: transform .25s ease;
}
.gcapp-sheet.is-open .gcapp-sheet__panel { transform: translateY(0); }
.gcapp-sheet__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 8px; }
.gcapp-sheet__head strong { font-family: var(--gc-font-display, system-ui); font-size: 1.35rem; text-transform: uppercase; letter-spacing: .02em; color: #fff; }
.gcapp-sheet__close { background: #1c1c1c; border: 0; color: #e2e1e1; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; }
.gcapp-sheet__body { overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 0 16px 8px; }
.gcapp-sheet__body h3 { margin: 14px 0 4px; font-family: var(--gc-font-display, system-ui); font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; color: #f90f14; }
.gcapp-sheet__body ul { list-style: none; margin: 0; padding: 0; }
.gcapp-sheet__body a {
	display: flex; align-items: center; justify-content: space-between; min-height: 50px; padding: 0 4px;
	border-bottom: 1px solid #1f1f1f; color: #fff; text-decoration: none;
	font-family: var(--gc-font-display, system-ui); font-size: 1.2rem; font-weight: 600;
}
.gcapp-sheet__body a svg { width: 18px; height: 18px; color: #6d6d6d; }
.gcapp-sheet__body a.is-current { color: #f90f14; }
.gcapp-sheet__body a:active { background: #161616; }
.gcapp-search { display: flex; gap: 8px; padding: 6px 16px 14px; }
.gcapp-search input { flex: 1; min-width: 0; font-size: 17px; padding: .8rem .9rem; border-radius: 8px; border: 1px solid #333; background: #161616; color: #fff; }
.gcapp-search input:focus { outline: 2px solid #f90f14; outline-offset: 0; }
.gcapp-search button { width: 54px; border: 0; border-radius: 8px; background: #d50b11; color: #fff; display: grid; place-items: center; cursor: pointer; }

/* Loading bar */
html.gcapp-standalone .gcapp-progress {
	display: block; position: fixed; z-index: 9999; top: env(safe-area-inset-top, 0px); left: 0; height: 3px; width: 0;
	background: #f90f14; box-shadow: 0 0 8px rgba(249, 15, 20, .6); pointer-events: none; opacity: 0;
}
html.gcapp-standalone .gcapp-progress.is-on { opacity: 1; animation: gcapp-load 8s cubic-bezier(.1, .7, .2, 1) forwards; }
@keyframes gcapp-load { from { width: 0; } 15% { width: 45%; } to { width: 90%; } }

/* Toast */
html.gcapp-standalone .gcapp-toast {
	display: block; position: fixed; z-index: 9996; left: 50%; bottom: calc(var(--gcapp-tab-h) + var(--gcapp-safe-b) + 12px);
	max-width: calc(100% - 32px); transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
	background: #1b1b1b; color: #fff; border-left: 3px solid #f90f14; border-radius: 6px; padding: .7rem 1rem;
	font: 600 15px/1.35 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; box-shadow: 0 8px 28px rgba(0, 0, 0, .5);
	transition: opacity .2s ease, transform .2s ease;
}
html.gcapp-standalone .gcapp-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* Prompts sit above the tab bar in the app */
html.gcapp-standalone .gcapp-card { bottom: calc(var(--gcapp-tab-h) + var(--gcapp-safe-b) + 12px); }
@media (min-width: 901px) { html.gcapp-standalone .gcapp-card, html.gcapp-standalone .gcapp-toast { bottom: 16px; } }
@media (prefers-reduced-motion: reduce) { .gcapp-sheet__panel, .gcapp-toast { transition: none; } html.gcapp-standalone .gcapp-progress.is-on { animation-duration: .01s; } }
/* Search opens from the top so the phone keyboard never covers it. */
#gcapp-search .gcapp-sheet__panel {
	top: 0; bottom: auto; max-height: none; border-radius: 0 0 14px 14px; border-top: 0; border-bottom: 3px solid #f90f14;
	padding-top: env(safe-area-inset-top, 0px); padding-bottom: 6px; transform: translateY(-100%);
}
#gcapp-search.is-open .gcapp-sheet__panel { transform: translateY(0); }
