/*
 * Footer Component — Maximus-inspired multi-column layout
 *
 * Dynamic columns from centralized nav data. Full-width background,
 * treatment protocol sub-links, Maximus typography + accent borders.
 */

/* ==========================================================================
   Footer — Base
   ========================================================================== */

.gambit-footer {
	background-color: #131316;
	color: var(--off-white);
	position: relative;
	overflow: hidden;
}

/* Subtle red gradient accent at top */
.gambit-footer::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 1px;
	background: linear-gradient(
		90deg,
		transparent,
		rgba(196, 61, 47, 0.3),
		transparent
	);
}

/* ==========================================================================
   Footer Main Content
   ========================================================================== */

.gambit-footer__main {
	padding-top: 48px;
	padding-bottom: 40px;
}

.gambit-footer__grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 32px 24px;
}

/* ==========================================================================
   Brand Column
   ========================================================================== */

.gambit-footer__col--brand {
	grid-column: 1 / -1;
}

.gambit-footer__logo {
	display: inline-block;
	text-decoration: none;
	color: var(--warm-white);
	margin-bottom: 16px;
}

.gambit-footer__logo-img {
	height: 100px;
	width: auto;
	display: block;
}

.gambit-footer__tagline {
	font-family: var(--font-heading);
	font-weight: 500;
	font-size: 15px;
	color: var(--signal-red);
	margin: 0 0 10px;
}

.gambit-footer__desc {
	font-size: 13px;
	line-height: 1.7;
	color: var(--off-white);
	opacity: 0.5;
	margin: 0;
	max-width: none;
}

/* ==========================================================================
   Section Headings — Maximus style (mono, uppercase, muted)
   ========================================================================== */

.gambit-footer__heading {
	font-family: var(--font-mono);
	font-weight: 400;
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: 1.1px;
	color: var(--warm-white);
	opacity: 0.5;
	margin: 0 0 18px;
}

/* ==========================================================================
   Link Lists — left accent border + hover bar
   Matches Maximus list--ca790: padding 6px 0 6px 16px, ::before left border
   ========================================================================== */

.gambit-footer__links {
	list-style: none;
	padding: 6px 0 6px 16px;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 16px;
	position: relative;
}

/* Vertical left border */
.gambit-footer__links::before {
	content: "";
	position: absolute;
	left: 0;
	top: 6px;
	bottom: 6px;
	width: 1px;
	background: var(--off-white);
	opacity: 0.15;
}

.gambit-footer__links a {
	color: var(--off-white);
	opacity: 0.6;
	text-decoration: none;
	font-size: 13px;
	line-height: 1.4;
	position: relative;
	display: inline-block;
	transition: opacity 0.2s ease, color 0.2s ease;
}

.gambit-footer__links a:hover {
	color: var(--warm-white);
	opacity: 1;
}

/* Red accent bar on hover — Gambit brand touch */
.gambit-footer__links a::before {
	content: "";
	position: absolute;
	left: -16px;
	top: 0;
	bottom: 0;
	width: 2px;
	background: var(--signal-red);
	opacity: 0;
	transition: opacity 0.3s ease;
}

.gambit-footer__links a:hover::before {
	opacity: 1;
}

/* ==========================================================================
   CTA Column — vertical left border like every other column
   Maximus: link-sign-up = bg:#edece5, color:#121212, border-radius:30px,
   padding:8px 18px, font-size:12px. On mobile: border-radius:14px, 4px 12px.
   ========================================================================== */

.gambit-footer__col--cta {
	display: flex;
	flex-direction: column;
	gap: 16px;
	justify-content: flex-start;
	align-items: flex-start;
	padding-left: 16px;
	position: relative;
}

/* Vertical left border — always present, matching Maximus */
.gambit-footer__col--cta::before {
	content: "";
	position: absolute;
	left: 0;
	top: 6px;
	bottom: 6px;
	width: 1px;
	background: var(--off-white);
	opacity: 0.2;
}

/* Shared pill sizing for footer CTA buttons */
.gambit-footer__col--cta .gambit-btn,
.gambit-footer__login-link {
	display: inline-block;
	padding: 4px 12px;
	font-size: 12px;
	line-height: 16px;
	border-radius: 14px;
	text-align: center;
	white-space: nowrap;
}

/* Reset global .gambit-btn overrides inside footer CTA */
.gambit-footer__col--cta .gambit-btn {
	min-height: auto; /* reset global 48px min-height */
	width: auto;
}

.gambit-footer__login-link {
	font-family: var(--font-heading);
	font-weight: 500;
	color: var(--off-white);
	background: hsla(53, 18%, 91%, 0.2);
	text-decoration: none;
	transition: opacity 0.2s ease;
}

.gambit-footer__login-link:hover {
	opacity: 0.8;
}

/* ==========================================================================
   Bottom Bar — matches Maximus layout exactly
   Maximus: flex, justify-content:space-between, padding-top:40px
   Mobile (≤700px): column-reverse, gap:32px
   Structure: [socials] [badges: inc+legitscript]
   Copyright sits below everything.
   ========================================================================== */

.gambit-footer__bottom {
	border-top: 1px solid var(--warm-white-6);
	padding: 40px 0 24px;
}

.gambit-footer__bottom-inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 32px;
}

/* Row that holds socials on left and badges on right */
.gambit-footer__bottom-row {
	display: flex;
	flex-direction: column-reverse;
	align-items: center;
	gap: 32px;
	width: 100%;
}

/* Copyright always at the very bottom */
.gambit-footer__copyright {
	font-size: 12px;
	color: var(--off-white);
	opacity: 0.35;
	margin: 0;
	text-align: center;
}

/* ==========================================================================
   Social Links — Maximus: 40×40 icons, gap:16px, filled SVGs
   ========================================================================== */

.gambit-footer__social {
	display: flex;
	align-items: center;
	gap: 16px;
}

.gambit-footer__social-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	color: var(--off-white);
	text-decoration: none;
	transition: opacity 0.4s ease;
}

.gambit-footer__social-link:hover {
	opacity: 0.7;
}

/* ==========================================================================
   Badges — maple leaf + LegitScript
   Maximus: icons container = flex, gap:16px, justify-content:space-between
   Inc badge = 76px tall, 198px wide. LegitScript = 76×76.
   ========================================================================== */

.gambit-footer__badges {
	display: flex;
	align-items: center;
	gap: 16px;
}

/* Maple leaf Canadian badge */
.gambit-footer__badge-canada {
	display: flex;
	align-items: center;
	gap: 10px;
}

.gambit-footer__maple-leaf {
	flex-shrink: 0;
}

.gambit-footer__badge-text {
	color: var(--off-white);
	font-size: 13px;
	line-height: 1.3;
	white-space: nowrap;
}

/* LegitScript seal — 76×76 to match Maximus */
.gambit-footer__legitscript {
	display: block;
	flex-shrink: 0;
	transition: opacity 0.4s ease;
}

.gambit-footer__legitscript:hover {
	opacity: 0.7;
}

.gambit-footer__legitscript-img {
	height: 76px;
	width: 76px;
	object-fit: contain;
	display: block;
}

/* ==========================================================================
   Small desktop — ≥ 768px
   Maximus bottom: flex-row, justify-content:space-between
   ========================================================================== */

@media (min-width: 768px) {
	.gambit-footer__bottom-row {
		flex-direction: row;
		justify-content: space-between;
		align-items: center;
	}

	.gambit-footer__copyright {
		text-align: right;
	}
}

/* ==========================================================================
   Desktop — ≥ 1100px (full 7-column grid)
   ========================================================================== */

@media (min-width: 1100px) {
	.gambit-footer__main {
		padding-top: 72px;
		padding-bottom: 56px;
	}

	/* 7 cols = brand + featured_count(3) + overflow + company + cta.
	   Update if gambit_get_footer_config() featured_count changes. */
	.gambit-footer__grid {
		grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr 1fr 1.1fr;
		gap: 40px;
	}

	.gambit-footer__col--brand {
		grid-column: auto;
		margin-bottom: 0;
	}

	.gambit-footer__logo-img {
		height: 56px;
	}

	.gambit-footer__desc {
		max-width: 280px;
	}

	.gambit-footer__cta-btn {
		width: 100%;
	}

	.gambit-footer__col--cta {
		padding-left: 16px;
	}

	/* Desktop pill sizing — visually match Maximus footer CTAs */
	.gambit-footer__col--cta .gambit-btn,
	.gambit-footer__login-link {
		padding: 12px 24px;
		border-radius: 30px;
	}
}
