:root {
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  color: #253c37;
  background: #f6f5ef;
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
header,
footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 5vw;
  border-bottom: 1px solid #d8ded6;
}
.brand {
  font-size: 22px;
  font-weight: 750;
  letter-spacing: -1px;
  text-decoration: none;
  color: inherit;
}
.brand span {
  display: block;
  font-size: 9px;
  letter-spacing: 3px;
  margin-top: 6px;
}
.badge,
.number,
.eyebrow {
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 2px;
}
.badge {
  border: 1px solid #bdc7b9;
  padding: 9px 12px;
  border-radius: 40px;
}
main {
  max-width: 1340px;
  margin: auto;
  padding: 64px 5vw 100px;
  min-height: 78vh;
}
h1 {
  font-size: clamp(44px, 6vw, 80px);
  line-height: 1.03;
  letter-spacing: -4px;
  margin: 20px 0 32px;
  font-weight: 550;
}
h2 {
  font-size: 27px;
  letter-spacing: -1px;
  font-weight: 550;
}
.intro {
  max-width: 510px;
  line-height: 1.7;
  font-size: 18px;
}
button {
  background: #284b40;
  color: white;
  border: 0;
  padding: 15px 22px;
  border-radius: 8px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
button:hover {
  background: #19392f;
}
button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid #bb7b3c;
  outline-offset: 4px;
}
.muted {
  font-size: 13px;
  color: #60726a;
  line-height: 1.7;
  max-width: 460px;
}
.heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.account {
  text-align: right;
}
.quiet {
  background: transparent;
  color: #284b40;
  border: 1px solid #bdc7b9;
  padding: 9px 14px;
}
.quiet:hover {
  background: #e4e9df;
}
.grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 24px;
  margin-top: 24px;
}
.upload,
.library {
  border: 1px solid #d2dacd;
  border-radius: 16px;
  padding: 32px;
  background: #fffdf7;
}
.upload {
  background: #e6eddd;
}
.upload p {
  line-height: 1.65;
}
label {
  display: block;
  margin: 26px 0 12px;
  font-weight: 600;
}
label span {
  float: right;
  font-size: 12px;
  font-weight: 400;
}
input {
  display: block;
  width: 100%;
  margin-bottom: 24px;
  font: inherit;
}
input::file-selector-button {
  padding: 12px;
  border: 1px solid #b2bda9;
  border-radius: 6px;
  background: #fffdf7;
  margin-right: 10px;
}
.library-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.file {
  padding: 22px 0;
  border-top: 1px solid #dde2d8;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
}
.file strong {
  display: block;
  overflow-wrap: anywhere;
}
.file small {
  display: block;
  line-height: 1.7;
  color: #66776f;
}
.file a {
  color: #284b40;
  white-space: nowrap;
}
.empty {
  padding: 45px 0;
  color: #6b7a71;
}
#status {
  line-height: 1.6;
  padding-top: 18px;
}
footer {
  border-top: 1px solid #d8ded6;
  border-bottom: 0;
  font-size: 12px;
  color: #69766e;
}
[hidden] {
  display: none !important;
}
@media (max-width: 700px) {
  header,
  footer {
    gap: 20px;
  }
  .badge {
    font-size: 8px;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .heading {
    align-items: flex-start;
    flex-direction: column;
  }
  .account {
    text-align: left;
  }
  main {
    padding-top: 36px;
  }
  h1 {
    letter-spacing: -2px;
  }
  .upload,
  .library {
    padding: 24px;
  }
  .file {
    align-items: flex-start;
    flex-direction: column;
  }
  footer span {
    max-width: 140px;
    text-align: right;
  }
}
#editor,
#job-history,
#review {
  margin-top: 28px;
}
.replacement {
  display: flex;
  gap: 12px;
  margin: 16px 0;
  align-items: center;
}
.replacement input,
.replacement select {
  margin: 0;
  min-width: 0;
  flex: 1;
  padding: 12px;
  border: 1px solid #b8c4b1;
  border-radius: 6px;
  background: #fff;
  font: inherit;
}
.preview-page {
  margin: 24px 0;
}
.preview-page img {
  display: block;
  max-width: 100%;
  border: 1px solid #d2dacd;
  background: #fff;
}
.preview-page input {
  display: inline;
  width: auto;
  margin: 0;
}
#generated-download {
  display: inline-block;
  padding: 16px;
  background: #284b40;
  color: white;
  border-radius: 8px;
}
@media (max-width: 700px) {
  .replacement {
    flex-direction: column;
    align-items: stretch;
  }
  .file {
    flex-wrap: wrap;
  }
  .file button {
    width: 100%;
  }
}

#business,
#template-mapper,
#document-library {
  margin-top: 28px;
}
.mapping-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.mapping-grid label {
  margin: 10px 0;
}
select,
textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #b8c4b1;
  border-radius: 6px;
  font: inherit;
  background: #fff;
  color: inherit;
}
form input:not([type="checkbox"]) {
  padding: 12px;
  border: 1px solid #b8c4b1;
  border-radius: 6px;
}
input[type="checkbox"] {
  display: inline;
  width: auto;
  margin: 0;
}
.item-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 8px;
  margin: 20px 0;
}
.item-row input {
  min-width: 0;
  margin: 0;
}
.item-row button {
  grid-column: 1/-1;
}
#calculated {
  line-height: 1.8;
  font-weight: 600;
}
@media (max-width: 700px) {
  .mapping-grid {
    grid-template-columns: 1fr;
  }
  .item-row {
    grid-template-columns: 1fr;
  }
  .mapping-grid label {
    min-width: 0;
  }
}
#document-fields { border: 0; padding: 0; margin: 0; min-width: 0; }
#documents .file { flex-wrap: wrap; }
#documents .file > div { flex: 1 1 100%; overflow-wrap: anywhere; }
#documents details { flex: 1 1 100%; }
#documents summary { cursor: pointer; padding: 12px 0; }
#documents details p { line-height: 1.8; overflow-wrap: anywhere; }
.access-notice { padding: 18px 22px; border: 1px solid #b58b48; border-radius: 8px; background: #fff7e8; line-height: 1.6; }
#usage-warning { line-height: 1.7; }
#plan-state { font-weight: 600; }
#client-fields { border: 0; padding: 0; margin: 0; min-width: 0; }
#client-list .file { flex-wrap: wrap; overflow-wrap: anywhere; }
#client-edit-label { line-height: 1.7; }
#template-fields { border: 0; padding: 0; margin: 0; min-width: 0; }
#template-list .file { flex-wrap: wrap; overflow-wrap: anywhere; }
#crm-form-fields { border: 0; padding: 0; margin: 0; min-width: 0; }
#crm .file { flex-wrap: wrap; overflow-wrap: anywhere; }
#crm details { flex-basis: 100%; }
#crm summary { cursor: pointer; padding: 10px 0; }
.workspace-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 32px; }
.workspace-nav a { color: #294d41; border: 1px solid #c7d1c4; border-radius: 24px; padding: 10px 16px; text-decoration: none; }
.workspace-nav a:hover, .workspace-nav a:focus-visible { background: #e2eadf; }
.onboarding { padding: 26px; background: #edf1e8; border-radius: 16px; margin-bottom: 36px; }
.onboarding h2 { font-size: 1.6rem; }
.onboarding ol { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; padding-left: 22px; }
.onboarding a { color: #294d41; line-height: 1.6; }
@media(max-width:700px){.onboarding ol{grid-template-columns:1fr}.workspace-nav a{font-size:14px}}

.pricing-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;margin:24px 0}.plan-card{border:1px solid #ddd9d0;border-radius:20px;padding:24px;background:#faf9f5}.plan-card.featured{background:#eaf0df;border-color:#8d9c76}.plan-price{font-size:2.8rem;letter-spacing:-.05em;margin:18px 0}.plan-price small{font-size:.85rem;letter-spacing:0}.plan-card ul{padding-left:18px;line-height:1.8}.plan-card .eyebrow{font-size:.7rem}@media(max-width:850px){.pricing-grid{grid-template-columns:1fr}}

.workflow-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:24px 0}.workflow-item{border:1px solid #ddd9d0;border-radius:16px;padding:20px}.workflow-item h3{margin:0 0 10px}.workflow-review{margin:24px 0;padding:24px;background:#f3f5eb;border-radius:20px}.workflow-review .grid{align-items:start}.workflow-review dl,#workflow-history dl{margin:0}.workflow-review dt,#workflow-history dt{font-size:.75rem;color:#626b59;text-transform:uppercase;margin-top:12px}.workflow-review dd,#workflow-history dd{margin:4px 0 14px;white-space:pre-wrap;overflow-wrap:anywhere}.workflow-review article{min-width:0}@media(max-width:650px){.workflow-list{grid-template-columns:1fr}.workflow-review{padding:16px}}
#workflow-editor-fields{border:0;margin:0;padding:0;min-width:0}
#workflows summary{padding:12px 0;cursor:pointer}
#workflow-history details{padding:8px 0;border-bottom:1px solid #ddd9d0}
#workflows .mapping-grid{margin:20px 0}
#workflows .quiet{min-height:44px}
#workflow-list a{display:inline-block;margin:12px 0;color:#284b40;text-underline-offset:4px}

.skip-link{position:fixed;left:16px;top:12px;z-index:100;padding:14px 20px;background:#284b40;color:white;border-radius:8px;transform:translateY(-150%)}.skip-link:focus{transform:none}
