:root {
  color-scheme: light;
  font:
    16px/1.6 "Inter",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: #142c43;
  background: #f9fbfd;
  --line: #cbd7e2;
  --blue: #164fc5;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
a {
  color: var(--blue);
  text-underline-offset: 0.22em;
}
a:focus-visible {
  outline: 3px solid #ff9700;
  outline-offset: 4px;
}
header,
footer {
  background: white;
  border-bottom: 1px solid var(--line);
}
.bar,
main,
.foot {
  max-width: 1240px;
  margin: auto;
  padding: 0 clamp(18px, 4vw, 64px);
}
.bar,
.foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  min-height: 72px;
}
.bar nav,
.actions {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.bar a,
.foot a,
.cards a,
.actions a,
aside a {
  text-decoration: none;
}
.brand {
  color: #142c43;
  font-size: 1.3rem;
  font-weight: 750;
  letter-spacing: -0.06em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.mark {
  width: 25px;
  height: 25px;
  display: inline-grid;
  place-items: center;
  background: #164fc5;
  color: white;
  border-radius: 6px;
  font-size: 23px;
  line-height: 1;
}
.bar nav a {
  color: #344e65;
  font-size: 0.94rem;
}
.bar nav a:hover,
.secondary:hover,
aside a:hover {
  text-decoration: underline;
}
.hero {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 5%;
  align-items: center;
  padding: clamp(48px, 7vw, 98px) 0;
}
.eyebrow,
code {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
}
.eyebrow {
  color: var(--blue);
  font-size: 0.87rem;
}
.hero h1 {
  font-size: clamp(3.1rem, 5.4vw, 5rem);
  line-height: 1.01;
  letter-spacing: -0.07em;
  margin: 0.28em 0;
}
.hero em {
  font-family: Georgia, serif;
  font-weight: 500;
  color: var(--blue);
}
.intro {
  font-size: 1.14rem;
  color: #425970;
  max-width: 40ch;
}
.actions {
  margin-top: 1.7rem;
  gap: 16px;
}
.button,
.secondary {
  font-weight: 600;
}
.button {
  background: var(--blue);
  color: white;
  padding: 0.72em 1.1em;
  border-radius: 6px;
}
.preview {
  background: #132338;
  border: 1px solid #243950;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 18px 36px #142c431c;
}
.window {
  display: flex;
  justify-content: space-between;
  color: #e1ebfa;
  padding: 9px 14px;
  font-size: 0.86rem;
}
.preview img {
  display: block;
  width: 100%;
  height: auto;
}
.resources {
  border-top: 1px solid var(--line);
  padding: 28px 0 56px;
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.cards a {
  background: white;
  color: inherit;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.cards a:hover {
  border-color: var(--blue);
}
.cards h3 {
  font-size: 1.25rem;
  margin: 0.7em 0 0.3em;
}
.cards p {
  color: #425970;
  margin: 0;
}
.cards code {
  color: var(--blue);
  font-size: 0.87rem;
}
.doc {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: clamp(24px, 6vw, 84px);
  padding-block: 40px 64px;
}
.doc aside {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.doc aside a[aria-current] {
  font-weight: bold;
  color: #142c43;
}
.doc article {
  max-width: 850px;
  min-width: 0;
  overflow-wrap: anywhere;
}
.doc h1 {
  letter-spacing: -0.045em;
  font-size: 2.65rem;
  line-height: 1.12;
  margin: 0 0 24px;
}
.doc h2 {
  margin-top: 1.6em;
}
.doc pre {
  overflow-x: auto;
  color: #edf4fc;
  background: #142a40;
  padding: 18px;
  border-radius: 6px;
  font-size: 0.9rem;
}
.doc table {
  display: block;
  overflow: auto;
  border-collapse: collapse;
}
.doc th,
.doc td {
  border: 1px solid var(--line);
  padding: 8px;
  text-align: left;
}
footer {
  border-top: 1px solid var(--line);
}
.foot {
  min-height: 64px;
}
.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 12px;
  background: white;
  padding: 8px;
}
@media (max-width: 780px) {
  .hero,
  .doc {
    grid-template-columns: 1fr;
  }
  .hero {
    gap: 32px;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .doc aside {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px 16px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 16px;
  }
  .bar {
    padding-block: 12px;
    gap: 8px 18px;
  }
  .bar nav {
    gap: 12px;
  }
  .hero h1 {
    font-size: clamp(3rem, 9vw, 4rem);
  }
}

#tools { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1rem 0; border: 1px solid var(--line); }
#tools button { font: inherit; padding: .35rem .8rem; cursor: pointer; }
#canvas marker-area { display: block; height: clamp(300px, 55vh, 620px); }
#attachment { max-width: 100%; border: 1px solid var(--line); }

.review-layout { display: grid; grid-template-columns: minmax(0, 4fr) minmax(11rem, 1fr); border: 1px solid var(--line); background: white; }
.regions { padding: 1rem; }
.regions h2, .recipient h2 { margin: 0; }
.regions ol { list-style: none; padding: 0; }
.regions li + li { margin-top: .25rem; }
.regions button { width: 100%; text-align: left; }
#tools button, .regions button { border: 1px solid var(--line); background: white; border-radius: 4px; font: inherit; padding: .4rem .8rem; cursor: pointer; }
#tools button[aria-pressed=true], .regions button[aria-pressed=true] { background: var(--blue); color: white; }
#tools button:disabled { cursor: default; }
.recipient { margin: 2rem 0; }
#attachment { display: block; max-height: 55vh; margin-bottom: 1rem; }
#canvas [hidden], #attachment[hidden], #download[hidden] { display: none; }
@media (max-width: 680px) { .review-layout { grid-template-columns: minmax(0, 1fr); } }

#ticket-image { display: block; max-width: 100%; max-height: 40vh; margin-bottom: 1rem; border: 1px solid var(--line); }
#attach-ticket, #copy-png { font: inherit; cursor: pointer; padding: .4rem .8rem; }

.review-shortcuts { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.review-shortcuts button, #placement input { font: inherit; }
.review-shortcuts button, #tools button, .regions button, .regions summary,
#attach-ticket, #download, #copy-png { min-height: 44px; }
.review-shortcuts button, #attach-ticket { padding: .55rem .9rem; border: 1px solid var(--blue); border-radius: 4px; background: var(--blue); color: white; cursor: pointer; }
.regions summary { cursor: pointer; padding-block: .55rem; }
.cover-fields { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: .5rem; margin-block: .75rem; }
.cover-fields input { width: 100%; min-height: 44px; }
.resources :focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
@media (max-width: 680px) {
  #canvas marker-area { height: clamp(180px, 69vw, 360px); }
  .recipient button, .recipient .button { margin-block: .25rem; }
  #image-file { max-width: 100%; }
}
.attachment-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; }
