/* FIX26.4 - Soft typography for Portal Dược
   Không phụ thuộc Google Fonts để hoạt động ổn định trên localhost/intranet. */
:root{
    --font-ui:"Aptos","Segoe UI Variable Text","Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
    --font-display:"Aptos Display","Segoe UI Variable Display","Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
}

html,body{
    font-family:var(--font-ui)!important;
    font-weight:400;
    line-height:1.65;
    letter-spacing:.002em;
    font-synthesis:none;
    text-rendering:optimizeLegibility;
    -webkit-font-smoothing:antialiased;
    -moz-osx-font-smoothing:grayscale;
}

button,input,select,textarea,optgroup,option{
    font:inherit;
    letter-spacing:inherit;
}

/* Tiêu đề: rõ nhưng không quá nặng */
h1,h2,h3,h4,h5,h6,
.brand-title,.site-brand__title,
.page-title,.section-title,
.card-title,.panel-title,
.nh-news-panel__head h2,
.nh-news-row__body h3,
.db-section-title,.db-side__head,
.news-side-card__head,
.v2-alert__title{
    font-family:var(--font-display)!important;
    font-weight:700!important;
    letter-spacing:-.012em!important;
}

h1{line-height:1.25}
h2{line-height:1.32}
h3,h4{line-height:1.4}

/* Các thành phần UI trước đây dùng 800/900 gây cảm giác thô */
.brand-subtitle,.site-brand__subtitle,
.main-nav a,.site-nav a,
button,.btn,.button,[class*="btn"],
th,label,summary,
.v2-theme-toggle,.v2-adr-quick,
.v2-stat__label,.v2-badge,
.icd-code-pill,.icd-page-link,
.nh-breaking__label,.nh-breaking>a,.nh-breaking time,
.nh-news-panel__head a,
.nh-news-row__body time,
.dropdown-quick-label,.dropdown-item-label,
.pharma-chat-foot a,
.db-badge,.db-btn,.db-info-box__label,
.pv-btn,.pv-meta__head{
    font-weight:600!important;
}

/* Số liệu và mã cần nhấn mạnh vẫn giữ nổi bật nhưng bớt nặng */
.v2-stat__value,.code,.icd-picker__code{
    font-family:var(--font-display)!important;
    font-weight:700!important;
}

p,li,td,.muted,.news-summary,.article-summary,
.bhyt-condition-text,.bhyt-sub,.bhyt-source,
.db-info-box__value,.db-related-item__title,
.related-item__title{
    line-height:1.7;
}

strong,b{
    font-weight:600;
}

/* Form và bảng dễ đọc hơn khi nhập dữ liệu dài */
input,select,textarea{
    font-weight:400;
    line-height:1.5;
}
textarea{line-height:1.65}

table{font-variant-numeric:tabular-nums}
th{letter-spacing:.002em}

/* Chatbot dùng cùng typography toàn portal */
.pharma-chat-widget,.pharma-chat-panel,.pharma-chat-message{
    font-family:var(--font-ui)!important;
}

/* Mobile: giữ chữ thoáng, không co quá nhỏ */
@media(max-width:768px){
    html,body{font-size:15.5px;line-height:1.62}
    h1{letter-spacing:-.01em!important}
}
