/**
 * BMT Update Log Stylesheet
 * BestMoneyTip — Content Update Log Page
 * Scoped to .bmt-update-log
 * Version: 1.0
 *
 * Design tokens: mirrors modern-home.css variables exactly
 */

/* ============================================================
   CSS Variables (modern-home.css 와 동일한 토큰)
   ============================================================ */
.bmt-update-log {
    --bg-primary:    hsl(40, 20%, 96%);
    --fg-primary:    hsl(30, 10%, 12%);
    --bg-card:       hsl(40, 25%, 98%);
    --bg-secondary:  hsl(40, 15%, 92%);
    --fg-muted:      hsl(30, 8%, 45%);
    --border-color:  hsl(40, 15%, 88%);
    --brand:         hsl(243, 75%, 59%);
    --brand-light:   hsl(243, 82%, 70%);
    --radius:        0.625rem;
    --radius-lg:     1rem;
    --shadow-sm:     0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md:     0 4px 16px rgba(0, 0, 0, 0.08);
    --font-serif:    'Noto Serif KR', Georgia, serif;
    --font-sans:     'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --transition:    all 0.3s cubic-bezier(0.25, 1, 0.5, 1);

    /* Update type colours */
    --c-threshold:   hsl(24, 77%, 40%);
    --c-threshold-bg:hsl(24, 77%, 40%, 0.07);
    --c-rate:        hsl(210, 51%, 36%);
    --c-rate-bg:     hsl(210, 51%, 36%, 0.07);
    --c-law:         hsl(270, 33%, 42%);
    --c-law-bg:      hsl(270, 33%, 42%, 0.07);
    --c-data:        hsl(153, 60%, 26%);
    --c-data-bg:     hsl(153, 60%, 26%, 0.07);
}

/* ============================================================
   Base
   ============================================================ */
.bmt-update-log,
.bmt-update-log * {
    box-sizing: border-box;
}

.bmt-update-log {
    background-color: var(--bg-primary);
    font-family: var(--font-sans);
    color: var(--fg-primary);
    min-height: 60vh;
    padding-bottom: 5rem;
}

.bmt-ul-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

@media (min-width: 640px) {
    .bmt-ul-wrap { padding: 0 2rem; }
}

/* ============================================================
   Hero
   ============================================================ */
.bul-hero {
    padding: 3rem 0 2rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 2rem;
}

.bul-hero-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

.bul-eyebrow {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--fg-muted);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.bul-eyebrow::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 2px;
    background: var(--brand);
}

.bul-title {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 3vw, 2.4rem);
    font-weight: 400;
    color: var(--fg-primary);
    line-height: 1.25;
    margin: 0 0 0.75rem;
}

.bul-desc {
    font-size: 0.9375rem;
    color: var(--fg-muted);
    max-width: 520px;
    line-height: 1.7;
    margin: 0;
}

.bul-hero-stats {
    display: flex;
    gap: 2rem;
    flex-shrink: 0;
}

.bul-stat {
    text-align: right;
}

.bul-stat-num {
    font-family: var(--font-serif);
    font-size: 1.8rem;
    color: var(--fg-primary);
    line-height: 1;
    margin-bottom: 3px;
}

.bul-stat-label {
    font-size: 0.72rem;
    color: var(--fg-muted);
    font-weight: 500;
    letter-spacing: 0.04em;
}

/* ============================================================
   Editorial Standards Block
   ============================================================ */
.bul-standards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.75rem 2rem;
    margin-bottom: 2rem;
}

.bul-std-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--fg-muted);
    margin-bottom: 0.4rem;
}

.bul-std-value {
    font-family: var(--font-serif);
    font-size: 0.95rem;
    color: var(--fg-primary);
    line-height: 1.55;
}

/* ============================================================
   Filter Row  (category-pill 은 modern-home.css 그대로 재사용)
   ============================================================ */
.bul-filter-row {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    flex-wrap: wrap;
    margin-bottom: 1.75rem;
}

/* category-pill styles already in modern-home.css — scoped below for standalone use */
.bmt-update-log .category-pill {
    padding: 0.5rem 1.1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 9999px;
    background-color: var(--bg-secondary);
    color: var(--fg-muted);
    transition: var(--transition);
    border: 1px solid transparent;
    cursor: pointer;
    font-family: var(--font-sans);
}

.bmt-update-log .category-pill:hover {
    background-color: hsl(40, 15%, 88%);
    color: var(--fg-primary);
    border-color: var(--border-color);
}

.bmt-update-log .category-pill.active {
    background-color: var(--fg-primary);
    color: var(--bg-primary);
    font-weight: 600;
    border-color: var(--fg-primary);
}

/* ============================================================
   Update Entry
   ============================================================ */
.bul-entry {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem 1.75rem;
    margin-bottom: 0.875rem;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 1.25rem;
    align-items: start;
    transition: var(--transition);
}

.bul-entry:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
    border-color: var(--brand-light);
}

.bul-entry.bul-hidden {
    display: none;
}

/* Entry meta row */
.bul-entry-meta {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.bul-entry-date {
    font-size: 0.8rem;
    color: var(--fg-muted);
    font-weight: 500;
}

.bul-meta-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--fg-muted);
    opacity: 0.4;
    display: inline-block;
    flex-shrink: 0;
}

.bul-entry-cat {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--fg-muted);
}

.bul-type-badge {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 2px 7px;
    border-radius: 4px;
    background: var(--bg-secondary);
    color: var(--fg-muted);
    border: 1px solid var(--border-color);
}

/* Entry title */
.bul-entry-title {
    display: block;
    font-family: var(--font-serif);
    font-size: 1.1rem;
    color: var(--fg-primary);
    line-height: 1.35;
    text-decoration: none;
    margin-bottom: 0.6rem;
    transition: var(--transition);
}

.bul-entry-title:hover {
    color: var(--brand);
}

/* Entry change summary */
.bul-entry-change {
    font-size: 0.85rem;
    color: var(--fg-muted);
    line-height: 1.65;
    margin-bottom: 0.75rem;
}

.bul-entry-change strong {
    color: var(--fg-primary);
    font-weight: 600;
}

/* Sources row */
.bul-entry-sources {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.bul-source-label {
    font-size: 0.72rem;
    color: var(--fg-muted);
}

.bul-source-chip {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 4px;
    background: hsla(243, 75%, 59%, 0.07);
    color: var(--brand);
    border: 1px solid hsla(243, 75%, 59%, 0.18);
    letter-spacing: 0.04em;
}

/* Right column pill */
.bul-entry-right {
    text-align: right;
    flex-shrink: 0;
    padding-top: 2px;
}

.bul-pill {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 9999px;
}

.pill-threshold { background: var(--c-threshold-bg); color: var(--c-threshold); }
.pill-rate      { background: var(--c-rate-bg);      color: var(--c-rate); }
.pill-law       { background: var(--c-law-bg);       color: var(--c-law); }
.pill-data      { background: var(--c-data-bg);      color: var(--c-data); }
.pill-initial   { background: var(--bg-secondary);   color: var(--fg-muted); border: 1px solid var(--border-color); }

/* ============================================================
   Component Reference Section
   ============================================================ */
.bul-reference {
    margin-top: 3rem;
    padding-top: 2.5rem;
    border-top: 1px solid var(--border-color);
}

.bul-ref-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.bul-ref-badge {
    padding: 0.25rem 0.75rem;
    background-color: var(--fg-primary);
    color: var(--bg-primary);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-family: var(--font-sans);
}

.bul-ref-title {
    font-family: var(--font-serif);
    font-size: 1.375rem;
    font-weight: 400;
    margin: 0;
}

.bul-ref-desc {
    font-size: 0.875rem;
    color: var(--fg-muted);
    margin: 0.5rem 0 1.5rem;
}

.bul-ref-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.bul-ref-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.bul-ref-tag {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 0.5rem 1.25rem;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--fg-muted);
    font-family: var(--font-sans);
}

.bul-ref-body {
    padding: 1.5rem;
}

.bul-ref-cat {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--fg-muted);
    margin-bottom: 0.4rem;
}

.bul-ref-article-title {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    color: var(--fg-primary);
    line-height: 1.3;
    margin-bottom: 0.875rem;
}

/* A형 component */
.bul-comp-a {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding: 0.75rem 0 1rem;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.bul-comp-key {
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--fg-muted);
    margin-bottom: 2px;
}

.bul-comp-val {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--fg-primary);
}

/* B형 component */
.bul-comp-b {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--fg-muted);
    margin-bottom: 1rem;
    padding-bottom: 0.875rem;
    border-bottom: 1px solid var(--border-color);
}

.bul-ref-excerpt {
    font-size: 0.84rem;
    color: var(--fg-muted);
    line-height: 1.7;
}

/* ============================================================
   Footer Note
   ============================================================ */
.bul-footer-note {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-top: 2.5rem;
    padding: 1.5rem 2rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.bul-fn-icon {
    width: 32px;
    height: 32px;
    background: var(--bg-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.bul-fn-text {
    font-size: 0.85rem;
    color: var(--fg-muted);
    line-height: 1.7;
}

.bul-fn-text strong {
    color: var(--fg-primary);
    font-weight: 600;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 768px) {
    .bul-hero-inner    { flex-direction: column; align-items: flex-start; }
    .bul-hero-stats    { gap: 1.25rem; }
    .bul-stat          { text-align: left; }
    .bul-standards     { grid-template-columns: 1fr; gap: 1rem; }
    .bul-entry         { grid-template-columns: 1fr; }
    .bul-entry-right   { text-align: left; }
    .bul-ref-grid      { grid-template-columns: 1fr; }
    .bul-footer-note   { flex-direction: column; }
}

@media (max-width: 480px) {
    .bul-hero          { padding: 2rem 0 1.5rem; }
    .bul-standards     { padding: 1.25rem; }
    .bul-entry         { padding: 1.25rem; }
    .bul-ref-body      { padding: 1.25rem; }
    .bul-footer-note   { padding: 1.25rem; }
}

/* ============================================================
   Hide Kadence leftovers (skip link, nav, extra footer)
   ============================================================ */
.skip-link,
.site-header,
.site-header-wrap,
.kadence-header,
#masthead,
.site-footer,
.kadence-footer,
#colophon,
.footer-wrap,
.bmt-log-page .wp-site-blocks > header,
.bmt-log-page .wp-site-blocks > footer {
    display: none !important;
}

/* ============================================================
   Custom Site Header
   ============================================================ */
.bul-site-header {
    background: hsl(40, 20%, 96%);
    border-bottom: 1px solid hsl(40, 15%, 88%);
    padding: 0.875rem 0;
}
.bul-site-header-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}
.bul-site-logo {
    font-family: 'Noto Serif KR', Georgia, serif;
    font-size: 1.25rem;
    color: hsl(30, 10%, 12%);
    text-decoration: none;
    font-weight: 400;
}
.bul-site-logo:hover { color: hsl(243, 75%, 59%); }

/* ============================================================
   Custom Site Footer
   ============================================================ */
.bul-site-footer {
    border-top: 1px solid hsl(40, 15%, 88%);
    padding: 2rem 0;
    background: hsl(40, 20%, 96%);
}
.bul-site-footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
    text-align: center;
}
.bul-footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 12px;
}
.bul-footer-links a {
    color: hsl(30, 10%, 12%);
    font-size: 0.92rem;
    text-decoration: none;
    margin: 0 8px;
    font-family: 'Pretendard', sans-serif;
    font-weight: 500;
}
.bul-footer-links a:hover { color: #2563eb; }
.bul-footer-dot { color: #ccc; font-size: 0.8rem; }
.bul-footer-copy { font-size: 0.85rem; color: hsl(30, 8%, 45%); margin: 0; }

/* Header layout with Home nav */
.bul-site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.bul-nav-home {
    font-family: 'Pretendard', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    color: hsl(30, 10%, 12%);
    text-decoration: none;
    padding: 0.35rem 0.875rem;
    border: 1px solid hsl(40, 15%, 88%);
    border-radius: 9999px;
    transition: all 0.2s;
}
.bul-nav-home:hover {
    background: hsl(243, 75%, 59%);
    color: #fff;
    border-color: hsl(243, 75%, 59%);
}