/* Content pages (/gioi-thieu, /lien-he, policies), the blog index, posts and post cards.
   The .prose rules style the HTML from services/markup.py; the admin preview loads this file too. */

/* ---------------------------------------------------------------- page head */
.ct { padding-bottom: 24px; }
.ct-crumbs { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding-top: 22px; font-size: 13px; color: var(--text-3); }
.ct-crumbs a:hover { color: var(--text); }
.ct-crumbs .truncate { max-width: min(420px, 60vw); }
.ct-hero { padding: 18px 0 26px; max-width: 760px; }
.ct-hero .eyebrow { margin-bottom: 14px; }
.ct-hero h1 { font-family: var(--font-display); font-weight: 800; font-size: clamp(30px, 4.4vw, 46px); line-height: 1.08;
  letter-spacing: -0.01em; }
.ct-lead { margin-top: 12px; font-size: 16.5px; line-height: 1.65; color: var(--text-2); }
.ct-meta { margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--text-3); }
.ct-section { padding: 26px 20px 40px; }

/* ---------------------------------------------------------------- rendered markup */
.prose { font-size: 16px; line-height: 1.78; color: var(--text); overflow-wrap: anywhere; }
.prose > * + * { margin-top: 1em; }
.prose h2 { font-family: var(--font-display); font-weight: 800; font-size: clamp(22px, 2.6vw, 28px); line-height: 1.2;
  letter-spacing: -0.01em; margin-top: 1.7em; }
.prose h3 { font-size: 18.5px; font-weight: 800; line-height: 1.3; margin-top: 1.5em; }
.prose > :first-child { margin-top: 0; }
.prose h2 + *, .prose h3 + * { margin-top: 0.6em; }
.prose ul, .prose ol { margin-bottom: 0; padding-left: 1.5em; }
.prose li + li { margin-top: 0.4em; }
.prose li::marker { color: var(--brick); font-weight: 800; }
.prose a { color: var(--accent-text); font-weight: 600; text-decoration: underline; text-decoration-thickness: 1.5px;
  text-underline-offset: 3px; }
.prose a:hover { color: var(--brick); }
.prose strong { font-weight: 750; }
.prose blockquote { margin: 1.4em 0 0; padding: 14px 18px; border-left: 5px solid var(--mustard); border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--surface-2); color: var(--text-2); }
.prose blockquote p + p { margin-top: 0.7em; }
.prose img { width: auto; max-width: 100%; height: auto; margin: 0.4em auto; border-radius: 16px; border: 2px solid var(--espresso);
  box-shadow: 4px 4px 0 var(--espresso); background: var(--surface-2); }
:root[data-theme="dark"] .prose img { border-color: #000; box-shadow: 4px 4px 0 #000; }

/* ---------------------------------------------------------------- content pages */
.cp-layout { display: grid; grid-template-columns: minmax(0, 760px); gap: 40px; align-items: start; padding-bottom: 32px; }
.cp-layout.has-side { grid-template-columns: minmax(0, 1fr) 280px; }
.cp-main { min-width: 0; max-width: 760px; }
.cp-body { padding: 28px 32px; border-radius: var(--radius-lg); background: var(--surface); border: 2px solid var(--espresso);
  box-shadow: 6px 6px 0 var(--espresso); }
:root[data-theme="dark"] .cp-body { border-color: #000; box-shadow: 6px 6px 0 #000; }
.cp-side { position: sticky; top: calc(var(--header-h) + 24px); display: flex; flex-direction: column; gap: 18px; padding: 18px;
  border-radius: var(--radius-lg); background: var(--surface-2); border: 1px dashed var(--border-strong); }
.cp-side h2 { margin-bottom: 8px; font-size: 12px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.cp-side ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.cp-side a { display: block; padding: 8px 10px; border-radius: 10px; font-weight: 650; color: var(--text-2);
  transition: background var(--fast), color var(--fast); }
.cp-side a:hover { background: var(--surface); color: var(--text); }
.cp-side a.is-current { background: var(--brick); color: #fff8ee; }
.cp-hours { display: inline-flex; align-items: center; gap: 8px; margin-top: 22px; padding: 8px 14px; border-radius: 999px; font-weight: 600;
  background: color-mix(in srgb, var(--mustard) 28%, var(--surface)); color: var(--text); border: 1.5px solid var(--espresso); }
.cp-empty { margin-top: 22px; color: var(--text-3); }

/* contact channels: Zalo first, each a sticker card */
.channels { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 22px; }
.cp-hours + .channels { margin-top: 16px; }
.channel { --tone: var(--espresso); display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 14px; padding: 18px;
  border-radius: var(--radius-lg); background: var(--surface); border: 2px solid var(--espresso); box-shadow: var(--sticker);
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease); }
.channel:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--espresso); }
:root[data-theme="dark"] .channel { border-color: #000; }
:root[data-theme="dark"] .channel:hover { box-shadow: 5px 5px 0 #000; }
.channel-icon { grid-row: span 2; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 14px; color: #fff;
  background: var(--tone); border: 2px solid var(--espresso); }
.channel-icon .icon { width: 24px; height: 24px; }
.channel-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.channel-body strong { font-family: var(--font-display); font-weight: 800; font-size: 20px; line-height: 1.15; }
.channel-value { font-weight: 700; overflow-wrap: anywhere; }
.channel-note { font-size: 13px; color: var(--text-3); line-height: 1.45; }
.channel-cta { grid-column: 2; display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-weight: 800; color: var(--accent-text); }
.channel:hover .channel-cta { gap: 9px; }
:root[data-theme="dark"] .channel-icon, :root[data-theme="dark"] .cp-hours,
:root[data-theme="dark"] .post-card-ph .icon { border-color: #000; }
.channel-zalo { --tone: #0068ff; }
.channel-phone { --tone: var(--brick); }
.channel-facebook { --tone: #1877f2; }
.channel-shopee { --tone: var(--shopee); }

/* ---------------------------------------------------------------- blog index */
.blog-tabs { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }
.blog-tab { height: 40px; padding: 0 18px; display: inline-flex; align-items: center; border-radius: 999px; font-weight: 750;
  background: var(--surface); border: 2px solid var(--espresso); box-shadow: 2px 2px 0 var(--espresso); transition: transform var(--fast); }
.blog-tab:hover { transform: translate(-1px, -1px); }
.blog-tab.is-active { background: var(--brick); color: #fff8ee; }
:root[data-theme="dark"] .blog-tab { border-color: #000; box-shadow: 2px 2px 0 #000; }
.ct-pager { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px; padding: 36px 0 8px; }
.ct-num, .ct-gap { min-width: 40px; height: 40px; padding: 0 10px; display: inline-grid; place-items: center; border-radius: 12px; font-weight: 800; }
.ct-num { background: var(--surface); border: 2px solid var(--border-strong); }
.ct-num:hover { border-color: var(--espresso); }
.ct-num.is-current { background: var(--espresso); color: #fff8ee; border-color: var(--espresso); }
:root[data-theme="dark"] .ct-num.is-current { background: var(--surface-3); color: var(--text); }
.ct-gap { color: var(--text-3); }
.ct-empty { padding: 64px 20px; }

/* ---------------------------------------------------------------- post cards (also used on the home page) */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.post-card { display: flex; flex-direction: column; border-radius: var(--radius-lg); overflow: hidden; background: var(--surface);
  border: 2px solid var(--espresso); box-shadow: var(--sticker); transition: transform var(--med) var(--ease), box-shadow var(--med) var(--ease); }
.post-card:hover { transform: translate(-2px, -3px); box-shadow: 5px 6px 0 var(--espresso); }
:root[data-theme="dark"] .post-card { border-color: #000; }
:root[data-theme="dark"] .post-card:hover { box-shadow: 5px 6px 0 #000; }
.post-card-media { position: relative; aspect-ratio: 16 / 10; background: var(--surface-2); border-bottom: 2px solid var(--espresso); overflow: hidden; }
:root[data-theme="dark"] .post-card-media { border-bottom-color: #000; }
.post-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease); }
.post-card:hover .post-card-media img { transform: scale(1.04); }
.post-card-ph { width: 100%; height: 100%; display: grid; place-items: center; color: var(--brick);
  background: conic-gradient(var(--surface-3) 25%, transparent 0 50%, var(--surface-3) 0 75%, transparent 0) 0 0 / 22px 22px; }
.post-card-ph .icon { width: 44px; height: 44px; padding: 8px; border-radius: 12px; background: var(--surface); border: 2px solid var(--espresso); box-sizing: content-box; }
.post-kind { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 800;
  letter-spacing: 0.03em; background: var(--mustard); color: var(--espresso); border: 1.5px solid var(--espresso); }
.post-card-media .post-kind { position: absolute; left: 12px; top: 12px; }
.post-card-body { display: flex; flex-direction: column; gap: 6px; flex: 1; padding: 16px 18px 18px; }
.post-card-body time { font-size: 12.5px; font-weight: 700; color: var(--text-3); }
.post-card-body h3 { font-family: var(--font-display); font-size: 20px; font-weight: 800; line-height: 1.25; }
.post-card-body p { color: var(--text-2); line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.post-more { display: inline-flex; align-items: center; gap: 4px; margin-top: auto; padding-top: 6px; font-weight: 800; color: var(--accent-text);
  transition: gap var(--fast) var(--ease); }
.post-card:hover .post-more { gap: 8px; }

/* ---------------------------------------------------------------- post page */
.post { max-width: 900px; }
.post-head { padding: 22px 0 22px; }
.post-meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; font-size: 13.5px; font-weight: 700; color: var(--text-3); }
.post-meta time { display: inline-flex; align-items: center; gap: 6px; }
.post-head h1 { font-family: var(--font-display); font-weight: 800; font-size: clamp(30px, 4.6vw, 48px); line-height: 1.08; letter-spacing: -0.01em; }
.post-lead { margin-top: 14px; font-size: 18px; line-height: 1.6; color: var(--text-2); }
.post-cover { margin: 0 0 30px; border-radius: 22px; overflow: hidden; aspect-ratio: 16 / 9; background: var(--surface-2);
  border: 2px solid var(--espresso); box-shadow: 6px 6px 0 var(--espresso); }
:root[data-theme="dark"] .post-cover { border-color: #000; box-shadow: 6px 6px 0 #000; }
.post-cover img { width: 100%; height: 100%; object-fit: cover; }
.post-body { max-width: 760px; font-size: 17px; }
.post-share { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; max-width: 760px;
  margin-top: 36px; padding-top: 22px; border-top: 2px dashed var(--border-strong); }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1000px) {
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cp-layout.has-side { grid-template-columns: minmax(0, 1fr); }
  .cp-side { position: static; }
}
@media (max-width: 640px) {
  .ct-hero { padding: 14px 0 20px; }
  .ct-section { padding: 18px 16px 32px; }
  .cp-layout { gap: 24px; }
  .cp-body { padding: 20px 18px; box-shadow: 4px 4px 0 var(--espresso); }
  :root[data-theme="dark"] .cp-body { box-shadow: 4px 4px 0 #000; }
  .prose { font-size: 15.5px; }
  .post-body { font-size: 16px; }
  .channels { grid-template-columns: minmax(0, 1fr); }
  .post-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .post-cover { border-radius: 16px; box-shadow: 4px 4px 0 var(--espresso); margin-bottom: 22px; }
  .post-lead { font-size: 16.5px; }
  .ct-num { min-width: 36px; height: 36px; }
}
