/* ==========================================================================
   Vertex 5 — layout, menu, module boxes and Joomla 5 markup.
   Colours/sizes follow the original Shape5 Vertex settings on changhuitan.com.
   Variables are set from the template style (see index.php).
   ========================================================================== */

:root {
  --v5-hl: #73A0CF;
  --v5-bg: #F0F0F0;
  --v5-body-font: Arial, Helvetica, sans-serif;
  --v5-head-font: 'Oswald', Arial, sans-serif;
  --v5-width: 94%;
  --v5-max-width: 1300px;
  --v5-left: 240px;
  --v5-right: 238px;
  --v5-font-size: 13px;
  --v5-border: #C5C5C5;
  --v5-shadow: 0 0 8px #BDBDBD;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--v5-bg);
  font-family: var(--v5-body-font);
  font-size: var(--v5-font-size);   /* Vertex: 0.8125em = 13px */
  line-height: 140%;
  color: #333;
}
img { max-width: 100%; height: auto; }
#map_canvas img, .gm-style img { max-width: none; }

a, h2, h4, .btn-link { color: var(--v5-hl); }
h2, .s5_mod_h3 { font-family: var(--v5-head-font); }
.s5_mod_h3 { text-transform: uppercase; }

.v5-skip { position: absolute; left: -9999px; top: 0; z-index: 9999; background: #fff; padding: 8px 12px; }
.v5-skip:focus { left: 8px; top: 8px; }

/* -------------------------------------------------- wrapper */
.s5_wrap {
  width: var(--v5-width);
  max-width: var(--v5-max-width);
  margin: 0 auto;
}

/* -------------------------------------------------- header */
#s5_header_area_inner { padding-top: 28px; }

#s5_header_area_inner2,
#s5_component_wrap,
#s5_footer_area_inner2 {
  background: #fff;
  border: 1px solid var(--v5-border);
  border-radius: 6px;
  margin: 0 7px 14px;
  box-shadow: var(--v5-shadow);
}

#s5_header_wrap {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  background: #1A1A1A;
  border-radius: 6px 6px 0 0;
  min-height: 130px;
}
#s5_logo_link { display: block; flex: 0 1 auto; line-height: 0; }
#s5_logo { display: block; width: auto; max-height: 130px; height: auto; cursor: pointer; }
#s5_banner {
  flex: 1 1 auto;
  padding: 36px 32px 0 0;
  color: #ccc;
  text-align: right;
}
#s5_banner a { color: #999; }
#s5_banner img { display: inline-block; vertical-align: middle; }

/* -------------------------------------------------- main menu */
#s5_menu_wrap {
  display: flex;
  align-items: stretch;
  background: #151515;
  border-top: 1px solid #222;
  font-family: var(--v5-head-font);
  text-transform: uppercase;
  position: relative;
  z-index: 50;
}
#s5_menu_inner { flex: 1 1 auto; }
#v5_menu_toggle { display: none; }

#s5_nav, #s5_nav ul { list-style: none; margin: 0; padding: 0; }
#s5_nav { display: flex; flex-wrap: wrap; }

#s5_nav > li {
  position: relative;
  height: 59px;
  padding: 7px 17px 0;
  border-right: 1px solid #222;
}
#s5_nav > li > .s5_level1_span1 { display: block; height: 32px; }
#s5_nav > li > .s5_level1_span1 > .s5_level1_span2 { display: block; padding-top: 6px; }
#s5_nav > li > .s5_level1_span1 a,
#s5_nav > li > .s5_level1_span1 .s5_nolink {
  color: #fff;
  font-size: 1.3em;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}
#s5_nav > li.mainParentBtn > .s5_level1_span1 a,
#s5_nav > li.mainParentBtn > .s5_level1_span1 .s5_nolink {
  padding-right: 18px;
  background: url(../images/s5_menu_arrow.png) no-repeat right center;
}
#s5_nav > li.active > .s5_level1_span1 a { color: var(--v5-hl); }

/* hovered / open top tab turns white, like Vertex */
#s5_nav > li { transition: background-color .25s ease; }
#s5_nav > li:hover,
#s5_nav > li:focus-within,
#s5_nav > li.v5-open { background: #fff; }
#s5_nav > li:hover > .s5_level1_span1 a,
#s5_nav > li:focus-within > .s5_level1_span1 a,
#s5_nav > li.v5-open > .s5_level1_span1 a,
#s5_nav > li:hover > .s5_level1_span1 .s5_nolink,
#s5_nav > li.v5-open > .s5_level1_span1 .s5_nolink { color: var(--v5-hl); }
#s5_nav > li.mainParentBtn:hover > .s5_level1_span1 a,
#s5_nav > li.mainParentBtn:focus-within > .s5_level1_span1 a,
#s5_nav > li.mainParentBtn.v5-open > .s5_level1_span1 a { background-image: url(../images/s5_menu_arrow_focus.png); }
#s5_nav > li:hover .S5_parent_subtext,
#s5_nav > li:focus-within .S5_parent_subtext,
#s5_nav > li.v5-open .S5_parent_subtext { color: #333; }

.S5_parent_subtext {
  display: block;
  clear: both;
  color: #ccc;
  font-size: 0.7em;
  line-height: inherit;
  white-space: nowrap;
  cursor: pointer;
}

/* drop-downs — same as Vertex's MenuMatic "slide & fade": the panel slides
   out from under the menu bar (marginTop -height -> 0) while fading in,
   500 ms easeOutCirc; it waits 250 ms (hideDelay) and then slides back.
   Fly-outs slide out to the right the same way. */
#s5_nav ul.s5_sub_wrap {
  display: block;
  position: absolute;
  left: 0;
  top: 59px;
  width: max-content;
  min-width: 220px;
  max-width: 290px;
  padding: 8px 0 13px;           /* measured on the live site: 8px above, 13px below */
  line-height: 1em;              /* Vertex: 13px lines in the drop-downs */
  background: #fff;
  border: 1px solid var(--v5-border);
  border-top: none;
  border-bottom: 3px solid var(--v5-hl);
  box-shadow: 2px 2px 2px rgba(0, 0, 0, .2);
  text-transform: none;
  z-index: 100;
  visibility: hidden;
  opacity: 0;
  /* slid up by its own height and clipped at the menu bar's lower edge */
  transform: translateY(-100%);
  clip-path: inset(100% -100vw -100vh -12px);
  pointer-events: none;
  transition:
    transform .5s cubic-bezier(.075, .82, .165, 1) .25s,
    clip-path .5s cubic-bezier(.075, .82, .165, 1) .25s,
    opacity .5s ease .25s,
    visibility 0s linear .75s;
}
#s5_nav ul.s5_sub_wrap ul.s5_sub_wrap {
  left: 100%;
  top: 0;                        /* top edge level with the hovered item, as on the live site */
  max-width: none;               /* Vertex: fly-outs as wide as the longest title */
  padding: 8px 0 10px;           /* Vertex: ul ul padding 8px top, 10px bottom */
  white-space: nowrap;
  border-top: 1px solid var(--v5-border);
  transform: translateX(-100%);
  clip-path: inset(-100vh -100vw -100vh 100%);
}
#s5_nav li:hover > ul.s5_sub_wrap,
#s5_nav li:focus-within > ul.s5_sub_wrap,
#s5_nav li.v5-open > ul.s5_sub_wrap {
  visibility: visible;
  opacity: 1;
  transform: none;
  clip-path: inset(0 -100vw -100vh -12px);
  pointer-events: auto;
  transition:
    transform .5s cubic-bezier(.075, .82, .165, 1),
    clip-path .5s cubic-bezier(.075, .82, .165, 1),
    opacity .5s ease,
    visibility 0s;
}
#s5_nav li:hover > ul.s5_sub_wrap ul.s5_sub_wrap { clip-path: inset(-100vh -100vw -100vh 100%); }
#s5_nav ul.s5_sub_wrap li:hover > ul.s5_sub_wrap,
#s5_nav ul.s5_sub_wrap li:focus-within > ul.s5_sub_wrap,
#s5_nav ul.s5_sub_wrap li.v5-open > ul.s5_sub_wrap { clip-path: inset(-100vh -100vw -100vh 0); }

#s5_nav ul.s5_sub_wrap li { position: relative; padding: 0 8px; }   /* Vertex: 0 8px */
#s5_nav ul.s5_sub_wrap ul.s5_sub_wrap a,
#s5_nav ul.s5_sub_wrap ul.s5_sub_wrap .s5_nolink { white-space: nowrap; }

/* picture on the left, as tall as title + subtitle; text beside it */
.S5_submenu_item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  padding: 6px;
  border-radius: 2px;
}
.S5_submenu_item:hover { background: #F2F1F1; }
/* menu pictures at their own size (25x25 icons), top-aligned, 8px gap — as in Vertex */
.s5_img_span { grid-column: 1; grid-row: 1 / span 2; margin-right: 8px; line-height: 0; align-self: start; }
.s5_img_span img { display: block; width: 25px; height: 25px; max-width: none; object-fit: contain; }   /* menu pictures: 25px box, any file size or SVG */
.s5_sub_a_span { grid-column: 2; align-self: end; }
.S5_subtext { grid-column: 2; align-self: start; }
.S5_submenu_item:not(:has(.s5_img_span)) { grid-template-columns: minmax(0, 1fr); }
.S5_submenu_item:not(:has(.s5_img_span)) > * { grid-column: 1; }
#s5_nav ul.s5_sub_wrap a,
#s5_nav ul.s5_sub_wrap .s5_nolink {
  display: block;
  color: #333;
  font-size: 0.9em;              /* Vertex: 0.9em (11.7px) */
  line-height: inherit;
  text-decoration: none;
  white-space: normal;
}
#s5_nav ul.s5_sub_wrap li.subParentBtn > .S5_submenu_item .s5_sub_a_span {
  padding-right: 16px;
  background: url(../images/s5_menu_arrow_subs.png) no-repeat right center;
}
#s5_nav ul.s5_sub_wrap li.active > .S5_submenu_item a,
#s5_nav ul.s5_sub_wrap li:hover > .S5_submenu_item a { color: var(--v5-hl); }
.S5_subtext {
  padding-top: 2px;
  color: #888787;
  font-family: var(--v5-head-font);
  font-size: 0.8em;              /* Vertex: 0.8em (10.4px) */
  line-height: inherit;
  cursor: pointer;
}

.v5-sub-toggle { display: none; }

/* search in the menu bar (Smart Search module) */
#s5_search { flex: 0 0 auto; padding: 0; }
#s5_search label, #s5_search button, #s5_search .visually-hidden { display: none; }
#s5_search form { margin: 0; }
#s5_search input[type="search"], #s5_search input[type="text"] {
  width: 168px;
  margin: 12px 22px 9px 0;
  padding: 8px 14px;
  line-height: 20px;
  border: none;
  border-radius: 8px;
  background: #151515;
  color: #fff;
  font-family: var(--v5-head-font);
  font-size: 0.8em;
  box-shadow: 0 0 18px 2px rgba(0, 0, 0, .5) inset;
}
#s5_search input::placeholder { color: #ddd; }
#s5_search .awesomplete > ul { text-transform: none; font-family: var(--v5-body-font); }

/* -------------------------------------------------- breadcrumb bar */
#s5_breadcrumb_fonts_wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 14px 20px 12px;
}
#s5_breadcrumb_wrap .breadcrumb, #s5_breadcrumb_wrap ol {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
  background: none;
}
#s5_breadcrumb_wrap li { margin: 0; padding: 0; float: none; }
#s5_breadcrumb_wrap .mod-breadcrumbs__here { color: #333; padding-right: 4px; }
#s5_breadcrumb_wrap .breadcrumb-item + .breadcrumb-item::before {
  content: "\203A";
  padding: 0 6px;
  color: #999;
}
#s5_breadcrumb_wrap .breadcrumb-item.active, #s5_breadcrumb_wrap li:last-child { color: #888; }
#s5_breadcrumb_wrap .divider, #s5_breadcrumb_wrap img { display: none; }

#s5_social_wrap1 { display: flex; flex-direction: row-reverse; align-items: center; gap: 0; }
#s5_social_wrap1 .v5-social { display: block; float: none; margin-left: 7px; }
#s5_loginreg { margin: 0 5px 0 10px; }
#s5_register { margin-left: 7px; }
#fontControls { display: flex; align-items: baseline; gap: 3px; margin-right: 15px; }
#fontControls button {
  border: 0;
  background: none;
  padding: 0 1px;
  color: #151515;
  cursor: pointer;
  font-family: inherit;
  line-height: 1;
}
#fontControls .decreaseSize { font-size: 12px; }
#fontControls .resetSize { font-size: 15px; }
#fontControls .increaseSize { font-size: 19px; }

/* -------------------------------------------------- columns */
#s5_columns_wrap {
  display: grid;
  grid-template-columns: var(--v5-left) minmax(0, 1fr) var(--v5-right);
  grid-template-areas: "left center right";
  align-items: start;
}
.no-left  #s5_columns_wrap { grid-template-columns: minmax(0, 1fr) var(--v5-right); grid-template-areas: "center right"; }
.no-right #s5_columns_wrap { grid-template-columns: var(--v5-left) minmax(0, 1fr); grid-template-areas: "left center"; }
.no-left.no-right #s5_columns_wrap { grid-template-columns: minmax(0, 1fr); grid-template-areas: "center"; }

#s5_center_column_wrap { grid-area: center; min-width: 0; }
#s5_left_column_wrap   { grid-area: left; min-width: 0; }
#s5_right_column_wrap  { grid-area: right; min-width: 0; }

#s5_component_wrap { padding: 20px; overflow-wrap: break-word; }
#s5_component_wrap:focus { outline: none; }
#s5_component_wrap h3 { margin-bottom: 8px; }

.v5-row { display: flex; flex-wrap: wrap; }
.v5-row > .v5-col { flex: 1 1 0; min-width: 0; }
#s5_bottom_row1_area1 { margin-top: 0; }

/* -------------------------------------------------- module boxes */
.module_round_box_outer { margin: 0 7px 14px; }
.module_round_box,
.module_round_box-dark {
  border: 1px solid var(--v5-border);
  border-radius: 6px;
  padding: 20px 20px 16px;
  background: #fff;
  box-shadow: var(--v5-shadow);
}
.module_round_box-dark { background: #1A1A1A; color: #fff; }
.module_round_box-none { background: none; }
.module_round_box .s5_mod_h3,
.module_round_box-dark .s5_mod_h3 {
  margin: -20px -20px 12px;
  padding: 12px 13px 11px;
  border-bottom: 1px solid var(--v5-border);
  border-radius: 6px 6px 0 0;
  background: linear-gradient(to bottom, #fff 0%, #F9F9F9 100%);
  font-size: 1em;
  font-weight: normal;
}
.module_round_box-dark .s5_mod_h3 { background: linear-gradient(to bottom, #1A1A1A 0%, #121212 100%); border-bottom-color: #0B0B0B; color: #fff; }
.s5_h3_first { color: var(--v5-hl); }
.module_round_box-dark .s5_h3_first { color: #999; }
.s5_mod_h3_below { clear: both; }
.s5_outer > :last-child { margin-bottom: 0; }
.module_round_box .custom > div > p:first-child, .s5_outer p { margin-top: 0; }

/* lists in module boxes: arrow bullet + dotted separator (Vertex style) */
.module_round_box ul.latestnews,
.module_round_box ul.mod-articlescategory,
.module_round_box ul.category-module,
.module_round_box ul.mostread,
.module_round_box ul.weblinks,
.module_round_box ul.mod-articles-category,
.module_round_box ul.mod-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.module_round_box ul.mod-articlescategory > li,
.module_round_box ul.category-module > li,
.module_round_box ul.mod-articles-category > li,
.module_round_box ul.mod-list > li {
  padding: 6px 0 6px 24px;
  border-bottom: 1px dotted #D3D3D3;
  background: url(../images/system/arrow.png) no-repeat left center;
}
.module_round_box ul > li:last-child { border-bottom: 0; }
/* web links: plain list, as in Vertex */
.module_round_box ul.weblinks > li { padding: 2px 0; background: none; border-bottom: 0; }
.module_round_box ul.menu a { background: url(../images/system/arrow.png) no-repeat left center; }

/* -------------------------------------------------- footer */
#s5_footer_area_inner2 {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 17px 20px 14px;
  font-size: 0.9em;
}
#s5_bottom_menu_wrap ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 8px; }
#s5_bottom_menu_wrap .mod-languages ul { margin: 0; }
#s5_bottom_menu_wrap .lang-active img, #s5_bottom_menu_wrap .lang-active { opacity: 1; }

/* scroll to top */
#s5_scrolltopvar {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 30px;
  height: 30px;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: transparent url(../images/s5_scroll_arrow.png) no-repeat;
  opacity: .85;
  z-index: 40;
}
#s5_scrolltopvar:hover { opacity: 1; }

/* -------------------------------------------------- Joomla 5 core markup */
.visually-hidden, .element-invisible {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0;
}
.float-start { float: left; }
.float-end { float: right; }
.text-center { text-align: center; }
.d-none { display: none !important; }
.list-unstyled { list-style: none; padding-left: 0; margin-left: 0; }
.clearfix::after { content: ""; display: table; clear: both; }
.img-fluid { max-width: 100%; height: auto; }

/* article / blog */
/* Joomla 4–6 print the article/page title as <h1>; Vertex (J3) used <h2>.
   Give both the Vertex heading look: blue Oswald, normal case. */
#s5_component_wrap .page-header h1,
#s5_component_wrap .item-page h1,
#s5_component_wrap .blog-featured h1,
#s5_component_wrap > main > div > h1,
#s5_component_wrap .com-content-category-blog > h1 {
  margin: 0 0 18px;
  padding: 0;
  color: var(--v5-hl);
  font-family: var(--v5-head-font);
  font-size: 1.4em;
  font-weight: normal;
  line-height: 1;
  text-transform: none;
}
.com-content-article .page-header h1,
.com-content-article .page-header h2,
.item-page .page-header h2,
.blog .page-header h2,
.blog-item .page-header h2 { margin: 0 0 18px; font-size: 1.4em; font-weight: normal; }
/* single article page (Teaching, About me, ...): a larger title, set apart
   from the article's own headings by a line — same size as the Research items */
#s5_component_wrap .content-category > h1,
#s5_component_wrap .com-content-article.item-page > .page-header {
  margin: 0 0 16px;
  padding: 0 0 10px;
  border-bottom: 2px solid #E3E3E3;
}
#s5_component_wrap .content-category > h1,
#s5_component_wrap .com-content-article.item-page > .page-header h1 {
  margin: 0;
  font-size: 2.1em;
  line-height: 1.15;
}
/* the "Display #" box (5 / 10 / ... / All) sits in the heading row, above the line */
#s5_component_wrap .content-category:has(> h1) { position: relative; }
#s5_component_wrap .content-category:has(> h1) .com-content-category__pagination {
  position: absolute;
  top: 0;
  right: 0;
  float: none;
}
#s5_component_wrap .content-category:has(> h1) .com-content-category__pagination .form-select { width: auto; }
/* "New Article" button (shown when logged in): also in the heading row,
   left of the Display # box, instead of below the whole list */
#s5_component_wrap .content-category:has(> h1) a.btn[href*="task=article.add"] {
  position: absolute;
  top: 0;
  right: 82px;
  padding: 5px 10px;
}
#s5_component_wrap .content-category:has(> h1):has(a[href*="task=article.add"]) > h1 { padding-right: 210px; }
#s5_component_wrap .content-category > h1 {
  padding-right: 90px;
  margin-bottom: 16px;
  color: var(--v5-hl);
  font-family: var(--v5-head-font);
  font-weight: normal;
  text-transform: none;
}
/* headings inside article text: less space below them than Vertex's 18px */
.com-content-article__body :is(h2, h3, h4) { margin-bottom: 10px; }
/* download links with a file-type icon (archive, mp4, pdf, ppt, ...):
   text centred vertically on the icon */
#s5_component_wrap a > img[src*="images/logo/"] { vertical-align: middle; margin-right: 5px; }
/* even space between sections (replaces blank lines typed into the text) */
.com-content-article__body > :is(h2, h3, h4):not(:first-child) { margin-top: 24px; }
.com-content-article__body > :is(h2, h3, h4) + :is(h2, h3, h4) { margin-top: 0; }
/* info tables right under a heading (e.g. "Course Information" on the
   Teaching pages): a little more space between the lines */
.com-content-article__body :is(h2, h3, h4) + table td,
.com-content-article__body :is(h2, h3, h4) + table th {
  padding-top: 4px;
  padding-bottom: 4px;
  line-height: 1.45;
  vertical-align: top;
}
/* older Teaching pages (2010-2016) list the course info as <ul class="text">
   (layout from images/jtemp.css): same extra line space */
.com-content-article__body ul.text li { padding-top: 4px; padding-bottom: 4px; line-height: 1.45; }
/* jtemp.css places the value with "position:absolute; left:150px", which
   overlaps long labels/values here; use two real columns instead */
.com-content-article__body ul.text li:has(> .second) { display: grid; grid-template-columns: 150px 1fr; }
.com-content-article__body ul.text li > .second { position: static; }
.blog-item .page-header h2 a { text-decoration: none; }
.blog-item .page-header h2 a:hover { text-decoration: underline; }
.blog h1, .blog > h2, .com-content-category-blog > h2 { font-size: 1.6em; font-weight: normal; margin: 0 0 10px; }
.subheading-category { font-size: 1em; text-transform: none; }
.category-desc { padding: 0 0 16px; border-bottom: 1px solid #EDEDED; margin-bottom: 18px; overflow: hidden; }
.category-desc img { float: right; margin: 0 0 10px 14px; }
.blog-items .blog-item, .items-leading > div {
  padding-bottom: 16px;
  margin-bottom: 18px;
  border-bottom: 1px solid #EDEDED;
}
.blog-items .blog-item:last-child { border-bottom: 0; }
/* "Details" block, stacked one per line as on the Vertex/J3 site */
dl.article-info { margin: 0 0 12px; font-size: 1em; color: #333; }
dl.article-info dt.article-info-term { display: block; font-weight: bold; }
dl.article-info dd { display: block; margin: 0; }
dl.article-info [class^="icon-"], dl.article-info .icon-fw { display: none; }
p.readmore { margin: 8px 0 0; }
p.readmore a, p.readmore a.btn {
  display: inline-block;
  padding: 5px 10px;
  background: var(--v5-hl);
  color: #fff !important;
  border-radius: 3px;
  font-weight: bold;
  font-size: .9em;
  text-decoration: none;
}
p.readmore a:hover { background: #666; }
p.readmore .icon-chevron-right, p.readmore [class^="icon-"] { display: none; }
ul.tags { list-style: none; padding: 0; margin: 10px 0; }
ul.tags li { display: inline-block; margin: 0 4px 4px 0; }

/* article navigation (Prev / Next) */
.pagenavigation .pagination { display: flex; justify-content: space-between; height: auto; }
.pagenavigation a {
  display: inline-block;
  padding: 5px 10px;
  border-radius: 3px;
  background: var(--v5-hl);
  color: #fff;
  text-decoration: none;
}
.pagenavigation a:hover { background: #666; }

/* list pagination */
.pagination__wrapper, .com-content-category-blog__navigation { text-align: center; margin: 10px 0; }
ul.pagination {
  display: inline-flex;
  flex-wrap: wrap;
  list-style: none;
  gap: 4px;
  margin: 0 !important;
  padding: 0;
  height: auto;
}
ul.pagination li { float: none; }
ul.pagination .page-link {
  display: block;
  padding: 4px 9px;
  border: 1px solid #D8D8D8;
  border-radius: 3px;
  text-decoration: none;
}
ul.pagination .active .page-link { background: var(--v5-hl); border-color: var(--v5-hl); color: #fff; }
ul.pagination .disabled .page-link { color: #aaa; }
.counter, .com-content-category-blog__counter { color: #888; text-align: center; }

/* forms */
.btn, button.btn, input[type="submit"] {
  display: inline-block;
  padding: 6px 12px;
  border: 0;
  border-radius: 3px;
  background: var(--v5-hl);
  color: #fff;
  font: bold 1em/1.3 var(--v5-body-font);
  text-decoration: none;
  vertical-align: middle;
  cursor: pointer;
}
.btn:hover, .btn:focus { background: #666; color: #fff; text-decoration: none; }
.btn-secondary { background: #888; }
.btn-danger { background: #B94A48; }
.btn-success { background: #448344; }
.btn-link { background: transparent; color: var(--v5-hl); font-weight: normal; }
.btn-link:hover, .btn-link:focus { background: transparent; color: #333; }
.btn [class^="icon-"], .btn [class*=" icon-"] { margin-right: 4px; }
.btn-group { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.btn-toolbar { display: flex; flex-wrap: wrap; gap: 6px; }
.form-control, .inputbox, input[type="text"], input[type="email"], input[type="password"], input[type="search"], input[type="url"], input[type="number"], input[type="tel"], textarea, select {
  max-width: 100%;
  font: inherit;
}

/* Joomla's front-end forms (editing an article or module, profile, ...) */
#s5_component_wrap .form-control,
#s5_component_wrap .form-select,
#s5_component_wrap textarea {
  display: block;
  width: 100%;
  padding: 6px 8px;
  border: 1px solid #C4C4C4;
  border-radius: 3px;
  background: #fff;
  color: #333;
  line-height: 1.4;
}
#s5_component_wrap .form-select { padding-right: 24px; }
#s5_component_wrap .form-control:focus,
#s5_component_wrap .form-select:focus,
#s5_component_wrap textarea:focus { border-color: var(--v5-hl); outline: 2px solid rgba(115, 160, 207, .25); }
#s5_component_wrap .form-control[readonly], #s5_component_wrap .form-control:disabled { background: #F3F3F3; }
.control-group, .mb-3 { margin-bottom: 14px; }
.control-label, .control-label label, .form-label { display: block; margin-bottom: 4px; font-weight: bold; }
.control-label .star, .form-label .star, .star { color: #B94A48; }
.form-text, small.text-muted, .text-muted, .small { color: #777; font-size: .92em; }
.form-text { display: block; margin-top: 4px; }
.input-group { display: flex; align-items: stretch; width: 100%; }
.input-group > .form-control, .input-group > .form-select { flex: 1 1 auto; width: 1%; min-width: 0; }
.input-group > .form-control:not(:last-child) { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.input-group > .btn { border-radius: 0 3px 3px 0; }
#s5_component_wrap fieldset { margin: 0 0 18px; padding: 0; border: 0; min-width: 0; }
#s5_component_wrap legend {
  display: block; width: 100%; margin-bottom: 10px; padding-bottom: 4px;
  border-bottom: 1px solid #DDD; font-size: 1.15em; font-weight: bold;
}
.invalid, .form-control.invalid { border-color: #B94A48 !important; color: #B94A48; }
label.invalid { background: none; }
/* "remove" button in category / tag pickers: a small × like Joomla's template */
.choices__button_joomla {
  margin-left: 6px; padding: 0 3px; border: 0; background: none;
  font-size: 0; line-height: 1; cursor: pointer; vertical-align: middle;
}
.choices__button_joomla::before { content: "\00D7"; font-size: 15px; color: #777; }
.choices__button_joomla:hover::before { color: #B94A48; }
/* Yes/No switches: plain radio buttons side by side */
.switcher { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; }
.switcher .toggle-outside { display: none; }
/* the Save / Save & Close / Cancel bar */
.d-grid.gap-2 { display: flex; flex-wrap: wrap; gap: 6px; }
.edit.item-page .d-grid.gap-2 { margin: 0 0 14px; }
.edit.item-page .toggle-editor { margin-top: 8px; text-align: right; }
.edit.item-page .tox-tinymce { border-radius: 3px; }
.float-end { float: right; }
.clearfix::after { content: ""; display: table; clear: both; }
.mt-3 { margin-top: 1rem; }
.mb-2 { margin-bottom: .5rem; }
.hidden, [hidden] { display: none !important; }

/* front-end editing: the small edit buttons and their hover labels */
[role="tooltip"]:not(.show) {
  display: none;
  position: absolute;
  z-index: 1070;
  max-width: 280px;
  margin: 4px;
  padding: 6px 9px;
  border: 1px solid #6D757E;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 0 .5rem rgba(0, 0, 0, .5);
  color: #000;
  font: normal 12px/1.4 var(--v5-body-font);
  letter-spacing: normal;
  text-align: left;
  text-transform: none;
  white-space: normal;
}
:hover + [role="tooltip"], :focus + [role="tooltip"],
a:hover > [role="tooltip"], a:focus > [role="tooltip"] { display: block; }
*:has(> .jmodedit) { position: relative; }
.btn.jmodedit {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 900;
  padding: 2px 6px;
  border: 0;
  border-radius: 3px;
  background: rgba(255, 255, 255, .85);
  color: var(--v5-hl);
  font-weight: normal;
  line-height: 1.2;
}
.btn.jmodedit:hover, .btn.jmodedit:focus { background: #fff; color: #333; }
.btn.jmodedit [class^="icon-"] { margin: 0; }
.jmodedit + [role="tooltip"] { top: 1.8em; right: 0; }
a.jmenuedit { display: none; }
/* "Edit" link on articles */
.icons, a[aria-describedby^="editarticle-"] { position: relative; }
a[aria-describedby^="editarticle-"] { font-size: .92em; }
a[aria-describedby^="editarticle-"] > [role="tooltip"] { top: 1.4em; left: 0; white-space: nowrap; }

/* tables: Vertex dark header kept, but only on Joomla's own list tables */
table { max-width: 100%; }
#s5_component_wrap table:not(.table):not(.category) th { background: none; color: inherit; }
table.table, table.category { width: 100%; border-collapse: collapse; }
table.table thead th, table.category thead th { background: #222; color: #fff; padding: 6px 10px; text-align: left; }
/* Joomla 6 puts each item title in a row-header cell (<th scope="row">):
   style it like a normal cell, not like the dark header bar */
table.table td, table.category td,
table.table tbody th, table.category tbody th {
  padding: 6px 10px;
  border-bottom: 1px solid #EDEDED;
  background: transparent;
  color: inherit;
  font-weight: normal;
  text-align: left;
}
table.table tbody th, table.category tbody th { border: 0; border-bottom: 1px solid #EDEDED; }
table tbody th[scope="row"] a { color: var(--v5-hl) !important; }
table.category tbody tr:nth-child(even) > * { background: #F7F7F7; }
table.category tbody tr:hover > * { background: #EEF3F9; }
table.category td.list-edit { width: 1%; white-space: nowrap; }

/* system messages */
#system-message-container:not(:empty) { margin-bottom: 10px; }
joomla-alert { display: block; margin-bottom: 12px; }

/* comments */
#v5_comments { margin-top: 30px; padding-top: 20px; border-top: 1px solid #EDEDED; }

/* math */
mjx-container[display="true"] { overflow-x: auto; overflow-y: hidden; }

/* -------------------------------------------------- tablet */
@media (max-width: 970px) {
  #s5_nav > li { padding: 7px 12px 0; }
  #s5_search input[type="search"], #s5_search input[type="text"] { width: 130px; }
}

/* -------------------------------------------------- phone */
@media (max-width: 750px) {
  .s5_wrap { width: 100%; }
  #s5_header_area_inner { padding-top: 8px; }
  #s5_header_area_inner2, #s5_component_wrap, #s5_footer_area_inner2, .module_round_box_outer { margin-left: 8px; margin-right: 8px; }

  #s5_header_wrap { flex-direction: column; align-items: center; min-height: 0; padding: 10px; }
  #s5_logo { max-width: 100%; max-height: 100px; }
  #s5_banner { padding: 6px 0 4px; text-align: center; }
  #s5_banner img { max-height: 60px; width: auto; }

  #s5_menu_wrap { flex-direction: column; }
  #v5_menu_toggle {
    display: block;
    width: 100%;
    padding: 12px 16px;
    border: 0;
    background: #151515;
    color: #fff;
    font: inherit;
    font-size: 1.3em;
    text-align: left;
    text-transform: uppercase;
    cursor: pointer;
  }
  #s5_menu_inner { display: none; }
  #s5_menu_wrap.v5-menu-open #s5_menu_inner { display: block; }
  #s5_nav { display: block; }
  #s5_nav > li { height: auto; padding: 0; border-right: 0; border-top: 1px solid #222; }
  #s5_nav > li > .s5_level1_span1 { height: auto; padding: 10px 52px 10px 16px; }
  #s5_nav > li > .s5_level1_span1 > .s5_level1_span2 { padding-top: 0; }
  #s5_nav > li.mainParentBtn > .s5_level1_span1 a { background: none !important; padding-right: 0; }
  #s5_nav li { position: relative; }
  #s5_nav ul.s5_sub_wrap, #s5_nav ul.s5_sub_wrap ul.s5_sub_wrap {
    display: none; visibility: visible; opacity: 1; transform: none; clip-path: none; pointer-events: auto;
    transition: none; width: auto; max-width: none;
    white-space: normal; padding: 0 0 3px; top: auto;
  }
  #s5_nav ul.s5_sub_wrap ul.s5_sub_wrap a,
  #s5_nav ul.s5_sub_wrap ul.s5_sub_wrap .s5_nolink { white-space: normal; }
  #s5_nav li:hover > ul.s5_sub_wrap, #s5_nav li:focus-within > ul.s5_sub_wrap { display: none; }
  #s5_nav li.v5-open > ul.s5_sub_wrap { display: block; }
  #s5_nav > li:hover, #s5_nav > li:focus-within, #s5_nav > li.v5-open { background: transparent; }
  #s5_nav > li:hover .S5_parent_subtext, #s5_nav > li.v5-open .S5_parent_subtext { color: #ccc; }
  #s5_nav ul.s5_sub_wrap,
  #s5_nav ul.s5_sub_wrap ul.s5_sub_wrap {
    position: static;
    min-width: 0;
    border: 0;
    box-shadow: none;
    border-left: 3px solid var(--v5-hl);
    margin: 0 0 0 16px;
  }
  #s5_nav ul.s5_sub_wrap li { min-width: 0; padding-right: 44px; }
  #s5_nav ul.s5_sub_wrap a, #s5_nav ul.s5_sub_wrap .s5_nolink { white-space: normal; }
  .v5-sub-toggle {
    display: block;
    position: absolute;
    right: 6px;
    top: 6px;
    width: 40px;
    height: 36px;
    border: 0;
    background: transparent url(../images/s5_menu_arrow.png) no-repeat center;
    cursor: pointer;
  }
  ul.s5_sub_wrap .v5-sub-toggle { top: 2px; background-image: url(../images/s5_menu_arrow_focus.png); }
  li.v5-open > .v5-sub-toggle { transform: rotate(180deg); }
  #s5_nav ul.s5_sub_wrap li.subParentBtn > .S5_submenu_item .s5_sub_a_span { background: none; padding-right: 0; }
  #s5_search { padding: 0 16px 12px; }
  #s5_search input[type="search"], #s5_search input[type="text"] { width: 100%; }

  #s5_breadcrumb_fonts_wrap { padding: 10px 12px; }
  #fontControls { display: none; }

  #s5_columns_wrap,
  .no-left #s5_columns_wrap,
  .no-right #s5_columns_wrap {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "center" "left" "right";
  }
  .v5-row { display: block; }
  #s5_component_wrap { padding: 16px; }
  #s5_footer_area_inner2 { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  #s5_nav ul.s5_sub_wrap { transition-duration: 0s !important; transition-delay: 0s !important; }
}

@media print {
  #s5_menu_wrap, #s5_breadcrumb_fonts_wrap, #s5_left_column_wrap, #s5_right_column_wrap,
  #s5_bottom_row1_area1, #s5_scrolltopvar, #v5_comments { display: none !important; }
  #s5_columns_wrap { display: block; }
  body { background: #fff; }
}

/* ==========================================================================
   Former K2 pages (Research, Blog, ACM Seminar, Conference) — same look as
   the K2 lists and items the site used before. Values measured on the live
   site (K2 2.11 + Vertex's K2 styles).
   ========================================================================== */

/* category box: picture left, blue title, description */
#s5_component_wrap .itemListCategory {
  margin: 0 0 20px;
  padding: 25px;
  background: #FAFAFA;
  border: 1px solid #F1F1F1;
  border-radius: 4px;
  font-size: 0.9em;
  overflow: hidden;
}
#s5_component_wrap .itemListCategory img { float: left; display: block; width: 100px; height: auto; margin: 0 8px 0 0; }
#s5_component_wrap .itemListCategory .itemListCategoryTitle {
  margin: 0 0 18px;
  padding: 0;
  color: var(--v5-hl);
  font-family: var(--v5-head-font);
  font-size: 1.4em;
  font-weight: normal;
  line-height: 18.2px;
  text-transform: none;
}
#s5_component_wrap .itemListCategory p { margin: 0; padding: 5px; }

/* banner with a picture: picture left, text block centred beside it,
   larger title, links shown as chips */
#s5_component_wrap .itemListCategory:has(> img) {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 22px;
  align-content: center;
  padding: 18px 22px;
  background: linear-gradient(135deg, #F7F9FC 0%, #FAFAFA 60%);
  border-color: #E8EDF3;
}
#s5_component_wrap .itemListCategory:has(> img) > * { grid-column: 2; }
#s5_component_wrap .itemListCategory:has(> img) > img {
  grid-column: 1;
  grid-row: 1 / span 6;
  align-self: center;
  float: none;
  width: 110px;
  margin: 0;
}
#s5_component_wrap .itemListCategory > .itemListCategoryTitle {
  align-self: end;
  margin: 0 0 6px;
  font-size: calc(var(--v5-font-size) * 2.1);   /* 27px, like "Courses Taught" */
  line-height: 1.15;
}
#s5_component_wrap .itemListCategory > p { padding: 2px 0; font-size: var(--v5-font-size); color: #555; }
#s5_component_wrap .itemListCategory > p a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 6px 4px 0 2px;
  padding: 5px 14px 5px 11px;
  border: 1px solid #DCE3EC;
  border-radius: 999px;
  background: #fff;
  line-height: 1.3;
  text-decoration: none;
  transition: background .15s, border-color .15s;
}
#s5_component_wrap .itemListCategory > p a:hover { border-color: var(--v5-hl); background: #EEF3F9; }
#s5_component_wrap .itemListCategory > p a::before {
  content: "\f0c1";                       /* link */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .95em;
  color: var(--v5-hl);
}
#s5_component_wrap .itemListCategory > p a[href*="cv" i]::before { content: "\f2c2"; }            /* id card */
#s5_component_wrap .itemListCategory > p a[href*="publication" i]::before { content: "\f02d"; }   /* book */
@media (max-width: 750px) {
  #s5_component_wrap .itemListCategory:has(> img) { grid-template-columns: minmax(0, 1fr); text-align: center; }
  #s5_component_wrap .itemListCategory:has(> img) > * { grid-column: 1; }
  #s5_component_wrap .itemListCategory:has(> img) > img { grid-row: auto; justify-self: center; margin-bottom: 8px; }
}

/* list entries */
.blog-items .blog-item,
.items-leading > .blog-item {
  margin: 0 0 50px;
  padding: 0 0 50px;
  border-bottom: 1px solid #F1F1F1;
}
.blog-items .blog-item:last-child { border-bottom: 0; }
.catItemView { padding: 4px 40px 4px 4px; }
.catItemDateCreated, .itemDateCreated {
  margin-right: 15px;
  color: #999;
  font-size: 0.9em;
}
/* list titles: same look as the title on the item page (blue Oswald, 22px) */
h3.catItemTitle {
  margin: 6px 0 8px;
  padding: 4px 0 0;
  color: var(--v5-hl);
  font-family: var(--v5-head-font);
  font-size: 1.6923em;                /* 22px at the 13px base */
  font-weight: normal;
  line-height: 1.15;
}
h3.catItemTitle a { color: var(--v5-hl); font: inherit; text-decoration: none; }
h3.catItemTitle a:hover { text-decoration: underline; }
.catItemIntroText { padding: 4px 0 4px; }
.catItemLinks { margin: 0 0 6px; padding: 0 0 4px; }
a.k2ReadMore {
  display: inline-block;
  margin-top: 8px;
  padding: 12px 22px;
  background: #000;
  color: #fff;
  font-size: 0.9em;
  font-weight: bold;
  line-height: 100%;
  text-decoration: none;
}
a.k2ReadMore:hover { background: #3C3C3C; color: #fff; text-decoration: none; }

/* single item */
.itemHeader { margin-bottom: 0; }
#s5_component_wrap h1.itemTitle {
  margin: 0 0 13px;
  padding: 10px 0 4px;
  color: var(--v5-hl);
  font-family: var(--v5-head-font);   /* same font as the Teaching page titles */
  font-size: 1.6923em;                /* 22px at the 13px base */
  font-weight: normal;
  line-height: 1.15;
  text-transform: none;
}

/* ---- research paper page (K2-style item): authors / abstract / funding / preview */
.v5-k2item .v5-sec {
  padding: 16px 0;
  border-top: 1px solid #E6E6E6;
}
.v5-k2item .v5-sec:first-child { padding-top: 2px; border-top: 0; }
.v5-k2item .v5-sec > p:first-child { margin-top: 0; }
.v5-k2item .v5-sec > p:last-child { margin-bottom: 0; }

/* authors */
.v5-k2item .v5-sec--authors p { padding: 0; font-size: 1.15em; color: #555; }
/* published papers: journal line below the authors, with a little room */
.v5-k2item .v5-sec--authors p + p { margin-top: 8px; font-size: 1.05em; }

/* abstract: light panel with a blue edge */
.v5-k2item .v5-sec--abstract {
  margin: 4px 0 6px;
  padding: 14px 20px 14px 18px;
  border-top: 0;
  border-left: 3px solid var(--v5-hl);
  border-radius: 0 4px 4px 0;
  background: #F6F8FB;
}
.v5-k2item .v5-sec--abstract + .v5-sec { border-top: 0; }
.v5-k2item .v5-sec--abstract p { padding: 0; margin: 0 0 9px; line-height: 1.6; }
.v5-k2item .v5-sec--abstract p:has(> :is(strong, b):only-child) {
  margin-bottom: 6px;
  color: var(--v5-hl);
  font-family: var(--v5-head-font);
  font-size: 1.25em;
  line-height: 1.2;
}
.v5-k2item .v5-sec--abstract p > :is(strong, b):only-child { font-weight: normal; }

/* funding / links: icon + text rows */
.v5-k2item .v5-sec--links table { width: auto; border-collapse: collapse; }
.v5-k2item .v5-sec--links tr { height: auto !important; }
.v5-k2item .v5-sec--links td { padding: 5px 10px 5px 0; vertical-align: middle; border: 0; }
.v5-k2item .v5-sec--links td:first-child { width: 40px !important; }
.v5-k2item .v5-sec--links td img { display: block; max-width: 32px; height: auto; }

/* DOI / published version / award page: side by side, as rounded chips */
.v5-reflinks { display: flex; flex-wrap: wrap; gap: 10px 12px; margin: 0 0 14px; }
.v5-reflink {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px 5px 7px;
  border: 1px solid #DCE3EC;
  border-radius: 999px;
  background: #F8FAFC;
  line-height: 1.3;
  transition: background .15s, border-color .15s;
}
.v5-reflink:hover { border-color: var(--v5-hl); background: #EEF3F9; }
.v5-reflink img { display: block; width: auto; height: 24px; margin: 0 !important; }
.v5-reflink a { text-decoration: none; }
/* funding: its own soft panel, one grant per row */
.v5-funding {
  display: grid;
  gap: 8px;
  padding: 10px 16px;
  border: 1px solid #ECECEC;
  border-radius: 4px;
  background: #FAFAFA;
  color: #555;
}
.v5-funding-row { display: flex; align-items: center; gap: 12px; line-height: 1.4; }
.v5-funding-row img { flex: 0 0 auto; display: block; width: auto; height: 28px; margin: 0 !important; }
.v5-reflinks + .v5-funding { margin-top: 4px; }

/* in the Research list, each entry's last block needs no extra space below */
.catItemIntroText.v5-k2item .v5-sec:last-child { padding-bottom: 6px; }

/* preview: caption line, framed PDF viewer, "open" link */
.v5-k2item .v5-sec--preview > p { padding: 0; margin: 0 0 10px; color: #666; }
/* the viewer itself (.v5-pdf) is styled by the "Content - PDF Preview" plugin */
@media (max-width: 750px) {
  .v5-k2item .v5-sec--abstract { padding: 12px 14px; }
}

/* ---- blog lists in two (or more) columns: each entry is a light card */
.blog-items[class*="columns-"], .blog-items[class*="masonry-"] {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;   /* cards in a row share the same height */
}
.blog-items.columns-3, .blog-items.masonry-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.blog-items[class*="columns-"] > .blog-item,
.blog-items[class*="masonry-"] > .blog-item {
  margin: 0;
  padding: 12px 16px 14px;
  border: 1px solid #E4E4E4;
  border-radius: 5px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .05);
}
.blog-items[class*="columns-"] > .blog-item:hover { border-color: #CFDCEB; }
.blog-items[class*="columns-"] .catItemView { padding: 0; }
.blog-items[class*="columns-"] h3.catItemTitle { margin: 4px 0 6px; padding: 0; font-size: 1.45em; }
.blog-items[class*="columns-"] .catItemIntroText { padding: 0; }
.blog-items[class*="columns-"] .v5-k2item .v5-sec { padding: 10px 0; }
.blog-items[class*="columns-"] .v5-k2item .v5-sec:first-child { padding-top: 0; }
.blog-items[class*="columns-"] .v5-k2item .v5-sec--abstract { margin: 2px 0 4px; padding: 10px 14px 10px 12px; }
.blog-items[class*="columns-"] .v5-k2item .v5-sec--abstract p { line-height: 1.5; }
.blog-items[class*="columns-"] .v5-funding { padding: 8px 12px; }
.blog-items[class*="columns-"] .catItemLinks { margin: 0; padding: 0; }
@media (max-width: 750px) {
  .blog-items[class*="columns-"], .blog-items[class*="masonry-"] { grid-template-columns: minmax(0, 1fr); }
}


/* banner without a picture (e.g. Events): compact, same title, light gradient */
#s5_component_wrap .itemListCategory:not(:has(> img)) {
  padding: 16px 22px;
  background: linear-gradient(135deg, #F7F9FC 0%, #FAFAFA 60%);
  border-color: #E8EDF3;
}
#s5_component_wrap .itemListCategory--events > .itemListCategoryTitle::before {
  content: "\f073";                       /* calendar */
  margin-right: 10px;
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .8em;
  vertical-align: 2px;
}
/* sub-categories as chips (Events -> ACM Seminar, Conference) */
#s5_component_wrap .itemListCategory > p.v5-subcats { padding: 0; }
#s5_component_wrap .itemListCategory > p.v5-subcats a::before { content: "\f07c"; }            /* folder */
#s5_component_wrap .itemListCategory > p.v5-subcats a[href*="seminar" i]::before { content: "\f51c"; }   /* chalkboard teacher */
#s5_component_wrap .itemListCategory > p.v5-subcats a[href*="conference" i]::before { content: "\f0c0"; } /* users */

/* ---- seminar talks in a list: speaker, abstract panel, time / location / host */
.v5-speaker { margin: 2px 0 8px; color: #444; font-size: 1.05em; font-weight: normal; line-height: 1.4; }
.v5-talkabstract {
  margin: 0 0 10px;
  padding: 10px 14px 10px 12px;
  border-left: 3px solid var(--v5-hl);
  border-radius: 0 4px 4px 0;
  background: #F6F8FB;
  line-height: 1.5;
}
.v5-talkabstract p { margin: 0 0 6px; padding: 0; }
.v5-talkabstract p:last-child { margin-bottom: 0; }
.v5-talkabstract br:last-child { display: none; }
.v5-talkinfo {
  display: grid;
  gap: 4px;
  padding: 8px 12px;
  border: 1px solid #ECECEC;
  border-radius: 4px;
  background: #FAFAFA;
  color: #555;
}
.v5-info { display: flex; align-items: baseline; gap: 8px; line-height: 1.4; }
.v5-info::before {
  flex: 0 0 1.1em;
  text-align: center;
  color: var(--v5-hl);
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .95em;
  content: "\f105";                       /* angle right */
}
.v5-info--time::before { content: "\f017"; }      /* clock */
.v5-info--location::before { content: "\f3c5"; }  /* map pin */
.v5-info--host::before { content: "\f007"; }      /* user */

/* Events list: long conference pages (speaker / participant lists, schedules)
   are shown as a preview that fades out; the title opens the full page */
.blog:has(.itemListCategory--events) .catItemIntroText:not(:has(.v5-talkinfo)) {
  max-height: 340px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
}
.blog:has(.itemListCategory--events) .catItemIntroText img { max-width: 100%; height: auto; }

/* numbered lists in articles: room for two- and three-digit numbers */
.com-content-article__body ol, .catItemIntroText ol { padding-left: 2.6em; margin-left: 0; }
.com-content-article__body ol li, .catItemIntroText ol li { margin-left: 0; padding-left: 2px; }

/* home page: the article title ("About me") as a module-style header bar */
#s5_component_wrap h1.s5_mod_h3.v5-component-h3 {
  margin: -20px -20px 14px;
  padding: 12px 13px 11px;
  border-bottom: 1px solid var(--v5-border);
  border-radius: 6px 6px 0 0;
  background: linear-gradient(to bottom, #fff 0%, #F9F9F9 100%);
  color: #333;
  font-family: var(--v5-head-font);
  font-size: 1em;
  font-weight: normal;
  line-height: 1.2;
  text-transform: uppercase;
}
@media (max-width: 750px) {
  #s5_component_wrap h1.s5_mod_h3.v5-component-h3 { margin: -16px -16px 12px; }
}

/* chips inside article text: add class="v5-chip" to a link
   (optional icon: v5-chip--cv / --statement / --publications / --pdf) */
a.v5-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 2px 1px;
  padding: 2px 11px 2px 9px;
  border: 1px solid #DCE3EC;
  border-radius: 999px;
  background: #F8FAFC;
  line-height: 1.45;
  text-decoration: none;
  vertical-align: baseline;
  white-space: nowrap;
  transition: background .15s, border-color .15s;
}
a.v5-chip:hover, a.v5-chip:focus { border-color: var(--v5-hl); background: #EEF3F9; text-decoration: none; }
a.v5-chip::before {
  content: "\f0c1";                       /* link */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .9em;
  color: var(--v5-hl);
}
a.v5-chip--cv::before { content: "\f2c2"; }            /* id card */
a.v5-chip--statement::before { content: "\f15c"; }     /* document */
a.v5-chip--publications::before { content: "\f02d"; }  /* book */
a.v5-chip--pdf::before { content: "\f1c1"; }           /* pdf */

/* ---- contact box: icon + label + details per row */
.module_round_box ul.v5-contact { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.module_round_box ul.v5-contact > li.v5-contact__item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  column-gap: 9px;
  row-gap: 2px;
  margin: 0;
  padding: 11px 0;
  border-bottom: 1px dashed #E3E3E3;
  background: none;
  list-style: none;
}
.module_round_box ul.v5-contact > li.v5-contact__item:first-child { padding-top: 2px; }
.module_round_box ul.v5-contact > li.v5-contact__item:last-child { padding-bottom: 2px; border-bottom: 0; }
.v5-contact__item::before {
  grid-row: 1 / span 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #EEF3F9;
  color: var(--v5-hl);
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 11px;
}
.v5-contact--mail::before { content: "\f5a0"; }       /* map location */
.v5-contact--office::before { content: "\f1ad"; }     /* building */
.v5-contact--email::before { content: "\f0e0"; }      /* envelope */
.v5-contact--guestbook::before { content: "\f4ad"; }  /* comment dots */
.v5-contact__label {
  grid-column: 2;
  align-self: end;
  color: #333;
  font-family: var(--v5-head-font);
  font-size: 1.05em;
  line-height: 1.2;
}
.v5-contact__value { grid-column: 2; color: #555; font-size: .9em; line-height: 1.45; overflow-wrap: break-word; }
.v5-contact__value a.v5-chip { margin: 3px 0 0; }
a.v5-chip--message::before { content: "\f303"; }      /* pen */

/* ---- research profiles (Google Scholar, MathSciNet, arXiv): clickable rows */
.module_round_box ul.v5-profiles { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.module_round_box ul.v5-profiles > li { margin: 0; padding: 0; border: 0; background: none; list-style: none; }
a.v5-profile {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 6px 7px;
  border: 1px solid #E3E8EF;
  border-radius: 6px;
  background: #F8FAFC;
  color: #333;
  line-height: 1.3;
  text-decoration: none;
  transition: background .15s, border-color .15s;
}
a.v5-profile:hover, a.v5-profile:focus { border-color: var(--v5-hl); background: #EEF3F9; color: var(--v5-hl); text-decoration: none; }
a.v5-profile img { flex: 0 0 auto; display: block; width: 26px; height: 26px; object-fit: contain; margin: 0 !important; border-radius: 4px; background: #fff; }
a.v5-profile span { flex: 1 1 auto; }
a.v5-profile::after {
  content: "\f35d";                       /* up-right arrow: opens a new tab */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .8em;
  color: #9AA8B8;
}
a.v5-profile:hover::after { color: var(--v5-hl); }

/* news lists (Articles - Category module): date in small grey on the right */
.module_round_box ul.mod-articlescategory > li:has(.mod-articles-category-date),
.module_round_box ul.category-module > li:has(.mod-articles-category-date) {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 12px;
}
.module_round_box li:has(.mod-articles-category-date) > a { flex: 1 1 260px; }
.mod-articles-category-date {
  flex: 0 0 auto;
  margin-left: auto;
  color: #999;
  font-size: .88em;
  white-space: nowrap;
}

/* Useful Weblinks in the bottom row: links in columns */
#s5_bottom_row1_area1 .module_round_box ul.weblinks {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 2px 18px;
}
#s5_bottom_row1_area1 .module_round_box ul.weblinks > li {
  display: flex;
  align-items: baseline;
  gap: 7px;
  padding: 4px 0;
  border-bottom: 1px dotted #E3E3E3;
}
#s5_bottom_row1_area1 .module_round_box ul.weblinks > li::before {
  content: "\f35d";                       /* external link */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .75em;
  color: #9AA8B8;
}

/* tables placed right before the next section heading (CV): the heading's
   own top margin spaces the sections evenly, ignore the tables' inline gaps */
.com-content-article__body > table:has(+ :is(h2, h3, h4)) { margin-bottom: 0 !important; }

/* ---- CV: timeline (education, positions), grants list, links, students */
.v5-cv-timeline { margin: 0; }
.v5-cv-item {
  display: grid;
  grid-template-columns: 108px 34px minmax(0, 1fr);
  column-gap: 14px;
  align-items: start;
  padding: 11px 0;
  border-bottom: 1px dashed #E3E3E3;
}
.v5-cv-item:first-child { padding-top: 2px; }
.v5-cv-item:last-child { border-bottom: 0; }
.v5-cv-when {
  color: var(--v5-hl);
  font-family: var(--v5-head-font);
  font-size: 1.08em;
  line-height: 1.35;
  white-space: nowrap;
}
.v5-cv-item .v5-cv-logo { display: block; justify-self: center; align-self: center; width: auto; height: auto; max-width: 32px; max-height: 32px; margin: 0 !important; }   /* centred on the three lines */
.v5-cv-what { color: #666; line-height: 1.5; }
.v5-cv-what strong { color: #333; }

.com-content-article__body ul.v5-cv-list { margin: 0; padding: 0; list-style: none; }
.com-content-article__body ul.v5-cv-list > li {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr) 28px;
  column-gap: 14px;
  align-items: start;
  margin: 0;
  padding: 7px 0;
  border-bottom: 1px dashed #E3E3E3;
  background: none;
  line-height: 1.5;
}
.com-content-article__body ul.v5-cv-list > li:last-child { border-bottom: 0; }
.v5-cv-list .v5-cv-logo { display: block; width: auto; height: auto; max-width: 24px; max-height: 24px; margin: 0 !important; justify-self: end; }

.com-content-article__body p.v5-cv-more { margin: 2px 0 0; padding: 0; color: #666; }
.com-content-article__body p.v5-cv-more--right { margin-top: 10px; text-align: right; }
.v5-cv-more a.v5-chip[href*="publication"]::before { content: "\f02d"; }   /* book */
.v5-cv-more a.v5-chip[href*="conference"]::before { content: "\f0c0"; }    /* users */
.v5-cv-more a.v5-chip[href*="teaching"]::before { content: "\f51c"; }      /* chalkboard */
.v5-cv-more a.v5-chip[href*="award"]::before { content: "\f091"; }         /* trophy */

.com-content-article__body ul.v5-cv-people { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.com-content-article__body ul.v5-cv-people > li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin: 0;
  padding: 0;
  background: none;
}
.v5-cv-people .v5-cv-name::before {
  content: "\f007";                       /* user */
  margin-right: 8px;
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .9em;
  color: var(--v5-hl);
}
.v5-cv-badge {
  display: inline-block;
  padding: 1px 9px;
  border: 1px solid #E3E3E3;
  border-radius: 999px;
  background: #F6F6F6;
  color: #666;
  font-size: .88em;
  line-height: 1.5;
}
.v5-cv-badge--current { border-color: #CDE5C6; background: #EEF7EB; color: #3E7D32; }

@media (max-width: 750px) {
  .v5-cv-item { grid-template-columns: 34px minmax(0, 1fr); row-gap: 2px; }
  .v5-cv-item .v5-cv-when { grid-column: 1 / -1; }
  .com-content-article__body ul.v5-cv-list > li { grid-template-columns: minmax(0, 1fr) 28px; }
  .v5-cv-list .v5-cv-when { grid-column: 1 / -1; }
}

/* one award per row (Honors and Awards): the year only on the first row of
   each year; rows of the same year sit closer, without a separator */
.v5-cv-timeline--entries .v5-cv-item { align-items: center; padding: 8px 0; }
.v5-cv-timeline--entries .v5-cv-item:has(+ .v5-cv-item--same) { border-bottom: 0; padding-bottom: 3px; }
.v5-cv-timeline--entries .v5-cv-item--same { padding-top: 3px; }
.v5-cv-timeline--entries .v5-cv-item .v5-cv-logo { max-width: 34px; max-height: 26px; }
.v5-cv-timeline--entries span.v5-cv-logo { width: 26px; height: 26px; }

/* Honors and Awards: year | groups of entries that share one logo.
   Dashed lines: between years (full width), between logo groups of the same
   year (logo + text), and between entries of a group (text only). */
.v5-cv-awards { margin: 0; }
.v5-cv-year {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);   /* single years only need a narrow column */
  column-gap: 14px;
  border-bottom: 1px dashed #E3E3E3;
}
.v5-cv-year:last-child { border-bottom: 0; }
.v5-cv-year > .v5-cv-when { padding-top: 8px; }
.v5-cv-group {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  column-gap: 14px;
  align-items: center;
}
.v5-cv-group + .v5-cv-group { border-top: 1px dashed #E3E3E3; }
.v5-cv-group .v5-cv-logo { display: block; justify-self: center; width: auto; height: auto; max-width: 34px; max-height: 26px; margin: 0 !important; }
.v5-cv-line { padding: 8px 0; color: #555; line-height: 1.4; }
.v5-cv-line + .v5-cv-line { border-top: 1px dashed #E3E3E3; }
@media (max-width: 750px) {
  .v5-cv-year { grid-template-columns: minmax(0, 1fr); }
  .v5-cv-year > .v5-cv-when { padding-top: 10px; }
}

/* keep short phrases such as "(2023–2028)" on one line */
.v5-nowrap { white-space: nowrap; }

/* ---- Conferences, workshops and seminars: date | event name, talk line(s) */
.v5-events { margin: 0; }
.v5-event {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  column-gap: 14px;
  padding: 9px 0;
  border-bottom: 1px dashed #E3E3E3;
}
.v5-event:first-child { padding-top: 2px; }
.v5-event:last-child { border-bottom: 0; }
.v5-event-date { color: var(--v5-hl); font-family: var(--v5-head-font); font-size: 1.02em; line-height: 1.4; white-space: nowrap; }
.v5-event-name { color: #333; line-height: 1.45; }
.v5-event-name a { color: #333; text-decoration: none; }
.v5-event-name a:hover { color: var(--v5-hl); text-decoration: underline; }
.v5-event-talk {
  position: relative;
  margin-top: 3px;
  padding-left: 18px;
  color: #666;
  line-height: 1.45;
}
.v5-event-talk::before {
  content: "\f130";                       /* microphone */
  position: absolute;
  left: 1px;
  top: 1px;
  color: var(--v5-hl);
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .85em;
}
@media (max-width: 750px) {
  .v5-event { grid-template-columns: minmax(0, 1fr); row-gap: 2px; }
}

/* role badges in event lists: Organizer (gold) / Co-organizer (blue) */
.v5-role {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: 6px;
  padding: 0 9px 0 7px;
  border: 1px solid #E8C873;
  border-radius: 999px;
  background: #FBF3DC;
  color: #8A6212;
  font-size: .85em;
  font-weight: bold;
  line-height: 1.6;
  vertical-align: 1px;
  white-space: nowrap;
}
.v5-role::before {
  content: "\f005";                       /* star */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .85em;
  color: #E0AE2E;
}
.v5-role--co { border-color: #C9D9EC; background: #EEF3F9; color: #3F6E9F; }
.v5-role--co::before { content: "\f0c0"; color: var(--v5-hl); }   /* users */

/* ---- List of publications: [n] | authors / title / journal or status */
.v5-pubs { margin: 0; }
.v5-pub {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  column-gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed #E3E3E3;
}
.v5-pub:first-child { padding-top: 2px; }
.v5-pub:last-child { border-bottom: 0; }
.v5-pub-num { color: var(--v5-hl); font-family: var(--v5-head-font); font-size: 1.02em; line-height: 1.45; white-space: nowrap; }
.v5-pub-authors { color: #666; line-height: 1.45; }
.v5-me { color: inherit; font-weight: inherit; }   /* own name: no highlight */
.v5-pub-title { margin: 1px 0; line-height: 1.45; }
.v5-pub-title a { color: #333; font-weight: bold; text-decoration: none; }
.v5-pub-title a:hover { color: var(--v5-hl); text-decoration: underline; }
.v5-pub-venue { color: #666; font-style: italic; line-height: 1.45; }
.v5-pub-venue strong { font-style: normal; color: #555; }
.v5-pub-status {
  display: inline-block;
  margin-top: 2px;
  padding: 0 9px;
  border: 1px solid #E3E3E3;
  border-radius: 999px;
  background: #F6F6F6;
  color: #666;
  font-size: .88em;
  font-style: normal;
  line-height: 1.6;
}
.v5-pub-status--submitted { border-color: #C9D9EC; background: #EEF3F9; color: #3F6E9F; }
.v5-pub-status--accepted { border-color: #CDE5C6; background: #EEF7EB; color: #3E7D32; }
.v5-pub-status--accepted::before {
  content: "\f00c";                       /* check */
  margin-right: 5px;
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: .85em;
}
