/**
 * İstanbul Studio – İletişim Butonları
 * Ön yüz stilleri
 */

.iscb-bar,
.iscb-inline {
	--iscb-brand: #875f42;
	--iscb-brand-dark: #694a33;
	--iscb-wa: #25d366;
	--iscb-wa-dark: #1ba34d;
	--iscb-offset: 22px;
	--iscb-z: 99990;
	--iscb-radius: 999px;
	--iscb-size: 56px;
	--iscb-ease: cubic-bezier(0.22, 1, 0.36, 1);

	box-sizing: border-box;
	font-family: inherit;
}

.iscb-bar *,
.iscb-inline * {
	box-sizing: border-box;
}

.iscb-bar {
	position: fixed;
	bottom: calc(var(--iscb-offset) + env(safe-area-inset-bottom, 0px));
	z-index: var(--iscb-z);
	pointer-events: none;
}

.iscb-inner {
	display: flex;
	pointer-events: auto;
}

/* =============================================================== DİKEY */

.iscb-layout-vertical {
	right: var(--iscb-offset);
	left: auto;
	transform: none;
}

.iscb-layout-vertical.iscb-pos-left {
	left: var(--iscb-offset);
	right: auto;
}

.iscb-layout-vertical .iscb-inner {
	flex-direction: column;
	align-items: flex-end;
	gap: 12px;
}

.iscb-layout-vertical.iscb-pos-left .iscb-inner {
	align-items: flex-start;
}

/* ============================================================== YATAY */

.iscb-layout-horizontal.iscb-pos-center {
	left: 50%;
	transform: translateX(-50%);
}

.iscb-layout-horizontal.iscb-pos-right {
	right: var(--iscb-offset);
}

.iscb-layout-horizontal.iscb-pos-left {
	left: var(--iscb-offset);
}

.iscb-layout-horizontal .iscb-inner {
	align-items: stretch;
	gap: 8px;
	padding: 7px;
	border-radius: calc(var(--iscb-radius) + 6px);
}

.iscb-layout-horizontal.iscb-style-glass .iscb-inner {
	background: rgba(255, 255, 255, 0.72);
	-webkit-backdrop-filter: saturate(180%) blur(18px);
	backdrop-filter: saturate(180%) blur(18px);
	border: 1px solid rgba(255, 255, 255, 0.6);
	box-shadow:
		0 1px 2px rgba(16, 12, 8, 0.06),
		0 12px 32px -8px rgba(16, 12, 8, 0.26);
}

.iscb-layout-horizontal.iscb-style-solid .iscb-inner {
	background: #ffffff;
	border: 1px solid rgba(16, 12, 8, 0.08);
	box-shadow:
		0 1px 2px rgba(16, 12, 8, 0.06),
		0 14px 34px -10px rgba(16, 12, 8, 0.3);
}

/* ============================================================== BUTON */

.iscb-btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: flex-start;
	height: var(--iscb-size);
	min-height: var(--iscb-size);
	padding: 0 16px;
	gap: 0;
	border-radius: var(--iscb-radius);
	text-decoration: none !important;
	color: #fff !important;
	line-height: 1.15;
	white-space: nowrap;
	overflow: hidden;
	isolation: isolate;
	-webkit-tap-highlight-color: transparent;
	transition:
		transform 0.28s var(--iscb-ease),
		box-shadow 0.28s var(--iscb-ease),
		filter 0.2s ease;
}

.iscb-btn::after {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 52%;
	background: linear-gradient(rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0));
	pointer-events: none;
	z-index: -1;
}

.iscb-btn--whatsapp {
	background: linear-gradient(140deg, var(--iscb-wa) 0%, var(--iscb-wa-dark) 100%);
	box-shadow:
		0 4px 10px -4px rgba(16, 12, 8, 0.28),
		0 14px 30px -10px rgba(37, 211, 102, 0.55);
}

.iscb-btn--phone {
	background: linear-gradient(140deg, var(--iscb-brand) 0%, var(--iscb-brand-dark) 100%);
	box-shadow:
		0 4px 10px -4px rgba(16, 12, 8, 0.3),
		0 14px 30px -10px rgba(16, 12, 8, 0.45);
}

.iscb-btn:hover {
	transform: translateY(-2px);
	filter: brightness(1.06);
}

.iscb-btn:active {
	transform: translateY(0) scale(0.96);
	transition-duration: 0.08s;
}

.iscb-btn:focus-visible {
	outline: 3px solid #111;
	outline-offset: 3px;
}

/* İkon */

.iscb-ico-wrap {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 26px;
	height: 26px;
}

.iscb-icon {
	width: 26px;
	height: 26px;
	display: block;
}

/* Metin */

.iscb-text {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.iscb-label {
	font-size: 15px;
	font-weight: 600;
	letter-spacing: 0.01em;
}

.iscb-sub {
	font-size: 11.5px;
	font-weight: 400;
	opacity: 0.82;
	letter-spacing: 0.02em;
}

/* ------------------------------------------- Buton stili: yalnızca ikon */

.iscb-btnstyle-icon .iscb-btn {
	width: var(--iscb-size);
	justify-content: center;
	border-radius: 50%;
	padding: 0;
}

.iscb-btnstyle-icon .iscb-text {
	display: none;
}

/* --------------------------------- Buton stili: ikon + üzerine gelince aç */

.iscb-btnstyle-expand .iscb-btn {
	justify-content: center;
	padding: 0 16px;
}

.iscb-btnstyle-expand .iscb-text {
	max-width: 0;
	opacity: 0;
	margin-left: 0;
	overflow: hidden;
	transition:
		max-width 0.42s var(--iscb-ease),
		margin-left 0.42s var(--iscb-ease),
		opacity 0.24s ease;
}

@media (hover: hover) and (pointer: fine) {
	.iscb-btnstyle-expand .iscb-btn:hover .iscb-text,
	.iscb-btnstyle-expand .iscb-btn:focus-visible .iscb-text {
		max-width: 220px;
		margin-left: 12px;
		opacity: 1;
	}
}

/* Klavye kullanıcıları için dokunmatik cihazlarda da açılsın */
.iscb-btnstyle-expand .iscb-btn:focus-visible .iscb-text {
	max-width: 220px;
	margin-left: 12px;
	opacity: 1;
}

/* --------------------------------------- Buton stili: ikon + yazı (hap) */

.iscb-btnstyle-label .iscb-btn {
	padding: 0 24px 0 18px;
}

.iscb-btnstyle-label .iscb-text {
	margin-left: 12px;
}

/* Alt yazı kapalıyken dikey ortalama net kalsın */
.iscb-btnstyle-label .iscb-text:only-child,
.iscb-btnstyle-label .iscb-label:only-child {
	justify-content: center;
}

/* --------------------------------------------------- Çevrimiçi noktası */

.iscb-dot {
	position: absolute;
	top: -3px;
	right: -4px;
	width: 11px;
	height: 11px;
	border-radius: 50%;
	background: #4ade80;
	border: 2px solid rgba(255, 255, 255, 0.95);
}

.iscb-dot::before {
	content: "";
	position: absolute;
	inset: -2px;
	border-radius: 50%;
	background: rgba(74, 222, 128, 0.5);
	animation: iscb-ping 2.4s var(--iscb-ease) infinite;
}

@keyframes iscb-ping {
	0% {
		transform: scale(0.9);
		opacity: 0.7;
	}
	70%,
	100% {
		transform: scale(2.2);
		opacity: 0;
	}
}

/* ---------------------------------------------------------- Dalga efekti */

.iscb-ripple {
	position: absolute;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.4);
	transform: scale(0);
	animation: iscb-ripple 0.6s ease-out;
	pointer-events: none;
	z-index: -1;
}

@keyframes iscb-ripple {
	to {
		transform: scale(2.8);
		opacity: 0;
	}
}

/* ------------------------------------------------------ Giriş animasyonu */

.iscb-animate .iscb-btn {
	opacity: 0;
	animation: iscb-rise 0.6s var(--iscb-ease) forwards;
}

.iscb-animate .iscb-btn:nth-child(1) {
	animation-delay: 0.35s;
}

.iscb-animate .iscb-btn:nth-child(2) {
	animation-delay: 0.47s;
}

@keyframes iscb-rise {
	from {
		opacity: 0;
		transform: translateY(16px) scale(0.9);
	}
	to {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}

/* ------------------------------------------------------ Cihaz görünürlüğü */

@media (max-width: 782px) {
	.iscb-show-desktop {
		display: none !important;
	}
}

@media (min-width: 783px) {
	.iscb-show-mobile {
		display: none !important;
	}
}

/* ================================================================ MOBİL */

@media (max-width: 600px) {
	.iscb-bar {
		--iscb-size: 54px;
		--iscb-offset: 16px;
	}

	.iscb-layout-vertical .iscb-inner {
		gap: 10px;
	}

	.iscb-ico-wrap,
	.iscb-icon {
		width: 24px;
		height: 24px;
	}

	/* Yatay düzen mobilde tam genişlik çubuğa dönüşür */
	.iscb-layout-horizontal {
		left: 10px;
		right: 10px;
		transform: none;
		bottom: calc(10px + env(safe-area-inset-bottom, 0px));
	}

	.iscb-layout-horizontal .iscb-inner {
		padding: 6px;
		gap: 6px;
	}

	.iscb-layout-horizontal .iscb-btn {
		flex: 1 1 0;
		justify-content: center;
		padding: 0 12px;
	}

	.iscb-layout-horizontal.iscb-btnstyle-expand .iscb-text,
	.iscb-layout-horizontal.iscb-btnstyle-icon .iscb-text {
		display: flex;
		max-width: none;
		opacity: 1;
		margin-left: 10px;
	}

	.iscb-label {
		font-size: 14.5px;
	}

	.iscb-sub {
		font-size: 11px;
	}
}

/* ============================================================= SATIR İÇİ */

.iscb-inline .iscb-inner {
	display: inline-flex;
	gap: 10px;
	padding: 0;
	background: none;
	border: 0;
	box-shadow: none;
	flex-wrap: wrap;
}

/* ================================================================= İMZA */

.iscb-credit--bar {
	box-sizing: border-box;
	width: 100%;
	padding: 14px 16px calc(14px + env(safe-area-inset-bottom, 0px));
	background: #0f0d0b;
	color: rgba(255, 255, 255, 0.62);
	font-size: 13px;
	line-height: 1.5;
	text-align: center;
}

.iscb-credit--left {
	text-align: left;
}

.iscb-credit--right {
	text-align: right;
}

.iscb-credit__link {
	color: rgba(255, 255, 255, 0.82);
	text-decoration: none;
	font-weight: 500;
	border-bottom: 1px solid rgba(255, 255, 255, 0.24);
	padding-bottom: 1px;
	transition: color 0.2s ease, border-color 0.2s ease;
}

.iscb-credit__link:hover,
.iscb-credit__link:focus {
	color: #fff;
	border-bottom-color: rgba(255, 255, 255, 0.7);
}

.iscb-credit--inline .iscb-credit__link {
	color: inherit;
	border-bottom-color: currentColor;
	opacity: 0.85;
}

/* ------------------------------------------------ Erişilebilirlik / baskı */

@media (prefers-reduced-motion: reduce) {
	.iscb-btn,
	.iscb-text {
		transition: none !important;
		animation: none !important;
		opacity: 1 !important;
	}

	.iscb-animate .iscb-btn {
		transform: none !important;
	}

	.iscb-dot::before,
	.iscb-ripple {
		animation: none !important;
	}
}

@media print {
	.iscb-bar,
	.iscb-credit--bar {
		display: none !important;
	}
}
