/* BRN Resource Library: fits the Kadence child theme (Montserrat, BRN red #cf3a28 / #a5291a). */

.brn-lib {
	--brn-red: #a5291a;
	--brn-red-dark: #7c1f13;
	--brn-ink: #040506;
	--brn-muted: #555;
	--brn-line: #e3e3e3;
	--brn-tint: #f6f2f1;
	--brn-field: #8a8a8a;
	color: var(--brn-ink);
}
.brn-lib a { color: var(--brn-red); text-decoration: none; }
.brn-lib a:hover, .brn-lib a:focus { color: var(--brn-red-dark); text-decoration: underline; }
.brn-lib :focus-visible { outline: 3px solid #2f6fb0; outline-offset: 2px; }
.brn-lib [hidden] { display: none !important; }
.brn-muted { color: var(--brn-muted); font-size: 0.85em; }
.brn-back { font-size: 15px; font-weight: 600; margin: 0 0 1rem; }
.brn-from-brn { font-weight: 700; color: var(--brn-red); }

/* Buttons */
.brn-btn {
	display: inline-flex; align-items: center; justify-content: center; min-height: 44px; box-sizing: border-box;
	padding: 10px 20px; border-radius: 30px; border: 2px solid var(--brn-red); background: #fff;
	color: var(--brn-red) !important; font: inherit; font-size: 15px; font-weight: 700; line-height: 1.2; cursor: pointer; text-decoration: none !important;
}
.brn-btn:hover, .brn-btn:focus { background: #fbeceb; }
.brn-btn--primary { background: var(--brn-red); color: #fff !important; }
.brn-btn--primary:hover, .brn-btn--primary:focus { background: var(--brn-red-dark); border-color: var(--brn-red-dark); color: #fff !important; }
.brn-btn--big { font-size: 17px; padding: 13px 30px; }
.brn-linkbtn { background: none; border: 0; padding: 10px 6px; min-height: 44px; color: var(--brn-red); font: inherit; font-size: 15px; font-weight: 700; cursor: pointer; }
.brn-linkbtn:hover { color: var(--brn-red-dark); text-decoration: underline; }

/* ---------- Library page ---------- */
.brn-library__intro { font-size: 18px; line-height: 1.6; margin: 0 0 24px; max-width: 860px; }
.brn-filters {
	display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end;
	padding: 16px; background: var(--brn-tint); border-radius: 6px; margin: 0 0 18px;
}
.brn-field { display: flex; flex-direction: column; gap: 4px; }
.brn-field label, .brn-typepick legend { font-size: 14px; font-weight: 700; line-height: 1.3; }
.brn-filters .brn-field label { font-size: 13px; }
.brn-field--search { flex: 1 1 260px; }
.brn-field--type { flex: 0 1 190px; }
.brn-field--trad { flex: 0 1 200px; }
.brn-field--theme { flex: 0 1 230px; }
.brn-lib input[type="text"], .brn-lib input[type="search"], .brn-lib input[type="email"], .brn-lib input[type="url"], .brn-lib select, .brn-lib textarea {
	box-sizing: border-box; font: inherit; font-size: 16px; color: var(--brn-ink); background: #fff;
	border: 1px solid var(--brn-field); border-radius: 4px; padding: 0 12px; height: 44px; max-width: 100%; width: 100%;
}
.brn-lib select { padding: 0 10px; font-size: 15px; }
.brn-lib input::placeholder, .brn-lib textarea::placeholder { color: #666; opacity: 1; }
.brn-lib input:focus, .brn-lib select:focus, .brn-lib textarea:focus { color: var(--brn-ink); border-color: var(--brn-ink); }
.brn-lib textarea { height: auto; padding: 10px 12px; line-height: 1.5; resize: vertical; }
.brn-search { display: flex; }
.brn-search input[type="search"] { flex: 1 1 auto; min-width: 0; border-right: 0; border-radius: 4px 0 0 4px; }
.brn-search__btn {
	flex: 0 0 auto; white-space: nowrap; box-shadow: none; line-height: 1;
	display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 18px; border: 0; border-radius: 0 4px 4px 0;
	background: var(--brn-red); color: #fff; font: inherit; font-size: 15px; font-weight: 700; cursor: pointer;
}
.brn-search__btn:hover { background: var(--brn-red-dark); }
.brn-check { display: flex; align-items: center; gap: 8px; min-height: 44px; font-size: 15px; font-weight: 600; padding: 0 4px; cursor: pointer; }
.brn-check input { width: 20px; height: 20px; accent-color: var(--brn-red); margin: 0; flex: 0 0 auto; }
.brn-view { display: flex; margin-left: auto; }
.brn-view button { height: 44px; box-shadow: none; line-height: 1; border-radius: 0; padding: 0 16px; border: 1px solid var(--brn-field); background: #fff; font: inherit; font-size: 14px; color: var(--brn-ink); cursor: pointer; }
.brn-view button:first-child { border-radius: 4px 0 0 4px; }
.brn-view button:last-child { border-left: 0; border-radius: 0 4px 4px 0; }
.brn-view button[aria-pressed="true"] { background: #e6e6e6; font-weight: 700; }

.brn-results-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; font-size: 15px; margin-bottom: 8px; }
.brn-results { margin: 0; }
.brn-clear { font-weight: 700; padding: 8px; }

.brn-table { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 1.4; margin: 0; border: 0; }
.brn-table th, .brn-table td { border: 0; padding: 10px 8px; text-align: left; vertical-align: top; }
.brn-table thead tr { border-bottom: 2px solid var(--brn-ink); }
.brn-table th { font-weight: 700; font-size: 16px; }
.brn-table th a { color: var(--brn-ink); }
.brn-table th a.is-current { text-decoration: underline; }
.brn-table tbody tr { border-bottom: 1px solid var(--brn-line); background: #fff; }
.brn-table tbody tr.brn-odd { background: #f9f9f9; }
.brn-col-thumb { width: 64px; }
.brn-col-type { width: 150px; font-size: 15px; }
.brn-col-trad { width: 170px; font-size: 15px; }
.brn-col-themes { width: 210px; font-size: 15px; }
.brn-col-year { width: 70px; font-size: 15px; }
.brn-row__title { font-weight: 700; font-size: 17px; }
.brn-row__by { font-size: 15px; color: #3d3d3d; margin-top: 2px; }
.brn-row__extras { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; font-size: 13px; color: var(--brn-muted); }
.brn-type { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.brn-icon { flex: 0 0 auto; }

.brn-thumb, .brn-cover-thumb {
	display: flex; align-items: flex-end; justify-content: center; box-sizing: border-box; overflow: hidden;
	color: #fff; font-size: 10px; font-weight: 700; letter-spacing: 0.04em; border-radius: 3px; background: #7c1f13;
}
.brn-thumb { width: 48px; height: 64px; padding-bottom: 4px; }
.brn-thumb--podcast { background: #2f4f6f; }
.brn-thumb--video { background: #1f1f1f; }
.brn-thumb--img { background: #eee; padding: 0; align-items: center; }
.brn-thumb img, .brn-cover-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; margin: 0; }

.brn-covers { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 22px 18px; }
.brn-cover-item { margin: 0; }
.brn-cover-item a { display: flex; flex-direction: column; gap: 6px; color: var(--brn-ink); font-size: 14px; font-weight: 600; line-height: 1.3; }
.brn-cover-thumb { aspect-ratio: 2 / 3; width: 100%; padding-bottom: 8px; font-size: 12px; }
.brn-cover-thumb.brn-thumb--img { background: #eee; padding: 0; }
.brn-cover-item__by { font-weight: 500; color: var(--brn-muted); font-size: 13px; }
.brn-empty { font-size: 17px; padding: 24px 8px; }
.brn-library__suggest { margin-top: 32px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; padding: 20px 22px; font-size: 16px; line-height: 1.5; }
.brn-library__suggest p { margin: 0; flex: 1 1 360px; }

/* Phones: filters stack, list rows become cards */
@media (max-width: 760px) {
	.brn-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px; }
	.brn-field--search, .brn-field--theme { grid-column: span 2; }
	.brn-check { grid-column: span 2; }
	.brn-view { grid-column: span 2; margin-left: 0; }
	.brn-view button { flex: 1 1 50%; }
	.brn-table thead { display: none; }
	.brn-table, .brn-table tbody { display: block; }
	.brn-table tbody tr.brn-row { display: block; position: relative; min-height: 56px; padding: 14px 4px 14px 72px; background: #fff; }
	.brn-table tbody tr.brn-row[hidden] { display: none; }
	.brn-table tbody tr.brn-odd { background: #fff; }
	.brn-table td { padding: 0; width: auto; }
	.brn-table td.brn-col-thumb { position: absolute; left: 4px; top: 14px; }
	.brn-table td.brn-col-title { display: block; }
	.brn-table td.brn-col-type, .brn-table td.brn-col-trad, .brn-table td.brn-col-themes, .brn-table td.brn-col-year { display: inline; font-size: 13px; color: var(--brn-muted); }
	.brn-table td.brn-col-type .brn-type { font-weight: 600; margin-top: 4px; }
	.brn-table td.brn-col-trad::before, .brn-table td.brn-col-themes::before, .brn-table td.brn-col-year::before { content: " · "; }
	.brn-table td.brn-col-year:empty, .brn-table td.brn-col-themes.is-empty { display: none; }
	.brn-thumb { width: 56px; height: 56px; }
	.brn-row__title { font-size: 16px; line-height: 1.35; }
	.brn-covers { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 12px; }
	.brn-cover-item a { font-size: 12px; }
}

/* ---------- Single resource ---------- */
.brn-single__layout { display: flex; flex-wrap: wrap; gap: 48px; }
.brn-single__main { flex: 999 1 600px; min-width: 0; }
.brn-single__aside { flex: 1 1 260px; min-width: 0; font-size: 16px; }
.brn-single__head { display: flex; flex-wrap: wrap; gap: 32px; margin-top: 8px; }
.brn-cover { flex: 0 0 200px; }
.brn-cover img, .brn-cover__img { width: 200px; height: auto; border-radius: 4px; display: block; box-shadow: 0 1px 4px rgba(0,0,0,.18); }
.brn-cover__placeholder {
	display: flex; align-items: flex-end; width: 200px; height: 280px; box-sizing: border-box; padding: 18px; border-radius: 4px;
	background: #7c1f13; color: #fff; font-weight: 800; font-size: 20px; line-height: 1.2;
}
.brn-cover--podcast .brn-cover__placeholder { background: #2f4f6f; }
.brn-cover--video .brn-cover__placeholder { background: #1f1f1f; }
.brn-single__facts { flex: 1 1 320px; min-width: 0; }
.brn-single__head--media .brn-single__facts { flex-basis: 100%; }
.brn-kicker { margin: 0 0 6px; font-size: 14px; font-weight: 700; color: var(--brn-red); letter-spacing: 0.06em; }
.brn-single__title { font-size: clamp(28px, 4vw, 40px); font-weight: 600; line-height: 1.15; margin: 0 0 8px; }
.brn-single__by { font-size: 20px; margin: 0 0 18px; }
.brn-single__by a { font-weight: 600; }
.brn-embed { margin: 4px 0 22px; }
.brn-embed iframe { width: 100%; max-width: 100%; border-radius: 6px; }
.brn-embed iframe[src*="youtube"], .brn-embed iframe[src*="vimeo"] { aspect-ratio: 16 / 9; height: auto; }
.brn-facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: 17px; line-height: 1.5; margin: 0 0 20px; }
.brn-facts dt { font-weight: 700; margin: 0; }
.brn-facts dd { margin: 0; }
.brn-oop { font-size: 16px; margin: 0 0 12px; }
.brn-buttons { display: flex; flex-wrap: wrap; gap: 10px; }
.brn-single__about { margin-top: 40px; }
.brn-single__about > h2 { font-size: 32px; font-weight: 700; margin: 0 0 8px; }

.brn-reviews { margin-top: 44px; border-top: 2px solid var(--brn-ink); padding-top: 24px; }
.brn-reviews__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; }
.brn-reviews__head h2 { font-size: 32px; font-weight: 700; margin: 0; }
.brn-reviews__none { font-size: 17px; margin: 16px 0 0; }
.brn-review { margin-top: 24px; padding-bottom: 22px; border-bottom: 1px solid var(--brn-line); }
.brn-review__by { margin: 0 0 6px; font-size: 16px; }
.brn-review__where { color: var(--brn-muted); }
.brn-review__text { font-size: 17px; line-height: 1.7; }
.brn-review__text p { margin: 0 0 0.8em; }
.brn-review__text p:last-child { margin-bottom: 0; }
.js-brn .brn-clamp:not(.is-open) { max-height: 10.2em; overflow: hidden; -webkit-mask-image: linear-gradient(#000 60%, transparent); mask-image: linear-gradient(#000 60%, transparent); }
.brn-review__more { padding-left: 0; }

.brn-aside__h { font-size: 17px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; margin: 52px 0 12px; line-height: 1.3; }
.brn-aside__h ~ .brn-aside__h { margin-top: 32px; }
.brn-aside__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; line-height: 1.4; }
.brn-aside__list li { margin: 0; }
.brn-aside__list a { font-weight: 600; }
.brn-aside__more { margin: 10px 0 0; font-size: 15px; font-weight: 700; }
.brn-callout { margin-top: 32px; background: var(--brn-tint); border-radius: 6px; padding: 18px; }
.brn-callout p { margin: 0 0 10px; }
.brn-callout a { font-weight: 700; }

/* ---------- Forms ---------- */
.brn-form { margin-top: 20px; background: var(--brn-tint); border-radius: 6px; padding: 24px; display: flex; flex-direction: column; gap: 16px; font-size: 16px; }
.brn-form h3 { font-size: 20px; font-weight: 700; margin: 0; }
.brn-form__intro { margin: 0; font-size: 15px; line-height: 1.5; }
.brn-form__row { display: flex; flex-wrap: wrap; gap: 14px; }
.brn-form__row > .brn-field { flex: 1 1 220px; }
.brn-help { font-size: 13px; color: var(--brn-muted); line-height: 1.5; }
.brn-form__actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.brn-form__error { margin: 0; color: #8a2424; font-weight: 700; }
.brn-field.has-error input, .brn-field.has-error textarea { border-color: #b32d2e; border-width: 2px; }
.brn-field__error { color: #8a2424; font-size: 14px; font-weight: 600; }
.brn-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.brn-thanks { margin-top: 20px; background: #eef5ee; border: 1px solid #2f6b3a; border-radius: 6px; padding: 18px 20px; font-size: 16px; line-height: 1.6; }
.brn-thanks p { margin: 0 0 8px; }
.brn-thanks__h { font-weight: 700; font-size: 20px; }
.brn-thanks__links { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
.brn-note { background: var(--brn-tint); padding: 12px 16px; border-radius: 6px; }

.brn-suggest { max-width: 820px; }
.brn-suggest__intro { font-size: 18px; line-height: 1.6; margin: 0 0 26px; }
.brn-form--suggest { background: none; padding: 0; gap: 22px; }
.brn-form__row--you { padding-top: 14px; border-top: 1px solid var(--brn-line); }
.brn-typepick { border: 0; padding: 0; margin: 0; }
.brn-typepick legend { margin-bottom: 8px; padding: 0; }
.brn-pill { display: inline-block; margin: 0 8px 8px 0; position: relative; }
.brn-pill input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.brn-pill span {
	display: inline-flex; align-items: center; min-height: 48px; padding: 0 20px; border-radius: 30px; box-sizing: border-box;
	border: 2px solid var(--brn-red); background: #fff; color: var(--brn-red); font-size: 16px; font-weight: 700; cursor: pointer;
}
.brn-pill input:checked + span { background: var(--brn-red); color: #fff; }
.brn-pill input:focus-visible + span { outline: 3px solid #2f6fb0; outline-offset: 2px; }

/* ---------- [brn_library_by] on teacher pages ---------- */
.brn-by__title { margin: 0 0 12px; }
.brn-by__tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.brn-by__tab {
	min-height: 40px; padding: 6px 16px; border-radius: 30px; border: 2px solid var(--brn-red); background: #fff;
	color: var(--brn-red); font: inherit; font-size: 15px; font-weight: 700; line-height: 1.2; cursor: pointer; box-shadow: none;
}
.brn-by__tab:hover { background: #fbeceb; }
.brn-by__tab[aria-pressed="true"] { background: var(--brn-red); color: #fff; }
.brn-by__count { font-weight: 500; }
.brn-by__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px 24px; }
.brn-by__item { display: flex; gap: 14px; align-items: flex-start; margin: 0; font-size: 16px; line-height: 1.4; }
.brn-by__item[hidden] { display: none; }
/* Kadence pads lists inside page content; this list carries its own layout. */
.entry-content .brn-by__list, .brn-lib .brn-by__list { padding-left: 0; margin-left: 0; }
/* Every thumbnail the same book-shaped box, never squeezed by a long title. */
.brn-by__thumb { flex: 0 0 56px; width: 56px; height: 74px; padding-bottom: 6px; font-size: 9px; letter-spacing: 0.06em; }
.brn-by__thumb.brn-thumb--img { padding: 0; background: #f2f2f2; }
.brn-by__text { min-width: 0; flex: 1 1 auto; }
.brn-by__link { font-weight: 700; overflow-wrap: anywhere; }
