/*
 * Noel Hub layout. Colors and fonts come from the skin (--noel-* properties).
 * Mobile first: comfortable at 375px wide.
 */

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

html {
	-webkit-text-size-adjust: 100%;
}

body.noel-hub {
	margin: 0;
	min-height: 100vh;
	min-height: 100dvh;
}

.noel-hub img {
	max-width: 100%;
	height: auto;
}

/* ---------- Sign-in and denied ---------- */
.noel-signin {
	display: flex;
	flex-direction: column;
	align-items: center;
}

.noel-signin__fold {
	width: 100%;
	height: 96px;
	flex: none;
}

.noel-signin__card {
	width: 100%;
	max-width: 440px;
	padding: 32px var(--noel-gutter) 48px;
	text-align: center;
}

.noel-signin__logo {
	display: block;
	width: 200px;
	margin: 0 auto 28px;
}

.noel-signin__title {
	font-size: clamp(2.25rem, 9vw, 3rem);
}

.noel-signin__lead {
	margin: 12px 0 28px;
}

.noel-signin__button {
	display: flex;
	justify-content: center;
	min-height: 44px;
}

.noel-signin__message {
	min-height: 1.65em;
	margin: 16px 0 0;
	font-weight: 600;
}

.noel-signin__note {
	margin-top: 40px;
	padding-top: 20px;
	border-top: 1px solid var(--noel-line);
	font-size: 0.9375rem;
}

/* ---------- Board header ---------- */
.noel-header {
	position: relative;
	color: var(--noel-on-dark);
}

.noel-header__fold {
	position: absolute;
	inset: 0;
}

.noel-header__inner {
	position: relative;
	z-index: 1;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	max-width: 1280px;
	margin: 0 auto;
	padding: 16px var(--noel-gutter);
	padding-right: 30%;
}

.noel-header__logo {
	display: block;
	width: 120px;
}

.noel-logo-link {
	display: block;
	border-radius: 4px;
}

.noel-logo-link:focus-visible {
	outline: 2px solid var(--noel-apricot);
	outline-offset: 4px;
}

.noel-header__account {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 2px;
	font-size: 0.9375rem;
	line-height: 1.3;
}

.noel-header__signout {
	color: var(--noel-apricot);
	text-decoration: underline;
	text-underline-offset: 0.18em;
	padding: 6px 0;
}

@media (min-width: 720px) {
	/* Keep the name and Sign out beside the logo, on the indigo side of the
	   fold at every width (the panels start at 70% of the header). */
	.noel-header__inner {
		justify-content: flex-start;
		gap: 40px;
		padding-top: 20px;
		padding-bottom: 20px;
		padding-right: calc(var(--noel-gutter) + 34%);
	}

	.noel-header__logo {
		width: 150px;
	}

	.noel-header__account {
		flex-direction: row;
		align-items: center;
		gap: 16px;
	}
}

/* ---------- Helpers ---------- */
.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;
}

.noel-skip {
	position: absolute;
	left: var(--noel-gutter);
	top: -100px;
	z-index: 10;
	padding: 10px 16px;
	border-radius: var(--noel-radius-pill);
	background: var(--noel-paper);
	color: var(--noel-indigo);
}

.noel-skip:focus {
	top: 12px;
}

.noel-button--small {
	min-height: 40px;
	padding: 0.4em 1em;
	font-size: 0.9375rem;
}

/* ---------- Board ---------- */
.noel-board__main {
	max-width: 1280px;
	margin: 0 auto;
	padding: 28px var(--noel-gutter) 64px;
}

.noel-board__main:focus {
	outline: none;
}

.noel-board__top {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 20px;
}

.noel-board__main h1 {
	font-size: clamp(1.75rem, 7vw, 2.5rem);
}

.noel-board__empty,
.noel-notice {
	margin: 0 0 24px;
}

.noel-notice {
	padding: 14px 16px;
	border-left: 4px solid var(--noel-rule);
	border-radius: 4px;
	background: var(--noel-surface);
}

/* ---------- Worship session cards (styled after the staff dashboard) ----------
 * Season colors come from skin.php as .noel-season-* classes that set
 * --card-bg, --card-ink and --card-border. */
.noel-section-title {
	margin: 0;
	font-size: clamp(1.5rem, 6vw, 2rem);
}

.noel-section-title__count {
	margin-left: 8px;
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.875rem;
	white-space: nowrap;
}

.noel-cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr));
	gap: 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.noel-card {
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding: 20px;
	border: 2px solid var(--card-border, var(--noel-line));
	border-radius: 20px;
	background: var(--card-bg, var(--noel-surface));
	color: var(--card-ink, var(--noel-indigo));
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.noel-card:hover {
	transform: translateY(-2px);
	box-shadow: 0 10px 26px color-mix(in srgb, var(--noel-indigo) 10%, transparent);
}

@media (prefers-reduced-motion: reduce) {
	.noel-card,
	.noel-card:hover {
		transition: none;
		transform: none;
	}
}

.noel-card--next {
	/* Gold ring with a thin indigo outline so it shows on the paper page. */
	box-shadow: 0 0 0 3px var(--noel-highlight), 0 0 0 4px var(--noel-indigo);
}

.noel-card--next:hover {
	box-shadow: 0 0 0 3px var(--noel-highlight), 0 0 0 4px var(--noel-indigo), 0 10px 26px color-mix(in srgb, var(--noel-indigo) 10%, transparent);
}

.noel-card__head {
	display: flex;
	align-items: center;
	gap: 16px;
}

.noel-card__tile {
	display: flex;
	flex: none;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 68px;
	height: 68px;
	border-radius: 16px;
	/* A darker tint keeps white text above 4.5:1 on every season color. */
	background: color-mix(in srgb, #000 18%, transparent);
}

.noel-card--light .noel-card__tile {
	background: color-mix(in srgb, var(--noel-indigo) 8%, transparent);
}

.noel-card__dow {
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.6875rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.noel-card__day {
	font-family: var(--noel-font-display);
	font-weight: 600;
	font-size: 1.25rem;
	line-height: 1.1;
	white-space: nowrap;
}

.noel-card__meta {
	flex: 1;
	min-width: 0;
}

.noel-hub .noel-card__date {
	margin: 0;
	font-size: 1.0625rem;
	line-height: 1.3;
	color: inherit;
}

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

.noel-pill {
	padding: 3px 11px;
	border: 1px solid color-mix(in srgb, #fff 55%, transparent);
	border-radius: var(--noel-radius-pill);
	background: color-mix(in srgb, #000 15%, transparent);
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.75rem;
	line-height: 1.5;
	white-space: nowrap;
}

.noel-card--light .noel-pill {
	border-color: color-mix(in srgb, var(--noel-indigo) 30%, transparent);
	background: #fff;
}

.noel-hub .noel-pill--next {
	border-color: var(--noel-highlight);
	background: var(--noel-highlight);
	color: var(--noel-indigo);
}

.noel-card__folder {
	margin: 0;
	font-size: 0.875rem;
}

.noel-card__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: auto;
	font-size: 0.875rem;
}

.noel-hub .noel-card__open {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	border-bottom: 2px solid var(--noel-highlight);
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.9375rem;
	text-decoration: none;
	line-height: 1.2;
	padding-top: 2px;
}

.noel-card :focus-visible {
	outline-color: currentColor;
}

/* Other folders: plain white cards. */
.noel-folder-card {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 20px;
	border: 1px solid var(--noel-line);
	border-radius: 20px;
	background: var(--noel-surface);
}

.noel-hub .noel-folder-card__name {
	font-size: 1.125rem;
}

.noel-folder-card .noel-card__open {
	border-bottom-color: var(--noel-apricot);
}

/* ---------- Collapsed groups ---------- */
.noel-group {
	margin-top: 36px;
}

.noel-group__summary {
	display: flex;
	align-items: center;
	gap: 12px;
	min-height: 52px;
	margin-bottom: 14px;
	cursor: pointer;
	list-style: none;
}

.noel-group__summary::-webkit-details-marker {
	display: none;
}

.noel-group__summary::before {
	content: "";
	flex: none;
	width: 0.6em;
	height: 0.6em;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(-45deg);
	transition: transform 0.15s;
}

.noel-group[open] > .noel-group__summary::before {
	transform: rotate(45deg);
}

@media (prefers-reduced-motion: reduce) {
	.noel-group__summary::before {
		transition: none;
	}
}

.noel-group__summary .noel-section-title {
	font-size: clamp(1.25rem, 5vw, 1.5rem);
}

/* ---------- Phase 2: the full Sunday board (after the old dashboard) ---------- */
.noel-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	margin-bottom: 28px;
}

.noel-search {
	flex: 1 1 220px;
	max-width: 380px;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid var(--noel-line);
	border-radius: var(--noel-radius-pill);
	background: var(--noel-surface);
	color: var(--noel-indigo);
	font: inherit;
}

.noel-search::placeholder {
	color: color-mix(in srgb, var(--noel-indigo) 70%, transparent);
}

.noel-search:focus-visible {
	outline: 3px solid var(--noel-dusk);
	outline-offset: 2px;
}

.noel-toolbar__status {
	font-size: 0.875rem;
}

.noel-section {
	margin-top: 36px;
}

.noel-section:first-of-type {
	margin-top: 0;
}

.noel-section > .noel-section-title {
	margin-bottom: 14px;
}

.noel-card--past {
	opacity: 0.72;
}

.noel-card--past:hover,
.noel-card--past:focus-within {
	opacity: 1;
}

/* Pills */
.noel-hub .noel-pill--ready {
	border-color: var(--card-ink, var(--noel-indigo));
	background: var(--card-ink, var(--noel-indigo));
	color: var(--card-bg, #fff);
}

.noel-hub .noel-pill--new {
	border-color: transparent;
	background: var(--card-ink, var(--noel-indigo));
	color: var(--card-bg, #fff);
}

.noel-card--light .noel-pill--new,
.noel-card--light .noel-pill--ready {
	background: var(--noel-indigo);
	color: #fff;
}

/* Plan summary */
.noel-plan {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 0;
	padding: 12px 14px;
	border: 1px solid color-mix(in srgb, #fff 30%, transparent);
	border-radius: 14px;
	background: color-mix(in srgb, #fff 12%, transparent);
}

.noel-card--light .noel-plan {
	border-color: #b9ab92;
	background: #fbf7ee;
}

.noel-plan__line {
	display: flex;
	gap: 10px;
	align-items: baseline;
	font-size: 0.875rem;
	line-height: 1.4;
}

.noel-plan__label {
	flex: none;
	width: 88px;
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.6875rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.noel-plan__text {
	min-width: 0;
	margin: 0;
	overflow-wrap: anywhere;
}

/* Slots */
.noel-slots {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.noel-slot {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 48px;
	padding: 8px 12px;
	border: 1px dashed color-mix(in srgb, #fff 50%, transparent);
	border-radius: 14px;
	background: color-mix(in srgb, #fff 12%, transparent);
}

.noel-slot--filled {
	border: 1px solid color-mix(in srgb, #fff 45%, transparent);
	background: color-mix(in srgb, #fff 22%, transparent);
}

.noel-card--light .noel-slot {
	border-color: #b9ab92;
	background: #fbf7ee;
}

.noel-card--light .noel-slot--filled {
	background: #eef4f0;
}

.noel-slot__tick {
	display: grid;
	flex: none;
	place-items: center;
	width: 24px;
	height: 24px;
	border: 1px solid color-mix(in srgb, #fff 70%, transparent);
	border-radius: 6px;
	font-size: 0.8125rem;
	font-weight: 600;
}

.noel-slot--filled .noel-slot__tick {
	border-color: var(--card-ink, var(--noel-indigo));
	background: var(--card-ink, var(--noel-indigo));
	color: var(--card-bg, #fff);
}

.noel-card--light .noel-slot__tick {
	border-color: #8d93b3;
	background: #fff;
	color: var(--noel-indigo);
}

.noel-card--light .noel-slot--filled .noel-slot__tick {
	border-color: var(--noel-indigo);
	background: var(--noel-indigo);
	color: #fff;
}

.noel-slot__label {
	flex: none;
	width: 104px;
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.8125rem;
	white-space: nowrap;
}

.noel-hub .noel-slot__file {
	flex: 1;
	min-width: 0;
	overflow: hidden;
	color: inherit;
	font-size: 0.875rem;
	text-decoration: none;
	text-overflow: ellipsis;
	white-space: nowrap;
	border-bottom: 1px solid transparent;
}

.noel-hub .noel-slot__file:hover {
	border-bottom-color: currentColor;
}

.noel-slot__wait {
	flex: 1;
	white-space: nowrap;
	font-size: 0.8125rem;
	font-style: italic;
	opacity: 0.85;
}

.noel-slot .noel-pill {
	flex: none;
}

/* Also here */
.noel-extras {
	margin: 0;
	font-size: 0.8125rem;
	line-height: 1.5;
	overflow-wrap: anywhere;
}

.noel-hub .noel-extras a {
	color: inherit;
}

/* Other folders and Archived: plain file lists */
.noel-file-list {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.noel-file-list li {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
	font-size: 0.875rem;
}

.noel-hub .noel-file-list a {
	min-width: 0;
	overflow: hidden;
	color: var(--noel-indigo);
	text-decoration: none;
	text-overflow: ellipsis;
	white-space: nowrap;
	border-bottom: 1px solid transparent;
}

.noel-hub .noel-file-list a:hover {
	border-bottom-color: var(--noel-dusk);
}

.noel-file-list__empty {
	font-style: italic;
}

/* Top level files */
.noel-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.noel-hub .noel-chips a {
	display: inline-block;
	max-width: 100%;
	padding: 7px 14px;
	overflow: hidden;
	border: 1px solid var(--noel-line);
	border-radius: var(--noel-radius-pill);
	background: var(--noel-surface);
	color: var(--noel-indigo);
	font-size: 0.875rem;
	text-decoration: none;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.noel-hub .noel-chips a:hover {
	border-color: var(--noel-dusk);
}

/* Archived */
.noel-archived {
	margin-top: 36px;
	padding: 16px 20px;
	border: 1px solid var(--noel-line);
	border-radius: 18px;
	background: var(--noel-surface);
}

.noel-archived__summary {
	min-height: 32px;
	cursor: pointer;
	font-family: var(--noel-font-display);
	font-weight: 600;
	font-size: 1.125rem;
}

.noel-archived[open] .noel-archived__summary {
	margin-bottom: 14px;
}

.noel-footer {
	padding: 0 var(--noel-gutter) 32px;
	font-size: 0.8125rem;
	text-align: center;
}

@media (max-width: 560px) {
	.noel-slot__label {
		width: 88px;
	}
}

/* ---------- Card actions and dialogs (Step 4 on) ---------- */
.noel-card__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: 10px 14px;
}

.noel-hub .noel-card__button {
	min-height: 36px;
	padding: 6px 14px;
	border: none;
	border-radius: var(--noel-radius-pill);
	background: #fff;
	color: var(--noel-indigo);
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.8125rem;
	cursor: pointer;
}

.noel-hub .noel-card__button:hover {
	background: var(--noel-paper);
}

.noel-card--light .noel-card__button {
	background: var(--noel-indigo);
	color: #fff;
}

.noel-card--light .noel-card__button:hover {
	background: var(--noel-dusk);
}

.noel-dialog {
	width: min(440px, calc(100vw - 32px));
	max-height: calc(100vh - 32px);
	padding: 0;
	border: none;
	border-radius: 20px;
	background: #fff;
	color: var(--noel-indigo);
	box-shadow: 0 20px 50px color-mix(in srgb, var(--noel-indigo) 25%, transparent);
}

.noel-dialog::backdrop {
	background: color-mix(in srgb, var(--noel-indigo) 45%, transparent);
}

.noel-dialog__form {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 24px;
}

.noel-hub .noel-dialog__title {
	margin: 0;
	font-size: 1.375rem;
}

.noel-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
	margin: 0;
	padding: 0;
	border: none;
}

.noel-field--set {
	gap: 8px;
}

.noel-field--indent {
	margin-left: 28px;
}

.noel-field__label {
	padding: 0;
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.8125rem;
}

.noel-dialog input[type="text"],
.noel-dialog textarea {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid #b9ab92;
	border-radius: 12px;
	background: #fbf7ee;
	color: var(--noel-indigo);
	font: inherit;
	font-size: 0.9375rem;
	resize: vertical;
}

.noel-dialog input[type="text"]:focus-visible,
.noel-dialog textarea:focus-visible,
.noel-dialog input[type="radio"]:focus-visible,
.noel-dialog input[type="checkbox"]:focus-visible {
	outline: 3px solid var(--noel-dusk);
	outline-offset: 2px;
}

.noel-check {
	display: flex;
	align-items: center;
	gap: 8px;
	min-height: 32px;
	font-size: 0.9375rem;
}

.noel-check input {
	width: 18px;
	height: 18px;
	margin: 0;
	accent-color: var(--noel-indigo);
}

.noel-dialog__error {
	margin: 0;
	padding: 10px 12px;
	border-left: 4px solid var(--noel-coral);
	border-radius: 4px;
	background: #fbf1e3;
	font-size: 0.875rem;
}

.noel-dialog__actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 10px;
	margin-top: 6px;
}

/* ---------- Uploads (Step 5) ---------- */
.noel-hub .noel-slot__upload {
	flex: none;
	min-height: 32px;
	padding: 4px 12px;
	font-size: 0.75rem;
}

.noel-dialog__text {
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.5;
}

.noel-toast {
	position: fixed;
	bottom: 24px;
	left: 50%;
	z-index: 50;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 16px;
	width: max-content;
	max-width: calc(100vw - 32px);
	padding: 12px 14px 12px 20px;
	border-radius: 24px;
	background: var(--noel-indigo);
	color: var(--noel-paper);
	font-size: 0.875rem;
	box-shadow: 0 10px 30px color-mix(in srgb, var(--noel-indigo) 30%, transparent);
	transform: translateX(-50%);
}

.noel-toast[hidden] {
	display: none;
}

.noel-toast__text {
	min-width: 0;
	overflow-wrap: anywhere;
}

.noel-toast__progress {
	width: 120px;
	accent-color: var(--noel-apricot);
}

.noel-hub .noel-toast__link {
	color: var(--noel-apricot);
	font-family: var(--noel-font-label);
	font-weight: 500;
}

.noel-toast__close {
	min-width: 32px;
	min-height: 32px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: transparent;
	color: inherit;
	font-size: 1.25rem;
	line-height: 1;
	cursor: pointer;
}

.noel-toast__close:hover {
	background: color-mix(in srgb, #fff 15%, transparent);
}

/* A problem stays until closed and looks different from good news. */
.noel-toast.is-bad {
	border: 2px solid var(--noel-coral);
	background: #fff;
	color: var(--noel-indigo);
}

.noel-toast.is-bad .noel-toast__close:hover {
	background: color-mix(in srgb, var(--noel-indigo) 10%, transparent);
}

.noel-toast__close:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

/* Buttons while their form is on its way. */
.noel-hub button[aria-busy="true"] {
	opacity: 0.6;
	cursor: progress;
}

@media (max-width: 560px) {
	.noel-slot__label {
		width: auto;
		flex: 1 1 auto;
	}

	.noel-slot {
		flex-wrap: wrap;
	}
}

/* ---------- Archive and Restore (Step 6) ---------- */
.noel-hub .noel-card__button--line {
	border: 1px solid var(--noel-line);
	background: var(--noel-surface);
	color: var(--noel-indigo);
}

.noel-hub .noel-card__button--line:hover {
	border-color: var(--noel-dusk);
	background: var(--noel-paper);
}

.noel-hub .noel-card__button:disabled {
	opacity: 0.5;
	cursor: wait;
}

.noel-archived__item {
	justify-content: space-between;
}

.noel-hub .noel-toast__undo {
	min-height: 32px;
	padding: 6px 16px;
	border: none;
	border-radius: var(--noel-radius-pill);
	background: var(--noel-apricot);
	color: var(--noel-indigo);
	font-family: var(--noel-font-label);
	font-weight: 500;
	cursor: pointer;
}

.noel-toast__undo[hidden] {
	display: none;
}

/* ---------- Notifications (Step 8) ---------- */
.noel-dialog__note {
	padding: 10px 12px;
	border-left: 4px solid var(--noel-apricot);
	border-radius: 4px;
	background: var(--noel-paper);
	font-size: 0.875rem;
}

.noel-subscribers {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-top: 14px;
	border-top: 1px solid var(--noel-line);
}

.noel-subscribers__list {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.noel-subscribers__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.noel-subscribers__who {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.noel-subscribers__email {
	overflow: hidden;
	font-size: 0.875rem;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.noel-subscribers__what {
	font-size: 0.75rem;
	opacity: 0.8;
}

.noel-hub .noel-button--armed {
	border-color: var(--noel-apricot);
	background: var(--noel-apricot);
	color: var(--noel-indigo);
}

.noel-dialog__actions .noel-button {
	min-width: 0;
}

/* ---------- Headline (0.2.1) ----------
 * "Everything for Worship in one place", with the italic word cycling
 * Worship, Missions, Ministry. The three words share one grid cell, so the
 * line never shifts as they change. */
.noel-hub .noel-headline {
	flex-basis: 100%;
	order: 3;
	margin: 4px 0 0;
	color: var(--noel-on-dark);
	font-family: var(--noel-font-display);
	font-weight: 600;
	font-size: clamp(1.5rem, 5.5vw, 2.25rem);
	line-height: 1.15;
}

.noel-headline__rotor {
	display: inline-grid;
	justify-items: start;
}

.noel-headline__rotor > span {
	grid-area: 1 / 1;
	color: var(--noel-accent-on-dark);
	font-style: italic;
	font-weight: 500;
	opacity: 0;
	animation: noel-rotor 9s infinite;
}

.noel-headline__rotor > span:nth-child(2) {
	animation-delay: 3s;
}

.noel-headline__rotor > span:nth-child(3) {
	animation-delay: 6s;
}

@keyframes noel-rotor {
	0% {
		opacity: 0;
		transform: translateY(0.25em);
	}
	5%,
	30% {
		opacity: 1;
		transform: none;
	}
	35%,
	100% {
		opacity: 0;
		transform: translateY(-0.25em);
	}
}

/* No motion wanted: show "Worship" and stop. */
@media (prefers-reduced-motion: reduce) {
	.noel-headline__rotor > span {
		animation: none;
	}

	.noel-headline__rotor > span:first-child {
		opacity: 1;
	}

	.noel-headline__rotor > span:not(:first-child) {
		display: none;
	}
}

/* ---------- Phase 3: tabs, Access screen, Help ---------- */
.noel-tabs {
	flex-basis: 100%;
	order: 4;
	display: flex;
	gap: 4px;
	margin: 8px 0 -16px; /* Sit on the bottom edge of the header. */
	padding: 0 2px;
	overflow-x: auto;
	scrollbar-width: none;
}

.noel-tabs::-webkit-scrollbar {
	display: none;
}

.noel-tabs__link {
	flex: none;
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0.4em 1.1em;
	border: 1px solid color-mix(in srgb, var(--noel-paper) 40%, transparent);
	border-bottom: 0;
	border-radius: 14px 14px 0 0;
	color: var(--noel-on-dark);
	text-decoration: none;
	white-space: nowrap;
}

.noel-tabs__link:hover,
.noel-tabs__link:focus-visible {
	border-color: var(--noel-apricot);
	color: var(--noel-apricot);
}

/* The current tab takes the page color, so it joins the content below. */
.noel-tabs__link.is-current {
	border-color: var(--noel-paper);
	background: var(--noel-bg);
	color: var(--noel-indigo);
	font-weight: 600;
}

@media (min-width: 720px) {
	.noel-tabs {
		margin-bottom: -20px;
	}
}

.noel-hub .noel-headline--page {
	font-size: clamp(1.375rem, 5vw, 2rem);
}

.noel-notice--soft {
	border-left-color: var(--noel-dusk);
}

.noel-panel {
	margin: 0 0 20px;
	padding: 18px 20px;
	border: 1px solid var(--noel-line);
	border-radius: 20px;
	background: var(--noel-surface);
}

.noel-panel__title {
	margin: 0;
	font-family: var(--noel-font-display);
	font-weight: 600;
	font-size: 1.25rem;
}

details.noel-panel > summary.noel-panel__title {
	cursor: pointer;
	list-style-position: outside;
	min-height: 32px;
}

.noel-panel__text {
	margin: 8px 0 14px;
	font-size: 0.9375rem;
}

.noel-access__shortcuts {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
	gap: 0 20px;
	align-items: start;
}

.noel-form-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
	gap: 0 16px;
}

.noel-inline-form {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 10px 14px;
}

.noel-inline-form .noel-field {
	margin: 0;
}

.noel-check--area {
	align-items: flex-start;
}

.noel-check__hint {
	display: block;
	font-size: 0.875rem;
	opacity: 0.85;
}

.noel-check__hint--warn {
	color: var(--noel-rule);
	opacity: 1;
}

.noel-datepick {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
	gap: 6px;
	max-height: 260px;
	margin-top: 8px;
	overflow-y: auto;
}

.noel-datepick__day {
	display: flex;
	align-items: center;
	gap: 6px;
	min-height: 40px;
	padding: 4px 10px;
	border: 1px solid var(--noel-line);
	border-radius: 10px;
	font-size: 0.9375rem;
	cursor: pointer;
}

.noel-datepick__day:has(input:checked) {
	border-color: var(--noel-dusk);
	background: color-mix(in srgb, var(--noel-dusk) 12%, transparent);
}

.noel-people {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
	gap: 16px;
	margin: 16px 0 0;
	padding: 0;
	list-style: none;
}

.noel-person {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 18px;
	border: 1px solid var(--noel-line);
	border-radius: 20px;
	background: var(--noel-surface);
}

.noel-person--ended,
.noel-person--disabled {
	opacity: 0.72;
}

.noel-person__head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.noel-person__name {
	margin: 0;
	font-size: 1.25rem;
	overflow-wrap: anywhere;
}

.noel-person .noel-card__actions form {
	display: inline;
	margin: 0;
}

.noel-guide {
	max-width: 640px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.noel-guide__step {
	display: flex;
	gap: 14px;
	align-items: flex-start;
	margin: 0 0 16px;
	font-size: 1.0625rem;
}

.noel-guide__num {
	flex: none;
	display: inline-grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: var(--noel-apricot);
	color: var(--noel-indigo);
	font-family: var(--noel-font-label);
	font-weight: 600;
}

.noel-guide__shot {
	max-width: 640px;
	margin: 8px 0 0;
}

.noel-guide__shot img {
	display: block;
	width: 100%;
	height: auto;
	border: 1px solid var(--noel-line);
	border-radius: 16px;
}

.noel-help__note {
	max-width: 640px;
	font-size: 0.9375rem;
}

.noel-signin__message--error {
	color: var(--noel-rule);
}

.noel-signin__link {
	margin-top: 28px;
	text-align: left;
}

.noel-signin__link > summary {
	min-height: 44px;
	padding: 10px 0;
	text-align: center;
	cursor: pointer;
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.noel-signin__link-form {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin-top: 8px;
}

.noel-slot__file:not(a) {
	overflow-wrap: anywhere;
}

.noel-panel input[type="text"],
.noel-panel input[type="email"],
.noel-panel input[type="date"],
.noel-panel select,
.noel-panel textarea,
.noel-signin__link-form input[type="email"] {
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid #b9ab92;
	border-radius: 12px;
	background: #fbf7ee;
	color: var(--noel-indigo);
	font: inherit;
	font-size: 1rem; /* 16px keeps phones from zooming in. */
}

.noel-panel input:focus-visible,
.noel-panel select:focus-visible,
.noel-panel textarea:focus-visible,
.noel-signin__link-form input:focus-visible {
	outline: 3px solid var(--noel-dusk);
	outline-offset: 2px;
}

.noel-panel form > * + * {
	margin-top: 14px;
}

.noel-panel .noel-inline-form > * + * {
	margin-top: 0;
}

.noel-hub .noel-person .noel-card__button {
	border: 1px solid var(--noel-indigo);
	text-decoration: none;
	display: inline-flex;
	align-items: center;
}

.noel-hub .noel-person .noel-card__actions {
	justify-content: flex-start;
	flex-wrap: wrap;
}

/* ---------- Comms board (Phase 3 Step 5) ---------- */
.noel-comms__jump {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 20px;
}

.noel-comms__jump .noel-pill {
	text-decoration: none;
}

.noel-comms__cols {
	display: grid;
	gap: 24px;
}

@media (min-width: 1100px) {
	.noel-comms__cols {
		grid-template-columns: repeat(5, minmax(0, 1fr));
		gap: 16px;
		align-items: start;
	}
	.noel-comms__col .noel-section-title {
		font-size: 1.25rem;
	}
}

.noel-comms__list {
	display: grid;
	gap: 12px;
	margin: 12px 0 0;
	padding: 0;
	list-style: none;
}

.noel-request {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding: 14px 16px;
	border: 1px solid var(--noel-line);
	border-radius: 16px;
	background: var(--noel-surface);
}

.noel-request--urgent {
	border: 2px solid var(--noel-rule);
}

.noel-request__title {
	margin: 0;
	font-size: 1.125rem;
	overflow-wrap: anywhere;
}

.noel-request__meta {
	margin: 0;
	font-size: 0.875rem;
}

.noel-request__flag {
	margin: 0;
	color: var(--noel-rule);
	font-weight: 600;
	font-size: 0.875rem;
}

.noel-request__more > summary {
	min-height: 36px;
	padding: 6px 0;
	cursor: pointer;
	font-size: 0.9375rem;
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.noel-request__card {
	margin: 4px 0 8px;
	padding: 10px;
	border-radius: 10px;
	background: var(--noel-paper);
	font: 0.8125rem/1.5 var(--noel-font-body);
	white-space: pre-wrap;
	overflow-wrap: anywhere;
}

.noel-request__history {
	margin: 4px 0 0;
	padding-left: 18px;
	font-size: 0.8125rem;
}

.noel-comms__actions {
	justify-content: flex-start;
	flex-wrap: wrap;
}

.noel-comms__form {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin: 0;
}

.noel-comms__actions .noel-comms__form {
	display: inline-flex;
}

.noel-hub .noel-comms .noel-card__button,
.noel-hub.noel-comms .noel-card__button {
	min-height: 44px;
	border: 1px solid var(--noel-indigo);
}

.noel-hub .noel-card__button--main {
	background: var(--noel-indigo);
	color: #fff;
}

.noel-comms textarea,
.noel-comms select {
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid #b9ab92;
	border-radius: 12px;
	background: #fbf7ee;
	color: var(--noel-indigo);
	font: inherit;
	font-size: 1rem;
}

/* ---------- Newsletter queue (Phase 3 Step 6) ---------- */
.noel-letter__list {
	max-width: 760px;
}

.noel-letter__used select {
	min-height: 44px;
	padding: 8px 10px;
	border: 1px solid #b9ab92;
	border-radius: 12px;
	background: #fbf7ee;
	color: var(--noel-indigo);
	font: inherit;
	font-size: 1rem;
}

.noel-letter__done {
	max-width: 760px;
	margin-top: 24px;
}

.noel-letter__alerts {
	max-width: 760px;
	margin-top: 24px;
}

.noel-coming__list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
	gap: 12px;
	margin: 12px 0 0;
	padding: 0;
	list-style: none;
}

.noel-coming__day {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 12px 14px;
	border: 1px solid var(--noel-line);
	border-radius: 14px;
	background: var(--noel-surface);
}

.noel-coming__date {
	font-family: var(--noel-font-label);
	font-weight: 500;
	font-size: 0.875rem;
}

.noel-coming__special {
	color: var(--noel-rule);
	font-weight: 600;
	font-size: 0.875rem;
}

.noel-coming__sermon {
	font-size: 0.9375rem;
}

.noel-hub.noel-newsletter .noel-card__button {
	min-height: 44px;
	border: 1px solid var(--noel-indigo);
}

/* ---------- Sign-ups (Phase 3 Step 7) ---------- */
.noel-linked {
	display: grid;
	gap: 6px;
	margin: 0;
	padding: 10px 12px;
	border-radius: 12px;
	background: color-mix(in srgb, var(--card-ink, var(--noel-indigo)) 8%, transparent);
	list-style: none;
}

.noel-linked__item {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 4px 12px;
	font-size: 0.9375rem;
}

.noel-linked__link {
	color: inherit;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.noel-linked__count {
	font-size: 0.875rem;
	opacity: 0.85;
}

.noel-hub.noel-signups .noel-card__button {
	min-height: 44px;
	border: 1px solid var(--noel-indigo);
}

.noel-signups select {
	min-height: 44px;
	padding: 8px 10px;
	border: 1px solid #b9ab92;
	border-radius: 12px;
	background: #fbf7ee;
	color: var(--noel-indigo);
	font: inherit;
	font-size: 1rem;
}

/* The tab's one-line subheading under the rotating headline. */
.noel-hub .noel-subhead {
	flex-basis: 100%;
	order: 3;
	margin: -4px 0 0;
	max-width: 46ch;
	text-wrap: pretty;
	color: color-mix(in srgb, var(--noel-paper) 88%, transparent);
	font-size: 1rem;
	line-height: 1.45;
}

@media (min-width: 720px) {
	.noel-hub .noel-subhead {
		margin-top: -28px; /* The header's 40px gap is too wide between headline and subheading. */
		max-width: 62ch;
		font-size: 1.0625rem;
	}
	.noel-tabs {
		margin-top: -12px;
	}
}
