/* ==========================================================================
   Quay So — luxury gold/terracotta ticket theme
   Single committed dark visual world (no light-mode variant by design).
   ========================================================================== */

.qs-page {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 32px 16px;
	background: radial-gradient(circle at 50% 28%, #da5324 0%, #b83a17 28%, #852210 58%, #511206 88%, #360b03 100%);
	font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
	box-sizing: border-box;
}

/* Full-bleed themed backdrop behind the widget: default warm sunset
   gradient, or an admin-picked solid color / image (qs_render_theme_style()). */
.qs-bleed {
	--qs-accent: #f6bd54;
	--qs-accent-dark: #ac843b;
	width: 100%;
	box-sizing: border-box;
	padding: 40px 16px;
	background: radial-gradient(circle at 50% 28%, #da5324 0%, #b83a17 28%, #852210 58%, #511206 88%, #360b03 100%);
	font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
	position: relative;
	overflow: hidden;
}

.qs-bleed-standalone {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* Ambient glow layers, matching the sunburst behind the mockup's cards. */
.qs-bleed::before {
	content: '';
	position: absolute;
	top: 12%;
	left: 50%;
	width: 70rem;
	height: 34rem;
	transform: translate(-50%, -50%);
	background: radial-gradient(circle at center, rgba(255, 165, 60, 0.32), rgba(230, 85, 32, 0.22) 40%, transparent 72%);
	filter: blur(60px);
	pointer-events: none;
}

.qs-widget {
	width: 100%;
	max-width: 1080px;
	margin: 0 auto;
	position: relative;
	z-index: 1;
}

/* ---- Brand header: logo + optional tagline ---- */

.qs-brandbar {
	text-align: center;
	margin-bottom: 32px;
}

.qs-logo {
	display: block;
	/* Show at the image's own resolution; only step in if it's wider than
	   the card itself, so a logo can never overflow/break the layout. */
	width: auto;
	height: auto;
	max-width: 100%;
	margin: 0 auto;
}

.qs-tagline-row {
	margin-top: 14px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

.qs-rule {
	height: 1px;
	width: 64px;
	background: linear-gradient(to right, transparent, rgba(255, 198, 107, 0.65), transparent);
}

.qs-tagline {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.32em;
	text-transform: uppercase;
	color: #ffe4a0;
	text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

@keyframes qs-shimmer {
	0% { background-position: -200% center; }
	100% { background-position: 200% center; }
}

/* ---- Two-column layout: form left, ticket result right ---- */

.qs-layout {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 24px;
	align-items: stretch;
}

.qs-col {
	display: flex;
}

.qs-panel {
	--qs-text: #fed896;
	width: 100%;
	border-radius: 18px;
	background: linear-gradient(to bottom, rgba(92, 28, 14, 0.95), rgba(74, 21, 10, 0.95), rgba(58, 15, 7, 0.95));
	border: 1px solid rgba(229, 160, 68, 0.4);
	box-shadow: 0 16px 45px rgba(30, 5, 2, 0.65), inset 0 1px 1px rgba(255, 220, 140, 0.3);
	padding: 28px 26px;
	position: relative;
	overflow: hidden;
	display: flex;
	flex-direction: column;
}

.qs-panel::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 3px;
	background: linear-gradient(to right, transparent, #ffd875, transparent);
	box-shadow: 0 1px 10px rgba(255, 216, 117, 0.7);
}

.qs-ticket-panel {
	border-width: 2px;
	box-shadow: 0 20px 50px rgba(30, 5, 2, 0.7), inset 0 1px 2px rgba(255, 225, 145, 0.4);
}

.qs-ticket-panel::before {
	height: 4px;
	background: linear-gradient(to right, #e5a044, #fff1b8, #e5a044);
	box-shadow: 0 2px 12px rgba(255, 220, 120, 0.8);
}

.qs-panel-eyebrow {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: #ffe29a;
	text-shadow: 0 1px 6px rgba(255, 215, 100, 0.35);
	border-bottom: 1px solid rgba(229, 148, 68, 0.25);
	padding-bottom: 12px;
	margin-bottom: 20px;
}

.qs-pulse-dot {
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: #fbc453;
	box-shadow: 0 0 8px #fbc453;
	animation: qs-pulse-dot 1.6s ease-in-out infinite;
	flex-shrink: 0;
}

@keyframes qs-pulse-dot {
	0%, 100% { opacity: 1; transform: scale(1); }
	50% { opacity: 0.55; transform: scale(0.85); }
}

/* ---- Form fields ---- */

.qs-form {
	text-align: left;
	display: flex;
	flex-direction: column;
	gap: 18px;
	flex: 1;
}

.qs-field {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.qs-field[hidden] {
	display: none;
}

.qs-label {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--qs-text, #fed896);
}

.qs-req {
	color: var(--qs-accent);
}

/* Inline validation: shown on blur, cleared live once the field becomes
   valid again (see app.js). Empty <p> collapses to nothing via :empty. */
.qs-field-error {
	display: flex;
	align-items: flex-start;
	gap: 6px;
	margin: -2px 0 0;
	padding: 7px 10px;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.4;
	color: #7a1a04;
	background: #ffe9d6;
	border: 1px solid #ff7a3d;
	border-radius: 8px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.qs-field-error::before {
	content: 'error';
	font-family: 'Material Symbols Outlined';
	font-size: 16px;
	line-height: 1.35;
	flex-shrink: 0;
	color: #d9440e;
}

.qs-field-error:empty {
	display: none;
	margin: 0;
	padding: 0;
	border: none;
	background: none;
}

.qs-field.has-error .qs-input-icon-wrap,
.qs-field.has-error .qs-plain-field,
.qs-field.has-error .qs-select-field {
	border-color: #ff6b5e;
	box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5), 0 0 0 2px rgba(255, 107, 94, 0.3);
}

.qs-input-icon-wrap {
	position: relative;
	border-radius: 12px;
	background: rgba(46, 11, 4, 0.9);
	border: 1px solid rgba(184, 91, 55, 0.5);
	box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5);
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.qs-input-icon-wrap:focus-within {
	border-color: var(--qs-accent);
	box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5), 0 0 0 3px rgba(246, 189, 84, 0.25);
}

.qs-input-icon {
	position: absolute;
	left: 14px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--qs-accent);
	font-size: 22px;
	pointer-events: none;
	filter: drop-shadow(0 0 6px rgba(255, 200, 107, 0.35));
}

.qs-input-icon-field {
	width: 100%;
	box-sizing: border-box;
	padding: 14px 16px 14px 46px;
	background: transparent;
	border: none;
	border-radius: 12px;
	color: #fff4ee;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 16px;
	font-weight: 500;
}

.qs-input-icon-field::placeholder {
	color: rgba(211, 149, 126, 0.5);
}

.qs-input-icon-field:focus {
	outline: none;
}

.qs-plain-field {
	width: 100%;
	box-sizing: border-box;
	padding: 13px 16px;
	background: rgba(46, 11, 4, 0.9);
	border: 1px solid rgba(184, 91, 55, 0.5);
	border-radius: 12px;
	color: #fff4ee;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 15px;
	box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5);
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.qs-plain-field:focus {
	outline: none;
	border-color: var(--qs-accent);
	box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5), 0 0 0 3px rgba(246, 189, 84, 0.25);
}

textarea.qs-plain-field {
	resize: vertical;
}

.qs-select-wrap {
	position: relative;
}

.qs-select-field {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	padding-right: 40px;
}

.qs-select-wrap-icon .qs-select-field {
	padding-left: 46px;
}

.qs-select-arrow {
	position: absolute;
	right: 10px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--qs-accent);
	font-size: 20px;
	pointer-events: none;
}

.qs-checkbox-label {
	display: flex !important;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 600;
	color: var(--qs-text, #fed896);
	cursor: pointer;
}

.qs-checkbox-label input {
	width: auto;
	accent-color: var(--qs-accent);
}

.qs-hp-wrap {
	position: absolute;
	left: -9999px;
	top: -9999px;
}

.qs-captcha-field .qs-label {
	color: var(--qs-text, #fed896);
}

.qs-captcha-question {
	font-weight: 700;
	color: var(--qs-accent);
}

/* ---- Buttons ---- */

.qs-btn-row {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-top: 4px;
}

@media (min-width: 480px) {
	.qs-btn-row {
		flex-direction: row;
	}
}

.qs-btn {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 15px 20px;
	border: none;
	border-radius: 12px;
	background: linear-gradient(135deg, #ffea9f 0%, var(--qs-accent) 28%, var(--qs-accent-dark) 55%, #fcd677 82%, #fff1b8 100%);
	background-size: 200% 200%;
	box-shadow: 0 0 25px rgba(246, 189, 84, 0.45), 0 4px 18px rgba(168, 50, 15, 0.4);
	color: #351802;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 15px;
	font-weight: 800;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	cursor: pointer;
	transition: box-shadow 0.3s ease, filter 0.3s ease, transform 0.1s ease;
}

.qs-btn:hover {
	box-shadow: 0 0 35px rgba(255, 215, 120, 0.7), 0 6px 24px rgba(168, 50, 15, 0.5);
	filter: brightness(1.06);
}

.qs-btn:active {
	transform: scale(0.98);
}

.qs-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
	transform: none;
}

.qs-btn-icon {
	font-size: 20px;
}

.qs-btn-reset {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 15px 18px;
	border-radius: 12px;
	background: #4b180d;
	border: 1px solid rgba(186, 95, 58, 0.5);
	color: #fcd2b8;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: background 0.15s ease;
}

.qs-btn-reset:hover {
	background: #682314;
}

.qs-btn-reset .material-symbols-outlined {
	font-size: 18px;
	color: var(--qs-accent);
}

.qs-msg {
	min-height: 20px;
	font-size: 14px;
	text-align: center;
	margin: 0;
}

.qs-msg.qs-error {
	color: #ffb4a4;
}

.qs-alert {
	padding: 16px 18px;
	border-radius: 12px;
	font-size: 14px;
}

.qs-alert-error {
	background: rgba(147, 0, 10, 0.35);
	border: 1px solid rgba(255, 180, 171, 0.4);
	color: #ffdad6;
}

/* ---- Ticket / result panel ---- */

.qs-col-result {
	position: relative;
}

.qs-ticket-panel {
	min-height: 320px;
}

.qs-ticket-panel .qs-result-placeholder:not([hidden]),
.qs-ticket-panel .qs-result:not([hidden]) {
	flex: 1;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

.qs-result-placeholder[hidden],
.qs-result[hidden] {
	display: none;
}

.qs-result-placeholder {
	text-align: center;
	color: #e2b8a4;
}

.qs-result-placeholder-icon {
	font-size: 48px;
	color: var(--qs-accent);
	display: block;
	margin: 0 auto 14px;
	filter: drop-shadow(0 0 10px rgba(255, 190, 70, 0.35));
}

.qs-result-placeholder p {
	font-size: 14px;
	line-height: 1.6;
	max-width: 260px;
	margin: 0 auto;
}

.qs-result {
	width: 100%;
}

.qs-number-reel {
	text-align: center;
	padding: 28px 16px;
	border-radius: 16px;
	background: linear-gradient(to bottom, rgba(46, 11, 4, 0.98), rgba(31, 6, 2, 0.98));
	border: 2px solid rgba(229, 160, 68, 0.6);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), inset 0 0 20px rgba(255, 160, 50, 0.15);
	position: relative;
	overflow: hidden;
}

.qs-result-label {
	display: block;
	font-size: 12px;
	letter-spacing: 0.24em;
	text-transform: uppercase;
	color: #fed180;
	font-weight: 600;
	margin-bottom: 12px;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}

.qs-number {
	display: block;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: clamp(44px, 6vw, 64px);
	font-weight: 800;
	letter-spacing: 0.04em;
	font-variant-numeric: tabular-nums;
	background: linear-gradient(105deg, #fce9a6 0%, var(--qs-accent) 25%, #fff6cc 48%, var(--qs-accent-dark) 52%, #ffdd87 75%, #fbe38e 100%);
	background-size: 250% auto;
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	filter: drop-shadow(0 0 28px rgba(255, 195, 75, 0.5));
	animation: qs-shimmer 6s linear infinite;
}

.qs-number.qs-spin {
	animation: qs-shimmer 6s linear infinite, qs-number-pulse 0.15s ease-in-out infinite alternate;
}

@keyframes qs-number-pulse {
	from { transform: scale(1); }
	to { transform: scale(1.06); }
}

.qs-ticket-meta {
	margin-top: 20px;
	padding-top: 16px;
	border-top: 1px solid rgba(140, 53, 32, 0.4);
	text-align: left;
}

.qs-ticket-meta-label {
	display: block;
	font-size: 10px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: #e29b82;
	font-weight: 600;
	margin-bottom: 4px;
}

.qs-ticket-guest-name {
	display: block;
	font-size: 16px;
	font-weight: 700;
	color: #fff1eb;
}

.qs-ticket-guest-phone {
	display: block;
	font-size: 13px;
	font-family: 'Plus Jakarta Sans', monospace;
	color: #f7c062;
	font-weight: 600;
	margin-top: 2px;
}

.qs-result-note {
	margin-top: 16px;
	font-size: 13px;
	color: #ecd0c2;
	text-align: left;
}

.qs-ticket-timestamp {
	margin-top: 10px;
	font-size: 13px;
	color: #d68c74;
	text-align: left;
}

.qs-report-wrap {
	margin-top: 14px;
	padding-top: 12px;
	border-top: 1px dashed rgba(140, 53, 32, 0.4);
	text-align: left;
}

.qs-report-btn[hidden] {
	display: none;
}

.qs-report-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: none;
	border: none;
	padding: 0;
	color: #d68c74;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 12px;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}

.qs-report-btn:hover {
	color: #ffb4a4;
}

.qs-report-btn .material-symbols-outlined {
	font-size: 16px;
}

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

.qs-report-form {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.qs-report-form textarea {
	font-size: 13px;
	padding: 8px 10px;
}

.qs-report-actions {
	display: flex;
	gap: 8px;
	justify-content: flex-end;
}

.qs-report-actions .qs-btn-reset {
	padding: 8px 14px;
	font-size: 12px;
}

.qs-report-confirm {
	font-size: 12px;
	color: #9fd8b8;
	margin: 0;
}

@media (max-width: 860px) {
	.qs-layout {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 480px) {
	.qs-panel {
		padding: 22px 18px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.qs-number,
	.qs-number.qs-spin,
	.qs-pulse-dot {
		animation: none;
	}
}

/* ---- Privacy consent checkbox + policy popup ---- */

.qs-consent-field .qs-checkbox-label {
	align-items: center;
	flex-wrap: nowrap;
	font-weight: 500;
	line-height: 1.4;
}

.qs-consent-field .qs-checkbox-label input {
	flex-shrink: 0;
}

.qs-consent-text {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	font-size: 12.5px;
}

@media (max-width: 460px) {
	.qs-consent-text {
		white-space: normal;
		overflow: visible;
		text-overflow: clip;
	}

	.qs-consent-field .qs-checkbox-label {
		align-items: flex-start;
		flex-wrap: wrap;
	}

	.qs-consent-field .qs-checkbox-label input {
		margin-top: 3px;
	}
}

.qs-privacy-link {
	display: inline;
	background: none;
	border: none;
	padding: 0;
	margin: 0;
	font: inherit;
	font-weight: 700;
	color: var(--qs-accent);
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}

.qs-privacy-link:hover {
	color: #fff;
}

.qs-privacy-modal[hidden] {
	display: none;
}

.qs-privacy-modal {
	position: fixed;
	inset: 0;
	z-index: 9998;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.qs-privacy-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(10, 2, 1, 0.72);
	backdrop-filter: blur(2px);
}

.qs-privacy-modal-panel {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: 640px;
	max-height: 82vh;
	display: flex;
	flex-direction: column;
	background: linear-gradient(160deg, #3a0f07, #1c0603);
	border: 1px solid rgba(246, 189, 84, 0.35);
	border-radius: 16px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
}

.qs-privacy-modal-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 18px 22px;
	border-bottom: 1px solid rgba(246, 189, 84, 0.2);
}

.qs-privacy-modal-header h3 {
	margin: 0;
	font-family: 'Playfair Display', serif;
	font-size: 20px;
	color: var(--qs-accent);
}

.qs-privacy-modal-close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 34px;
	height: 34px;
	flex-shrink: 0;
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(246, 189, 84, 0.3);
	border-radius: 50%;
	color: #fff4ee;
	cursor: pointer;
}

.qs-privacy-modal-close:hover {
	background: rgba(255, 255, 255, 0.14);
}

.qs-privacy-modal-body {
	overflow-y: auto;
	padding: 20px 22px 24px;
	color: #f2e3d8;
	font-size: 14px;
	line-height: 1.7;
}

.qs-privacy-modal-body p {
	margin: 0 0 14px;
}

.qs-privacy-modal-body p:last-child {
	margin-bottom: 0;
}

@media (max-width: 480px) {
	.qs-privacy-modal-panel {
		max-height: 88vh;
	}

	.qs-privacy-modal-body {
		font-size: 13.5px;
	}
}
