:root {
  --ink: #1b282c;
  --mist: #c9d4d2;
  --clay: #af705b;
  --oat: #d3ccbf;
  --bone: #f0ebe1;
  --paper: #fbf8f4;
  --line: #dfd5cc;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #e9e4e0;
  color: var(--ink);
  font-family: Georgia, 'Times New Roman', serif;
}
button,
input,
textarea {
  font-family: inherit;
}
button {
  cursor: pointer;
}
.toolbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 13px 20px;
  background: #fff;
  box-shadow: 0 2px 15px #0002;
  display: flex;
  justify-content: center;
  gap: 9px;
  align-items: center;
  flex-wrap: wrap;
  font:
    13px Georgia,
    'Times New Roman',
    serif;
}
.toolbar strong {
  margin-right: 12px;
  color: var(--ink);
}
.toolbar button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 39px;
  padding: 10px 15px;
  background: var(--ink);
  color: #fff;
  border: 1px solid #1b282c;
  border-radius: 5px;
  font:
    normal 13px/1.2 Georgia,
    'Times New Roman',
    serif;
  letter-spacing: 0.05px;
  white-space: nowrap;
  box-shadow: none;
  cursor: pointer;
  transition:
    background 0.15s ease,
    color 0.15s ease;
}
.toolbar .secondary {
  background: #b27a63;
}
.unsaved {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #8a4b36;
  font:
    13px Arial,
    sans-serif;
}
.unsaved::before {
  content: '';
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #af705b;
}
.unsaved[hidden],
.message[hidden] {
  display: none;
}
.message-area {
  flex-basis: 100%;
}
.message {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 8px 12px;
  border: 1px solid #dac5b6;
  border-radius: 6px;
  background: #f2e5dc;
  color: var(--ink);
  font:
    13px Arial,
    sans-serif;
}
.toolbar .hint {
  font-size: 11px;
  color: #657;
}
.sheet {
  width: 8.5in;
  min-height: 11in;
  background: var(--paper);
  margin: 25px auto;
  box-shadow: 0 10px 32px #0002;
  position: relative;
  padding: 35px 47px 66px;
  overflow: hidden;
}
.sheet::before {
  content: '';
  position: absolute;
  right: -90px;
  top: -45px;
  width: 310px;
  height: 240px;
  background: radial-gradient(ellipse at center, #d7c1ae33, transparent 72%);
  pointer-events: none;
}
.inner {
  position: relative;
}
.head {
  text-align: center;
  height: 54px;
  border-bottom: 1px solid #cfc5ba;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}
.head img {
  max-height: 43px;
  width: 170px;
  object-fit: contain;
}
.intro {
  margin: 20px 0 24px;
}
.kicker {
  color: #b57962;
  letter-spacing: 1.9px;
  font:
    700 10px Arial,
    sans-serif;
  margin-bottom: 8px;
  text-transform: uppercase;
}
.intro h1 {
  font-size: 37px;
  letter-spacing: -0.8px;
  line-height: 1.1;
  font-weight: 400;
  margin: 0;
  display: inline;
  background: linear-gradient(transparent 58%, #eedbd2 58%);
}
.intro p {
  font-size: 14px;
  line-height: 1.5;
  color: #526a6b;
  margin: 11px 0 0;
  font-style: italic;
}
h2 {
  font-weight: 400;
  font-size: 20px;
  line-height: 1.16;
  margin: 0 0 8px;
}
h2 span {
  font-size: 15px;
  display: inline-grid;
  place-items: center;
  background: #f1e1d8;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #b0765f;
  margin-right: 5px;
}
h3 {
  font:
    700 10px Arial,
    sans-serif;
  color: #b3755e;
  letter-spacing: 1.3px;
  margin: 15px 0 9px;
}
h3 small {
  font:
    italic 11px Georgia,
    serif;
  letter-spacing: 0;
  color: #627a7b;
  margin-left: 8px;
}
.sub {
  font-size: 12px;
  color: #597274;
  font-style: italic;
  margin: 2px 0 12px;
  line-height: 1.35;
}
.twocol {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 25px;
}
.warmnote {
  background: #f0e7df;
  padding: 18px 20px;
  border-left: 3px solid #b57c66;
  border-radius: 3px;
  font-size: 14px;
  line-height: 1.5;
  margin-bottom: 23px;
}
.compact {
  margin: 20px 0;
  padding: 16px 20px;
}
.compact h2 {
  font-size: 21px;
}
.question {
  margin: 0 0 18px;
}
.question label,
.closing label {
  display: block;
  font-size: 15px;
  line-height: 1.35;
  margin: 0 0 9px;
}
.question small {
  display: block;
  font-size: 11px;
  color: #597274;
  margin-bottom: 9px;
}
.entry {
  border: 1px solid #dbd0c6;
  background: #fffdfb;
  border-radius: 6px;
  padding: 9px 10px;
  color: var(--ink);
  font-size: 13px;
  outline-color: #b17660;
  width: 100%;
  min-width: 0;
}
.entry:focus {
  border-color: #b17660;
  box-shadow: 0 0 0 2px #b1766022;
}
textarea.entry {
  resize: vertical;
  line-height: 1.45;
}
.prompt-block {
  margin: 10px 0 24px;
}
.three-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
}
.statement {
  background: #eee6df;
  border-radius: 7px;
  padding: 18px 20px;
}
.statement h2 {
  font-style: italic;
  font-size: 24px;
}
.statement label {
  font-size: 14px;
  display: block;
  margin: 10px 0 5px;
}
.rule {
  height: 1px;
  background: #dacec4;
  margin: 16px 0;
}
.naming {
  gap: 18px;
}
.naming .entry {
  margin: 0 0 6px;
}
.sketch {
  position: relative;
  height: 132px;
  border: 1px dashed #bca99b;
  border-radius: 7px;
  background: #fffdfa;
  overflow: hidden;
}
.sketch canvas {
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: crosshair;
  display: block;
}
.sketch-hint {
  position: absolute;
  top: 8px;
  left: 9px;
  font:
    italic 11px Georgia,
    serif;
  color: #9a9086;
  pointer-events: none;
}
.mini {
  font:
    10px Arial,
    sans-serif;
  background: #f2e5dc;
  border: 1px solid #dac5b6;
  border-radius: 3px;
  color: var(--ink);
  padding: 5px;
}
.clear-sketch {
  position: absolute;
  bottom: 7px;
  right: 7px;
}
.reference-colors {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-top: 9px;
}
.refcolor {
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.color-square {
  height: 57px;
  border-radius: 8px;
  border: 1px solid #ded4ca;
}
.refcolor b {
  font-size: 12px;
  font-weight: 400;
}
.refcolor code {
  font:
    10px Arial,
    sans-serif;
  color: #5d7777;
}
.custom-colors {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}
.custom-color {
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
}
.picker-shell {
  position: relative;
  display: block;
  height: 75px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #d2c7bf;
}
.picker-shell input {
  position: absolute;
  inset: -7px;
  width: calc(100% + 14px);
  height: calc(100% + 14px);
  padding: 0;
  border: 0;
  cursor: pointer;
}
.picker-shell span {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  text-align: center;
  background: #fff9;
  font:
    9px Arial,
    sans-serif;
  padding: 4px;
  pointer-events: none;
}
.color-meta {
  min-width: 0;
  display: grid;
  gap: 6px;
}
.color-meta label {
  display: block;
  font:
    10px Arial,
    sans-serif;
  color: #537073;
}
.color-meta .entry {
  padding: 6px;
  font:
    11px Arial,
    sans-serif;
  display: block;
  margin-top: 3px;
}
.mood-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 8px;
}
.mood-photo {
  aspect-ratio: 4/3;
  height: auto;
  min-height: 178px;
  overflow: hidden;
  background: #eee7df;
  border-radius: 6px;
}
.mood-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}
.replace {
  display: inline-block;
  margin-top: 6px;
  margin-bottom: 6px;
  padding: 4px 0;
  background: none;
  border: 0;
  color: #a86e58;
  border-bottom: 1px solid #cba28f;
  cursor: pointer;
  font:
    12px Georgia,
    serif;
}
.voice-place {
  display: grid;
  grid-template-columns: 44% 1fr;
  gap: 20px;
  margin-top: 17px;
}
.voice-place h2 {
  font-size: 18px;
}
.voice-place .sub {
  margin-bottom: 7px;
}
.voice-lines {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
}
.voice-lines .entry {
  padding: 7px;
}
.voice-place textarea {
  height: 82px;
}
.options {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 9px;
}
.option {
  display: flex;
  align-items: center;
  gap: 5px;
  font:
    11px Arial,
    sans-serif;
  padding: 5px 8px;
  background: #fffcf9;
  border-radius: 15px;
  border: 1px solid #ded0c5;
  cursor: pointer;
}
.option input {
  accent-color: var(--clay);
}
.smalllabel {
  font:
    12px Georgia,
    serif;
  display: block;
  margin-top: 6px;
}
.closing {
  background: #eee5de;
  padding: 17px 20px;
  margin-top: 17px;
  border-left: 3px solid #b77d66;
}
.closing h2 {
  font-size: 22px;
}
.closing p {
  font-size: 14px;
  line-height: 1.4;
  margin: 7px 0;
}
.closing .signoff {
  font-style: italic;
}
.readiness {
  border-radius: 7px;
  overflow: hidden;
  border: 1px solid #e3d5c9;
  background: #fffdfb;
}
.readiness-row {
  display: grid;
  grid-template-columns: 2.2fr 0.65fr 0.86fr 0.82fr;
  align-items: center;
  border-top: 1px solid #eee3da;
  min-height: 36px;
}
.readiness-row:first-child {
  border-top: 0;
}
.readiness-header {
  background: #eee2d8;
  color: #8d6a59;
  letter-spacing: 0.4px;
  font:
    10px Arial,
    sans-serif;
}
.readiness-header > div {
  text-align: center;
}
.readiness-header > div:first-child {
  text-align: left;
}
.readiness-row > div:first-child {
  padding-left: 12px;
  font-size: 12px;
}
.readiness-row label {
  text-align: center;
}
.readiness-row input {
  accent-color: #b77c65;
}
.checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 20px;
}
.checkitem {
  font:
    12px Arial,
    sans-serif;
  display: flex;
  align-items: center;
  gap: 8px;
}
.checkitem input {
  accent-color: #b77c65;
}
.lower {
  margin-top: 20px;
}
.cta {
  font:
    13px Arial,
    sans-serif;
  color: #1b282c;
  display: inline-block;
  margin-top: 5px;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
footer {
  position: absolute;
  bottom: 27px;
  left: 47px;
  right: 47px;
  border-top: 1px solid #cfc3b7;
  text-align: center;
  padding-top: 10px;
}
footer a {
  font:
    italic 16px Georgia,
    serif;
  color: var(--ink);
  text-decoration: none;
}
.policy {
  width: min(92vw, 620px);
  margin: 40px auto;
  padding: 30px;
  background: var(--paper);
}
.policy a {
  color: var(--ink);
}
.page-footer {
  position: static;
  margin: 0 auto;
  padding: 0 0 35px;
  border-top: 0;
}
.page-footer a {
  font:
    12px Arial,
    sans-serif;
  color: #687878;
  text-decoration: underline;
}
footer a:hover {
  text-decoration: underline;
}
.helper {
  text-align: center;
  font:
    12px Arial,
    sans-serif;
  color: #687878;
  padding: 10px 0 35px;
}
@media (width <= 850px) {
  .sheet {
    width: min(100%, 8.5in);
    margin: 10px auto;
    box-shadow: none;
    padding: 27px 23px 58px;
    min-height: 0;
  }
  .twocol,
  .voice-place {
    gap: 14px;
  }
  .sheet footer {
    left: 23px;
    right: 23px;
  }
  .custom-color {
    grid-template-columns: 50px 1fr;
  }
  .picker-shell {
    height: 66px;
  }
}
@media (width <= 570px) {
  .twocol,
  .voice-place,
  .naming {
    grid-template-columns: 1fr;
  }
  .sheet {
    padding: 22px 17px 60px;
  }
  .sheet footer {
    left: 17px;
    right: 17px;
  }
  .intro h1 {
    font-size: 32px;
  }
  .custom-colors {
    grid-template-columns: 1fr;
  }
  .custom-color {
    grid-template-columns: 90px 1fr;
  }
  .reference-colors {
    gap: 6px;
  }
  .color-square {
    height: 42px;
  }
  .voice-place textarea {
    height: 100px;
  }
}
@page {
  size: letter;
  margin: 0;
}
@media print {
  body {
    background: #fff !important;
  }
  .toolbar,
  .helper,
  .page-footer,
  .replace,
  .clear-sketch,
  .sketch-hint {
    display: none !important;
  }
  .sheet {
    width: 8.5in;
    height: 11in;
    min-height: 11in;
    margin: 0;
    padding: 35px 47px 66px;
    box-shadow: none;
    break-after: page;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    overflow: hidden;
  }
  .sheet:last-of-type {
    break-after: auto;
  }
  .sheet:nth-of-type(2) .inner {
    transform: scale(0.82);
    transform-origin: top left;
    width: 121.95%;
  }
  .entry {
    background: transparent;
  }
  .sheet::before {
    display: none;
  }
}

.toolbar button.iconbtn {
  min-width: 42px;
  padding: 10px 12px;
  font-size: 16px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.editable-palette {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 10px;
}
.palette-card {
  display: grid;
  gap: 8px;
  align-content: start;
}
.palette-meta {
  display: grid;
  gap: 6px;
}
.palette-meta label {
  display: block;
  font:
    10px Arial,
    sans-serif;
  color: #537073;
}
.palette-meta .entry {
  padding: 6px;
  font:
    11px Arial,
    sans-serif;
  display: block;
  margin-top: 3px;
}
.reference-colors,
.custom-colors {
  display: none !important;
}
@media (width <= 850px) {
  .editable-palette {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .mood-photo {
    min-height: 170px;
  }
}
@media (width <= 570px) {
  .editable-palette {
    grid-template-columns: 1fr 1fr;
  }
  .mood-photo {
    min-height: 230px;
  }
}
@media print {
  .toolbar button.iconbtn {
    display: none !important;
  }
  .editable-palette {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
  }
  .palette-meta .entry {
    padding: 4px;
    font-size: 10px;
  }
  .mood-grid {
    gap: 10px;
  }
  .mood-photo {
    min-height: 0;
    aspect-ratio: 4/3;
  }
}
/* Consistent AVRAE toolbar controls */
.toolbar #pdf-export,
.toolbar #save-work {
  background: #1b282c;
  color: #fff;
}
.toolbar #open-work,
.toolbar #reset {
  background: #fff;
  color: #1b282c;
}
.toolbar #open-work:hover,
.toolbar #reset:hover {
  background: #f0ebe1;
}
.toolbar #pdf-export:enabled:hover,
.toolbar #save-work:hover {
  background: #34464a;
}
.toolbar button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.toolbar button:focus-visible {
  outline: 2px solid #af705b;
  outline-offset: 2px;
}
@media (width <= 650px) {
  .toolbar {
    gap: 7px;
    padding: 10px;
  }
  .toolbar strong {
    width: 100%;
    text-align: center;
    margin: 0;
  }
  .toolbar button {
    font-size: 12px;
    padding: 9px 11px;
    min-height: 36px;
  }
}
.toolbar .message button {
  min-height: 0;
  padding: 5px 9px;
  background: #fff;
  color: #1b282c;
  font-size: 12px;
}
dialog {
  width: min(92vw, 420px);
  padding: 22px;
  border: 0;
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 10px 40px #0005;
}
dialog::backdrop {
  background: #1b282c99;
}
.dialog-title {
  margin: 0 0 10px;
  font-size: 20px;
}
.dialog-text {
  margin: 0 0 18px;
  font:
    14px/1.45 Arial,
    sans-serif;
}
.dialog-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 9px;
}
.dialog-button {
  background: var(--ink);
  color: #fff;
  border: 0;
  border-radius: 6px;
  padding: 10px 13px;
  font:
    13px Arial,
    sans-serif;
}
.dialog-button.secondary {
  background: #b27a63;
}
