/* Стили генераторов, примеров, FAQ и перелинковки.
   Перенесены из style.css дочерней темы и дополнены новой разметкой (поля, примеры, реклама). */

:root {
	--ozg-accent: #0d6efd;
	--ozg-accent-dark: #0b5ed7;
	--ozg-border: #dee2e6;
	--ozg-surface: #f8f9fa;
	--ozg-muted: #555;
}

/* --- контейнер и форма --- */

.ozarilo-generator-container {
	background-color: var(--ozg-surface);
	border: 1px solid var(--ozg-border);
	border-radius: 5px;
	padding: 20px;
	margin-bottom: 25px;
}

.ozarilo-generator-container h4,
.ozg-title {
	margin-top: 0;
	margin-bottom: 15px;
	border-bottom: 1px solid var(--ozg-border);
	padding-bottom: 5px;
	font-weight: 700;
}

.ozg-controls {
	display: flex;
	flex-wrap: wrap;
	gap: 15px 25px;
	margin-bottom: 15px;
}

.ozg-field {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 1 1 180px;
}

/* Правило с display выше атрибута hidden по специфичности — возвращаем скрытие. */
.ozg-field[hidden],
.ozg [hidden] {
	display: none !important;
}

.ozarilo-generator-container label {
	margin-right: 10px;
	font-weight: 700;
}

.ozarilo-generator-container select,
.ozarilo-generator-container input[type="number"] {
	padding: 6px;
	border-radius: 4px;
	border: 1px solid #ced4da;
	background: #fff;
	max-width: 100%;
}

.ozarilo-checkbox-group,
.ozg-checkbox-group {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.ozg-checkbox,
.ozarilo-checkbox-group label {
	cursor: pointer;
	font-weight: 400;
	display: inline-flex;
	align-items: center;
	gap: 5px;
}

/* --- кнопки --- */

.ozarilo-button,
.ozarilo-button-copy {
	background-color: var(--ozg-accent);
	color: #fff;
	border: none;
	padding: 10px 15px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 1em;
	transition: background-color 0.2s ease;
}

.ozarilo-button:hover,
.ozarilo-button-copy:hover {
	background-color: var(--ozg-accent-dark);
}

.ozarilo-button-copy {
	background-color: #6c757d;
	margin-top: 10px;
}

.ozarilo-button-copy:hover {
	background-color: #5a6268;
}

.ozg-actions {
	display: flex;
	align-items: center;
	gap: 12px;
}

.ozg-feedback {
	color: #198754;
	font-size: 0.9em;
}

/* --- результат --- */

.ozarilo-output-box {
	background-color: #fff;
	border: 1px solid #ced4da;
	border-radius: 4px;
	padding: 10px 15px;
	font-size: 1.1em;
	font-weight: 700;
	margin-top: 10px;
	color: #333;
}

.ozarilo-output-box p {
	margin: 0 0 0.6em;
	font-weight: 400;
}

.ozarilo-output-box p:last-child {
	margin-bottom: 0;
}

.ozg-result-list {
	margin: 0;
	padding-left: 1.2em;
}

.ozg-result-list li {
	margin-bottom: 2px;
}

.ozg-idea-list {
	margin: 0;
	padding-left: 1.2em;
}

.ozg-idea-list li {
	margin-bottom: 10px;
}

.ozg-idea {
	display: block;
	font-weight: 700;
}

/* Подсказка по технике — то, чем страница полезнее списка идей у конкурентов. */
.ozg-idea-hint {
	display: block;
	font-weight: 400;
	font-size: 0.88em;
	color: var(--ozg-muted);
	line-height: 1.4;
	margin-top: 2px;
}

.ozg-examples--sketch .ozg-example-list {
	columns: 1;
}

.ozg-empty {
	font-weight: 400;
	color: var(--ozg-muted);
}

.ozg-preset-note {
	margin: 10px 0 0;
	font-size: 0.9em;
	color: var(--ozg-muted);
}

/* --- палитра --- */

.ozarilo-output-box .ozg-swatch,
.ozg-example-palette .ozg-swatch {
	display: inline-flex;
	align-items: flex-end;
	justify-content: center;
	min-width: 90px;
	flex: 1 1 90px;
	height: 80px;
	padding-bottom: 5px;
	font-size: 0.85em;
	font-weight: 700;
	cursor: pointer;
	transition: transform 0.1s ease;
}

.ozg-swatch:active {
	transform: scale(0.98);
}

.ozarilo-output-box:has(.ozg-swatch),
.ozg-example-palette {
	display: flex;
	flex-wrap: wrap;
	padding: 0;
	overflow: hidden;
	border-radius: 4px;
}

.ozarilo-hex-codes {
	margin-top: 10px;
	font-size: 0.9em;
	color: var(--ozg-muted);
	word-break: break-word;
}

/* --- примеры --- */

.ozg-examples {
	margin: 15px 0 25px;
}

.ozg-example-list {
	columns: var(--ozg-cols, 2);
	column-gap: 30px;
	margin: 0;
	padding-left: 1.2em;
}

.ozg-example-list li {
	break-inside: avoid;
	margin-bottom: 4px;
}

.ozg-examples--palette .ozg-example-palette {
	margin-bottom: 10px;
}

/* --- FAQ --- */

.ozg-faq {
	margin: 25px 0;
}

.ozg-faq__item {
	border: 1px solid var(--ozg-border);
	border-radius: 5px;
	padding: 12px 15px;
	margin-bottom: 10px;
	background: #fff;
}

.ozg-faq__item summary {
	cursor: pointer;
	font-weight: 700;
}

.ozg-faq__answer {
	margin-top: 8px;
}

.ozg-faq__answer p:last-child {
	margin-bottom: 0;
}

/* --- перелинковка --- */

.ozarilo-cross-promo {
	margin-top: 40px;
	border-top: 1px solid #e0e0e0;
	padding-top: 20px;
}

.cross-promo-title,
.ozg-related__title {
	font-size: 1.5em;
	margin-bottom: 25px;
}

.cross-promo-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 20px;
	margin-bottom: 30px;
}

.cross-promo-card {
	display: block;
	padding: 20px;
	border: 1px solid var(--ozg-border);
	border-radius: 5px;
	text-decoration: none;
	color: #333;
	transition: all 0.2s ease-in-out;
	background-color: #fff;
}

.cross-promo-card:hover,
.cross-promo-card:focus {
	transform: translateY(-3px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
	border-color: var(--ozg-accent);
}

.cross-promo-card .card-title,
.cross-promo-card__title {
	display: block;
	font-weight: 700;
	font-size: 1.1em;
	color: var(--ozg-accent);
	margin-bottom: 5px;
}

.cross-promo-card .card-description,
.cross-promo-card__text {
	display: block;
	font-size: 0.9em;
	color: var(--ozg-muted);
	line-height: 1.4;
}

.ozarilo-article-promo {
	margin-top: 20px;
	padding: 20px;
	background-color: var(--ozg-surface);
	border: 1px solid var(--ozg-border);
	border-radius: 5px;
	text-align: center;
}

.ozarilo-article-promo p {
	margin-top: 0;
	margin-bottom: 10px;
}

.ozarilo-article-promo a {
	font-weight: 700;
}

/* --- хаб --- */

.ozg-hub__group {
	margin-bottom: 30px;
}

.ozg-hub__title {
	margin-bottom: 6px;
}

.ozg-hub__lead {
	color: var(--ozg-muted);
	margin-bottom: 8px;
}

.ozg-hub__list {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 16px;
	list-style: none;
	margin: 0;
	padding: 0;
}

/* --- реклама: высота резервируется, чтобы баннер не сдвигал текст --- */

.ozg-ad {
	margin: 20px 0 5px;
	display: flow-root;
}

#yandex_rtb_R-A-16309019-1 {
	min-height: 250px;
}

/* --- мобильные --- */

@media (max-width: 768px) {
	.cross-promo-grid {
		grid-template-columns: 1fr;
	}

	.ozg-example-list {
		columns: 1;
	}

	.ozg-controls {
		gap: 12px;
	}

	.ozg-field {
		flex: 1 1 100%;
	}
}
