/* BraunAI Short Sale Process Guide. Base styles match /realtor-message-templates/ and /realtor-listing-brief/. */
:root {
  --navy: #0b1f3a;
  --navy-2: #122a4a;
  --gold: #c9a227;
  --cream: #f7f3e8;
  --ink: #1b1b1b;
  --muted: #3d3d3d;
  --line: #c8c4b8;
  --warn-bg: #fff3cd;
  --ok-bg: #e8f2e8;
  --card: #ffffff;
  --focus: #0b1f3a;
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
body {
  margin: 0;
  font: 16px/1.5 var(--font);
  background: var(--cream);
  color: var(--ink);
}
.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--gold);
  color: var(--navy);
  padding: 0.65rem 1rem;
  z-index: 20;
  font-weight: 700;
  min-height: 44px;
}
.skip:focus { left: 1rem; top: 1rem; }
a { color: var(--navy); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: var(--navy-2); }
.sources a { display: inline-block; padding: 6px 0; min-height: 44px; line-height: 1.35; }
header {
  background: var(--navy);
  color: #fff;
  padding: 16px 20px;
}
header .brand { margin: 0; font-size: 1.05rem; }
header b { color: var(--gold); font-weight: 700; }
.badge {
  display: inline-block;
  margin-left: 0.4rem;
  padding: 0.1rem 0.45rem;
  border: 1px solid #c9a227;
  border-radius: 999px;
  color: #c9a227;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  vertical-align: middle;
}
main { max-width: 760px; margin: 0 auto; padding: 20px; }
h1 { font-size: 1.65rem; line-height: 1.25; margin: 0 0 0.75rem; color: var(--navy); }
h2 { font-size: 1.25rem; margin: 1.5rem 0 0.5rem; color: var(--navy); }
h3 { font-size: 1.05rem; margin: 1.15rem 0 0.4rem; color: var(--navy); }
.lead { margin: 0 0 0.75rem; }
.note { font-size: 0.95rem; color: var(--muted); }
.callout {
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: 6px;
  padding: 10px 12px;
  margin: 0 0 1rem;
}
fieldset {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
  margin: 0 0 1rem;
  padding: 12px 14px 16px;
}
legend { font-weight: 700; color: var(--navy); padding: 0 0.35rem; }
label, .field-label {
  display: block;
  font-weight: 600;
  margin-top: 12px;
  color: var(--ink);
}
.hint { display: block; font-weight: 400; color: var(--muted); font-size: 0.9rem; margin: 0.15rem 0 0.35rem; }
input, textarea, select, button, pre {
  font: inherit;
}
input, textarea, select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  min-height: 44px;
}
textarea { min-height: 88px; resize: vertical; }
select { min-height: 44px; }
input:focus, textarea:focus, select:focus, button:focus, a:focus, pre:focus, .skip:focus {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
header a:focus, header .skip:focus {
  outline-color: var(--gold);
}
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
button {
  margin: 0;
  background: var(--gold);
  color: var(--navy);
  border: 0;
  padding: 11px 18px;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
  min-height: 44px;
}
button.secondary {
  background: #fff;
  color: var(--navy);
  border: 2px solid var(--navy);
}
button:hover { filter: brightness(0.97); }
button:disabled { opacity: 0.6; cursor: not-allowed; }
#form-status, #copy-status, #check-status { margin: 0.6rem 0 0; }
#form-status[data-kind="warn"], #check-status[data-kind="warn"], .flag-box {
  background: var(--warn-bg);
  border-radius: 6px;
  padding: 8px 10px;
}
#form-status[data-kind="ok"] { background: var(--ok-bg); border-radius: 6px; padding: 8px 10px; }
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px;
  margin: 0.4rem 0 0.6rem;
  color: var(--ink);
  line-height: 1.55;
}
.flag {
  background: var(--warn-bg);
  padding: 0 4px;
  border-radius: 3px;
  font-weight: 600;
}
h3.with-badge {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}
.pending {
  display: inline-block;
  margin-left: 0;
  padding: 0.15rem 0.45rem;
  background: transparent;
  color: #0b1f3a;
  border: 1.5px solid #c9a227;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  vertical-align: middle;
}
.sources { margin: 0.6rem 0 0; padding-left: 1.2rem; }
.sources li { margin: 0.25rem 0; }
#checked-copy { margin-top: 0.75rem; }
footer {
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
  padding: 24px 20px 32px;
  max-width: 760px;
  margin: 0 auto;
}
@media (max-width: 400px) {
  main { padding: 16px; }
  header { padding: 14px 16px; }
  h1 { font-size: 1.4rem; }
  .actions { flex-direction: column; }
  .actions button { width: 100%; }
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 12px 0 1rem;
  padding: 8px 0;
  min-height: 44px;
}
.checkbox-row input[type="checkbox"] {
  width: 20px;
  height: 20px;
  min-width: 20px;
  min-height: 20px;
  margin: 2px 0 0;
  flex: 0 0 20px;
  accent-color: var(--navy);
}
.checkbox-row label {
  display: inline;
  font-weight: 600;
  margin-top: 0;
}
.fh-item {
  margin: 0.6rem 0;
  padding: 8px 10px;
  border-radius: 6px;
}
.fh-item p { margin: 0; }
.fh-item.tier-a {
  background: var(--warn-bg);
  border-left: 4px solid #8a6d12;
}
.fh-item.tier-b {
  background: #f3f0e6;
  border: 1px solid var(--line);
}
.fh-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #8a6d12;
  margin: 0 0 0.3rem;
}
.fh-item.tier-b .fh-label { color: var(--navy); }
.fh-summary { margin: 0.6rem 0 0.4rem; }
mark.flag-cliche {
  background: none;
  background-color: transparent;
  color: inherit;
  font-weight: 600;
  padding: 0;
  border-radius: 0;
  text-decoration: underline;
  text-decoration-style: solid;
  text-decoration-color: #c9a227;
  text-decoration-thickness: 2px;
  text-underline-offset: 2px;
}
.about-check {
  margin: 1rem 0 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--card);
  padding: 0 12px;
}
.about-check summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--navy);
  padding: 12px 0;
  min-height: 44px;
}
.about-check .callout { margin: 0 0 12px; border: 0; border-radius: 0; padding: 0; }
.fh-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.fh-actions button {
  min-height: 44px;
  padding: 8px 14px;
  font-weight: 600;
}
mark.flag-b {
  background: #e6e2d6;
  color: var(--ink);
  font-weight: 600;
  padding: 0 4px;
  border-radius: 3px;
}
.style-tip { margin-top: 0.6rem; }


/* Client Message Templates additions */
.tone-row { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 8px; }
.tone-row .radio {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin: 0;
  font-weight: 600;
}
.tone-row input[type="radio"] {
  width: 20px;
  height: 20px;
  min-width: 20px;
  min-height: 20px;
  margin: 0;
  accent-color: var(--navy);
}
.out-label { margin-top: 14px; }
textarea.msg { min-height: 140px; line-height: 1.55; }
textarea.msg-email { min-height: 260px; }
.counts { margin: 0.35rem 0 0; font-size: 0.9rem; color: var(--muted); }
.counts[data-kind="warn"] { color: #6b5410; font-weight: 600; }
.fh-where { margin: 0.25rem 0 0; font-size: 0.85rem; color: var(--muted); }
.sensitive-box {
  background: var(--warn-bg);
  border-left: 4px solid #8a6d12;
  border-radius: 6px;
  padding: 8px 10px;
  margin: 0.6rem 0;
}
.sensitive-box p { margin: 0; }
footer p { margin: 0.4rem 0; }

/* Short Sale Process Guide additions */
.disclaimer { font-size: 0.95rem; }
.disclaimer p { margin: 0 0 0.5rem; }
.disclaimer p:last-child { margin-bottom: 0; }
.toc { margin: 0 0 1rem; padding-left: 1.2rem; }
.toc a { display: inline-block; padding: 6px 0; min-height: 44px; line-height: 1.35; }
.progress-all { font-weight: 600; margin: 0.5rem 0 0; }
.stage {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  margin: 0 0 1rem;
  padding: 4px 14px 12px;
}
.stage h3 {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 0.75rem;
}
.stage-count { font-size: 0.85rem; font-weight: 600; color: var(--muted); }
.stage-count[data-done="true"] { color: #2c5e2c; }
ul.checks { list-style: none; margin: 0; padding: 0; }
ul.checks li { margin: 0; }
ul.checks .checkbox-row { margin: 4px 0; padding: 6px 0; }
ul.checks .checkbox-row label { font-weight: 400; }
ul.checks input:checked + label { color: var(--muted); }
.caution {
  background: var(--warn-bg);
  border-left: 4px solid #8a6d12;
  border-radius: 6px;
  padding: 8px 10px;
  margin: 0.6rem 0;
}
.caution p { margin: 0; }
.tip { margin: 0.6rem 0; }
.copy-block { min-height: 0; }
.copy-block:focus { outline: 3px solid var(--focus); outline-offset: 2px; }
.advisor-list { margin: 0.4rem 0 0; padding-left: 1.2rem; }
.advisor-list li { margin: 0.35rem 0; }
.js-only[hidden] { display: none !important; }
footer .disclaimer { text-align: left; }
.stage-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}
.stage-jump li { margin: 0; }
.stage-jump a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 8px 14px;
  border: 1.5px solid var(--navy);
  border-radius: 999px;
  background: #fff;
  color: var(--navy);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.2;
  white-space: nowrap;
}
.stage-jump a:hover { border-color: var(--gold); }
.stage-jump a:focus {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}
.print-brand { display: none; }
@media print {
  .skip, header, .actions, .toc, .stage-jump, #privacy-note, .js-only, button { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  main { max-width: none; padding: 0; }
  .stage, .callout, .caution, pre { break-inside: avoid; background: #fff; }
  .caution { border: 1px solid #000; border-left: 4px solid #000; }
  a { color: #000; text-decoration: none; }
  footer { text-align: left; padding: 12px 0 0; max-width: none; }
  footer .links { display: none; }
  .print-brand {
    display: block !important;
    margin: 0 0 12px;
    font-size: 11pt;
    font-weight: 700;
    color: #000;
  }
}
