* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  background: #f5f6f8;
  color: #1f2329;
}

.page {
  max-width: 420px;
  margin: 0 auto;
  padding: 24px 16px 40px;
}

.header {
  margin-bottom: 20px;
}

.header h1 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 600;
}

.subtitle {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: #646a73;
}

.card {
  background: #fff;
  border-radius: 16px;
  padding: 20px 16px;
  box-shadow: 0 8px 24px rgba(31, 35, 41, 0.06);
}

.field-label {
  display: block;
  margin: 16px 0 8px;
  font-size: 14px;
  color: #646a73;
}

.field-label:first-of-type {
  margin-top: 0;
}

.required {
  color: #d44085;
}

.select-input,
.text-input,
#telInput {
  width: 100%;
  height: 44px;
  border: 1px solid #e5e6eb;
  border-radius: 10px;
  padding: 0 12px;
  font-size: 16px;
  outline: none;
}

.select-input:focus,
.text-input:focus,
#telInput:focus {
  border-color: #d44085;
}

.picker-area {
  text-align: center;
  padding: 12px 0;
}

.pick-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pick-btn {
  width: 100%;
  height: 44px;
  border: 1px dashed #d44085;
  border-radius: 10px;
  background: #fff7fb;
  color: #d44085;
  font-size: 15px;
  cursor: pointer;
}

.pick-btn-secondary {
  border-style: solid;
  border-color: #e5e6eb;
  background: #fff;
  color: #1f2329;
}

.hint {
  margin: 8px 0 0;
  font-size: 12px;
  color: #8f959e;
}

.field-error {
  margin: 6px 0 0;
  font-size: 12px;
  line-height: 1.5;
  color: #d83931;
}

.preview-wrap {
  margin-top: 12px;
  text-align: center;
}

.crop-viewport-shell,
.preview-photo-shell {
  max-width: 360px;
  margin: 0 auto;
  padding: 1mm;
  background: #000;
}

.preview-photo-shell {
  display: inline-block;
  max-width: min(360px, 100%);
}

.crop-viewport,
.preview-photo-stage {
  width: 100%;
  overflow: hidden;
  position: relative;
  background: #fff;
  box-shadow: inset 0 0 0 1mm #000;
}

.preview-photo-stage {
  max-width: 360px;
  max-height: 280px;
  margin: 0 auto;
}

.preview-photo-stage img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.text-btn {
  margin-top: 8px;
  border: none;
  background: none;
  color: #d44085;
  font-size: 14px;
  cursor: pointer;
}

.submit-btn {
  width: 100%;
  margin-top: 20px;
  height: 48px;
  border: none;
  border-radius: 12px;
  background: #d44085;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
}

.submit-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.submit-btn.secondary {
  background: #e78cb6;
}

.upload-notices {
  margin: 14px 0 0;
  padding-left: 1.2em;
  font-size: 12px;
  line-height: 1.65;
  color: #8f959e;
  text-align: left;
}

.upload-notices li + li {
  margin-top: 8px;
}

.status {
  min-height: 20px;
  margin: 12px 0 0;
  font-size: 13px;
  color: #8f959e;
  text-align: center;
}

.status.error {
  color: #d83931;
}

.status.loading {
  color: #d44085;
}

.hidden {
  display: none !important;
}

.success-panel {
  text-align: center;
}

.success-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: #e8f7ee;
  color: #2ea043;
  font-size: 28px;
  line-height: 56px;
}

.success-panel h2 {
  margin: 0 0 8px;
  font-size: 20px;
}

.success-tel {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 600;
  color: #d44085;
}

.error-panel h2 {
  margin: 0 0 8px;
  font-size: 18px;
  color: #cf222e;
}

.crop-hint {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fff7fb;
  border: 1px solid #f0c4d8;
  font-size: 14px;
  color: #d44085;
  text-align: center;
}

.crop-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  touch-action: none;
}

.crop-panel {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
}

.crop-header {
  padding: 16px 16px 8px;
}

.crop-header h2 {
  margin: 0 0 6px;
  font-size: 18px;
}

.crop-tip {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: #646a73;
}

.crop-viewport-wrap {
  padding: 0 16px 16px;
}

.crop-zoom-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 16px 12px;
}

.crop-zoom-btn,
.crop-rotate-btn {
  width: 44px;
  height: 44px;
  border: 1px solid #e5e6eb;
  border-radius: 50%;
  background: #fff;
  color: #d44085;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.crop-rotate-btn {
  font-size: 22px;
}

.crop-zoom-label {
  min-width: 56px;
  text-align: center;
  font-size: 14px;
  color: #646a73;
}

.crop-viewport {
  touch-action: none;
  user-select: none;
}

.crop-viewport img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform-origin: center center;
  max-width: none;
  max-height: none;
  pointer-events: none;
  z-index: 1;
}

.crop-actions {
  display: flex;
  gap: 12px;
  padding: 0 16px 16px;
}

.crop-btn {
  flex: 1;
  height: 44px;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  cursor: pointer;
}

.crop-btn-secondary {
  background: #f2f3f5;
  color: #1f2329;
}

.crop-btn-primary {
  background: #d44085;
  color: #fff;
}

.crop-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
