/* Bookmark Web - look and feel modelled on the Bookmark library system (Windows style windows,
   blue title bars, red module headings, large rounded menu buttons, grey #f3f3f3 module background). */
:root {
  --win-bg: #f3f3f3;
  --title: #0078d7;
  --title-dlg: #4a90d9;
  --border: #1883d7;
  --red: #cc0000;
  --blue: #0000ee;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; font-family: Arial, Helvetica, sans-serif; font-size: 13px; color: #000; }
body { background: #3a6ea5; }
#desktop { position: absolute; left: 0; top: 0; right: 0; bottom: 34px; overflow: hidden; background: #3a6ea5; }
#taskbar { position: absolute; left: 0; right: 0; bottom: 0; height: 34px; background: #1c2a3a; color: #fff; display: flex; align-items: center; gap: 4px; padding: 0 6px; font: 12px "Segoe UI", Arial, sans-serif; user-select: none; }
#taskbar .tk { flex: 1; display: flex; gap: 4px; overflow: hidden; }
#taskbar .tb { max-width: 190px; min-width: 90px; height: 26px; padding: 0 8px; background: #2d4259; border: 0; border-bottom: 2px solid #5aa0e6; color: #fff; text-align: left; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; cursor: pointer; font: inherit; }
#taskbar .tb.on { background: #3e5c7e; }
#taskbar .tb.min { border-bottom-color: #2d4259; opacity: .8; }
#taskbar .ver { opacity: .75; padding: 0 8px; }
#taskbar .clock { padding: 0 8px; }

/* ---------------------------------------------------------------- windows */
.bmwin { position: absolute; background: var(--win-bg); border: 1px solid var(--border); box-shadow: 0 6px 22px rgba(0,0,0,.45); display: flex; flex-direction: column; min-width: 300px; min-height: 140px; }
.bmwin.active { box-shadow: 0 8px 28px rgba(0,0,0,.6); }
.bmwin.hidden { display: none; }
.bmtitle { flex: 0 0 26px; height: 26px; background: var(--title); color: #fff; display: flex; align-items: center; font: 11px "Segoe UI", Arial, sans-serif; cursor: default; user-select: none; }
.bmwin:not(.active) .bmtitle { background: #6aaee8; }
.bmtitle .ico { width: 16px; height: 16px; margin: 0 6px 0 6px; flex: none; }
.bmtitle .ttl { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.bmtitle .ctl { display: flex; height: 100%; }
.bmtitle .ctl button { width: 40px; border: 0; background: transparent; color: #fff; font: 13px "Segoe UI Symbol", "Segoe UI", Arial; cursor: pointer; padding: 0; }
.bmtitle .ctl button:hover { background: rgba(255,255,255,.22); }
.bmtitle .ctl button:disabled { opacity: .35; cursor: default; background: transparent; }
.bmtitle .ctl .cls:hover { background: #e81123; }
.bmwin.dlg .bmtitle { background: var(--title-dlg); }
.bmwin.dlg .bmtitle .ctl .cls { background: #c9503c; width: 42px; margin: 1px 3px 1px 0; height: 20px; border: 1px solid #7a2a1c; border-radius: 3px; }
.bmwin.dlg .bmtitle .ctl .cls:hover { background: #e81123; }
.bmwin.dlg .bmtitle .ctl .min, .bmwin.dlg .bmtitle .ctl .max { display: none; }
.bmbody { flex: 1; overflow: auto; position: relative; background: var(--win-bg); }
.bmwin .rz { position: absolute; z-index: 5; }
.rz.n { top: -3px; left: 6px; right: 6px; height: 6px; cursor: n-resize; }
.rz.s { bottom: -3px; left: 6px; right: 6px; height: 6px; cursor: s-resize; }
.rz.e { right: -3px; top: 6px; bottom: 6px; width: 6px; cursor: e-resize; }
.rz.w { left: -3px; top: 6px; bottom: 6px; width: 6px; cursor: w-resize; }
.rz.ne { top: -3px; right: -3px; width: 10px; height: 10px; cursor: ne-resize; }
.rz.nw { top: -3px; left: -3px; width: 10px; height: 10px; cursor: nw-resize; }
.rz.se { bottom: -3px; right: -3px; width: 12px; height: 12px; cursor: se-resize; }
.rz.sw { bottom: -3px; left: -3px; width: 10px; height: 10px; cursor: sw-resize; }
#modal { position: absolute; inset: 0; background: rgba(0,0,0,.08); z-index: 90000; display: none; }

/* message boxes */
.msgbox { display: flex; gap: 14px; padding: 18px 18px 8px 18px; align-items: flex-start; background: #fff; min-height: 70px; }
.msgbox .mi { flex: none; width: 32px; height: 32px; border-radius: 50%; color: #fff; font: bold 22px Arial; text-align: center; line-height: 32px; }
.msgbox .mi.info { background: #2c6fbb; } .msgbox .mi.q { background: #2c6fbb; } .msgbox .mi.warn { background: #e0a800; } .msgbox .mi.err { background: #c9302c; }
.msgbox .mt { padding-top: 6px; font-size: 13px; white-space: pre-wrap; }
.msgfoot { background: var(--win-bg); padding: 10px 14px; text-align: right; border-top: 1px solid #ddd; }
.msgfoot .btn { min-width: 76px; margin-left: 6px; }

/* ---------------------------------------------------------------- module chrome */
.mod { padding: 10px 14px 44px; min-height: 100%; position: relative; }
.mh { text-align: center; color: var(--red); font-size: 18px; margin: 12px 0 24px; }
.mh.blue { color: #1010c0; font-weight: bold; font-size: 16px; }
.mh.black { color: #000; }
.mh small { display: block; color: #000; font-size: 12px; font-weight: normal; margin-top: 4px; }
.foot { position: absolute; right: 10px; bottom: 8px; display: flex; gap: 6px; }
.foot.left { left: 10px; right: auto; }
.foot.center { left: 0; right: 0; justify-content: center; }

.mgrid { display: grid; justify-content: center; gap: 8px 6px; margin: 0 auto; }
.mgrid.c2 { grid-template-columns: repeat(2, 162px); }
.mgrid.c1 { grid-template-columns: 162px; }
.mgrid.c3 { grid-template-columns: repeat(3, 162px); }
.mbtn { display: flex; align-items: center; gap: 4px; width: 100%; height: 34px; padding: 0 6px; border: 1px solid #8a8a8a; border-radius: 6px; background: linear-gradient(#fff, #efefef); cursor: pointer; font: bold 11px Arial, sans-serif; text-align: center; }
.mbtn:hover { background: linear-gradient(#fff, #e3f0fb); border-color: #0078d7; }
.mbtn:active { background: #cde6f7; }
.mbtn .ic { flex: none; }
.mbtn span { flex: 1; text-align: center; }
.mbtn.big { height: 38px; width: 178px; }
.mbtn.big span { font-weight: normal; font-size: 18px; }
.mbtn.small { height: 26px; width: 94px; }
.mbtn.small span { font-weight: normal; font-size: 10px; color: #000 !important; }
.mbtn.small .ic { width: 18px; height: 18px; }
.mainmenu .mgrid.c2 { grid-template-columns: repeat(2, 178px); gap: 10px 6px; }
.mainmenu .sm { display: flex; justify-content: center; gap: 6px; margin-top: 14px; }
.mainmenu .site { text-align: center; color: #000080; font: bold 16px Arial; margin-top: 6px; }
.mainmenu .verbox { position: absolute; left: 8px; top: 6px; text-align: center; font: bold 10px Arial; line-height: 13px; }
.mainmenu .verbox small { font-weight: normal; color: #444; }
.mainmenu .datebox { position: absolute; right: 12px; top: 8px; font: bold 11px Arial; color: #000080; }
.mainmenu .logo { width: 40px; height: 40px; background: #222; color: #ffd000; font: bold 8px/9px Arial; padding: 4px 2px; margin: 0 auto 2px; text-align: center; border: 1px solid #000; letter-spacing: .3px; }

/* ---------------------------------------------------------------- controls */
.btn, button.btn, a.btn { display: inline-block; background: #e1e1e1; border: 1px solid #adadad; padding: 2px 12px; font: 11px Tahoma, "Segoe UI", Arial, sans-serif; color: #000; cursor: pointer; min-height: 21px; text-decoration: none; text-align: center; border-radius: 0; }
.btn:hover { background: #e5f1fb; border-color: #0078d7; }
.btn:active { background: #cce4f7; }
.btn.def { border: 2px solid #0078d7; padding: 1px 11px; }
.btn.sm { padding: 0 8px; min-height: 18px; }
.btn:disabled { color: #888; background: #ececec; border-color: #ccc; }
input[type=text], input[type=password], input[type=number], input[type=date], input[type=email], select, textarea {
  font: 11px Tahoma, "Segoe UI", Arial, sans-serif; border: 1px solid #7a7a7a; background: #fff; padding: 1px 3px; height: 20px; color: #000; }
textarea { height: auto; resize: vertical; }
select { height: 20px; padding: 0 1px; background: #fff; }
input:focus, select:focus, textarea:focus { outline: 1px solid #0078d7; border-color: #0078d7; }
input[readonly], input.ro { background: #ececec; }
input[type=checkbox], input[type=radio] { margin: 0 4px 0 0; vertical-align: middle; }
label.ck { font: 11px Tahoma, Arial; margin-right: 10px; }

.tiny, .tiny td, .tiny th { font: 11px Tahoma, "Segoe UI", Arial, sans-serif; }
.lbl { font: bold 11px Tahoma, Arial, sans-serif; color: #000; white-space: nowrap; }
.lbl.r { color: #b00000; }
.hint { font: 11px Tahoma, Arial; color: #333; }
.err { color: #c00; font-weight: bold; }
.ok { color: #060; font-weight: bold; }
hr.sep { border: 0; border-top: 1px solid #c8c8c8; margin: 8px 0; }
.center { text-align: center; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.row { display: flex; align-items: center; gap: 6px; }
.row.wrap { flex-wrap: wrap; }
.gap { height: 10px; }
.go { display: inline-block; width: 22px; height: 22px; border-radius: 50%; background: #2ea62e; border: 1px solid #0a6a0a; color: #fff; font: bold 8px/20px Arial; text-align: center; cursor: pointer; vertical-align: middle; }

fieldset { border: 1px solid #c8c8c8; margin: 6px 0; padding: 6px 8px; }
fieldset legend { font: italic 11px Tahoma, Arial; color: #1030c0; padding: 0 4px; }

/* record forms (Add/Edit Items, Borrowers) */
.rec { display: grid; gap: 3px 8px; align-items: center; }
.rec .lbl { text-align: right; }
.rec input[type=text], .rec select, .rec textarea { width: 100%; }
.rec2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.rl { display: grid; grid-template-columns: 96px 1fr; gap: 3px 6px; align-items: center; margin-bottom: 3px; }
.rl.t { align-items: start; }
.rl.t .lbl { padding-top: 2px; }
.rl .lbl { text-align: right; }
.rl .grp { display: flex; gap: 4px; align-items: center; }
.rl .grp > input, .rl .grp > select { flex: 1; min-width: 0; }
.toolbar { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; margin: 2px 0 6px; }
.toolbar .btn { min-width: 58px; }
.navb { display: inline-block; width: 22px; height: 20px; border: 1px solid #2030a0; background: #3a4ee0; color: #fff; font: bold 11px/18px Arial; text-align: center; cursor: pointer; margin-right: 1px; user-select: none; }
.navb:hover { background: #5a6ef0; }

/* lists / tables */
table.lst { border-collapse: collapse; width: 100%; background: #fff; font: 11px Tahoma, Arial, sans-serif; }
table.lst th { background: linear-gradient(#fff, #e8e8e8); border: 1px solid #c9c9c9; padding: 2px 5px; text-align: left; font-weight: normal; position: sticky; top: 0; cursor: default; }
table.lst td { border-bottom: 1px solid #eee; border-right: 1px solid #f2f2f2; padding: 2px 5px; vertical-align: top; }
table.lst tr:hover td { background: #eaf4ff; }
table.lst tr.sel td { background: #3399ff; color: #fff; }
table.lst tr.od td { background: #ffff66; color: #c00; font-weight: bold; }
.listbox { background: #fff; border: 1px solid #828790; overflow: auto; }
.num { text-align: right; }

/* circulation */
.loanhead { display: grid; grid-template-columns: 1fr 1fr 110px; gap: 4px 10px; background: #f8f8f8; padding: 8px 14px; font: 11px Tahoma, Arial; color: #444; }
.loanhead b { color: #000; }
.loanhead .nm { font: bold 12px Tahoma, Arial; color: #000040; }
.photo { width: 100px; height: 120px; object-fit: cover; background: #cfd8e3; border: 1px solid #aaa; }
.scanrow { text-align: center; margin: 12px 0 6px; font: 11px Tahoma, Arial; color: #800000; }
.scanrow input { width: 160px; height: 22px; }
.cbar { display: flex; justify-content: center; gap: 2px; padding: 8px 0; }
.cbtn { display: flex; align-items: center; gap: 4px; padding: 2px 8px 2px 4px; height: 28px; border: 1px solid #444; background: linear-gradient(#fff, #e6e6e6); font: bold 11px Tahoma, Arial; color: #0000c0; cursor: pointer; }
.cbtn:hover { background: #e3f0fb; }
.cbtn .ic { width: 20px; height: 20px; }

/* search / opac */
.srch .mh { font-family: "Comic Sans MS", "Segoe Print", Arial; }
.srchbtns { display: grid; grid-template-columns: repeat(2, 150px); gap: 8px 6px; justify-content: center; }
.ibar { display: flex; justify-content: center; gap: 2px; margin-top: 22px; flex-wrap: wrap; }
.ibtn { width: 52px; text-align: center; font: 9px Arial; color: #333; cursor: pointer; padding: 2px; }
.ibtn:hover { background: #dbeeff; }
.ibtn .ic { display: block; margin: 0 auto 1px; }
.res { display: grid; grid-template-columns: 62px 38px 1fr 190px; gap: 8px; padding: 6px 4px; border-bottom: 1px solid #888; background: #fff; }
.res .cv { width: 60px; height: 78px; background: #e8e8e8; border: 1px solid #ccc; object-fit: cover; display: block; }
.res .tt { font: bold 12px Arial; }
.res .tt a { color: #000; text-decoration: none; cursor: pointer; }
.res .tt a:hover { text-decoration: underline; }
.res .cl { font: 10px Arial; color: #b00000; font-weight: bold; }
.res .sb { font: 10px Arial; }
.res .av { text-align: right; font: 10px Arial; }
.res .av .a1 { color: #008000; font-weight: bold; font-size: 12px; }
.res .av .a2 { color: #0000c0; font-weight: bold; font-size: 12px; }
.res a.det, .res a.bag { font: 9px Arial; color: #0000c0; text-decoration: underline; cursor: pointer; }

.tabs { display: flex; gap: 0; border-bottom: 1px solid #999; margin: 0 0 10px; padding-left: 8px; }
.tabs button { background: #ececec; border: 1px solid #999; border-bottom: 0; padding: 3px 12px; margin-right: -1px; font: 11px Tahoma, Arial; cursor: pointer; }
.tabs button.on { background: #fff; position: relative; top: 1px; font-weight: bold; }
.tabpane { display: none; } .tabpane.on { display: block; }

.login { max-width: 330px; margin: 0 auto; }
.pwreq { display: flex; gap: 14px; padding: 14px 18px 4px; background: #f0f0f0; }
.pwreq .lg { width: 42px; height: 56px; background: #222; color: #ffd000; font: bold 8px/10px Arial; padding: 6px 2px; text-align: center; border: 1px solid #000; }
.pwreq input { width: 190px; }
.yellow { background: #ffff00; padding: 0 4px; }
.pink { background: #fde8e8; }
.modal-red { color: #b00000; font-weight: bold; font-size: 11px; }
.footnote { font: 10px Tahoma, Arial; color: #444; }
.cols2 { column-count: 2; }
.printonly { display: none; }
@media print {
  body { background: #fff; overflow: visible; }
  #taskbar, .bmtitle, .rz, .foot, .noprint { display: none !important; }
  .printonly { display: block; }
  .bmwin { position: static !important; border: 0; box-shadow: none; width: auto !important; height: auto !important; }
  .bmbody { overflow: visible; }
}
