/* CSS Reset: http://meyerweb.com/eric/tools/css/reset */

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
  display: block;
}
hr {
  border-top: 1px solid #e1dddd;
}
sup {
  vertical-align: super !important;
  font-size: 0.8em;      /* make it a bit smaller */
  line-height: normal;   /* prevent weird line‐height inheritance */
}
ul {
  list-style-type: disc;
  list-style-position: outside;
  margin-left: 1.5em;
}
ol {
  list-style-type: decimal;
  list-style-position: outside;
  margin-left: 1.5em;
}
blockquote, q {
  quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
  content: '';
  content: none;
}
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/**************************************************/

#body{
  font-family: "Times New Roman";
  font-size: 1em;
  line-height: 1.5em;
  color: #150c21;
}

#main {
  width: 54em;
  margin: 0px auto;
  position: relative;
  min-height: 100vh;
}

a {
  text-decoration: none;
  color: rgb(20, 110, 190);
}

a:hover {
  text-decoration: none;
  border-bottom: 1px solid rgb(20, 110, 190);
}

i {
  font-style: italic;
}

b {
  font-weight: 700;
}

h1 {
  font-size: 2.4em;
  line-height: 3em;
  font-weight: 500;
}

/**************************************************/
/* Profile image and description. */

#intro {
  padding-top: 6em;
  display: flex;
}

#intro-text {
  width: 44em;
  float: left;
}

#intro-image {
  margin: 2em 0 0 2em;
  width: 12em;
  height: 20em;
  float: left;
  overflow: hidden;
  border-radius: 1em;
}

#intro-image img {
  width: 12em;
}

#busuanzi_container_site_uv {
  color: #a0a8b0;
}

/**************************************************/
/* Section buttons. */

#menu {
  display: flex;
}

.menu-item {
  float: left;
  margin-right: 2em;
}

h2 {
  font-size: 1.6em;
  line-height: 2.4em;
  margin-top: 0.5em;
  /* color: #a0a8b0; */
}

.selected h2 {
  color: #150c21;
}

.button {
  display: inline-block;
  cursor: pointer;
  border: none;
  background: none;
  color: #a0a8b0;
  font-size: 1.4em;
  line-height: 2.4em;
  margin-top: 0.5em;
  margin-right: 0.7em;
  float: left;
  padding: 0;
}

.button:hover {
  color: #150c21;
}

.button:active,
.button.is-checked {
  color: #150c21;
}

.button-group:after {
  content: '';
  display: block;
  clear: both;
}

/**************************************************/
/* Isotope grid list of items. */

.grid {
  padding-bottom: 6em;
}

/* clear fix */
.grid:after {
  content: '';
  display: block;
  clear: both;
}

.description {
  margin-bottom: 1em;
}

.list-item {
  width: 100%;
  line-height: 1em;
  margin-top: 1em;
}

.list-item p.date {
  display: inline-block;
  width: 3em;
  color: #a0a8b0;
}

/**************************************************/
/* Gallery of 3 preview videos. */

.previews {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  grid-auto-rows: minmax(100px, auto);
  height: 12.5em;
}

.previews video {
  border-radius: 5px;
}

.previews a:hover {
  border: none;
}

.preview1 {
  grid-column: 1;
  width: 100%;
}
.preview2 {
  grid-column: 2;
  width: 100%;
}
.preview3 {
  grid-column: 3;
  width: 100%;
}

/**************************************************/
/* Buttons for showing more or less highlights. */

.toggle-button {
  margin-top: 2em;
}

.toggle-button a {
  color: #a0a8b0;
}

.toggle-button a:hover {
  color: rgb(20, 110, 190);
}

/**************************************************/
/* Publication details (thumbnail media, title, and description). */

.thumbnail {
 width: 26%;
  /* width: 18%; */
  float: left;
  margin-right: 2%;
}
/* adjust the thumbnail in pub only */
.list-item.publication .thumbnail {
  width: 34%;
  margin-right: 2%;
}

.list-item.service .thumbnail {
  width: 36%;
  margin-right: 2%;
}

.list-item.edu .thumbnail {
  width: 30%;
  margin-right: 2%;
}

.thumbnail:hover {
  border-bottom: none;
}

.thumbnail img {
  margin-top: 0.4em;
  border-radius: 5px;
  width: 100%;
  height: 100%;
}

.thumbnail video {
  margin-top: 0.4em;
  border-radius: 5px;
  width: 100%;
  height: 100%;
}

h3 {
  font-size: 1em;
  line-height: 1.5em;
}

h3 a {
  color: #150c21;
}

h3 a:hover {
  color: rgb(20, 110, 190);
}

.list-item.highlight.description {
  /* reset any margins from other rules */
  margin-bottom: 0.0em;
  align-items: flex-start;
}

.list-item.service {
  align-items: flex-start;
}

.publication {
  margin-bottom: 0.5em;
}

.intern {
  margin-bottom: 0.5em;
}

.cv {
  margin-bottom: 0.5em;
}

.edu {
  margin-bottom: 0.5em;
}

.service {
  margin-bottom: 0.5em;
}

.misc {
  margin-bottom: 0.5em;
}

.publication p {
  font-size: 1.05em;
  line-height: 1.5em;
  color: #a0a8b0;
}

.list-item.intern p {
  font-size: 1.05em;
  line-height: 1.5em;
  color: #a0a8b0;
}

.edu p {
  font-size: 1.05em;
  line-height: 1.5em;
  color: #a0a8b0;
}

.service p {
  font-size: 1.05em;
  line-height: 1.5em;
  color: #a0a8b0;
}

.misc p {
  font-size: 1.0em;
  line-height: 1.5em;
  color: #a0a8b0;
}

.project-description {
  font-size: 1.05em;
  width: 80%;
  float: left;
}




.list-item {
  display: flex;
  align-items: center;
  margin-bottom: 5px;
}
.grey_box {
  color: #888;
  flex-shrink: 0;
}
.date {
  min-width: 60px; /* Adjust width as needed */
  color: #888;
  font-weight: 600;
  margin-right: 12px;
  flex-shrink: 0;
}
.description {
  font-size: 1.05em;
  flex-grow: 1;
}


.list-item.misc .misc-images {
  display: flex;
  gap: 2%;  /* 2% of the container width between the two images */
}

/* Select each image in that wrapper */
.list-item.misc .misc-images img {
  /* give each image a flex‑basis of half the remaining width */
  flex: 0 0 calc((100% - 2%) / 2);
  width: 20%;     /* fill its flex slot */
  height: auto;    /* preserve aspect ratio */
  display: block;  /* eliminate the little inline‐image gap */
  object-fit: cover; /* optional: crop to fill if source ratios vary */
}

/**************************************************/
/* Subtle footer at the bottom of the page. */

/* #footer {
  color: #a0a8b0;
  position: absolute;
  bottom: 0;
  line-height: 2.5em;
} */

#footer {
  clear: both;
  margin-top: 0rem;
  color: #a0a8b0;
  line-height: 2.0em;
  position: relative;
  z-index: 1;
}
.friend-section {
  max-width: 700px;
  /* margin: 2rem auto; */
  margin: 2rem 0;
  position: relative;
}

.friend-header {
  background-color: #2d72d9;
  color: white;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 14px;
  display: inline-block;
  margin-bottom: 16px;
  margin-left: 0px; /* aligns with timeline */
}

.friend-timeline {
  position: relative;
  padding-left: 0px;
  border-left: 2px solid #ccc;
}

.friend-item {
  display: flex;
  align-items: center;
  margin-bottom: 28px;
}

.timeline-left {
  width: 60px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.timeline-dot {
  width: 12px;
  height: 12px;
  background-color: #ccc;
  border-radius: 50%;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  margin-left: -31px;
}

.friend-content {
  display: flex;
  align-items: center;
}

.avatar {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  margin-right: 12px;
}

.friend-info {
  display: flex;
  flex-direction: column;
}

.domain {
  font-size: 13px;
  color: #555;
  text-decoration: none;
  margin-bottom: 2px;
}

.name {
  font-weight: bold;
  font-size: 16px;
}



.friend-link:hover {
  border-bottom: none;
  text-decoration: none;
}