/* 공지사항 목록 · 상세. column.css 뒤에 건다. 경계는 767 · 768 · 1068 · 1069 */

/* 머리의 검색창 — 칼럼 · 준비 중 마크업을 바꾸지 않고 격자로 오른쪽에 둔다 */
.cm-hero:has(.notice-search) .cm-inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 380px); column-gap: 24px; }
.cm-hero:has(.notice-search) .cm-eyebrow, .cm-hero:has(.notice-search) .cm-hero-title, .cm-hero:has(.notice-search) .cm-hero-sub { grid-column: 1; }
.cm-hero:has(.notice-search) .cm-tabs { grid-column: 1 / -1; }
.notice-search { grid-column: 2; grid-row: 1 / span 3; align-self: end; display: flex; align-items: center; gap: 6px; min-width: 0; height: 52px; box-sizing: border-box; padding: 4px 4px 4px 18px; border-radius: 999px; background: #fff; box-shadow: 0 0 0 1px #ebe6f1, 0 14px 30px -22px rgba(60, 40, 110, .4); }
.notice-search:focus-within { box-shadow: 0 0 0 2px #8c79b3, 0 14px 30px -22px rgba(60, 40, 110, .4); }
.notice-search input { flex: 1; min-width: 0; height: 44px; padding: 0; border: 0; outline: 0; background: transparent; font-size: 15px; color: #16181d; }
.notice-search input::placeholder { color: #5d6069; }
.notice-search button { flex: none; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: #4d3f72; color: #fff; cursor: pointer; }
.notice-search button svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.notice-search button:focus-visible { outline: 2px solid #8c79b3; outline-offset: 2px; }

/* 표 — reset.css 가 전역 fixed 라 auto 를 직접 준다 */
.notice-table { table-layout: auto; width: 100%; border-collapse: collapse; border-top: 2px solid #16181d; }
.notice-table th { padding: 14px 20px; font-size: 13px; font-weight: 700; color: #5d6069; text-align: start; border-bottom: 1px solid #ebe6f1; white-space: nowrap; }
.notice-table td { padding: 0 20px; height: 68px; border-bottom: 1px solid #ebe6f1; font-size: 14px; color: #5d6069; }
.notice-row.is-pinned td { background: #f7f4f9; }
.notice-row:hover td { background: #f3effa; }
.notice-row:hover .column-link, .notice-row:focus-within .column-link { color: #4d3f72; }
.notice-c-no { width: 110px; }
.notice-c-date { width: 140px; white-space: nowrap; }
.notice-table .notice-c-views { width: 90px; text-align: end; white-space: nowrap; }
.notice-main { position: relative; }   /* 제목 링크의 ::after 가 제목칸을 덮는다. tr 기준은 브라우저마다 달라 쓰지 않는다 */
.notice-main-in { display: flex; align-items: center; gap: 10px; }
.notice-title { margin: 0; min-width: 0; font-size: 16px; font-weight: 500; line-height: 1.5; color: #16181d; overflow-wrap: anywhere; }
.notice-title:lang(ko) { word-break: keep-all; }
.is-pinned .notice-title { font-weight: 800; }
.notice-pin { display: inline-flex; align-items: center; gap: 4px; height: 26px; padding: 0 10px; border-radius: 999px; background: #4d3f72; color: #fff; font-size: 12px; font-weight: 800; white-space: nowrap; }
.notice-pin svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.notice-new { flex: none; display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; background: #eaa6c8; color: #16181d; font-size: 12px; font-weight: 800; }
.notice-attach { flex: none; display: inline-flex; align-items: center; gap: 4px; color: #4d3f72; }
.notice-attach svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.notice-attach-text, .notice-views-label, .notice-no-label { display: none; }
.notice-pages { margin-top: 40px; }

/* 탭으로 넘어왔을 때 행이 차례로 떠오른다 — 쪽 크기가 10 이다 */
.cm-rise .notice-row { animation: cmRise .5s cubic-bezier(.2, .8, .2, 1) backwards; animation-delay: calc(var(--i, 0) * 45ms); }
.notice-row:nth-child(2) { --i: 1; }
.notice-row:nth-child(3) { --i: 2; }
.notice-row:nth-child(4) { --i: 3; }
.notice-row:nth-child(5) { --i: 4; }
.notice-row:nth-child(6) { --i: 5; }
.notice-row:nth-child(7) { --i: 6; }
.notice-row:nth-child(8) { --i: 7; }
.notice-row:nth-child(9) { --i: 8; }
.notice-row:nth-child(10) { --i: 9; }
@media (prefers-reduced-motion: reduce) {
  .cm-rise .notice-row { animation: none; }
}

/* 검색 0건의 고정 공지 바로가기 */
.column-empty .notice-pins-title { margin-top: 28px; font-size: 14px; font-weight: 700; color: #16181d; }
.notice-pins { display: grid; gap: 6px; margin: 10px auto 0; padding: 0; max-width: 560px; list-style: none; }
.notice-pins a { color: #4d3f72; font-size: 15px; text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }

/* 상세 */
.column-detail.medical-item-detail > .notice-package { margin-top: 32px; }
.column-detail.medical-item-detail > .notice-files { margin-top: 32px; }
.notice-files-box { padding: 18px 20px; border-radius: 14px; background: #f7f4f9; box-shadow: 0 0 0 1px #ebe6f1; }
.notice-files h2 { margin: 0 0 10px; font-size: 15px; font-weight: 800; color: #16181d; }
.notice-files ul { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.notice-file { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 6px 10px; border-radius: 10px; color: #4d3f72; text-decoration: none; }
.notice-file:hover { background: #f3effa; }
.notice-file:focus-visible { outline: 2px solid #8c79b3; outline-offset: 2px; }
.notice-file .material-symbols-outlined { flex: none; font-size: 20px; }
.notice-file-name { flex: 1 1 auto; min-width: 0; font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }
.notice-file-size { flex: none; font-size: 13px; color: #5d6069; }
.column-pager.is-single { grid-template-columns: minmax(0, 1fr); }
.column-pager small { color: #5d6069; }
.column-detail.medical-item-detail > .notice-back { margin-top: 24px; margin-bottom: 40px; text-align: center; }
.notice-back a { display: inline-flex; align-items: center; min-height: 48px; padding: 0 28px; border-radius: 999px; background: #4d3f72; color: #fff; font-size: 15px; font-weight: 700; text-decoration: none; }
.notice-back a:focus-visible { outline: 2px solid #8c79b3; outline-offset: 2px; }

/* 오른쪽 퀵메뉴에 글이 가리지 않게 칼럼 목록과 같은 폭을 비운다 */
@media (min-width: 768px) and (max-width: 1439px) {
  .column-detail.medical-item-detail > *:not(.dblocks):not(.full-bleed) { padding-right: clamp(40px, calc(120px - (100vw - 1280px) / 2), 120px); }
}

@media (min-width: 768px) and (max-width: 1068px) {
  .notice-table th, .notice-table td { padding-inline: 12px; }
  .notice-c-no { width: 84px; }
  .notice-c-date { width: 100px; }
  .notice-table .notice-c-views { width: 64px; }
}

@media (max-width: 767px) {
  .cm-hero:has(.notice-search) .cm-inner { display: block; }
  .notice-search { height: 48px; margin: 14px 16px 0; padding: 2px 2px 2px 14px; }
  .notice-total-pin { display: none; }
  .notice-table, .notice-table tbody { display: block; border-top: 0; }
  .notice-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
  .notice-row { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-bottom: 10px; padding: 16px 18px; border-radius: 20px; box-shadow: 0 0 0 1px #ebe6f1; background: #fff; }
  .notice-row.is-pinned { background: #f7f4f9; }
  .notice-row:hover { background: #f3effa; }
  .notice-table td, .notice-row.is-pinned td, .notice-row:hover td { display: block; height: auto; padding: 0; border: 0; background: none; font-size: 13px; }
  .notice-table td.notice-main, .notice-main-in { display: contents; }
  .notice-main { position: static; }
  .notice-table .notice-c-no { order: 1; width: auto; font-size: 12.5px; }
  .notice-new { order: 2; }
  .notice-title { order: 3; flex: 0 0 100%; font-weight: 600; }
  .notice-c-date { order: 4; width: auto; }
  .notice-table .notice-c-views { order: 5; width: auto; text-align: start; }
  .notice-attach { order: 6; font-size: 13px; }
  .notice-attach svg { width: 14px; height: 14px; }
  .notice-attach-text, .notice-views-label, .notice-no-label { display: inline; }
  .notice-attach .blind { display: none; }
  .column-section .notice-pages .pagination-controls { gap: 2px; }
  .notice-pages .is-edge { display: none; }
}
