:root{font-family:system-ui,-apple-system,"Segoe UI",Arial,sans-serif;color:#203044;background:#f5f7fa}*{box-sizing:border-box}body{margin:0;line-height:1.55}.wrap{max-width:1000px;margin:auto;padding:0 22px}header{background:#163d60;color:white;padding:32px 0}header h1{font-size:clamp(1.65rem,4vw,2.6rem);margin:4px 0}.eyebrow{letter-spacing:.05em;text-transform:uppercase;font-size:.75rem;font-weight:700;color:#d3e4f0}header p{margin:6px 0}main{padding-top:24px!important;padding-bottom:48px!important}.notice{background:#fff8e6;border-left:4px solid #bd8b26;padding:13px 16px;margin-bottom:20px}.controls,.print-controls{background:white;border:1px solid #dce3eb;border-radius:12px;padding:22px;margin-bottom:20px}label{display:block;font-weight:650;font-size:.9rem;margin-bottom:6px}input[type=search],select{width:100%;border:1px solid #a9b8c8;border-radius:7px;padding:11px;font:inherit;background:white;color:inherit}.split{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:15px}.muted{color:#596c7c}.small{font-size:.85rem}.results{display:grid;gap:12px}.entry{background:white;border:1px solid #dce3eb;border-radius:10px;padding:16px 20px}.entry h3{margin:0 0 5px;color:#163d60;font-size:1.1rem}.entry p{margin:0}.entry .translation{margin-top:12px;border-top:1px solid #e6eaf0;padding-top:10px}.entry .translation strong{display:block}.id{font-size:.75rem;color:#738394;float:right}#pagination{display:flex;gap:10px;justify-content:center;align-items:center;margin:24px 0 34px}.checks{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:8px;margin:15px 0}.check{font-weight:400;display:flex;align-items:center;gap:8px}button{border:0;background:#165b87;color:white;border-radius:7px;padding:11px 20px;font:inherit;font-weight:650;cursor:pointer}button:disabled{opacity:.45;cursor:not-allowed}button:hover:not(:disabled){background:#104769}.print-controls h2{margin-top:0}footer{border-top:1px solid #dce3eb;padding:22px 0;color:#607181;font-size:.85rem}@media(max-width:550px){.split{grid-template-columns:1fr}.controls,.print-controls{padding:15px}}

.controls h2{margin:0 0 6px}.language-grid{display:grid;grid-template-columns:repeat(var(--cols,2),minmax(0,1fr));gap:12px;margin-top:12px}.language-cell{min-width:0;background:#f7f9fc;border:1px solid #e1e7ef;border-radius:8px;padding:12px;overflow-wrap:anywhere}.language-cell .lang-title{font-size:.76rem;color:#49667f;text-transform:uppercase;letter-spacing:.025em;font-weight:750;margin-bottom:5px}.language-cell strong{display:block;color:#173d60}.language-cell p{margin:5px 0 0}.language-cell .missing{color:#66717b;font-style:italic}.check input:disabled{opacity:.5}.check:has(input:disabled){color:#78838d}.check{cursor:pointer}@media(max-width:850px){.language-grid{grid-template-columns:repeat(min(2,var(--cols,2)),minmax(0,1fr))}}@media(max-width:540px){.language-grid{grid-template-columns:1fr}}

.search-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:16px}.search-head label{margin:0}.search-head button{padding:9px 14px}.focused-print{outline:3px solid #165b87;outline-offset:3px}#printControls{scroll-margin-top:20px}@media(max-width:500px){.search-head{align-items:flex-start;flex-direction:column}}

/* Vertical language selection and stacked language results */
.checks{grid-template-columns:1fr;gap:7px}
.language-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}

/* Consistent section headings and side-by-side language comparisons */
.search-head h2{margin:0;font-size:1.5em;font-weight:700;line-height:1.3}
.language-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
@media(max-width:540px){.language-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px}.language-cell{padding:8px}}

/* Always show all selected languages side by side, up to four.
   On narrow screens the result scrolls horizontally instead of stacking. */
.language-grid{display:grid!important;grid-template-columns:repeat(var(--cols,2),minmax(0,1fr))!important;gap:12px;overflow-x:auto}
@media(max-width:750px){
  .language-grid{grid-template-columns:repeat(var(--cols,2),minmax(180px,1fr))!important}
}

/* Search mode selector */
.search-mode{border:0;padding:0;margin:12px 0 4px;display:flex;flex-wrap:wrap;align-items:center;gap:12px 22px}
.search-mode legend{font-size:.85rem;color:#596c7c;padding:0;margin-bottom:6px}
.search-mode label{display:inline-flex;align-items:center;gap:7px;margin:0;font-weight:400;cursor:pointer}
.language-cell .lang-title{font-size:.69rem;font-weight:600;letter-spacing:.055em;color:#657b8d}

/* Search scope alongside heading */
.search-head-left{display:flex;align-items:center;flex-wrap:wrap;gap:12px 24px;min-width:0}
.search-head-left h2{white-space:nowrap}
.search-head .search-mode{display:flex;align-items:center;gap:10px 20px;margin:0;padding:0}
.search-head .search-mode label{white-space:nowrap;font-size:.85rem}
@media(max-width:780px){.search-head{flex-wrap:wrap}.search-head-left{gap:10px}}
/* Advanced printable glossary */
.advanced-print{margin:18px 0;padding:13px;border:1px solid #dce3eb;border-radius:8px}
.advanced-print summary{cursor:pointer;font-weight:650;color:#163d60}
.advanced-inner{padding-top:15px}
.advanced-actions{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin:12px 0}
.advanced-actions .check{margin:0}
button.secondary{background:#e7edf3;color:#163d60}
.print-matches{max-height:270px;overflow-y:auto;border:1px solid #e1e7ef;border-radius:7px;padding:8px 12px}
.print-match{padding:3px 0}

.search-tips{margin:12px 0;font-size:.9rem}.search-tips summary{cursor:pointer;color:#164a70}.search-tips p{line-height:1.6}.search-tips code{background:#e9edf2;padding:1px 4px;border-radius:3px}.search-error{color:#a32222;margin:5px 0}.search-error:empty{display:none}

#specificPrint{scroll-margin-top:20px}#specificPrint h2{margin:0 0 8px}#specificPrint .advanced-inner{padding-top:8px}#printSpecificBtn{margin-top:14px}

/* Compact language checkboxes, keeping their vertical arrangement. */
.checks{gap:2px!important;margin:7px 0!important}
.checks .check{margin:0!important;padding:1px 0!important;line-height:1.3!important;min-height:0!important}
.checks .check input{margin:0 4px 0 0}
/* Search controls share a line; printing shortcut occupies the next line. */
.search-head{display:block!important;margin-top:13px}
.search-head-left{display:flex;align-items:center;gap:12px 22px;flex-wrap:wrap}
.search-head-left h2{margin:0;line-height:1.3}
.search-head .search-mode{margin:0!important}

/* Mandatory English stays blue and fully legible while remaining non-interactive. */
.checks .check:has(input[value="en"]:disabled){color:inherit;cursor:default}
.checks .check input[value="en"]:disabled{opacity:1;accent-color:#0878f9;cursor:default}
/* Draw mandatory English checkbox in the same selected-blue style, despite disabled state. */
.checks input[type="checkbox"][value="en"]:disabled{
  appearance:none;-webkit-appearance:none;
  width:13px;height:13px;min-width:13px;
  border:1px solid #0878f9;border-radius:2px;
  background-color:#0878f9;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8l3.3 3.3L13 4.5' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size:contain;background-repeat:no-repeat;background-position:center;
  opacity:1!important;vertical-align:middle;
}


/* Mockup-inspired light, expansive branded design; functional V13 layout preserved. */
:root{color:#132744;background:#edf4fa}
body{background:linear-gradient(180deg,#e5f1fb 0,#f6f9fc 560px,#f6f9fc 100%)}
.wrap{max-width:1320px;padding-left:30px;padding-right:30px}
.brand-header{position:relative;overflow:hidden;background:linear-gradient(108deg,#d8eff9 0%,#f4f9ff 49%,#e2effb 100%);color:#0b284e;padding:46px 0 42px;border-bottom:5px solid #1477b4}
.brand-header:before{content:"";position:absolute;inset:auto -7% -80px 48%;height:240px;border-radius:50%;border-top:42px solid rgba(43,135,195,.17);transform:rotate(-12deg);pointer-events:none}
.brand-header:after{content:"";position:absolute;top:-160px;left:-160px;width:550px;height:460px;background:radial-gradient(ellipse,rgba(44,148,198,.20),transparent 70%);pointer-events:none}
.brand-header-inner{position:relative;z-index:1;display:flex;align-items:center;gap:50px}
.brand-lockup{display:flex;align-items:center;gap:14px;flex:0 0 320px;padding-right:35px;border-right:1px solid rgba(34,88,130,.26)}
.brand-mark{width:75px;height:76px;flex:none;filter:drop-shadow(0 2px 1px rgba(12,66,102,.08))}
.brand-name{font-size:3rem;font-weight:850;line-height:1;letter-spacing:-.055em;color:#0b3765}
.brand-full{font-size:.82rem;font-weight:600;line-height:1.35;color:#365b76;margin-top:10px}
.brand-heading{min-width:0}
.brand-heading h1{font-size:clamp(2.2rem,4.2vw,3.8rem);font-weight:780;letter-spacing:-.035em;line-height:1.1;margin:0 0 14px;color:#092c59}
.brand-heading p{font-size:clamp(.98rem,1.45vw,1.35rem);margin:0;color:#3b526b;line-height:1.45}
main.wrap{padding-top:28px!important}
.notice{background:#f0f7fd;border-left:4px solid #2a91c8;border-radius:0 8px 8px 0;color:#31546d}
.controls,.print-controls,.entry{box-shadow:0 4px 20px rgba(17,62,105,.055);border-color:#d4e3f0}
.controls,.print-controls{border-radius:13px}
.controls h2,.print-controls h2{color:#0b305b}
input[type=search],select{border-color:#bfd0df;border-radius:8px}
input[type=search]:focus,select:focus{outline:2px solid #3c95ce;outline-offset:1px}
button{background:#1462a1;border-radius:8px}
button:hover:not(:disabled){background:#0e4e82}
.language-cell{background:#f5f9fe;border-color:#dbe6f2}
.entry h3,.language-cell strong{color:#103d70}
.print-controls{scroll-margin-top:20px}
@media(max-width:800px){.brand-header-inner{gap:25px}.brand-lockup{flex-basis:235px;padding-right:20px}.brand-mark{width:56px}.brand-name{font-size:2.4rem}.brand-full{font-size:.68rem}.brand-heading h1{font-size:2.2rem}}
@media(max-width:650px){.wrap{padding-left:17px;padding-right:17px}.brand-header{padding:26px 0}.brand-header-inner{flex-direction:column;align-items:flex-start;gap:20px}.brand-lockup{border-right:0;border-bottom:1px solid rgba(34,88,130,.25);padding:0 0 16px;width:100%;flex-basis:auto}.brand-heading h1{font-size:2rem}.brand-heading p{font-size:1rem}}

/* Result-linked print actions */
#notice[hidden]{display:none!important}
.hardcopy-links{font-size:.91em}
.hardcopy-links a{color:#1262a2;text-decoration:underline;text-underline-offset:2px}

/* Explicit search submission controls hardcopy-link visibility */
.main-search-form{display:flex;gap:10px;align-items:stretch}
.main-search-form input{flex:1;min-width:0}
.main-search-form button{flex:0 0 auto;white-space:nowrap}
@media(max-width:480px){.main-search-form{flex-wrap:wrap}.main-search-form button{width:100%}}

/* Show the results summary near the top after an explicit search. */
#count { scroll-margin-top: 12px; }

/* Dedicated, intentional results heading and hardcopy actions. */
.results-summary{background:#fff;border:1px solid #d4e3f0;border-radius:13px;padding:18px 26px;margin:0 0 18px;box-shadow:0 4px 20px rgba(17,62,105,.055)}
.results-summary #count{margin:0;color:#103d70;font-size:1.1rem;font-weight:700;line-height:1.5;scroll-margin-top:14px}
.results-summary .hardcopy-links{display:inline;font-size:inherit;font-weight:inherit;color:inherit;line-height:inherit}
.results-summary .hardcopy-links a{color:#1768ad;font-weight:400;text-decoration:underline}
@media(max-width:550px){.results-summary{padding:15px}}

/* Keep the results-count panel hidden until a search is submitted. */
.results-summary[hidden]{display:none!important}

/* Search-first landing screen: no entries or print panels before submission. */
.results[hidden],#pagination[hidden],.print-controls[hidden],.results-summary[hidden]{display:none!important}
.results-summary{scroll-margin-top:0}

/* Online advanced search is independent of search scope. */
.online-advanced-toggle{display:inline-flex;align-items:center;gap:7px;white-space:nowrap;font-size:inherit;cursor:pointer}
.online-advanced-toggle input{accent-color:#2879db}
.online-search-tips{margin:10px 0 2px;padding:12px 16px;border:1px solid #d7e3f0;border-radius:10px;background:#f5f9fd}
.online-search-tips p{margin:8px 0 0;line-height:1.6}
.online-search-tips code{font-size:.95em}

/* Compact advanced-search guidance */
.search-tips p{font-size:.85rem;line-height:1.45}
.search-tips p code{font-size:inherit}

/* Search tips headings are understated, not bold. */
.search-tips summary{font-weight:400!important}

/* Ensure the tips heading stays regular weight regardless of theme. */
details.search-tips > summary.tips-heading{font-weight:400!important;font-family:inherit!important;}

/* Checkbox label: normal weight, including any inherited label styles. */
label.online-advanced-toggle{font-weight:400!important;}

/* One point smaller guidance text; preserve existing formatting. */
.online-search-tips p, .search-tips p{font-size:calc(.85rem - 1pt)}

/* V33: the checkbox caption is explicitly regular weight; tips copy is 1pt smaller. */
label.online-advanced-toggle, label.online-advanced-toggle * {font-weight:400!important;}
#onlineSearchTips > p {font-size:calc(.85rem - 1pt)!important;}
#onlineSearchTips > summary {font-weight:400!important;}

/* V34: align checkbox caption with the two radio labels exactly. */
.search-head label.online-advanced-toggle{font-size:.85rem!important;font-weight:400!important;line-height:inherit!important;}

/* Explicitly separate the language searched from languages displayed. */
.main-search-form .search-language-picker{display:flex;flex:0 0 210px;flex-direction:column;gap:3px;font-size:13px;font-weight:400;line-height:1.2;color:#163b65}
.main-search-form .search-language-picker select{width:100%;height:42px;padding:7px 9px;border:1px solid #b8cbe0;border-radius:8px;background:#fff;color:#163b65;font:inherit;font-size:14px}
@media(max-width:680px){.main-search-form{flex-wrap:wrap}.main-search-form .search-language-picker{flex:1 1 100%}.main-search-form input#query{flex:1 1 60%}}

/* V36: search-language choices, all visible on one line at desktop widths. */
.main-search-form .search-language-options{flex:1 1 100%;display:flex;align-items:center;gap:14px;min-width:0;margin:0;padding:0;border:0;font-size:.85rem;color:#163b65}
.main-search-form .search-language-options legend{float:left;width:auto;margin:0 14px 0 0;padding:0;font-size:.85rem;font-weight:400}
.main-search-form .search-language-radio-row{display:flex;align-items:center;gap:15px;flex-wrap:wrap}
.main-search-form .search-language-radio-row label{display:inline-flex;align-items:center;gap:4px;white-space:nowrap;font-size:.85rem;font-weight:400;cursor:pointer}
.main-search-form .search-language-radio-row input{margin:0;accent-color:#1866a3}
@media(max-width:700px){.main-search-form .search-language-options{display:block}.main-search-form .search-language-options legend{float:none;margin-bottom:7px}.main-search-form .search-language-radio-row{gap:9px 14px}}

/* V38: language selector occupies its own row; search input must remain full-width. */
.main-search-form{flex-wrap:wrap!important}
.main-search-form .search-language-options{flex:0 0 100%!important;width:100%;box-sizing:border-box}
.main-search-form input#query{flex:1 1 300px!important;width:auto!important;min-width:180px!important;box-sizing:border-box}
.main-search-form button#mainSearchButton{flex:0 0 auto}
@media(max-width:480px){.main-search-form input#query{flex-basis:100%!important}.main-search-form button#mainSearchButton{width:100%}}

/* V40: distinguish the search-language prompt without changing the choices. */
.main-search-form .search-language-options legend{font-style:italic}

/* V41: italicize and vertically align the prompt and every search-language option. */
.main-search-form .search-language-options{display:flex!important;align-items:center!important;gap:14px!important;font-style:italic}
.main-search-form .search-language-prompt{display:inline-flex;align-items:center;flex:0 0 auto;line-height:1.35;font-size:.85rem;font-style:italic;font-weight:400}
.main-search-form .search-language-radio-row{display:flex;align-items:center;gap:15px;line-height:1.35;font-style:italic}
.main-search-form .search-language-radio-row label{display:inline-flex;align-items:center;gap:5px;line-height:1.35;font-style:italic}
.main-search-form .search-language-radio-row input{vertical-align:middle;flex:0 0 auto;margin:0}
@media(max-width:700px){.main-search-form .search-language-options{flex-wrap:wrap}.main-search-form .search-language-radio-row{gap:9px 14px}}

/* Version 42: print settings appear only on demand. */
#resultsPrintLinks{margin:14px 0 30px;padding:14px 18px;text-align:center;font-size:.95rem;color:#123c68}
#resultsPrintLinks a{color:#2266a8;text-decoration:underline}
#printDialog{position:fixed;inset:0;margin:auto;width:min(760px,calc(100vw - 30px));max-height:calc(100vh - 35px);overflow:auto;border:1px solid #cad9e9;border-radius:14px;padding:0;box-shadow:0 18px 55px #163d6040;background:#fff;color:#123c68}
#printDialog::backdrop{background:#0d244a80}
#printDialog .print-controls{margin:0;border:0;box-shadow:none;padding:26px}
#printDialog .print-dialog-close{position:absolute;right:12px;top:10px;border:0;background:transparent;color:#345;font-size:26px;line-height:1;padding:4px 10px;cursor:pointer}
#printDialog h2{padding-right:30px}

/* Keep both print links inline with the result count. */
.results-summary .summary-print-links{display:inline;font:inherit;font-weight:inherit}
.results-summary #count{display:inline}

/* Horizontal search filters */
.search-filters{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr) minmax(0,1fr) auto;gap:12px;align-items:end;margin:14px 0 12px}
.search-filters label{display:flex;flex-direction:column;gap:5px;font-size:.85rem;color:#163b65;font-weight:500}
.search-filters select{width:100%;min-width:0;height:42px;border:1px solid #b8cbe0;border-radius:8px;background:white;padding:7px 9px;color:#163b65;font:inherit;font-size:14px}
.search-filters button{min-height:42px;white-space:nowrap;padding:8px 13px}
@media(max-width:850px){.search-filters{grid-template-columns:repeat(3,minmax(0,1fr))}.search-filters button{grid-column:1/-1;justify-self:end}}
@media(max-width:540px){.search-filters{grid-template-columns:1fr}.search-filters button{grid-column:auto;justify-self:stretch}}

/* Review-status language selector */
#displayChecks.checks{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:20px!important;align-items:start}
.review-group{min-width:0;padding:8px 12px;border:1px solid #dce3eb;border-radius:8px}
.review-group h3{font-size:.95rem;margin:0 0 9px;color:#163d60;border-bottom:1px solid #dce3eb;padding-bottom:7px}
.review-group .check{font-weight:400;display:flex;align-items:center;gap:7px;margin:5px 0!important}
@media(max-width:480px){#displayChecks.checks{gap:8px!important}.review-group{padding:7px}.review-group .check{font-size:.8rem}}

/* Compact single-spaced language selection, preserving two columns. */
#displayChecks.checks{column-gap:20px!important;row-gap:0!important;align-items:start!important;margin-top:7px!important;margin-bottom:7px!important}
#displayChecks .check{line-height:1.15!important;margin:0!important;padding:1px 0!important;min-height:0!important}
#displayChecks .check input{margin:0 4px 0 0!important}

/* Compact layout: remove unused whitespace above the language selector. */
.brand-header{padding:20px 0 18px!important}
.brand-header-inner{gap:26px!important}
.brand-lockup{flex-basis:255px!important;padding-right:22px!important}
.brand-mark{width:58px!important;height:60px!important}
.brand-name{font-size:2.45rem!important}
.brand-full{margin-top:4px!important;line-height:1.2!important}
.brand-heading h1{font-size:clamp(1.9rem,3.3vw,3rem)!important;margin-bottom:5px!important;line-height:1.08!important}
.brand-heading p{font-size:clamp(.9rem,1.25vw,1.1rem)!important;line-height:1.25!important}
main.wrap{padding-top:10px!important}
.collection-nav{margin-top:0!important;margin-bottom:10px!important;padding-top:6px!important;padding-bottom:6px!important;gap:6px!important}
.collection-nav a{padding-top:7px!important;padding-bottom:7px!important}
#terminology .controls{padding-top:14px!important;padding-bottom:15px!important}
#terminology .controls>h2{margin-top:0!important;margin-bottom:3px!important}
#terminology .controls>p.muted.small{margin-top:0!important;margin-bottom:4px!important}
#displayChecks.checks{margin:3px 0 5px!important;row-gap:0!important}
#displayChecks .check{padding:0!important;line-height:1.15!important}
#displayCount{margin:4px 0 9px!important}
@media(max-width:650px){.brand-header{padding:14px 0!important}.brand-header-inner{gap:10px!important}.brand-lockup{padding-bottom:8px!important}}

/* Small-laptop first-screen target: 1366x768 CSS pixels, 100% zoom.
   No scrollbar is hidden; results retain their normal document flow. */
@media (min-width: 901px) and (max-height: 800px) {
 .brand-header{padding:10px 0 9px!important;border-bottom-width:3px!important}
 .brand-header-inner{gap:18px!important}
 .brand-lockup{flex-basis:220px!important;padding-right:14px!important;gap:9px!important}
 .brand-mark{width:42px!important;height:46px!important}
 .brand-name{font-size:2rem!important}
 .brand-full{font-size:.7rem!important;margin-top:2px!important;line-height:1.08!important}
 .brand-heading h1{font-size:clamp(1.65rem,2.8vw,2.5rem)!important;line-height:1.04!important;margin:0 0 2px!important}
 .brand-heading p{font-size:.92rem!important;line-height:1.12!important;margin:0!important}
 main.wrap{padding-top:4px!important;padding-bottom:0!important}
 .collection-nav{padding:2px 0!important;margin:0 0 5px!important;gap:2px!important}
 .collection-nav a{padding:5px 8px!important;line-height:1.15!important}
 #terminology .controls{padding:9px 15px 10px!important;margin-bottom:5px!important}
 #terminology .controls>h2{font-size:1.35rem!important;line-height:1.12!important;margin:0 0 1px!important}
 #terminology .controls>p.muted.small{margin:0 0 2px!important;line-height:1.15!important}
 #displayChecks.checks{margin:2px 0!important;gap:0 14px!important}
 #displayChecks .check{line-height:1.05!important;padding:0!important;margin:0!important;font-size:.83rem!important}
 #displayCount{margin:2px 0 4px!important;line-height:1.1!important}
 .search-head{margin-top:3px!important}
 .search-head h2{font-size:1.2rem!important;line-height:1.1!important}
 .search-filters{margin:5px 0!important;gap:7px!important}
 .search-filters label{gap:2px!important;line-height:1.12!important}
 .search-filters select{height:33px!important;padding:4px 7px!important}
 .search-filters button{min-height:33px!important;padding:5px 9px!important}
 .main-search-form{margin:4px 0 0!important}
 .main-search-form input#query{padding:7px 10px!important;min-height:36px!important}
 .main-search-form button#mainSearchButton{padding:6px 16px!important}
 footer{padding:7px 0!important;font-size:.75rem!important}
}

/* A little deliberate breathing room above each section heading. */
#terminology .controls>h2{margin-top:8px!important;margin-bottom:3px!important}
#terminology .search-head{margin-top:11px!important}
/* The language selector has been removed: three filter controls remain. */
.search-filters{grid-template-columns:minmax(0,1.25fr) minmax(0,1fr) auto!important}
@media(max-width:850px){.search-filters{grid-template-columns:repeat(2,minmax(0,1fr))!important}.search-filters button{grid-column:1/-1}}
@media(max-width:540px){.search-filters{grid-template-columns:1fr!important}}
#languageChoiceDialog{border:1px solid #c7d9ea;border-radius:12px;padding:24px;width:min(440px,calc(100vw - 30px));box-shadow:0 15px 45px #173e6040;color:#143c65}
#languageChoiceDialog::backdrop{background:#142b4b77}
#languageChoiceDialog h2{margin:0 0 8px}
#languageChoiceDialog p{margin:0 0 16px}
#languageChoiceOptions{display:flex;gap:9px;flex-wrap:wrap;margin-bottom:16px}
#languageChoiceOptions button{padding:9px 15px;border:1px solid #bdd0e2;border-radius:8px;background:#23639d;color:white;cursor:pointer}
#cancelLanguageChoice{background:white;color:#24476a;border:1px solid #bccfdf;border-radius:8px;padding:8px 14px;cursor:pointer}

/* Compact, clear initial search layout. */
#terminology .controls>h2{margin:5px 0 10px!important}
#terminology .available-languages-heading{font-size:1.05rem;color:#153960;margin:0 0 3px;line-height:1.2}
#terminology .search-head{margin-top:8px!important}
#terminology .search-head-left:empty{display:none}
#terminology .search-entry-label{display:block;margin:15px 0 7px;font-size:1.05rem;font-weight:700;color:#0b305b}
#terminology .main-search-form{margin-top:0!important}
#terminology .main-search-form #query{border:2px solid #447fbb!important;box-shadow:0 0 0 2px rgba(68,127,187,.07);background:#fff}
#terminology .main-search-form #query:focus{outline:3px solid rgba(52,114,185,.2);outline-offset:1px}

/* Give the search input a clearly defined, spacious panel, without wasting screen height. */
#terminology .search-entry-panel{margin-top:16px;padding:14px 16px;background:#edf5fd;border:1px solid #bdd6ec;border-radius:12px;box-shadow:0 2px 8px rgba(23,76,124,.08)}
#terminology .search-entry-panel .main-search-form{margin:0!important;display:flex;align-items:stretch;gap:12px}
#terminology .search-entry-panel #query{min-width:0;flex:1;min-height:48px!important;padding:10px 15px!important;font-size:1.05rem;border:2px solid #3c80bf!important;border-radius:9px!important;background:white!important}
#terminology .search-entry-panel #mainSearchButton{min-height:48px!important;padding:10px 23px!important}
#terminology .search-filters{margin-bottom:9px!important}
#terminology .search-head{margin-top:15px!important}
#terminology .controls{padding-top:17px!important;padding-bottom:18px!important}
#terminology .controls>h2{margin-top:10px!important;margin-bottom:9px!important}
@media(min-width:901px) and (max-height:800px){
 #terminology .controls{padding-top:14px!important;padding-bottom:15px!important}
 #terminology .search-entry-panel{margin-top:11px!important;padding:11px 13px!important}
 #terminology .search-head{margin-top:12px!important}
 #terminology .search-entry-panel #query,#terminology .search-entry-panel #mainSearchButton{min-height:44px!important}
}
@media(max-width:550px){#terminology .search-entry-panel{padding:10px}#terminology .search-entry-panel .main-search-form{gap:7px}#terminology .search-entry-panel #mainSearchButton{padding:8px 12px!important}}

/* Language ambiguity dialog: explicit dropdown and actions */
#languageChoiceDialog{max-width:min(450px,calc(100vw - 32px));width:100%;padding:22px;border:1px solid #b7cadd;border-radius:12px;box-shadow:0 15px 45px #142e4a40}
#languageChoiceDialog::backdrop{background:rgba(15,35,55,.48)}
#languageChoiceDialog h2{margin:0 0 10px}
#languageChoiceDialog p{margin:0 0 16px}
#languageChoiceDialog label{display:block;margin-bottom:7px;font-weight:600}
#languageChoiceSelect{display:block;width:100%;padding:10px;border:1px solid #8aaac7;border-radius:7px;background:white;color:#17344d}
#languageChoiceDialog .language-choice-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}

/* Print dialog: generous spacing, with the search scope controlling definitions. */
#printDialog{width:min(680px,calc(100vw - 30px))}
#printDialog .print-controls{padding:38px 42px 40px}
#printDialog .print-controls h2{margin:0 0 18px;line-height:1.25}
#printDialog .print-intro{margin:0 0 32px;line-height:1.7;max-width:55ch}
#printDialog .print-settings{display:grid;grid-template-columns:1fr;gap:28px;margin-bottom:34px;max-width:540px}
#printDialog .print-setting label{display:block;margin:0 0 12px;font-size:1rem}
#printDialog .print-setting select{min-height:52px;padding:12px 16px}
#printDialog #printBtn{margin-bottom:14px;min-height:48px}
#printDialog .print-controls>.muted{margin:8px 0 0;line-height:1.6}
@media(max-width:550px){#printDialog .print-controls{padding:28px 22px 30px}#printDialog .print-settings{gap:22px;margin-bottom:26px}#printDialog .print-intro{margin-bottom:24px}}

/* V10: compact language columns; navigation tab is the section heading. */
#terminology #displayChecks.checks{width:min(100%,500px)!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;column-gap:18px!important;margin-top:9px!important;margin-bottom:12px!important}
#terminology .available-languages-heading{margin-top:8px!important}
@media(max-width:550px){#terminology #displayChecks.checks{width:100%!important;column-gap:12px!important}}

/* CTTIC branding — exact user-provided mark and its navy / silver palette */
:root{--cttic-navy:#193c69;--cttic-silver:#b7c8d6}
.brand-header{background:linear-gradient(105deg,#193c69 0%,#214c7d 58%,#193c69 100%)!important;border-bottom:3px solid #9db6c9!important}
.brand-header .brand-header-inner{align-items:center!important}
.brand-header .brand-lockup{flex:0 0 auto!important;min-width:0!important;padding-right:20px!important;border-right:1px solid rgba(230,238,246,.32)!important}
.brand-header .cttic-logo{display:block;width:180px;max-width:100%;height:auto;object-fit:contain;border-radius:2px}
.brand-header .brand-heading h1{color:#f7fbff!important}
.brand-header .brand-heading p{color:#dbe6ef!important}
.collection-nav a[aria-current="page"]{color:#193c69!important}
#terminology .search-entry-panel{background:#edf3f8!important;border-color:#c1d0df!important}
#terminology .search-entry-panel #query{border-color:#376394!important}
@media(max-width:600px){.brand-header .cttic-logo{width:125px}.brand-header .brand-lockup{padding-right:10px!important}}

/* Group multilingual search results by the language in which the query matched. */
#results .search-language-group{margin:0 0 32px}
#results .search-language-heading{font-size:1.18rem;line-height:1.35;color:#163d69;background:#eaf2f9;border-left:4px solid #356c9f;border-radius:5px;padding:12px 16px;margin:18px 0 14px}
#results .search-language-group+.search-language-group{border-top:1px solid #d4e0ec;padding-top:16px}

/* Search text within glossary results */
.query-hit{font-style:italic!important}

/* V31: Bold the entire online results summary, including its links. */
.results-summary, .results-summary .summary-print-links, .results-summary .summary-print-links a{font-weight:700!important}

/* V35: one uniform blue field behind the transparent white CTTIC wordmark */
.brand-header{background:#193c69!important}
.brand-header .cttic-logo{border-radius:0!important}

/* Source collection identification only; original selector/layout unchanged. */
.collection-result-heading{font-size:1.04rem;font-weight:700;color:#244665;border-bottom:1px solid #b9c7d4;margin:1.3rem 0 .65rem;padding:0 0 .4rem}.collection-result-group:first-child>.collection-result-heading{margin-top:.4rem}

/* Collection heading precedes language-match groups; both have a blue left accent. */
.collection-result-heading{background:#eaf1f8;border-left:5px solid #416b9f;border-bottom:0;border-radius:5px;padding:14px 18px;margin:1.3rem 0 .7rem;line-height:1.4}
.collection-result-group:first-child>.collection-result-heading{margin-top:.4rem}
.search-language-group{margin:0 0 1.25rem}
.search-language-heading{margin:.8rem 0 1rem}

/* V54: collection is primary heading; match-language heading is secondary.
   With a single selected collection, match-language heading becomes primary. */
#results .collection-result-heading{font-size:1.22rem;font-weight:750;background:#eaf1f8;border-left:5px solid #416b9f;border-bottom:0;border-radius:5px;padding:14px 18px;margin:1.3rem 0 .85rem;line-height:1.4}
#results .search-language-heading.search-language-subheading{background:transparent;border-left:0;border-radius:0;padding:4px 0 8px;margin:14px 0 12px;font-size:1.04rem;font-weight:650;color:#244665;border-bottom:1px solid #cbd7e3}
#results .collection-result-group:first-child>.search-language-group:first-child>.search-language-heading{margin-top:.4rem}

/* V55: primary collection heading only for results spanning multiple collections;
   otherwise the matching-language heading is the primary blue heading. */
#results .collection-result-group > .collection-result-heading{
  background:#eaf1f8;border-left:5px solid #416b9f;border-bottom:0;
  border-radius:5px;padding:14px 18px;margin:18px 0 12px;
  font-size:1.22rem;line-height:1.4;font-weight:750;color:#163d69;
}
#results .collection-result-group .search-language-heading.search-language-subheading{
  background:transparent;border-left:0;border-radius:0;
  padding:5px 0 9px;margin:12px 0;
  font-size:1.04rem;line-height:1.4;font-weight:650;color:#244665;
  border-bottom:1px solid #cbd7e3;
}
