.cg-generator-wrapper {
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 1.5rem;
	background: #fff;
	box-shadow: 0 20px 40px rgba(15, 23, 42, 0.1);
	margin-bottom: 2rem;
}

.cg-layout-modal .cg-generator {
	position: relative;
}

.cg-steps-nav {
	display: flex;
	gap: 0.5rem;
	margin-bottom: 1rem;
	flex-wrap: wrap;
}

.cg-step-trigger {
	flex: 1;
	padding: 0.8rem 1rem;
	border-radius: 8px;
	border: 1px solid #cbd5f5;
	background: #f8fafc;
	font-weight: 600;
	color: #0f172a;
	cursor: pointer;
}

.cg-step-trigger.is-active {
	background: #475569;
	color: #fff;
	border-color: #475569;
}

.cg-step-panel {
	display: none;
	gap: 1.5rem;
}

.cg-step-panel.is-active {
	display: block;
}

.cg-field {
	margin-bottom: 1.2rem;
}

.cg-field label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.4rem;
}

.cg-field input[type="text"],
.cg-field select,
.cg-field textarea {
	width: 100%;
	padding: 0.7rem 0.9rem;
	border-radius: 8px;
	border: 1px solid #cbd5f5;
	font-size: 1rem;
}

.cg-field textarea {
	min-height: 140px;
	resize: vertical;
}

.cg-two-col {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 1rem;
}

.cg-message-library {
	background: #f8fafc;
	padding: 1rem;
	border-radius: 12px;
}

.cg-library-list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	gap: 0.5rem;
	margin-top: 0.8rem;
}

.cg-library-item {
	border: 1px dashed #cbd5f5;
	border-radius: 10px;
	padding: 0.8rem;
	background: #fff;
	cursor: pointer;
	text-align: left;
}

.cg-template-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
	gap: 1rem;
}

.cg-template-card {
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	padding: 0.8rem;
	background: #fff;
	cursor: pointer;
	text-align: left;
}

.cg-template-card.is-selected {
	border-color: #475569;
	box-shadow: 0 0 0 2px rgba(71, 85, 105, 0.3);
}

.cg-template-thumb {
	height: 100px;
	border-radius: 10px;
	background-size: cover;
	background-position: center;
	margin-bottom: 0.5rem;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2rem;
}

.cg-preview-panel {
	border: 1px solid #cbd5f5;
	border-radius: 16px;
	padding: 1rem;
	background: #0f172a;
	color: #fff;
}

.cg-preview-stage {
	min-height: 280px;
	border-radius: 12px;
	padding: 1rem;
	background: #fff;
	margin-top: 1rem;
}

.cg-preview-card {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 1rem;
	align-items: center;
}

.cg-preview-media img {
	width: 100%;
	border-radius: 10px;
	object-fit: cover;
}

.cg-preview-icon {
	width: 120px;
	height: 120px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.5);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2.5rem;
	margin: 0 auto;
}

.cg-actions {
	display: flex;
	gap: 1rem;
	justify-content: flex-end;
	margin-top: 1.5rem;
}

.cg-share-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
	gap: 0.8rem;
	list-style: none;
	padding: 0;
}

.cg-share-grid a,
.cg-share-grid button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	border-radius: 10px;
	background: #e2e8f0;
	border: none;
	cursor: pointer;
	font-weight: 600;
}

.cg-share-output {
	margin-top: 1rem;
	background: #f8fafc;
	padding: 1rem;
	border-radius: 10px;
	font-family: monospace;
	font-size: 0.9rem;
	word-break: break-all;
}

.cg-ad-slot {
	margin: 1rem 0;
	text-align: center;
}

.cg-custom-event {
	display: none;
	margin-top: 0.5rem;
}

.cg-custom-event.is-visible {
	display: block;
}

.cg-celebration-page {
	padding: 3rem 1rem;
	max-width: 960px;
	margin: 0 auto;
}

.cg-celebration-stage {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 2rem;
	align-items: center;
	background: #fff;
	border-radius: 18px;
	box-shadow: 0 30px 60px rgba(15, 23, 42, 0.15);
	padding: 2rem;
}

.cg-stage-media img {
	width: 100%;
	border-radius: 14px;
}

.cg-stage-copy h1 {
	font-size: clamp(2rem, 4vw, 3.75rem);
	margin-bottom: 1rem;
}

.cg-share-bar {
	margin-top: 1.5rem;
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: center;
}

.cg-share-link,
.cg-share-copy,
.cg-extra-actions .button {
	padding: 0.6rem 1rem;
	border-radius: 8px;
	border: 1px solid #94a3b8;
	background: #f8fafc;
	text-decoration: none;
	color: #0f172a;
	font-weight: 600;
}

.cg-extra-actions {
	margin-top: 2rem;
	display: flex;
	gap: 0.5rem;
}

.cg-report-modal {
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.7);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 9999;
}

.cg-report-dialog {
	background: #fff;
	padding: 2rem;
	border-radius: 18px;
	max-width: 480px;
	width: 100%;
	box-shadow: 0 25px 45px rgba(15, 23, 42, 0.3);
}

.cg-report-close {
	background: transparent;
	border: none;
	font-size: 1.5rem;
	position: absolute;
	top: 1rem;
	right: 1rem;
	cursor: pointer;
}

@media (max-width: 640px) {
	.cg-actions {
		flex-direction: column;
	}

	.cg-share-bar {
		flex-direction: column;
		align-items: stretch;
	}
}

