@font-face{font-family:"Noto Sans";font-style:normal;font-weight:100 900;font-display:swap;
  src:url(../fonts/noto-sans-latin-ext-wght-normal.woff2) format("woff2-variations");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Noto Sans";font-style:normal;font-weight:100 900;font-display:swap;
  src:url(../fonts/noto-sans-latin-wght-normal.woff2) format("woff2-variations");
  unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}

/* Revenue & Disaster Management Department, Govt. of Meghalaya — site stylesheet */

:root {
  --bg: #f4f5ef;
  --surface: #ffffff;
  --ink: #18221d;
  --muted: #55625a;
  --line: #dde2d8;
  --brand: #1b5a44;
  --brand-d: #103a2b;
  --brand-l: #e7f0ea;
  --on-brand: #ffffff;
  --on-brand-muted: #c9ddd2;
  --accent: #d6a03a;
  --link: #12614a;
  --link-hover: #0a3d2e;
  --focus: #0b57d0;
  --chip: #eef2ea;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16, 40, 30, .06), 0 10px 28px -14px rgba(16, 40, 30, .22);
  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Roboto, Arial, sans-serif;
  --border-w: 1px;
}

/* Accessibility colour schemes (replace the old alternate stylesheets) */
html[data-contrast="hc-dark"] {
  --bg: #000; --surface: #000; --ink: #ffeb3b; --muted: #ffeb3b; --line: #ffeb3b;
  --brand: #000; --brand-d: #000; --brand-l: #111; --on-brand: #ffeb3b; --on-brand-muted: #ffeb3b;
  --accent: #ffeb3b; --link: #ffeb3b; --link-hover: #fff; --chip: #111; --focus: #fff;
  --shadow: none; --border-w: 2px;
}
html[data-contrast="hc-light"] {
  --bg: #fff; --surface: #fff; --ink: #000; --muted: #000; --line: #000;
  --brand: #000; --brand-d: #000; --brand-l: #fff; --on-brand: #fff; --on-brand-muted: #fff;
  --accent: #000; --link: #0000b8; --link-hover: #000; --chip: #fff; --focus: #b80000;
  --shadow: none; --border-w: 2px;
}
html[data-spacing="wide"] body { letter-spacing: .06em; word-spacing: .12em; }

*, *::before, *::after { box-sizing: border-box; }
html { font-size: 100%; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 1.0625rem/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--link); text-underline-offset: .18em; text-decoration-thickness: .08em; }
a:hover { color: var(--link-hover); text-decoration-thickness: .14em; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
h1, h2, h3, h4 { line-height: 1.25; color: var(--ink); text-wrap: balance; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.wrap { width: 80%; max-width: none; margin-inline: auto; padding-inline: 1.25rem; }

/* Skip link */
.skip {
  position: absolute; left: .75rem; top: -4rem; z-index: 100; padding: .6rem 1rem;
  background: var(--accent); color: #000; font-weight: 600; border-radius: 0 0 8px 8px; transition: top .15s;
}
.skip:focus { top: 0; color: #000; }

/* ---------- Masthead (white header: emblem, name, search, accessibility) ---------- */
body { border-top: 3px solid var(--brand-d); }
html[data-contrast="hc-dark"] body { border-top-color: var(--ink); }
.masthead { background: var(--surface); border-bottom: var(--border-w) solid var(--line); }
.masthead .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(14rem, 21rem) minmax(0, 1fr); gap: .75rem 2rem; align-items: center; padding-block: 1.2rem; }
.brand { display: flex; align-items: center; gap: .9rem; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand img { width: 3.1rem; height: auto; border-radius: 6px; background: #6b6a3c; padding: .15rem; flex: none; }
.brand-sub { display: block; font-size: 1.05rem; color: var(--ink); line-height: 1.2; }
.brand-name { display: inline; white-space: nowrap; font-size: clamp(1.15rem, 1rem + .9vw, 1.65rem); font-weight: 700; line-height: 1.2; color: var(--ink); letter-spacing: -.005em; }
.head-tools { grid-column: 3; display: flex; align-items: center; gap: 1rem; justify-content: flex-end; min-width: 0; }
.brand { grid-column: 1; min-width: 0; }
.brand img { height: 5.5rem; width: auto; max-width: none; background: none; padding: 0; border-radius: 0; flex: none; }
html[data-contrast="hc-dark"] .brand img { filter: invert(1); }
.search { display: flex; min-width: 0; width: 19rem; border: 1px solid #c9d0c6; border-bottom: 3px solid var(--brand); border-radius: 8px 8px 4px 4px; background: var(--surface); overflow: hidden; }
.masthead .search { grid-column: 2; width: 100%; max-width: 21rem; justify-self: center; }
.masthead .search input[type=search] { padding-block: .7rem; }
html[data-contrast] .search { border: 2px solid var(--ink); }
.search input[type=search] { flex: 1; min-width: 0; font: inherit; font-size: 1rem; padding: .6rem .8rem; color: var(--ink); background: transparent; border: 0; }
.search input[type=search]:focus-visible { outline-offset: -3px; }
.search button { display: grid; place-items: center; width: 3rem; color: var(--brand); background: transparent; border: 0; border-left: 1px solid var(--line); cursor: pointer; }
html[data-contrast] .search button { color: var(--ink); }
.search button:hover { background: var(--brand-l); }
svg.i, .search svg, .tool-btn svg { width: 1.35rem; height: 1.35rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* three header tools: skip to content | Bhashini language | accessibility */
.tool-icons { position: relative; z-index: 70; display: flex; align-items: center; }
.tool-icons > * { display: flex; align-items: center; transform: scale(.92); transform-origin: center; }
.tool-icons > .tool-btn:not(:first-child), .tool-icons > .bhashini-plugin-container:not(:empty) { border-left: 1.5px solid var(--brand); border-radius: 0; margin-left: .35rem; padding-left: .35rem; }
html[data-contrast] .tool-icons > .tool-btn:not(:first-child) { border-left-color: var(--ink); }
.tool-btn { display: grid; place-items: center; width: 2.6rem; height: 2.6rem; color: var(--brand); background: transparent; border: 0; border-radius: 8px; cursor: pointer; text-decoration: none; }
html[data-contrast] .tool-btn { color: var(--ink); }
.tool-btn:hover, .tool-btn[aria-expanded="true"] { background: var(--brand-l); color: var(--brand); }
.tool-btn[aria-label="Skip to main content"] { color: #12614a; }
.tool-btn svg { width: 1.7rem; height: 1.7rem; }
.bhashini-plugin-container { min-width: 0; }
.bhashini-plugin-container:empty { display: none; }

/* ---------- Accessibility drawer ---------- */
.a11y-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 190; }
.a11y-drawer { position: fixed; top: 0; right: 0; bottom: 0; z-index: 200; width: min(24rem, 100vw); overflow-y: auto; background: var(--surface); color: var(--ink); box-shadow: -8px 0 32px rgba(0,0,0,.25); padding: 1.1rem 1.25rem 1.5rem; }
.a11y-backdrop[hidden], .a11y-drawer[hidden] { display: none; }
.a11y-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.1rem; }
.a11y-head h2 { display: flex; align-items: center; gap: .6rem; margin: 0; font-size: 1.2rem; font-weight: 500; }
.a11y-head-ico svg, .a11y-close svg { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.a11y-head-ico { color: var(--brand); display: grid; }
html[data-contrast] .a11y-head-ico { color: var(--ink); }
.a11y-close { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; background: none; border: 0; border-radius: 8px; color: var(--ink); cursor: pointer; }
.a11y-close:hover { background: var(--brand-l); }
.tiles-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.tile {
  display: grid; justify-items: center; align-content: center; gap: .5rem; min-height: 5.6rem; padding: .8rem .4rem; text-align: center;
  font: inherit; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; line-height: 1.25;
  color: var(--brand); background: var(--surface); border: 1.5px solid var(--brand); border-radius: 8px; cursor: pointer;
}
html[data-contrast] .tile { color: var(--ink); border: 2px solid var(--ink); }
.tile:hover { background: var(--brand-l); }
.tile[aria-pressed="true"] { background: var(--brand); color: var(--on-brand); }
html[data-contrast="hc-dark"] .tile[aria-pressed="true"] { background: #ffeb3b; color: #000; }
html[data-contrast="hc-light"] .tile[aria-pressed="true"] { background: #000; color: #fff; }
.tile-ico { display: grid; place-items: center; height: 1.9rem; }
.tile-ico svg { width: 1.9rem; height: 1.9rem; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tile-txt { font-size: 1.5rem; font-weight: 500; letter-spacing: 0; text-transform: none; }
.tile .state { display: block; font-weight: 500; letter-spacing: 0; text-transform: none; opacity: .85; }
.tile .state:empty { display: none; }
.a11y-foot { margin-top: 1rem; display: grid; gap: .9rem; }
.tile-wide { min-height: 3.2rem; grid-auto-flow: column; justify-content: center; gap: .6rem; }
.tile-wide .tile-ico { height: 1.4rem; } .tile-wide .tile-ico svg { width: 1.3rem; height: 1.3rem; }
.a11y-link { text-align: center; font-size: .95rem; }

/* user-selected display options */
html[data-invert="on"] { filter: invert(1) hue-rotate(180deg); }
html[data-invert="on"] img, html[data-invert="on"] video { filter: invert(1) hue-rotate(180deg); }
html[data-sat="low"] body { filter: saturate(.45); }
html[data-sat="high"] body { filter: saturate(2.2); }
html[data-sat="mono"] body { filter: grayscale(1); }
html[data-links="on"] main a, html[data-links="on"] footer a, html[data-links="on"] nav a { background: #ffeb3b !important; color: #000 !important; outline: 2px solid #000; text-decoration: underline !important; }
html[data-images="hide"] img { visibility: hidden; }
html[data-cursor="default"] *, html[data-cursor="default"] *::before { cursor: default !important; }

/* ---------- Primary navigation ---------- */
.primary { background: var(--brand); position: sticky; top: 0; z-index: 50; box-shadow: 0 2px 10px rgba(0,0,0,.12); }
.primary .wrap { position: relative; }
.nav-toggle {
  display: none; width: 100%; font: inherit; font-weight: 600; text-align: left; padding: .85rem 0; color: var(--on-brand);
  background: none; border: 0; cursor: pointer; align-items: center; justify-content: space-between;
}
.nav-toggle svg { width: 1.4rem; height: 1.4rem; }
.primary #nav-list { list-style: none; margin: 0; padding: 0; display: flex; flex: 1 1 auto; flex-wrap: wrap; }
.primary #nav-list > li { position: relative; }
.primary li a {
  display: block; padding: .85rem .95rem; color: var(--on-brand); text-decoration: none; font-size: .95rem; font-weight: 500;
  border-bottom: 3px solid transparent;
}
.primary li a:hover { background: rgba(255,255,255,.1); color: var(--on-brand); }
.primary #nav-list > li > a[aria-current="page"] { border-bottom-color: var(--accent); font-weight: 700; background: rgba(0,0,0,.14); }
html[data-contrast="hc-light"] .primary li a:hover { background: #333; }

/* Global information-architecture dropdowns use native details/summary controls. */
.primary .nav-group { position: relative; }
.primary .nav-group > summary {
  display: flex; align-items: center; gap: .55rem; min-height: 3.25rem; padding: .85rem .95rem;
  color: var(--on-brand); font-size: .95rem; font-weight: 500; cursor: pointer; list-style: none;
  border-bottom: 3px solid transparent;
}
.primary .nav-group > summary::-webkit-details-marker { display: none; }
.primary .nav-group > summary::after {
  content: ""; width: .42rem; height: .42rem; margin-left: auto; border: solid currentColor;
  border-width: 0 2px 2px 0; transform: translateY(-.12rem) rotate(45deg); transition: transform .15s;
}
.primary .nav-group[open] > summary::after { transform: translateY(.1rem) rotate(225deg); }
.primary .nav-group[open] > summary,
.primary .nav-group.is-current > summary { border-bottom-color: var(--accent); background: rgba(0,0,0,.14); font-weight: 700; }
.primary .nav-submenu {
  position: absolute; top: 100%; left: 0; z-index: 60; display: none; flex-direction: column;
  width: max-content; min-width: 14rem; max-width: min(24rem, 90vw); max-height: 70vh; overflow: auto;
  list-style: none; margin: 0; padding: .35rem 0; background: var(--surface); color: var(--ink);
  border: var(--border-w) solid var(--line); box-shadow: var(--shadow);
}
.primary .nav-group[open] > .nav-submenu { display: flex; }
.primary .nav-submenu li { width: 100%; }
.primary .nav-submenu li a {
  padding: .65rem .9rem; border: 0; border-bottom: var(--border-w) solid var(--line);
  color: var(--ink) !important; font-size: .95rem; white-space: normal;
}
.primary .nav-submenu li:last-child a { border-bottom: 0; }
.primary .nav-submenu li a:hover { background: var(--brand-l); color: var(--brand) !important; }
.primary .nav-submenu li a[aria-current="page"] { background: var(--brand-l); color: var(--brand) !important; font-weight: 700; }

/* ---------- Hero (home) ---------- */
.hero {
  background:
    radial-gradient(1200px 400px at 85% -20%, rgba(214,160,58,.28), transparent 60%),
    linear-gradient(135deg, var(--brand-d), var(--brand));
  color: var(--on-brand); padding: clamp(2.5rem, 6vw, 4.5rem) 0;
}
.hero .eyebrow { display: inline-block; font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); font-weight: 700; margin: 0 0 .75rem; }
html[data-contrast="hc-light"] .hero .eyebrow { color: #fff; }
.hero h1 { color: var(--on-brand); font-size: clamp(1.9rem, 1.2rem + 3vw, 3.2rem); letter-spacing: -.02em; margin: 0 0 1rem; max-width: 20ch; }
.hero p.lead { font-size: clamp(1.05rem, 1rem + .4vw, 1.25rem); color: var(--on-brand-muted); max-width: 60ch; margin: 0 0 1.75rem; }
.hero .actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.btn {
  display: inline-flex; align-items: center; gap: .5rem; padding: .75rem 1.3rem; border-radius: 999px; font-weight: 600;
  text-decoration: none; border: 2px solid transparent; font-size: 1rem;
}
.btn-primary { background: var(--accent); color: #1c1503; }
.btn-primary:hover { background: #e6b556; color: #1c1503; }
.btn-ghost { color: var(--on-brand); border-color: rgba(255,255,255,.6); }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: var(--on-brand); }
html[data-contrast="hc-dark"] .btn-primary { background: #ffeb3b; color: #000; }
html[data-contrast="hc-light"] .btn-primary { background: #fff; color: #000; }

/* ---------- Page header band ---------- */
.pagehead { background: var(--brand-l); border-bottom: var(--border-w) solid var(--line); padding: 1.5rem 0 1.6rem; }
.crumbs { font-size: .875rem; color: var(--muted); margin: 0 0 .6rem; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .25rem .5rem; margin: 0; padding: 0; }
.crumbs li + li::before { content: "›"; margin-right: .5rem; color: var(--muted); }
.crumbs a { color: var(--muted); }
.crumbs [aria-current] { color: var(--ink); font-weight: 600; }
.pagehead .kicker { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: var(--brand); margin: 0 0 .25rem; }
html[data-contrast] .pagehead .kicker { color: var(--ink); }
.pagehead h1 { margin: 0; font-size: clamp(1.6rem, 1.2rem + 1.8vw, 2.35rem); letter-spacing: -.015em; padding-left: .9rem; border-left: 5px solid var(--accent); }
html[data-contrast="hc-light"] .pagehead h1 { border-left-color: #000; }

/* ---------- Layout ---------- */
main { display: block; padding: 2rem 0 3.5rem; }
.layout { display: grid; gap: 2rem; align-items: start; }
.layout.has-side { grid-template-columns: 16.5rem minmax(0, 1fr); }
.card {
  background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
}
.prose { padding: clamp(1.25rem, 3vw, 2.25rem); }
.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose p, .prose li { max-width: none; }
.prose h2 { font-size: 1.45rem; margin: 2rem 0 .75rem; padding-bottom: .4rem; border-bottom: var(--border-w) solid var(--line); }
.prose h3 { font-size: 1.15rem; margin: 1.6rem 0 .5rem; color: var(--brand); }
html[data-contrast] .prose h3 { color: var(--ink); }
.prose ul, .prose ol { padding-left: 1.4rem; }
.prose li { margin: .35rem 0; }
.prose figure, .prose p > img { margin: 1rem 0; }
.prose img { border-radius: 8px; }
.prose .org-chart img, .prose p > img[alt*="Organisational"] { border: var(--border-w) solid var(--line); background: #fff; padding: .5rem; width: 100%; max-width: 760px; }

/* Side navigation (Directorate pages) */
.subnav { padding: 1rem; position: sticky; top: 4.5rem; }
.subnav h2 { font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: .25rem .5rem .6rem; }
.subnav ul { list-style: none; margin: 0; padding: 0; }
.subnav a { display: block; padding: .6rem .75rem; border-radius: 8px; text-decoration: none; color: var(--ink); font-size: .95rem; }
.subnav a:hover { background: var(--brand-l); }
.subnav a[aria-current="page"] { background: var(--brand); color: var(--on-brand); font-weight: 600; }
.subnav .back { margin-top: .75rem; padding-top: .75rem; border-top: var(--border-w) solid var(--line); }
.subnav .back a { color: var(--link); font-size: .875rem; }

/* ---------- Document lists (notifications, reports, acts) ---------- */
.filter { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; margin: 0 0 1rem; }
.filter label { font-weight: 600; }
.filter input {
  flex: 1 1 16rem; max-width: 28rem; font: inherit; padding: .6rem .9rem; border: 1px solid #8a968f; border-radius: 8px; background: var(--surface); color: var(--ink);
}
html[data-contrast] .filter input { border: 2px solid var(--ink); }
.filter .count { color: var(--muted); font-size: .9rem; }
.prose ul.doc-list { list-style: none; padding: 0; margin: 1rem 0; border-top: var(--border-w) solid var(--line); }
.prose ul.doc-list li.doc {
  max-width: none; margin: 0; display: flex; gap: 1rem; align-items: flex-start; justify-content: space-between;
  padding: .9rem .5rem; border-bottom: var(--border-w) solid var(--line);
}
li.doc:hover { background: var(--brand-l); }
html[data-contrast] li.doc:hover { background: transparent; }
li.doc .doc-link { font-weight: 500; flex: 1; min-width: 0; overflow-wrap: anywhere; }
li.doc .doc-meta { display: inline-flex; gap: .5rem; align-items: center; flex: none; font-size: .8125rem; color: var(--muted); padding-top: .2rem; white-space: nowrap; }
.badge {
  display: inline-block; padding: .1rem .5rem; border-radius: 6px; font-size: .7rem; font-weight: 700; letter-spacing: .05em;
  background: #fbe9e7; color: #8a2a17; border: 1px solid #f2c4bb;
}
.badge.img { background: #e8f0fb; color: #1d4f91; border-color: #c3d6f2; }
html[data-contrast] .badge { background: transparent; color: var(--ink); border: 2px solid var(--ink); }
.no-results { padding: 1rem .5rem; color: var(--muted); }

/* Links that open elsewhere */
.prose a[target="_blank"]:not(.doc-link)::after, .aside-card a[target="_blank"]::after, .foot a[target="_blank"]::after {
  content: "↗"; font-size: .8em; margin-left: .2em; text-decoration: none; display: inline-block;
}

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; margin: 1rem 0 1.5rem; border: var(--border-w) solid var(--line); border-radius: 10px; }
table.data { width: 100%; border-collapse: collapse; font-size: .975rem; background: var(--surface); }
table.data caption { text-align: left; font-weight: 600; padding: .75rem 1rem; }
table.data th, table.data td { padding: .75rem 1rem; text-align: left; vertical-align: top; border-bottom: var(--border-w) solid var(--line); }
table.data th { background: var(--brand-l); font-size: .875rem; letter-spacing: .02em; }
html[data-contrast] table.data th { background: transparent; border-bottom: 2px solid var(--ink); }
table.data tbody tr:nth-child(even) td { background: color-mix(in srgb, var(--brand-l) 45%, transparent); }
html[data-contrast] table.data tbody tr:nth-child(even) td { background: transparent; }
table.data tr:last-child td { border-bottom: 0; }
@media (max-width: 720px) {
  table.data.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table.data.stack, table.data.stack tbody, table.data.stack tr, table.data.stack td { display: block; width: 100%; }
  table.data.stack tr { padding: .5rem 0; border-bottom: 4px solid var(--line); }
  table.data.stack td { border: 0; padding: .3rem 1rem; }
  table.data.stack td[data-label]::before { content: attr(data-label); display: block; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
  table.data.stack td:empty { display: none; }
}

/* ---------- Home ---------- */
.section-title { font-size: 1.35rem; margin: 0 0 1rem; }
.quick { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1rem; margin-top: -2.5rem; position: relative; z-index: 2; padding: 0; list-style: none; }
.quick a {
  display: flex; gap: .9rem; align-items: center; padding: 1rem 1.1rem; text-decoration: none; color: var(--ink);
  background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
  transition: transform .15s, border-color .15s;
}
.quick a:hover { transform: translateY(-2px); border-color: var(--brand); color: var(--ink); }
.quick .ico { flex: none; width: 2.6rem; height: 2.6rem; border-radius: 10px; display: grid; place-items: center; background: var(--brand-l); color: var(--brand); }
html[data-contrast] .quick .ico { background: transparent; border: 2px solid var(--ink); color: var(--ink); }
.quick svg { width: 1.4rem; height: 1.4rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.quick strong { display: block; line-height: 1.2; }
.quick small { color: var(--muted); font-size: .85rem; }
.home-grid { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: 2rem; margin-top: 2.5rem; align-items: start; }
.panel { padding: 1.5rem; }
.panel + .panel { margin-top: 1.5rem; }
.panel .more { display: inline-block; margin-top: 1rem; font-weight: 600; }
.panel ul.doc-list { margin-top: 0; }
.panel ul.doc-list { list-style: none; padding: 0; border-top: var(--border-w) solid var(--line); }
.panel li.doc { display: flex; gap: 1rem; justify-content: space-between; align-items: flex-start; padding: .8rem .25rem; border-bottom: var(--border-w) solid var(--line); margin: 0; }
.aside-card { padding: 1.25rem 1.25rem 1.1rem; }
.aside-card + .aside-card { margin-top: 1.25rem; }
.aside-card h2 { font-size: 1.05rem; margin: 0 0 .6rem; }
.aside-card ul { list-style: none; margin: 0; padding: 0; }
.aside-card li { border-bottom: var(--border-w) solid var(--line); }
.aside-card li:last-child { border-bottom: 0; }
.aside-card li a { display: block; padding: .5rem 0; font-size: .95rem; }
.portal-links { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: .75rem; align-items: center; }
.portal-links img { border-radius: 6px; border: var(--border-w) solid var(--line); background: #fff; }
.agencies { display: grid; grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); gap: 1rem; margin-top: 2.5rem; }
.agency { display: block; text-decoration: none; color: var(--ink); overflow: hidden; }
.agency:hover { border-color: var(--brand); color: var(--ink); }
.agency img { display: block; width: 100%; height: auto; }
.agency span { display: block; padding: .9rem 1.1rem; font-weight: 600; }
.agency span::after { content: " →"; }
.about-strip { margin-top: 2.5rem; padding: clamp(1.25rem, 3vw, 2rem); }
.about-strip p { max-width: 80ch; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: .85rem; }
.gallery a { display: block; border-radius: 10px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--chip); border: var(--border-w) solid var(--line); }
.gallery img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 0; transition: transform .25s; }
.gallery a:hover img { transform: scale(1.05); }
.videos { display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 1.25rem; list-style: none; padding: 0 !important; }
.videos li { max-width: none !important; margin: 0 !important; }
.videos a { display: block; text-decoration: none; color: var(--ink); }
.videos img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.videos span { display: block; margin-top: .4rem; font-weight: 500; }
dialog.pv { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100%; height: 100%; color: #fff; }
dialog.pv::backdrop { background: rgba(0,0,0,.88); }
.pv figure { margin: 0; width: 100%; height: 100%; display: grid; grid-template-rows: minmax(0, 1fr) auto; place-items: center; padding: 3.5rem 4rem 1rem; gap: 1rem; }
.pv img { width: 100%; height: 100%; min-width: 0; min-height: 0; max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 4px; }
.pv figcaption { text-align: center; max-width: 60ch; }
.lb-btn { position: fixed; background: rgba(255,255,255,.14); color: #fff; border: 1px solid rgba(255,255,255,.5); border-radius: 999px; width: 2.8rem; height: 2.8rem; font-size: 1.4rem; cursor: pointer; line-height: 1; }
.lb-btn:hover { background: rgba(255,255,255,.28); }
.lb-close { top: 1rem; right: 1rem; }
.lb-prev { left: 1rem; top: 50%; }
.lb-next { right: 1rem; top: 50%; }

/* Help page chips */
.chip { display: inline-block; padding: .05rem .6rem; border: 1px solid var(--line); border-radius: 6px; background: var(--chip); font-weight: 600; font-size: .9em; }

/* ---------- Footer ---------- */
.foot { background: var(--brand-d); color: var(--on-brand-muted); border-top: 4px solid var(--accent); font-size: .95rem; }
.foot .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; padding: 2.5rem 0 2rem; }
.foot h2 { color: var(--on-brand); font-size: 1rem; margin: 0 0 .75rem; }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin: .35rem 0; }
.foot a { color: var(--on-brand); }
.foot a:hover { color: var(--on-brand); text-decoration-thickness: .16em; }
.foot p { margin: 0 0 .5rem; }
.foot .legal { border-top: 1px solid rgba(255,255,255,.2); padding: 1rem 0 1.5rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 1.5rem; font-size: .875rem; }
html[data-contrast] .foot .legal { border-top-color: var(--on-brand); }
.totop { color: var(--on-brand); }

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: 3rem 1rem; }
.notfound .code { font-size: clamp(4rem, 12vw, 7rem); font-weight: 800; color: var(--brand); line-height: 1; margin: 0; }
html[data-contrast] .notfound .code { color: var(--ink); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .home-grid { grid-template-columns: 1fr; }
  .layout.has-side { grid-template-columns: 1fr; }
  .subnav { position: static; }
  .subnav ul { display: flex; flex-wrap: wrap; gap: .25rem; }
  .site-footer .footer-links { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .foot .cols { grid-template-columns: 1fr 1fr; }
  .foot .cols > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .site-footer .footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .primary #nav-list { display: none; flex-direction: column; align-items: stretch; padding-bottom: .5rem; }
  .primary.open #nav-list { display: flex; }
  .primary #nav-list > li > a { border-bottom: 0; border-left: 4px solid transparent; padding: .75rem .5rem; }
  .primary #nav-list > li > a[aria-current="page"] { border-left-color: var(--accent); }
  .primary .nav-group > summary { justify-content: space-between; min-height: 2.9rem; padding: .65rem .5rem; border-bottom: 0; border-left: 4px solid transparent; }
  .primary .nav-group.is-current > summary,
  .primary .nav-group[open] > summary { border-left-color: var(--accent); border-bottom: 0; }
  .primary .nav-submenu,
  .primary .nav-group[open] > .nav-submenu {
    position: static; width: auto; min-width: 0; max-width: none; max-height: none; overflow: visible;
    margin: 0 .5rem .6rem; padding: .2rem 0; border: 0; border-left: 2px solid var(--line); box-shadow: none;
    background: transparent;
  }
  .primary .nav-submenu li a { padding: .6rem .8rem; border: 0; }
  .primary .nav-submenu li a[aria-current="page"] { border: 0; }
}
@media (max-width: 560px) {
  .site-footer .footer-links { grid-template-columns: 1fr; }
  li.doc, .prose ul.doc-list li.doc, .panel li.doc { flex-direction: column; gap: .35rem !important; }
  .foot .cols { grid-template-columns: 1fr; }
  .pv figure { padding: 3.5rem .5rem 1rem; }
  .lb-prev { left: .25rem; } .lb-next { right: .25rem; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }

/* ---------- Print ---------- */
@media print {
  .primary, .search, .skip, .a11y-drawer, .tool-icons, .subnav, .foot .cols, .filter, .hero .actions, .lb-btn { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .card { box-shadow: none; border: 0; }
  a { color: #000; }
  .prose a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .8em; }
  .pagehead { background: none; border: 0; }
}

/* long obfuscated e-mail addresses must wrap on narrow screens */
table.data td, .prose p { overflow-wrap: anywhere; }

@media (min-width: 761px) and (max-width: 900px) {
  .masthead .wrap { grid-template-columns: minmax(0, 1fr); gap: .75rem; }
  .masthead .brand { grid-column: 1; grid-row: 1; }
  .masthead .search { grid-column: 1; grid-row: 2; max-width: 21rem; justify-self: center; }
  .masthead .head-tools { grid-column: 1; grid-row: 3; justify-self: end; gap: .5rem; }
}
@media (min-width: 901px) and (max-width: 1439px) {
  .masthead .wrap { grid-template-columns: minmax(0, 1fr) auto; gap: .75rem 1rem; }
  .masthead .brand { grid-column: 1; grid-row: 1; }
  .masthead .head-tools { grid-column: 2; grid-row: 1; gap: .75rem; padding-left: 0; }
  .masthead .search { grid-column: 1 / -1; grid-row: 2; }
}
@media (min-width: 901px) and (max-width: 1000px) {
  .masthead .brand-name { font-size: 1.2rem; }
}
@media (min-width: 1440px) {
  .masthead .wrap { display: flex; justify-content: space-between; gap: 1rem; }
  .masthead .head-tools { display: contents; }
  .masthead .brand, .masthead .search, .partner, .tool-icons { flex: 0 0 auto; }
  .masthead .search { width: 21rem; max-width: 21rem; }
}
@media (max-width: 760px) {
  .masthead .wrap { grid-template-columns: minmax(0, 1fr); gap: .75rem; }
  .masthead .brand { grid-column: 1 / -1; grid-row: 1; }
  .masthead .search { grid-column: 1; grid-row: 2; max-width: 21rem; justify-self: center; }
  .masthead .head-tools { grid-column: 1; grid-row: 3; justify-self: end; gap: .5rem; }
}
@media (max-width: 400px) { .tiles-grid { grid-template-columns: 1fr; } }

@media (max-width: 560px) { .brand img { height: 4rem; } }


/* =====================================================================
   MSDMA-specific layout (content markup is unchanged from the DBIM build)
   ===================================================================== */
:root { --font: "Noto Sans", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Roboto, Arial, sans-serif; }
.partner { display: block; flex: none; }
.partner img { display: block; height: 5.5rem; width: auto; }
a:visited { color: var(--link); }
.primary .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.primary #nav-list { flex: 1 1 auto; }
.primary .nav-toggle { flex: 1 1 100%; }
.lang ul { display: flex; gap: .25rem; list-style: none; margin: 0; padding: 0; }
.lang a { display: block; padding: .3rem .65rem; border: 1px solid transparent; border-radius: 6px; color: var(--on-brand); font-size: .85rem; text-decoration: none; }
.lang a:hover { background: rgba(255,255,255,.12); color: var(--on-brand); }
.lang a[aria-current="true"] { border-color: var(--on-brand); font-weight: 700; }
.primary li a:visited { color: var(--on-brand); }

nav.crumbs { background: var(--brand-l); border-bottom: var(--border-w) solid var(--line); margin: 0; }
nav.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .25rem .5rem; margin: 0; padding: .8rem 0; }
nav.crumbs a { color: var(--muted); }

.wrap.layout { display: grid; grid-template-columns: 17rem minmax(0, 1fr); gap: 2rem; align-items: start; padding-block: 2rem 3.5rem; }
.wrap.layout.no-side { grid-template-columns: minmax(0, 1fr); }
.layout > main { grid-column: 2; grid-row: 1; padding: clamp(1.25rem, 3vw, 2.25rem); background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding-block: clamp(1.25rem, 3vw, 2.25rem); }
.layout.no-side > main { grid-column: 1; }
.layout > .sidenav { grid-column: 1; grid-row: 1; }
main { display: block; padding: 0; }
main:focus { outline: none; }
.layout > main > h1 { margin: 0 0 1.25rem; font-size: clamp(1.6rem, 1.2rem + 1.8vw, 2.35rem); letter-spacing: -.015em; padding-left: .9rem; border-left: 5px solid var(--accent); }
html[data-contrast="hc-light"] .layout > main > h1 { border-left-color: #000; }
.layout main .prose { padding: 0; }
.prose { max-width: none; }
.prose h2 { font-size: 1.45rem; margin: 2rem 0 .75rem; padding-bottom: .4rem; border-bottom: var(--border-w) solid var(--line); }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.15rem; margin: 1.6rem 0 .5rem; color: var(--brand); }
html[data-contrast] .prose h3 { color: var(--ink); }
.prose h4 { margin: 1.25rem 0 .5rem; }
.prose p, .prose li { max-width: none; }
.prose ul, .prose ol { padding-left: 1.4rem; }
.prose li { margin: .35rem 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: .975rem; background: var(--surface); }
.prose th, .prose td { padding: .7rem .9rem; text-align: left; vertical-align: top; border: var(--border-w) solid var(--line); }
.prose th { background: var(--brand-l); font-size: .875rem; }
html[data-contrast] .prose th { background: transparent; border-bottom: 2px solid var(--ink); }
.prose th p, .prose td p { margin: 0; max-width: none; }
.table-wrap { margin: 1rem 0 1.5rem; }
.table-wrap:focus-visible { outline: 3px solid var(--focus); }

/* file-type pill that follows a PDF link */
.file { display: inline-block; margin-left: .4rem; padding: .1rem .5rem; font-size: .72rem; font-weight: 700; letter-spacing: .03em; color: #8a2a17; background: #fbe9e7; border: 1px solid #f2c4bb; border-radius: 6px; white-space: nowrap; }
html[data-contrast] .file { background: transparent; color: var(--ink); border: 2px solid var(--ink); }
.ext::after { content: " \2197"; font-size: .8em; }

/* notice lists */
.notices { list-style: none; padding: 0; margin: 0 0 1rem; border-top: var(--border-w) solid var(--line); }
.prose .notices li, .notices li { max-width: none; margin: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: .85rem .5rem; border-bottom: var(--border-w) solid var(--line); }
.notices li:hover { background: var(--brand-l); }
html[data-contrast] .notices li:hover { background: transparent; }
.notices li > a { flex: 1; min-width: 0; font-weight: 500; overflow-wrap: anywhere; }
.notices li > .file { flex: none; margin-left: 0; margin-top: .2rem; }
.notices li[hidden] { display: none; }

/* side navigation */
.sidenav { align-self: start; padding: 1rem; background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); position: sticky; top: 4.5rem; }
.sidenav > .hd { margin: .25rem .5rem .6rem; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; color: var(--muted); }
.sidenav ul { list-style: none; margin: 0; padding: 0; }
.sidenav li { margin: 0; }
.sidenav a, .sidenav summary.sub { display: block; padding: .6rem .75rem; border-radius: 8px; text-decoration: none; color: var(--ink); font-size: .95rem; }
.sidenav a:visited { color: var(--ink); }
.sidenav a:hover, .sidenav summary.sub:hover { background: var(--brand-l); }
.sidenav a[aria-current="page"] { background: var(--brand); color: var(--on-brand); font-weight: 600; }
html[data-contrast="hc-dark"] .sidenav a[aria-current="page"] { background: #ffeb3b; color: #000; }
.sidenav summary.sub { cursor: pointer; font-weight: 600; }
.sidenav details ul { padding-left: .75rem; border-left: 2px solid var(--line); margin-left: .75rem; }
.sidenav details ul a { font-size: .9rem; }

/* galleries */
.gallery { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: 1rem; }
.prose .gallery li { margin: 0; max-width: none; }
.gallery figure { margin: 0; height: 100%; background: var(--surface); border: var(--border-w) solid var(--line); border-radius: 10px; overflow: hidden; }
.gallery a { display: block; }
.gallery img { display: block; width: 100%; height: 9rem; object-fit: cover; border-radius: 0; transition: transform .25s; }
.gallery a:hover img { transform: scale(1.04); }
.gallery figcaption { padding: .55rem .75rem; font-size: .85rem; }

/* home */
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 26rem); gap: 2.5rem; align-items: center; }
.hero h1 { max-width: 22ch; }
.hero p { color: var(--on-brand-muted); max-width: 62ch; margin: 0 0 1rem; }
.hero img { width: 100%; border-radius: var(--radius); box-shadow: 0 10px 30px rgba(0,0,0,.35); }
.btn { display: inline-flex; align-items: center; padding: .7rem 1.3rem; border-radius: 999px; font-weight: 600; text-decoration: none; border: 2px solid var(--brand); background: var(--brand); color: var(--on-brand) !important; }
.btn:hover { background: var(--brand-d); border-color: var(--brand-d); }
.btn.alt { background: transparent; color: var(--link) !important; border-color: var(--link); }
.hero .btn { background: var(--accent); border-color: var(--accent); color: #1c1503 !important; }
.hero .btn:hover { background: #e6b556; border-color: #e6b556; }
html[data-contrast="hc-dark"] .hero .btn { background: #ffeb3b; border-color: #ffeb3b; color: #000 !important; }
html[data-contrast="hc-light"] .hero .btn { background: #fff; border-color: #fff; color: #000 !important; }
.home-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 2rem; align-items: start; padding-block: 2.5rem 3.5rem; }
.card { padding: 1.5rem; margin-bottom: 1.5rem; }
.card h2 { font-size: 1.25rem; margin: 0 0 1rem; }
.card ul.notices { margin-top: 0; }
.tiles { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr)); gap: .6rem; }
.tiles a { display: block; height: 100%; padding: .7rem .85rem; border: var(--border-w) solid var(--line); border-radius: 8px; text-decoration: none; font-weight: 500; background: var(--surface); }
.tiles a:hover { background: var(--brand-l); border-color: var(--brand); }
.linklist { list-style: none; padding: 0; margin: 0; }
.linklist li { margin: 0; border-bottom: var(--border-w) solid var(--line); }
.linklist li:last-child { border-bottom: 0; }
.linklist a { display: block; padding: .55rem 0; }
.linklist ul.linklist { padding-left: 1rem; margin: .25rem 0 .5rem; }
.award { text-align: center; }
.award img { display: block; margin: 0 auto; border-radius: 8px; }

/* Footer: DBIM groups, lineage, and per-page update date. */
.site-footer { background: var(--brand-d); color: var(--on-brand-muted); border-top: 4px solid var(--accent); font-size: .95rem; }
.site-footer a, .site-footer a:visited { color: var(--on-brand); }
.site-footer .footer-links { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; padding-block: 2rem; }
.site-footer nav { min-width: 0; }
.site-footer h2 { font-size: 1rem; margin: 0 0 .75rem; color: var(--on-brand); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: .4rem 0; }
.site-footer nav a { display: inline-block; text-underline-offset: .18em; }
.site-footer nav a:hover { text-decoration-thickness: .14em; }
.site-footer p { margin: 0 0 .45rem; }
.site-footer .footer-meta { border-top: 1px solid rgba(255,255,255,.24); padding-block: 1rem 1.4rem; font-size: .875rem; }
.site-footer .lineage { margin-bottom: .5rem; font-size: 1.05rem; font-weight: 700; color: var(--on-brand); }
.site-footer .page-updated { margin-top: .75rem; color: var(--on-brand); }
html[data-contrast] .site-footer .footer-meta { border-top-color: var(--on-brand); }

/* Two-level page tree linked from the footer sitemap. */
.prose .sitemap-tree { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr)); gap: 1rem; list-style: none; margin: 1.25rem 0 0; padding: 0; }
.prose .sitemap-tree > li { min-width: 0; padding: 1rem; border: var(--border-w) solid var(--line); border-radius: var(--radius); background: var(--surface); }
.prose .sitemap-tree > li:first-child { grid-column: 1 / -1; }
.prose .sitemap-tree h2 { margin: 0 0 .65rem; font-size: 1.1rem; }
.prose .sitemap-tree .sitemap-subgroups, .prose .sitemap-tree .sitemap-subgroup ul { margin: 0; padding-left: 1rem; }
.prose .sitemap-tree .sitemap-subgroups { list-style: none; padding-left: 0; }
.prose .sitemap-tree .sitemap-subgroup { margin: .75rem 0; }
.prose .sitemap-tree .sitemap-subgroup > strong { display: block; margin-bottom: .25rem; }
.prose .sitemap-tree .sitemap-subgroup li { margin: .3rem 0; }

/* 404 */
.layout.no-side > main .btn + .btn { margin-left: .5rem; }

@media (max-width: 960px) {
  .wrap.layout { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
  .layout > main, .layout > .sidenav { grid-column: 1; }
  .layout > .sidenav { grid-row: 2; position: static; }
  .home-grid, .hero .wrap { grid-template-columns: minmax(0, 1fr); }
  .hero img { display: none; }
}
@media (max-width: 760px) { .partner { display: none; } }
@media (max-width: 860px) {
  .primary .wrap { display: block; }
  .primary .lang { padding: 0 0 .75rem; } .primary .lang ul { flex-wrap: wrap; }
}
@media print { .primary, .lang, .skip { display: none !important; } }

/* keep a file pill inside its tile (e.g. the Lightning PDF) */
.tiles li { display: flex; flex-direction: column; align-items: flex-start; gap: .3rem; }
.tiles li > a { width: 100%; flex: 1; }
.tiles li > .file { margin: 0 0 0 .1rem; }

/* mobile menu icon */
.nav-toggle svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
