/* =========================================================
   CRM Services page — CrmServices.cshtml
   Depends on: common.css (tokens, buttons, reveal, page-hero,
   pill-badge, hero-blob, slideDownFade keyframe)
   ========================================================= */

/* ---------- Feature tabs ---------- */
.feature-tabs { border: none; gap: 8px; flex-wrap: wrap; margin-bottom: 48px; }
.feature-tabs .nav-link {
  border: 1px solid var(--border); border-radius: 999px; color: var(--ink-soft); font-weight: 600;
  padding: 10px 18px; font-size: 0.9rem; display: flex; align-items: center; gap: 8px; transition: all 0.3s var(--ease);
}
.feature-tabs .nav-link:hover { border-color: var(--primary); color: var(--primary); }
.feature-tabs .nav-link.active { background: var(--gradient-brand); color: #fff; border-color: transparent; box-shadow: var(--shadow-sm); }

.tab-kicker { font-weight: 700; color: var(--primary); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; }
.feature-tab-content h3 { font-size: 1.7rem; margin: 10px 0 22px; }
.feature-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.feature-list li { display: flex; gap: 10px; color: var(--ink-soft); font-size: 0.98rem; align-items: flex-start; }
.feature-list i { color: var(--green); margin-top: 4px; flex-shrink: 0; }

.feature-visual { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; min-height: 260px; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.visual-row { display: flex; align-items: center; gap: 10px; font-size: 0.92rem; color: var(--ink-soft); background: #fff; border-radius: 10px; padding: 10px 14px; }
.visual-row strong { margin-left: auto; color: var(--ink); }
.visual-bar { height: 8px; background: var(--border); border-radius: 999px; overflow: hidden; margin-top: 6px; }
.visual-bar span { display: block; height: 100%; width: var(--w); background: var(--gradient-brand); border-radius: 999px; animation: growRight 1.2s var(--ease) both; }
@keyframes growRight { from { transform: scaleX(0); transform-origin: left; } to { transform: scaleX(1); transform-origin: left; } }

.workflow-visual { align-items: center; }
.workflow-node {
  background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 12px 18px; font-weight: 600;
  font-size: 0.9rem; text-align: center; box-shadow: var(--shadow-sm); position: relative; width: 100%; max-width: 260px; margin: 0 auto;
}
.node-branch span { display: block; font-size: 0.75rem; font-weight: 500; color: var(--ink-soft); }
.node-end { background: var(--gradient-brand); color: #fff; border-color: transparent; }
.workflow-line { width: 2px; height: 26px; background: var(--border); margin: 0 auto; position: relative; }
.workflow-line::after {
  content: ""; position: absolute; top: -4px; left: -3px; width: 8px; height: 8px; border-radius: 50%;
  background: var(--primary); animation: travelDown 2s linear infinite;
}
@keyframes travelDown { 0% { top: -4px; opacity: 1; } 90% { opacity: 1; } 100% { top: 100%; opacity: 0; } }

.kanban-visual { display: flex; gap: 14px; align-items: flex-start; }
.kanban-col { flex: 1; background: #fff; border-radius: 12px; padding: 12px; border: 1px solid var(--border); }
.kanban-title { display: block; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 10px; }
.kanban-card { background: var(--surface); border-radius: 8px; padding: 10px 12px; font-size: 0.85rem; font-weight: 600; margin-bottom: 8px; transition: transform 0.3s ease; }
.kanban-card:hover { transform: translateY(-3px); }
.kanban-won { background: rgba(22, 199, 141, 0.15); color: #0e8f66; }

.phone-visual { display: flex; justify-content: center; }
.phone-shell { width: 200px; background: var(--surface-dark); border-radius: 32px; padding: 14px 10px; box-shadow: var(--shadow-lg); animation: floatY 5s ease-in-out infinite; }
.phone-notch { width: 60px; height: 8px; background: #000; border-radius: 6px; margin: 0 auto 10px; }
.phone-screen { background: #fff; border-radius: 20px; padding: 16px 12px; min-height: 220px; }
.phone-row { display: flex; align-items: center; gap: 8px; font-size: 0.78rem; font-weight: 600; color: var(--ink-soft); margin-bottom: 12px; }
.phone-row i { color: var(--primary); }
.phone-progress { height: 6px; background: var(--border); border-radius: 999px; overflow: hidden; margin-top: 16px; }
.phone-progress span { display: block; height: 100%; width: 72%; background: var(--gradient-brand); animation: growRight 1.4s var(--ease) both; }

.mock-chart { display: flex; align-items: flex-end; gap: 8px; height: 90px; margin-bottom: 20px; }
.mock-chart span {
  flex: 1; height: var(--h); border-radius: 6px 6px 0 0;
  background: var(--gradient-brand); opacity: 0.85;
  animation: growUp 1.2s var(--ease) both;
}
.mock-chart-lg { height: 160px; }
@keyframes growUp { from { transform: scaleY(0); transform-origin: bottom; } to { transform: scaleY(1); transform-origin: bottom; } }

.integration-visual { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.integration-visual span {
  aspect-ratio: 1; display: flex; align-items: center; justify-content: center; background: #fff; border-radius: 16px;
  border: 1px solid var(--border); font-size: 1.6rem; color: var(--primary); transition: transform 0.3s var(--ease);
}
.integration-visual span:hover { transform: translateY(-6px) scale(1.05); box-shadow: var(--shadow-md); }

/* ---------- Smart data layer (bento grid) ---------- */
.smart-section { background: #faf7f1; }

.serif-heading {
  font-family: "Fraunces", "Sora", serif;
  font-weight: 400;
  font-size: clamp(1.9rem, 3.4vw, 2.7rem);
  line-height: 1.2;
  margin-bottom: 16px;
}
.serif-heading em { font-style: italic; font-weight: 300; color: var(--primary); }
.smart-lead { font-size: 1.08rem; margin: 0 auto 50px; max-width: 560px; }

.bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: minmax(150px, auto);
  gap: 22px;
}
.bento-card {
  background: #fff; border: 1px solid var(--border); border-radius: 22px;
  padding: 30px; transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.bento-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.bento-card h4 { font-size: 1.05rem; margin-bottom: 8px; }
.bento-card p { font-size: 0.92rem; margin: 0; }
.bento-icon {
  width: 48px; height: 48px; border-radius: 13px; background: var(--gradient-soft); color: var(--primary);
  display: flex; align-items: center; justify-content: center; font-size: 1.25rem; margin-bottom: 16px;
}

.bento-large {
  grid-column: span 2; grid-row: span 2;
  display: flex; flex-direction: column;
  background: linear-gradient(155deg, #12132c, #1e1b4b);
  color: #fff; border: none; position: relative; overflow: hidden;
}
.bento-large::before {
  content: ""; position: absolute; top: -80px; right: -80px; width: 260px; height: 260px; border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.45), transparent 70%);
}
.bento-large > * { position: relative; }
.bento-eyebrow {
  display: inline-flex; align-items: center; gap: 6px; width: fit-content;
  background: rgba(255, 255, 255, 0.08); color: #c7bdfb; font-weight: 700; font-size: 0.78rem;
  text-transform: uppercase; letter-spacing: 0.05em; padding: 6px 12px; border-radius: 999px; margin-bottom: 16px;
}
.bento-large h3 { color: #fff; font-size: 1.5rem; margin-bottom: 12px; }
.bento-large p { color: #b9bcdb; margin-bottom: 24px; }

.ai-mock { margin-top: auto; }
.ai-input {
  display: flex; align-items: center; gap: 10px; background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 999px; padding: 12px 18px;
  font-size: 0.88rem; color: #d8daf0; margin-bottom: 14px;
}
.ai-input i { color: #a78bfa; }
.ai-response {
  display: flex; gap: 12px; background: rgba(255, 255, 255, 0.05); border-radius: 16px; padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08); animation: slideDownFade 0.6s var(--ease);
}
.ai-avatar {
  width: 32px; height: 32px; border-radius: 50%; background: var(--gradient-brand); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 0.85rem; flex-shrink: 0;
  animation: pulseGlow 2.4s ease-in-out infinite;
}
@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 0 rgba(124, 58, 237, 0.5); }
  50% { box-shadow: 0 0 16px rgba(124, 58, 237, 0.7); }
}
.ai-response strong { color: #fff; font-size: 0.9rem; }
.ai-response span { display: block; color: #a9acce; font-size: 0.85rem; margin-top: 4px; line-height: 1.5; }

@media (max-width: 991px) {
  .bento-grid { grid-template-columns: repeat(2, 1fr); }
  .bento-large { grid-column: span 2; grid-row: span 1; }
}
@media (max-width: 575px) {
  .bento-grid { grid-template-columns: 1fr; }
  .bento-large { grid-column: span 1; }
}

/* ---------- Long-form content sections ---------- */
.content-section h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin-bottom: 20px; }
.content-section-alt { background: var(--surface); }
.content-prose p { font-size: 1rem; margin-bottom: 18px; }
.content-prose p:last-child { margin-bottom: 0; }
.content-visual { min-height: auto; align-items: stretch; }
.content-visual-title { font-size: 0.95rem; font-weight: 700; color: var(--ink); margin-bottom: 18px; }

/* ---------- Why section ---------- */
.why-card { background: var(--surface); border-radius: var(--radius); padding: 26px; height: 100%; transition: transform 0.3s var(--ease); }
.why-card:hover { transform: translateY(-6px); }
.why-number { font-family: "Sora", sans-serif; font-size: 2rem; font-weight: 800; color: var(--primary); margin-bottom: 6px; }
.why-card p { margin: 0; font-size: 0.92rem; }
