/**
 * SDC Footer Styles
 *
 * Footer section styles based on Figma design specifications.
 * Supports two variants: light (homepage) and dark (other pages).
 *
 * @package SDC_Theme
 * @since 0.1.0
 */

/* ========================================
   FOOTER CONTAINER
   ======================================== */

.sdc-footer {
	/* CSS Custom Properties for theming - Light variant (default) */
	--footer-bg: var(--color-base);
	--footer-text: var(--color-contrast);
	--footer-accent: var(--color-accent); /* Red for "Started?" on light */
	--colophon-bg: var(--color-muted);
	--colophon-text: var(--color-contrast);
	--divider-color: var(--color-secondary);

	width: 100%;
	background-color: var(--footer-bg);
	color: var(--footer-text);
}

/* ========================================
   DARK VARIANT (Other Pages)
   ======================================== */

.sdc-footer--dark {
	--footer-bg: var(--color-tertiary);
	--footer-text: var(--color-base);
	--footer-accent: var(--color-primary); /* Cyan for "Started?" on dark */
	--colophon-bg: var(--color-tertiary);
	--colophon-text: var(--color-base);

	background-color: var(--footer-bg);
	color: var(--footer-text);
}

/* ========================================
   CTA SECTION
   ======================================== */

.sdc-footer__cta {
	display: flex;
	flex-direction: row;
	justify-content: space-between;
	align-items: center;
	gap: var(--space-2xl);
	width: 100%;
	max-width: 1440px;
	margin-left: auto;
	margin-right: auto;
	padding: var(--space-7xl) 160px;
}

/* CTA Question Group - Icon + Headline */
.sdc-footer__cta-question {
	display: flex;
	flex-direction: row;
	align-items: center;
	gap: var(--space-2xl);
	flex: 1;
}

/* Sound Wave Icon */
.sdc-footer__cta-icon {
	display: block;
	width: 101px;
	height: 80px;
	flex-shrink: 0;
}

/* CTA Title - Uses text-h2 primitive, only footer-specific overrides */
.sdc-footer__cta-title {
	color: var(--footer-text);
	margin: 0;
}

/* CTA Button Wrapper */
.sdc-footer__cta-button {
	flex-shrink: 0;
}

/* Light variant button - larger text per Figma (25px / 120% line-height) */
.sdc-footer--light .sdc-footer__cta-button .btn {
	font-size: var(--text-h4);
	line-height: var(--leading-normal);
}

/* ========================================
   COLOPHON SECTION
   ======================================== */

.sdc-footer__colophon {
	display: flex;
	justify-content: center;
	align-items: center;
	width: 100%;
	max-width: 1440px;
	margin-left: auto;
	margin-right: auto;
	padding: var(--space-sm) var(--space-md);
}

/* Pill-shaped inner container */
.sdc-footer__colophon-inner {
	display: flex;
	flex-direction: row;
	justify-content: center;
	align-items: center;
	gap: var(--space-lg);
	padding: var(--space-sm) var(--space-lg);
	background-color: var(--colophon-bg);
	border-radius: var(--radius-xl);
	font-size: var(--text-body);
	line-height: var(--leading-loose);
}

/* Copyright Text - Uses text-body primitive, only footer-specific overrides */
.sdc-footer__copyright {
	color: var(--colophon-text);
}

/* Divider - Uses text-body primitive, only footer-specific overrides */
.sdc-footer__divider {
	color: var(--divider-color);
}

/* Privacy Link - Uses text-body primitive, only footer-specific overrides */
.sdc-footer__privacy-link {
	color: var(--colophon-text);
	text-decoration: none;
	transition: opacity 0.2s ease;
}

.sdc-footer__privacy-link:hover {
	opacity: 0.7;
	text-decoration: underline;
}

.sdc-footer__privacy-link:focus {
	outline: none;
}

.sdc-footer__privacy-link:focus-visible {
	outline: 2px solid var(--color-primary);
	outline-offset: 2px;
}

/* ========================================
   RESPONSIVE BREAKPOINTS
   ======================================== */

/* Tablet - 1024px and below */
@media (max-width: 1024px) {
	.sdc-footer__cta {
		padding: var(--space-6xl) 80px;
		gap: var(--space-xl);
	}

	.sdc-footer__cta-question {
		gap: var(--space-xl);
	}

	.sdc-footer__cta-icon {
		width: 80px;
		height: 64px;
	}

	.sdc-footer__cta-title {
		font-size: clamp(32px, 5vw, var(--text-h2));
	}
}

/* Tablet - 768px and below */
@media (max-width: 768px) {
	.sdc-footer__cta {
		flex-direction: column;
		align-items: flex-start;
		padding: var(--space-4xl) var(--site-padding);
		gap: var(--space-xl);
	}

	.sdc-footer__cta-question {
		flex-direction: column;
		align-items: flex-start;
		gap: var(--space-lg);
		width: 100%;
	}

	.sdc-footer__cta-icon {
		width: 60px;
		height: 48px;
	}

	.sdc-footer__cta-title {
		font-size: clamp(28px, 8vw, 32px);
		line-height: var(--leading-snug);
	}

	.sdc-footer__cta-button {
		width: 100%;
	}

	.sdc-footer__cta-button .btn {
		width: 100%;
	}

	.sdc-footer__colophon {
		padding: var(--space-sm) var(--site-padding);
	}

	.sdc-footer__colophon-inner {
		flex-wrap: wrap;
		gap: var(--space-sm) var(--space-md);
		padding: var(--space-sm) var(--space-md);
		text-align: center;
	}
}

/* Small Mobile - 480px and below */
@media (max-width: 480px) {
	.sdc-footer__cta {
		padding: var(--space-3xl) var(--site-padding);
	}

	.sdc-footer__cta-icon {
		width: 48px;
		height: 38px;
	}

	.sdc-footer__cta-title {
		font-size: clamp(24px, 7vw, 28px);
	}

	.sdc-footer__colophon-inner {
		flex-direction: column;
		gap: var(--space-xs);
		border-radius: var(--radius-lg);
	}

	.sdc-footer__divider {
		display: none;
	}
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

/* Focus styles for keyboard navigation */
.sdc-footer__cta-button .btn:focus {
	outline: none;
}

.sdc-footer__cta-button .btn:focus-visible {
	outline: 2px solid var(--color-primary);
	outline-offset: 2px;
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
	.sdc-footer__privacy-link,
	.sdc-footer__cta-button .btn {
		transition: none;
	}
}

/* High contrast mode support */
@media (prefers-contrast: high) {
	.sdc-footer__privacy-link:hover {
		text-decoration: underline;
		opacity: 1;
	}

	.sdc-footer__privacy-link:focus-visible,
	.sdc-footer__cta-button .btn:focus-visible {
		outline-width: 3px;
	}
}
