/**
 * Sharebox AI - Admin Styles
 *
 * Styles for the WordPress admin settings page.
 *
 * @package SBAI_Sharebox
 * @since 1.0.0
 */

/* ==========================================================================
   Admin Page Layout
   ========================================================================== */

.sbai-admin {
	max-width: 900px;
}

.sbai-admin h1 {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 1.75rem;
	font-weight: 700;
	margin-bottom: 0.5em;
}

.sbai-logo {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	background: #FF4D00;
	border: 2.5px solid #0D0D0D;
	border-radius: 12px;
	box-shadow: 3px 3px 0 #0D0D0D;
	color: #FFFFFF;
}

.sbai-logo svg {
	width: 24px;
	height: 24px;
	fill: currentColor;
}

.sbai-description {
	font-size: 1.1rem;
	color: #555;
	margin-bottom: 2em;
}

/* ==========================================================================
   Sections
   ========================================================================== */

.sbai-section {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	padding: 24px;
	margin-bottom: 24px;
}

.sbai-section h2 {
	font-size: 1.2rem;
	font-weight: 600;
	margin: 0 0 8px 0;
	padding: 0;
	border: none;
}

.sbai-section > .description {
	color: #666;
	margin: 0 0 20px 0;
}

.sbai-section .form-table {
	margin-top: 0;
}

.sbai-section .form-table th {
	width: 180px;
	padding-top: 16px;
	padding-bottom: 16px;
}

.sbai-section .form-table td {
	padding-top: 12px;
	padding-bottom: 12px;
}

.sbai-section-advanced {
	border-color: #dba617;
	background: #fffbeb;
}

.sbai-section-advanced h2 {
	color: #92400e;
}

/* ==========================================================================
   Platforms Grid
   ========================================================================== */

.sbai-platforms-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	gap: 12px;
}

.sbai-platform-item {
	display: flex;
	align-items: center;
	cursor: pointer;
}

.sbai-platform-item input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
}

.sbai-platform-label {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 14px;
	background: #f6f7f7;
	border: 2px solid #dcdcde;
	border-radius: 8px;
	transition: all 0.15s ease;
	width: 100%;
}

.sbai-platform-item:hover .sbai-platform-label {
	border-color: #2271b1;
	background: #f0f6fc;
}

.sbai-platform-item input:checked + .sbai-platform-label {
	border-color: #2271b1;
	background: #e7f3ff;
}

.sbai-platform-item input:focus + .sbai-platform-label {
	box-shadow: 0 0 0 2px #2271b1;
}

.sbai-platform-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 10px;
	background: #FAF8F5;
	border: 2px solid #0D0D0D;
	box-shadow: 3px 3px 0 #0D0D0D;
	color: #0D0D0D;
	flex-shrink: 0;
}

.sbai-platform-icon svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
}

.sbai-platform-name {
	font-weight: 500;
	font-size: 0.9rem;
	color: #1e1e1e;
}

/* ==========================================================================
   Usage Grid
   ========================================================================== */

.sbai-section-help {
	background: #f0f6fc;
	border-color: #c5d9ed;
}

.sbai-usage-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 20px;
}

.sbai-usage-item {
	background: #fff;
	padding: 20px;
	border-radius: 8px;
	border: 1px solid #c5d9ed;
}

.sbai-usage-item h3 {
	font-size: 0.95rem;
	font-weight: 600;
	margin: 0 0 8px 0;
	color: #1e1e1e;
}

.sbai-usage-item code {
	display: inline-block;
	padding: 6px 10px;
	background: #f6f7f7;
	border-radius: 4px;
	font-size: 0.85rem;
	margin-bottom: 8px;
}

.sbai-usage-item p {
	margin: 0;
	font-size: 0.85rem;
	color: #555;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.sbai-footer {
	margin-top: 32px;
	padding-top: 16px;
	border-top: 1px solid #dcdcde;
	color: #666;
	font-size: 0.9rem;
}

.sbai-footer a {
	color: #2271b1;
	text-decoration: none;
}

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

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 782px) {
	.sbai-platforms-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.sbai-usage-grid {
		grid-template-columns: 1fr;
	}

	.sbai-section .form-table th {
		width: auto;
		display: block;
		padding-bottom: 8px;
	}

	.sbai-section .form-table td {
		display: block;
		padding-top: 0;
	}
}

@media (max-width: 480px) {
	.sbai-platforms-grid {
		grid-template-columns: 1fr;
	}
}
