/*
 * St Mark Confession Nights
 *
 * Two rules govern this file:
 *
 * 1. LIGHT ONLY. There is no dark scheme. The church site is a light site,
 *    and the page must look identical on a phone set to dark mode. Every
 *    colour is stated outright so nothing is inherited from a theme or from
 *    the operating system.
 *
 * 2. IT MUST WIN. This renders inside the live theme, which styles bare
 *    buttons, headings and inputs with its own colours. Every rule is
 *    anchored on .smc and the properties the theme fights over carry
 *    !important. That is deliberate, not laziness.
 *
 * Tokens read off stmark.com.au: Roboto, #141519 panels, #E36F4E accent,
 * #00CE1B the green already used to colour code the liturgies.
 */

.smc {
	--smc-panel: #141519;
	--smc-ink: #1e2024;
	--smc-ink-2: #4a4f55;
	--smc-ink-3: #7c838a;
	--smc-accent: #e36f4e;
	--smc-blue: #12288f;   /* the deep blue of the church crest, sampled from the logo */
	--smc-field: #c9cdd1;
	--smc-page: #ffffff;

	--smc-good: #1b6e3a;
	--smc-good-dot: #00ce1b;
	--smc-warn: #b0532a;
	--smc-warn-dot: #e36f4e;
	--smc-busy: #a6392c;
	--smc-busy-dot: #d64c3c;
	--smc-off: #7c838a;
	--smc-off-dot: #c9cdd1;

	font-family: Roboto, Arial, Helvetica, sans-serif !important;
	font-size: 16px;
	line-height: 1.5;
	color: var(--smc-ink) !important;
	background: transparent;
	max-width: 1000px;
	margin: 0 auto;
	padding: 0 4px;
	text-align: left;
}

.smc *,
.smc *::before,
.smc *::after { box-sizing: border-box; }

.smc p { margin: 0; }

.smc img { max-width: 100%; }

/* ---------- crest header, centred ---------- */

.smc .smc-crest {
	text-align: center !important;
	margin: 0 auto;
	max-width: 640px;
}

.smc .smc-logo {
	display: block !important;
	margin: 0 auto 20px !important;
	width: auto !important;
	height: auto !important;
	max-height: 150px;
	max-width: 220px;
	border-radius: 0 !important;
	float: none !important;
}

@media (max-width: 600px) {
	.smc .smc-logo { max-height: 120px; max-width: 180px; margin-bottom: 16px !important; }
}

.smc .smc-title {
	display: block !important;
	font-family: Roboto, Arial, Helvetica, sans-serif !important;
	font-weight: 500 !important;
	font-size: clamp(21px, 3.4vw, 28px) !important;
	line-height: 1.25 !important;
	letter-spacing: 2.4px !important;
	text-transform: uppercase !important;
	text-align: center !important;
	color: var(--smc-ink) !important;
	background: none !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	text-decoration: none !important;
}

.smc .smc-who {
	text-align: center !important;
	font-size: 19px;
	font-weight: 700;
	color: var(--smc-ink) !important;
	letter-spacing: -.2px;
	margin: 12px 0 0 !important;
}

.smc .smc-say {
	text-align: center !important;
	font-size: 16px;
	line-height: 1.55;
	color: var(--smc-ink-2) !important;
	max-width: 46ch;
	margin: 14px auto 0 !important;
}

.smc .smc-say--quiet {
	font-size: 14.5px;
	color: var(--smc-ink-3) !important;
	margin-top: 6px !important;
}

/* ---------- last updated ---------- */

.smc .smc-stamp {
	display: flex;
	align-items: flex-start;
	justify-content: center;
	text-align: center;
	gap: 10px;
	margin: 26px auto 0 !important;
	font-size: 13.5px;
	line-height: 1.5;
	color: var(--smc-ink-2) !important;
}

.smc .smc-pulse {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--smc-good-dot);
	flex: none;
	margin-top: 7px;
}

.smc .smc-stamp--cold .smc-pulse { background: var(--smc-busy-dot); }
.smc .smc-stamp-text b { color: var(--smc-ink) !important; font-weight: 700; }

/* ---------- the nights ---------- */

.smc .smc-nights {
	display: grid;
	gap: 52px 48px;
	margin-top: 48px;
	grid-template-columns: repeat(auto-fit, minmax(268px, 1fr));
	text-align: left;
}

@media (max-width: 600px) {
	.smc .smc-nights { gap: 44px; margin-top: 36px; }
}

.smc .smc-card { min-width: 0; }

.smc .smc-card-top {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 14px;
}

.smc .smc-day {
	font-weight: 900 !important;
	font-size: 30px !important;
	line-height: 1.05 !important;
	letter-spacing: -.4px;
	color: var(--smc-ink) !important;
}

.smc .smc-date {
	font-size: 13.5px;
	color: var(--smc-ink-3) !important;
	white-space: nowrap;
	font-weight: 400;
}

.smc .smc-time {
	font-size: 21px;
	font-weight: 700;
	margin-top: 10px !important;
	line-height: 1.25;
	letter-spacing: -.2px;
}

.smc .smc-card--good .smc-time { color: var(--smc-good) !important; }
.smc .smc-card--warn .smc-time { color: var(--smc-warn) !important; }
.smc .smc-card--busy .smc-time { color: var(--smc-busy) !important; }
.smc .smc-card--off  .smc-time { color: var(--smc-off) !important; }
.smc .smc-time--struck { text-decoration: line-through; text-decoration-thickness: 2px; }

.smc .smc-status {
	display: flex;
	align-items: flex-start;
	gap: 9px;
	margin-top: 11px;
	font-size: 14.5px;
	font-weight: 500;
	line-height: 1.4;
}

.smc .smc-card--good .smc-status { color: var(--smc-good) !important; }
.smc .smc-card--warn .smc-status { color: var(--smc-warn) !important; }
.smc .smc-card--busy .smc-status { color: var(--smc-busy) !important; }
.smc .smc-card--off  .smc-status { color: var(--smc-off) !important; }

.smc .smc-dot {
	width: 11px;
	height: 11px;
	border-radius: 50%;
	flex: none;
	margin-top: 5px;
}

.smc .smc-card--good .smc-dot { background: var(--smc-good-dot); }
.smc .smc-card--warn .smc-dot { background: var(--smc-warn-dot); }
.smc .smc-card--busy .smc-dot { background: var(--smc-busy-dot); }
.smc .smc-card--off  .smc-dot { background: var(--smc-off-dot); }

.smc .smc-status-text small {
	display: block;
	font-weight: 400;
	font-size: 13.5px;
	color: var(--smc-ink-3) !important;
	margin-top: 4px;
	font-variant-numeric: tabular-nums;
}

.smc .smc-note {
	margin: 14px 0 0 !important;
	padding-left: 15px;
	border-left: 3px solid var(--smc-blue);
	font-size: 13.5px;
	line-height: 1.5;
	color: var(--smc-ink-2) !important;
	font-style: italic;
}

.smc .smc-note-label {
	display: block;
	font-style: normal;
	font-size: 10.5px;
	font-weight: 500;
	letter-spacing: 1.4px;
	text-transform: uppercase;
	color: var(--smc-blue) !important;
	margin-bottom: 3px;
}

/* ---------- buttons. The theme colours bare buttons, so these must win. ---------- */

.smc .smc-btn,
.smc button.smc-btn,
.smc input[type="submit"].smc-btn {
	display: block !important;
	font-family: Roboto, Arial, Helvetica, sans-serif !important;
	font-size: 12px !important;
	font-weight: 500 !important;
	letter-spacing: 1.7px !important;
	text-transform: uppercase !important;
	background: var(--smc-panel) !important;
	background-color: var(--smc-panel) !important;
	background-image: none !important;
	color: #ffffff !important;
	border: 0 !important;
	border-radius: 8px !important;
	box-shadow: none !important;
	text-shadow: none !important;
	padding: 15px 22px !important;
	margin: 20px 0 0 !important;
	width: 100% !important;
	max-width: none !important;
	line-height: 1.3 !important;
	cursor: pointer;
	text-decoration: none !important;
	transition: background-color .15s ease;
}

.smc .smc-btn:hover,
.smc button.smc-btn:hover,
.smc .smc-btn:focus,
.smc button.smc-btn:focus {
	background: var(--smc-blue) !important;
	background-color: var(--smc-blue) !important;
	color: #ffffff !important;
}

.smc .smc-btn:focus-visible { outline: 2px solid var(--smc-accent) !important; outline-offset: 3px; }
.smc .smc-btn--big { max-width: 340px !important; margin: 44px 0 56px !important; }

.smc .smc-link,
.smc button.smc-link {
	display: inline !important;
	font-family: inherit !important;
	font-size: 13.5px !important;
	font-weight: 400 !important;
	letter-spacing: normal !important;
	text-transform: none !important;
	background: none !important;
	background-color: transparent !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	padding: 0 !important;
	margin: 0 !important;
	width: auto !important;
	cursor: pointer;
	color: var(--smc-ink-3) !important;
	text-decoration: underline !important;
	text-underline-offset: 4px;
}

.smc .smc-link:hover { color: var(--smc-busy) !important; background: none !important; }

/* ---------- signup, underline fields rather than boxes ---------- */

.smc .smc-form { display: none; margin-top: 20px; }
.smc .smc-form.is-open { display: block; }

.smc .smc-field { margin: 0 0 20px !important; }

.smc .smc-field label {
	display: block;
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 1.4px;
	text-transform: uppercase;
	color: var(--smc-ink-3) !important;
	margin-bottom: 4px;
}

.smc .smc-field input,
.smc .smc-row-times input,
.smc .smc-row-times select,
.smc .smc-row-note input {
	font-family: Roboto, Arial, Helvetica, sans-serif !important;
	font-size: 17px !important;
	color: var(--smc-ink) !important;
	width: 100% !important;
	background: transparent !important;
	background-color: transparent !important;
	border: 0 !important;
	border-bottom: 2px solid var(--smc-field) !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	padding: 7px 0 9px !important;
	margin: 0 !important;
	height: auto !important;
}

.smc .smc-field input:focus,
.smc .smc-row-times input:focus,
.smc .smc-row-times select:focus,
.smc .smc-row-note input:focus {
	outline: 0 !important;
	border-bottom-color: var(--smc-accent) !important;
}

.smc .smc-privacy {
	font-size: 12.5px;
	line-height: 1.5;
	color: var(--smc-ink-3) !important;
}

/* Honeypot, off screen rather than display:none which some bots detect. */
.smc .smc-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.smc .smc-confirmed {
	margin-top: 20px;
	padding-left: 17px;
	border-left: 3px solid var(--smc-good-dot);
}

.smc .smc-confirmed p {
	font-size: 15px;
	font-weight: 700;
	color: var(--smc-good) !important;
	line-height: 1.4;
}

.smc .smc-confirmed small {
	display: block;
	font-weight: 400;
	color: var(--smc-ink-2) !important;
	font-size: 13.5px;
	margin: 6px 0 10px;
	line-height: 1.5;
}

.smc .smc-confirmed form { margin: 0 !important; }

/* ---------- closing note ---------- */

.smc .smc-closing { margin-top: 60px; }

.smc .smc-closing h3 {
	font-family: Roboto, Arial, Helvetica, sans-serif !important;
	font-size: 11px !important;
	font-weight: 500 !important;
	letter-spacing: 2px !important;
	text-transform: uppercase !important;
	color: var(--smc-ink) !important;
	background: none !important;
	margin: 0 0 12px !important;
	padding: 0 !important;
	border: 0 !important;
	line-height: 1.4 !important;
}

.smc .smc-closing p {
	margin-bottom: 8px !important;
	font-size: 15px;
	line-height: 1.65;
	color: var(--smc-ink-2) !important;
	max-width: 64ch;
}

.smc .smc-closing b { color: var(--smc-ink) !important; font-weight: 500; }

.smc .smc-notice {
	margin-bottom: 22px;
	padding-left: 17px;
	border-left: 3px solid var(--smc-good-dot);
	font-size: 15px;
	line-height: 1.5;
	color: var(--smc-ink) !important;
}

.smc .smc-notice--bad { border-left-color: var(--smc-busy-dot); }

.smc .smc-none,
.smc .smc-empty p {
	font-size: 15px;
	color: var(--smc-ink-3) !important;
	padding: 26px 0;
	text-align: center;
}

.smc .smc-priest + .smc-priest { margin-top: 72px; }

/* ---------- priest panel ---------- */

.smc-manage { max-width: 860px; }

.smc .smc-pattern { margin: 34px auto 0; max-width: 62ch; }

.smc .smc-pattern h3 {
	font-family: Roboto, Arial, Helvetica, sans-serif !important;
	font-size: 11px !important;
	font-weight: 500 !important;
	letter-spacing: 2px !important;
	text-transform: uppercase !important;
	color: var(--smc-accent) !important;
	background: none !important;
	margin: 0 0 10px !important;
	padding: 0 !important;
	border: 0 !important;
}

.smc .smc-pattern p { font-size: 15.5px; line-height: 1.6; color: var(--smc-ink-2) !important; }
.smc .smc-pattern b { color: var(--smc-ink) !important; font-weight: 700; }

.smc .smc-weeklabel {
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 2px;
	text-transform: uppercase;
	color: var(--smc-ink-3) !important;
	margin: 44px 0 0 !important;
}

.smc .smc-row { margin-top: 34px; max-width: 560px; }

.smc .smc-row-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.smc .smc-row .smc-day { font-size: 24px !important; letter-spacing: -.3px; }
.smc .smc-row .smc-date { display: block; margin-top: 4px; font-size: 14px; }
.smc .smc-row--off .smc-day,
.smc .smc-row--off .smc-date { color: var(--smc-ink-3) !important; }

/* Switch */
.smc .smc-switch { position: relative; flex: none; cursor: pointer; display: block; }

.smc .smc-switch input {
	position: absolute;
	opacity: 0;
	width: 54px;
	height: 32px;
	margin: 0;
	cursor: pointer;
}

.smc .smc-switch-track {
	display: block;
	width: 54px;
	height: 32px;
	border-radius: 32px;
	background: var(--smc-field);
	position: relative;
	transition: background .16s ease;
}

.smc .smc-switch-track::after {
	content: "";
	position: absolute;
	top: 4px;
	left: 4px;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: #fff;
	transition: transform .16s ease;
}

.smc .smc-switch input:checked + .smc-switch-track { background: var(--smc-good-dot); }
.smc .smc-switch input:checked + .smc-switch-track::after { transform: translateX(22px); }

.smc .smc-switch input:focus-visible + .smc-switch-track {
	outline: 2px solid var(--smc-accent);
	outline-offset: 3px;
}

.smc .smc-row-times {
	display: flex;
	gap: 26px;
	margin-top: 18px;
	flex-wrap: wrap;
}

.smc .smc-row-times label,
.smc .smc-row-note {
	display: block;
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 1.4px;
	text-transform: uppercase;
	color: var(--smc-ink-3) !important;
	flex: 1 1 120px;
}

.smc .smc-row-note { margin-top: 18px; flex-basis: 100%; }

.smc .smc-row-times input,
.smc .smc-row-times select,
.smc .smc-row-note input {
	display: block;
	font-size: 16px !important;
	letter-spacing: normal !important;
	text-transform: none !important;
	margin-top: 4px !important;
}

.smc .smc-people { margin-top: 18px; font-size: 14px; }

.smc .smc-people summary {
	cursor: pointer;
	color: var(--smc-ink-2) !important;
	font-weight: 500;
}

.smc .smc-people ul { list-style: none !important; margin: 12px 0 0 !important; padding: 0 !important; }

.smc .smc-people li {
	display: flex;
	justify-content: space-between;
	gap: 14px;
	padding: 8px 0;
	max-width: 340px;
	list-style: none !important;
}

.smc .smc-people li span { font-weight: 500; }

.smc .smc-people li a {
	color: var(--smc-accent) !important;
	text-decoration: none;
	font-variant-numeric: tabular-nums;
}

.smc .smc-people-none {
	margin-top: 16px !important;
	font-size: 13.5px;
	color: var(--smc-ink-3) !important;
}

@media (prefers-reduced-motion: reduce) {
	.smc * { transition: none !important; }
}
