html {
  scroll-behavior: smooth;
}

li {
  list-style-type: none;
}

a {
  text-decoration: none;
}

.single-container {
  max-width: 1300px;
  margin: 60px auto;
  display: flex;
  gap: 26px;
  padding: 0 30px;
}

/* ------ mini dashboard ------ */
/* Sidebar container */
.mini-dashboard {
  width: 30%;
  display: flex;
  flex-direction: column;
  gap: 30px;
  position: -webkit-sticky;
  /* For Safari */
  position: sticky;
  top: 20px;
  z-index: 10;
  max-height: 100vh;
  /* Prevent overflow of sidebar */
  overflow-y: auto;
}

/* When the sidebar reaches the comments section, make it stop */
.mini-dashboard.stuck {
  position: absolute;
  top: auto;
  bottom: 20px;
  z-index: 5;
  /* So it goes behind content like comments */
}

/* Logos inside the sidebar */
.mini-dashboard-logos-container {
  width: 100%;
  padding: 12px 10px;
  border: 1px solid #ADADAD80;
  border-radius: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mini-dashboard-logos-container svg {
  width: 32px;
  height: 32px;
}

.sidebar-share-btn {
  line-height: 0;
}


.sidebar-share-btn svg {
  color: inherit;
}

.sidebar-share-btn {
  color: var(--mini-dashboard-logos);
}

.telegram-btn:hover {
  color: #20c8f1;
}

.instagram-btn:hover {
  color: #ff8d4b;
}

.x-btn:hover {
  color: #000000;
}

.whatsapp-btn:hover {
  color: #17dd49;
}

/* Heading in sidebar */
.mini-dashboard>h2 {
  font-size: 24px;
  font-weight: 600;
}

/* ------------------------------------------- */

.headings-container {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  position: relative;
  direction: rtl;
  /* Set Right-to-Left */
}

/* The vertical line */
.circles-lines {
  position: absolute;
  right: 8px;
  /* Align to the right */
  top: 0px;
  width: 5px;
  background-color: #EBEDEF80;
  /* height: 100%; */
  bottom: 4px;
}

/* Ensure the table of contents container grows and allows text truncation */
.table-of-contents {
  flex-grow: 1;
  /* Allow the container to grow */
  min-width: 0;
  /* Important for allowing flex items to shrink and text to ellipsis */
  position: relative;
  /* Needed if children are positioned relative to it */
}

/* Style the list */
.table-of-contents ul {
  list-style: none;
  padding-right: 20px;
  /* Space for circles */
  position: relative;
  max-width: 100%;
  /* Ensure the list doesn't overflow the container */
  overflow: hidden;
  /* Prevent the list from overflowing */
}

/* Style each list item - remove redundant padding */
.table-of-contents li {
  position: relative;
  margin-bottom: 20px;
  padding-right: 10px;
  font-size: 14px;
}

.table-of-contents li a:hover {
  color: #FFC107;
}

/* Remove margin from the last list item */
.table-of-contents li:last-child {
  margin-bottom: 0;
}

/* Apply truncation and ellipsis to the <a> */
.table-of-contents ul li a {
  display: block;
  /* Make sure the <a> spans the available width */
  max-width: 100%;
  /* Ensure it doesn't exceed the container's width */
  white-space: nowrap;
  /* Prevent wrapping */
  overflow: hidden;
  /* Hide overflowed text */
  text-overflow: ellipsis;
  /* Add "..." when the text overflows */
  color: var(--hover-card-text);
  direction: rtl;
  /* Ensure RTL text flow */
  text-align: right;
  /* Align text to the right */
}

/* Add circles before each <li> - adjust position if needed after removing li padding */
.table-of-contents li::before {
  content: "";
  position: absolute;
  /* Adjust 'right' if the circle alignment is off now */
  right: -18px;
  /* Example adjustment - may need fine-tuning */
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 3px solid #EBEDEF;
  /* Light gray border */
  background-color: var(--bg-color);
  /* Hollow circle */
}

/* Highlight the active item */
.table-of-contents li.active::before {
  border-color: #fbbf24;
  /* Gold */
  background-color: var(--bg-color);
}

/* Change text color when active */
.table-of-contents li.active a {
  color: #fbbf24;
}


/* ----------------- main post ----------------- */

.main-post {
  width: 70%;
}

.post-title {
  margin: 20px 0;
  font-weight: 700;
  font-size: 30px;
}

.main-post-content {
  border-bottom: 3px solid var(--footer-main);
  display: flex;
  flex-direction: column !important;
  gap: 20px;
  line-height: 40px;
  text-align: justify;
  font-size: 18px;
  font-weight: 400;
  padding-bottom: 20px;
}

#post-content {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.main-post-content img {
  border-radius: 20px;
}

.main-post-content h2 {
  font-weight: bolder;
  font-size: 25px;
  margin: 20px 0;
}

.main-post-content h3 {
  font-weight: 400;
  margin: 20px 0;
}

.main-post-content p {
  line-height: 40px;
  text-align: justify;
}

.main-post-content a {
  text-decoration: none;
  color: #FFD700;
}

.main-post-content a:hover {
  color: #e0a510;
}

.main-post-content ol li {
  list-style-type: decimal;
  margin-right: 24px;
}

.main-post-content ul {
  background-color: var(--post-content-list-bg);
  padding: 20px;
  margin: 20px 0;
  border-radius: 30px;
}

.main-post-content ul li {
  list-style-type: disc;
  margin-right: 16px;
}

.main-post-content ul li::marker {
  color: #FFC107;
}

.main-post-content blockquote {
  background-color: var(--post-content-blockquote-bg);
  border: 1px solid var(--post-content-blockquote-border);
  border-radius: 30px;
  padding: 50px 70px;
  position: relative;
  width: fit-content;
  max-width: 100%;
  text-align: justify;
}

.main-post-content blockquote::before,
.main-post-content blockquote::after {
  content: '';
  position: absolute;
  display: inline-block;
  width: 37px;
  height: 37px;
  background-color: var(--text-color);
  /* This is the color of the icon */
  mask-image: url('../assets/icons/single/icon-quote.svg');
  mask-repeat: no-repeat;
  mask-size: contain;
  mask-position: center;
  -webkit-mask-image: url('../assets/icons/single/icon-quote.svg');
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-size: contain;
  -webkit-mask-position: center;
}

.main-post-content blockquote::before {
  top: 20px;
  right: 20px;
  transform: rotate(180deg);
}

.main-post-content blockquote::after {
  bottom: 20px;
  left: 20px;
}

.main-post-content table {
  max-width: 100%;
  font-size: 14px;
  border-collapse: collapse;
  margin: 20px 0;
}

.main-post-content table tbody tr td {
  border: 1px solid #666666;
  padding: 8px;
  text-align: justify;
  width: 50%;
}

.main-post-content table tbody tr {}

.main-post-content table tbody tr:nth-child(even) {
  background-color: var(--bg-color);
}

.main-post-content table tbody tr:nth-child(odd) {
  background-color: var(--header-bg);
}

.main-post-content table tbody tr:hover {
  background-color: var(--comment-bg);
}

.main-post-top-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.breadcrumb-navigation a,
.breadcrumb-navigation h5 {
  font-size: 14px;
  font-weight: 400;
}

.breadcrumb-navigation-post-title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.breadcrumb-navigation h5 {
  color: #FFC107;
}

.breadcrumb-navigation {
  display: flex;
  align-items: center;
  gap: 10px;
}

.breadcrumb-navigation a:hover {
  color: #FFC107;
}

.breadcrumb-navigation-post-date {
  font-size: 14px !important;
  font-weight: 400 !important;
}

.main-post-top-line a {
  color: var(--text-color);
}

.main-post-image {
  width: 100%;
  height: auto;
}

.main-post-image img {
  width: 100%;
  height: 100%;
  object-fit: fill;
  border-radius: 20px;
}

.navigator-prev-next {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 20px 0;
}

.navigator-prev-next a:hover {
  color: #FFC107
}

.prev-post,
.next-post {
  display: flex;
  align-items: center;
  gap: 10px;
}

.navigator-prev-next span svg {
  width: 30px;
  height: 30px;
}

.prev-post,
.next-post {
  color: var(--text-color);
  text-decoration: none;
}

.navigator-prev-next a svg {
  width: 25px;
  height: 25px;
}

.prev-post svg {
  transform: rotate(90deg);
}

.next-post svg {
  transform: rotate(-90deg);
}

/* ------------------------------ */

.rating-stars {
  margin: 40px 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
}

.rating-stars .star {
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: inline-block;
}

.rating-stars .star svg {
  width: 100%;
  height: 100%;
  transition: fill 0.3s ease-in-out;
  display: block;
}

.rating-stars .star.filled {
  color: #FFC107;
}

.rating-stars .star.filled svg {
  fill: #FFC107;
  /* Gold */
}

.rating-stars .star.empty {
  color: #8C8C8C;
}

.rating-stars .star.empty svg {
  fill: #8C8C8C;
  /* Gray */
}

/* -------------------------------- */

.share-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.share-copy button {
  border: 1px solid #FFC107;
  border-radius: 10px;
  width: 232px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: inherit;
  cursor: pointer;
  font-size: 18px;
  font-weight: 600;
  background-color: var(--bg-color);
  color: var(--text-color);
}

.share-copy button svg {
  width: 22px;
  height: 22px;
}

/* ------------------------------ */

.comments-section {
  margin-top: 50px;
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.comments-section>h2,
.comments-section>h3 {
  font-size: 25px;
  font-weight: 600;
  color: var(--comments-h2);
}

.comments-section>h2 span,
.comments-section>h3 span {
  padding: 2px 13px;
  background-color: #FFC107;
  color: #ffffff;
  border-radius: 10px;
  text-align: center;
  margin-left: 4px;
}

.comment-input-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
  background-color: var(--comment-input-section-bg);
  border-radius: 30px;
  padding: 20px;
}

.comment-text-input {
  padding: 20px;
  border-radius: 12px;
  height: 265px;
  width: 100% !important;
  font-family: inherit;
  border: none;
  outline: none;
  font-size: 18px;
  font-weight: 400;
  background-color: var(--comment-textarea-bg);
  color: var(--text-color);
}

.comment-text-input::placeholder {
  color: #DADADA80;
}

.comment-input-section-bottom {
  display: flex;
  align-items: center;
  gap: 20px;
}

.comment-input-section-bottom>* {
  width: 33%;
  padding: 15px 20px;
  border-radius: 12px;
  font-family: inherit;
  border: none;
  outline: none;
  font-size: 18px;
  font-weight: 400;
  background-color: var(--comment-textarea-bg);
  color: var(--text-color);
}

.comment-input-section-bottom>*::placeholder {
  color: #DADADA80;
}

.cisb-btn {
  background-color: #FFC107;
  color: #ffffff;
  cursor: pointer;
  transition: all 0.3s ease;
}

.cisb-btn:hover {
  transform: translateY(-2px);
  opacity: 0.80;
}

.comments-container {
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Individual comment */
.comment {
  background-color: var(--comment-bg);
  border-radius: 20px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.comment-header {
  display: flex;
  align-items: center;
  gap: 14px;
  font: 16px;
  font-weight: 400;
  color: #8c8c8c;
}

.avatar-container {
  width: 48px;
  height: 48px;
  border-radius: 9999px;
  overflow: hidden;
}

.avatar-container img {
  object-fit: contain;
}

.comment-author {
  font-size: 16px;
  font-weight: 600;
  color: #666666;
}

.comment p {
  font-size: 16px;
  font-weight: 400;
  color: #666666;
}

.comment-footer {
  display: flex;
  align-items: center;
  justify-content: end;
}

.comment-dislikes {
  color: #8C8C8C;
}

.comment-likes {
  color: #8C8C8C;
  margin: 0 12px;
}

.comment-likes svg,
.comment-dislikes svg {
  width: 20px;
  /* Adjust size as needed */
  height: 20px;
  /* Adjust size as needed */
  vertical-align: middle;
  /* Align the icons with the text */
  margin-right: 5px;
  /* Space between the icon and the count */
  color: #33B028;
}

.comment-inner-reply,
.reply-inner-reply {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #8C8C8C;
  cursor: pointer;
  padding: 4px 8px;
}

.comment-inner-reply:hover,
.reply-inner-reply:hover {
  background-color: #d4d4c9;
  border-radius: 10px;
}

.comment-inner-reply svg,
.reply-inner-reply svg {
  width: 14px;
  height: 12px;
}

.reply-input-container {
  display: none;
  flex-direction: column;
  gap: 20px;
}

.reply-input-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.reply-input-reply-to span {
  color: var(--hover-card-text);
}

.reply-input-cancel {
  border: none;
  background-color: #FF6969;
  color: #ffffff;
  padding: 6px 12px;
  border-radius: 8px;
  font-family: inherit;
  cursor: pointer;
}

.reply-input-content {
  width: 100% !important;
  padding: 20px;
  height: 214px;
  border-radius: 20px;
  font-family: inherit;
  border: 1px solid #ADADAD80;
  outline: none;
}

.reply-input-name-email-container {
  width: 100%;
  display: flex;
  gap: 10px;
}

.reply-input-name-email-container div {
  width: 50%;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.reply-input-name-email-container div label {
  font-size: 20px;
  font-weight: 600;
}

.reply-input-name-email-container div label span {
  color: #FF0000;
}

.reply-input-name-email-container div input {
  width: 100%;
  height: 60px;
  padding: 10px;
  border-radius: 20px;
  font-family: inherit;
  border: 1px solid #ADADAD80;
  outline: none;
}

.reply-input-checkbox-container {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
}

.reply-submit {
  background-color: #FFC107;
  color: #ffffff;
  padding: 15px 20px;
  border-radius: 15px;
  font-family: inherit;
  font-weight: 600;
  font-size: 20px;
  cursor: pointer;
  border: none;
}

/* -------------------------------------- */

.replies-container {
  margin-right: 50px;
  /* Indent replies */
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Individual reply */
.reply {
  background-color: var(--reply-bg);
  /* Only reply itself has this background */
  border-radius: 20px;
  padding: 15px;
  color: var(--comments-h2);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.selectpicker {
  display: none;
  width: 100%;
}

.mini-dashboard-logos-container-mobile {
  display: none;
}

.table-of-contents-mobile {
  display: none;
}

/* popup ==================================================== */
.popup {
  position: fixed;
  top: 40px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 16px;
  color: #fff;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.popup.show {
  opacity: 1;
  pointer-events: auto;
}

.popup.success {
  background-color: #28a745;
  /* green */
}

.popup.error {
  background-color: #dc3545;
  /* red */
}

.popup button {
  background: transparent;
  border: none;
  font-size: 20px;
  color: #fff;
  cursor: pointer;
}

.hidden {
  display: none;
}

/* ==================================================== */
@media screen and (max-width: 1000px) {
  .main-post-top-line h5 {
    font-weight: 400;
    font-size: 12px;
    line-height: 18px;
    /* margin-bottom: 10px; */
  }

  .single-container {
    align-items: center;
    width: 100%;
    flex-direction: column;
    gap: 0px;
  }

  .mini-dashboard {
    display: none;
  }

  .main-post {
    width: 100%;
    padding-left: 10px;
    padding-right: 10px;
  }

  .main-post-image {
    overflow: hidden;
    border-radius: 10px;
  }

  .selectpicker {
    display: flex;
    width: 100%;
    margin-bottom: 20px;
    height: 50px;
    background-color: transparent;
    border: 1px solid rgba(173, 173, 173, 0.5);
    border-radius: 20px;
    padding-left: 15px;
    padding-right: 30px;
    appearance: none;
    cursor: pointer;
  }

  .selectpicker {
    background-image: url('data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2016%2016%22%3E%3Cpath%20d%3D%22M2%203l6%206%206-6%22%20fill%3D%22none%22%20stroke%3D%22%23ADADAD%22%20stroke-width%3D%222%22%2F%3E%3C%2Fsvg%3E');
    background-repeat: no-repeat;
    background-position: left 15px center;
    background-size: 16px;
    outline: none;
    color: var(--text-color);
    font-family: inherit;
  }

  .selectpicker option {
    color: var(--text-color);
    font-weight: normal;
    font-size: 14px;
    line-height: 22px !important;
    background-color: var(--bg-color);
  }

  .selectpicker option:checked {
    background-color: orange !important;
    color: white !important;
  }

  .mini-dashboard-logos-container-mobile {
    width: 100%;
    height: 49px;
    margin-bottom: 20px;
    padding: 10px;
    border: 1px solid #ADADAD80;
    border-radius: 20px;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .table-of-contents-mobile {
    width: 100%;
    margin-bottom: 20px;
    padding: 10px;
    border: 1px solid #ADADAD80;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
  }

  .table-of-contents-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .table-of-contents-mobile-header-chevron-icon {
    width: 16px;
    height: 16px;
    line-height: 0;
    transition: transform 0.3s ease-in-out;
  }

  .table-of-contents-mobile.open .table-of-contents-mobile-header-chevron-icon {
    transform: rotate(180deg);
  }

  .contents-mobile {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-in-out;
  }

  .contents-mobile.open {
    max-height: 1000px;
  }

  .contents-mobile>*:first-child {
    border-top: 1px solid #ADADAD80;
    padding-top: 12px;
    margin-top: 12px;
  }

  .contents-mobile a {
    text-decoration: none;
    font-size: 14px;
    color: var(--text-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
  }

  .mini-dashboard-logos-container-mobile svg {
    width: 26px;
    height: 26px;
  }

  .navigator-prev-next span svg {
    width: 20px;
    height: 20px;
  }

  .navigator-prev-next a svg {
    width: 12px;
    height: 12px;
  }

  .navigator-prev-next a {
    font-size: 12px;
    font-weight: 600;
  }

  .rating-stars {
    margin: 40px 0;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;

  }

  .star svg {
    width: 20px;
    height: 20px;
  }

  .share-copy button {
    border: 0.55px solid #FFC107;
    border-radius: 4.5px;
    width: 134px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    font-family: inherit;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    background-color: var(--bg-color);
    color: var(--text-color);
  }

  .share-copy button svg {
    width: 10px;
    height: 10px;
  }

  .comments-section {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .comments-section>h2,
  .comments-section>h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--comments-h2);
  }

  .comments-section>h2 span,
  .comments-section>h3 span {
    padding: 2px 8px;
    background-color: #FFC107;
    color: #ffffff;
    border-radius: 5px;
    text-align: center;
    margin-left: 4px;
  }

  .comment-text-input {
    padding: 9px 8px;
    border-radius: 5px;
    height: 121px;
    width: 100%;
    font-size: 12px;
  }

  .comment-input-section {
    margin-top: 20PX;
    margin-bottom: 20PX;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background-color: var(--comment-input-section-bg);
    border-radius: 10px;
    padding: 10px;

  }

  .comment-input-section-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
  }

  .comment-input-section-bottom>* {
    width: 100%;
    padding: 5px 8px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: 400;
  }

  .main-post-content p {
    font-size: 14px !important;
    line-height: 30px;
  }

}

@media screen and (max-width: 768px) {

  .breadcrumb-navigation-post-date {
    display: none;
  }

  .breadcrumb-navigation a,
  .breadcrumb-navigation h5 {
    font-size: 10px;
  }

  .breadcrumb-navigation a {
    white-space: nowrap;
    flex-shrink: 0;
  }

  .breadcrumb-navigation {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    overflow: hidden;
    gap: 4px;
  }

  /* Truncate <h5> with ellipsis */
  .breadcrumb-navigation h5 {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    display: block;
  }

  .breadcrumb-navigation {
    gap: 4px;
  }

  .breadcrumb-navigation-post-title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    flex-shrink: 1;
    flex-grow: 1;
    min-width: 0;
  }

  .main-post-content h2,
  .main-post-content h3,
  .main-post-content ul {
    text-align: start;
  }

  .main-post-content table {
    font-size: 12px;
  }

  .single-container {
    padding: 0 12px;
    margin-top: 20px;
  }

  .post-title {
    font-size: 25px;
  }

}