/* =========================================================
   MỤC MỚI: Chào ngày mới · Các bài báo · Video · Tác phẩm · Thư viện ảnh
   ========================================================= */
.btn-sm { padding: 9px 16px; font-size: 13.5px; gap: 6px; }
.btn-sm svg { width: 15px; height: 15px; }
[hidden] { display: none !important; }

/* ---------- Chào ngày mới ---------- */
.sunrise {
  background:
    radial-gradient(900px 420px at 80% 110%, rgba(240, 170, 90, .35), transparent 60%),
    radial-gradient(700px 360px at 15% 0%, rgba(201,103,46,.12), transparent 60%),
    linear-gradient(180deg, #FBF3E6 0%, var(--paper-2) 100%);
}
.sun-disc { position: absolute; right: 8%; bottom: -120px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, #F7C98B 0%, rgba(247,201,139,.35) 45%, transparent 70%); pointer-events: none; }
.today-pill { display: inline-flex; align-items: center; gap: 10px; margin-top: 26px; padding: 10px 18px; border-radius: 999px; background: rgba(255,255,255,.7); border: 1px solid var(--line); font-size: 14.5px; color: var(--ink-2); }
.today-pill svg { width: 18px; height: 18px; color: var(--orange); }
.daily-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(36px, 5vw, 72px); align-items: start; }
.daily-aside { position: sticky; top: calc(var(--nav-h) + 24px); display: grid; gap: 22px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.panel .panel-title { font-family: var(--sans); font-size: 11.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.panel p { margin: 0; font-size: 14.5px; color: var(--ink-2); line-height: 1.6; }
.daily-filter { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 18px; border-radius: 14px; background: var(--accent-soft); color: var(--ink); font-size: 15px; }

/* Thẻ bài trong danh sách — bấm để mở toàn bài */
.day-feed { display: grid; gap: 18px; }
.day-card {
  display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 24px; align-items: start;
  padding: 24px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  scroll-margin-top: calc(var(--nav-h) + 24px); cursor: pointer;
  transition: border-color .25s, box-shadow .3s, transform .3s var(--ease);
}
.day-card.has-img { grid-template-columns: 92px minmax(0, 1fr) 168px; }
.day-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); transform: translateY(-3px); }
.day-date { display: block; text-align: center; padding: 12px 6px; border-radius: 14px; background: var(--paper); border: 1px solid var(--line); }
.day-date .dd { display: block; font-family: var(--serif); font-size: 40px; font-weight: 600; line-height: 1; color: var(--accent); }
.day-date .mm { display: block; margin-top: 6px; font-size: 12.5px; color: var(--ink-2); line-height: 1.35; }
.day-date .wd { display: block; margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line-strong); font-size: 12px; font-weight: 600; color: var(--gold-ink); }
.day-body { display: flex; flex-direction: column; min-width: 0; }
.day-hello { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--orange); }
.day-hello svg { width: 16px; height: 16px; }
.day-hello .chip { letter-spacing: .02em; text-transform: none; }
.day-title { display: block; margin-top: 10px; font-family: var(--serif); font-size: clamp(22px, 2.2vw, 27px); font-weight: 600; line-height: 1.3; color: var(--ink); transition: color .2s; }
.day-card:hover .day-title { color: var(--accent); }
.day-excerpt { display: block; margin-top: 10px; color: var(--ink-2); font-size: 16px; line-height: 1.65; }
.day-more { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; font-size: 14.5px; font-weight: 600; color: var(--accent); }
.day-more svg { width: 16px; height: 16px; transition: transform .25s var(--ease); }
.day-card:hover .day-more svg { transform: translateX(4px); }
.day-thumb { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 4/3; background: var(--paper-3); }
.day-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; }
.day-card.big .day-title { font-size: clamp(26px, 2.8vw, 34px); }
.day-card.big .day-excerpt { font-size: 17px; }

/* Cửa sổ đọc toàn bài */
.day-modal { position: fixed; inset: 0; z-index: 100; display: none; align-items: flex-start; justify-content: center; padding: 48px 20px; background: rgba(20, 24, 32, .55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); overflow-y: auto; }
.day-modal.open { display: flex; animation: fadeIn .25s; }
.dm-panel { position: relative; width: min(760px, 100%); background: var(--paper); border-radius: 22px; box-shadow: var(--shadow-lg); padding: clamp(28px, 5vw, 56px); outline: none; animation: dmUp .35s var(--ease); }
@keyframes dmUp { from { transform: translateY(24px); opacity: 0; } }
.dm-close { position: absolute; top: 16px; right: 16px; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--card); display: grid; place-items: center; }
.dm-close:hover { border-color: var(--ink); }
.dm-close svg { width: 20px; height: 20px; }
.dm-date { margin: 12px 0 0; font-size: 14.5px; color: var(--muted); }
.dm-head h2 { margin-top: 10px; font-size: clamp(30px, 4vw, 44px); line-height: 1.2; }
.dm-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.dm-img { margin: 28px 0 0; }
.dm-img img { width: 100%; border-radius: 14px; max-height: 440px; object-fit: cover; object-position: 50% 25%; }
.dm-img figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); }
.dm-content { margin-top: 28px; }
.dm-content p { margin: 0 0 1.1em; font-family: var(--serif); font-size: clamp(19px, 2vw, 22px); line-height: 1.7; color: var(--ink); }
.dm-source { margin: 8px 0 0; font-size: 13.5px; color: var(--muted); font-style: italic; }
.dm-sign { margin: 24px 0 0; text-align: right; font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--ink-2); }
.dm-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--line); }
.dm-nav .btn:disabled { opacity: .35; pointer-events: none; }

/* Lịch */
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal-head strong { font-family: var(--serif); font-size: 18px; }
.cal-nav { width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); background: transparent; display: grid; place-items: center; }
.cal-nav:hover { border-color: var(--ink); }
.cal-nav:disabled { opacity: .3; pointer-events: none; }
.cal-nav svg { width: 16px; height: 16px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.cal-wd { font-size: 11px; font-weight: 600; color: var(--muted); padding: 4px 0; }
.cal-day { position: relative; display: grid; place-items: center; aspect-ratio: 1; border-radius: 50%; border: 0; background: none; padding: 0; font-size: 13.5px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.cal-day.before { color: var(--line-strong); }
.cal-day.has { background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.cal-day.has:hover, .cal-day.sel { background: var(--accent); color: #fff; }
.cal-day i { position: absolute; top: -2px; right: -2px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 99px; background: var(--ink); color: #fff; font-size: 10px; font-style: normal; line-height: 16px; }
.cal-day.today { box-shadow: inset 0 0 0 1.5px var(--ink); }
.cal-note { display: flex; align-items: center; gap: 8px; margin: 14px 0 0 !important; font-size: 13px !important; color: var(--muted) !important; }
.cal-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent-soft); box-shadow: inset 0 0 0 1.5px var(--accent); }
.cal-meta { margin-top: 14px !important; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13.5px !important; }

/* Trang chủ */
.day-mini-list { display: grid; gap: 12px; }
.day-mini { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 16px; align-items: center; padding: 16px 18px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); transition: border-color .2s, transform .25s var(--ease); }
.day-mini:hover { border-color: var(--line-strong); transform: translateX(4px); }
.dm-date { font-family: var(--serif); font-size: 22px; font-weight: 600; color: var(--accent); text-align: center; }
.day-mini .dm-date svg { width: 26px; height: 26px; color: var(--orange); }
.day-mini strong { display: block; font-family: var(--serif); font-size: 17px; font-weight: 600; }
.day-mini em { display: block; font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-style: normal; }
.day-mini-all { background: transparent; border-style: dashed; }
.home-daily { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
@media (max-width: 960px) {
  .daily-layout, .home-daily { grid-template-columns: minmax(0, 1fr); }
  .daily-aside { position: static; order: -1; }
}
@media (max-width: 640px) {
  .day-card, .day-card.has-img { grid-template-columns: minmax(0, 1fr); gap: 14px; padding: 20px; }
  .day-thumb { order: -1; aspect-ratio: 16/9; }
  .day-date { display: flex; align-items: baseline; gap: 10px; text-align: left; padding: 8px 14px; width: max-content; }
  .day-date .dd { font-size: 26px; }
  .day-date .mm br { display: none; }
  .day-date .mm, .day-date .wd { margin: 0; padding: 0; border: 0; }
  .day-modal { padding: 0; }
  .dm-panel { border-radius: 0; min-height: 100%; padding: 64px 22px 32px; }
}

/* ---------- Các bài báo: tabs, view toggle, year list ---------- */
.list-toolbar { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; align-items: center; margin-bottom: 26px; }
.list-toolbar .tabs { margin-bottom: 0; }
.tab .n { margin-left: 6px; font-size: 12px; opacity: .6; }
.view-toggle { display: inline-flex; padding: 4px; border-radius: 999px; border: 1px solid var(--line-strong); }
.view-btn { border: 0; background: transparent; padding: 8px 14px; border-radius: 999px; display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--muted); }
.view-btn svg { width: 16px; height: 16px; }
.view-btn.active { background: var(--ink); color: #fff; }
.year-jump { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 40px; }
.year-jump a { display: inline-flex; gap: 8px; align-items: center; padding: 8px 14px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-family: var(--serif); font-weight: 600; font-size: 17px; }
.year-jump a span { font-family: var(--sans); font-size: 11.5px; color: var(--muted); }
.year-jump a:hover { border-color: var(--ink); }
#press-all { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-strong); }

/* ---------- Thư viện ảnh ---------- */
.gallery figure .g-year { position: absolute; top: 12px; left: 12px; padding: 3px 10px; border-radius: 999px; background: rgba(255,255,255,.9); font-size: 12px; font-weight: 600; color: var(--ink); }
.lb-count { position: absolute; top: 30px; left: 50%; transform: translateX(-50%); color: #C9C2B5; font-size: 13px; letter-spacing: .1em; }
.gal-hero-strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-top: 44px; }
.gal-hero-strip img { width: 100%; aspect-ratio: 3/4; object-fit: cover; object-position: 50% 25%; border-radius: 12px; box-shadow: var(--shadow); }
.gal-hero-strip img:nth-child(even) { transform: translateY(18px); }
@media (max-width: 700px) { .gal-hero-strip { grid-template-columns: repeat(3, 1fr); } .gal-hero-strip img:nth-child(n+4) { display: none; } }

/* ---------- Video ---------- */
.player { position: relative; aspect-ratio: 16/9; background: #0F141D; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-lg); }
.player iframe, .player video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player video { background: #000; }
.player-cover { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; background: none; }
.player-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease), filter .3s; }
.player-cover:hover img { transform: scale(1.03); filter: brightness(.92); }
.v-play { position: absolute; left: 50%; top: 50%; width: 54px; height: 54px; margin: -27px 0 0 -27px; border-radius: 50%; background: rgba(255,255,255,.92); color: var(--accent); display: grid; place-items: center; box-shadow: 0 8px 24px rgba(0,0,0,.25); transition: transform .25s var(--ease), background .2s, color .2s; }
.v-play svg { width: 22px; height: 22px; margin-left: 3px; fill: currentColor; }
.v-play.big { width: 84px; height: 84px; margin: -42px 0 0 -42px; }
.v-play.big svg { width: 32px; height: 32px; }
.player-cover:hover .v-play, .v-card:hover .v-play { transform: scale(1.08); background: var(--accent); color: #fff; }
.player-info { margin-top: 22px; }
.player-info h2 { margin-top: 12px; font-size: clamp(24px, 2.6vw, 32px); }
.player-info p { margin: 10px 0 0; color: var(--muted); font-size: 15px; }
.player-info a { color: var(--accent); font-weight: 600; }
.video-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px 24px; }
.v-card { display: flex; flex-direction: column; gap: 12px; padding: 0; border: 0; background: none; text-align: left; }
.v-thumb { position: relative; display: block; aspect-ratio: 16/9; border-radius: 14px; overflow: hidden; background: var(--paper-3); }
.v-thumb img, .v-thumb video { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); pointer-events: none; }
.v-card:hover .v-thumb img { transform: scale(1.05); }
.v-len { position: absolute; right: 8px; bottom: 8px; padding: 2px 8px; border-radius: 6px; background: rgba(15,20,29,.85); color: #fff; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.v-meta { display: block; }
.v-ch { display: block; font-size: 12.5px; color: var(--muted); font-weight: 500; }
.v-title { display: block; margin-top: 6px; font-family: var(--serif); font-size: 18px; line-height: 1.35; font-weight: 600; color: var(--ink); transition: color .2s; }
.v-card:hover .v-title { color: var(--accent); }
.more-wrap { text-align: center; margin-top: 44px; }
.home-video { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.v-side { display: grid; gap: 18px; }
.v-side .v-card { flex-direction: row; gap: 14px; align-items: flex-start; }
.v-side .v-thumb { flex: 0 0 150px; border-radius: 10px; }
.v-side .v-play { width: 34px; height: 34px; margin: -17px 0 0 -17px; }
.v-side .v-play svg { width: 14px; height: 14px; }
.v-side .v-title { font-size: 15.5px; margin-top: 4px; }
@media (max-width: 1000px) { .video-grid { grid-template-columns: 1fr 1fr; } .home-video { grid-template-columns: 1fr; } }
@media (max-width: 600px) { .video-grid { grid-template-columns: 1fr; } .v-side .v-thumb { flex-basis: 128px; } }

/* ---------- Tác phẩm ---------- */
.work-sec { scroll-margin-top: calc(var(--nav-h) + 24px); }
.work-sec + .work-sec { margin-top: 72px; }
.work-sec-head { display: flex; align-items: center; gap: 16px; padding-bottom: 18px; margin-bottom: 26px; border-bottom: 1px solid var(--line-strong); }
.work-sec-head .ico { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); flex: none; }
.work-sec-head .ico svg { width: 24px; height: 24px; }
.work-sec-head h2 { font-size: clamp(26px, 3vw, 36px); }
.work-sec-head .n { margin-left: auto; font-family: var(--serif); font-size: 26px; color: var(--line-strong); font-weight: 700; }
.work-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.work { display: flex; gap: 24px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; transition: border-color .3s, box-shadow .3s, transform .35s var(--ease); }
.work:hover { border-color: var(--line-strong); box-shadow: var(--shadow); transform: translateY(-4px); }
.work.has-cover { grid-column: 1 / -1; }
.work-cover { width: 150px; flex: none; align-self: flex-start; border-radius: 4px 8px 8px 4px; box-shadow: -6px 10px 24px -8px rgba(23,32,46,.4); }
.work-main { min-width: 0; display: flex; flex-direction: column; flex: 1; }
.work-top { display: flex; align-items: center; gap: 12px; }
.work-year { font-family: var(--serif); font-size: 26px; font-weight: 600; color: var(--accent); line-height: 1; }
.work h3 { margin-top: 14px; font-size: 21px; line-height: 1.35; }
.work .work-vi { margin: 6px 0 0; font-family: var(--serif); font-style: italic; color: var(--ink-2); font-size: 16px; }
.work p { margin: 12px 0 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.65; }
.work-meta { margin: 16px 0 0; display: grid; gap: 6px; font-size: 14px; }
.work-meta div { display: grid; grid-template-columns: 82px 1fr; gap: 10px; }
.work-meta dt { color: var(--muted); font-weight: 600; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; padding-top: 2px; }
.work-meta dd { margin: 0; color: var(--ink); }
.work-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; padding-top: 20px; }
.work.pending { background: transparent; border-style: dashed; }
.work.pending:hover { transform: none; box-shadow: none; }
.works-intro { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); }
.w-mini { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 28px 26px 30px; border-left: 1px solid var(--line); transition: background .25s; }
.w-mini:first-child { border-left: 0; }
.w-mini:hover { background: rgba(255,255,255,.6); }
.w-mini .chip { align-self: flex-start; }
.w-mini .w-year { font-family: var(--serif); font-size: 34px; font-weight: 600; color: var(--accent); line-height: 1; }
.w-mini h3 { font-size: 18.5px; line-height: 1.35; }
.w-mini p { margin: 0; font-size: 13.5px; color: var(--muted); }
.w-mini > svg { width: 18px; height: 18px; color: var(--accent); margin-top: auto; transition: transform .25s var(--ease); }
.w-mini:hover > svg { transform: translateX(4px); }
@media (max-width: 1000px) { .works-intro { grid-template-columns: 1fr 1fr; } .w-mini:nth-child(3) { border-left: 0; } .w-mini:nth-child(n+3) { border-top: 1px solid var(--line); } }
@media (max-width: 800px) { .work-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .works-intro { grid-template-columns: 1fr; } .w-mini { border-left: 0; border-top: 1px solid var(--line); } .w-mini:first-child { border-top: 0; } .work { flex-direction: column; padding: 24px; } .work-cover { width: 120px; } }

/* ---------- Các bài báo: bộ lọc nhiều nguồn ---------- */
.art-stats { margin-top: 44px; }
.art-stats .stat b { font-weight: 600; color: var(--ink-2); }
.art-filters { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.art-filters .search { flex: none; }
.select { position: relative; display: block; }
.select select {
  width: 100%; appearance: none; -webkit-appearance: none; padding: 12px 40px 12px 18px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: var(--card); font: inherit; font-size: 14.5px; color: var(--ink); cursor: pointer;
  text-overflow: ellipsis; white-space: nowrap; overflow: hidden;
}
.select::after { content: ""; position: absolute; right: 18px; top: 50%; width: 8px; height: 8px; margin-top: -6px; border-right: 1.6px solid var(--muted); border-bottom: 1.6px solid var(--muted); transform: rotate(45deg); pointer-events: none; }
.select select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.art-info { margin: 0 0 22px; font-size: 14.5px; color: var(--muted); }
.art-info strong { color: var(--ink); }
.link-reset { margin-left: 10px; border: 0; background: none; padding: 0; color: var(--accent); font-weight: 600; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; }
.a-card.art { min-height: 0; padding: 26px; }
.a-card.art h3 { font-size: 20px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.a-card.art p { font-size: 15px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.a-card.art.own { border-color: var(--gold-soft); background: linear-gradient(180deg, #FFFDF9, var(--card)); }
.a-card.art .foot { font-weight: 600; }
.a-card.art .src-name em { font-style: normal; font-weight: 500; color: var(--muted); }
@media (max-width: 900px) { .art-filters { grid-template-columns: 1fr 1fr; } .art-filters .search { grid-column: 1 / -1; } }
@media (max-width: 520px) { .art-filters { grid-template-columns: 1fr 1fr; } .art-filters .select:nth-child(2) { grid-column: 1 / -1; } }
