/* Sosed Service paywall — mobile-first, dark theme.
   Brand accent: #3ddc97. */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: #0e0e10;
  color: #f5f5f7;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter",
               "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
  min-height: 100%;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  /* radial accent in the corner */
  background:
    radial-gradient(1200px 600px at 100% -10%, rgba(61, 220, 151, 0.08), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(61, 220, 151, 0.05), transparent 60%),
    #0e0e10;
}

a {
  color: #3ddc97;
  text-decoration: underline;
  text-decoration-color: rgba(61, 220, 151, 0.4);
  text-underline-offset: 3px;
}
a:hover, a:focus { text-decoration-color: #3ddc97; }

.container {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
  flex: 1;
}

.view {
  animation: fade-in 0.25s ease;
}

@keyframes fade-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: none; }
}

/* --- HERO --- */
.hero {
  text-align: center;
  margin: 2rem 0 1.5rem;
}
.hero-compact { margin: 1rem 0 1.25rem; }
.logo {
  display: inline-block;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 0.85rem;
  color: #3ddc97;
  background: rgba(61, 220, 151, 0.08);
  border: 1px solid rgba(61, 220, 151, 0.25);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
  text-transform: uppercase;
}
.hero-title {
  font-size: 1.55rem;
  line-height: 1.25;
  margin: 0 0 0.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.hero-subtitle {
  margin: 0;
  color: #b8b8be;
  font-size: 1rem;
}

/* --- FEATURES --- */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.75rem;
}
.feature-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 1rem;
}
.feature-list li:last-child { border-bottom: 0; }
.check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(61, 220, 151, 0.15);
  color: #3ddc97;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}

/* --- BUTTONS --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 56px;
  padding: 0 1.25rem;
  font-size: 1.05rem;
  font-weight: 600;
  border: 1px solid transparent;
  border-radius: 14px;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.05s ease, background 0.15s ease, opacity 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:active:not(:disabled) { transform: scale(0.98); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.btn:focus-visible {
  outline: 2px solid #3ddc97;
  outline-offset: 2px;
}

.btn-primary {
  background: #3ddc97;
  color: #06281b;
  border-color: #3ddc97;
}
.btn-primary:hover:not(:disabled) { background: #4eeaa6; }

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: #f5f5f7;
  border-color: rgba(255, 255, 255, 0.12);
  min-height: 44px;
  font-size: 0.95rem;
  width: auto;
  padding: 0 1rem;
}
.btn-secondary:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.1);
}

.btn-cta { margin-bottom: 1rem; font-size: 1.1rem; }

/* --- FORM --- */
.purchase-form {
  margin-top: 0.75rem;
  padding: 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
}
.field {
  margin-bottom: 1rem;
}
.field label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
  color: #b8b8be;
}
.field input[type="email"],
.field input[type="text"] {
  width: 100%;
  min-height: 48px;
  padding: 0 0.9rem;
  font-size: 1rem;
  font-family: inherit;
  color: #f5f5f7;
  background: #1a1a1d;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  transition: border-color 0.15s ease;
}
.field input:focus {
  outline: none;
  border-color: #3ddc97;
  box-shadow: 0 0 0 3px rgba(61, 220, 151, 0.15);
}
.field-checkbox label {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.95rem;
  color: #d8d8dc;
  margin: 0;
  cursor: pointer;
}
.field-checkbox input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin: 2px 0 0;
  flex-shrink: 0;
  accent-color: #3ddc97;
  cursor: pointer;
}
.field-error {
  margin-top: 0.4rem;
  font-size: 0.85rem;
  color: #ff6b6b;
  min-height: 1.1em;
}
.field-error:empty { min-height: 0; margin: 0; }

.form-error {
  margin-top: 0.75rem;
  padding: 0.75rem;
  font-size: 0.9rem;
  color: #ffb8b8;
  background: rgba(255, 80, 80, 0.08);
  border: 1px solid rgba(255, 80, 80, 0.25);
  border-radius: 10px;
}
.form-error:empty { display: none; }

.legal-note {
  margin: 1rem 0 0;
  font-size: 0.8rem;
  color: #82828a;
  text-align: center;
}

/* --- SPINNERS --- */
.spinner {
  display: inline-block;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: #3ddc97;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.spinner-sm { width: 16px; height: 16px; }
.spinner-lg { width: 48px; height: 48px; border-width: 3px; }

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

/* --- PROCESSING VIEW --- */
.processing-wrap {
  margin-top: 4rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}
.processing-wrap h2 {
  font-size: 1.3rem;
  margin: 0;
}
.muted { color: #b8b8be; }

/* --- ACCOUNT VIEW --- */
.badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
}
.badge-success {
  background: rgba(61, 220, 151, 0.12);
  color: #3ddc97;
}
.badge-warn {
  background: rgba(255, 180, 60, 0.12);
  color: #ffb43c;
}

.card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}
.card h3 {
  margin: 0 0 0.6rem;
  font-size: 1.05rem;
  font-weight: 600;
}
.card p { margin: 0.4rem 0; }

.store-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}
.store-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 0.9rem;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: #f5f5f7;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: background 0.15s ease;
}
.store-link:hover { background: rgba(255, 255, 255, 0.1); }

.qr-wrap {
  margin: 1rem auto 0;
  padding: 0.75rem;
  background: #ffffff;
  border-radius: 12px;
  display: inline-flex;
  width: 100%;
  max-width: 280px;
  align-items: center;
  justify-content: center;
}
#qr-canvas {
  width: 100% !important;
  height: auto !important;
  max-width: 256px;
  display: block;
  image-rendering: pixelated;
}

.copy-row {
  display: flex;
  gap: 0.5rem;
  align-items: stretch;
  margin-top: 0.5rem;
}
#sub-url {
  flex: 1;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.78rem;
  letter-spacing: -0.01em;
}
#btn-copy { flex-shrink: 0; }

.copy-feedback {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: #3ddc97;
  min-height: 1em;
}
.copy-feedback:empty { min-height: 0; }

/* --- FOOTER --- */
.footer {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
  font-size: 0.85rem;
  color: #82828a;
}
.footer a { color: #b8b8be; text-decoration: none; }
.footer a:hover { color: #3ddc97; }

/* --- NOSCRIPT --- */
.noscript-banner {
  background: rgba(255, 180, 60, 0.1);
  color: #ffd086;
  border-bottom: 1px solid rgba(255, 180, 60, 0.25);
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  text-align: center;
}

/* --- LEGAL DOC PAGES --- */
.doc-page {
  max-width: 720px;
  padding-top: 2.5rem;
}
.doc-page h1 {
  font-size: 1.6rem;
  margin: 0 0 1rem;
}
.doc-page h2 {
  font-size: 1.15rem;
  margin: 1.5rem 0 0.5rem;
}
.doc-page p { color: #c8c8cc; }

/* --- DESKTOP TWEAKS --- */
@media (min-width: 600px) {
  .container { padding-top: 3rem; }
  .hero-title { font-size: 1.85rem; }
  .hero-subtitle { font-size: 1.05rem; }
}

/* --- REDUCED MOTION --- */
@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
