/**
 * Calendar view (V6) styles.
 *
 * @package Tobalt_Renginiai
 * @author  Tobalt — https://tobalt.lt
 */

.tr-cal {
	max-width: 1100px;
	margin: 0 auto;
}

.tr-cal__grid {
	display: grid;
	grid-template-columns: 340px 1fr;
	gap: 32px;
	align-items: start;
}

/* ── Picker ───────────────────────────────────────────────── */

.tr-cal__picker {
	background: #fff;
	border-radius: 12px;
	padding: 24px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.tr-cal__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 16px;
}

.tr-cal__month-label {
	font-size: 18px;
	font-weight: 700;
	color: #111827;
}

.tr-cal__nav-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border: 1px solid #e5e7eb;
	border-radius: 6px;
	background: #fff;
	color: #374151;
	cursor: pointer;
	transition: all 0.15s ease;
}

.tr-cal__nav-btn:hover {
	border-color: #2563eb;
	color: #2563eb;
}

.tr-cal__weekdays {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	text-align: center;
	font-size: 12px;
	font-weight: 600;
	color: #9ca3af;
	margin-bottom: 8px;
}

.tr-cal__days {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 4px;
}

.tr-cal__day {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	margin: 0 auto;
	border-radius: 50%;
	border: none;
	background: transparent;
	font-size: 14px;
	color: #374151;
	cursor: default;
	position: relative;
}

.tr-cal__day--empty {
	visibility: hidden;
}

.tr-cal__day--has-event {
	cursor: pointer;
	font-weight: 600;
}

.tr-cal__day--has-event::after {
	content: '';
	position: absolute;
	bottom: 2px;
	left: 50%;
	transform: translateX(-50%);
	width: 4px;
	height: 4px;
	border-radius: 50%;
	background: #2563eb;
}

.tr-cal__day--has-event:hover {
	background: #eff6ff;
}

.tr-cal__day--selected {
	background: #2563eb;
	color: #fff;
}

.tr-cal__day--selected::after {
	background: #fff;
}

.tr-cal__day--today {
	border: 2px solid #2563eb;
}

/* ── Panel ────────────────────────────────────────────────── */

.tr-cal__panel {
	min-height: 200px;
}

.tr-cal__panel-empty {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 200px;
	color: #9ca3af;
	font-size: 15px;
}

.tr-cal__panel-events {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

/* Event card within panel */
.tr-cal__event {
	display: flex;
	gap: 16px;
	background: #fff;
	border-radius: 12px;
	padding: 20px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.tr-cal__event-thumb {
	width: 120px;
	height: 90px;
	border-radius: 8px;
	object-fit: cover;
	flex-shrink: 0;
}

.tr-cal__event-body {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.tr-cal__event-category {
	display: inline-block;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	color: #2563eb;
}

.tr-cal__event-title {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	color: #111827;
}

.tr-cal__event-title a {
	color: inherit;
	text-decoration: none;
}

.tr-cal__event-title a:hover {
	color: #2563eb;
}

.tr-cal__event-meta {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}

.tr-cal__event-meta .tr-meta-item {
	font-size: 13px;
}

.tr-cal__event-excerpt {
	font-size: 14px;
	color: #6b7280;
	margin: 0;
}

.tr-cal__event-actions {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-top: 4px;
}

.tr-cal__loading {
	text-align: center;
	padding: 32px;
	color: #9ca3af;
}

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

	.tr-cal__event {
		flex-direction: column;
	}

	.tr-cal__event-thumb {
		width: 100%;
		height: 160px;
	}
}
