/**
 * Admin styles for Validation Muse for Contact Form 7.
 *
 * @package ValidationMuse
 * @since   1.0.0
 */

.vmcf7-panel {
	padding: 20px;
}

.vmcf7-enable-toggle {
	margin-bottom: 20px;
}

.vmcf7-hidden {
	display: none !important;
}

.vmcf7-col-25 {
	width: 25%;
}

.vmcf7-col-37 {
	width: 37.5%;
}

.vmcf7-fields-table {
	width: 100%;
	border-collapse: collapse;
	margin-top: 15px;
}

.vmcf7-fields-table th,
.vmcf7-fields-table td {
	padding: 10px;
	border: 1px solid #ddd;
	text-align: left;
	vertical-align: middle;
}

.vmcf7-fields-table th {
	background: #f5f5f5;
}

.vmcf7-fields-table input[type="text"] {
	width: 100%;
	padding: 5px;
}

.vmcf7-fields-table.vmcf7-disabled {
	opacity: 0.5;
	pointer-events: none;
}

.vmcf7-field-name {
	font-weight: 600;
	color: #23282d;
	display: flex;
	align-items: center;
	gap: 10px;
}

.vmcf7-field-type {
	color: #666;
	font-size: 12px;
	margin-top: 4px;
}

.vmcf7-no-fields {
	padding: 15px;
	background: #fff;
	border-left: 4px solid #dc3232;
}

/* Flavor Translation Tabs */

.vmcf7-translations {
	margin-top: 30px;
	border-top: 1px solid #ddd;
	padding-top: 20px;
}

.vmcf7-translations.vmcf7-disabled {
	opacity: 0.5;
	pointer-events: none;
}

.vmcf7-translations h3 {
	margin: 0 0 15px;
}

.vmcf7-lang-tabs {
	display: flex;
	align-items: center;
	gap: 0;
	border-bottom: 1px solid #ddd;
	margin-bottom: 0;
}

.vmcf7-lang-tab {
	padding: 8px 16px;
	border: 1px solid transparent;
	border-bottom: none;
	background: none;
	cursor: pointer;
	font-size: 13px;
	color: #646970;
	margin-bottom: -1px;
	border-radius: 3px 3px 0 0;
}

.vmcf7-lang-tab:hover {
	color: #135e96;
}

.vmcf7-lang-tab.active {
	background: #fff;
	border-color: #ddd;
	color: #1d2327;
	font-weight: 600;
}

.vmcf7-ai-translate {
	margin-left: auto !important;
	margin-bottom: 4px !important;
}

.vmcf7-lang-panel {
	display: none;
}

.vmcf7-lang-panel.active {
	display: block;
}

.vmcf7-translation-table {
	margin-top: 0;
	border-top: none;
}

.vmcf7-translation-table input::placeholder {
	font-style: italic;
	color: #a7aaad;
}

.vmcf7-notice {
	margin: 10px 0;
}

/* Toolbar */
.vmcf7-toolbar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	background: #fff;
	padding: 10px 15px;
	border: 1px solid #ccd0d4;
	border-radius: 4px;
	margin-bottom: 15px;
	box-shadow: 0 1px 1px rgba(0,0,0,.04);
}

.vmcf7-toolbar.vmcf7-disabled {
	opacity: 0.5;
	pointer-events: none;
}

.vmcf7-toolbar-left, .vmcf7-toolbar-right {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
}

/* Vertically center the dashicon + label inside toolbar buttons. */
.vmcf7-toolbar .button {
	display: inline-flex;
	align-items: center;
	gap: 5px;
}

.vmcf7-toolbar .button .dashicons {
	line-height: 1;
	vertical-align: middle;
}

.vmcf7-copy-select-wrap {
	display: inline-flex;
	align-items: center;
	gap: 5px;
}

.vmcf7-sharing-notice {
	padding: 10px 15px;
	margin-bottom: 15px;
	border-radius: 4px;
	border-left: 4px solid #fff;
}

.vmcf7-sharing-notice.success {
	background: #edfaef;
	border-left-color: #46b450;
	color: #255d28;
}

.vmcf7-sharing-notice.error {
	background: #fdf2f2;
	border-left-color: #dc3232;
	color: #a02626;
}

/* Accordion Rows */
.vmcf7-toggle-advanced,
.vmcf7-toggle-advanced-trans {
	font-size: 11px !important;
	padding: 0 !important;
	height: auto !important;
	line-height: normal !important;
	text-decoration: none !important;
	vertical-align: middle !important;
	margin-left: 5px !important;
}

.vmcf7-toggle-advanced .dashicons,
.vmcf7-toggle-advanced-trans .dashicons {
	font-size: 14px;
	width: 14px;
	height: 14px;
	line-height: 14px;
	vertical-align: text-top;
}

.vmcf7-advanced-row,
.vmcf7-advanced-trans-row {
	display: none;
	background: #fbfbfb;
}

.vmcf7-advanced-row.is-open,
.vmcf7-advanced-trans-row.is-open {
	display: table-row;
}

.vmcf7-advanced-rules-container {
	padding: 4px 0 8px;
	border: none;
	background: transparent;
	box-shadow: none;
}

.vmcf7-advanced-rules-container.translation-rules {
	border-top: none;
}

.vmcf7-rule-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 20px;
}

.vmcf7-rule-group {
	border: 1px solid #e5e5e5;
	border-radius: 4px;
	padding: 15px;
	background: #fff;
}

.vmcf7-rule-group h4 {
	margin: 0 0 12px;
	font-size: 13px;
	border-bottom: 1px solid #eee;
	padding-bottom: 6px;
	color: #1d2327;
}

.vmcf7-input-wrap {
	margin-bottom: 10px;
}

.vmcf7-input-wrap:last-child {
	margin-bottom: 0;
}

.vmcf7-input-wrap label {
	display: block;
	font-weight: 600;
	font-size: 11px;
	color: #50575e;
	margin-bottom: 4px;
}

.vmcf7-input-wrap input[type="text"],
.vmcf7-input-wrap input[type="number"] {
	width: 100%;
	padding: 6px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	box-sizing: border-box;
}

.vmcf7-flex-inputs {
	display: flex;
	gap: 10px;
}

.vmcf7-flex-inputs .short {
	flex: 0 0 80px;
}

.vmcf7-flex-inputs .long {
	flex: 1;
}

/* Linter warnings */
.vmcf7-lint-warning {
	color: #d63638;
	font-size: 11px;
	margin-top: 4px;
	font-weight: 500;
	line-height: 1.4;
}

/* Live Preview Card */
.vmcf7-live-preview-section {
	margin-top: 30px;
	background: #fff;
	border: 1px solid #ccd0d4;
	border-radius: 4px;
	padding: 20px;
	box-shadow: 0 1px 1px rgba(0,0,0,.04);
}

.vmcf7-live-preview-section h3 {
	margin-top: 0;
	color: #1d2327;
}

.vmcf7-preview-selector-wrap {
	margin-bottom: 15px;
}

.vmcf7-preview-selector-wrap select {
	min-width: 200px;
	padding: 5px;
}

.vmcf7-preview-card {
	background: #f6f7f7;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	padding: 15px;
}

.vmcf7-preview-label {
	margin-bottom: 15px;
	font-size: 13px;
	color: #1d2327;
}

.vmcf7-preview-errors {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.vmcf7-preview-err-row {
	display: flex;
	align-items: baseline;
	gap: 10px;
	background: #fff;
	border: 1px solid #ccd0d4;
	border-left: 4px solid #d63638;
	padding: 8px 12px;
	border-radius: 2px;
}

.vmcf7-preview-err-row strong {
	flex: 0 0 200px;
	font-size: 12px;
	color: #50575e;
}

.vmcf7-preview-err-row .wpcf7-not-valid-tip {
	display: inline;
	color: #dc3232;
	font-weight: 600;
}
