/* Default css file for jemdoc. */

table#tlayout {
    border: none;
    border-collapse: separate;
    background: white;
}

body {
	background: white;
	font-family: Georgia, serif;
	padding-bottom: 8px;
	margin: 0;
}

#layout-menu {
	background: #f6f6f6;
	border: 1px solid #dddddd;
	padding-top: 0.5em;
	padding-left: 8px;
	padding-right: 8px;
	font-size: 1.0em;
	width: auto;
	white-space: nowrap;
    text-align: left;
    vertical-align: top;
}

#layout-menu td {
	background: #f4f4f4;
    vertical-align: top;
}

#layout-content {
	padding-top: 0.0em;
	padding-left: 1.0em;
	padding-right: 1.0em;
    border: none;
    background: white;
    text-align: left;
    vertical-align: top;
}

#layout-menu a {
	line-height: 1.5em;
	margin-left: 0.5em;
}

tt {
    background: #ffffdd;
}

pre, tt {
	font-size: 90%;
	font-family: monaco, monospace;
}

a, a > tt {
	color: #224b8d;
	text-decoration: none;
}

a:hover {
	border-bottom: 1px gray dotted;
}

#layout-menu a.current:link, #layout-menu a.current:visited {
	color: #022b6d;
	border-bottom: 1px gray solid;
}
#layout-menu a:link, #layout-menu a:visited, #layout-menu a:hover {
	color: #527bbd;
	text-decoration: none;
}
#layout-menu a:hover {
	text-decoration: none;
}

div.menu-category {
	border-bottom: 1px solid gray;
	margin-top: 0.8em;
	padding-top: 0.2em;
	padding-bottom: 0.1em;
	font-weight: bold;
}

div.menu-item {
	padding-left: 16px;
	text-indent: -16px;
}

div#toptitle {
	padding-bottom: 0.2em;
	margin-bottom: 1.5em;
	border-bottom: 3px double gray;
}

/* Reduce space if we begin the page with a title. */
div#toptitle + h2, div#toptitle + h3 {
	margin-top: -0.7em;
}

div#subtitle {
	margin-top: 0.0em;
	margin-bottom: 0.0em;
	padding-top: 0em;
	padding-bottom: 0.1em;
}

em {
	font-style: italic;
}

strong {
	font-weight: bold;
}


h1, h2, h3 {
	color: #527bbd;
	margin-top: 0.7em;
	margin-bottom: 0.3em;
	padding-bottom: 0.2em;
	line-height: 1.0;
	padding-top: 0.5em;
	border-bottom: 1px solid #aaaaaa;
}

h1 {
	font-size: 165%;
}

h2 {
	padding-top: 0.8em;
	font-size: 125%;
}

h2 + h3 {
    padding-top: 0.2em;
}

h3 {
	font-size: 110%;
	border-bottom: none;
}

p {
	margin-top: 0.0em;
	margin-bottom: 0.8em;
	padding: 0;
	line-height: 1.3;
}

pre {
	padding: 0;
	margin: 0;
}

div#footer {
	font-size: small;
	border-top: 1px solid #c0c0c0;
	padding-top: 0.1em;
	margin-top: 4.0em;
	color: #c0c0c0;
}

div#footer a {
	color: #80a0b0;
}

div#footer-text {
	float: left;
	padding-bottom: 8px;
}

ul, ol, dl {
	margin-top: 0.2em;
	padding-top: 0;
	margin-bottom: 0.8em;
}

dt {
	margin-top: 0.5em;
	margin-bottom: 0;
}

dl {
	margin-left: 20px;
}

dd {
	color: #222222;
}

dd > *:first-child {
	margin-top: 0;
}

ul {
	list-style-position: outside;
	list-style-type: square;
}

p + ul, p + ol {
	margin-top: -0.5em;
}

li ul, li ol {
	margin-top: -0.3em;
}

ol {
	list-style-position: outside;
	list-style-type: decimal;
}

li p, dd p {
	margin-bottom: 0.3em;
}


ol ol {
	list-style-type: lower-alpha;
}

ol ol ol {
	list-style-type: lower-roman;
}

p + div.codeblock {
	margin-top: -0.6em;
}

div.codeblock, div.infoblock {
	margin-right: 0%;
	margin-top: 1.2em;
	margin-bottom: 1.3em;
}

div.blocktitle {
	font-weight: bold;
	color: #cd7b62;
	margin-top: 1.2em;
	margin-bottom: 0.1em;
}

div.blockcontent {
	border: 1px solid silver;
	padding: 0.3em 0.5em;
}

div.infoblock > div.blockcontent {
	background: #ffffee;
}

div.blockcontent p + ul, div.blockcontent p + ol {
	margin-top: 0.4em;
}

div.infoblock p {
	margin-bottom: 0em;
}

div.infoblock li p, div.infoblock dd p {
	margin-bottom: 0.5em;
}

div.infoblock p + p {
	margin-top: 0.8em;
}

div.codeblock > div.blockcontent {
	background: #f6f6f6;
}

span.pycommand {
	color: #000070;
}

span.statement {
	color: #008800;
}
span.builtin {
	color: #000088;
}
span.special {
	color: #990000;
}
span.operator {
	color: #880000;
}
span.error {
	color: #aa0000;
}
span.comment, span.comment > *, span.string, span.string > * {
	color: #606060;
}

@media print {
	#layout-menu { display: none; }
}

#fwtitle {
	margin: 2px;
}

#fwtitle #toptitle {
	padding-left: 0.5em;
	margin-bottom: 0.5em;
}

#layout-content h1:first-child, #layout-content h2:first-child, #layout-content h3:first-child {
	margin-top: -0.7em;
}

div#toptitle h1, #layout-content div#toptitle h1 {
	margin-bottom: 0.0em;
	padding-bottom: 0.1em;
	padding-top: 0;
	margin-top: 0.5em;
	border-bottom: none;
}

img.eq {
	padding: 0;
	padding-left: 0.1em;
	padding-right: 0.1em;
	margin: 0;
}

img.eqwl {
	padding-left: 2em;
	padding-top: 0.6em;
	padding-bottom: 0.2em;
	margin: 0;
}

table {
    border: 2px solid black;
    border-collapse: collapse;
}

td {
    padding: 2px;
    padding-left: 0.5em;
    padding-right: 0.5em;
    text-align: center;
    border: 1px solid gray;
}

table + table {
    margin-top: 1em;
}

tr.heading {
    font-weight: bold;
    border-bottom: 2px solid black;
}

img {
    border: none;
}

table.imgtable, table.imgtable td {
    border: none;
    text-align: left;
}



/* members */
div#member-container{
	text-align: center;
}
div#member{
	display: inline-block;
	vertical-align: top;
	width: 240px;
	text-align: center;
	margin-bottom: 15px;
	margin-right: 10px;
}

div#member img{
	width: 220px;
	height:440px;
	margin: 0px;
	padding: 0px;
}

div#member p{
	text-align: center;
	margin: 0px;
	padding: 0px;
}
/* ─── 2026-05 modernisation pass — additive only, keeps academic feel ─── */

/* Cap content width on large screens for readability (~85ch). */
#layout-content {
    max-width: 920px;
}

/* Slightly more breathing room in body paragraphs. */
p {
    line-height: 1.55;
}
li {
    line-height: 1.5;
    margin-top: 0.15em;
}

/* Images never overflow their column; default to a sensible size with subtle treatment. */
img {
    max-width: 100%;
    height: auto;
}

/* Centred figures for screenshots — used when the page wraps an image in <figure>. */
figure {
    margin: 1.2em auto;
    padding: 6px;
    background: #fafafa;
    border: 1px solid #e6e6e6;
    border-radius: 4px;
    max-width: 720px;
    text-align: center;
}
figure img {
    display: block;
    margin: 0 auto;
    border-radius: 2px;
}
figure figcaption {
    font-style: italic;
    font-size: 13px;
    color: #666;
    padding: 6px 4px 0;
}

/* Mobile: drop the table-based sidebar, stack vertically. */
@media (max-width: 720px) {
    table#tlayout, table#tlayout tbody, table#tlayout tr, table#tlayout td {
        display: block;
        width: 100%;
    }
    #layout-menu {
        width: auto !important;
        white-space: normal;
        margin-bottom: 1em;
    }
    #layout-content {
        padding: 0.6em;
    }
}

/* ─── 2026-05 phase-2: typography + nav + links polish (academic, not flashy) ─── */

/* Modern serif: Charter renders natively on macOS / iOS / Win11; falls back to Georgia. */
body {
    font-family: Charter, "Iowan Old Style", "Source Serif 4", "Source Serif Pro", "Palatino Linotype", Georgia, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Serif CJK SC", "Noto Sans CJK SC", ui-serif, serif;
    font-size: 16.5px;
    color: #1f2937;
}

/* ─── Mobile hamburger drawer menu ─── */
#menu-toggle, #menu-backdrop { display: none; }

@media (max-width: 720px) {
  #menu-toggle {
    display: block;
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 1001;
    width: 40px;
    height: 40px;
    padding: 0;
    font-size: 19px;
    line-height: 38px;
    text-align: center;
    color: #334155;
    background: rgba(255,255,255,.82);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    border: 1px solid #e3e6ea;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
    cursor: pointer;
    transition: background-color .15s ease, box-shadow .15s ease;
  }
  #menu-toggle:hover { background: #ffffff; box-shadow: 0 2px 7px rgba(0,0,0,.12); }
  #menu-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.4);
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
    z-index: 999;
  }
  body.menu-open #menu-backdrop { opacity: 1; pointer-events: auto; }

  #layout-menu {
    position: fixed !important;
    top: 0;
    left: 0;
    bottom: 0;
    width: 78% !important;
    max-width: 280px;
    margin: 0 !important;
    padding: 56px 8px 16px !important;
    overflow-y: auto;
    background: #f6f6f6;
    border-right: 1px solid #ddd;
    transform: translateX(-100%);
    transition: transform .25s ease;
    z-index: 1000;
    box-shadow: 2px 0 10px rgba(0,0,0,.25);
  }
  body.menu-open #layout-menu { transform: translateX(0); }

  html, body { overflow-x: hidden; }
  #layout-content { box-sizing: border-box; max-width: 100%; padding-top: 56px !important; }
}

/* Section headings: cleaner border, modern weight, slightly tighter blue. */
h1, h2, h3 {
    color: #1e3a5f;
    font-weight: 600;
    letter-spacing: -0.005em;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 0.3em;
    margin-top: 1.4em;
    margin-bottom: 0.55em;
}
h1 { font-size: 1.85em; border-bottom-width: 2px; border-bottom-color: #d1d5db; }
h2 { font-size: 1.3em; }
h3 { font-size: 1.08em; border-bottom: none; }

/* Top title: replace dated double-border with a single thin line. */
div#toptitle {
    border-bottom: 2px solid #d1d5db;
    padding-bottom: 0.5em;
    margin-bottom: 1.5em;
}

/* Links: cleaner blue, underline on hover (not dotted). */
a, a > tt {
    color: #2563eb;
    text-decoration: none;
}
a:hover {
    color: #1e40af;
    border-bottom: none;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

/* Sidebar: softer surface, clear visual hierarchy, modern menu group label. */
#layout-menu {
    background: #fafbfc;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    padding: 12px 16px;
}
#layout-menu td { background: transparent; }
div.menu-category {
    border-bottom: 1px solid #d1d5db;
    color: #374151;
    margin-top: 1em;
    padding-bottom: 0.3em;
    text-transform: uppercase;
    font-size: 0.72em;
    letter-spacing: 0.06em;
    font-weight: 700;
}
#layout-menu a {
    line-height: 1.85;
    margin-left: 0;
    color: #374151;
    font-size: 0.95em;
}
#layout-menu a:hover {
    color: #2563eb;
    text-decoration: none;
}
#layout-menu a.current:link, #layout-menu a.current:visited {
    color: #1e40af;
    font-weight: 600;
    border-bottom: none;
}

/* Inline code: drop the 2005-era yellow box. */
tt {
    background: #f3f4f6;
    color: #be185d;
    border-radius: 3px;
    padding: 1px 5px;
    font-size: 0.92em;
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
pre tt, tt tt { background: transparent; padding: 0; color: inherit; }

/* Horizontal rules / footer: lighter touch. */
div#footer {
    border-top: 1px solid #e5e7eb;
    color: #9ca3af;
    margin-top: 3em;
}

/* (menu item styling reverted to the previous version per request) */

/* Space out Experience entries: loose between entries, tight within one. */
#layout-content > p:has(> i) { margin-top: 2.1em; margin-bottom: 0.15em; }
#layout-content > p:has(> i):first-of-type { margin-top: 1em; }
#layout-content > p:has(> i) + ul { margin-top: 0.2em; }
