/* Báo giá AI Automation — kiểu tech, phong cách "giọt nước". Màu chỉ ở :root; theme tối chỉ đổi token.
   Chuyển động khi cuộn dùng animation-timeline và chỉ dịch/kéo, không ẩn chữ: trình duyệt cũ vẫn thấy đủ nội dung. */
:root {
  --bg: #eef4f6; --surface: #ffffff; --surface-2: #dfe9ec;
  --fg: #0b1a20; --muted: #4a5f68; --line: rgba(11, 26, 32, .13);
  --glass: rgba(255, 255, 255, .58); --bar: rgba(255, 255, 255, .82); --glass-2: rgba(11, 60, 74, .08); --edge: rgba(255, 255, 255, .95);
  --shadow: 0 24px 60px -28px rgba(10, 60, 76, .38);
  --accent: #086b80; --accent-fg: #ffffff;
  --a1: #0a7d95; --a2: #17876a; --a3: #b4601c;
  --glow-1: rgba(120, 208, 226, .50); --glow-2: rgba(255, 205, 150, .36);
  --spot: rgba(120, 208, 226, .20);
  --font-display: "Fraunces", "Be Vietnam Pro", Georgia, serif;
  --font-body: "Be Vietnam Pro", system-ui, sans-serif;
  --t-hero: clamp(2.9rem, 1rem + 7.2vw, 6.75rem);
  --t-h2: clamp(2.2rem, 1.2rem + 4vw, 4.25rem);
  --t-big: clamp(1.9rem, 1.4rem + 1.6vw, 2.6rem);
  --t-h3: clamp(1.2rem, 1.05rem + .6vw, 1.5rem);
  --t-lead: clamp(1.05rem, .95rem + .45vw, 1.25rem);
  --t-body: 1rem; --t-small: .875rem;
  --r-lg: 28px; --r-md: 18px; --r-pill: 999px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --page: 1240px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #06090c; --surface: #0d1317; --surface-2: #161f25;
    --fg: #eef4f5; --muted: #9fb0b6; --line: rgba(255, 255, 255, .12);
    --glass: rgba(16, 26, 31, .46); --bar: rgba(10, 17, 21, .8); --glass-2: rgba(255, 255, 255, .1); --edge: rgba(255, 255, 255, .22);
    --shadow: 0 24px 60px -24px rgba(0, 0, 0, .8);
    --accent: #8fe3f2; --accent-fg: #04151a;
    --a1: #8fe3f2; --a2: #c9f5d9; --a3: #ffd7a8;
    --glow-1: rgba(143, 227, 242, .17); --glow-2: rgba(255, 215, 168, .11);
    --spot: rgba(143, 227, 242, .12);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #06090c; --surface: #0d1317; --surface-2: #161f25;
  --fg: #eef4f5; --muted: #9fb0b6; --line: rgba(255, 255, 255, .12);
  --glass: rgba(16, 26, 31, .46); --bar: rgba(10, 17, 21, .8); --glass-2: rgba(255, 255, 255, .1); --edge: rgba(255, 255, 255, .22);
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, .8);
  --accent: #8fe3f2; --accent-fg: #04151a;
  --a1: #8fe3f2; --a2: #c9f5d9; --a3: #ffd7a8;
  --glow-1: rgba(143, 227, 242, .17); --glow-2: rgba(255, 215, 168, .11);
  --spot: rgba(143, 227, 242, .12);
  color-scheme: dark;
}

[hidden] { display: none !important; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; background: var(--bg); }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 var(--t-body)/1.65 var(--font-body); -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
img, svg, canvas { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
p, dd, li { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
.d { font-family: var(--font-display); font-weight: 300; letter-spacing: -.045em; line-height: 1.04; text-wrap: balance; overflow-wrap: break-word; }
.wrap { width: 100%; max-width: var(--page); margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px)); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--surface); padding: 12px 16px; border-radius: 8px; }
.glass { background: var(--glass); -webkit-backdrop-filter: blur(22px) saturate(170%); backdrop-filter: blur(22px) saturate(170%);
  box-shadow: inset 0 1px 0 var(--edge), inset 0 0 0 1px var(--line), var(--shadow); }
.nojs { margin-block: 24px; padding: 16px 20px; border-radius: var(--r-md); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.clip { position: fixed; left: -999px; top: 0; }

/* Menu: viên sáng trượt theo mục đang xem */
.nav.glass, .dock.glass { background: var(--bar); }
.nav { position: fixed; z-index: 30; left: 50%; transform: translateX(-50%); top: calc(12px + env(safe-area-inset-top, 0px));
  display: flex; align-items: center; gap: 2px; padding: 6px; border-radius: var(--r-pill); max-width: calc(100% - 24px); }
.nav a, .nav button { position: relative; display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 16px; border-radius: var(--r-pill); font-size: var(--t-small); white-space: nowrap;
  transition: background-color .3s var(--ease), color .3s var(--ease); }
.nav a:hover, .nav button:hover { background: var(--glass-2); }
.nav a:active, .nav button:active { transform: scale(.96); }
.nav .brand { font-family: var(--font-display); font-size: var(--t-lead); letter-spacing: -.02em; }
.nav .cta { background: var(--fg); color: var(--bg); font-weight: 500; }
.nav .cta:hover { background: var(--accent); color: var(--accent-fg); }
.nav-ind { position: absolute; z-index: 0; top: 6px; left: 0; height: 44px; width: 0; border-radius: var(--r-pill); background: var(--glass-2); pointer-events: none; opacity: 0;
  transition: translate .6s var(--ease), width .6s var(--ease), opacity .3s var(--ease); }
.nav .theme { width: 44px; padding: 0; border: 0; background: none; cursor: pointer; }
.theme svg { transition: rotate .7s var(--ease); }
:root[data-theme="light"] .theme svg { rotate: 180deg; }
.nav .theme, .nav .cta { flex: none; }
.nav .brand { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; line-height: 44px; }   /* tên dài trên màn rất hẹp: cắt bằng dấu … thay vì đẩy mất nút */
@media (max-width: 899px) { .nav .hide-md { display: none; } }
@media (max-width: 359px) { .seg button { padding: 0 4px; } #base { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) { .nav .hide-sm { display: none; } .nav a { padding: 0 12px; } .nav { gap: 0; } .nav .brand { font-size: var(--t-body); } }

/* Hero */
.hero { --drop-y: 190px; position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: center;
  min-height: min(92vh, 860px); padding-block: calc(112px + env(safe-area-inset-top, 0px)) 72px; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -2;
  background: radial-gradient(46% 60% at 76% 46%, var(--glow-1), transparent 72%), radial-gradient(30% 40% at 96% 92%, var(--glow-2), transparent 70%);
  animation: breathe 9s ease-in-out infinite alternate; }
@keyframes breathe { to { opacity: .7; } }
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: 120px; z-index: -1; background: linear-gradient(transparent, var(--bg)); pointer-events: none; }
#droplet { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.drop-css { display: none; position: absolute; z-index: -1; right: 12%; top: 22%; width: min(38vw, 440px); aspect-ratio: 1; border-radius: 48% 52% 55% 45% / 52% 46% 54% 48%;
  background: radial-gradient(circle at 34% 24%, var(--surface) 0 5%, transparent 18%), radial-gradient(circle at 66% 82%, var(--a2), transparent 34%),
    radial-gradient(circle at 50% 50%, var(--surface-2) 36%, var(--a1) 100%); }
.no-gl .drop-css { display: block; animation: blob 7s ease-in-out infinite alternate; } .no-gl #droplet { display: none; }
/* không có WebGL: giọt CSS vẫn thở và đổi dáng chậm (reduced-motion tắt ở cuối file) */
@keyframes blob { 50% { border-radius: 54% 46% 44% 56% / 46% 55% 45% 54%; translate: 0 -12px; scale: 1.03; } to { border-radius: 45% 55% 52% 48% / 55% 44% 56% 45%; translate: 0 8px; } }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) 372px; gap: 40px; align-items: end; }
.hero-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 26px; min-width: 0; }
.hero h1 { font-size: var(--t-hero); line-height: .96; margin-left: -.04em; padding-block: .04em .1em; max-width: 9.5em; }
/* Tiêu đề hero: từng chữ dâng lên khi tải (chữ nằm sẵn trong HTML, không cần JS) */
.w { white-space: nowrap; }
.ch { display: inline-block; animation: ch .9s var(--ease) both; animation-delay: calc(var(--i) * 35ms); }
@keyframes ch { from { opacity: .01; translate: 0 .38em; rotate: 9deg; } }
.grad { background: linear-gradient(100deg, var(--a1), var(--a2) 35%, var(--a3) 65%, var(--a1)); background-size: 240% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; font-style: italic; padding-inline: .05em .12em;
  animation: flow 9s ease-in-out infinite alternate; }
@keyframes flow { to { background-position: 100% 0; } }
.lead { max-width: 46ch; font-size: var(--t-lead); color: var(--muted); }
.chip { display: inline-flex; align-items: center; gap: 10px; min-height: 36px; padding: 6px 16px; border-radius: var(--r-pill); font-size: var(--t-small); line-height: 1.4; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; animation: pulse 2.6s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent); } 70%, 100% { box-shadow: 0 0 0 9px transparent; } }
.ctas { display: flex; flex-wrap: wrap; gap: 10px; max-width: 100%; }
.btn { position: relative; overflow: hidden; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 24px; border-radius: var(--r-pill); font-weight: 500; border: 0; cursor: pointer;
  transition: transform .4s var(--ease), background-color .3s var(--ease), color .3s var(--ease); }
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--fg); color: var(--bg); } .btn-primary:hover, .btn-primary.done { background: var(--accent); color: var(--accent-fg); }
.btn-quiet { background: var(--glass-2); } .btn-quiet:hover, .btn-quiet.done { background: var(--fg); color: var(--bg); }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: var(--t-small); }
.btn:disabled, .btn:disabled:hover { background: none; color: var(--muted); cursor: default; box-shadow: inset 0 0 0 1px var(--line); }
.btn svg { transition: transform .4s var(--ease); }
/* Ánh lướt qua nút: dải sáng lấy màu chữ của nút nên luôn nổi trên nền nút ở cả sáng + tối; rời chuột thì về chỗ ngay (không lướt ngược) */
.btn::after { content: ""; position: absolute; inset: 0; pointer-events: none; translate: -115% 0;
  background: linear-gradient(105deg, transparent 32%, color-mix(in srgb, currentColor 24%, transparent) 50%, transparent 68%); }
.btn:active::after { translate: 115% 0; transition: translate .7s var(--ease); }
.btn:disabled::after { display: none; }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { transform: translateY(-2px); } .btn:hover svg { transform: translateX(4px); }
  .btn:hover::after { translate: 115% 0; transition: translate .9s var(--ease); }
  .btn:hover:active { transform: translateY(1px) scale(.97); }
  .btn:disabled:hover { transform: none; }
}
/* Gợn nước khi nhấn nút */
.rip { position: absolute; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; pointer-events: none; box-shadow: 0 0 0 1.5px currentColor, inset 0 0 0 1.5px currentColor; opacity: .5; animation: rip .75s var(--ease) forwards; }
@keyframes rip { to { scale: 18; opacity: 0; } }

/* Tấm kính giá tham khảo nằm trước giọt nước */
.card { border-radius: var(--r-lg); padding: 10px; transform: translateY(44px); }
.card-h { padding: 8px 14px 4px; font-size: var(--t-small); color: var(--muted); }
.card a { display: flex; align-items: center; gap: 14px; min-height: 62px; padding: 8px 14px; border-radius: var(--r-md); min-width: 0; transition: background-color .3s var(--ease); }
.card a:hover { background: var(--glass-2); }
.card a:active { background: var(--line); }
.card a svg { flex: none; color: var(--accent); transition: translate .5s var(--ease); }
@media (hover: hover) and (pointer: fine) { .card a:hover svg, .svc-go:hover svg { translate: 4px 0; } }
.card a span { flex: 1; display: block; min-width: 0; line-height: 1.35; }
.card small { display: block; font-size: var(--t-small); color: var(--muted); }
.card b { display: block; font: 400 var(--t-h3)/1.3 var(--font-display); letter-spacing: -.02em; font-variant-numeric: lining-nums tabular-nums; }
.rise { animation: rise .8s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes rise { from { opacity: .01; translate: 0 18px; } }

/* Đầu mục */
.section { padding-block: clamp(64px, 8vw, 120px); }
.section + .section { padding-top: 0; }
.sh { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 14px 24px; margin-bottom: 36px; }
.sh h2 { font-size: var(--t-h2); }
.sh p { color: var(--muted); max-width: 58ch; margin-top: 12px; }
.fine { margin-top: 20px; font-size: var(--t-small); color: var(--muted); }

/* Dịch vụ: lưới 6 cột, mỗi hàng 2 thẻ; 4 nhóm nổi bật có luồng việc + quầng màu */
.svc { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
/* Thẻ video + thẻ giá: quầng sáng theo con trỏ nằm ở nền thẻ; ::after là viền sáng chạy theo con trỏ (chỉ vẽ dải viền 1,5px nhờ mask) */
.svc-card, .plan { background: radial-gradient(360px circle at var(--mx, -400px) var(--my, -400px), var(--spot), transparent 60%) no-repeat, var(--surface);
  transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.svc-card::after, .plan::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; padding: 1.5px; opacity: 0; transition: opacity .4s var(--ease);
  background: radial-gradient(280px circle at var(--mx, -400px) var(--my, -400px), var(--accent), transparent 70%);
  -webkit-mask: linear-gradient(var(--fg) 0 0) content-box, linear-gradient(var(--fg) 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(var(--fg) 0 0) content-box exclude, linear-gradient(var(--fg) 0 0); }
@media (hover: hover) and (pointer: fine) {
  .svc-card:hover, .plan:hover { transform: translateY(-4px); }
  .svc-card:hover, .plan:not(.hot):hover { box-shadow: inset 0 0 0 1px var(--line), var(--shadow); }
  .svc-card:hover::after, .plan:hover::after { opacity: 1; }
}
.svc-card { position: relative; isolation: isolate; overflow: hidden; grid-column: span 3; min-width: 0; display: flex; flex-direction: column; gap: 14px; padding: 28px 28px 14px; border-radius: var(--r-lg); box-shadow: inset 0 0 0 1px var(--line); }
.svc-card.big::before { content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none; background: radial-gradient(60% 80% at 100% 0%, var(--glow-1), transparent 70%); opacity: .55; }
.svc-card h3 { font-family: var(--font-display); font-weight: 400; font-size: var(--t-h3); letter-spacing: -.02em; line-height: 1.25; }
.svc-card > p { color: var(--muted); max-width: 52ch; }
.flow { display: flex; flex-wrap: wrap; gap: 8px 6px; margin-top: 6px; }
.flow li { position: relative; padding: 6px 12px; border-radius: var(--r-pill); background: var(--surface-2); font-size: var(--t-small); line-height: 1.4; white-space: nowrap; }
.flow li:not(:last-child) { margin-right: 18px; }
.flow li:not(:last-child)::before { content: ""; position: absolute; right: -17px; top: 50%; width: 7px; height: 7px; margin-top: -4px; border-top: 1.5px solid var(--muted); border-right: 1.5px solid var(--muted); rotate: 45deg; }
.flow .you { background: var(--accent); color: var(--accent-fg); font-weight: 500; }
.svc-go { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 16px; min-height: 56px; padding-top: 8px; border-top: 1px solid var(--line); font-weight: 500; font-variant-numeric: tabular-nums; }
/* Gạch chân chạy từ trái sang khi rê chuột (điện thoại: khi nhấn) */
.svc-more, .footer a { background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: color .3s var(--ease), background-size .6s var(--ease); }
.svc-more { display: inline-flex; align-items: center; gap: 8px; padding-bottom: 3px; font-size: var(--t-small); font-weight: 400; color: var(--muted); }
.svc-more svg { transition: translate .5s var(--ease); }
.svc-go:hover .svc-more, .svc-go:active .svc-more { color: var(--accent); background-size: 100% 1px; }

/* Ba gói */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.plan { position: relative; isolation: isolate; overflow: hidden; min-width: 0; display: flex; flex-direction: column; gap: 16px; padding: 28px; border-radius: var(--r-lg); box-shadow: inset 0 0 0 1px var(--line); }
.plan.hot { box-shadow: inset 0 0 0 2px var(--accent), var(--shadow); }
.plan.hot::before { content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none; background: radial-gradient(80% 60% at 100% 0%, var(--glow-1), transparent 70%); opacity: .6; }
.plan-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; min-height: 32px; }
.plan h3 { font-size: var(--t-lead); font-weight: 500; }
.tag { padding: 4px 12px; border-radius: var(--r-pill); background: var(--accent); color: var(--accent-fg); font-size: var(--t-small); font-weight: 500; line-height: 1.5; }
.plan-price { font-size: var(--t-big); font-variant-numeric: lining-nums tabular-nums; letter-spacing: -.03em; white-space: nowrap; }
.plan-price small { font: 400 var(--t-small)/1 var(--font-body); letter-spacing: 0; color: var(--muted); }
.plan-fit { color: var(--muted); min-height: 3.3em; }
.ticks { flex: 1; display: flex; flex-direction: column; gap: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.ticks li { display: flex; gap: 10px; align-items: flex-start; }
.ticks svg { flex: none; margin-top: 4px; color: var(--accent); }
.plan-meta { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding-block: 14px; border-block: 1px solid var(--line); }
.plan-meta dt { font-size: var(--t-small); color: var(--muted); }
.plan-meta dd { font-weight: 500; font-variant-numeric: tabular-nums; line-height: 1.4; }

/* Bảng tính báo giá */
.calc { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 24px; align-items: start; }
.calc-pick { min-width: 0; display: flex; flex-direction: column; gap: 16px; padding: 28px; border-radius: var(--r-lg); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.pick-h h3, .sum h3 { font-size: var(--t-lead); font-weight: 500; }
.pick-h p { color: var(--muted); font-size: var(--t-small); }
.pick-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 10px 16px; margin-top: 12px; padding-top: 24px; border-top: 1px solid var(--line); }
.seg { display: inline-flex; align-self: flex-start; max-width: 100%; padding: 4px; border-radius: var(--r-pill); background: var(--glass-2); }
.seg button { min-height: 44px; padding: 0 18px; border: 0; border-radius: var(--r-pill); background: none; font-size: var(--t-small); white-space: nowrap; cursor: pointer; transition: background-color .3s var(--ease), color .3s var(--ease); }
.seg button:hover { color: var(--accent); }
.seg button[aria-pressed="true"] { background: var(--fg); color: var(--bg); font-weight: 500; }
.seg button:active { transform: scale(.97); }
.item { position: relative; isolation: isolate; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 16px; padding-block: 8px; border-top: 1px solid var(--line); }
/* Nền nhẹ khi rê chuột / nhấn vào dòng tuỳ chọn và câu hỏi: lớp nền nằm sau chữ, nới ra 14px mỗi bên (vẫn trong lề thẻ, không tràn ngang) */
.item::before, .qa summary::before { content: ""; position: absolute; z-index: -1; inset: 3px -14px; border-radius: 14px; background: var(--glass-2); opacity: 0; pointer-events: none; transition: opacity .3s var(--ease); }
.item:active::before, .qa summary:active::before { opacity: 1; }
@media (hover: hover) and (pointer: fine) { .item:hover::before, .qa summary:hover::before { opacity: 1; } }
.item-main { display: flex; align-items: flex-start; gap: 12px; min-width: 0; min-height: 44px; padding-block: 6px; cursor: pointer; }
/* ô tick tự vẽ: hình thấy 22px, vùng chạm 44px */
.item-main input { -webkit-appearance: none; appearance: none; position: relative; flex: none; width: 44px; height: 44px; margin: -9px -10px -9px -11px; border-radius: 50%; background: none; cursor: pointer; }
.item-main input::before { content: ""; position: absolute; inset: 11px; border-radius: 7px; box-shadow: inset 0 0 0 1.5px var(--muted); transition: background-color .25s var(--ease), box-shadow .25s var(--ease); }
.item-main input::after { content: ""; position: absolute; left: 19px; top: 14px; width: 7px; height: 12px; border: solid var(--accent-fg); border-width: 0 2px 2px 0; rotate: 45deg; scale: .6; opacity: 0; transition: scale .25s var(--ease), opacity .15s var(--ease); }
.item-main input:hover::before { box-shadow: inset 0 0 0 1.5px var(--accent); }
.item-main input:checked::before { background: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); }
.item-main input:checked::after { scale: 1; opacity: 1; }
.item-t { min-width: 0; line-height: 1.45; }
.item-t b { display: block; font-weight: 500; }
.item-t small, .item-p small { display: block; font-size: var(--t-small); color: var(--muted); }
.item-p { text-align: right; white-space: nowrap; line-height: 1.45; font-variant-numeric: tabular-nums; }
.item-p b { font-weight: 500; transition: color .3s var(--ease); }
.item.on .item-p b { color: var(--accent); }
.count { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.qty { flex: none; display: inline-flex; align-items: center; padding: 0; border-radius: var(--r-pill); background: var(--surface-2); }
.qty button { position: relative; overflow: hidden; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: none; font-size: var(--t-lead); line-height: 1; cursor: pointer; transition: background-color .3s var(--ease), color .3s var(--ease); }
.qty button:hover { background: var(--fg); color: var(--bg); }
.qty button:active { transform: scale(.94); }
.qty button:disabled, .qty button:disabled:hover { background: none; color: var(--muted); cursor: default; }
.qty input { width: 60px; height: 44px; padding: 0; border: 0; border-radius: 8px; background: none; color: inherit; font: inherit; font-weight: 500; text-align: center; font-variant-numeric: tabular-nums; -moz-appearance: textfield; appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.sum { position: sticky; top: 88px; min-width: 0; display: flex; flex-direction: column; gap: 16px; padding: 28px; border-radius: var(--r-lg); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line), var(--shadow); scroll-margin-top: 96px; }
.sum-lines { display: flex; flex-direction: column; }
.sum-lines li { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding-block: 10px; border-top: 1px solid var(--line); line-height: 1.45; }
.sum-lines li > span:first-child { min-width: 0; }
.sum-lines b { display: block; font-weight: 500; }
.sum-lines small { display: block; font-size: var(--t-small); color: var(--muted); }
.amt { flex: none; text-align: right; white-space: nowrap; font-weight: 500; font-variant-numeric: tabular-nums; }
.amt small { font-weight: 400; }
.sum-lines .off b, .sum-lines .off .amt { color: var(--accent); }
.sum-total { display: flex; flex-direction: column; gap: 8px; padding-top: 16px; border-top: 1px solid var(--fg); }
.sum-total dt { font-size: var(--t-small); color: var(--muted); }
#total { display: inline-block; transform-origin: 0 70%; font-size: var(--t-big); font-variant-numeric: lining-nums tabular-nums; letter-spacing: -.03em; white-space: nowrap; }
#per { font-weight: 500; font-variant-numeric: tabular-nums; }
/* Số tổng nhún 1 lần khi đổi: lún xuống, nảy quá lên rồi về chỗ (chỉ transform) */
.bump { animation: bump .6s var(--ease); }
@keyframes bump { 0% { transform: translateY(8px) scale(.96); } 55% { transform: translateY(-3px) scale(1.03); } }
.sum-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.sum-btns .btn { flex: 1 1 auto; padding-inline: 18px; }
.sum .fine { margin-top: 0; }
.notes { display: flex; flex-direction: column; gap: 2px; }

/* Cách làm việc: 5 bước nối bằng 1 đường kẻ, chấm màu nhấn ở đầu mỗi bước */
.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.step { position: relative; min-width: 0; padding: 36px 24px 0 0; }
.step::before { content: ""; position: absolute; inset: 5px 0 auto; height: 1px; background: var(--line); transform-origin: 0 50%; }
.step::after { content: ""; position: absolute; left: 0; top: 0; width: 11px; height: 11px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 5px var(--bg); }
.step h3 { font-family: var(--font-display); font-weight: 400; font-size: var(--t-h3); letter-spacing: -.02em; line-height: 1.25; }
.step p { margin-top: 10px; color: var(--muted); }

/* Hỏi đáp */
#hoi-dap .wrap { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 20px 48px; align-items: start; }
#hoi-dap .sh { margin-bottom: 0; }
.faq { min-width: 0; border-bottom: 1px solid var(--line); }
.qa { position: relative; }
.qa::before { content: ""; position: absolute; inset: 0 0 auto; height: 1px; background: var(--line); transform-origin: 0 50%; }   /* đường kẻ trên mỗi câu: kéo dài ra khi cuộn tới */
.qa summary { position: relative; isolation: isolate; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; padding-block: 14px; font-size: var(--t-lead); font-weight: 500; line-height: 1.4; cursor: pointer; list-style: none; transition: color .3s var(--ease); }
.qa summary::-webkit-details-marker { display: none; }
.qa summary:hover { color: var(--accent); }
.qa summary span { min-width: 0; }
.qa i { position: relative; flex: none; width: 44px; height: 44px; border-radius: 50%; background: var(--glass-2); transition: rotate .5s var(--ease), background-color .3s var(--ease); }
.qa i::before, .qa i::after { content: ""; position: absolute; left: 15px; top: 21px; width: 14px; height: 2px; border-radius: 2px; background: currentColor; }
.qa i::after { rotate: 90deg; transition: rotate .5s var(--ease); }
.qa[open] i { rotate: 180deg; } .qa[open] i::after { rotate: 0deg; }
.qa p { max-width: 68ch; padding-bottom: 24px; color: var(--muted); }

/* Dải kết */
.contact { position: relative; isolation: isolate; overflow: hidden; border-radius: var(--r-lg); padding: clamp(28px, 5vw, 72px); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.contact::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(50% 90% at 100% 0%, var(--glow-1), transparent 70%); animation: dim 5s ease-in-out infinite alternate; }
@keyframes dim { to { opacity: .55; } }
.contact h2 { font-size: var(--t-h2); max-width: 16em; }
.end-p { margin-top: 16px; max-width: 56ch; font-size: var(--t-lead); color: var(--muted); }
.lines { margin-top: clamp(24px, 4vw, 40px); }
.line { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 6px 20px; padding-block: 14px; border-top: 1px solid var(--line); }
.line:last-child { border-bottom: 1px solid var(--line); }
.line > a { font-family: var(--font-display); font-weight: 300; font-size: var(--t-big); letter-spacing: -.03em; line-height: 1.2; min-width: 0; min-height: 44px; display: flex; flex-direction: column; justify-content: center; overflow-wrap: anywhere; transition: color .3s var(--ease), translate .6s var(--ease); }
.line > a small { font: 400 var(--t-small)/1.5 var(--font-body); letter-spacing: 0; color: var(--muted); }
.copy { position: relative; overflow: hidden; flex: none; min-width: 108px; min-height: 44px; padding: 0 18px; border-radius: var(--r-pill); border: 0; background: var(--glass-2); font-size: var(--t-small); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; transition: background-color .3s var(--ease), color .3s var(--ease); }
.copy:hover, .copy.done { background: var(--accent); color: var(--accent-fg); } .copy:active { transform: scale(.97); }
@media (hover: hover) and (pointer: fine) { .line > a:hover { color: var(--accent); translate: 10px 0; } }
.socials { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.footer { padding-block: 24px calc(40px + env(safe-area-inset-bottom, 0px)); color: var(--muted); font-size: var(--t-small); }
.footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; }
.footer a { display: inline-flex; align-items: center; min-height: 44px; background-position: 0 calc(50% + .85em); } .footer a:hover, .footer a:active { color: var(--fg); background-size: 100% 1px; }

/* Thanh tổng tiền ở đáy: chỉ khi bảng tính xếp 1 cột (≤ 899px), hiện sau hero, ẩn khi tấm tổng đã trong màn hình */
.dock { display: none; }
.toast { position: fixed; z-index: 60; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); width: max-content; max-width: calc(100% - 32px); padding: 12px 20px; border-radius: 24px; background: var(--fg); color: var(--bg); font-size: var(--t-small); font-weight: 500; text-align: center; animation: rise .5s var(--ease); }

/* Tờ báo giá chỉ dùng khi in */
.sheet { display: none; }

/* Đổi giao diện: lan ra như giọt nước rơi (ui.js) */
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

/* Chuyển động theo cuộn (cùng bộ với web portfolio: khối trồi lên, phóng nhẹ, kéo đường kẻ, hero trôi lệch tốc độ).
   --lag = thứ tự trong hàng: thẻ sau trồi từ thấp hơn và xong muộn hơn nên cả hàng vào lệch nhịp; xếp 1 cột thì --lag = 0. */
@media (min-width: 900px) {
  .svc-card:nth-child(even), .plan:nth-child(2), .sum { --lag: 1; }
  .plan:nth-child(3) { --lag: 2; }
}
@media (min-width: 1100px) {
  .step:nth-child(2) { --lag: .6; } .step:nth-child(3) { --lag: 1.2; } .step:nth-child(4) { --lag: 1.8; } .step:nth-child(5) { --lag: 2.4; }
}
.svc-card, .plan, .calc-pick, .sum { --s0: .9; }   /* thẻ: vừa trồi vừa phóng nhẹ từ 97% */
.contact { --s0: .88; }
.qa, .footer .wrap { --dy: 48px; }
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    /* fill forwards (không "both"): khối CHƯA vào màn hình đứng đúng chỗ, không dịch sẵn đè lên dòng chữ bên dưới (ghi chú giá dưới 3 thẻ gói) */
    .lift { animation: lift linear forwards; animation-timeline: view(); animation-range: entry 0% cover calc(30% + var(--lag, 0) * 6%); }
    /* khối sát đáy trang không bao giờ lên tới 22% màn hình: xong ngay khi vào hết màn hình */
    .contact.lift { animation-range: entry 0% entry 90%; }
    .footer .lift { animation-range: entry 0% entry 100%; }
    .svc-card.big::before, .plan.hot::before { animation: glow linear forwards; animation-timeline: view(); animation-range: entry 0% cover 45%; }
    .step::before, .qa::before { animation: draw linear both; animation-timeline: view(); animation-range: entry 0% cover 35%; }
    .step::after { animation: dot linear forwards; animation-timeline: view(); animation-range: entry 0% cover 30%; }
    .hero-copy { animation: leave linear both; animation-timeline: view(); animation-range: exit 0% exit 100%; }
    @keyframes lift { from { opacity: .01; translate: 0 calc(var(--dy, 110px) + var(--lag, 0) * 44px); scale: var(--s0, 1); } }
    @keyframes glow { from { opacity: 0; } }
    @keyframes draw { from { transform: scaleX(.02); } }
    @keyframes dot { from { scale: .2; } }
    @keyframes leave { to { translate: 0 90px; } }
  }
}
/* Máy tính: tấm kính giá ở hero trôi lên nhanh hơn trang trong lúc khối chữ trôi chậm lại (lệch tốc độ) */
@media (prefers-reduced-motion: no-preference) and (min-width: 900px) {
  @supports (animation-timeline: view()) {
    .hero .card { animation: rise .8s var(--ease) both, drift linear both; animation-delay: calc(var(--i, 0) * 70ms), 0s; animation-timeline: auto, view(); animation-range: normal, contain 0% exit 100%; }
    @keyframes drift { to { transform: translateY(-44px); } }
  }
}
/* Trình duyệt chưa có animation-timeline: view(): main.js gắn .io rồi cho từng khối trồi lên 1 lần khi vào màn hình.
   Chỉ dịch + phóng, không đổi opacity; JS lỗi thì không có .io nên mọi khối đứng sẵn đúng chỗ. */
@media (prefers-reduced-motion: no-preference) {
  .io .lift { translate: 0 var(--dy, 110px); scale: var(--s0, 1); transition: translate .9s var(--ease), scale .9s var(--ease); transition-delay: calc(var(--lag, 0) * 90ms); }
  .io .lift.in { translate: none; scale: none; }
}

@media (max-width: 1099px) {
  .steps { grid-template-columns: minmax(0, 1fr); }
  .step { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 8px 48px; padding: 32px 0 28px; }
  .step p { margin-top: 0; max-width: 62ch; }
}
@media (max-width: 899px) {
  .hero { min-height: 0; padding-top: 312px; padding-bottom: 48px; align-items: flex-start; }
  .hero::before { background: radial-gradient(80% 34% at 50% 190px, var(--glow-1), transparent 72%); }
  .drop-css { right: auto; left: 50%; top: 94px; width: 190px; margin-left: -95px; }
  .hero .wrap { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .card { transform: none; }
  .svc-card { grid-column: 1 / -1; }
  .plans { grid-template-columns: minmax(0, 1fr); }
  .plan-fit { min-height: 0; }
  .calc { grid-template-columns: minmax(0, 1fr); }
  .sum { position: static; }
  #hoi-dap .wrap { grid-template-columns: minmax(0, 1fr); }
  .dock { position: fixed; z-index: 25; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 6px 6px 6px 18px; border-radius: 24px;
    visibility: hidden; translate: 0 120%; transition: translate .6s var(--ease), visibility .6s; }
  .dock.on { visibility: visible; translate: 0 0; }
  .dock-t { min-width: 0; line-height: 1.3; }
  .dock-t small { display: block; font-size: var(--t-small); color: var(--muted); }
  .dock-t b { display: block; font-weight: 500; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
  .dock a { flex: none; display: flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 20px; border-radius: var(--r-md); background: var(--fg); color: var(--bg); font-size: var(--t-small); font-weight: 500; }
  .dock a:active { background: var(--accent); color: var(--accent-fg); }
}
@media (max-width: 560px) {
  .sh { align-items: stretch; flex-direction: column; }
  .ctas { width: 100%; } .ctas .btn { flex: 1 1 140px; padding-inline: 16px; }
  .card { padding: 6px; } .card a { padding: 8px 10px; gap: 12px; }
  .svc-card { padding: 22px 20px 10px; }
  .plan, .calc-pick, .sum { padding: 22px 20px; }
  .seg { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-self: stretch; border-radius: 26px; }
  .count .seg { flex: 1 1 200px; }
  .seg button { padding: 0 10px; }
  .item { grid-template-columns: minmax(0, 1fr); }
  .item-p { text-align: left; padding: 0 0 8px 34px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px; }
  .step { grid-template-columns: minmax(0, 1fr); }
  .socials .btn { flex: 1 1 100%; }
  .line > a { font-size: var(--t-lead); letter-spacing: -.02em; } .line { gap: 12px; } .copy { min-width: 76px; padding: 0 12px; }
  .contact { padding: 28px 20px; } .br-wide { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after, ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* In / lưu PDF: chỉ in tờ báo giá, nền trắng chữ đen (đổi token, không đổi kiểu thành phần) */
@media print {
  :root, :root[data-theme="dark"], :root[data-theme="light"] { --bg: #ffffff; --surface: #ffffff; --fg: #000000; --muted: #444444; --line: #bbbbbb; color-scheme: light; }
  @page { margin: 16mm; }
  html, body { background: var(--bg); }
  body > :not(.sheet) { display: none !important; }
  .sheet { display: block; color: var(--fg); font-size: 11pt; line-height: 1.5; }
  .sheet header { padding-bottom: 12pt; border-bottom: 1.5pt solid var(--fg); }
  .sheet-brand { font-weight: 500; }
  .sheet h2 { font: 300 24pt/1.2 var(--font-display); letter-spacing: -.02em; }
  .sheet header p:last-child { color: var(--muted); }
  .sheet table { width: 100%; margin-top: 14pt; border-collapse: collapse; font-variant-numeric: tabular-nums; }
  .sheet th, .sheet td { padding: 7pt 6pt 7pt 0; border-bottom: .75pt solid var(--line); text-align: left; vertical-align: top; font-weight: 400; }
  .sheet thead th { color: var(--muted); font-size: 9pt; }
  .sheet td b { font-weight: 500; } .sheet td small { display: block; color: var(--muted); font-size: 9pt; }
  .sheet th:last-child, .sheet td:last-child { text-align: right; padding-right: 0; white-space: nowrap; }
  .sheet tfoot th { text-align: right; font-weight: 500; } .sheet tfoot td { font-weight: 500; }
  .sheet tfoot tr:first-child > * { border-bottom-color: var(--fg); font-size: 13pt; }
  .sheet ul { margin-top: 14pt; color: var(--muted); font-size: 9pt; }
  .sheet-contact { margin-top: 10pt; font-size: 10pt; }
  .sheet tr { break-inside: avoid; }
}
