/* ================================================================
   DoiHinhTFT — Sidebar Widgets: Lịch Cập Nhật + Mẹo Ngẫu Nhiên
   Theme palette: #0a0d1a body / #0f1428 card / #d4b896 gold
   ================================================================ */

/* ── Shared Widget Shell ── */
.dhtft-patch-schedule-widget,
.dhtft-random-tip-widget,
.dhtft-top-players-widget,
.dhtft-latest-posts-widget {
  --ps-bg:       #0c1020;
  --ps-border:   rgba(212,184,150,.1);
  --ps-gold:     #d4b896;
  --ps-gold-dim: rgba(212,184,150,.55);
  --ps-text:     #e6e6e6;
  --ps-muted:    rgba(230,230,230,.42);
  --ps-live:     #22c55e;
  --ps-soon:     #f59e0b;
  --ps-radius:   10px;
  background: var(--ps-bg);
  border: 1px solid var(--ps-border);
  border-radius: var(--ps-radius);
  overflow: hidden;
  position: relative;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  color: var(--ps-text);
}
/* Corner bracket top-left */
.dhtft-patch-schedule-widget::before,
.dhtft-random-tip-widget::before,
.dhtft-top-players-widget::before,
.dhtft-latest-posts-widget::before {
  content: '';
  position: absolute;
  top: 6px;
  left: 6px;
  width: 14px;
  height: 14px;
  border-top: 2px solid #d4b896;
  border-left: 2px solid #d4b896;
  pointer-events: none;
  z-index: 2;
}

/* Corner bracket bottom-right */
.dhtft-patch-schedule-widget::after,
.dhtft-random-tip-widget::after,
.dhtft-top-players-widget::after,
.dhtft-latest-posts-widget::after {
  content: '';
  position: absolute;
  bottom: 6px;
  right: 6px;
  width: 14px;
  height: 14px;
  border-bottom: 2px solid #d4b896;
  border-right: 2px solid #d4b896;
  pointer-events: none;
  z-index: 2;
}


/* ── Shared Header ── */
.dhtft-ps__header,
.dhtft-rt__header,
.dhtft-tp__header,
.dhtft-lp__header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--ps-border);
  background: rgba(212,184,150,.04);
}

.dhtft-ps__icon,
.dhtft-rt__icon,
.dhtft-tp__icon,
.dhtft-lp__icon {
  color: var(--ps-gold);
  flex-shrink: 0;
}

.dhtft-ps__title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--ps-gold);
}

/* ════════════════════════════
   TFT MÙA 18 NAVIGATION WIDGET
════════════════════════════ */

/* Gaming / Esports HUD style: khung vát chamfer, viền neon,
   huy hiệu lục giác, sọc năng lượng, nền hexagon + scanline. */

.dhtft-set18-nav-widget {
  --s18-gold: #d4b896;
  --s18-gold-hi: #f0d6ad;
  --s18-green: #57e69b;
  --s18-cut: 12px; /* độ vát góc */
  position: relative;
  color: #e6e6e6;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  filter: drop-shadow(0 0 14px rgba(87,230,155,.1)) drop-shadow(0 10px 22px rgba(0,0,0,.35));
}

/* Viền neon: lớp ngoài = border gradient, lớp trong = nền, cùng clip-path vát góc */
.dhtft-s18__frame {
  position: relative;
  padding: 1px;
  clip-path: polygon(var(--s18-cut) 0, 100% 0, 100% calc(100% - var(--s18-cut)), calc(100% - var(--s18-cut)) 100%, 0 100%, 0 var(--s18-cut));
  background: linear-gradient(140deg, rgba(87,230,155,.65), rgba(212,184,150,.28) 40%, rgba(87,230,155,.12) 70%, rgba(240,214,173,.55));
}

.dhtft-s18__inner {
  position: relative;
  clip-path: polygon(var(--s18-cut) 0, 100% 0, 100% calc(100% - var(--s18-cut)), calc(100% - var(--s18-cut)) 100%, 0 100%, 0 var(--s18-cut));
  background:
    radial-gradient(130% 90% at 100% 0%, rgba(52,168,110,.2), transparent 50%),
    linear-gradient(160deg, #0a121f 0%, #0c1826 55%, #090f1c 100%);
  overflow: hidden;
}

/* Scanline mờ kiểu HUD */
.dhtft-s18__inner::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,.016) 0 1px, transparent 1px 4px);
}

/* Lưới hexagon mờ góc phải */
.dhtft-s18__hex-bg {
  position: absolute;
  top: -8px;
  right: -10px;
  width: 150px;
  height: 120px;
  color: rgba(87,230,155,.08);
  pointer-events: none;
  z-index: 0;
}

/* Dải năng lượng sọc chéo chạy trên cùng */
.dhtft-s18__strip {
  position: relative;
  z-index: 1;
  height: 5px;
  background:
    repeating-linear-gradient(115deg, #57e69b 0 10px, transparent 10px 18px),
    linear-gradient(90deg, rgba(87,230,155,.25), rgba(212,184,150,.2));
  background-size: 56px 100%, 100% 100%;
  animation: s18stripe 2.8s linear infinite;
  opacity: .6;
}
@keyframes s18stripe {
  from { background-position: 0 0, 0 0; }
  to   { background-position: 56px 0, 0 0; }
}

.dhtft-s18__hero {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 72px;
  padding: 13px 15px 12px;
  color: #e6e6e6 !important;
  text-decoration: none !important;
  border-bottom: 1px solid rgba(87,230,155,.14);
  overflow: hidden;
}

/* Vệt shine quét ngang khi hover */
.dhtft-s18__shine {
  position: absolute;
  top: 0;
  bottom: 0;
  left: -70%;
  width: 44%;
  background: linear-gradient(105deg, transparent, rgba(240,214,173,.1) 48%, transparent);
  transform: skewX(-18deg);
  transition: left .5s ease;
  pointer-events: none;
}
.dhtft-s18__hero:hover .dhtft-s18__shine,
.dhtft-s18__hero:focus .dhtft-s18__shine { left: 135%; }

/* Huy hiệu lá trong khung lục giác */
.dhtft-s18__icon {
  position: relative;
  width: 46px;
  height: 50px;
  flex: 0 0 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #8ef0b8;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  background: linear-gradient(160deg, rgba(87,230,155,.3), rgba(87,230,155,.06));
  box-shadow: inset 0 0 16px rgba(87,230,155,.14);
}
.dhtft-s18__icon::before {
  content: '';
  position: absolute;
  inset: 1.5px;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  background: linear-gradient(160deg, #0d1a24, #0a1420);
  z-index: 0;
}
.dhtft-s18__icon svg { position: relative; z-index: 1; }

/* Vòng hex pulse */
.dhtft-s18__icon::after {
  content: '';
  position: absolute;
  inset: -5px;
  z-index: 0;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  background: linear-gradient(160deg, rgba(87,230,155,.5), transparent 65%);
  opacity: 0;
  animation: s18hex 2.4s ease-out infinite;
}
@keyframes s18hex {
  0%   { opacity: .75; transform: scale(.88); }
  70%  { opacity: 0;   transform: scale(1.12); }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .dhtft-s18__icon::after,
  .dhtft-s18__strip { animation: none; }
  .dhtft-s18__shine { display: none; }
}

.dhtft-s18__heading {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1 1 auto;
}

.dhtft-s18__title-row {
  display: flex;
  align-items: center;
  gap: 7px;
}

.dhtft-s18__title-row strong {
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 1.1px;
  line-height: 1.1;
  font-style: italic;
  text-transform: uppercase;
  background: linear-gradient(92deg, #f5deb6 15%, #d4b896 55%, #8ef0b8 115%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.dhtft-s18__badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 7px 3px 8px;
  clip-path: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%);
  color: #07130c;
  background: linear-gradient(120deg, #8ef0b8, #3fce82);
  font-size: 8px;
  font-weight: 900;
  font-style: normal;
  letter-spacing: 1px;
  line-height: 1;
  box-shadow: 0 0 12px rgba(87,230,155,.45);
}

.dhtft-s18__heading small {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(142,240,184,.6);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 2.2px;
  text-transform: uppercase;
  line-height: 1.2;
}
.dhtft-s18__heading small::before {
  content: '';
  width: 14px;
  height: 1px;
  background: linear-gradient(90deg, #57e69b, transparent);
}

.dhtft-s18__arrow {
  color: rgba(212,184,150,.55);
  flex: 0 0 auto;
  transition: transform .18s ease, color .18s ease;
}
.dhtft-s18__hero:hover .dhtft-s18__arrow,
.dhtft-s18__hero:focus .dhtft-s18__arrow {
  color: #f0d6ad;
  transform: translateX(3px);
}

/* 6 nút link — bố cục 2 cột, hai nút tải PBE nằm ở hàng cuối */
.dhtft-s18__links {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 11px 11px 12px;
}

.dhtft-s18__links a {
  --cut: 8px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  padding: 10px 6px 9px;
  min-height: 66px;
  min-width: 0;
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut));
  color: rgba(232,232,232,.8) !important;
  text-decoration: none !important;
  background: linear-gradient(165deg, rgba(255,255,255,.045), rgba(255,255,255,.015));
  font-size: 11px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: .25px;
  text-align: center;
  text-transform: uppercase;
  transition: transform .15s ease, background .15s ease, color .15s ease, box-shadow .15s ease;
}

/* Gạch chân neon của mỗi nút */
.dhtft-s18__links a::after {
  content: '';
  position: absolute;
  left: 20%;
  right: 20%;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #57e69b, transparent);
  opacity: .35;
  transition: opacity .15s ease, left .15s ease, right .15s ease;
}

.dhtft-s18__links a i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  font-style: normal;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
  color: #8ef0b8;
  background: rgba(87,230,155,.1);
  transition: color .15s ease, background .15s ease;
}

.dhtft-s18__links a:hover,
.dhtft-s18__links a:focus {
  color: #f0d6ad !important;
  background: linear-gradient(165deg, rgba(212,184,150,.13), rgba(212,184,150,.04));
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,.3), 0 0 12px rgba(240,214,173,.08);
  text-decoration: none !important;
}
.dhtft-s18__links a:hover::after,
.dhtft-s18__links a:focus::after {
  opacity: 1;
  left: 8%;
  right: 8%;
  background: linear-gradient(90deg, transparent, #f0d6ad, transparent);
}
.dhtft-s18__links a:hover i,
.dhtft-s18__links a:focus i {
  color: #f0d6ad;
  background: rgba(212,184,150,.12);
}

.dhtft-s18__links a svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

.dhtft-s18__links a.dhtft-s18__download {
  color: #eaf8ef !important;
  background: linear-gradient(165deg, rgba(87,230,155,.105), rgba(255,255,255,.018));
  box-shadow: inset 0 0 0 1px rgba(87,230,155,.12);
}
.dhtft-s18__links a.dhtft-s18__download--ios {
  color: #f3e5d0 !important;
  background: linear-gradient(165deg, rgba(212,184,150,.11), rgba(255,255,255,.018));
  box-shadow: inset 0 0 0 1px rgba(212,184,150,.12);
}
.dhtft-s18__links a.dhtft-s18__download--ios i {
  color: #f0d6ad;
  background: rgba(212,184,150,.1);
}

@media (max-width: 380px) {
  .dhtft-s18__links a {
    font-size: 10px;
    gap: 5px;
  }
}

/* ════════════════════════════
   PATCH SCHEDULE WIDGET
════════════════════════════ */

.dhtft-ps__countdown-wrap {
  padding: 14px 16px 10px;
  border-bottom: 1px solid var(--ps-border);
}

.dhtft-ps__countdown-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--ps-muted);
  margin-bottom: 10px;
}

.dhtft-ps__countdown {
  display: flex;
  align-items: center;
  gap: 6px;
}

.dhtft-ps__count-block {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.dhtft-ps__count-num {
  font-size: 32px;
  font-weight: 800;
  color: var(--ps-gold);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  letter-spacing: -1px;
}

.dhtft-ps__count-unit {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--ps-muted);
  text-transform: uppercase;
  padding-bottom: 2px;
}

.dhtft-ps__count-sep {
  font-size: 28px;
  font-weight: 700;
  color: var(--ps-gold-dim);
  line-height: 1;
  margin-bottom: 4px;
}

.dhtft-ps__list {
  list-style: none;
  margin: 0;
  padding: 8px 0 4px;
}

.dhtft-ps__item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  border-bottom: 1px solid rgba(255,255,255,.04);
  transition: background .18s;
}
.dhtft-ps__item:last-child { border-bottom: none; }
.dhtft-ps__item--live { background: rgba(34,197,94,.04); }
.dhtft-ps__item--future { opacity: .55; }

.dhtft-ps__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  position: relative;
}

.dhtft-ps__dot--live {
  background: var(--ps-live);
  box-shadow: 0 0 6px rgba(34,197,94,.5);
}

.dhtft-ps__dot-pulse {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid var(--ps-live);
  opacity: 0;
  animation: dhtft-ps-pulse 2s ease-out infinite;
}

@keyframes dhtft-ps-pulse {
  0%   { transform: scale(1); opacity: .6; }
  100% { transform: scale(2.2); opacity: 0; }
}

.dhtft-ps__dot--soon  { background: var(--ps-soon); box-shadow: 0 0 4px rgba(245,158,11,.35); }
.dhtft-ps__dot--future { background: rgba(255,255,255,.2); }

.dhtft-ps__info { flex: 1; min-width: 0; }

.dhtft-ps__patch-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.dhtft-ps__patch-row strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--ps-text);
  letter-spacing: .3px;
}

.dhtft-ps__item--live .dhtft-ps__patch-row strong { color: var(--ps-gold); }

.dhtft-ps__badge {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .8px;
  padding: 2px 7px;
  border-radius: 4px;
  text-transform: uppercase;
}

.dhtft-ps__badge--live {
  background: rgba(34,197,94,.15);
  color: #22c55e;
  border: 1px solid rgba(34,197,94,.25);
}

.dhtft-ps__badge--soon {
  background: rgba(245,158,11,.12);
  color: #f59e0b;
  border: 1px solid rgba(245,158,11,.2);
}

.dhtft-ps__date {
  font-size: 12px;
  color: var(--ps-muted);
}

/* ════════════════════════════
   RANDOM TIP WIDGET
════════════════════════════ */

.dhtft-rt__title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.dhtft-rt__title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--ps-gold);
}

.dhtft-rt__refresh {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  border: 1px solid var(--ps-border);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ps-muted);
  transition: all .2s;
  margin-left: auto;
}
.dhtft-rt__refresh:hover {
  border-color: rgba(212,184,150,.3);
  color: var(--ps-gold);
  background: rgba(212,184,150,.07);
}
.dhtft-rt__refresh.is-spinning svg {
  animation: dhtft-spin .5s linear infinite;
}
@keyframes dhtft-spin { to { transform: rotate(360deg); } }

.dhtft-rt__body {
  padding: 14px 16px 12px;
  transition: opacity .25s, transform .25s;
}
.dhtft-rt__body.is-loading {
  opacity: .3;
  transform: translateY(4px);
  pointer-events: none;
}

.dhtft-rt__icons {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-bottom: 10px;
}

.dhtft-rt__tip-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--ps-gold);
  margin: 0 0 6px;
  line-height: 1.35;
}

.dhtft-rt__excerpt {
  font-size: 13px;
  color: rgba(230,230,230,.65);
  line-height: 1.65;
  margin: 0 0 10px;
}

.dhtft-rt__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dhtft-rt__patch {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .6px;
  color: var(--ps-gold);
  background: rgba(212,184,150,.1);
  border: 1px solid rgba(212,184,150,.2);
  border-radius: 4px;
  padding: 1px 6px;
}

.dhtft-rt__source {
  font-size: 11px;
  color: var(--ps-muted);
}

.dhtft-rt__footer {
  padding: 10px 16px 12px;
  border-top: 1px solid var(--ps-border);
}

.dhtft-rt__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ps-gold-dim);
  text-decoration: none;
  transition: color .18s;
}
.dhtft-rt__link:hover {
  color: var(--ps-gold);
}

/* ── Compact widget spacing ── */
.bloghash-sidebar-inner .bloghash-widget,
.bloghash-sidebar-inner .widget {
  margin-bottom: 1.4rem !important;
}

.bloghash-sidebar-inner .widget-title,
.bloghash-sidebar-inner .h4.widget-title {
  font-size: 0.9rem !important;
  margin-bottom: 0.8rem !important;
}

/* ── Container wider + giảm padding 2 bên ── */
.bloghash-container,
.bloghash-container-fluid {
  padding: 0 2rem !important;
  max-width: 1680px !important;
}

.bloghash-header-container,
.bloghash-footer-container,
#bloghash-topbar .bloghash-container,
#bloghash-copyright .bloghash-container {
  padding: 0 2.5rem !important;
}

@media screen and (max-width: 1200px) {
  .bloghash-container,
  .bloghash-container-fluid {
    padding: 0 1.5rem !important;
  }
}


/* ═══════════════════════════════════════════════
   SIDEBAR OUTER WRAPPER — bỏ nền đặc xấu xí
   ═══════════════════════════════════════════════ */

/* Xoá background/border/padding của outer wrapper */
#secondary .bloghash-widget,
#secondary .widget {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

/* Sidebar nền: dot grid nhẹ tone vàng */
#secondary.bloghash-sidebar-container {
  background-image: radial-gradient(circle, rgba(212,184,150,.055) 1px, transparent 1px);
  background-size: 20px 20px;
  padding: 0 !important;
}

/* Gap giữa các widget */
#secondary .bloghash-sidebar-inner > .bloghash-widget,
#secondary .bloghash-sidebar-inner > .widget {
  margin-bottom: 16px !important;
}
#secondary .bloghash-sidebar-inner > .bloghash-widget:last-child,
#secondary .bloghash-sidebar-inner > .widget:last-child {
  margin-bottom: 0 !important;
}

/* Widget mặc định WP (Recent Posts, Archives...) — style card đơn giản */
#secondary .widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) .widget-title,
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) .widget-title,
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) .h4.widget-title {
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 1.8px !important;
  text-transform: uppercase !important;
  color: #d4b896 !important;
  padding: 10px 14px !important;
  margin: 0 0 0 0 !important;
  border-bottom: 1px solid rgba(212,184,150,.12) !important;
  background: rgba(212,184,150,.04) !important;
  border-radius: 10px 10px 0 0 !important;
}

/* Card wrap cho widget WP thường */
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)),
#secondary .widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) {
  background: #0c1020 !important;
  border: 1px solid rgba(212,184,150,.1) !important;
  border-radius: 10px !important;
  overflow: hidden !important;
  position: relative !important;
  padding: 0 !important;
}

/* Corner brackets cho widget WP thường */
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget))::before,
#secondary .widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget))::before {
  content: '';
  position: absolute;
  top: 6px; left: 6px;
  width: 13px; height: 13px;
  border-top: 2px solid #d4b896;
  border-left: 2px solid #d4b896;
  pointer-events: none;
  z-index: 2;
}

#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget))::after,
#secondary .widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget))::after {
  content: '';
  position: absolute;
  bottom: 6px; right: 6px;
  width: 13px; height: 13px;
  border-bottom: 2px solid #d4b896;
  border-right: 2px solid #d4b896;
  pointer-events: none;
  z-index: 2;
}

/* Nội dung bên trong widget WP thường */
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) ul,
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) form,
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) p {
  padding: 10px 14px !important;
  margin: 0 !important;
  font-size: 13px !important;
  color: rgba(230,230,230,.65) !important;
}

#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) ul li {
  padding: 5px 0 !important;
  border-bottom: 1px solid rgba(255,255,255,.04) !important;
  list-style: none !important;
}
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) ul li:last-child {
  border-bottom: none !important;
}
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) ul li a {
  color: rgba(230,230,230,.65) !important;
  text-decoration: none !important;
  transition: color .18s !important;
}
#secondary .bloghash-widget:not(:has(.dhtft-patch-schedule-widget)):not(:has(.dhtft-random-tip-widget)):not(:has(.dhtft-top-players-widget)):not(:has(.dhtft-set18-nav-widget)):not(:has(.dhtft-latest-posts-widget)) ul li a:hover {
  color: #d4b896 !important;
}


/* ════════════════════════════
   TOP PLAYERS RANKING WIDGET
════════════════════════════ */
.dhtft-tp__header {
  justify-content: space-between;
  min-height: 44px;
}

.dhtft-tp__title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.dhtft-tp__title {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--ps-gold);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dhtft-tp__mini-badge {
  flex: 0 0 auto;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .8px;
  color: rgba(212,184,150,.75);
  background: rgba(212,184,150,.08);
  border: 1px solid rgba(212,184,150,.14);
  border-radius: 999px;
  padding: 3px 7px;
}

.dhtft-tp__list {
  padding: 6px 0 4px;
}

.dhtft-tp__item {
  display: grid;
  grid-template-columns: 34px 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  padding: 9px 14px;
  color: var(--ps-text);
  text-decoration: none !important;
  border-bottom: 1px solid rgba(255,255,255,.045);
  transition: background .18s ease, transform .18s ease, border-color .18s ease;
}
.dhtft-tp__item:last-child { border-bottom: none; }
.dhtft-tp__item:hover {
  background: rgba(212,184,150,.055);
  transform: translateX(2px);
  text-decoration: none !important;
}

.dhtft-tp__rank {
  font-size: 13px;
  font-weight: 900;
  color: rgba(230,230,230,.9);
  font-variant-numeric: tabular-nums;
}
.dhtft-tp__item:nth-child(1) .dhtft-tp__rank { color: #f8d66d; }
.dhtft-tp__item:nth-child(2) .dhtft-tp__rank { color: #d7e2ef; }
.dhtft-tp__item:nth-child(3) .dhtft-tp__rank { color: #d59a62; }

.dhtft-tp__avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid rgba(212,184,150,.18);
  background: #070a13;
  box-shadow: 0 0 0 2px rgba(0,0,0,.18);
}

.dhtft-tp__main {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.dhtft-tp__name {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12.5px;
  line-height: 1.25;
  font-weight: 800;
  color: rgba(255,255,255,.92);
  text-decoration: none !important;
}
.dhtft-tp__item:hover .dhtft-tp__name { color: var(--ps-gold); }

.dhtft-tp__sub {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  font-size: 10.5px;
  font-weight: 700;
  color: rgba(230,230,230,.46);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dhtft-tp__rank-icon {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex: 0 0 auto;
  filter: drop-shadow(0 0 5px rgba(212,184,150,.24));
}

.dhtft-tp__lp {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  color: var(--ps-gold);
  font-size: 13px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}
.dhtft-tp__lp small {
  color: rgba(230,230,230,.45);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .4px;
}

.dhtft-tp__footer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px 12px;
  border-top: 1px solid var(--ps-border);
}

.dhtft-tp__all {
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 34px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(212,184,150,.16), rgba(212,184,150,.06));
  border: 1px solid rgba(212,184,150,.18);
  color: var(--ps-gold) !important;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none !important;
  transition: all .18s ease;
}
.dhtft-tp__all:hover {
  background: linear-gradient(135deg, rgba(212,184,150,.22), rgba(212,184,150,.09));
  border-color: rgba(212,184,150,.32);
  transform: translateY(-1px);
}

.dhtft-tp__search-toggle {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(212,184,150,.16);
  background: rgba(255,255,255,.02);
  color: rgba(212,184,150,.78);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all .18s ease;
}
.dhtft-tp__search-toggle:hover,
.dhtft-tp__search-toggle[aria-expanded="true"] {
  color: var(--ps-gold);
  border-color: rgba(212,184,150,.35);
  background: rgba(212,184,150,.09);
}

.dhtft-tp__search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 0 14px 14px;
  margin: 0;
}
.dhtft-tp__search[hidden] { display: none !important; }
.dhtft-tp__search input[type="text"] {
  width: 100%;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(212,184,150,.14);
  background: rgba(5,8,18,.55);
  color: rgba(255,255,255,.9);
  padding: 0 10px;
  font-size: 12px;
  outline: none;
}
.dhtft-tp__search input[type="text"]::placeholder { color: rgba(230,230,230,.36); }
.dhtft-tp__search input[type="text"]:focus {
  border-color: rgba(212,184,150,.38);
  box-shadow: 0 0 0 2px rgba(212,184,150,.08);
}
.dhtft-tp__search button[type="submit"] {
  height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid rgba(212,184,150,.22);
  background: rgba(212,184,150,.13);
  color: var(--ps-gold);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.dhtft-tp__msg {
  grid-column: 1 / -1;
  min-height: 14px;
  font-size: 11px;
  color: rgba(230,230,230,.5);
}

.dhtft-tp__empty {
  padding: 14px 16px;
  color: rgba(230,230,230,.62);
  font-size: 12.5px;
  line-height: 1.55;
}
.dhtft-tp__empty strong { color: var(--ps-gold); }

@media screen and (max-width: 480px) {
  .dhtft-tp__item {
    grid-template-columns: 30px 32px minmax(0, 1fr);
  }
  .dhtft-tp__lp { display: none; }
}


/* Auto refresh status for BXH Players */
.dhtft-top-players-widget.is-refreshing [data-dhtft-top-players-content] {
  opacity: .72;
  transition: opacity .18s ease;
}

.dhtft-tp__updated {
  padding: 0 14px 8px;
  margin-top: -1px;
  color: rgba(230,230,230,.34);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .2px;
  text-align: right;
}

/* Nút xem chi tiết riêng cho widget Lịch Cập Nhật.
   Scope theo .dhtft-patch-schedule-widget để không ảnh hưởng badge/header/widget khác. */
.dhtft-patch-schedule-widget .dhtft-ps__detail-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  margin-left: auto;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(212,184,150,.28);
  background: rgba(212,184,150,.07);
  color: var(--ps-gold);
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: .2px;
  text-decoration: none;
  white-space: nowrap;
  transition: background .18s, border-color .18s, color .18s, transform .18s;
}

.dhtft-patch-schedule-widget .dhtft-ps__detail-btn:hover,
.dhtft-patch-schedule-widget .dhtft-ps__detail-btn:focus {
  border-color: rgba(212,184,150,.5);
  background: rgba(212,184,150,.14);
  color: #f3d7ae;
  text-decoration: none;
  transform: translateY(-1px);
}

@media (max-width: 480px) {
  .dhtft-patch-schedule-widget .dhtft-ps__item {
    gap: 10px;
  }

  .dhtft-patch-schedule-widget .dhtft-ps__detail-btn {
    padding: 4px 7px;
    font-size: 9px;
  }
}

/* ════════════════════════════
   LATEST POSTS WIDGET — DESKTOP ONLY
════════════════════════════ */
.dhtft-latest-posts-widget {
  contain: layout paint;
  content-visibility: auto;
  contain-intrinsic-size: 390px;
}

.dhtft-lp__header {
  min-height: 44px;
}

.dhtft-lp__title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--ps-gold);
}

.dhtft-lp__list {
  list-style: none;
  padding: 5px 13px 8px;
  margin: 0;
}

.dhtft-lp__list > li {
  list-style: none;
  margin: 0;
  padding: 0;
  border-bottom: 1px solid rgba(255,255,255,.055);
}

.dhtft-lp__list > li:last-child {
  border-bottom: 0;
}

.dhtft-lp__item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 9px 0;
  color: var(--ps-text) !important;
  text-decoration: none !important;
}

.dhtft-lp__thumb {
  width: 72px;
  height: 52px;
  flex: 0 0 72px;
  display: block;
  overflow: hidden;
  border-radius: 7px;
  background: rgba(212,184,150,.055);
  border: 1px solid rgba(212,184,150,.11);
}

.dhtft-lp__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.001);
  transition: transform .22s ease, opacity .22s ease;
}

.dhtft-lp__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(212,184,150,.45);
  background:
    radial-gradient(circle at top right, rgba(212,184,150,.1), transparent 55%),
    #0a0e1c;
}

.dhtft-lp__content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  min-width: 0;
  flex: 1 1 auto;
}

.dhtft-lp__post-title {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-size: 13px;
  line-height: 1.38;
  font-weight: 650;
  color: rgba(238,238,238,.86);
  transition: color .18s ease;
}

.dhtft-lp__date {
  font-size: 10px;
  line-height: 1;
  color: var(--ps-muted);
  letter-spacing: .2px;
}

.dhtft-lp__item:hover .dhtft-lp__post-title,
.dhtft-lp__item:focus-visible .dhtft-lp__post-title {
  color: var(--ps-gold);
}

.dhtft-lp__item:hover .dhtft-lp__thumb img,
.dhtft-lp__item:focus-visible .dhtft-lp__thumb img {
  transform: scale(1.045);
  opacity: .92;
}

.dhtft-lp__item:focus-visible {
  outline: 1px solid rgba(212,184,150,.5);
  outline-offset: 4px;
  border-radius: 4px;
}

/* Chỉ hiện trên giao diện máy tính; không chiếm khoảng trống ở tablet/mobile. */
@media screen and (max-width: 991px) {
  #secondary .dhtft-latest-posts-sidebar-slot,
  #secondary .widget_dhtft_latest_posts,
  #secondary .dhtft-latest-posts-widget {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dhtft-lp__thumb img {
    transition: none;
  }
}

