/* =====================================================================
   racunaj.me — content plugin, front end
   ---------------------------------------------------------------------
   Theme-independent. Colours read from the racunaj.me custom properties
   when the theme is active, and fall back to their own values otherwise,
   so the plugin looks right on any theme.
   ===================================================================== */


/* ---------- class chooser ---------- */
.rmc-razredi {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
	gap: 20px;
	margin-bottom: 52px;
}

.rmc-razred {
	position: relative;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	min-height: 190px;
	padding: 24px;
	border-radius: var(--rmc-radius);
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	backdrop-filter: blur(16px) saturate(140%);
	-webkit-backdrop-filter: blur(16px) saturate(140%);
	color: inherit;
	text-decoration: none;
	overflow: hidden;
	transition: transform 0.4s var(--rmc-ease), border-color 0.4s var(--rmc-ease), box-shadow 0.4s var(--rmc-ease);
}

.rmc-razred:hover,
.rmc-razred:focus-visible {
	transform: translateY(-6px);
	border-color: rgba(155, 92, 255, 0.34);
	box-shadow: 0 22px 50px -24px rgba(0, 0, 0, 0.9), 0 0 40px rgba(77, 124, 255, 0.28);
}

/*
 * The oversized numeral sat at top: -0.16em with the card on overflow: hidden,
 * so its top was cut off. It was also placed by `right` while carrying a
 * trailing letter-spacing: -0.06em, which shifts each glyph by its own side
 * bearing — that is why 6, 7, 8 and 9 did not line up with one another.
 *
 * Now: a fixed px offset inside the card, and a fixed 1em box with the digit
 * centred in it, so every card places its number identically whatever the digit.
 */
.rmc-razred__num {
	position: absolute;
	top: 14px;
	right: 16px;
	width: 1em;
	text-align: center;
	font-size: clamp(3.6rem, 5.4vw, 5.2rem);
	font-weight: 800;
	line-height: 1;
	letter-spacing: normal;
	font-variant-numeric: tabular-nums;
	background: var(--rmc-grad);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
	opacity: 0.3;
	pointer-events: none;
}

/*
 * The curve used to sit at bottom: 56px, which put it straight through the
 * class name. It belongs in the top-left corner instead: max-width keeps it in
 * the left half of the card, so it can never reach the numeral on the right.
 */
.rmc-razred__deco {
	position: absolute;
	left: 16px;
	top: 22px;
	width: 78px;
	max-width: 42%;
	height: auto;
	opacity: 0.3;
	pointer-events: none;
}

.rmc-razred__label {
	position: relative;
	font-size: 1.18rem;
	font-weight: 700;
	letter-spacing: -0.02em;
}

.rmc-razred__go {
	position: relative;
	margin-top: 10px;
	color: var(--rmc-violet);
	display: inline-flex;
	transition: transform 0.3s var(--rmc-ease);
}

.rmc-razred__go svg {
	width: 20px;
	height: 20px;
}

.rmc-razred:hover .rmc-razred__go {
	transform: translateX(6px);
}

/* ---------- groups and filter pills ---------- */
.rmc-groups {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 22px;
	margin-bottom: 52px;
}

.rmc-group {
	padding: 24px;
	border-radius: var(--rmc-radius);
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	backdrop-filter: blur(16px) saturate(140%);
	-webkit-backdrop-filter: blur(16px) saturate(140%);
}

.rmc-group.is-active {
	border-color: rgba(155, 92, 255, 0.4);
}

.rmc-group__title {
	font-size: 1.1rem;
	margin: 0 0 14px;
}

.rmc-group__title a {
	color: inherit;
	text-decoration: none;
}

.rmc-group__title a:hover {
	text-decoration: underline;
}

.rmc-group__note {
	color: var(--rmc-dim);
	font-size: 0.9rem;
	margin: 0;
}

.rmc-pills {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.rmc-pill {
	display: inline-block;
	padding: 8px 14px;
	border-radius: 999px;
	border: 1px solid var(--rmc-brd);
	background: rgba(255, 255, 255, 0.03);
	color: var(--rmc-soft);
	font-size: 0.88rem;
	text-decoration: none;
	transition: color 0.25s, border-color 0.25s, background 0.25s;
}

.rmc-pill:hover {
	color: var(--rmc-text);
	border-color: rgba(155, 92, 255, 0.4);
}

.rmc-pill.is-on {
	color: #fff;
	background: var(--rmc-grad);
	border-color: transparent;
}

/* ---------- item list (tests / areas inside a group) ---------- */
.rmc-items {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 16px;
	margin-bottom: 52px;
}

.rmc-item {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 20px 22px;
	border-radius: 16px;
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	backdrop-filter: blur(14px) saturate(140%);
	-webkit-backdrop-filter: blur(14px) saturate(140%);
	color: inherit;
	text-decoration: none;
	transition: transform 0.35s var(--rmc-ease), border-color 0.35s var(--rmc-ease), box-shadow 0.35s var(--rmc-ease);
}

.rmc-item:hover,
.rmc-item:focus-visible {
	transform: translateY(-4px);
	border-color: rgba(155, 92, 255, 0.34);
	box-shadow: 0 18px 40px -22px rgba(0, 0, 0, 0.9);
}

.rmc-item__name {
	font-weight: 600;
	font-size: 1.02rem;
}

.rmc-item__count {
	margin-left: auto;
	font-size: 0.8rem;
	color: var(--rmc-dim);
	white-space: nowrap;
}

.rmc-item__go {
	color: var(--rmc-violet);
	display: inline-flex;
	flex: none;
	transition: transform 0.3s var(--rmc-ease);
}

.rmc-item__go svg {
	width: 19px;
	height: 19px;
}

.rmc-item:hover .rmc-item__go {
	transform: translateX(4px);
}

/* ---------- sections and grid ---------- */
.rmc-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 22px;
}

/* ---------- cards ---------- */
.rmc-card {
	display: flex;
	flex-direction: column;
	border-radius: var(--rmc-radius);
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	backdrop-filter: blur(16px) saturate(140%);
	-webkit-backdrop-filter: blur(16px) saturate(140%);
	overflow: hidden;
	transition: transform 0.4s var(--rmc-ease), border-color 0.4s var(--rmc-ease);
}

.rmc-card:hover {
	transform: translateY(-4px);
	border-color: rgba(155, 92, 255, 0.3);
}

.rmc-card__body {
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	flex: 1;
}

.rmc-card__meta {
	display: flex;
	align-items: center;
	gap: 10px;
}

.rmc-num {
	font-family: var(--font-mono, ui-monospace, Menlo, monospace);
	font-size: 0.8rem;
	color: var(--rmc-cyan);
}

.rmc-badge {
	font-size: 0.7rem;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	padding: 4px 10px;
	border-radius: 999px;
	border: 1px solid var(--rmc-brd);
	color: var(--rmc-soft);
}

.rmc-badge--novo {
	color: #7ef0c2;
	border-color: rgba(126, 240, 194, 0.35);
}

.rmc-badge--preporuceno {
	color: #c79bff;
	border-color: rgba(199, 155, 255, 0.35);
}

.rmc-badge--vazno {
	color: #ffb37e;
	border-color: rgba(255, 179, 126, 0.35);
}

.rmc-card__title {
	font-size: 1.08rem;
	margin: 0;
	line-height: 1.3;
}

.rmc-card__title a {
	color: inherit;
	text-decoration: none;
}

.rmc-card__title a:hover {
	text-decoration: underline;
}

.rmc-card__desc {
	color: var(--rmc-dim);
	font-size: 0.91rem;
	margin: 0;
	flex: 1;
}

.rmc-card__foot {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
	margin-top: 4px;
}

.rmc-card__pages {
	color: var(--rmc-dim);
	font-size: 0.84rem;
}

.rmc-card__missing {
	color: var(--rmc-dim);
	font-size: 0.86rem;
	font-style: italic;
}

/* ---------- video facade ---------- */
.rmc-video {
	position: relative;
	aspect-ratio: 16 / 9;
	background: rgba(0, 0, 0, 0.45);
	overflow: hidden;
}

.rmc-video__btn {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
	display: block;
}

.rmc-video__btn img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* ---------- the tint over the poster ---------------------------------
 * YouTube thumbnails arrive in whatever colours their author chose —
 * coral, cyan, chalkboard green — and half a dozen of them side by side
 * pull the page away from its own palette. These two layers put them
 * back in it without hiding anything.
 *
 * Both live on the button, which is the poster: it covers exactly the
 * image and nothing else. front.js removes that button when the visitor
 * clicks, so the tint disappears with it — the iframe is never under a
 * purple sheet, and no JavaScript had to be changed to arrange it.
 */
.rmc-video__btn::before,
.rmc-video__btn::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
}

/*
 * The plain overlay, not the mix-blend-mode variant. `screen` lightens
 * whatever is beneath it, and these posters are already bright — it
 * washed the coral one out and left the chalkboard one looking foggy.
 * A flat wash at low alpha keeps every thumbnail readable.
 */
.rmc-video__btn::after {
	background: linear-gradient(135deg, rgba(41, 25, 105, 0.46), rgba(119, 50, 220, 0.28));
	opacity: 0.8;
	transition: opacity 0.22s ease;
}

/* A vignette rather than a tint: a little light in the middle, a little
   weight along the bottom, where the title sits directly underneath. */
.rmc-video__btn::before {
	box-shadow:
		inset 0 0 40px rgba(103, 73, 255, 0.18),
		inset 0 -40px 60px rgba(15, 10, 45, 0.34);
}

/* On approach the poster opens up — the photograph is what the visitor
   came to judge, and by now they are clearly looking at this one. */
.rmc-card:hover .rmc-video__btn::after,
.rmc-card:focus-within .rmc-video__btn::after {
	opacity: 0.55;
}

/*
 * Belt and braces. The button is gone by the time the iframe exists, so
 * this should never match — but if the facade is ever changed to keep the
 * poster around, the tint still gets out of the way rather than sitting
 * over a playing video.
 */
.rmc-video.is-playing .rmc-video__btn::before,
.rmc-video.is-playing .rmc-video__btn::after {
	display: none;
}

.rmc-video__play {
	/* Above both layers above. Without this the tint would paint over the
	   play icon — pseudo-elements come after every child in tree order,
	   and neither had a z-index to argue with. */
	z-index: 2;
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 62px;
	height: 62px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	background: var(--rmc-grad);
	color: #fff;
	box-shadow: 0 10px 30px -8px rgba(120, 90, 255, 0.7);
	transition: transform 0.35s var(--rmc-ease);
}

.rmc-video__play svg {
	width: 30px;
	height: 30px;
}

.rmc-video__btn:hover .rmc-video__play,
.rmc-video__btn:focus-visible .rmc-video__play {
	transform: translate(-50%, -50%) scale(1.08);
}

.rmc-video__time {
	position: absolute;
	right: 10px;
	bottom: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	background: rgba(0, 0, 0, 0.72);
	color: #fff;
	font-size: 0.76rem;
	pointer-events: none;
}

.rmc-video__frame {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.rmc-video--single {
	border-radius: var(--rmc-radius);
	margin-bottom: 16px;
}

/* ---------- pdf visuals ---------- */
/* A page, not a picture: the taller frame is what tells a document apart
   from a video card before a word is read. Was 16/10. */
.rmc-pdf-visual {
	position: relative;
	aspect-ratio: 4 / 5;
	display: grid;
	place-items: center;
	background: linear-gradient(160deg, rgba(30, 24, 74, 0.9), rgba(12, 10, 34, 0.95));
	overflow: hidden;
}

/* The pill states a fact about this document; stretched across the card it
   reads as a banner. The card body is a flex column, so it has to opt out
   of the stretch explicitly. */
.rmc-card__solutions {
	align-self: flex-start;
	width: fit-content;
}

.rmc-pdf-visual img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.rmc-pdf-icon {
	color: var(--rmc-cyan);
}

.rmc-pdf-icon svg {
	width: 54px;
	height: 54px;
}

.rmc-pdf-cover {
	border-radius: var(--rmc-radius);
	overflow: hidden;
	margin-bottom: 22px;
}

.rmc-pdf-cover img {
	width: 100%;
	height: auto;
	display: block;
}

/* ---------- areas ---------- */
.rmc-oblasti {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
	gap: 16px;
}

.rmc-oblast {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding: 20px;
	border-radius: 16px;
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	color: inherit;
	text-decoration: none;
	transition: transform 0.35s var(--rmc-ease), border-color 0.35s var(--rmc-ease);
}

.rmc-oblast:hover {
	transform: translateY(-4px);
	border-color: rgba(155, 92, 255, 0.34);
}

.rmc-oblast__no {
	font-size: 0.74rem;
	font-weight: 700;
	letter-spacing: 0.16em;
	color: var(--rmc-violet);
	opacity: 0.75;
}

.rmc-oblast__name {
	font-weight: 600;
}

.rmc-oblast__desc {
	color: var(--rmc-dim);
	font-size: 0.88rem;
}

.rmc-oblast__count {
	color: var(--rmc-cyan);
	font-size: 0.8rem;
}

/* ---------- buttons ---------- */
.rmc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 11px 20px;
	border-radius: 999px;
	font-size: 0.9rem;
	font-weight: 600;
	text-decoration: none;
	border: 1px solid transparent;
	transition: transform 0.3s var(--rmc-ease), box-shadow 0.3s var(--rmc-ease);
}

.rmc-btn--primary {
	background: var(--rmc-grad);
	color: #fff;
}

.rmc-btn--primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 14px 32px -12px rgba(120, 90, 255, 0.75);
}

.rmc-btn--ghost {
	background: rgba(255, 255, 255, 0.05);
	border-color: var(--rmc-brd);
	color: var(--rmc-text);
}

.rmc-btn--ghost:hover {
	transform: translateY(-2px);
	border-color: rgba(155, 92, 255, 0.4);
}

.rmc-actions,
.rmc-back {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin: 26px 0;
}

.rmc-single__external {
	margin: 0 0 26px;
	font-size: 0.9rem;
}

.rmc-single__external a {
	color: var(--rmc-cyan);
}

/* ---------- misc ---------- */
.rmc-content {
	color: var(--rmc-soft);
	line-height: 1.7;
	margin-bottom: 30px;
}

.rmc-pagination {
	margin: 30px 0;
}

/* ---------- external-exam band ----------------------------------------
 * A full-width panel with its own motif, so it does not read as a fifth
 * class card sitting in the same grid.
 */
.rmc-extcta {
	position: relative;
	overflow: hidden;
	padding: clamp(30px, 4.4vw, 52px);
	border-radius: var(--rmc-radius);
	background:
		radial-gradient(720px 340px at 88% 6%, rgba(82, 226, 251, 0.16), transparent 62%),
		radial-gradient(620px 320px at 6% 100%, rgba(155, 92, 255, 0.2), transparent 60%),
		var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	backdrop-filter: blur(16px) saturate(140%);
	-webkit-backdrop-filter: blur(16px) saturate(140%);
}

/* A gradient hairline, drawn as a mask so the fill stays translucent. */
.rmc-extcta::before {
	content: "";
	position: absolute;
	inset: -1px;
	border-radius: inherit;
	padding: 1.5px;
	background: var(--rmc-grad);
	-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
	mask-composite: exclude;
	opacity: 0.5;
	pointer-events: none;
}

.rmc-extcta__deco {
	position: absolute;
	top: 50%;
	right: clamp(18px, 3vw, 44px);
	transform: translateY(-50%);
	width: clamp(150px, 20vw, 240px);
	opacity: 0.42;
	pointer-events: none;
}

.rmc-extcta__deco svg {
	display: block;
	width: 100%;
	height: auto;
}

.rmc-extcta__body {
	position: relative;
	/* Keeps the copy clear of the curve on the right. */
	max-width: min(100%, 46ch);
}

.rmc-extcta__title {
	font-size: clamp(1.5rem, 2.7vw, 2.2rem);
	line-height: 1.18;
	letter-spacing: -0.028em;
	margin: 12px 0 12px;
}

.rmc-extcta__text {
	color: var(--rmc-soft);
	line-height: 1.72;
	margin: 0 0 24px;
	max-width: 52ch;
}

/* Below this the curve and the text would fight for the same space. */
@media (max-width: 820px) {
	.rmc-extcta__deco {
		position: static;
		transform: none;
		display: block;
		width: 160px;
		margin-bottom: 18px;
	}

	.rmc-extcta__body { max-width: none; }
}

/* ---------- social CTA ---------- */
.rmc-social {
	margin-top: 60px;
	padding: clamp(32px, 5vw, 56px);
	border-radius: var(--rmc-radius);
	background:
		radial-gradient(600px 300px at 20% 0%, rgba(155, 92, 255, 0.22), transparent 62%),
		var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	text-align: center;
}

/* Short version for the foot of the lesson pages. */
.rmc-social--compact {
	margin-top: 40px;
	padding: clamp(24px, 3vw, 34px);
}

.rmc-social--compact .rmc-social__title {
	font-size: clamp(1.1rem, 1.9vw, 1.4rem);
	margin-bottom: 18px;
}

.rmc-social__title {
	font-size: clamp(1.4rem, 2.6vw, 2rem);
	margin: 0 0 12px;
	letter-spacing: -0.02em;
}

.rmc-social__text {
	color: var(--rmc-soft);
	margin: 0 auto 26px;
	max-width: 52ch;
}

.rmc-social__actions {
	display: flex;
	gap: 14px;
	justify-content: center;
	flex-wrap: wrap;
}

.rmc-social__btn {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 13px 24px;
	border-radius: 999px;
	font-weight: 600;
	text-decoration: none;
	color: var(--rmc-text);
	background: rgba(255, 255, 255, 0.05);
	border: 1px solid var(--rmc-brd);
	transition: transform 0.3s var(--rmc-ease), box-shadow 0.3s var(--rmc-ease), border-color 0.3s;
}

.rmc-social__btn svg {
	width: 20px;
	height: 20px;
}

/* Discreet brand accents — no big logos, still clearly each platform. */
.rmc-social__btn--yt svg {
	color: #ff4d4d;
}

.rmc-social__btn--yt:hover {
	transform: translateY(-2px);
	border-color: rgba(255, 77, 77, 0.45);
	box-shadow: 0 0 30px rgba(255, 77, 77, 0.2);
}

.rmc-social__btn--tt svg {
	color: #4de2ff;
}

.rmc-social__btn--tt:hover {
	transform: translateY(-2px);
	border-color: rgba(255, 92, 214, 0.45);
	box-shadow: 0 0 30px rgba(255, 92, 214, 0.2);
}

/* ---------- class section (IX-c) ---------- */
/*
 * Quieter than the marketing pages: less glow, more contrast on the text.
 * The weekly schedule is a grid of day cards rather than a table, so it
 * reflows to one column on a phone instead of scrolling sideways.
 */
.rmc-week {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
	gap: 16px;
}

.rmc-day {
	padding: 20px;
	border-radius: 16px;
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
}

.rmc-day__title {
	font-size: 0.86rem;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--rmc-cyan);
	margin: 0 0 14px;
}

.rmc-day__empty {
	color: var(--rmc-dim);
	font-size: 0.86rem;
	margin: 0;
}

.rmc-lessons {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 10px;
}

.rmc-lesson {
	display: flex;
	align-items: baseline;
	gap: 10px;
	padding-bottom: 10px;
	border-bottom: 1px solid var(--rmc-brd);
}

.rmc-lesson:last-child {
	padding-bottom: 0;
	border-bottom: 0;
}

.rmc-lesson__no {
	flex: none;
	width: 22px;
	font-family: var(--font-mono, ui-monospace, Menlo, monospace);
	font-size: 0.78rem;
	color: var(--rmc-dim);
}

.rmc-lesson__body {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.rmc-lesson__name { font-weight: 600; font-size: 0.96rem; }
.rmc-lesson__meta { color: var(--rmc-dim); font-size: 0.8rem; }

.rmc-lesson__time {
	flex: none;
	font-size: 0.78rem;
	color: var(--rmc-soft);
	font-family: var(--font-mono, ui-monospace, Menlo, monospace);
}

/* ---------- teacher / lesson cards ---------- */
.rmc-cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
	gap: 16px;
}

.rmc-tcard {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding: 20px;
	border-radius: 16px;
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
}

.rmc-tcard__icon { color: var(--rmc-cyan); margin-bottom: 6px; }
.rmc-tcard__icon svg { width: 26px; height: 26px; }

.rmc-tcard__name { font-size: 1.04rem; margin: 0; }
.rmc-tcard__subject { color: var(--rmc-cyan); font-size: 0.86rem; margin: 0; }
.rmc-tcard__when { color: var(--rmc-soft); font-size: 0.92rem; margin: 0; }
.rmc-tcard__place { color: var(--rmc-dim); font-size: 0.86rem; margin: 0; }
.rmc-tcard__note { color: var(--rmc-dim); font-size: 0.86rem; margin: 0; }
.rmc-tcard__contact { color: var(--rmc-dim); font-size: 0.84rem; margin: 0; word-break: break-all; }

/*
 * Dopunska vs dodatna: a left edge and a quiet label, not red/green blocks —
 * neither kind is a warning and neither is a success.
 */
.rmc-kind {
	font-size: 0.68rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--rmc-dim);
}

.rmc-tcard--dopunska { border-left: 3px solid rgba(99, 200, 245, 0.55); }
.rmc-tcard--dopunska .rmc-kind { color: #7fd4f5; }

.rmc-tcard--dodatna { border-left: 3px solid rgba(180, 107, 255, 0.55); }
.rmc-tcard--dodatna .rmc-kind { color: #c79bff; }

.rmc-status {
	margin: 0;
	font-size: 0.8rem;
	font-weight: 600;
}

.rmc-status--promijenio { color: #ffcf8a; }
.rmc-status--otkazano { color: #ff9ba6; }

/* ---------- notices ---------- */
.rmc-notices {
	display: grid;
	gap: 14px;
}

.rmc-notice {
	padding: 20px 22px;
	border-radius: 16px;
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
	border-left-width: 3px;
}

.rmc-notice--info { border-left-color: rgba(99, 200, 245, 0.5); }
.rmc-notice--vazno { border-left-color: rgba(180, 107, 255, 0.6); }
.rmc-notice--hitno { border-left-color: rgba(255, 155, 166, 0.7); }

.rmc-notice__top {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 8px;
}

.rmc-notice__tag {
	font-size: 0.68rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--rmc-soft);
}

.rmc-notice--hitno .rmc-notice__tag { color: #ff9ba6; }
.rmc-notice--vazno .rmc-notice__tag { color: #c79bff; }

.rmc-notice__date {
	margin-left: auto;
	font-size: 0.78rem;
	color: var(--rmc-dim);
}

.rmc-notice__title { font-size: 1.06rem; margin: 0 0 6px; }
.rmc-notice__text { color: var(--rmc-soft); font-size: 0.93rem; }
.rmc-notice__text p { margin: 0 0 8px; }

/* ---------- student corner ---------- */
.rmc-submit {
	display: flex;
	gap: 26px;
	align-items: flex-start;
	padding: clamp(24px, 4vw, 38px);
	border-radius: var(--rmc-radius);
	background: var(--rmc-glass);
	border: 1px solid var(--rmc-brd);
}

.rmc-submit__icon {
	flex: none;
	width: 68px;
	height: 68px;
	border-radius: 20px;
	display: grid;
	place-items: center;
	background: linear-gradient(140deg, rgba(77, 124, 255, 0.24), rgba(155, 92, 255, 0.24));
	border: 1px solid var(--rmc-brd);
	color: var(--rmc-cyan);
}

.rmc-submit__icon svg { width: 30px; height: 30px; }
.rmc-submit__body p { color: var(--rmc-soft); margin: 0 0 10px; }

.rmc-steps {
	color: var(--rmc-soft);
	line-height: 1.8;
	margin: 0 0 18px;
	padding-left: 20px;
}

.rmc-about-photo {
	border-radius: var(--rmc-radius);
	overflow: hidden;
	margin-bottom: 44px;
	border: 1px solid var(--rmc-brd);
}

.rmc-about-photo img { display: block; width: 100%; height: auto; }

/* ---------- accessibility ---------- */
.rmc-page :focus-visible {
	outline: 2px solid var(--rmc-cyan);
	outline-offset: 3px;
	border-radius: 6px;
}

.rmc-page .screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

@media (max-width: 680px) {
	.rmc-grid,
	.rmc-razredi,
	.rmc-groups,
	.rmc-oblasti,
	.rmc-items,
	.rmc-cards,
	.rmc-week {
		grid-template-columns: 1fr;
	}

	.rmc-card__foot .rmc-btn {
		flex: 1 1 auto;
	}

	/* Stack the icon above the text so nothing is squeezed. */
	.rmc-submit {
		flex-direction: column;
		gap: 18px;
	}
}

/* =====================================================================
   ONE ASSESSMENT, WITH ITS VIDEOS
   ---------------------------------------------------------------------
   The class page used to be a row of links. These blocks put the videos
   themselves on it, one section per kontrolni, so the first thing a
   pupil sees is a thumbnail rather than another menu.
   ===================================================================== */

.rmc-assess {
	margin-top: clamp(26px, 3.4vw, 40px);
}

.rmc-assess__head {
	display: flex;
	align-items: flex-start;
	gap: 16px;
	margin-bottom: 18px;
}

/* 01, 02, 03 — decoration next to a heading that already says which one
   this is, so it is hidden from assistive technology in the markup. */
.rmc-assess__num {
	flex: none;
	display: grid;
	place-items: center;
	width: 46px;
	height: 46px;
	border-radius: 14px;
	font-size: 0.94rem;
	font-weight: 700;
	letter-spacing: 0.02em;
	color: var(--neon-cyan, #52e2fb);
	border: 1px solid rgba(82, 226, 251, 0.28);
	background: linear-gradient(150deg, rgba(82, 226, 251, 0.12), rgba(155, 92, 255, 0.14));
}

.rmc-assess__ident { min-width: 0; }

.rmc-assess__eyebrow {
	display: block;
	margin-bottom: 5px;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--neon-cyan, #52e2fb);
}

.rmc-assess__title {
	margin: 0;
	font-size: clamp(1.12rem, 2vw, 1.4rem);
	line-height: 1.25;
	letter-spacing: -0.015em;
}

.rmc-assess__title a {
	color: inherit;
	text-decoration: none;
}

.rmc-assess__title a:hover { color: var(--neon-cyan, #52e2fb); }

.rmc-assess__lead {
	margin: 7px 0 0;
	font-size: 0.92rem;
	line-height: 1.6;
	color: var(--text-dim, #9096c2);
}

/*
 * Two per row, and a ceiling on how wide one may get. Without the ceiling a
 * kontrolni with a single video would stretch that card across the whole
 * screen, and the same video would look like a different kind of thing
 * depending on how many others happened to sit beside it.
 */
.rmc-assess__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: clamp(16px, 2vw, 24px);
	align-items: start;
}

.rmc-assess__grid > * { max-width: 560px; }

.rmc-card__kind {
	font-size: 0.74rem;
	font-weight: 600;
	letter-spacing: 0.09em;
	text-transform: uppercase;
	color: var(--text-dim, #9096c2);
}

.rmc-badge--group {
	color: var(--neon-cyan, #52e2fb);
	border-color: rgba(82, 226, 251, 0.34);
	background: rgba(82, 226, 251, 0.09);
}

@media (max-width: 900px) {

	.rmc-assess__grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.rmc-assess__grid > * { max-width: none; }
}

@media (max-width: 460px) {

	.rmc-assess__head { gap: 12px; }

	.rmc-assess__num {
		width: 40px;
		height: 40px;
		font-size: 0.86rem;
	}
}

@media (prefers-reduced-motion: reduce) {

	.rmc-video__btn::after,
	.rmc-video__play {
		transition: none;
	}

	.rmc-video__btn:hover .rmc-video__play,
	.rmc-video__btn:focus-visible .rmc-video__play {
		transform: translate(-50%, -50%);
	}
}

/* ---------- the rest of the channels ----------
 * Named rows rather than more buttons: two identical TikTok marks side by
 * side would leave a visitor guessing which account each one opens. */
.rmc-social__more {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px;
	margin: 18px 0 0;
	padding: 0;
	list-style: none;
}

.rmc-social__link {
	display: flex;
	align-items: center;
	gap: 11px;
	/* 44 px is the smallest target a thumb hits reliably. */
	min-height: 44px;
	padding: 8px 18px 8px 12px;
	border-radius: 999px;
	text-decoration: none;
	color: var(--text-soft, #c3c7e8);
	border: 1px solid var(--glass-brd, rgba(255, 255, 255, 0.1));
	background: rgba(15, 12, 42, 0.7);
	transition: color 0.22s ease, border-color 0.22s ease;
}

.rmc-social__link:hover {
	color: var(--text, #eef0ff);
	border-color: rgba(82, 226, 251, 0.5);
}

.rmc-social__link:focus-visible {
	outline: 2px solid var(--neon-cyan, #52e2fb);
	outline-offset: 2px;
}

.rmc-social__ico {
	display: grid;
	place-items: center;
	flex: none;
	width: 28px;
	height: 28px;
	color: var(--neon-cyan, #52e2fb);
}

.rmc-social__ico svg { width: 20px; height: 20px; }

.rmc-social__txt {
	display: flex;
	flex-direction: column;
	gap: 1px;
	min-width: 0;
	text-align: left;
	line-height: 1.3;
}

.rmc-social__txt strong {
	font-size: 0.92rem;
	font-weight: 700;
	color: var(--text, #eef0ff);
}

.rmc-social__txt span {
	font-size: 0.76rem;
	color: var(--text-dim, #9096c2);
}

/* The handle beside a footer mark, for the same reason. */
.footer-social__link {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	min-height: 44px;
	padding: 0 10px;
	border-radius: 999px;
}

.footer-social__tag {
	font-size: 0.76rem;
	white-space: nowrap;
	color: var(--text-dim, #9096c2);
}

@media (max-width: 480px) {

	/* Full width apiece: "Udruženje nastavnika matematike Crne Gore" has no
	   good place to break in half a row. */
	.rmc-social__more { flex-direction: column; }
	.rmc-social__link { width: 100%; }

	.footer-social__tag { display: none; }
}

/* ---------- a lesson that is not filmed yet ----------
 * Same footprint as a video card, so a row of four keeps its rhythm — and
 * plainly not a video: no play button, no thumbnail, nothing requested from
 * YouTube. */
.rmc-video--soon {
	position: relative;
	display: grid;
	place-items: center;
	gap: 10px;
	aspect-ratio: 16 / 9;
	background:
		radial-gradient(120% 100% at 50% 0%, rgba(82, 226, 251, 0.1), transparent 60%),
		linear-gradient(160deg, rgba(30, 24, 74, 0.92), rgba(12, 10, 34, 0.96));
	border-bottom: 1px solid var(--rmc-brd, rgba(255, 255, 255, 0.1));
}

.rmc-video__soonmark {
	display: grid;
	place-items: center;
	width: 52px;
	height: 52px;
	border-radius: 50%;
	/* Dimmed on purpose: it reads as an icon that is waiting, not one that
	   has failed to load. */
	color: rgba(82, 226, 251, 0.6);
	border: 1px solid rgba(137, 101, 255, 0.35);
	background: rgba(15, 12, 42, 0.7);
	animation: rmc-soon-pulse 4.5s ease-in-out infinite;
}

.rmc-video__soonmark svg { width: 24px; height: 24px; }

.rmc-video__soontext {
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--rmc-dim, #9096c2);
}

@keyframes rmc-soon-pulse {
	0%, 100% { box-shadow: 0 0 0 0 rgba(82, 226, 251, 0); }
	50%      { box-shadow: 0 0 22px -4px rgba(82, 226, 251, 0.45); }
}

@media (prefers-reduced-motion: reduce) {

	/* The glow stays, at a settled value; only the breathing stops. */
	.rmc-video__soonmark {
		animation: none;
		box-shadow: 0 0 18px -6px rgba(82, 226, 251, 0.35);
	}
}
