/**
 * GatewayKit Standalone Frontend Form Styles
 */
.gatewaykit-form-wrap {
	max-width: 580px;
	margin: 0 auto;
	padding: 24px;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
	font-family: inherit;
	box-sizing: border-box;
}

.gatewaykit-form-wrap * {
	box-sizing: border-box;
}

.gk-form-header {
	margin-bottom: 20px;
	padding-bottom: 12px;
	border-bottom: 1px solid #f1f5f9;
}

.gk-form-description {
	margin: 0;
	color: #64748b;
	font-size: 15px;
	line-height: 1.5;
}

.gk-amount-container {
	margin-bottom: 22px;
}

.gk-fixed-amount-card {
	display: flex;
	justify-content: space-between;
	align-items: center;
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	padding: 14px 18px;
}

.gk-amount-label {
	font-size: 15px;
	font-weight: 500;
	color: #475569;
}

.gk-amount-value {
	font-size: 22px;
	font-weight: 700;
	color: #0f172a;
}

.gk-field-label {
	display: block;
	font-size: 14px;
	font-weight: 600;
	color: #334155;
	margin-bottom: 6px;
}

.gk-required {
	color: #ef4444;
}

.gk-donation-presets {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 8px;
}

.gatewaykit-form-wrap button.gk-preset-pill,
.gatewaykit-form-wrap .gk-preset-pill {
	padding: 8px 18px;
	background: #ffffff !important;
	border: 1px solid #cbd5e1 !important;
	border-radius: 20px;
	font-size: 14px;
	font-weight: 600;
	color: #334155 !important;
	cursor: pointer;
	box-shadow: none;
	text-decoration: none;
	transition: all 0.15s ease-in-out;
	outline: none;
}

.gatewaykit-form-wrap button.gk-preset-pill:hover,
.gatewaykit-form-wrap .gk-preset-pill:hover {
	border-color: #94a3b8 !important;
	background: #f8fafc !important;
	color: #1e293b !important;
}

.gatewaykit-form-wrap button.gk-preset-pill.is-selected,
.gatewaykit-form-wrap .gk-preset-pill.is-selected {
	background: #2563eb !important;
	border-color: #2563eb !important;
	color: #ffffff !important;
	box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

.gk-custom-amount-wrapper {
	margin-top: 12px;
}

.gk-input-group {
	display: flex;
	align-items: center;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	background: #ffffff;
	overflow: hidden;
	transition: border-color 0.15s;
}

.gk-input-group:focus-within {
	border-color: #2563eb;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.gk-input-prefix {
	padding: 10px 14px;
	background: #f8fafc;
	border-right: 1px solid #e2e8f0;
	color: #64748b;
	font-weight: 600;
	font-size: 15px;
}

.gk-custom-amount-input {
	border: none;
	padding: 10px 14px;
	font-size: 16px;
	font-weight: 600;
	width: 100%;
	outline: none;
	color: #0f172a;
}

.gk-helper-text {
	display: block;
	margin-top: 4px;
	color: #64748b;
	font-size: 12px;
}

.gk-fields-container {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin-bottom: 8px;
}

.gk-col-100 {
	width: 100%;
}

.gk-col-50 {
	width: calc(50% - 7px);
}

@media (max-width: 540px) {
	.gk-col-50 {
		width: 100%;
	}
}

.gk-heading-group {
	margin-top: 8px;
	margin-bottom: 4px;
}

.gk-section-heading {
	margin: 0 0 4px 0;
	font-size: 16px;
	font-weight: 700;
	color: #1e293b;
}

.gk-divider-group {
	margin: 8px 0;
}

.gk-divider {
	border: 0;
	border-top: 1px solid #e2e8f0;
	margin: 0;
}

.gk-help-text {
	margin: 4px 0 0 0;
	font-size: 12px;
	color: #64748b;
	line-height: 1.4;
}

.gk-select-input {
	height: 42px;
	background-color: #ffffff;
}

.gk-choice-list {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 4px;
}

.gk-choice-option {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	color: #334155;
	cursor: pointer;
}

.gk-choice-option input[type="radio"],
.gk-choice-option input[type="checkbox"] {
	margin: 0;
	cursor: pointer;
}

.gk-checkbox-single {
	margin-top: 4px;
}

.gk-form-group {
	margin-bottom: 16px;
}

.gk-text-input {
	width: 100%;
	padding: 10px 14px;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	font-size: 14px;
	color: #0f172a;
	background: #ffffff;
	outline: none;
	transition: border-color 0.15s, box-shadow 0.15s;
}

.gk-text-input:focus {
	border-color: #2563eb;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.gk-gateways-container {
	margin-top: 20px;
	margin-bottom: 20px;
}

.gk-gateway-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
	gap: 10px;
	margin-top: 8px;
}

.gk-gateway-card {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 12px 14px;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	background: #ffffff;
	cursor: pointer;
	transition: all 0.15s ease-in-out;
}

.gk-gateway-card:hover {
	border-color: #cbd5e1;
	background: #f8fafc;
}

.gk-gateway-card.is-selected {
	border-color: #2563eb;
	background: #eff6ff;
	box-shadow: 0 1px 3px rgba(37, 99, 235, 0.1);
}

.gk-gateway-card input[type="radio"] {
	margin: 0;
	cursor: pointer;
}

.gk-gw-title {
	font-size: 14px;
	font-weight: 500;
	color: #1e293b;
}

.gk-terms-group {
	margin-bottom: 18px;
}

.gk-terms-label {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	font-size: 13px;
	color: #475569;
	cursor: pointer;
}

.gk-terms-label input[type="checkbox"] {
	margin-top: 2px;
	cursor: pointer;
}

.gk-form-notices {
	margin-bottom: 16px;
	padding: 12px 16px;
	border-radius: 8px;
	font-size: 14px;
	line-height: 1.4;
}

.gk-notice-error {
	background: #fef2f2;
	border: 1px solid #fecaca;
	color: #b91c1c;
}

.gk-notice-success {
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	color: #15803d;
}

.gk-notice-info {
	background: #eff6ff;
	border: 1px solid #bfdbfe;
	color: #1d4ed8;
}

.gk-submit-wrapper {
	margin-top: 8px;
}

.gatewaykit-form-wrap button.gk-submit-btn,
.gatewaykit-form-wrap .gk-submit-btn {
	width: 100%;
	padding: 13px 20px;
	background: #2563eb !important;
	color: #ffffff !important;
	border: none !important;
	border-radius: 8px;
	font-size: 16px;
	font-weight: 600;
	cursor: pointer;
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 8px;
	box-shadow: none;
	transition: background-color 0.15s, opacity 0.15s;
}

.gatewaykit-form-wrap button.gk-submit-btn:hover:not(:disabled),
.gatewaykit-form-wrap .gk-submit-btn:hover:not(:disabled) {
	background: #1d4ed8 !important;
	color: #ffffff !important;
}

.gatewaykit-form-wrap button.gk-submit-btn:disabled,
.gatewaykit-form-wrap .gk-submit-btn:disabled {
	opacity: 0.65;
	cursor: not-allowed;
}

.gk-spinner {
	display: inline-block;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-radius: 50%;
	border-top-color: #ffffff;
	animation: gk-spin 0.8s linear infinite;
}

@keyframes gk-spin {
	to { transform: rotate(360deg); }
}

/* Discount Code Field (Pro) */
.gk-discount-input-wrapper {
	display: flex;
	gap: 8px;
	align-items: stretch;
}

.gk-discount-input-wrapper .gk-discount-input {
	flex: 1;
}

.gatewaykit-form-wrap button.gk-discount-apply-btn,
.gatewaykit-form-wrap .gk-discount-apply-btn {
	white-space: nowrap;
	padding: 0 16px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
	cursor: pointer;
	border: 1px solid #cbd5e1 !important;
	background: #f8fafc !important;
	color: #1e293b !important;
	box-shadow: none;
	transition: all 0.15s ease;
}

.gatewaykit-form-wrap button.gk-discount-apply-btn:hover:not(:disabled),
.gatewaykit-form-wrap .gk-discount-apply-btn:hover:not(:disabled) {
	background: #f1f5f9 !important;
	border-color: #94a3b8 !important;
	color: #0f172a !important;
}

.gatewaykit-form-wrap button.gk-discount-apply-btn:disabled,
.gatewaykit-form-wrap .gk-discount-apply-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.gk-discount-feedback {
	font-size: 13px;
	margin-top: 6px;
	padding: 6px 12px;
	border-radius: 6px;
	line-height: 1.4;
}

.gk-discount-feedback.is-success {
	background: #ecfdf5;
	color: #065f46;
	border: 1px solid #a7f3d0;
}

.gk-discount-feedback.is-error {
	background: #fef2f2;
	color: #991b1b;
	border: 1px solid #fecaca;
}

/* Animated amount and strike-through on discount applied */
.gk-amount-original {
	text-decoration: line-through;
	opacity: 0.55;
	font-size: 0.82em;
	margin-right: 6px;
	font-weight: normal;
}

@keyframes gkAmountPulse {
	0% {
		transform: scale(1);
	}
	30% {
		transform: scale(1.12);
	}
	60% {
		transform: scale(0.97);
	}
	100% {
		transform: scale(1);
	}
}

.gk-amount-value.gk-amount-pulse {
	animation: gkAmountPulse 0.5s ease-out;
	display: inline-block;
}

/* Footer Attribution (Lite / Free) */
.gk-form-footer-badge {
	text-align: center;
	margin-top: 14px;
	font-size: 12px;
	line-height: 1.4;
}

.gk-form-footer-badge a {
	color: #64748b;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 4px;
	transition: color 0.15s ease;
}

.gk-form-footer-badge a:hover {
	color: #2563eb;
	text-decoration: underline;
}
