/* Interactive Hebrew/Gregorian calendar HUB (lookup intent).
   Separate from assets/calendar/* which powers the printable /dl/ page. */

.in4u-calhub {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 10px;
	padding: 16px;
	margin: 16px 0;
	font-family: inherit;
	color: #212529;
}

/* --- Today strip --- */
.in4u-calhub-today {
	background: linear-gradient(135deg, #2271b1, #1a5a8f);
	color: #fff;
	border-radius: 8px;
	padding: 14px 18px;
	margin-bottom: 16px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 18px;
	line-height: 1.5;
}

.in4u-calhub-today .lbl { font-size: 13px; opacity: 0.85; }
.in4u-calhub-today .greg { font-size: 20px; font-weight: 700; }
.in4u-calhub-today .heb { font-size: 20px; font-weight: 700; }
.in4u-calhub-today .sep { opacity: 0.5; }
.in4u-calhub-today .extra { font-size: 14px; opacity: 0.95; width: 100%; }
.in4u-calhub-today .extra b { font-weight: 700; }

/* --- Control bar --- */
.in4u-calhub-bar {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 10px;
	align-items: center;
	margin-bottom: 14px;
	padding-bottom: 12px;
	border-bottom: 1px solid #f0f0f0;
}

.in4u-calhub-nav {
	display: flex;
	align-items: center;
	gap: 6px;
}

.in4u-calhub-btn {
	padding: 7px 14px;
	border: 1px solid #2271b1;
	border-radius: 6px;
	background: #fff;
	color: #2271b1;
	font-size: 14px;
	font-family: inherit;
	cursor: pointer;
	transition: background 0.15s, color 0.15s;
}

.in4u-calhub-btn:hover { background: #eaf2fa; }
.in4u-calhub-btn.is-primary { background: #2271b1; color: #fff; }
.in4u-calhub-btn.is-primary:hover { filter: brightness(0.95); }

.in4u-calhub-arrow {
	width: 38px;
	height: 38px;
	padding: 0;
	font-size: 20px;
	line-height: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.in4u-calhub-bar select {
	padding: 7px 10px;
	border: 1px solid #ced4da;
	border-radius: 6px;
	background: #fff;
	font-size: 14px;
	font-family: inherit;
	min-width: 96px;
}

.in4u-calhub-toggles {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	align-items: center;
	margin-inline-start: auto;
}

.in4u-calhub-toggle {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	color: #495057;
	margin: 0;
	cursor: pointer;
}

.in4u-calhub-print {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 7px 14px;
	border-radius: 6px;
	background: #198754;
	color: #fff;
	font-size: 14px;
	text-decoration: none;
	white-space: nowrap;
}

.in4u-calhub-print:hover { filter: brightness(0.95); color: #fff; }

/* --- Layout: grid + side panel --- */
.in4u-calhub-main {
	display: grid;
	grid-template-columns: 1fr 240px;
	gap: 16px;
	align-items: start;
}

.in4u-calhub-render { min-width: 0; }

.in4u-calhub-side {
	background: #f8f9fa;
	border: 1px solid #eceef0;
	border-radius: 8px;
	padding: 12px 14px;
}

.in4u-calhub-side h3 {
	margin: 0 0 10px;
	font-size: 15px;
	font-weight: 700;
	color: #212529;
}

.in4u-calhub-side ul { list-style: none; margin: 0; padding: 0; }

.in4u-calhub-side li {
	display: flex;
	gap: 8px;
	padding: 6px 0;
	border-bottom: 1px dashed #e3e6e9;
	font-size: 13px;
	line-height: 1.35;
}

.in4u-calhub-side li:last-child { border-bottom: 0; }
.in4u-calhub-side .d { flex: 0 0 34px; font-weight: 700; color: #2271b1; }
.in4u-calhub-side .n { color: #343a40; }
.in4u-calhub-side .empty { color: #6c757d; font-size: 13px; }

/* --- Month grid --- */
.in4u-calhub-month-title {
	text-align: center;
	margin: 0 0 12px;
	font-size: 22px;
	font-weight: 700;
	color: #212529;
}

.in4u-calhub-table {
	width: 100%;
	border-collapse: collapse;
	table-layout: fixed;
	background: #fff;
}

.in4u-calhub-table th,
.in4u-calhub-table td {
	border: 1px solid #dde1e5;
	padding: 4px;
	vertical-align: top;
	text-align: center;
}

.in4u-calhub-table th {
	background: #f1f3f5;
	font-weight: 700;
	padding: 8px 4px;
	font-size: 14px;
	color: #343a40;
}

.in4u-calhub-table td {
	height: 78px;
	width: calc(100% / 7);
}

.in4u-calhub-table td.empty { background: #fafbfc; }
.in4u-calhub-table td.shabbat { background: #fff8e1; }
.in4u-calhub-table td.chag { background: #ffe8e8; }

.in4u-calhub-table td.today {
	outline: 2px solid #2271b1;
	outline-offset: -2px;
	background: #eaf2fa;
}

.in4u-calhub-daynum { font-weight: 700; font-size: 17px; color: #212529; }
.in4u-calhub-hebdate { font-size: 12px; color: #6c757d; margin-top: 2px; }

.in4u-calhub-evts { font-size: 10px; color: #495057; margin-top: 3px; line-height: 1.2; }
.in4u-calhub-evt {
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* --- Year view (12 mini months) --- */
.in4u-calhub-year-title {
	text-align: center;
	margin: 0 0 16px;
	font-size: 24px;
	font-weight: 700;
}

.in4u-calhub-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 12px;
}

.in4u-calhub-grid .in4u-calhub-month-title { font-size: 14px; margin: 4px 0 6px; }
.in4u-calhub-grid .in4u-calhub-table td { height: 30px; }
.in4u-calhub-grid .in4u-calhub-daynum { font-size: 11px; }
.in4u-calhub-grid .in4u-calhub-hebdate,
.in4u-calhub-grid .in4u-calhub-evts { display: none; }

.in4u-calhub-status { font-size: 13px; color: #6c757d; }

/* --- Responsive --- */
@media (max-width: 860px) {
	.in4u-calhub-main { grid-template-columns: 1fr; }
	.in4u-calhub-side { order: 2; }
}

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

@media (max-width: 560px) {
	.in4u-calhub-toggles { margin-inline-start: 0; width: 100%; }
	.in4u-calhub-table td { height: 58px; }
	.in4u-calhub-daynum { font-size: 15px; }
	.in4u-calhub-hebdate { font-size: 10px; }
	.in4u-calhub-evts { display: none; }
}

@media (max-width: 480px) {
	.in4u-calhub-grid { grid-template-columns: 1fr; }
}
