/**
 * Discover Metric — Settings Page Styles
 *
 * Modern, clean design for the plugin settings.
 *
 * @package Discover_Metric
 * @since   1.0.2
 */

/* Wrap */
.discm-settings-wrap {
	max-width: 740px;
	margin: 20px auto 40px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

/* Header */
.discm-settings-header {
	background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 50%, #4c1d95 100%);
	color: #fff;
	padding: 28px 32px 22px;
	border-radius: 16px 16px 0 0;
}

.discm-settings-logo {
	display: flex;
	align-items: center;
	gap: 14px;
}

.discm-logo-icon {
	font-size: 36px;
	width: 36px;
	height: 36px;
	opacity: 0.95;
}

.discm-settings-logo h2 {
	color: #fff;
	font-size: 22px;
	font-weight: 700;
	margin: 0;
	padding: 0;
	line-height: 1.2;
}

.discm-settings-tagline {
	margin: 2px 0 0;
	opacity: 0.8;
	font-size: 13px;
	font-weight: 400;
}

/* Cards */
.discm-settings-card {
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 0;
	margin-top: -1px;
}

.discm-settings-card:last-of-type {
	border-radius: 0 0 12px 12px;
}

.discm-card-header {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 16px 24px;
	border-bottom: 1px solid #f3f4f6;
}

.discm-card-header .dashicons {
	color: #7c3aed;
	font-size: 18px;
	width: 18px;
	height: 18px;
}

.discm-card-header h3 {
	font-size: 15px;
	font-weight: 600;
	color: #1f2937;
	margin: 0;
	padding: 0;
}

.discm-card-body {
	padding: 20px 24px;
}

/* Field groups */
.discm-field-group {
	margin-bottom: 20px;
}

.discm-field-group:last-child {
	margin-bottom: 0;
}

.discm-field-label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	color: #374151;
	margin-bottom: 8px;
}

.discm-field-help {
	font-size: 12px;
	color: #6b7280;
	margin: 8px 0 0;
	line-height: 1.5;
}

.discm-field-help a {
	color: #7c3aed;
	text-decoration: none;
}

.discm-field-help a:hover {
	text-decoration: underline;
}

/* Input */
.discm-input {
	width: 100%;
	max-width: 380px;
	padding: 8px 12px;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	font-size: 13px;
	font-family: "SF Mono", Monaco, "Cascadia Code", monospace;
	color: #1f2937;
	background: #fff;
	transition: border-color 0.2s, box-shadow 0.2s;
	box-sizing: border-box;
}

.discm-input:focus {
	border-color: #7c3aed;
	box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
	outline: none;
}

/* API key wrapper */
.discm-api-key-wrapper {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}

/* Buttons */
.discm-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 8px 16px;
	border-radius: 8px;
	font-size: 13px;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s;
	border: 1px solid transparent;
	text-decoration: none;
	line-height: 1.4;
}

.discm-btn-secondary {
	background: #f3f4f6;
	color: #374151;
	border-color: #d1d5db;
}

.discm-btn-secondary:hover {
	background: #e5e7eb;
	border-color: #9ca3af;
}

.discm-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 8px;
	border: 1px solid #d1d5db;
	background: #f9fafb;
	cursor: pointer;
	transition: all 0.2s;
	padding: 0;
}

.discm-icon-btn:hover {
	background: #e5e7eb;
}

.discm-icon-btn .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
	color: #6b7280;
}

/* Key validation status */
.discm-key-status {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	padding: 6px 12px;
	border-radius: 8px;
	margin-top: 8px;
	transition: all 0.3s;
}

.discm-key-status.discm-status-success {
	background: #ecfdf5;
	color: #065f46;
	border: 1px solid #a7f3d0;
}

.discm-key-status.discm-status-error {
	background: #fef2f2;
	color: #991b1b;
	border: 1px solid #fecaca;
}

.discm-key-status.discm-status-loading {
	background: #f3f4f6;
	color: #6b7280;
	border: 1px solid #e5e7eb;
}

/* Checkboxes */
.discm-checkbox-group {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.discm-checkbox-label {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	border: 1px solid #e5e7eb;
	border-radius: 8px;
	font-size: 13px;
	color: #374151;
	cursor: pointer;
	transition: all 0.2s;
	background: #fff;
}

.discm-checkbox-label:hover {
	border-color: #c4b5fd;
	background: #faf5ff;
}

.discm-checkbox-label input:checked + .discm-checkbox-text {
	color: #7c3aed;
	font-weight: 600;
}

/* Toggle label */
.discm-toggle-label {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	font-size: 13px;
	color: #374151;
	cursor: pointer;
}

.discm-toggle-text {
	line-height: 1.5;
}

/* Submit */
.discm-settings-submit {
	padding: 20px 0;
	text-align: left;
}

.discm-settings-submit .button-primary,
.discm-btn-save {
	background: #7c3aed;
	border-color: #6d28d9;
	border-radius: 10px;
	padding: 8px 28px;
	font-size: 14px;
	font-weight: 600;
	color: #fff;
	transition: all 0.2s;
	line-height: 1.5;
}

.discm-settings-submit .button-primary:hover,
.discm-btn-save:hover {
	background: #6d28d9;
	border-color: #5b21b6;
}

.discm-settings-submit .button-primary:focus,
.discm-btn-save:focus {
	box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.25);
}

/* Account links */
.discm-account-links {
	margin-top: 12px;
	padding: 14px 16px;
	background: linear-gradient(135deg, #faf5ff 0%, #ede9fe 100%);
	border-radius: 10px;
	border: 1px solid #ddd6fe;
}

.discm-free-credits-notice {
	margin: 0 0 8px;
	font-size: 13px;
	font-weight: 600;
	color: #6d28d9;
	display: flex;
	align-items: center;
	gap: 6px;
}

.discm-free-credits-notice .dashicons {
	color: #f59e0b;
	font-size: 16px;
	width: 16px;
	height: 16px;
}

.discm-account-actions {
	margin: 0;
	font-size: 12.5px;
	color: #4b5563;
	line-height: 1.6;
}

.discm-link-register {
	color: #7c3aed;
	font-weight: 600;
	text-decoration: none;
}

.discm-link-register:hover {
	text-decoration: underline;
	color: #6d28d9;
}

.discm-link-dashboard {
	color: #7c3aed;
	text-decoration: none;
}

.discm-link-dashboard:hover {
	text-decoration: underline;
	color: #6d28d9;
}

/* Footer */
.discm-settings-footer {
	margin-top: 16px;
	padding: 12px 0;
	text-align: center;
	color: #9ca3af;
	font-size: 12px;
}

.discm-settings-footer a {
	color: #7c3aed;
	text-decoration: none;
}

.discm-settings-footer a:hover {
	text-decoration: underline;
}

/* How-to Video */
.discm-howto-video {
	margin-top: 16px;
}

.discm-howto-video h4 {
	font-size: 14px;
	font-weight: 600;
	margin-bottom: 8px;
}

.discm-howto-video-wrapper {
	position: relative;
	padding-bottom: 56.25%;
	height: 0;
	overflow: hidden;
	max-width: 100%;
	border-radius: 8px;
}

.discm-howto-video-wrapper iframe {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border: 0;
	border-radius: 8px;
}

/* Breaking News Banner */
.discm-breaking-news-banner {
	position: relative;
	overflow: hidden;
	background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
	border-radius: 12px;
	padding: 28px 32px;
	margin-bottom: 24px;
}

.discm-banner-glow {
	position: absolute;
	top: -40px;
	right: -40px;
	width: 180px;
	height: 180px;
	background: radial-gradient(circle, rgba(139, 92, 246, 0.35) 0%, transparent 70%);
	pointer-events: none;
}

.discm-banner-body {
	position: relative;
	z-index: 1;
}

.discm-banner-badge {
	display: inline-block;
	background: rgba(139, 92, 246, 0.2);
	border: 1px solid rgba(139, 92, 246, 0.4);
	color: #a78bfa;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1.5px;
	padding: 4px 12px;
	border-radius: 20px;
	margin-bottom: 12px;
}

.discm-banner-title {
	margin: 0 0 10px 0;
	font-size: 20px;
	font-weight: 800;
	color: #ffffff;
	line-height: 1.3;
}

.discm-banner-text {
	margin: 0 0 18px 0;
	font-size: 14px;
	line-height: 1.6;
	color: #cbd5e1;
	max-width: 680px;
}

.discm-banner-cta {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%);
	color: #ffffff;
	font-weight: 700;
	font-size: 14px;
	padding: 12px 28px;
	border-radius: 8px;
	text-decoration: none;
	transition: transform 0.2s, box-shadow 0.2s;
	box-shadow: 0 4px 14px rgba(139, 92, 246, 0.3);
}

.discm-banner-cta:hover {
	transform: translateY(-1px);
	box-shadow: 0 6px 20px rgba(139, 92, 246, 0.45);
	color: #ffffff;
}

.discm-banner-cta-arrow {
	font-size: 16px;
	transition: transform 0.2s;
}

.discm-banner-cta:hover .discm-banner-cta-arrow {
	transform: translateX(3px);
}

@media (max-width: 782px) {
	.discm-breaking-news-banner {
		padding: 20px;
	}

	.discm-banner-title {
		font-size: 17px;
	}

	.discm-banner-text {
		font-size: 13px;
	}
}
