/* Hương Tâm — trang khách, bản "một mạch liền" (14/10/2026).
   Không chia khối: nền cả trang đổi màu dần theo cảnh (đêm → bảy sắc → đêm → giấy dó → son → giấy dó).
   Màu, phông theo Bộ nhận diện 1.2. */
:root {
  --do-tram: #741C21; --do-tram-sau: #4E1216; --giay: #F2EADB; --giay-2: #E9DEC9; --giay-sang: #FBF7EF;
  --mun: #2A1B17; --dem: #1a100e; --dong: #B08A4E; --dong-sang: #e2c48a; --tro: #6f655d; --son: #A8322D;
  --f-td: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --f: "Be Vietnam Pro", "Helvetica Neue", Arial, sans-serif;
  --nen: var(--dem); --chu: var(--giay); --chu-phu: #c9bba6; --vach: rgba(242,234,219,.16);
  color-scheme: light;
}
body[data-nen="giay"] { --nen: var(--giay); --chu: var(--mun); --chu-phu: var(--tro); --vach: rgba(42,27,23,.14); }
body[data-nen="son"] { --nen: #3d0f12; }
body[data-nen="mau"] { --nen: var(--mau-hien, #9B2226); --chu: var(--chu-mau, var(--giay)); --chu-phu: var(--chu-mau-phu, #e9dcc6); --vach: rgba(255,255,255,.2); }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body { margin: 0; background: var(--nen); color: var(--chu); font: 300 16px/1.65 var(--f); transition: background-color 1.1s ease, color .8s ease; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--f-td); font-weight: 500; line-height: 1.12; margin: 0; font-variant-numeric: lining-nums; }
h2 { font-size: clamp(40px, 7vw, 84px); letter-spacing: -.01em; }
h2 em, h1 em { font-style: italic; color: var(--dong); }
.nhan { font: 500 11.5px/1.4 var(--f); letter-spacing: .32em; text-transform: uppercase; color: var(--dong); margin: 0 0 18px; }
.an { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
:focus-visible { outline: 2px solid var(--dong); outline-offset: 3px; }
.canh { position: relative; padding: clamp(80px, 14vw, 180px) clamp(16px, 6vw, 96px); }
.dau-muc { margin-bottom: clamp(40px, 8vw, 96px); }

/* Đầu trang trong suốt, đổi logo theo nền */
.dau { position: fixed; top: 0; left: 0; right: 0; z-index: 40; display: flex; align-items: center; gap: 24px; padding: 18px clamp(16px, 4vw, 48px); color: var(--chu); transition: color .8s, background-color .5s, padding .4s; }
.dau.cuon { background: color-mix(in srgb, var(--nen) 82%, transparent); backdrop-filter: blur(10px); padding-top: 12px; padding-bottom: 12px; }
.logo { position: relative; display: block; width: 150px; height: 36px; }
.logo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: left; transition: opacity .6s; }
.logo-sang { opacity: 0; }
body[data-nen="giay"] .logo-sang, body[data-nen="mau"][data-sang="1"] .logo-sang { opacity: 1; } body[data-nen="giay"] .logo-toi, body[data-nen="mau"][data-sang="1"] .logo-toi { opacity: 0; }
.menu { display: none; gap: 28px; margin-left: auto; }
.menu a { text-decoration: none; font-size: 14px; letter-spacing: .04em; position: relative; }
.menu a::after { content: ""; position: absolute; left: 0; right: 100%; bottom: -4px; height: 1px; background: var(--dong); transition: right .35s; }
.menu a:hover::after { right: 0; }
.nut-gio { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.nut-gio b { min-width: 22px; height: 22px; border-radius: 11px; background: var(--son); color: #fff; font: 600 12px var(--f); display: grid; place-items: center; padding: 0 6px; }
@media (min-width: 900px) { .menu { display: flex; } .nut-gio { margin-left: 12px; } }

/* ---------- 1. Mở đầu ---------- */
.mo-dau { min-height: 100svh; display: grid; place-items: center; text-align: center; overflow: hidden; padding-top: 120px; padding-bottom: 120px; }
.khoi-nen { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.may { position: absolute; width: clamp(110px, 16vw, 220px); opacity: .32; pointer-events: none; }
.may-1 { left: 4%; top: 22%; } .may-2 { right: 5%; top: 14%; transform: scaleX(-1); width: clamp(90px, 12vw, 160px); opacity: .22; } .may-3 { right: 12%; bottom: 14%; opacity: .16; }
.nen-lon { position: absolute; left: 50%; bottom: 0; width: 200px; height: 34vh; transform: translateX(-50%); pointer-events: none; }
.nen-lon .than-lon { position: absolute; left: 98px; bottom: 60px; width: 4px; height: calc(var(--con, 1) * (34vh - 110px)); background: linear-gradient(#3a2316, #5b3a24); border-radius: 2px; }
.nen-lon .chan-lon { position: absolute; left: 97px; bottom: 50px; width: 6px; height: 70px; background: #9B2226; border-radius: 3px; }
.nen-lon .dom-lon { position: absolute; left: 92px; bottom: calc(60px + var(--con, 1) * (34vh - 110px) - 8px); width: 16px; height: 16px; border-radius: 50%; background: radial-gradient(#fff4cc, #ff9a3c 45%, rgba(255,90,31,0) 72%); box-shadow: 0 0 40px 14px rgba(255,140,60,.25); animation: chay 1.6s ease-in-out infinite alternate; }
.nen-lon .bat-nho { position: absolute; left: 0; bottom: -10px; width: 200px; }
@keyframes chay { from { opacity: .75; transform: scale(.92); } to { opacity: 1; transform: scale(1.06); } }
.mo-dau-chu { position: relative; z-index: 2; max-width: min(980px, 100%); padding: 0 8px; margin-bottom: 26vh; }
.mo-dau h1 { font-size: clamp(36px, 6.4vw, 92px); font-weight: 500; letter-spacing: -.01em; line-height: 1.15; text-wrap: balance; }
.mo-dau-phu { max-width: 34em; margin: 28px auto 0; color: var(--chu-phu); font-size: clamp(15px, 1.5vw, 18px); }
.goi-cuon { position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%); display: grid; justify-items: center; gap: 10px; font-size: 11px; letter-spacing: .3em; text-transform: uppercase; color: var(--chu-phu); z-index: 2; }
.goi-cuon i { width: 1px; height: 46px; background: linear-gradient(var(--dong), transparent); animation: rot 2s ease-in-out infinite; transform-origin: top; }
@keyframes rot { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* ---------- 2. Bảy sắc ---------- */
.bay-sac { padding: 0; }
.bay-sac-ghim { position: relative; height: 100svh; min-height: 640px; overflow: hidden; display: grid; place-items: center; touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.bay-sac-ghim:active { cursor: grabbing; }
.dai-ten { position: absolute; top: 50%; left: 0; transform: translateY(-50%); display: flex; white-space: nowrap; will-change: transform; pointer-events: none; }
.dai-ten span { font: italic 600 clamp(120px, 24vw, 340px)/1 var(--f-td); color: transparent; -webkit-text-stroke: 1px color-mix(in srgb, var(--chu) 32%, transparent); padding: 0 .25em; }
.cap-hop { position: relative; z-index: 2; display: flex; gap: clamp(40px, 8vw, 120px); align-items: flex-end; }
.cap-hop figure { margin: 0; display: grid; justify-items: center; gap: 22px; }
.cap-hop figcaption { font: 500 15px var(--f); text-align: center; letter-spacing: .04em; }
.cap-hop figcaption small { display: block; font-weight: 300; font-size: 12.5px; opacity: .75; letter-spacing: .02em; }
.cho-hop { position: relative; perspective: 1400px; }
.bay-sac-chu { position: absolute; left: clamp(16px, 6vw, 96px); bottom: clamp(24px, 7vh, 72px); z-index: 3; max-width: 330px; }
.bay-sac-chu .nhan { color: var(--chu); opacity: .85; }
.ten-mau-lon { font: italic 600 clamp(40px, 6vw, 72px)/1 var(--f-td); margin: 0 0 6px; }
.dem-mau { font: 500 13px var(--f); letter-spacing: .2em; margin: 0 0 14px; opacity: .8; }
.dieu-khien { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.mui-ten { width: 44px; height: 44px; border-radius: 50%; border: 1px solid currentColor; background: transparent; color: inherit; font-size: 18px; cursor: pointer; opacity: .8; transition: opacity .2s, transform .2s; }
.mui-ten:hover { opacity: 1; transform: scale(1.08); }
.cham-tien-do { display: flex; gap: 6px; }
.cham-tien-do button { width: 22px; height: 22px; border-radius: 50%; border: 2px solid transparent; padding: 0; cursor: pointer; box-shadow: 0 0 0 1px rgba(255,255,255,.35) inset; transition: transform .25s cubic-bezier(.3,1.6,.5,1), border-color .25s; }
.cham-tien-do button[aria-selected="true"] { border-color: currentColor; transform: scale(1.2); }
.goi-y-vuot { font-size: 12px; opacity: .7; margin: 0 0 12px; letter-spacing: .04em; }
.bay-sac-ghi { font-size: 13.5px; opacity: .8; margin: 0; }
@media (max-width: 760px) {
  .cap-hop { gap: 36px; margin-top: -18vh; }
  .bay-sac-chu { right: 16px; max-width: none; }
  .bay-sac-ghi { display: none; }
}

/* Hộp 3D (dựng từ bản in thật, xem js/hop3d.js) */
.hop3d { position: relative; transform-style: preserve-3d; transform: rotateX(var(--rx, -12deg)) rotateY(var(--ry, -30deg)); }
.hop3d .mat { position: absolute; backface-visibility: hidden; background-repeat: no-repeat; }
.hop3d .mat::after { content: ""; position: absolute; inset: 0; pointer-events: none; }
.hop3d .mat-truoc::after { background: linear-gradient(105deg, rgba(255,255,255,.10), rgba(255,255,255,0) 40%, rgba(0,0,0,.06)); }
.hop3d .mat-phai::after { background: linear-gradient(90deg, rgba(0,0,0,.22), rgba(0,0,0,.36)); }
.hop3d .mat-trai::after { background: rgba(0,0,0,.42); }
.hop3d .mat-sau::after { background: rgba(0,0,0,.3); }
.hop3d .mat-tren::after { background: linear-gradient(rgba(255,255,255,.18), rgba(255,255,255,.02)); }
.hop3d .tem { position: absolute; filter: drop-shadow(0 0 .5px rgba(0,0,0,.25)); }
.hop3d .ke-nap { position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: rgba(0,0,0,.35); }
.bong { position: absolute; left: 50%; bottom: -14px; width: 160%; height: 26px; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(rgba(0,0,0,.38), transparent 68%); filter: blur(2px); pointer-events: none; }

/* ---------- 3. Thắp hương ---------- */
.thap-trong { display: grid; gap: 24px; align-items: center; max-width: 1180px; margin: 0 auto; }
@media (min-width: 900px) { .thap-trong { grid-template-columns: 1.1fr 1fr; } }
.ban-tho { position: relative; width: 100%; max-width: 440px; margin: 0 auto; aspect-ratio: 360 / 590; }
.ban-tho-svg, #khoi { position: absolute; inset: 0; width: 100%; height: 100%; }
#khoi { pointer-events: none; }
.chu-bay { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.chu-bay span { position: absolute; left: 50%; bottom: 52%; transform: translateX(-50%); width: 80%; text-align: center; font: italic 500 24px/1.3 var(--f-td); color: #f2e3c4; animation: bay 9s ease-out forwards; }
@keyframes bay { 0% { opacity: 0; transform: translate(-50%, 20px); filter: blur(2px); } 15% { opacity: 1; filter: blur(0); } 70% { opacity: .85; } 100% { opacity: 0; transform: translate(-50%, -190px); filter: blur(4px); } }
.dom { animation: chay 1.6s ease-in-out infinite alternate; transform-box: fill-box; transform-origin: center; }
.am-hom-nay { color: var(--dong); margin: 14px 0 28px; font-size: 15px; }
.chon-nen { display: flex; margin-bottom: 22px; border-bottom: 1px solid var(--vach); }
.chon-nen button { flex: 1; padding: 12px 0; border: 0; background: none; color: var(--chu-phu); font: 400 15px var(--f); cursor: pointer; position: relative; }
.chon-nen button[aria-checked="true"] { color: var(--chu); }
.chon-nen button[aria-checked="true"]::after { content: ""; position: absolute; left: 20%; right: 20%; bottom: -1px; height: 2px; background: var(--dong); }
.chon-nen button:disabled { opacity: .4; cursor: default; }
.loi-nguyen { display: grid; gap: 4px; margin-bottom: 26px; }
.loi-nguyen span { font-size: 12px; color: var(--chu-phu); letter-spacing: .04em; }
.loi-nguyen input { font: italic 500 22px var(--f-td); padding: 8px 0; border: 0; border-bottom: 1px solid var(--vach); background: none; color: var(--chu); border-radius: 0; }
.loi-nguyen input:focus { outline: none; border-bottom-color: var(--dong); }
.loi-nguyen input::placeholder { color: color-mix(in srgb, var(--chu) 40%, transparent); }
.nut-chau { position: relative; display: flex; align-items: center; gap: 16px; padding: 0; border: 0; background: none; color: var(--chu); font: 500 16px var(--f); cursor: pointer; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; touch-action: none; }
.nut-chau .vong { width: 64px; height: 64px; flex: none; transform: rotate(-90deg); }
.nut-chau .vong circle { fill: rgba(168,50,45,.25); stroke: rgba(242,234,219,.25); stroke-width: 2; }
.nut-chau .vong .tien-do { fill: none; stroke: #f5c56b; stroke-width: 3; stroke-dasharray: 182.2; stroke-dashoffset: 182.2; stroke-linecap: round; }
.nut-chau .lua { position: absolute; left: 19px; color: #f5c56b; }
.nut-chau.dang-giu .vong circle:first-child { fill: rgba(168,50,45,.55); }
.nut-chau.da-thap { cursor: default; opacity: .75; }
.dem-thap { color: var(--chu-phu); font-size: 14px; margin: 22px 0 0; min-height: 1.6em; }
.dem-thap b { color: #f5c56b; font-weight: 500; }

/* ---------- 4. Chọn hương bằng một câu ---------- */
.chon { min-height: 100svh; display: grid; align-content: center; }
.chon-trong { max-width: 1180px; margin: 0 auto; width: 100%; }
.cau-chon { font: 500 clamp(44px, 8.4vw, 120px)/1.08 var(--f-td); margin: 0; letter-spacing: -.01em; }
.tu-chon { font: italic 600 1em/1 var(--f-td); color: var(--do-tram); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-decoration-color: var(--dong); text-decoration-thickness: 2px; text-underline-offset: .14em; display: inline-block; text-align: left; }
.goi-y-bam { font-size: 13px; color: var(--chu-phu); letter-spacing: .06em; margin: 22px 0 48px; }
.goi-y { display: grid; gap: 40px; }
@media (min-width: 760px) { .goi-y { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.goi-y-sp { display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: end; }
.goi-y-sp .cho-hop { height: 280px; min-width: 90px; display: flex; align-items: flex-end; justify-content: center; }
.goi-y-sp h3 { font-size: 34px; }
.goi-y-sp p { margin: 6px 0 14px; color: var(--chu-phu); font-size: 15px; }
.gia { font: 500 22px var(--f); font-variant-numeric: tabular-nums; }

/* ---------- 5. Sản phẩm: hàng biên tập, không khung ---------- */
.dong-sp { display: grid; gap: 28px; align-items: center; padding: clamp(40px, 7vw, 96px) 0; border-top: 1px solid var(--vach); position: relative; }
.dong-sp:last-of-type { border-bottom: 1px solid var(--vach); }
@media (min-width: 860px) { .dong-sp { grid-template-columns: 1fr 1fr; gap: 64px; } .dong-sp:nth-child(even) .san-hop { order: 2; } }
.dong-sp.noi-bat .ten-sp { color: var(--son); }
.san-hop { position: relative; height: clamp(380px, 42vw, 540px); display: grid; place-items: center; }
.san-hop::before { content: ""; position: absolute; width: min(78%, 420px); aspect-ratio: 1; border-radius: 50%; background: radial-gradient(color-mix(in srgb, var(--mau-sp, #9B2226) 24%, transparent), transparent 66%); transition: background .6s; }
.san-hop .vong-vang { position: absolute; width: min(70%, 380px); aspect-ratio: 1; border-radius: 50%; border: 1px solid rgba(176,138,78,.4); }
.sp-so { font: italic 500 18px var(--f-td); color: var(--dong); }
.sp-dong { font: 500 11.5px var(--f); letter-spacing: .3em; text-transform: uppercase; color: var(--chu-phu); margin: 8px 0 10px; }
.ten-sp { font-size: clamp(40px, 5.4vw, 72px); transition: color .4s; }
.mo-ta-sp { max-width: 30em; color: var(--chu-phu); margin: 18px 0 24px; }
.cham { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 8px; }
.cham button { width: 26px; height: 26px; border-radius: 50%; border: 0; cursor: pointer; padding: 0; box-shadow: 0 0 0 1px rgba(0,0,0,.12) inset; transition: transform .25s cubic-bezier(.3,1.6,.5,1); }
.cham button:hover { transform: scale(1.15); }
.cham button[aria-checked="true"] { box-shadow: 0 0 0 2px var(--nen), 0 0 0 3.5px var(--dong); }
.ten-mau { font-size: 13px; color: var(--chu-phu); margin: 0 0 22px; min-height: 1.4em; }
.mua { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.mua .gia { font-size: 26px; margin-right: 8px; }
.so-luong { display: inline-flex; align-items: center; border-bottom: 1px solid var(--vach); }
.so-luong button { width: 38px; height: 44px; border: 0; background: none; font-size: 20px; cursor: pointer; color: inherit; }
.so-luong input { width: 34px; border: 0; text-align: center; font: 500 17px var(--f); background: none; color: inherit; -moz-appearance: textfield; }
.so-luong input::-webkit-inner-spin-button { -webkit-appearance: none; }
.nut { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 28px; border-radius: 999px; font: 500 15px var(--f); text-decoration: none; cursor: pointer; border: 1px solid transparent; position: relative; overflow: hidden; isolation: isolate; }
.nut-chinh, .nut-them { background: var(--do-tram); color: var(--giay); }
.nut-chinh::before, .nut-them::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--son); transform: translateY(101%); transition: transform .45s cubic-bezier(.2,.8,.2,1); }
.nut-chinh:hover::before, .nut-them:hover::before { transform: none; }
.nut-zalo { border-color: #0068FF; color: #0068FF; background: transparent; }
.nut-chu { background: none; border: 0; color: inherit; font: italic 500 20px var(--f-td); cursor: pointer; border-bottom: 1px solid var(--dong); padding: 4px 0; }
.ghi-chu-si { margin-top: 56px; text-align: center; color: var(--chu-phu); }

/* ---------- 6. Lời kinh ---------- */
.chuc { text-align: center; overflow: hidden; }
.chuc-trong { display: grid; justify-items: center; }
.phong-thu { position: relative; width: min(420px, 88vw); aspect-ratio: 34 / 22; margin: clamp(230px, 34vw, 290px) auto 40px; }
.thu-sau, .thu-truoc, .nap-thu { position: absolute; left: 0; right: 0; }
.thu-sau { inset: 0; background: #E9DEC9; border-radius: 4px; }
.thu-truoc { inset: 0; background: linear-gradient(160deg, #F2EADB, #e2d4ba); border-radius: 4px; clip-path: polygon(0 0, 50% 52%, 100% 0, 100% 100%, 0 100%); z-index: 3; box-shadow: 0 30px 60px rgba(0,0,0,.45); }
.nap-thu { top: 0; height: 56%; background: linear-gradient(#e9dcc3, #d9c7a6); clip-path: polygon(0 0, 100% 0, 50% 100%); transform-origin: top; transition: transform .7s cubic-bezier(.4,0,.2,1) .15s, z-index 0s .5s; z-index: 4; }
.phong-thu.mo .nap-thu { transform: rotateX(180deg); z-index: 1; }
.la-thu { position: absolute; left: 6%; right: 6%; top: 6%; min-height: 88%; background: #FBF7EF; color: var(--mun); border-radius: 3px; z-index: 2; padding: 24px 20px 16px; display: flex; flex-direction: column; justify-content: center; gap: 12px; transition: transform 1s cubic-bezier(.2,.8,.2,1) .55s; box-shadow: 0 0 0 1px rgba(176,138,78,.5) inset; }
.phong-thu.mo .la-thu { transform: translateY(-78%); }
.chu-chuc { font: italic 500 clamp(18px, 2.3vw, 22px)/1.45 var(--f-td); color: var(--do-tram); margin: 0; min-height: 5.8em; white-space: pre-line; }
.nguon-chuc { font: 500 10.5px/1.5 var(--f); letter-spacing: .14em; text-transform: uppercase; color: var(--dong); min-height: 1.5em; }
.dau-son { position: absolute; left: 50%; top: 52%; transform: translate(-50%, -50%); z-index: 5; width: 82px; height: 82px; border: 0; padding: 0; background: none; cursor: pointer; filter: drop-shadow(0 6px 10px rgba(0,0,0,.45)); transition: transform .6s cubic-bezier(.5,-0.4,.5,1), opacity .5s; animation: dapDau 2.4s ease-in-out infinite; }
.dau-son img { width: 100%; height: 100%; }
@keyframes dapDau { 0%, 100% { transform: translate(-50%, -50%) scale(1); } 50% { transform: translate(-50%, -50%) scale(1.07); } }
.phong-thu.mo .dau-son { animation: none; transform: translate(-50%, 40%) scale(.4) rotate(160deg); opacity: 0; pointer-events: none; }
.chuc .nut-chu { margin-top: 20px; color: var(--giay); }

/* ---------- 7. Lịch: dải trăng ---------- */
.trang { list-style: none; padding: 0 0 12px; margin: 0; display: flex; gap: clamp(24px, 4vw, 56px); overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.trang::-webkit-scrollbar { display: none; }
.trang li { scroll-snap-align: start; flex: 0 0 auto; width: 180px; display: grid; gap: 6px; }
.trang .mat-trang { width: 84px; height: 84px; margin-bottom: 10px; }
.trang .loai { font: 500 11px var(--f); letter-spacing: .24em; text-transform: uppercase; color: var(--dong); }
.trang .ngay { font: 500 46px/1 var(--f-td); font-variant-numeric: lining-nums; }
.trang .thu { font-size: 14px; color: var(--chu-phu); }
.nut-nhac { justify-self: start; background: none; border: 0; border-bottom: 1px solid var(--dong); padding: 4px 0; font: 400 13px var(--f); color: inherit; cursor: pointer; margin-top: 6px; }
.tieu-de-nho { margin: 96px 0 24px; font-size: clamp(30px, 4vw, 44px); }
.le-nam { list-style: none; padding: 0; margin: 0; }
.le-nam li { display: grid; grid-template-columns: 90px 1fr auto; gap: 18px; align-items: center; padding: 20px 0; border-top: 1px solid var(--vach); transition: padding-left .35s; }
.le-nam li:hover { padding-left: 10px; }
.le-nam li:last-child { border-bottom: 1px solid var(--vach); }
.le-nam .am b { display: block; font: 500 36px/1 var(--f-td); color: var(--do-tram); font-variant-numeric: lining-nums; }
.le-nam .am small { font-size: 10.5px; color: var(--chu-phu); letter-spacing: .14em; text-transform: uppercase; }
.le-nam h4 { margin: 0; font: 500 22px/1.25 var(--f-td); }
.le-nam p { margin: 2px 0 0; font-size: 13.5px; color: var(--chu-phu); }
.le-nam .the-mau { display: inline-block; font: 600 10px var(--f); letter-spacing: .14em; text-transform: uppercase; color: var(--son); margin-bottom: 2px; }
.nguon { font-size: 12.5px; color: var(--chu-phu); margin: 24px 0 0; max-width: 60em; }

/* ---------- 8. Đặt hàng ---------- */
.dat-hang { display: grid; gap: 56px; }
@media (min-width: 900px) { .dat-hang { grid-template-columns: 1fr 1fr; gap: 96px; } }
.ds-gio { list-style: none; padding: 0; margin: 0; }
.ds-gio li { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 18px 0; border-top: 1px solid var(--vach); }
.ds-gio .ten { font: 500 22px var(--f-td); }
.ds-gio .mau { font-size: 13px; color: var(--chu-phu); display: flex; align-items: center; gap: 6px; }
.ds-gio .mau i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.ds-gio .tien { font-weight: 500; font-variant-numeric: tabular-nums; text-align: right; }
.ds-gio .sua { grid-column: 1 / -1; display: flex; align-items: center; gap: 16px; }
.ds-gio .xoa { background: none; border: 0; color: var(--chu-phu); text-decoration: underline; cursor: pointer; font: 300 13px var(--f); }
.gio-trong { color: var(--chu-phu); margin: 0; font: italic 500 22px var(--f-td); }
.tong { display: flex; justify-content: space-between; align-items: baseline; padding-top: 18px; border-top: 1px solid var(--chu); }
.tong b { font: 500 34px var(--f-td); font-variant-numeric: lining-nums; color: var(--do-tram); }
.nho { font-size: 13px; color: var(--chu-phu); margin: 12px 0 0; }
.form { display: grid; gap: 22px; }
.form label { display: grid; gap: 2px; }
.form label span { font-size: 12px; letter-spacing: .08em; color: var(--chu-phu); }
.form input, .form textarea { font: 400 17px var(--f); padding: 10px 0; border: 0; border-bottom: 1px solid var(--vach); background: none; color: var(--chu); width: 100%; resize: vertical; border-radius: 0; }
.form input:focus, .form textarea:focus { outline: none; border-bottom-color: var(--dong); }
.form .hang-nut { display: flex; gap: 12px; flex-wrap: wrap; }
.loi { color: var(--son); margin: 0; font-size: 14px; }
.loi:empty { display: none; }
.xong { text-align: center; display: grid; justify-items: center; gap: 14px; padding: 40px 0; }
.xong h3 { font-size: 40px; color: var(--do-tram); }
.xong p { color: var(--chu-phu); max-width: 30em; margin: 0; }

/* Chân trang */
.chan { background: var(--do-tram-sau); color: #E4D8C4; padding: 80px 16px 110px; text-align: center; display: grid; justify-items: center; gap: 8px; }
.chan img { width: 220px; height: auto; margin-bottom: 8px; }
.chan p { margin: 0; }
.chan a { color: var(--giay); }
.khau-hieu { font: italic 500 26px var(--f-td); color: var(--dong); }
.sap-co-chan { font-size: 13px; opacity: .75; }

/* Giỏ nổi, báo */
.gio-noi { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 30; display: flex; justify-content: space-between; align-items: center; background: var(--do-tram); color: var(--giay); text-decoration: none; border-radius: 999px; padding: 15px 24px; box-shadow: 0 10px 30px rgba(0,0,0,.3); }
@media (min-width: 820px) { .gio-noi { left: auto; width: 320px; } }
.bao { position: fixed; left: 50%; top: 80px; transform: translate(-50%, -20px); opacity: 0; transition: .25s; z-index: 50; background: var(--mun); color: var(--giay); padding: 10px 20px; border-radius: 999px; font-size: 14px; pointer-events: none; max-width: calc(100% - 32px); text-align: center; }
.bao.hien { opacity: 1; transform: translate(-50%, 0); }

/* Nén hương chỉ tiến độ cuộn + vệt tàn hương theo chuột */
.nen-tien-do { --p: 0; position: fixed; z-index: 25; pointer-events: none; }
@media (min-width: 900px) {
  .nen-tien-do { right: 22px; top: 22vh; height: 56vh; width: 6px; }
  .nen-tien-do .chan-nen { position: absolute; bottom: 0; left: 0; width: 6px; height: 18%; background: #9B2226; border-radius: 3px; }
  .nen-tien-do .than-nen { position: absolute; left: 1px; bottom: 18%; width: 4px; height: calc((1 - var(--p)) * 82%); background: #4a2e1d; border-radius: 2px 2px 0 0; box-shadow: 0 0 0 1px rgba(242,234,219,.12); }
  .nen-tien-do .dom-nen { position: absolute; left: -3px; bottom: calc(18% + (1 - var(--p)) * 82% - 6px); width: 12px; height: 12px; border-radius: 50%; background: radial-gradient(#fff2c4, #ff9a3c 45%, rgba(255,90,31,0) 72%); animation: chay 1.4s ease-in-out infinite alternate; }
}
@media (max-width: 899px) {
  .nen-tien-do { left: 0; right: 0; top: 0; height: 2px; }
  .nen-tien-do .than-nen { position: absolute; left: 0; top: 0; height: 2px; width: calc(var(--p) * 100%); background: linear-gradient(90deg, #9B2226, var(--dong)); }
  .nen-tien-do .dom-nen { position: absolute; top: -3px; left: calc(var(--p) * 100% - 4px); width: 8px; height: 8px; border-radius: 50%; background: radial-gradient(#fff2c4, #ff9a3c 50%, transparent 72%); }
  .nen-tien-do .chan-nen { display: none; }
}
.vet-chuot { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 60; }

.chu-khoi { display: inline-block; }

@media (prefers-reduced-motion: reduce) {
  .dau-son, .nen-lon .dom-lon, .goi-cuon i { animation: none; }
  body { transition: none; }
}
@media (max-width: 760px) {
  .mo-dau h1 { font-size: 34px; }
  .cap-hop { gap: 22px; }
  .cap-hop figcaption { font-size: 13px; }
  .cap-hop figcaption small { max-width: 130px; margin: 2px auto 0; font-size: 11px; }
}

/* ---------- So sánh hai dòng ---------- */
.hai-dong { display: grid; gap: 1px; background: var(--vach); border: 1px solid var(--vach); margin-bottom: clamp(48px, 8vw, 110px); }
@media (min-width: 760px) { .hai-dong { grid-template-columns: 1fr 1fr; } }
.cot-dong { background: var(--nen); padding: clamp(28px, 4vw, 52px); transition: background-color 1.1s; }
.cot-dong h3 { font-size: clamp(32px, 4vw, 48px); margin-bottom: 26px; }
.cot-dong h3 em { font-style: italic; color: var(--dong); }
.cot-dong ul { list-style: none; margin: 0; padding: 0; }
.cot-dong li { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--vach); font-size: 15px; }
.cot-dong li b { font-weight: 500; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--chu-phu); padding-top: 3px; }
.cot-dong.cao-cap { background: linear-gradient(160deg, rgba(176,138,78,.12), transparent 60%), var(--nen); }
.cot-dong.cao-cap .nhan::after { content: " ✦"; }

/* ---------- Chọn hương theo dịp ---------- */
.chon { min-height: auto; }
.o-trong { display: inline-block; min-width: 3ch; color: var(--do-tram); font-style: italic; font-weight: 600; border-bottom: 2px dashed var(--dong); line-height: 1.05; }
.o-trong.da-dien { border-bottom-style: solid; }
.dip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 40px 0 56px; }
@media (min-width: 760px) { .dip { grid-template-columns: repeat(3, 1fr); } }
.dip button { display: grid; justify-items: start; gap: 14px; padding: 22px 20px; border: 1px solid var(--vach); border-radius: 18px; background: transparent; color: var(--chu); font: 400 16px var(--f); text-align: left; cursor: pointer; transition: background-color .3s, border-color .3s, translate .3s cubic-bezier(.3,1.5,.5,1); }
.dip button svg { color: var(--dong); }
.dip button:hover { translate: 0 -4px; border-color: var(--dong); }
.dip button[aria-checked="true"] { background: var(--do-tram); border-color: var(--do-tram); color: var(--giay); }
.dip button[aria-checked="true"] svg { color: var(--dong-sang); }
.goi-y:empty { display: none; }
.goi-y-nut { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; margin-top: 18px; }
.goi-y-trong { color: var(--chu-phu); }

/* ---------- Khay hương ---------- */
.khay { position: relative; padding-top: 30px; margin-bottom: 28px; min-height: 320px; display: flex; flex-direction: column; justify-content: flex-end; }
.khay-hang { position: relative; z-index: 2; display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-end; gap: 4px 30px; padding: 0 30px; margin-bottom: -14px; }
.khay-go { width: 100%; height: 70px; display: block; filter: drop-shadow(0 18px 18px rgba(42,27,23,.25)); }
.mon { position: relative; border: 0; background: none; padding: 0; cursor: pointer; perspective: 900px; transition: transform .3s; }
.mon:hover { transform: translateY(-8px); }
.mon .hop-phang svg, .mon .hop-phang img { display: block; }
.so-mon { position: absolute; top: -10px; right: -12px; min-width: 30px; height: 30px; padding: 0 7px; border-radius: 15px; background: var(--dong); color: #fff; font: 600 12.5px/30px var(--f); text-align: center; box-shadow: 0 4px 10px rgba(0,0,0,.2); }
.khay-trong { position: absolute; left: 0; right: 0; top: 40%; transform: translateY(-50%); text-align: center; margin: 0; color: var(--chu-phu); font: italic 500 22px/1.4 var(--f-td); }
.khay-trong a { color: var(--do-tram); }
.dom-bay { position: fixed; left: 0; top: 0; z-index: 70; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; pointer-events: none; background: radial-gradient(#fff4cc, #ff9a3c 45%, rgba(255,90,31,0) 72%); box-shadow: 0 0 18px 6px rgba(255,150,60,.35); }

.khac-khay { position: absolute; left: 0; right: 0; bottom: 30px; z-index: 3; margin: 0; text-align: center; font: italic 500 17px var(--f-td); color: #e7c789; letter-spacing: .04em; pointer-events: none; }
.khay::after { content: "Bấm vào hộp để bớt một"; position: absolute; top: 0; right: 0; font-size: 11.5px; color: var(--chu-phu); letter-spacing: .06em; }
.khay:has(.khay-trong:not([hidden]))::after { display: none; }

/* Dấu hiệu vuốt ngang ở cảnh Bảy sắc */
.mep { position: absolute; top: 50%; z-index: 4; width: 58px; height: 58px; margin-top: -29px; border-radius: 50%; border: 1px solid color-mix(in srgb, currentColor 40%, transparent); background: color-mix(in srgb, var(--nen) 70%, transparent); color: inherit; display: grid; place-items: center; cursor: pointer; backdrop-filter: blur(4px); transition: transform .3s, background-color .3s; }
.mep:hover { transform: scale(1.1); }
.mep-trai { left: clamp(10px, 3vw, 40px); animation: goiTrai 2.4s ease-in-out infinite; }
.mep-phai { right: clamp(10px, 3vw, 56px); animation: goiPhai 2.4s ease-in-out infinite; }
@keyframes goiPhai { 0%, 60%, 100% { translate: 0; } 30% { translate: 8px; } }
@keyframes goiTrai { 0%, 60%, 100% { translate: 0; } 30% { translate: -8px; } }
.he-mau { position: absolute; top: 0; bottom: 0; width: 18px; z-index: 1; transition: background-color .6s; }
.he-phai { right: 0; box-shadow: -10px 0 24px rgba(0,0,0,.18); }
.he-trai { left: 0; box-shadow: 10px 0 24px rgba(0,0,0,.18); }
.tay-vuot { position: absolute; left: 50%; bottom: clamp(140px, 22vh, 210px); transform: translateX(-50%); z-index: 4; display: grid; justify-items: center; gap: 4px; pointer-events: none; transition: opacity .6s; }
.tay-vuot b { font: 500 11px var(--f); letter-spacing: .24em; text-transform: uppercase; }
.tay-vuot .tay { animation: vuot 2.2s cubic-bezier(.5,0,.3,1) infinite; }
.vet-vuot { display: flex; gap: 6px; height: 6px; margin-bottom: -4px; }
.vet-vuot i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: 0; animation: vet 2.2s ease-in-out infinite; }
.vet-vuot i:nth-child(2) { animation-delay: .12s; } .vet-vuot i:nth-child(3) { animation-delay: .24s; }
@keyframes vuot { 0% { transform: translateX(34px) rotate(8deg); opacity: 0; } 15% { opacity: 1; } 55% { transform: translateX(-34px) rotate(-8deg); opacity: 1; } 75%, 100% { transform: translateX(-34px) rotate(-8deg); opacity: 0; } }
@keyframes vet { 0%, 20% { opacity: 0; } 40% { opacity: .7; } 70%, 100% { opacity: 0; } }
.tay-vuot.an-di { opacity: 0; }
.goi-y-vuot { display: none; }
@media (min-width: 761px) { .tay-vuot { bottom: 46px; left: auto; right: clamp(90px, 10vw, 160px); transform: none; } }
@media (prefers-reduced-motion: reduce) { .mep-trai, .mep-phai, .tay-vuot .tay, .vet-vuot i { animation: none; } .vet-vuot i { opacity: .5; } }
@media (max-width: 760px) { .tay-vuot { bottom: auto; top: calc(50% + 96px); gap: 0; } .mep { width: 46px; height: 46px; margin-top: -23px; } }
