.saha-local {
    --sg-accent: #15569a;
    --sg-ink: #1e3041;
    --sg-muted: #475a6d;
    --sg-line: #d5dfe8;
    container: local-guide / inline-size;
    min-width: 0;
    overflow-wrap: anywhere;
    color: var(--sg-ink);
}
.saha-local :where(h1, h2, h3) { line-height: 1.3; margin: 0 0 .6rem; }
.saha-local h1 { font-size: clamp(1.65rem, 4vw, 2.5rem); letter-spacing: normal; }
.saha-local h2 { font-size: clamp(1.2rem, 2vw, 1.55rem); }
.saha-local h3 { font-size: 1.05rem; }
.saha-local :where(p, ul, ol, dl) { margin: 0 0 .85rem; }
.saha-local :where(p, ul, ol, dl):last-child { margin-bottom: 0; }
.saha-local a { color: var(--sg-accent); text-underline-offset: .18em; }
.saha-local :where(a, button, summary, input, select):focus-visible { outline: 3px solid #1b72b0; outline-offset: 3px; }
.saha-local :is(.field-guide, .sg-help, .sg-profile, .sg-intro, .sg-filters, .sg-answer, .sg-search, .field-guide + nav) {
    margin: 0 0 1rem;
    border: 1px solid var(--sg-line);
    border-radius: 14px;
    background: white;
    padding: clamp(1rem, 3vw, 1.6rem);
}
.saha-local .field-list, .sg-search ul { padding: 0; list-style: none; }
.saha-local .field-list li + li, .sg-search li + li { border-top: 1px solid var(--sg-line); }
.saha-local .field-list a, .sg-search li a { display: block; padding: .65rem 0; }
.saha-local .field-guide details { margin-top: 1.2rem; }
.saha-local .field-guide .button, .saha-local button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border: 1px solid var(--sg-accent);
    border-radius: .55rem;
    padding: .45rem .85rem;
    color: white;
    background: var(--sg-accent);
    font: inherit;
    font-weight: 650;
    cursor: pointer;
}
.saha-local .sg-profile { padding: 0; overflow: hidden; }
.sg-profile section { padding: 1.15rem clamp(1rem, 3vw, 1.6rem); }
.sg-profile section + section { border-top: 1px solid var(--sg-line); }
.sg-identity { display: flex; align-items: center; gap: 1rem; padding: 1.4rem; background: #203e53; color: white; }
.sg-identity h1, .sg-identity p { color: white; margin: 0; }
.sg-identity img { width: clamp(65px, 20%, 110px); height: auto; aspect-ratio: 1; object-fit: cover; border-radius: .75rem; }
.sg-skills { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,13rem),1fr)); gap: 1rem; }
.sg-skills div { border-top: 1px solid var(--sg-line); padding-top: .75rem; }
.sg-skills h3 { margin-bottom: .25rem; }
.sg-contacts { display: grid; grid-template-columns: auto 1fr; gap: .35rem 1rem; }
.sg-contacts dd { margin: 0; font: 600 1rem/1.65 system-ui,sans-serif; }
.saha-local details > summary { cursor: pointer; }
.sg-help details { border-top: 1px solid var(--sg-line); padding-block: .7rem; }
.sg-help details summary { font-weight: 650; }
.sg-help details p { padding-top: .45rem; }
.sg-filters { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,15rem),1fr)); gap: .9rem; align-items: end; }
.sg-filters label { min-width: 0; font-weight: 650; }
.sg-filters select, .sg-search input, .sg-actions input { width: 100%; min-height: 44px; font: inherit; padding: .45rem; border: 1px solid #96aabc; border-radius: .45rem; color: var(--sg-ink); background: white; }
.sg-filters select { display: block; margin-top: .3rem; }
.sg-filters button { justify-self: start; }
.sg-tags, .sg-actions, .sg-search form { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.sg-tags span, .sg-hashtag { color: #245781; }
.sg-tags span { background: #eef4fb; border-radius: 1rem; font-size: .875rem; padding: .15rem .65rem; }
.sg-answer ol { padding-inline-start: 1.6rem; }
.sg-answer li + li { margin-top: .4rem; }
.sg-actions a { padding: .5rem .1rem; }
.sg-search label { flex: 1 1 11rem; }
.sg-search small { display: block; color: var(--sg-muted); }
.sg-search p[role=status] { margin-top: .75rem; }
.saha-local [hidden] { display: none !important; }
@container local-guide (max-width: 740px) {
    .saha-local .nb-cards { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .saha-local .nb-detail-hero, .saha-local .nb-article-grid { grid-template-columns: 1fr; }
    .saha-local .nb-detail-hero img { height: clamp(140px,33cqi,255px); min-height: 0; }
}
@container local-guide (max-width: 410px) {
    .saha-local .nb-cards { grid-template-columns: 1fr; }
    .sg-contacts { grid-template-columns: 1fr; }
}
