/* Product section styles */

.product-section {
  position: relative;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: clamp(56px, 7.5vh, 96px) clamp(20px, 5vw, 32px) clamp(20px, 2.8vh, 32px);
  z-index: 1;
}
.product-section .section-intro { margin-bottom: clamp(48px, 6.5vh, 80px); }

.workflow {
  position: relative;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: clamp(44px, 6.5vh, 80px) clamp(20px, 5vw, 32px);
  z-index: 1;
}
.workflow-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.workflow-grid.reverse { direction: rtl; }
.workflow-grid.reverse > * { direction: ltr; }

.workflow-meta {
  font-size: var(--fs-label-lg);
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(75, 42, 99, 0.55);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}
.workflow-meta .num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--fs-num-lg);
  font-weight: 400;
  color: var(--primary);
  letter-spacing: -0.02em;
  text-transform: none;
  line-height: 1;
}
.workflow-meta .divider { width: 24px; height: 1px; background: rgba(75, 42, 99, 0.25); }

.workflow-headline {
  color: var(--charcoal);
  margin-bottom: 18px;
  max-width: 14ch;
}
.workflow-headline .italic {
  font-style: italic;
  color: var(--primary);
}

.workflow-body {
  font-size: var(--fs-body-md);
  line-height: 1.6;
  color: var(--charcoal-75);
  max-width: 44ch;
  margin-bottom: 28px;
}
.workflow-body strong { color: var(--charcoal); font-weight: 500; }

/* Merchant panel */
.merchant-panel {
  background: var(--white);
  border: 1px solid rgba(75, 42, 99, 0.08);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.04),
    0 4px 16px rgba(0, 0, 0, 0.06),
    0 8px 24px rgba(75, 42, 99, 0.08);
  max-width: 380px;
}
.merchant-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(75, 42, 99, 0.08);
  margin-bottom: 14px;
}
.merchant-panel-title { display: flex; align-items: center; gap: 8px; font-size: var(--fs-ui-md); font-weight: 600; color: var(--charcoal); }
.shopify-bag {
  width: 18px; height: 18px;
  background: #95BF47;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: var(--fs-label-2xs);
  font-weight: 700;
  font-family: var(--font-display);
}
.merchant-panel-tag { font-size: var(--fs-label-sm); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(75, 42, 99, 0.55); }
.metric-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.metric-row.three { grid-template-columns: 1fr 1fr 1fr; }
.metric { padding: 4px 0; }
.metric-label { font-size: var(--fs-label-md); color: rgba(26, 26, 26, 0.5); letter-spacing: 0.04em; margin-bottom: 4px; line-height: 1.2; }
.metric-value { color: var(--primary); }
.metric-trend { font-size: var(--fs-label-sm); color: var(--accent); margin-left: 4px; font-weight: 600; font-family: var(--font-ui); }

.merchant-panel.dark { background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.12); }
.merchant-panel.dark .merchant-panel-title { color: rgba(255, 255, 255, 0.92); }
.merchant-panel.dark .merchant-panel-tag { color: rgba(199, 166, 222, 0.7); }
.merchant-panel.dark .merchant-panel-header { border-color: rgba(255, 255, 255, 0.08); }
.merchant-panel.dark .metric-label { color: rgba(255, 255, 255, 0.55); }
.merchant-panel.dark .metric-value { color: var(--primary-pale); }

.sparkline { margin-top: 14px; height: 36px; width: 100%; display: block; }

/* Dark section */
.workflow.dark-section {
  width: calc(100% - 64px);
  margin: clamp(32px, 4.5vh, 60px) auto;
  padding: clamp(44px, 6.5vh, 80px) 64px;
  background:
    radial-gradient(ellipse 80% 60% at 30% 20%, rgba(132, 76, 172, 0.4) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 80% 80%, rgba(75, 42, 99, 0.5) 0%, transparent 50%),
    linear-gradient(135deg, #2A1738 0%, #1A0E25 100%);
  border-radius: var(--radius-xl);
  max-width: calc(1280px - 64px);
  overflow: hidden;
  position: relative;
}
.workflow.dark-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(199, 166, 222, 0.12) 0.8px, transparent 1px);
  background-size: 28px 28px;
  opacity: 0.5;
  mask-image: radial-gradient(ellipse 60% 60% at 50% 50%, #000 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 60% 60% at 50% 50%, #000 0%, transparent 70%);
  pointer-events: none;
}
.workflow.dark-section .workflow-headline { color: rgba(255, 255, 255, 0.95); }
.workflow.dark-section .workflow-headline .italic { color: var(--primary-pale); }
.workflow.dark-section .workflow-body { color: rgba(255, 255, 255, 0.7); }
.workflow.dark-section .workflow-body strong { color: rgba(255, 255, 255, 0.95); }
.workflow.dark-section .workflow-meta { color: rgba(199, 166, 222, 0.6); }
.workflow.dark-section .workflow-meta .num { color: var(--primary-pale); }
.workflow.dark-section .workflow-meta .divider { background: rgba(199, 166, 222, 0.25); }

/* Storefront */
.storefront-stage { position: relative; width: 100%; aspect-ratio: 4/2.4; }
.storefront {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 16px;
  overflow: hidden;
}
.storefront-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 14px;
}
.storefront-bar .dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.18); }
.storefront-bar .dot:nth-child(1) { background: rgba(255, 95, 86, 0.7); }
.storefront-bar .dot:nth-child(2) { background: rgba(255, 189, 46, 0.7); }
.storefront-bar .dot:nth-child(3) { background: rgba(39, 201, 63, 0.7); }
.storefront-bar .url {
  margin-left: 14px;
  font-size: var(--fs-mono-sm);
  color: rgba(255, 255, 255, 0.45);
  font-family: var(--font-mono);
  background: rgba(255, 255, 255, 0.04);
  padding: 4px 10px;
  border-radius: 6px;
  flex: 1;
}
.storefront-content { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; height: calc(100% - 48px); }
.storefront-product-img {
  background:
    radial-gradient(circle at 30% 30%, rgba(199, 166, 222, 0.3) 0%, transparent 50%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.storefront-product-img::after {
  content: "";
  width: 48%;
  aspect-ratio: 1.4 / 1;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.storefront-info { display: flex; flex-direction: column; gap: 8px; padding: 4px; }
.storefront-info .skeleton { background: rgba(255, 255, 255, 0.08); border-radius: 4px; height: 8px; }
.storefront-info .skeleton.title { height: 14px; width: 75%; background: rgba(255, 255, 255, 0.18); margin-bottom: 4px; }
.storefront-info .skeleton.price { width: 40%; height: 16px; background: rgba(199, 166, 222, 0.35); margin-top: 6px; }
.storefront-info .skeleton.short { width: 60%; }
.storefront-info .skeleton.long { width: 90%; }
.storefront-info .cta-skeleton { margin-top: 12px; height: 28px; background: rgba(255, 255, 255, 0.12); border-radius: var(--radius-pill); width: 70%; }

.call-us-btn {
  position: absolute;
  bottom: 36px; right: 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px 11px 13px;
  background: var(--accent);
  color: var(--charcoal);
  border-radius: var(--radius-pill);
  font-size: var(--fs-body-xs);
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(155, 207, 106, 0.4), 0 0 0 4px rgba(155, 207, 106, 0.15);
  cursor: pointer;
  z-index: 5;
  animation: float-pulse 3s ease-in-out infinite;
}
.call-us-btn .phone-icon {
  width: 18px; height: 18px;
  background: var(--charcoal);
  color: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-label-2xs);
}
.call-us-btn .powered-by {
  position: absolute;
  bottom: -22px; right: 4px;
  font-size: var(--fs-label-2xs);
  font-weight: 500;
  letter-spacing: 0.05em;
  color: rgba(199, 166, 222, 0.6);
  white-space: nowrap;
}

.feature-callout { position: absolute; bottom: 36px; right: 160px; max-width: 180px; text-align: right; z-index: 4; }
.feature-callout-label { font-size: var(--fs-label-sm); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.feature-callout-text { font-family: var(--font-display); font-style: italic; font-size: var(--fs-body-base); color: rgba(255, 255, 255, 0.85); line-height: 1.3; }

.inbound-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center; }
.inbound-stack { display: flex; flex-direction: column; gap: 24px; }

@media (max-width: 960px) {
  .workflow-grid, .inbound-grid { grid-template-columns: 1fr; gap: 24px; }
  .workflow-grid.reverse { direction: ltr; }
  .workflow.dark-section { padding: 48px 20px; width: 100%; margin: 32px 0; }
  .workflow { padding: 48px 20px; }
  .product-section { padding-left: 20px; padding-right: 20px; }
  .merchant-panel { max-width: 100%; }
  .feature-callout { display: none; }
  .storefront-stage { aspect-ratio: 4/3.2; }
  .storefront-content { grid-template-columns: 1fr; }
}

/* Workflow overview cards */
.workflow-overview {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 48px clamp(44px, 6.5vh, 80px);
}

.workflow-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px 28px 24px;
  border-radius: var(--radius-md);
  background: var(--white);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  box-shadow:
    0 1px 2px rgba(75, 42, 99, 0.04),
    0 4px 12px rgba(75, 42, 99, 0.08),
    0 16px 40px rgba(75, 42, 99, 0.06);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.workflow-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(75, 42, 99, 0.04);
  transform: translateY(100%);
  transition: transform 0.25s ease;
  pointer-events: none;
}
.workflow-card:hover::after { transform: translateY(0); }
.workflow-card:hover {
  box-shadow:
    0 1px 2px rgba(75, 42, 99, 0.06),
    0 6px 16px rgba(75, 42, 99, 0.12),
    0 24px 56px rgba(75, 42, 99, 0.10);
  transform: translateY(-2px);
}

.wc-number {
  font-family: var(--font-mono);
  font-size: var(--fs-label-lg);
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--primary);
  opacity: 0.55;
}

.wc-name {
  font-family: var(--font-ui);
  font-size: var(--fs-body-md);
  font-weight: 600;
  color: var(--on-surface);
  line-height: 1.3;
}

.wc-metric {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin: 4px 0 2px;
}
.wc-metric-value {
  color: var(--primary);
}
.wc-metric-label {
  font-family: var(--font-ui);
  font-size: var(--fs-ui-md);
  color: var(--on-surface);
  opacity: 0.55;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.wc-desc {
  font-family: var(--font-ui);
  font-size: var(--fs-body-base);
  color: var(--on-surface);
  opacity: 0.7;
  line-height: 1.5;
  margin: 0;
  flex: 1;
}

.wc-arrow {
  font-size: var(--fs-body-md);
  color: var(--primary);
  opacity: 0.45;
  align-self: flex-end;
  transition: opacity 0.2s, transform 0.2s;
}
.workflow-card:hover .wc-arrow {
  opacity: 0.9;
  transform: translateX(4px);
}

@media (max-width: 960px) {
  .workflow-overview {
    grid-template-columns: 1fr;
    padding: 0 20px 40px;
  }
}
