/*
 * Màn hình danh sách seminar — mobile-first.
 *
 * CSS thuần, không framework, không build step: yêu cầu là copy nguyên thư mục
 * lên honban là chạy được.
 */

/*
 * Design token lấy TRỰC TIẾP từ CSS của honban
 * (seminar/css/ser.css, style-m.css, themes/jawhm.css, css/base_mobile.css)
 * để giao diện đồng nhất với phần còn lại của site.
 */
:root {
    --ink: #000000;          /* base_mobile.css dùng đen tuyền, không phải xám */
    --ink-soft: #666;
    --line: #d6d6d6;         /* xám viền của honban */
    --bg: #ffffff;           /* honban nền trắng, không phải xám nhạt */
    --navy: #262c6a;         /* màu thương hiệu: .lv-title, .top-title */
    --navy-edge: #62658c;    /* viền trên 3px — nét nhận diện đặc trưng */
    --navy-ink: #000034;     /* chữ tiêu đề mục */
    --accent: #fca84e;       /* .btn-ser_m — nút đăng ký cam */
    --box: #eeeeee;          /* nền .lv-box */
    --radius: 4px;           /* .lv-box dùng 4px, không phải 10px */
}

/*
 * KHÔNG dùng `*` toàn cục: trang này được chèn vào khung site chung
 * (include/header.php, menu.css, headhootg-nav.css…) — những file đó giả định
 * box-sizing mặc định (content-box) cho #header, #global-menu, sidebar…
 * Reset toàn cục sẽ làm lệch kích thước các khối đó dù ta không đụng vào chúng.
 * Chỉ scope vào phần nội dung + modal do trang này tự render.
 *
 * TRƯỚC ĐÂY scope là "#maincontent, #maincontent *" — #maincontent bao luôn
 * cả .sec-title (thanh tiêu đề xanh dùng chung toàn site, honban giả định
 * content-box: width 880px + padding 20px = 900px). Ép border-box lên nó làm
 * padding bị TRỪ VÀO 880px có sẵn, hụt mất 20px bên phải — lỗi masaki phát
 * hiện (2026-09-15, mục 13). Thu hẹp xuống đúng phần trang này tự vẽ:
 * .ns-page (nội dung + lịch + form), .ns-intro (đoạn giới thiệu đầu trang),
 * .modal (modal chi tiết/đặt chỗ JS tạo ra, gắn vào <body> nên nằm ngoài
 * #maincontent).
 */
.ns-page, .ns-page *,
.ns-intro, .ns-intro *,
.modal, .modal * { box-sizing: border-box; }

/*
 * KHÔNG đụng background của body: base.min.css đặt
 * `background-color:#fff; background-image:url(body-bg.jpg); background-repeat:repeat-x`
 * — dải ảnh navy lặp ngang đó chính là màu nền quanh header/banner/nav của
 * khung site chung. Set `background` (shorthand) ở đây sẽ xoá luôn ảnh nền
 * đó, làm mất dải navy — dùng #maincontent để giới hạn nền trắng vào đúng
 * phần nội dung seminar tự vẽ.
 */
body {
    margin: 0;
    color: var(--ink);
    /* Đúng stack của honban (css/base_mobile.css) */
    font-family: Verdana, Arial, Helvetica, sans-serif;
    line-height: 1.6;
}

#maincontent {
    background: var(--bg);
}

/* ---------- header ---------- */

/*
 * Viền trên 3px màu navy nhạt trên nền navy đậm là nét nhận diện đặc trưng
 * nhất của honban — xuất hiện trên mọi thanh tiêu đề (.lv-title, .top-title).
 */
.hd {
    background: var(--navy);
    border-top: 3px solid var(--navy-edge);
    color: #fff;
    padding: 12px 16px;
}

.hd__title {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
}

/* ---------- dải ngày ---------- */

/*
 * Honban gom seminar theo ngày bằng h3.title-date — dải cyan #00FFFF, chữ đen.
 * Sao lại đúng màu đó để khớp bản mobile hiện hành.
 */
.date-band {
    list-style: none;
    background: #00ffff;
    border: 1px solid #00ffff;
    color: #000;
    font-size: 14px;
    font-weight: 700;
    padding: 7px 12px;
    margin-top: 6px;
}

.date-band:first-child {
    margin-top: 0;
}

.wrap {
    max-width: 720px;
    margin: 0 auto;
    padding: 16px;
}

/*
 * Bản PC của honban là khung cố định 970px. Từ tablet trở lên nới ra cho khớp,
 * dưới ngưỡng này giữ nguyên bố cục mobile một cột.
 */
@media (min-width: 768px) {
    .wrap {
        max-width: 970px;
    }

    .card__title {
        font-size: 15px;
    }

    /* Trên màn rộng, nút đăng ký không cần kéo hết chiều ngang */
    .btn--apply {
        width: auto;
        min-width: 240px;
        margin-left: auto;
    }

    .card__cta {
        display: flex;
        justify-content: flex-end;
    }
}

/* ---------- bộ lọc ---------- */

.filter {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px;
    margin-bottom: 18px;
}

.filter__row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.filter__row--end {
    align-items: center;
    margin-bottom: 0;
}

.filter__field {
    flex: 1 1 160px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.filter__label {
    font-size: 12px;
    color: var(--ink-soft);
}

.filter__field input,
.filter__field select {
    padding: 9px 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    font-size: 15px; /* >=16px tránh iOS tự zoom; 15px + no-zoom meta là đủ */
    background: #fff;
}

/*
 * Override có chủ đích khi trang nhúng vào khung site.
 *
 * CSS legacy của jawhm (jawhm-form.css, base.min.css…) ép <select> và <label>
 * của form về 21.33px, khiến cả hàng lọc co về 0 và chữ xếp dọc ở mép phải.
 * Dùng !important vì đó là stylesheet lớn ta không kiểm soát và không nên sửa;
 * phạm vi giới hạn trong .filter nên không ảnh hưởng phần còn lại của site.
 */
.filter,
.filter .filter__row {
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
}

.filter .filter__field {
    float: none !important;
    min-width: 160px;
}

.filter .filter__field input,
.filter .filter__field select {
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
    height: auto !important;
    max-width: none !important;
}

/*
 * Select "会場選択" / "興味のある国選択" — sao đúng dạng pill của honban
 * (seminar/css/themes/jawhm.css .ui-btn-up-a: gradient trắng→#DDD2D2, viền
 * #f6eaea, bo góc 1em, chữ đậm căn giữa) thay vì <select> trần mặc định.
 * Vẽ nút mũi tên bằng CSS thay vì kéo cả jQuery Mobile chỉ để lấy 1 icon.
 */
.ns-select { margin-bottom: 14px; }

.ns-select__label {
    margin: 0 0 6px;
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
}

.ns-select__control { position: relative; }

.ns-select__control select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    display: block;
    margin: 0;
    padding: 11px 44px 11px 14px;
    border: 1px solid #f6eaea;
    border-radius: 1em;
    background: linear-gradient(180deg, #ffffff 0%, #ddd2d2 100%);
    color: #000;
    font-size: 15px; /* >=16px iOS auto-zoom là lý do cỡ chữ ở đây, giống .filter__field */
    font-weight: 700;
    text-align: center;
    text-align-last: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .1);
}

/*
 * text-align-last ở trên là để CĂN GIỮA giá trị đang chọn trên nút pill —
 * nhưng nó kế thừa xuống cả danh sách <option> khi mở dropdown, làm cả danh
 * sách bị căn giữa theo (khác con chính: danh sách luôn căn trái). Trả lại
 * text-align trái riêng cho <option>.
 */
.ns-select__control select option {
    text-align: left;
    text-align-last: left;
}

.ns-select__arrow {
    position: absolute;
    top: 50%;
    right: 8px;
    width: 24px;
    height: 24px;
    margin-top: -12px;
    border-radius: 50%;
    background: #f2f2f2;
    border: 1px solid #ccc;
    pointer-events: none;
}

.ns-select__arrow::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 8px;
    width: 8px;
    height: 8px;
    border-right: 2px solid #777;
    border-bottom: 2px solid #777;
    transform: rotate(45deg);
}

/* Cùng lý do override .filter__field bên dưới: CSS legacy của jawhm ép <select> co lại. */
.filter .ns-select select {
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
    height: auto !important;
    max-width: none !important;
}

.filter__check {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    margin-right: auto;
}

/* ---------- nút ---------- */

.btn {
    display: inline-block;
    padding: 9px 18px;
    border: 1px solid var(--navy);
    border-radius: 6px;
    font-size: 14px;
    text-decoration: none;
    cursor: pointer;
}

/* .btn-ser_m của honban: nền cam, chữ đen đậm, bo 5px */
.btn--primary {
    background: var(--accent);
    border-color: var(--accent);
    border-radius: 5px;
    color: #000;
    font-weight: 700;
}

.btn--ghost {
    background: #fff;
    color: var(--navy);
}

/* ---------- danh sách ---------- */

.count {
    margin: 0 0 10px;
    font-size: 13px;
    color: var(--ink-soft);
}

.list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 12px;
}

.card {
    position: relative;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}

.card__link {
    display: block;
    /* Chừa bên phải cho .card__badge (cờ/nhãn) khỏi đè lên giờ/tiêu đề */
    padding: 14px 52px 14px 14px;
    color: inherit;
    text-decoration: none;
}

/* Cờ/nhãn quốc gia ở góc phải thẻ, giống danh sách mobile của honban */
.card__badge {
    position: absolute;
    top: 14px;
    right: 14px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/*
 * メンバー限定セミナー — honban tô nổi bật hẳn (nền hồng nhạt + băng cam ở
 * đầu thẻ), không phải chip nhỏ chung dòng như các nhãn khác. Băng cam là
 * flow bình thường (không absolute) nên đẩy .card__badge xuống theo —
 * dịch top của badge xuống đúng bằng chiều cao băng + khoảng cách gốc.
 */
.card--member {
    background: #fbe4de;
    border-color: #f0b8a8;
}

.card--member .card__badge {
    top: 48px;
}

.card__memberband {
    margin: -14px -52px 10px -14px;
    padding: 7px 14px;
    background: #ef812d;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    text-align: center;
}

.card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 6px;
}

.card__date {
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
}

.card__title {
    margin: 0 0 10px;
    font-size: 16px;
    font-weight: 700;
}

.card__meta {
    margin: 0;
    font-size: 13px;
    color: var(--ink-soft);
    display: grid;
    gap: 2px;
}

.card__meta > div {
    display: flex;
    gap: 8px;
}

.card__meta dt {
    flex: 0 0 44px;
    margin: 0;
}

.card__meta dd {
    margin: 0;
}

/* ---------- dòng thông tin trên card (giống h3.time-place-seminar) ---------- */

.card__line {
    margin: 0 0 6px;
    font-size: 13px;
    color: var(--ink);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
}

/*
 * Cờ quốc gia — dùng lại đúng sprite của honban ở /css/images/.
 * Đường dẫn tuyệt đối từ gốc site, chạy được vì cùng domain.
 * 'wd' (toàn cầu/online) có kích thước riêng 32x21, không phải 16x16.
 */
.flag {
    display: inline-block;
    width: 16px;
    height: 16px;
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    flex: 0 0 auto;
}

.flag--au  { background-image: url(/css/images/au.png); }
.flag--nz  { background-image: url(/css/images/nz.png); }
.flag--uk  { background-image: url(/css/images/uk.png); }
.flag--ca  { background-image: url(/css/images/ca.png); }
.flag--de  { background-image: url(/css/images/de.png); }
.flag--dk  { background-image: url(/css/images/dk.png); }
.flag--fr  { background-image: url(/css/images/fr.png); }
.flag--ire { background-image: url(/css/images/ire.png); }
.flag--us  { background-image: url(/css/images/us.png); }
.flag--eu  { background-image: url(/css/images/eu.png); }

.flag--wd {
    width: 32px;
    height: 21px;
    background-image: url(/css/images/wd.png);
}

/* Nhãn nổi bật: sao おすすめ và 新着 — cũng là sprite của honban */
.mark {
    display: inline-block;
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    flex: 0 0 auto;
}

.mark--osusume {
    width: 18px;
    height: 18px;
    background-image: url(/css/images/hoshi.png);
}

.mark--shinchyaku {
    width: 25px;
    height: 14px;
    background-image: url(/css/images/new.png);
}

/* 中継対象 (livestream) — dùng cho .ns-legend, honban gọi đúng ảnh này */
.mark--camera {
    width: 18px;
    height: 14px;
    background-image: url(/css/images/camera.png);
}

.chip {
    background: #eef1f8;
    color: var(--navy);
    border-radius: 3px;
    padding: 1px 7px;
    font-size: 11px;
}

/* ---------- nút đăng ký (giống .btn-ser_m của honban) ---------- */

/*
 * width/float tường minh — cùng lý do với .filter, .calnav, .detail__head:
 * CSS legacy của jawhm bóp khối này còn ~170px và đẩy nó sang phải, khiến nút
 * rộng 240px tràn ngược lên đè chữ tiêu đề.
 */
.card__cta {
    display: block;
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
    padding: 0 14px 14px;
}

/*
 * float:none là bắt buộc, không phải để cho gọn.
 *
 * CSS legacy của jawhm float mọi <h2>. Phần tử float KHÔNG được tính vào chiều
 * cao thẻ cha, nên .card__link chỉ cao 58px trong khi tiêu đề chiếm tới 96px —
 * tiêu đề tràn ra ngoài và đè lên nút 申し込む bên dưới.
 *
 * margin cũng phải đặt lại: legacy cho h2 margin 20px/10px, quá rộng trong thẻ.
 */
.card__title {
    float: none !important;
    margin: 0 0 6px !important;
    overflow-wrap: anywhere;
    word-break: break-word;
}

/* Cùng lý do: .detail__title và .ev__title cũng là thẻ dễ bị legacy float */
.detail__title,
.ev__title { float: none !important; }

.btn--apply {
    display: block;
    width: 100%;
    box-sizing: border-box;
    background: var(--accent);
    border: 1px solid var(--accent);
    border-radius: 5px;
    padding: 10px 12px;
    color: #000;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
}

/* ---------- badge tình trạng chỗ ---------- */

.badge {
    flex: 0 0 auto;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.badge--ok      { background: #e7f5ec; color: #1b7a3d; }
.badge--few     { background: #fff3e0; color: #b26a00; }
.badge--full    { background: #fdecec; color: #b32020; }
.badge--wait    { background: #eef1f8; color: #3a4f8a; }
.badge--closed  { background: #eee;    color: #666;    }
.badge--unknown { background: #eee;    color: #666;    }

/* ---------- trạng thái rỗng / lỗi ---------- */

.alert,
.empty {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px;
    text-align: center;
    font-size: 14px;
}

.alert {
    border-color: #f0c2c2;
    background: #fdf6f6;
    color: #b32020;
}

/* ---------- trang chi tiết ---------- */

.back {
    margin: 0 0 12px;
    font-size: 14px;
}

.back a {
    color: var(--navy);
    text-decoration: none;
}

.detail {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px;
}

/*
 * width tường minh vì cùng lý do với .filter và .calnav: CSS legacy của jawhm
 * co các khối này về vài px và dồn ra mép phải, khiến ngày bị xếp dọc.
 */
.detail__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
    float: none;
    margin-bottom: 8px;
}

.detail__date,
.card__line,
.mitem__line {
    white-space: normal;
    word-break: normal;
}

.detail__date {
    flex: 0 0 auto;
}

.detail__date {
    font-size: 15px;
    font-weight: 700;
    color: var(--navy);
}

.detail__title {
    margin: 0 0 12px;
    font-size: 19px;
    font-weight: 700;
    line-height: 1.45;
}

.tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 14px;
    padding: 0;
}

.tag {
    background: #eef1f8;
    color: var(--navy);
    border-radius: 4px;
    padding: 3px 9px;
    font-size: 12px;
}

.detail__meta {
    margin: 0 0 16px;
    padding: 14px 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    font-size: 14px;
    display: grid;
    gap: 6px;
}

.detail__meta > div {
    display: flex;
    gap: 10px;
}

.detail__meta dt {
    flex: 0 0 56px;
    margin: 0;
    color: var(--ink-soft);
}

.detail__meta dd {
    margin: 0;
}

.maplink {
    margin-left: 8px;
    font-size: 13px;
    color: var(--navy);
}

/*
 * Nội dung do nhân viên soạn, đã lọc qua HtmlSanitizer phía Laravel.
 * Chặn ảnh và bảng tràn ra ngoài khung trên màn hình hẹp.
 */
/*
 * pre-line giữ lại các ký tự xuống dòng của dữ liệu gốc.
 *
 * Cột k_desc1 ngắt dòng bằng "\n" chứ không phải <br>, mà HTML gộp mọi khoảng
 * trắng nên toàn bộ nội dung dồn thành một khối chữ dày đặc. pre-line giữ dòng
 * mà vẫn gộp khoảng trắng thừa (khác pre-wrap, giữ luôn cả thụt lề).
 */
.detail__body {
    font-size: 15px;
    line-height: 1.85;
    white-space: pre-line;
    overflow-wrap: break-word;
}

/* Thẻ khối bên trong tự quản lý khoảng cách, không để pre-line sinh dòng trống */
.detail__body p,
.detail__body ul,
.detail__body ol,
.detail__body table,
.detail__body div {
    white-space: normal;
}

.detail__body img {
    max-width: 100%;
    height: auto;
}

.detail__body table {
    max-width: 100%;
    display: block;
    overflow-x: auto;
}

.detail__body a {
    color: var(--navy);
}

.detail__cta {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.note {
    margin: 0;
    text-align: center;
    font-size: 14px;
    color: var(--ink-soft);
}

/* ---------- phần dẫn nhập trên lịch ---------- */

/* .sec-title và .navy-dotted là class sẵn có của jawhm — cố tình không định
   nghĩa lại ở đây để chúng ăn theo style chung của site. */

.ns-intro {
    padding: 0 20px;
    font-size: 14px;
}

.ns-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0 6px;
}

.ns-cta img {
    max-width: 100%;
    height: auto;
    border: 0;
}

/* ---------- bộ lọc dạng pill (giống honban) ---------- */

.ns-lead {
    margin: 0 0 12px;
    font-size: 14px;
}

/* Khung viền cam bo góc bao mỗi nhóm bộ lọc */
.fbox {
    border: 2px solid #f39800;
    border-radius: 8px;
    padding: 10px 12px 12px;
    margin-bottom: 10px;
}

.fbox__title {
    margin: 0 0 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
}

.fbox__pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.fbox__note {
    margin: 0 0 12px;
    font-size: 12px;
    text-align: right;
}

/*
 * Pill là thẻ <a>, không phải nút JS: mỗi tổ hợp lọc có URL riêng nên chia sẻ
 * và đánh dấu được, và trang vẫn chạy khi tắt JavaScript.
 */
.pill {
    display: inline-block;
    background: linear-gradient(#f2f8ff, #d8e9fb);
    border: 1px solid #a9c7e8;
    border-radius: 5px;
    padding: 6px 12px;
    /* Khai báo cả hai để CSS của site không kéo màu chữ pill lệch nhau
       giữa các nhóm — trước đó nhóm 会場 hiện màu khác hai nhóm còn lại. */
    color: #14418c !important;
    font-size: 13px;
    font-weight: 400;
    text-decoration: none;
    white-space: nowrap;
}

.pill:hover { background: linear-gradient(#e8f2ff, #c8dff7); }

.pill.is-on {
    background: linear-gradient(#7fb2e5, #4a8fd4);
    border-color: #3f7cbd;
    color: #fff !important;
    font-weight: 700;
}

/* ---------- chú thích icon ---------- */

.fbox--legend { border-color: #f39800; }

/*
 * Tiêu đề + mô tả loại seminar đang lọc (vd. 語学学校セミナー). Tiêu đề chữ
 * đen (icon vẫn riêng theo loại), chỉ dòng mô tả tô màu theo ns_type_intro();
 * viền dưới ngăn với khung "アイコンの意味" giống ảnh mẫu.
 */
.type-intro {
    border-bottom: 1px solid var(--line);
    padding-bottom: 10px;
    margin-bottom: 14px;
}

.type-intro__title {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 4px;
    font-size: 16px;
    font-weight: 700;
    color: var(--ink);
}

.type-intro__desc {
    margin: 0;
    font-size: 13px;
    line-height: 1.6;
}

/* Khung "アイコンの意味" nền xanh nhạt, bo góc — khác .fbox--legend (viền cam) của bản PC */
.ns-legend {
    background: #eaf5fb;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 14px;
}

.ns-legend__title {
    margin: 0 0 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
}

.legend {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 28px;
    font-size: 12px;
}

.legend li {
    display: flex;
    align-items: center;
    gap: 5px;
}

.mark--full {
    width: 18px;
    height: 18px;
    background-image: url(/css/images/full.png);
}

.tag-chumoku {
    background: #e72582;
    color: #fff;
    border-radius: 3px;
    padding: 1px 6px;
    font-size: 11px;
    font-weight: 700;
}

/* ---------- lịch tuần ---------- */

.weekhead {
    margin: 18px 0 10px;
    color: #f39800;
    font-size: 26px;
    font-weight: 700;
}

.weeknav {
    margin: 14px 0;
    text-align: center;
}

/*
 * Nút chuyển tuần: dùng đúng ảnh nút của honban (jn_seminar.css
 * .jn_button_previous / .jn_button_next) để đồng bộ, thay vì tự vẽ bằng CSS.
 */
.weekbtn {
    display: inline-block;
    line-height: 0;
}

.weekbtn img {
    display: block;
    border-radius: 7px;
}

.weekbtn:hover img { opacity: .8; }

/* Trạng thái đang tải: mờ đi và chặn bấm tiếp cho khỏi gọi chồng nhau. */
.weekbtn.is-busy,
#weeks.is-busy { opacity: .5; pointer-events: none; }

/*
 * Overlay "セミナーを探しています…" khi đổi bộ lọc (applyFilter) — #weeks
 * cần position:relative để overlay định vị đúng theo nó, không theo cả trang.
 * Trước đây chỉ có opacity:.5 ở #weeks.is-busy, không có gì báo cho người
 * dùng biết trang đang tải chứ không phải bị treo.
 */
#weeks { position: relative; min-height: 80px; }

.ns-loading {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: rgba(255, 255, 255, .85);
}

#weeks.is-busy .ns-loading { display: flex; }

.ns-loading__spinner {
    width: 34px;
    height: 34px;
    border: 4px solid var(--box);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: ns-spin .7s linear infinite;
}

.ns-loading__text {
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
}

@keyframes ns-spin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    .ns-loading__spinner { animation-duration: 2.4s; }
}

.week { display: block; }

/*
 * Mỗi tuần là một <table> độc lập nên tuần nào cũng mang theo <thead> riêng.
 * Khi append/prepend nhiều tuần, hàng 日〜土 lặp lại giữa lịch.
 *
 * Chỉ giữ hàng thứ của tuần ĐẦU TIÊN. Dùng :first-child nên khi prepend tuần
 * mới lên đầu, hàng thứ tự động chuyển sang tuần đó — không cần JS.
 */
#weeks .week:not(:first-child) .week__table thead {
    display: none;
}

/* Các tuần nối tiếp nhau liền mạch, chỉ dùng viền xám như mọi hàng khác */
#weeks .week:not(:first-child) .week__cell {
    border-top: 1px solid #e6e6e6;
}

.week__table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
}

/*
 * Hàng thứ: bo góc trên, gradient cam, có vạch phân cách sáng giữa các cột.
 * Bản trước chỉ là ô cam phẳng viền 1px nên nhìn thô.
 */
/*
 * Dính lên đầu khi cuộn: sau khi tải thêm vài tuần, lịch dài ra và người dùng
 * mất mốc thứ nếu hàng này trôi mất.
 */
.week__wd {
    position: sticky;
    top: 0;
    z-index: 5;
    background: linear-gradient(180deg, #ffa54d 0%, #f7931e 60%, #ef8410 100%);
    border: 0;
    border-right: 1px solid rgba(255, 255, 255, .35);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: .3em;
    text-indent: .3em;
    padding: 9px 0;
    text-shadow: 0 1px 1px rgba(0, 0, 0, .2);
}

.week__wd:first-child { border-top-left-radius: 8px; }
.week__wd:last-child { border-right: 0; border-top-right-radius: 8px; }

/* Chủ nhật / thứ bảy nhạt màu chữ để phân biệt, vẫn đọc rõ trên nền cam */
.week__wd--0 { color: #fff0f0; }
.week__wd--6 { color: #eef6ff; }

.week__cell {
    background: #fff;
    border-right: 1px solid #e6e6e6;
    border-bottom: 1px solid #e6e6e6;
    vertical-align: top;
    padding: 7px 6px 12px;
    width: 14.28%;
}

.week__cell:last-child { border-right: 0; }
.week__cell.is-today { background: #fff8e8; }

.week__date {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 7px;
    padding-bottom: 4px;
    border-bottom: 1px solid #eee;
    font-size: 13px;
    font-weight: 700;
    color: #777;
}

.week__cell--0 .week__num { color: #d33; }
.week__cell--6 .week__num { color: #0b57a4; }

.week__todaytag {
    background: #d33;
    color: #fff;
    border-radius: 3px;
    padding: 1px 6px;
    font-size: 10px;
}

/* Giờ bắt đầu — honban hiện ngay trên tiêu đề trong mỗi ô */
.ev__time {
    display: block;
    margin-bottom: 2px;
    font-size: 12px;
    font-weight: 700;
}

.ev--painted .ev__time { color: #fff; }

/* Seminar đã hết chỗ: xám lại, không tô màu nhóm */
.ev--full {
    background: #f4f4f4;
    border-style: solid;
    border-color: #ddd;
    color: #888;
}

.tag-member {
    background: #6a4ea8;
    color: #fff;
    border-radius: 3px;
    padding: 1px 5px;
    font-size: 10px;
    font-weight: 700;
}

/* Thẻ seminar trong ô: trắng viền đứt, hoặc tô màu theo group_color */
.ev {
    display: block;
    border: 1px dashed #b5b5b5;
    border-radius: 3px;
    padding: 5px 6px;
    margin-bottom: 6px;
    color: var(--ink);
    font-size: 12px;
    line-height: 1.45;
    text-decoration: none;
}

/*
 * Hover phải thấy rõ: bản trước chỉ đổi màu viền, trên thẻ đã tô màu thì viền
 * gần như không thấy nên cảm giác như thẻ không bấm được.
 * Nhấc lên + đổ bóng + sáng thêm là tín hiệu nhìn ra ngay ở cả hai loại thẻ.
 */
.ev {
    position: relative;
    transition: transform .12s, box-shadow .12s, filter .12s;
}

/*
 * .is-hover đi kèm :hover để kiểm chứng được bằng automation — trạng thái
 * :hover không tồn tại khi chạy script qua CDP nên không thể đo trực tiếp.
 * Cũng dùng được cho điều hướng bằng bàn phím nếu cần sau này.
 */
/*
 * Hover phải nhìn ra ngay. Bản trước chỉ nhấc 2px và sáng 6% — quá nhẹ, trên
 * thẻ đã tô màu đậm thì gần như không thấy gì.
 *
 * Dùng !important vì CSS legacy của jawhm có nhiều rule cho `a:hover` và
 * `#maincontent a` với độ ưu tiên cao hơn; không ép thì thẻ trong lịch không
 * nhận được style hover nào.
 */
.ev:hover,
.ev.is-hover,
.ev:focus-visible {
    z-index: 3 !important;
    transform: translateY(-3px) scale(1.03) !important;
    box-shadow: 0 8px 18px rgba(0, 0, 0, .32) !important;
    filter: brightness(1.12) !important;
    outline: 2px solid var(--navy) !important;
    outline-offset: 1px;
    text-decoration: none !important;
}

.ev--painted {
    border-style: solid;
    border-color: rgba(0, 0, 0, .15);
    color: #fff;
}

.ev--painted .ev__title { color: #fff; }

.ev__icons {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 3px;
    margin-bottom: 3px;
}

.ev__title { display: block; }

/*
 * Tooltip khi hover thẻ seminar — sao lại đúng nội dung + viền màu của honban
 * (wz_tooltip: border = group_color, nền trắng, dòng ngày giờ rồi tới trích
 * đoạn mô tả). Honban dùng thư viện JS rời (wz_tooltip.js); ở đây tự vẽ bằng
 * assets/ev-tooltip.js cho gọn, không kéo thêm thư viện ngoài.
 */
.ev-tooltip {
    position: fixed;
    z-index: 60;
    max-width: 320px;
    background: #fff;
    border: 2px solid #999;
    border-radius: 3px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
    overflow: hidden;
    font-size: 13px;
    line-height: 1.6;
    color: #333;
    pointer-events: none;
}

.ev-tooltip[hidden] { display: none; }

/* Thanh tiêu đề tô màu nhóm (group_color) — giống TITLEBGCOLOR của wz_tooltip honban */
.ev-tooltip__title {
    margin: 0;
    padding: 6px 11px;
    background: #999;
    color: #fff;
    font-weight: 700;
}

.ev-tooltip__title:empty { display: none; }

.ev-tooltip__when {
    margin: 9px 11px 4px;
    color: var(--ink);
    font-weight: 700;
}

.ev-tooltip__body { margin: 0 11px 9px; }

/* Khung chọn khu vực — viền cam bo góc, giống form tìm kiếm của honban */
.areabox {
    border: 2px solid #f39800;
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 16px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 16px;
}

.areabox__title {
    width: 100%;
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: var(--navy);
}

.areabox__opt {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    white-space: nowrap;
}

.areabox__opt input {
    margin: 0;
}

.areabox .btn {
    margin-left: auto;
}

/* ---------- lịch tháng (bản PC) ---------- */

/*
 * width/box-sizing khai báo tường minh: CSS sẵn có của jawhm co <nav> lại còn
 * 16px và dồn về mép phải khi trang này nhúng vào khung site. Không dựa vào
 * chiều rộng mặc định của block nữa.
 */
.calnav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
    margin: 0 0 10px;
    float: none;
}

/* Chừa lề trong khung #maincontent cho khớp các trang khác của honban */
.ns-page {
    padding: 0 20px 24px;
    box-sizing: border-box;
}

.calnav__now {
    font-size: 17px;
    color: var(--navy);
}

.switch {
    margin: 0 0 12px;
    font-size: 13px;
    text-align: right;
}

.switch a { color: var(--navy); }

/*
 * Banner ガイドブック + box hỏi-đáp/khảo sát dưới lịch — sao lại đúng honban
 * (seminar.php + css/style-p.css: navy-dotted, area-btn-seminar,
 * btn-seminar-inquiry-1/2, area-seminar-inquiry-form).
 */
.guidebook-banner {
    margin: 16px 0;
    text-align: center;
}

.guidebook-banner img {
    max-width: 100%;
    height: auto;
}

.seminar-inquiry {
    border: 2px dotted navy;
    margin: 20px 0 10px;
    padding: 12px 16px;
    font-size: 14px;
    line-height: 1.7;
}

.seminar-inquiry__attn { margin: 10px 0; }

.seminar-inquiry__btnbox {
    max-width: 670px;
    margin: 10px auto;
}

.seminar-inquiry__btn {
    display: block;
    border-radius: 3px;
    text-align: center;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    text-decoration: none;
}

.seminar-inquiry__btn--blue {
    padding: 18px 0;
    border: 1px solid #2470bf;
    background: linear-gradient(#58a6f7, #2470bf);
}

.seminar-inquiry__btn--green {
    padding: 8px 0;
    border: 1px solid #81b602;
    background: linear-gradient(#a0d800, #81b602);
}

.seminar-inquiry__btn-sub {
    font-size: 12px;
    font-weight: 400;
    text-decoration: underline;
}

.seminar-inquiry__form {
    padding: 10px;
    margin-top: 4px;
    background-color: #fffcca;
}

.seminar-inquiry__form label { font-weight: 700; }

.seminar-inquiry__form select,
.seminar-inquiry__form input[type="text"] {
    font-size: 14px;
    padding: 4px 6px;
}

.seminar-inquiry__form textarea {
    width: 100%;
    max-width: 600px;
    height: 160px;
    box-sizing: border-box;
    margin-bottom: 4px;
    font-size: 14px;
}

.seminar-inquiry__form-message {
    color: #d33;
    font-weight: 700;
    font-size: 13px;
}

.seminar-inquiry__hint { font-size: 12px; }
.seminar-inquiry__hint--warn { color: #ff0000; }

.seminar-inquiry .si-req {
    font-weight: 700;
    font-size: 12px;
    color: #ff0000;
}

.seminar-inquiry__success-title {
    font-weight: 700;
    font-size: 15px;
}

.cal {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;   /* honban cũng dùng, giữ ô đều nhau */
    background: #fff;
    border: 1px solid var(--line);
}

.cal__wd {
    background: var(--navy);
    border-top: 3px solid var(--navy-edge);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    padding: 6px 0;
}

/* Chủ nhật đỏ, thứ bảy xanh — quy ước lịch Nhật */
.cal__wd--0 { color: #ffb3b3; }
.cal__wd--6 { color: #b3d4ff; }

.cal__cell {
    border: 1px solid var(--line);
    vertical-align: top;
    height: 74px;
    padding: 0;
}

.cal__cell--empty { background: #fafafa; }
.cal__cell--0 .cal__num { color: #c00; }
.cal__cell--6 .cal__num { color: #0b57a4; }
.cal__cell.is-today { background: #fffbe6; }

.cal__day {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    width: 100%;
    height: 100%;
    padding: 6px;
    background: none;
    border: 0;
    font: inherit;
    text-align: left;
}

button.cal__day.has-items {
    cursor: pointer;
    background: #fff8f0;
}

button.cal__day.has-items:hover {
    background: #ffefdc;
}

.cal__num {
    font-size: 13px;
    font-weight: 700;
}

.cal__count {
    background: var(--accent);
    border-radius: 100px;
    padding: 1px 8px;
    font-size: 11px;
    font-weight: 700;
    color: #000;
}

/* ---------- modal ngày ---------- */

.modal {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.modal[hidden] { display: none; }

.modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .5);
}

/* honban giới hạn modal ở 800px — giữ nguyên con số đó */
.modal__panel {
    position: relative;
    background: #fff;
    border-radius: var(--radius);
    width: 100%;
    max-width: 800px;
    max-height: 90vh;
    /*
     * KHÔNG để panel này tự cuộn (overflow-y:auto) — phần cuộn thật là
     * #ev-modal-body / .modal__body bên trong (xem chú thích ở đó).
     *
     * Có overflow-y:auto ở CẢ panel NGOÀI và body TRONG cùng lúc là hai
     * vùng cuộn lồng nhau: 90vh của panel và calc(90vh - 52px) của body
     * chỉ chênh đúng 52px (chiều cao header) trên lý thuyết, nhưng `vh`
     * trên mobile không ổn định (thanh địa chỉ Safari/Chrome co giãn làm
     * 100vh đổi giá trị theo thời điểm đo), nên có lúc panel NGOÀI cũng bị
     * dư ra vài px và trở thành vùng cuộn — trình duyệt bắt cử chỉ vuốt cho
     * panel (chỉ cuộn được vài px đó) thay vì body bên trong, làm cảm giác
     * "cuộn không tới được nút đặt chỗ" dù body vẫn còn cuộn được. Đây là
     * nguyên nhân thật của lỗi, không phải -webkit-overflow-scrolling.
     *
     * overflow: hidden ở panel loại hẳn khả năng đó — panel chỉ còn dùng để
     * bo góc + giới hạn max-height, không tranh chấp cuộn với body.
     */
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal__head {
    position: sticky;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--navy);
    border-top: 3px solid var(--navy-edge);
    color: #fff;
    padding: 10px 14px;
    font-size: 15px;
}

.modal__close {
    background: none;
    border: 0;
    color: #fff;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

/*
 * Thanh đầu modal chi tiết: đồng bộ với modal đặt chỗ — nền navy, chữ trắng,
 * nút đóng chỉ có dấu ×. Tiêu đề seminar dài nên cho phép xuống dòng, không
 * ép trên một hàng như modal đặt chỗ (tiêu đề đó ngắn, cố định).
 */
#ev-modal .modal__head strong {
    white-space: normal;
    line-height: 1.4;
    margin-right: 12px;
}

/*
 * Panel ngoài (.modal__panel) vốn overflow-y:auto — nếu để nó tự cuộn thì
 * scrollbar native đè lên góc bo tròn của header navy, cắt cụt mất một
 * mảnh (bug đã thấy trên Windows/Chrome). Cho #ev-modal-body tự cuộn thay
 * panel, giống cách modal đặt chỗ đang làm, để header luôn full width.
 */
#ev-modal-body {
    min-height: 0;
    flex: 1 1 auto;
    overflow-y: auto;
    /* KHÔNG thêm -webkit-overflow-scrolling: touch — xem chú thích ở .modal__panel. */
    overscroll-behavior: contain;
}

#ev-modal-body .detail {
    border: 0;
    padding: 18px 22px 24px;
}

/*
 * Ẩn hẳn (không chỉ giấu về mặt hình ảnh — JS vẫn đọc textContent của nó để
 * đặt tiêu đề thanh đầu modal, xem detail-modal.js render()): thanh đầu đã
 * hiện tên seminar rồi, lặp lại ngay trong nội dung là dư — dùng chung cho cả
 * PC và mobile vì cả hai đều dùng chung #ev-modal.
 */
#ev-modal-body .detail__title {
    display: none;
}

#ev-modal-body .back { display: none; }

.modal__list {
    list-style: none;
    margin: 0;
    padding: 14px;
    display: grid;
    gap: 12px;
}

.mitem {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 12px;
}

.mitem__line {
    margin: 0 0 6px;
    font-size: 13px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.mitem__title {
    display: block;
    margin-bottom: 10px;
    color: var(--ink);
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
}

/* ---------- chi tiết: khối thông báo + bảng thông tin ---------- */

/* Thanh dọc bên trái + nền nhạt, đọc là biết ngay đây là trạng thái */
.notice {
    margin: 0 0 18px;
    background: #f2f6fb;
    border-left: 4px solid #4a7fc1;
    border-radius: 2px;
    padding: 12px 14px;
    font-size: 14px;
    color: #33415c;
}

.notice--warn {
    background: #fff6ec;
    border-left-color: #f39800;
    color: #7a4a09;
}

.detail__h {
    margin: 22px 0 12px;
    padding-left: 9px;
    border-left: 4px solid var(--navy);
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
}

/* Bảng thông tin: mỗi dòng một gạch mảnh, nhãn cột trái cố định */
.spec {
    margin: 0 0 6px;
    border-top: 1px solid #e7e7e7;
}

.spec__row {
    display: flex;
    gap: 18px;
    align-items: baseline;
    border-bottom: 1px solid #e7e7e7;
    padding: 13px 4px;
}

.spec dt {
    flex: 0 0 90px;
    margin: 0;
    font-size: 13px;
    color: #6b7280;
}

.spec dd {
    flex: 1 1 auto;
    margin: 0;
    font-size: 15px;
}

.spec dd strong { font-weight: 700; }

.spec__note {
    margin-left: 6px;
    font-size: 13px;
    color: #6b7280;
}

/* Ghi chú phụ (link Zoom gửi sau) xuống dòng riêng cho dễ đọc */
.spec__sub {
    display: block;
    margin-top: 5px;
    font-size: 13px;
    color: #6b7280;
    line-height: 1.6;
}

.btn--disabled {
    display: block;
    width: 100%;
    box-sizing: border-box;
    background: #eef0f2;
    border: 1px solid #dfe3e6;
    border-radius: 6px;
    padding: 14px 12px;
    color: #98a0a8;
    font-size: 15px;
    font-weight: 700;
    text-align: center;
    cursor: not-allowed;
}

/* ---------- modal đặt chỗ ---------- */

/* Rộng hơn modal chi tiết: form có bảng 2 cột và 15 checkbox một hàng. */
.modal--booking .modal__panel { max-width: 960px; }

.modal--booking .modal__body {
    min-height: 0;
    flex: 1 1 auto;
    overflow-y: auto;
    /* KHÔNG thêm -webkit-overflow-scrolling: touch — xem chú thích ở .modal__panel. */
    overscroll-behavior: contain;
    padding: 16px 18px 20px;
}

/* Trong modal, khung viền của .yform là thừa — panel đã có viền rồi */
.modal--booking .yform {
    border: 0;
    padding: 0;
}

/* ---------- màn hình đặt chỗ (booking.php) ---------- */

.yform {
    border: 1px solid #999;
    padding: 18px 20px 22px;
    background: #fff;
}

.yform__lead {
    border: 1px solid #333;
    margin: 0 0 18px;
    padding: 7px 10px;
    text-align: center;
    font-size: 14px;
    font-weight: 700;
}

.yform__rules {
    margin: 0 0 18px;
    padding-left: 26px;
    font-size: 13.5px;
    line-height: 1.9;
}

.yform__rules li { margin-bottom: 14px; }

.yform__note {
    margin: 0 0 12px;
    font-size: 13.5px;
    line-height: 1.9;
}

/* Điều khoản huỷ — honban để đỏ vì đây là phần khách hay bỏ qua nhất */
.yform__warn {
    margin: 0 0 18px;
    color: #d00;
    font-size: 13.5px;
    line-height: 1.9;
}

.yform__actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    margin: 22px 0 0;
}

.ybtn {
    display: inline-block;
    border: 1px solid #b5b5b5;
    border-radius: 4px;
    background: linear-gradient(#fff, #e9e9e9);
    padding: 7px 20px;
    color: #222;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.ybtn:hover { background: linear-gradient(#fff, #dcdcdc); }

.ybtn--cancel { border-color: #d9534f; color: #c0392b; }
.ybtn--cancel:hover { background: linear-gradient(#fff, #fbe0df); }

.ybtn--next { border-color: #2470bf; color: #1a5490; }
.ybtn--next:hover { background: linear-gradient(#fff, #dceafd); }

.ybtn--submit {
    border-color: #e2761f;
    background: linear-gradient(#ffb877, #f5842c);
    padding: 11px 46px;
    color: #fff;
    font-size: 16px;
    text-shadow: 0 1px 1px rgba(0, 0, 0, .22);
}

.ybtn--submit:hover { filter: brightness(1.06); }

/* Khung "quên mật khẩu" dưới form đăng nhập メンバー限定セミナー */
.yform__hint {
    margin-top: 18px;
    padding: 12px 14px;
    border: 1px solid #dbe6f3;
    border-radius: 4px;
    background: #f2f6fb;
    text-align: center;
    font-size: 13px;
}

.yform__hint a { color: var(--navy); }

/* --- bảng nhập liệu --- */

.yhead {
    display: flex;
    align-items: stretch;
    margin-bottom: 16px;
    border: 1px solid #4a7fb5;
}

/* Rộng bằng .ytable th (210px) để mép trái của phần nội dung bên phải
   thẳng hàng xuống tới các hàng của bảng — khác thì nhãn "セミナー名" bị
   lệch so với các nhãn お名前/ふりがな/... ngay dưới. */
.yhead__label {
    flex: 0 0 210px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #4a7fb5;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
}

.yhead__value {
    flex: 1;
    background: #3f6fa0;
    color: #fff;
    padding: 12px 14px;
    font-size: 14px;
    line-height: 1.6;
}

/*
 * honban: background-color:LightPink; font-size:10pt; color:black;
 * font-weight:bold (ser.php:1713).
 *
 * Chia 2 cột trái/phải — nhãn "ご注意" rộng 210px THẲNG VỚI .yhead__label và
 * .ytable th ở trên/dưới, để mắt kéo một đường viền trái xuyên suốt cả form
 * chứ không riêng khối này lệch ra ngoài.
 */
.ynotice {
    display: flex;
    align-items: center;
    background-color: lightpink;
    font-size: 14px;
    color: #000;
    font-weight: 700;
    margin: 6px 0 16px;
    border: 2px solid #ff0000;
}

.ynotice__title {
    flex: 0 0 210px;
    padding: 10px 14px;
    color: #ff0000;
}

.ynotice__body {
    flex: 1;
    padding: 10px 14px 10px 0;
}

.ynotice a { color: #1a5490; }

@media (max-width: 700px) {
    .ynotice { display: block; padding: 10px 12px; }
    .ynotice__title { display: block; padding: 0; margin-bottom: 4px; }
    .ynotice__body { padding: 0; }
}

/* honban: .require-text (base_mobile.css:3933) — gradient #FD8B8B -> red, không phải màu đỏ bầm */
.ynreq {
    display: inline-block;
    background-image: linear-gradient(#fd8b8b, red);
    padding: 2px 6px;
    margin-left: 4px;
    border-radius: 3px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}

.ytable {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
}

.ytable th,
.ytable td {
    border: 1px solid #cfd8e3;
    padding: 11px 14px;
    text-align: left;
}

/*
 * Nhãn canh giữa theo chiều dọc.
 *
 * Trước để vertical-align:top nên với các hàng cao (15 checkbox nước, ô
 * アンケート) nhãn dính lên đỉnh còn nội dung trải dài xuống — nhìn rời rạc,
 * mắt không nối được nhãn với ô tương ứng.
 */
/*
 * Nhãn + badge 必須 nằm hai đầu ô, như honban. Dùng flex thay vì để badge trôi
 * ngay sau chữ: nhãn dài ngắn khác nhau nên badge sẽ so le, nhìn rất lộn xộn.
 */
.ytable th {
    width: 210px;
    background: #e4edf7;
    vertical-align: middle;
    font-weight: 700;
    line-height: 1.5;
}

/*
 * Badge 必須 ghim vào mép phải bằng position, KHÔNG dùng flex trên <th>.
 *
 * display:flex làm <th> thôi là table-cell, nên <td> rơi xuống dòng dưới và ô
 * nhập bị bóp lại — đúng lỗi vừa gặp. position giữ nguyên hành vi bảng.
 */
.ytable th {
    position: relative;
    padding-right: 62px;
}

.ytable th .ynreq {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    margin: 0;
}

/* Hai ô 姓/名 cạnh nhau */
.ypair {
    display: flex;
    gap: 10px;
}

.ypair input { flex: 1 1 0; min-width: 0; }

/* Checkbox メール会員 nằm ngay dưới ô email */
.ycheck-inline {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 9px;
    font-size: 13.5px;
}

.ycheck-inline input { width: auto !important; margin: 0; }

.yform__actions--single { gap: 0; }

.ytable td { vertical-align: middle; }

/* Hàng có nhiều khối con thì canh trên cho tự nhiên */
.ytable td:has(.ychecks),
.ytable td:has(textarea) { vertical-align: top; }

.ytable input[type="text"],
.ytable input[type="tel"],
.ytable input[type="email"],
.ytable input[type="password"],
.ytable textarea,
.ytable select {
    width: 100% !important;
    box-sizing: border-box !important;
    max-width: none !important;
    height: auto !important;
    float: none !important;
    padding: 7px 9px;
    border: 1px solid #b9c6d6;
    border-radius: 3px;
    font-size: 14px;
    font-family: inherit;
}

.ytable .ynum { width: 90px !important; }
.ytable .yzip { width: 220px !important; }
.ytable select { width: auto !important; min-width: 200px; }

.ytable input:focus,
.ytable textarea:focus,
.ytable select:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(38, 44, 106, .12);
}

/*
 * Form đăng nhập chỉ 2 nhãn ngắn — 210px mặc định để trống quá nhiều, nhưng
 * hẹp quá thì "メールアドレス"/"パスワード" bị xuống dòng (đã gặp ở 140px).
 * nowrap để chắc không bao giờ vỡ dòng dù còn hẹp hơn nữa.
 */
.ytable--login th {
    width: 170px;
    white-space: nowrap;
}

/*
 * Grid thay cho flex-wrap.
 *
 * flex-wrap co giãn theo độ dài nhãn nên các cột lệch nhau mỗi hàng một kiểu —
 * đó là thứ khiến khối 15 nước trông lộn xộn. Grid cố định 4 cột đều nhau,
 * mọi ô thẳng hàng bất kể nhãn dài ngắn.
 */
.ychecks {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 9px 12px;
}

.ychecks label {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    white-space: nowrap;
}

.ychecks input {
    width: auto !important;
    margin: 0;
    flex: 0 0 auto;
}

/* Câu hỏi 不安: 3 cột cho nhãn dài hơn */
.ychecks--2col { grid-template-columns: repeat(3, minmax(0, 1fr)); }

@media (max-width: 900px) {
    .ychecks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .ychecks--2col { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.yq {
    margin: 0 0 7px;
    font-size: 13.5px;
    font-weight: 700;
}

/* Câu hỏi thứ hai trong cùng ô cần khoảng thở với khối phía trên */
.yq:not(:first-child) { margin-top: 16px; }

.yq + textarea { margin-bottom: 4px; }

.ynote {
    margin: 6px 0 0;
    color: #666;
    font-size: 12px;
    line-height: 1.7;
}

.yfoot {
    margin-top: 16px;
    background: #eef3f9;
    padding: 12px 14px;
    font-size: 13px;
    line-height: 1.8;
}

.yfoot p { margin: 0 0 8px; }
.yfoot p:last-child { margin: 0; }

/* ---------- form đặt chỗ trên màn hẹp ---------- */

/*
 * Dưới 700px, bảng 2 cột không còn dùng được: cột nhãn cố định 210px ép chữ
 * xuống thành một ký tự mỗi dòng, còn ô nhập bị bóp lại vài chục pixel.
 *
 * Chuyển sang xếp chồng — nhãn thành một thanh trên, ô nhập full width bên
 * dưới. Đây là cách duy nhất giữ được cả nhãn lẫn ô nhập đọc được trên điện
 * thoại; thu nhỏ chữ chỉ làm cả hai cùng khó đọc.
 */
@media (max-width: 700px) {
    .modal--booking .modal__panel { max-width: 100%; border-radius: 0; }
    .modal--booking .modal__body { padding: 12px 12px 16px; }

    /* Tiêu đề seminar: nhãn nằm trên, tên seminar bên dưới */
    .yhead { display: block; }

    .yhead__label {
        display: block;
        padding: 7px 12px;
        font-size: 13px;
    }

    /*
     * Tiêu đề seminar phải ngắt được giữa chừng.
     *
     * Tên seminar là một chuỗi tiếng Nhật dài không có khoảng trắng, nên trình
     * duyệt không tìm ra chỗ ngắt và để nó tràn khỏi modal. anywhere cho phép
     * ngắt ở bất kỳ ký tự nào — với tiếng Nhật đó là cách xuống dòng bình thường.
     */
    .yhead__value {
        display: block;
        padding: 10px 12px;
        font-size: 13.5px;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .ytable,
    .ytable tbody,
    .ytable tr,
    .ytable th,
    .ytable td {
        display: block;
        width: auto;
    }

    .ytable tr {
        border: 1px solid #cfd8e3;
        border-radius: 4px;
        margin-bottom: 12px;
        overflow: hidden;
    }

    .ytable th,
    .ytable td { border: 0; }

    .ytable th {
        padding: 9px 12px;
        padding-right: 62px;    /* chừa chỗ cho badge 必須 */
        border-bottom: 1px solid #cfd8e3;
        font-size: 13.5px;
    }

    /* <br> trong nhãn là để xuống dòng ở bản PC, ở đây thừa */
    .ytable th br { display: none; }

    .ytable td { padding: 11px 12px; }

    /*
     * 姓/名 vẫn cạnh nhau — hai ô ngắn, xếp dọc chỉ tốn chiều cao.
     *
     * Phải viết `.ytable td.ypair`: `.ypair` chính là một <td>, mà quy tắc
     * `.ytable td { display: block }` ở trên có độ ưu tiên cao hơn `.ypair`
     * nên sẽ đè mất display:flex và hai ô rơi xuống hai dòng.
     */
    .ytable td.ypair {
        display: flex;
        gap: 8px;
    }

    .ytable td.ypair input { width: auto !important; }

    .ychecks { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .ychecks--2col { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ychecks label { white-space: normal; }

    .ytable select { width: 100% !important; min-width: 0; }

    .ybtn--submit { width: 100%; padding: 13px 20px; }

    /* Bảng lưu ý (bước 1) */
    .yform__rules { padding-left: 20px; font-size: 13px; }
    .yform__actions { gap: 12px; }
    .yform__actions .ybtn { flex: 1 1 0; text-align: center; }
}

/* ---------- form đặt chỗ ---------- */

.bookform {
    margin-top: 6px;
}

/*
 * Bẫy bot. Không dùng display:none — một số bot bỏ qua ô ẩn kiểu đó.
 * Đẩy ra ngoài khung nhìn để người thật không thấy, bot vẫn "thấy" và điền.
 */
.bookform__trap {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.bookform__row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0 0 12px;
    width: 100%;
    box-sizing: border-box;
}

.bookform__row > label {
    flex: 1 1 220px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 13px;
    color: var(--ink-soft);
}

.bookform__wide {
    flex: 1 1 100% !important;
}

.bookform input[type="text"],
.bookform input[type="tel"],
.bookform input[type="email"],
.bookform input[type="number"],
.bookform textarea {
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
    max-width: none !important;
    height: auto !important;
    padding: 9px 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    font-size: 15px;
    font-family: inherit;
}

.bookform__check {
    flex-direction: row !important;
    align-items: center;
    gap: 6px !important;
    color: var(--ink) !important;
}

.bookform__check input {
    width: auto !important;
    margin: 0;
}

/*
 * Nhãn của mỗi ô nhập nằm trong .lbl để badge 必須 ở cùng dòng chữ.
 * Trước đây badge là con trực tiếp của <label> (flex column) nên bị kéo giãn
 * thành một thanh đỏ dài suốt dòng.
 */
.lbl {
    display: block;
    font-size: 13px;
    color: var(--ink-soft);
}

.req {
    background: #b32020;
    color: #fff;
    border-radius: 3px;
    padding: 0 5px;
    margin-left: 4px;
    font-size: 10px;
    line-height: 1.6;
}

.booknum {
    margin: 14px 0;
    text-align: center;
    font-size: 16px;
}

.booknum strong {
    color: var(--navy);
    font-size: 20px;
}

/* ---------- nút もっと見る (bản mobile) ---------- */

.more {
    margin: 16px 0 4px;
    text-align: center;
}

/* Nút xanh viền trắng, bo góc — theo bản mobile của honban */
.morebtn {
    display: block;
    width: 100%;
    box-sizing: border-box;
    background: linear-gradient(180deg, #6cb6f5 0%, #3f97e8 100%);
    border: 3px solid #fff;
    border-radius: 10px;
    box-shadow: 0 0 0 1px #b9d8f4, 0 2px 4px rgba(0, 0, 0, .14);
    padding: 13px 20px;
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    text-shadow: 0 1px 1px rgba(0, 0, 0, .2);
}

.morebtn:hover { filter: brightness(1.06); }

.morebtn.is-busy {
    opacity: .6;
    pointer-events: none;
}

/* ---------- phân trang ---------- */

.pager {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-top: 18px;
}

.pager__pos {
    font-size: 13px;
    color: var(--ink-soft);
}
