/* Robot Notice (bet 47) on /notice/, and the card itself. The card (.nc, markup from ops/notice.js card())
   sizes everything in container units (cqw), so the same rules draw the small preview, the samples, and the
   1080x1350 PNG that ops/notice.js renders with Chromium. Four styles: brass, carbon, cork, night. */

:root {
  --nt-brass: #c8952c;
  --nt-brass-dark: #7a5512;
  --nt-cork: #c18d55;
  --nt-type: #231c14;
  --nt-paper: #f8f1de;
}

/* ---- The card ---- */
/* Self-contained (the PNG render loads only this file), so the card sets its own box model. */
.nc,
.nc * {
  box-sizing: border-box;
}
.nc-wrap {
  container-type: inline-size;
}
.nc {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  width: 100%;
  padding: 4.4cqw;
  overflow: hidden;
  color: var(--nt-type);
  font-family: "Libre Franklin", Arial, sans-serif;
  line-height: 1.3;
}
:where(.nc) p {
  margin: 0;
}
.nc-paper {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 6cqw 6.4cqw 4.2cqw;
  background-color: var(--nt-paper);
  /* A little paper grain. */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='p'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .4 0 0 0 0 .3 0 0 0 0 .15 0 0 0 .9 -.62'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23p)'/%3E%3C/svg%3E");
}
.nc-title {
  padding-bottom: 2.2cqw;
  border-bottom: 1.1cqw double currentColor;
  color: var(--nt-brass-dark);
  font-size: 6.9cqw;
  font-weight: 900;
  letter-spacing: 0.07em;
  line-height: 1;
  text-align: center;
  text-transform: uppercase;
}
.nc-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 2.2cqw;
  font-size: 2.7cqw;
  font-weight: 700;
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
}
.nc-to {
  margin-top: 6.5cqw;
  padding-bottom: 1.2cqw;
  border-bottom: 0.3cqw solid currentColor;
  font-family: "Courier Prime", "Courier New", monospace;
  font-size: 5cqw;
  font-weight: 700;
  overflow-wrap: anywhere;
}
.nc-label {
  margin-right: 1cqw;
  font-family: "Libre Franklin", Arial, sans-serif;
  font-size: 3cqw;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.nc-text {
  flex: 1;
  margin-top: 5cqw;
  font-family: "Courier Prime", "Courier New", monospace;
  font-weight: 700;
  line-height: 1.32;
  overflow-wrap: anywhere;
}
.nc-s .nc-text {
  font-size: 7.6cqw;
}
.nc-m .nc-text {
  font-size: 6.1cqw;
}
.nc-l .nc-text {
  font-size: 4.9cqw;
}
.nc-foot {
  display: flex;
  align-items: center;
  gap: 3.4cqw;
}
.nc .nc-seal {
  flex: none;
  width: 17cqw;
  height: 17cqw;
  border: 0.9cqw solid var(--nt-brass);
  border-radius: 50%;
  box-shadow:
    0 0 0 0.6cqw var(--nt-paper),
    0 0 0 1cqw var(--nt-brass-dark);
}
.nc-filed {
  font-size: 3.2cqw;
  font-weight: 600;
  line-height: 1.2;
}
.nc-filed b {
  display: block;
  font-size: 5.6cqw;
  font-weight: 900;
}
.nc-dept {
  display: block;
  margin-top: 0.6cqw;
  font-size: 2.5cqw;
  font-weight: 600;
  letter-spacing: 0.04em;
  opacity: 0.75;
}
/* The rubber stamp: red ink, a little crooked, a little worn. */
.nc-stamp {
  position: absolute;
  right: 6.5cqw;
  bottom: 26cqw;
  padding: 0.8cqw 2.8cqw;
  border: 0.8cqw solid currentColor;
  border-radius: 1.8cqw;
  color: #c8102e;
  font-size: 6.4cqw;
  font-weight: 900;
  letter-spacing: 0.14em;
  line-height: 1.1;
  text-transform: uppercase;
  transform: rotate(-11deg);
  opacity: 0.86;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='60'%3E%3Cfilter id='s'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -2.2 2.1'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23s)'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='60'%3E%3Cfilter id='s'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -2.2 2.1'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23s)'/%3E%3C/svg%3E");
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
}
.nc-url {
  margin-top: 3.4cqw;
  font-size: 2.6cqw;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-align: center;
  opacity: 0.7;
}
/* The live draft only: a big watermark, so a screenshot of the preview is plainly not the card. */
.nc-mark {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  margin: 0;
  color: rgba(200, 16, 46, 0.16);
  font-size: 17cqw;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transform: rotate(-30deg);
  pointer-events: none;
}
.nc-ghost .nc-name,
.nc-ghost .nc-text {
  opacity: 0.45;
}

/* Brass: cream paper in a brushed brass frame. */
.nc-brass {
  background:
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.06) 0 2px,
      rgba(0, 0, 0, 0.04) 2px 4px
    ),
    linear-gradient(135deg, #e7c26a, #b8862a 38%, #edd087 55%, #a5731d);
}
/* Carbon copy: the blue duplicate of a form, ruled. */
.nc-carbon {
  --nt-paper: #e3edf6;
  --nt-brass-dark: #1d3557;
  background: #9fb7cc;
  color: #1d3557;
}
.nc-carbon .nc-paper {
  background-image:
    repeating-linear-gradient(
      180deg,
      transparent 0 calc(6.1cqw - 1px),
      rgba(29, 53, 87, 0.16) calc(6.1cqw - 1px) 6.1cqw
    ),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='p'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .1 0 0 0 0 .2 0 0 0 0 .35 0 0 0 .8 -.6'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23p)'/%3E%3C/svg%3E");
}
.nc-carbon .nc-title::after {
  content: "Copy 2 of 3";
  display: block;
  margin-top: 1.4cqw;
  font-size: 2.3cqw;
  font-weight: 700;
  letter-spacing: 0.12em;
}
/* Cork: a white sheet pinned to the board with a brass tack. */
.nc-cork {
  --nt-paper: #fffcf3;
  padding: 7cqw 6cqw 6cqw;
  background-color: var(--nt-cork);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .36 0 0 0 0 .2 0 0 0 0 .07 0 0 0 1.6 -.62'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='m'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.32' numOctaves='3' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .93 0 0 0 0 .78 0 0 0 0 .55 0 0 0 1.5 -.68'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23m)'/%3E%3C/svg%3E");
  box-shadow: inset 0 0 6cqw rgba(60, 30, 5, 0.35);
}
.nc-cork .nc-paper {
  transform: rotate(-1.4deg);
  box-shadow: 0.8cqw 1.6cqw 2.4cqw rgba(40, 20, 0, 0.45);
}
.nc-cork .nc-paper::before {
  content: "";
  position: absolute;
  top: -2.6cqw;
  left: 50%;
  width: 6.4cqw;
  height: 6.4cqw;
  margin-left: -3.2cqw;
  border-radius: 50%;
  background:
    radial-gradient(
      circle at 34% 28%,
      rgba(255, 255, 255, 0.9) 0 8%,
      rgba(255, 255, 255, 0) 42%
    ),
    radial-gradient(circle, #d9a640 0 55%, #8a5d14 100%);
  box-shadow: 0.4cqw 0.8cqw 1cqw rgba(30, 15, 0, 0.5);
}
/* Night shift: navy, brass type, for notices filed after hours. */
.nc-night {
  --nt-paper: #16233d;
  --nt-brass-dark: #e0b354;
  background: #0d1628;
  color: #f3e6c4;
}
.nc-night .nc-paper {
  border: 0.4cqw solid var(--nt-brass);
  background-image: none;
}
.nc-night .nc-stamp {
  color: #ff6b7d;
}
.nc-night .nc-seal {
  box-shadow:
    0 0 0 0.6cqw var(--nt-paper),
    0 0 0 1cqw var(--nt-brass);
}

/* ---- The page ---- */
.nt-sign {
  padding-bottom: 0;
}
.nt-what {
  font-weight: 600;
}
.nt-stage {
  display: grid;
  gap: 24px;
  margin-top: 28px;
}
.nt-show {
  display: grid;
  gap: 14px;
  justify-items: center;
}
.nt-preview {
  width: 100%;
  max-width: 440px;
  box-shadow: 0 18px 30px -16px rgba(50, 28, 8, 0.6);
}
.nt-tack {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 440px;
}
.nt-tack[hidden] {
  display: none;
}
.nt-tack img {
  flex: none;
  width: 72px;
  height: 72px;
  border: 3px solid var(--ink);
  border-radius: 14px;
}
.bubble {
  position: relative;
  flex: 1;
  margin: 0;
  padding: 10px 14px;
  border: 2px solid var(--ink);
  border-radius: 14px;
  background: #fff;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}
.bubble::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 100%;
  border: 9px solid transparent;
  border-right-color: var(--ink);
  transform: translateY(-50%);
}

/* The request form: an intake slip, typed on lines. */
.nt-form {
  align-self: start;
  padding: 22px 20px 20px;
  border: 1px solid #d9cdb0;
  border-top: 8px solid var(--nt-brass);
  background: #fbf7ec;
}
.nt-form-h {
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--ink);
  font-size: 1.0625rem;
  font-weight: 800;
}
.nt-form > label {
  display: block;
  margin-top: 14px;
  font-weight: 800;
}
.nt-form > label span {
  color: var(--muted);
  font-weight: 500;
}
.nt-form input[type="text"],
.nt-form textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 8px 2px;
  border: 0;
  border-bottom: 2px solid var(--ink);
  border-radius: 0;
  background: transparent;
  color: var(--nt-type);
  font:
    700 1.1875rem/1.4 "Courier Prime",
    "Courier New",
    monospace;
  resize: vertical;
}
.nt-form input[type="text"]:focus,
.nt-form textarea:focus {
  outline: 3px solid var(--nt-brass);
  outline-offset: 2px;
}
.nt-words {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.9375rem;
}
.nt-words.over {
  color: var(--red);
  font-weight: 700;
}
.nt-styles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 18px 0 0;
  padding: 0;
  border: 0;
}
.nt-styles legend {
  margin-bottom: 8px;
  padding: 0;
  font-weight: 800;
}
.nt-style {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 6px 10px;
  border: 2px solid #d9cdb0;
  background: #fff;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
}
.nt-style input {
  position: absolute;
  opacity: 0;
}
.nt-style:has(input:checked) {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}
.nt-style:has(input:focus-visible) {
  outline: 3px solid var(--nt-brass);
  outline-offset: 2px;
}
.nt-chip {
  flex: none;
  width: 26px;
  height: 32px;
  border: 1px solid rgba(0, 0, 0, 0.35);
}
.nt-chip-brass {
  background: #f8f1de;
  box-shadow: inset 0 0 0 5px #c8952c;
}
.nt-chip-carbon {
  background: #e3edf6;
  box-shadow: inset 0 0 0 4px #9fb7cc;
}
.nt-chip-cork {
  background: #c18d55;
  box-shadow:
    inset 0 0 0 5px #c18d55,
    inset 0 0 0 13px #fffcf3;
}
.nt-chip-night {
  background: #16233d;
  box-shadow:
    inset 0 0 0 4px #0d1628,
    inset 0 0 0 5px #c8952c;
}
.nt-pay {
  width: 100%;
  margin-top: 20px;
}
.nt-pay[aria-disabled="true"] {
  background: #8a8a86;
  border-color: #8a8a86;
  cursor: not-allowed;
}
.nt-after {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.9375rem;
}
.nt-fine {
  max-width: 44em;
  color: var(--muted);
  font-size: 0.9375rem;
}
.nt-sign .nt-fine {
  margin: 18px 0 0;
}
.nt-thanks {
  max-width: 40em;
  margin: 20px 0 0;
  padding: 14px 18px;
  border-left: 6px solid var(--red);
  background: #fffdf5;
  box-shadow: 0 6px 12px -6px rgba(40, 20, 0, 0.45);
}
.nt-thanks[hidden] {
  display: none;
}
.nt-thanks p {
  margin: 0;
}
.nt-thanks p + p {
  margin-top: 6px;
}

/* Samples and steps */
.nt-samples {
  padding-top: 56px;
}
.nt-sample-row {
  display: grid;
  gap: 28px;
  margin-top: 20px;
}
.nt-sample-row figure {
  max-width: 420px;
  margin: 0;
}
.nt-sample-row .nc-wrap {
  box-shadow: 0 14px 24px -14px rgba(50, 28, 8, 0.55);
}
.nt-sample-row figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.9375rem;
}
/* Share (site/assets/share.js) */
.nt-share {
  display: grid;
  justify-items: start;
  gap: 10px;
  margin-top: 28px;
  font-weight: 700;
}
.btn-share {
  min-height: 48px;
  font-family: inherit;
  cursor: pointer;
}
.btn-share:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}
.share-said {
  font-size: 0.9375rem;
  overflow-wrap: anywhere;
}
.share-said:empty {
  display: none;
}
.nt-samples + .nt-how {
  padding-top: 8px;
}
.nt-how h2 + p,
.nt-how h2 + ol {
  margin-top: 12px;
}
.nt-how ol + h2 {
  margin-top: 40px;
}
.nt-steps {
  max-width: 36em;
  padding-left: 1.4em;
}
.nt-steps li {
  margin: 0 0 8px;
}

@media (min-width: 700px) {
  .nt-sample-row {
    grid-template-columns: 1fr 1fr;
  }
}
@media (min-width: 900px) {
  .nt-stage {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: 40px;
    align-items: start;
  }
  .nt-show {
    order: 2;
    position: sticky;
    top: 20px;
  }
  .nt-form {
    padding: 26px 26px 24px;
  }
}

/* Motion: Tack tilts once when it has something new to say. */
@media (prefers-reduced-motion: no-preference) {
  .nt-tack.talk img {
    animation: nt-tilt 0.5s ease-in-out;
  }
}
@keyframes nt-tilt {
  30% {
    transform: rotate(-7deg);
  }
  70% {
    transform: rotate(4deg);
  }
}
