/* Shared DueByLaw palette and approved artwork. Page-specific rules stay scoped;
   generated report documents do not load this stylesheet. */
.duebylaw-public,
.duebylaw-app {
  --brand-navy: #122f54;
  --brand-teal: #498d8e;
  --brand-teal-dark: #286667;
  --brand-teal-soft: #edf5f4;
  --brand-paper: #fafbf9;
  --brand-white: #fff;
  --brand-ink: #18324c;
  --brand-muted: #536477;
  --brand-line: #d9e2e7;
  --brand-input-line: #718592;
  --brand-footer-muted: #c6d6e3;
  --brand-focus: #267a9b;
  --brand-shadow: 0 12px 36px rgb(18 47 84 / 6%);
  --brand-font: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  /* Existing public components consume these aliases. */
  --ink: var(--brand-ink);
  --muted: var(--brand-muted);
  --line: var(--brand-line);
  --paper: var(--brand-paper);
  --panel: var(--brand-teal-soft);
  --white: var(--brand-white);
  --brass: var(--brand-teal-dark);
  --brass-dark: var(--brand-teal-dark);
  --focus: var(--brand-focus);
  --shadow: var(--brand-shadow);
  color: var(--ink);
  background: var(--paper);
  font-family: var(--brand-font);
}

/* The same authentication card is used on public and signed-in entry routes. */
.auth-brand { padding: 28px 30px 0; }
.auth-brand img { display: block; width: 216px; max-width: 100%; height: auto; margin-inline: auto; }

.duebylaw-public .landing-nav,
.duebylaw-public .survey-nav {
  min-height: 88px;
  padding: 14px max(24px, calc((100% - 1180px) / 2));
  background: var(--white);
  border-bottom: 1px solid var(--line);
  backdrop-filter: none;
}

.duebylaw-public .landing-brand-mark {
  width: 216px;
  height: auto;
  max-height: none;
}

.duebylaw-public .landing-brand-mark img {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
}

.duebylaw-public .landing-nav nav { gap: 8px; }
.duebylaw-public .landing-nav nav a { border-radius: 8px; }
.duebylaw-public .landing-nav nav a:hover,
.duebylaw-public .landing-nav nav a[aria-current="page"],
.duebylaw-public .nav-dashboard-link {
  background: var(--brand-navy);
  color: var(--white);
}

.duebylaw-public .btn { border-radius: 9px; box-shadow: none; }
.duebylaw-public .btn-primary { background: var(--brand-navy); }
.duebylaw-public .about-cta .btn-primary { background: var(--white); color: var(--brand-navy); }
.duebylaw-public .btn-brass { background: var(--brand-teal-dark); }
.duebylaw-public .btn-quiet { background: var(--brand-teal-soft); color: var(--brand-navy); }
.duebylaw-public .btn:hover { box-shadow: var(--shadow); }
.duebylaw-public :is(input:not([type="radio"]):not([type="checkbox"]), textarea, select, .price-input) {
  border-color: var(--brand-input-line);
}
.duebylaw-public :is(input, textarea)::placeholder { color: var(--brand-muted); opacity: 1; }
.duebylaw-public .price-input:focus-within { outline: 3px solid var(--focus); outline-offset: 3px; }
.duebylaw-public :is(main, .mock-flow-card, .report-scope-card) { overflow-wrap: anywhere; }
.duebylaw-public :is(.mock-flow-actions, .report-scope-actions, .panel-footer-actions) { flex-wrap: wrap; }
.duebylaw-public .btn { white-space: normal; text-align: center; }
.duebylaw-public .mock-draft-summary span { color: var(--brand-muted); }
.duebylaw-public .survey-form input[type="radio"] { min-height: 0; padding: 0; }
.duebylaw-public .survey-form fieldset { min-width: 0; }
.duebylaw-public .survey-form legend small { font-size: 0.8em; font-weight: 500; }
.duebylaw-public .survey-form label:has(input[type="radio"]:checked) {
  border-color: var(--brand-teal-dark);
  background: var(--brand-teal-soft);
  box-shadow: 0 0 0 1px var(--brand-teal-dark);
}
.duebylaw-public .promotion-code { overflow: visible; }
.duebylaw-public .promotion-code button { min-height: 44px; }
.duebylaw-public .visitor-survey { max-height: calc(100dvh - 32px); overflow-y: auto; }
.duebylaw-public .visitor-survey[inert] { visibility: hidden; }
/* Keep the optional card out of the way while a page control has focus. */
.duebylaw-public:has(:is(main, .landing-nav, .about-footer) :focus) .visitor-survey {
  position: static;
  max-height: none;
  margin: 24px auto;
}
.duebylaw-public .public-report-overlay {
  overflow: auto;
  grid-template-rows: auto minmax(240px, 1fr);
}
.duebylaw-public .public-report-toolbar > div { min-width: 0; overflow-wrap: anywhere; }

@media (max-height: 500px) {
  .duebylaw-public .visitor-survey { position: static; max-height: none; margin: 24px auto; }
}
.duebylaw-public .visitor-survey { border-color: var(--line); background: var(--white); box-shadow: var(--shadow); }
.duebylaw-public .visitor-survey legend { font-family: var(--brand-font); font-weight: 700; }
.duebylaw-public .visitor-survey-choices button:hover,
.duebylaw-public .visitor-survey-choices button:focus-visible { background: var(--brand-teal-soft); }
.duebylaw-public :is(a, button, input, textarea, select):focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.duebylaw-public .about-footer,
.duebylaw-public .survey-footer {
  border-top: 0;
  background: var(--brand-navy);
  color: var(--white);
}

.duebylaw-public .about-footer-inner {
  align-items: flex-start;
  gap: 36px;
  padding: 44px 0 30px;
}

.duebylaw-public .about-footer-brand {
  display: block;
  flex: 0 0 auto;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--white);
}

.duebylaw-public .about-footer-brand img { width: 190px; height: auto; }
.duebylaw-public .about-footer-nav { max-width: 670px; color: var(--white); }
.duebylaw-public .about-footer-nav a { border-radius: 6px; }
.duebylaw-public .about-footer-nav a:hover,
.duebylaw-public .about-footer-nav a[aria-current="page"] {
  background: var(--white);
  color: var(--brand-navy);
}
.duebylaw-public .about-footer-note { color: var(--brand-footer-muted); padding-bottom: 44px; }
.duebylaw-public .survey-footer p,
.duebylaw-public .survey-footer a { color: var(--brand-footer-muted); }
.duebylaw-public :is(.about-footer, .survey-footer) :focus-visible { outline-color: var(--white); }

@media (max-width: 960px) {
  .duebylaw-public .landing-nav { flex-direction: row; align-items: center; gap: 16px; }
  .duebylaw-public .landing-nav nav { width: auto; padding: 0; font-size: 0.84rem; }
  .duebylaw-public .landing-nav nav a { padding: 10px; }
  .duebylaw-public .landing-brand-mark { width: 185px; }
}

@media (max-width: 700px) {
  .duebylaw-public .landing-nav { position: relative; flex-direction: column; gap: 12px; padding: 16px 12px 12px; }
  .duebylaw-public .landing-nav nav { justify-content: center; flex-wrap: wrap; gap: 2px; overflow: visible; width: 100%; }
  .duebylaw-public .landing-nav nav a { padding: 9px 7px; font-size: 0.78rem; }
  .duebylaw-public .about-footer-inner { width: calc(100% - 40px); gap: 24px; }
  .duebylaw-public .about-footer-note { width: calc(100% - 40px); }
  .duebylaw-public .about-footer-nav { gap: 6px 0; }
  .duebylaw-public .about-footer-nav a { padding-inline: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .duebylaw-public .btn { transition: none; }
}
