/* ==========================================================================
   Phòng tranh Nghị Lực Sống — giao diện
   Không cần build. Nhóm theo: tokens → nền tảng → bố cục → thành phần → trang
   ========================================================================== */

/* ---------- 1. Design tokens ----------
   Thương hiệu Nghị Lực Sống (lấy từ nghilucsong.net):
   xanh lá #8DC63F · tím đậm #2B0522 · nền kem #F7F2E9 · Oswald (tiêu đề) · Quicksand (nội dung) · Roboto Condensed (nhãn, nút)
   Lưu ý trợ năng: chữ trắng trên xanh #8DC63F chỉ đạt tương phản ~2:1 nên nút xanh dùng chữ tím đậm,
   còn chữ/liên kết xanh trên nền sáng dùng sắc xanh đậm hơn (--accent). */
:root {
  --plum: #2b0522;
  --plum-2: #21031a;
  --brand: #8dc63f;            /* xanh thương hiệu: dùng làm nền nút, nhấn */
  --brand-ink: #2b0522;        /* chữ trên nền xanh */
  --ink: #1b0f18;
  --ink-2: #4a3d47;
  --ink-3: #6a5c67;
  --paper: #ffffff;
  --paper-2: #f7f2e9;          /* kem của NLS */
  --wall: #f7f2e9;
  --card: #ffffff;
  --line: #e4dccf;
  --accent: #4d7c0f;           /* xanh đậm: chữ & liên kết trên nền sáng (≥ 4.5:1) */
  --accent-ink: #ffffff;
  --accent-soft: #eef6dc;
  --green: #2b0522;            /* “khối đậm” (tím) dùng cho banner nổi bật */
  --green-soft: #eef6dc;
  --sun: #e8a33d;
  --danger: #b3261e;
  --danger-soft: #fbe4e1;
  --ok: #1d6b43;
  --ok-soft: #dff1e6;
  --warn-soft: #fdf0d3;
  --focus: #1a56db;

  --radius: 8px;
  --radius-sm: 5px;
  --shadow: 0 1px 2px rgba(43, 5, 34, .06), 0 10px 28px rgba(43, 5, 34, .08);
  --shadow-art: 0 2px 4px rgba(43, 5, 34, .14), 0 14px 34px rgba(43, 5, 34, .18);

  --font-sans: "Quicksand", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Oswald", "Roboto Condensed", "Arial Narrow", Impact, sans-serif;   /* tên cũ, nay là phông tiêu đề */
  --font-label: "Roboto Condensed", "Arial Narrow", sans-serif;

  --text-scale: 1;
  --maxw: 1240px;
  --gutter: clamp(1rem, 4vw, 2rem);
  --av-bg-l: 88%;
  --av-fg-l: 28%;
  color-scheme: light;
}

[data-theme="dark"] {
  --ink: #f6eef4;
  --ink-2: #dccfd9;
  --ink-3: #b3a2af;
  --paper: #17020f;
  --paper-2: #21031a;
  --wall: #1d0316;
  --card: #2b0522;
  --line: #4d2a45;
  --accent: #a6dc5c;
  --accent-ink: #17020f;
  --accent-soft: #2c3d14;
  --green: #2b0522;
  --green-soft: #2c3d14;
  --danger: #ff9b92;
  --danger-soft: #3d1d1a;
  --ok: #7fd6a3;
  --ok-soft: #173325;
  --warn-soft: #3a2f14;
  --focus: #8ab4ff;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px rgba(0, 0, 0, .35);
  --shadow-art: 0 2px 4px rgba(0, 0, 0, .5), 0 14px 34px rgba(0, 0, 0, .5);
  --av-bg-l: 24%;
  --av-fg-l: 82%;
  color-scheme: dark;
}

[data-theme="contrast"] {
  --ink: #000000;
  --ink-2: #000000;
  --ink-3: #1a1a1a;
  --paper: #ffffff;
  --paper-2: #ffffff;
  --wall: #ffffff;
  --card: #ffffff;
  --line: #000000;
  --accent: #2f5000;
  --accent-ink: #ffffff;
  --accent-soft: #f0f8e0;
  --green: #000000;
  --green-soft: #f0f8e0;
  --danger: #8a0000;
  --danger-soft: #fff0f0;
  --ok: #004d1f;
  --ok-soft: #eaffef;
  --warn-soft: #fff7d6;
  --focus: #0033cc;
  --shadow: none;
  --shadow-art: 0 0 0 2px #000;
  --av-bg-l: 92%;
  --av-fg-l: 15%;
}

/* ---------- 2. Nền tảng ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { font-size: calc(100% * var(--text-scale)); scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font-sans); font-size: 1rem; line-height: 1.65;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
[data-theme="contrast"] a { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.2; font-weight: 500; }
h1, h2, h3 { font-family: var(--font-serif); }
strong, b { font-weight: 700; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.25em; }
address { font-style: normal; }
dl, dd { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
main:focus { outline: none; }

.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 200; background: var(--ink); color: var(--paper); padding: .6rem 1rem; border-radius: 0 0 8px 8px; }
.skip-link:focus { top: 0; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.muted { color: var(--ink-3); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- 3. Bố cục ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: 780px; }
.section { padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.section--tight { padding-block: clamp(1.25rem, 3vw, 2.25rem); }
.band { background: var(--paper-2); border-block: 1px solid var(--line); }
.page-head { padding-block: clamp(2rem, 5vw, 3.5rem) 1.5rem; }
.page-pad { padding-block: 4rem; }
.section__head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.75rem; }
.section__head .h1 { margin: 0; }

/* Typography */
.display { font-family: var(--font-serif); font-weight: 500; font-size: clamp(2rem, 5.2vw, 3.6rem); line-height: 1.1; letter-spacing: -.01em; margin-bottom: .4em; }
.display em { color: var(--accent); font-style: normal; }
.h1 { font-family: var(--font-serif); font-weight: 500; font-size: clamp(1.5rem, 3.2vw, 2.1rem); }
.h2 { font-family: var(--font-serif); font-weight: 500; font-size: 1.45rem; margin-top: 1.8em; }
.h3 { font-size: 1.15rem; }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--ink-2); max-width: 46rem; }
.eyebrow { font-family: var(--font-label); font-size: .95rem; letter-spacing: 1.5px; text-transform: uppercase; font-weight: 600; color: var(--accent); margin-bottom: .75rem; }
.eyebrow a { text-decoration: none; }
.link-arrow { font-weight: 600; text-decoration: none; white-space: nowrap; }
.link-arrow:hover { text-decoration: underline; }
.prose { max-width: 42rem; font-size: 1.06rem; }
.prose.narrow { max-width: 780px; }
.prose > :first-child { margin-top: 0; }
.prose li { margin-bottom: .5em; }
.plain-list { list-style: none; padding: 0; }
.plain-list li { padding: .35rem 0; border-bottom: 1px solid var(--line); }

/* ---------- 4. Thành phần ---------- */
/* Nút */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 2.9rem; padding: .55rem 1.6rem; border-radius: var(--radius-sm); border: 2px solid transparent;
  font-family: var(--font-label); text-transform: uppercase; letter-spacing: .04em; font-weight: 600; font-size: 1rem; line-height: 1.2; text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s, transform .15s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.btn--primary:hover { background: color-mix(in srgb, var(--brand) 82%, #000); border-color: color-mix(in srgb, var(--brand) 82%, #000); text-decoration: none; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn--ghost:hover { background: var(--plum); color: var(--brand); border-color: var(--plum); text-decoration: none; }
[data-theme="dark"] .btn--ghost:hover { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.btn--quiet { background: transparent; color: var(--ink-2); }
.btn--quiet:hover { background: var(--paper-2); text-decoration: none; }
.btn--danger { background: var(--danger); color: #fff; }
.btn--quiet.btn--danger { background: transparent; color: var(--danger); }
.btn--quiet.btn--danger:hover { background: var(--danger-soft); }
.btn--small { min-height: 2.4rem; padding: .35rem 1rem; font-size: .9rem; }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; }
.inline-form { display: inline; margin: 0; }

/* Thanh tiện ích (cỡ chữ, giao diện) */
.utility { background: var(--plum); color: #fff; font-size: .82rem; }
.utility__inner { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 2.5rem; flex-wrap: wrap; }
.utility__org { color: #fff; text-decoration: none; }
.utility__org:hover { text-decoration: underline; }
.utility__tools { display: flex; align-items: center; gap: .25rem; flex-wrap: wrap; }
.tool { background: transparent; border: 1px solid transparent; border-radius: var(--radius-sm); padding: .2rem .55rem; cursor: pointer; color: #fff; min-height: 1.9rem; }
.tool:hover { border-color: rgba(255, 255, 255, .45); }
.tool[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); font-weight: 700; }
.tool-sep { width: 1px; height: 1.1rem; background: rgba(255, 255, 255, .35); margin-inline: .35rem; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 4.5rem; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand__mark { height: 3.4rem; width: auto; flex: none; }
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__text strong { font-family: var(--font-serif); font-weight: 500; font-size: 1.35rem; text-transform: uppercase; letter-spacing: .02em; }
.brand__text span { font-family: var(--font-label); font-size: .8rem; letter-spacing: 1.5px; text-transform: uppercase; color: var(--accent); font-weight: 600; margin-top: .2rem; }
.site-nav { display: flex; align-items: center; gap: 1.25rem; }
.site-nav ul { display: flex; gap: .25rem; list-style: none; margin: 0; padding: 0; }
.site-nav ul a { display: block; padding: .5rem .8rem; border-radius: var(--radius-sm); color: var(--ink); text-decoration: none; font-weight: 500; }
.site-nav ul a:hover { background: var(--paper-2); }
.site-nav ul a[aria-current="page"] { background: var(--paper-2); color: var(--accent); font-weight: 700; box-shadow: inset 0 -3px 0 var(--brand); }
[data-theme="contrast"] .site-nav ul a[aria-current="page"] { outline: 2px solid #000; }
.site-nav__account { display: flex; align-items: center; gap: .4rem; }
.site-search { position: relative; }
.site-search input { width: 12.5rem; min-height: 2.5rem; padding: .35rem 2.5rem .35rem 1rem; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--card); }
.site-search button { position: absolute; right: .25rem; top: 50%; transform: translateY(-50%); width: 2rem; height: 2rem; border: 0; background: transparent; cursor: pointer; border-radius: 50%; color: var(--ink-2); display: grid; place-items: center; }
.nav-toggle { display: none; align-items: center; gap: .6rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: .5rem 1rem; cursor: pointer; font-weight: 600; }
.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { display: block; width: 1.1rem; height: 2px; background: currentColor; border-radius: 2px; position: relative; content: ""; }
.nav-toggle__bars::before { position: absolute; top: -6px; }
.nav-toggle__bars::after { position: absolute; top: 6px; }

.site-nav ul a, .site-nav__account .btn { white-space: nowrap; }
@media (max-width: 1100px) {
  .nav-toggle { display: inline-flex; }
  .site-nav { position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 1rem; padding: 1rem var(--gutter) 1.5rem; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); display: none; }
  .site-nav.is-open { display: flex; }
  .site-nav ul { flex-direction: column; }
  .site-search input { width: 100%; }
  .site-nav__account { flex-wrap: wrap; }
}

/* Thông báo */
.messages { padding-top: 1rem; }
.message { margin: 0 0 .5rem; padding: .85rem 1.1rem; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--card); font-weight: 500; }
.message--success { background: var(--ok-soft); border-color: var(--ok); color: var(--ok); }
.message--error { background: var(--danger-soft); border-color: var(--danger); color: var(--danger); }
.message--warning { background: var(--warn-soft); border-color: var(--sun); }
.note { padding: .9rem 1.1rem; border-radius: var(--radius-sm); background: var(--green-soft); border: 1px solid color-mix(in srgb, var(--green) 40%, transparent); }
.note--warn { background: var(--warn-soft); border-color: var(--sun); }
.note--error { background: var(--danger-soft); border-color: var(--danger); color: var(--danger); }
.note ul { margin: 0; padding-left: 1.1rem; }
.preview-bar { background: var(--warn-soft); border-bottom: 1px solid var(--sun); padding: .8rem 0; font-size: .95rem; }
.preview-bar a { margin-left: .75rem; font-weight: 600; }

/* Tag / badge / chip */
.tag { display: inline-block; padding: .2rem .7rem; border-radius: 999px; font-size: .78rem; font-weight: 600; letter-spacing: .02em; background: var(--paper-2); color: var(--ink-2); border: 1px solid var(--line); text-transform: none; }
.tag--ongoing { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.tag--upcoming { background: var(--warn-soft); color: #8a5a00; border-color: transparent; }
[data-theme="dark"] .tag--upcoming { color: var(--sun); }
.tag--available { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.badge { display: inline-block; padding: .25rem .75rem; border-radius: 999px; font-size: .8rem; font-weight: 600; background: var(--paper-2); }
.badge--published { background: var(--ok-soft); color: var(--ok); }
.badge--pending { background: var(--warn-soft); color: #8a5a00; }
[data-theme="dark"] .badge--pending { color: var(--sun); }
.badge--rejected { background: var(--danger-soft); color: var(--danger); }
.badge--draft { background: var(--paper-2); color: var(--ink-3); border: 1px solid var(--line); }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0 0 1rem; align-items: center; }
.chip { display: inline-block; padding: .3rem .85rem; border-radius: 999px; background: var(--card); border: 1px solid var(--line); color: var(--ink); font-size: .9rem; text-decoration: none; }
a.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip--removable { background: var(--accent-soft); border-color: transparent; color: var(--accent); font-weight: 600; }
.chips--lg .chip { font-size: 1rem; padding: .5rem 1.1rem; }

/* Ảnh đại diện */
.avatar { --s: 64px; width: var(--s); height: var(--s); border-radius: 50%; object-fit: cover; flex: none; background: var(--paper-2); }
.avatar--initials { display: grid; place-items: center; font-weight: 700; font-size: calc(var(--s) * .36); background: hsl(var(--hue) 45% var(--av-bg-l)); color: hsl(var(--hue) 40% var(--av-fg-l)); }

/* Thẻ tranh + lưới masonry */
.masonry { columns: 1; column-gap: 1.75rem; }
@media (min-width: 560px) { .masonry { columns: 2; } }
@media (min-width: 900px) { .masonry { columns: 3; } }
@media (min-width: 1180px) { .masonry { columns: 4; } }
.masonry--compact { columns: 2; }
@media (min-width: 900px) { .masonry--compact { columns: 3; } }
@media (min-width: 1180px) { .masonry--compact { columns: 3; } }

.card { position: relative; break-inside: avoid; margin: 0 0 1.9rem; }
.card__frame { overflow: hidden; background: var(--bg, #ddd); aspect-ratio: var(--ar, 4 / 3); border-radius: 3px; box-shadow: var(--shadow-art); }
.card__frame img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.card:hover .card__frame img { transform: scale(1.04); }
.card__title { font-family: var(--font-serif); font-weight: 500; font-size: 1.1rem; margin: .8rem 0 .1rem; line-height: 1.3; }
.card__title a { color: var(--ink); text-decoration: none; }
.card__title a::after { content: ""; position: absolute; inset: 0; }
.card:hover .card__title a { color: var(--accent); }
.card:has(a:focus-visible) .card__frame { outline: 3px solid var(--focus); outline-offset: 3px; }
.card__title a:focus-visible { outline: none; }
.card__meta { color: var(--ink-3); font-size: .9rem; margin: 0; }
.card__flag { display: inline-block; margin: .35rem 0 0; font-size: .75rem; font-weight: 700; color: #8a5a00; background: var(--warn-soft); padding: .1rem .55rem; border-radius: 999px; }

/* Tác giả */
.artist-grid { display: grid; gap: 2rem 1.5rem; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); }
.artist-card { position: relative; text-align: center; }
.artist-card .avatar { margin: 0 auto .9rem; box-shadow: var(--shadow); }
.artist-card__name { font-family: var(--font-serif); font-size: 1.1rem; margin: 0 0 .2rem; }
.artist-card__name a { color: var(--ink); text-decoration: none; }
.artist-card__name a::after { content: ""; position: absolute; inset: 0; }
.artist-card:hover .artist-card__name a { color: var(--accent); }
.artist-card__tag { font-size: .88rem; color: var(--ink-2); margin: 0 0 .25rem; }
.artist-card__meta { font-size: .85rem; color: var(--ink-3); margin: 0; }

/* Triển lãm (thẻ) */
.exh-grid { display: grid; gap: 1.75rem; grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr)); }
.exh-card { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: transform .2s; }
.exh-card:hover { transform: translateY(-3px); }
.exh-card__media { position: relative; aspect-ratio: 16 / 10; background: linear-gradient(135deg, var(--accent-soft), var(--green-soft)); overflow: hidden; }
.exh-card__media img { width: 100%; height: 100%; object-fit: cover; }
.exh-card__media .tag { position: absolute; left: .85rem; top: .85rem; box-shadow: var(--shadow); background: var(--card); }
.exh-card__media .tag--ongoing { background: var(--ok-soft); }
.exh-card__media .tag--upcoming { background: var(--warn-soft); }
.exh-card__body { padding: 1.1rem 1.25rem 1.3rem; }
.exh-card__title { font-family: var(--font-serif); font-size: 1.25rem; margin: 0 0 .25rem; }
.exh-card__title a { color: var(--ink); text-decoration: none; }
.exh-card__title a::after { content: ""; position: absolute; inset: 0; }
.exh-card:hover .exh-card__title a { color: var(--accent); }
.exh-card__sub { color: var(--ink-2); margin: 0 0 .5rem; }
.exh-card__meta { color: var(--ink-3); font-size: .88rem; margin: 0; }

/* Phân trang */
.pagination { display: flex; justify-content: center; align-items: center; gap: .75rem; flex-wrap: wrap; margin-top: 2.5rem; }
.pagination__pages { display: flex; gap: .3rem; list-style: none; margin: 0; padding: 0; }
.pagination a, .pagination__current { display: grid; place-items: center; min-width: 2.6rem; height: 2.6rem; padding-inline: .7rem; border-radius: 999px; text-decoration: none; color: var(--ink); border: 1px solid transparent; }
.pagination a:hover { background: var(--paper-2); }
.pagination__current { background: var(--ink); color: var(--paper); font-weight: 700; }
.pagination__step { border: 1px solid var(--line) !important; font-weight: 600; }

/* Số liệu */
.stats { display: flex; gap: 2.25rem; flex-wrap: wrap; margin: 2rem 0 0; }
.stats dt { font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.stats dd { font-family: var(--font-serif); font-size: 2.1rem; font-weight: 500; line-height: 1.1; }
.stats--boxed { margin: 0; gap: 1rem; }
.stats--boxed > div { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.4rem; min-width: 8.5rem; }
.stats--boxed dd { font-size: 1.8rem; }

/* Trạng thái rỗng */
.empty { text-align: center; padding: 3rem 1rem; max-width: 36rem; margin-inline: auto; }
.empty-note { color: var(--ink-3); font-style: italic; padding: 2rem 0; }

/* Breadcrumb */
.crumbs { padding-top: 1.25rem; font-size: .9rem; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; margin: 0; padding: 0; color: var(--ink-3); }
.crumbs li + li::before { content: "/"; margin-right: .4rem; }
.crumbs a { color: var(--ink-2); }

/* ---------- 5. Trang chủ ---------- */
.hero-band { background: var(--plum); color: #fff; }
.hero-band .display { color: #fff; }
.hero-band .display em { color: var(--brand); }
.hero-band .lead { color: rgba(255, 255, 255, .88); }
.hero-band .eyebrow { color: var(--brand); }
.hero-band .stats dd { color: var(--brand); }
.hero-band .stats dt { color: rgba(255, 255, 255, .75); }
.hero-band .btn--ghost { color: #fff; border-color: #fff; }
.hero-band .btn--ghost:hover { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.hero { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: center; padding-block: clamp(2rem, 5vw, 4rem); grid-template-columns: 1fr; }
@media (min-width: 900px) { .hero { grid-template-columns: 1.05fr 1fr; } }
.hero__cta { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.5rem; }
.hero__wall { position: relative; aspect-ratio: 1 / 1; width: 100%; max-width: 560px; margin-inline: auto; background: radial-gradient(circle at 30% 20%, rgba(141, 198, 63, .35), transparent 60%), radial-gradient(circle at 80% 80%, rgba(255, 255, 255, .10), transparent 55%); border-radius: var(--radius); }
.hero__wall[data-empty] { display: grid; place-items: center; }
.hero__frame { position: absolute; display: block; background: var(--card); padding: .55rem; box-shadow: var(--shadow-art); border-radius: 3px; text-decoration: none; color: var(--ink); transition: transform .35s cubic-bezier(.2, .7, .2, 1), z-index 0s; }
.hero__frame img { width: 100%; height: 100%; object-fit: cover; background: var(--bg); }
.hero__frame:hover, .hero__frame:focus-visible { transform: rotate(0) scale(1.03); z-index: 5; }
.hero__caption { position: absolute; left: .55rem; right: .55rem; bottom: .55rem; padding: .5rem .65rem; font-size: .78rem; line-height: 1.3; background: linear-gradient(transparent, rgba(0, 0, 0, .72)); color: #fff; opacity: 0; transition: opacity .25s; padding-top: 1.5rem; }
.hero__frame:hover .hero__caption, .hero__frame:focus-visible .hero__caption { opacity: 1; }
.hero__frame--1 { left: 2%; top: 4%; width: 52%; aspect-ratio: 4 / 5; transform: rotate(-3deg); z-index: 2; }
.hero__frame--2 { right: 2%; top: 14%; width: 44%; aspect-ratio: 1 / 1; transform: rotate(2.5deg); z-index: 3; }
.hero__frame--3 { left: 30%; bottom: 3%; width: 46%; aspect-ratio: 5 / 4; transform: rotate(-1.5deg); z-index: 4; }
.hero__frame:only-child { left: 12%; top: 8%; width: 76%; aspect-ratio: 1 / 1; }

.spotlight { background: var(--green); color: #fff; }
[data-theme="contrast"] .spotlight { background: #000; }
.spotlight a { color: #fff; }
.spotlight .eyebrow { color: var(--brand); }
.spotlight .h1 { color: #fff; }
.spotlight .lead, .spotlight .muted { color: rgba(255, 255, 255, .85); }
.spotlight__inner { display: grid; gap: 2rem; align-items: center; padding-block: clamp(2rem, 5vw, 3.5rem); }
@media (min-width: 800px) { .spotlight__inner { grid-template-columns: 1fr 1.1fr; } }
.spotlight__media { aspect-ratio: 16 / 10; background: rgba(255, 255, 255, .1); border-radius: var(--radius); overflow: hidden; }
.spotlight__media img { width: 100%; height: 100%; object-fit: cover; }
.spotlight__text { order: -1; }
@media (min-width: 800px) { .spotlight__text { order: 0; } .spotlight__media { order: 1; } .spotlight__text { order: 0; } }

.cta__box { display: grid; gap: 1.5rem; align-items: center; background: var(--plum); color: #fff; border-radius: var(--radius); padding: clamp(1.75rem, 4vw, 3rem); }
.cta__box .h1 { color: #fff; }
.cta__box .lead { color: rgba(255, 255, 255, .88); }
.cta__box .btn--ghost { color: #fff; border-color: #fff; }
.cta__box .btn--ghost:hover { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
@media (min-width: 800px) { .cta__box { grid-template-columns: 1fr auto; } }
.cta__box .h1 { margin-bottom: .4em; }
.cta__box .lead { margin: 0; }
.cta__actions { display: flex; gap: .75rem; flex-wrap: wrap; margin: 0; }
[data-theme="contrast"] .cta__box { background: #000; }

/* ---------- 6. Bộ lọc ---------- */
.filters { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.25rem; }
.filters__grid { display: grid; gap: .9rem 1rem; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); align-items: end; }
.filters .field { margin: 0; }
.field--grow { grid-column: span 2; }
@media (max-width: 560px) { .field--grow { grid-column: auto; } }
.filters .chips { margin: 1rem 0 0; }
.inline-search { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; margin-top: 1.25rem; }
.inline-search input { min-width: min(100%, 20rem); }

/* ---------- 7. Chi tiết tranh (bảng tên kiểu triển lãm) ---------- */
.stage { background: color-mix(in srgb, var(--bg, #d8cfc2) 16%, var(--wall)); margin-top: 1rem; padding-block: clamp(1.5rem, 4vw, 3.5rem); border-block: 1px solid var(--line); }
.stage__grid { display: grid; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: start; }
@media (min-width: 960px) { .stage__grid { grid-template-columns: minmax(0, 1.5fr) minmax(20rem, 1fr); } }
.artwork { margin: 0; }
.artwork__frame { position: relative; display: block; width: fit-content; max-width: 100%; margin-inline: auto; padding: 0; border: 0; background: var(--bg); cursor: zoom-in; box-shadow: var(--shadow-art); border-radius: 2px; }
.artwork__frame img { display: block; width: auto; height: auto; max-width: 100%; max-height: min(78vh, 900px); margin-inline: auto; }
.artwork__frame.landscape img { width: 100%; }
.artwork__zoom { position: absolute; right: .75rem; bottom: .75rem; padding: .35rem .85rem; border-radius: 999px; font-size: .8rem; font-weight: 600; background: rgba(20, 15, 10, .72); color: #fff; opacity: 0; transition: opacity .2s; pointer-events: none; }
.artwork__frame:hover .artwork__zoom, .artwork__frame:focus-visible .artwork__zoom { opacity: 1; }
@media (hover: none) { .artwork__zoom { opacity: 1; } }
.thumbs { display: flex; gap: .6rem; list-style: none; padding: 0; margin: 1.25rem 0 0; flex-wrap: wrap; justify-content: center; }
.thumbs__btn { width: 4.5rem; height: 4.5rem; padding: 0; border: 2px solid transparent; border-radius: 6px; overflow: hidden; background: var(--card); cursor: pointer; opacity: .8; }
.thumbs__btn:hover, .thumbs__btn.is-current { opacity: 1; border-color: var(--accent); }
.thumbs__btn img { width: 100%; height: 100%; object-fit: cover; }

.label { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.25rem, 3vw, 2rem); box-shadow: var(--shadow); }
@media (min-width: 960px) { .label { position: sticky; top: 6rem; } }
.label__code { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin-bottom: .5rem; }
.label__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin-bottom: .3rem; }
.label__artist { font-size: 1.15rem; margin-bottom: 1.25rem; }
.label__artist a { font-weight: 600; text-decoration: none; }
.label__artist a:hover { text-decoration: underline; }
.specs { border-top: 1px solid var(--line); margin-bottom: 1.25rem; }
.specs > div { display: grid; grid-template-columns: 9.5rem 1fr; gap: 1rem; padding: .6rem 0; border-bottom: 1px solid var(--line); font-size: .95rem; }
.specs dt { color: var(--ink-3); }
.specs dd { font-weight: 500; }
.specs a { color: var(--ink); }
@media (max-width: 440px) { .specs > div { grid-template-columns: 1fr; gap: .1rem; } }
.label__credit { font-size: .85rem; color: var(--ink-3); margin: 1rem 0 1.25rem; }
.label__actions { display: flex; flex-wrap: wrap; gap: .6rem; }

.story-grid { display: grid; gap: 2.5rem; padding-block: clamp(2rem, 5vw, 3.5rem); }
@media (min-width: 960px) { .story-grid { grid-template-columns: minmax(0, 1fr) 21rem; gap: 4rem; } }
.pullstory { border-left: 4px solid var(--accent); padding-left: 1.4rem; font-family: var(--font-serif); font-size: 1.2rem; line-height: 1.75; color: var(--ink-2); }
.artist-aside { align-self: start; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.artist-aside__head { display: flex; gap: 1rem; align-items: center; margin-bottom: 1rem; }
.artist-aside__name { font-family: var(--font-serif); font-size: 1.2rem; font-weight: 500; margin: 0; }
.artist-aside__name a { color: var(--ink); text-decoration: none; }
.pager { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; padding-block: 2rem 3rem; }
.pager__item { display: flex; flex-direction: column; gap: .2rem; padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); background: var(--card); }
.pager__item:hover { border-color: var(--accent); }
.pager__item--next { text-align: right; grid-column: 2; }
.pager__item span { font-size: .85rem; }

/* ---------- 8. Tác giả (chi tiết) ---------- */
.artist-head { display: grid; gap: 1.75rem; align-items: center; padding-block: clamp(2rem, 5vw, 3.5rem) 1rem; }
@media (min-width: 700px) { .artist-head { grid-template-columns: auto 1fr; gap: 2.5rem; } }
.artist-head .avatar { box-shadow: var(--shadow-art); }
.meta-line { display: flex; flex-wrap: wrap; gap: .4rem 1.25rem; list-style: none; padding: 0; margin: 0 0 .75rem; color: var(--ink-2); }
.links { display: flex; gap: 1.25rem; }
.artist-bio { padding-block: 1rem 0; }

/* ---------- 9. Triển lãm (chi tiết) ---------- */
.exh-hero { position: relative; background: var(--paper-2); border-bottom: 1px solid var(--line); overflow: hidden; }
.exh-hero__inner { position: relative; padding-block: clamp(2.5rem, 7vw, 5rem); }
.exh-hero--cover { color: #fff; background: #1b1511; }
.exh-hero--cover .exh-hero__inner { padding-block: clamp(4rem, 12vw, 8rem) clamp(2.5rem, 6vw, 4rem); }
.exh-hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.exh-hero--cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 14, 10, .15), rgba(20, 14, 10, .78)); }
.exh-hero--cover .exh-hero__inner { z-index: 1; }
.exh-hero--cover .lead, .exh-hero--cover .exh-facts dt { color: rgba(255, 255, 255, .85); }
.exh-hero--cover .eyebrow { color: #fff; }
.exh-facts { display: flex; flex-wrap: wrap; gap: 1rem 2.5rem; margin: 1.5rem 0; }
.exh-facts dt { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.exh-facts dd { font-weight: 600; }
.curatorial { padding-block: 3rem 1rem; }
.curatorial p:first-of-type::first-letter { font-family: var(--font-serif); font-size: 3.4em; float: left; line-height: .9; padding: .08em .1em 0 0; color: var(--accent); }
.walk { padding-block: 2rem 4rem; display: grid; gap: clamp(2.5rem, 7vw, 5rem); }
.walk__item { display: grid; gap: 1.5rem; align-items: center; }
@media (min-width: 900px) {
  .walk__item { grid-template-columns: 1.3fr 1fr; gap: 3.5rem; }
  .walk__item--flip { grid-template-columns: 1fr 1.3fr; }
  .walk__item--flip .walk__art { order: 2; }
}
.walk__art { background: color-mix(in srgb, var(--bg, #d8cfc2) 14%, var(--wall)); padding: clamp(1rem, 4vw, 2.5rem); border-radius: var(--radius); display: grid; place-items: center; }
.walk__btn { display: block; padding: 0; border: 0; background: var(--bg); cursor: zoom-in; box-shadow: var(--shadow-art); max-width: 100%; }
.walk__btn img { max-height: 70vh; width: auto; margin-inline: auto; }
.walk__title { font-family: var(--font-serif); font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: .2rem; }
.walk__title a { color: var(--ink); text-decoration: none; }
.walk__title a:hover { color: var(--accent); }
.curator-note { margin: 1.25rem 0; padding: 1rem 1.25rem; background: var(--accent-soft); border-radius: var(--radius-sm); }
.curator-note__by { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 600; color: var(--accent); margin-bottom: .4rem; }
.curator-note p:last-child { margin-bottom: 0; }

/* ---------- 10. Trang tĩnh ---------- */
.steps { list-style: none; display: grid; gap: 1.25rem; padding: 0; counter-reset: s; }
@media (min-width: 800px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps__item { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; }
.steps__num { display: grid; place-items: center; width: 2.6rem; height: 2.6rem; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-family: var(--font-serif); font-size: 1.2rem; margin-bottom: 1rem; }
.faq { border-bottom: 1px solid var(--line); padding: .85rem 0; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq p { margin: .75rem 0 0; color: var(--ink-2); }
.contact-grid { display: grid; gap: 2.5rem; padding-bottom: 4rem; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: minmax(0, 1.4fr) 1fr; } }
.contact-info { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; align-self: start; }

/* ---------- 11. Biểu mẫu ---------- */
.form { display: grid; gap: 1.1rem; }
.card-form { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.25rem, 3vw, 2rem); }
.field { display: grid; gap: .35rem; margin: 0; min-width: 0; }
.field > label, .field > legend, .field--group legend { font-weight: 600; font-size: .95rem; padding: 0; }
.req { color: var(--danger); }
input[type="text"], input[type="email"], input[type="password"], input[type="search"], input[type="url"], input[type="number"], input[type="tel"], select, textarea {
  width: 100%; min-height: 2.9rem; padding: .6rem .9rem; border: 1.5px solid color-mix(in srgb, var(--ink) 35%, var(--line)); border-radius: var(--radius-sm); background: var(--card); color: var(--ink);
}
[data-theme="contrast"] input, [data-theme="contrast"] select, [data-theme="contrast"] textarea { border-color: #000; border-width: 2px; }
textarea { min-height: 7rem; resize: vertical; line-height: 1.55; }
input:focus, select:focus, textarea:focus { outline: 3px solid var(--focus); outline-offset: 1px; border-color: transparent; }
input[type="file"] { width: 100%; padding: .75rem; border: 2px dashed var(--line); border-radius: var(--radius-sm); background: var(--paper-2); cursor: pointer; }
input[type="file"]::file-selector-button { margin-right: 1rem; border: 0; border-radius: 999px; padding: .5rem 1.1rem; background: var(--ink); color: var(--paper); font-weight: 600; cursor: pointer; }
.help { margin: 0; font-size: .87rem; color: var(--ink-3); }
.error { margin: 0; font-size: .9rem; font-weight: 600; color: var(--danger); }
.field--error input, .field--error select, .field--error textarea { border-color: var(--danger); }
.check { display: flex; gap: .7rem; align-items: flex-start; font-weight: 400; cursor: pointer; }
.check input { width: 1.3rem; height: 1.3rem; margin-top: .2rem; flex: none; accent-color: var(--accent); }
.field--group { border: 0; padding: 0; }
.field--group > div > div, .field--group div > div { display: inline-block; }
.field--group label { display: inline-flex; align-items: center; gap: .5rem; padding: .4rem .9rem; margin: 0 .5rem .5rem 0; border: 1.5px solid var(--line); border-radius: 999px; background: var(--card); cursor: pointer; font-weight: 500; font-size: .92rem; }
.field--group label:has(input:checked) { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.field--group input { accent-color: var(--accent); width: 1.05rem; height: 1.05rem; }
.form-section { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem 1.5rem 1.6rem; display: grid; gap: 1.1rem; background: var(--card); margin: 0; min-width: 0; }
.form-section > legend { font-family: var(--font-serif); font-weight: 500; font-size: 1.2rem; padding-inline: .6rem; }
.field-row { display: grid; gap: 1.1rem; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } .field-row--3 { grid-template-columns: repeat(3, 1fr); } }
.form-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin: 0; align-items: center; }
.uploader__preview { margin-top: .75rem; }
.uploader__preview img { max-height: 320px; width: auto; border-radius: var(--radius-sm); box-shadow: var(--shadow); }
.current-image img { max-height: 280px; width: auto; border-radius: var(--radius-sm); box-shadow: var(--shadow); }
.extra-list { display: flex; flex-wrap: wrap; gap: .6rem; list-style: none; padding: 0; margin: 0; }
.extra-list img { width: 96px; height: 96px; object-fit: cover; border-radius: 6px; }
.editor-grid { display: grid; gap: 2rem; padding-bottom: 4rem; }
@media (min-width: 1000px) { .editor-grid { grid-template-columns: minmax(0, 1fr) 20rem; } }
.tips { background: var(--green-soft); border-radius: var(--radius); padding: 1.4rem 1.5rem; align-self: start; font-size: .95rem; }
@media (min-width: 1000px) { .tips { position: sticky; top: 6rem; } }
.tips ul { padding-left: 1.1rem; margin: 0; }
.tips li { margin-bottom: .6rem; }

/* Đăng nhập / đăng ký */
.auth { display: grid; place-items: start center; padding-block: clamp(2rem, 6vw, 4.5rem); }
.auth__box { width: 100%; max-width: 28rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.5rem, 4vw, 2.25rem); box-shadow: var(--shadow); }
.auth__box--wide { max-width: 36rem; }
.auth__links { margin: 1.25rem 0 0; text-align: center; font-size: .95rem; }

/* Bảng điều khiển tác giả */
.works { list-style: none; padding: 0; display: grid; gap: .9rem; }
.work { display: grid; gap: .75rem 1.1rem; grid-template-columns: 5rem 1fr; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; }
.work__thumb { width: 5rem; height: 5rem; object-fit: cover; border-radius: 8px; }
.work__title { font-family: var(--font-serif); font-size: 1.15rem; margin: 0 0 .15rem; }
.work__main p { margin: 0; font-size: .9rem; }
.work__main .note { margin-top: .6rem; }
.work__status, .work__actions { margin: 0; grid-column: 1 / -1; display: flex; gap: .4rem; flex-wrap: wrap; }
@media (min-width: 860px) {
  .work { grid-template-columns: 5rem 1fr auto auto; }
  .work__status, .work__actions { grid-column: auto; }
}
.account-links { padding-block: 1rem 4rem; }

/* ---------- 12. Chân trang ---------- */
.site-footer { margin-top: 3rem; background: var(--plum); color: #fff; font-size: .95rem; }
.footer-grid { display: grid; gap: 2rem; padding-block: 3rem 2rem; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1.2fr; gap: 3rem; } }
.footer-logo { height: 5.5rem; width: auto; margin-bottom: 1rem; }
.footer-brand { font-family: var(--font-serif); font-size: 1.35rem; font-weight: 500; text-transform: uppercase; margin-bottom: .6rem; }
.footer-h { font-family: var(--font-serif); font-size: 1.15rem; font-weight: 500; letter-spacing: .02em; text-transform: uppercase; color: #fff; margin-bottom: .8rem; }
.footer-list { list-style: none; padding: 0; margin: 0; }
.footer-list li { margin-bottom: .4rem; }
.footer-list p { margin-bottom: .4rem; }
.footer-list a, .site-footer a { color: #fff; }
.site-footer a:hover { color: var(--brand); }
.footer-phone { font-family: var(--font-label); font-size: 1.6rem; font-weight: 600; color: var(--brand) !important; text-decoration: none; }
.site-footer .btn--primary, .site-footer .btn--primary:hover { color: var(--brand-ink); }
.footer-social { display: flex; gap: 1rem; }
.footer-legal { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-top: 1px solid rgba(255, 255, 255, .2); padding-block: 1.25rem 2rem; color: rgba(255, 255, 255, .75); font-size: .85rem; }
.footer-legal p { margin: 0; }

/* ---------- 13. Trình xem ảnh (lightbox / trình chiếu) ---------- */
.viewer { position: fixed; inset: 0; z-index: 1000; display: grid; grid-template-rows: auto 1fr auto; background: rgba(12, 9, 6, .96); color: #f5eee4; }
.viewer[hidden] { display: none; }
.viewer__bar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .75rem 1rem; }
.viewer__count { font-size: .9rem; opacity: .8; }
.viewer__tools { display: flex; gap: .4rem; }
.viewer__btn { display: inline-grid; place-items: center; min-width: 2.75rem; height: 2.75rem; padding: 0 .9rem; border: 1px solid rgba(255, 255, 255, .28); border-radius: 999px; background: rgba(255, 255, 255, .08); color: #fff; font-size: .95rem; font-weight: 600; cursor: pointer; }
.viewer__btn:hover { background: rgba(255, 255, 255, .2); }
.viewer__btn:focus-visible { outline: 3px solid #8ab4ff; }
.viewer__stage { position: relative; overflow: auto; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; min-height: 0; padding: .5rem 4rem; overscroll-behavior: contain; }
.viewer__img { width: 100%; height: 100%; object-fit: contain; cursor: zoom-in; user-select: none; -webkit-user-drag: none; transition: opacity .25s; }
.viewer__img.is-loading { opacity: .25; }
.viewer.is-zoomed .viewer__stage { grid-template: auto / auto; place-items: start; padding: 0; }
.viewer.is-zoomed .viewer__img { width: auto; height: auto; max-width: none; max-height: none; cursor: zoom-out; margin: auto; }
.viewer__nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 3rem; height: 3rem; font-size: 1.4rem; padding: 0; background: rgba(20, 15, 10, .7); }
.viewer__nav--prev { left: .75rem; }
.viewer__nav--next { right: .75rem; }
.viewer.is-zoomed .viewer__nav { display: none; }
.viewer__caption { padding: .9rem 1.25rem 1.4rem; text-align: center; }
.viewer__title { font-family: var(--font-serif); font-size: 1.3rem; margin: 0 0 .15rem; }
.viewer__meta { margin: 0; font-size: .95rem; opacity: .85; }
.viewer__link { display: inline-block; margin-top: .4rem; color: #ffcfa8; font-weight: 600; }
body.viewer-open { overflow: hidden; }
@media (max-width: 640px) {
  .viewer__stage { padding: .25rem; }
  .viewer__nav { top: auto; bottom: 5.5rem; transform: none; }
}

@media print {
  .utility, .site-header, .site-footer, .label__actions, .viewer, .skip-link { display: none !important; }
  body { background: #fff; color: #000; }
}
