/* =============================================================
   EuroParts3D — Custom Order Form
   ============================================================= */

/* ── WRAP ─────────────────────────────────────────────────── */
.ep3d-form-wrap {
	max-width: 860px;
	margin: 2rem auto;
	padding: 0 1rem;
	font-family: inherit;
}

/* ── INTRO ────────────────────────────────────────────────── */
.ep3d-form-title {
	font-size: 1.75rem;
	font-weight: 700;
	color: #111827;
	margin: 0 0 .5rem;
}

.ep3d-form-subtitle {
	color: #6b7280;
	font-size: .975rem;
	margin: 0 0 2rem;
	max-width: 620px;
}

/* ── FIELDSET ─────────────────────────────────────────────── */
.ep3d-fieldset {
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	padding: 1.5rem 1.75rem;
	margin: 0 0 1.5rem;
	background: #fff;
}

.ep3d-legend {
	display: flex;
	align-items: center;
	gap: .6rem;
	font-size: 1rem;
	font-weight: 600;
	color: #111827;
	padding: 0 .5rem;
	margin-bottom: 1.25rem;
}

.ep3d-legend__num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: #2563eb;
	color: #fff;
	font-size: .8rem;
	font-weight: 700;
	flex-shrink: 0;
}

/* ── GRID ─────────────────────────────────────────────────── */
.ep3d-grid {
	display: grid;
	gap: 1.1rem;
}

.ep3d-grid--2 { grid-template-columns: repeat(2, 1fr); }
.ep3d-grid--3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 640px) {
	.ep3d-grid--2,
	.ep3d-grid--3 { grid-template-columns: 1fr; }
}

/* ── FIELDS ───────────────────────────────────────────────── */
.ep3d-field {
	display: flex;
	flex-direction: column;
	gap: .35rem;
}

.ep3d-field--full {
	grid-column: 1 / -1;
}

.ep3d-field--required .ep3d-label::after {
	content: " *";
	color: #dc2626;
}

.ep3d-label {
	font-size: .875rem;
	font-weight: 500;
	color: #374151;
}

.ep3d-input {
	padding: .6rem .9rem;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	font-size: .9rem;
	color: #111827;
	background: #f9fafb;
	transition: border-color .15s, box-shadow .15s;
	outline: none;
	width: 100%;
	box-sizing: border-box;
}

.ep3d-input:focus {
	border-color: #2563eb;
	background: #fff;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, .15);
}

.ep3d-input.ep3d-input--error {
	border-color: #dc2626;
	box-shadow: 0 0 0 3px rgba(220, 38, 38, .12);
}

.ep3d-textarea {
	resize: vertical;
	min-height: 100px;
}

.ep3d-select {
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%236b7280'%3E%3Cpath fill-rule='evenodd' d='M5.23 7.21a.75.75 0 011.06.02L10 11.168l3.71-3.938a.75.75 0 111.08 1.04l-4.25 4.5a.75.75 0 01-1.08 0l-4.25-4.5a.75.75 0 01.02-1.06z' clip-rule='evenodd'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right .75rem center;
	background-size: 1.1rem;
	padding-right: 2.25rem;
	cursor: pointer;
}

/* ── FILE UPLOAD ──────────────────────────────────────────── */
.ep3d-upload-zone {
	position: relative;
	border: 2px dashed #d1d5db;
	border-radius: 10px;
	background: #f9fafb;
	transition: border-color .2s, background .2s;
	overflow: hidden;
}

.ep3d-upload-zone:hover,
.ep3d-upload-zone.ep3d-drag-over {
	border-color: #2563eb;
	background: #eff6ff;
}

.ep3d-upload-input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	cursor: pointer;
	z-index: 2;
}

.ep3d-upload-label {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1.75rem 1.5rem;
	cursor: pointer;
}

.ep3d-upload-icon {
	width: 40px;
	height: 40px;
	color: #2563eb;
	flex-shrink: 0;
}

.ep3d-upload-text {
	display: flex;
	flex-direction: column;
	gap: .2rem;
}

.ep3d-upload-text strong {
	font-size: .95rem;
	color: #111827;
}

.ep3d-upload-text small {
	font-size: .8rem;
	color: #6b7280;
}

.ep3d-upload-filename {
	margin: 0;
	padding: .5rem 1.5rem .75rem;
	font-size: .85rem;
	color: #2563eb;
	font-weight: 500;
	background: #eff6ff;
}

.ep3d-upload-note {
	margin: .75rem 0 0;
	font-size: .82rem;
	color: #9ca3af;
}

/* ── SUBMIT ───────────────────────────────────────────────── */
.ep3d-submit-wrap {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: .75rem;
}

.ep3d-btn {
	display: inline-flex;
	align-items: center;
	gap: .6rem;
	padding: .8rem 2rem;
	border: none;
	border-radius: 8px;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	transition: background .2s, transform .1s;
}

.ep3d-btn--primary {
	background: #2563eb;
	color: #fff;
}

.ep3d-btn--primary:hover:not(:disabled) {
	background: #1d4ed8;
}

.ep3d-btn:disabled {
	opacity: .65;
	cursor: not-allowed;
}

/* ── SPINNER ──────────────────────────────────────────────── */
.ep3d-btn__spinner {
	width: 18px;
	height: 18px;
	border: 2px solid rgba(255,255,255,.4);
	border-top-color: #fff;
	border-radius: 50%;
	animation: ep3d-spin .7s linear infinite;
}

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

/* ── PRIVACY NOTE ─────────────────────────────────────────── */
.ep3d-privacy-note {
	font-size: .8rem;
	color: #9ca3af;
	margin: 0;
}

.ep3d-privacy-note a {
	color: #2563eb;
	text-decoration: underline;
}

/* ── RESPONSE MESSAGE ─────────────────────────────────────── */
.ep3d-response-message {
	margin-top: 1.5rem;
	padding: 1.1rem 1.4rem;
	border-radius: 10px;
	font-size: .95rem;
	font-weight: 500;
	line-height: 1.5;
}

.ep3d-response-message.ep3d-success {
	background: #ecfdf5;
	color: #065f46;
	border: 1px solid #6ee7b7;
}

.ep3d-response-message.ep3d-error {
	background: #fef2f2;
	color: #991b1b;
	border: 1px solid #fca5a5;
}
