/**
 * AffiStyle Admin Dashboard & Metabox Styles
 *
 * @package AffiStyle
 *
 * Table of Contents:
 *
 * 1.0 General Container Setup
 * 2.0 Field Groups & Form Controls
 * 2.1 Quick-Fill Product URL Grabber
 * 3.0 Grid Rows & Layout Columns
 * 4.0 Media Image Uploader Component
 * 5.0 Helper Text & Headings
 * 6.0 Analytics Header & Action Buttons
 * 7.0 Admin List Table Shortcode & Quick Preview Modal
 * 8.0 Animations & Utilities
 * 9.0 Responsive Media Queries
 */

/**
 * 1.0 General Container Setup
 */
.affistyle-metabox-wrapper {
	box-sizing: border-box;
	padding: 12px 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.affistyle-metabox-wrapper *,
.affistyle-metabox-wrapper *::before,
.affistyle-metabox-wrapper *::after {
	box-sizing: border-box;
}


/**
 * 2.0 Field Groups & Form Controls
 */
.affistyle-field-group {
	margin-bottom: 20px;
}

.affistyle-field-group label {
	display: block;
	margin-bottom: 6px;
	color: #1d2327;
	font-size: 13px;
	font-weight: 600;
}

.affistyle-field-group input[type="text"],
.affistyle-field-group input[type="url"],
.affistyle-field-group input[type="number"],
.affistyle-field-group textarea,
.affistyle-field-group select {
	width: 100%;
	max-width: 100%;
	padding: 8px 12px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	background: #fff;
	color: #2c3338;
	font-size: 14px;
	line-height: 1.4;
	transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.affistyle-field-group input[type="color"] {
	height: 38px;
	padding: 4px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	background: #fff;
	vertical-align: middle;
	cursor: pointer;
}

.affistyle-field-group input[type="text"]:focus,
.affistyle-field-group input[type="url"]:focus,
.affistyle-field-group input[type="number"]:focus,
.affistyle-field-group input[type="color"]:focus,
.affistyle-field-group textarea:focus,
.affistyle-field-group select:focus {
	border-color: #2271b1;
	outline: 2px solid transparent;
	box-shadow: 0 0 0 1px #2271b1;
}

.affistyle-field-group textarea {
	min-height: 90px;
	resize: vertical;
}


/**
 * 2.1 Quick-Fill Product URL Grabber
 */
.affistyle-quick-fill-card {
	margin-bottom: 24px;
	padding: 16px;
	border: 1px solid #c7d2fe;
	border-radius: 8px;
	background: #f8faff;
}

.affistyle-quick-fill-header {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 12px;
}

.affistyle-quick-fill-icon {
	flex-shrink: 0;
	width: 24px;
	height: 24px;
	margin-top: 2px;
	color: #4f46e5;
	font-size: 24px;
}

.affistyle-quick-fill-header strong {
	color: #312e81;
	font-size: 14px;
}

.affistyle-quick-fill-input-row {
	display: flex;
	align-items: center;
	gap: 10px;
}

.affistyle-quick-fill-input-row input[type="url"] {
	flex: 1;
	min-width: 0;
	height: 36px;
	padding: 0 12px;
	border: 1px solid #a5b4fc;
	border-radius: 4px;
	background: #fff;
	color: #1e1b4b;
	font-size: 13px;
}

.affistyle-quick-fill-input-row input[type="url"]:focus {
	border-color: #4f46e5;
	outline: 2px solid transparent;
	box-shadow: 0 0 0 1px #4f46e5;
}

.affistyle-quick-fill-input-row .button-primary {
	display: inline-flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	height: 36px;
	padding: 0 16px;
	border-color: #4338ca;
	border-radius: 4px;
	background: #4f46e5;
	color: #fff;
	font-weight: 600;
	transition: background 0.15s ease-in-out;
}

.affistyle-quick-fill-input-row .button-primary:hover,
.affistyle-quick-fill-input-row .button-primary:focus {
	border-color: #3730a3;
	background: #4338ca;
	color: #fff;
}

.affistyle-quick-fill-status {
	margin-top: 10px;
	padding: 8px 12px;
	border-radius: 4px;
	font-size: 13px;
	line-height: 1.4;
}

.affistyle-quick-fill-status.affistyle-status-loading {
	border: 1px solid #bfdbfe;
	background: #eff6ff;
	color: #1e40af;
}

.affistyle-quick-fill-status.affistyle-status-success {
	border: 1px solid #bbf7d0;
	background: #f0fdf4;
	color: #166534;
}

.affistyle-quick-fill-status.affistyle-status-error {
	border: 1px solid #fecaca;
	background: #fef2f2;
	color: #991b1b;
}


/**
 * 3.0 Grid Rows & Layout Columns
 */
.affistyle-field-row {
	display: flex;
	gap: 20px;
	width: 100%;
}

.affistyle-field-row .affistyle-field-group {
	flex: 1;
	min-width: 0;
}


/**
 * 4.0 Media Image Uploader Component
 */
.affistyle-image-upload-container {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-top: 6px;
}

.affistyle-image-preview {
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	flex-shrink: 0;
	width: 80px;
	height: 80px;
	border: 1px dashed #c3c4c7;
	border-radius: 6px;
	background: #f6f7f7;
}

.affistyle-image-preview img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.affistyle-image-actions {
	display: flex;
	flex-direction: column;
	gap: 8px;
}


/**
 * 5.0 Helper Text & Headings
 */
.affistyle-description {
	display: block;
	margin-top: 6px;
	color: #646970;
	font-size: 12px;
	line-height: 1.4;
}

.affistyle-section-heading {
	margin: 24px 0 12px;
	padding-bottom: 8px;
	border-bottom: 1px solid #dcdcde;
	color: #1d2327;
	font-size: 15px;
	font-weight: 700;
}


/**
 * 6.0 Analytics Header & Action Buttons
 */
.affistyle-analytics-header {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 12px;
}

.affistyle-analytics-header .wp-heading-inline {
	margin-right: 0;
	padding-top: 0;
	padding-bottom: 0;
}

.affistyle-read-more-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-weight: 600;
}

.affistyle-analytics-chart-card {
	background: #ffffff;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	padding: 20px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
	margin-top: 20px;
}

.affistyle-analytics-chart-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 12px;
	margin-bottom: 16px;
	padding-bottom: 12px;
	border-bottom: 1px solid #f1f5f9;
}

.affistyle-analytics-chart-title-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
}

.affistyle-analytics-chart-icon {
	font-size: 24px;
	line-height: 1;
}

.affistyle-analytics-chart-title {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	color: #0f172a;
	line-height: 1.3;
}

.affistyle-analytics-chart-subtitle {
	display: block;
	font-size: 12px;
	color: #64748b;
	margin-top: 2px;
}

.affistyle-analytics-chart-meta {
	display: flex;
	align-items: center;
	gap: 8px;
}

.affistyle-chart-meta-pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 9999px;
	background: #eff6ff;
	color: #1d4ed8;
	font-size: 12px;
	font-weight: 600;
	border: 1px solid #dbeafe;
}

.affistyle-chart-meta-dot {
	display: inline-block;
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: #2563eb;
}

.affistyle-chart-wrapper {
	position: relative;
	width: 100%;
	height: 260px;
}

.affistyle-analytics-canvas {
	display: block;
	width: 100%;
	height: 100%;
	cursor: crosshair;
}

.affistyle-chart-tooltip {
	position: absolute;
	pointer-events: none;
	opacity: 0;
	transform: translate(-50%, -100%);
	transition: opacity 0.15s ease, transform 0.15s ease;
	background: #0f172a;
	color: #ffffff;
	padding: 6px 12px;
	border-radius: 6px;
	box-shadow: 0 4px 12px rgba(15, 23, 42, 0.25);
	z-index: 10;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	white-space: nowrap;
}

.affistyle-chart-tooltip.affistyle-tooltip-visible {
	opacity: 1;
	transform: translate(-50%, -100%) translateY(-6px);
}

.affistyle-chart-tooltip-date {
	font-size: 11px;
	color: #94a3b8;
	font-weight: 500;
	margin-bottom: 2px;
}

.affistyle-chart-tooltip-val {
	display: flex;
	align-items: center;
	gap: 6px;
}

.affistyle-chart-tooltip-badge {
	font-size: 13px;
	font-weight: 700;
	color: #38bdf8;
}

.affistyle-pro-teaser-card {
	background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
	border: 1px solid #bfdbfe;
	border-radius: 8px;
	padding: 20px;
	margin-top: 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 16px;
	box-shadow: 0 1px 3px rgba(37, 99, 235, 0.05);
}

.affistyle-pro-teaser-content {
	max-width: 720px;
}

.affistyle-pro-teaser-badge {
	display: inline-block;
	background: linear-gradient(135deg, #4f46e5 0%, #2563eb 100%);
	color: #ffffff;
	font-size: 10px;
	font-weight: 700;
	padding: 3px 8px;
	border-radius: 4px;
	letter-spacing: 0.5px;
	margin-bottom: 8px;
}

.affistyle-pro-teaser-title {
	margin: 0 0 6px 0;
	font-size: 16px;
	font-weight: 700;
	color: #1e293b;
}

.affistyle-pro-teaser-desc {
	margin: 0 0 12px 0;
	font-size: 13px;
	color: #64748b;
	line-height: 1.5;
}

.affistyle-pro-teaser-features {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
}

.affistyle-pro-feature-chip {
	display: inline-flex;
	align-items: center;
	padding: 4px 10px;
	background: #ffffff;
	border: 1px solid #cbd5e1;
	border-radius: 20px;
	font-size: 12px;
	font-weight: 600;
	color: #334155;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.affistyle-pro-upgrade-btn {
	background: #2563eb;
	border-color: #1d4ed8;
	font-weight: 600;
	padding: 6px 16px;
	height: auto;
	font-size: 13px;
}


/**
 * 7.0 Admin List Table Shortcode & Quick Preview Modal
 */
.affistyle-shortcode-pill-wrap {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
}

.affistyle-shortcode-pill {
	display: inline-block;
	padding: 3px 8px;
	border: 1px solid #cbd5e1;
	border-radius: 4px;
	background: #f8fafc;
	color: #1e293b;
	font-size: 12px;
	font-family: Consolas, Monaco, monospace;
	cursor: pointer;
	transition: background 0.15s ease, border-color 0.15s ease;
}

.affistyle-shortcode-pill:hover {
	border-color: #2271b1;
	background: #eff6ff;
	color: #1e40af;
}

.affistyle-copy-shortcode-btn.affistyle-copied,
.affistyle-copy-shortcode-btn:focus {
	border-color: #10b981;
	color: #10b981;
}

.affistyle-modal-backdrop {
	display: flex;
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 100000;
	align-items: center;
	justify-content: center;
	padding: 24px;
	background: rgba(15, 23, 42, 0.75);
}

.affistyle-modal-box {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	width: 100%;
	max-width: 1040px;
	max-height: 90vh;
	border-radius: 14px;
	background: #fff;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.affistyle-modal-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 20px;
	border-bottom: 1px solid #e2e8f0;
	background: #f8fafc;
}

.affistyle-modal-header-info {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
}

.affistyle-modal-title {
	margin: 0;
	color: #0f172a;
	font-size: 15px;
	font-weight: 700;
}

.affistyle-modal-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 9999px;
	background: #e0e7ff;
	color: #3730a3;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
}

.affistyle-viewport-switcher {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 3px;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	background: #f1f5f9;
}

.affistyle-vp-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	height: 30px;
	padding: 0 10px;
	border: 0;
	border-radius: 6px;
	background: transparent;
	color: #64748b;
	font-size: 12px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.15s ease;
}

.affistyle-vp-btn:hover {
	background: #e2e8f0;
	color: #0f172a;
}

.affistyle-vp-btn.active {
	border-color: #cbd5e1;
	background: #fff;
	color: #2271b1;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.affistyle-modal-close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: 6px;
	background: transparent;
	color: #64748b;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.affistyle-modal-close:hover {
	background: #fee2e2;
	color: #dc2626;
}

.affistyle-modal-body {
	display: flex;
	overflow-y: auto;
	flex: 1;
	align-items: flex-start;
	justify-content: center;
	padding: 24px;
	background: #f1f5f9;
}

.affistyle-modal-loading {
	padding: 40px;
	color: #64748b;
	text-align: center;
}

.affistyle-viewport-canvas {
	width: 100%;
	margin: 0 auto;
	transition: max-width 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.affistyle-viewport-canvas.viewport-desktop {
	max-width: 960px;
}

.affistyle-viewport-canvas.viewport-tablet {
	max-width: 768px;
}

.affistyle-viewport-canvas.viewport-mobile {
	max-width: 375px;
}

/* Responsive Viewport Simulation for Mobile Preview */
.affistyle-viewport-canvas.viewport-mobile [class*="affistyle-style-"],
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-wrapper,
.affistyle-viewport-canvas.viewport-mobile .affistyle-widget {
	box-sizing: border-box !important;
	max-width: 100% !important;
	width: 100% !important;
	margin: 12px auto !important;
	padding: 16px !important;
	border-radius: 18px !important;
}

/* Style 1: Modern Horizontal Grid */
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-wrapper .affistyle-card-style-1-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-box-container .affistyle-card-style-1-grid {
	grid-template-columns: 1fr !important;
	gap: 16px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-card-image-box,
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1 .affistyle-card-image-box {
	width: 100% !important;
	min-height: 180px !important;
	padding: 14px !important;
	box-sizing: border-box !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-card-image-box img,
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1 .affistyle-card-image-box img {
	max-height: 160px !important;
	width: auto !important;
	margin: 0 auto !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-card-title,
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1 .affistyle-card-title {
	font-size: 19px !important;
	line-height: 1.35 !important;
	text-align: left !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-pros-cons-wrapper,
.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-pros-cons,
.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-pros-cons,
.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-pros-cons,
.affistyle-viewport-canvas.viewport-mobile .affistyle-v-criteria-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-v-pros-cons {
	grid-template-columns: 1fr !important;
	gap: 12px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1-footer,
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-wrapper .affistyle-card-style-1-footer {
	flex-direction: column !important;
	align-items: stretch !important;
	gap: 12px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1-btn-wrap {
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-card-sponsored,
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-style-1 .affistyle-card-sponsored {
	text-align: center !important;
}

/* Style 3: Editorial Hero Review */
.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-layout {
	flex-direction: column !important;
	align-items: center !important;
	gap: 18px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-media {
	flex: 0 0 auto !important;
	width: 100% !important;
	max-width: 240px !important;
	min-height: 180px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-media img {
	max-height: 160px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-content {
	flex: 1 1 100% !important;
	min-width: 0 !important;
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-action-bar {
	flex-direction: column !important;
	align-items: stretch !important;
	gap: 12px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-cta-wrap,
.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-btn {
	width: 100% !important;
}

/* Style 4: Dark Spotlight Pro */
.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-layout {
	flex-direction: column !important;
	align-items: center !important;
	gap: 18px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-media {
	flex: 0 0 auto !important;
	width: 100% !important;
	max-width: 240px !important;
	height: 200px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-media img {
	max-height: 160px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-content {
	flex: 1 1 100% !important;
	min-width: 0 !important;
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-title {
	font-size: 20px !important;
	line-height: 1.3 !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-footer {
	flex-direction: column !important;
	align-items: stretch !important;
	gap: 14px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-cta-wrap,
.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-btn {
	width: 100% !important;
}

/* Style 5: Hero Glass Overlay */
.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-media-wrapper {
	flex-direction: column !important;
	min-height: auto !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-bg-img {
	position: relative !important;
	width: 100% !important;
	height: 200px !important;
	border-radius: 16px 16px 0 0 !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-gradient-shade {
	display: none !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-panel {
	position: relative !important;
	bottom: auto !important;
	left: auto !important;
	right: auto !important;
	width: calc(100% - 20px) !important;
	margin: -20px 10px 10px 10px !important;
	padding: 16px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-header-row {
	flex-direction: column !important;
	align-items: stretch !important;
	gap: 12px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-actions,
.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-btn {
	width: 100% !important;
}

/* Style 6: Verdict Score Card */
.affistyle-viewport-canvas.viewport-mobile .affistyle-style-6 .affistyle-v-wrap {
	flex-direction: column !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-style-6 .affistyle-v-badge {
	min-width: auto !important;
	width: calc(100% - 24px) !important;
	margin: 12px 12px 0 12px !important;
	padding: 18px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-style-6 .affistyle-v-body {
	width: 100% !important;
	padding: 16px 12px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-style-6 .affistyle-v-footer {
	flex-direction: column !important;
	align-items: stretch !important;
	gap: 12px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-style-6 .affistyle-v-cta-wrap,
.affistyle-viewport-canvas.viewport-mobile .affistyle-style-6 .affistyle-v-btn {
	width: 100% !important;
}

/* Style 7: Multi-Retailer Price List */
.affistyle-viewport-canvas.viewport-mobile .affistyle-s7-header {
	padding: 16px !important;
	flex-direction: column !important;
	align-items: center !important;
	text-align: center !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-s7-meta {
	min-width: 0 !important;
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-s7-row {
	flex-direction: column !important;
	align-items: stretch !important;
	padding: 14px 16px !important;
	gap: 10px !important;
	text-align: center !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-s7-row-left,
.affistyle-viewport-canvas.viewport-mobile .affistyle-s7-row-right {
	justify-content: space-between !important;
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-s7-btn {
	width: 100% !important;
}

/* Style 8: Horizontal Review Card */
.affistyle-viewport-canvas.viewport-mobile .affistyle-style-8 .affistyle-v-top {
	flex-direction: column !important;
	align-items: center !important;
	text-align: center !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-style-8 .affistyle-v-meta {
	min-width: 0 !important;
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-style-8 .affistyle-v-grid {
	grid-template-columns: 1fr !important;
	gap: 12px !important;
}

/* Style 9, 10, 11, 12, 13: Compact, Deals, Showcase, Ranked */
.affistyle-viewport-canvas.viewport-mobile .affistyle-split-pricing-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-compact-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-deals-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-showcase-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-ranked-grid {
	display: flex !important;
	flex-direction: column !important;
	grid-template-columns: 1fr !important;
	width: 100% !important;
	gap: 16px !important;
}

/* Style 14 & 16: Versus Side-by-Side Dual Grids */
.affistyle-viewport-canvas.viewport-mobile .affistyle-versus-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-cyber-grid,
.affistyle-viewport-canvas.viewport-mobile .affistyle-performance-showcase-16,
.affistyle-viewport-canvas.viewport-mobile [class*="versus-grid"],
.affistyle-viewport-canvas.viewport-mobile [class*="cyber-grid"] {
	grid-template-columns: 1fr !important;
	display: flex !important;
	flex-direction: column !important;
	gap: 16px !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-versus-badge,
.affistyle-viewport-canvas.viewport-mobile .affistyle-cyber-badge {
	margin: 10px auto !important;
}

/* Style 15: Spec Comparison Table */
.affistyle-viewport-canvas.viewport-mobile .affistyle-list-15,
.affistyle-viewport-canvas.viewport-mobile .affistyle-spec-table {
	overflow-x: auto !important;
	display: block !important;
	width: 100% !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-list-15-row {
	flex-direction: column !important;
	align-items: stretch !important;
}

/* Universal Button & CTA Sizing for Mobile Preview */
.affistyle-viewport-canvas.viewport-mobile .affistyle-card-button,
.affistyle-viewport-canvas.viewport-mobile .affistyle-btn,
.affistyle-viewport-canvas.viewport-mobile .affistyle-hero-btn,
.affistyle-viewport-canvas.viewport-mobile .affistyle-darkspot-btn,
.affistyle-viewport-canvas.viewport-mobile .affistyle-glass-btn,
.affistyle-viewport-canvas.viewport-mobile .affistyle-v-btn,
.affistyle-viewport-canvas.viewport-mobile .affistyle-retailer-btn,
.affistyle-viewport-canvas.viewport-mobile .affistyle-multi-store-group,
.affistyle-viewport-canvas.viewport-mobile .affistyle-multi-retailers-group {
	display: flex !important;
	justify-content: center !important;
	width: 100% !important;
	min-height: 44px !important;
	box-sizing: border-box !important;
}

.affistyle-viewport-canvas.viewport-mobile .affistyle-secondary-retailer-btn {
	flex: 1 1 calc(50% - 8px) !important;
	min-width: 120px !important;
	justify-content: center !important;
	box-sizing: border-box !important;
}

.affistyle-modal-footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 20px;
	border-top: 1px solid #e2e8f0;
	background: #f8fafc;
}

.affistyle-modal-footer-left {
	display: flex;
	align-items: center;
	gap: 10px;
}


/**
 * 8.0 Animations & Utilities
 */
@keyframes affistyle-spin {
	0% {
		transform: rotate(0deg);
	}
	100% {
		transform: rotate(360deg);
	}
}

.dashicons.spin,
.affistyle-spin {
	display: inline-block;
	animation: affistyle-spin 1s infinite linear;
}


/**
 * 9.0 Responsive Media Queries
 */
@media all and (max-width: 782px) {
	.affistyle-field-row {
		flex-direction: column;
		gap: 0;
	}

	.affistyle-quick-fill-input-row {
		flex-direction: column;
		align-items: stretch;
	}

	.affistyle-quick-fill-input-row .button-primary {
		width: 100%;
	}

	.affistyle-provider-grid {
		grid-template-columns: 1fr;
	}
}