:root {
  --accent: #ff7417;
  --ink: #13171b;
  --muted: #69717b;
  --line: #e4e6e8;
  --soft: #f4f0ea;
  --paper: #ffffff;
  --sheet-text: var(--ink);
  --sheet-muted: var(--muted);
  --sheet-line: var(--line);
  --sheet-panel: #ffffff;
  --shadow: 0 18px 50px rgba(13, 18, 23, 0.12);
  --plus-icon: url("assets/plus.svg?v=2");
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: #eef1f3;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
  padding: 9px 12px;
  cursor: pointer;
}

button:hover {
  border-color: #c4c9cf;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 11px;
  background: #fff;
  color: var(--ink);
}

input[type="color"] {
  min-width: 34px;
  height: 34px;
  padding: 3px;
  overflow: hidden;
  cursor: pointer;
}

input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 0;
}

input[type="color"]::-webkit-color-swatch {
  border: 0;
  border-radius: 6px;
}

textarea {
  resize: vertical;
}

label {
  display: grid;
  gap: 7px;
  color: #4d5661;
  font-size: 12px;
  font-weight: 700;
}

.app-shell {
  display: grid;
  grid-template-columns: 1fr;
  min-height: 100vh;
}

.editor {
  display: none;
  height: 100vh;
  overflow: auto;
  padding: 18px;
  background: #f7f8f9;
  border-right: 1px solid #d7dce1;
}

.editor__header,
.panel__title,
.workspace__bar,
.toolbar,
.editor-actions,
.variants-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.editor__header {
  margin-bottom: 14px;
}

.editor__header h1 {
  margin: 2px 0 0;
  font-size: 22px;
  line-height: 1.05;
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.icon-button {
  width: 58px;
  height: 42px;
  font-weight: 900;
  color: #fff;
  background: var(--ink);
}

.panel {
  display: grid;
  gap: 13px;
  margin-bottom: 14px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.panel h2 {
  margin: 0;
  font-size: 15px;
}

.grid-2,
.grid-3 {
  display: grid;
  gap: 10px;
}

.grid-2 {
  grid-template-columns: 1fr 1fr;
}

.grid-3 {
  grid-template-columns: 1fr 0.65fr 1.2fr;
}

.color-grid {
  grid-template-columns: repeat(auto-fit, minmax(88px, 1fr));
}

.scheme-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.scheme-button {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 7px 8px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  text-align: left;
}

.scheme-button:hover,
.scheme-button.is-active {
  border-color: var(--scheme-accent);
  box-shadow: inset 0 0 0 1px var(--scheme-accent);
}

.scheme-button span:last-child {
  min-width: 0;
  overflow: hidden;
  font-size: 11px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scheme-button__preview {
  display: grid;
  grid-template-columns: repeat(4, 9px);
  gap: 2px;
}

.scheme-button__preview i {
  display: block;
  width: 9px;
  height: 18px;
  border: 1px solid rgba(13, 18, 23, 0.16);
  border-radius: 999px;
}

.color-control {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 40px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.color-control > span:first-child {
  min-width: 0;
  overflow: hidden;
  color: #4d5661;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.color-control__body {
  position: relative;
  display: block;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
}

.color-control__swatch {
  position: absolute;
  inset: 0;
  border: 1px solid #cfd6dd;
  border-radius: 8px;
  background: var(--color-value, #13171b);
  box-shadow: inset 0 0 0 2px #fff;
}

.color-control input[type="color"] {
  position: absolute;
  inset: 0;
  width: 100%;
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  opacity: 0;
}

.primary-button,
.ghost-button,
.file-button {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 800;
}

.ghost-button {
  color: var(--ink);
  background: #fff6ef;
}

.toolbar {
  flex-wrap: wrap;
  justify-content: flex-start;
}

.toolbar button,
.file-button {
  padding: 8px 10px;
  color: var(--ink);
  background: #f6f7f8;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.file-button input,
.logo-drop input,
.image-drop input {
  display: none;
}

.logo-drop,
.image-drop {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 92px;
  overflow: hidden;
  border: 1px dashed #b9c0c7;
  border-radius: 8px;
  background: #fafafa;
  color: var(--muted);
  text-align: center;
  cursor: pointer;
}

.logo-drop img,
.image-drop img {
  display: none;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.logo-drop.has-image img,
.image-drop.has-image img {
  display: block;
}

.logo-drop.has-image span,
.image-drop.has-image span {
  display: none;
}

.product-list {
  display: grid;
  gap: 10px;
}

.page-list {
  display: grid;
  gap: 10px;
}

.page-editor {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfbfc;
}

.page-editor__head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
}

.page-editor__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.page-editor__move {
  display: flex;
  gap: 5px;
}

.page-editor__move button {
  width: 30px;
  height: 30px;
  padding: 0;
  font-weight: 900;
}

.product-editor {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.product-editor__summary {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  width: 100%;
  border: 0;
  border-radius: 0;
  text-align: left;
  background: #fbfbfc;
}

.position-pill,
.page-number,
.dot {
  display: inline-grid;
  place-items: center;
  min-width: 28px;
  height: 22px;
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  font-size: 11px;
  font-weight: 900;
}

.summary-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.summary-total {
  color: var(--accent);
  font-weight: 900;
}

.product-editor.collapsed .product-editor__body {
  display: none;
}

.product-editor__body {
  display: grid;
  gap: 11px;
  padding: 12px;
}

.image-drop {
  height: 140px;
  background: #f3efe9;
}

.variants-head {
  margin-top: 2px;
  color: #4d5661;
  font-size: 12px;
  font-weight: 900;
}

.variants-head button {
  padding: 7px 9px;
  font-size: 12px;
  font-weight: 800;
}

.variants {
  display: grid;
  gap: 8px;
}

.variant-row {
  display: grid;
  grid-template-columns: 1fr 58px 54px 96px 34px;
  gap: 7px;
  align-items: center;
}

.variant-row input {
  padding: 8px;
  font-size: 12px;
}

.variant-row button {
  width: 34px;
  height: 34px;
  padding: 0;
  color: #a33;
  font-weight: 900;
}

.editor-actions {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.editor-actions button {
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
}

.danger {
  color: #b42318;
}

.workspace {
  height: 100vh;
  overflow: auto;
  padding: 96px 28px 120px;
  scroll-padding: 96px 28px 120px;
}

.tilda-toolbar {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 20;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  width: max-content;
  max-width: calc(100vw - 46px);
  margin: 0;
  padding: 8px;
  background: rgba(247, 248, 249, 0.94);
  backdrop-filter: blur(10px);
  border: 1px solid #d7dce1;
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(13, 18, 23, 0.12);
}

.tilda-toolbar > button,
.toolbar-menu > summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 12px;
  background: #fff;
  font-weight: 900;
  cursor: pointer;
}

.tilda-toolbar > .history-button {
  width: 38px;
  min-width: 38px;
  padding: 0;
  font-size: 18px;
  line-height: 1;
}

.tilda-toolbar > .history-button:disabled {
  color: #aeb6bf;
  cursor: default;
  opacity: 0.55;
}

.tilda-toolbar .toolbar-menu:first-of-type {
  display: none;
}

.toolbar-menu {
  position: relative;
}

.toolbar-menu > summary {
  list-style: none;
}

.toolbar-menu > summary::-webkit-details-marker {
  display: none;
}

.toolbar-menu__body {
  position: absolute;
  top: 48px;
  left: 0;
  z-index: 30;
  display: grid;
  gap: 9px;
  width: 310px;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: var(--shadow);
}

.project-menu {
  width: min(360px, calc(100vw - 24px));
}

.block-picker {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.block-picker button,
.project-menu button {
  font-size: 12px;
  font-weight: 900;
}

.toolbar-total {
  display: grid;
  align-content: center;
  min-height: 38px;
  padding: 0 8px;
}

.toolbar-total strong {
  margin-right: 12px;
  font-size: 15px;
}

.toolbar-total span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.live-summary {
  position: fixed;
  top: 86px;
  right: 14px;
  z-index: 18;
  display: grid;
  gap: 8px;
  width: 230px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(13, 18, 23, 0.12);
  backdrop-filter: blur(10px);
  transition: width 0.18s ease, min-height 0.18s ease, padding 0.18s ease, transform 0.18s ease;
}

.live-summary h3 {
  margin: 0;
  font-size: 12px;
}

.live-summary strong {
  display: block;
  font-size: 22px;
  line-height: 1;
}

.live-summary dl {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 7px 10px;
  margin: 0;
  font-size: 11px;
}

.live-summary dt {
  color: var(--muted);
}

.live-summary dd {
  margin: 0;
  font-weight: 900;
}

.ui-summary-collapsed .live-summary:not(:hover):not(:focus-within) {
  place-items: center;
  width: 54px;
  min-height: 54px;
  padding: 0;
  gap: 0;
  overflow: hidden;
}

.ui-summary-collapsed .live-summary:not(:hover):not(:focus-within)::before {
  content: "₽";
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  color: #fff;
  background: var(--ink);
  font-size: 18px;
  font-weight: 1000;
}

.ui-summary-collapsed .live-summary:not(:hover):not(:focus-within) > * {
  display: none;
}

.ui-summary-collapsed .live-summary:hover,
.ui-summary-collapsed .live-summary:focus-within {
  width: min(230px, calc(100vw - 28px));
}

.ui-toolbar-collapsed .tilda-toolbar {
  max-width: calc(100vw - 24px);
  gap: 5px;
  padding: 6px;
}

.ui-toolbar-collapsed .tilda-toolbar > button,
.ui-toolbar-collapsed .toolbar-menu > summary {
  min-height: 32px;
  padding: 7px 9px;
  font-size: 12px;
}

.text-format-toolbar {
  position: fixed;
  left: 50%;
  bottom: 14px;
  z-index: 24;
  display: none;
  align-items: end;
  gap: 8px;
  padding: 9px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(13, 18, 23, 0.16);
  transform: translateX(-50%);
}

.text-format-toolbar.is-visible {
  display: flex;
}

.text-format-toolbar label {
  width: 74px;
  gap: 4px;
}

.text-format-toolbar input {
  height: 32px;
  padding: 5px 7px;
}

.text-format-toolbar button {
  height: 32px;
  padding: 5px 9px;
  font-weight: 900;
  white-space: nowrap;
}

#textSizeAllControl {
  min-width: 122px;
}

.workspace__actions {
  display: flex;
  gap: 8px;
}

.proposal {
  display: grid;
  justify-content: center;
  gap: 18px;
  zoom: var(--preview-zoom, 1);
}

.page-insert {
  display: grid;
  justify-self: center;
  position: relative;
  z-index: 14;
}

.page-insert summary {
  position: relative;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 10px 24px rgba(13, 18, 23, 0.14);
  cursor: pointer;
  font-size: 0;
  font-weight: 900;
  line-height: 1;
  list-style: none;
  background-image: var(--plus-icon);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px 18px;
}

.page-insert summary::before {
  content: "";
}

.page-insert summary::-webkit-details-marker {
  display: none;
}

.page-insert__menu {
  position: absolute;
  top: 42px;
  left: 50%;
  display: grid;
  grid-template-columns: repeat(2, minmax(120px, 1fr));
  gap: 7px;
  width: 280px;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: var(--shadow);
  transform: translateX(-50%);
}

.page-insert__menu button {
  font-size: 12px;
  font-weight: 900;
}

.page {
  position: relative;
  width: 297mm;
  height: 210mm;
  min-height: 210mm;
  overflow: hidden;
  padding: 18mm;
  color: var(--sheet-text);
  background: var(--paper);
  box-shadow: var(--shadow);
  page-break-after: always;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

.page:hover .page-tools,
.proposal-card:hover .inline-card-tools,
.proposal-card.is-resizing .inline-card-tools {
  opacity: 1;
  pointer-events: auto;
}

.page-tools,
.inline-card-tools {
  position: absolute;
  z-index: 12;
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

.page-tools {
  top: 7mm;
  right: 7mm;
  padding: 6px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-radius: 9px;
  box-shadow: 0 10px 24px rgba(13, 18, 23, 0.12);
}

.page-tools button,
.page-tools select,
.inline-card-tools button {
  width: auto;
  min-height: 30px;
  padding: 5px 8px;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 900;
}

.page-tools select {
  max-width: 124px;
}

.inline-card-tools {
  z-index: 30;
  top: 8px;
  right: 8px;
  padding: 5px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-radius: 8px;
}

[contenteditable="true"] {
  display: inline-block;
  min-width: 12px;
  min-height: 1.35em;
  margin: -3px -4px;
  padding: 3px 4px;
  outline: 0;
  border-radius: 4px;
}

p[contenteditable="true"],
div[contenteditable="true"],
h2[contenteditable="true"],
h3[contenteditable="true"],
ul[contenteditable="true"] {
  display: block;
}

[contenteditable="true"]:hover,
[contenteditable="true"]:focus {
  box-shadow: 0 0 0 2px rgba(255, 116, 23, 0.22);
  background: rgba(255, 255, 255, 0.58);
}

body.is-exporting-pdf [contenteditable="true"]:hover,
body.is-exporting-pdf [contenteditable="true"]:focus {
  box-shadow: none !important;
  background: transparent !important;
}

.inline-cell {
  min-width: 30px;
  display: inline-block;
}

.image-input-inline {
  display: none;
}

.page.portrait {
  width: 210mm;
  height: 297mm;
  min-height: 297mm;
}

.page.landscape {
  width: 297mm;
  height: 210mm;
  min-height: 210mm;
}

.page:last-child {
  page-break-after: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 28px;
  font-weight: 1000;
  cursor: move;
  user-select: none;
  transform: translate(var(--logo-x, 0), var(--logo-y, 0)) scale(var(--logo-scale, 1));
  transform-origin: left center;
  will-change: transform;
  z-index: 4;
}

.brand.is-logo-dragging,
.is-logo-dragging .brand {
  cursor: grabbing;
}

.brand.is-logo-selected {
  outline: 2px solid var(--accent);
  outline-offset: 5px;
  border-radius: 4px;
}

.page:not(.cover-page) > .brand {
  margin-top: -8mm;
  margin-bottom: 8mm;
}

.brand__mark {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: var(--accent);
}

.brand img {
  max-width: 170px;
  max-height: 42px;
  object-fit: contain;
}

.brand__svg {
  display: block;
  width: 170px;
  max-width: 170px;
  max-height: 42px;
  color: currentColor;
}

.brand__svg svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 42px;
  overflow: visible;
}

.brand--text {
  min-height: 24px;
}

.brand__text {
  display: block;
  font-family: Montserrat, Inter, "Segoe UI", Arial, sans-serif;
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  text-transform: uppercase;
  white-space: nowrap;
}

.brand__tag {
  display: block;
  margin-top: -1px;
  color: #69717b;
  font-size: 7px;
  font-weight: 800;
}

.page-footer {
  position: absolute;
  right: 18mm;
  bottom: 8mm;
  left: 18mm;
  display: flex;
  justify-content: space-between;
  color: #98a0a8;
  font-size: 7px;
  font-weight: 700;
}

.page-footer__right {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.page-footer__credit {
  color: inherit;
  text-decoration: none;
}

.page-footer__credit:hover {
  color: var(--accent);
}

.page-footer::before {
  content: "";
  position: absolute;
  top: -6px;
  left: 0;
  width: 155px;
  height: 2px;
  background: var(--accent);
}

.cover-page {
  color: #fff;
  background: #101417;
  padding: 0;
}

.cover-page .brand,
.cover-copy,
.cover-meta,
.corner-block,
.cover-page::before,
.cover-page::after {
  z-index: 4;
}

.cover-page .brand__tag {
  color: #ccd2d6;
}

.cover-page .brand {
  position: absolute;
  top: 17mm;
  left: 19mm;
}

.cover-copy {
  position: absolute;
  left: 19mm;
  top: 82mm;
  z-index: 5;
  transform: translate(var(--cover-text-x, 0), var(--cover-text-y, 0));
}

.cover-text-block {
  cursor: move;
  touch-action: none;
}

.cover-text-block.is-cover-text-dragging {
  cursor: grabbing;
}

.is-cover-text-dragging [contenteditable="true"] {
  user-select: none;
}

.cover-copy h2 {
  max-width: 78mm;
  margin: 0;
  font-size: 24px;
  line-height: 0.95;
  text-transform: uppercase;
  overflow-wrap: break-word;
}

.cover-copy p {
  max-width: 68mm;
  margin: 11px 0 0;
  color: var(--accent);
  font-size: 10px;
  font-weight: 1000;
  line-height: 1.22;
  text-transform: uppercase;
  overflow-wrap: break-word;
}

.cover-meta {
  position: absolute;
  left: 18mm;
  bottom: 28mm;
  color: #c6ccd1;
  font-size: 7px;
  font-weight: 700;
  transform: translate(var(--cover-text-x, 0), var(--cover-text-y, 0));
}

.cover-meta > span {
  display: block;
}

.cover-image {
  position: absolute;
  top: 12mm;
  right: 12mm;
  width: 185mm;
  height: 174mm;
  z-index: 2;
  overflow: hidden;
  border-radius: 20px;
  background: #ebe9e5;
  cursor: pointer;
}

.cover-image[data-has-image="true"] {
  cursor: grab;
}

.cover-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: translate(var(--image-x, 0), var(--image-y, 0)) scale(var(--image-scale, 1));
  transform-origin: center;
  transition: transform 0.08s ease;
  user-select: none;
  pointer-events: none;
}

.cover-image.is-panning {
  cursor: grabbing;
}

.corner-block {
  position: absolute;
  right: 10mm;
  top: 10mm;
  width: 25mm;
  height: 25mm;
  border-radius: 8px;
  background: var(--accent);
  pointer-events: none;
}

.cover-page .page-footer {
  color: #78828a;
}

.cover-page::before {
  content: "";
  position: absolute;
  left: 76mm;
  bottom: 17mm;
  width: 10mm;
  height: 10mm;
  border-radius: 3px;
  background: var(--accent);
  pointer-events: none;
}

.cover-page::after {
  content: "";
  position: absolute;
  left: 75mm;
  bottom: 12mm;
  width: 55mm;
  height: 1.2px;
  background: var(--accent);
  pointer-events: none;
}

.cover-page.portrait .brand {
  top: 18mm;
  left: 18mm;
  z-index: 5;
}

.cover-page.portrait .cover-image {
  top: 13mm;
  right: 13mm;
  left: 13mm;
  width: auto;
  height: 176mm;
  border-radius: 18px;
}

.cover-page.portrait .cover-copy {
  top: 202mm;
  left: 18mm;
  right: 18mm;
  z-index: 4;
}

.cover-page.portrait .cover-copy h2 {
  max-width: 168mm;
  font-size: 27px;
  line-height: 0.98;
}

.cover-page.portrait .cover-copy p {
  max-width: 148mm;
  margin-top: 10px;
  font-size: 11px;
}

.cover-page.portrait .cover-meta {
  left: 18mm;
  bottom: 30mm;
  z-index: 4;
}

.cover-page.portrait .corner-block {
  top: 12mm;
  right: 12mm;
  z-index: 4;
}

.cover-page.portrait::before {
  left: 18mm;
  bottom: 22mm;
}

.cover-page.portrait::after {
  left: 18mm;
  bottom: 17mm;
}

.cover-layout-classic-shift .cover-copy {
  left: 19mm;
  top: 82mm;
}

.cover-layout-classic-shift .cover-image {
  top: 12mm;
  right: 12mm;
  width: 185mm;
  height: 174mm;
}

.cover-layout-circle-focus {
  background: #111315;
}

.cover-layout-circle-focus .brand {
  top: 16mm;
  left: 20mm;
}

.cover-layout-circle-focus .cover-image {
  top: 16mm;
  right: 18mm;
  width: 168mm;
  height: 168mm;
  border: 10mm solid var(--accent);
  border-radius: 999px;
  background: var(--accent);
}

.cover-layout-circle-focus .cover-copy {
  top: 54mm;
  left: 22mm;
}

.cover-layout-circle-focus .cover-copy h2 {
  max-width: 86mm;
  font-size: 25px;
}

.cover-layout-circle-focus .cover-copy p {
  max-width: 72mm;
}

.cover-layout-circle-focus .cover-meta {
  left: 22mm;
  bottom: 22mm;
}

.cover-layout-circle-focus .corner-block {
  top: auto;
  right: 48mm;
  bottom: 18mm;
  width: 13mm;
  height: 13mm;
  border-radius: 999px;
}

.cover-layout-circle-focus::before {
  display: none;
}

.cover-layout-circle-focus::after {
  left: 22mm;
  bottom: 14mm;
  width: 48mm;
  height: 1.2px;
}

.cover-layout-light-technical {
  color: var(--ink);
  background: var(--paper);
}

.cover-layout-light-technical .brand {
  top: 18mm;
  left: 20mm;
  color: var(--ink);
}

.cover-layout-light-technical .cover-image {
  top: 18mm;
  right: 18mm;
  width: 156mm;
  height: 172mm;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.cover-layout-light-technical .cover-copy {
  top: 56mm;
  left: 20mm;
}

.cover-layout-light-technical .cover-copy h2 {
  max-width: 88mm;
  font-size: 21px;
}

.cover-layout-light-technical .cover-copy p {
  max-width: 74mm;
  color: var(--muted);
  font-size: 8px;
  text-transform: none;
}

.cover-layout-light-technical .cover-meta {
  left: 20mm;
  bottom: 18mm;
  color: var(--muted);
}

.cover-layout-light-technical .corner-block {
  top: auto;
  right: 176mm;
  bottom: 25mm;
  width: 18mm;
  height: 18mm;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 82%, #9b4a2b);
}

.cover-layout-light-technical::before {
  inset: 14mm;
  width: auto;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}

.cover-layout-light-technical::after {
  left: 20mm;
  bottom: 13mm;
  width: 58mm;
}

.cover-layout-industrial-band {
  color: var(--ink);
  background: #f3f5f6;
}

.cover-layout-industrial-band .brand {
  top: 17mm;
  left: 19mm;
  color: #fff;
}

.cover-layout-industrial-band .cover-image {
  top: 24mm;
  right: 22mm;
  width: 202mm;
  height: 150mm;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(13, 18, 23, 0.22);
}

.cover-layout-industrial-band .cover-copy {
  top: 90mm;
  left: 19mm;
}

.cover-layout-industrial-band .cover-copy h2 {
  max-width: 60mm;
  color: #fff;
  font-size: 21px;
}

.cover-layout-industrial-band .cover-copy p {
  max-width: 58mm;
  font-size: 8px;
}

.cover-layout-industrial-band .cover-meta {
  right: 22mm;
  bottom: 18mm;
  left: auto;
  color: var(--muted);
  text-align: right;
}

.cover-layout-industrial-band .corner-block {
  top: 20mm;
  right: 20mm;
  width: 19mm;
  height: 19mm;
  border-radius: 0;
}

.cover-layout-industrial-band::before {
  top: 0;
  bottom: 0;
  left: 0;
  width: 96mm;
  height: auto;
  border-radius: 0;
  background: var(--ink);
}

.cover-layout-industrial-band::after {
  left: 19mm;
  bottom: 16mm;
  width: 52mm;
}

.cover-layout-premium-reverse {
  color: #f8f5ef;
  background: #0f1317;
}

.cover-layout-premium-reverse .brand {
  top: 17mm;
  left: 20mm;
}

.cover-layout-premium-reverse .cover-image {
  top: 26mm;
  right: 26mm;
  width: 180mm;
  height: 138mm;
  border-radius: 48mm 8mm 48mm 8mm;
}

.cover-layout-premium-reverse .cover-copy {
  top: auto;
  left: 20mm;
  bottom: 50mm;
}

.cover-layout-premium-reverse .cover-copy h2 {
  max-width: 66mm;
  font-size: 26px;
}

.cover-layout-premium-reverse .cover-copy p {
  max-width: 64mm;
}

.cover-layout-premium-reverse .cover-meta {
  left: 20mm;
  bottom: 25mm;
  color: #b7c0c8;
}

.cover-layout-premium-reverse .corner-block {
  top: auto;
  right: 27mm;
  bottom: 25mm;
  width: 20mm;
  height: 20mm;
  border-radius: 999px;
}

.cover-layout-premium-reverse::before {
  inset: 10mm;
  width: auto;
  height: auto;
  border: 1px solid #303842;
  border-radius: 12px;
  background: transparent;
}

.cover-layout-premium-reverse::after {
  left: 20mm;
  bottom: 17mm;
  width: 64mm;
}

.cover-layout-portrait-gallery .brand {
  top: 16mm;
  left: 18mm;
}

.cover-layout-portrait-gallery .cover-image {
  top: 31mm;
  right: 18mm;
  left: 18mm;
  width: auto;
  height: 122mm;
  border-radius: 18px;
}

.cover-layout-portrait-gallery .cover-copy {
  top: 160mm;
  left: 18mm;
  right: 18mm;
}

.cover-layout-portrait-gallery .cover-copy h2 {
  max-width: 172mm;
  font-size: 25px;
}

.cover-layout-portrait-gallery .cover-copy p {
  max-width: 148mm;
}

.cover-layout-portrait-gallery .cover-meta {
  left: 18mm;
  bottom: 24mm;
}

.cover-layout-portrait-gallery .corner-block {
  top: 13mm;
  right: 16mm;
  width: 18mm;
  height: 18mm;
  border-radius: 6px;
}

.cover-layout-portrait-gallery::before {
  left: 18mm;
  top: 155mm;
  bottom: auto;
  width: 7mm;
  height: 7mm;
  border-radius: 999px;
}

.cover-layout-portrait-gallery::after {
  left: 18mm;
  bottom: 16mm;
  width: 58mm;
}

.cover-page.portrait.cover-layout-circle-focus .cover-image {
  top: 28mm;
  right: 26mm;
  left: 26mm;
  width: auto;
  height: 158mm;
}

.cover-page.portrait.cover-layout-circle-focus .cover-copy,
.cover-page.portrait.cover-layout-light-technical .cover-copy,
.cover-page.portrait.cover-layout-industrial-band .cover-copy,
.cover-page.portrait.cover-layout-premium-reverse .cover-copy,
.cover-page.portrait.cover-layout-portrait-gallery .cover-copy {
  top: 205mm;
  bottom: auto;
  left: 18mm;
  right: 18mm;
}

.cover-page.portrait.cover-layout-circle-focus .cover-copy h2,
.cover-page.portrait.cover-layout-light-technical .cover-copy h2,
.cover-page.portrait.cover-layout-industrial-band .cover-copy h2,
.cover-page.portrait.cover-layout-premium-reverse .cover-copy h2,
.cover-page.portrait.cover-layout-portrait-gallery .cover-copy h2 {
  max-width: 166mm;
  font-size: 27px;
}

.cover-page.portrait.cover-layout-circle-focus .cover-copy p,
.cover-page.portrait.cover-layout-light-technical .cover-copy p,
.cover-page.portrait.cover-layout-industrial-band .cover-copy p,
.cover-page.portrait.cover-layout-premium-reverse .cover-copy p,
.cover-page.portrait.cover-layout-portrait-gallery .cover-copy p {
  max-width: 150mm;
  font-size: 11px;
}

.cover-page.portrait.cover-layout-light-technical .cover-image,
.cover-page.portrait.cover-layout-industrial-band .cover-image,
.cover-page.portrait.cover-layout-premium-reverse .cover-image,
.cover-page.portrait.cover-layout-portrait-gallery .cover-image {
  top: 34mm;
  right: 18mm;
  left: 18mm;
  width: auto;
  height: 158mm;
}

.cover-page.portrait.cover-layout-industrial-band::before {
  width: 100%;
  height: 96mm;
  bottom: auto;
}

.cover-page.portrait.cover-layout-industrial-band .brand,
.cover-page.portrait.cover-layout-industrial-band .cover-copy h2 {
  color: var(--ink);
}

.cover-page.portrait.cover-layout-light-technical .cover-copy p {
  color: var(--muted);
}

html[data-theme-mode="dark"] .page:not(.cover-page) {
  color: var(--sheet-text);
}

html[data-theme-mode="dark"] .page:not(.cover-page) .brand__tag,
html[data-theme-mode="dark"] .page:not(.cover-page) .section-header p,
html[data-theme-mode="dark"] .page:not(.cover-page) .metric span,
html[data-theme-mode="dark"] .page:not(.cover-page) .workflow-card p,
html[data-theme-mode="dark"] .page:not(.cover-page) .dimensions,
html[data-theme-mode="dark"] .page:not(.cover-page) .description,
html[data-theme-mode="dark"] .page:not(.cover-page) .description-copy p,
html[data-theme-mode="dark"] .page:not(.cover-page) .page-footer,
html[data-theme-mode="dark"] .page:not(.cover-page) .summary-continue-note,
html[data-theme-mode="dark"] .page:not(.cover-page) .terms-box ul,
html[data-theme-mode="dark"] .page:not(.cover-page) .terms-box li {
  color: var(--sheet-muted);
}

html[data-theme-mode="dark"] .page:not(.cover-page) .proposal-card,
html[data-theme-mode="dark"] .page:not(.cover-page) .workflow-card {
  background: var(--sheet-panel);
  border-color: var(--sheet-line);
}

html[data-theme-mode="dark"] .page:not(.cover-page) .proposal-card__media,
html[data-theme-mode="dark"] .page:not(.cover-page) .description-media,
html[data-theme-mode="dark"] .page:not(.cover-page) .metric,
html[data-theme-mode="dark"] .page:not(.cover-page) .terms-box {
  background: var(--soft);
}

html[data-theme-mode="dark"] .page:not(.cover-page) .lead-time,
html[data-theme-mode="dark"] .page:not(.cover-page) .unit-picker {
  color: var(--sheet-text);
}

html[data-theme-mode="dark"] .page:not(.cover-page) .variant-table td,
html[data-theme-mode="dark"] .page:not(.cover-page) .summary-table td {
  border-bottom-color: var(--sheet-line);
}

html[data-theme-mode="dark"] .page:not(.cover-page) .summary-table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.045);
}

.section-header {
  display: grid;
  gap: 15px;
  margin-bottom: 18px;
}

.section-header h2 {
  margin: 0;
  font-size: 26px;
  line-height: 1.05;
}

.section-header p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.metrics {
  display: grid;
  grid-template-columns: 1.35fr 0.62fr 0.62fr 0.78fr;
  gap: 12px;
  margin-top: 4px;
}

.metric {
  display: grid;
  align-content: center;
  min-height: 93px;
  padding: 16px;
  border-radius: 8px;
  background: var(--soft);
}

.metric.dark {
  color: #fff;
  background: var(--ink);
}

.metric strong {
  display: block;
  font-size: 30px;
  line-height: 1;
}

.metric .quantity-breakdown {
  display: grid;
  gap: 4px;
  font-size: 23px;
  line-height: 1.03;
}

.metric .quantity-breakdown span {
  display: block;
  white-space: nowrap;
}

.metric span {
  margin-top: 6px;
  color: #7a838c;
  font-size: 8px;
  font-weight: 900;
  text-transform: uppercase;
}

.metric.dark span {
  color: #bdc5cc;
}

.lead-note-metric {
  position: relative;
}

.lead-note-metric strong {
  padding-right: 42px;
  font-size: 16px;
  line-height: 1.1;
}

.lead-auto-button {
  position: absolute;
  top: 8px;
  right: 8px;
  min-height: 22px;
  padding: 3px 7px;
  font-size: 8px;
  font-weight: 1000;
}

.lead-note-metric.is-auto .lead-auto-button {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.workflow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 42px;
}

.workflow-card {
  position: relative;
  min-height: 94px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.workflow-add {
  position: relative;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  min-height: 20px;
  padding: 0;
  border: 1px solid rgba(255, 116, 23, 0.35);
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  font-size: 0;
  font-weight: 1000;
  background-image: var(--plus-icon);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 12px 12px;
}

.workflow-add::before {
  content: "";
}

.workflow > .workflow-add {
  align-self: center;
  justify-self: start;
}

.workflow-card .workflow-add {
  position: absolute;
  top: 50%;
  right: -10px;
  z-index: 4;
  opacity: 0;
  transform: translateY(-50%);
}

.workflow-delete {
  position: absolute;
  top: 8px;
  right: 8px;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  min-height: 18px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: #c93c2f;
  font-size: 11px;
  font-weight: 1000;
  opacity: 0;
}

.workflow-card:hover .workflow-add,
.workflow-card:hover .workflow-delete {
  opacity: 1;
}

.workflow-card h3 {
  margin: 11px 0 6px;
  font-size: 12px;
}

.workflow-card p {
  margin: 0;
  color: var(--muted);
  font-size: 8px;
  line-height: 1.35;
}

.description-page {
  display: flex;
  flex-direction: column;
}

.description-page .section-header {
  margin-bottom: 14px;
}

.description-media-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(var(--description-count, 1), minmax(0, 1fr));
  gap: 14px;
  height: var(--description-media-height, 300px);
  min-height: 120px;
  max-height: 58%;
  margin-top: 6px;
}

.description-media-grid.per-1 {
  --description-count: 1;
}

.description-media-grid.per-2 {
  --description-count: 2;
}

.description-media-grid.per-3 {
  --description-count: 3;
}

.description-media {
  position: relative;
  overflow: hidden;
  min-height: 100%;
  border-radius: 8px;
  background: var(--soft);
  cursor: pointer;
  outline: 0 solid transparent;
  transition: outline-color 0.12s ease, box-shadow 0.12s ease;
}

.description-media[data-has-image="true"] {
  cursor: grab;
}

.description-media.is-panning {
  cursor: grabbing;
}

.description-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: translate(var(--image-x, 0), var(--image-y, 0)) scale(var(--image-scale, 1));
  transform-origin: center;
  transition: transform 0.08s ease;
  user-select: none;
  pointer-events: none;
}

.description-media .dot {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 3;
}

.description-media-resize-y {
  position: absolute;
  right: 0;
  bottom: -7px;
  left: 0;
  z-index: 12;
  height: 14px;
  cursor: ns-resize;
}

.description-media-resize-y::after {
  content: "";
  position: absolute;
  bottom: 5px;
  left: 50%;
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 116, 23, 0.56);
  opacity: 0;
  transform: translateX(-50%);
}

.description-media-grid:hover .description-media-resize-y::after,
.description-media-grid.is-media-resizing .description-media-resize-y::after {
  opacity: 1;
}

.description-copy {
  margin-top: 18px;
  max-width: 78%;
  text-align: left;
}

.description-copy h3 {
  margin: 0 0 8px;
  font-size: 22px;
  line-height: 1.12;
}

.description-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.48;
  white-space: pre-line;
}

.page.portrait .description-media-grid {
  max-height: 50%;
}

.page.portrait .description-copy {
  max-width: 100%;
}

.cards-grid {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: stretch;
  transform-origin: top left;
  overflow: visible;
}

.cards-grid.per-1 {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.cards-grid.per-2,
.cards-grid.per-4,
.cards-grid.per-6 {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.cards-grid.per-3,
.cards-grid.per-5 {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.page.landscape .cards-grid.per-3 {
  min-height: 132mm;
}

.page.landscape .cards-grid.per-4,
.page.landscape .cards-grid.per-5,
.page.landscape .cards-grid.per-6 {
  height: 132mm;
  min-height: 132mm;
  align-content: stretch;
}

.page.portrait .cards-grid {
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  height: 224mm;
  min-height: 0;
  gap: 10px;
}

.page.portrait .cards-grid .proposal-card {
  flex: 1 1 0;
  width: 100%;
  min-height: 0;
}

.page.portrait .cards-grid.per-1 .proposal-card {
  flex-basis: 100%;
}

.page.portrait .cards-grid.per-2 .proposal-card {
  flex-basis: calc((100% - 10px) / 2);
}

.page.portrait .cards-grid.per-3 .proposal-card {
  flex-basis: calc((100% - 20px) / 3);
}

.page.portrait .cards-grid.per-4 .proposal-card {
  flex-basis: calc((100% - 30px) / 4);
}

.page.portrait .cards-grid.per-5 .proposal-card {
  flex-basis: calc((100% - 40px) / 5);
}

.page.portrait .cards-grid.per-6 .proposal-card {
  flex-basis: calc((100% - 50px) / 6);
}

.proposal-card {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr;
  flex: 0 0 calc(var(--card-width, 50%) - 10px);
  min-height: 295px;
  overflow: hidden;
  padding: 10px;
  border: 1px solid #dfe4e8;
  border-radius: 8px;
}

.add-card-tile {
  display: grid;
  place-items: center;
  position: absolute;
  right: -34px;
  top: 50%;
  z-index: 13;
  width: 22px;
  height: 22px;
  border: 1px solid rgba(255, 116, 23, 0.35);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--accent);
  padding: 0;
  transform: translateY(-50%);
}

.add-card-tile span {
  position: relative;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  font-size: 0;
  line-height: 0;
  font-weight: 900;
  background-image: var(--plus-icon);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 11px 11px;
}

.add-card-tile span::before {
  content: "";
}

.per-1 .proposal-card {
  min-height: 488px;
}

.page.landscape .cards-grid.per-1 {
  height: 132mm;
  min-height: 132mm;
}

.page.landscape .cards-grid.per-2 {
  height: 132mm;
  min-height: 132mm;
  align-content: stretch;
}

.page.landscape .per-1 .proposal-card {
  height: 132mm;
  min-height: 0;
}

.page.landscape .per-2 .proposal-card {
  height: 132mm;
  min-height: 0;
}

.per-1 .proposal-card:not(.feature) {
  grid-template-columns: 1.12fr 0.88fr;
  gap: 14px;
}

.per-1 .proposal-card__media {
  height: 645px;
  min-height: 645px;
  max-height: 645px;
}

.page.landscape .per-1 .proposal-card__media {
  min-height: 0;
  height: 100%;
  max-height: none;
}

.page.landscape .per-1 .proposal-card.orientation-stack,
.page.landscape .per-1 .proposal-card.feature.orientation-stack {
  grid-template-rows: minmax(0, 1fr) auto;
}

.page.landscape .per-1 .proposal-card.orientation-stack .proposal-card__body,
.page.landscape .per-1 .proposal-card.feature.orientation-stack .proposal-card__body {
  min-height: 0;
  padding-top: 8px;
}

.per-3 .proposal-card,
.per-4 .proposal-card,
.per-5 .proposal-card,
.per-6 .proposal-card {
  min-height: 215px;
}

.page.landscape .per-3 .proposal-card {
  height: 132mm;
  min-height: 132mm;
}

.page.landscape .per-4 .proposal-card,
.page.landscape .per-6 .proposal-card {
  height: calc((132mm - 14px) / 2);
  min-height: 0;
}

.page.landscape .per-5 .proposal-card {
  height: calc((132mm - 28px) / 3);
  min-height: 0;
}

.per-3 .proposal-card,
.per-4 .proposal-card,
.per-5 .proposal-card,
.per-6 .proposal-card {
  grid-template-rows: minmax(88px, 0.68fr) auto;
}

.per-3 .proposal-card__media,
.per-4 .proposal-card__media,
.per-5 .proposal-card__media,
.per-6 .proposal-card__media {
  height: 195px;
  min-height: 195px;
  max-height: 195px;
}

.per-5 .proposal-card,
.per-6 .proposal-card {
  padding: 8px;
}

.per-5 .proposal-card {
  min-height: 166px;
}

.per-6 .proposal-card {
  min-height: 190px;
}

.per-5 .proposal-card__media,
.per-6 .proposal-card__media {
  height: 141px;
  min-height: 141px;
  max-height: 141px;
}

.per-5 .proposal-card h3,
.per-6 .proposal-card h3 {
  font-size: 12px;
  line-height: 1.05;
}

.per-5 .description,
.per-6 .description {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.per-3 .proposal-card__body,
.per-4 .proposal-card__body,
.per-5 .proposal-card__body,
.per-6 .proposal-card__body {
  gap: 5px;
  min-height: 0;
  padding-top: 7px;
}

.per-3 .proposal-card h3,
.per-4 .proposal-card h3,
.per-5 .proposal-card h3,
.per-6 .proposal-card h3 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;
}

.per-3 .description,
.per-4 .description {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.per-3 .lead-time,
.per-4 .lead-time,
.per-5 .lead-time,
.per-6 .lead-time {
  margin-top: 2px;
}

.per-3 .total-strip,
.per-4 .total-strip,
.per-5 .total-strip,
.per-6 .total-strip {
  margin-top: 4px;
}

.page.landscape .per-3 .proposal-card {
  grid-template-rows: minmax(158px, 0.86fr) minmax(0, 1fr);
}

.page.landscape .per-3 .proposal-card__media {
  height: 100%;
  min-height: 158px;
  max-height: none;
}

.page.landscape .per-3 .proposal-card__body {
  height: 100%;
  padding-top: 10px;
}

.page.landscape .per-3 .description {
  -webkit-line-clamp: 4;
}

.page.landscape .per-3 .total-strip {
  min-height: 42px;
  padding: 10px 12px;
}

.page.landscape .per-4 .proposal-card,
.page.landscape .per-5 .proposal-card,
.page.landscape .per-6 .proposal-card {
  grid-template-rows: auto minmax(0, 1fr);
}

.page.landscape .per-4 .proposal-card__media {
  height: 111px;
  min-height: 111px;
  max-height: 111px;
}

.page.landscape .per-5 .proposal-card__media {
  height: 63px;
  min-height: 63px;
  max-height: 63px;
}

.page.landscape .per-6 .proposal-card__media {
  height: 78px;
  min-height: 78px;
  max-height: 78px;
}

.page.landscape .per-4 .description,
.page.landscape .per-5 .description,
.page.landscape .per-6 .description {
  -webkit-line-clamp: 1;
}

.page.landscape .per-4 .total-strip,
.page.landscape .per-5 .total-strip,
.page.landscape .per-6 .total-strip {
  min-height: 25px;
  padding: 5px 8px;
}

.per-5 .proposal-card__body,
.per-6 .proposal-card__body {
  gap: 3px;
  padding-top: 5px;
}

.per-5 .dimensions,
.per-6 .dimensions {
  font-size: 6px;
}

.per-5 .lead-time,
.per-6 .lead-time {
  font-size: 7px;
  line-height: 1.08;
}

.per-5 .total-strip,
.per-6 .total-strip {
  min-height: 25px;
  padding: 5px 8px;
}

.per-5 .total-strip strong,
.per-6 .total-strip strong {
  font-size: 11px;
}

.per-5 .total-strip span,
.per-6 .total-strip span {
  font-size: 5.8px;
}

.page.portrait .per-1 .proposal-card:not(.feature) {
  grid-template-columns: 1fr;
}

.page.portrait .per-1 .proposal-card__media {
  height: 533px;
  min-height: 533px;
  max-height: 533px;
}

.proposal-card.orientation-side,
.proposal-card.feature.orientation-side {
  grid-template-columns: 1.2fr 0.95fr;
  grid-template-rows: 1fr;
  gap: 14px;
}

.proposal-card.feature.orientation-side {
  min-height: 440px;
}

.proposal-card.orientation-stack,
.proposal-card.feature.orientation-stack {
  grid-template-columns: 1fr;
  grid-template-rows: auto 1fr;
}

.proposal-card.has-custom-media.orientation-stack {
  grid-template-rows: auto minmax(0, 1fr);
}

.page.landscape .per-1 .proposal-card.has-custom-media.orientation-stack,
.page.landscape .per-1 .proposal-card.feature.has-custom-media.orientation-stack,
.page.landscape .per-3 .proposal-card.has-custom-media {
  grid-template-rows: auto minmax(0, 1fr);
}

.proposal-card.has-custom-media.orientation-side .proposal-card__media {
  align-self: start;
}

.proposal-card__media {
  position: relative;
  overflow: hidden;
  height: 240px;
  min-height: 240px;
  max-height: 240px;
  border-radius: 8px;
  background: var(--soft);
  cursor: pointer;
  outline: 0 solid transparent;
  transition: outline-color 0.12s ease, box-shadow 0.12s ease;
}

.proposal-card__media[data-has-image="true"] {
  cursor: grab;
}

.proposal-card__media.is-panning {
  cursor: grabbing;
}

.proposal-card__media.is-image-active,
.cover-image.is-image-active,
.description-media.is-image-active {
  outline: 3px solid var(--accent);
  box-shadow: 0 0 0 7px rgba(255, 116, 23, 0.15);
}

.proposal-card.orientation-side .proposal-card__media,
.proposal-card.feature.orientation-side .proposal-card__media {
  height: 100%;
  min-height: 240px;
  max-height: none;
}

.proposal-card.feature.orientation-side .proposal-card__media {
  min-height: 385px;
}

.page.portrait .cards-grid:not(.per-1) .proposal-card,
.page.portrait .cards-grid:not(.per-1) .proposal-card.orientation-stack,
.page.portrait .cards-grid:not(.per-1) .proposal-card.orientation-side,
.page.portrait .cards-grid:not(.per-1) .proposal-card.feature.orientation-stack,
.page.portrait .cards-grid:not(.per-1) .proposal-card.feature.orientation-side {
  display: grid;
  grid-template-columns: minmax(0, 0.62fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 10px;
  padding: 8px;
}

.page.portrait .cards-grid:not(.per-1) .proposal-card__media,
.page.portrait .cards-grid:not(.per-1) .proposal-card.orientation-side .proposal-card__media,
.page.portrait .cards-grid:not(.per-1) .proposal-card.feature.orientation-side .proposal-card__media {
  height: 100%;
  min-height: 0;
  max-height: none;
}

.page.portrait .cards-grid:not(.per-1) .proposal-card__body {
  min-height: 0;
  padding-top: 0;
  gap: 4px;
}

.page.portrait .cards-grid:not(.per-1) .proposal-card h3 {
  display: -webkit-box;
  overflow: hidden;
  margin-bottom: 0;
  font-size: 15px;
  line-height: 1.08;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.page.portrait .cards-grid:not(.per-1) .description {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  line-height: 1.24;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.page.portrait .cards-grid.per-5 .description,
.page.portrait .cards-grid.per-6 .description {
  -webkit-line-clamp: 1;
}

.page.portrait .cards-grid:not(.per-1) .variant-table {
  margin-top: 2px;
}

.page.portrait .cards-grid:not(.per-1) .lead-time {
  margin-top: auto;
}

.page.portrait .cards-grid:not(.per-1) .total-strip {
  min-height: 28px;
  margin-top: 3px;
  padding: 5px 8px;
  border-radius: 6px;
}

.page.portrait .cards-grid:not(.per-1) .total-strip strong {
  font-size: 12px;
  white-space: nowrap;
}

.proposal-card__media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: translate(var(--image-x, 0), var(--image-y, 0)) scale(var(--image-scale, 1));
  transform-origin: center;
  transition: transform 0.08s ease;
  user-select: none;
  pointer-events: none;
}

.proposal-card__media .dot {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 3;
}

.media-resize-handle-y {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 12;
  height: 14px;
  cursor: ns-resize;
}

.media-resize-handle-y::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 50%;
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 116, 23, 0.56);
  transform: translateX(-50%);
  opacity: 0;
}

.proposal-card__media:hover .media-resize-handle-y::after,
.proposal-card__media.is-media-resizing .media-resize-handle-y::after {
  opacity: 1;
}

.image-hint {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 14;
  padding: 5px 8px;
  color: #fff;
  background: rgba(19, 23, 27, 0.72);
  border-radius: 7px;
  font-size: 8px;
  font-weight: 900;
}

.resize-handle-x {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 11;
  width: 14px;
  cursor: ew-resize;
}

.resize-handle-x::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 2px;
  width: 4px;
  height: 38px;
  border-radius: 999px;
  background: rgba(255, 116, 23, 0.52);
  transform: translateY(-50%);
  opacity: 0;
}

.resize-handle-y {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 11;
  height: 14px;
  cursor: ns-resize;
}

.resize-handle-y::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 50%;
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 116, 23, 0.52);
  transform: translateX(-50%);
  opacity: 0;
}

.proposal-card:hover .resize-handle-x::after,
.proposal-card:hover .resize-handle-y::after,
.proposal-card.is-resizing .resize-handle-x::after,
.proposal-card.is-resizing .resize-handle-y::after {
  opacity: 1;
}

.proposal-card__media.is-drop-target,
.description-media.is-drop-target,
.cover-image.is-drop-target,
.image-drop.is-drop-target,
.logo-drop.is-drop-target {
  outline: 4px solid color-mix(in srgb, var(--accent) 72%, white);
  box-shadow: 0 0 0 8px rgba(255, 116, 23, 0.15);
}

.page.is-page-drop-target {
  box-shadow: 0 0 0 5px rgba(255, 116, 23, 0.45), var(--shadow);
}

.proposal.is-empty-drop-target {
  outline: 3px dashed var(--accent);
  outline-offset: 12px;
}

.proposal-card__body {
  display: flex;
  flex-direction: column;
  gap: 7px;
  height: 100%;
  padding: 10px 4px 0;
}

.proposal-card__body .total-strip {
  margin-top: 10px;
}

.table-head-label {
  display: inline-block;
  vertical-align: middle;
}

.proposal-card h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.08;
}

.proposal-card.feature h3 {
  font-size: 26px;
}

.dimensions {
  color: #58616b;
  font-size: 8px;
  font-weight: 900;
}

.description {
  margin: 0;
  color: #626c76;
  font-size: 9px;
  line-height: 1.4;
}

.lead-time {
  margin-top: 4px;
  color: #111820;
  font-size: 9px;
  font-weight: 1000;
}

.lead-time [data-edit="leadTime"] {
  cursor: pointer;
}

.proposal-card__body .lead-time {
  margin-top: auto;
}

.lead-date-popover {
  position: fixed;
  z-index: 300;
  display: none;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  width: 260px;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 14px 34px rgba(13, 18, 23, 0.16);
}

.lead-date-popover.is-visible {
  display: flex;
}

.lead-date-popover__row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.lead-date-popover__quick {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.lead-calendar {
  display: grid;
  gap: 6px;
}

.lead-calendar__head {
  display: grid;
  grid-template-columns: 30px 1fr 30px;
  align-items: center;
  gap: 6px;
}

.lead-calendar__head strong {
  color: var(--ink);
  font-size: 11px;
  font-weight: 1000;
  text-align: center;
  text-transform: capitalize;
}

.lead-calendar__weekdays,
.lead-calendar__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.lead-calendar__weekdays span {
  color: #788390;
  font-size: 8px;
  font-weight: 900;
  text-align: center;
}

.lead-calendar__grid span,
.lead-calendar__grid button {
  width: 100%;
  min-width: 0;
  min-height: 27px;
  padding: 0;
  border-radius: 6px;
  font-size: 10px;
  line-height: 1;
  text-align: center;
}

.lead-calendar__grid span {
  display: block;
}

.lead-calendar__grid button {
  border: 1px solid transparent;
  background: #f6f7f8;
  color: var(--ink);
  font-weight: 900;
}

.lead-calendar__grid button:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: #fff;
}

.lead-calendar__grid button.is-today {
  border-color: rgba(255, 111, 26, 0.42);
}

.lead-calendar__grid button.is-selected {
  color: #fff;
  background: var(--accent);
}

.lead-date-popover input {
  width: 100%;
  min-height: 30px;
  padding: 5px 7px;
  border: 1px solid #cfd6dd;
  border-radius: 7px;
  color: var(--ink);
  font: 800 11px Montserrat, Inter, "Segoe UI", Arial, sans-serif;
}

.lead-date-popover button {
  min-height: 30px;
  padding: 5px 8px;
  border-radius: 7px;
  font-size: 10px;
  font-weight: 1000;
}

.lead-date-popover__quick button {
  color: var(--accent);
  background: rgba(255, 111, 26, 0.08);
}

.lead-date-popover__quick button:hover {
  color: #fff;
  background: var(--accent);
}

.lead-date-popover [data-lead-date-close] {
  width: 30px;
  padding: 0;
}

.variant-table {
  width: 100%;
  margin-top: 8px;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 8px;
}

.variant-col-name {
  width: 48%;
}

.variant-col-qty {
  width: 14%;
}

.variant-col-price {
  width: 19%;
}

.variant-col-sum {
  width: 19%;
}

.variant-table th,
.variant-table td {
  position: relative;
  padding: 5px 4px;
  border-bottom: 1px solid #e8ecef;
  text-align: left;
  white-space: nowrap;
  overflow: visible;
}

.variant-table td:first-child {
  padding-left: 14px;
  padding-right: 4px;
}

.variant-table th {
  position: relative;
  color: #626c76;
  font-size: 7px;
  line-height: 1.15;
  text-transform: uppercase;
}

.variant-table th[contenteditable="true"] {
  display: table-cell;
  min-width: 0;
  min-height: 0;
  margin: 0;
}

.variant-table th [contenteditable],
.variant-table th[contenteditable="true"],
.variant-table td .inline-cell {
  max-width: 100%;
  vertical-align: baseline;
  white-space: nowrap;
  overflow: visible;
}

.qty-unit {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  gap: 6px;
  max-width: 100%;
  min-width: 0;
  white-space: nowrap;
}

.qty-unit [contenteditable],
.qty-unit .inline-cell {
  flex: 0 1 auto;
  min-width: 7px;
}

.unit-picker {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  min-width: 0;
  padding-right: 0;
  color: var(--ink);
  font-size: 1em;
  font-weight: 800;
  line-height: 1.05;
  vertical-align: baseline;
  cursor: pointer;
  outline: none;
}

.unit-picker::after {
  content: "";
  position: static;
  flex: 0 0 auto;
  width: 0;
  height: 0;
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  border-top: 4px solid currentColor;
  transform: translateY(-1px);
}

.unit-picker__value {
  display: inline-block;
  max-width: none;
  white-space: nowrap;
}

.unit-picker__menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  z-index: 120;
  display: grid;
  gap: 2px;
  min-width: 46px;
  padding: 4px;
  border: 1px solid #cfd6dd;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(13, 18, 23, 0.16);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(-2px);
  transition:
    opacity 0.14s ease 1s,
    transform 0.14s ease 1s,
    visibility 0s linear 1.14s;
}

.unit-picker:hover .unit-picker__menu,
.unit-picker:focus-within .unit-picker__menu,
.unit-picker:focus .unit-picker__menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  transition-delay: 0s;
}

.unit-picker__menu button {
  min-height: 20px;
  padding: 4px 8px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  font-size: 9px;
  font-weight: 800;
  text-align: left;
  white-space: nowrap;
}

.unit-picker__menu button:hover,
.unit-picker__menu button.is-selected {
  color: #fff;
  background: var(--accent);
}

.variant-table th:nth-child(2),
.variant-table td:nth-child(2),
.variant-table th:nth-child(3),
.variant-table td:nth-child(3) {
  text-align: center;
}

.per-3 .variant-table,
.per-4 .variant-table,
.per-5 .variant-table,
.per-6 .variant-table {
  margin-top: 3px;
  font-size: 5.8px;
}

.per-3 .variant-table th,
.per-3 .variant-table td,
.per-4 .variant-table th,
.per-4 .variant-table td,
.per-5 .variant-table th,
.per-5 .variant-table td,
.per-6 .variant-table th,
.per-6 .variant-table td {
  padding: 3px 2px;
  white-space: nowrap;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}

.per-3 .qty-unit,
.per-4 .qty-unit,
.per-5 .qty-unit,
.per-6 .qty-unit {
  gap: 4px;
}

.per-3 .unit-picker,
.per-4 .unit-picker,
.per-5 .unit-picker,
.per-6 .unit-picker {
  gap: 2px;
  padding-right: 0;
}

.per-3 .unit-picker__value,
.per-4 .unit-picker__value,
.per-5 .unit-picker__value,
.per-6 .unit-picker__value {
  max-width: none;
}

.per-3 .variant-table th,
.per-4 .variant-table th,
.per-5 .variant-table th,
.per-6 .variant-table th {
  font-size: 5.2px;
}

.per-3 .variant-table td:first-child,
.per-4 .variant-table td:first-child,
.per-5 .variant-table td:first-child,
.per-6 .variant-table td:first-child {
  padding-left: 16px;
}

.per-3 .variant-row-delete,
.per-4 .variant-row-delete,
.per-5 .variant-row-delete,
.per-6 .variant-row-delete {
  left: 1px;
  font-size: 11px;
}

.variant-table td:first-child {
  white-space: normal;
  overflow-wrap: break-word;
  word-break: normal;
  line-height: 1.22;
  vertical-align: top;
}

.variant-table td:first-child .inline-cell {
  display: block;
  max-width: 100%;
  min-width: 0;
  white-space: normal;
  overflow-wrap: break-word;
  word-break: normal;
}

.variant-table td:last-child,
.variant-table th:last-child {
  text-align: right;
}

.row-add-menu {
  position: relative;
  display: inline-grid;
  margin-left: 4px;
  vertical-align: middle;
}

.row-add-trigger,
.variant-row-delete {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  min-height: 16px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  font-size: 0;
  font-weight: 1000;
  line-height: 1;
}

.row-add-trigger {
  background-image: var(--plus-icon);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 9px 9px;
}

.row-add-trigger::before {
  content: "";
}

.row-add-menu__body {
  position: absolute;
  top: 18px;
  left: 0;
  z-index: 150;
  display: grid;
  gap: 4px;
  min-width: 110px;
  padding: 5px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 7px;
  box-shadow: 0 10px 24px rgba(13, 18, 23, 0.14);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-2px);
  transition:
    opacity 0.12s ease 1s,
    transform 0.12s ease 1s,
    visibility 0s linear 1.12s;
}

.row-add-menu:hover .row-add-menu__body,
.row-add-menu:focus-within .row-add-menu__body {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition-delay: 0s;
}

.row-add-menu__body button {
  min-height: 22px;
  padding: 4px 6px;
  border-radius: 6px;
  color: var(--ink);
  background: #fff;
  font-size: 8px;
  font-weight: 900;
  text-align: left;
}

.variant-row-delete {
  position: absolute;
  left: 2px;
  top: 50%;
  display: inline-grid;
  width: auto;
  height: auto;
  min-height: 0;
  background: transparent;
  color: #8f241d;
  font-size: 13px;
  opacity: 0.68;
  transform: translateY(-50%);
}

.variant-table tr:hover .variant-row-delete {
  opacity: 1;
}

.variant-table td:last-child,
.summary-table td:last-child,
.summary-table td:nth-child(3),
.summary-table td:nth-child(4),
.metric strong,
.total-strip strong,
.grand-total strong,
.toolbar-total strong,
.live-summary strong,
.live-summary dd {
  font-weight: 1000;
}

.total-strip {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  margin-top: 10px;
  padding: 11px 13px;
  color: #fff;
  background: var(--ink);
  border-radius: 8px;
}

.total-strip span {
  color: #bdc5cc;
  font-size: 7px;
  font-weight: 900;
  text-transform: uppercase;
}

.total-strip strong {
  color: var(--accent);
  font-size: 14px;
}

.page.landscape .per-4 .proposal-card__body,
.page.landscape .per-5 .proposal-card__body {
  padding-bottom: 0;
}

.page.landscape .per-4 .total-strip,
.page.landscape .per-5 .total-strip {
  min-height: 26px;
  margin-top: 3px;
  padding: 5px 8px;
  border-radius: 6px;
}

.page.landscape .per-4 .total-strip strong,
.page.landscape .per-5 .total-strip strong {
  font-size: 11px;
  line-height: 1;
  white-space: nowrap;
}

.page.landscape .per-4 .total-strip span,
.page.landscape .per-5 .total-strip span {
  font-size: 5.8px;
}

.summary-table {
  width: 100%;
  border-collapse: collapse;
  overflow: visible;
  border-radius: 8px;
  font-size: 9px;
}

.summary-table tbody,
.summary-table tr,
.summary-table td {
  overflow: visible;
}

.summary-table th {
  padding: 9px 8px;
  color: #fff;
  background: var(--ink);
  text-align: left;
  white-space: nowrap;
}

.summary-table th:last-child,
.summary-table td:last-child {
  text-align: right;
}

.summary-table th:first-child {
  width: 64px;
}

.summary-table td {
  position: relative;
  padding: 9px 8px;
  border-bottom: 1px solid #eceff1;
  white-space: nowrap;
  overflow: visible;
}

.summary-table td:nth-child(2) {
  white-space: normal;
  overflow-wrap: break-word;
  word-break: normal;
  line-height: 1.25;
}

.summary-table td:nth-child(2) [contenteditable] {
  display: block;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: break-word;
  word-break: normal;
}

.summary-table tbody tr:nth-child(even) {
  background: #f4f0ea;
}

.summary-number-cell {
  position: relative;
  display: grid;
  grid-template-columns: 13px 13px 15px 13px;
  align-items: center;
  gap: 2px;
  width: 64px;
  white-space: nowrap;
  overflow: visible;
  z-index: 4;
}

.summary-row-drag,
.summary-row-insert,
.summary-row-delete {
  position: static;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 999px;
  color: #fff;
  font-weight: 1000;
  line-height: 1;
  opacity: 0;
}

.summary-row-drag {
  width: 13px;
  height: 16px;
  min-height: 16px;
  background: #111820;
  cursor: grab;
  font-size: 8px;
}

.summary-row-drag:active {
  cursor: grabbing;
}

.is-summary-row-dragging,
.is-summary-row-dragging * {
  cursor: grabbing;
  user-select: none;
}

.summary-row-insert {
  position: relative;
  width: 13px;
  height: 13px;
  min-height: 13px;
  background: var(--accent);
  font-size: 0;
  background-image: var(--plus-icon);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 8px 8px;
}

.summary-row-insert::before {
  content: "";
}

.summary-row-delete {
  width: 13px;
  height: 13px;
  min-height: 13px;
  background: #c93c2f;
  font-size: 9px;
}

.summary-number-cell > span {
  display: inline-block;
  min-width: 15px;
  text-align: center;
}

.summary-table tr:hover .summary-row-delete,
.summary-table tr:hover .summary-row-drag,
.summary-table tr:hover .summary-row-insert {
  opacity: 1;
}

.summary-table tr.is-summary-dragging {
  opacity: 0.38;
}

.summary-table tr.is-summary-drop-before {
  box-shadow: inset 0 2px 0 var(--accent);
}

.summary-table tr.is-summary-drop-after {
  box-shadow: inset 0 -2px 0 var(--accent);
}

.summary-add-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  margin-top: 8px;
  padding: 7px 11px;
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
  font-size: 10px;
  font-weight: 1000;
}

.summary-add-menu,
.summary-row-add-menu {
  position: relative;
  display: inline-grid;
  width: max-content;
}

.summary-add-menu__body {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 80;
  display: grid;
  gap: 4px;
  min-width: 96px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(13, 18, 23, 0.14);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-2px);
  transition:
    opacity 0.16s ease 1s,
    transform 0.16s ease 1s,
    visibility 0s linear 1.16s;
}

.summary-row-add-menu .summary-add-menu__body {
  top: auto;
  bottom: 18px;
}

.summary-add-menu:hover .summary-add-menu__body,
.summary-add-menu:focus-within .summary-add-menu__body,
.summary-row-add-menu:hover .summary-add-menu__body,
.summary-row-add-menu:focus-within .summary-add-menu__body {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition-delay: 0s;
}

.summary-add-menu__body button {
  justify-content: flex-start;
  min-height: 22px;
  padding: 5px 7px;
  font-size: 8px;
  font-weight: 900;
  white-space: nowrap;
}

.summary-continue-note {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding: 8px 11px;
  border-radius: 8px;
  color: #4f5964;
  background: var(--soft);
  font-size: 9px;
  font-weight: 900;
}

.summary-continue-note::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
}

.summary-bottom {
  display: grid;
  grid-template-columns: 1.45fr 0.7fr;
  gap: 16px;
  margin-top: 18px;
}

.terms-box,
.grand-total {
  min-height: 122px;
  padding: 16px;
  border-radius: 8px;
  background: var(--soft);
}

.terms-box h3,
.grand-total h3 {
  margin: 0 0 12px;
  font-size: 12px;
}

.terms-box ul {
  margin: 0;
  padding-left: 14px;
  color: #59636e;
  font-size: 8px;
  line-height: 1.55;
}

.terms-box li::marker {
  color: var(--accent);
}

.grand-total {
  color: #fff;
  background: var(--ink);
}

.grand-total strong {
  display: block;
  margin-top: 10px;
  font-size: 30px;
}

.grand-total span {
  color: #bdc5cc;
  font-size: 8px;
  font-weight: 900;
  text-transform: uppercase;
}

.grand-total::after {
  content: "";
  display: block;
  width: 150px;
  height: 4px;
  margin-top: 20px;
  background: var(--accent);
}

.page .brand__tag,
.page .page-footer,
.page .cover-meta,
.page .metric span,
.page .workflow-card p,
.page .image-hint,
.page .dimensions,
.page .description,
.page .lead-time,
.page .variant-table,
.page .variant-table th,
.page .variant-table td,
.page .unit-picker__menu button,
.page .row-add-menu__body button,
.page .summary-table,
.page .summary-table th,
.page .summary-table td,
.page .summary-add-menu__body button,
.page .summary-continue-note,
.page .terms-box ul,
.page .terms-box li,
.page .grand-total span,
.page .total-strip span {
  font-size: 10px;
}

.page.landscape .per-4 .total-strip span,
.page.landscape .per-5 .total-strip span,
.per-5 .dimensions,
.per-6 .dimensions,
.per-5 .lead-time,
.per-6 .lead-time,
.per-5 .total-strip span,
.per-6 .total-strip span,
.per-3 .variant-table,
.per-4 .variant-table,
.per-5 .variant-table,
.per-6 .variant-table,
.per-3 .variant-table th,
.per-4 .variant-table th,
.per-5 .variant-table th,
.per-6 .variant-table th {
  font-size: 10px;
}

@media (max-width: 1100px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .editor,
  .workspace {
    height: auto;
  }

  .workspace {
    padding: 88px 10px 18px;
  }

  .page {
    transform-origin: top center;
  }
}

@media (max-width: 520px) {
  .workspace {
    padding-top: 180px;
  }

  .tilda-toolbar {
    right: 8px;
    left: 8px;
    flex-wrap: wrap;
    width: auto;
    max-width: none;
  }

  .toolbar-total {
    order: 10;
    width: 100%;
  }
}

body.is-exporting-pdf {
  background: #fff !important;
}

body.is-exporting-pdf .editor,
body.is-exporting-pdf .tilda-toolbar,
body.is-exporting-pdf .live-summary,
body.is-exporting-pdf .text-format-toolbar,
body.is-exporting-pdf .lead-date-popover,
body.is-exporting-pdf .page-tools,
body.is-exporting-pdf .page-insert,
body.is-exporting-pdf .inline-card-tools,
body.is-exporting-pdf .summary-row-drag,
body.is-exporting-pdf .summary-row-insert,
body.is-exporting-pdf .summary-row-delete,
body.is-exporting-pdf .summary-add-row,
body.is-exporting-pdf .summary-add-menu,
body.is-exporting-pdf .summary-row-add-menu,
body.is-exporting-pdf .lead-auto-button,
body.is-exporting-pdf .row-add-menu,
body.is-exporting-pdf .variant-row-delete,
body.is-exporting-pdf .workflow-add,
body.is-exporting-pdf .workflow-delete,
body.is-exporting-pdf .add-card-tile,
body.is-exporting-pdf .image-hint,
body.is-exporting-pdf .resize-handle-x,
body.is-exporting-pdf .resize-handle-y,
body.is-exporting-pdf .media-resize-handle-y,
body.is-exporting-pdf .description-media-resize-y,
body.is-exporting-pdf .image-input-inline,
body.is-exporting-pdf .unit-picker__menu {
  display: none !important;
}

body.is-exporting-pdf .app-shell,
body.is-exporting-pdf .workspace,
body.is-exporting-pdf .proposal {
  display: block !important;
  height: auto !important;
  overflow: visible !important;
  padding: 0 !important;
  margin: 0 !important;
}

body.is-exporting-pdf .page {
  margin: 0 !important;
  box-shadow: none !important;
}

body.is-exporting-pdf .unit-picker {
  padding-right: 0 !important;
  color: inherit !important;
  font-size: inherit !important;
  font-weight: inherit !important;
}

body.is-exporting-pdf .unit-picker::after {
  display: none !important;
}

body.is-exporting-pdf .proposal-card__media.is-image-active,
body.is-exporting-pdf .description-media.is-image-active,
body.is-exporting-pdf .cover-image.is-image-active,
body.is-exporting-pdf .brand.is-logo-active,
body.is-exporting-pdf .proposal-card.is-selected,
body.is-exporting-pdf .proposal-card.is-resizing,
body.is-exporting-pdf .is-drop-target,
body.is-exporting-pdf .is-page-drop-target {
  outline: 0 !important;
  box-shadow: none !important;
}

@media print {
  @page {
    size: A4 landscape;
    margin: 0;
  }

  @page portraitPage {
    size: A4 portrait;
    margin: 0;
  }

  @page landscapePage {
    size: A4 landscape;
    margin: 0;
  }

  body {
    background: #fff;
  }

  .editor,
  .tilda-toolbar,
  .live-summary,
  .text-format-toolbar,
  .lead-date-popover,
  .page-tools,
  .page-insert,
  .inline-card-tools,
  .summary-row-drag,
  .summary-row-insert,
  .summary-row-delete,
  .summary-add-row,
  .summary-add-menu,
  .summary-row-add-menu,
  .lead-auto-button,
  .row-add-menu,
  .variant-row-delete,
  .workflow-add,
  .workflow-delete,
  .add-card-tile,
  .image-hint,
  .resize-handle-x,
  .resize-handle-y,
  .media-resize-handle-y,
  .description-media-resize-y,
  .image-input-inline,
  .unit-picker__menu {
    display: none;
  }

  .app-shell,
  .workspace,
  .proposal {
    display: block;
    height: auto;
    overflow: visible;
    padding: 0;
    margin: 0;
    zoom: 1;
  }

  .page {
    page: landscapePage;
    width: 297mm;
    height: 210mm;
    min-height: 210mm;
    margin: 0;
    box-shadow: none;
    break-after: page;
  }

  .page.portrait {
    page: portraitPage;
    width: 210mm;
    height: 297mm;
    min-height: 297mm;
  }

  .unit-picker {
    padding-right: 0;
    color: inherit;
    font-size: inherit;
    font-weight: inherit;
  }

  .unit-picker::after,
  .unit-picker__menu {
    display: none;
  }

  [contenteditable="true"]:hover,
  [contenteditable="true"]:focus {
    outline: 0;
    box-shadow: none;
    background-color: transparent;
  }

  .proposal-card__media.is-image-active,
  .description-media.is-image-active,
  .cover-image.is-image-active,
  .brand.is-logo-selected,
  .proposal-card.is-selected,
  .proposal-card.is-resizing,
  .is-drop-target,
  .is-page-drop-target {
    outline: 0;
    box-shadow: none;
  }
}
