/* =============================================================================
   AlphaWells help drawer ("How do I...?"), wwwroot/js/help/help-drawer.js.
   Everything is scoped under .awh-drawer / .awh so it never leaks into the host
   page. Colors come from the theme variables in custom.css with the Alpha
   navy/teal palette the valuation methodology drawer already uses.
   ============================================================================= */

.awh-drawer { width: 640px; max-width: 95vw; color: var(--text-color, #333); }
.awh-drawer .offcanvas-header { background: var(--secondary-color, #2c3e50); color: #fff; }
.awh-drawer .offcanvas-header .btn-close { filter: invert(1) grayscale(100%) brightness(200%); }
.awh-drawer .offcanvas-title { font-size: 15px; font-weight: 600; }
.awh-drawer .offcanvas-body { position: relative; padding: 18px 22px; font-size: 13px; line-height: 1.55; }

.awh-head { margin-bottom: 12px; }
.awh-eyebrow {
    display: inline-block; font-size: 10.5px; font-weight: 700; letter-spacing: .06em;
    text-transform: uppercase; background: #e6f5f6; color: #1e7a80;
    border: 1px solid rgba(56, 168, 157, .25); border-radius: 3px; padding: 2px 8px; margin-bottom: 6px;
}
.awh-title { font-size: 17px; font-weight: 700; color: var(--secondary-color, #2c3e50); line-height: 1.3; }
.awh-intro { font-size: 12.5px; color: #6b7a8c; margin-top: 4px; }

/* "You are here" banner */
.awh-here {
    border: 1px solid rgba(56, 168, 157, .35); border-left: 4px solid #38a89d; background: #f2fbfa;
    border-radius: 6px; padding: 10px 12px; margin-bottom: 12px;
}
.awh-here-eyebrow { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #1e7a80; }
.awh-here-t { font-weight: 700; color: var(--secondary-color, #2c3e50); margin-top: 2px; }
.awh-here-x { color: #445263; margin-top: 2px; }
.awh-here-jump { display: inline-block; margin-top: 6px; font-weight: 700; }

/* Tools row: search + expand/collapse */
.awh-tools { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.awh-search { flex: 1 1 200px; position: relative; }
.awh-search i { position: absolute; left: 9px; top: 50%; transform: translateY(-50%); color: #94a3b8; font-size: 11px; }
.awh-search-input {
    width: 100%; padding: 5px 10px 5px 26px; font-size: 12.5px; border: 1px solid #e2e8f0; border-radius: 5px;
    font-family: inherit;
}
.awh-search-input:focus { outline: none; border-color: #38a89d; box-shadow: 0 0 0 2px rgba(56, 168, 157, .18); }
.awh-tool {
    font-size: 11.5px; padding: 4px 9px; border-radius: 5px; border: 1px solid #e2e8f0; background: #fff;
    color: #6b7a8c; cursor: pointer; font-family: inherit; font-weight: 600;
}
.awh-tool:hover { border-color: #38a89d; color: #1e7a80; }

/* Table of contents */
.awh-toc { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px solid #e2e8f0; }
.awh-toc-item { font-size: 12px; color: #1e7a80; text-decoration: none; font-weight: 600; }
.awh-toc-item:hover { text-decoration: underline; }

/* Sections */
.awh-secs { margin: 0; padding: 0; }
.awh-sec { position: relative; padding: 0 0 14px 32px; border-left: 2px solid #e2e8f0; margin-left: 11px; }
.awh-sec:last-child { border-left-color: transparent; }
.awh-sec-head {
    display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: none; border: none;
    padding: 0 0 6px; cursor: pointer; font-family: inherit; color: var(--secondary-color, #2c3e50);
}
.awh-sec-n {
    position: absolute; left: -12px; top: 0; width: 22px; height: 22px; border-radius: 50%;
    background: #38a89d; color: #fff; font-size: 11px; font-weight: 700;
    display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 3px #fff;
}
.awh-sec-t { font-size: 13.5px; font-weight: 700; flex: 1; }
.awh-sec-chev { font-size: 10px; color: #94a3b8; transition: transform .15s ease; }
.awh-sec--collapsed .awh-sec-chev { transform: rotate(-90deg); }
.awh-sec-body { color: #445263; }
.awh-sec-body p { margin: 0 0 8px; }
.awh-sec--flash { animation: awh-flash 2.4s ease-out; border-radius: 6px; }
@keyframes awh-flash {
    0%   { background: rgba(244, 166, 59, .22); box-shadow: 0 0 0 2px rgba(244, 166, 59, .45); }
    60%  { background: rgba(244, 166, 59, .10); box-shadow: 0 0 0 2px rgba(244, 166, 59, .18); }
    100% { background: transparent; box-shadow: none; }
}

/* Labeled sub-list */
.awh-sub { border: 1px solid #e2e8f0; border-radius: 6px; padding: 9px 12px; margin: 0 0 8px; background: #fff; border-left: 3px solid #38a89d; }
.awh-sub-h { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #1e7a80; margin-bottom: 6px; }
.awh-list { margin: 0; padding-left: 18px; }
.awh-list li { margin-bottom: 5px; }
.awh-list li:last-child { margin-bottom: 0; }

/* Step cards */
.awh-steps { list-style: none; margin: 0 0 8px; padding: 0; counter-reset: awh-step; }
.awh-step { display: flex; gap: 10px; padding: 8px 10px; margin-bottom: 6px; border: 1px solid #e2e8f0; border-radius: 6px; background: #fff; }
.awh-step-n {
    flex: 0 0 22px; width: 22px; height: 22px; border-radius: 4px; background: var(--secondary-color, #2c3e50); color: #fff;
    font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.awh-step-body { flex: 1; min-width: 0; }
.awh-step-t { font-weight: 700; color: var(--secondary-color, #2c3e50); }
.awh-step-x { margin-top: 2px; }
.awh-step-tip { margin-top: 5px; font-size: 12px; color: #7a5a00; background: #fff8e6; border-radius: 4px; padding: 4px 8px; }

/* Tables */
.awh-table-wrap { overflow-x: auto; margin: 0 0 8px; }
.awh-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.awh-table th, .awh-table td { border: 1px solid #e2e8f0; padding: 5px 7px; vertical-align: top; text-align: left; }
.awh-table th { background: #f4f7fa; font-weight: 700; color: var(--secondary-color, #2c3e50); }
.awh-td-key { font-weight: 700; white-space: nowrap; color: var(--secondary-color, #2c3e50); }

/* Callouts */
.awh-callout { display: flex; gap: 9px; padding: 8px 11px; margin: 0 0 8px; border-radius: 6px; border: 1px solid; font-size: 12.5px; }
.awh-callout > i { margin-top: 2px; }
.awh-callout-t { font-weight: 700; }
.awh-callout--info { background: #eef6fc; border-color: rgba(52, 152, 219, .35); color: #1f4e79; }
.awh-callout--warn { background: #fff8e6; border-color: rgba(244, 166, 59, .45); color: #7a5a00; }
.awh-callout--ok { background: #eefaf1; border-color: rgba(39, 174, 96, .35); color: #1e6b3a; }
.awh-callout--stop { background: #fdeeec; border-color: rgba(231, 76, 60, .35); color: #922b21; }

/* If you see ... */
.awh-qa-item { margin-bottom: 8px; padding: 7px 10px; border-radius: 6px; background: #f8fafc; border: 1px solid #e2e8f0; }
.awh-qa-q { font-weight: 700; color: var(--secondary-color, #2c3e50); }
.awh-qa-a { margin-top: 2px; }

.awh-jump { color: #1e7a80; font-weight: 600; text-decoration: none; }
.awh-jump:hover { text-decoration: underline; }
.awh-nomatch { color: #6b7a8c; font-style: italic; padding: 8px 0; }

.awh-footer { margin-top: 6px; padding-top: 12px; border-top: 1px solid #e2e8f0; display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.awh-manual { font-size: 11px; color: #6b7a8c; }
.awh-version { font-size: 10.5px; color: #94a3b8; letter-spacing: .02em; }

/* Trigger button (host pages) */
.aw-help-trigger {
    font-size: 12px; padding: 5px 10px; border-radius: 5px; border: 1px solid #e2e8f0;
    background: #fff; color: #6b7a8c; cursor: pointer; font-family: inherit; font-weight: 600;
    display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; text-decoration: none;
}
.aw-help-trigger:hover { border-color: #38a89d; color: #1e7a80; }
.aw-help-trigger i { font-size: 11px; }
.aw-help-trigger--icon { padding: 2px 6px; border: none; background: transparent; color: #38a89d; font-size: 13px; }
.aw-help-trigger--icon:hover { color: #1e7a80; }
