/* The shortcode is isolated from the existing Newsup slider and article cards. */
.oct-hk {
  direction: rtl;
  text-align: right;
  color: inherit;
  width: 100%;
  margin: 24px 0 32px;
  font-family: inherit;
}
.oct-hk * { box-sizing: border-box; }
.oct-hk__main-heading { margin: 0 0 20px; }
.oct-hk__main-heading h2 { font-size: clamp(20px, 2vw, 26px); margin: 0; }
.oct-hk__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.oct-hk__column { min-width: 0; padding: 15px 17px; border: 1px solid rgba(128,128,128,.23); border-radius: 4px; }
.oct-hk__column-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.oct-hk__column-heading h3 { margin: 0; font-size: 20px; }
.oct-hk__archive { font-size: 13px; font-weight: 600; white-space: nowrap; text-decoration: none; }
.oct-hk__posts { display: flex; flex-direction: column; gap: 0; }
.oct-hk__post { display: flex; align-items: flex-start; gap: 12px; padding: 13px 0; border-top: 1px solid rgba(128,128,128,.20); }
.oct-hk__post:first-child { border-top: 0; padding-top: 2px; }
.oct-hk__thumb { flex: 0 0 112px; width: 112px; display: block; overflow: hidden; }
.oct-hk__thumb img { display: block; width: 100%; height: 83px; object-fit: cover; border-radius: 3px; }
.oct-hk__details { flex: 1; min-width: 0; }
.oct-hk__post-title { font-size: 16px; line-height: 1.75; margin: 0 0 5px; overflow-wrap: anywhere; }
.oct-hk__post-title a { color: inherit; text-decoration: none; }
.oct-hk__post-title a:hover, .oct-hk__post-title a:focus { text-decoration: underline; }
.oct-hk__date { font-size: 12px; opacity: .7; }
.oct-hk__empty, .oct-hk__warning { margin: 8px 0; font-size: 14px; }
@media (max-width: 800px) {
  .oct-hk__grid { grid-template-columns: 1fr; gap: 16px; }
}
@media (max-width: 400px) {
  .oct-hk__column { padding: 12px; }
  .oct-hk__thumb { flex-basis: 90px; width: 90px; }
  .oct-hk__thumb img { height: 74px; }
  .oct-hk__post-title { font-size: 15px; }
}

/* Newsup single-post markup has .mg-header, then the featured img, then the article.
   Flex order puts the ORIGINAL image above the title, without duplicating it.
   This is applied ONLY if the post belongs to Notices or Plenums. */
body.single-post.oct-hk-document #content .mg-blog-post-box {
  display: flex;
  flex-direction: column;
}
body.single-post.oct-hk-document #content .mg-blog-post-box > img.wp-post-image {
  order: 1;
  align-self: center;
  display: block;
  width: min(100%, 720px);
  height: auto;
  max-height: 500px;
  object-fit: contain;
  margin: 4px auto 22px;
}
body.single-post.oct-hk-document #content .mg-blog-post-box > .mg-header {
  order: 2;
  width: 100%;
  direction: rtl;
  text-align: center;
}
body.single-post.oct-hk-document #content .mg-blog-post-box > .mg-header .title.single {
  text-align: center;
}
body.single-post.oct-hk-document #content .mg-blog-post-box > article.small.single {
  order: 3;
  width: 100%;
  direction: rtl;
  text-align: right;
}
