/**
 * Sinemax yönetim paneli stilleri.
 */

.sinemax-admin {
	--sxa-accent: #ff3d57;
	--sxa-accent-2: #7c5cff;
	--sxa-radius: 10px;
}

.sinemax-admin__title {
	display: flex;
	align-items: center;
	gap: .5rem;
}

.sinemax-admin__logo {
	color: var(--sxa-accent);
	font-size: 1.3em;
	line-height: 1;
	text-shadow: 0 0 14px rgba(255, 61, 87, .5);
}

/* ------------------------------------------------------------ Meta kutuları */

.sinemax-grid-fields {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
	gap: 1rem;
	padding: .4rem 0;
}

.sinemax-field label {
	display: block;
	font-weight: 600;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: .04em;
	color: #50575e;
	margin-bottom: .3rem;
}

.sinemax-field input[type="text"],
.sinemax-field input[type="url"],
.sinemax-field input[type="number"],
.sinemax-field input[type="date"],
.sinemax-field select {
	width: 100%;
	max-width: 100%;
}

.sinemax-field--checkbox label:first-child {
	margin-bottom: .5rem;
}

.sinemax-toggle {
	display: inline-flex !important;
	align-items: center;
}

.sinemax-image-picker .sinemax-image-preview {
	margin-bottom: .5rem;
	min-height: 10px;
}

.sinemax-image-picker img {
	max-width: 100%;
	height: auto;
	border-radius: 6px;
	display: block;
	border: 1px solid #dcdcde;
}

.sinemax-subhead {
	margin: 1.6rem 0 .5rem;
	padding-top: 1rem;
	border-top: 1px solid #e0e0e2;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: #50575e;
}

/* ---------------------------------------------------------------- Repeater */

.sinemax-repeater-toolbar {
	display: flex;
	align-items: center;
	gap: .5rem;
	margin-bottom: .7rem;
	flex-wrap: wrap;
}

.sinemax-repeater {
	border-radius: var(--sxa-radius);
	overflow: hidden;
}

.sinemax-repeater th {
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: .05em;
}

.sinemax-repeater td {
	vertical-align: middle;
	padding: 6px 8px;
}

.sinemax-repeater input[type="text"],
.sinemax-repeater input[type="url"],
.sinemax-repeater textarea,
.sinemax-repeater select {
	width: 100%;
	min-width: 70px;
	font-size: 13px;
}

.sinemax-repeater textarea.sinemax-url {
	min-height: 30px;
	resize: vertical;
	font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
	font-size: 12px;
	line-height: 1.5;
}

.sinemax-repeater .sinemax-narrow {
	min-width: 60px;
	max-width: 90px;
}

.sinemax-repeater .sinemax-center {
	text-align: center;
}

.sinemax-col-handle {
	width: 34px;
	text-align: center;
}

.sinemax-drag {
	cursor: grab;
	color: #a7aaad;
}

.sinemax-drag:active {
	cursor: grabbing;
}

.sinemax-sort-placeholder {
	height: 44px;
	background: #f0f6fc;
	outline: 2px dashed #2271b1;
}

.sinemax-remove-row {
	color: #b32d2e !important;
	text-decoration: none !important;
	font-size: 14px;
	padding: 4px;
}

.sinemax-remove-row:hover {
	color: #fff !important;
	background: #b32d2e;
	border-radius: 4px;
}

.sinemax-repeater--templates input {
	font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
	font-size: 12px;
}

.sinemax-desc-block {
	background: #f6f7f7;
	border-left: 4px solid var(--sxa-accent-2);
	padding: .7rem .9rem;
	margin: 0 0 1rem;
	border-radius: 0 6px 6px 0;
}

/* ------------------------------------------------------------------- TMDB */

.sinemax-tmdb-list {
	list-style: none;
	margin: .5rem 0 0;
	padding: 0;
	max-height: 340px;
	overflow-y: auto;
	display: grid;
	gap: 4px;
}

.sinemax-tmdb-pick {
	display: flex;
	gap: .55rem;
	align-items: center;
	width: 100%;
	text-align: left;
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 8px;
	padding: 5px;
	cursor: pointer;
	transition: border-color .15s ease, box-shadow .15s ease;
}

.sinemax-tmdb-pick:hover {
	border-color: var(--sxa-accent);
	box-shadow: 0 2px 10px -4px rgba(255, 61, 87, .5);
}

.sinemax-tmdb-pick img,
.sinemax-tmdb-noimg {
	width: 36px;
	aspect-ratio: 2 / 3;
	object-fit: cover;
	border-radius: 4px;
	background: #f0f0f1;
	flex: 0 0 auto;
}

.sinemax-tmdb-body {
	display: grid;
	gap: 1px;
	min-width: 0;
}

.sinemax-tmdb-body strong {
	font-size: 12.5px;
	line-height: 1.3;
}

.sinemax-tmdb-body em {
	font-style: normal;
	font-size: 11px;
	color: #646970;
}

/* -------------------------------------------------------------- İstatistik */

.sinemax-stat-list {
	margin: 0;
	list-style: none;
	display: grid;
	gap: .35rem;
	font-size: 13px;
}

.sinemax-stat-list strong {
	font-size: 15px;
	color: #1d2327;
}

.sinemax-stat-cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 1rem;
	margin: 1.25rem 0;
}

.sinemax-stat-card {
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 12px;
	padding: 1rem 1.1rem;
	display: grid;
	gap: .2rem;
	box-shadow: 0 1px 2px rgba(0, 0, 0, .04);
	position: relative;
	overflow: hidden;
}

.sinemax-stat-card::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 3px;
	background: linear-gradient(90deg, var(--sxa-accent), var(--sxa-accent-2));
	opacity: .25;
}

.sinemax-stat-card--accent::before,
.sinemax-stat-card--alert::before {
	opacity: 1;
}

.sinemax-stat-card--alert::before {
	background: linear-gradient(90deg, #d63638, #f0a92b);
}

.sinemax-stat-card__label {
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: .07em;
	color: #646970;
	font-weight: 700;
}

.sinemax-stat-card__value {
	font-size: 1.9rem;
	line-height: 1.1;
	font-weight: 800;
	color: #1d2327;
}

.sinemax-stat-card a,
.sinemax-stat-card span:last-child {
	font-size: 12px;
	text-decoration: none;
}

/* ------------------------------------------------------------------ Panel */

.sinemax-admin__grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
	gap: 1.1rem;
	align-items: start;
}

.sinemax-admin__grid--import {
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.sinemax-panel {
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 12px;
	padding: 1.1rem 1.25rem;
	box-shadow: 0 1px 2px rgba(0, 0, 0, .04);
}

.sinemax-panel--wide {
	grid-column: 1 / -1;
	margin-top: 1.1rem;
}

.sinemax-panel h2 {
	margin: 0 0 .8rem;
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: #50575e;
}

.sinemax-panel h3 {
	margin: 1.2rem 0 .5rem;
	font-size: 13px;
}

.sinemax-quick {
	display: flex;
	flex-wrap: wrap;
	gap: .4rem;
}

.sinemax-shortcode-list {
	margin: 0;
	font-size: 12.5px;
	color: #50575e;
	list-style: none;
	display: grid;
	gap: .35rem;
}

.sinemax-shortcode-list code {
	font-size: 11.5px;
	background: #f0f0f1;
}

.sinemax-mini-list {
	margin: 0;
	padding: 0;
	list-style: none;
	display: grid;
	gap: 1px;
}

.sinemax-mini-list li {
	display: flex;
	justify-content: space-between;
	gap: .5rem;
	padding: .42rem .1rem;
	border-bottom: 1px solid #f0f0f1;
	font-size: 13px;
}

.sinemax-mini-list li span {
	color: #646970;
	font-size: 12px;
	white-space: nowrap;
}

.sinemax-mini-list--ranked {
	counter-reset: sxrank;
}

.sinemax-mini-list--ranked li::before {
	counter-increment: sxrank;
	content: counter(sxrank) ".";
	color: var(--sxa-accent);
	font-weight: 700;
	margin-right: .4rem;
}

/* ------------------------------------------------------------------ Grafik */

.sinemax-chart {
	display: flex;
	align-items: flex-end;
	gap: 2px;
	height: 120px;
	padding: .5rem 0;
}

.sinemax-chart__bar {
	flex: 1;
	height: var(--h, 4%);
	min-height: 2px;
	border-radius: 3px 3px 0 0;
	background: linear-gradient(180deg, var(--sxa-accent), var(--sxa-accent-2));
	opacity: .8;
	transition: opacity .15s ease, transform .15s ease;
}

.sinemax-chart__bar:hover {
	opacity: 1;
	transform: scaleY(1.04);
}

/* ------------------------------------------------------------------ Kuyruk */

.sinemax-progress-bar {
	height: 10px;
	border-radius: 99px;
	background: #f0f0f1;
	overflow: hidden;
	margin-bottom: .7rem;
}

.sinemax-progress-bar span {
	display: block;
	height: 100%;
	background: linear-gradient(90deg, var(--sxa-accent), var(--sxa-accent-2));
	transition: width .3s ease;
}

.sinemax-queue__status {
	font-weight: 600;
}

.sinemax-queue__log {
	margin: 1rem 0 0;
	padding: .6rem .8rem;
	list-style: none;
	max-height: 280px;
	overflow-y: auto;
	background: #f6f7f7;
	border-radius: 8px;
	font-size: 12.5px;
	display: grid;
	gap: .25rem;
}

.sinemax-import-form label {
	font-weight: 600;
	font-size: 13px;
}

.sinemax-import-form select,
.sinemax-import-form textarea {
	max-width: 100%;
}

/* ------------------------------------------------------------------ Sezon */

.sinemax-seasons__toolbar {
	display: flex;
	align-items: center;
	gap: .7rem;
	flex-wrap: wrap;
	padding: .7rem;
	background: #f6f7f7;
	border-radius: 8px;
	margin-bottom: 1rem;
}

.sinemax-seasons__toolbar label {
	font-size: 12px;
	font-weight: 600;
}

.sinemax-season {
	margin-bottom: .7rem;
	border: 1px solid #dcdcde;
	border-radius: 8px;
	overflow: hidden;
}

.sinemax-season > summary {
	cursor: pointer;
	padding: .6rem .8rem;
	background: #f6f7f7;
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 13px;
}

.sinemax-season > summary span {
	color: #646970;
	font-size: 12px;
}

.sinemax-season table {
	border: 0;
}

/* ------------------------------------------------------------------ Etiket */

.sinemax-pill {
	display: inline-block;
	padding: 1px 7px;
	border-radius: 99px;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.7;
}

.sinemax-pill--ok {
	background: #edfaef;
	color: #1a7f37;
	border: 1px solid #9fe0ae;
}

.sinemax-pill--warn {
	background: #fcf3e6;
	color: #9a6700;
	border: 1px solid #f0c78a;
}

.sinemax-pill--alert {
	background: #fcebeb;
	color: #b32d2e;
	border: 1px solid #f0a9a9;
}

.sinemax-pill--muted {
	background: #f0f0f1;
	color: #646970;
	border: 1px solid #dcdcde;
}

.sinemax-ok { color: #1a7f37; font-weight: 600; }
.sinemax-error { color: #b32d2e; font-weight: 600; }
.sinemax-muted { color: #646970; }

.sinemax-check {
	display: inline-flex;
	align-items: flex-start;
	gap: .4rem;
	line-height: 1.5;
}

.sinemax-tabs {
	margin-bottom: 1.2rem;
}

.sinemax-reports td {
	vertical-align: middle;
}

.sinemax-fetch-status {
	font-size: 12.5px;
}

.sinemax-empty {
	color: #646970;
	font-style: italic;
}

@media (max-width: 782px) {
	.sinemax-repeater,
	.sinemax-repeater thead,
	.sinemax-repeater tbody,
	.sinemax-repeater tr,
	.sinemax-repeater td { display: block; width: 100%; }
	.sinemax-repeater thead { display: none; }
	.sinemax-repeater-row {
		border: 1px solid #dcdcde;
		border-radius: 8px;
		margin-bottom: .6rem;
		padding: .4rem;
	}
	.sinemax-repeater .sinemax-narrow { max-width: 100%; }
}

.sinemax-settings-sub {
	margin: 1.6rem 0 .2rem;
	padding-top: 1.1rem;
	border-top: 2px solid #dcdcde;
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--sxa-accent-2);
}

.sinemax-person-status { margin-left: .5rem; font-size: 12.5px; }

/* ------------------------------------------------------- Liste kurucusu */

.sinemax-listbuilder__search {
	position: relative;
	margin-bottom: .6rem;
}

.sinemax-listbuilder__results {
	position: absolute;
	top: calc(100% + 4px);
	left: 0;
	right: 0;
	z-index: 20;
	max-height: 320px;
	overflow-y: auto;
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 8px;
	box-shadow: 0 12px 30px -14px rgba(0, 0, 0, .35);
	padding: 4px;
	display: grid;
	gap: 2px;
}

.sinemax-listbuilder__result {
	display: flex;
	align-items: center;
	gap: 8px;
	width: 100%;
	text-align: left;
	background: #fff;
	border: 1px solid transparent;
	border-radius: 6px;
	padding: 4px;
	cursor: pointer;
}

.sinemax-listbuilder__result:hover {
	border-color: var(--sxa-accent);
	background: #fdf6f7;
}

.sinemax-listbuilder__result img,
.sinemax-listbuilder__item img {
	width: 32px;
	aspect-ratio: 2 / 3;
	object-fit: cover;
	border-radius: 4px;
	flex: 0 0 auto;
	background: #f0f0f1;
}

.sinemax-listbuilder__result span,
.sinemax-listbuilder__title {
	display: grid;
	gap: 1px;
	min-width: 0;
	font-size: 12.5px;
	font-weight: 600;
}

.sinemax-listbuilder__result em,
.sinemax-listbuilder__title em {
	font-style: normal;
	font-size: 11px;
	font-weight: 400;
	color: #646970;
}

.sinemax-listbuilder__items {
	list-style: none;
	margin: 0;
	padding: 0;
	counter-reset: sxlist;
	display: grid;
	gap: 3px;
}

.sinemax-listbuilder__item {
	counter-increment: sxlist;
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 5px 8px;
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 7px;
}

.sinemax-listbuilder__item::before {
	content: counter(sxlist);
	min-width: 22px;
	height: 22px;
	display: grid;
	place-items: center;
	border-radius: 5px;
	background: linear-gradient(135deg, var(--sxa-accent), var(--sxa-accent-2));
	color: #fff;
	font-size: 11px;
	font-weight: 800;
	flex: 0 0 auto;
}

.sinemax-listbuilder__item .sinemax-listbuilder__title {
	flex: 1;
}

.sinemax-listbuilder__remove {
	color: #b32d2e !important;
	text-decoration: none !important;
	padding: 2px 5px;
}

.sinemax-listbuilder__count {
	margin: .6rem 0 0;
	font-size: 12px;
	font-weight: 600;
	color: #646970;
}

/* --------------------------------------------------------------- demo içerik */
.sinemax-demo-page .sinemax-lead {
	max-width: 78ch;
	font-size: 14px;
	line-height: 1.7;
	color: #50575e;
}

.sinemax-cards {
	display: grid;
	gap: 12px;
	margin: 18px 0;
}

.sinemax-cards--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

@media (max-width: 782px) {
	.sinemax-cards--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.sinemax-cards .sinemax-card {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 16px 18px;
	background: #fff;
	border: 1px solid #dcdcde;
	border-left: 3px solid #2271b1;
	border-radius: 6px;
}

.sinemax-card__num {
	font-size: 26px;
	font-weight: 700;
	line-height: 1.1;
	color: #1d2327;
}

.sinemax-card__label {
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: #646970;
}

.sinemax-demo-note p { margin: .4em 0; }

.sinemax-demo-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
	margin-top: 18px;
}

.sinemax-progress {
	margin-top: 18px;
	padding: 16px 18px;
	background: #f6f7f7;
	border: 1px solid #dcdcde;
	border-radius: 6px;
}

.sinemax-progress__bar {
	height: 8px;
	overflow: hidden;
	background: #dcdcde;
	border-radius: 99px;
}

.sinemax-progress__bar span {
	display: block;
	height: 100%;
	background: linear-gradient(90deg, #2271b1, #72aee6);
	border-radius: 99px;
	transition: width .25s ease;
}

.sinemax-progress__text {
	margin: 10px 0 6px;
	font-weight: 600;
	color: #1d2327;
}

.sinemax-progress__log {
	max-height: 190px;
	margin: 0;
	overflow-y: auto;
	font-size: 12px;
	line-height: 1.7;
	color: #50575e;
	list-style: none;
}

.sinemax-progress__log li { border-top: 1px solid #e0e0e0; padding: 3px 0; }
.sinemax-progress__log li::before { content: "✓ "; color: #00a32a; }

.sinemax-steps {
	max-width: 80ch;
	font-size: 14px;
	line-height: 1.8;
	color: #50575e;
}

/* ------------------------------------------- dosya URL'si + yükle düğmesi -- */

.sinemax-fileurl {
	display: flex;
	gap: 4px;
	align-items: center;
}

.sinemax-fileurl__input {
	flex: 1;
	min-width: 0;
}

.sinemax-fileurl .sinemax-upload {
	flex: none;
	white-space: nowrap;
}

/* --------------------------------------------------------- CSV panosu -- */

.sinemax-csv {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem 1.5rem;
	align-items: center;
	padding: .75rem 0;
}

.sinemax-csv form {
	display: flex;
	flex-wrap: wrap;
	gap: .4rem;
	align-items: center;
}

/* --------------------------------------------------- lisans / kütüphane -- */

.sinemax-license-table th { width: 200px; }

.sinemax-pill {
	display: inline-block;
	padding: 2px 9px;
	border-radius: 999px;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.7;
	text-transform: uppercase;
	letter-spacing: .04em;
}

.sinemax-pill--ok   { background: #dcfce7; color: #166534; }
.sinemax-pill--bad  { background: #fee2e2; color: #991b1b; }
.sinemax-pill--idle { background: #e5e7eb; color: #4b5563; }

.sinemax-lib-status {
	margin-inline-start: 8px;
	font-style: italic;
	color: #4b5563;
}
