/* MeTravel — Video hành trình: trang tạo video (/lich-trinh/<mã>/video) và thẻ lối vào ở trang chuyến.
   Màu chỉ từ tokens.css (màu của chính video nằm trong JS, vẽ lên canvas).

   Phông dùng để VẼ VIDEO được tự host ở static/font/video/ (không phụ thuộc Google, hỗ trợ tiếng Việt
   đầy đủ — subset vietnamese + latin + latin-ext). Giấy phép SIL OFL, xem static/font/video/OFL.txt.
   Tên họ phông riêng ("MT Video …") để không lẫn với phông Google mà base.html nạp. */
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../font/video/sans-500-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../font/video/sans-500-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../font/video/sans-500-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../font/video/sans-600-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../font/video/sans-600-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../font/video/sans-600-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../font/video/sans-700-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../font/video/sans-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../font/video/sans-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 800; font-display: swap;
  src: url("../font/video/sans-800-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 800; font-display: swap;
  src: url("../font/video/sans-800-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "MT Video Sans"; font-style: normal; font-weight: 800; font-display: swap;
  src: url("../font/video/sans-800-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "MT Video Script"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url("../font/video/script-500-700-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "MT Video Script"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url("../font/video/script-500-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "MT Video Script"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url("../font/video/script-500-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "MT Video Serif"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../font/video/serif-700-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "MT Video Serif"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../font/video/serif-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "MT Video Serif"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../font/video/serif-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ---------- Thẻ lối vào ở trang chuyến ---------- */
.mt-vd-loi-vao { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 12px 0; padding: 12px 14px; border: 1px solid var(--mt-border); border-radius: 14px;
  background: var(--mt-primary-soft); }
.mt-vd-loi-vao[hidden] { display: none; }
.mt-vd-loi-vao-chu { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 220px; }
.mt-vd-loi-vao-chu strong { font-size: 15px; color: var(--mt-primary); }
.mt-vd-loi-vao-chu span { font-size: 13px; color: var(--mt-muted); line-height: 1.45; }
.mt-vd-loi-vao-nut { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--mt-primary); background: var(--mt-surface); color: var(--mt-primary); font-weight: 600; font-size: 14px; text-decoration: none; }
.mt-vd-loi-vao-nut:hover { background: var(--mt-primary); color: var(--mt-on-primary); }
.mt-vd-loi-vao-nut:focus-visible { outline: 3px solid var(--mt-gold); outline-offset: 2px; }

/* ---------- Trang tạo video ---------- */
.vd-trang { max-width: 1080px; margin: 0 auto; padding: 18px 16px 44px; color: var(--mt-text); }
.vd-quay-lai { display: inline-block; font-size: 14px; color: var(--mt-primary); text-decoration: none; margin-bottom: 10px; }
.vd-quay-lai:hover { text-decoration: underline; }
.vd-canh { display: inline-block; background: var(--mt-note-bg); color: var(--mt-note-text); font-size: 13px; padding: 6px 12px; border-radius: 999px; margin: 0 0 12px 8px; }
.vd-trang h1 { font-family: "Playfair Display", Georgia, serif; font-size: 30px; margin: 0 0 6px; color: var(--mt-primary); }
.vd-mo { color: var(--mt-muted); margin: 0 0 20px; line-height: 1.55; max-width: 740px; }
.vd-rong-diem { background: var(--mt-note-bg); color: var(--mt-note-text); border-radius: 16px; padding: 18px 20px; max-width: 560px; }
.vd-rong-diem h2 { margin: 0 0 6px; font-size: 17px; }
.vd-rong-diem p { margin: 0; line-height: 1.55; }
.vd-rong-diem[hidden], .vd-khung[hidden] { display: none; }

.vd-khung { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 22px; align-items: start; }
@media (max-width: 900px) { .vd-khung { grid-template-columns: 1fr; } }
.vd-xem { display: flex; flex-direction: column; align-items: center; gap: 12px; position: sticky; top: 12px; }
@media (max-width: 900px) { .vd-xem { position: static; } }
.vd-xem canvas { width: min(100%, 360px); aspect-ratio: 9 / 16; border-radius: 22px; box-shadow: 0 10px 30px rgba(0, 77, 67, .18); background: var(--mt-surface); }
.vd-thanh { width: min(100%, 360px); height: 6px; background: var(--mt-border); border-radius: 6px; overflow: hidden; }
.vd-thanh i { display: block; height: 100%; width: 0; background: var(--mt-primary); }
.vd-trangthai { font-size: 13px; color: var(--mt-muted); min-height: 20px; text-align: center; max-width: 360px; }
.vd-xem video { width: min(100%, 360px); border-radius: 16px; display: none; }

.vd-the { background: var(--mt-page); border: 1px solid var(--mt-border); border-radius: 18px; padding: 16px 18px; }
.vd-the + .vd-the { margin-top: 12px; }
.vd-the h2 { font-size: 15px; margin: 0 0 10px; color: var(--mt-primary); }
.vd-mau { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.vd-mau button { flex-direction: column; align-items: flex-start; border-radius: 14px; padding: 10px; gap: 2px; text-align: left; border: 1px solid var(--mt-border); background: var(--mt-surface); color: var(--mt-text); }
.vd-mau button b { font-size: 14px; }
.vd-mau button span { font-size: 11.5px; color: var(--mt-muted); line-height: 1.35; }
.vd-mau button[aria-pressed="true"] { border: 2px solid var(--mt-primary); background: var(--mt-primary-soft); }
.vd-bang { display: flex; gap: 8px; flex-wrap: wrap; }
.vd-bang button { width: 44px; height: 44px; border-radius: 50%; padding: 0; border: 2px solid var(--mt-surface); box-shadow: 0 0 0 1px var(--mt-border); }
.vd-bang button[aria-pressed="true"] { box-shadow: 0 0 0 3px var(--mt-primary); }
.vd-dong { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 14px; padding: 6px 0; }
.vd-trang input[type="text"], .vd-trang select { font: inherit; font-size: 14px; padding: 8px 10px; border: 1px solid var(--mt-border); border-radius: 10px; background: var(--mt-surface); color: var(--mt-text); min-height: 40px; }
.vd-dong input[type="text"], .vd-dong select { width: 190px; max-width: 55%; }
.vd-trang input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--mt-primary); }
.vd-trang button, .vd-nut { font: inherit; font-size: 14px; border-radius: 999px; padding: 9px 16px; min-height: 44px; cursor: pointer; border: 1px solid var(--mt-primary); background: var(--mt-surface); color: var(--mt-primary); display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.vd-trang button.vd-chinh { background: var(--mt-primary); color: var(--mt-on-primary); }
.vd-trang button:disabled { opacity: .5; cursor: not-allowed; }
.vd-trang button:focus-visible, .vd-nut:focus-within, .vd-nut:focus-visible, .vd-trang input:focus-visible, .vd-trang select:focus-visible, .vd-trang summary:focus-visible { outline: 3px solid var(--mt-gold); outline-offset: 2px; }
.vd-hang { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.vd-hang[hidden], .vd-trang button[hidden] { display: none; }
.vd-ghi { display: flex; flex-direction: column; gap: 6px; }
.vd-ghi label { font-size: 12.5px; color: var(--mt-muted); }
.vd-ghi input { width: 100%; margin-top: 3px; }
.vd-anh { list-style: none; padding: 0; margin: 8px 0 0; max-height: 280px; overflow: auto; }
.vd-anh li { display: flex; gap: 8px; align-items: center; padding: 6px 0; border-bottom: 1px dashed var(--mt-border); font-size: 13px; }
.vd-anh img { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; flex: none; }
.vd-anh select { font-size: 13px; flex: 1; min-width: 0; padding: 5px; }
.vd-anh .vd-bo { border: none; background: none; color: var(--mt-muted); padding: 4px 6px; font-size: 16px; min-width: 44px; }
.vd-nho { font-size: 12.5px; color: var(--mt-muted); line-height: 1.55; }
.vd-rong { font-size: 13px; color: var(--mt-muted); padding: 8px 0; }
.vd-trang input[type="file"] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.vd-trang details summary { cursor: pointer; font-size: 15px; font-weight: 600; color: var(--mt-primary); min-height: 32px; }
