/**
 * Footer styles for Econopapi theme.
 *
 * @package EconopapiWP
 */

/* ==========================================================================
   Footer Base Styles
   ========================================================================== */

.eco-site-footer {
	--eco-footer-bg: #f8f9fc;
	--eco-footer-surface: #ffffff;
	--eco-footer-border: #e2e6f0;
	--eco-footer-text: #1e2130;
	--eco-footer-muted: #676d82;
	--eco-footer-accent: #5f58d8;
	--eco-footer-accent-soft: rgba(95, 88, 216, 0.1);
	--eco-footer-shadow: 0 -4px 20px rgba(33, 35, 53, 0.05);
	
	background: var(--eco-footer-bg);
	border-top: 1px solid var(--eco-footer-border);
	color: var(--eco-footer-text);
	padding: 3rem 0 2rem;
	margin-top: auto;
	position: relative;
	z-index: 10;
	width: 100%;
	clear: both;
	float: none;
}

.eco-site-footer__inner {
	display: flex;
	flex-direction: column;
	gap: 3rem;
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 20px;
	width: 100%;
	box-sizing: border-box;
}

/* Dark mode variables */
body.theme-dark .eco-site-footer,
body[data-theme="dark"] .eco-site-footer {
	--eco-footer-bg: #0b0d17;
	--eco-footer-surface: #111523;
	--eco-footer-border: #232940;
	--eco-footer-text: #e7ebf9;
	--eco-footer-muted: #9ca4bf;
	--eco-footer-accent: #857cff;
	--eco-footer-accent-soft: rgba(133, 124, 255, 0.16);
	--eco-footer-shadow: 0 -4px 20px rgba(3, 6, 18, 0.4);
}

@media (prefers-color-scheme: dark) {
	body:not([data-theme="light"]) .eco-site-footer {
		--eco-footer-bg: #0b0d17;
		--eco-footer-surface: #111523;
		--eco-footer-border: #232940;
		--eco-footer-text: #e7ebf9;
		--eco-footer-muted: #9ca4bf;
		--eco-footer-accent: #857cff;
		--eco-footer-accent-soft: rgba(133, 124, 255, 0.16);
		--eco-footer-shadow: 0 -4px 20px rgba(3, 6, 18, 0.4);
	}
}

/* ==========================================================================
   Footer Main Area (Widgets)
   ========================================================================== */

.eco-footer-main__grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 2.5rem;
	margin-bottom: 2rem;
}

.eco-footer-widget {
	background: var(--eco-footer-surface);
	border-radius: 1rem;
	padding: 1.75rem;
	box-shadow: var(--eco-footer-shadow);
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.eco-footer-widget:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 30px rgba(33, 35, 53, 0.12);
}

body.theme-dark .eco-footer-widget:hover,
body[data-theme="dark"] .eco-footer-widget:hover {
	box-shadow: 0 8px 30px rgba(3, 6, 18, 0.5);
}

.eco-footer-widget__title {
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--eco-footer-text);
	margin: 0 0 1.25rem 0;
	padding-bottom: 0.75rem;
	border-bottom: 2px solid var(--eco-footer-accent-soft);
}

.eco-footer-widget ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.eco-footer-widget li {
	margin-bottom: 0.75rem;
}

.eco-footer-widget a {
	color: var(--eco-footer-muted);
	text-decoration: none;
	transition: color 0.2s ease;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
}

.eco-footer-widget a:hover,
.eco-footer-widget a:focus {
	color: var(--eco-footer-accent);
}

.eco-footer-widget a::before {
	content: "→";
	opacity: 0;
	transform: translateX(-0.5rem);
	transition: opacity 0.2s ease, transform 0.2s ease;
}

.eco-footer-widget a:hover::before,
.eco-footer-widget a:focus::before {
	opacity: 1;
	transform: translateX(0);
}

/* ==========================================================================
   Footer Bottom Area
   ========================================================================== */

.eco-footer-bottom {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	gap: 1.5rem;
	padding-top: 2rem;
}

.eco-footer-bottom__left {
	flex: 1;
	min-width: 200px;
}

.eco-footer-bottom__right {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 2rem;
}

.eco-footer-copyright__text {
	margin: 0;
	font-size: 0.875rem;
	color: var(--eco-footer-muted);
	line-height: 1.5;
}

.eco-footer-copyright a {
	color: var(--eco-footer-accent);
	text-decoration: none;
	transition: opacity 0.2s ease;
}

.eco-footer-copyright a:hover,
.eco-footer-copyright a:focus {
	opacity: 0.8;
	text-decoration: underline;
}

/* ==========================================================================
   Footer Navigation
   ========================================================================== */

.eco-footer-nav__list {
	display: flex;
	flex-wrap: wrap;
	gap: 1.5rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.eco-footer-nav__list a {
	color: var(--eco-footer-muted);
	text-decoration: none;
	font-size: 0.875rem;
	font-weight: 500;
	transition: color 0.2s ease;
	padding: 0.25rem 0;
	position: relative;
}

.eco-footer-nav__list a:hover,
.eco-footer-nav__list a:focus {
	color: var(--eco-footer-accent);
}

.eco-footer-nav__list a::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 0;
	height: 2px;
	background: var(--eco-footer-accent);
	transition: width 0.3s ease;
}

.eco-footer-nav__list a:hover::after,
.eco-footer-nav__list a:focus::after {
	width: 100%;
}

/* ==========================================================================
   Social Links
   ========================================================================== */

.eco-social-links {
	display: flex;
	gap: 0.75rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.eco-social-links__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.5rem;
	height: 2.5rem;
	border-radius: 0.75rem;
	background: var(--eco-footer-surface);
	color: var(--eco-footer-muted);
	text-decoration: none;
	transition: all 0.25s ease;
	border: 1px solid var(--eco-footer-border);
}

.eco-social-links__link:hover,
.eco-social-links__link:focus {
	background: var(--eco-footer-accent);
	color: white;
	border-color: var(--eco-footer-accent);
	transform: translateY(-2px);
	box-shadow: 0 6px 16px rgba(95, 88, 216, 0.25);
}

body.theme-dark .eco-social-links__link:hover,
body[data-theme="dark"] .eco-social-links__link:hover {
	box-shadow: 0 6px 16px rgba(133, 124, 255, 0.3);
}

.eco-social-links__icon {
	display: inline-block;
	width: 1.25rem;
	height: 1.25rem;
	background: currentColor;
	mask-size: contain;
	mask-repeat: no-repeat;
	mask-position: center;
}

.eco-icon--twitter {
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M23.953 4.57a10 10 0 01-2.825.775 4.958 4.958 0 002.163-2.723c-.951.555-2.005.959-3.127 1.184a4.92 4.92 0 00-8.384 4.482C7.69 8.095 4.067 6.13 1.64 3.162a4.822 4.822 0 00-.666 2.475c0 1.71.87 3.213 2.188 4.096a4.904 4.904 0 01-2.228-.616v.06a4.923 4.923 0 003.946 4.827 4.996 4.996 0 01-2.212.085 4.936 4.936 0 004.604 3.417 9.867 9.867 0 01-6.102 2.105c-.39 0-.779-.023-1.17-.067a13.995 13.995 0 007.557 2.213c9.053 0 13.998-7.496 13.998-13.985 0-.21 0-.42-.015-.63A9.935 9.935 0 0024 4.59z'/%3E%3C/svg%3E");
}

.eco-icon--linkedin {
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z'/%3E%3C/svg%3E");
}

.eco-icon--github {
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12'/%3E%3C/svg%3E");
}

.eco-icon--instagram {
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 0-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838c-3.403 0-6.162 2.759-6.162 6.162s2.759 6.163 6.162 6.163 6.162-2.759 6.162-6.163c0-3.403-2.759-6.162-6.162-6.162zm0 10.162c-2.209 0-4-1.79-4-4 0-2.209 1.791-4 4-4s4 1.791 4 4c0 2.21-1.791 4-4 4zm6.406-11.845c-.796 0-1.441.645-1.441 1.44s.645 1.44 1.441 1.44c.795 0 1.439-.645 1.439-1.44s-.644-1.44-1.439-1.44z'/%3E%3C/svg%3E");
}

/* ==========================================================================
   Responsive Styles
   ========================================================================== */

@media (max-width: 768px) {
	.eco-site-footer {
		padding: 2rem 0 1.5rem;
	}
	
	.eco-site-footer__inner {
		gap: 2rem;
	}
	
	.eco-footer-main__grid {
		grid-template-columns: 1fr;
		gap: 1.5rem;
	}
	
	.eco-footer-widget {
		padding: 1.5rem;
	}
	
	.eco-footer-bottom {
		flex-direction: column;
		text-align: center;
		gap: 1.5rem;
	}
	
	.eco-footer-bottom__left,
	.eco-footer-bottom__right {
		width: 100%;
	}
	
	.eco-footer-bottom__right {
		justify-content: center;
	}
	
	.eco-footer-nav__list {
		justify-content: center;
	}
	
	.eco-social-links {
		justify-content: center;
	}
}

@media (max-width: 480px) {
	.eco-site-footer {
		padding: 1.5rem 0 1rem;
	}
	
	.eco-footer-widget {
		padding: 1.25rem;
	}
	
	.eco-footer-widget__title {
		font-size: 1rem;
	}
	
	.eco-footer-copyright__text {
		font-size: 0.8125rem;
	}
	
	.eco-footer-nav__list {
		gap: 1rem;
	}
	
	.eco-social-links {
		gap: 0.5rem;
	}
	
	.eco-social-links__link {
		width: 2.25rem;
		height: 2.25rem;
	}
}

/* ==========================================================================
   Accessibility Improvements
   ========================================================================== */

.eco-site-footer a:focus-visible {
	outline: 2px solid var(--eco-footer-accent);
	outline-offset: 2px;
	border-radius: 0.25rem;
}

.eco-social-links__link:focus-visible {
	outline: 2px solid var(--eco-footer-accent);
	outline-offset: 2px;
}

.eco-footer-nav__list a:focus-visible {
	outline: none;
}

.eco-footer-nav__list a:focus-visible::after {
	width: 100%;
	height: 3px;
	bottom: -2px;
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
	.eco-site-footer {
		border-top: 1px solid #ccc;
		background: none;
		color: #000;
		padding: 1rem 0;
	}
	
	.eco-footer-widget {
		box-shadow: none;
		border: 1px solid #eee;
	}
	
	.eco-social-links,
	.eco-footer-nav {
		display: none;
	}
}