.image-tool-page {
  background:
    linear-gradient(180deg, rgba(236, 246, 255, 0.86), rgba(255, 255, 255, 0) 520px),
    #fff;
}

.image-hero {
  display: none;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 68px var(--page-pad) 38px;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.36fr);
  gap: 36px;
  align-items: end;
}

.image-hero h1 {
  max-width: 920px;
  margin: 0;
  color: var(--ink);
  font-size: clamp(3.2rem, 6vw, 6.8rem);
  line-height: 0.96;
}

.image-hero .lead {
  max-width: 800px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 1.18rem;
  line-height: 1.72;
}

.image-hero-card {
  min-height: 180px;
  display: grid;
  align-content: center;
  gap: 12px;
  padding: 26px;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(23, 111, 223, 0.12), rgba(239, 71, 111, 0.1)),
    #fff;
  border: 1px solid #d8e6f6;
  box-shadow: 0 20px 54px rgba(28, 82, 141, 0.12);
}

.image-hero-card strong {
  font-size: 1.3rem;
}

.image-hero-card span {
  color: var(--muted);
  line-height: 1.65;
}

.image-workbench {
  position: relative;
  height: calc(100vh - 126px);
  min-height: 520px;
  max-width: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  background: #111827;
  color: #e5edf8;
  border-top: 1px solid rgba(15, 23, 42, 0.12);
}

.image-workbench::after {
  content: "";
  position: absolute;
  inset: 54px 10px 10px;
  z-index: 12;
  border: 2px dashed rgba(133, 183, 255, 0.85);
  border-radius: 10px;
  background: rgba(23, 111, 223, 0.08);
  box-shadow: inset 0 0 0 9999px rgba(15, 23, 36, 0.28);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

.image-workbench.dragging-file::after {
  opacity: 1;
}

.image-toolbar {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  flex-wrap: nowrap;
  background: #0f1724;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.image-toolbar-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.image-menu {
  position: relative;
  flex: 0 0 auto;
}

.image-menu-button {
  gap: 8px;
  min-width: 82px;
  color: #eef5ff;
  background: #172132;
  border-color: #2b3a52;
}

.image-menu-button .lucide {
  width: 18px;
  height: 18px;
  color: #85b7ff;
}

.image-menu-popover {
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  z-index: 20;
  width: 218px;
  display: grid;
  gap: 3px;
  padding: 8px;
  background: #172132;
  border: 1px solid #33435b;
  border-radius: 8px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.34);
}

.image-menu-popover[hidden] {
  display: none;
}

.image-menu-item {
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: start;
  gap: 10px;
  padding: 0 10px;
  color: #dce7f5;
  background: transparent;
  border: 0;
  border-radius: 7px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 850;
  text-align: left;
  cursor: pointer;
}

.image-menu-item:hover {
  color: #fff;
  background: #243147;
}

.image-menu-item .lucide {
  width: 17px;
  height: 17px;
  color: #85b7ff;
}

.image-menu-item input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.image-menu-separator {
  height: 1px;
  margin: 5px 4px;
  background: #2b3a52;
}

.image-command-group {
  min-height: 34px;
  gap: 4px;
  padding-left: 6px;
  border-left: 1px solid #26344a;
}

.image-group-label {
  margin-right: 2px;
  color: #86a0bf;
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.image-toolbar-divider {
  width: 1px;
  height: 30px;
  background: #33435b;
}

.image-tool-options {
  min-width: 0;
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 2px;
  overflow-x: auto;
}

.image-tool-options [data-option-tools] {
  display: none;
}

.image-tool-options [data-option-tools].active {
  display: inline-flex;
}

.image-tool-options [data-option-tools]:not(.active) {
  display: none;
}

.image-tool-options [data-option-tools][hidden],
.image-tool-options [hidden] {
  display: none;
}

.image-tool-hint {
  min-height: 34px;
  align-items: center;
  padding: 0 10px;
  color: #93a4bc;
  background: #111827;
  border: 1px solid #26344a;
  border-radius: 7px;
  font-size: 0.84rem;
  font-weight: 800;
  white-space: nowrap;
}

.image-tool-options label,
.image-tool-options .image-line-style,
.image-selection-options,
.image-crop-options {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 8px;
  color: #dce7f5;
  background: #111827;
  border: 1px solid #26344a;
  border-radius: 7px;
  font-weight: 850;
}

.image-selection-options {
  gap: 8px;
}

.image-selected-badge {
  min-width: 62px;
  padding: 0 8px;
  color: #fff;
  background: #176fdf;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 900;
  line-height: 26px;
  text-align: center;
}

.image-opacity-option {
  min-width: 150px;
}

.image-opacity-option input[type="range"] {
  width: 78px;
  accent-color: #176fdf;
}

.image-opacity-option output {
  min-width: 34px;
  color: #dce7f5;
  font-size: 0.78rem;
  font-weight: 850;
}

.image-crop-options label {
  min-height: 28px;
  padding: 0 6px;
  gap: 4px;
  background: #0f1724;
  border-color: #26344a;
}

.image-crop-options label span {
  color: #85b7ff;
  font-size: 0.72rem;
  font-weight: 900;
}

.image-crop-options input {
  width: 54px;
  min-height: 24px;
  padding: 0 3px;
  color: #f8fbff;
  background: transparent;
  border: 0;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 850;
}

.image-crop-options button {
  min-height: 28px;
  padding: 0 9px;
  color: #cdd9e8;
  background: #0f1724;
  border: 1px solid #26344a;
  border-radius: 6px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 900;
  cursor: pointer;
}

.image-crop-options button:hover,
.image-crop-options button.active,
.image-crop-options [data-apply-crop] {
  color: #fff;
  background: #176fdf;
  border-color: #176fdf;
}

.image-tool-options label span {
  color: #85b7ff;
  font-size: 0.78rem;
  font-weight: 900;
}

.image-tool-options input[type="number"] {
  width: 56px;
  min-height: 26px;
  padding: 0 4px;
  color: #f8fbff;
  background: transparent;
  border: 0;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 850;
}

.image-tool-options input[type="text"] {
  width: 132px;
  min-height: 26px;
  padding: 0 4px;
  color: #f8fbff;
  background: transparent;
  border: 0;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 850;
}

.image-toolbar button,
.image-file-button,
.image-secondary-button,
.image-primary-button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 11px;
  color: #dce7f5;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
  cursor: pointer;
}

.image-icon-button {
  width: 34px;
  min-width: 34px;
  padding: 0;
  font-size: 1.1rem;
}

.image-workbench .lucide {
  width: 18px;
  height: 18px;
  display: block;
  stroke-width: 2.2;
}

.image-tool-rail .lucide {
  width: 22px;
  height: 22px;
}

.image-button-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.image-toolbar button:disabled {
  opacity: 0.38;
  cursor: not-allowed;
}

.image-toolbar button:hover,
.image-file-button:hover,
.image-secondary-button:hover,
.image-primary-button:hover {
  color: #fff;
  background: #243147;
  border-color: #37465f;
}

.image-primary-button {
  color: #fff;
  background: #176fdf;
  border-color: #176fdf;
}

.image-primary-button:hover {
  background: #0f63cd;
  border-color: #0f63cd;
}

.image-file-button input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.image-toolbar [data-image-status] {
  flex: 0 0 auto;
  color: #93a4bc;
  font-size: 0.88rem;
  font-weight: 800;
}

.image-layout {
  min-height: 0;
  display: grid;
  grid-template-columns: 56px minmax(420px, 1fr) 318px;
  overflow: hidden;
}

.image-controls,
.image-preview-panel,
.image-inspector {
  min-width: 0;
  min-height: 0;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.image-tool-rail {
  display: grid;
  align-content: start;
  gap: 5px;
  padding: 8px 6px;
  background: #0f1724;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.image-tool-section-label {
  width: 44px;
  margin-top: 3px;
  color: #6f86a3;
  font-size: 0.56rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
  text-transform: uppercase;
}

.image-tool-section-label:first-child {
  margin-top: 0;
}

.image-tool-rail button {
  width: 44px;
  height: 40px;
  display: grid;
  place-items: center;
  color: #b8c7db;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  font: inherit;
  font-size: 1.16rem;
  font-weight: 900;
  cursor: pointer;
}

.image-tool-rail button:hover,
.image-tool-rail button.active {
  color: #fff;
  background: #1d2a3e;
  border-color: #334766;
  box-shadow: inset 3px 0 0 #176fdf;
}

.image-color-dock {
  margin-top: 16px;
  width: 44px;
  min-height: 84px;
  position: relative;
}

.image-color-swatch {
  position: absolute;
  width: 31px;
  height: 31px;
  display: block;
  background: #fff;
  border: 2px solid #d7e3f3;
  border-radius: 2px;
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.28);
  cursor: pointer;
}

.image-color-swatch span {
  display: block;
  width: 100%;
  height: 100%;
}

.image-color-swatch input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.image-stroke-swatch {
  left: 0;
  top: 0;
  z-index: 2;
}

.image-fill-swatch {
  right: 0;
  top: 22px;
  z-index: 1;
}

.image-fill-swatch span.transparent {
  background:
    linear-gradient(45deg, #c9d2df 25%, transparent 25%) 0 0 / 8px 8px,
    linear-gradient(45deg, transparent 75%, #c9d2df 75%) 0 0 / 8px 8px,
    #fff;
}

.image-color-dock button {
  position: absolute;
  bottom: 0;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  padding: 0;
  color: #b8c7db;
  background: transparent;
  border: 0;
  font-size: 0.78rem;
  cursor: pointer;
}

.image-color-dock [data-swap-colors] {
  left: 0;
}

.image-color-dock [data-transparent-fill] {
  right: 0;
}

.image-controls,
.image-inspector {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 10px;
  overflow: auto;
  background: #111827;
}

.image-controls {
  grid-column: 3;
  grid-row: 1;
}

.image-preview-panel {
  grid-column: 2;
  grid-row: 1;
}

.image-inspector {
  display: none;
}

.image-panel,
.image-check-card,
.image-stat-grid article {
  background: #172132;
  border: 1px solid #27354b;
  border-radius: 8px;
}

.image-panel,
.image-check-card {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.image-panel .eyebrow,
.image-check-card .eyebrow {
  margin: 0;
  color: #85b7ff;
}

.image-drop-zone {
  min-height: 84px;
  display: grid;
  place-items: center;
  gap: 8px;
  padding: 14px;
  text-align: center;
  color: #dce7f5;
  background:
    linear-gradient(45deg, rgba(133, 183, 255, 0.08) 25%, transparent 25%) 0 0 / 18px 18px,
    linear-gradient(45deg, transparent 75%, rgba(133, 183, 255, 0.08) 75%) 0 0 / 18px 18px,
    #0f1724;
  border: 1px dashed #41516a;
  border-radius: 8px;
}

.image-drop-zone.dragging {
  border-color: #176fdf;
  background-color: #13233b;
  box-shadow: 0 0 0 3px rgba(23, 111, 223, 0.2);
}

.image-drop-zone span,
.image-meta-list span,
.image-panel label span {
  color: #9cafc6;
  font-size: 0.8rem;
  font-weight: 800;
}

.image-meta-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.image-meta-list div {
  display: grid;
  gap: 4px;
  padding: 10px;
  background: #0f1724;
  border: 1px solid #26344a;
  border-radius: 7px;
}

.image-meta-list strong,
.image-panel strong {
  overflow-wrap: anywhere;
  color: #f8fbff;
  font-size: 0.92rem;
}

.image-toggle {
  display: flex;
  align-items: center;
  gap: 9px;
}

.image-toggle input {
  width: 17px;
  height: 17px;
  accent-color: #176fdf;
}

.image-segmented {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.image-segmented.annotate-tools {
  display: none;
}

.image-segmented button {
  min-height: 34px;
  color: #cdd9e8;
  background: #0f1724;
  border: 1px solid #26344a;
  border-radius: 7px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 850;
  cursor: pointer;
}

.image-segmented button:hover,
.image-segmented button.active {
  color: #fff;
  background: #176fdf;
  border-color: #176fdf;
}

.image-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.image-panel label {
  display: grid;
  gap: 7px;
}

.image-panel input,
.image-panel select {
  width: 100%;
  min-height: 34px;
  padding: 0 10px;
  color: #dfe7f2;
  background: #0f1724;
  border: 1px solid #33435b;
  border-radius: 7px;
  font: inherit;
}

.image-panel input[type="range"] {
  min-height: 24px;
  padding: 0;
}

.image-panel output {
  color: #dfe7f2;
  font-size: 0.82rem;
  font-weight: 850;
}

.image-filter-toggles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.image-line-style {
  display: grid;
  grid-template-columns: 42px 42px;
  align-items: center;
  gap: 8px;
}

.image-line-style button {
  min-height: 34px;
  width: 34px;
  color: #cdd9e8;
  background: #0f1724;
  border: 1px solid #26344a;
  border-radius: 7px;
  font: inherit;
  font-size: 1.05rem;
  font-weight: 900;
  cursor: pointer;
}

.image-line-style .lucide {
  width: 18px;
  height: 18px;
}

.image-line-style button:hover,
.image-line-style button.active {
  color: #fff;
  background: #176fdf;
  border-color: #176fdf;
}

.image-panel-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.image-secondary-button.primary {
  color: #fff;
  background: #176fdf;
  border-color: #176fdf;
}

.image-preview-panel {
  display: grid;
  grid-template-rows: 48px minmax(0, 1fr);
  background: #222b3a;
}

.image-preview-heading {
  min-height: 48px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  padding: 8px 14px;
  background: #172132;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.image-preview-heading p {
  margin: 0;
}

.image-preview-heading strong {
  color: #f8fbff;
  font-size: 0.92rem;
}

.image-preview-heading span {
  color: #93a4bc;
  font-size: 0.92rem;
  font-weight: 850;
}

.image-canvas-wrap {
  position: relative;
  min-height: 0;
  display: grid;
  place-items: center;
  overflow: auto;
  padding: 22px;
  background:
    linear-gradient(45deg, #2b3547 25%, transparent 25%) 0 0 / 22px 22px,
    linear-gradient(45deg, transparent 75%, #2b3547 75%) 0 0 / 22px 22px,
    #222b3a;
}

.image-text-editor {
  position: absolute;
  z-index: 5;
  min-width: 90px;
  max-width: min(520px, 70%);
  min-height: 42px;
  padding: 3px 6px;
  color: var(--editor-color, #176fdf);
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid #176fdf;
  outline: 2px solid rgba(23, 111, 223, 0.22);
  resize: both;
  overflow: hidden;
  font: 800 var(--editor-size, 48px) Arial, sans-serif;
  line-height: 1.08;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.18);
}

.image-canvas-wrap canvas {
  max-width: 100%;
  max-height: calc(100vh - 260px);
  display: block;
  background: #fff;
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.38);
  touch-action: none;
}

.image-crop-overlay {
  position: absolute;
  z-index: 3;
  border: 2px solid #f8fbff;
  box-shadow:
    0 0 0 9999px rgba(15, 23, 36, 0.48),
    0 0 0 1px rgba(23, 111, 223, 0.7);
  background: rgba(255, 255, 255, 0.001);
  cursor: move;
  pointer-events: none;
  touch-action: none;
}

.image-crop-overlay.interactive {
  pointer-events: none;
}

.image-crop-overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(to right, transparent 33.333%, rgba(255, 255, 255, 0.58) 33.333%, rgba(255, 255, 255, 0.58) calc(33.333% + 1px), transparent calc(33.333% + 1px), transparent 66.666%, rgba(255, 255, 255, 0.58) 66.666%, rgba(255, 255, 255, 0.58) calc(66.666% + 1px), transparent calc(66.666% + 1px)),
    linear-gradient(to bottom, transparent 33.333%, rgba(255, 255, 255, 0.58) 33.333%, rgba(255, 255, 255, 0.58) calc(33.333% + 1px), transparent calc(33.333% + 1px), transparent 66.666%, rgba(255, 255, 255, 0.58) 66.666%, rgba(255, 255, 255, 0.58) calc(66.666% + 1px), transparent calc(66.666% + 1px));
}

.crop-move-surface {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  background: rgba(255, 255, 255, 0.001);
  cursor: move;
  pointer-events: none;
}

.image-crop-overlay .crop-move-surface,
.image-crop-overlay .crop-handle {
  pointer-events: none;
}

.crop-handle {
  position: absolute;
  z-index: 2;
  width: 10px;
  height: 10px;
  background: #fff;
  border: 2px solid #176fdf;
  border-radius: 50%;
  pointer-events: auto;
}

.crop-handle.nw { left: -6px; top: -6px; cursor: nwse-resize; }
.crop-handle.ne { right: -6px; top: -6px; cursor: nesw-resize; }
.crop-handle.sw { left: -6px; bottom: -6px; cursor: nesw-resize; }
.crop-handle.se { right: -6px; bottom: -6px; cursor: nwse-resize; }

.image-export-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(6, 12, 22, 0.68);
}

.image-export-modal[hidden] {
  display: none;
}

.image-export-dialog {
  width: min(520px, 100%);
  display: grid;
  gap: 16px;
  padding: 18px;
  color: #e5edf8;
  background: #172132;
  border: 1px solid #33435b;
  border-radius: 8px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.46);
}

.image-export-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.image-export-heading h2 {
  margin: 4px 0 0;
  color: #f8fbff;
  font-size: 1.16rem;
}

.image-export-fields {
  display: grid;
  gap: 12px;
}

.image-export-fields label {
  display: grid;
  gap: 7px;
}

.image-export-fields label span {
  color: #9cafc6;
  font-size: 0.8rem;
  font-weight: 800;
}

.image-export-fields input,
.image-export-fields select {
  width: 100%;
  min-height: 36px;
  padding: 0 10px;
  color: #dfe7f2;
  background: #0f1724;
  border: 1px solid #33435b;
  border-radius: 7px;
  font: inherit;
}

.image-export-fields input[type="range"] {
  min-height: 24px;
  padding: 0;
}

.image-export-fields output {
  color: #dfe7f2;
  font-size: 0.82rem;
  font-weight: 850;
}

.image-export-actions {
  display: flex;
  justify-content: end;
  gap: 10px;
}

.image-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.image-stat-grid article {
  display: grid;
  gap: 6px;
  padding: 13px;
}

.image-stat-grid span {
  color: #85b7ff;
  font-size: 0.74rem;
  font-weight: 900;
}

.image-stat-grid strong {
  overflow-wrap: anywhere;
  color: #f8fbff;
  font-size: 1.08rem;
}

.image-check-card [data-image-checks],
.image-use-list {
  display: grid;
  gap: 8px;
}

.image-check-card [data-image-checks] span,
.image-use-list span {
  display: block;
  padding: 9px 10px;
  color: #cbd7e7;
  background: #0f1724;
  border: 1px solid #26344a;
  border-radius: 7px;
  font-size: 0.84rem;
  line-height: 1.38;
}

.image-check-card [data-image-checks] span.ok {
  border-color: rgba(22, 160, 133, 0.45);
}

.image-check-card [data-image-checks] span.warn {
  border-color: rgba(242, 201, 76, 0.56);
}

.image-guide-section {
  background: #fff;
}

.image-guide-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.image-guide-grid article {
  min-height: 160px;
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 24px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 16px 42px rgba(28, 82, 141, 0.07);
}

.image-guide-grid strong {
  color: var(--ink);
  font-size: 1.14rem;
}

.image-guide-grid span {
  color: var(--muted);
  line-height: 1.7;
}

@media (max-width: 1180px) {
  .image-hero,
  .image-layout {
    grid-template-columns: 1fr;
  }

  .image-layout {
    min-height: auto;
    overflow: visible;
  }

  .image-workbench {
    height: auto;
    overflow: visible;
  }

  .image-tool-rail,
  .image-controls,
  .image-preview-panel {
    grid-column: 1;
    grid-row: auto;
  }

  .image-tool-rail {
    grid-auto-flow: column;
    grid-auto-columns: 44px;
    overflow-x: auto;
  }

  .image-controls,
  .image-inspector {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .image-controls {
    display: grid;
  }

  .image-canvas-wrap canvas {
    max-height: 70vh;
  }
}

@media (max-width: 760px) {
  .image-hero {
    padding-top: 44px;
  }

  .image-hero h1 {
    font-size: 3.1rem;
  }

  .image-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .image-toolbar-group {
    overflow-x: auto;
  }

  .image-controls,
  .image-inspector,
  .image-guide-grid {
    grid-template-columns: 1fr;
  }

  .image-canvas-wrap {
    padding: 18px;
  }

  .image-field-grid,
  .image-stat-grid {
    grid-template-columns: 1fr;
  }
}
