/* ═══════════════════════════════════════════════════════
   Feature Deep-Dive Pages — Shared Styles
   ═══════════════════════════════════════════════════════ */

/* HERO */
.feature-hero {
  background: linear-gradient(135deg, #0d0d1a 0%, #1a1a2e 40%, #3D2A60 100%);
  padding: 170px 24px 100px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.feature-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(91,62,140,0.3) 0%, transparent 60%),
              radial-gradient(ellipse at 70% 30%, rgba(245,166,35,0.1) 0%, transparent 50%);
  pointer-events: none;
}
.feature-hero .container { position: relative; z-index: 1; }
.feature-hero .section-label { color: var(--orange); }
.feature-hero h1 {
  color: #fff; max-width: 800px; margin: 0 auto 24px;
  background: linear-gradient(135deg, #fff 0%, #e0d0f0 50%, #c084fc 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.feature-hero p {
  color: rgba(255,255,255,0.7); font-size: 20px; line-height: 1.7;
  max-width: 640px; margin: 0 auto;
}
.feature-hero .hero-buttons {
  display: flex; gap: 12px; justify-content: center; margin-top: 36px; flex-wrap: wrap;
}

/* OVERVIEW */
.feature-overview {
  padding: 100px 24px;
  background: var(--bg);
}
.feature-overview .overview-header {
  text-align: center; max-width: 720px; margin: 0 auto 64px;
}
.feature-overview .overview-header p {
  color: var(--text-secondary); font-size: 18px; line-height: 1.7;
}

/* CAPABILITY CARDS */
.capabilities {
  padding: 100px 24px;
  background: var(--bg-subtle);
}
.capabilities .section-header {
  text-align: center; max-width: 720px; margin: 0 auto 64px;
}
.capabilities .section-header p {
  color: var(--text-secondary); font-size: 18px; line-height: 1.7;
}
.capability-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px; max-width: 1200px; margin: 0 auto;
}
.capability-card {
  background: #fff; border-radius: 16px; padding: 40px 32px;
  border: 1px solid var(--border);
  transition: transform 0.2s, box-shadow 0.2s;
}
.capability-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(91,62,140,0.08);
}
.capability-icon {
  width: 56px; height: 56px; border-radius: 14px;
  background: var(--purple-bg); display: flex; align-items: center; justify-content: center;
  font-size: 28px; margin-bottom: 24px;
}
.capability-card h3 { font-size: 20px; margin-bottom: 12px; }
.capability-card p { color: var(--text-secondary); font-size: 15px; line-height: 1.7; }
.capability-card ul {
  list-style: none; margin-top: 16px; padding: 0;
}
.capability-card ul li {
  padding: 6px 0; font-size: 14px; color: var(--text-secondary);
  padding-left: 20px; position: relative;
}
.capability-card ul li::before {
  content: '✓'; position: absolute; left: 0; color: var(--purple); font-weight: 700;
}

/* HOW IT WORKS / WORKFLOW */
.how-it-works {
  padding: 100px 24px;
  background: var(--bg);
}
.how-it-works .section-header {
  text-align: center; max-width: 720px; margin: 0 auto 64px;
}
.how-it-works .section-header p {
  color: var(--text-secondary); font-size: 18px; line-height: 1.7;
}
.workflow-steps {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 32px; max-width: 1200px; margin: 0 auto;
  counter-reset: step;
}
.workflow-step {
  text-align: center; padding: 32px 24px; position: relative;
  counter-increment: step;
}
.workflow-step::before {
  content: counter(step);
  display: flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--purple); color: #fff;
  font-size: 20px; font-weight: 800;
  margin: 0 auto 20px;
}
.workflow-step h3 { font-size: 18px; margin-bottom: 8px; }
.workflow-step p { color: var(--text-secondary); font-size: 14px; line-height: 1.7; }

/* ═══ FEATURE SPLIT (from platform.css) ═══ */
.feature-split {
  display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center;
  max-width: 1200px; margin: 0 auto;
}
.feature-split.reverse { direction: rtl; }
.feature-split.reverse > * { direction: ltr; }
.feature-text .section-label { margin-bottom: 16px; }
.feature-text h2 { margin-bottom: 16px; }
.feature-text > p { color: var(--text-secondary); font-size: 17px; line-height: 1.7; margin-bottom: 24px; }
.feature-bullets {
  list-style: none; padding: 0; margin: 0;
}
.feature-bullets li {
  padding: 10px 0; font-size: 15px; color: var(--text-secondary); line-height: 1.6;
  border-bottom: 1px solid var(--border);
}
.feature-bullets li:last-child { border-bottom: none; }
.feature-bullets li strong { color: var(--text); }

/* FEATURE SECTIONS (alternating) */
.feature-section {
  padding: 100px 24px;
  background: var(--bg);
}
.feature-section.feature-alt {
  background: var(--bg-subtle);
}
.feature-section.feature-dark {
  background: var(--dark2); color: #fff;
}
.feature-section.feature-dark .section-label { color: var(--orange); }
.feature-section.feature-dark h2 { color: #fff; }
.feature-section.feature-dark p { color: rgba(255,255,255,0.7); }
.feature-section.feature-dark .feature-bullets li { color: rgba(255,255,255,0.7); border-color: rgba(255,255,255,0.1); }
.feature-section.feature-dark .feature-bullets li strong { color: #fff; }

/* ═══ MOCKUP CARDS ═══ */
.mock-card {
  background: #fff; border-radius: 16px; padding: 0;
  box-shadow: 0 8px 40px rgba(0,0,0,0.08); border: 1px solid var(--border);
  overflow: hidden;
}
.mock-label {
  background: #f8f8fa; padding: 14px 20px; font-size: 13px; font-weight: 600;
  color: var(--text-muted); border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
.online-badge { color: #22c55e; font-size: 12px; }

/* ═══ PIPELINE VISUAL ═══ */
.pipeline-visual {
  display: flex; gap: 0; overflow-x: auto; padding: 20px 0;
  max-width: 1200px; margin: 0 auto;
}
.pipeline-stage {
  flex: 1; min-width: 130px; text-align: center;
  padding: 20px 12px; position: relative;
  background: var(--purple-bg); border-right: 2px solid var(--purple-light);
}
.pipeline-stage:first-child { border-radius: 12px 0 0 12px; }
.pipeline-stage:last-child { border-radius: 0 12px 12px 0; border-right: none; background: var(--orange-light); }
.pipeline-stage .stage-name {
  font-size: 13px; font-weight: 700; color: var(--purple);
}
.pipeline-stage:last-child .stage-name { color: var(--orange-dark); }
.pipeline-stage .stage-icon { font-size: 24px; margin-bottom: 8px; display: block; }
.pipeline-arrow {
  position: absolute; right: -8px; top: 50%; transform: translateY(-50%);
  color: var(--purple-light); font-size: 14px; z-index: 1;
}

/* ═══ STAT BAR ═══ */
.stat-bar {
  background: var(--bg-light, #f8f7fa);
  padding: 48px 24px;
  border-top: 1px solid rgba(91,62,140,0.08);
  border-bottom: 1px solid rgba(91,62,140,0.08);
}
.stat-bar .container {
  display: flex; justify-content: center; align-items: center;
  gap: 0; max-width: 1000px; flex-wrap: wrap;
}
.stat-bar .stat-item {
  text-align: center; padding: 16px 40px;
  border-right: 1px solid rgba(91,62,140,0.12);
}
.stat-bar .stat-item:last-child { border-right: none; }
.stat-bar .stat-item .stat-number {
  font-size: 36px; font-weight: 800; color: var(--purple);
  margin-bottom: 4px; line-height: 1.1; letter-spacing: -0.5px;
}
.stat-bar .stat-item .stat-label {
  font-size: 13px; color: var(--text-muted, #666); font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.5px;
}

/* ═══ VALUE PROPS ═══ */
.value-props {
  background: var(--bg-light, #f8f7fa);
  padding: 64px 24px;
  border-top: 1px solid rgba(91,62,140,0.08);
  border-bottom: 1px solid rgba(91,62,140,0.08);
}
.value-props-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 32px; max-width: 1100px; margin: 0 auto;
}
.value-prop-card {
  text-align: center; padding: 32px 24px;
}
.value-prop-icon {
  width: 56px; height: 56px; border-radius: 14px;
  background: rgba(91,62,140,0.08);
  color: var(--purple);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
}
.value-prop-card h3 {
  font-size: 18px; font-weight: 700; color: var(--text-primary, #1a1a2e);
  margin: 0 0 10px; line-height: 1.3;
}
.value-prop-card p {
  font-size: 15px; line-height: 1.6; color: var(--text-secondary, #555);
  margin: 0;
}
@media (max-width: 768px) {
  .value-props-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
}
@media (max-width: 480px) {
  .value-props-grid { grid-template-columns: 1fr; gap: 20px; }
}

/* ═══ STAT CALLOUT (inline) ═══ */
.stat-callout {
  background: linear-gradient(135deg, var(--purple-dark), var(--purple));
  color: #fff; border-radius: 16px; padding: 48px;
  text-align: center; max-width: 800px; margin: 64px auto 0;
}
.stat-callout .stat-number {
  font-size: 48px; font-weight: 900; color: var(--orange);
  margin-bottom: 8px;
}
.stat-callout p { color: rgba(255,255,255,0.8); font-size: 18px; }

/* ═══ TRIGGER-ACTION-RESULT ═══ */
.trigger-block {
  background: #fff; border-radius: 16px; border: 1px solid var(--border);
  padding: 32px; margin-bottom: 24px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.trigger-block:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(91,62,140,0.06);
}
.trigger-block h3 { font-size: 20px; margin-bottom: 16px; display: flex; align-items: center; gap: 12px; }
.trigger-flow {
  display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; gap: 16px; align-items: start;
}
.trigger-flow-item {
  background: var(--bg-subtle); border-radius: 10px; padding: 16px;
  font-size: 14px; line-height: 1.6;
}
.trigger-flow-item strong {
  display: block; font-size: 11px; text-transform: uppercase;
  letter-spacing: 1px; color: var(--purple); margin-bottom: 6px;
}
.trigger-flow-arrow {
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: var(--orange); font-weight: 700; padding-top: 16px;
}

/* ═══ MESSAGE EXAMPLE ═══ */
.message-example {
  background: #fff; border-radius: 12px; border: 1px solid var(--border);
  padding: 20px 24px; margin-top: 16px; font-size: 14px; line-height: 1.7;
  color: var(--text-secondary); position: relative;
}
.message-example::before {
  content: '💬'; position: absolute; top: -12px; left: 20px;
  background: #fff; padding: 0 8px; font-size: 18px;
}
.message-example .msg-label {
  font-size: 11px; text-transform: uppercase; letter-spacing: 1px;
  color: var(--text-muted); margin-bottom: 8px; font-weight: 600;
}

/* ═══ CHAT THREAD (AI page) ═══ */
.chat-thread { padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.chat-bubble {
  max-width: 80%; padding: 12px 16px; border-radius: 16px;
  font-size: 14px; line-height: 1.6; position: relative;
}
.chat-bubble.incoming {
  background: #f0f0f5; align-self: flex-start; border-bottom-left-radius: 4px;
}
.chat-bubble.outgoing {
  background: var(--purple); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px;
}
.chat-time { display: block; font-size: 11px; margin-top: 6px; opacity: 0.6; }
.chat-status {
  text-align: center; font-size: 13px; color: #22c55e; font-weight: 600;
  padding: 12px; background: #f0fdf4; border-radius: 8px;
}

/* ═══ COMPARISON TABLE ═══ */
.comparison-table {
  width: 100%; max-width: 900px; margin: 0 auto; border-collapse: collapse;
  font-size: 15px;
}
.comparison-table th {
  text-align: left; padding: 16px 20px; font-weight: 700;
  border-bottom: 2px solid var(--border);
}
.comparison-table th:first-child { color: var(--text-muted); }
.comparison-table th:nth-child(2) { color: #dc2626; }
.comparison-table th:nth-child(3) { color: var(--purple); }
.comparison-table td {
  padding: 14px 20px; border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.comparison-table tr:hover td { background: var(--bg-subtle); }
.comparison-table .check { color: #22c55e; font-weight: 700; }
.comparison-table .cross { color: #dc2626; }

/* ═══ INTEGRATION MAP ═══ */
.integration-hub {
  display: grid; grid-template-columns: 1fr auto 1fr; gap: 32px; align-items: center;
  max-width: 900px; margin: 0 auto; padding: 40px 0;
}
.hub-center {
  width: 140px; height: 140px; border-radius: 50%;
  background: linear-gradient(135deg, var(--purple-dark), var(--purple));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 14px; text-align: center;
  box-shadow: 0 8px 40px rgba(91,62,140,0.3);
}
.hub-spokes {
  display: flex; flex-direction: column; gap: 16px;
}
.hub-spoke {
  background: #fff; border: 1px solid var(--border); border-radius: 12px;
  padding: 14px 20px; font-size: 14px; font-weight: 600;
  display: flex; align-items: center; gap: 10px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.hub-spoke:hover { transform: translateX(4px); box-shadow: 0 4px 16px rgba(0,0,0,0.06); }
.hub-spoke svg { flex-shrink: 0; color: var(--purple); }

/* ═══ NARRATIVE / STORY BLOCK ═══ */
.narrative-block {
  max-width: 720px; margin: 0 auto; padding: 64px 0;
}
.narrative-block h2 { margin-bottom: 24px; }
.narrative-block p {
  font-size: 17px; line-height: 1.8; color: var(--text-secondary); margin-bottom: 20px;
}
.narrative-block p strong { color: var(--text); }

/* ═══ TIMELINE ═══ */
.timeline {
  position: relative; max-width: 700px; margin: 0 auto; padding: 20px 0;
}
.timeline::before {
  content: ''; position: absolute; left: 28px; top: 0; bottom: 0;
  width: 3px; background: linear-gradient(to bottom, var(--purple), var(--orange));
  border-radius: 2px;
}
.timeline-item {
  position: relative; padding-left: 72px; margin-bottom: 40px;
}
.timeline-item:last-child { margin-bottom: 0; }
.timeline-dot {
  position: absolute; left: 18px; top: 4px;
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--purple); border: 3px solid #fff;
  box-shadow: 0 0 0 3px var(--purple-bg);
}
.timeline-item:last-child .timeline-dot { background: var(--orange); box-shadow: 0 0 0 3px var(--orange-light); }
.timeline-time {
  font-size: 12px; text-transform: uppercase; letter-spacing: 1px;
  color: var(--purple); font-weight: 700; margin-bottom: 4px;
}
.timeline-item h3 { font-size: 18px; margin-bottom: 6px; }
.timeline-item p { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

/* ═══ DASHBOARD METRICS ═══ */
.dashboard-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px; max-width: 900px; margin: 0 auto;
}
.dashboard-metric {
  background: #fff; border: 1px solid var(--border); border-radius: 14px;
  padding: 24px; text-align: center;
  transition: transform 0.2s;
}
.dashboard-metric:hover { transform: translateY(-4px); }
.dashboard-metric .metric-value {
  font-size: 36px; font-weight: 900; color: var(--purple); margin-bottom: 4px;
}
.dashboard-metric .metric-label {
  font-size: 13px; color: var(--text-muted); font-weight: 500; margin-bottom: 8px;
}
.dashboard-metric .metric-trend {
  font-size: 12px; font-weight: 700;
}
.dashboard-metric .metric-trend.up { color: #22c55e; }
.dashboard-metric .metric-trend.down { color: #dc2626; }

/* ═══ CROSS-LINKS ═══ */
.cross-links {
  padding: 60px 24px;
  background: var(--bg-subtle);
}
.cross-links .container { max-width: 900px; text-align: center; }
.cross-links h3 { margin-bottom: 24px; color: var(--text-muted); font-size: 16px; font-weight: 600; }
.cross-link-grid {
  display: flex; gap: 16px; justify-content: center; flex-wrap: wrap;
}
.cross-link-grid a {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 20px; font-size: 14px; font-weight: 600; color: var(--purple);
  text-decoration: none; transition: all 0.2s;
}
.cross-link-grid a:hover {
  border-color: var(--purple); background: var(--purple-bg);
  transform: translateY(-2px);
}

/* ═══ RESPONSIVE ═══ */
@media (max-width: 768px) {
  .feature-hero { padding: 140px 16px 80px; }
  .feature-hero p { font-size: 17px; }
  .feature-overview,
  .capabilities,
  .how-it-works,
  .feature-section { padding: 72px 24px; }
  .capability-grid { grid-template-columns: 1fr; }
  .workflow-steps { grid-template-columns: 1fr; }
  .feature-split { grid-template-columns: 1fr; gap: 40px; }
  .feature-split.reverse { direction: ltr; }
  .pipeline-visual { flex-wrap: wrap; }
  .pipeline-stage { min-width: auto; flex: 1 1 45%; border-radius: 8px !important; border-right: none; margin: 4px; }
  .trigger-flow { grid-template-columns: 1fr; }
  .trigger-flow-arrow { transform: rotate(90deg); padding: 0; }
  .integration-hub { grid-template-columns: 1fr; text-align: center; }
  .hub-center { margin: 0 auto; }
  .comparison-table { font-size: 13px; }
  .comparison-table th, .comparison-table td { padding: 10px 12px; }
  .stat-bar .stat-item { border-right: none; border-bottom: 1px solid rgba(91,62,140,0.08); padding: 20px 32px; flex: 1 1 50%; }
  .stat-bar .stat-item:nth-child(even) { border-left: 1px solid rgba(91,62,140,0.08); }
  .stat-bar .stat-item:nth-last-child(-n+2) { border-bottom: none; }
  .timeline::before { left: 18px; }
  .timeline-item { padding-left: 52px; }
  .timeline-dot { left: 8px; }
  .dashboard-grid { grid-template-columns: 1fr 1fr; }
}
