/* Hiệu ứng động trang chủ, dùng chung cho index.html và khung xem trước trong Cổng nội bộ (covers.js).
   Logo cá heo: .emb (mặc định = cá heo nhảy sóng) + .emb-fx-float / -spin / -pulse / -none.
   Tiêu đề Nhà nước kiến tạo: .kt-head.tfx.tfx-KIEU (+ .tfx-on khi đang phát); site-fx.js tách chữ thành từ (.tw) và ký tự (.tl). */
/* Logo cá heo chuyển động: nhảy vào sân khấu → bơi nhấp nhô → định kỳ tung mình xoay vòng, đáp xuống tạo gợn sóng và bọt nước; ánh sáng lướt qua đúng hình logo */
.emb{position:relative; flex:none; width:88px; aspect-ratio:1; display:block;}
.emb img{width:100%; height:auto; display:block;}
.emb-fish{position:absolute; inset:0; z-index:2; transform-origin:50% 60%; animation:embLeapIn 1.4s cubic-bezier(.2,.9,.3,1.25) both, embSwim 9s ease-in-out 1.4s infinite;}
.emb-shine{position:absolute; inset:0; pointer-events:none; background:linear-gradient(115deg,transparent 38%,rgba(255,255,255,.7) 50%,transparent 62%) no-repeat; background-size:260% 100%; background-position:160% 0;
  -webkit-mask:url(emblem.png?v=2) center/contain no-repeat; mask:url(emblem.png?v=2) center/contain no-repeat; animation:embShine 9s ease-in-out 1.4s infinite;}
.emb-ring{position:absolute; left:50%; bottom:-4%; width:110%; height:23%; margin-left:-55%; border-radius:50%; border:2px solid rgba(18,164,221,.55); opacity:0; z-index:1; animation:embRing 9s ease-out 1.4s infinite;}
.emb-ring.r2{border-color:rgba(240,122,38,.45); animation-delay:1.6s;}
.emb-drop{position:absolute; left:50%; bottom:-2px; width:6px; height:8px; border-radius:50% 50% 50% 50%/60% 60% 40% 40%; background:linear-gradient(#bfeaff,#12a4dd); opacity:0; z-index:3;}
.emb-drop.d1{animation:embDrop1 9s ease-out 1.4s infinite;} .emb-drop.d2{animation:embDrop2 9s ease-out 1.4s infinite;} .emb-drop.d3{animation:embDrop3 9s ease-out 1.4s infinite;}
.emb-bub{position:absolute; left:78%; top:16%; width:8px; height:8px; border-radius:50%; background:radial-gradient(circle at 35% 35%,#fff 0 30%,rgba(255,255,255,.35) 45%,rgba(18,164,221,.25) 70%); border:1px solid rgba(255,255,255,.9); opacity:0; z-index:3; animation:embBub 4.2s ease-in 2s infinite;}
.emb-bub.b2{width:5px; height:5px; animation-delay:3.3s;} .emb-bub.b3{width:6px; height:6px; animation-delay:4.6s;}
.emb-spark{position:absolute; width:10px; height:10px; background:#ffb62e; clip-path:polygon(50% 0,62% 38%,100% 50%,62% 62%,50% 100%,38% 62%,0 50%,38% 38%); opacity:0; z-index:3; animation:embSpark 3s ease-in-out infinite;}
.emb-spark.s1{left:-6px; top:10%; animation-delay:1.8s;} .emb-spark.s2{right:-8px; top:46%; width:8px; height:8px; background:#12a4dd; animation-delay:2.8s;} .emb-spark.s3{left:20%; top:-8px; width:7px; height:7px; background:#f07a26; animation-delay:3.8s;}
@keyframes embLeapIn{0%{opacity:0; transform:translate(-26px,46px) rotate(-70deg) scale(.4);} 55%{opacity:1; transform:translate(4px,-16px) rotate(14deg) scale(1.1);} 78%{transform:translate(0,3px) rotate(-5deg) scale(.97);} 100%{opacity:1; transform:none;}}
@keyframes embSwim{0%,100%{transform:perspective(400px) translateY(0px) rotate(0deg) rotateY(0deg) scale(1,1);} 14%{transform:perspective(400px) translateY(-6px) rotate(-4deg) rotateY(0deg) scale(1,1);} 28%{transform:perspective(400px) translateY(0px) rotate(2deg) rotateY(0deg) scale(1,1);} 42%{transform:perspective(400px) translateY(-6px) rotate(-4deg) rotateY(0deg) scale(1,1);} 56%{transform:perspective(400px) translateY(0px) rotate(1deg) rotateY(0deg) scale(1,1);}
  64%{transform:perspective(400px) translateY(3px) rotate(6deg) rotateY(0deg) scale(0.96,1.04);} 72%{transform:perspective(400px) translateY(-22px) rotate(-16deg) rotateY(0deg) scale(1.05,1.05);} 79%{transform:perspective(400px) translateY(-27px) rotate(-4deg) rotateY(180deg) scale(1.06,1.06);} 86%{transform:perspective(400px) translateY(-9px) rotate(13deg) rotateY(360deg) scale(1.03,1.03);} 91%{transform:perspective(400px) translateY(3px) rotate(3deg) rotateY(360deg) scale(1.05,0.94);} 95%{transform:perspective(400px) translateY(-2px) rotate(0deg) rotateY(360deg) scale(1,1);} 99.99%{transform:perspective(400px) translateY(0px) rotate(0deg) rotateY(360deg) scale(1,1);}}
@keyframes embShine{0%,30%{background-position:160% 0;} 46%{background-position:-60% 0;} 100%{background-position:-60% 0;}}
@keyframes embRing{0%,87%{opacity:0; transform:scale(.3);} 89%{opacity:1; transform:scale(.45);} 100%{opacity:0; transform:scale(1.5);}}
@keyframes embDrop1{0%,88%{opacity:0; transform:translate(0,0) scale(.6);} 90%{opacity:1;} 95%{transform:translate(-26px,-26px) rotate(-30deg) scale(1);} 100%{opacity:0; transform:translate(-36px,2px) rotate(-60deg) scale(.6);}}
@keyframes embDrop2{0%,88%{opacity:0; transform:translate(0,0) scale(.6);} 90%{opacity:1;} 95%{transform:translate(4px,-36px) scale(1);} 100%{opacity:0; transform:translate(6px,-6px) scale(.6);}}
@keyframes embDrop3{0%,88%{opacity:0; transform:translate(0,0) scale(.6);} 90%{opacity:1;} 95%{transform:translate(30px,-24px) rotate(30deg) scale(1);} 100%{opacity:0; transform:translate(40px,4px) rotate(60deg) scale(.6);}}
@keyframes embBub{0%{opacity:0; transform:translate(0,0) scale(.3);} 15%{opacity:.95;} 100%{opacity:0; transform:translate(10px,-40px) scale(1.15);}}
@keyframes embSpark{0%,100%{opacity:0; transform:scale(.2) rotate(0);} 45%{opacity:1; transform:scale(1) rotate(45deg);} 70%{opacity:0; transform:scale(.4) rotate(90deg);}}

@media (prefers-reduced-motion:reduce){ .emb-fish,.emb-shine,.emb-ring,.emb-drop,.emb-bub,.emb-spark{animation:none !important;} .emb-ring,.emb-drop,.emb-bub,.emb-spark{display:none;} }

/* ---------- các kiểu logo khác ---------- */
.emb-fx-float .emb-fish{animation:embLeapIn 1.4s cubic-bezier(.2,.9,.3,1.25) both, embFloat 5.5s ease-in-out 1.4s infinite;}
.emb-fx-float .emb-shine{animation-duration:5.5s;}
.emb-fx-float .emb-ring,.emb-fx-float .emb-drop{display:none;}
.emb-fx-float .emb-bub{animation-duration:3.2s;}
@keyframes embFloat{0%,100%{transform:translate(0,0) rotate(0);} 25%{transform:translate(2px,-7px) rotate(-3deg);} 50%{transform:translate(0,-10px) rotate(1deg);} 75%{transform:translate(-2px,-5px) rotate(3deg);}}
.emb-fx-spin .emb-fish{animation:embLeapIn 1.4s cubic-bezier(.2,.9,.3,1.25) both, embSpin 7s cubic-bezier(.65,0,.35,1) 1.4s infinite;}
.emb-fx-spin .emb-shine{animation:embShineSpin 7s ease-in-out 1.4s infinite;}
.emb-fx-spin .emb-ring,.emb-fx-spin .emb-drop,.emb-fx-spin .emb-bub{display:none;}
@keyframes embSpin{0%,55%{transform:perspective(400px) translateY(0) rotateY(0deg) scale(1);} 70%{transform:perspective(400px) translateY(-6px) rotateY(180deg) scale(1.06);} 85%,99.99%{transform:perspective(400px) translateY(0) rotateY(360deg) scale(1);} 100%{transform:perspective(400px) translateY(0) rotateY(0deg) scale(1);}}
@keyframes embShineSpin{0%,85%{background-position:160% 0;} 97%,100%{background-position:-60% 0;}}
.emb-fx-pulse .emb-fish{animation:embLeapIn 1.4s cubic-bezier(.2,.9,.3,1.25) both, embBeat 2.4s ease-in-out 1.4s infinite;}
.emb-fx-pulse .emb-ring{left:6%; right:6%; top:6%; bottom:6%; width:auto; height:auto; margin:0; animation:embPulseRing 2.4s ease-out 1.4s infinite;}
.emb-fx-pulse .emb-ring.r2{animation-delay:1.7s;}
.emb-fx-pulse .emb-drop,.emb-fx-pulse .emb-bub{display:none;}
@keyframes embBeat{0%,48%,100%{transform:scale(1);} 10%{transform:scale(1.09);} 20%{transform:scale(.98);} 30%{transform:scale(1.06);}}
@keyframes embPulseRing{0%{opacity:.85; transform:scale(.85);} 80%,100%{opacity:0; transform:scale(1.55);}}
.emb-fx-none .emb-fish,.emb-fx-none .emb-shine{animation:none;}
.emb-fx-none .emb-ring,.emb-fx-none .emb-drop,.emb-fx-none .emb-bub,.emb-fx-none .emb-spark{display:none;}

/* ---------- tiêu đề: phần dùng chung ---------- */
.tfx .kt-eye{display:table; margin-left:auto; margin-right:auto; position:relative;}
.tfx .kt-eye::after{content:''; position:absolute; left:4%; right:4%; bottom:-3px; height:3px; border-radius:3px; background:linear-gradient(90deg,transparent,#f07a26 18%,#ffb62e 60%,transparent); transform:scaleX(0); transform-origin:left;}
.tfx.tfx-on .kt-eye{animation:tfEyeIn 1.1s cubic-bezier(.3,.7,.2,1) both;}
.tfx.tfx-on .kt-eye::after{animation:tfLine .9s cubic-bezier(.3,.7,.2,1) .8s both;}
.tfx-none .kt-eye::after{display:none;} .tfx-none.tfx-on .kt-eye{animation:none;}
.tfx :is(h2,.tfx-h) .tw{display:inline-block; white-space:nowrap;}
.tfx :is(h2,.tfx-h) .tl{display:inline-block;}
.tfx :is(h2,.tfx-h) .tw,.tfx :is(h2,.tfx-h) .tl{color:inherit;}   /* trang chủ tô cam mọi "h2 span": chữ đã tách phải giữ màu của dòng chứa nó */
@keyframes tfEyeIn{from{clip-path:inset(0 100% 0 0); transform:translateX(-10px);} to{clip-path:inset(0 0 0 0); transform:none;}}
@keyframes tfLine{to{transform:scaleX(1);}}

/* 1. Cực quang: từng từ bay lên rõ dần, phần chữ cam chuyển sắc như dải cực quang */
.tfx-aurora.tfx-on :is(h2,.tfx-h) .tw{animation:tfRise .8s cubic-bezier(.2,.8,.2,1) both; animation-delay:calc(var(--w) * 70ms + .35s);}
.tfx-aurora :is(h2,.tfx-h) .thl .tl,.tfx-aurora.tfx-flat :is(h2,.tfx-h) .thl{background:linear-gradient(90deg,#f07a26,#ffb62e,#ff5f6d,#ff8a00,#f07a26); background-size:500% 100%; -webkit-background-clip:text; background-clip:text; color:transparent; -webkit-text-fill-color:transparent;}
.tfx-aurora.tfx-on :is(h2,.tfx-h) .thl .tl,.tfx-aurora.tfx-on.tfx-flat :is(h2,.tfx-h) .thl{animation:tfFlow 5s linear infinite; animation-delay:calc(var(--i, 0) * -90ms);}
@keyframes tfRise{from{opacity:0; transform:translateY(.6em) rotateX(55deg); filter:blur(6px);} to{opacity:1; transform:none; filter:none;}}
@keyframes tfFlow{from{background-position:0% 0;} to{background-position:100% 0;}}

/* 2. Sóng vỗ: từng chữ nhấp nhô nối tiếp như sóng biển */
.tfx-wave.tfx-on :is(h2,.tfx-h) .tl{animation:tfWave 2.8s ease-in-out infinite; animation-delay:calc(var(--i) * 55ms);}
.tfx-wave :is(h2,.tfx-h) .thl{text-shadow:0 6px 14px rgba(240,122,38,.25);}
@keyframes tfWave{0%,55%,100%{transform:translateY(0);} 18%{transform:translateY(-.2em) rotate(-3deg);} 36%{transform:translateY(.05em) rotate(1deg);}}

/* 3. Gõ chữ: chữ hiện lần lượt như đang gõ, con trỏ nhấp nháy ở cuối */
/* không dùng steps(1): Chrome làm tròn tiến độ 0.99999… → chữ từ khoảng thứ 31 trở đi đứng yên ở trạng thái ẩn ("…trở thành n" rồi mất chữ) */
.tfx-typing.tfx-on :is(h2,.tfx-h) .tl{animation:tfType 20ms linear both; animation-delay:calc(var(--i) * 45ms + .6s);}
.tfx-typing :is(h2,.tfx-h)::after{content:''; display:inline-block; width:.09em; height:.95em; margin-left:.08em; vertical-align:-.12em; border-radius:2px; background:#f07a26; opacity:0;}
/* con trỏ chạy theo chữ vừa gõ (trước đây nằm cố định ở cuối dòng, cách xa chữ đang gõ → trông như lỗi chữ);
   gõ xong mới hiện con trỏ nhấp nháy sau chữ cuối */
.tfx-typing.tfx-on :is(h2,.tfx-h)::after{animation:tfCaret .9s steps(1) infinite; animation-delay:calc(var(--n,0) * 45ms + .6s);}
.tfx-typing :is(h2,.tfx-h) .tl{position:relative;}
.tfx-typing :is(h2,.tfx-h) .tl::after{content:''; position:absolute; left:100%; top:.1em; width:.09em; height:.95em; margin-left:.03em; border-radius:2px; background:#f07a26; opacity:0; pointer-events:none;}
.tfx-typing.tfx-on :is(h2,.tfx-h) .tl::after{animation:tfCur 45ms linear; animation-delay:calc(var(--i) * 45ms + .6s);}
@keyframes tfCur{from,to{opacity:1;}}
@keyframes tfType{0%,30%{opacity:0;} 31%,100%{opacity:1;}}
@keyframes tfCaret{0%,49%{opacity:1;} 50%,100%{opacity:0;}}

/* 4. Đèn neon: phần chữ cam bật sáng chập chờn rồi phát sáng đều như biển neon */
.tfx-neon :is(h2,.tfx-h){text-shadow:0 0 18px rgba(255,255,255,.9),0 0 2px rgba(255,255,255,.9);}
.tfx-neon :is(h2,.tfx-h) .thl{color:#ff7a1a;}
.tfx-neon.tfx-on :is(h2,.tfx-h) .thl{animation:tfFlicker 1.3s linear .4s both, tfNeon 2.6s ease-in-out 1.7s infinite;}
@keyframes tfFlicker{0%,18%,22%,40%,44%,100%{opacity:1; text-shadow:0 0 4px rgba(255,255,255,.3),0 0 12px rgba(255,122,26,.75),0 0 26px rgba(255,90,20,.5);} 20%,42%{opacity:.35; text-shadow:none;}}
@keyframes tfNeon{0%,100%{text-shadow:0 0 3px rgba(255,255,255,.6),0 0 10px rgba(255,122,26,.65),0 0 24px rgba(255,90,20,.45);} 50%{text-shadow:0 0 4px rgba(255,255,255,.9),0 0 16px rgba(255,140,40,.95),0 0 40px rgba(255,90,20,.7),0 0 64px rgba(255,90,20,.35);}}

/* 5. Ánh kim lướt: vệt sáng kim loại chạy qua từng chữ */
.tfx-shine :is(h2,.tfx-h) .tl,.tfx-shine.tfx-flat :is(h2,.tfx-h),.tfx-shine.tfx-flat :is(h2,.tfx-h) .thl{--c:#0f3a75; background:linear-gradient(110deg,var(--c) 0 42%,#bfe6ff 47%,#ffffff 50%,#bfe6ff 53%,var(--c) 58% 100%); background-size:350% 100%; background-position:100% 0; -webkit-background-clip:text; background-clip:text; color:transparent; -webkit-text-fill-color:transparent;}
.tfx-shine :is(h2,.tfx-h) .thl .tl,.tfx-shine.tfx-flat :is(h2,.tfx-h) .thl{--c:#e8611a;}
.tfx-shine.tfx-on :is(h2,.tfx-h) .tl,.tfx-shine.tfx-on.tfx-flat :is(h2,.tfx-h),.tfx-shine.tfx-on.tfx-flat :is(h2,.tfx-h) .thl{animation:tfShine 4.5s ease-in-out infinite; animation-delay:calc(var(--i, 0) * 28ms + .3s);}
@keyframes tfShine{0%{background-position:100% 0;} 40%,100%{background-position:0% 0;}}

/* 6. Nảy chữ: từng chữ rơi xuống nảy lên, rồi bút dạ quang tô sáng phần chữ cam */
.tfx-bounce.tfx-on :is(h2,.tfx-h) .tl{animation:tfDrop .7s cubic-bezier(.3,1.6,.5,1) both; animation-delay:calc(var(--i) * 26ms + .3s);}
.tfx-bounce :is(h2,.tfx-h) .thl{background:linear-gradient(transparent 60%,rgba(255,196,64,.55) 60%,rgba(255,196,64,.55) 94%,transparent 94%) no-repeat 0 0 / 0% 100%; -webkit-box-decoration-break:clone; box-decoration-break:clone; padding:0 .06em;}
.tfx-bounce.tfx-on :is(h2,.tfx-h) .thl{animation:tfMark .9s ease-out both; animation-delay:calc(var(--n, 40) * 26ms + .8s);}
@keyframes tfDrop{0%{opacity:0; transform:translateY(-1.1em) rotate(-14deg);} 60%{opacity:1; transform:translateY(.1em) rotate(3deg);} 80%{transform:translateY(-.04em);} 100%{opacity:1; transform:none;}}
@keyframes tfMark{to{background-size:100% 100%;}}

@media (prefers-reduced-motion:reduce){ .tfx .kt-eye,.tfx .kt-eye::after,.tfx :is(h2,.tfx-h),.tfx :is(h2,.tfx-h) *,.tfx :is(h2,.tfx-h)::after{animation:none !important;} .tfx .kt-eye::after{transform:none;} .tfx-bounce :is(h2,.tfx-h) .thl{background-size:100% 100%;} }

/* ---------- logo cá heo + DAHALA TRAVEL đặt trên ảnh bìa (site_covers.brand) ---------- */
.cv-brand{position:absolute; z-index:7; display:flex; align-items:center; gap:clamp(6px,.9vw,12px); padding:clamp(4px,.6vw,8px) clamp(12px,1.5vw,20px) clamp(4px,.6vw,8px) clamp(6px,.8vw,10px); border-radius:999px; background:rgba(255,255,255,.74); -webkit-backdrop-filter:blur(8px) saturate(1.2); backdrop-filter:blur(8px) saturate(1.2); border:1px solid rgba(255,255,255,.9); box-shadow:0 12px 28px -16px rgba(15,58,117,.6); pointer-events:none; animation:cvbIn .9s cubic-bezier(.2,.9,.3,1.2) both;}
.cv-brand .emb{width:clamp(34px,4.4vw,62px);}
.cvb-name{display:block; font-family:'Be Vietnam Pro',system-ui,sans-serif; font-weight:800; font-size:clamp(13px,1.65vw,23px); line-height:.98; letter-spacing:.3px; color:#0f3a75; white-space:nowrap;}
.cvb-name span{display:block; color:#12a4dd;}
.cv-brand.p-tl{top:4%; left:2%;} .cv-brand.p-tr{top:4%; right:2%;} .cv-brand.p-top{top:4%; left:50%; translate:-50% 0;}
.cv-brand.p-bl{bottom:6%; left:2%;} .cv-brand.p-br{bottom:6%; right:2%;}
@keyframes cvbIn{from{opacity:0; transform:translateY(-10px) scale(.92);} to{opacity:1; transform:none;}}
@media (max-width:640px){ .cv-brand{padding:3px 10px 3px 4px; gap:5px;} .cv-brand .emb{width:30px;} .cvb-name{font-size:11.5px;} .cv-brand .emb-drop,.cv-brand .emb-bub,.cv-brand .emb-spark{display:none;} }
@media (prefers-reduced-motion:reduce){ .cv-brand{animation:none;} }

/* ---------- tiêu đề động đặt trên ảnh bìa (site_covers.kt_*) ---------- */
.cv-kt.kt-head{position:absolute; z-index:6; left:50%; translate:-50% 0; width:min(80%,900px); max-width:none; margin:0; padding:1.1cqw 2.6cqw 1.5cqw; text-align:center; border-radius:2cqw; background:rgba(255,255,255,.72); -webkit-backdrop-filter:blur(8px) saturate(1.15); backdrop-filter:blur(8px) saturate(1.15); border:1px solid rgba(255,255,255,.85); box-shadow:0 1.6cqw 3.4cqw -2.2cqw rgba(15,58,117,.6); pointer-events:none;}
.cv-kt.p-top{top:5%;} .cv-kt.p-middle{top:50%; translate:-50% -50%;} .cv-kt.p-bottom{bottom:9%;}
.cv-kt .kt-eye{margin:0 auto .2cqw; font-family:'Dancing Script',cursive; font-weight:700; font-size:clamp(12px,2.3cqw,30px); line-height:1.2; color:#f07a26;}
.cv-kt h2{margin:0; font-weight:800; font-size:clamp(14px,3.3cqw,44px); line-height:1.18; color:#0f3a75; text-wrap:balance;}
.cv-kt h2 .thl{color:#d9631a;}
@media (max-width:640px){ .cv-kt.kt-head{width:88%; padding:5px 10px 7px; border-radius:12px;} }
/* logo và tiêu đề cùng ở phía trên: tiêu đề tự thu hẹp (logo ở góc) hoặc dịch xuống (logo ở giữa) để không chồng nhau */
.cv-fr:has(> .cv-brand.p-tl) > .cv-kt.p-top,.cv-fr:has(> .cv-brand.p-tr) > .cv-kt.p-top{width:min(56%,720px);}
.cv-fr:has(> .cv-brand.p-tl) > .cv-kt.p-top{left:auto; right:3%; translate:none;}
.cv-fr:has(> .cv-brand.p-tr) > .cv-kt.p-top{left:3%; translate:none;}
.cv-fr:has(> .cv-brand.p-top) > .cv-kt.p-top{top:30%;}
.cv-fr:has(> .cv-brand.p-bl) > .cv-kt.p-bottom,.cv-fr:has(> .cv-brand.p-br) > .cv-kt.p-bottom{width:min(56%,720px);}
.cv-fr:has(> .cv-brand.p-bl) > .cv-kt.p-bottom{left:auto; right:3%; translate:none;}
.cv-fr:has(> .cv-brand.p-br) > .cv-kt.p-bottom{left:3%; translate:none;}
/* điện thoại: mép trên ảnh bìa nằm sát thanh menu, đẩy logo / tiêu đề phía trên xuống để không bị che */
@media (max-width:640px){ .cv-fr > .cv-brand.p-tl,.cv-fr > .cv-brand.p-tr,.cv-fr > .cv-brand.p-top{top:calc(4% + 14px);} .cv-fr > .cv-kt.p-top{top:calc(5% + 12px);} }

/* ---------- hiệu ứng động chạy trên khung tiêu đề của ảnh bìa (.cv-cap, tiêu đề = .tfx-h): giữ màu của kiểu khung đã chọn ---------- */
.cv-cap .cv-eb + .tfx-h,.cv-cap .tfx-h{display:block;}
.cv-cap.tfx-shine .tfx-h .tl,.cv-cap.tfx-shine .tfx-h .thl .tl{background:none; color:inherit; -webkit-text-fill-color:currentColor; animation:none;}
.cv-cap.tfx-shine .tfx-h .thl .tl{color:var(--hl,#ff8a2a);}
.cv-cap.tfx-shine.tfx-on .tfx-h .tl{animation:tfGlint 4.5s ease-in-out infinite; animation-delay:calc(var(--i) * 32ms + .3s);}
.cv-cap.tfx-shine.tfx-flat .tfx-h,.cv-cap.tfx-shine.tfx-flat .tfx-h .thl{background:none; color:inherit; -webkit-text-fill-color:currentColor;}
.cv-cap.tfx-shine.tfx-on.tfx-flat .tfx-h{animation:tfGlint 4.5s ease-in-out infinite;}
@keyframes tfGlint{0%,14%,100%{filter:none;} 6%{filter:brightness(1.9) drop-shadow(0 0 .22em rgba(255,255,255,.95));}}
.cv-cap.tfx-neon .tfx-h{text-shadow:none;}
.cv-cap.tfx-neon .tfx-h .thl{color:var(--hl,#ff8a2a);}
.cv-cap.tfx-typing .tfx-h::after,.cv-cap.tfx-typing .tfx-h .tl::after{background:var(--ac,#ff8a2a);}
/* khung "chữ ánh kim" tô màu bằng cách cắt nền theo chữ: chữ đã tách phải tự có màu, nếu không sẽ trong suốt */
.cv-cap.cs-gradient.tfx .tfx-h .tl{-webkit-text-fill-color:#fff; color:#fff;}
.cv-cap.cs-gradient.tfx .tfx-h .thl .tl{-webkit-text-fill-color:var(--hl,#ffc93c); color:var(--hl,#ffc93c);}
.cv-cap.cs-gradient.tfx-aurora .tfx-h .thl .tl{-webkit-text-fill-color:transparent; color:transparent;}

/* ---------- nền + kích cỡ logo trên ảnh bìa (site_covers.brand_bg / brand_scale → class bg-*, biến --bs) ---------- */
.cv-brand{gap:calc(clamp(6px,.9vw,12px) * var(--bs,1)); padding:calc(clamp(4px,.6vw,8px) * var(--bs,1)) calc(clamp(12px,1.5vw,20px) * var(--bs,1)) calc(clamp(4px,.6vw,8px) * var(--bs,1)) calc(clamp(6px,.8vw,10px) * var(--bs,1));}
.cv-brand .emb{width:calc(clamp(34px,4.4vw,62px) * var(--bs,1));}
.cv-brand .cvb-name{font-size:calc(clamp(13px,1.65vw,23px) * var(--bs,1));}
/* tách nền: bỏ khung kính, chữ có quầng sáng trắng để vẫn đọc rõ trên ảnh tối */
.cv-brand.bg-clear{background:none; border-color:transparent; box-shadow:none; -webkit-backdrop-filter:none; backdrop-filter:none; padding-left:0; padding-right:0;}
.cv-brand.bg-clear .cvb-name{text-shadow:0 0 2px #fff,0 0 6px rgba(255,255,255,.95),0 0 14px rgba(255,255,255,.8);}
.cv-brand.bg-clear .emb-fish{filter:drop-shadow(0 4px 8px rgba(15,58,117,.4));}
@media (max-width:640px){
  .cv-brand{gap:calc(5px * min(var(--bs,1),1.4)); padding:calc(3px * min(var(--bs,1),1.4)) calc(10px * min(var(--bs,1),1.4)) calc(3px * min(var(--bs,1),1.4)) calc(4px * min(var(--bs,1),1.4));}
  .cv-brand .emb{width:calc(30px * min(var(--bs,1),1.4));} .cv-brand .cvb-name{font-size:calc(11.5px * min(var(--bs,1),1.4));}
  .cv-brand.bg-clear{padding-left:0; padding-right:0;}
}

/* ---------- phần chữ nổi bật trong khung tiêu đề ảnh bìa: màu luôn tương phản với kiểu khung + màu nhấn đã chọn ---------- */
.cv-cap{--hl:var(--ac);}
.cv-cap.cc-white{--hl:#ffd166;}                                   /* màu nhấn trắng: tiêu đề đã trắng nên nổi bật bằng vàng */
.cv-cap.cs-ticket,.cv-cap.cs-postcard{--hl:var(--ak);}             /* khung nền kem: dùng màu nhấn đậm */
.cv-cap.cs-ticket.cc-white,.cv-cap.cs-postcard.cc-white{--hl:#e8701f;}
.cv-cap.cs-gradient{--hl:var(--ac2);} .cv-cap.cs-gradient.cc-white{--hl:#ffd166;}
.cv-cap .tfx-h .thl{color:var(--hl); -webkit-text-fill-color:var(--hl);}
/* khung có nền chính là màu nhấn (ruy băng, hoàng hôn, nét cọ): phần nổi bật thành nhãn trắng chữ màu nhấn đậm */
.cv-cap.cs-ribbon .tfx-h .thl,.cv-cap.cs-sunset .tfx-h .thl,.cv-cap.cs-brush .tfx-h .thl{background:#fff; color:var(--ak); -webkit-text-fill-color:var(--ak); padding:0 .22em; border-radius:.2em; text-shadow:none; -webkit-box-decoration-break:clone; box-decoration-break:clone;}
.cv-cap.cc-white.cs-ribbon .tfx-h .thl,.cv-cap.cc-white.cs-sunset .tfx-h .thl,.cv-cap.cc-white.cs-brush .tfx-h .thl{background:#0f3a75; color:#fff; -webkit-text-fill-color:#fff;}
