.app-shell { min-height: 100vh; display: grid; grid-template-columns: 280px minmax(0, 1fr); }
.ad-rail { display: none; }
@media (min-width: 1440px) {
  .app-shell { grid-template-columns: 280px minmax(0, 1fr) 300px; }
  .ad-rail { display: block; padding: 24px 24px 24px 0; }
  .ad-rail .ad-slot { position: sticky; top: 24px; }
}
.sidebar { background: var(--brand); color: white; padding: 24px 18px; position: sticky; top: 0; height: 100vh; overflow: auto; }
.brand { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-bottom: 16px; }
.brand-logo-link { display: inline-block; line-height: 0; }
.brand-logo-link:hover { opacity: .85; }
.brand-logo { width: 150px; height: auto; filter: brightness(0) invert(1); }
.brand p { margin: 0; font-size: 12px; opacity: .7; }
.sidebar-search { position: relative; margin-bottom: 18px; }
.sidebar-search-field { display: flex; align-items: center; gap: 7px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); border-radius: 8px; padding: 0 10px; }
.sidebar-search-field:focus-within { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.32); }
.sidebar-search-field svg { flex: 0 0 auto; color: rgba(255,255,255,.55); }
.sidebar-search-input { all: unset; flex: 1 1 auto; color: #fff; font-size: 12.5px; padding: 8px 0; }
.sidebar-search-input::placeholder { color: rgba(255,255,255,.5); }
.sidebar-search-results { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 20; margin: 0; padding: 6px; list-style: none; background: #fff; border-radius: 10px; box-shadow: 0 10px 28px rgba(0,0,0,.35); max-height: 60vh; overflow-y: auto; }
.sidebar-search-results[hidden] { display: none; }
.sidebar-search-results .no-hit { padding: 12px 10px; font-size: 12.5px; color: #8991a3; text-align: center; }
.sidebar-search-result { display: flex; align-items: center; gap: 8px; padding: 8px 9px; border-radius: 7px; text-decoration: none; font-size: 13px; color: #1b2030; }
.sidebar-search-result:hover { background: #eceef3; }
.sidebar-search-result .result-tag { flex: 0 0 auto; font-size: 10px; font-weight: 700; letter-spacing: .04em; padding: 2px 6px; border-radius: 5px; background: #eceef3; color: #5b6172; }
.sidebar-search-result .result-title { flex: 1 1 auto; }
.nav-group { margin-top: 12px; }
.nav-group-title { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; opacity: .55; margin: 0 10px 5px; }
.nav-button { display: block; width: 100%; border: 0; background: transparent; color: rgba(255,255,255,.78); text-align: left; text-decoration: none; padding: 7px 12px; border-radius: 8px; margin: 1px 0; line-height: 1.35; }
.nav-button:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-button.active { background: #fff; color: var(--brand); font-weight: 700; }
.sidebar-guide { margin-top: 24px; padding: 14px; border: 1px solid rgba(255,255,255,.15); border-radius: 10px; font-size: 11px; line-height: 1.6; color: rgba(255,255,255,.72); }
.sidebar-guide strong { color: #fff; }
.suite-directory { max-width: 1120px; margin: 28px auto 48px; padding: 28px 32px; background: var(--panel, #fff); border: 1px solid var(--line, #dce1e7); border-radius: 14px; color: var(--ink, #17202a); box-shadow: var(--shadow, 0 10px 30px rgba(18,38,63,.08)); }
.app-static-fallback { max-width: 1120px; margin: 28px auto; padding: 28px 32px; background: var(--panel, #fff); border: 1px solid var(--line, #dce1e7); border-radius: 14px; color: var(--ink, #17202a); box-shadow: var(--shadow, 0 10px 30px rgba(18,38,63,.08)); }
.app-static-fallback h1,
.suite-directory h1 { margin: 8px 0 12px; font-size: clamp(24px, 3vw, 34px); letter-spacing: -.03em; }
.app-static-fallback > p { color: var(--muted, #66717f); line-height: 1.75; }
.app-static-fallback .app-loading-note { margin-bottom: 0; font-size: 12px; }
.calculator-context { margin-top: 22px; color: var(--ink, #17202a); }
.seo-details { overflow: hidden; background: var(--panel, #fff); border: 1px solid var(--line, #dce1e7); border-radius: 12px; box-shadow: var(--shadow, 0 10px 30px rgba(18,38,63,.08)); }
.seo-details > summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; cursor: pointer; color: var(--ink, #17202a); font-weight: 800; list-style: none; }
.seo-details > summary::-webkit-details-marker { display: none; }
.seo-details > summary::after { content: "+"; flex: 0 0 auto; color: var(--accent, #2877c7); font-size: 22px; line-height: 1; }
.seo-details[open] > summary { border-bottom: 1px solid var(--line, #dce1e7); }
.seo-details[open] > summary::after { content: "−"; }
.seo-details > summary small { margin-left: auto; color: var(--muted, #66717f); font-size: 11px; font-weight: 500; }
.seo-details-body { padding: 2px 22px 22px; }
.calculator-context h2,
.suite-directory h2 { margin: 28px 0 10px; font-size: 19px; }
.calculator-context h3 { margin: 18px 0 6px; font-size: 15px; }
.calculator-context p,
.calculator-context li,
.suite-directory p,
.suite-directory li { color: var(--muted, #66717f); line-height: 1.75; }
.calculator-context a,
.suite-directory a { color: var(--accent, #2877c7); }
.seo-breadcrumb { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; font-size: 12px; color: var(--muted, #66717f); }
.seo-breadcrumb a { text-decoration: none; }
.related-calculators,
.suite-directory-list { display: flex; flex-wrap: wrap; gap: 8px 18px; padding-left: 20px; }
.calculator-related { margin-top: 12px; padding: 16px 20px; border: 1px solid var(--line, #dce1e7); border-radius: 12px; background: var(--panel, #fff); }
.calculator-related h2 { margin: 0 0 10px; font-size: 15px; }
.calculator-related .related-calculators { margin: 0; }
.calculator-authority { margin: 0; padding: 0; }
.calculator-authority h2 { margin-top: 0; }
.authority-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 20px; }
.authority-heading > p { margin: 0; font-size: 12px; }
.authority-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 28px; }
.authority-example { padding: 14px 16px; border-radius: 10px; background: var(--panel, #fff); }
.authority-example dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; margin: 12px 0; }
.authority-example dl > div { display: grid; grid-template-columns: minmax(90px, .8fr) minmax(0, 1.2fr); gap: 8px; }
.authority-example dt,
.authority-example dd { margin: 0; overflow-wrap: anywhere; }
.authority-example code { font-size: 11px; }
.authority-sources { display: grid; gap: 8px; padding-left: 20px; }
.authority-sources li span { display: block; font-size: 11px; }
.site-footer { border-top: 1px solid var(--line, #dce1e7); background: var(--panel, #fff); color: var(--muted, #66717f); }
.site-footer-inner { max-width: 1120px; margin: 0 auto; padding: 22px 24px 28px; }
.site-footer p { margin: 0; font-size: 12px; line-height: 1.65; }
.site-footer-links { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 12px; font-size: 12px; }
.site-footer a { color: var(--accent, #2877c7); }
@media (max-width: 1050px) {
  .app-shell { grid-template-columns: 230px minmax(0,1fr); }
}
@media (max-width: 760px) {
  .app-shell { display: block; }
  .sidebar { position: static; height: auto; padding: 16px; }
  .nav-group { display: flex; gap: 5px; overflow-x: auto; margin-top: 10px; }
  .nav-group-title { display: none; }
  .nav-button { width: auto; min-width: max-content; }
  .sidebar-guide { display: none; }
  .suite-directory { margin: 18px 14px 36px; padding: 22px 18px; }
  .app-static-fallback { margin: 18px 14px; padding: 22px 18px; }
  .calculator-context { margin-top: 18px; }
  .seo-details > summary { align-items: flex-start; padding: 15px 16px; }
  .seo-details > summary small { display: none; }
  .seo-details-body { padding: 0 16px 18px; }
  .calculator-related { padding: 15px 16px; }
  .authority-grid,
  .authority-example dl { grid-template-columns: 1fr; }
  .site-footer-inner { padding: 18px 14px 24px; }
}
