
/* ===== WT Courses – Full Facelift (Dark) =====
   Includes: base facelift, countdown tiles, search z-index fix,
   thumbnail height fix, badges/progress/CTA polish.
   Safe drop-in for assets/css/frontend.css
*/

:root{
  --wtc-bg:#0d1117;
  --wtc-elev:#111827;
  --wtc-elev-2:#0b1220;
  --wtc-text:#e5e7eb;
  --wtc-text-dim:#9ca3af;
  --wtc-accent:#fbbf24;
  --wtc-accent-2:#22c55e;
  --wtc-danger:#ef4444;
  --wtc-border:#1f2937;
  --wtc-focus:#3b82f6;
}

/* Containers */
.wtc-container,.wtc-archive-template,.wtc-single-template,.wtc-grid-wrap{color:var(--wtc-text);}
.wtc-archive-template h1{font-size:clamp(28px,3.2vw,40px);font-weight:800;margin:12px 0 20px;letter-spacing:.2px}

/* Search */
.wtc-search{position:relative;margin:8px 0 18px;display:flex;gap:10px;align-items:center;z-index:20}
.wtc-search input[type="text"]{flex:1;height:46px;border-radius:12px;background:var(--wtc-elev);border:1px solid var(--wtc-border);color:var(--wtc-text);padding:0 44px 0 16px;outline:0;transition:box-shadow .2s,border-color .2s}
.wtc-search input[type="text"]::placeholder{color:var(--wtc-text-dim)}
.wtc-search input[type="text"]:focus{border-color:var(--wtc-focus);box-shadow:0 0 0 3px rgba(59,130,246,.25)}
.wtc-search .wtc-go,.wtc-search .wtc-clear{z-index:25;position:absolute;right:10px;width:32px;height:32px;border:0;border-radius:8px;cursor:pointer;background:transparent;color:var(--wtc-text-dim);display:grid;place-items:center;top:50%;transform:translateY(-50%);transition:color .2s,background .2s}
.wtc-search .wtc-clear{right:46px}
.wtc-search .wtc-go:hover,.wtc-search .wtc-clear:hover{color:var(--wtc-text);background:#ffffff0a}
.wtc-grid,.wtc-card{position:relative;z-index:1}

/* Grid */
.wtc-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
@media(max-width:900px){.wtc-grid{grid-template-columns:1fr}}

/* Card */
.wtc-card{background:linear-gradient(180deg,var(--wtc-elev-2),var(--wtc-elev));border:1px solid var(--wtc-border);border-radius:16px;overflow:hidden;box-shadow:0 10px 24px rgba(0,0,0,.25);transition:transform .18s ease,box-shadow .18s ease,border-color .18s}
.wtc-card:hover{transform:translateY(-2px);box-shadow:0 16px 36px rgba(0,0,0,.35);border-color:#2a3a52}

/* Thumbnail (fixed height to avoid giant cards) */
.wtc-thumb{position:relative;height:200px;overflow:hidden;border-bottom:1px solid var(--wtc-border);background:#0b0f14}
.wtc-thumb img{width:100%;height:100%;object-fit:cover;display:block;transition:transform .6s ease}
.wtc-card:hover .wtc-thumb img{transform:scale(1.04)}

/* Body */
.wtc-body{padding:14px 16px 16px}
.wtc-title{margin:6px 0 8px;font-weight:800;font-size:clamp(18px,2.2vw,22px);color:#ffde76}
.wtc-excerpt{color:var(--wtc-text-dim);font-size:14px;line-height:1.5;min-height:42px}

/* Badge */
.wtc-badge{display:inline-block;padding:4px 8px;font-size:12px;border-radius:9999px;line-height:1;background:#1b2a1e;color:var(--wtc-accent-2);border:1px solid #1f3d2a;margin:2px 0 6px}
.wtc-badge.free{background:#052e16;color:#22c55e;border:1px solid #166534}
.wtc-badge.paid{background:#3f1d1d;color:#f87171;border:1px solid #991b1b}

/* Progress bar on grid cards */
.wtc-progress{margin-top:8px;width:100%;height:8px;background:#1f2937;border-radius:9999px;overflow:hidden}
.wtc-progress-bar{height:100%;background:#2563eb}
.wtc-progress-label{font-size:12px;opacity:.85;margin-top:4px}

/* Progress thresholds */
.wtc-progress-bar.low{background:#2563eb}
.wtc-progress-bar.med{background:#f59e0b}
.wtc-progress-bar.high{background:#ef4444}

/* Countdown tiles (JS builds .wtc-clock-*) */
.wtc-countdown.wtc-clock .wtc-clock-wrap{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.wtc-countdown.wtc-clock .wtc-clock-box{background:#0a1322;border:1px solid var(--wtc-border);border-radius:12px;padding:8px 10px;min-width:64px;text-align:center;box-shadow:inset 0 0 0 1px rgba(255,255,255,.02)}
.wtc-countdown.wtc-clock .wtc-clock-num{font-size:20px;font-weight:800;color:#ffde76;letter-spacing:1px}
.wtc-countdown.wtc-clock .wtc-clock-label{font-size:11px;color:var(--wtc-text-dim);margin-top:2px}
.wtc-countdown.wtc-clock .wtc-clock-status{width:100%;font-size:12px;color:var(--wtc-text-dim);margin-top:4px}
.wtc-card.wtc-ended .wtc-countdown.wtc-clock .wtc-clock-num{color:var(--wtc-danger)}
.wtc-card.wtc-ended .wtc-countdown.wtc-clock .wtc-clock-status{color:var(--wtc-danger);font-weight:700}

/* Date line + status */
.wtc-dates{margin-top:10px;color:var(--wtc-text-dim);font-size:13px}
.wtc-status{margin:8px 0 0;font-size:13px}
.wtc-status.ended{color:var(--wtc-danger);font-weight:700}
.wtc-status.upcoming{color:var(--wtc-text-dim)}

/* CTA */
.wtc-actions{margin-top:14px}
.wtc-btn{display:inline-flex;align-items:center;justify-content:center;min-height:42px;padding:0 16px;border-radius:14px;border:1px solid #6b5606;background:linear-gradient(180deg,#f59e0b,#eab308);color:#1e1b04;font-weight:700;text-decoration:none;box-shadow:0 8px 18px rgba(234,179,8,.25);transition:transform .1s ease,box-shadow .15s ease,filter .2s ease}
.wtc-btn:hover{transform:translateY(-1px);box-shadow:0 12px 24px rgba(234,179,8,.32);filter:brightness(1.03)}
.wtc-btn:active{transform:translateY(0)}

/* Modal & form */
.wtc-modal .wtc-dialog{background:linear-gradient(180deg,var(--wtc-elev-2),var(--wtc-elev));border:1px solid var(--wtc-border);border-radius:16px;box-shadow:0 30px 60px rgba(0,0,0,.5)}
.wtc-form input,.wtc-form textarea{width:100%;background:#0e1626;border:1px solid var(--wtc-border);color:var(--wtc-text);border-radius:12px;padding:10px 12px;outline:0;margin-bottom:10px}
.wtc-form input:focus,.wtc-form textarea:focus{border-color:var(--wtc-focus);box-shadow:0 0 0 3px rgba(59,130,246,.25)}
.wtc-submit{height:42px;border-radius:12px;border:1px solid #6b5606;background:linear-gradient(180deg,#f59e0b,#eab308);color:#1e1b04;font-weight:700;width:100%;cursor:pointer}
.wtc-msg{margin-top:8px;font-size:13px;color:var(--wtc-text-dim)}

/* ===== Fix responsive GRID & overflow ===== */

/* 1) Grid tự căn cột theo bề rộng, không cứng 2 cột */
.wtc-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 18px;
  align-items: start;     /* tránh card kéo giãn vì nội dung trong */
  width: 100%;
}
@media (max-width: 480px){
  .wtc-grid{ grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
}

/* 2) Ngăn phần tử con đẩy vỡ cột vì min-content */
.wtc-grid > *{ min-width: 0; }

/* 3) Card dựng theo cột để CTA luôn dính đáy card */
.wtc-card{ display:flex; flex-direction: column; height:auto; }
.wtc-body{ flex: 1; display:flex; flex-direction: column; }
.wtc-actions{ margin-top: auto; }

/* 4) Ảnh & phần tử không tràn khung */
.wtc-thumb img{ display:block; width:100%; height:100%; object-fit: cover; }
.wtc-card, .wtc-grid{ max-width: 100%; overflow: hidden; }

/* 5) Nếu theme bên ngoài có float/flex lạ -> cô lập grid */
.wtc-grid-wrap{ isolation: isolate; }

/* ===== Polishing layout for balance ===== */

/* 0) Container canh giữa + giới hạn bề rộng, khoảng cách heading */
.wtc-archive-template { max-width: 1180px; margin: 28px auto; padding: 0 18px; }
.wtc-archive-template h1 { margin-bottom: 14px; }

/* 1) Grid tự co giãn mượt, gap hợp lý */
.wtc-grid{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 20px;
  align-items: start;
}
@media (max-width: 920px){ .wtc-grid{ grid-template-columns: repeat(auto-fit, minmax(300px,1fr)); gap:16px; }}

/* 2) Card đồng chiều cao + bóng/viền mềm */
.wtc-card{
  display:flex; flex-direction:column; height:auto;
  border-radius: 18px;
  box-shadow: 0 8px 20px rgba(0,0,0,.22);
  border: 1px solid #212b3b;
}
.wtc-thumb{ height: 190px; border-bottom: 1px solid #1f2937; border-top-left-radius:18px; border-top-right-radius:18px; }
@media (max-width: 920px){ .wtc-thumb{ height: 180px; }}

/* 3) Body gọn – nhịp chữ dễ đọc */
.wtc-body{ padding: 16px 18px 18px; display:flex; flex-direction:column; }
.wtc-title{ margin: 4px 0 6px; letter-spacing:.2px; }
.wtc-excerpt{ font-size: 14px; line-height: 1.55; margin-bottom: 8px; }

/* 4) Badge & meta canh đều */
.wtc-badge{ margin: 2px 0 10px; }

/* 5) Progress thanh mảnh hơn + nhãn sát nhau */
.wtc-progress{ margin: 10px 0 10px; }
.wtc-progress .meta{ font-size: 12px; gap: 10px; }

/* 6) Countdown “tile” nhỏ gọn, đều nhau */
.wtc-countdown.wtc-clock .wtc-clock-wrap{ gap: 8px; }
.wtc-countdown.wtc-clock .wtc-clock-box{ min-width: 66px; padding: 8px 10px; border-radius: 12px; }
.wtc-countdown.wtc-clock .wtc-clock-num{ font-size: 18px; }
.wtc-countdown.wtc-clock .wtc-clock-label{ font-size: 10.5px; }
.wtc-countdown.wtc-clock .wtc-clock-status{ margin-top: 6px; }

/* 7) Dòng ngày-giờ & trạng thái rõ ràng, không đẩy layout */
.wtc-dates{ margin-top: 8px; font-size: 13px; }
.wtc-status{ margin: 6px 0 0; }

/* 8) CTA full-width, cân mép và dính đáy card */
.wtc-actions{ margin-top: auto; }
.wtc-btn{
  width: 100%;
  min-height: 44px;
  border-radius: 14px;
  box-shadow: 0 10px 22px rgba(234,179,8,.26);
}

/* 9) Search bar – chiều cao & clickable hoàn hảo */
.wtc-search{ margin: 10px 0 18px; }
.wtc-search input[type="text"]{ height: 48px; }
.wtc-search .wtc-go, .wtc-search .wtc-clear{ width: 34px; height: 34px; }

/* 10) Tinh chỉnh hover nhẹ nhàng, không “giật” layout */
.wtc-card:hover{ transform: translateY(-1px); box-shadow: 0 14px 30px rgba(0,0,0,.28); }
.wtc-card:hover .wtc-thumb img{ transform: scale(1.03); }

/* 11) Ngăn mọi phần tử con làm tràn cột */
.wtc-grid > * { min-width: 0; }


/* ===== Single Course – Hero + Body ===== */

/* Container chung */
.wtc-single-template { max-width: 1180px; margin: 24px auto 32px; padding: 0 18px; }

/* Hero */
.wtc-single-hero-wrap { margin: 12px auto 20px; }
.wtc-single-hero{
  position: relative;
  height: clamp(240px, 36vw, 380px);
  border-radius: 20px;
  overflow: hidden;
  background: #0b0f14;
  background-image: var(--bg);
  background-size: cover;
  background-position: center;
  border: 1px solid #1f2937;
  box-shadow: 0 16px 42px rgba(0,0,0,.35);
}
.wtc-single-hero__overlay{
  position:absolute; inset:0;
  background: radial-gradient(120% 100% at 20% 0%, rgba(0,0,0,.55), rgba(0,0,0,.35) 40%, rgba(0,0,0,.15) 80%);
}
.wtc-single-hero__inner{
  position: absolute; inset: 0; display:flex; align-items:flex-end;
  padding: 28px; pointer-events:none;
}
.wtc-single-hero__title{
  margin: 0; padding: 10px 14px;
  font-weight: 800; letter-spacing:.2px;
  font-size: clamp(28px, 4vw, 44px);
  color: #ffde76;
  text-shadow: 0 2px 8px rgba(0,0,0,.55);
  background: linear-gradient(180deg, #0c1322cc, #0a101bcc);
  border: 1px solid #263044; border-radius: 14px;
}

/* Body dưới hero (nơi shortcode [wt_course] render) */
.wtc-single-body.container{ max-width: 980px; margin: 18px auto; }

/* Tinh chỉnh riêng cho phần chi tiết do shortcode xuất ra */
.wtc-single-body .wtc-card{ border-radius: 16px; }
.wtc-single-body .wtc-thumb{ height: 220px; }        /* ảnh đầu bài, đồng nhất */
.wtc-single-body .wtc-title{ font-size: clamp(20px,2.4vw,24px); }
.wtc-single-body .wtc-excerpt{ margin-bottom: 10px; }

/* Progress, countdown, dates cân đối hơn */
.wtc-single-body .wtc-progress{ margin: 12px 0 12px; }
.wtc-single-body .wtc-countdown.wtc-clock .wtc-clock-wrap{ gap:10px; }
.wtc-single-body .wtc-countdown.wtc-clock .wtc-clock-box{ min-width:70px; padding:9px 11px; }
.wtc-single-body .wtc-dates{ margin-top:10px; }

/* CTA full width và dính đáy card */
.wtc-single-body .wtc-actions{ margin-top:auto; }
.wtc-single-body .wtc-btn{ width:100%; min-height:46px; }

/* Responsive nhỏ */
@media (max-width: 760px){
  .wtc-single-hero__inner{ padding: 18px; }
  .wtc-single-hero__title{ font-size: clamp(22px, 6vw, 32px); }
  .wtc-single-body .wtc-thumb{ height: 190px; }
}

/* Ẩn ảnh trong card ở sidebar */
.wtc-col-right .wtc-thumb { display: none; }
/* Lưới 2 cột: trái nội dung, phải sidebar */
.wtc-single-2col {
  display: grid;
  grid-template-columns: minmax(0,1fr) 360px;
  gap: 32px;
  margin-top: 28px;
}
@media (max-width: 1024px) {
  .wtc-single-2col { grid-template-columns: 1fr; }
}

/* Cột trái: nội dung */
.wtc-col-left { font-size: 16px; line-height: 1.7; }
.wtc-col-left h2, .wtc-col-left h3 { margin-top: 20px; color: #ffde76; }

/* Cột phải: sticky card */
.wtc-col-right { position: relative; }
.wtc-col-right .wtc-sticky {
  position: sticky;
  top: 90px;     /* chỉnh theo header cao bao nhiêu */
}
.wtc-col-right .wtc-card {
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(0,0,0,.28);
}

.wtc-single-hero {
  height: clamp(200px, 30vw, 320px);
}
/* ===== Single – 2 cột cân đối + sidebar sticky gọn ===== */

/* Lưới 2 cột: trái co giãn, phải cố định */
.wtc-single-2col.container{ max-width:1180px; margin: 18px auto 40px; padding: 0 18px; }
.wtc-single-2col{
  display:grid;
  grid-template-columns: minmax(0, 1fr) 400px; /* cột phải 400px */
  gap: 32px;
  align-items:start;
}
@media (max-width: 1100px){ .wtc-single-2col{ grid-template-columns: 1fr; gap: 22px; }}

/* Cột trái – dễ đọc hơn */
.wtc-col-left{ max-width: 760px; }
.wtc-col-left > *:first-child{ margin-top: 0; }
.wtc-col-left p, .wtc-col-left li{ line-height: 1.8; font-size: 16px; }
.wtc-col-left h2, .wtc-col-left h3{ color:#ffde76; margin: 18px 0 8px; }

/* Cột phải – sticky + ẩn thumbnail để không lặp hero */
.wtc-col-right{ position: relative; }
.wtc-col-right .wtc-sticky{ position: sticky; top: 90px; } /* chỉnh theo chiều cao header */
.wtc-col-right .wtc-card{
  border-radius:16px; border:1px solid #212b3b;
  box-shadow:0 12px 28px rgba(0,0,0,.28);
}
.wtc-col-right .wtc-thumb{ display:none; }               /* ẩn ảnh to */
.wtc-col-right .wtc-body{ padding:16px 18px 18px; }
.wtc-col-right .wtc-title{ font-size:22px; margin:4px 0 8px; }
.wtc-col-right .wtc-excerpt{ font-size:14px; margin-bottom:10px; }

/* Countdown tile trong sidebar nhỏ gọn */
.wtc-col-right .wtc-countdown.wtc-clock .wtc-clock-box{ min-width:66px; padding:8px 10px; }

/* CTA: nút Đăng ký của form (class .wtc-submit) cùng style với .wtc-btn */
.wtc-col-right .wtc-submit{
  display:inline-flex; align-items:center; justify-content:center;
  width:100%; min-height:46px; cursor:pointer;
  border-radius:14px; border:1px solid #6b5606;
  background: linear-gradient(180deg, #f59e0b, #eab308);
  color:#1e1b04; font-weight:700;
  box-shadow:0 10px 22px rgba(234,179,8,.26);
  transition:transform .1s ease, box-shadow .15s ease, filter .2s ease;
}
.wtc-col-right .wtc-submit:hover{ transform:translateY(-1px); box-shadow:0 12px 26px rgba(234,179,8,.32); filter:brightness(1.03); }

/* Tinh khoảng cách dưới: ngày/giờ và CTA không bị dạt */
.wtc-col-right .wtc-actions{ margin-top: 12px; }

/* Hero thấp lại để đỡ chiếm màn hình */
.wtc-single-hero{ height: clamp(220px, 30vw, 320px); }

/* Đảm bảo form input đồng bộ dark theme trong sidebar */
.wtc-col-right .wtc-form input, 
.wtc-col-right .wtc-form textarea{
  width:100%; background:#0e1626; border:1px solid #1f2937; color:#e5e7eb;
  border-radius:12px; padding:10px 12px; margin-bottom:10px; outline:0;
}
.wtc-col-right .wtc-form input:focus, 
.wtc-col-right .wtc-form textarea:focus{
  border-color:#3b82f6; box-shadow:0 0 0 3px rgba(59,130,246,.25);
}

/* Sidebar card trong single: ẩn ảnh & làm gọn */
.wtc-col-right .wtc-thumb { display: none !important; }
.wtc-col-right .wtc-card { margin-top: 0; }
.wtc-col-right .wtc-body { padding-top: 14px; }

/* Sidebar card trong single course */
.wtc-col-right .wtc-card {
  border-radius: 16px;
  border: 1px solid #212b3b;
  box-shadow: 0 10px 26px rgba(0,0,0,.28);
  padding: 0;
}
.wtc-col-right .wtc-body {
  padding: 18px;
}
.wtc-col-right .wtc-title {
  font-size: 22px;
  margin-bottom: 8px;
  color: #ffde76;
}
.wtc-col-right .wtc-excerpt {
  font-size: 14px;
  margin-bottom: 12px;
  color: #9ca3af;
}
.wtc-col-right .wtc-body strong {
  color: #e5e7eb;
}

/* Nút submit đăng ký */
.wtc-col-right .wtc-submit {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 44px;
  margin-top: 12px;
  cursor: pointer;
  border-radius: 14px;
  border: 1px solid #6b5606;
  background: linear-gradient(180deg, #f59e0b, #eab308);
  color: #1e1b04;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(234,179,8,.25);
  transition: transform .1s ease, box-shadow .15s ease, filter .2s ease;
}
.wtc-col-right .wtc-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(234,179,8,.32);
  filter: brightness(1.03);
}

/* Nút Đăng ký trong single sidebar */
.wtc-col-right .wtc-submit {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 44px;
  margin-top: 12px;
  cursor: pointer;
  border-radius: 14px;
  border: 1px solid #6b5606;
  background: linear-gradient(180deg, #f59e0b, #eab308);
  color: #1e1b04;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(234,179,8,.25);
  transition: transform .1s ease, box-shadow .15s ease, filter .2s ease;
}
.wtc-col-right .wtc-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(234,179,8,.32);
  filter: brightness(1.03);
}

.wtc-col-right .wtc-card {
  padding: 0;
  border-radius: 16px;
  box-shadow: 0 10px 26px rgba(0,0,0,.28);
}
.wtc-col-right .wtc-body {
  padding: 18px;
}
.wtc-col-right .wtc-title {
  font-size: 22px;
  margin-bottom: 8px;
  color: #ffde76;
}
.wtc-col-right .wtc-excerpt {
  font-size: 14px;
  margin-bottom: 12px;
  color: #9ca3af;
}

.wtc-col-left {
  font-size: 16px;
  line-height: 1.75;
  max-width: 760px;
}
.wtc-col-left h2, .wtc-col-left h3 {
  margin-top: 22px;
  margin-bottom: 10px;
  color: #ffde76;
}
.wtc-col-left p {
  margin-bottom: 14px;
}

/* === WT Courses – Progress (track + fill + label) === */
.wtc-progress{
  position: relative;
  height: 8px;
  background: #0f172a;                /* track */
  border: 1px solid var(--wtc-border);
  border-radius: 999px;
  overflow: hidden;
  margin: 12px 0 10px;
}

.wtc-progress-bar{
  display: block;                      /* fill (đang có width:% inline) */
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb, #22d3ee);
  box-shadow: 0 0 8px rgba(37,99,235,.35) inset, 0 0 6px rgba(37,99,235,.35);
  transition: width .35s ease;
}

/* Label phía dưới thanh */
.wtc-progress-label{
  margin-top: 6px;
  font-size: 12px;
  color: var(--wtc-text-dim);
}

/* Sidebar (single page) tinh chỉnh nhẹ spacing */
.wtc-col-right .wtc-progress{ margin: 10px 0 12px; }


/* Progress thickness + colors by level */
.wtc-progress{ height:15px; margin:12px 0 8px; }
.wtc-progress-bar{ transition: width .35s ease; }

/* Mặc định (xanh dương) */
.wtc-progress-bar{ 
  background: linear-gradient(90deg,#2563eb,#22d3ee);
  box-shadow: inset 0 0 8px rgba(37,99,235,.35);
}

/* < 50% chỗ đã đăng ký */
.wtc-progress-bar.low{
  background: linear-gradient(90deg,#22c55e,#86efac);
  box-shadow: inset 0 0 8px rgba(34,197,94,.35);
}

/* 50–80% */
.wtc-progress-bar.med{
  background: linear-gradient(90deg,#f59e0b,#fbbf24);
  box-shadow: inset 0 0 8px rgba(245,158,11,.35);
}

/* > 80% (gần full) */
.wtc-progress-bar.high{
  background: linear-gradient(90deg,#ef4444,#f43f5e);
  box-shadow: inset 0 0 8px rgba(239,68,68,.35);
}

/* Ended state -> đỏ mờ + label cảnh báo */
.wtc-card.wtc-ended .wtc-progress-bar{
  background: linear-gradient(90deg,#7f1d1d,#ef4444);
  box-shadow: inset 0 0 6px rgba(239,68,68,.35);
}
.wtc-card.wtc-ended .wtc-progress-label{ color:#ef4444; font-weight:600; }

/* Nhãn dưới thanh: căn đều & chữ số đều hàng */
.wtc-progress-label{
  display:flex; justify-content:space-between; gap:8px;
  font-size:12px; color:var(--wtc-text-dim);
  font-variant-numeric: tabular-nums; /* số thẳng hàng */
}


/* % hiển thị ngay trong thanh, canh giữa */
.wtc-progress{ position: relative; }
.wtc-progress::after{
  content: attr(aria-valuenow) '%';
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700;
  color: #e5e7eb; text-shadow: 0 1px 2px rgba(0,0,0,.6);
  pointer-events: none;
}


/* ===== Single Course – 2 cột gọn đẹp + sticky card ===== */

/* Khung 2 cột */
.wtc-single-2col.container{max-width:1180px;margin:18px auto 40px;padding:0 18px}
.wtc-single-2col{display:grid;grid-template-columns:minmax(0,1fr) 400px;gap:32px;align-items:start}
@media (max-width:1100px){.wtc-single-2col{grid-template-columns:1fr;gap:22px}}

/* Cột trái: nội dung dễ đọc hơn */
.wtc-col-left{max-width:760px}
.wtc-col-left p,.wtc-col-left li{line-height:1.8;font-size:16px}
.wtc-col-left h2,.wtc-col-left h3{margin:20px 0 10px;color:#ffde76}

/* Hero (đỡ cao) */
.wtc-single-hero{height:clamp(220px,30vw,320px)}

/* Cột phải: sticky card */
.wtc-col-right{position:relative}
.wtc-col-right .wtc-sticky{position:sticky;top:90px} /* chỉnh theo chiều cao header của bạn */
@media (max-width:1100px){.wtc-col-right .wtc-sticky{position:static}}

/* Card trong sidebar – ẩn thumbnail để không lặp hero, padding đẹp hơn */
.wtc-col-right .wtc-thumb{display:none!important}
.wtc-col-right .wtc-card{border-radius:16px;border:1px solid #212b3b;box-shadow:0 10px 26px rgba(0,0,0,.28)}
.wtc-col-right .wtc-body{padding:18px}
.wtc-col-right .wtc-title{font-size:22px;margin:2px 0 8px;color:#ffde76}
.wtc-col-right .wtc-excerpt{font-size:14px;margin-bottom:10px;color:#9ca3af}

/* Meta dòng “Category/Time/Type” gọn gàng */
.wtc-col-right .wtc-body strong{color:#e5e7eb}
.wtc-col-right .wtc-body p{margin:.35rem 0}

/* Countdown căn giữa (nếu có) */
.wtc-col-right .wtc-countdown.wtc-clock{display:flex;justify-content:center}
.wtc-col-right .wtc-countdown.wtc-clock .wtc-clock-wrap{display:flex;justify-content:center;gap:10px;flex-wrap:wrap}
.wtc-col-right .wtc-countdown.wtc-clock .wtc-clock-box{min-width:66px;padding:8px 10px;text-align:center}

/* Progress: hiện lại + % nằm bên trong thanh (đọc từ aria-valuenow) */
.wtc-col-right .wtc-progress{position:relative;height:10px;background:#0f172a;border:1px solid var(--wtc-border);border-radius:999px;overflow:hidden;margin:10px 0 12px}
.wtc-col-right .wtc-progress::after{
  content: attr(aria-valuenow) '%'; position:absolute; inset:0;
  display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;
  color:#e5e7eb;text-shadow:0 1px 2px rgba(0,0,0,.6); pointer-events:none;
}
.wtc-col-right .wtc-progress-bar{
  display:block;height:100%;background:linear-gradient(90deg,#2563eb,#22d3ee);
  box-shadow:inset 0 0 8px rgba(37,99,235,.35);transition:width .35s ease
}
.wtc-col-right .wtc-progress-label{display:flex;justify-content:center;gap:12px;font-size:12px;color:var(--wtc-text-dim);margin-top:6px;font-variant-numeric:tabular-nums}

/* CTA: biến nút Đăng ký mặc định thành nút vàng, kể cả khi plugin không gán class */
.wtc-col-right .wtc-submit,
.wtc-col-right .wtc-body input[type=submit],
.wtc-col-right .wtc-body button[type=submit],
.wtc-col-right .wtc-body .button{
  display:inline-flex;justify-content:center;align-items:center;width:100%;min-height:46px;margin-top:12px;cursor:pointer;
  border-radius:14px;border:1px solid #6b5606;background:linear-gradient(180deg,#f59e0b,#eab308);
  color:#1e1b04;font-weight:700;box-shadow:0 8px 18px rgba(234,179,8,.25);
  transition:transform .1s ease,box-shadow .15s ease,filter .2s ease;text-decoration:none
}
.wtc-col-right .wtc-submit:hover,
.wtc-col-right .wtc-body input[type=submit]:hover,
.wtc-col-right .wtc-body button[type=submit]:hover,
.wtc-col-right .wtc-body .button:hover{
  transform:translateY(-1px);box-shadow:0 12px 24px rgba(234,179,8,.32);filter:brightness(1.03)
}

/* Form input đồng bộ dark */
.wtc-col-right .wtc-form input,.wtc-col-right .wtc-form textarea{
  width:100%;background:#0e1626;border:1px solid #1f2937;color:#e5e7eb;border-radius:12px;padding:10px 12px;margin-bottom:10px;outline:0
}
.wtc-col-right .wtc-form input:focus,.wtc-col-right .wtc-form textarea:focus{
  border-color:#3b82f6;box-shadow:0 0 0 3px rgba(59,130,246,.25)
}

/* === Single Course – polish sidebar === */

/* 1) Ẩn trigger mở modal và nút close 'x' dư thừa trong sidebar
      (giữ lại nút submit thật của form) */
.wtc-col-right .wtc-body > button:not(.wtc-submit),
.wtc-col-right .wtc-body > .button:not(.wtc-submit),
.wtc-col-right .wtc-body .wtc-open-modal,
.wtc-col-right .wtc-body .wtc-modal-close { 
  display: none !important; 
}

/* 2) Tiêu đề form & spacing */
.wtc-col-right .wtc-form h3{
  margin: 8px 0 12px;
  font-size: 18px;
  font-weight: 800;
  color: #ffde76;
}

/* 3) Field input đồng bộ chiều rộng & khoảng cách */
.wtc-col-right .wtc-form input,
.wtc-col-right .wtc-form textarea{
  width: 100%;
  background: #0e1626;
  border: 1px solid #1f2937;
  color: #e5e7eb;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 10px;
}

/* 4) CTA gửi đăng ký – đã style vàng, tinh thêm margin */
.wtc-col-right .wtc-submit{ margin-top: 14px; }

