/* Modern Stripe-inspired styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --stripe-purple: #635bff;
  --stripe-purple-dark: #4c44db;
  --stripe-purple-light: #f6f9fc;
  --stripe-gray-900: #0a2540;
  --stripe-gray-800: #1a365d;
  --stripe-gray-600: #425466;
  --stripe-gray-500: #6b7c93;
  --stripe-gray-400: #8792a2;
  --stripe-gray-200: #e3e8ee;
  --stripe-gray-100: #f6f9fc;
  --stripe-green: #00d924;
  --stripe-red: #df1b41;
  --stripe-orange: #ff5722;
}

.text-primary-purple {
  color: var(--stripe-purple);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--stripe-gray-900);
  line-height: 1.6;
}

/* Typography */
h1 {
  font-size: 3.5rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--stripe-gray-900);
  margin-bottom: 1.5rem;
}

h2 {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--stripe-gray-900);
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--stripe-gray-900);
  margin-bottom: 0.5rem;
}

p {
  font-size: 1.125rem;
  color: var(--stripe-gray-600);
  margin-bottom: 1rem;
}

/* Sticky Header */
.sticky-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  background-color: var(--stripe-gray-100);
  border-bottom: 1px solid var(--stripe-gray-200);
  z-index: 9999;
  transition: transform 0.3s ease, height 0.3s ease;
  width: 100%;
  height: auto;
  overflow: hidden;
}

.sticky-header.hidden {
  transform: translateY(-100%);
}

.header-content {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.5rem 0.5rem 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
  transition: padding 0.3s ease;
}

.header-brand {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  flex-shrink: 0;
}

.header-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.header-nav-link {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--stripe-gray-600);
  text-decoration: none;
  transition: color 0.2s ease;
}

.header-nav-link:hover {
  color: var(--stripe-purple);
}

.header-nav-link--active {
  color: var(--stripe-purple);
}

.header-nav-feedback {
  padding: 0.4rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--stripe-purple);
  background: transparent;
  border: 2px solid var(--stripe-purple);
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease, transform 0.2s ease;
}

.header-nav-feedback:hover {
  background: rgba(99, 91, 255, 0.08);
}

.feature-feedback-textarea {
  min-height: 140px;
  resize: vertical;
}

.feature-feedback-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 2rem;
  height: 2rem;
  border: none;
  background: var(--stripe-gray-100);
  border-radius: 8px;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  color: var(--stripe-gray-600);
}

.feature-feedback-close:hover {
  background: var(--stripe-gray-200);
  color: var(--stripe-gray-900);
}

.feature-feedback-card {
  position: relative;
  max-width: 520px;
}

.feature-feedback-title {
  font-size: 1.35rem;
  margin-bottom: 0.5rem;
  padding-right: 2rem;
  line-height: 1.3;
}

.feature-feedback-intro {
  font-size: 0.95rem;
  color: var(--stripe-gray-600);
  margin-bottom: 1rem;
}

.feature-feedback-label {
  display: block;
  margin-top: 1rem;
  margin-bottom: 0.35rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--stripe-gray-800);
}

@media (max-width: 767px) {
  .header-brand {
    justify-content: center;
    width: 100%;
  }

  .header-nav {
    justify-content: center;
    width: 100%;
  }
}

/* Header without form visible - compact */
.sticky-header:not(.form-visible) .header-content {
  padding-bottom: 1rem;
}

.sticky-header:not(.form-visible) .header-form {
  height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

/* Header with form visible - expanded */
.sticky-header.form-visible .header-content {
  padding-bottom: 1rem;
}

.sticky-header.form-visible .header-form {
  margin-top: 0.75rem;
  height: auto;
}

@media (min-width: 768px) {
  .header-content {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
  }
  
  .header-brand {
    margin-bottom: 0;
    flex: 1;
    min-width: 0;
  }
  
  .sticky-header:not(.form-visible) .header-content,
  .sticky-header.form-visible .header-content {
    padding: 1rem 1.5rem;
  }
  
  .sticky-header:not(.form-visible) .header-form,
  .sticky-header.form-visible .header-form {
    height: auto;
    margin: 0;
    overflow: visible;
  }
}

.header-logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--stripe-gray-900);
  text-decoration: none;
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
}

.header-logo:hover {
  color: var(--stripe-purple);
}

.header-logo-img {
  height: 32px;
  width: auto;
  transition: opacity 0.2s ease;
}

.header-logo:hover .header-logo-img {
  opacity: 0.8;
}

.header-cta {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  background: var(--stripe-purple);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.header-cta:hover {
  background: var(--stripe-purple-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99, 91, 255, 0.3);
}

/* Header Form Styles */
.header-form {
  opacity: 0;
  transform: translateX(20px);
  transition: all 0.3s ease;
  pointer-events: none;
}

.header-form.visible {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.header-form-inner {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
  width: 100%;
}

.header-email-input {
  padding: 0.5rem 0.75rem;
  font-size: 16px; /* Prevent mobile zoom by using 16px minimum */
  border: 2px solid var(--stripe-gray-400);
  border-radius: 6px;
  flex: 1;
  min-width: 200px;
  transition: all 0.2s ease;
  background: white;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

@media (min-width: 768px) {
  .header-form-inner {
    width: auto;
  }
  
  .header-email-input {
    width: 300px;
    flex: none;
  }
}

.header-email-input:focus {
  outline: none;
  border-color: var(--stripe-purple);
  box-shadow: 0 0 0 3px rgba(99, 91, 255, 0.15), 0 1px 3px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

.header-email-input:hover:not(:focus) {
  border-color: var(--stripe-gray-500);
}

.header-submit-btn {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  background: var(--stripe-purple);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.header-submit-btn:hover {
  background: var(--stripe-purple-dark);
  transform: translateY(-1px);
}

.header-submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Removed default CTA styles - no longer needed */

/* Add top padding to body to account for the fixed announcement and header. */
body {
  padding-top: calc(
    var(--site-header-height, 65px) + var(--announcement-banner-height, 0px)
  );
}

/* Layout utilities */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 640px) {
  .container {
    padding: 0 1.5rem;
  }
}

.hero-section {
  background: linear-gradient(135deg, var(--stripe-purple-light) 0%, #ffffff 100%);
  padding: 6rem 0;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23635bff' fill-opacity='0.05'%3E%3Ccircle cx='9' cy='9' r='2'/%3E%3Ccircle cx='51' cy='9' r='2'/%3E%3Ccircle cx='9' cy='51' r='2'/%3E%3Ccircle cx='51' cy='51' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.section {
  padding: 5rem 0;
}

.section-gray {
  background-color: var(--stripe-gray-100);
}

/* Button styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

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

.btn-primary {
  background: linear-gradient(135deg, var(--stripe-purple) 0%, var(--stripe-purple-dark) 100%);
  color: white;
  box-shadow: 0 4px 14px 0 rgba(99, 91, 255, 0.25);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px 0 rgba(99, 91, 255, 0.4);
}

.btn-secondary {
  background: white;
  color: var(--stripe-purple);
  border: 2px solid var(--stripe-purple);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-secondary:hover {
  background: var(--stripe-purple-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Form styles */
.form-group {
  margin-bottom: 1.5rem;
}

.form-input {
  width: 100%;
  padding: 1rem 1.25rem;
  font-size: 1rem;
  border: 2px solid var(--stripe-gray-200);
  border-radius: 8px;
  background: white;
  transition: all 0.2s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--stripe-purple);
  box-shadow: 0 0 0 3px rgba(99, 91, 255, 0.1);
}

.form-flex {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
  max-width: 800px; 
  margin: 0 auto;
}

/* Grid layouts */
.grid-1 { display: grid; grid-template-columns: 1fr; gap: 2rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .form-flex { flex-direction: column; }
  h1 { font-size: 2rem; }
  .hero-section { padding: 4rem 0; }

  .container {
    padding: 0 1rem;
  }
  
  /* Mobile header adjustments */
  .header-content {
    padding: 0.75rem 1rem;
  }
  
  .header-logo {
    font-size: 1.125rem;
  }
  
  .header-cta {
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
  }
  
  /* Mobile header form */
  .header-email-input {
    width: 160px;
    font-size: 16px; /* Prevent mobile zoom by using 16px minimum */
    padding: 0.4rem 0.6rem;
    border-width: 2px;
  }
  
  .header-submit-btn {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
  }
  
  .header-form-inner {
    gap: 0.4rem;
  }
  
  body {
    padding-top: calc(
      var(--site-header-height, 65px) + var(--announcement-banner-height, 0px)
    );
  }
}

/* Card styles */
.card {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
  transition: all 0.2s ease;
  border: 1px solid var(--stripe-gray-200);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-color: var(--stripe-purple);
}

.card h3 {
  color: var(--stripe-gray-900);
  margin-bottom: 0.75rem;
}

.card p {
  color: var(--stripe-gray-600);
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

.card-link {
  color: var(--stripe-purple);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  transition: color 0.2s ease;
}

.card-link:hover {
  color: var(--stripe-purple-dark);
}

/* Step indicators */
.step-indicator {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, var(--stripe-purple-light) 0%, rgba(99, 91, 255, 0.1) 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--stripe-purple);
}

/* FAQ Styles */
.faq-item {
  background: white;
  border-radius: 8px;
  border: 1px solid var(--stripe-gray-200);
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  padding: 1.5rem;
  background: none;
  border: none;
  text-align: left;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--stripe-gray-900);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background-color 0.2s ease;
}

.faq-question:hover {
  background-color: var(--stripe-gray-100);
}

.faq-icon {
  font-size: 1.5rem;
  color: var(--stripe-purple);
  transition: transform 0.2s ease;
  font-weight: 300;
}

.faq-content {
  color: var(--stripe-gray-600);
  display: none;
  padding: 1rem 1.5rem 1rem;
}

.faq-content.active {
  display: block;
  animation: slideDown 0.3s ease;
}

.faq-content p {
  font-size: 1.125rem;
  line-height: 1.6;
  margin: 0;
}

.faq-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
  font-weight: 600;
  padding: 0.15em 0.4em;
  border-radius: 4px;
  background: var(--stripe-gray-100);
  color: var(--stripe-gray-900);
  border: 1px solid var(--stripe-gray-200);
  white-space: nowrap;
}

.faq-content a.card-link {
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  display: inline;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Code blocks */
.code-block {
  background: var(--stripe-gray-900);
  color: #ffffff;
  padding: 1.5rem;
  border-radius: 8px;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  font-size: 0.875rem;
  line-height: 1.4;
  overflow-x: auto;
  margin: 1.5rem 0;
}

.code-block .comment {
  color: var(--stripe-gray-400);
  font-style: italic;
}

/* Footer CTA */
.footer-cta {
  background: linear-gradient(135deg, var(--stripe-purple) 0%, var(--stripe-purple-dark) 100%);
  color: white;
  padding: 4rem 0;
  text-align: center;
}

.footer-cta h2 {
  color: white;
  margin-bottom: 0.5rem;
}

.footer-cta p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2rem;
}

.footer-cta .btn-secondary {
  background: white;
  color: var(--stripe-purple);
  border: none;
}

.footer-cta .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.95);
  transform: translateY(-1px);
}

/* Footer Navigation */
.footer-nav {
  background: var(--stripe-gray-800);
  color: white;
  padding: 4rem 0 2rem;
}

.footer-nav h3 {
  color: white;
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin-bottom: 0.5rem;
}

.footer-nav a {
  color: var(--stripe-gray-400);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s ease;
  display: block;
  padding: 0.25rem 0;
}

.footer-nav a:hover {
  color: white;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* Footer */
.footer {
  background: var(--stripe-gray-900);
  padding: 2rem 0;
  text-align: center;
  border-top: 1px solid var(--stripe-gray-600);
}

.footer .container.flex {
  text-align: left;
}

.footer p {
  color: var(--stripe-gray-500);
  font-size: 0.875rem;
  margin: 0;
}

/* Toast notifications (above webform overlay at 10050) */
.toast {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  color: white;
  font-weight: 600;
  z-index: 10100;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  max-width: 350px;
}

.toast.show {
  transform: translateX(0);
}

.toast.success {
  background: var(--stripe-green);
}

.toast.error {
  background: var(--stripe-red);
}

.toast.info {
  background: var(--stripe-purple);
}

@media (max-width: 768px) {
  .toast {
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
    max-width: none;
    transform: translateY(100%);
  }
  
  .toast.show {
    transform: translateY(0);
  }
}

/* Text utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-sm { font-size: 0.875rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }

.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }

.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-16 { margin-bottom: 4rem; }

.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }

.mx-auto { margin-left: auto; margin-right: auto; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-out;
}

/* Loading states */
.loading {
  opacity: 0.6;
  pointer-events: none;
  position: relative;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid var(--stripe-purple);
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Post-signup webform (Alyssa) */
.webform-overlay {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(10, 37, 64, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: webformOverlayIn 0.35s ease-out;
}

@keyframes webformOverlayIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.webform-card {
  width: 100%;
  max-width: 480px;
  max-height: min(90vh, 720px);
  overflow-y: auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 48px rgba(10, 37, 64, 0.18), 0 0 0 1px var(--stripe-gray-200);
  padding: 1.5rem 1.5rem 1.25rem;
  animation: webformCardIn 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes webformCardIn {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.webform-header {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  margin-bottom: 1rem;
}

.webform-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--stripe-gray-200);
  box-shadow: 0 2px 8px rgba(99, 91, 255, 0.15);
}

.webform-from {
  flex: 1;
  min-width: 0;
}

.webform-name {
  font-weight: 700;
  font-size: 1rem;
  color: var(--stripe-gray-900);
  margin-bottom: 0.25rem;
}

.webform-bubble {
  position: relative;
  background: var(--stripe-gray-100);
  border-radius: 12px 12px 12px 4px;
  padding: 0.875rem 1rem;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--stripe-gray-800);
  border: 1px solid var(--stripe-gray-200);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.webform-bubble.webform-bubble--visible {
  opacity: 1;
  transform: translateY(0);
}

.webform-bubble p {
  font-size: 0.9375rem;
  margin-bottom: 0.65rem;
  color: var(--stripe-gray-800);
}

.webform-bubble p:last-child {
  margin-bottom: 0;
}

.webform-bubble .webform-signoff {
  margin-top: 0.75rem;
  margin-bottom: 0;
  font-weight: 500;
  color: var(--stripe-gray-600);
}

.webform-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1rem;
}

.webform-option {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.75rem 0.85rem;
  border-radius: 10px;
  border: 2px solid var(--stripe-gray-200);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.webform-option:hover {
  border-color: var(--stripe-purple);
  background: var(--stripe-purple-light);
}

.webform-option:has(input:checked) {
  border-color: var(--stripe-purple);
  background: rgba(99, 91, 255, 0.06);
  box-shadow: 0 0 0 3px rgba(99, 91, 255, 0.12);
}

.webform-option input[type="radio"] {
  margin-top: 0.2rem;
  accent-color: var(--stripe-purple);
  flex-shrink: 0;
}

.webform-option-text {
  font-size: 0.9375rem;
  color: var(--stripe-gray-900);
  line-height: 1.45;
}

.webform-other-wrap {
  margin-top: 0.5rem;
  margin-left: 1.75rem;
  display: none;
}

.webform-other-wrap.webform-other-wrap--open {
  display: block;
  animation: fadeIn 0.25s ease;
}

.webform-text-input {
  width: 100%;
  padding: 0.65rem 0.85rem;
  font-size: 16px;
  border: 2px solid var(--stripe-gray-200);
  border-radius: 8px;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.webform-text-input:focus {
  outline: none;
  border-color: var(--stripe-purple);
  box-shadow: 0 0 0 3px rgba(99, 91, 255, 0.1);
}

.webform-inline-error {
  display: none;
  margin-top: 0.75rem;
  padding: 0.65rem 0.85rem;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.45;
  color: #fff;
  background: var(--stripe-red);
  border-radius: 8px;
}

.webform-inline-error.webform-inline-error--visible {
  display: block;
}

.webform-actions {
  margin-top: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.webform-submit {
  width: 100%;
  padding: 0.875rem 1.25rem;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, var(--stripe-purple) 0%, var(--stripe-purple-dark) 100%);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(99, 91, 255, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.webform-submit:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(99, 91, 255, 0.35);
}

.webform-submit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.webform-hint {
  font-size: 0.8125rem;
  color: var(--stripe-gray-500);
  text-align: center;
}

@media (max-width: 768px) {
  .webform-card {
    padding: 1.25rem 1rem 1rem;
    border-radius: 14px;
  }

  .webform-avatar {
    width: 48px;
    height: 48px;
  }
}

@supports not selector(:has(*)) {
  .webform-option.webform-option--selected {
    border-color: var(--stripe-purple);
    background: rgba(99, 91, 255, 0.06);
  }
}

/* --- Bulk upload (CSV → Stripe) --- */
/* Vertical padding comes from parent .section; height follows content (no fixed viewport floor). */
.bulk-upload {
  padding: 0;
}

.bulk-upload h1 {
  font-size: 2.25rem;
  margin-bottom: 0.5rem;
}

.bulk-upload__lead {
  font-size: 1.0625rem;
  color: var(--stripe-gray-600);
  max-width: 42rem;
  margin-bottom: 2rem;
  line-height: 1.55;
}

.bulk-upload__back {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.bulk-upload__back a {
  color: var(--stripe-purple);
  text-decoration: none;
}

.bulk-upload__back a:hover {
  text-decoration: underline;
}

.bulk-step__hint {
  color: var(--stripe-gray-600);
  font-size: 1rem;
  line-height: 1.5;
  /* max-width: 40rem; */
}

.bulk-col-row {
  margin: 0.25rem 0;
}

.bulk-col-opt {
  color: var(--stripe-gray-400);
  font-size: 0.8125rem;
}

.bulk-api-field__intro {
  font-size: 0.9375rem;
  color: var(--stripe-gray-600);
  margin-bottom: 0.65rem;
  line-height: 1.5;
}

.bulk-api-field__intro a {
  color: var(--stripe-purple);
  font-weight: 600;
}

.bulk-key-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-bottom: 0.35rem;
}

.bulk-key-row input {
  flex: 1;
  min-width: 12rem;
  max-width: none;
  width: auto;
}

.bulk-key-remove {
  padding: 0.5rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--stripe-gray-600);
  background: var(--stripe-gray-100);
  border: 1px solid var(--stripe-gray-200);
  border-radius: 8px;
  cursor: pointer;
}

.bulk-key-remove:hover {
  border-color: var(--stripe-gray-400);
  color: var(--stripe-gray-900);
}

.bulk-key-saved {
  font-size: 0.8125rem;
  color: #0a7b3c;
  margin-bottom: 0.35rem;
}

.bulk-stepper {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.bulk-secondary-btn {
  padding: 0.6rem 0.95rem;
  border-radius: 8px;
  border: 1px solid var(--stripe-gray-200);
  background: #fff;
  color: var(--stripe-gray-800);
  font-weight: 600;
  cursor: pointer;
}

.bulk-secondary-btn:hover {
  border-color: var(--stripe-purple);
  color: var(--stripe-purple);
}

.bulk-stepper__item {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--stripe-gray-500);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: var(--stripe-gray-100);
  border: 1px solid var(--stripe-gray-200);
}

.bulk-stepper__item--active {
  color: var(--stripe-purple);
  border-color: var(--stripe-purple);
  background: rgba(99, 91, 255, 0.08);
}

.bulk-stepper__item--done {
  color: var(--stripe-gray-600);
}

.bulk-step h2 {
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
}

.bulk-object-type-panel {
  padding: 0.5rem 0 0;
  text-align: center;
}

.bulk-object-type-panel__hint {
  max-width: none;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 1rem;
  text-align: center;
}

.bulk-object-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 0;
}

.bulk-object-list__loading {
  flex: 1 1 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3.25rem;
  width: 100%;
  color: var(--stripe-gray-500, #6b7280);
  font-size: 0.875rem;
}

.bulk-object-list__error {
  flex: 1 1 100%;
  margin: 0 0 0.5rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--stripe-red-500, #b42318);
}

.bulk-object-list--compact {
  gap: 0.45rem;
}

.bulk-object-list--compact .bulk-object-list__loading {
  min-height: 2.5rem;
  font-size: 0.8125rem;
}

.bulk-object-list--compact .bulk-object-card {
  padding: 0.45rem 0.65rem;
  min-width: 7.5rem;
  border-radius: 10px;
  gap: 0.45rem;
}

.bulk-object-list--compact .bulk-object-card__label {
  font-size: 0.8125rem;
}

.bulk-object-list--compact .bulk-object-card__badge {
  top: 0.3rem;
  right: 0.35rem;
  font-size: 0.5625rem;
}

.bulk-object-card {
  flex: 0 1 auto;
  min-width: 160px;
  text-align: left;
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid var(--stripe-gray-200);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, padding 0.15s ease, gap 0.15s ease,
    border-radius 0.15s ease;
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.625rem;
}

.bulk-object-card__icon {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  color: var(--stripe-purple);
  line-height: 0;
}

.bulk-object-card:hover:not(:disabled) {
  border-color: var(--stripe-purple);
  box-shadow: 0 4px 14px rgba(99, 91, 255, 0.12);
}

.bulk-object-card--selected {
  border-color: var(--stripe-purple);
  background: rgba(99, 91, 255, 0.1);
  box-shadow: 0 0 0 2px rgba(99, 91, 255, 0.35);
}

.bulk-object-card--selected .bulk-object-card__label {
  color: var(--stripe-purple);
}

.bulk-object-card--disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.bulk-object-card__label {
  flex: 1;
  min-width: 0;
  font-weight: 600;
  color: var(--stripe-gray-900);
}

.bulk-object-card__meta {
  display: block;
  font-size: 0.75rem;
  color: var(--stripe-gray-500);
  margin-top: 0.25rem;
}

.bulk-object-card__badge {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--stripe-gray-500);
}

.bulk-object-card__badge--muted {
  color: var(--stripe-purple);
}

.bulk-object-card--other {
  border-style: dashed;
}

.bulk-status {
  font-size: 0.875rem;
  min-height: 1.25rem;
  margin-top: 0.5rem;
}

.bulk-status--error {
  color: var(--stripe-red);
}

.bulk-status--ok {
  color: #0a7b3c;
}

.bulk-schema-alert {
  margin-bottom: 1.25rem;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--stripe-gray-200);
  background: var(--stripe-gray-100);
}

.bulk-schema-alert__intro {
  font-size: 0.9375rem;
  color: var(--stripe-gray-600);
  margin: 0 0 0.85rem;
  line-height: 1.5;
}

.bulk-schema-alert__intro:last-child {
  margin-bottom: 0;
}

.bulk-schema-alert__details {
  margin: 0;
  padding-top: 0.85rem;
  border-top: 1px solid var(--stripe-gray-200);
}

.bulk-schema-alert__details summary {
  font-weight: 600;
  font-size: 0.9375rem;
  cursor: pointer;
  color: var(--stripe-gray-800);
}

.bulk-schema-alert__details[open] summary {
  margin-bottom: 0.5rem;
}

.bulk-schema-alert a {
  color: var(--stripe-purple);
}

.bulk-column-list {
  font-size: 0.8125rem;
  color: var(--stripe-gray-600);
  margin: 0;
  max-height: 10rem;
  overflow: auto;
  padding: 0.25rem 0 0;
}

.bulk-column-list code {
  font-size: 0.78rem;
  background: var(--stripe-gray-100);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
}

.bulk-file-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.1rem;
  border-radius: 8px;
  background: var(--stripe-purple);
  color: #fff;
  font-weight: 600;
  font-size: 0.9375rem;
  cursor: pointer;
  border: none;
}

.bulk-file-label input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
}

.bulk-back-btn {
  margin-top: 1rem;
  background: none;
  border: none;
  color: var(--stripe-purple);
  font-weight: 600;
  cursor: pointer;
  font-size: 0.9375rem;
}

.bulk-back-btn:hover {
  text-decoration: underline;
}

.bulk-grid-scroll {
  overflow: auto;
  max-height: min(55vh, 520px);
  border: 1px solid var(--stripe-gray-200);
  border-radius: 10px;
  margin-bottom: 1rem;
}

.bulk-grid {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.bulk-grid th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--stripe-gray-100);
  text-align: left;
  padding: 0.5rem 0.4rem;
  border-bottom: 1px solid var(--stripe-gray-200);
  white-space: nowrap;
  font-weight: 600;
}

.bulk-grid td {
  padding: 0;
  border-bottom: 1px solid var(--stripe-gray-200);
  vertical-align: middle;
}

.bulk-grid__cell--error {
  position: relative;
  background: rgba(223, 27, 65, 0.08);
  box-shadow: inset 0 0 0 1px rgba(223, 27, 65, 0.35);
}
.bulk-grid__cell--error .bulk-grid__input {
  padding-right: 1.5rem;
}
.bulk-grid__warn {
  position: absolute;
  right: 4px;
  top: 50%;
  translate: 0 -50%;
  color: #df1b41;
  flex-shrink: 0;
  pointer-events: none;
  opacity: 0.8;
}

.bulk-grid-tooltip {
  position: fixed;
  z-index: 50;
  max-width: 300px;
  padding: 6px 12px;
  font-size: 0.75rem;
  line-height: 1.4;
  color: #fafafa;
  background: #18181b;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  pointer-events: none;
  animation: bulk-tooltip-in 0.1s ease-out;
}
.bulk-grid-tooltip[hidden] {
  display: none;
}

.bulk-grid-tooltip[data-placement="top"]::after,
.bulk-grid-tooltip[data-placement="bottom"]::before {
  content: '';
  position: absolute;
  left: 50%;
  translate: -50% 0;
  border: 5px solid transparent;
}
.bulk-grid-tooltip[data-placement="top"]::after {
  top: 100%;
  border-top-color: #18181b;
}
.bulk-grid-tooltip[data-placement="bottom"]::before {
  bottom: 100%;
  border-bottom-color: #18181b;
}

@keyframes bulk-tooltip-in {
  from { opacity: 0; scale: 0.96; }
  to   { opacity: 1; scale: 1; }
}

.bulk-grid__input {
  width: 100%;
  min-width: 7rem;
  border: none;
  padding: 0.4rem 0.45rem;
  font-size: inherit;
  font-family: inherit;
  background: transparent;
}

.bulk-grid__input:focus {
  outline: 2px solid var(--stripe-purple);
  outline-offset: -2px;
}

.bulk-grid-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.bulk-grid-meta {
  font-size: 0.875rem;
  color: var(--stripe-gray-600);
  margin: 0;
}

.bulk-discard-file-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: none;
  border: none;
  color: var(--stripe-gray-500);
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}

.bulk-discard-file-btn:hover {
  color: var(--stripe-gray-700);
  background: var(--stripe-gray-100);
}

.bulk-discard-file-btn--confirm {
  color: #d1242f;
}

.bulk-discard-file-btn--confirm:hover {
  color: #d1242f;
  background: rgba(209, 36, 47, 0.08);
}

/* Ensure remove-key confirm matches discard “Really?” (beat Tailwind / nested color) */
#bulk-remove-key.bulk-discard-file-btn--confirm,
#bulk-remove-key.bulk-discard-file-btn--confirm #bulk-remove-key-label {
  color: #d1242f;
}

#bulk-remove-key.bulk-discard-file-btn--confirm svg {
  color: #d1242f;
}

@media (prefers-color-scheme: dark) {
  .bulk-discard-file-btn {
    color: #8b949e;
  }

  .bulk-discard-file-btn:hover {
    color: #c9d1d9;
    background: rgba(255, 255, 255, 0.06);
  }

  .bulk-discard-file-btn--confirm {
    color: #f85149;
  }

  .bulk-discard-file-btn--confirm:hover {
    color: #f85149;
    background: rgba(248, 81, 73, 0.1);
  }
}

.bulk-step__hint--after-grid {
  font-size: 0.8125rem;
  color: var(--stripe-gray-500);
  max-width: 40rem;
  margin: 0 0 1.25rem;
  line-height: 1.45;
}

.bulk-step3-actions {
  margin-bottom: 1rem;
}

.bulk-step3-signed-in[hidden],
.bulk-step3-confirm-row[hidden],
.bulk-step3-key-upload[hidden],
.bulk-key-saved-row[hidden],
.bulk-auth-callout[hidden] {
  display: none;
}

.bulk-step3-signed-in {
  width: 100%;
}

.bulk-step3-key-confirm-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  width: 100%;
}

.bulk-step3-confirm-row {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  flex: 0 0 auto;
  margin-left: auto;
}

.bulk-step3-confirm-row .bulk-confirm-btn {
  flex: 0 0 auto;
}

.bulk-auth-callout__actions--single {
  flex-shrink: 0;
}

.bulk-step3-key-upload {
  flex: 0 1 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  min-width: 0;
}

.bulk-key-saved-row {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  max-width: 100%;
  padding-top: 0.6rem;
}

.bulk-key-indicator {
  position: relative;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.65rem;
  padding: 0.45rem 0.65rem;
  border-radius: 10px;
  border: 1px solid rgba(10, 123, 60, 0.35);
  background: rgba(10, 123, 60, 0.08);
  width: fit-content;
  max-width: min(100%, 100vw - 2rem);
  box-sizing: border-box;
}

.bulk-key-indicator:focus {
  outline: 2px solid var(--stripe-purple);
  outline-offset: 2px;
}

.bulk-key-indicator__lock-icon {
  color: #0a7b3c;
  flex-shrink: 0;
}

.bulk-key-indicator__label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #0a5c2e;
}

.bulk-key-indicator__tooltip {
  position: absolute;
  left: 0;
  right: auto;
  bottom: calc(100% + 8px);
  z-index: 20;
  min-width: 14rem;
  max-width: min(22rem, 92vw);
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--stripe-gray-200);
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--stripe-gray-700);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease, visibility 0.15s ease;
}

.bulk-key-indicator:hover .bulk-key-indicator__tooltip,
.bulk-key-indicator:focus-within .bulk-key-indicator__tooltip,
.bulk-key-indicator:focus .bulk-key-indicator__tooltip {
  opacity: 1;
  visibility: visible;
}

.bulk-api-field--compact {
  margin-bottom: 0;
  width: 100%;
  max-width: 28rem;
}

.bulk-api-field__label-inline {
  display: block;
  font-weight: 600;
  font-size: 0.8125rem;
  margin-bottom: 0.35rem;
  color: var(--stripe-gray-800);
}

.bulk-key-row--compact {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.5rem;
}

.bulk-key-row--compact input {
  flex: 1 1 auto;
  min-width: 0;
  max-width: none;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--stripe-gray-200);
  border-radius: 8px;
  font-size: 0.875rem;
}

.bulk-api-key-tooltip-anchor {
  position: relative;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem;
  border-radius: 6px;
  cursor: help;
  color: var(--stripe-gray-500);
}

.bulk-api-key-tooltip-anchor:hover,
.bulk-api-key-tooltip-anchor:focus {
  color: var(--stripe-purple);
  outline: none;
}

.bulk-api-key-tooltip-anchor__tip {
  position: absolute;
  right: 0;
  bottom: calc(100% + 8px);
  z-index: 20;
  min-width: 14rem;
  max-width: min(20rem, 85vw);
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--stripe-gray-200);
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--stripe-gray-700);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease, visibility 0.15s ease;
}

.bulk-api-key-tooltip-anchor:hover .bulk-api-key-tooltip-anchor__tip,
.bulk-api-key-tooltip-anchor:focus .bulk-api-key-tooltip-anchor__tip,
.bulk-api-key-tooltip-anchor:focus-within .bulk-api-key-tooltip-anchor__tip {
  opacity: 1;
  visibility: visible;
}

.bulk-api-key-hint-popover__link {
  display: block;
  margin-top: 0.5rem;
  font-weight: 600;
  color: var(--stripe-purple);
}

.bulk-api-field {
  margin-bottom: 1.25rem;
}

.bulk-api-field label {
  display: block;
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 0.35rem;
}

.bulk-api-field input {
  width: 100%;
  max-width: 28rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--stripe-gray-200);
  border-radius: 8px;
  font-size: 0.9375rem;
}

.bulk-api-field__hint {
  font-size: 0.8125rem;
  color: var(--stripe-gray-500);
  margin-top: 0.35rem;
}

.bulk-auth-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 0 0 1rem;
  padding: 1rem;
  border-radius: 10px;
  border: 1px solid rgba(99, 91, 255, 0.18);
  background: rgba(99, 91, 255, 0.06);
}

.bulk-auth-callout__title {
  font-weight: 700;
  color: var(--stripe-gray-900);
  margin-bottom: 0.25rem;
}

.bulk-auth-callout__copy {
  margin: 0;
  font-size: 0.875rem;
  color: var(--stripe-gray-600);
}

.bulk-auth-callout__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.bulk-auth-callout__btn {
  padding: 0.65rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--stripe-gray-200);
  background: #fff;
  color: var(--stripe-gray-800);
  font-weight: 600;
  cursor: pointer;
}

.bulk-auth-callout__btn--primary {
  border-color: var(--stripe-purple);
  background: var(--stripe-purple);
  color: #fff;
}

/* Green variant — used for "Add your Stripe API key" callout */
.bulk-auth-callout--green {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  width: 100%;
  border-color: rgba(34, 197, 94, 0.3);
  background: rgba(34, 197, 94, 0.06);
}

/* Widen slot only when the add-key form is visible (not merely present in DOM) */
.bulk-step3-key-upload:has(.bulk-auth-callout--green:not([hidden])) {
  flex: 1 1 100%;
  align-items: stretch;
}

.bulk-auth-callout__body {
  flex: 0 1 40%;
  min-width: 0;
}

.bulk-auth-callout__input-row {
  flex: 1 1 55%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  min-width: 14rem;
  width: 100%;
}

.bulk-auth-callout__input-row .bulk-key-row--compact {
  width: 100%;
}

/* On narrow screens, stack body above input row */
@media (max-width: 540px) {
  .bulk-auth-callout--green {
    flex-direction: column;
    align-items: stretch;
  }
  .bulk-auth-callout__input-row {
    align-items: stretch;
    min-width: 0;
    max-width: none;
  }
}

.bulk-api-key-label-link {
  color: var(--stripe-gray-800);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.bulk-api-key-label-link:hover {
  color: var(--stripe-purple);
}

.bulk-auth-modal-note {
  margin: 0 0 1rem;
  padding: 0.75rem 0.875rem;
  border-radius: 10px;
  background: rgba(99, 91, 255, 0.06);
  color: var(--stripe-gray-700);
  font-size: 0.875rem;
}

.bulk-confirm-btn {
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  border: none;
  background: var(--stripe-purple);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
}

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

.bulk-confirm-btn--destructive {
  background: #b91c1c;
}

.bulk-confirm-btn--destructive:hover:not(:disabled) {
  background: #991b1b;
}

.bulk-btn-destructive {
  background: #b91c1c;
  color: #fff;
  border: none;
}

.bulk-btn-destructive:hover:not(:disabled) {
  background: #991b1b;
}

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

.bulk-destructive-callout {
  border-radius: 10px;
  border: 1px solid rgba(185, 28, 28, 0.35);
  background: rgba(254, 226, 226, 0.5);
  padding: 1rem 1.125rem;
  color: var(--stripe-gray-800);
}

.bulk-destructive-callout__title {
  font-weight: 700;
  color: #991b1b;
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.bulk-destructive-callout__body {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.5;
}

.dark .bulk-destructive-callout {
  border-color: rgba(248, 113, 113, 0.35);
  background: rgba(127, 29, 29, 0.22);
  color: #e4e4e7;
}

.dark .bulk-destructive-callout__title {
  color: #fecaca;
}

.bulk-sub-back:hover {
  text-decoration: none;
  opacity: 0.6;
}

.bulk-step--subscription-action,
.bulk-step--delete-all,
.bulk-step--test-card-all {
  padding-top: 0.25rem;
}

.bulk-confirm-banner {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  background: var(--stripe-gray-100);
  border: 1px solid var(--stripe-gray-200);
  font-size: 0.9375rem;
  color: var(--stripe-gray-800);
}

.bulk-confirm-banner--error {
  border-color: rgba(223, 27, 65, 0.25);
  background: rgba(223, 27, 65, 0.06);
}

.bulk-confirm-banner--ok {
  border-color: rgba(10, 123, 60, 0.25);
  background: rgba(10, 123, 60, 0.06);
}

/* ── Key mode badge (Production / Test) ── */

.bulk-key-mode-badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  line-height: 1.4;
  vertical-align: middle;
  margin-left: 0.4rem;
}

.bulk-key-mode-badge--production {
  color: #92400e;
  background: rgba(251, 191, 36, 0.15);
  border-color: rgba(251, 191, 36, 0.45);
}

.bulk-key-mode-badge--test {
  color: var(--stripe-gray-600, #6b7280);
  background: rgba(99, 102, 241, 0.08);
  border-color: rgba(99, 102, 241, 0.25);
}

/* ── Upload time estimate ── */

.bulk-upload-estimate {
  font-size: 0.8125rem;
  color: var(--stripe-gray-600, #6b7280);
  margin: 0.5rem 0 0;
  text-align: center;
  width: 100%;
}

/* ── Restore notice (shown after OAuth redirect preserves CSV) ── */

.bulk-restore-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  border: 1px solid rgba(99, 91, 255, 0.25);
  background: rgba(99, 91, 255, 0.06);
  font-size: 0.875rem;
  color: var(--stripe-gray-800);
}

.bulk-restore-notice[hidden] {
  display: none;
}

.bulk-restore-notice__copy {
  margin: 0;
  flex: 1;
}

.bulk-restore-notice__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.bulk-restore-notice__btn {
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  border: 1px solid var(--stripe-gray-300);
  background: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--stripe-gray-700);
  transition: background 0.15s, border-color 0.15s;
}

.bulk-restore-notice__btn:hover {
  background: var(--stripe-gray-50);
  border-color: var(--stripe-gray-400);
}

.bulk-restore-notice__btn--dismiss {
  border: none;
  background: transparent;
  font-size: 1rem;
  padding: 0.25rem 0.5rem;
  color: var(--stripe-gray-500);
}

.bulk-restore-notice__btn--dismiss:hover {
  color: var(--stripe-gray-700);
  background: transparent;
}

/* ── Truncation notice (shown when CSV exceeds row limit) ── */

.bulk-truncation-notice {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  border: 1px solid rgba(255, 152, 0, 0.35);
  background: rgba(255, 152, 0, 0.07);
  font-size: 0.875rem;
  color: var(--stripe-gray-800);
  line-height: 1.5;
}

.bulk-truncation-notice[hidden] {
  display: none;
}

.bulk-truncation-notice__icon {
  flex: 0 0 auto;
  color: #e67e00;
}

.bulk-truncation-notice__copy {
  margin: 0;
  flex: 1 1 auto;
}

.bulk-truncation-notice__upgrade-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 1rem;
  border-radius: 6px;
  border: 1px solid var(--brand-main, #635bff);
  background: var(--brand-main, #635bff);
  color: #fff;
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.bulk-truncation-notice__upgrade-btn:hover {
  background: var(--brand-dark, #4f46e5);
  border-color: var(--brand-dark, #4f46e5);
  color: #fff;
}

.bulk-truncation-notice__link {
  color: var(--brand-main, #635bff);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.bulk-truncation-notice__link:hover {
  color: var(--brand-dark, #4f46e5);
}

.bulk-upload-results {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 10px;
  border: 1px solid var(--stripe-gray-200);
  background: #fff;
  font-size: 0.9375rem;
}

.bulk-upload-results--ok {
  border-color: rgba(10, 123, 60, 0.35);
  background: rgba(10, 123, 60, 0.06);
}

.bulk-upload-results--partial {
  border-color: rgba(255, 152, 0, 0.45);
  background: rgba(255, 152, 0, 0.06);
}

.bulk-upload-results--fail {
  border-color: rgba(223, 27, 65, 0.35);
  background: rgba(223, 27, 65, 0.06);
}

.bulk-upload-results__title {
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.bulk-upload-results__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.bulk-upload-results__header .bulk-upload-results__title {
  margin-bottom: 0;
}

.bulk-upload-results__icon {
  flex-shrink: 0;
  color: #df1b41;
  opacity: 0.85;
}

.bulk-upload-results--ok .bulk-upload-results__icon {
  color: #0a7b3c;
}

.bulk-upload-results__msg {
  margin: 0 0 0.35rem;
  font-size: 0.9rem;
  line-height: 1.5;
}

.bulk-upload-results__hint {
  margin: 0.5rem 0 0;
  font-size: 0.875rem;
  color: var(--stripe-gray-600);
  line-height: 1.5;
}

.bulk-upload-results__list {
  margin: 0.5rem 0 0;
  padding-left: 1.25rem;
  max-height: 12rem;
  overflow: auto;
}

.bulk-grid__row--upload-error {
  background: rgba(223, 27, 65, 0.06);
}

/* --- Dark mode (class on html from next-themes) --- */
html.dark {
  --stripe-gray-900: #eceef1;
  --stripe-gray-800: #d8dee8;
  --stripe-gray-600: #9aa5b5;
  --stripe-gray-500: #8490a3;
  --stripe-gray-400: #6b7788;
  --stripe-gray-200: #3d444d;
  --stripe-gray-100: #1e2229;
  --stripe-purple-light: rgba(99, 91, 255, 0.18);
}

html.dark .section-gray {
  background-color: #23272f;
}

html.dark .card {
  background: #1e2229;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

html.dark .card:hover {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
}

html.dark .faq-item {
  background: #1e2229;
}

html.dark .faq-question:hover {
  background-color: #21262d;
}

html.dark .faq-content code {
  background: #2d333b;
  color: #e6edf3;
  border-color: #3d444d;
}

html.dark .form-input {
  background: #181b21;
  color: var(--stripe-gray-900);
  border-color: var(--stripe-gray-200);
}

html.dark .btn-secondary {
  background: #1e2229;
  color: var(--stripe-purple);
}

html.dark .webform-card {
  background: #1e2229;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35), 0 0 0 1px var(--stripe-gray-200);
}

html.dark .webform-text-input {
  background: #181b21;
  color: var(--stripe-gray-900);
}

html.dark .bulk-schema-alert {
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(30, 34, 41, 0.92);
}

html.dark .bulk-schema-alert__intro {
  color: #8b949e;
}

html.dark .bulk-schema-alert__details {
  border-top-color: rgba(148, 163, 184, 0.35);
}

html.dark .bulk-schema-alert__details summary {
  color: #e6edf3;
}

html.dark .bulk-column-list {
  color: #8b949e;
}

html.dark .bulk-column-list code {
  background: #181b21;
  color: #e6edf3;
}

html.dark .bulk-object-card,
html.dark .bulk-upload-results:not(.bulk-upload-results--ok):not(.bulk-upload-results--partial):not(.bulk-upload-results--fail) {
  background: #1e2229;
}

html.dark .bulk-object-card--selected {
  background: rgba(99, 91, 255, 0.18);
  box-shadow: 0 0 0 2px rgba(167, 139, 250, 0.45);
}

html.dark .bulk-object-card--selected .bulk-object-card__label {
  color: #c4b5fd;
}

html.dark .bulk-object-card__icon {
  color: #a78bfa;
}

html.dark .bulk-object-card--other {
  border-color: rgba(148, 163, 184, 0.45);
}

html.dark .bulk-object-card__badge--muted {
  color: #c4b5fd;
}

html.dark .bulk-step__hint--after-grid {
  color: #8b949e;
}

html.dark .bulk-discard-file-btn {
  color: #8b949e;
}

html.dark .bulk-discard-file-btn:hover {
  color: #c9d1d9;
  background: rgba(255, 255, 255, 0.06);
}

html.dark .bulk-discard-file-btn--confirm {
  color: #f85149;
}

html.dark .bulk-discard-file-btn--confirm:hover {
  color: #f85149;
  background: rgba(248, 81, 73, 0.1);
}

html.dark #bulk-remove-key.bulk-discard-file-btn--confirm,
html.dark #bulk-remove-key.bulk-discard-file-btn--confirm #bulk-remove-key-label {
  color: #f85149;
}

html.dark #bulk-remove-key.bulk-discard-file-btn--confirm svg {
  color: #f85149;
}

html.dark .bulk-key-indicator {
  border-color: rgba(52, 211, 153, 0.45);
  background: rgba(16, 185, 129, 0.12);
}

html.dark .bulk-key-indicator__lock-icon {
  color: #34d399;
}

html.dark .bulk-key-indicator__label {
  color: #6ee7b7;
}

html.dark .bulk-key-indicator__tooltip {
  background: #1e2229;
  border-color: rgba(148, 163, 184, 0.35);
  color: #c9d1d9;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

html.dark .bulk-api-key-tooltip-anchor__tip {
  background: #1e2229;
  border-color: rgba(148, 163, 184, 0.35);
  color: #c9d1d9;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

html.dark .bulk-api-field__label-inline {
  color: #e6edf3;
}

html.dark .bulk-api-field input {
  background: #181b21;
  color: var(--stripe-gray-900);
}

html.dark .bulk-restore-notice {
  border-color: rgba(99, 91, 255, 0.28);
  background: rgba(99, 91, 255, 0.12);
  color: #e6edf3;
}

html.dark .bulk-restore-notice__btn {
  background: #1e2229;
  color: #e6edf3;
  border-color: var(--stripe-gray-200);
}

html.dark .bulk-restore-notice__btn:hover {
  background: #262b33;
}

html.dark .bulk-restore-notice__btn--dismiss {
  background: transparent;
  color: var(--stripe-gray-400);
}

html.dark .bulk-restore-notice__btn--dismiss:hover {
  color: #e6edf3;
  background: transparent;
}

html.dark .bulk-truncation-notice {
  border-color: rgba(255, 152, 0, 0.3);
  background: rgba(255, 152, 0, 0.1);
  color: #e6edf3;
}

html.dark .bulk-truncation-notice__icon {
  color: #ffa726;
}

html.dark .bulk-truncation-notice__upgrade-btn {
  background: #7c6bff;
  border-color: #7c6bff;
}

html.dark .bulk-truncation-notice__upgrade-btn:hover {
  background: #9b8bff;
  border-color: #9b8bff;
}

html.dark .bulk-truncation-notice__link {
  color: #a78bfa;
}

html.dark .bulk-truncation-notice__link:hover {
  color: #c4b5fd;
}

html.dark .bulk-auth-callout {
  border-color: rgba(99, 91, 255, 0.28);
  background: rgba(99, 91, 255, 0.12);
}

html.dark .bulk-auth-callout__btn {
  background: #1e2229;
  color: var(--stripe-gray-900);
  border-color: var(--stripe-gray-200);
}

html.dark .bulk-auth-callout__btn--primary {
  background: var(--stripe-purple);
  color: #fff;
  border-color: var(--stripe-purple);
}

html.dark .bulk-auth-callout--green {
  border-color: rgba(34, 197, 94, 0.3);
  background: rgba(34, 197, 94, 0.1);
}

html.dark .bulk-api-key-label-link {
  color: #e6edf3;
}

html.dark .bulk-api-key-label-link:hover {
  color: var(--stripe-purple);
}

html.dark .bulk-auth-modal-note {
  background: rgba(99, 91, 255, 0.12);
  color: var(--stripe-gray-900);
}

html.dark .footer {
  background: #1e2229;
  border-top-color: var(--stripe-gray-200);
}

html.dark .footer p {
  color: #8b949e;
}

html.dark .footer-nav {
  background: #181b21;
}