@font-face {
  font-family: "Neue";
  src: url("./font/PPNeueMontreal-Variable.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #161616;
  --muted: #777;
  --line: #e7e7e7;
  --soft: #f4f4f3;
  --content: 1440px;

  --color-agency: #ff6e3a;
  --color-corporate: #D6CDC6;
  --color-events: #1fd092;
  --color-network: #3974f4;
  --color-plus: #6d7882;
  --color-social: #ed5bad;
  --color-studio: #9172ff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: "Neue", Arial, sans-serif;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select {
  font: inherit;
}

button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

.topbar {
  height: 64px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  position: fixed;
  z-index: 10;
  width: 100%;
  background: #fff;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  font-size: 16px;
}

.wordmark img {
  display: block;
  width: 120px;
  height: auto;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 12px;
}

.topnav a {
  text-decoration: none;
}

.topnav a:hover,
.footer a:hover {
  text-decoration: underline;
}

.account {
  height: 32px;
  padding-left: 18px;
  border-left: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.avatar {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-size: 9px;
}

.menu-button,
.mobile-tabs,
.mobile-action-bar {
  display: none;
}

main {
  max-width: var(--content);
  margin: 0 auto;
}

.intro {
  padding: 78px 24px 52px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 20px;
  font-size: 12px;
}

.square {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 5px;
  background: var(--ink);
  vertical-align: 1px;
}

h1,
h2,
p {
  margin-top: 0;
}

.intro h1 {
  margin-bottom: 20px;
  font-size: clamp(40px, 5vw, 60px);
  font-weight: 450;
  letter-spacing: -0.055em;
  line-height: .98;
}

.intro h1 span,
.install-top h2 span {
  color: #929292;
}

.intro-copy {
  margin-bottom: 0;
  color: #555;
  font-size: 15px;
  line-height: 1.55;
}

.builder {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  border-bottom: 1px solid var(--line);
}

.form-panel,
.preview-panel {
  min-width: 0;
  padding: 40px 34px 44px;
}

.form-panel {
  border-right: 1px solid var(--line);
}

.signature-form {
  display: flex;
  flex-direction: column;
}

.section-heading {
  min-width: 0;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0;
}

.section-number {
  flex: none;
  color: #929292;
  font-size: 11px;
}

.section-heading h2,
.legend-title,
.preview-heading h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 450;
  letter-spacing: -.025em;
}

.sync-badge {
  margin-left: auto;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 20px;
  color: #555;
  font-size: 10px;
  white-space: nowrap;
}

.fields-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 18px;
}

.fields-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.fields-grid label > span {
  color: #555;
  font-size: 12px;
}

.fields-grid small {
  color: #888;
  font-size: 11px;
  font-weight: 400;
}

.fields-grid input,
.fields-grid select {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  border: 1px solid #d9d9d9;
  border-radius: 0;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
}

.fields-grid input:focus,
.fields-grid select:focus {
  outline: 1px solid var(--ink);
  outline-offset: 1px;
}

.fields-grid input::placeholder {
  color: #888;
}

.field-wide {
  grid-column: 1 / -1;
}

.brand-section,
.settings-section {
  min-width: 0;
  margin-top: 50px;
  padding: 0;
  border: 0;
}

.brand-section legend,
.settings-section legend {
  width: 100%;
}

.brand-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.brand-option {
  min-width: 0;
  cursor: pointer;
}

.brand-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.brand-card {
  position: relative;
  min-height: 92px;
  padding: 14px 12px;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 10px;
  border: 1px solid #d8d8d8;
  transition: border-color .15s ease, background .15s ease;
}

.brand-color {
  width: 20px;
  height: 5px;
  background: var(--brand-color);
}

.brand-card-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.brand-card-copy img {
  display: block;
  max-width: 100%;
  width: 100%;
  height: 15px;
  object-fit: contain;
  object-position: left center;
  margin-bottom: 4px;
}

.brand-card-copy small {
  color: #777;
  font-size: 10px;
  line-height: 1.3;
}



.brand-option input:checked + .brand-card {
  border-color: var(--ink);
}

.brand-option input:focus-visible + .brand-card {
  outline: 2px solid #555;
  outline-offset: 2px;
}

.settings-section .section-heading {
  margin-bottom: 12px;
}

.check-row,
.legal-row {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-top: 1px solid #ededed;
  font-size: 13px;
}

.check-row input {
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: var(--ink);
}

.check-row small,
.legal-row small {
  margin-left: auto;
  color: #888;
  font-size: 10px;
  text-align: right;
}

.legal-row {
  border-bottom: 1px solid #ededed;
  color: #555;
}

.lock-icon {
  position: relative;
  width: 17px;
  height: 17px;
  flex: none;
}


.preview-panel {
  padding-right: 34px;
  padding-left: 42px;
}

.preview-heading {
  margin-bottom: 24px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.preview-heading span {
  color: #777;
  font-size: 11px;
}

.email-preview {
  border: 1px solid var(--line);
  background: #fff;
}

.email-meta {
  min-height: 60px;
  padding: 12px 17px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  border-bottom: 1px solid var(--line);
  color: #777;
  font-size: 10px;
}

.email-meta b {
  color: #444;
  font-weight: 450;
}

.email-body {
  padding: 25px 20px 20px;
}

.email-body > p {
  margin-bottom: 22px;
  color: #777;
  font-size: 12px;
}

.signature-preview {
  min-height: 138px;
  /* overflow-wrap: anywhere; */
  overflow-x: scroll;
}

.desktop-actions {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

#copyHtmlBtn img, #mobileCopyBtn img, #downloadHtmlBtn img, #mobileDownloadBtn img {
  width: 16px;
  height: 16px;
  fill: #fff;
}

.primary-btn,
.secondary-btn {
  min-height: 48px;
  padding: 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid var(--ink);
  border-radius: 0;
  cursor: pointer;
  font-size: 13px;
}

.primary-btn {
  background: var(--ink);
  color: #fff;
}

.secondary-btn {
  background: #fff;
  color: var(--ink);
}

.primary-btn:hover {
  background: #333;
}

.secondary-btn:hover {
  background: #f5f5f5;
}

.primary-btn:focus-visible,
.secondary-btn:focus-visible,
.mobile-preview-link:focus-visible,
.install-tab:focus-visible {
  outline: 2px solid #666;
  outline-offset: 2px;
}

.preview-note {
  max-width: 500px;
  margin: 19px 0 0;
  color: #666;
  font-size: 11px;
  line-height: 1.55;
}

#htmlOutput {
  position: fixed;
  width: 1px;
  height: 1px;
  padding: 0;
  opacity: 0;
  pointer-events: none;
}

.mobile-preview-link {
  display: none;
}

.install-section {
  padding: 48px 24px 50px;
  background: var(--ink);
  color: #fff;
}

.install-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  padding-bottom: 34px;
}

.install-top h2 {
  margin: 0;
  font-size: clamp(38px, 5vw, 54px);
  font-weight: 450;
  letter-spacing: -.05em;
  line-height: .98;
}

.install-tabs {
  display: flex;
  gap: 7px;
}

.install-tab {
  min-height: 39px;
  padding: 0 16px;
  border: 1px solid #444;
  border-radius: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
  font-size: 11px;
}

.install-tab.is-active {
  border-color: #fff;
  background: #fff;
  color: var(--ink);
}

.install-steps {
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
  border-top: 1px solid #383838;
}

.install-steps li {
  min-height: 94px;
  padding: 22px 22px 0 0;
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 8px;
}

.install-steps li + li {
  padding-left: 22px;
  border-left: 1px solid #383838;
}

.install-steps li > span {
  color: #aaa;
  font-size: 10px;
}

.install-steps p {
  max-width: 310px;
  margin: 0;
  font-size: 15px;
  line-height: 1.4;
}

.help-section {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
}

.help-card {
  min-height: 195px;
  padding: 35px 22px 26px;
  font-size: 13px;
  line-height: 1.5;
}

.help-card + .help-card {
  border-left: 1px solid var(--line);
}

.help-question {
  margin-bottom: 12px;
  color: #888;
  font-size: 11px;
}

.help-card > p:not(.help-question) {
  margin-bottom: 10px;
}

.help-card a {
  font-size: 12px;
  text-decoration: underline;
}

.footer {
  padding: 40px 0 17px;
}

.footer-logo {
  display: block;
  width: min(58%, 630px);
  height: auto;
  margin-bottom: 18px;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: #777;
  font-size: 10px;
}

.footer-bottom nav {
  display: flex;
  gap: 20px;
}

.footer-bottom a {
  text-decoration: underline;
}

@media (max-width: 900px) {
  :root {
    --content: 100%;
  }

  .topbar {
    padding: 0 22px;
  }

  main {
    max-width: 100%;
  }

  .form-panel,
  .preview-panel {
    padding-right: 24px;
    padding-left: 24px;
  }

  .brand-options {
    grid-template-columns: 1fr;
  }

  .brand-card {
    min-height: 72px;
    align-items: center;
  }

  .preview-heading {
    flex-direction: column;
    gap: 6px;
  }

  .install-top {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 14px;
  }

  .topbar {
    height: 54px;
    padding: 0 16px;
  }

  .wordmark img {
    width: 69px;
  }

  .topnav {
    display: none;
  }

  .topnav.is-open {
    position: absolute;
    z-index: 8;
    top: 53px;
    right: 0;
    left: 0;
    padding: 16px;
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
    border-bottom: 1px solid var(--line);
    background: #fff;
  }

  .menu-button {
    width: 28px;
    height: 28px;
    padding: 7px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3px;
    border: 0;
    background: transparent;
  }

  .menu-button span {
    width: 5px;
    height: 5px;
    background: var(--ink);
  }

  .intro {
    padding: 36px 16px 27px;
  }

  .eyebrow {
    margin-bottom: 14px;
    font-size: 11px;
  }

  .intro h1 {
    margin-bottom: 14px;
    font-size: clamp(34px, 9vw, 43px);
    line-height: 1.01;
    letter-spacing: -.055em;
  }

  .intro-copy {
    max-width: 440px;
    font-size: 14px;
    line-height: 1.5;
  }

  .desktop-break {
    display: none;
  }

  .builder {
    display: flex;
    flex-direction: column;
    border: 0;
  }

  .mobile-tabs {
    height: 47px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
  }

  .mobile-tab {
    position: relative;
    border: 0;
    background: #fff;
    color: #777;
    cursor: pointer;
    font-size: 13px;
  }

  .mobile-tab.is-active {
    color: var(--ink);
  }

  .mobile-tab.is-active::after {
    position: absolute;
    right: 0;
    bottom: -1px;
    left: 0;
    height: 2px;
    background: var(--ink);
    content: "";
  }

  .tab-panel {
    display: none;
  }

  .tab-panel.is-active {
    display: block;
  }

  .form-panel,
  .preview-panel {
    padding: 25px 16px 18px;
    border: 0;
  }

  .signature-form {
    gap: 30px;
  }

  .section-heading {
    gap: 10px;
    margin-bottom: 17px;
  }

  .section-heading h2,
  .legend-title,
  .preview-heading h2 {
    font-size: 20px;
  }

  .sync-badge {
    padding: 4px 7px;
    font-size: 9px;
  }

  .fields-grid {
    grid-template-columns: 1fr;
    gap: 17px;
  }

  .field-wide {
    grid-column: auto;
  }

  .fields-grid label {
    gap: 7px;
  }

  .fields-grid label > span {
    font-size: 12px;
  }

  .fields-grid input,
  .fields-grid select {
    height: 46px;
  }

  .brand-options {
    gap: 8px;
  }

  .brand-card {
    min-height: 72px;
    padding: 10px;
  }

  .brand-card-copy {
    gap: 5px;
  }

  .brand-option:first-child .brand-card-copy img {
    width: 66px;
  }

  .brand-card-copy img {
    width: 97px;
  }

  .check-row,
  .legal-row {
    min-height: 48px;
    gap: 10px;
    font-size: 12px;
  }

  .check-row small,
  .legal-row small {
    font-size: 9px;
  }

  .mobile-preview-link {
    width: 100%;
    min-height: 45px;
    margin-top: 22px;
    display: block;
    border: 1px solid #999;
    background: #fff;
    color: var(--ink);
    cursor: pointer;
  }

  .preview-panel {
    min-height: 410px;
    padding-top: 25px;
  }

  .preview-heading {
    margin-bottom: 18px;
  }

  .email-meta {
    padding: 11px;
  }

  .email-body {
    padding: 19px 13px;
  }

  .desktop-actions {
    display: none;
  }

  .mobile-action-bar {
    position: sticky;
    z-index: 5;
    bottom: 0;
    min-height: 64px;
    padding: 8px 16px;
    display: flex;
    gap: 8px;
    border-top: 1px solid var(--line);
    background: #fff;
  }

  .mobile-action-bar .primary-btn {
    flex: 1;
  }

  .mobile-action-bar .secondary-btn {
    width: 48px;
    padding: 0;
  }

  .install-section {
    padding: 29px 16px 30px;
  }

  .install-top {
    gap: 18px;
    padding-bottom: 20px;
  }

  .install-top h2 {
    font-size: 34px;
    line-height: 1.03;
  }

  .install-tabs {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
  }

  .install-tab {
    min-width: 0;
    min-height: 39px;
    padding: 0 5px;
    font-size: 11px;
  }

  .install-steps {
    display: block;
  }

  .install-steps li {
    min-height: 61px;
    padding: 14px 0;
    grid-template-columns: 20px 1fr;
    border-bottom: 1px solid #383838;
  }

  .install-steps li + li {
    padding-left: 0;
    border-left: 0;
  }

  .install-steps p {
    max-width: none;
    font-size: 14px;
  }

  .help-section {
    display: block;
    margin: 24px 16px 0;
    border-top: 1px solid var(--line);
  }

  .help-card {
    min-height: 0;
    padding: 17px 0;
    border-bottom: 1px solid var(--line);
    font-size: 12px;
  }

  .help-card + .help-card {
    border-left: 0;
  }

  .help-question {
    position: relative;
    margin: 0;
    padding-right: 25px;
    color: var(--ink);
    font-size: 13px;
  }

  .help-question::after {
    position: absolute;
    right: 2px;
    content: "+";
    font-size: 17px;
    line-height: 12px;
  }

  .help-card.is-open .help-question::after {
    content: "−";
  }

  .help-card > p:not(.help-question),
  .help-card a {
    display: none;
  }

  .help-card.is-open > p:not(.help-question),
  .help-card.is-open a {
    display: block;
  }

  .footer {
    padding: 28px 16px 20px;
  }

  .footer-logo {
    width: min(78%, 280px);
    margin-bottom: 15px;
  }

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
    font-size: 10px;
  }

  .footer-bottom nav {
    gap: 17px;
  }
}

@media (max-width: 360px) {
  .sync-badge {
    font-size: 8px;
  }

  .check-row,
  .legal-row {
    gap: 7px;
    font-size: 11px;
  }

  .check-row small,
  .legal-row small {
    max-width: 76px;
  }
}
