/* RoyalComply Admin Styles */

/* === Cards === */
.rcomply-card {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	padding: 20px;
	margin: 15px 0;
	box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
}

.rcomply-card h2 {
	font-size: 16px;
	font-weight: 600;
	color: #1d2327;
	padding-bottom: 10px;
	border-bottom: 1px solid #f0f0f1;
	margin-bottom: 15px;
}

/* === Stat Cards === */
.rcomply-stats {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 15px;
	margin: 15px 0;
}

.rcomply-stat-card {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	padding: 20px;
	text-align: center;
	box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
}

.rcomply-stat-icon {
	font-size: 28px;
	width: 28px;
	height: 28px;
	display: block;
	margin: 0 auto 8px;
}

.rcomply-stat-value {
	font-size: 32px;
	font-weight: 600;
	color: #1d2327;
	line-height: 1.2;
}

.rcomply-stat-label {
	font-size: 13px;
	color: #646970;
	margin-top: 4px;
}

/* === Dashboard Grid === */
.rcomply-dashboard-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 15px;
	margin-top: 15px;
}

/* === Filters === */
.rcomply-filters {
	margin: 15px 0;
}

.rcomply-filters form {
	display: flex;
	gap: 8px;
	align-items: center;
	flex-wrap: wrap;
}

/* === Table === */
.rcomply-table td,
.rcomply-table th {
	vertical-align: middle;
}

.rcomply-url-cell {
	max-width: 200px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.rcomply-sep {
	color: #c3c4c7;
	margin: 0 2px;
}

/* === Badges === */
.rcomply-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 3px;
	font-size: 12px;
	font-weight: 500;
	line-height: 1.5;
	white-space: nowrap;
}

.rcomply-badge-necessary { background: #d1fae5; color: #065f46; }
.rcomply-badge-analytics { background: #dbeafe; color: #1e40af; }
.rcomply-badge-marketing { background: #fce7f3; color: #9d174d; }
.rcomply-badge-preferences { background: #e0e7ff; color: #3730a3; }
.rcomply-badge-info { background: #f3f4f6; color: #374151; }
.rcomply-badge-warning { background: #fef3c7; color: #92400e; }

/* === Empty State === */
.rcomply-empty-state {
	text-align: center;
	padding: 40px 20px;
	color: #646970;
}

.rcomply-empty-state p {
	margin-top: 10px;
}

/* === Pagination === */
.rcomply-pagination {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin: 15px 0;
	padding: 10px 0;
}

.rcomply-pagination-info {
	color: #646970;
	font-size: 13px;
}

.rcomply-pagination-links {
	display: flex;
	gap: 4px;
}

/* === Modal === */
.rcomply-modal {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
}

.rcomply-modal-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
}

.rcomply-modal-content {
	position: relative;
	background: #fff;
	border-radius: 4px;
	width: 560px;
	max-width: 90vw;
	max-height: 80vh;
	display: flex;
	flex-direction: column;
	box-shadow: 0 5px 30px rgba(0, 0, 0, 0.3);
}

.rcomply-modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 15px 20px;
	border-bottom: 1px solid #dcdcde;
}

.rcomply-modal-header h2 {
	margin: 0;
	font-size: 16px;
}

.rcomply-modal-close {
	background: none;
	border: none;
	font-size: 24px;
	cursor: pointer;
	color: #646970;
	padding: 0;
	line-height: 1;
}

.rcomply-modal-body {
	padding: 15px 20px;
	overflow-y: auto;
	flex: 1;
}

.rcomply-modal-body .form-table th {
	width: 130px;
	padding: 10px 0;
}

.rcomply-modal-body .form-table td {
	padding: 10px 0;
}

.rcomply-modal-footer {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	padding: 15px 20px;
	border-top: 1px solid #dcdcde;
}

/* === Checklist === */
.rcomply-checklist {
	list-style: none;
	padding: 0;
	margin: 0;
}

.rcomply-checklist li {
	padding: 10px 0;
	border-bottom: 1px solid #f0f0f1;
	display: flex;
	align-items: center;
	gap: 8px;
}

.rcomply-checklist li:last-child {
	border-bottom: none;
}

.rcomply-checklist li .dashicons-yes {
	color: #22c55e;
}

.rcomply-checklist li .dashicons-no-alt {
	color: #ef4444;
}

.rcomply-checklist li.done {
	color: #646970;
}

.rcomply-checklist li a {
	margin-left: auto;
	font-size: 12px;
}

/* === Chart === */
.rcomply-chart-container {
	position: relative;
	width: 100%;
	max-height: 250px;
}

/* === Banner Design === */
.rcomply-banner-design-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 15px;
	margin-top: 15px;
}

/* Preview container */
.rcomply-preview-container {
	background: #f0f0f1;
	border-radius: 4px;
	min-height: 300px;
	position: relative;
	overflow: hidden;
}

.rcomply-preview-banner {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	background: #1e293b;
	color: #f1f5f9;
	padding: 16px 20px;
	font-size: 12px;
	line-height: 1.5;
}

.rcomply-preview-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.rcomply-preview-text p {
	margin: 0;
	font-size: 11px;
}

.rcomply-preview-actions {
	display: flex;
	gap: 6px;
	flex-shrink: 0;
}

.rcomply-preview-btn {
	padding: 6px 12px;
	border: none;
	border-radius: 4px;
	font-size: 11px;
	cursor: default;
	white-space: nowrap;
}

.rcomply-preview-accept {
	background: #22c55e;
	color: #fff;
}

.rcomply-preview-reject {
	background: transparent;
	color: #94a3b8;
	border: 1px solid #94a3b8;
}

.rcomply-preview-settings-btn {
	background: transparent;
	color: #f1f5f9;
	text-decoration: underline;
}

/* === Utility: Hidden === */
.rcomply-hidden { display: none; }

/* === Card Title (replaces inline margin-top:0) === */
.rcomply-card-title { margin-top: 0; }
.rcomply-card-narrow { max-width: 700px; }

/* === Icon Colors (replaces inline style colors) === */
.rcomply-icon-green { color: #22c55e; }
.rcomply-icon-blue { color: #3b82f6; }
.rcomply-icon-purple { color: #8b5cf6; }
.rcomply-icon-amber { color: #f59e0b; }
.rcomply-icon-red { color: #ef4444; }
.rcomply-icon-gold { color: #c9a227; margin-right: 4px; }
.rcomply-icon-warning { color: #dba617; margin-right: 4px; }
.rcomply-icon-empty { font-size: 36px; width: 36px; height: 36px; color: #ccc; }

/* === Notice variants === */
.rcomply-notice-gold { margin: 5px 0 20px; border-left-color: #c9a227; }
.rcomply-notice-warning { margin: 10px 0 15px; }

/* === Button with icon (replaces inline flex) === */
.rcomply-btn-icon { display: inline-flex; align-items: center; gap: 6px; }
.rcomply-btn-dashicon { font-size: 16px; width: 16px; height: 16px; line-height: 1; }

/* === Inline description === */
.rcomply-description-inline { margin-left: 8px; }

/* === Empty state variants === */
.rcomply-empty-state-lg { padding: 40px 0; }
.rcomply-empty-state-sm { padding: 30px 0; }

/* === Table column widths === */
.rcomply-col-8 { width: 8%; }
.rcomply-col-10 { width: 10%; }
.rcomply-col-12 { width: 12%; }
.rcomply-col-15 { width: 15%; }
.rcomply-col-20 { width: 20%; }
.rcomply-col-25 { width: 25%; }
.rcomply-col-num { width: 80px; text-align: right; }
.rcomply-text-right { text-align: right; }

/* === Consent log specific === */
.rcomply-input-country { width: 180px; }
.rcomply-hash-code { font-size: 11px; }

/* === Color picker fixes === */
.wp-picker-container {
	display: inline-block;
}

/* === Responsive === */
@media screen and (max-width: 782px) {
	.rcomply-stats {
		grid-template-columns: repeat(2, 1fr);
	}

	.rcomply-dashboard-grid {
		grid-template-columns: 1fr;
	}

	.rcomply-banner-design-grid {
		grid-template-columns: 1fr;
	}

	.rcomply-stat-value {
		font-size: 24px;
	}
}
