/* ============================================================================
 * Pixelius — Video hướng dẫn (web 5.55.0)
 * Dùng chung: index.html (khối #huong-dan) + huong-dan.html. Nội dung vẽ từ js/huong-dan.js.
 * Biến màu/phông (--accent, --border, --mono…) lấy từ :root của trang chứa.
 * ========================================================================== */
.lp-guides[hidden], .gd-all[hidden] { display: none !important; }

.gd-feature { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 44px; align-items: start; }

/* Khung phát 16:9 — ảnh bìa + nút play; bấm mới nạp iframe YouTube (trang nhẹ, không tải script YouTube sẵn) */
.gd-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: #0d0d10;
  border: 1px solid var(--border-strong); box-shadow: 0 30px 80px rgba(0, 0, 0, .55); }
.gd-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.gd-player { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; margin: 0; border: 0;
  background: none; cursor: pointer; display: block; }
.gd-player img, .gd-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .45s ease, filter .3s ease; }
.gd-player:hover img, .gd-card:hover .gd-thumb img { transform: scale(1.02); filter: brightness(1.08); }
.gd-player:focus-visible { outline: 2px solid var(--accent); outline-offset: -4px; }
.gd-play { position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%;
  background: var(--accent); color: #0a0a0b; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 40px rgba(216, 254, 61, .35); transition: transform .2s ease; pointer-events: none; }
.gd-play svg { width: 30px; height: 30px; margin-left: 4px; }
.gd-player:hover .gd-play { transform: scale(1.08); }
.gd-dur { position: absolute; right: 12px; bottom: 12px; font-family: var(--mono); font-size: 12px; line-height: 1;
  color: #fff; background: rgba(0, 0, 0, .74); padding: 5px 8px; border-radius: 6px; pointer-events: none; }

/* Cột chữ */
.gd-meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.gd-cat { font-family: var(--mono); font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--accent);
  background: rgba(216, 254, 61, .08); border: 1px solid rgba(216, 254, 61, .2); padding: 5px 11px; border-radius: 999px; }
.gd-len, .gd-date { display: inline-flex; align-items: center; gap: 5px; font-family: var(--mono); font-size: 12px; color: var(--text-muted); }
.gd-len svg { width: 13px; height: 13px; }
.gd-info h3 { font-family: var(--sans); font-weight: 600; font-size: clamp(21px, 2.1vw, 27px); line-height: 1.25;
  letter-spacing: -.01em; color: var(--text); margin: 0 0 10px; }
.gd-info > p { font-size: 15.5px; line-height: 1.62; color: var(--text-muted); margin: 0 0 22px; }
.gd-chaps-h { font-family: var(--mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim); margin: 0 0 8px; }
.gd-chaps { list-style: none; margin: 0 0 24px; padding: 0; border-top: 1px solid var(--border); }
.gd-chaps li { border-bottom: 1px solid var(--border); }
.gd-chaps button { display: flex; gap: 14px; align-items: baseline; width: 100%; padding: 10px 6px; margin: 0; background: none; border: 0;
  color: var(--text); font-family: var(--sans); font-size: 14.5px; line-height: 1.4; text-align: left; cursor: pointer;
  transition: color .15s ease, background .15s ease; }
.gd-chaps button:hover { color: var(--accent); background: rgba(255, 255, 255, .025); }
.gd-chaps button:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.gd-chaps .gd-t { font-family: var(--mono); font-size: 12.5px; color: var(--accent); min-width: 40px; flex: 0 0 auto; }
.gd-actions { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.gd-yt { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-muted); text-decoration: none; transition: color .15s ease; }
.gd-yt:hover { color: var(--text); }
.gd-yt svg { width: 18px; height: 18px; }

/* Lưới thẻ video */
.gd-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin-top: 48px; }
.gd-card { display: block; text-decoration: none; color: inherit; background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 16px; overflow: hidden; transition: border-color .2s ease, transform .2s ease; }
.gd-card:hover { border-color: var(--border-strong); transform: translateY(-3px); }
.gd-card[aria-current="true"] { border-color: rgba(216, 254, 61, .45); }
.gd-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.gd-thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #0d0d10; }
.gd-thumb .gd-play { width: 48px; height: 48px; margin: -24px 0 0 -24px; opacity: .92; }
.gd-thumb .gd-play svg { width: 19px; height: 19px; margin-left: 3px; }
.gd-thumb .gd-dur { right: 10px; bottom: 10px; font-size: 11px; }
.gd-card-body { padding: 16px 18px 20px; }
.gd-card-body .gd-meta { margin-bottom: 10px; gap: 10px; }
.gd-card h4 { font-family: var(--sans); font-size: 16px; font-weight: 600; line-height: 1.38; color: var(--text); margin: 0; }

@media (max-width: 960px) {
  .gd-feature { grid-template-columns: 1fr; gap: 26px; }
  .gd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .gd-grid { grid-template-columns: 1fr; margin-top: 36px; }
  .gd-frame { border-radius: 12px; }
  .gd-play { width: 60px; height: 60px; margin: -30px 0 0 -30px; }
  .gd-play svg { width: 24px; height: 24px; }
  .gd-actions .lp-btn { flex: 1 1 100%; justify-content: center; }
}
