/* ===================================================
   Uzman Klinik Psikolog Dr. Ali Öktem
   Canlı Online Seans Odası Stilleri (online_seans.css)
   =================================================== */

:root {
	--primary: #4eaac8;
	--primary-dark: #368ea8;
	--dark-bg: #070b14;
	--card-bg: #0f172a;
	--border: rgba(255, 255, 255, 0.12);
	--text-main: #f8fafc;
	--text-muted: #94a3b8;
	--success: #10b981;
	--warning: #f59e0b;
	--danger: #ef4444;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
	font-family: 'Plus Jakarta Sans', sans-serif;
}

body {
	background: var(--dark-bg);
	color: var(--text-main);
	height: 100vh;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

/* Üst Başlık Çubuğu */
.session-header {
	background: #0f172a;
	border-bottom: 1px solid var(--border);
	padding: 12px 24px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 15px;
	z-index: 20;
	flex-shrink: 0;
}

.header-left {
	display: flex;
	align-items: center;
	gap: 16px;
}

.header-logo {
	display: flex;
	align-items: center;
	gap: 10px;
	text-decoration: none;
	color: #ffffff;
}

.header-logo img {
	height: 30px;
	filter: brightness(0) invert(1);
}

.room-badge {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: rgba(78, 170, 200, 0.15);
	color: #7dd3fc;
	border: 1px solid rgba(78, 170, 200, 0.3);
	padding: 5px 12px;
	border-radius: 20px;
	font-size: 13px;
	font-weight: 700;
}

.encrypted-badge {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: rgba(16, 185, 129, 0.15);
	color: #6ee7b7;
	border: 1px solid rgba(16, 185, 129, 0.3);
	padding: 5px 12px;
	border-radius: 20px;
	font-size: 12px;
	font-weight: 600;
}

.header-right {
	display: flex;
	align-items: center;
	gap: 10px;
}

.timer-display {
	display: flex;
	align-items: center;
	gap: 8px;
	background: #1e293b;
	border: 1px solid var(--border);
	padding: 6px 14px;
	border-radius: 10px;
	font-size: 13.5px;
	font-weight: 700;
	color: #e2e8f0;
}

.timer-display i {
	color: var(--primary);
}

.btn-action {
	background: #1e293b;
	border: 1px solid var(--border);
	color: #ffffff;
	padding: 8px 15px;
	border-radius: 10px;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	transition: all 0.2s;
	text-decoration: none;
}

.btn-action:hover {
	background: var(--primary);
	border-color: var(--primary);
	color: #ffffff;
	text-decoration: none;
}

.btn-whatsapp {
	background: #25d366;
	border-color: #25d366;
	color: #ffffff;
}

.btn-whatsapp:hover {
	background: #1eb956;
	border-color: #1eb956;
	color: #ffffff;
}

/* Ana Konteyner */
.session-main {
	flex-grow: 1;
	display: flex;
	height: calc(100vh - 62px);
	position: relative;
	overflow: hidden;
}

/* Video Sahnesi (İki Eşit Bölünmüş Ekran) */
.video-stage {
	flex-grow: 1;
	display: flex;
	flex-direction: column;
	background: #060911;
	position: relative;
	padding: 16px;
	overflow: hidden;
}

.video-grid {
	flex-grow: 1;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
	height: calc(100% - 80px);
	width: 100%;
}

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

.video-box {
	background: #0f172a;
	border: 2px solid var(--border);
	border-radius: 20px;
	position: relative;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.video-box video {
	width: 100%;
	height: 100%;
	object-fit: cover;
	background: #0f172a;
}

.video-user-badge {
	position: absolute;
	bottom: 16px;
	left: 16px;
	background: rgba(15, 23, 42, 0.85);
	backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.15);
	padding: 8px 16px;
	border-radius: 12px;
	font-size: 13.5px;
	font-weight: 700;
	color: #ffffff;
	display: flex;
	align-items: center;
	gap: 8px;
	z-index: 5;
}

.video-user-badge i {
	color: var(--primary);
}

.status-tag {
	font-size: 11px;
	padding: 3px 8px;
	border-radius: 8px;
	background: rgba(239, 68, 68, 0.2);
	color: #fca5a5;
	font-weight: 600;
}

.video-placeholder {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: radial-gradient(circle at center, #1e293b 0%, #0f172a 100%);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 30px;
	text-align: center;
	z-index: 2;
}

.avatar-circle {
	width: 80px;
	height: 80px;
	border-radius: 50%;
	background: rgba(78, 170, 200, 0.15);
	border: 2px solid rgba(78, 170, 200, 0.4);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 34px;
	color: var(--primary);
	margin-bottom: 16px;
}

.placeholder-title {
	font-size: 18px;
	font-weight: 700;
	color: #ffffff;
	margin-bottom: 8px;
}

.placeholder-desc {
	font-size: 13.5px;
	color: var(--text-muted);
	max-width: 320px;
	line-height: 20px;
	margin-bottom: 15px;
}

.connecting-spinner {
	font-size: 24px;
	color: var(--primary);
}

/* Alt Buton Çubuğu */
.control-bar {
	height: 70px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	padding: 10px;
	flex-wrap: wrap;
}

.ctrl-btn {
	background: #1e293b;
	border: 1px solid var(--border);
	color: #ffffff;
	height: 48px;
	padding: 0 18px;
	border-radius: 14px;
	font-size: 13.5px;
	font-weight: 700;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
	text-decoration: none;
}

.ctrl-btn:hover {
	background: #334155;
	border-color: rgba(255, 255, 255, 0.25);
	color: #ffffff;
	transform: translateY(-2px);
	text-decoration: none;
}

.ctrl-btn.btn-off {
	background: rgba(239, 68, 68, 0.2);
	border-color: rgba(239, 68, 68, 0.5);
	color: #fca5a5;
}

.ctrl-btn.btn-hangup {
	background: #ef4444;
	border-color: #ef4444;
	color: #ffffff;
}

.ctrl-btn.btn-hangup:hover {
	background: #dc2626;
	border-color: #dc2626;
	box-shadow: 0 4px 15px rgba(239, 68, 68, 0.4);
}

/* Klinik Seans Notları Yan Paneli */
.notes-sidebar {
	width: 340px;
	background: #0f172a;
	border-left: 1px solid var(--border);
	display: flex;
	flex-direction: column;
	transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
	z-index: 10;
}

.notes-sidebar.is-collapsed {
	width: 0;
	border-left: none;
	opacity: 0;
	pointer-events: none;
	overflow: hidden;
}

.notes-header {
	padding: 16px 20px;
	border-bottom: 1px solid var(--border);
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.notes-header h4 {
	font-size: 15px;
	font-weight: 700;
	color: #ffffff;
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
}

.notes-body {
	padding: 16px 20px;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.session-notes-textarea {
	width: 100%;
	flex-grow: 1;
	background: #1e293b;
	border: 1px solid var(--border);
	border-radius: 12px;
	padding: 14px;
	color: #ffffff;
	font-size: 13.5px;
	line-height: 20px;
	resize: none;
	outline: none;
}

.session-notes-textarea:focus {
	border-color: var(--primary);
}

.notes-footer {
	padding: 14px 20px;
	border-top: 1px solid var(--border);
	display: flex;
	gap: 10px;
}

/* Lobi / Bekleme Ekranı */
.lobby-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: radial-gradient(circle at center, #172554 0%, #070b14 100%);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 50;
	padding: 20px;
	overflow-y: auto;
}

.lobby-card {
	background: #0f172a;
	border: 1px solid var(--border);
	border-radius: 24px;
	padding: 32px 36px;
	width: 100%;
	max-width: 620px;
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7);
	text-align: center;
}

.lobby-badge-status {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: rgba(16, 185, 129, 0.15);
	color: #34d399;
	border: 1px solid rgba(16, 185, 129, 0.3);
	padding: 6px 16px;
	border-radius: 20px;
	font-size: 13px;
	font-weight: 700;
	margin-bottom: 16px;
}

.pulse-dot {
	width: 8px;
	height: 8px;
	background: #34d399;
	border-radius: 50%;
	box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.7);
	animation: pulse 1.6s infinite;
}

@keyframes pulse {
	0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.7); }
	70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(52, 211, 153, 0); }
	100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}

.lobby-title {
	font-size: 24px;
	font-weight: 800;
	color: #ffffff;
	margin-bottom: 6px;
}

.lobby-subtitle {
	font-size: 13.5px;
	color: var(--text-muted);
	margin-bottom: 18px;
	line-height: 21px;
}

/* Görüşme Türü Seçim Kutuları */
.mode-selector-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px;
	margin-bottom: 18px;
	text-align: left;
}

.mode-option-card {
	background: #1e293b;
	border: 2px solid var(--border);
	border-radius: 14px;
	padding: 12px 16px;
	cursor: pointer;
	transition: all 0.2s;
	display: flex;
	align-items: center;
	gap: 12px;
}

.mode-option-card:hover {
	border-color: #7dd3fc;
}

.mode-option-card.is-active {
	border-color: var(--primary);
	background: rgba(78, 170, 200, 0.15);
}

.mode-icon {
	font-size: 22px;
	color: var(--primary);
}

.mode-text h5 {
	font-size: 13.5px;
	font-weight: 700;
	color: #ffffff;
	margin: 0 0 2px;
}

.mode-text p {
	font-size: 11px;
	color: var(--text-muted);
	margin: 0;
}

.lobby-info-box {
	background: rgba(30, 41, 59, 0.7);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 14px;
	padding: 14px 18px;
	text-align: left;
	margin-bottom: 18px;
	display: flex;
	gap: 12px;
}

.lobby-info-box i {
	font-size: 20px;
	color: #38bdf8;
	flex-shrink: 0;
	margin-top: 2px;
}

.lobby-info-box p {
	margin: 0;
	font-size: 12.5px;
	color: #cbd5e1;
	line-height: 18px;
}

.lobby-form-group {
	text-align: left;
	margin-bottom: 14px;
}

.lobby-label {
	display: block;
	font-size: 12.5px;
	font-weight: 700;
	color: #cbd5e1;
	margin-bottom: 6px;
}

.lobby-input {
	width: 100%;
	height: 44px;
	background: #1e293b;
	border: 1px solid var(--border);
	border-radius: 12px;
	padding: 10px 14px;
	font-size: 14px;
	color: #ffffff;
	outline: none;
	transition: border-color 0.2s;
}

.lobby-input:focus {
	border-color: var(--primary);
}

/* ==========================================
   CİHAZ SEÇİMİ VE AYARLAR BİLEŞENLERİ (KAMERA / MİKROFON)
   ========================================== */
.device-settings-card {
	background: #1e293b;
	border: 1px solid var(--border);
	border-radius: 14px;
	padding: 14px 16px;
	margin-bottom: 16px;
	text-align: left;
}

.device-settings-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	cursor: pointer;
	user-select: none;
}

.device-settings-header h5 {
	font-size: 13px;
	font-weight: 700;
	color: #e2e8f0;
	margin: 0;
	display: flex;
	align-items: center;
	gap: 8px;
}

.device-settings-header h5 i {
	color: var(--primary);
}

.device-settings-header .chevron-icon {
	font-size: 12px;
	color: #94a3b8;
	transition: transform 0.2s ease;
}

.device-settings-body {
	margin-top: 14px;
	padding-top: 12px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.device-settings-body.is-hidden {
	display: none;
}

.device-row {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.device-row label {
	font-size: 11.5px;
	font-weight: 700;
	color: #94a3b8;
	display: flex;
	align-items: center;
	gap: 6px;
}

.device-select {
	width: 100%;
	height: 38px;
	background: #0f172a;
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 10px;
	padding: 6px 12px;
	font-size: 13px;
	color: #f8fafc;
	outline: none;
	cursor: pointer;
	transition: all 0.2s ease;
}

.device-select:focus {
	border-color: var(--primary);
	box-shadow: 0 0 0 2px rgba(78, 170, 200, 0.25);
}

.device-select option {
	background: #0f172a;
	color: #ffffff;
}

/* Görüşme Esnasında Cihaz Ayarları Modalı */
.device-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(7, 11, 20, 0.75);
	backdrop-filter: blur(8px);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 1000;
	opacity: 0;
	visibility: hidden;
	transition: all 0.25s ease;
	padding: 20px;
}

.device-modal-overlay.is-active {
	opacity: 1;
	visibility: visible;
}

.device-modal-card {
	background: #0f172a;
	border: 1px solid var(--border);
	border-radius: 20px;
	width: 100%;
	max-width: 480px;
	box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
	overflow: hidden;
	transform: translateY(20px) scale(0.96);
	transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.device-modal-overlay.is-active .device-modal-card {
	transform: translateY(0) scale(1);
}

.device-modal-header {
	padding: 18px 24px;
	border-bottom: 1px solid var(--border);
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: #1e293b;
}

.device-modal-header h4 {
	font-size: 16px;
	font-weight: 700;
	color: #ffffff;
	margin: 0;
	display: flex;
	align-items: center;
	gap: 8px;
}

.device-modal-close {
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.15);
	width: 32px;
	height: 32px;
	border-radius: 50%;
	color: #cbd5e1;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.2s;
}

.device-modal-close:hover {
	background: #ef4444;
	border-color: #ef4444;
	color: #ffffff;
}

.device-modal-body {
	padding: 24px;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.device-modal-footer {
	padding: 16px 24px;
	border-top: 1px solid var(--border);
	display: flex;
	justify-content: flex-end;
	background: #0f172a;
}

.btn-join-session {
	width: 100%;
	background: var(--primary);
	color: #ffffff;
	border: none;
	height: 50px;
	border-radius: 14px;
	font-size: 15.5px;
	font-weight: 800;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	margin-top: 16px;
	transition: all 0.25s;
}

.btn-join-session:hover {
	background: var(--primary-dark);
	transform: translateY(-2px);
	box-shadow: 0 10px 25px rgba(78, 170, 200, 0.45);
}

/* Toast Bildirimi */
.session-toast {
	position: fixed;
	bottom: 30px;
	right: 30px;
	background: #1e293b;
	border: 1px solid var(--border);
	color: #ffffff;
	padding: 14px 22px;
	border-radius: 12px;
	font-size: 14px;
	font-weight: 600;
	display: flex;
	align-items: center;
	gap: 10px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
	z-index: 9999;
	transform: translateY(100px);
	opacity: 0;
	transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.session-toast.show {
	transform: translateY(0);
	opacity: 1;
}

/* ==========================================
   MOBİL UYUMLULUK & RESPONSIVE (REDMI, IPHONE, ANDROID)
   ========================================== */
@media (max-width: 768px) {
	.session-header {
		padding: 8px 12px;
	}

	.encrypted-badge, .room-badge {
		display: none;
	}

	.session-main {
		height: calc(100vh - 52px);
		height: calc(100dvh - 52px);
	}

	.video-stage {
		padding: 6px;
		display: flex;
		flex-direction: column;
		justify-content: space-between;
	}

	.video-grid {
		gap: 8px;
		height: calc(100% - 68px);
		grid-template-columns: 1fr;
		grid-template-rows: 1fr 1fr;
	}

	.video-box {
		border-radius: 14px;
	}

	.video-user-badge {
		bottom: 8px;
		left: 8px;
		padding: 4px 10px;
		font-size: 11.5px;
		border-radius: 8px;
		backdrop-filter: blur(4px);
	}

	.avatar-circle {
		width: 56px;
		height: 56px;
		font-size: 24px;
		margin-bottom: 8px;
	}

	.placeholder-title {
		font-size: 15px;
		margin-bottom: 4px;
	}

	.placeholder-desc {
		font-size: 11.5px;
		line-height: 16px;
		margin-bottom: 8px;
	}

	/* Alt Kontrol Çubuğu - Mobilde Asla Taşmaz ve Kesilmez */
	.control-bar {
		height: 60px;
		min-height: 60px;
		display: flex;
		align-items: center;
		justify-content: center;
		gap: 8px;
		padding: 6px 8px;
		padding-bottom: max(6px, env(safe-area-inset-bottom));
		flex-wrap: nowrap;
		width: 100%;
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
	}

	.ctrl-btn {
		height: 44px;
		width: 44px;
		min-width: 44px;
		padding: 0;
		font-size: 15px;
		border-radius: 12px;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		flex-shrink: 0;
	}

	.ctrl-btn span {
		display: none !important;
	}

	.ctrl-btn i {
		font-size: 17px;
		margin: 0;
	}

	.ctrl-btn.btn-hangup {
		background: #ef4444;
		border-color: #ef4444;
		color: #ffffff;
		width: 48px;
		min-width: 48px;
		height: 44px;
		border-radius: 12px;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		padding: 0;
	}

	.ctrl-btn.btn-hangup i {
		transform: rotate(135deg);
		font-size: 18px;
	}

	.lobby-card {
		padding: 22px 16px;
		border-radius: 18px;
		max-width: 100%;
	}

	.lobby-title {
		font-size: 18px;
	}

	.lobby-subtitle {
		font-size: 12px;
		margin-bottom: 12px;
	}

	.mode-selector-grid {
		grid-template-columns: 1fr;
		gap: 8px;
	}

	.lobby-info-box {
		padding: 10px 12px;
		font-size: 11.5px;
	}
}
