/* =====================================================================
   CĂN LỀ & CỠ CHỮ CHUNG CHO TOÀN BỘ kyyeu.vn  (nạp sau cùng ở mọi loại trang)

   Ba quy tắc:
   1. Chữ chạy hết bề ngang khung rồi mới xuống dòng
      (không ngắt "cân đối", không giới hạn bề ngang theo số ký tự trên điện thoại).
   2. Một trục lề duy nhất: chữ, khung và ảnh cùng bắt đầu cách mép màn hình --le;
      đệm trong khung là --dem. Không cộng dồn nhiều lớp lề.
   3. Một thang cỡ chữ: tiêu đề trang > tiêu đề mục > tiêu đề nhỏ > nội dung > chú thích.
   ===================================================================== */
:root { --le: 12px; --dem: 14px; --bo: 14px; }
@media (min-width: 480px) { :root { --le: 18px; --dem: 18px; } }
@media (min-width: 768px) { :root { --le: 24px; --dem: 22px; --bo: 16px; } }

/* ---------- 1. Chữ xuống dòng bình thường ở mọi nơi ---------- */
html body * { text-wrap-style: auto !important; }

/* =====================================================================
   A. TRANG DÙNG KHUNG CHUNG (.kui): trang chủ, mẫu kỷ yếu, thiệp mời,
      kỷ yếu online, công cụ, chính sách
   ===================================================================== */
@media (max-width: 899.98px) {
  .kui-wrap { padding-left: var(--le); padding-right: var(--le); }
  .kui-tab { margin-left: calc(var(--le) * -1); margin-right: calc(var(--le) * -1); padding-left: var(--le); padding-right: var(--le); }
  .kui .kui-lead, .kui-noi-bat p, .kui-thu-bia p, .kui-co p, .kui-buoc p, .kui-hoi details p, .kui-cuoi p,
  .kui-muc-head, .kui-thu-head, .kui-thu-chu, .kcc .kcc-mo { max-width: none; }
}
@media (max-width: 640px) {
  /* Cỡ chữ */
  html body .kui .kui-h1, html body .kcc h1 { font-size: clamp(27px, 7.6vw, 32px) !important; line-height: 1.18 !important; margin-bottom: 12px; }
  html body .kui .kui-h2, html body .kui-tc-trang .kui-h2, html body .kui-home .kui-h2, html body .kui-home .kui-home-head .kui-h2 { font-size: clamp(22px, 6.1vw, 25px) !important; line-height: 1.24 !important; }
  html body .kui .kui-lead, html body .kui-tc-trang .kui-lead, html body .kui-home .kui-lead, html body .kui-home .kui-home-head .kui-lead { font-size: 16px !important; line-height: 1.65 !important; }
  html body .kui .kui-co h3, html body .kui .kui-buoc h3, html body .kui-tc-trang .kui-co h3 { font-size: 18.5px !important; line-height: 1.3 !important; }
  html body .kui .kui-co p, html body .kui .kui-buoc p, html body .kui-tc-trang .kui-co p { font-size: 15px !important; line-height: 1.6 !important; }
  html body .kui-home .kui-home-chu h3 { font-size: 20px !important; }
  .kui-the h3 { font-size: 16.5px; line-height: 1.28; }
  .kui-the p { font-size: 13.5px; line-height: 1.5; }
  .kui-eyebrow { margin-bottom: 8px; }
  /* Nhịp dọc gọn hơn */
  .kui-hero { padding: 26px 0 22px; }
  .kui-muc { padding: 30px 0; }
  .kui-cuoi { padding: 30px 0; }
  .kui-tc-trang .kui-tc, .kui-tc-trang .kui-home { padding: 30px 0 !important; }
  .kui-muc-head { margin-bottom: 14px; }
  /* Khung: đệm trong một mức */
  .kui-vd-link { padding: 16px var(--dem); }
  .kui-dk-the, .kui-ncc-the { padding: 16px var(--dem); border-radius: var(--bo); }
  .kui-noi-bat-in, .kui-cuoi-in { padding: 22px var(--dem); border-radius: var(--bo); }
  .kui-home-chu { padding: 14px var(--dem) 18px; }
  .kui-thu-bia { padding: 30px var(--dem); }
  .kui-thu-phan { padding: 20px var(--dem); }
  html body .kui-tc-trang a.kui-cc-the { padding: 16px var(--dem); border-radius: var(--bo); }
  .kui-chon-the { padding: 10px 12px 10px 10px; }
  .kui-co li { padding: 14px 0 14px 36px; }
  .kui-co li::before { top: 15px; font-size: 18px; }
  .kui-buoc li { padding: 14px 0 14px 46px; }
  .kui-buoc li::before { top: 14px; width: 32px; height: 32px; font-size: 14px; }
  .kui-tc-dv li { padding: 14px 0 12px 36px; }
  .kui-hoi summary { padding: 15px 34px 15px 0; }
  /* Nút chính chiếm trọn bề ngang để hai mép thẳng với khung */
  .kui-hero-actions .kui-btn { flex: 1 1 auto; }
  .kui-luoi { gap: 22px 12px; }
  .kui-tc-luoi { gap: 16px 12px; }
}

/* =====================================================================
   B. TRANG THƯỜNG, BÀI VIẾT, DANH MỤC (khung Blocksy)
   CSS cũ trong "CSS bổ sung" cộng dồn 3–4 lớp lề (và làm bài viết lệch trái 40px / phải 8px).
   Ở đây gỡ hết các lớp trung gian, chỉ giữ MỘT lề --le ở .entry-content / đầu trang.
   ===================================================================== */
@media (max-width: 767.98px) {
  html body #main#main > [class*="ct-container"],
  html body #main#main > [class*="ct-container"] > article,
  html body #main#main > [class*="ct-container"] > section,
  html body #main#main .hero-section,
  html body #main#main .hero-section > [class*="ct-container"],
  html body #main#main .entry-content > .article-content,
  html body #main#main .entry-content > .article-detail,
  html body #main#main .entry-content > .article-detail > .mb-3,
  html body #main#main .entry-content .article-detail .article-content {
    box-sizing: border-box !important; width: auto !important; max-width: none !important;
    margin-left: 0 !important; margin-right: 0 !important; padding-left: 0 !important; padding-right: 0 !important;
  }
  html body #main#main .entry-content,
  html body #main#main .hero-section .entry-header,
  html body #main#main > [class*="ct-container"] > section > .entries,
  html body #main#main > [class*="ct-container"] > .entries,
  html body #main#main .ct-pagination, html body #main#main .ct-related-posts-container, html body #main#main .post-navigation, html body #main#main .ct-no-results, html body #main#main .entry-tags {
    box-sizing: border-box !important; width: auto !important; max-width: none !important;
    margin-left: 0 !important; margin-right: 0 !important; padding-left: var(--le) !important; padding-right: var(--le) !important;
  }

  /* ----- Cỡ chữ ----- */
  html body #main#main .hero-section .page-title, html body #main#main .entry-content > h1 { font-size: clamp(26px, 7.4vw, 31px) !important; line-height: 1.2 !important; letter-spacing: -.005em !important; }
  html body #main#main .entry-content h2:not(.kui *, .kui-tc-trang *, .kui-home *) { font-size: clamp(21px, 5.9vw, 24px) !important; line-height: 1.28 !important; }
  html body #main#main .entry-content h3:not(.kui *, .kui-tc-trang *, .kui-home *) { font-size: 19px !important; line-height: 1.32 !important; }
  html body #main#main .entry-content h4:not(.kui *, .kui-tc-trang *, .kui-home *) { font-size: 17px !important; line-height: 1.35 !important; }
  html body #main#main .entry-content :is(p, li):not(.kui *, .kui-tc-trang *, .kui-home *, [class] > *) { font-size: 16px; line-height: 1.68; }
  html body #main#main .entry-content :is(ul, ol):not([class]) { padding-left: 22px !important; }

  /* ----- Ảnh trong bài: trọn bề ngang, cùng trục với chữ ----- */
  html body #main#main .entry-content :is(figure, .wp-block-image) { margin-left: 0 !important; margin-right: 0 !important; padding: 0 !important; max-width: none !important; }
  html body #main#main .entry-content :is(figure.wp-block-image, p) > img, html body #main#main .entry-content figure.wp-block-image > a > img { display: block; width: 100% !important; max-width: 100% !important; height: auto; margin-left: 0 !important; margin-right: 0 !important; border-radius: var(--bo) !important; }
  html body #main#main .hero-section > figure { margin: 0 var(--le) !important; }

  /* ----- Thẻ bài viết trong danh mục ----- */
  html body #main#main .entries > article.entry-card { padding: var(--dem) !important; border-radius: var(--bo) !important; }
  html body #main#main .entries > article.entry-card .entry-title { font-size: 19px !important; line-height: 1.32 !important; }
  html body #main#main .entries > article.entry-card .entry-excerpt, html body #main#main .entries > article.entry-card .entry-excerpt p { font-size: 15px !important; line-height: 1.6 !important; }
  html body #main#main .entries { gap: 12px !important; }
}

@media (max-width: 767.98px) {
  /* Khối con trực tiếp của nội dung trang: không tự thụt thêm (Blocksy "constrained" + CSS cũ) */
  html body #main#main .entry-content.is-layout-constrained > *:not(.alignfull) { box-sizing: border-box !important; width: auto !important; max-width: none !important; margin-left: 0 !important; margin-right: 0 !important; }
  /* Trang chủ: các dải nền chạy trọn bề ngang, mỗi dải tự giữ lề --le */
  html body.home #main#main .entry-content { padding-left: 0 !important; padding-right: 0 !important; }
  html body .kui-tc-trang :is(h2, h3), html body .kui-home :is(h2, h3) { padding-left: 0 !important; margin-left: 0 !important; border-left: 0 !important; }
  html body.home .chovinh-home-v2 .cv-hero { padding-left: var(--le) !important; padding-right: var(--le) !important; padding-top: 26px !important; }
  html body.home #main#main .cv-hero .cv-actions { display: grid !important; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important; gap: 10px !important; width: auto !important; }
  html body.home #main#main .cv-hero .cv-actions > a { width: auto !important; min-width: 0 !important; margin: 0 !important; padding-left: 8px !important; padding-right: 8px !important; text-align: center !important; justify-content: center !important; white-space: nowrap; font-size: 14.5px !important; letter-spacing: 0 !important; }
  html body.home .cv-hero__caption { left: var(--dem) !important; right: var(--dem) !important; width: auto !important; }
  html body.home .ky-lookup, html body.home .ky-lookup.cv-section { margin-left: var(--le) !important; margin-right: var(--le) !important; padding-left: var(--dem) !important; padding-right: var(--dem) !important; width: auto !important; max-width: none !important; box-sizing: border-box !important; }
  html body.home .ky-lookup h2 { padding-left: 0 !important; border-left: 0 !important; }
  html body.home .ky-lookup__form, html body.home .ky-lookup__head { padding-left: 0 !important; padding-right: 0 !important; margin-left: 0 !important; margin-right: 0 !important; }

  /* ----- Đầu trang danh mục / tìm kiếm: gọn, chữ thẳng một trục ----- */
  html body #main#main .hero-section[data-type="type-2"] > .entry-header { min-height: 0 !important; padding-top: 30px !important; padding-bottom: 24px !important; text-align: left !important; align-items: flex-start !important; }
  html body #main#main .hero-section .page-title { padding-left: 0 !important; padding-right: 0 !important; margin-left: 0 !important; margin-right: 0 !important; }
  html body #main#main .hero-section .ct-breadcrumbs { justify-content: flex-start !important; text-align: left !important; margin-left: 0 !important; padding-left: 0 !important; }
  /* Bài viết: mục cuối của đường dẫn lặp lại đúng tiêu đề ngay bên dưới nên ẩn đi */
  html body.single-post #main#main .hero-section .ct-breadcrumbs .last-item { display: none !important; }
  html body.single-post #main#main .hero-section .ct-breadcrumbs > span:nth-last-child(2) > .ct-separator, html body.single-post #main#main .hero-section .ct-breadcrumbs > span:nth-last-child(2) > svg { display: none !important; }
  html body:not(.single-post) #main#main .hero-section[data-type="type-2"] { min-height: 0 !important; padding-top: 0 !important; padding-bottom: 0 !important; --min-height: 0px; }
  html body #main#main .hero-section .entry-meta { justify-content: flex-start !important; }
  html body #main#main .hero-section.is-width-constrained { padding: 22px var(--le) 6px !important; }
  html body #main#main .hero-section.is-width-constrained .entry-header { padding-left: 0 !important; padding-right: 0 !important; }

  /* ----- Đầu bài viết: ảnh trọn bề ngang ở trên, tiêu đề chữ đậm màu ở dưới (không đè chữ lên ảnh) ----- */
  html body.single-post #main#main .hero-section[data-type="type-2"] { display: flex !important; flex-direction: column !important; background: none !important; min-height: 0 !important; padding: 0 !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > figure { position: relative !important; inset: auto !important; order: 1; box-sizing: border-box !important; width: auto !important; height: auto !important; min-height: 0 !important; max-height: none !important; margin: var(--le) var(--le) 0 !important; aspect-ratio: 16 / 10; border-radius: var(--bo) !important; overflow: hidden !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > figure::after { content: none !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > figure .ct-media-container { position: absolute !important; inset: 0 !important; width: 100% !important; height: 100% !important; border-radius: 0 !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > figure img { width: 100% !important; height: 100% !important; object-fit: cover !important; border-radius: 0 !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > .entry-header { order: 2; background: none !important; padding-top: 16px !important; padding-bottom: 0 !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > figure ~ .entry-header .page-title { color: #2e1746 !important; text-shadow: none !important; margin-top: 6px !important; margin-bottom: 8px !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > figure ~ .entry-header :is(.entry-meta, .entry-meta li, .entry-meta a, .page-description, .ct-breadcrumbs, .ct-breadcrumbs a, .ct-breadcrumbs span) { color: #6a5f72 !important; text-shadow: none !important; }
  html body.single-post #main#main .hero-section[data-type="type-2"] > .entry-header .ct-breadcrumbs { order: -1; margin: 0 0 4px !important; font-size: 12px !important; }
  html body.single-post #main#main > [class*="ct-container"] { padding-top: 18px !important; }

  /* ----- Trang Đăng ký nhà cung cấp ----- */
  html body .ky-provider-page-hero { padding: 22px var(--dem) !important; border-radius: var(--bo) !important; }
  html body .ky-provider-benefits { display: grid !important; gap: 10px !important; }
  html body .ky-provider-benefits > div { padding: var(--dem) !important; border-radius: var(--bo) !important; margin: 0 !important; }
  html body #main#main .entry-content > .ky-provider-process { margin-left: calc(var(--le) * -1) !important; margin-right: calc(var(--le) * -1) !important; padding: 26px var(--le) !important; border-radius: 0 !important; border-left: 0 !important; border-right: 0 !important; }
  html body .ky-provider-process .process-grid { gap: 10px !important; }
  html body .ky-provider-process .process-grid > div { padding: var(--dem) !important; border-radius: var(--bo) !important; }
  html body .ky-provider-page-hero ~ #provider-form .ky-provider-intro { display: none !important; }
  html body form.ky-provider-form { padding: 16px var(--dem) !important; border-radius: var(--bo) !important; }
  html body form.ky-provider-form fieldset { margin: 0 0 18px !important; padding: 0 !important; border: 0 !important; min-width: 0; }
  html body form.ky-provider-form legend { margin: 0 0 10px !important; padding: 0 !important; font-size: 19px !important; line-height: 1.3 !important; }
  html body form.ky-provider-form .ky-provider-checks { display: grid !important; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important; gap: 8px !important; }
  html body form.ky-provider-form .ky-provider-consent { flex-wrap: wrap !important; font-size: 14px !important; line-height: 1.5 !important; }
  html body form.ky-provider-form .ky-provider-consent > span { flex: 1 1 0; min-width: 0; }
  html body form.ky-provider-form .ky-provider-consent > a { flex: 1 0 100%; padding-left: 26px; }
  html body form.ky-provider-form button[type="submit"], html body form.ky-provider-form > button { width: 100% !important; }
  html body form.ky-provider-form .ky-provider-checks > label { margin: 0 !important; padding: 9px 10px !important; min-width: 0; font-size: 14px !important; line-height: 1.3 !important; }

  /* ----- Trang Album & lưu trữ ----- */
  html body #main#main .entry-content > .ky-album-page { margin-left: calc(var(--le) * -1) !important; margin-right: calc(var(--le) * -1) !important; border-radius: 0 !important; background: none !important; box-shadow: none !important; border: 0 !important; padding: 0 !important; }
  html body .ky-album-page > section { padding-left: var(--le) !important; padding-right: var(--le) !important; margin-left: 0 !important; margin-right: 0 !important; border-radius: 0 !important; }
  html body .ky-album-page :is(.ky-album-option, .ky-process-step) { padding: var(--dem) !important; border-radius: var(--bo) !important; }
  html body .ky-album-page h1 br, html body .ky-album-page h2 br { display: none; }
  html body .ky-album-page :is(h1, h2) em::before { content: " "; }
  html body .ky-album-page figcaption { font-size: 12.5px !important; line-height: 1.35 !important; }
  html body .ky-album-cta { text-align: left !important; }
  html body .ky-album-cta :is(h2, p) { text-align: left !important; margin-left: 0 !important; margin-right: 0 !important; max-width: none !important; }

  /* ----- Trang Liên hệ ----- */
  html body .ky-search-results { padding: 18px var(--dem) !important; border-radius: var(--bo) !important; }
  html body .ky-search-results h2 { padding-left: 0 !important; border-left: 0 !important; }
  html body .ky-search-results :is(p, a) { margin-left: 0 !important; }
  html body #main#main .wpforms-container .wpforms-field { padding-left: 0 !important; padding-right: 0 !important; }
  html body #main#main .wpforms-container .wpforms-submit { width: 100% !important; }

  /* ----- Khu vực lớp trưởng ----- */
  html body .ky-portal-wrap { padding-left: 0 !important; padding-right: 0 !important; margin-left: 0 !important; margin-right: 0 !important; max-width: none !important; }
  html body .ky-portal-auth-card, html body .ky-portal-card, html body .ky-portal-panel { padding: 18px var(--dem) !important; border-radius: var(--bo) !important; }
  html body .ky-portal-wrap h1 { font-size: clamp(26px, 7.4vw, 31px) !important; line-height: 1.2 !important; }
  html body .ky-portal-auth-copy > p { max-width: none !important; font-size: 16px !important; }

  /* ----- Trang Giới thiệu, bài cẩm nang dạng trang ----- */
  html body .cv-about-image, html body .cv-about-split figure { padding: 0 !important; background: none !important; border: 0 !important; box-shadow: none !important; }
  html body .cv-about-split { display: block !important; }
  html body .cv-about-split > * + * { margin-top: 16px !important; }
  html body #main#main .entry-content .article-detail { padding: 0 !important; background: none !important; border: 0 !important; box-shadow: none !important; }
  html body #main#main .entry-content .kyyeu-province-section { padding-left: 0 !important; padding-right: 0 !important; }

  /* ----- Trang không tìm thấy / tìm kiếm ----- */
  html body #main#main .ct-search-form, html body #main#main .entry-content > form[role="search"] { width: auto !important; max-width: none !important; margin-left: 0 !important; margin-right: 0 !important; }
}

/* Mọi bề ngang: trang nhà cung cấp không lặp lại lời giới thiệu hai lần */
html body .ky-provider-page-hero ~ #provider-form .ky-provider-intro { display: none !important; }

/* ----- Chân trang: cùng trục lề với thân trang ----- */
@media (max-width: 767.98px) {
  html body .kyc { padding-left: var(--le) !important; padding-right: var(--le) !important; }
  html body .kyc > *, html body .kyc .kyc-in { padding-left: 0 !important; padding-right: 0 !important; margin-left: 0 !important; margin-right: 0 !important; max-width: none !important; }
  html body .kyc p { max-width: none !important; }
}

/* =====================================================================
   C. TRANG KỶ YẾU CỦA LỚP (44 mẫu) — body.kyyeu-standalone
   ===================================================================== */
@media (max-width: 640px) {
  body.kyyeu-standalone .section { padding-left: var(--le) !important; padding-right: var(--le) !important; }
  body.kyyeu-standalone .share { margin-left: var(--le) !important; margin-right: var(--le) !important; padding-left: var(--dem) !important; padding-right: var(--dem) !important; }
  body.kyyeu-standalone .kyu-ch { padding-left: var(--le) !important; padding-right: var(--le) !important; }
  body.kyyeu-standalone .kyu-step { padding-left: var(--dem) !important; padding-right: var(--dem) !important; }
  body.kyyeu-standalone .kyu-card { padding-left: var(--dem) !important; padding-right: var(--dem) !important; }
  body.kyyeu-standalone :is(.kyu-close, .kyu-days, .kyu-intro-line, .kyu-teacher-note, .kyu-quote, .kyu-sub, .deck),
  body.kyyeu-standalone .cover p { max-width: none !important; }
}
/* Không để bất kỳ mẫu nào tràn ngang màn hình */
body.kyyeu-standalone { overflow-x: hidden; overflow-x: clip; }
body.kyyeu-standalone .wrap { overflow-x: clip; }
@media (max-width: 640px) {
  body.kyyeu-standalone .wrap > .filmstrip-outer { margin-left: 0 !important; margin-right: 0 !important; }
  body.kyyeu-standalone .coffee-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; gap: 10px !important; }
  body.kyyeu-standalone .coffee-grid :is(.coffee-card, .coffee-ring) { width: auto !important; min-width: 0 !important; max-width: 100% !important; }
  body.kyyeu-standalone .coffee-grid img { max-width: 100% !important; height: auto !important; }
  body.kyyeu-standalone .orbit-system { overflow: hidden; }
  /* Chữ đọc được: phụ đề mục, lời dẫn, ghi chú không nhỏ hơn 14px */
  body.kyyeu-standalone .section-head > p.sub, body.kyyeu-standalone .section > p.sub, body.kyyeu-standalone .section > p.lead,
  body.kyyeu-standalone .share > p, body.kyyeu-standalone .kyu-credits-title { font-size: 14px !important; line-height: 1.55 !important; }
  body.kyyeu-standalone .kyu-intro-hint { font-size: 13.5px !important; }
  body.kyyeu-standalone .foot { font-size: 12.5px !important; padding-left: var(--le) !important; padding-right: var(--le) !important; }
  /* Khung nội dung trong mẫu: đệm một mức, không cộng dồn */
  body.kyyeu-standalone .section :is(.note, .leaf-note, .field-note, .scroll-note, .liner-note, .lid-note, .diary-page, .darkroom-note, .captain-msg, .blackbox, .teacher-note, .ink-preview, .thanks-card, .wish-card, .sound-card, .night-note, .shore-note, .flight-note, .sleeve-note, .ink-note, .guest-entry, .mini-timeline-item, .quote, .card) { padding-left: var(--dem) !important; padding-right: var(--dem) !important; }
  body.kyyeu-standalone .timeline .t-year { padding-left: var(--dem) !important; }
  body.kyyeu-standalone :is(.liner, .release, .sand-board, .chalkboard, .pencil-case, .ink-preview, table.schedule, .ky25-facts) { margin-left: 0 !important; margin-right: 0 !important; }
  body.kyyeu-standalone section.quotes { padding-left: var(--le) !important; padding-right: var(--le) !important; }
  body.kyyeu-standalone section.chapter { padding-left: var(--le) !important; padding-right: var(--le) !important; }
}
@media (max-width: 640px) {
  body.kyyeu-standalone.kyyeu-theme-tap-viet .wrap { width: 100% !important; }
  body.kyyeu-standalone :is(.ky25-facts, .sand-board) { max-width: none !important; width: auto !important; }
  body.kyyeu-standalone .wrap > .share { width: auto !important; max-width: none !important; box-sizing: border-box !important; }
}

/* =====================================================================
   D. THIỆP MỜI: 24 mẫu tương tác (.k24-demo), mẫu hoàn chỉnh (.demo-invite), thiệp của lớp (.kyinvite)
   ===================================================================== */
/* Thanh chữ trên bìa: nằm yên trên bìa, không trôi theo khi cuộn và không đè lên nội dung */
.k24-top { position: absolute !important; mix-blend-mode: normal !important; color: #fff !important; font-size: 11px !important; letter-spacing: .1em !important; text-shadow: 0 1px 8px rgba(0, 0, 0, .45); }
.k24-top > div { font-size: 0 !important; display: flex; gap: 16px; }
.k24-top > div > a { font-size: 11px !important; }
.k24-demo { position: relative; }
@media (max-width: 680px) {
  .k24-top { padding: 12px var(--le) !important; justify-content: flex-end !important; }
  .k24-shell { width: auto !important; margin-left: var(--le) !important; margin-right: var(--le) !important; padding-top: 30px !important; }
  .k24-card { padding: 20px var(--dem) !important; border-radius: 18px !important; margin-bottom: 14px !important; }
  .k24-intro { margin-bottom: 22px !important; }
  .k24-intro h2, .k24-card h2, .k24-cover p { max-width: none !important; }
  .k24-info { gap: 8px !important; margin-top: 16px !important; }
  .k24-info div { padding: 12px var(--dem) !important; border-radius: 12px !important; }
  .k24-info small, .k24-date small, .k24-label, .k24-kicker { font-size: 11px !important; }
  .k24-share { padding: 20px var(--dem) !important; border-radius: 16px !important; }
  .k24-share details, .k24-card details { font-size: 13px !important; }
  .k24-actions a { font-size: 14px !important; min-height: 46px !important; }
  .k24-art { gap: 16px !important; }
  .k24-art img { border-radius: 14px !important; }
  .k24-art-copy { padding: 0 !important; }
  .k24-cover-inner { padding-left: var(--le) !important; padding-right: var(--le) !important; }
}
/* Mẫu thiệp hoàn chỉnh (.demo-invite) */
.demo-topbar { position: absolute !important; mix-blend-mode: normal !important; font-size: 11px !important; text-shadow: 0 1px 8px rgba(0, 0, 0, .45); }
.demo-invite { position: relative; }
@media (max-width: 680px) {
  .demo-topbar { padding: 12px var(--le) !important; }
  .demo-shell { width: auto !important; margin-left: var(--le) !important; margin-right: var(--le) !important; padding-top: 30px !important; }
  .demo-section { padding: 20px var(--dem) !important; border-radius: 18px !important; margin-bottom: 14px !important; }
  .demo-intro { margin-bottom: 22px !important; }
  .demo-intro h2, .demo-section h2, .demo-cover p, .demo-letter p { max-width: none !important; }
  .demo-letter { padding: 22px var(--dem) !important; }
  .demo-letter::before { inset: 6px !important; }
  .demo-map { padding: 16px var(--dem) !important; border-radius: 14px !important; gap: 12px !important; }
  .demo-map p { font-size: 14px !important; }
  .demo-map a, .demo-actions a { font-size: 14px !important; }
  .demo-qr { padding: 20px var(--dem) !important; border-radius: 16px !important; }
  .demo-info { padding: 12px var(--dem) !important; border-radius: 12px !important; }
  .demo-info small, .demo-kicker, .demo-date small { font-size: 11px !important; letter-spacing: .12em !important; }
  .demo-grid { gap: 8px !important; margin-top: 16px !important; }
}

/* Thiệp của từng lớp (.kyinvite) */
@media (max-width: 560px) {
  .kyinvite { padding-left: var(--le) !important; padding-right: var(--le) !important; }
  .kyinvite-shell { max-width: none !important; margin-left: 0 !important; margin-right: 0 !important; }
  .kyinvite-card { padding: 20px var(--dem) !important; border-radius: 18px !important; }
  .kyinvite-info { padding: 12px var(--dem) !important; border-radius: 12px !important; }
  .kyinvite-grid { gap: 8px !important; }
  .kyinvite p, .kyinvite h1, .kyinvite h2 { max-width: none !important; }
  .kyinvite-label, .kyinvite-kicker { font-size: 11px !important; }
}

/* ----- Bổ sung sau khi đo lại toàn bộ ----- */
@media (max-width: 680px) {
  .k24-demo .k24-art h3, .demo-invite .demo-section h3 { font-size: clamp(19px, 5.2vw, 22px) !important; line-height: 1.25 !important; }
}
@media (max-width: 640px) {
  .kcc { padding-left: var(--le) !important; padding-right: var(--le) !important; padding-top: 24px !important; }
  .kcc .kcc-khoi { padding: 16px var(--dem) !important; border-radius: var(--bo) !important; margin-bottom: 14px !important; }
  .kcc .kcc-the { padding: 10px !important; gap: 12px !important; }
  .kcc .kcc-ghi { font-size: 14px !important; }
}
@media (max-width: 767.98px) {
  html body.home #main#main .chovinh-home-v2 .cv-hero { padding-left: var(--le) !important; padding-right: var(--le) !important; }
  html body.home #main#main .cv-hero__caption { position: relative !important; inset: auto !important; left: auto !important; right: auto !important; bottom: auto !important; width: auto !important; max-width: none !important; margin: -28px var(--dem) 0 !important; transform: none !important; }
  html body #main#main .ky-album-page figcaption { font-size: 12.5px !important; line-height: 1.35 !important; }
  html body #main#main .ky-album-page :is(h1, h2) { padding-left: 0 !important; border-left: 0 !important; }
  html body #main#main .ky-provider-page-hero h2, html body #main#main .ky-provider-benefits h2 { padding-left: 0 !important; border-left: 0 !important; }
  html body #main#main .ky-provider-benefits h2 { font-size: 19px !important; line-height: 1.3 !important; margin-top: 10px !important; }
  html body #main#main .ky-search-results > div > p { margin-left: 0 !important; padding-left: 0 !important; }
}
@media (max-width: 767.98px) {
  html body #main#main .ky-search-results > div:has(> a) { display: grid !important; grid-template-columns: 1fr !important; gap: 10px !important; }
  html body #main#main .ky-search-results > div > a { display: block !important; width: auto !important; margin: 0 !important; text-align: center !important; }
}
@media (max-width: 767.98px) {
  html body #main#main .hero-section > .entry-header { flex: 1 1 100% !important; width: 100% !important; align-self: stretch !important; }
}
/* Tiêu đề hai vế (vế sau in nghiêng): trên điện thoại nối liền, chữ chạy hết bề ngang rồi mới xuống dòng */
@media (max-width: 767.98px) {
  html body .ky-portal-auth-copy h1 br, html body.home .cv-hero h1 br { display: none !important; }
  html body .ky-portal-auth-copy h1 em, html body.home .cv-hero h1 em, html body.home .cv-hero h1 span { display: inline !important; }
  html body .ky-portal-auth-copy h1 em::before, html body.home .cv-hero h1 em::before { content: " "; }
}
/* Trang chủ: thẻ xuống dòng thừa giữa hai nút làm nút thứ hai rơi xuống hàng dưới */
html body.home .cv-hero .cv-actions > br, html body.home .cv-hero .cv-hero__notes > br { display: none !important; }
@media (max-width: 767.98px) {
  html body.home .cv-hero .cv-hero__notes { display: flex !important; flex-wrap: wrap; gap: 4px 14px !important; }
}

/* =====================================================================
   E. MÃ QR: luôn vuông (kể cả khi bộ vẽ mới chưa chạy xong hoặc trình duyệt tắt JavaScript)
   ===================================================================== */
img[data-qr] { height: auto !important; aspect-ratio: 1 / 1; object-fit: contain; }
#qrcode img, #qrcode canvas { height: auto !important; aspect-ratio: 1 / 1; max-width: 100%; }

/* =====================================================================
   F. THIỆP MỜI: thanh trên bìa chỉ còn nút "Chọn mẫu này" ở bên phải (bên trái là nút "Trở lại")
   ===================================================================== */
.k24-top > a:first-child, .k24-top > div > a:first-child, .demo-topbar > a:first-child, .demo-topbar-right > a:first-child { display: none !important; }
.k24-top, .demo-topbar { justify-content: flex-end !important; padding-top: 10px !important; }
.k24-top > div > a:last-child, .demo-topbar-right > a:last-child { display: inline-flex !important; align-items: center; min-height: 40px; padding: 0 16px; border: 1px solid rgba(255, 255, 255, .45); border-radius: 999px; background: rgba(24, 18, 32, .35); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); color: #fff !important; font: 600 13.5px/1 "Be Vietnam Pro", system-ui, sans-serif !important; letter-spacing: 0 !important; text-transform: none !important; text-shadow: none; }
@media (max-width: 680px) { .k24-top, .demo-topbar { padding-right: 10px !important; } }

/* Đầu trang trên điện thoại: logo và nút menu cùng trục lề với thân trang */
@media (max-width: 999.98px) {
  html body #header#header [data-device="mobile"] [class*="ct-container"] { box-sizing: border-box !important; width: auto !important; max-width: none !important; margin-left: var(--le) !important; margin-right: var(--le) !important; padding-left: 0 !important; padding-right: 0 !important; }
}

/* Dòng ghi nhận nhà tài trợ ở cuối thiệp không bị nút "Bật nhạc nền" che */
.k24-shell > .kytt-chan, .demo-shell > .kytt-chan { padding-bottom: 72px; }

/* ===== Thẻ đánh số: số thứ tự và tiêu đề nằm trên cùng một dòng =====
   Trang Album & lưu trữ ("01 Album online", "01 Chọn và phân loại") và trang Đăng ký nhà cung cấp
   ("01 Được tìm thấy theo nhu cầu", "01 Gửi hồ sơ"). Trước đây số đứng riêng một dòng phía trên tiêu đề. */
html body #main#main :is(.ky-album-option, .ky-process-step, .ky-provider-benefits > div, .ky-provider-process .process-grid > div) {
  display: grid !important; grid-template-columns: auto minmax(0, 1fr) !important; column-gap: 12px !important; row-gap: 0 !important;
  align-items: center !important; align-content: start !important;
}
html body #main#main :is(.ky-album-option, .ky-process-step, .ky-provider-benefits > div, .ky-provider-process .process-grid > div) > * { grid-column: 1 / -1 !important; min-width: 0 !important; }
html body #main#main :is(.ky-album-option, .ky-process-step, .ky-provider-benefits > div, .ky-provider-process .process-grid > div) > p:empty { display: none !important; }
html body #main#main :is(.ky-album-option > .ky-album-option__num, .ky-process-step > span:first-child, .ky-provider-benefits > div > strong:first-child, .ky-provider-process .process-grid > div > span:first-child) {
  grid-column: 1 !important; grid-row: 1 !important; flex: 0 0 auto !important; margin: 0 !important;
}
html body #main#main :is(.ky-album-option, .ky-process-step, .ky-provider-benefits > div, .ky-provider-process .process-grid > div) > :is(h2, h3) {
  grid-column: 2 !important; grid-row: 1 !important; margin: 0 !important;
}
html body #main#main :is(.ky-album-option, .ky-process-step, .ky-provider-benefits > div, .ky-provider-process .process-grid > div) > :is(h2, h3) + p { margin-top: 12px !important; }
/* Tiêu đề trong thẻ không mang vạch tím bên trái (vạch sẽ chen giữa số và chữ); dòng cuối của thẻ không để thừa khoảng trống. */
html body #main#main .ky-provider-benefits > div > h2 { padding-left: 0 !important; border-left: 0 !important; }
html body #main#main :is(.ky-album-option, .ky-process-step, .ky-provider-benefits > div, .ky-provider-process .process-grid > div) > :last-child { margin-bottom: 0 !important; }
/* "01 Gửi hồ sơ": số là chữ nhỏ (không phải hình tròn) nên căn theo chân chữ của tiêu đề. */
html body #main#main .ky-provider-process .process-grid > div { align-items: baseline !important; column-gap: 10px !important; }
/* Dưới 1280px: thẻ Album xếp một cột để tiêu đề nằm trọn một dòng cạnh số (chia ba cột thì tiêu đề bị ép thành 2–4 dòng). */
@media (min-width: 641px) and (max-width: 1279.98px) {
  html body #main#main :is(.ky-album-options__grid, .ky-album-process__grid) { grid-template-columns: minmax(0, 1fr) !important; }
  html body #main#main :is(.ky-album-option, .ky-process-step) > h3 { font-size: 21px !important; line-height: 1.3 !important; }
}
/* 1024–1279px: thẻ trang nhà cung cấp giữ cách xếp của máy tính bảng (một cột / hai cột) vì cột ba, bốn còn hẹp. */
@media (min-width: 1024px) and (max-width: 1279.98px) {
  html body #main#main .ky-provider-benefits { grid-template-columns: minmax(0, 1fr) !important; max-width: 760px !important; }
  html body #main#main .ky-provider-benefits > div > h2 { font-size: 20px !important; line-height: 1.3 !important; }
  html body #main#main .ky-provider-process .process-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}
/* Từ 1280px: thẻ chia ba cột, cỡ chữ tiêu đề vừa để nằm một dòng cạnh số. */
@media (min-width: 1280px) {
  html body #main#main :is(.ky-album-option, .ky-process-step) > h3 { font-size: 22px !important; line-height: 1.3 !important; }
  html body #main#main .ky-provider-benefits > div > h2 { font-size: 20px !important; line-height: 1.3 !important; }
}

/* =====================================================================================================
   Bản 2.14.0 — bố cục, dòng chữ và khung trên các trang nội dung.
   Nguyên tắc: chữ chỉ xuống dòng khi đã chạm lề phải của trang/thẻ (không chia cột hẹp làm chữ gãy sớm);
   bớt khung lồng khung; khoảng trống vừa đủ.
   ===================================================================================================== */

/* ----- Chân trang trên điện thoại: mỗi mục một dòng (trước đây chia hai cột hẹp, mục dài bị gãy làm 2 dòng) ----- */
@media (max-width: 560px) {
  html body .kyc .kyc-tren { grid-template-columns: minmax(0, 1fr) !important; gap: 0 !important; }
  html body .kyc .kyc-thuong-hieu { padding-bottom: 22px !important; }
  html body .kyc .kyc-cot { padding: 16px 0 10px !important; border-top: 1px solid rgba(255, 255, 255, .13) !important; }
  html body .kyc .kyc-cot .kyc-tieu-de { margin: 0 0 6px !important; }
  html body .kyc .kyc-cot a { padding: 7px 0 !important; white-space: nowrap !important; }
  html body .kyc .kyc-duoi { margin-top: 6px !important; gap: 6px !important; }
}

/* ----- Trang Tra cứu (/contact/?region=…): khung "Kết quả tra cứu" gọn lại ----- */
html body #main#main .ky-search-results > h2 { margin: 0 0 14px !important; }
/* Ghi chú: chữ thường, không đóng thêm khung trong khung */
html body #main#main .ky-search-results > div:has(> p:only-child) { margin: 0 0 16px !important; padding: 0 !important; background: none !important; border: 0 !important; border-radius: 0 !important; }
html body #main#main .ky-search-results > div:has(> p:only-child) > p { margin: 0 !important; color: #5b4a68 !important; font-size: 15px !important; font-weight: 400 !important; line-height: 1.6 !important; }
html body #main#main .ky-search-results > div:has(> a) > a { padding: 13px 22px !important; border-radius: 999px !important; font-weight: 600 !important; box-shadow: none !important; }
@media (max-width: 767.98px) {
  /* Ba tiêu chí: một bảng nhỏ, mỗi tiêu chí một dòng (nhãn bên trái, giá trị bên phải) thay cho ba khung lớn xếp chồng */
  html body #main#main #ky-result-meta { display: block !important; margin: 0 0 14px !important; overflow: hidden !important; background: #fff !important; border: 1px solid rgba(62, 31, 92, .12) !important; border-radius: 14px !important; }
  html body #main#main #ky-result-meta > div { display: flex !important; align-items: baseline !important; justify-content: space-between !important; gap: 16px !important; margin: 0 !important; padding: 12px 16px !important; background: none !important; border: 0 !important; border-top: 1px solid rgba(62, 31, 92, .08) !important; border-radius: 0 !important; }
  html body #main#main #ky-result-meta > div:first-child { border-top: 0 !important; }
  html body #main#main #ky-result-meta > div > div:first-child { flex: 0 0 auto; margin: 0 !important; color: #665e6c !important; font-size: 14px !important; }
  html body #main#main #ky-result-meta > div > div:last-child { min-width: 0; font-size: 16px !important; font-weight: 600 !important; text-align: right !important; }
}

/* ----- Ô đồng ý điều khoản (đăng ký lớp trưởng): chữ chạy liền một mạch cạnh ô tích
   (trước đây mỗi cụm chữ và mỗi đường link bị tách thành một cột riêng) ----- */
html body label.ky-portal-check { display: block !important; position: relative !important; padding-left: 32px !important; font-size: 15px !important; line-height: 1.55 !important; text-align: left !important; }
html body label.ky-portal-check > input[type="checkbox"] { position: absolute !important; left: 0 !important; top: 1px !important; width: 22px !important; height: 22px !important; min-height: 0 !important; margin: 0 !important; accent-color: #3e1f5c; }

/* ----- Trang Đăng ký nhà cung cấp ----- */
html body .ky-provider-page-hero .eyebrow { margin: 0 0 12px !important; font-size: 13px !important; font-weight: 600 !important; letter-spacing: .04em !important; text-transform: none !important; }
html body .ky-provider-page-hero .hero-actions > a.wp-element-button { border-radius: 999px !important; }
/* Tên từng phần của biểu mẫu: cùng kiểu chữ với nhãn, có đường kẻ mảnh ngăn các phần */
html body form.ky-provider-form fieldset + fieldset { padding-top: 18px !important; border-top: 1px solid rgba(62, 31, 92, .12) !important; }
html body form.ky-provider-form legend { float: left; width: 100%; margin: 0 0 12px !important; color: #2e1746 !important; font: 600 18px/1.3 "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important; letter-spacing: 0 !important; }
html body form.ky-provider-form legend + * { clear: both; }
/* Ô chọn dịch vụ, khu vực, cấp học: dạng "thẻ chọn" rộng vừa chữ, tự xếp hàng — không còn hai cột hẹp làm chữ gãy dòng */
html body form.ky-provider-form .ky-provider-checks { display: flex !important; flex-wrap: wrap !important; gap: 8px !important; grid-template-columns: none !important; }
html body form.ky-provider-form .ky-provider-checks > label { display: inline-flex !important; flex: 0 1 auto !important; align-items: center !important; gap: 8px !important; width: auto !important; min-width: 0 !important; min-height: 42px !important; margin: 0 !important; padding: 8px 15px 8px 12px !important; border-radius: 999px !important; font-size: 15px !important; line-height: 1.2 !important; white-space: nowrap !important; cursor: pointer; }
html body form.ky-provider-form .ky-provider-checks > label > span { white-space: nowrap !important; }
html body form.ky-provider-form .ky-provider-checks > label > input { flex: 0 0 auto; margin: 0 !important; accent-color: #3e1f5c; }
/* Riêng nhóm "Dịch vụ cung cấp" (tên dài): mỗi dịch vụ một hàng ngang bằng nhau cho ngay ngắn; từ máy tính bảng trở lên chia hai cột. */
html body form.ky-provider-form .ky-provider-checks:has(input[name^="provider_services"]) { display: grid !important; grid-template-columns: minmax(0, 1fr) !important; gap: 8px !important; }
html body form.ky-provider-form .ky-provider-checks:has(input[name^="provider_services"]) > label { display: flex !important; width: 100% !important; border-radius: 12px !important; }
@media (min-width: 768px) { html body form.ky-provider-form .ky-provider-checks:has(input[name^="provider_services"]) { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; } }
html body form.ky-provider-form .ky-provider-checks > label:has(input:checked) { border-color: #3e1f5c !important; background: #f3ecf8 !important; color: #2e1746 !important; }

/* ----- Trang nội dung trên điện thoại: bớt khoảng trống trên và dưới tiêu đề trang ----- */
@media (max-width: 767.98px) {
  html body.page #main#main > [data-vertical-spacing*="top"] { padding-top: 22px !important; }
  html body.page #main#main .hero-section[data-type="type-1"] { margin-bottom: 14px !important; }
  html body.page #main#main .hero-section[data-type="type-1"] .entry-header { margin: 0 !important; padding: 0 !important; min-height: 0 !important; }
}

/* ----- Trang kỷ yếu của lớp và thiệp: nút nhỏ không bị gãy làm hai dòng ----- */
html body #kylb .kylb-nut, html body a.kyu-back, html body .kytt-the .kytt-link { white-space: nowrap !important; }

/* =====================================================================================================
   Bản 2.15.0 — Menu trên điện thoại (bảng #offcanvas của Blocksy).
   Trước đây: chữ "Menu" thay cho logo, chữ xanh đen và mũi tên cam lệch bộ màu, đường kẻ đứt nét, hàng cao
   không đều, menu con có ô bo tròn bị cắt ở mép trái, bốn biểu tượng mạng xã hội trỏ tới đường link rỗng,
   không có nút "Nhận tư vấn".
   ===================================================================================================== */
html body #offcanvas#offcanvas#offcanvas,
html body #offcanvas#offcanvas#offcanvas .ct-panel-content,
html body #offcanvas#offcanvas#offcanvas .ct-panel-content-inner { background: #fbf8f2 !important; }

/* Hàng đầu: logo bên trái, nút đóng tròn bên phải */
html body #offcanvas#offcanvas#offcanvas .ct-panel-actions { display: flex !important; align-items: center !important; justify-content: space-between !important; box-sizing: border-box !important; min-height: 66px !important; margin: 0 !important; padding: 10px 14px 10px 18px !important; border: 0 !important; border-bottom: 1px solid rgba(62, 31, 92, .1) !important; background: #fbf8f2 !important; }
html body #offcanvas#offcanvas#offcanvas .ct-panel-actions::before { content: "" !important; display: block !important; flex: 0 0 150px !important; width: 150px !important; height: 32px !important; margin: 0 !important; padding: 0 !important; background: url(../img/logo/logo-kyyeu.svg) left center / contain no-repeat !important; font-size: 0 !important; }
html body #offcanvas#offcanvas#offcanvas .ct-panel-actions::after { content: none !important; }
html body #offcanvas#offcanvas#offcanvas .ct-toggle-close { position: static !important; display: inline-flex !important; align-items: center !important; justify-content: center !important; flex: 0 0 44px !important; width: 44px !important; height: 44px !important; margin: 0 !important; padding: 0 !important; border: 1px solid rgba(62, 31, 92, .16) !important; border-radius: 50% !important; background: #fff !important; color: #2e1746 !important; opacity: 1 !important; box-shadow: none !important; transform: none !important; }
html body #offcanvas#offcanvas#offcanvas .ct-toggle-close .ct-icon { width: 13px !important; height: 13px !important; fill: currentColor !important; }

/* Thân menu */
html body #offcanvas#offcanvas#offcanvas .ct-panel-content[data-device="mobile"] { padding: 0 !important; }
html body #offcanvas#offcanvas#offcanvas .ct-panel-content[data-device="mobile"] > .ct-panel-content-inner { display: flex !important; flex-direction: column !important; align-items: stretch !important; gap: 0 !important; box-sizing: border-box !important; padding: 4px 18px 30px !important; }
html body #offcanvas#offcanvas#offcanvas .ct-header-text { display: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu { order: 1 !important; width: 100% !important; margin: 0 !important; padding: 0 !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu ul { margin: 0 !important; padding: 0 !important; list-style: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu > ul > li { margin: 0 !important; padding: 0 !important; border: 0 !important; border-bottom: 1px solid rgba(62, 31, 92, .1) !important; background: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .ct-sub-menu-parent { display: flex !important; align-items: center !important; justify-content: space-between !important; gap: 8px !important; margin: 0 !important; padding: 0 !important; border: 0 !important; background: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu > ul > li > a,
html body #offcanvas#offcanvas#offcanvas .mobile-menu > ul > li > .ct-sub-menu-parent > a { display: flex !important; align-items: center !important; flex: 1 1 auto !important; box-sizing: border-box !important; min-height: 56px !important; margin: 0 !important; padding: 8px 0 !important; border: 0 !important; background: none !important; color: #2e1746 !important; font: 600 17px/1.3 "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important; letter-spacing: 0 !important; text-transform: none !important; text-decoration: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .current-menu-item > a,
html body #offcanvas#offcanvas#offcanvas .mobile-menu .current-menu-item > .ct-sub-menu-parent > a,
html body #offcanvas#offcanvas#offcanvas .mobile-menu .current-menu-ancestor > .ct-sub-menu-parent > a { color: #8a6a36 !important; }
/* Nút mở menu con: vùng chạm 44px, mũi tên màu tím của website */
html body #offcanvas#offcanvas#offcanvas .mobile-menu .ct-toggle-dropdown-mobile { display: inline-flex !important; align-items: center !important; justify-content: center !important; flex: 0 0 44px !important; width: 44px !important; height: 44px !important; min-height: 0 !important; margin: 0 -10px 0 0 !important; padding: 0 !important; border: 0 !important; border-radius: 50% !important; background: none !important; color: #3e1f5c !important; opacity: 1 !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .ct-toggle-dropdown-mobile[aria-expanded="true"] { background: rgba(62, 31, 92, .08) !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .ct-toggle-dropdown-mobile svg { width: 11px !important; height: 11px !important; fill: currentColor !important; color: inherit !important; }

/* Menu con: thụt vào, vạch mảnh bên trái, không khung nền, không đường đứt nét, không ô trang trí */
html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu { border: 0 !important; border-left: 2px solid rgba(185, 140, 62, .5) !important; border-radius: 0 !important; background: none !important; box-shadow: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu li { margin: 0 !important; padding: 0 !important; border: 0 !important; background: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu li::before, html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu li::after,
html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu a::before, html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu a::after { content: none !important; display: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu a { display: flex !important; align-items: center !important; box-sizing: border-box !important; min-height: 44px !important; margin: 0 !important; padding: 6px 0 6px 14px !important; border: 0 !important; background: none !important; color: #4a3d57 !important; font: 400 15.5px/1.35 "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important; letter-spacing: 0 !important; text-transform: none !important; text-decoration: none !important; }
html body #offcanvas#offcanvas#offcanvas .mobile-menu .sub-menu .current-menu-item > a { color: #8a6a36 !important; font-weight: 600 !important; }

/* Cuối menu: nút "Nhận tư vấn" và đường vào Khu vực lớp trưởng; ẩn biểu tượng mạng xã hội chưa có đường link thật */
html body #offcanvas#offcanvas#offcanvas .ct-header-cta { display: grid !important; gap: 10px !important; order: 2 !important; margin: 22px 0 0 !important; padding: 0 !important; }
html body #offcanvas#offcanvas#offcanvas .ct-header-cta > a { display: flex !important; align-items: center !important; justify-content: center !important; box-sizing: border-box !important; width: 100% !important; min-height: 50px !important; margin: 0 !important; padding: 0 22px !important; border: 1px solid #3e1f5c !important; border-radius: 999px !important; background: #3e1f5c !important; color: #fff !important; font: 600 16px/1.2 "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important; letter-spacing: 0 !important; text-transform: none !important; text-decoration: none !important; box-shadow: none !important; }
html body #offcanvas#offcanvas#offcanvas .ct-header-cta > a.kyyeu-menu-lop-truong { border-color: rgba(62, 31, 92, .3) !important; background: #fff !important; color: #3e1f5c !important; }
html body #offcanvas#offcanvas#offcanvas .ct-header-socials { order: 3 !important; margin: 18px 0 0 !important; }
html body #offcanvas#offcanvas#offcanvas .ct-header-socials a[href="#"], html body #offcanvas#offcanvas#offcanvas .ct-header-socials a[href=""] { display: none !important; }
/* Máy tính bảng: menu không kéo giãn hết bề ngang màn hình */
@media (min-width: 600px) {
  html body #offcanvas#offcanvas#offcanvas .ct-panel-actions,
  html body #offcanvas#offcanvas#offcanvas .ct-panel-content[data-device="mobile"] > .ct-panel-content-inner { width: 100% !important; max-width: 560px !important; margin-left: auto !important; margin-right: auto !important; }
}

/* =====================================================================
   Bản 2.16.0 — RÀ SOÁT TỪNG MẪU KỶ YẾU TRÊN ĐIỆN THOẠI
   Ba quy tắc: (1) chữ ngắn nằm trên một dòng; (2) lưới không để lẻ một ô ở hàng cuối;
   (3) khung không lệch lề, không cắt mép. Phần co chữ do tieu-de-1-dong.js lo; ở đây sửa bố cục để chữ có đủ chỗ.
   ===================================================================== */
@media (max-width: 640px) {
  /* --- Dùng chung: đường link của lớp luôn nằm trên một dòng --- */
  body.kyyeu-standalone .link-row { flex-wrap: wrap; }
  body.kyyeu-standalone .link-row code { display: block; max-width: 100%; min-width: 0; box-sizing: border-box; overflow-wrap: anywhere; }

  /* --- Mưa tháng sáu --- */
  body.kyyeu-standalone :is(.wl-head, .wl-row) { grid-template-columns: 74px minmax(0, 1fr) 28px !important; gap: 10px !important; padding-left: var(--dem) !important; padding-right: var(--dem) !important; }
  body.kyyeu-standalone .wl-head > :nth-child(3) { visibility: hidden; }
  body.kyyeu-standalone .class-windows { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 8px !important; }
  body.kyyeu-standalone .cw-pane { border-width: 3px !important; }
  body.kyyeu-standalone .rm-stat { display: grid !important; grid-template-columns: minmax(0, 1fr) !important; gap: 8px !important; width: fit-content; max-width: 100%; margin-left: auto !important; margin-right: auto !important; }
  body.kyyeu-standalone .rm-cell { display: grid !important; grid-template-columns: 58px minmax(0, 1fr); column-gap: 14px; align-items: baseline; text-align: left !important; }
  body.kyyeu-standalone .rm-cell strong { text-align: right; }
  body.kyyeu-standalone .rm-cell span { font-size: 11px !important; letter-spacing: .08em !important; white-space: nowrap; }

  /* --- Cuốn băng 199x --- */
  body.kyyeu-standalone .tv-controls { gap: 6px !important; }
  body.kyyeu-standalone .vhs-btn { flex: 1 1 0; min-width: 0; padding: 10px 4px !important; font-size: 11px !important; letter-spacing: .04em !important; white-space: nowrap; }
  body.kyyeu-standalone .side-list li { flex-direction: column-reverse; gap: 1px !important; }
  body.kyyeu-standalone .side-list li span:last-child { font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; }
}

@media (max-width: 640px) {
  /* --- Dùng chung: lưới ô nhỏ (số liệu, ô cửa, thẻ khen…) chia đều theo số ô, không để lẻ một ô ở hàng cuối.
         Lưới 6 cột: 1 ô → cả hàng · 2 ô → 2/hàng · 3 ô → 3/hàng · 4 ô → 2 × 2 · 5 ô → 3 + 2 · 6 ô → 3 × 2. --- */
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) { display: grid !important; grid-template-columns: repeat(6, minmax(0, 1fr)) !important; gap: 10px !important; }
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > * { grid-column: span 2; min-width: 0 !important; }
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > :first-child:nth-last-child(1) { grid-column: 1 / -1; }
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > :first-child:nth-last-child(2),
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > :first-child:nth-last-child(2) ~ *,
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > :first-child:nth-last-child(4),
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > :first-child:nth-last-child(4) ~ *,
  body.kyyeu-standalone :is(.stat-row, .advent-grid, .like-grid, .star-board) > :first-child:nth-last-child(5) ~ :nth-child(n+4) { grid-column: span 3; }
  body.kyyeu-standalone .stat-chip { padding: 14px 8px !important; }

  /* --- Chuyến bay ký ức: bảng giờ bay còn 2 cột thì tiêu đề cũng 2 cột --- */
  body.kyyeu-standalone .db-head > :nth-child(3) { display: none !important; }
  /* --- Phòng tối: 7 khung phim xếp 4 + 3 --- */
  body.kyyeu-standalone .contact-sheet { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 6px !important; padding: 10px !important; }
  /* --- Đồng hồ cát: mốc thời gian xếp dọc (nhãn trên, câu dưới) để câu dùng hết bề ngang --- */
  body.kyyeu-standalone .mini-timeline-item { flex-direction: column !important; gap: 2px !important; }
  body.kyyeu-standalone .mini-timeline-item span { text-align: left !important; }
}

/* Mùa đông: bông tuyết quay tại chỗ (trước đây ô chứa nó cao bằng cả hàng nên bông tuyết quay thành vòng rộng, lấn ra ngoài mép). */
body.kyyeu-standalone .wi-flake { align-self: flex-start; width: 1.5em; height: 1.5em; line-height: 1.5; text-align: center; }
@media (max-width: 640px) {
  /* Mưa tháng sáu: cột ngày và cột biểu tượng gọn lại, nhường chỗ cho tên sự kiện */
  body.kyyeu-standalone :is(.wl-head, .wl-row) { grid-template-columns: 66px minmax(0, 1fr) 24px !important; gap: 8px !important; }
  body.kyyeu-standalone .wl-date { font-size: 11px !important; }
  body.kyyeu-standalone .wl-event { font-size: 13px !important; }
  /* Hộp thư thời gian: ô lẻ cuối lưới trải hết bề ngang */
  body.kyyeu-standalone .archive-grid > :last-child:nth-child(odd):not(:first-child) { grid-column: 1 / -1; }
}

/* Máy tính: khối nội dung của trang thường nằm giữa (trước đây trang Album lệch trái 16px so với khung trang). */
@media (min-width: 1000px) {
  html body.page #main#main .entry-content.is-layout-constrained { margin-left: auto !important; margin-right: auto !important; }
}

/* Thiệp của lớp: ba nút "Mở Google Maps / Thêm vào lịch / Google Lịch" không để lẻ một nút ở hàng dưới.
   Số nút lẻ → nút đầu trải cả hàng, các nút còn lại chia đôi; số nút chẵn → chia đôi đều. */
@media (max-width: 640px) {
  html body .kyinvite .kyinvite-nut { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  html body .kyinvite .kyinvite-nut > * { margin: 0; min-width: 0; justify-content: center; text-align: center; white-space: nowrap; padding-left: 10px; padding-right: 10px; box-sizing: border-box; }
  html body .kyinvite .kyinvite-nut > :first-child:nth-last-child(odd) { grid-column: 1 / -1; }
}

/* Giao mùa: nút "Sao chép" trước đây trắng trên nền trắng (nền lấy currentColor trong khi chữ cũng màu trắng). */
body.kyyeu-standalone.kyyeu-theme-giao-mua .link-row button { background: #4A2E3A; color: #fff; }

/* Danh mục mẫu kỷ yếu / thiệp trên điện thoại: mô tả trong thẻ hiện đủ câu (trước đây bị cắt "…" giữa chữ sau 2 dòng);
   hai nút của các thẻ cùng hàng vẫn thẳng nhau ở đáy thẻ. */
@media (max-width: 760px) {
  html body .kui-the { display: flex; flex-direction: column; }
  html body .kui-the .kui-the-than { display: flex; flex-direction: column; flex: 1 1 auto; }
  html body .kui-the p:not(.kui-the-meta) { display: block; -webkit-line-clamp: unset; overflow: visible; }
  html body .kui-the .kui-the-nut { margin-top: auto; }
}

/* Ảnh trong lưới của các mẫu: thẻ <figure> không giữ lề mặc định của trình duyệt (40px mỗi bên) — trước đây làm thẻ ảnh
   của "Mùa phượng", "Tà áo trắng" chỉ còn rộng ~95px giữa ô lưới 174px. */
:where(body.kyyeu-standalone :is([class*="grid"], [class*="gallery"], [class*="wall"], [class*="strip"])) > figure { margin: 0; }
/* Editorial: ảnh bo góc không còn lộ nền đen vuông phía sau. */
body.kyyeu-standalone .bento figure { background: transparent; }

/* Thẻ <figure> trong trang lớp không giữ lề ngang mặc định của trình duyệt (40px mỗi bên): lề đó làm ảnh lục giác của
   "Di sản" chỉ xếp được 1 tấm một hàng, thẻ ảnh của vài mẫu bị bó hẹp. */
:where(body.kyyeu-standalone) figure { margin-left: 0; margin-right: 0; }
@media (max-width: 640px) {
  /* Di sản: nhãn dọc ở lề trái không đủ chỗ trên điện thoại (đè lên lề 12px) → ẩn; khung lời nhắn dùng hết bề ngang. */
  body.kyyeu-standalone .vertical-label { display: none; }
  body.kyyeu-standalone .scroll-notes { padding-left: 14px !important; padding-right: 14px !important; }
  body.kyyeu-standalone .scroll-notes .scroll-note { padding-left: 0 !important; padding-right: 0 !important; }
}


/* ===== Bản 2.16.0 — sửa riêng các mẫu 38, 40, 45 (soát bằng ảnh, lô D) ===== */
/* 38 Chuyến bay: bản đồ vẽ theo khung 500 đơn vị, trên điện thoại co còn 0,7 → nhãn 10 chỉ còn 7px. Phóng nhãn và nét để đọc được. */
@media (max-width:640px){
  body.kyyeu-standalone .route-map .rm-label{font-size:19px}
  body.kyyeu-standalone .route-map .rm-path{stroke-width:3}
  body.kyyeu-standalone .route-map .rm-stop{r:8px}
  body.kyyeu-standalone .bb-wave{justify-content:space-between}
  body.kyyeu-standalone .boarding-pass :is(.bp-point span,.bp-seat){font-size:10.5px}
  body.kyyeu-standalone .boarding-pass .bp-label{font-size:10.5px;letter-spacing:.16em}
}
/* 40 Sóng biển: nhãn mốc đầu/cuối canh theo mép thanh (trước đây canh giữa điểm nên bị cắt ở mép màn hình); kim la bàn ngắn lại để không đè chữ "B". */
body.kyyeu-standalone .tide-fill + .tide-marker span{left:-8px;transform:none}
body.kyyeu-standalone .tide-marker:last-child span{left:auto;right:-8px;transform:none}
body.kyyeu-standalone .compass-needle{height:58px;margin-top:-58px}
body.kyyeu-standalone .tide-marker span{font-size:12px}
/* 45 Tập viết: hộp bút 4 cột đều; tiêu đề bảng một dòng; bỏ vạch lề đỏ chạy xuyên chữ canh giữa trên màn hình hẹp. */
@media (max-width:640px){
  body.kyyeu-standalone .pencil-case{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;padding:16px 8px 14px}
  body.kyyeu-standalone .pencil-case .pc-tool{width:auto}
  body.kyyeu-standalone .schedule th{font-size:15px;padding:9px 10px;white-space:nowrap}
  body.kyyeu-standalone .schedule td{padding:10px}
  body.kyyeu-standalone .schedule .sc-no{width:38px}
  body.kyyeu-standalone.kyyeu-theme-tap-viet .paper-bg{background-position:-10px 0,0 0,0 0}
}

/* ===== Bản 2.16.0 — sửa riêng các mẫu 02–12 (lô A) ===== */
/* 02: biểu tượng mặt trời nằm ngoài góc thẻ, chỉ cách mép màn hình 2px → ghim vào cạnh trên của thẻ. */
body.kyyeu-standalone .leaf-note::before{left:14px;top:-11px;font-size:18px;line-height:1;color:#E0892E;font-variant-emoji:text;font-family:'Segoe UI Symbol','Apple Symbols','Noto Sans Symbols 2','DejaVu Sans',sans-serif}
/* 03: ba số liệu dồn về bên trái → trải đều hết bề ngang. */
body.kyyeu-standalone .meta-strip{justify-content:space-between;gap:14px 16px}
/* 04: khung lục giác trước đây chỉ thấy viền ở 2 cạnh đứng (viền vuông bị cắt theo hình) → viền vàng chạy đủ 6 cạnh. */
body.kyyeu-standalone .hex{background:#C9A227;padding:4px;box-sizing:border-box}
body.kyyeu-standalone .hex img{display:block;clip-path:polygon(50% 0%,100% 25%,100% 75%,50% 100%,0% 75%,0% 25%)}
body.kyyeu-standalone .hex::after{content:none}
/* Hàng ảnh cuộn ngang (05, 10, 13 và dải phim dùng chung): trước đây bị cắt ngay ở lề 12px, trông như ảnh bị xén.
   Cho hàng ảnh chạy tràn ra tới mép màn hình, ảnh đầu vẫn thẳng lề với nội dung. */
@media (max-width:760px){
  body.kyyeu-standalone.kyyeu-theme-da-tiec .gallery,
  body.kyyeu-standalone.kyyeu-theme-dem-hoi .photo-row,
  body.kyyeu-standalone.kyyeu-theme-vu-dieu-pastel .carousel,
  body.kyyeu-standalone .kyu .kyu-g-film .kyu-gallery{margin-left:-12px!important;margin-right:-12px!important;padding-left:12px!important;padding-right:12px!important;scroll-padding-left:12px;scroll-padding-right:12px;max-width:none!important;width:auto!important}
}
/* 07 Vườn hoa: số lời nhắn của mỗi tổ trôi lơ lửng giữa hàng → đứng ngay sau tên tổ; chữ phụ đậm hơn cho dễ đọc. */
body.kyyeu-standalone .acc summary{justify-content:flex-start;gap:8px}
body.kyyeu-standalone .acc summary::after{margin-left:auto}
body.kyyeu-standalone .acc summary span{color:#8A6F5C!important}
body.kyyeu-standalone .flip-hint{font-size:12.5px;color:#8A6F5C}
/* 09 Ngân hà: bốn ô đếm ngược rộng bằng nhau (trước đây ô "ngày" rộng hơn hẳn ba ô còn lại). */
body.kyyeu-standalone .countdown{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;max-width:340px;margin-left:auto;margin-right:auto}
body.kyyeu-standalone .countdown .cd-item{min-width:0;padding-left:6px;padding-right:6px}
body.kyyeu-standalone .countdown .cd-item span{font-size:10.5px}
/* 11 Giao hưởng: thẻ "Giữ album này lại" bo góc nhưng chạm cả hai mép màn hình → lùi vào đúng lề như các thẻ khác. */
@media (max-width:760px){ body.kyyeu-standalone.kyyeu-theme-giao-huong .release{margin-left:12px!important;margin-right:12px!important;padding-left:16px;padding-right:16px} }
/* ===== Bản 2.16.0 — sửa riêng các mẫu 13–23 (lô B) ===== */
/* 19 Giảng đường: 6 ảnh tròn có vòng viền ngoài 11px nhưng khe chỉ 10px nên các vòng đè lên nhau và chạm mép màn hình. */
@media (max-width:640px){
  body.kyyeu-standalone .coffee-grid{gap:26px 24px!important;padding:12px 12px 0}
  body.kyyeu-standalone .coffee-grid .coffee-ring{aspect-ratio:1;height:auto!important;padding:5px}
  body.kyyeu-standalone .coffee-grid .coffee-ring img{height:100%!important}
}
/* 20 Tà áo trắng: chữ ký màu hồng nhạt gần như không đọc được trên nền trắng. */
body.kyyeu-standalone .signature{opacity:1}
body.kyyeu-standalone .signature:nth-child(3n){color:#A8635A}
/* ===== Bản 2.16.0 — sửa riêng các mẫu 24–34 (lô C) ===== */
/* 24 Đồng hồ cát: bầu dưới lúc chưa có cát chỉ còn một vạch ngang → tô nền kính nhạt để thấy đủ hình đồng hồ. */
body.kyyeu-standalone :is(.glass-top,.glass-bottom){background:rgba(168,121,46,.16)}
/* 25 Vũ trụ: lúc mới mở (và khi máy tắt chuyển động) 6 hành tinh cùng nằm trên một đường thẳng đứng, đè lên nhau.
   Cho mỗi quỹ đạo một góc xuất phát riêng; trên điện thoại thu quỹ đạo để hành tinh không bị cắt ở mép màn hình. */
body.kyyeu-standalone .orbit-ring.o2{animation-delay:-4.3s}
body.kyyeu-standalone .orbit-ring.o3{animation-delay:-11.3s}
body.kyyeu-standalone .orbit-ring.o4{animation-delay:-21s}
body.kyyeu-standalone .orbit-ring.o5{animation-delay:-33.3s}
body.kyyeu-standalone .orbit-ring.o6{animation-delay:-9.7s}
@media (prefers-reduced-motion: reduce){
  body.kyyeu-standalone .orbit-ring.o2{transform:translate(-50%,-50%) rotate(-60deg)} body.kyyeu-standalone .orbit-ring.o2 .planet{transform:rotate(60deg)}
  body.kyyeu-standalone .orbit-ring.o3{transform:translate(-50%,-50%) rotate(120deg)} body.kyyeu-standalone .orbit-ring.o3 .planet{transform:rotate(-120deg)}
  body.kyyeu-standalone .orbit-ring.o4{transform:translate(-50%,-50%) rotate(-180deg)} body.kyyeu-standalone .orbit-ring.o4 .planet{transform:rotate(180deg)}
  body.kyyeu-standalone .orbit-ring.o5{transform:translate(-50%,-50%) rotate(240deg)} body.kyyeu-standalone .orbit-ring.o5 .planet{transform:rotate(-240deg)}
  body.kyyeu-standalone .orbit-ring.o6{transform:translate(-50%,-50%) rotate(-300deg)} body.kyyeu-standalone .orbit-ring.o6 .planet{transform:rotate(300deg)}
}
@media (max-width:520px){
  body.kyyeu-standalone .orbit-system .sun{width:76px;height:76px}
  body.kyyeu-standalone .orbit-ring.o1{width:140px;height:140px}
  body.kyyeu-standalone .orbit-ring.o2{width:calc(100vw - 216px);height:calc(100vw - 216px)}
  body.kyyeu-standalone .orbit-ring.o3{width:calc(100vw - 182px);height:calc(100vw - 182px)}
  body.kyyeu-standalone .orbit-ring.o4{width:calc(100vw - 148px);height:calc(100vw - 148px)}
  body.kyyeu-standalone .orbit-ring.o5{width:calc(100vw - 114px);height:calc(100vw - 114px)}
  body.kyyeu-standalone .orbit-ring.o6{width:calc(100vw - 80px);height:calc(100vw - 80px)}
  body.kyyeu-standalone .orbit-system .planet{width:40px;height:40px;margin-left:-20px;margin-top:-20px}
}
/* 28 Đèn lồng: đèn rộng hơn và chữ to hơn một chút để lời nhắn không bị bó thành cột hẹp. */
@media (max-width:640px){
  body.kyyeu-standalone .lantern-field{gap:22px 14px}
  body.kyyeu-standalone .lantern-field .lantern{width:174px}
  body.kyyeu-standalone .lantern-text{font-size:12.5px;line-height:1.45}
  body.kyyeu-standalone .lantern-name{font-size:13.5px}
}
/* 29 Album ép hoa: chữ ghi chú nằm sát vạch kẻ dọc → trả lại khoảng cách; nhãn mẫu vật không lặp lại tên hai lần. */
body.kyyeu-standalone .field-note{padding-left:26px!important}
body.kyyeu-standalone .label-latin.label-trung{display:none}
/* 36 Mưa tháng sáu: tên người gửi trên kính mờ gần như lẫn vào nền tối. 37 Cuộn băng: bỏ dải chú thích trống dưới khung hình. */
body.kyyeu-standalone .fog-note cite{color:#9FC3D6;color:color-mix(in srgb,var(--kyyeu-accent) 40%,#E6F0F5)}
body.kyyeu-standalone .vhs-still figcaption:empty{display:none}
/* 39 Đom đóm: mặt trăng che mất chữ cuối của dòng "ĐÊM HÈ · KYYEU.VN" trên điện thoại → thu nhỏ, đưa lên góc. Chữ gợi ý sáng hơn trên nền tối. */
@media (max-width:640px){ body.kyyeu-standalone.kyyeu-theme-dom-dom .moon{top:18px;right:14px;width:52px;height:52px} }
body.kyyeu-standalone .whisper-hint{font-size:12px;color:#8FA886}
body.kyyeu-standalone .whisper-text{color:#C9B8E8;color:color-mix(in srgb,var(--kyyeu-dusk) 55%,#F1ECFA)}
/* 42 Lá vàng: cột "bây giờ" chạy sát mép phải của hàng → thu cột biểu tượng, thêm lề trong, chữ nhỏ lại một nấc. */
@media (max-width:640px){
  body.kyyeu-standalone .change-row{grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr);gap:8px;padding-left:4px;padding-right:8px}
  body.kyyeu-standalone .change-row :is(.cr-then,.cr-now){font-size:13px}
  body.kyyeu-standalone .change-row .cr-arrow{text-align:center}
}
/* 45 Tập viết: bảng thời khóa biểu bị co lại 50px so với khung (bảng đang là display:block) → trả về bảng thật, rộng hết khung. */
body.kyyeu-standalone table.schedule{display:table!important;width:100%!important;table-layout:auto}
/* 45: tên lớp dài làm dòng đầu vở gãy 2 dòng → chỉ cho xuống dòng gọn, canh phải. */
@media (max-width:640px){ body.kyyeu-standalone .notebook-header{flex-wrap:nowrap;gap:8px} body.kyyeu-standalone .notebook-header .nb-class{overflow:hidden;text-overflow:ellipsis} }
/* Trang danh mục (2 cột trên điện thoại): dòng "Loại · Phong cách" của thẻ luôn nằm trên một dòng. */
@media (max-width:480px){ html body .kui-luoi .kui-the .kui-the-meta{font-size:11.6px;gap:0 5px;flex-wrap:wrap;white-space:nowrap;overflow:visible;-webkit-line-clamp:unset} }
/* 24 Đồng hồ cát: khung ảnh trượt rộng bằng các khối khác (trước lùi vào 15px, lệch 3px so với lề chung 12px). */
@media (max-width:640px){ body.kyyeu-standalone figure.slide-photo{max-width:100%} }
/* ===== Bản 2.16.0 — lượt soát ảnh thứ 4 ===== */
/* 02: chữ kem trên nền cam ở thẻ chia sẻ khó đọc (2:1) → nền cam đậm hơn, chữ trắng; tên lớp cách vòng ảnh bìa xa hơn. */
body.kyyeu-standalone.kyyeu-theme-nang-san-truong .share{background:linear-gradient(160deg,#C97C2E,#9A5718);color:#fff}
body.kyyeu-standalone.kyyeu-theme-nang-san-truong .share p{opacity:1}
body.kyyeu-standalone.kyyeu-theme-nang-san-truong .share .link-row code{background:rgba(255,255,255,.2);color:#fff}
/* 03: chữ cái đầu to cách phần còn lại của chữ quá xa ("B a năm"). */
body.kyyeu-standalone .deck p::first-letter{margin-right:3px}
/* 06: gợi ý cuộn quá nhạt. 07: tên người gửi quá nhạt. */
body.kyyeu-standalone :is(.scroll-hint,.scroll-cue){opacity:1}
/* Nút bấm trong trang lớp dùng font của trang (trước đây vài nút hiện bằng font hệ thống: "Trang sau", "Sao chép", thẻ mùa). */
body.kyyeu-standalone :is(button, input[type="button"], input[type="submit"]){font-family:inherit}
/* 06: gợi ý cuộn. 07: tên người gửi. 08: tiêu đề vàng trên hồng nhạt (2:1) → vàng đậm; tên người gửi; khoảng trống dưới phong bì. */
body.kyyeu-standalone .scroll-cue{opacity:1;color:#fff;font-size:11.5px;text-shadow:0 1px 6px rgba(60,20,30,.55)}
body.kyyeu-standalone .acc-note cite{color:#8A6F5C}
body.kyyeu-standalone.kyyeu-theme-vuon-hoa .divider{padding-left:12px}
body.kyyeu-standalone.kyyeu-theme-thu-tinh .section h2{background-image:linear-gradient(90deg,#8C6A2A,#B38A3C,#8C6A2A)}
body.kyyeu-standalone.kyyeu-theme-thu-tinh :is(.letter cite,.note cite,cite){color:#8C6A2A}
@media (max-width:640px){ body.kyyeu-standalone.kyyeu-theme-thu-tinh .envelope-stage{min-height:0;padding-top:52px;padding-bottom:26px} }
/* 18: tiêu đề "Lời nhắn dọc đường về" sát khối chip phía trên. */
body.kyyeu-standalone.kyyeu-theme-con-duong .section + .section{padding-top:56px}
/* 26 Hộp thư: ảnh lẻ cuối bị cắt thành một dải dẹt 354×80 → giữ tỉ lệ ảnh; bỏ dải trắng trống dưới ảnh không có chú thích. */
body.kyyeu-standalone .archive-grid > :last-child:nth-child(odd) img{aspect-ratio:16/9;height:auto!important;width:100%;object-fit:cover}
body.kyyeu-standalone .archive-grid figcaption:empty{display:none}
/* 29: nhãn "No. 01" quá nhạt; góc tím lộ sau ảnh bo tròn. 30/31: nhãn nhỏ và nhạt. */
body.kyyeu-standalone .specimen-label .label-no{color:#7B7A5E;font-size:11.5px}
body.kyyeu-standalone .specimen-frame{background:transparent;border-radius:10px;overflow:hidden}
body.kyyeu-standalone .specimen-frame img{border-radius:0!important}
body.kyyeu-standalone :is(.tk-label,.ticket-meta span,.ticket-row span){font-size:10.5px;color:#5E7480}
body.kyyeu-standalone.kyyeu-theme-trien-lam :is(.plate-meta span,.plaque-no){color:#6F6A62;font-size:10.5px}
/* 32 Thủy mặc: vệt mực trang trí đè lên dòng nhãn và dòng thông tin trên điện thoại → đưa ra sau chữ, nhạt bớt. */
@media (max-width:640px){ body.kyyeu-standalone.kyyeu-theme-thuy-mac :is(.ink-drops,.ink-splash){opacity:.3} }
/* 35: bảng liên hệ 7 khung — hàng cuối canh giữa, không hở ô. */
body.kyyeu-standalone .contact-sheet{display:flex!important;flex-wrap:wrap;justify-content:center}
body.kyyeu-standalone .contact-sheet > *{flex:0 0 calc((100% - 18px) / 4);min-width:0}
/* 36: hàng tiêu đề bảng thời tiết cao thừa; chữ gợi ý mờ. */
body.kyyeu-standalone .wl-head{align-items:center;min-height:0;padding-top:9px;padding-bottom:9px;font-size:10.5px;color:#9DB6C2}
body.kyyeu-standalone .wl-head > :nth-child(3){display:none}
body.kyyeu-standalone :is(.wipe-hint,.rain-lyric){color:#9DB6C2;opacity:1}
/* 40: nhãn mốc thủy triều cách thẻ bên dưới; chữ gợi ý trên cát. 41: tên người gửi cam nhạt (2.1:1), gợi ý mờ. */
body.kyyeu-standalone .tide-track{margin-bottom:46px}
body.kyyeu-standalone .sand-hint{color:rgba(92,64,28,.85)}
body.kyyeu-standalone .warm-note cite{color:#A85A2A}
body.kyyeu-standalone :is(.breath-hint,.frost-hint){color:#5E7C8E}
/* 45: thẻ sao — sao bên trái, tên và lời khen cùng một dòng (trước đây 3 cột hẹp, lời khen gãy 2 dòng). */
@media (max-width:640px){
  body.kyyeu-standalone .star-board{grid-template-columns:1fr!important}
  body.kyyeu-standalone .star-board > *{grid-column:auto!important;display:grid;grid-template-columns:auto auto minmax(0,1fr);align-items:center;column-gap:10px;text-align:left;padding:12px 14px}
  body.kyyeu-standalone .star-board .sc-star{margin:0;font-size:22px}
}
body.kyyeu-standalone.kyyeu-theme-dia-dang .section-icon{color:#B46A8E;font-family:'Segoe UI Symbol','Apple Symbols','Noto Sans Symbols 2','DejaVu Sans',sans-serif;font-variant-emoji:text}
body.kyyeu-standalone .map-pin .pin-label{font-family:inherit}
/* 02: vòng ảnh bìa cách tên lớp xa hơn. 05: bốn chấm vàng lẻ loi trên nền (trông như bụi bẩn) → bỏ. 09: lớp sao nền dịu lại để không lẫn với dấu chữ. */
body.kyyeu-standalone.kyyeu-theme-nang-san-truong .lens{margin-bottom:84px}
body.kyyeu-standalone.kyyeu-theme-da-tiec{background-image:none}
@media (max-width:640px){ body.kyyeu-standalone.kyyeu-theme-ngan-ha :is(.stars,.stars2,.stars3){opacity:.5} }
/* 17: chữ số viết tay dính nhau ("1.095"); thanh chữ thập của cửa sổ thò ra ngoài khung. */
body.kyyeu-standalone .stat-chip strong{letter-spacing:.05em;font-variant-numeric:lining-nums}
body.kyyeu-standalone.kyyeu-theme-khung-cua .window::before{top:16px;bottom:16px}
body.kyyeu-standalone.kyyeu-theme-khung-cua .window::after{left:16px;right:16px}
/* 18: vạch đường nét đứt chạy xuyên qua chữ của các trạm → chữ có nền riêng nằm trên vạch. */
body.kyyeu-standalone .stop-text{position:relative;z-index:1;background:rgba(255,250,244,.9);padding:5px 9px;border-radius:9px}
body.kyyeu-standalone .road-line{z-index:0}
/* 21: viền màn chiếu chỉ cách mép màn hình 2px → thu viền, thẳng lề chung; số trang ảnh có nền để đọc được trên ảnh sáng. */
@media (max-width:640px){ body.kyyeu-standalone .screen{box-shadow:0 0 0 5px #1A1420,0 20px 50px rgba(0,0,0,.5);margin-left:5px;margin-right:5px} }
body.kyyeu-standalone .screen-controls span{background:rgba(0,0,0,.5);padding:2px 9px;border-radius:10px;color:#F3D27A}
/* 24: thanh trượt thẳng lề với khung ảnh. 28: hai đèn lồng cao bằng nhau. 29: chữ ghi chú cách vạch kẻ dọc. */
body.kyyeu-standalone #timeSlider{width:100%!important;max-width:100%!important;margin-left:0;margin-right:0;box-sizing:border-box}
body.kyyeu-standalone .lantern-field{align-items:stretch}
body.kyyeu-standalone .lantern-field .lantern{display:flex;flex-direction:column}
body.kyyeu-standalone .lantern-field .lantern-body{flex:1 1 auto;display:flex;flex-direction:column;justify-content:center}
html body.kyyeu-standalone .field-notes .field-note{padding-left:28px!important}
/* 21 Rạp chiếu phim: người bật "Giảm chuyển động" trên máy thì danh sách cảm ơn cuối phim biến mất (hoạt ảnh cuộn bị ép về 0,001 giây).
   Khi đó hiện danh sách đứng yên, đầy đủ. */
@media (prefers-reduced-motion: reduce){
  body.kyyeu-standalone .credits-window{height:auto;-webkit-mask-image:none;mask-image:none;overflow:visible}
  body.kyyeu-standalone .credits-roll{position:static;animation:none!important;transform:none!important}
}
/* 36: ba "đồ ngày mưa" xếp 2+1 (một chip lẻ hàng dưới) → trên điện thoại xếp thành cột, mỗi chip một dòng, canh giữa. */
@media (max-width:480px){ body.kyyeu-standalone .rain-items{flex-direction:column;align-items:center} }
@media (max-width:640px){ body.kyyeu-standalone .lantern-field .lantern-glow{inset:-8px} }
/* Chú thích ảnh để trống (lớp không ghi chú thích): không hiện dải màu/khung trống dưới hoặc trên ảnh. */
body.kyyeu-standalone :is(figcaption, .hex-cap, .bloom-cap, .coffee-cap, .tilt-cap):empty{display:none}
/* ===== Bản 2.17.0 ===== */
/* Lưới chẵn/lẻ trên máy tính: ô cuối đứng một mình → nằm giữa hàng (mẫu 23, 34, 44), lưới 4 cột dư 1 (mẫu 26), 4 con số (mẫu 17). */
@media (min-width:761px){
  body.kyyeu-standalone :is(.wish-grid,.sound-grid,.kid-notes)>:last-child:nth-child(odd):not(:only-child){grid-column:1/-1;max-width:50%;justify-self:center;width:100%}
  body.kyyeu-standalone .archive-grid>:last-child:nth-child(4n+1):not(:only-child){grid-column:1/-1;justify-self:center;width:25%}
}
@media (min-width:761px){ body.kyyeu-standalone.kyyeu-theme-khung-cua .stat-row{max-width:760px;flex-wrap:nowrap} }
/* ----- 2.17.0: bài viết và trang nội dung ----- */
/* Bảng trên điện thoại: cuộn ngang trong khung thay vì mỗi ô một chữ. */
@media (max-width:600px){
  html body :is(.entry-content,.article-content) table{display:block;max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch;font-size:14px;line-height:1.45}
  html body :is(.entry-content,.article-content) :is(th,td){min-width:8em;padding:8px 10px}
}
/* Bảng trên máy tính: cỡ chữ như thân bài, cột đầu không gãy dòng, có khoảng cách dưới. */
@media (min-width:768px){
  html body #main#main .entry-content table{margin:0 0 1.5em;font-size:inherit}
  html body #main#main .entry-content table :is(th,td){text-wrap:pretty}
  html body #main#main .entry-content table :is(th,td):first-child{white-space:nowrap}
}
/* Độ dài dòng chữ bài viết trên máy tính: khoảng 70 ký tự/dòng (trước đây 130–155). */
@media (min-width:768px){
  html body:not(.category-album-ky-yeu) #main#main .entry-content .article-detail,
  html body:not(.category-album-ky-yeu) #main#main .entry-content > .article-content{max-width:46rem!important;margin-left:auto!important;margin-right:auto!important}
}
/* Thứ bậc tiêu đề: H1 > H2 > H3. */
@media (min-width:768px){
  html body.single-post #main#main .hero-section .page-title,html body.page #main#main .hero-section .page-title{font-size:clamp(34px,3.2vw,46px)!important;line-height:1.15!important}
  html body #main#main .entry-content .article-detail h2,html body #main#main .entry-content > .article-content h2{font-size:clamp(26px,2.2vw,32px)!important;line-height:1.25!important}
  html body #main#main .entry-content .article-detail h3,html body #main#main .entry-content > .article-content h3{font-size:clamp(20px,1.6vw,24px)!important;line-height:1.3!important}
}
/* Thẻ bài viết (Cẩm nang, chuyên mục, tìm kiếm): tiêu đề tối đa 2 dòng, không bị cắt; thẻ có lề trong. */
html body .entries .entry-card .entry-title{overflow-wrap:anywhere;text-wrap:balance}
html body .entries .entry-card .entry-title a{font-size:inherit!important;white-space:normal!important}
@media (min-width:768px){
  html body #main#main .entries > article.entry-card{padding:20px 20px 22px!important}
  html body #main#main .entries > article.entry-card .entry-title{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:2.6em}
  html body.category #main .ct-pagination{max-width:1180px;margin:40px auto 72px!important;padding-inline:clamp(24px,5vw,68px)}
}
/* Bài album: quy tắc trong "CSS bổ sung" vô tình áp vào cả <body> (lùi 4px, bo góc) → trả lại toàn chiều rộng. */
html body.single-post.single-post{margin:0!important;width:auto!important;max-width:none!important;border-radius:0!important}
/* Trang chủ: ảnh thu nhỏ lấp đầy khung (không còn dải màu be dưới ảnh). */
html body .kui-home-anh > span > img,html body .kui-tc-the > span > img{height:100%!important;border-radius:0!important}
/* Trang nhà cung cấp: dòng nhãn "CÁCH THAM GIA" đọc được. */
html body .ky-provider-process .eyebrow{color:#7a5a26!important}
/* Tiêu đề trang chủ: "Kỷ yếu của lớp mình," trọn một dòng trên máy tính. */
@media (min-width:768px){ html body.home #main #cv-hero-title{max-width:none!important;font-size:clamp(44px,4.6vw,66px)!important;text-wrap:balance} }
/* Đầu trang riêng (kyyeu-ui) ở màn hình 320px: không tràn ngang. */
@media (max-width:360px){
  .kui-top .kui-wrap{gap:8px}
  .kui-nav{gap:10px;font-size:13px}
  .kui-top .kui-logo{flex:0 1 auto;min-width:0}
  .kui-top .kui-logo svg,.kui-top .kui-logo img{max-width:118px;height:auto}
}
