:root {
  --bg: #f5f7fb;
  --surface: #ffffff;
  --surface-2: #eef2f8;
  --text: #16202e;
  --muted: #5b6878;
  --line: #dde3ec;
  --brand: #0b5cad;
  --brand-2: #0a4a8c;
  --brand-soft: #e3eefb;
  --accent: #e8a317;
  --new: #d64545;
  --ok: #1f8a5b;
  --shadow: 0 1px 2px rgba(16, 32, 56, .06), 0 4px 16px rgba(16, 32, 56, .06);
  --radius: 14px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e141c; --surface: #151d28; --surface-2: #1c2633; --text: #e6ecf3; --muted: #9aa8b8;
    --line: #273342; --brand: #5aa6f2; --brand-2: #8cc2f7; --brand-soft: #18304a; --accent: #f0b84a;
    --new: #ef6b6b; --ok: #4cc28d; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 20px rgba(0,0,0,.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e141c; --surface: #151d28; --surface-2: #1c2633; --text: #e6ecf3; --muted: #9aa8b8;
  --line: #273342; --brand: #5aa6f2; --brand-2: #8cc2f7; --brand-soft: #18304a; --accent: #f0b84a;
  --new: #ef6b6b; --ok: #4cc28d; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 20px rgba(0,0,0,.25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: 80px; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15.5px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
kbd { font: 11px var(--font); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 6px; padding: 1px 6px; color: var(--muted); background: var(--surface); }
button { font: inherit; color: inherit; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 99; background: var(--surface); padding: 8px 12px; border-radius: 8px; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 6px; }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.top-in { max-width: 1280px; margin: 0 auto; display: flex; align-items: center; gap: 18px; padding: 10px 20px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); }
.brand:hover { text-decoration: none; }
.logo { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 11px; background: linear-gradient(135deg, var(--brand), #2b8ae0); color: #fff; font-weight: 800; font-size: 13px; letter-spacing: .5px; }
.brand-txt { display: flex; flex-direction: column; line-height: 1.2; }
.brand-txt b { font-size: 15px; white-space: nowrap; }
.brand-txt small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.mainnav { display: flex; gap: 2px; margin-left: 8px; flex: 1; }
.nav-item { position: relative; }
.nav-item > a { display: block; padding: 8px 9px; border-radius: 9px; color: var(--text); font-weight: 500; font-size: 14.5px; white-space: nowrap; }
.nav-item > a:hover, .nav-item.on > a { background: var(--surface-2); text-decoration: none; }
.nav-item.on > a { color: var(--brand); }
.mega { display: none; position: absolute; top: 100%; left: 0; padding-top: 8px; z-index: 40; }
.nav-item:hover .mega, .nav-item:focus-within .mega { display: block; }
.mega-in { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; display: grid; grid-template-columns: repeat(3, 220px); gap: 6px 20px; }
.mega-col b a { color: var(--text); font-size: 14px; }
.mega-col ul { list-style: none; margin: 4px 0 8px; padding: 0; }
.mega-col li a { color: var(--muted); font-size: 13.5px; display: block; padding: 1px 0; }
.mega-col li a:hover { color: var(--brand); }
.badge { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--new); color: #fff; font-size: 11px; font-weight: 700; margin-left: 4px; vertical-align: 1px; }
.top-actions { display: flex; gap: 8px; align-items: center; margin-left: auto; }
.search-btn { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--surface-2); border-radius: 10px; padding: 7px 10px; color: var(--muted); cursor: pointer; min-width: 160px; }
.search-btn span { flex: 1; text-align: left; }
.search-btn svg { width: 17px; height: 17px; }
.icon-btn { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid var(--line); background: var(--surface); border-radius: 10px; cursor: pointer; }
.icon-btn:hover { background: var(--surface-2); }
.only-mobile { display: none; }
@media (max-width: 1260px) { .mainnav { display: none; } .only-mobile { display: grid; } }
@media (max-width: 640px) {
  .brand-txt { display: none; }
  .search-btn { min-width: 0; }
  .search-btn span, .search-btn kbd { display: none; }
  .top-in { padding: 10px 16px; gap: 10px; }
}

/* ---------- drawer ---------- */
.drawer { position: fixed; inset: 0; z-index: 50; background: rgba(8, 14, 22, .45); }
.drawer-panel { position: absolute; inset: 0 auto 0 0; width: min(360px, 88vw); background: var(--surface); overflow: auto; padding: 14px 16px 30px; box-shadow: var(--shadow); }
.drawer-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }

/* ---------- layout ---------- */
main { max-width: 1280px; margin: 0 auto; padding: 24px 20px 60px; min-height: 70vh; outline: none; }
@media (max-width: 640px) { main { padding: 16px 16px 40px; } }
.loading { display: flex; gap: 12px; align-items: center; justify-content: center; padding: 120px 0; color: var(--muted); }
.spinner { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.page { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 32px; align-items: start; }
@media (max-width: 960px) { .page { grid-template-columns: 1fr; } .page > .side { display: none; } }
.side { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow: auto; padding-right: 4px; }
.side-title { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; margin: 4px 10px 8px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 13.5px; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--brand); }
.crumbs svg { width: 14px; height: 14px; opacity: .6; }
h1.title { font-size: clamp(26px, 3.4vw, 36px); line-height: 1.15; margin: 0 0 6px; letter-spacing: -.02em; }
.subtitle { color: var(--muted); margin: 0 0 22px; }
.section-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 34px 0 14px; }
.section-h h2 { margin: 0; font-size: 20px; letter-spacing: -.01em; }
.section-h a { font-size: 14px; white-space: nowrap; }

/* ---------- tree (sidebar / drawer / sitemap) ---------- */
.tree, .tree ul { list-style: none; margin: 0; padding: 0; }
.tree ul { margin-left: 14px; border-left: 1px solid var(--line); padding-left: 6px; }
.tree li { margin: 1px 0; }
.tree .row { display: flex; align-items: center; }
.tree a { flex: 1; display: flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 8px; color: var(--text); font-size: 14px; line-height: 1.35; }
.tree a:hover { background: var(--surface-2); text-decoration: none; }
.tree a.cur { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.tree a.ext::after { content: "↗"; font-size: 11px; color: var(--muted); margin-left: auto; }
.tree .tog { width: 26px; height: 26px; display: grid; place-items: center; border: 0; background: none; cursor: pointer; border-radius: 6px; color: var(--muted); }
.tree .tog:hover { background: var(--surface-2); }
.tree .tog svg { width: 15px; height: 15px; transition: transform .15s; }
.tree li.open > .row .tog svg { transform: rotate(90deg); }
.tree li:not(.open) > ul { display: none; }
.tree .sec-top > .row > a { font-weight: 700; }

/* ---------- content ---------- */
.prose { padding: 26px 30px; overflow-wrap: anywhere; }
@media (max-width: 640px) { .prose { padding: 18px; } }
.prose > :first-child { margin-top: 0; }
.prose h2, .prose h3, .prose h4 { line-height: 1.3; margin: 1.4em 0 .5em; }
.prose h2 { font-size: 21px; } .prose h3 { font-size: 18px; } .prose h4 { font-size: 16px; }
.prose p, .prose div { margin: 0 0 .7em; }
.prose img { max-width: 100%; height: auto; border-radius: 10px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .2em 0; }
.prose table { border-collapse: collapse; width: 100%; margin: 1em 0; font-size: 14.5px; display: block; overflow-x: auto; }
.prose td, .prose th { border: 1px solid var(--line); padding: 7px 10px; vertical-align: top; }
.prose tr:nth-child(even) td { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.prose a[href$=".pdf"]::before, .prose a[href$=".PDF"]::before { content: "PDF"; font-size: 10px; font-weight: 800; color: #fff; background: #c8463c; border-radius: 4px; padding: 1px 4px; margin-right: 6px; vertical-align: 2px; }
.prose a[href$=".doc"]::before, .prose a[href$=".docx"]::before { content: "DOC"; font-size: 10px; font-weight: 800; color: #fff; background: #2f6cc0; border-radius: 4px; padding: 1px 4px; margin-right: 6px; vertical-align: 2px; }
.prose a[href$=".xls"]::before, .prose a[href$=".xlsx"]::before { content: "XLS"; font-size: 10px; font-weight: 800; color: #fff; background: #23854f; border-radius: 4px; padding: 1px 4px; margin-right: 6px; vertical-align: 2px; }
.empty { color: var(--muted); padding: 30px; text-align: center; }
.orig { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--muted); }
.orig svg { width: 15px; height: 15px; }
.page-tools { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-bottom: 18px; }

.children { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.child { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; color: var(--text); transition: transform .12s, border-color .12s; }
.child:hover { text-decoration: none; border-color: var(--brand); transform: translateY(-1px); }
.child b { font-size: 15px; line-height: 1.3; }
.child small { color: var(--muted); font-size: 13px; line-height: 1.4; }
.child .more { color: var(--brand); font-size: 12.5px; margin-top: auto; padding-top: 6px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 26px; }
.pager a { padding: 14px 18px; color: var(--text); }
.pager a:hover { border-color: var(--brand); text-decoration: none; }
.pager small { display: block; color: var(--muted); font-size: 12.5px; }
.pager .next { text-align: right; grid-column: 2; }

/* ---------- home ---------- */
.hero { position: relative; overflow: hidden; border-radius: 22px; padding: 44px 40px; color: #fff; background: radial-gradient(1200px 400px at 90% -20%, #3f9cf0 0%, transparent 60%), linear-gradient(135deg, #073f7a, #0b5cad 55%, #1b78d0); margin-bottom: 26px; }
.hero h1 { margin: 0 0 6px; font-size: clamp(28px, 4vw, 42px); letter-spacing: -.02em; line-height: 1.1; }
.hero p { margin: 0 0 22px; opacity: .88; max-width: 620px; }
.hero-search { display: flex; align-items: center; gap: 10px; background: #fff; color: #5b6878; border-radius: 14px; padding: 13px 16px; max-width: 620px; cursor: text; border: 0; width: 100%; font-size: 16px; box-shadow: 0 10px 30px rgba(0,0,0,.18); }
.hero-search span { flex: 1; text-align: left; }
.hero-meta { margin-top: 18px; font-size: 13.5px; opacity: .85; display: flex; gap: 18px; flex-wrap: wrap; }
.hero::after { content: ""; position: absolute; right: -60px; bottom: -80px; width: 340px; height: 340px; border-radius: 50%; border: 50px solid rgba(255,255,255,.06); }
@media (max-width: 640px) { .hero { padding: 28px 20px; border-radius: 18px; } }

.quick { display: grid; grid-template-columns: repeat(auto-fill, minmax(185px, 1fr)); gap: 12px; }
.q { display: flex; flex-direction: column; gap: 10px; padding: 16px; color: var(--text); position: relative; }
.q:hover { text-decoration: none; border-color: var(--brand); }
.q .ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); }
.q b { font-size: 14.5px; line-height: 1.25; }
.q small { color: var(--muted); font-size: 12.5px; line-height: 1.3; }
.q .badge { position: absolute; top: 12px; right: 12px; }
.q.ext::after { content: "↗"; position: absolute; top: 12px; right: 14px; color: var(--muted); font-size: 13px; }

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 900px) { .two { grid-template-columns: 1fr; } }
.feed { padding: 6px 0; }
.feed a.item { display: block; padding: 12px 18px; color: var(--text); border-bottom: 1px solid var(--line); }
.feed a.item:last-child { border-bottom: 0; }
.feed a.item:hover { background: var(--surface-2); text-decoration: none; }
.feed .t { font-weight: 600; line-height: 1.35; font-size: 14.5px; }
.meta { display: flex; flex-wrap: wrap; gap: 4px 10px; color: var(--muted); font-size: 12.5px; margin-top: 3px; align-items: center; }
.chip { display: inline-flex; align-items: center; gap: 4px; background: var(--surface-2); color: var(--muted); border-radius: 999px; padding: 1px 9px; font-size: 12px; white-space: nowrap; }
.chip.brand { background: var(--brand-soft); color: var(--brand); }
.new-dot { display: inline-block; font-size: 10.5px; font-weight: 800; color: #fff; background: var(--new); border-radius: 5px; padding: 0 5px; margin-right: 6px; vertical-align: 2px; letter-spacing: .03em; }

.sections { display: grid; grid-template-columns: repeat(auto-fill, minmax(225px, 1fr)); gap: 14px; }
.sec { padding: 18px 20px; }
.sec h3 { margin: 0 0 8px; font-size: 17px; }
.sec h3 a { color: var(--text); }
.sec ul { list-style: none; margin: 0; padding: 0; columns: 1; }
.sec li a { display: block; color: var(--muted); font-size: 14px; padding: 2px 0; }
.sec li a:hover { color: var(--brand); }

/* ---------- lists (news / boards) ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 16px; }
.input, select.input { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 9px 12px; font: inherit; color: var(--text); min-width: 0; }
.input:focus { outline: 2px solid var(--brand); outline-offset: -1px; }
.toolbar .input.grow { flex: 1; min-width: 200px; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pill { border: 1px solid var(--line); background: var(--surface); padding: 5px 12px; border-radius: 999px; cursor: pointer; font-size: 13.5px; color: var(--text); }
.pill:hover { border-color: var(--brand); }
.pill.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.posts { display: grid; gap: 12px; }
.post { padding: 18px 22px; }
.post h3 { margin: 0 0 4px; font-size: 17px; line-height: 1.35; }
.post h3 a { color: var(--text); }
.post .excerpt { color: var(--muted); font-size: 14.5px; margin-top: 8px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.post.with-img { display: grid; grid-template-columns: 1fr 160px; gap: 18px; }
.post.with-img img { width: 160px; height: 110px; object-fit: cover; border-radius: 10px; }
@media (max-width: 640px) { .post.with-img { grid-template-columns: 1fr; } .post.with-img img { width: 100%; height: 160px; order: -1; } }
.more-btn { margin: 18px auto 0; display: block; }
.btn { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 8px 14px; cursor: pointer; font-weight: 500; color: var(--text); }
.btn:hover { border-color: var(--brand); text-decoration: none; }
.btn.primary { background: var(--brand); color: #fff; border-color: var(--brand); }
.btn svg { width: 17px; height: 17px; }
.article-img { width: 100%; max-height: 420px; object-fit: cover; border-radius: var(--radius); margin-bottom: 18px; }
.star { border: 0; background: none; cursor: pointer; color: var(--muted); padding: 2px; display: inline-grid; }
.star.on { color: var(--accent); }
.star.on svg { fill: currentColor; }
.unit-list { display: flex; flex-direction: column; gap: 1px; }
.unit-list button { display: flex; align-items: center; gap: 8px; text-align: left; border: 0; background: none; padding: 6px 10px; border-radius: 8px; cursor: pointer; font-size: 13.5px; line-height: 1.3; color: var(--text); }
.unit-list button:hover { background: var(--surface-2); }
.unit-list button.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.unit-list .n { margin-left: auto; color: var(--muted); font-size: 12px; }

/* ---------- timetable ---------- */
.tt-wrap { overflow-x: auto; }
.tt { display: grid; grid-template-columns: 54px repeat(5, minmax(150px, 1fr)); min-width: 820px; position: relative; }
.tt-head { position: sticky; top: 0; padding: 10px 8px; font-weight: 700; font-size: 14px; border-bottom: 1px solid var(--line); text-align: center; }
.tt-head.today { color: var(--brand); }
.tt-hours, .tt-day { position: relative; }
.tt-hours div { position: absolute; right: 8px; font-size: 12px; color: var(--muted); transform: translateY(-50%); }
.tt-day { border-left: 1px solid var(--line); background-image: linear-gradient(var(--line) 1px, transparent 1px); background-size: 100% var(--hour); }
.tt-day.today { background-color: color-mix(in srgb, var(--brand-soft) 45%, transparent); }
.ev { position: absolute; left: 4px; right: 4px; border-radius: 9px; padding: 6px 8px; font-size: 12.5px; line-height: 1.3; overflow: hidden; border-left: 4px solid var(--c); background: color-mix(in srgb, var(--c) 16%, var(--surface)); color: var(--text); }
.ev b { display: block; font-size: 12.5px; }
.ev .r { color: var(--muted); font-size: 11.5px; }
.tt-list { display: none; }
@media (max-width: 760px) {
  .tt-wrap { display: none; }
  .tt-list { display: block; }
}
.tt-list .dayblock { margin-bottom: 14px; padding: 14px 16px; }
.tt-list h3 { margin: 0 0 8px; font-size: 16px; }
.tt-list .row { display: flex; gap: 12px; padding: 7px 0; border-top: 1px solid var(--line); }
.tt-list .row:first-of-type { border-top: 0; }
.tt-list .time { font-variant-numeric: tabular-nums; font-size: 13px; color: var(--muted); width: 90px; flex: none; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; color: var(--muted); margin: 14px 0 0; }

/* ---------- staff ---------- */
.people { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 12px; }
.person { padding: 16px 18px; display: flex; gap: 14px; }
.avatar { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); font-weight: 700; flex: none; font-size: 15px; }
.person b { display: block; line-height: 1.3; }
.person .role { color: var(--muted); font-size: 13px; }
.person .acts { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; font-size: 13px; }

/* ---------- search modal ---------- */
.modal { position: fixed; inset: 0; z-index: 60; background: rgba(8, 14, 22, .5); display: flex; justify-content: center; align-items: flex-start; padding: 10vh 16px 16px; }
.modal-box { width: min(680px, 100%); background: var(--surface); border-radius: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.35); overflow: hidden; border: 1px solid var(--line); }
.search-row { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); color: var(--muted); }
.search-row input { flex: 1; border: 0; outline: 0; background: none; font: inherit; font-size: 17px; color: var(--text); min-width: 0; }
.search-results { max-height: 60vh; overflow: auto; padding: 6px; }
.search-results .grp { font-size: 11.5px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; padding: 10px 12px 4px; }
.search-results a { display: block; padding: 9px 12px; border-radius: 10px; color: var(--text); }
.search-results a:hover, .search-results a.sel { background: var(--brand-soft); text-decoration: none; }
.search-results a small { display: block; color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-results mark { background: color-mix(in srgb, var(--accent) 35%, transparent); color: inherit; border-radius: 3px; }
.search-hint { color: var(--muted); padding: 18px; font-size: 14px; }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--line); background: var(--surface); margin-top: 40px; }
.foot-in { max-width: 1280px; margin: 0 auto; padding: 28px 20px; display: grid; grid-template-columns: 1.2fr 1fr 1.2fr; gap: 24px; font-size: 14px; color: var(--muted); }
.foot-in b { color: var(--text); }
.foot-links { display: flex; flex-direction: column; gap: 3px; }
.foot-status { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.link-btn { border: 0; background: none; color: var(--brand); cursor: pointer; padding: 0; font-size: 14px; }
.link-btn:hover { text-decoration: underline; }
@media (max-width: 760px) { .foot-in { grid-template-columns: 1fr; } }
.toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 70; background: var(--text); color: var(--bg); padding: 11px 18px; border-radius: 12px; box-shadow: var(--shadow); font-size: 14px; display: flex; gap: 14px; align-items: center; max-width: calc(100vw - 32px); }
.toast a { color: var(--bg); font-weight: 700; text-decoration: underline; }

/* sitemap */
.sitemap { columns: 2 340px; column-gap: 24px; }
.sitemap > .card { break-inside: avoid; padding: 14px 10px; margin-bottom: 16px; display: inline-block; width: 100%; }
@media (min-width: 961px) { .only-mobile-sel { display: none; } }

@media (min-width: 1261px) and (max-width: 1500px) { .search-btn { min-width: 0; } .search-btn span { display: none; } }
.tt-hours, .tt-day { margin-bottom: 14px; }
kbd { white-space: nowrap; }
.sitemap .tree > li > .row > a { font-weight: 700; }
.person > div:last-child { min-width: 0; }
.person .chip { white-space: normal; max-width: 100%; line-height: 1.35; padding: 2px 9px; }
@media (max-width: 640px) {
  .quick { grid-template-columns: 1fr 1fr; gap: 10px; }
  .q { padding: 13px; gap: 8px; }
  .q small { display: none; }
  .hero-search kbd { display: none; }
  .hero-search span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}
.unofficial { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 0 5px; margin-left: 4px; vertical-align: 2px; }
/* grid children default to "as wide as their content" — let them shrink on phones */
.page > div, .page > aside, .post > div, .two > div { min-width: 0; }
.post h3, .post .meta { overflow-wrap: anywhere; }

/* ---------- Praćeno ---------- */
.follow-btn { position: relative; color: var(--text); }
.follow-btn:hover { text-decoration: none; }
.follow-btn.on { color: var(--accent); }
.follow-btn.on svg { fill: currentColor; }
.follow-btn .badge { position: absolute; top: -6px; right: -7px; margin: 0; }
.follow-grid { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 24px; align-items: start; }
.follow-settings { display: flex; flex-direction: column; gap: 12px; }
@media (max-width: 960px) { .follow-grid { grid-template-columns: 1fr; } }
.fcard { padding: 16px 18px; }
.fcard h3 { margin: 0 0 8px; font-size: 15.5px; }
.fcard p { margin: 0 0 8px; font-size: 14px; }
.fcard .hint, .hint { color: var(--muted); font-size: 12.5px; }
.fcard .btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chips.dim { opacity: .45; }
.chips.ideas .pill { font-size: 12.5px; padding: 3px 10px; color: var(--muted); }
.chip .x { border: 0; background: none; color: inherit; cursor: pointer; font-size: 15px; line-height: 1; padding: 0 0 0 2px; opacity: .7; }
.chip .x:hover { opacity: 1; }
.chip.follow { background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--text); }
.check { display: flex; gap: 8px; align-items: center; font-size: 14px; cursor: pointer; }
.check input { width: 17px; height: 17px; accent-color: var(--brand); }
.addrow { display: flex; gap: 8px; }
.addrow .input { flex: 1; min-width: 0; }
/* header fits nav + search + ★ + theme between 1261px and 1500px */
@media (min-width: 1261px) and (max-width: 1500px) {
  .top-in { gap: 12px; }
  .nav-item > a { padding: 8px 7px; }
  .search-btn { width: 38px; height: 38px; padding: 0; justify-content: center; }
  .search-btn kbd { display: none; }
  .brand-txt small { display: none; }
}
.chips .chip { white-space: normal; max-width: 100%; }
html, body { overflow-x: hidden; }
@media (min-width: 1261px) {
  .top-in { max-width: 1440px; }
  .search-btn { min-width: 0; }
  .search-btn span { display: none; }
}
.follow-grid > div, .follow-settings > .card { min-width: 0; }
@media (max-width: 960px) { .follow-grid { grid-template-columns: minmax(0, 1fr); } }
.fcard select.input { max-width: 100%; text-overflow: ellipsis; }
/* the decorative circle in the banner must never catch taps (on phones it sits over the search box) */
.hero::after { pointer-events: none; }
.hero > * { position: relative; z-index: 1; }

.search-close { border: 0; background: none; padding: 0; cursor: pointer; color: var(--muted); display: grid; place-items: center; }
.search-close span { display: none; font-size: 20px; width: 36px; height: 36px; place-items: center; border-radius: 10px; }
.search-row input::-webkit-search-cancel-button { display: none; }
/* touch screens: no Esc key, show a real close button */
@media (hover: none) {
  .search-close kbd { display: none; }
  .search-close span { display: grid; }
  .search-close span:active { background: var(--surface-2); }
}
.about h2 { font-size: 18px; margin-top: 1.3em; }
.about h2:first-child { margin-top: 0; }
