.detailPage {
  background: #fff;
  color: #0c0c0d;
}

.detailPostWrapper {
  background: #fff;
}

.blog-hero.detailHero {
  position: relative;
  overflow: hidden;
  padding: 0;
  height: 340px;
}

.blog-hero__bg.detailHero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.blog-hero__bg.detailHero__bg::after {
  content: none;
}
.blog-hero__bg.detailHero__bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  -o-object-position: center;
     object-position: center;
  opacity: 1 !important;
  filter: none;
  display: block;
}

.detailCrumb {
  padding: 20px 0 10px;
}

.detailCrumb .container {
  padding-left: 0;
  padding-right: 0;
}
@media (max-width: 744px) {
  .detailCrumb .container {
    padding-left: 16px;
    padding-right: 16px;
  }
}

.detailCrumbText {
  margin: 0;
  color: #2d2d2f;
  font-family: var(--font-body, "Manrope", sans-serif);
  font-weight: 500;
  font-style: normal;
  font-size: 18px;
  line-height: 28px;
  letter-spacing: 0;
}

.detailSection {
  padding: 10px 0 100px;
}

.detailLayout {
  display: grid;
  grid-template-columns: minmax(0, 840px) minmax(320px, 384px);
  gap: 24px;
  align-items: start;
  justify-content: center;
  width: 100%;
}
.detailLayout > * {
  min-width: 0;
}
@media (max-width: 744px) {
  .detailLayout {
    grid-template-columns: 1fr;
  }
}

.detailSection > .container.detailLayout {
  max-width: 1248px;
  padding-left: 0;
  padding-right: 0;
}
@media (max-width: 744px) {
  .detailSection > .container.detailLayout {
    padding-left: 0;
    padding-right: 0;
  }
}

.detailContent {
  display: grid;
  gap: 24px;
  min-width: 0;
}

.detailTitle {
  margin: 0;
  font-size: clamp(1.8rem, 2.6vw, 2.1rem);
  line-height: 1.35;
  color: #232325;
}

.detailMeta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #36373a;
  font-weight: 500;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: 0;
  font-family: var(--font-body, "Manrope", sans-serif);
  font-style: normal;
}

.detailMetaIcon {
  width: 24px;
  height: 24px;
}

.detailParagraph {
  margin: 0;
  color: #232325;
  line-height: 1.6;
  min-width: 0;
  overflow-wrap: anywhere;
}

.detailParagraph img,
.detailParagraph video,
.detailParagraph iframe,
.detailParagraph table,
.detailParagraph pre {
  max-width: 100%;
}

.detailSidebar {
  width: 100%;
  max-width: 384px;
  background: #fff;
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.12);
  display: grid;
  gap: 20px;
  justify-self: end;
}
@media (max-width: 744px) {
  .detailSidebar {
    width: 100%;
    max-width: 100%;
    margin-top: 40px;
    margin-bottom: 60px;
  }
}

.detailSidebarTitle {
  margin: 0 0 20px;
  font-size: 1.25rem;
}

.detailRelated {
  display: grid;
  gap: 12px;
}

.detailRelatedCard {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  text-decoration: none;
  color: inherit;
}

.detailSidebar .detailRelatedCard {
  display: flex;
  align-items: flex-start;
  width: 100%;
  min-width: 0;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: flex-start;
  width: 100%;
}

.detailRelatedThumb {
  width: clamp(88px, 22vw, 120px);
  height: clamp(73px, 18.3vw, 100px);
  aspect-ratio: 6/5;
  border-radius: 5px;
  -o-object-fit: cover;
     object-fit: cover;
  display: block;
  flex-shrink: 0;
  order: 0;
}

@media (min-width: 1024px) and (max-width: 1440px) {
  .detailRelatedThumb {
    width: 120px;
    height: 100px;
  }
}
.detailRelatedInfo {
  display: grid;
  gap: 8px;
  min-width: 0;
  flex: 1;
  order: 1;
}

.detailRelatedDate {
  display: block;
  font-family: var(--font-body, "Manrope", sans-serif);
  font-style: normal;
  font-weight: 400;
  font-size: 14px;
  line-height: 22px;
  letter-spacing: 0;
  color: #7a7c85;
  margin: 0;
}

.detailSidebarCardTitle {
  margin: 0;
  font-size: 1rem;
  line-height: 1.5;
  color: #232325;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.detailRelatedTitle {
  display: block;
  font-size: 1rem;
  line-height: 1.5;
  color: #232325;
  font-weight: 600;
  max-height: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ================= MIGRATED FROM posts.css (detail only) ================= */
.detailBody {
  border: none;
}

.detailBodyLegacy {
  padding: 80px 0;
  border: none;
}

@media (max-width: 991.98px) {
  .blog-hero.detailHero {
    height: 360px;
    min-height: 360px;
  }
  .detailBodyLegacy {
    padding: 60px 40px;
  }
}
@media (max-width: 575.98px) {
  .blog-hero.detailHero {
    height: 260px;
    min-height: 260px;
  }
  .detailBodyLegacy {
    padding: 50px 15px;
  }
}
.detailBody p {
  margin-top: 0;
  margin-bottom: 1rem;
}

.detailBody a {
  display: inline-block;
}

.detailBody a,
.detailBody a:hover {
  color: #000 !important;
  text-decoration: none !important;
}

.detailPage .btn:focus {
  color: #000 !important;
  background-color: #fff !important;
}

.detailCommentActionIcon,
.detailComments .dropdown-menu .btn-icon,
.comment .dropdown-menu .btn-icon {
  display: flex !important;
}

.detailRelatedSection {
  margin-top: 48px;
}

.detailRelatedWrapper {
  margin-top: 80px;
}

.detailRelatedSectionTitle {
  margin-bottom: 24px;
  text-align: center;
}

.detailRelatedSectionItem {
  background: #fff;
  border-radius: 3px;
  transition: 0.3s;
  padding: 40px 0;
  border-bottom: var(--border);
}

.detailRelatedSectionItem a:hover {
  text-decoration: none;
}

.detailRelatedSectionTag {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 13px;
  line-height: 120%;
  margin-top: 0;
}

.detailRelatedSectionTag a {
  display: inline-block;
  margin-top: 0;
}

.detailRelatedSectionDate {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 0;
  color: #666666;
  font-weight: 500;
  white-space: nowrap;
}

.blog-card__tags {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 22px;
  max-width: 100%;
  flex-wrap: wrap;
  overflow: visible;
}

.blog-card__tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  max-width: 132px;
  padding: 2px 6px;
  border-radius: 8px;
  background: #bfdffe;
  color: #1d5bd8;
  font-size: 13px;
  font-weight: 500;
  line-height: 18px;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.detailRelatedSectionCardTitle {
  margin-top: 24px;
  font-weight: 700;
  font-size: 28px;
  line-height: 130%;
  color: var(--blue-strong);
}

.detailRelatedSectionCardContent {
  margin-top: 12px;
  font-weight: 400;
  font-size: 18px;
  line-height: 150%;
  color: #666666;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow-wrap: anywhere;
}

.detailRelatedSectionThumb {
  margin-top: 20px;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 16/9;
  width: 100%;
}

.detailRelatedSectionThumb > a {
  display: block;
  width: 100%;
  height: 100%;
}

.detailRelatedSectionThumb img {
  width: 100%;
  height: 100%;
  display: block;
  -o-object-fit: cover;
     object-fit: cover;
  border-radius: 8px;
  max-height: none;
}

@media (max-width: 744px) {
  .detailRelatedSectionThumb img {
    width: 100%;
    height: 100%;
  }
}
.detailShare {
  margin-top: 8px;
  text-align: center;
}

.detailShareText {
  margin-bottom: 8px;
}

.detailShareIcons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.detailShareLink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.detailComments {
  margin-top: 24px;
}

.comment {
  margin-top: 24px;
}

.color-web-ici {
  color: #666666;
}

.detailCommentsList {
  margin-top: 12px;
}

.detailComments .reply-comment,
.comment .reply-comment {
  display: none;
}

.detailComments .tui-editor,
.comment .tui-editor {
  width: 100%;
}

.detailComments .toastui-editor-defaultUI,
.comment .toastui-editor-defaultUI {
  border-radius: 6px;
}

.detailComments .toastui-editor-mode-switch,
.comment .toastui-editor-mode-switch {
  display: block;
}

.detailComments .float-end,
.comment .float-end {
  float: none !important;
  display: flex;
  justify-content: flex-end;
}

.detailCommentBackground {
  background-color: aliceblue;
  border-radius: 8px;
  padding: 0.5rem !important;
}

.detailCommentName {
  margin-top: 3px;
}

.detailCommentTime {
  display: inline-flex;
  align-items: center;
  margin-top: 5px;
}

.detailCommentReply {
  cursor: pointer;
}

.comment .actions-list,
.comment .action-comment {
  z-index: 1;
}

.btn_show_hide {
  color: #1c82f0;
}

.detailComments .toastui-editor-toolbar-icons.table,
.comment .toastui-editor-toolbar-icons.table {
  margin-top: 15px;
}

.detailParagraph img[src*="#center"],
.detailParagraph p > img[src*="#center"] + em {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0 auto;
}

.detailParagraph p > img[src*="#center"] + em {
  padding-top: 10px !important;
}

.detailParagraph blockquote > p {
  display: flex;
}

.detailParagraph blockquote a {
  margin-left: 3px;
}

.detailParagraph blockquote {
  border-left: 2px solid #2855b1 !important;
}

@media (max-width: 744px) {
  .detailLayout,
  .detailContent {
    width: 100%;
    min-width: 0;
  }
  .detailContent > * {
    max-width: 100%;
  }
  .detailTitle,
  .detailMeta,
  .detailParagraph,
  #post-content,
  .detailComments,
  .detailComments .form-comment {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  #post-content * {
    max-width: 100%;
  }
  #post-content table {
    display: block;
    overflow-x: auto;
  }
  #post-content pre {
    white-space: pre-wrap;
    word-break: break-word;
  }
  .detailRelatedSectionItem {
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    padding-right: 0;
  }
  .detailRelatedSectionDate {
    white-space: normal;
  }
  .detailComments .form-comment .d-flex,
  .comment .form-comment .d-flex {
    min-width: 0;
    align-items: flex-start;
    gap: 8px;
    display: grid;
    grid-template-columns: 32px minmax(0, 1fr);
  }
  .detailComments .form-comment .avatar,
  .comment .form-comment .avatar {
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
  }
  .detailComments .form-comment .tui-editor,
  .comment .form-comment .tui-editor {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
  }
  .detailComments .toastui-editor-defaultUI,
  .detailComments .toastui-editor-main,
  .detailComments .toastui-editor-main-container,
  .detailComments .toastui-editor-md-container,
  .detailComments .toastui-editor-ww-container,
  .detailComments .toastui-editor-md-preview,
  .comment .toastui-editor-defaultUI,
  .comment .toastui-editor-main,
  .comment .toastui-editor-main-container,
  .comment .toastui-editor-md-container,
  .comment .toastui-editor-ww-container,
  .comment .toastui-editor-md-preview {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }
  .detailComments .toastui-editor-toolbar,
  .comment .toastui-editor-toolbar {
    min-width: 0 !important;
  }
  .detailComments .toastui-editor-defaultUI-toolbar,
  .comment .toastui-editor-defaultUI-toolbar {
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
  }
  .detailComments .toastui-editor-md-splitter,
  .comment .toastui-editor-md-splitter {
    display: none !important;
  }
}
