/* ===========================================================
   한국요식업지원센터 블로그 - 개별 글(article) 전용 스타일
   blog.css 이후에 로드
   =========================================================== */

/* ── 본문 레이아웃 ── */
.article-hero {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e3a8a 100%);
    color: #fff;
    padding: 52px 20px 44px;
    text-align: center;
}
.article-hero__eyebrow {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    background: rgba(255,255,255,.15);
    border-radius: 999px;
    padding: 4px 14px;
    margin-bottom: 14px;
}
.article-hero__title {
    font-size: clamp(22px, 5vw, 36px);
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1.3;
    margin: 0 0 14px;
}
.article-hero__meta {
    font-size: 14px;
    opacity: .8;
    margin: 0;
}

/* ── 본문 래퍼 ── */
.article-wrap {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    max-width: 860px;
    margin: 48px auto;
    padding: 0 16px;
}

@media (min-width: 900px) {
    .article-wrap {
        grid-template-columns: 200px 1fr;
        gap: 40px;
        padding: 0 24px;
    }
}

/* ── 목차 사이드바 ── */
.article-toc {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px 18px;
    font-size: 13.5px;
    line-height: 1.7;
    height: fit-content;
    position: sticky;
    top: 76px;
}
.article-toc__title {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #6b7280;
    margin-bottom: 10px;
}
.article-toc ol {
    padding-left: 16px;
}
.article-toc li + li {
    margin-top: 4px;
}
.article-toc a {
    color: #374151;
    text-decoration: none;
    transition: color .15s;
}
.article-toc a:hover {
    color: #1d4ed8;
}

@media (max-width: 899px) {
    .article-toc {
        position: static;
        order: -1;           /* 모바일에서 본문 위 */
        border-left: 4px solid #1d4ed8;
        border-radius: 0 10px 10px 0;
    }
}

/* ── 본문 prose ── */
.prose {
    min-width: 0;
    color: #111827;
    font-size: 16px;
    line-height: 1.8;
}

.prose h1 {
    font-size: clamp(20px, 4vw, 28px);
    font-weight: 800;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 10px;
    margin: 48px 0 18px;
    color: #111827;
}
.prose h1:first-child { margin-top: 0; }

.prose h2 {
    font-size: clamp(17px, 3vw, 21px);
    font-weight: 700;
    margin: 36px 0 12px;
    color: #1e3a8a;
    border-left: 4px solid #1d4ed8;
    padding-left: 12px;
    line-height: 1.4;
}

.prose h3 {
    font-size: clamp(15px, 2.5vw, 17px);
    font-weight: 700;
    margin: 28px 0 10px;
    color: #1d4ed8;
}

.prose h4 {
    font-size: 15px;
    font-weight: 600;
    margin: 20px 0 8px;
    color: #374151;
}

.prose p {
    margin: 0 0 14px;
}

.prose strong {
    color: #1e3a8a;
}

.prose ul,
.prose ol {
    padding-left: 22px;
    margin: 0 0 16px;
}
.prose li {
    margin-bottom: 6px;
}

/* 인용문 */
.prose blockquote {
    background: #f0f4ff;
    border-left: 4px solid #1d4ed8;
    border-radius: 0 8px 8px 0;
    padding: 14px 18px;
    margin: 16px 0;
    color: #374151;
    font-size: 15px;
}
.prose blockquote em {
    font-style: normal;
    color: #4b5563;
}

/* 이미지 */
.prose img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
    margin: 16px auto;
    border: 1px solid #e5e7eb;
    background: #f8fafc;
}

/* 이미지 캡션 (figure 사용 권장) */
.prose figcaption {
    text-align: center;
    font-size: 13px;
    color: #6b7280;
    margin-top: 6px;
}

/* ── Q&A 섹션 ── */
.prose .qna-section {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px 22px;
    margin: 20px 0;
}
.prose .qna-section h3 {
    margin-top: 0;
    color: #1e3a8a;
    display: flex;
    gap: 8px;
    align-items: flex-start;
}
.prose .qna-section h3::before {
    content: "Q";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    background: #1d4ed8;
    color: #fff;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 800;
    flex-shrink: 0;
    margin-top: 1px;
}
.prose .qna-section p {
    margin: 8px 0 0;
    color: #374151;
}

/* ── 특성 테이블 ── */
.prose table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14.5px;
    margin: 16px 0 28px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
}
.prose table thead th,
.prose table tr.tr_th th {
    background: #1d4ed8;
    color: #fff;
    padding: 12px 14px;
    text-align: left;
    font-weight: 700;
}
.prose table tr.tr_white th,
.prose table tr.tr_white td {
    background: #fff;
    padding: 10px 14px;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: top;
}
.prose table tr.tr_green th,
.prose table tr.tr_green td {
    background: #f0fdf4;
    padding: 10px 14px;
    border-bottom: 1px solid #dcfce7;
    vertical-align: top;
}
.prose table tr.tr_white th,
.prose table tr.tr_green th {
    font-weight: 600;
    color: #1e3a8a;
    min-width: 100px;
}
.prose table td p,
.prose table th p {
    margin: 0 0 4px;
}

/* 모바일 테이블 스크롤 */
.table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 10px;
    margin: 16px 0 28px;
}
.table-scroll table {
    margin: 0;
    min-width: 560px;
}

/* ── 본문 내 섹션 카드 ── */
.prose .info-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 22px 24px;
    margin: 24px 0;
}

/* ── breadcrumb ── */
.breadcrumb {
    font-size: 13px;
    color: #6b7280;
    padding: 14px 0 0;
    max-width: 860px;
    margin: 0 auto;
    padding: 14px 16px 0;
}
.breadcrumb a { color: #1d4ed8; }
.breadcrumb a:hover { text-decoration: underline; }

/* ── 개정 현황 칩 ── */
.amendment-tag {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    background: #dbeafe;
    color: #1d4ed8;
    border-radius: 6px;
    padding: 3px 9px;
    margin-left: 6px;
    vertical-align: middle;
}

/* ── 이동 버튼 ── */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #1d4ed8;
    margin-bottom: 24px;
    text-decoration: none;
}
.back-link:hover { text-decoration: underline; }

/* ── responsive 글자크기 조정 ── */
@media (max-width: 480px) {
    .prose { font-size: 15px; }
    .prose h2 { font-size: 17px; }
    .prose h4 { font-size: 14px; }
    .article-toc { font-size: 13px; }
}