.newme-embed,
.newme-embed *,
.newme-embed *::before,
.newme-embed *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0
}

.newme-embed {
  /* newme.com.au — inline / Webflow tokens */
  --accent: #e55138;
  --accent-secondary: #4e57e0;
  --accent-warm: #ed8574;
  --text: #232323;
  --text-soft: rgba(35, 35, 35, 0.72);
  --bg-page: #f7f7f7;
  --surface: #ffffff;
  --border: #f2f2f2;
  --border-strong: #d0d0d0;
  --primary: #232323;
  --primary-hover: #1a1a1a;
  --pill-radius: 30px;
  --control-pad-y-bottom: 12px;
  --control-pad-y-top: calc(var(--control-pad-y-bottom) * 1.2);
  --pill-pad-y-bottom: 6px;
  --pill-pad-y-top: calc(var(--pill-pad-y-bottom) * 1.2);
  --radius: 16px;
  --shadow: rgba(99, 99, 99, 0.2) 0 2px 8px 0;
  --card-shadow: 0 8px 32px rgba(78, 87, 224, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
  --app-width: 1100px;
  --before-zone-bg: #fef8f7;
  --after-zone-bg: #f5f6ff;
  --page-gradient: linear-gradient(93.57deg, #f5f6ff 0.99%, #fef5f4 100%);
}

.newme-embed {
  font-family: 'Epilogue', system-ui, -apple-system, sans-serif;
  background: var(--page-gradient);
  color: var(--text);
  line-height: 1.55;
  min-height: 100vh;
  padding: 32px 20px 40px;
  -webkit-font-smoothing: antialiased;
}

html.is-embedded,
html.is-embedded body {
  background: transparent;
}

html.is-embedded .newme-embed {
  min-height: 0;
  padding: 16px;
  background: transparent;
}

html.is-embedded .newme-embed .loading-overlay {
  background: rgba(247, 247, 247, 0.92);
}

.newme-embed .container {
  max-width: var(--app-width);
  margin: 0 auto;
  width: 100%;
}

.newme-embed h1 {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: clamp(1.85rem, 4.5vw, 2.5rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 10px;
  color: var(--text);
  line-height: 1.2;
}

.newme-embed .subtitle {
  text-align: center;
  color: var(--text-soft);
  margin-bottom: 14px;
  font-size: 1.05rem;
  font-weight: 300;
  max-width: 36em;
  margin-left: auto;
  margin-right: auto;
}

.newme-embed .generate-section {
  margin-bottom: 24px;
}

.newme-embed .generate-cta {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: 18px;
}

.newme-embed .generate-cta-line {
  flex: 1;
  height: 1px;
  background: rgba(35, 35, 35, 0.14);
  min-width: 24px;
}

.newme-embed .btn-generate {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-shrink: 0;
  margin: 0 20px;
  padding: 21px 46px;
  border: 6px solid rgba(255, 255, 255, 0.84);
  border-radius: 100px;
  background: var(--accent-secondary);
  color: #fff;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: background .25s, transform .1s, opacity .2s;
  box-shadow: 0 4px 20px rgba(78, 87, 224, 0.28);
}

.newme-embed .btn-generate:hover:not(:disabled) {
  background: #434bc9;
}

.newme-embed .btn-generate:active:not(:disabled) {
  transform: scale(0.98);
}

.newme-embed .btn-generate:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  box-shadow: none;
}

.newme-embed .btn-generate-icon {
  flex-shrink: 0;
}

.newme-embed .generate-ready-text {
  text-align: center;
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 20px;
  line-height: 1.3;
}

.newme-embed .generate-section .progress-container {
  margin-top: 0;
  margin-bottom: 16px;
}

.newme-embed .privacy-note {
  text-align: center;
  color: rgba(35, 35, 35, 0.8);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  max-width: 44em;
  margin: 32px auto 0;
}

html.is-embedded .newme-embed .loading-overlay {
  background: rgba(245, 246, 255, 0.92);
}

.newme-embed .upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}

@media(max-width:720px) {
  .newme-embed .upload-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .newme-embed .generate-cta-line {
    display: none;
  }

  .newme-embed .btn-generate {
    margin: 0 auto;
    width: 100%;
    max-width: 360px;
    padding: 18px 28px;
    font-size: 17px;
  }

  .newme-embed .generate-cta {
    justify-content: center;
  }
}

.newme-embed .upload-card {
  background: var(--surface);
  border-radius: 20px;
  box-shadow: var(--card-shadow);
  padding: 20px 18px 18px;
}

.newme-embed .upload-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding-left: 4px;
}

.newme-embed .upload-card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
}

.newme-embed .upload-card-sep {
  width: 1px;
  height: 23px;
  background: rgba(35, 35, 35, 0.2);
  flex-shrink: 0;
}

.newme-embed .upload-card-subtitle {
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  line-height: 1;
}

.newme-embed .upload-zone {
  border: none;
  border-radius: 14px;
  padding: 0;
  text-align: center;
  cursor: pointer;
  transition: box-shadow .25s, background .25s;
  position: relative;
  overflow: hidden;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--before-zone-bg);
  box-shadow: none;
}

.newme-embed .upload-card--after .upload-zone {
  background: var(--after-zone-bg);
}

.newme-embed .upload-zone-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 36px 20px;
  width: 100%;
  min-height: 280px;
  border: 1px dashed rgba(78, 87, 224, 0.35);
  border-radius: 14px;
  transition: border-color .25s, background .25s;
}

.newme-embed .upload-zone:hover .upload-zone-inner,
.newme-embed .upload-zone.dragover .upload-zone-inner {
  border-color: var(--accent-secondary);
  background: rgba(255, 255, 255, 0.55);
}

.newme-embed .upload-drop-title {
  font-size: 20px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 22px;
  line-height: 1.2;
}

.newme-embed .upload-or-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  width: min(220px, 80%);
  margin-bottom: 18px;
}

.newme-embed .upload-or-divider::before,
.newme-embed .upload-or-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(35, 35, 35, 0.22);
}

.newme-embed .upload-or-divider span {
  font-size: 18px;
  font-weight: 400;
  color: rgba(35, 35, 35, 0.5);
  line-height: 1;
}

.newme-embed .upload-browse-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 176px;
  height: 44px;
  padding: 0 24px;
  border: 1px solid var(--accent-secondary);
  border-radius: 50px;
  font-size: 15px;
  font-weight: 600;
  color: var(--accent-secondary);
  background: transparent;
  pointer-events: none;
}

.newme-embed .upload-zone.has-image {
  padding: 0;
  min-height: 280px;
  cursor: default;
}

.newme-embed .upload-preview-wrap {
  display: none;
  position: relative;
  width: 100%;
  min-height: 280px;
  border-radius: 14px;
  overflow: hidden;
  background: #1a1a1a;
}

.newme-embed .upload-zone.has-image .upload-preview-wrap {
  display: block;
}

.newme-embed .upload-preview-wrap .upload-preview {
  display: block;
  position: static;
  width: 100%;
  height: 280px;
  min-height: 280px;
  object-fit: cover;
  border-radius: 0;
}

.newme-embed .upload-change-btn {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 24px;
  border: 1px solid #fff;
  border-radius: 100px;
  background: rgba(35, 35, 35, 0.52);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #fff;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition: background .2s, transform .1s;
}

.newme-embed .upload-change-btn:hover {
  background: rgba(35, 35, 35, 0.68);
}

.newme-embed .upload-change-btn:active {
  transform: scale(0.98);
}

.newme-embed .upload-change-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.newme-embed .upload-card--before .upload-change-dot {
  background: var(--accent);
}

.newme-embed .upload-card--after .upload-change-dot {
  background: var(--accent-secondary);
}

.newme-embed .upload-zone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 14px;
  min-height: 280px;
}

.newme-embed .upload-preview {
  display: none;
}

.newme-embed .upload-zone.has-image .upload-zone-inner {
  display: none;
}

.newme-embed .upload-zone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 2;
}

.newme-embed .upload-zone.has-image input {
  position: absolute;
  width: 0;
  height: 0;
  inset: auto;
  opacity: 0;
  pointer-events: none;
}

.newme-embed .upload-hint {
  font-size: 0.75rem;
  color: var(--text-soft);
  margin-top: 14px;
}

.newme-embed .error-msg {
  background: #FEF2F2;
  color: #DC2626;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  margin-bottom: 16px;
  display: none;
}

.newme-embed .error-msg.visible {
  display: block
}

.newme-embed .warning-msg {
  background: #FFFBEB;
  color: #D97706;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  margin-bottom: 16px;
  display: none;
}

.newme-embed .warning-msg.visible {
  display: block
}

.newme-embed .save-debug-panel {
  margin-top: 14px;
  padding: 14px 14px 12px;
  border-radius: var(--radius);
  background: #1a1d24;
  color: #e8eaef;
  font-size: 0.72rem;
  line-height: 1.45;
  border: 1px solid #2d3440;
  display: none;
}

.newme-embed .save-debug-panel.visible {
  display: block;
}

.newme-embed .save-debug-panel__hdr {
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #9ca3af;
  margin-bottom: 8px;
}

.newme-embed .save-debug-panel__body {
  white-space: pre-wrap;
  word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
  margin: 0 0 10px;
  max-height: 220px;
  overflow-y: auto;
}

.newme-embed .save-debug-panel .btn {
  width: auto;
  padding: calc(8px * 1.2) 16px 8px;
  font-size: 0.82rem;
}

.newme-embed .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: var(--control-pad-y-top) 28px var(--control-pad-y-bottom);
  border: none;
  border-radius: var(--pill-radius);
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .25s, color .25s, border-color .25s, transform .1s, opacity .2s;
  width: 100%;
}

.newme-embed .btn:active {
  transform: scale(0.98)
}

.newme-embed .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none
}

.newme-embed .btn-primary {
  background: var(--primary);
  color: #fff;
}

.newme-embed .btn-primary:hover:not(:disabled) {
  background: var(--primary-hover);
}

.newme-embed .btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 2px solid var(--text);
}

.newme-embed .btn-secondary:hover:not(:disabled) {
  background: var(--accent-secondary);
  border-color: var(--accent-secondary);
  color: #fff;
}

.newme-embed .effect-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
  margin-bottom: 16px;
}

.newme-embed .btn-effect {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  padding: calc(12px * 1.2) 16px 12px;
  border-radius: var(--pill-radius);
  border: 2px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: background .25s, border-color .25s, color .25s;
  width: 100%;
}

.newme-embed .btn-effect:hover:not(:disabled) {
  border-color: var(--accent);
  background: #fdf7f6;
}

.newme-embed .btn-effect:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.newme-embed .btn-effect.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.newme-embed .btn-effect.is-active:hover:not(:disabled) {
  background: #c9442e;
  border-color: #c9442e;
}

.newme-embed .progress-container {
  margin-top: 16px;
  display: none;
}

.newme-embed .progress-container.visible {
  display: block
}

.newme-embed .progress-bar {
  width: 100%;
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.newme-embed .progress-fill {
  height: 100%;
  background: var(--accent-secondary);
  border-radius: 4px;
  width: 0%;
  transition: width .3s;
}

.newme-embed .progress-text {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-soft);
  margin-top: 8px;
  font-weight: 400;
}

.newme-embed .result-section {
  display: none;
  margin: 32px 0 24px;
}

.newme-embed .result-section.visible {
  display: block;
}

.newme-embed .result-card {
  background: var(--surface);
  border-radius: 20px;
  box-shadow: var(--card-shadow);
  padding: 36px 32px 40px;
}

.newme-embed .result-title {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: clamp(2rem, 4vw, 46px);
  font-weight: 400;
  line-height: 1.2;
  color: var(--text);
  margin: 0 0 8px;
}

.newme-embed .result-subtitle {
  font-size: 20px;
  font-weight: 400;
  line-height: 1.3;
  color: rgba(35, 35, 35, 0.5);
  margin: 0 0 28px;
}

.newme-embed .transformation-preview {
  margin-bottom: 32px;
}

.newme-embed .gif-showcase {
  position: relative;
  margin: 0 auto;
  max-width: 760px;
  border-radius: 20px;
  overflow: hidden;
  background: #d9d9d9;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

@media (min-width: 721px) {
  .newme-embed .transformation-preview {
    display: flex;
    justify-content: center;
  }

  .newme-embed .gif-showcase--square {
    width: min(480px, calc(100vh - 300px), 42vw);
    max-width: min(480px, calc(100vh - 300px), 42vw);
  }

  .newme-embed .gif-showcase--square .gif-preview {
    width: 100%;
    max-height: min(480px, calc(100vh - 300px));
    object-fit: contain;
  }

  .newme-embed .gif-showcase--vertical {
    width: min(400px, calc((100vh - 300px) * 400 / 560), 32vw);
    max-width: min(400px, calc((100vh - 300px) * 400 / 560), 32vw);
  }

  .newme-embed .gif-showcase--vertical .gif-preview {
    width: 100%;
    height: auto;
    max-height: min(560px, calc(100vh - 300px));
    object-fit: contain;
  }
}

.newme-embed .gif-preview {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 0;
  object-fit: contain;
  margin: 0;
}

.newme-embed .result-settings {
  max-width: 990px;
  margin: 0 auto;
}

.newme-embed .settings-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 20px 48px;
  margin-bottom: 20px;
}

.newme-embed .settings-row .settings-block {
  margin-bottom: 0;
  flex: 0 1 auto;
}

.newme-embed .settings-block {
  margin-bottom: 20px;
}

.newme-embed .settings-label {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin: 0 0 10px;
}

.newme-embed .settings-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.newme-embed .settings-pill {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 500;
  padding: 8px 24px;
  border-radius: 100px;
  border: 1px solid #b0b4f2;
  background: transparent;
  color: #414141;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
}

.newme-embed .settings-pill:hover:not(:disabled) {
  border-color: var(--accent-secondary);
}

.newme-embed .settings-pill.is-active {
  background: #b0b4f2;
  border-color: #b0b4f2;
  color: #fff;
}

.newme-embed .settings-pill:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.newme-embed .result-divider {
  border: none;
  border-top: 1px solid rgba(35, 35, 35, 0.12);
  margin: 28px 0;
}

.newme-embed .export-story-section {
  margin-top: 4px;
}

.newme-embed .export-story-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px 24px;
  margin-bottom: 20px;
}

.newme-embed .export-story-title {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 28px;
  font-weight: 400;
  line-height: 1;
  color: var(--text);
  margin: 0 0 8px;
}

.newme-embed .export-story-lead {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.2;
  color: rgba(35, 35, 35, 0.5);
  margin: 0;
  max-width: 320px;
}

.newme-embed .export-story-header .share-row {
  margin-bottom: 0;
  flex-shrink: 0;
}

.newme-embed .share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.newme-embed .share-pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 24px;
  border-radius: 100px;
  border: 1px solid #b0b4f2;
  background: transparent;
  color: #414141;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition: background .2s, color .2s;
}

.newme-embed .share-pill:hover {
  border-color: var(--accent-secondary);
}

.newme-embed .share-pill.is-active {
  background: #b0b4f2;
  border-color: #b0b4f2;
  color: #fff;
}

.newme-embed .share-pill.is-active .share-pill-icon {
  color: #fff;
}

.newme-embed .share-pill-icon {
  flex-shrink: 0;
  color: #414141;
}

.newme-embed .format-info {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  background: #f5f5f5;
  border-radius: 8px;
  margin-bottom: 24px;
}

.newme-embed .format-info-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #414141;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  font-style: italic;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.newme-embed .format-info-text {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.35;
  color: #414141;
  margin: 0;
}

.newme-embed .download-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 12px;
}

.newme-embed .export-privacy-note {
  font-size: 14px;
  font-weight: 400;
  line-height: 1.45;
  color: rgba(35, 35, 35, 0.55);
  margin: 0 0 24px;
  max-width: 520px;
}

.newme-embed .promo-consent-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.newme-embed .promo-consent-modal.is-open {
  display: flex;
}

.newme-embed .promo-consent-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(35, 35, 35, 0.32);
  backdrop-filter: blur(2px);
}

.newme-embed .promo-consent-modal__panel {
  position: relative;
  max-width: 440px;
  width: 100%;
  background: var(--surface);
  border-radius: 20px;
  padding: 28px 26px 24px;
  box-shadow: 0 12px 40px rgba(35, 35, 35, 0.14);
  border: 1px solid rgba(35, 35, 35, 0.08);
}

.newme-embed .promo-consent-modal__title {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--text);
  margin: 0 0 8px;
  line-height: 1.25;
}

.newme-embed .promo-consent-modal__lead {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  margin: 0 0 14px;
  line-height: 1.4;
}

.newme-embed .promo-consent-modal__body {
  font-size: 0.92rem;
  line-height: 1.55;
  font-weight: 400;
  color: rgba(35, 35, 35, 0.82);
  margin: 0 0 12px;
}

.newme-embed .promo-consent-modal__note {
  font-size: 0.82rem;
  line-height: 1.45;
  font-weight: 400;
  color: rgba(35, 35, 35, 0.5);
  margin: 0 0 22px;
}

.newme-embed .promo-consent-modal__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.newme-embed .promo-consent-step[hidden] {
  display: none;
}

.newme-embed .promo-consent-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 14px;
}

.newme-embed .promo-consent-field__label {
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(35, 35, 35, 0.75);
}

.newme-embed .promo-consent-field__required,
.newme-embed .promo-consent-field__optional {
  font-weight: 400;
  color: rgba(35, 35, 35, 0.45);
  font-size: 0.78rem;
}

.newme-embed .promo-consent-field input,
.newme-embed .promo-consent-field textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  border: 1px solid rgba(35, 35, 35, 0.14);
  border-radius: 12px;
  background: #fff;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 0.95rem;
  color: var(--text);
  resize: vertical;
  transition: border-color .15s, box-shadow .15s;
}

.newme-embed .promo-consent-field input:focus,
.newme-embed .promo-consent-field textarea:focus {
  outline: none;
  border-color: var(--accent-secondary);
  box-shadow: 0 0 0 3px rgba(90, 99, 214, 0.18);
}

.newme-embed .promo-consent-field__error {
  margin: -6px 0 12px;
  font-size: 0.82rem;
  color: #b42318;
}

.newme-embed .promo-consent-field__error[hidden] {
  display: none;
}

.newme-embed .btn-promo-yes {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 14px 20px;
  border: none;
  border-radius: 100px;
  background: var(--accent-secondary);
  color: #fff;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s;
}

.newme-embed .btn-promo-yes:hover {
  background: #434bc9;
}

.newme-embed .btn-promo-no {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 20px;
  border: none;
  border-radius: 100px;
  background: transparent;
  color: rgba(35, 35, 35, 0.65);
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: color .2s, background .2s;
}

.newme-embed .btn-promo-no:hover {
  color: var(--text);
  background: rgba(35, 35, 35, 0.05);
}

.newme-embed .btn-download-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 18px 46px;
  border: none;
  border-radius: 100px;
  background: var(--accent-secondary);
  color: #fff;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: background .2s, transform .1s;
}

.newme-embed .btn-download-primary:hover:not(:disabled) {
  background: #434bc9;
}

.newme-embed .btn-download-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 18px 46px;
  border: 1px solid var(--accent-secondary);
  border-radius: 100px;
  background: transparent;
  color: var(--accent-secondary);
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: background .2s, color .2s;
}

.newme-embed .btn-download-secondary:hover:not(:disabled) {
  background: rgba(78, 87, 224, 0.06);
}

.newme-embed .btn-download-primary:active:not(:disabled),
.newme-embed .btn-download-secondary:active:not(:disabled) {
  transform: scale(0.98);
}

.newme-embed .btn-download-primary:disabled,
.newme-embed .btn-download-secondary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.newme-embed .watermark-toggle {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  cursor: pointer;
  margin-bottom: 0;
}

.newme-embed .watermark-toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.newme-embed .watermark-toggle-ui {
  flex-shrink: 0;
  width: 47px;
  height: 27px;
  border-radius: 100px;
  background: #d0d0d0;
  position: relative;
  transition: background .2s;
  margin-top: 2px;
}

.newme-embed .watermark-toggle-ui::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  transition: transform .2s;
}

.newme-embed .watermark-toggle input:checked + .watermark-toggle-ui {
  background: #b0b4f2;
}

.newme-embed .watermark-toggle input:checked + .watermark-toggle-ui::after {
  transform: translateX(20px);
}

.newme-embed .watermark-toggle-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.newme-embed .watermark-toggle-copy strong {
  font-size: 16px;
  font-weight: 600;
  color: rgba(35, 35, 35, 0.9);
  line-height: 1.2;
}

.newme-embed .watermark-toggle-copy span {
  font-size: 16px;
  font-weight: 400;
  color: rgba(35, 35, 35, 0.5);
  line-height: 1.3;
}

.newme-embed .btn-save-newme {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
  padding: 16px 32px;
  border: none;
  border-radius: 100px;
  background: var(--primary);
  color: #fff;
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s;
}

.newme-embed .btn-save-newme:hover:not(:disabled) {
  background: var(--primary-hover);
}

.newme-embed .btn-save-newme:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

@media(max-width:720px) {
  .newme-embed .result-card {
    padding: 24px 18px 28px;
  }

  .newme-embed .settings-row {
    flex-direction: column;
    gap: 20px;
  }

  .newme-embed .download-row {
    flex-direction: column;
  }

  .newme-embed .btn-download-primary,
  .newme-embed .btn-download-secondary {
    width: 100%;
    font-size: 17px;
    padding: 16px 24px;
  }

  .newme-embed .export-story-header {
    flex-direction: column;
  }

  .newme-embed .export-story-header .share-row {
    width: 100%;
  }
}

.newme-embed .consent-link {
  font-weight: 500;
  color: var(--accent-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.newme-embed .consent-link:hover {
  color: var(--accent);
}

.newme-embed .toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--text);
  color: #fff;
  padding: 14px 24px;
  border-radius: var(--pill-radius);
  font-size: 0.9rem;
  font-weight: 500;
  opacity: 0;
  transition: transform .3s, opacity .3s;
  z-index: 9999;
  max-width: min(90vw, var(--app-width));
  text-align: center;
  box-shadow: var(--shadow);
}

.newme-embed .toast.visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.newme-embed .loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(245, 246, 255, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
  flex-direction: column;
  gap: 16px;
}

.newme-embed .loading-overlay.hidden {
  display: none
}

.newme-embed .spinner {
  width: 40px;
  height: 40px;
  border: 4px solid var(--border);
  border-top-color: var(--accent-secondary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg)
  }
}

.newme-embed noscript .noscript-msg {
  text-align: center;
  padding: 40px;
  font-size: 1.1rem;
}

.newme-embed .customize-heading {
  font-family: 'Epilogue', system-ui, sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin: 0 0 14px;
}

.newme-embed .customize-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 16px;
  cursor: pointer;
  font-size: 0.9rem;
  line-height: 1.45;
  font-weight: 400;
  color: var(--text);
}

.newme-embed .customize-row input {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  accent-color: var(--accent-secondary);
  flex-shrink: 0;
}

.newme-embed .customize-lead {
  font-size: 0.88rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text-soft);
  margin: -4px 0 18px;
}

.newme-embed .result-primary-actions {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.newme-embed .result-primary-actions.share-hidden {
  grid-template-columns: 1fr 1fr;
}

@media(max-width:500px) {
  .newme-embed .result-primary-actions {
    grid-template-columns: 1fr;
  }

  .newme-embed .result-primary-actions.share-hidden {
    grid-template-columns: 1fr;
  }
}