@import url("https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700;800&family=Inter:wght@400;500;600;700;800&display=swap");

:root {
  --bg: #050816;
  --panel: rgba(12, 18, 39, 0.84);
  --border: rgba(255, 255, 255, 0.09);
  --text: #f8fafc;
  --muted: #96a1c2;
  --indigo: #6d5dfc;
  --violet: #a855f7;
  --shadow: 0 30px 80px rgba(2, 6, 23, 0.46);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top, rgba(109, 93, 252, 0.18), transparent 26%),
    radial-gradient(circle at 20% 10%, rgba(168, 85, 247, 0.15), transparent 18%),
    linear-gradient(180deg, #050816 0%, #091327 100%);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Geist", "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

code {
  color: #c4b5fd;
}

.shell,
.workspace-shell,
.admin-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.hidden {
  display: none !important;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.brand-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--indigo), var(--violet));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08), 0 10px 24px rgba(109, 93, 252, 0.35);
}

.workspace-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 0;
}

.workspace-header-actions,
.premium-actions,
.preview-actions,
.admin-footer-actions,
.preview-toolbar,
.workspace-meta-row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.primary-button,
.ghost-button {
  position: relative;
  border-radius: 16px;
  padding: 0.92rem 1.2rem;
  border: 1px solid transparent;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.primary-button {
  color: white;
  background: linear-gradient(135deg, var(--indigo), var(--violet));
  box-shadow: 0 12px 28px rgba(109, 93, 252, 0.34);
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-1px);
}

.ghost-button {
  color: var(--text);
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.04);
}

.large {
  padding: 1.05rem 1.45rem;
}

.small {
  padding: 0.7rem 1rem;
  font-size: 0.92rem;
}

.section-label,
.meta-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(109, 93, 252, 0.28);
  background: rgba(109, 93, 252, 0.1);
  color: #d8d4ff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-label {
  margin-bottom: 12px;
}

.paywall-card h2,
.panel-heading h2,
.admin-card h1,
.admin-card h2 {
  margin: 0;
  line-height: 1.02;
}

.workspace-subtitle,
.dropzone-copy,
.helper-text,
.workspace-note,
.modal-copy,
.status-card span,
.admin-card p {
  color: var(--muted);
  line-height: 1.7;
}

.workspace-panel,
.status-card,
.modal-card,
.admin-card,
.stat-card,
.faq-card {
  border: 1px solid var(--border);
  background: var(--panel);
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow);
}

.workspace-panel,
.admin-card,
.modal-card {
  border-radius: 28px;
}

.image-showcase {
  padding: 16px;
  position: relative;
  overflow: hidden;
  min-height: 520px;
}

.image-badge {
  position: absolute;
  top: 18px;
  left: 18px;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.8rem;
  color: #e2e8f0;
}

.image-faux {
  height: 100%;
  min-height: 488px;
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 180, 140, 0.95), rgba(100, 150, 255, 0.2)),
    linear-gradient(180deg, #eab308 0%, #082f49 100%);
  position: relative;
}

.image-faux::after {
  content: "";
  position: absolute;
  inset: auto 18px 18px auto;
  width: 96px;
  height: 96px;
  border-radius: 18px;
  background:
    linear-gradient(90deg, rgba(5, 8, 22, 0.85) 10px, transparent 10px) 0 0 / 18px 18px,
    linear-gradient(rgba(5, 8, 22, 0.85) 10px, transparent 10px) 0 0 / 18px 18px,
    rgba(255, 255, 255, 0.65);
}

.qr-mini {
  width: 74px;
  height: 74px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 24px rgba(2, 6, 23, 0.24);
}

.qr-mini.large {
  width: 96px;
  height: 96px;
}

.status-card,
.meta-pill,
.dropzone,
.alert,
.faq-card {
  border-radius: 20px;
}

.status-grid,
.stats-grid,
.admin-grid {
  display: grid;
  gap: 16px;
}

.status-card {
  padding: 18px;
}

.status-card strong {
  display: block;
  margin-bottom: 8px;
}

.paywall-price {
  font-size: clamp(3rem, 5vw, 4.2rem);
  font-weight: 800;
  color: #c4b5fd;
  margin: 8px 0;
}

.paywall-price span {
  font-size: 1rem;
  color: var(--muted);
}

.workspace-page .workspace-shell {
  width: min(1320px, calc(100% - 32px));
  padding-bottom: 34px;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(390px, 460px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.workspace-panel {
  padding: 24px;
}

.controls-panel {
  display: grid;
  align-content: start;
  gap: 18px;
}

.panel-section {
  padding: 20px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.02));
}

.panel-section + .panel-section {
  margin-top: 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.panel-heading {
  margin-bottom: 16px;
}

.panel-heading h2 {
  font-size: 1.4rem;
}

.panel-copy {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.65;
  max-width: 56ch;
}

.dropzone {
  padding: 26px 22px;
  border: 1px dashed rgba(255, 255, 255, 0.16);
  background: radial-gradient(circle at top, rgba(109, 93, 252, 0.12), rgba(255, 255, 255, 0.03) 58%);
  text-align: center;
}

.dropzone.dragover {
  border-color: rgba(109, 93, 252, 0.8);
  background: rgba(109, 93, 252, 0.1);
}

.dropzone-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 8px;
}

.file-queue {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  max-height: 220px;
  overflow: auto;
}

.file-item {
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
}

.file-item.active {
  border-color: rgba(109, 93, 252, 0.5);
  color: var(--text);
  box-shadow: inset 0 0 0 1px rgba(109, 93, 252, 0.18);
}

.segmented-control {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.segmented-button {
  border-radius: 14px;
  padding: 0.9rem 0.8rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-weight: 600;
}

.segmented-button.active {
  background: rgba(109, 93, 252, 0.15);
  border-color: rgba(109, 93, 252, 0.45);
}

.text-field {
  width: 100%;
  margin-top: 10px;
  padding: 1rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  outline: none;
}

.text-field:focus {
  border-color: rgba(109, 93, 252, 0.6);
}

.validation-text {
  min-height: 22px;
  margin: 10px 0 0;
  color: #fca5a5;
}

.qr-apply-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
}

.qr-apply-hint {
  margin: 0;
}

.slider-row {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
  grid-template-columns: 1fr auto;
  align-items: center;
}

.slider-row strong {
  justify-self: end;
}

.slider-row input[type="range"] {
  grid-column: 1 / -1;
}

input[type="range"] {
  width: 100%;
  accent-color: #8b5cf6;
}

.premium-card {
  background: linear-gradient(180deg, rgba(109, 93, 252, 0.12), rgba(255, 255, 255, 0.03));
}

.preview-panel {
  display: grid;
  gap: 18px;
  grid-template-rows: auto minmax(0, 1fr) auto auto;
}

.preview-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}

.preview-copy {
  max-width: 44ch;
}

.canvas-stage {
  position: relative;
  z-index: 1;
  min-height: 690px;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(circle at top, rgba(109, 93, 252, 0.14), transparent 34%),
    rgba(3, 7, 18, 0.9);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

#preview-canvas {
  width: 100%;
  height: auto;
  display: block;
  cursor: grab;
}

#preview-canvas.position-disabled {
  cursor: default;
}

.canvas-empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 10px;
  text-align: center;
  padding: 28px;
  color: var(--muted);
  pointer-events: none;
}

.canvas-empty p {
  margin: 0;
  font-size: 1.02rem;
  color: var(--text);
  font-weight: 600;
}

.canvas-empty span {
  max-width: 36ch;
}

.preview-toolbar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  position: relative;
  z-index: 3;
}

.workspace-note {
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(109, 93, 252, 0.08);
  border: 1px solid rgba(109, 93, 252, 0.18);
  position: relative;
  z-index: 3;
}

.primary-button.is-loading,
.ghost-button.is-loading {
  pointer-events: none;
  opacity: 0.9;
}

.primary-button.is-loading::after,
.ghost-button.is-loading::after {
  content: "";
  width: 16px;
  height: 16px;
  margin-left: 10px;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.32);
  border-top-color: rgba(255, 255, 255, 0.96);
  display: inline-block;
  vertical-align: -3px;
  animation: spin 0.8s linear infinite;
}

.paywall-card {
  max-width: 640px;
  width: min(640px, calc(100% - 28px));
  padding: 28px;
  position: relative;
  max-height: min(calc(100vh - 32px), 900px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.modal.hidden,
.toast.hidden,
.workspace-loading.hidden,
.route-loader.hidden {
  display: none;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 16px;
  overflow-y: auto;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(10px);
}

.modal-card {
  position: relative;
  z-index: 1;
}

.success-card {
  text-align: center;
  display: grid;
  gap: 14px;
  justify-items: center;
}

.success-icon {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #d8ccff;
  background: linear-gradient(180deg, rgba(122, 92, 255, 0.28), rgba(122, 92, 255, 0.12));
  border: 1px solid rgba(122, 92, 255, 0.4);
  box-shadow: 0 18px 38px rgba(91, 58, 255, 0.2);
}

.thank-you-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px 16px;
}

.thank-you-shell {
  width: min(760px, 100%);
  display: grid;
  gap: 18px;
  justify-items: center;
}

.thank-you-brand {
  align-self: center;
}

.thank-you-card {
  width: 100%;
  padding: 34px 30px;
  display: grid;
  gap: 16px;
  justify-items: center;
  text-align: center;
  background:
    radial-gradient(circle at top, rgba(122, 92, 255, 0.18), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03)),
    rgba(8, 14, 28, 0.96);
}

.thank-you-card h1 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
}

.thank-you-icon {
  width: 78px;
  height: 78px;
}

.thank-you-copy {
  margin: 0;
  max-width: 52ch;
  color: var(--text);
  line-height: 1.75;
}

.thank-you-copy strong {
  color: #ddd6fe;
}

.thank-you-copy-muted {
  color: var(--muted);
}

.thank-you-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.thank-you-highlights span {
  padding: 0.72rem 0.95rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
  color: #dbeafe;
  font-weight: 600;
}

.thank-you-actions {
  width: 100%;
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  border: 0;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: white;
  font-size: 1.3rem;
}

.paywall-benefits {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 16px;
}

.paywall-plan-selector {
  display: grid;
  gap: 10px;
  margin: 18px 0 12px;
}

.paywall-plan-option {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-radius: 18px;
  padding: 14px 16px;
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.paywall-plan-option:hover,
.paywall-plan-option.active {
  border-color: rgba(122, 92, 255, 0.42);
  background: linear-gradient(180deg, rgba(122, 92, 255, 0.14), rgba(255, 255, 255, 0.03));
  box-shadow: 0 16px 36px rgba(91, 58, 255, 0.14);
  transform: translateY(-1px);
}

.paywall-plan-top,
.paywall-plan-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.paywall-plan-top strong {
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.paywall-plan-top span {
  color: #ddd6fe;
  font-weight: 800;
}

.paywall-plan-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f5f3ff;
  background: linear-gradient(135deg, rgba(122, 92, 255, 0.95), rgba(168, 85, 247, 0.95));
  box-shadow: 0 10px 24px rgba(91, 58, 255, 0.2);
}

.paywall-plan-meta {
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.9rem;
}

.paywall-plan-note {
  margin: 0 0 8px;
  color: var(--muted);
  text-align: center;
  line-height: 1.6;
}

.paywall-benefits span,
.meta-pill.premium,
.meta-pill.success {
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.05);
  color: #dbeafe;
}

.paypal-status {
  min-height: 26px;
  color: var(--muted);
  margin-bottom: 12px;
}

.paypal-checkout-surface {
  margin-top: 12px;
  padding: 16px 14px 14px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.paypal-checkout-surface .paypal-status {
  color: #475569;
}

.paypal-surface-title {
  margin: 0 0 10px;
  color: #0f172a;
  font-weight: 800;
  letter-spacing: 0.01em;
}

#paypal-button-container {
  color: #0f172a;
}

#paypal-button-container a {
  color: #0f172a;
}

#paypal-button-container [class*="paypal"],
#paypal-button-container [data-funding-source],
#paypal-button-container [data-testid] {
  color: #0f172a;
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 60;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(12, 18, 39, 0.95);
  color: white;
  box-shadow: var(--shadow);
}

.route-loader,
.workspace-loading {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-content: center;
  gap: 14px;
  text-align: center;
  background: rgba(5, 8, 22, 0.86);
  backdrop-filter: blur(10px);
}

.spinner {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  border: 4px solid rgba(255, 255, 255, 0.12);
  border-top-color: #a78bfa;
  margin: 0 auto;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.admin-page {
  min-height: 100vh;
}

.admin-shell {
  padding: 28px 0 48px;
}

.admin-shell-wide {
  width: min(100%, 1320px);
  margin: 0 auto;
  padding-inline: 20px;
}

.hero-admin-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 24px 28px;
  margin-bottom: 18px;
}

.login-card,
.admin-card {
  padding: 24px;
}

.admin-login-wrap {
  width: min(100%, 680px);
}

.admin-login-card {
  width: min(100%, 520px);
}

.admin-login-note {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  margin-bottom: 18px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-login-note strong {
  font-size: 0.95rem;
}

.admin-login-note span {
  color: var(--muted);
}

.admin-recovery-warning {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  margin-bottom: 18px;
  border-radius: 16px;
  background: rgba(251, 191, 36, 0.09);
  border: 1px solid rgba(251, 191, 36, 0.22);
  color: #fde68a;
}

.admin-recovery-warning span {
  color: rgba(253, 230, 138, 0.88);
}

.admin-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-recovery-link {
  margin-top: 16px;
  text-align: center;
}

.auth-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr);
  gap: 18px;
}

.auth-page-center {
  background:
    radial-gradient(circle at top, rgba(122, 92, 255, 0.18), transparent 30%),
    linear-gradient(180deg, #060916 0%, #090f1f 55%, #060916 100%);
}

.auth-center-shell {
  min-height: 100vh;
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 32px 20px 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.auth-floating-brand {
  margin-bottom: 8px;
}

.auth-modal-card {
  width: min(100%, 460px);
  padding: 24px 24px 20px;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(8, 14, 28, 0.96);
  box-shadow: 0 30px 90px rgba(3, 8, 20, 0.52);
}

.auth-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.auth-modal-header h1 {
  margin: 8px 0 0;
  font-size: clamp(1.7rem, 3vw, 2.1rem);
}

.auth-close-link {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.auth-close-link:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.09);
}

.auth-side-card,
.auth-card {
  min-height: 100%;
}

.auth-side-card {
  display: grid;
  align-content: start;
  gap: 18px;
  background:
    radial-gradient(circle at top right, rgba(122, 92, 255, 0.24), transparent 40%),
    linear-gradient(180deg, rgba(122, 92, 255, 0.12), rgba(15, 23, 42, 0.92));
}

.auth-side-card h2 {
  max-width: 14ch;
}

.auth-side-points {
  display: grid;
  gap: 12px;
}

.auth-side-point {
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.auth-side-point span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-side-point strong {
  display: block;
  line-height: 1.5;
}

.auth-card {
  padding: 18px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 8px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 18px;
}

.auth-tab {
  border: 0;
  border-radius: 14px;
  padding: 0.95rem 1rem;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.auth-tab.active {
  background: linear-gradient(180deg, rgba(122, 92, 255, 0.22), rgba(122, 92, 255, 0.12));
  color: var(--text);
  box-shadow: 0 16px 32px rgba(91, 58, 255, 0.14);
}

.auth-panel {
  display: none;
  padding: 8px;
}

.auth-panel.active {
  display: block;
}

.social-auth-button {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 56px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #ffffff;
  color: #111827;
  font-weight: 700;
  cursor: not-allowed;
  opacity: 0.92;
}

.auth-google-button {
  cursor: pointer;
  opacity: 1;
}

.auth-google-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(255, 255, 255, 0.12);
}

.social-auth-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.auth-separator {
  position: relative;
  text-align: center;
  margin: 18px 0;
}

.auth-separator::before {
  content: "";
  position: absolute;
  inset: 50% 0 auto;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-separator span {
  position: relative;
  display: inline-block;
  padding: 0 12px;
  background: #0b1120;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
}

.auth-separator-light span {
  background: #0b1120;
}

.auth-form {
  gap: 14px;
}

.auth-form-compact label > span {
  display: none;
}

.auth-input-flat {
  min-height: 56px;
  margin-top: 0 !important;
  border-radius: 14px;
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.auth-input-flat::placeholder {
  color: rgba(226, 232, 240, 0.62);
}

.password-field {
  position: relative;
}

.password-field .text-field {
  padding-right: 52px;
  margin-top: 10px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.password-toggle.active,
.password-toggle:hover {
  background: rgba(122, 92, 255, 0.16);
  color: #d8ccff;
}

.auth-submit-button {
  min-height: 54px;
  margin-top: 4px;
}

.auth-inline-link {
  display: flex;
  justify-content: flex-end;
  margin-top: -2px;
}

.auth-inline-link a,
.checkbox-row a {
  color: #c4b5fd;
}

.auth-inline-link a:hover,
.checkbox-row a:hover {
  color: #ddd6fe;
}

.checkbox-row {
  display: flex !important;
  align-items: flex-start;
  gap: 12px !important;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.6;
}

.checkbox-row input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: #8b5cf6;
  flex: 0 0 auto;
}

.auth-switch-copy {
  margin: 18px 0 4px;
  text-align: center;
  color: var(--muted);
}

.auth-switch-copy a {
  color: #c4b5fd;
  font-weight: 700;
}

.admin-form {
  display: grid;
  gap: 16px;
}

.admin-form label {
  display: grid;
  gap: 8px;
}

.stats-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.admin-overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 18px;
}

.admin-tab-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.admin-tab-button {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  border-radius: 999px;
  padding: 12px 18px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.admin-tab-button:hover,
.admin-tab-button.active {
  background: linear-gradient(180deg, rgba(122, 92, 255, 0.22), rgba(122, 92, 255, 0.12));
  border-color: rgba(122, 92, 255, 0.34);
  color: var(--text);
  transform: translateY(-1px);
}

.admin-tab-panel {
  display: none;
}

.admin-tab-panel.active {
  display: block;
}

.stat-card strong {
  font-size: 2rem;
  margin-top: 10px;
  display: block;
}

.selected-plan-card {
  border-color: rgba(122, 92, 255, 0.45);
  background: linear-gradient(180deg, rgba(122, 92, 255, 0.16), rgba(15, 23, 42, 0.92));
  box-shadow: 0 24px 60px rgba(91, 58, 255, 0.14);
}

.admin-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.admin-wide-grid {
  display: grid;
  grid-template-columns: minmax(340px, 1.2fr) minmax(280px, 0.8fr);
  gap: 18px;
  margin-bottom: 18px;
}

.admin-settings-card .admin-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.admin-settings-card .admin-form button {
  grid-column: 1 / -1;
}

.admin-list-card {
  min-height: 100%;
}

.country-list {
  display: grid;
  gap: 10px;
}

.country-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-plan-grid {
  display: grid;
  gap: 16px;
}

.admin-plan-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-plan-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.admin-plan-head strong {
  display: block;
  font-size: 0.94rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.admin-plan-head span {
  color: var(--muted);
}

.admin-plan-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.admin-inline-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 600;
}

.danger-button {
  border-color: rgba(251, 113, 133, 0.3);
  color: #fecdd3;
}

.danger-button:hover {
  border-color: rgba(251, 113, 133, 0.5);
  background: rgba(251, 113, 133, 0.12);
}

.admin-plan-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.admin-field-span {
  grid-column: 1 / -1;
}

.admin-plan-textarea {
  min-height: 120px;
  resize: vertical;
}

.alert {
  padding: 14px 16px;
  margin-bottom: 16px;
}

.alert.error {
  background: rgba(251, 113, 133, 0.12);
  border: 1px solid rgba(251, 113, 133, 0.22);
  color: #fecdd3;
}

.alert.success {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.22);
  color: #bbf7d0;
}

@media (max-width: 1080px) {
  .workspace-grid,
  .admin-grid,
  .admin-wide-grid,
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .stats-grid,
  .admin-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-settings-card .admin-form {
    grid-template-columns: 1fr;
  }

  .admin-plan-fields {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1081px) {
  .preview-panel {
    position: sticky;
    top: 20px;
  }
}

@media (max-width: 760px) {
  .workspace-header,
  .hero-admin-card,
  .preview-heading {
    flex-direction: column;
    align-items: flex-start;
  }

  .status-grid,
  .stats-grid,
  .admin-overview-grid {
    grid-template-columns: 1fr;
  }

  .workspace-meta-row,
  .preview-toolbar,
  .workspace-header-actions {
    width: 100%;
  }

  .primary-button,
  .ghost-button,
  .social-auth-button {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .admin-tab-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .admin-toolbar,
  .admin-login-note,
  .admin-plan-head {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .admin-plan-actions {
    justify-content: flex-start;
  }

  .preview-toolbar {
    grid-template-columns: 1fr;
  }

  .canvas-stage {
    min-height: 420px;
  }

  .auth-card,
  .auth-panel {
    padding: 0;
  }

  .auth-center-shell {
    padding: 20px 14px 32px;
  }

  .auth-modal-card {
    width: 100%;
    padding: 20px 18px 18px;
    border-radius: 22px;
  }

  .paywall-card {
    width: min(100%, calc(100vw - 20px));
    max-height: calc(100vh - 20px);
    padding: 22px 18px;
  }

  .thank-you-card {
    padding: 26px 18px;
  }
}
