/* Button system */
.btn,
.btn-primary {
	display: flex !important;
	align-items: center;
	justify-content: center;
	text-align: center;
}

.btn {
	padding: 0 24px;
	height: 52px;
	border: none;
	border-radius: var(--border-radius);
	font-family: var(--font-system);
	font-size: 16px;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: var(--transition);
	min-width: 140px;
	position: relative;
	overflow: hidden;
}

.btn::before {
	content: '';
	position: absolute;
	top: 0;
	left: -100%;
	width: 100%;
	height: 100%;
	background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
	transition: left 0.5s;
}

.btn:hover::before { left: 100%; }

.btn-primary {
	background: var(--gradient-primary);
	color: var(--primary-contrast);
	box-shadow: var(--shadow-cta);
	border: 2px solid transparent;
	font-weight: 700;
	min-width: 200px;
	position: relative;
	overflow: hidden;
	background-size: 200% 200%;
	animation: gradient-shift 3s ease infinite;
}

.btn-primary::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 0;
	height: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.3);
	transform: translate(-50%, -50%);
	transition: width 0.6s ease, height 0.6s ease;
}

.btn-primary:hover::after {
	width: 300px;
	height: 300px;
}

.btn-primary:hover {
	transform: translateY(-3px) scale(1.02);
	box-shadow: var(--shadow-glow), 0 12px 40px rgba(99, 102, 241, 0.6);
	filter: brightness(1.15);
	animation-duration: 1.5s;
}

.btn-primary:active {
	transform: translateY(-1px) scale(1);
	box-shadow: var(--shadow-md);
}

.btn-secondary {
	background-color: var(--secondary-bg);
	color: var(--primary-color);
	border: 2px solid var(--secondary-border);
	box-shadow: var(--shadow-sm);
	font-weight: 600;
	min-width: 180px;
	opacity: 0.95;
	position: relative;
	overflow: hidden;
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary:hover {
	background: var(--gradient-primary);
	background-size: 200% 200%;
	color: var(--surface-contrast);
	transform: translateY(-2px) scale(1.02);
	box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4), 0 0 50px rgba(139, 92, 246, 0.3);
	opacity: 1;
	border-color: transparent;
	animation: gradient-shift 2s ease infinite;
}

/* Hero specific button styles */
.hero-cta-buttons {
	display: flex;
	flex-direction: column;
	gap: 16px;
	align-items: center;
	max-width: 400px;
	margin: 0 auto;
}

.btn-hero-primary {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 18px;
	font-weight: 700;
	padding: 0 32px;
	min-width: 280px;
	position: relative;
}

.btn-hero-primary::before {
	content: '';
	position: absolute;
	inset: 0;
	border-radius: inherit;
	padding: 2px;
	background: linear-gradient(135deg, #F59E0B, #D97706, #FBBF24);
	-webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	mask-composite: exclude;
}

.btn-hero-secondary {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 16px;
	font-weight: 600;
	padding: 0 28px;
	min-width: 260px;
	background: rgba(255, 255, 255, 0.95);
	border: 2px solid #E5E7EB;
	color: var(--primary-color);
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-hero-secondary:hover {
	background: linear-gradient(135deg, #10B981, #059669);
	color: white;
	border-color: transparent;
	transform: translateY(-2px) scale(1.02);
	box-shadow: 0 8px 24px rgba(16, 185, 129, 0.4);
}

.btn-ghost {
	background: transparent;
	border: 2px solid transparent;
	color: var(--primary-color);
	font-weight: 500;
	padding: 0 24px;
	min-width: 220px;
	display: flex;
	align-items: center;
	gap: 10px;
	transition: all 0.3s ease;
	position: relative;
}

.btn-ghost::before {
	content: '';
	position: absolute;
	inset: 0;
	border-radius: inherit;
	background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
	opacity: 0;
	transition: opacity 0.3s ease;
}

.btn-ghost:hover::before {
	opacity: 0.1;
}

.btn-ghost:hover {
	background: rgba(17, 24, 39, 0.05);
	border-color: rgba(17, 24, 39, 0.2);
	transform: translateY(-1px);
}

.btn-hero-ghost {
	font-size: 15px;
	padding: 0 20px;
	min-width: 200px;
}

/* Hero buttons animations */
.hero-cta-buttons {
	animation: hero-buttons-appear 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.5s both;
}

.btn-hero-primary {
	animation: button-pulse 3s ease-in-out infinite 1s;
}

.btn-hero-primary .btn-icon {
	animation: hero-button-glow 2s ease-in-out infinite 1.5s;
}

.btn-hero-secondary .btn-icon {
	transition: transform 0.3s ease;
}

.btn-hero-secondary:hover .btn-icon {
	transform: rotate(12deg) scale(1.1);
}

.btn-hero-ghost .btn-icon {
	transition: all 0.3s ease;
}

.btn-hero-ghost:hover .btn-icon {
	transform: scale(1.1);
	filter: brightness(1.2);
}

.btn-small {
	height: 44px;
	padding: 0 20px;
	font-size: 14px;
	min-width: 120px;
}

.btn-icon {
	font-size: clamp(14px, 2vw, 18px);
	filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
	line-height: 1;
}

@media (max-width: 767px) {
	.btn {
		height: 56px;
		font-size: 16px;
		font-weight: 600;
		min-width: auto;
		width: 100%;
		padding: 0 24px;
	}

	.hero-cta .btn {
		min-height: 56px;
		margin-bottom: 16px;
	}

	.hero-cta .btn:last-child { margin-bottom: 0; }

	.hero-cta-buttons {
		max-width: 100%;
		gap: 12px;
	}

	.btn-hero-primary {
		font-size: 16px;
		padding: 0 24px;
		min-width: auto;
		width: 100%;
		flex-direction: column;
		gap: 8px;
		text-align: center;
	}

	.btn-hero-secondary {
		font-size: 15px;
		padding: 0 20px;
		min-width: auto;
		width: 100%;
		flex-direction: column;
		gap: 8px;
		text-align: center;
	}

	.btn-hero-ghost {
		font-size: 14px;
		padding: 0 16px;
		min-width: auto;
		width: 100%;
		flex-direction: column;
		gap: 6px;
		text-align: center;
	}
}
