/* Cookiea Banner - Light Theme
 * CSS izolasyon stratejisi:
 * 1. #cookiea-banner wrapper: !important ile pozisyon sabitle
 * 2. .cookiea-banner__dialog: all:initial → tema stillerini sıfırla
 * 3. dialog * : font/box-sizing inherit ile tutarlı alt-element bazı
 * 4. Tüm bileşen seçicileri #cookiea-banner prefix → yüksek özgüllük
 */

/* ==============================
   Wrapper — tema stillerinden bağımsız pozisyon
   ============================== */

#cookiea-banner {
	display: none;
	position: fixed !important;
	inset: 0 !important;
	z-index: 2147483647 !important;
	align-items: center !important;
	justify-content: center !important;
	padding: 20px !important;
	pointer-events: auto !important;
	background: rgba(0, 0, 0, 0.45) !important;
}

#cookiea-banner.cookiea-visible {
	display: flex !important;
}

/* Açılışta odak dialog'a taşınır; kapsayıcıda halka gösterme */
#cookiea-banner:focus {
	outline: none !important;
}

#cookiea-banner .cookiea-consent-id code {
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	font-size: 12px;
	word-break: break-all;
	background: #f3f4f6;
	padding: 1px 4px;
	border-radius: 3px;
}

/* ==============================
   Dialog — tam CSS izolasyon
   ============================== */

#cookiea-banner .cookiea-banner__dialog {
	all: initial;
	display: block;
	position: relative;
	z-index: 1;
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
	font-size: 14px;
	line-height: 1.5;
	color: #111827;
	background: #ffffff;
	border-radius: 4px;
	width: 100%;
	max-width: 720px;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
	box-sizing: border-box;
}

/* Tüm alt elementler font/sizing miras alsın */
#cookiea-banner .cookiea-banner__dialog *,
#cookiea-banner .cookiea-banner__dialog *::before,
#cookiea-banner .cookiea-banner__dialog *::after {
	box-sizing: border-box;
	font-family: inherit;
	-webkit-font-smoothing: antialiased;
}

/* ==============================
   Header
   ============================== */

#cookiea-banner .cookiea-banner__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 24px;
	border-bottom: 1px solid #e5e7eb;
}

#cookiea-banner .cookiea-banner__logo a {
	display: inline-flex;
	text-decoration: none;
	border: none;
	box-shadow: none;
	outline: none;
}

#cookiea-banner .cookiea-banner__logo img {
	max-height: 36px;
	width: auto;
	display: block;
	border: none;
	box-shadow: none;
}

#cookiea-banner .cookiea-banner__site-name {
	font-size: 15px;
	font-weight: 700;
	color: #111827;
	display: block;
}

#cookiea-banner .cookiea-banner__powered {
	font-size: 13px;
	color: #6b7280;
	white-space: nowrap;
	font-weight: 500;
}

/* ==============================
   Tabs
   ============================== */

#cookiea-banner .cookiea-tabs {
	display: flex;
	border-bottom: 1px solid #e5e7eb;
	padding: 0 24px;
	margin: 0;
	list-style: none;
}

#cookiea-banner .cookiea-tab {
	display: inline-block;
	padding: 12px 18px;
	border: none;
	border-bottom: 2px solid transparent;
	border-top: none;
	border-left: none;
	border-right: none;
	background: none;
	font-size: 14px;
	font-weight: 500;
	color: #6b7280;
	cursor: pointer;
	margin: 0 0 -1px 0;
	line-height: 1.4;
	text-decoration: none;
	border-radius: 0;
	box-shadow: none;
	outline-offset: 2px;
	transition: color 0.15s, border-color 0.15s;
	-webkit-appearance: none;
	appearance: none;
}

#cookiea-banner .cookiea-tab:hover {
	color: #111827;
	background: none;
}

#cookiea-banner .cookiea-tab:focus-visible {
	outline: 2px solid #2563eb;
}

#cookiea-banner .cookiea-tab--active {
	color: #2563eb;
	border-bottom-color: #2563eb;
	font-weight: 600;
}

/* ==============================
   Panels
   ============================== */

#cookiea-banner .cookiea-panel {
	padding: 24px;
	display: block;
}

#cookiea-banner .cookiea-panel__title {
	font-size: 16px;
	font-weight: 700;
	color: #111827;
	margin: 0 0 12px 0;
	padding: 0;
	line-height: 1.4;
	display: block;
}

#cookiea-banner .cookiea-panel__desc {
	font-size: 14px;
	color: #374151;
	line-height: 1.65;
	margin: 0 0 12px 0;
	padding: 0;
	display: block;
	font-weight: 400;
}

#cookiea-banner .cookiea-panel__desc:last-child {
	margin-bottom: 0;
}

#cookiea-banner .cookiea-panel__links {
	display: flex;
	gap: 16px;
	flex-wrap: wrap;
	margin: 4px 0 0 0;
	padding: 0;
	list-style: none;
}

#cookiea-banner .cookiea-panel__links a {
	font-size: 13px;
	color: #2563eb;
	text-decoration: none;
	font-weight: 400;
	border: none;
	box-shadow: none;
}

#cookiea-banner .cookiea-panel__links a:hover {
	text-decoration: underline;
	color: #1d4ed8;
}

/* ==============================
   Toggle Grid
   ============================== */

#cookiea-banner .cookiea-toggles {
	display: flex;
	margin: 20px 0 0 0;
	border: 1px solid #e5e7eb;
	border-radius: 4px;
	overflow: hidden;
}

#cookiea-banner .cookiea-toggle-col {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	padding: 18px 8px;
	border-right: 1px solid #e5e7eb;
	text-align: center;
	margin: 0;
}

#cookiea-banner .cookiea-toggle-col:last-child {
	border-right: none;
}

#cookiea-banner .cookiea-toggle-col__name {
	font-size: 12px;
	font-weight: 600;
	color: #374151;
	line-height: 1.3;
	display: block;
	margin: 0;
	padding: 0;
}

/* Toggle switch */
#cookiea-banner .cookiea-toggle {
	display: inline-flex;
	cursor: pointer;
	position: relative;
	flex-shrink: 0;
	margin: 0;
	padding: 0;
}

#cookiea-banner .cookiea-toggle input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
	margin: 0;
	padding: 0;
	pointer-events: none;
}

#cookiea-banner .cookiea-toggle__track {
	width: 44px;
	height: 24px;
	background: #d1d5db;
	border-radius: 12px;
	position: relative;
	transition: background 0.2s;
	display: block;
	cursor: pointer;
}

#cookiea-banner .cookiea-toggle__thumb {
	position: absolute;
	top: 4px;
	left: 4px;
	width: 16px;
	height: 16px;
	background: #ffffff;
	border-radius: 50%;
	transition: transform 0.2s;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
	display: block;
}

#cookiea-banner .cookiea-toggle input:checked ~ .cookiea-toggle__track {
	background: #1f2937;
}

#cookiea-banner .cookiea-toggle input:checked ~ .cookiea-toggle__track .cookiea-toggle__thumb {
	transform: translateX(20px);
}

#cookiea-banner .cookiea-toggle:focus-within .cookiea-toggle__track {
	outline: 2px solid #2563eb;
	outline-offset: 2px;
}

/* "Her zaman aktif" rozeti (Zorunlu kategori) */
#cookiea-banner .cookiea-toggle-always {
	display: inline-block;
	font-size: 11px;
	font-weight: 500;
	color: #6b7280;
	font-style: italic;
	line-height: 1.3;
	margin: 0;
	padding: 0;
}

/* ==============================
   Details accordion
   ============================== */

#cookiea-banner .cookiea-detail {
	border-bottom: 1px solid #e5e7eb;
	margin: 0;
	padding: 0;
}

#cookiea-banner .cookiea-detail:last-child {
	border-bottom: none;
}

#cookiea-banner .cookiea-detail__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 14px 0;
	border: none;
	background: none;
	color: #111827;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	text-align: left;
	margin: 0;
	border-radius: 0;
	box-shadow: none;
	-webkit-appearance: none;
	appearance: none;
	transition: color 0.15s;
}

#cookiea-banner .cookiea-detail__header:hover {
	color: #2563eb;
	background: none;
}

#cookiea-banner .cookiea-detail__name {
	display: block;
}

#cookiea-banner .cookiea-detail__arrow {
	flex-shrink: 0;
	transition: transform 0.2s;
	color: #9ca3af;
	display: block;
}

#cookiea-banner .cookiea-detail[data-expanded="true"] .cookiea-detail__arrow {
	transform: rotate(180deg);
}

#cookiea-banner .cookiea-detail__body {
	padding: 0 0 14px 0;
}

#cookiea-banner .cookiea-detail__desc {
	font-size: 13px;
	color: #6b7280;
	line-height: 1.6;
	margin: 0 0 10px 0;
	padding: 0;
	display: block;
	font-weight: 400;
}

#cookiea-banner .cookiea-detail__services {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	margin: 0 0 10px 0;
	padding: 0;
}

#cookiea-banner .cookiea-detail__services li {
	padding: 2px 10px;
	background: #f3f4f6;
	border-radius: 4px;
	font-size: 12px;
	color: #374151;
	font-weight: 400;
	list-style: none;
	display: inline-block;
	margin: 0;
}

#cookiea-banner .cookiea-detail__cookies {
	font-size: 12px;
	color: #9ca3af;
	margin: 0;
	padding: 0;
	display: block;
	font-weight: 400;
}

#cookiea-banner .cookiea-detail__cookies strong {
	color: #6b7280;
	font-weight: 600;
}

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

#cookiea-banner .cookiea-banner__footer {
	display: flex;
	gap: 8px;
	padding: 16px 24px;
	border-top: 1px solid #e5e7eb;
	margin: 0;
}

#cookiea-banner .cookiea-btn {
	flex: 1;
	padding: 10px 16px;
	border: 1px solid #d1d5db;
	border-radius: 4px;
	background: #ffffff;
	color: #374151;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	text-align: center;
	line-height: 1.3;
	white-space: nowrap;
	margin: 0;
	display: inline-block;
	text-decoration: none;
	box-shadow: none;
	-webkit-appearance: none;
	appearance: none;
	border-radius: 4px;
	transition: background 0.15s, border-color 0.15s, color 0.15s;
	font-family: inherit;
}

#cookiea-banner .cookiea-btn:hover {
	background: #f9fafb;
	border-color: #9ca3af;
	color: #111827;
	text-decoration: none;
	box-shadow: none;
}

#cookiea-banner .cookiea-btn:focus-visible {
	outline: 2px solid #2563eb;
	outline-offset: 2px;
}

/* ==============================
   Mobile
   ============================== */

@media (max-width: 600px) {
	#cookiea-banner {
		padding: 0 !important;
		align-items: flex-end !important;
	}

	#cookiea-banner .cookiea-banner__dialog {
		max-width: 100%;
		border-radius: 12px 12px 0 0;
		max-height: 92vh;
	}

	#cookiea-banner .cookiea-tabs {
		padding: 0 16px;
	}

	#cookiea-banner .cookiea-tab {
		padding: 10px 12px;
		font-size: 13px;
	}

	#cookiea-banner .cookiea-panel {
		padding: 18px 16px;
	}

	#cookiea-banner .cookiea-toggles {
		flex-wrap: wrap;
	}

	#cookiea-banner .cookiea-toggle-col {
		flex: 1 1 calc(50% - 1px);
		border-bottom: 1px solid #e5e7eb;
	}

	#cookiea-banner .cookiea-toggle-col:nth-child(2n) {
		border-right: none;
	}

	#cookiea-banner .cookiea-toggle-col:nth-last-child(-n+2) {
		border-bottom: none;
	}

	#cookiea-banner .cookiea-banner__footer {
		padding: 12px 16px;
		flex-wrap: wrap;
	}

	/* Reddet ve Kabul eşit görünürlükte kalsın diye tüm butonlar tam genişlik */
	#cookiea-banner .cookiea-btn {
		flex: 1 1 100%;
		white-space: normal;
	}
}

@media (prefers-reduced-motion: reduce) {
	#cookiea-banner .cookiea-banner__dialog *,
	#cookiea-banner .cookiea-banner__overlay {
		transition: none !important;
	}
}
