/**

Exemplary TDLEG projects at CUHK

Copyright 2019 CUHK CLEAR

Jimmy Chu - jimmychu@link.cuhk.edu.hk

Last updated 20/06/2019

**/
@import url("https://webarchive.lib.cuhk.edu.hk/20220831100820cs_/https://fonts.googleapis.com/css?family=Concert+One|Roboto:300&display=swap");
@import url("https://webarchive.lib.cuhk.edu.hk/20220831100820cs_/https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css");


.dropdown-submenu {
  position: relative;
}

/* rotate caret on hover */
.dropdown-menu>li>a:hover:after {
  text-decoration: underline;
}


.nav-item {
  font-size: 115%;
}

:root {
  --content-width: 50rem;
  --sharp-color: #903F91;
}

* {
  margin: 0;
  min-height: 0.01px;
}

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

::-webkit-scrollbar {
  -webkit-appearance: none;
  width: 0.5rem;
}

::-webkit-scrollbar-thumb {
  border-radius: 0.25rem;
  background-color: var(--sharp-color);
  -webkit-box-shadow: 0 0 1px rgba(255, 255, 255, 0.5);
}

html,
body {
  margin: 0;
  padding: 0;
  min-width: 320px;
  width: 100%
}

a {
  color: inherit;
  text-decoration: none;
}

ul,
li {
  list-style: none;
}

body {
  font-size: 14px;
  /* font-family:  BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; */
  color: #262628;
  height: 100%;
}

h1 {
  /* font-family: 'Futura', "Helvetica Neue", "Segoe UI"; */
}

.cuhkclear {
  line-height: 3em;
  padding: 0 4rem;
}

.cuhkclear .cuhk {
  font-weight: 800;
  padding-right: 0.1rem;
  color: var(--sharp-color);
  text-decoration: none;
}

.clear,
.clear:hover {
  color: #000;
  text-decoration: none;
}

.main {
  background: #f9f9f9;
  margin: 1rem;
  margin-top: 0;
  padding: 1rem;
  padding-left: 3rem;
  height: 100%;
  display: grid;
  grid-gap: 0;
  grid-template-columns: 350px auto;
  border-radius: 1rem;
}

.main aside {
  padding: 1em 0;
  border-right: #FFF solid 2px;
}

.main .header h1 {
  font-size: 2.5rem;
  font-weight: 400;
  width: 100px;
  color: #000;
  text-transform: uppercase;
}

.main .header h1 .cuhk {
  color: var(--sharp-color);
}

.main .menu {
  margin-top: 3em;
  font-size: 1.2em;
  line-height: 1.6em;
}

.main .menu li {
  position: relative;
}

.main .menu li:hover .drop {
  display: block;
}

.main .menu .drop {
  background: #fff;
  margin-top: -2rem;
  margin-left: 8rem;
  display: none;
  position: absolute;
  min-width: 160px;
  padding: 12px 16px;
  z-index: 1;
}

.main .menu .mobile {
  display: none;
}

.main .menu .selected {
  color: var(--sharp-color);
  font-weight: 600;
}


.header figure {
  text-align: left;
}

.header figure img {
  max-height: 5rem;
  margin-left: 2rem;
}

.header figure img:last-child {
  max-height: 5rem;
  margin-left: 2rem;
}

.header figure a {
  display: contents;
  width: inherit;
  max-height: 5rem;
  margin-left: 2rem;
}

.header figure a:last-child {
  display: contents;
  width: inherit;
  max-height: 5rem;
  margin-left: 2rem;
}


.main .logo {
  margin-bottom: 2rem;
  width: 100%;
}

.main .logo img {
  height: 4rem;
  margin-right: 1rem;
}


.footer {
  position: static;
  padding-left: 3.8rem;
  line-height: 3rem;
  font-size: 0.75rem;
}

.footer a {
  margin-right: 1rem;
}

.footer a::after {
  margin-left: 1rem;
  content: "-";
}

.content {
  margin: 2rem;
  margin-bottom: 0;
}

.cover {
  width: 100%;
  padding-bottom: 60%;
  position: relative;
  display: inline-block;
  overflow: hidden;
  margin: 0;
  border-radius: 0.25rem
}

.content.homepage .item-list li div>img {
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100px;
  transform: translate(-0%, -0%)
}

.content.homepage .item-list li div>img:hover {
  opacity: 0.8;
  background: #000;
  transition: all .3s
}

.content.homepage {
  padding: 0 3rem;
}

.content.homepage .item-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 2rem;
}

.content.homepage .item-list li {
  overflow: hidden;
  width: 100%;
  margin-bottom: 2rem;
}

.content.homepage .item-list li h3 {
  font-size: 1rem;
  margin-bottom: 1rem;
}

.content.homepage .item-list li a {
  font-size: 0.75rem;
  padding: 0.7rem;
  line-height: 3rem;
  border: 2px solid #000;
  border-radius: 0.5rem;
  font-weight: 600;
}

.content.homepage .item-list li figure {
  position: relative;
  padding-bottom: 0%;
  border-radius: 0.5rem;
  overflow: hidden;
  margin-bottom: 1rem;
}

.content.homepage .item-list li figcaption {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  color: #fff;
  background: rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: flex-end;
  line-height: 1em;
  padding: 1rem;
  font-size: 0.75rem;
}

.content.homepage .item-list li figcaption span {
  background: #333;
  padding: 0.25rem;
  border-radius: 0.25rem;
  font-weight: 600;
  width: 100%;
}

.content.homepage .item-list li figcaption span::after {
  content: "read more";
  float: right;
}

.content.homepage .item-list li div>img {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: inherit;
}

.content.videopage {
  margin: 2rem;
  padding: 0 4rem;
}

.content.videopage h1 {
  font-weight: 400;
  font-size: 1.6rem;
  margin-bottom: 20px;
}

.content.videopage p {
  line-height: 1.2rem;
  margin-bottom: 0.8rem;
}

.content.videopage iframe {
  width: 38vw;
  height: 20vw;
  margin-bottom: 3rem;
  border-radius: 1rem;
}

.content.videopage figure {
  text-align: justify;
}

@media only screen and (max-width: 1600px) {

  .content.videopage {
    margin: 1rem;
  }

  .content.homepage .item-list {
    grid-template-columns: auto auto;
  }

  .content.homepage .item-list h3 {
    height: 5rem;
  }

  .content.homepage .item-list img {
    height: auto;
  }
}

@media only screen and (max-width: 1300px) {

  .content.videopage {
    margin: 1rem;
  }

  .content.homepage .item-list {
    grid-template-columns: auto;
  }

  .content.homepage .item-list img {
    height: auto;
  }
}

@media print,
screen and (max-width: 1100px) {

  html,
  body {
    width: 100%;
    min-width: 240px;
  }

  .footer {
    position: static;
    padding: 0 4rem 4rem 4rem;
    line-height: inherit;
    font-size: 0.75rem;
  }

  .footer a {
    margin-right: 1rem;
    line-height: 2rem;
  }

  .footer a::after {
    margin-left: 1rem;
    content: "";
  }

  .footer span {
    line-height: 1.5rem;
    margin-bottom: 1rem;
    display: block
  }

  .main {
    grid-template-columns: auto;
    display: block;
    padding: 2rem;
    height: 100%;
    overflow: visible;
  }

  .main aside {
    padding: 0;
    /* display: grid; */
    grid-template-columns: auto auto;
    margin-bottom: 3rem;
    border: 0px;
  }

  .main .header h1 {
    font-size: 2rem;
  }

  .main .menu {
    margin: 0;
    text-align: right;
  }

  .main .menu .mobile {
    display: block;
    font-size: 2rem;
    margin-top: 0.25rem;
  }

  .mobile {
    min-width: 40px;
    min-height: 40px;
  }

  i {
    width: 24px !important;
    height: 24px !important;
  }

  .main .menu #nav {
    display: none;
    background: #FFF;
    padding: 2rem;
    position: absolute;
    text-align: left;
    border-radius: 1rem;
    top: 8rem;
    right: 2.5rem;
    transition: 0;
  }

  .main .menu .drop {
    background: #fcfcfc;
    margin-top: 0;
    margin-left: 0;
    display: none;
    position: absolute;
    min-width: 160px;
    padding: 12px 16px;
    z-index: 1;
  }

  .content {
    width: 100%;
    min-width: 240px;
  }

  .content.homepage {
    padding: 0;
    margin: 0;
  }

  .content.homepage .item-list {
    grid-template-columns: auto;
  }

  .content.homepage .item-list li:last-child {
    margin-bottom: 0;
  }

  .content.videopage {
    margin: 0;
    padding: 0;
  }

  .content.videopage h1 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
  }

  .content.videopage p {
    line-height: 1.4rem;
    margin-bottom: 1rem;
  }

  p>b {
    font-size: 1.1em;
  }

  .content.videopage p:last-child {
    margin-bottom: 0;
  }

  .content.videopage iframe {
    width: 85vw;
    margin-bottom: 3rem;
    border-radius: 1rem;
    height: 52vw;
  }

  .content.videopage figure {
    text-align: center;
    z-index: 999;
  }
}

.nav-padding {
  padding: 0 !important;
  padding-top: 10px !important;
  margin: 0 !important;
}

.link-padding {
  padding: 0 !important;
  margin: 0 !important;
}

.active>a {
  color: var(--sharp-color) !important;
  font-weight: bold;
}

.numbering {
  display: list-item;
  line-height: 2rem;
  list-style: decimal;
}

.dropdown-item.active,
.dropdown-item:active {
  background-color: var(--sharp-color);
  border-color: #fff;
}

.dropdown-item {
  font-size: 14px;
}

.btn {
  font-size: 14px;
}

.dropdown-toggle-split {
  cursor: pointer;
}

.dropdown-menu {
  width: inherit !important;
  height: inherit !important;
}

.collapsing {
  -webkit-transition: none;
  transition: none;
  display: none;
}

.link-strip,
.link-strip:hover {
  color: #000;
  text-decoration: none;
}

.link-custom:hover {
  color: #000;
  text-decoration: none;
}