/* Wheel of Names — frontend styles */

.won-app {
	position: relative;
	z-index: 1;
	--won-primary: #c41e3a;
	--won-primary-hover: #9b1c1c;
	--won-bg: #f8f9fa;
	--won-surface: #ffffff;
	--won-border: #e0e0e0;
	--won-text: #202124;
	--won-text-muted: #5f6368;
	--won-radius: 12px;
	--won-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
	--won-pointer: #ff6b35;
	--won-area-bg: #9b1c1c;
	--won-area-bg-end: #4a0808;
	--won-border-color: #d4af37;
	--won-pointer-color: #d4af37;
	--won-pointer-tip: #9a7b0a;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	color: var(--won-text);
	background: var(--won-bg);
	border-radius: var(--won-radius);
	border: none;
	box-shadow: var(--won-shadow);
	overflow: hidden;
	max-width: 1200px;
	margin: 1.5rem auto;
	line-height: 1.5;
	box-sizing: border-box;
}

.won-app *,
.won-app *::before,
.won-app *::after {
	box-sizing: border-box;
}

/* Remove default outlines on all interactive controls */
.won-app button,
.won-app input,
.won-app select,
.won-app textarea,
.won-app [role="button"],
.won-app .won-spin-overlay,
.won-app .won-canvas {
	outline: none !important;
	-webkit-tap-highlight-color: transparent;
}

.won-app button:focus,
.won-app button:focus-visible,
.won-app input:focus,
.won-app input:focus-visible,
.won-app select:focus,
.won-app select:focus-visible,
.won-app textarea:focus,
.won-app textarea:focus-visible,
.won-app [role="button"]:focus,
.won-app [role="button"]:focus-visible,
.won-app .won-spin-overlay:focus,
.won-app .won-spin-overlay:focus-visible {
	outline: none !important;
	box-shadow: none;
}

/* Toolbar */
.won-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 0.75rem;
	padding: 0.875rem 1.25rem;
	background: var(--won-surface);
	border-bottom: 1px solid var(--won-border);
}

.won-toolbar-left {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	flex: 1;
	min-width: 200px;
}

.won-title-input {
	flex: 1;
	max-width: 320px;
	font-size: 1.25rem;
	font-weight: 600;
	border: none;
	background: transparent;
	color: var(--won-text);
	padding: 0.25rem 0.5rem;
	border-radius: 6px;
	outline: none;
}

.won-title-input:hover,
.won-title-input:focus {
	background: var(--won-bg);
}

.won-save-status {
	font-size: 0.75rem;
	padding: 0.2rem 0.6rem;
	border-radius: 999px;
	white-space: nowrap;
}

.won-save-status.won-unsaved {
	background: #fff3e0;
	color: #e65100;
}

.won-save-status.won-saved {
	background: #e8f5e9;
	color: #2e7d32;
}

.won-toolbar-right {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	flex-wrap: wrap;
}

/* Buttons */
.won-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.4rem;
	padding: 0.5rem 1rem;
	font-size: 0.875rem;
	font-weight: 500;
	border: 1px solid var(--won-border);
	border-radius: 8px;
	background: var(--won-surface);
	color: var(--won-text);
	cursor: pointer;
	pointer-events: auto;
	transition: background 0.15s, border-color 0.15s, transform 0.1s;
	white-space: nowrap;
}

.won-btn:hover {
	background: var(--won-bg);
	border-color: #ccc;
}

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

.won-btn-primary {
	background: var(--won-primary);
	border-color: var(--won-primary);
	color: #fff;
	width: 100%;
	padding: 0.75rem;
	font-size: 0.9375rem;
	margin-top: 0.75rem;
}

.won-btn-primary:hover {
	background: var(--won-primary-hover);
	border-color: var(--won-primary-hover);
}

.won-btn-ghost {
	border-color: transparent;
	background: transparent;
}

.won-btn-ghost:hover {
	background: var(--won-bg);
}

.won-btn-small {
	padding: 0.35rem 0.75rem;
	font-size: 0.8125rem;
}

.won-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	padding: 0;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	background: var(--won-surface);
	color: var(--won-text-muted);
	cursor: pointer;
	pointer-events: auto;
	font-size: 0.875rem;
	line-height: 1;
	transition: background 0.15s;
}

.won-fatal-error {
	padding: 1rem;
	color: #b71c1c;
	background: #ffebee;
	border-radius: 8px;
}

.won-icon-btn:hover:not(:disabled) {
	background: var(--won-bg);
	color: var(--won-text);
}

.won-icon-btn:disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

/* Customize panel */
.won-customize-panel {
	padding: 1rem 1.25rem 1.25rem;
	background: #f1f3f4;
	border-bottom: 1px solid var(--won-border);
}

.won-customize-section + .won-customize-section {
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid var(--won-border);
}

.won-customize-heading {
	margin: 0 0 0.75rem;
	font-size: 0.8125rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--won-text-muted);
}

.won-customize-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 1rem;
}

.won-field {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
	font-size: 0.8125rem;
	color: var(--won-text-muted);
}

.won-field input[type="range"] {
	width: 100%;
	accent-color: var(--won-primary);
}

.won-field select {
	padding: 0.4rem 0.6rem;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	background: var(--won-surface);
	font-size: 0.875rem;
}

.won-color-field input[type="color"] {
	width: 100%;
	height: 36px;
	padding: 2px;
	border: 1px solid var(--won-border);
	border-radius: 8px;
	cursor: pointer;
	background: var(--won-surface);
}

.won-toggle-field {
	flex-direction: row;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem;
}

.won-toggle-field > span:first-child {
	flex: 1;
}

/* Toggle switch */
.won-toggle {
	position: relative;
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	cursor: pointer;
}

.won-toggle input {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
}

.won-toggle-slider {
	position: relative;
	display: block;
	width: 44px;
	height: 24px;
	background: #ccc;
	border-radius: 999px;
	transition: background 0.2s;
}

.won-toggle-slider::before {
	content: "";
	position: absolute;
	left: 3px;
	top: 3px;
	width: 18px;
	height: 18px;
	background: #fff;
	border-radius: 50%;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
	transition: transform 0.2s;
}

.won-toggle input:checked + .won-toggle-slider {
	background: var(--won-primary);
}

.won-toggle input:checked + .won-toggle-slider::before {
	transform: translateX(20px);
}

.won-toggle-small .won-toggle-slider {
	width: 36px;
	height: 20px;
}

.won-toggle-small .won-toggle-slider::before {
	width: 14px;
	height: 14px;
}

.won-toggle-small input:checked + .won-toggle-slider::before {
	transform: translateX(16px);
}

.won-spin-duration-value {
	font-weight: 600;
	color: var(--won-text);
}

/* Main layout */
.won-main {
	display: grid;
	grid-template-columns: 1fr 380px;
	min-height: 520px;
}

/* Wheel area — casino stage */
.won-wheel-area {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 2.5rem 1.5rem;
	position: relative;
	background:
		radial-gradient(ellipse 80% 60% at 20% 30%, color-mix(in srgb, var(--won-border-color) 25%, transparent) 0%, transparent 55%),
		radial-gradient(ellipse 60% 50% at 80% 70%, color-mix(in srgb, var(--won-area-bg) 40%, transparent) 0%, transparent 50%),
		linear-gradient(160deg, var(--won-area-bg) 0%, color-mix(in srgb, var(--won-area-bg) 70%, var(--won-area-bg-end)) 40%, var(--won-area-bg-end) 100%);
	overflow: hidden;
	transition: background 0.3s ease;
}

.won-wheel-area::before,
.won-wheel-area::after {
	content: "";
	position: absolute;
	border-radius: 50%;
	pointer-events: none;
	filter: blur(28px);
	opacity: 0.4;
}

.won-wheel-area::before {
	width: 180px;
	height: 180px;
	background: color-mix(in srgb, var(--won-border-color) 35%, transparent);
	top: 8%;
	left: 10%;
}

.won-wheel-area::after {
	width: 140px;
	height: 140px;
	background: color-mix(in srgb, var(--won-area-bg) 50%, transparent);
	bottom: 12%;
	right: 8%;
}

.won-confetti-canvas {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
	z-index: 15;
	opacity: 0;
	transition: opacity 0.2s ease;
}

.won-confetti-canvas.won-confetti-active {
	opacity: 1;
}

.won-wheel-wrapper {
	position: relative;
	width: min(100%, 520px);
	aspect-ratio: 1 / 1;
	min-width: 280px;
	min-height: 280px;
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 1;
}

.won-wheel-stage {
	position: relative;
	display: inline-block;
	line-height: 0;
	vertical-align: middle;
}

.won-canvas {
	display: block;
	border-radius: 50%;
	cursor: pointer;
	transition: transform 0.25s ease, filter 0.25s ease;
	filter: drop-shadow(0 16px 40px rgba(0, 0, 0, 0.55)) drop-shadow(0 4px 12px rgba(0, 0, 0, 0.35));
}

.won-app:not(.won-spinning) .won-canvas:hover {
	transform: scale(1.03);
	filter: drop-shadow(0 20px 48px rgba(0, 0, 0, 0.6)) drop-shadow(0 0 24px rgba(212, 175, 55, 0.25));
}

.won-app.won-spinning .won-canvas {
	filter: drop-shadow(0 20px 50px rgba(0, 0, 0, 0.65)) drop-shadow(0 0 30px rgba(255, 200, 80, 0.35));
}

/* Gold flipper pointer */
.won-pointer {
	position: absolute;
	z-index: 12;
	filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.5));
}

.won-pointer-top {
	top: -6px;
	left: 50%;
	transform: translateX(-50%);
	width: 44px;
	height: 52px;
	background: linear-gradient(180deg, color-mix(in srgb, var(--won-pointer-color) 30%, white), var(--won-pointer-color), var(--won-pointer-tip));
	border-radius: 10px 10px 6px 6px;
	border: 2px solid color-mix(in srgb, var(--won-pointer-color) 40%, white);
	box-shadow:
		inset 0 3px 6px rgba(255, 255, 255, 0.55),
		inset 0 -3px 6px rgba(0, 0, 0, 0.2),
		0 6px 16px rgba(0, 0, 0, 0.45);
	transition: background 0.25s ease, border-color 0.25s ease;
}

.won-pointer-top::after {
	content: "";
	position: absolute;
	bottom: -14px;
	left: 50%;
	transform: translateX(-50%);
	width: 0;
	height: 0;
	border-left: 14px solid transparent;
	border-right: 14px solid transparent;
	border-top: 16px solid var(--won-pointer-tip);
}

.won-pointer-right {
	right: -10px;
	top: 50%;
	transform: translateY(-50%);
	width: 40px;
	height: 48px;
	background: linear-gradient(90deg, color-mix(in srgb, var(--won-pointer-color) 30%, white), var(--won-pointer-color), var(--won-pointer-tip));
	border-radius: 8px 10px 10px 8px;
	border: 2px solid color-mix(in srgb, var(--won-pointer-color) 40%, white);
	box-shadow:
		inset 3px 0 6px rgba(255, 255, 255, 0.5),
		0 4px 12px rgba(0, 0, 0, 0.4);
	transition: background 0.25s ease, border-color 0.25s ease;
}

.won-pointer-right::after {
	content: "";
	position: absolute;
	right: -12px;
	top: 50%;
	transform: translateY(-50%);
	border-top: 12px solid transparent;
	border-bottom: 12px solid transparent;
	border-left: 14px solid var(--won-pointer-tip);
}

.won-spin-overlay {
	position: absolute;
	inset: 0;
	background: transparent;
	border: none;
	cursor: pointer;
	border-radius: 50%;
	z-index: 5;
}

.won-spin-hint {
	position: absolute;
	bottom: 18%;
	left: 50%;
	transform: translateX(-50%);
	background: rgba(0, 0, 0, 0.55);
	color: #fff;
	font-size: 0.75rem;
	padding: 0.3rem 0.75rem;
	border-radius: 999px;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.2s;
	white-space: nowrap;
}

.won-wheel-wrapper:hover .won-spin-hint,
.won-app.won-spinning .won-spin-hint {
	opacity: 1;
}

/* Winner banner */
.won-winner-banner {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-top: 1.25rem;
	padding: 0.875rem 1.5rem;
	background: linear-gradient(135deg, #fff8c8, #f0d060, #d4af37);
	border: 3px solid #fff8dc;
	border-radius: var(--won-radius);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.6);
	animation: won-pop 0.4s ease;
	z-index: 2;
}

@keyframes won-pop {
	0% { transform: scale(0.8); opacity: 0; }
	70% { transform: scale(1.05); }
	100% { transform: scale(1); opacity: 1; }
}

.won-winner-label {
	font-weight: 800;
	color: #6b0a0a;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.won-winner-name {
	font-size: 1.35rem;
	font-weight: 800;
	color: #1a1a4e;
	text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
}

/* Sidebar */
.won-sidebar {
	background: var(--won-surface);
	border-left: 1px solid var(--won-border);
	display: flex;
	flex-direction: column;
	min-height: 0;
}

.won-tabs {
	display: flex;
	border-bottom: 1px solid var(--won-border);
}

.won-tab {
	flex: 1;
	padding: 0.875rem 1rem;
	border: none;
	background: transparent;
	font-size: 0.9375rem;
	font-weight: 500;
	color: var(--won-text-muted);
	cursor: pointer;
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
	transition: color 0.15s, border-color 0.15s;
}

.won-tab:hover {
	color: var(--won-text);
	background: var(--won-bg);
}

.won-tab.won-tab-active {
	color: var(--won-primary);
	border-bottom-color: var(--won-primary);
}

.won-tab-panel {
	flex: 1;
	display: flex;
	flex-direction: column;
	padding: 1rem;
	overflow: hidden;
	min-height: 0;
}

.won-tab-panel[hidden] {
	display: none !important;
}

.won-customize-panel[hidden] {
	display: none !important;
}

.won-winner-banner[hidden] {
	display: none !important;
}

.won-list-toolbar,
.won-results-toolbar {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	flex-wrap: wrap;
	margin-bottom: 0.75rem;
}

.won-advanced-toggle {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-left: auto;
	font-size: 0.8125rem;
	color: var(--won-text-muted);
}

/* Entries list */
.won-entries-list {
	list-style: none;
	margin: 0;
	padding: 0;
	flex: 1;
	overflow-y: auto;
	max-height: 380px;
}

.won-entry-item {
	display: grid;
	grid-template-columns: auto 32px 40px 1fr auto auto auto;
	align-items: center;
	gap: 0.5rem;
	padding: 0.5rem 0.25rem;
	border-bottom: 1px solid #f0f0f0;
	transition: background 0.15s, box-shadow 0.15s, opacity 0.15s;
}

.won-entry-drag {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 36px;
	padding: 0;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	background: var(--won-surface);
	color: var(--won-text-muted);
	cursor: grab;
	touch-action: none;
	user-select: none;
	-webkit-user-select: none;
	flex-shrink: 0;
	transition: background 0.15s, color 0.15s, border-color 0.15s;
	outline: none;
}

.won-entry-drag:hover {
	background: var(--won-bg);
	color: var(--won-text);
	border-color: #ccc;
}

.won-entry-drag:active,
.won-is-sorting .won-entry-drag {
	cursor: grabbing;
}

.won-entries-list.won-is-sorting {
	user-select: none;
	-webkit-user-select: none;
}

.won-entry-item.won-dragging {
	opacity: 0.45;
	background: var(--won-bg);
}

.won-entry-item.won-drag-over-top {
	box-shadow: inset 0 3px 0 0 var(--won-primary);
}

.won-entry-item.won-drag-over-bottom {
	box-shadow: inset 0 -3px 0 0 var(--won-primary);
}

.won-drag-ghost {
	opacity: 0.92;
	background: var(--won-surface);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
	border-radius: 8px;
	pointer-events: none;
}

.won-entry-color {
	width: 32px;
	height: 32px;
	padding: 2px;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	cursor: pointer;
	background: none;
}

.won-entry-image-wrap {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
}

.won-entry-image-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 2px;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	background: var(--won-surface);
	color: var(--won-text-muted);
	cursor: pointer;
	overflow: hidden;
	transition: border-color 0.15s, background 0.15s;
}

.won-entry-image-btn:hover {
	border-color: #ccc;
	background: var(--won-bg);
	color: var(--won-text);
}

.won-entry-image-btn.has-image {
	padding: 0;
	border-color: #d4af37;
}

.won-entry-image-btn.won-uploading {
	opacity: 0.55;
	pointer-events: none;
}

.won-entry-image-thumb {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 4px;
	display: block;
}

.won-entry-image-remove {
	position: absolute;
	top: -6px;
	right: -6px;
	width: 18px;
	height: 18px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: #d32f2f;
	color: #fff;
	font-size: 12px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.won-entry-image-remove:hover {
	background: #b71c1c;
}

.won-entry-text {
	flex: 1;
	padding: 0.4rem 0.6rem;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	font-size: 0.875rem;
	min-width: 0;
}

.won-entry-text:focus {
	outline: none;
	border-color: var(--won-border);
}

.won-entry-weight-wrap {
	display: none;
	align-items: center;
	gap: 2px;
}

.won-advanced .won-entry-weight-wrap {
	display: flex;
}

.won-entry-weight {
	width: 42px;
	padding: 0.25rem;
	text-align: center;
	border: 1px solid var(--won-border);
	border-radius: 6px;
	font-size: 0.8125rem;
	-moz-appearance: textfield;
}

.won-entry-weight::-webkit-inner-spin-button,
.won-entry-weight::-webkit-outer-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.won-entry-pct {
	display: none;
	font-size: 0.75rem;
	font-weight: 600;
	color: var(--won-text-muted);
	min-width: 36px;
	text-align: right;
}

.won-advanced .won-entry-pct {
	display: block;
}

.won-advanced .won-entry-item {
	grid-template-columns: auto 32px 40px 1fr auto auto auto;
}

.won-entry-delete {
	color: #d32f2f;
	font-size: 1.1rem;
}

.won-entry-delete:hover {
	background: #ffebee;
}

/* Results list */
.won-results-list {
	list-style: none;
	margin: 0;
	padding: 0;
	flex: 1;
	overflow-y: auto;
	max-height: 420px;
}

.won-result-item {
	display: grid;
	grid-template-columns: 32px 1fr auto;
	align-items: center;
	gap: 0.75rem;
	padding: 0.625rem 0.25rem;
	border-bottom: 1px solid #f0f0f0;
	font-size: 0.875rem;
}

.won-result-num {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	background: var(--won-primary);
	color: #fff;
	border-radius: 50%;
	font-size: 0.75rem;
	font-weight: 700;
}

.won-result-name {
	font-weight: 600;
}

.won-result-time {
	font-size: 0.75rem;
	color: var(--won-text-muted);
}

.won-no-results {
	text-align: center;
	color: var(--won-text-muted);
	font-size: 0.875rem;
	padding: 2rem 1rem;
	margin: 0;
}

/* Fullscreen — wheel area only */
.won-wheel-area:fullscreen,
.won-wheel-area.won-is-fullscreen,
.won-wheel-area:-webkit-full-screen {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	padding: 2rem;
	box-sizing: border-box;
}

.won-wheel-area:fullscreen .won-wheel-wrapper,
.won-wheel-area.won-is-fullscreen .won-wheel-wrapper,
.won-wheel-area:-webkit-full-screen .won-wheel-wrapper {
	width: min(85vmin, 720px);
	height: min(85vmin, 720px);
}

/* Spinning state */
.won-app.won-spinning .won-canvas {
	cursor: wait;
}

.won-app.won-spinning .won-sidebar {
	pointer-events: none;
	opacity: 0.7;
}

/* Responsive */
@media (max-width: 900px) {
	.won-main {
		grid-template-columns: 1fr;
	}

	.won-sidebar {
		border-left: none;
		border-top: 1px solid var(--won-border);
	}

	.won-wheel-area {
		padding: 1.5rem 1rem;
	}

	.won-entries-list {
		max-height: 280px;
	}
}

@media (max-width: 480px) {
	.won-toolbar {
		padding: 0.75rem;
	}

	.won-title-input {
		font-size: 1.1rem;
		max-width: 100%;
	}

	.won-entry-item {
		grid-template-columns: auto 28px 36px 1fr auto;
	}

	.won-advanced .won-entry-item {
		grid-template-columns: auto 28px 36px 1fr auto auto auto;
	}
}

/* Shared wheel banner */
.won-shared-banner {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.625rem 1rem;
	background: linear-gradient(135deg, #eef2ff 0%, #e0e7ff 100%);
	border-top: 1px solid #c7d2fe;
	color: #3730a3;
	font-size: 0.8125rem;
	font-weight: 500;
}

.won-shared-banner svg {
	flex-shrink: 0;
	color: #6366f1;
}

/* Share modal — Tailwind-inspired */
.won-modal-overlay {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
}

.won-modal-overlay[hidden] {
	display: none !important;
}

.won-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.55);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
}

.won-modal-card {
	position: relative;
	width: 100%;
	max-width: 420px;
	background: #ffffff;
	border-radius: 16px;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	padding: 2rem 1.75rem 1.75rem;
	animation: won-modal-in 0.2s ease-out;
}

@keyframes won-modal-in {
	from {
		opacity: 0;
		transform: scale(0.96) translateY(8px);
	}
	to {
		opacity: 1;
		transform: scale(1) translateY(0);
	}
}

.won-modal-close {
	position: absolute;
	top: 1rem;
	right: 1rem;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border: none;
	border-radius: 8px;
	background: transparent;
	color: #64748b;
	cursor: pointer;
	transition: background 0.15s, color 0.15s;
}

.won-modal-close:hover {
	background: #f1f5f9;
	color: #0f172a;
}

.won-modal-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	margin: 0 auto 1rem;
	border-radius: 14px;
	background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
	color: #ffffff;
	box-shadow: 0 10px 25px -5px rgba(99, 102, 241, 0.4);
}

.won-modal-icon-success {
	background: linear-gradient(135deg, #10b981 0%, #059669 100%);
	box-shadow: 0 10px 25px -5px rgba(16, 185, 129, 0.4);
}

.won-modal-title {
	margin: 0 0 0.5rem;
	font-size: 1.375rem;
	font-weight: 700;
	color: #0f172a;
	text-align: center;
	letter-spacing: -0.02em;
}

.won-modal-subtitle {
	margin: 0 0 1.5rem;
	font-size: 0.875rem;
	color: #64748b;
	text-align: center;
	line-height: 1.5;
}

.won-auth-tabs {
	display: flex;
	gap: 0.25rem;
	padding: 0.25rem;
	margin-bottom: 1.25rem;
	background: #f1f5f9;
	border-radius: 10px;
}

.won-auth-tab {
	flex: 1;
	padding: 0.5rem 0.75rem;
	font-size: 0.8125rem;
	font-weight: 600;
	border: none;
	border-radius: 8px;
	background: transparent;
	color: #64748b;
	cursor: pointer;
	transition: background 0.15s, color 0.15s, box-shadow 0.15s;
}

.won-auth-tab:hover {
	color: #334155;
}

.won-auth-tab.won-auth-tab-active {
	background: #ffffff;
	color: #4f46e5;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.won-form-group {
	margin-bottom: 1rem;
}

.won-form-label {
	display: block;
	margin-bottom: 0.375rem;
	font-size: 0.8125rem;
	font-weight: 600;
	color: #334155;
}

.won-form-input {
	display: block;
	width: 100%;
	padding: 0.625rem 0.875rem;
	font-size: 0.9375rem;
	line-height: 1.5;
	color: #0f172a;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 10px;
	transition: border-color 0.15s, box-shadow 0.15s;
}

.won-form-input::placeholder {
	color: #94a3b8;
}

.won-form-input:hover {
	border-color: #cbd5e1;
}

.won-form-input:focus {
	border-color: #6366f1;
	box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.won-form-error {
	margin: 0 0 1rem;
	padding: 0.625rem 0.875rem;
	font-size: 0.8125rem;
	color: #b91c1c;
	background: #fef2f2;
	border: 1px solid #fecaca;
	border-radius: 8px;
}

.won-form-error[hidden] {
	display: none !important;
}

.won-form-submit {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 0.75rem 1rem;
	font-size: 0.9375rem;
	font-weight: 600;
	color: #ffffff;
	background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
	border: none;
	border-radius: 10px;
	cursor: pointer;
	transition: opacity 0.15s, transform 0.1s, box-shadow 0.15s;
	box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.won-form-submit:hover:not(:disabled) {
	opacity: 0.95;
	box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.won-form-submit:active:not(:disabled) {
	transform: scale(0.98);
}

.won-form-submit:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.won-share-link-wrap {
	display: flex;
	gap: 0.5rem;
	margin-bottom: 1rem;
}

.won-share-link-input {
	flex: 1;
	min-width: 0;
	padding: 0.625rem 0.875rem;
	font-size: 0.8125rem;
	color: #334155;
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 10px;
}

.won-share-copy-btn {
	flex-shrink: 0;
	padding: 0.625rem 1rem;
	font-size: 0.8125rem;
	font-weight: 600;
	color: #4f46e5;
	background: #eef2ff;
	border: 1px solid #c7d2fe;
	border-radius: 10px;
	cursor: pointer;
	transition: background 0.15s;
	white-space: nowrap;
}

.won-share-copy-btn:hover {
	background: #e0e7ff;
}

.won-share-copy-btn.won-copied {
	color: #059669;
	background: #ecfdf5;
	border-color: #a7f3d0;
}

.won-modal-success[hidden],
.won-modal-auth[hidden] {
	display: none !important;
}

.won-app.won-shared-view:not(.won-shared-owner) .won-toolbar-left .won-save-status::after {
	content: ' · ' attr(data-shared-label);
	color: #6366f1;
	font-weight: 500;
}

.won-app.won-readonly .won-entry-text,
.won-app.won-readonly .won-entry-color,
.won-app.won-readonly .won-entry-weight,
.won-app.won-readonly .won-entry-delete,
.won-app.won-readonly .won-entry-drag,
.won-app.won-readonly .won-entry-image-btn,
.won-app.won-readonly .won-entry-image-remove,
.won-app.won-readonly .won-customize-panel,
.won-app.won-readonly .won-clear-results-btn {
	pointer-events: none;
	opacity: 0.55;
}

body.won-modal-open {
	overflow: hidden;
}

/* Shared guest — wheel + fullscreen only */
.won-app.won-guest-locked .won-toolbar,
.won-app.won-guest-locked .won-main,
.won-app.won-guest-locked .won-shared-banner {
	visibility: hidden;
	pointer-events: none;
	max-height: 0;
	overflow: hidden;
	opacity: 0;
}

.won-app.won-shared-guest-mode .won-sidebar,
.won-app.won-shared-guest-mode .won-customize-btn,
.won-app.won-shared-guest-mode .won-new-btn,
.won-app.won-shared-guest-mode .won-share-btn,
.won-app.won-shared-guest-mode .won-title-input,
.won-app.won-shared-guest-mode .won-save-status,
.won-app.won-shared-guest-mode .won-customize-panel {
	display: none !important;
}

.won-app.won-shared-guest-mode .won-main {
	grid-template-columns: 1fr;
}

.won-app.won-shared-guest-mode .won-toolbar {
	justify-content: flex-end;
}

.won-app.won-shared-guest-mode .won-toolbar-left {
	display: none;
}

.won-guest-spin-notice {
	text-align: center;
	margin: 0.75rem 0 0;
	padding: 0.625rem 1rem;
	font-size: 0.875rem;
	font-weight: 500;
	color: #92400e;
	background: #fffbeb;
	border: 1px solid #fde68a;
	border-radius: 10px;
}

.won-guest-spin-notice[hidden] {
	display: none !important;
}

.won-app.won-guest-spun .won-spin-overlay {
	pointer-events: none;
	cursor: not-allowed;
	opacity: 0.5;
}

.won-app.won-guest-spun .won-canvas {
	cursor: not-allowed;
}

.won-share-modal.won-visitor-mode .won-modal-close,
.won-share-modal.won-visitor-mode [data-wnv-close-modal].won-modal-backdrop {
	pointer-events: none;
}

.won-share-modal.won-visitor-mode .won-modal-close {
	display: none;
}

.won-share-modal.won-visitor-mode .won-modal-success {
	display: none !important;
}

.won-result-spinner {
	display: block;
	font-size: 0.75rem;
	font-weight: 500;
	color: #6366f1;
	margin-top: 0.125rem;
}
