/* ExactDr M5.1 UI refinement. Requires user-installed code/fonts/; no font files bundled.
 * Load AFTER app.css to preserve existing discovery/advisor interactions. */
@font-face {
  font-family: "ExactDr Inter";
  src: url("/fonts/inter/Inter-VariableFont_opsz,wght.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "ExactDr Inter";
  src: url("/fonts/inter/Inter-Italic-VariableFont_opsz,wght.ttf") format("truetype");
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "ExactDr Material Symbols";
  src: url("/fonts/MaterialSymbolsOutlined.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 700;
  font-display: block;
}
:root { --ink:#143341; --teal:#087e84; --muted:#5a7380; --border:#dbe7e8; }
html { scroll-padding-top: 14px; }
body { font-family:"ExactDr Inter",Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; font-optical-sizing:auto; }
button,input,select,textarea { font-family:inherit; }
.ms {
  font-family:"ExactDr Material Symbols";
  font-style:normal; font-weight:400; font-size:19px; line-height:1;
  display:inline-block; letter-spacing:normal; text-transform:none;
  white-space:nowrap; word-wrap:normal; direction:ltr;
  -webkit-font-feature-settings:'liga'; font-feature-settings:'liga';
  -webkit-font-smoothing:antialiased; user-select:none; overflow:hidden; max-width:1.2em;
}
/* Make the global header feel like a product navigation, not a second hero. */
.site-header {background:#fff; border-bottom:1px solid #e5ecee;}
.nav-wrap { min-height:60px; gap:18px; }
.brand {font-size:23px; letter-spacing:-1.05px; font-weight:800;}
.brand-mark {width:31px;height:31px; border-radius:9px; font-size:17px; margin-right:5px;}
.site-header nav {gap:22px; font-size:12.5px; font-weight:650;}
.site-header nav .nav-link {color:#536c78;}
.site-header nav .nav-link:hover {color:#087e84;}
.site-header nav .nav-cta {
  display:inline-flex;align-items:center;justify-content:center;gap:7px;
  min-height:34px; border-radius:9px; padding:7px 12px;
  background:#e8f5f4;color:#046c75;white-space:nowrap;
  border:1px solid #c5e5e4; font-weight:750;
}
.site-header nav .nav-cta:hover {background:#d4eeeb;color:#07575f;}
.site-header nav .nav-cta .ms {font-size:17px;}
.site-header nav .nav-cta .nav-arrow {font-size:15px;}
/* Compact, content-first intro band: no giant hero card or wasted first screen. */
.hero {padding:29px 0 31px; overflow:visible;
  background:linear-gradient(110deg,#112d3a 0%,#164855 80%,#195960 100%);}
.compact-hero {display:grid;grid-template-columns:minmax(0,1fr) 236px;align-items:center;gap:36px;}
.hero-copy {min-width:0;}
.hero .eyebrow {font-size:10px;letter-spacing:1.5px;font-weight:800;gap:8px;}
.hero .pulse {width:7px;height:7px;}
.hero h1 {font-size:clamp(30px,3.2vw,43px);line-height:1.11;letter-spacing:-.036em;font-weight:770;margin:9px 0 10px;}
.hero h1 em {color:#a9ece1;}
.hero-sub {font-size:13.5px;line-height:1.65;max-width:780px;color:#d4e4e8;}
.hero-actions {display:flex;flex-direction:column;align-items:stretch;gap:10px;}
.hero-cta {display:inline-flex;align-items:center;justify-content:center;gap:10px;
  min-height:42px;padding:10px 14px;border-radius:9px;background:#adede2;color:#0e414a;
  text-decoration:none;font-size:13px;font-weight:800;white-space:nowrap;}
.hero-cta:hover {background:#c8f7ee;}
.hero-cta .ms {font-size:19px;}
.hero-text-link {display:inline-flex;align-items:center;justify-content:center;gap:5px;
  color:#e8f4f5;font-size:11.5px;font-weight:650;text-decoration:underline;text-underline-offset:3px;}
.hero-text-link .ms {font-size:15px;}
.hero-disclaimer {display:flex;align-items:center;justify-content:center;gap:5px;color:#b9d2d7;font-size:10.5px;}
.hero-disclaimer .ms {font-size:15px;}
/* Bring the actual product above the fold, with calmer hierarchy and legible controls. */
.advisor-section {padding:31px 0 26px;}
.section-heading h2,.info-section h2,.sources-section h2 {font-size:clamp(24px,2.3vw,29px);letter-spacing:-.035em;margin:6px 0 6px;}
.section-heading p,.results-header p {font-size:13px;line-height:1.55;}
.kicker {font-size:10px;letter-spacing:1.45px;}
.scope-pill {font-size:10.5px;padding:6px 10px;white-space:nowrap;}
.advisor-grid {margin-top:16px;gap:16px;grid-template-columns:minmax(0,1.27fr) minmax(290px,.83fr);}
.advisor-panel,.advisor-evidence {border-radius:13px;box-shadow:0 3px 18px rgba(15,45,60,.035);}
.advisor-privacy {padding:11px 17px;font-size:11.5px;line-height:1.55;}
.advisor-messages {min-height:144px;max-height:360px;padding:16px;gap:10px;}
.advisor-welcome {font-size:13.5px;line-height:1.55;}
.advisor-bubble {font-size:13.5px;line-height:1.6;}
.advisor-form {padding:14px 17px;gap:7px;}
.advisor-form label {font-size:12px;}
.advisor-form input,.advisor-form textarea {font-size:13.5px;padding:9px 12px;}
.advisor-form textarea {min-height:70px;}
.advisor-actions {margin-top:3px;}
.advisor-status {margin:0 17px 12px;}
.advisor-evidence {padding:18px;gap:11px;}
.advisor-evidence h3 {font-size:18px;}
.advisor-evidence>p {line-height:1.6;}
.discovery-section {padding:34px 0 55px;}
.search-panel {margin-top:17px;padding:19px;gap:13px;box-shadow:0 4px 22px rgba(15,45,60,.045);}
.results-header {margin-top:31px;}
.info-section {padding:47px 0 51px;}
.sources-section {padding:47px 0 54px;}
.button {border-radius:8px;}
.button:focus-visible,a:focus-visible,summary:focus-visible {outline:3px solid #49beb5;outline-offset:3px;}
/* Responsive: keep a visible way to start a search at all widths. */
@media (max-width:960px) {
  .compact-hero {grid-template-columns:minmax(0,1fr) 205px;gap:22px;}
  .site-header nav {gap:14px;}
  .site-header nav .nav-sources {display:none;}
  .advisor-grid {grid-template-columns:1fr;}
}
@media (max-width:700px) {
  .nav-wrap {min-height:56px;}
  .site-header nav .nav-secondary,.site-header nav .nav-sources {display:none;}
  .site-header nav .nav-cta {min-height:33px;}
  .hero {padding:24px 0 25px;}
  .compact-hero {grid-template-columns:1fr;gap:18px;}
  .hero h1 {font-size:clamp(29px,7.3vw,37px);margin:8px 0;}
  .hero-sub {font-size:13px;}
  .hero-actions {flex-direction:row;align-items:center;flex-wrap:wrap;gap:9px 14px;}
  .hero-cta {min-height:39px;}
  .hero-disclaimer {width:100%;justify-content:flex-start;}
  .advisor-section {padding-top:28px;}
  .advisor-grid {margin-top:14px;}
  .section-heading {gap:10px;}
  .advisor-messages {min-height:130px;}
}
@media (max-width:390px) {
  .brand {font-size:21px;}
  .site-header nav .nav-cta {font-size:11px;padding:7px 9px;}
  .site-header nav .nav-cta .nav-arrow,
  .site-header nav .nav-cta .ms:first-child {display:none;}
  .hero-text-link {font-size:11px;}
}
@media (prefers-reduced-motion:reduce) {
  html {scroll-behavior:auto;}
  .button {transition:none;}
}

/* Keep the ZIP label and its optional/required hint on one aligned line. */
.zip-label-text{display:inline;white-space:nowrap;}

/* M5.3: compact empty conversation; in-thread activity; readable sanitized Markdown. */
.advisor-messages:empty {display:none}
.advisor-bubble.assistant {white-space:normal;line-height:1.65;min-width:0}
.advisor-bubble.assistant :is(p,ul,ol,blockquote,pre,table) {margin:0 0 .8em}
.advisor-bubble.assistant > :last-child {margin-bottom:0}
.advisor-bubble.assistant :is(ul,ol) {padding-left:1.45em}
.advisor-bubble.assistant li {padding-left:.1em;margin:.22em 0}
.advisor-bubble.assistant li > p {margin-bottom:.25em}
.advisor-bubble.assistant :is(h1,h2,h3,h4,h5,h6) {font-size:1.04em;line-height:1.4;letter-spacing:0;margin:1em 0 .35em;font-weight:750}
.advisor-bubble.assistant :first-child {margin-top:0}
.advisor-bubble.assistant strong {font-weight:750;color:#173d4b}
.advisor-bubble.assistant a {color:#087e84;text-decoration:underline;text-underline-offset:2px;overflow-wrap:anywhere}
.advisor-bubble.assistant blockquote {border-left:3px solid #7acbc6;padding:.3em .85em;background:#f5fafb;color:#456773}
.advisor-bubble.assistant :not(pre)>code {font-size:.91em;padding:2px 4px;border-radius:4px;background:#eaf4f4}
.advisor-bubble.assistant pre {overflow-x:auto;max-width:100%;padding:11px;background:#102f3a;color:#e5f5f3;border-radius:8px;white-space:pre;font-size:12px;line-height:1.5}
.advisor-bubble.assistant pre code {font:inherit}
.advisor-bubble.assistant table {display:block;overflow-x:auto;max-width:100%;border-collapse:collapse;font-size:.92em}
.advisor-bubble.assistant :is(th,td) {padding:6px 9px;border:1px solid #d6e5e7;text-align:left}
.advisor-bubble.assistant th {background:#eff7f7}
.advisor-bubble.assistant hr {border:0;border-top:1px solid #d9e8e9;margin:1em 0}
.advisor-activity {display:flex;align-items:flex-start;gap:11px;align-self:flex-start;max-width:93%;padding:11px 14px;background:#edf8f7;border:1px solid #c6e8e5;border-radius:12px;color:#235765}
.advisor-activity-spinner {width:17px;height:17px;margin-top:3px;flex-shrink:0;border:2px solid #b4d9d6;border-top-color:#08838a;border-radius:50%;animation:advisor-spin .85s linear infinite}
.advisor-activity-copy {display:flex;flex-direction:column;gap:2px;font-size:12px;line-height:1.5}
.advisor-activity-copy strong {font-size:12.5px;color:#14656c}
@keyframes advisor-spin {to {transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce) {.advisor-activity-spinner {animation:none;border-top-color:#08838a}}
