.resize-hero {
  background: #13211d;
}

.resize-workspace {
  background: #eef2f0;
}

.resize-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(360px, 1.18fr);
  gap: 18px;
  align-items: start;
}

.resize-controls,
.resize-preview-card {
  min-width: 0;
}

.resize-drop-zone {
  display: grid;
  min-height: 170px;
  place-items: center;
  align-content: center;
  gap: 7px;
  margin: 24px 0 14px;
  padding: 24px;
  border: 1px dashed #93a39d;
  border-radius: 8px;
  background: #f8faf9;
  text-align: center;
  cursor: pointer;
}

.resize-drop-zone:hover,
.resize-drop-zone:focus-within,
.resize-drop-zone.is-dragover {
  border-color: var(--teal);
  background: #eaf6f2;
}

.resize-drop-zone input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.resize-drop-zone > span:last-of-type {
  color: var(--muted);
  font-size: 13px;
}

.resize-drop-symbol {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 50%;
  background: var(--teal);
  color: #ffffff;
  font-size: 28px;
  line-height: 1;
}

.resize-presets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 20px;
}

.resize-presets button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.resize-presets button:hover:not(:disabled) {
  border-color: var(--teal);
  color: var(--teal);
}

.resize-presets button:disabled {
  opacity: 0.42;
  cursor: default;
}

.resize-dimensions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 10px;
  align-items: end;
}

.resize-dimensions label span {
  color: var(--muted);
  font-size: 12px;
}

.resize-lock {
  display: grid;
  min-width: 58px;
  min-height: 48px;
  place-items: center;
  align-content: center;
  gap: 0;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--muted);
  font: inherit;
  font-size: 10px;
  font-weight: 900;
  cursor: pointer;
}

.resize-lock > span:first-child {
  font-size: 18px;
  line-height: 1;
}

.resize-lock.is-locked {
  border-color: var(--teal);
  background: #eaf6f2;
  color: var(--teal-deep);
}

.resize-preview-shell {
  display: grid;
  min-height: 420px;
  place-items: center;
  margin: 24px 0 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background-color: #f8faf9;
  background-image:
    linear-gradient(45deg, #e6ebe9 25%, transparent 25%),
    linear-gradient(-45deg, #e6ebe9 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #e6ebe9 75%),
    linear-gradient(-45deg, transparent 75%, #e6ebe9 75%);
  background-position: 0 0, 0 10px, 10px -10px, -10px 0;
  background-size: 20px 20px;
}

.resize-preview-shell img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 560px;
  object-fit: contain;
}

.resize-empty {
  display: grid;
  place-items: center;
  gap: 8px;
  padding: 28px;
  text-align: center;
}

.resize-empty strong {
  color: var(--teal);
  font-size: 28px;
  letter-spacing: 0;
}

.resize-empty span {
  color: var(--muted);
}

.resize-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}

.resize-metrics article {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
}

.resize-metrics span,
.resize-metrics strong,
.resize-metrics small {
  display: block;
}

.resize-metrics span,
.resize-metrics small {
  color: var(--muted);
  font-size: 12px;
}

.resize-metrics strong {
  margin: 5px 0 2px;
  overflow: hidden;
  font-size: 17px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.resize-preview-card > .button {
  width: 100%;
}

@media (max-width: 980px) {
  .resize-layout { grid-template-columns: 1fr; }
  .resize-preview-shell { min-height: 360px; }
}

@media (max-width: 560px) {
  .resize-dimensions { grid-template-columns: 1fr 54px 1fr; gap: 7px; }
  .resize-lock { min-width: 50px; }
  .resize-preview-shell { min-height: 280px; }
  .resize-metrics { grid-template-columns: 1fr; }
}
