/* ===== 記事の検索 ===== */
.nsa-search { display: flex; align-items: stretch; width: 100%; box-sizing: border-box; border: 1px solid #CFCAC3; border-radius: 999px; background: #fff; overflow: hidden; }
.nsa-search:focus-within { border-color: #E8650C; box-shadow: 0 0 0 2px rgba(232, 101, 12, .2); }
.nsa-search input[type=search] { flex: 1 1 auto; min-width: 0; margin: 0; padding: 10px 4px 10px 16px; border: 0 !important; background: transparent; font: inherit; font-size: 14px; color: #1F1D1A; outline: none; box-shadow: none !important; }
.nsa-search button { flex: 0 0 auto; display: flex; align-items: center; justify-content: center; width: 44px; margin: 0; padding: 0; border: 0; background: #E8650C; color: #fff; cursor: pointer; border-radius: 0; }
.nsa-search button:hover { background: #B84E08; }
.nsa-sr { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }

/* ===== 広告スライド ===== */
.nsa-ads { position: relative; }
.nsa-track { display: grid; }
.nsa-slide { grid-area: 1 / 1; display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 12px; opacity: 0; visibility: hidden; transition: opacity .6s ease, visibility 0s linear .6s; }
.nsa-slide.is-active { opacity: 1; visibility: visible; transition: opacity .6s ease, visibility 0s; }
.nsa-link { position: relative; display: block; width: 100%; border-radius: 10px; overflow: hidden; line-height: 0; box-shadow: 0 2px 10px rgba(31, 29, 26, .12); }
.nsa-link:focus-visible { outline: 3px solid #E8650C; outline-offset: 2px; }
.nsa-img { display: block; width: 100% !important; height: auto !important; max-width: none !important; margin: 0 !important; }
.nsa-pr { position: absolute; top: 8px; right: 8px; padding: 2px 8px; border-radius: 4px; background: rgba(255, 255, 255, .92); color: #615D57; border: 1px solid #CFCAC3; font: 700 11px/1.5 sans-serif; letter-spacing: .05em; }
.nsa-dots { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px; margin-top: 10px; }
.nsa-dot { width: 24px; height: 24px; padding: 0; margin: 0; border: 0; background: transparent; cursor: pointer; position: relative; }
.nsa-dot::before { content: ""; position: absolute; inset: 0; margin: auto; width: 8px; height: 8px; border-radius: 50%; background: #D8D4CE; transition: background .2s, width .2s; }
.nsa-dot.is-active::before { width: 18px; border-radius: 999px; background: #E8650C; }
.nsa-dot:focus-visible { outline: 2px solid #E8650C; border-radius: 6px; }
.nsa-more { margin: 8px 0 0 !important; text-align: center; font-size: 13px; }
.nsa-more a { color: #B84E08; font-weight: 700; text-decoration: none; }
.nsa-more a:hover { text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  .nsa-slide, .nsa-slide.is-active { transition: none; }
}

/* スクロールに付いてくる（パソコン表示のみ。Astra のサイドバー） */
@media (min-width: 922px) {
  #secondary .sidebar-main:has(.nsa-sticky) { height: 100%; }
  #secondary .widget:has(.nsa-sticky) { position: sticky; top: calc(24px + var(--wp-admin--admin-bar--height, 0px)); z-index: 1; }
}
