:root {
  --wine: #5a0c25;
  --wine-deep: #2a0610;
  --red: #c41e3a;
  --gold: #fbad2a;
  --gold-deep: #d48912;
  --ink: #2a0a12;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--wine-deep);
}

body {
  color: var(--ink);
  background: var(--wine-deep);
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

.site-shell {
  background:
    radial-gradient(circle at 50% -20%, #c41e3a66, #0000 43%),
    linear-gradient(150deg, #7a1430 0%, #4a0a1c 48%, #1a040a 100%);
  min-height: 100svh;
  padding: 24px 16px 28px;
  position: relative;
  overflow: hidden;
}

.site-shell:before,
.site-shell:after {
  content: "";
  pointer-events: none;
  border: 1px solid #ffffff14;
  border-radius: 50%;
  width: 680px;
  height: 220px;
  position: absolute;
  transform: rotate(-18deg);
}

.site-shell:before {
  top: 180px;
  left: -410px;
}

.site-shell:after {
  bottom: 80px;
  right: -440px;
}

.brand-glow {
  filter: blur(80px);
  opacity: 0.22;
  pointer-events: none;
  border-radius: 50%;
  width: 240px;
  height: 240px;
  position: absolute;
}

.brand-glow-left {
  background: var(--red);
  top: 30%;
  left: -140px;
}

.brand-glow-right {
  background: var(--gold);
  bottom: 10%;
  right: -180px;
}

.editor-card {
  z-index: 1;
  background: #fffffff7;
  border: 1px solid #ffffff6b;
  border-radius: 28px;
  width: 100%;
  max-width: 540px;
  margin: 0 auto;
  padding: 22px;
  position: relative;
  box-shadow: 0 24px 70px #2a061061;
}

.editor-header {
  text-align: center;
}

.campaign-mark {
  color: var(--wine);
  letter-spacing: -0.045em;
  align-items: baseline;
  gap: 8px;
  font-weight: 1000;
  line-height: 1;
  display: inline-flex;
}

.campaign-mark span {
  font-size: 22px;
}

.campaign-mark strong {
  color: var(--red);
  font-size: 28px;
}

.eyebrow {
  color: var(--red);
  letter-spacing: 0.18em;
  margin: 15px 0 5px;
  font-size: 11px;
  font-weight: 900;
}

h1 {
  color: var(--wine);
  letter-spacing: -0.045em;
  margin: 0;
  font-size: clamp(29px, 8vw, 40px);
  line-height: 1.03;
}

.intro {
  color: #6a5860;
  max-width: 390px;
  margin: 10px auto 0;
  font-size: 14px;
  line-height: 1.45;
}

.step-row {
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  margin: 19px 0 12px;
  display: grid;
}

.step {
  color: #8b96a4;
  justify-content: center;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 800;
  display: flex;
}

.step span {
  background: #e8edf2;
  border-radius: 50%;
  place-items: center;
  width: 20px;
  height: 20px;
  font-size: 10px;
  display: grid;
}

.step.active {
  color: var(--wine);
}

.step.active span {
  color: #fff;
  background: var(--red);
}

.step.done {
  color: #8a6a10;
}

.step.done span {
  color: var(--wine);
  background: var(--gold);
}

.canvas-wrap {
  aspect-ratio: 1;
  background: #f3e8eb;
  border: 2px dashed #c5a8b0;
  border-radius: 19px;
  width: 100%;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px #ffffffb3;
}

.canvas-wrap.has-photo {
  border-style: solid;
  border-color: var(--wine);
}

canvas {
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  width: 100%;
  height: 100%;
  display: block;
}

.has-photo canvas {
  cursor: grab;
}

.has-photo canvas:active {
  cursor: grabbing;
}

.empty-action {
  width: 100%;
  color: var(--wine);
  cursor: pointer;
  background: 0 0;
  border: 0;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 7px;
  display: flex;
  position: absolute;
  inset: 0 0 39%;
}

.empty-action strong {
  font-size: clamp(14px, 4vw, 17px);
}

.empty-action small {
  color: #7b6d74;
  font-size: 11px;
}

.empty-icon {
  width: 52px;
  height: 52px;
  color: var(--wine);
  background: var(--gold);
  border-radius: 50%;
  place-items: center;
  display: grid;
  box-shadow: 0 8px 20px #d4891242;
}

.empty-icon svg {
  stroke: currentColor;
  stroke-width: 2px;
  width: 25px;
}

.drag-hint {
  color: #fff;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  pointer-events: none;
  background: #2a0610a6;
  border: 1px solid #ffffff52;
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 10px;
  font-weight: 800;
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translate(-50%);
  box-shadow: 0 5px 18px #00000029;
}

.controls {
  margin-top: 14px;
}

.file-row {
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 11px;
  font-size: 12px;
  display: flex;
}

.file-name {
  color: #647286;
  font-weight: 700;
}

.file-row button {
  color: var(--red);
  cursor: pointer;
  background: 0 0;
  border: 0;
  font-weight: 900;
}

.zoom-control {
  color: #687588;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
  font-size: 10px;
  font-weight: 800;
  display: grid;
}

.zoom-control input {
  width: 100%;
  accent-color: var(--red);
}

.button {
  cursor: pointer;
  border-radius: 14px;
  justify-content: center;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 52px;
  font-size: 14px;
  font-weight: 900;
  transition: transform 0.16s, box-shadow 0.16s, background 0.16s;
  display: flex;
}

.button:active {
  transform: translateY(1px) scale(0.995);
}

.button:disabled {
  opacity: 0.65;
  cursor: wait;
}

.button svg {
  stroke: currentColor;
  stroke-width: 2px;
  width: 21px;
}

.button-primary {
  border: 1px solid var(--gold-deep);
  color: var(--wine-deep);
  background: linear-gradient(180deg, #ffd56a 0%, var(--gold) 100%);
  box-shadow: 0 9px 22px #d489123d;
}

.button-primary:hover {
  box-shadow: 0 11px 26px #d4891252;
}

.button-secondary {
  color: var(--wine);
  background: #fff;
  border: 1px solid #e0ccd2;
  margin-top: 9px;
}

.choose-button {
  margin-top: 14px;
}

.privacy-note {
  color: #667486;
  text-align: left;
  justify-content: center;
  align-items: flex-start;
  gap: 7px;
  margin-top: 15px;
  font-size: 10px;
  line-height: 1.35;
  display: flex;
}

.privacy-note span {
  width: 16px;
  height: 16px;
  color: var(--wine);
  background: var(--gold);
  border-radius: 50%;
  flex: none;
  place-items: center;
  font-size: 9px;
  font-weight: 900;
  display: grid;
}

footer {
  z-index: 1;
  color: #fff;
  letter-spacing: 0.12em;
  justify-content: center;
  align-items: baseline;
  gap: 9px;
  margin-top: 18px;
  font-size: 10px;
  display: flex;
  position: relative;
  flex-wrap: wrap;
}

footer strong {
  color: var(--gold);
  font-size: 13px;
}

.toast {
  z-index: 10;
  color: #fff;
  text-align: center;
  background: #2a0a12;
  border-radius: 12px;
  width: max-content;
  max-width: calc(100vw - 32px);
  padding: 12px 16px;
  font-size: 12px;
  font-weight: 800;
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translate(-50%);
  box-shadow: 0 12px 34px #0000004d;
}

.sr-only {
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  position: absolute;
  overflow: hidden;
}

[hidden] {
  display: none !important;
}

@media (width >= 700px) {
  .site-shell {
    padding: 40px 24px 32px;
  }
  .editor-card {
    padding: 28px;
  }
  .intro {
    font-size: 15px;
  }
  .step {
    font-size: 12px;
  }
}

@media (width <= 370px) {
  .site-shell {
    padding: 10px;
  }
  .editor-card {
    border-radius: 22px;
    padding: 16px;
  }
  .intro {
    font-size: 12px;
  }
  .step-row {
    margin-top: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  :before,
  :after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
