/**
 * Frontend styles for Bitcoin Key Form.
 */

.bkf-key-form-container {
	max-width: 600px;
	margin: 0 auto;
	padding: 20px;
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.bkf-form-header {
	text-align: center;
	margin-bottom: 30px;
}

.bkf-form-header h3 {
	margin: 0 0 15px 0;
	color: #333;
	font-size: 24px;
}

.bkf-form-description {
	color: #666;
	line-height: 1.6;
}

.bkf-key-form {
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 8px;
	padding: 25px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.bkf-products-section {
	margin-bottom: 25px;
}

.bkf-products-section h4 {
	margin: 0 0 15px 0;
	color: #333;
	font-size: 18px;
}

.bkf-products-list {
	display: flex;
	flex-direction: column;
	gap: 15px;
}

.bkf-product-item {
	border: 2px solid #e1e5e9;
	border-radius: 6px;
	transition: all 0.3s ease;
}

.bkf-product-item:hover {
	border-color: #007cba;
}

.bkf-product-item.selected {
	border-color: #007cba;
	background: #f0f8ff;
}

.bkf-product-radio {
	display: block;
	padding: 20px;
	cursor: pointer;
	margin: 0;
}

.bkf-product-radio input[type="radio"] {
	display: none;
}

.bkf-product-info {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.bkf-product-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
}

.bkf-product-number {
	background: #007cba;
	color: white;
	padding: 4px 8px;
	border-radius: 4px;
	font-size: 12px;
	font-weight: bold;
}

.bkf-product-article {
	background: #f1f1f1;
	color: #333;
	padding: 4px 8px;
	border-radius: 4px;
	font-size: 12px;
	font-weight: bold;
}

.bkf-product-price {
	font-size: 18px;
	font-weight: bold;
	color: #28a745;
}

.bkf-product-description {
	color: #666;
	line-height: 1.5;
}

.bkf-key-type-indicator {
	margin-top: 10px;
}

.bkf-key-type {
	padding: 4px 8px;
	border-radius: 4px;
	font-size: 11px;
	font-weight: bold;
	text-transform: uppercase;
}

.bkf-key-type.unique {
	background: #cce5ff;
	color: #0066cc;
}

.bkf-key-type.shared {
	background: #fff2cc;
	color: #d6b656;
}

.bkf-customer-section {
	margin-bottom: 25px;
}

.bkf-customer-section h4 {
	margin: 0 0 15px 0;
	color: #333;
	font-size: 18px;
}

.bkf-field-group {
	margin-bottom: 15px;
}

.bkf-field-group label {
	display: block;
	margin-bottom: 5px;
	font-weight: 500;
	color: #333;
}

.bkf-field-group .required {
	color: #dc3545;
}

.bkf-input {
	width: 100%;
	padding: 12px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 16px;
	transition: border-color 0.3s ease;
}

.bkf-input:focus {
	outline: none;
	border-color: #007cba;
	box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.2);
}

.bkf-payment-section {
	margin-bottom: 25px;
}

.bkf-payment-summary {
	background: #f8f9fa;
	padding: 15px;
	border-radius: 6px;
	margin-bottom: 20px;
	text-align: center;
}

.bkf-total {
	font-size: 20px;
	color: #333;
}

.bkf-payment-methods h4 {
	margin: 0 0 15px 0;
	color: #333;
	font-size: 18px;
}

.bkf-payment-options {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.bkf-payment-option {
	border: 2px solid #e1e5e9;
	border-radius: 6px;
	transition: all 0.3s ease;
}

.bkf-payment-option:hover {
	border-color: #007cba;
}

.bkf-payment-option input[type="radio"] {
	display: none;
}

.bkf-payment-option input[type="radio"]:checked + .bkf-payment-label {
	background: #f0f8ff;
}

.bkf-payment-label {
	display: flex;
	align-items: center;
	padding: 15px;
	cursor: pointer;
	margin: 0;
}

.bkf-payment-icon {
	font-size: 24px;
	margin-right: 10px;
	color: #f7931a;
}

.bkf-form-actions {
	text-align: center;
}

.bkf-submit-btn {
	background: #f7931a;
	color: white;
	border: none;
	padding: 15px 30px;
	font-size: 16px;
	font-weight: bold;
	border-radius: 6px;
	cursor: pointer;
	transition: all 0.3s ease;
	min-width: 200px;
}

.bkf-submit-btn:hover:not(:disabled) {
	background: #e8821a;
	transform: translateY(-1px);
}

.bkf-submit-btn:disabled {
	background: #ccc;
	cursor: not-allowed;
	transform: none;
}

.bkf-form-messages {
	margin-top: 20px;
}

.bkf-message {
	padding: 12px 15px;
	border-radius: 4px;
	margin-bottom: 10px;
}

.bkf-message.bkf-error {
	background: #f8d7da;
	color: #721c24;
	border: 1px solid #f5c6cb;
}

.bkf-message.bkf-success {
	background: #d4edda;
	color: #155724;
	border: 1px solid #c3e6cb;
}

/* Payment Modal */
.bkf-payment-modal {
	position: fixed;
	z-index: 1000;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.5);
	display: flex;
	align-items: center;
	justify-content: center;
}

.bkf-modal-content {
	background: white;
	border-radius: 8px;
	width: 90%;
	max-width: 500px;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.bkf-modal-header {
	padding: 20px;
	border-bottom: 1px solid #ddd;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.bkf-modal-header h3 {
	margin: 0;
	color: #333;
}

.bkf-modal-close {
	font-size: 24px;
	font-weight: bold;
	cursor: pointer;
	color: #999;
	background: none;
	border: none;
	padding: 0;
	width: 30px;
	height: 30px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.bkf-modal-close:hover {
	color: #333;
}

.bkf-modal-body {
	padding: 20px;
}

.bkf-payment-info {
	text-align: center;
}

.bkf-payment-amount {
	font-size: 18px;
	margin-bottom: 20px;
	color: #333;
}

.bkf-payment-address {
	margin-bottom: 20px;
}

.bkf-payment-address label {
	display: block;
	margin-bottom: 10px;
	font-weight: 500;
	color: #333;
}

.bkf-address-container {
	display: flex;
	gap: 10px;
	align-items: center;
}

.bkf-address-input {
	flex: 1;
	padding: 10px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-family: monospace;
	font-size: 12px;
	background: #f8f9fa;
}

.bkf-copy-btn {
	background: #007cba;
	color: white;
	border: none;
	padding: 10px 15px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 12px;
}

.bkf-copy-btn:hover {
	background: #005a87;
}

.bkf-payment-qr {
	margin: 20px 0;
	display: flex;
	justify-content: center;
}

.bkf-payment-status {
	margin-top: 20px;
}

.bkf-status-message {
	font-size: 16px;
	color: #333;
	margin-bottom: 10px;
}

.bkf-payment-timer {
	font-size: 14px;
	color: #666;
}

.bkf-modal-footer {
	padding: 15px 20px;
	border-top: 1px solid #ddd;
	text-align: right;
}

/* Responsive Design */
@media (max-width: 768px) {
	.bkf-key-form-container {
		padding: 10px;
	}
	
	.bkf-key-form {
		padding: 20px;
	}
	
	.bkf-product-header {
		flex-direction: column;
		align-items: flex-start;
	}
	
	.bkf-address-container {
		flex-direction: column;
	}
	
	.bkf-address-input {
		width: 100%;
	}
	
	.bkf-modal-content {
		width: 95%;
		margin: 20px;
	}
}

/* Loading States */
.bkf-btn-loading {
	display: none;
}

.bkf-submit-btn:disabled .bkf-btn-text {
	display: none;
}

.bkf-submit-btn:disabled .bkf-btn-loading {
	display: inline;
}

/* Animations */
@keyframes fadeIn {
	from { opacity: 0; transform: translateY(10px); }
	to { opacity: 1; transform: translateY(0); }
}

.bkf-key-form-container {
	animation: fadeIn 0.3s ease-out;
}

.bkf-product-item {
	animation: fadeIn 0.3s ease-out;
}

/* Focus States */
.bkf-product-radio:focus-within {
	outline: 2px solid #007cba;
	outline-offset: 2px;
}

.bkf-payment-option:focus-within {
	outline: 2px solid #007cba;
	outline-offset: 2px;
}
