/*
 * FANTASYREALM - CONTACT PAGE
 *
 * Styles only the contact form and its surrounding content.
 * Shared navigation, footer, background and scrolling
 * are managed by their dedicated stylesheets.
 */

/* =========================================================
   PAGE LAYOUT
========================================================= */

.contact-page {
	padding: 60px 20px 90px;

	display: flex;
	justify-content: center;
	align-items: flex-start;

	color: #f5f0ff;
	font-family: "Inter", sans-serif;
}

.contact-panel {
	box-sizing: border-box;

	width: min(720px, 100%);
	padding: 44px 48px;

	border: 1px solid rgba(168, 85, 247, 0.42);
	border-radius: 22px;

	background:
		linear-gradient(140deg,
			rgba(23, 14, 49, 0.95),
			rgba(9, 7, 26, 0.94));

	box-shadow:
		0 18px 55px rgba(0, 0, 0, 0.28),
		0 0 35px rgba(124, 58, 237, 0.13);

	backdrop-filter: blur(16px);
}

/* =========================================================
   PAGE INTRODUCTION
========================================================= */

.contact-introduction {
	text-align: center;
}

.contact-page .section-label {
	margin-bottom: 12px;

	color: #d8b4fe;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.35em;
}

.contact-panel h1 {
	margin: 0 0 16px;

	color: #f9f1ff;
	font-family: "Cinzel", serif;
	font-size: clamp(29px, 5vw, 42px);
	font-weight: 600;

	text-shadow: 0 0 22px rgba(168, 85, 247, 0.35);
}

.contact-intro {
	max-width: 510px;
	margin: 0 auto;

	color: #c9c0da;
	font-size: 14px;
	line-height: 1.8;
}

.contact-divider {
	display: flex;
	align-items: center;
	justify-content: center;

	gap: 14px;
	margin: 28px 0 32px;

	color: #edd5a8;
}

.contact-divider span:first-child,
.contact-divider span:last-child {
	width: 80px;
	height: 1px;

	background:
		linear-gradient(90deg,
			transparent,
			rgba(216, 180, 254, 0.8));
}

.contact-divider span:last-child {
	transform: rotate(180deg);
}

/* =========================================================
   FORM FIELDS
========================================================= */

.contact-form {
	display: grid;
	gap: 20px;
}

.form-field {
	display: flex;
	flex-direction: column;
	gap: 9px;
}

.form-field label {
	color: #eee8f8;
	font-size: 13px;
	font-weight: 600;
}

.optional-label {
	color: #aaa0bf;
	font-size: 12px;
	font-weight: 400;
}

.required-mark {
	color: #edd5a8;
}

.contact-form input,
.contact-form textarea {
	box-sizing: border-box;

	width: 100%;
	padding: 14px 16px;

	border: 1px solid rgba(168, 85, 247, 0.4);
	border-radius: 12px;

	background: rgba(5, 5, 18, 0.74);
	color: #fff;

	font-family: "Inter", sans-serif;
	font-size: 14px;
	line-height: 1.5;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
	color: #89809b;
}

.contact-form textarea {
	min-height: 150px;
	resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
	outline: 2px solid rgba(216, 180, 254, 0.55);
	outline-offset: 2px;

	border-color: #c084fc;
}

.message-counter {
	margin: 0;

	color: #aaa0bf;
	font-size: 11px;
	text-align: right;
}

/* =========================================================
   PRIVACY INFORMATION
========================================================= */

.privacy-notice {
	margin: 0;

	color: #c3b8d6;
	font-size: 12px;
	line-height: 1.8;
}

.privacy-notice a {
	color: #e5c3ff;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.privacy-notice a:hover {
	color: #fff;
}

/* =========================================================
   SUBMISSION FEEDBACK
========================================================= */

.form-message {
	margin: 0;
	padding: 14px 16px;

	border: 1px solid rgba(216, 180, 254, 0.35);
	border-radius: 12px;

	background: rgba(124, 58, 237, 0.12);
	color: #f0e3ff;

	font-size: 13px;
	line-height: 1.6;
}

.form-message[hidden] {
	display: none;
}

.form-message[data-type="success"] {
	border-color: rgba(134, 239, 172, 0.5);

	background: rgba(22, 101, 52, 0.18);
	color: #bbf7d0;
}

.form-message[data-type="error"] {
	border-color: rgba(252, 165, 165, 0.5);

	background: rgba(127, 29, 29, 0.2);
	color: #fecaca;
}

/* =========================================================
   FORM SUBMISSION
========================================================= */

.send-button {
	width: 100%;
	padding: 15px 24px;

	border: 1px solid rgba(233, 213, 255, 0.85);
	border-radius: 999px;

	background:
		linear-gradient(135deg,
			#6d28d9,
			#a855f7);

	color: #fff;

	font-family: "Inter", sans-serif;
	font-size: 14px;
	font-weight: 600;

	cursor: pointer;

	box-shadow: 0 0 22px rgba(168, 85, 247, 0.2);

	transition:
		transform 180ms ease,
		box-shadow 180ms ease;
}

.send-button:hover:not(:disabled) {
	transform: translateY(-2px);
	box-shadow: 0 0 28px rgba(168, 85, 247, 0.4);
}

.send-button:disabled {
	opacity: 0.65;
	cursor: wait;
}

/* =========================================================
   SECONDARY NAVIGATION
========================================================= */

.contact-actions {
	display: flex;
	justify-content: center;
	flex-wrap: wrap;

	gap: 14px;
	margin-top: 30px;
}

.back-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	gap: 8px;
	padding: 11px 19px;

	border: 1px solid rgba(216, 180, 254, 0.4);
	border-radius: 999px;

	background: rgba(124, 58, 237, 0.12);
	color: #eee3ff;

	font-size: 12px;
	font-weight: 600;
	text-decoration: none;
}

.back-link:hover {
	border-color: #d8b4fe;
	background: rgba(124, 58, 237, 0.28);
}

.privacy-notice a:focus-visible,
.back-link:focus-visible,
.send-button:focus-visible {
	outline: 2px solid #edd5a8;
	outline-offset: 4px;
}

/* =========================================================
   RESPONSIVE DESIGN
========================================================= */

@media (max-width: 768px) {
	.contact-page {
		padding: 35px 16px 60px;
	}

	.contact-panel {
		padding: 30px 22px;
		border-radius: 16px;
	}

	.contact-divider {
		margin: 22px 0 26px;
	}
}

@media (max-width: 390px) {
	.contact-page {
		padding-inline: 12px;
	}

	.contact-panel {
		padding: 26px 16px;
	}

	.contact-actions {
		gap: 10px;
	}
}

/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {
	.send-button {
		transition: none;
	}

	.send-button:hover:not(:disabled) {
		transform: none;
	}
}