/*
 * sf-service-teaser — generic, brand-agnostic feature/service teaser row.
 *
 * Self-contained copy of the canonical home feature + dashboard styles (from
 * page-home-salesfision), every rule scoped under [data-sf-block="sf-service-teaser"].
 * Class names are kept IDENTICAL to the canonical so any shared front-end CSS/JS
 * still binds. Brand colors are lifted into CSS custom properties (original hexes
 * preserved as defaults); the badge glassmorphism is recolored per-instance via
 * inline --sf-st-badge-* props set in render.php.
 */
[data-sf-block="sf-service-teaser"] {
  --sf-st-accent: #e63946;
  --sf-st-accent-glow: #ff7043;
  --sf-st-text: #fff;
  --sf-st-muted: #888;
  /* badge defaults (green); overridden inline per badge_color */
  --sf-st-badge-bg: rgba(34,197,94,0.12);
  --sf-st-badge-border: rgba(34,197,94,0.45);
  --sf-st-badge-text: #86efac;
  --sf-st-badge-glow: 0 0 18px rgba(34,197,94,0.3), 0 0 40px rgba(34,197,94,0.12);
}

/* ── Section scaffold + decoration ── */
[data-sf-block="sf-service-teaser"] .page-deco {
  position: absolute;
  opacity: 0.28;
  pointer-events: none;
  z-index: 0;
  filter: drop-shadow(0 0 18px rgba(220,40,50,0.45));
}

/* ── Feature row + text side ── */
[data-sf-block="sf-service-teaser"] .feature-row {
  display: flex;
  align-items: center;
  gap: 100px;
  padding: 160px 90px;
  max-width: 1400px;
  margin: 0 auto;
}
[data-sf-block="sf-service-teaser"] .feature-text { flex: 1; }
[data-sf-block="sf-service-teaser"] .feature-text h2 {
  font-size: 52px;
  font-weight: 800;
  color: var(--sf-st-text);
  margin-bottom: 24px;
  line-height: 1.2;
}
[data-sf-block="sf-service-teaser"] .feature-text p {
  font-size: 18px;
  color: var(--sf-st-muted);
  line-height: 1.8;
  margin-bottom: 36px;
}
[data-sf-block="sf-service-teaser"] .feature-text .feature-sub {
  font-size: 20px;
  color: #bbb;
  font-style: italic;
  line-height: 1.5;
  margin-bottom: 24px;
}
[data-sf-block="sf-service-teaser"] .feature-text .see-more {
  font-size: 14px;
  font-weight: 600;
  color: var(--sf-st-text);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: 10px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.14);
  letter-spacing: 0.3px;
  text-decoration: none;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s, transform 0.3s, color 0.3s;
}
[data-sf-block="sf-service-teaser"] .feature-text .see-more::after {
  content: '\2192';
  display: inline-block;
  transition: transform 0.3s;
}
[data-sf-block="sf-service-teaser"] .feature-text .see-more:hover {
  background: rgba(230,57,70,0.18);
  border-color: rgba(230,57,70,0.55);
  box-shadow: 0 0 28px rgba(230,57,70,0.25), 0 8px 32px rgba(0,0,0,0.35);
  transform: translateY(-2px);
  color: var(--sf-st-text);
}
[data-sf-block="sf-service-teaser"] .feature-text .see-more:hover::after { transform: translateX(5px); }

/* ── Recolorable glassmorphism badge ── */
[data-sf-block="sf-service-teaser"] .sf-st-badge {
  display: inline-block;
  background: var(--sf-st-badge-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--sf-st-badge-border);
  border-radius: 10px;
  padding: 5px 13px;
  font-size: 10px;
  font-weight: 700;
  color: var(--sf-st-badge-text);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 20px;
  box-shadow: var(--sf-st-badge-glow);
}

/* ── Media side ── */
[data-sf-block="sf-service-teaser"] .feature-img {
  flex: 1;
  border-radius: 16px;
  overflow: hidden;
  background: transparent;
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
}
[data-sf-block="sf-service-teaser"] .feature-img img { width: 100%; border-radius: 16px; }

/* ── Dashboard mockup (shared by analytics + kanban presets) ── */
[data-sf-block="sf-service-teaser"] .sf-dash {
  max-width: 1140px; margin: 56px auto 0;
  background: linear-gradient(180deg, #14171f 0%, #0e1018 100%);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px; overflow: hidden;
  box-shadow: 0 14px 40px rgba(0,0,0,0.32), 0 0 0 1px rgba(232,54,66,0.04) inset;
}
[data-sf-block="sf-service-teaser"] .sf-dash-chrome {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 16px; background: rgba(255,255,255,0.02);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
[data-sf-block="sf-service-teaser"] .sf-dash-dots { display: flex; gap: 6px; }
[data-sf-block="sf-service-teaser"] .sf-dash-dots span { width: 11px; height: 11px; border-radius: 50%; background: rgba(255,255,255,0.18); }
[data-sf-block="sf-service-teaser"] .sf-dash-dots span:nth-child(1) { background: #ff5f57; }
[data-sf-block="sf-service-teaser"] .sf-dash-dots span:nth-child(2) { background: #febc2e; }
[data-sf-block="sf-service-teaser"] .sf-dash-dots span:nth-child(3) { background: #28c840; }
[data-sf-block="sf-service-teaser"] .sf-dash-url {
  flex: 1; text-align: center; font-size: 12.5px; color: rgba(255,255,255,0.55);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: rgba(0,0,0,0.35); padding: 6px 14px; border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.06);
}
[data-sf-block="sf-service-teaser"] .sf-dash-url .lock { color: #28c840; margin-right: 6px; font-size: 9px; vertical-align: middle; }

[data-sf-block="sf-service-teaser"] .sf-dash-body { display: grid; grid-template-columns: 220px 1fr; min-height: 440px; }
[data-sf-block="sf-service-teaser"] .sf-dash-side {
  background: rgba(0,0,0,0.25); border-right: 1px solid rgba(255,255,255,0.06);
  padding: 18px 14px; font-size: 13px;
}
[data-sf-block="sf-service-teaser"] .sf-dash-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 22px; }
[data-sf-block="sf-service-teaser"] .sf-dash-brand-dot {
  width: 30px; height: 30px; border-radius: 8px;
  background: linear-gradient(135deg, var(--sf-st-accent) 0%, var(--sf-st-accent-glow) 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800; color: #fff; letter-spacing: 0.5px;
}
[data-sf-block="sf-service-teaser"] .sf-dash-brand-dot img { width: 18px; height: 18px; }
[data-sf-block="sf-service-teaser"] .sf-dash-brand-name { font-size: 12.5px; font-weight: 700; color: #fff; line-height: 1.25; }
[data-sf-block="sf-service-teaser"] .sf-dash-brand-name small { display: block; font-weight: 500; font-size: 10px; color: rgba(255,255,255,0.4); margin-top: 1px; }
[data-sf-block="sf-service-teaser"] .sf-dash-side h6 {
  font-size: 10px; font-weight: 700; color: rgba(255,255,255,0.4);
  letter-spacing: 1.4px; text-transform: uppercase; margin: 18px 0 10px; padding: 0 6px;
}
[data-sf-block="sf-service-teaser"] .sf-dash-side ul { list-style: none; padding: 0; margin: 0 0 6px; }
[data-sf-block="sf-service-teaser"] .sf-dash-side li {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px; border-radius: 7px; color: rgba(255,255,255,0.7); font-size: 12.5px;
  cursor: default;
}
[data-sf-block="sf-service-teaser"] .sf-dash-side li.active { background: rgba(232,54,66,0.12); color: #fff; }
[data-sf-block="sf-service-teaser"] .sf-dash-side li .dot { width: 5px; height: 5px; border-radius: 50%; background: rgba(255,255,255,0.35); flex-shrink: 0; }
[data-sf-block="sf-service-teaser"] .sf-dash-side li.active .dot { background: var(--sf-st-accent); box-shadow: 0 0 8px var(--sf-st-accent); }
[data-sf-block="sf-service-teaser"] .sf-dash-side li .badge {
  margin-left: auto; background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.7);
  padding: 1px 8px; border-radius: 999px; font-size: 10.5px; font-weight: 700;
}

[data-sf-block="sf-service-teaser"] .sf-dash-main { padding: 22px 24px; min-width: 0; }
[data-sf-block="sf-service-teaser"] .sf-dash-topline { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 18px; gap: 14px; flex-wrap: wrap; }
[data-sf-block="sf-service-teaser"] .sf-dash-topline h3 { font-size: 16px; font-weight: 700; color: #fff; margin: 0; line-height: 1.3; }
[data-sf-block="sf-service-teaser"] .sf-dash-topline h3 small { display: block; font-size: 11.5px; font-weight: 500; color: rgba(255,255,255,0.4); margin-top: 4px; }
[data-sf-block="sf-service-teaser"] .sf-dash-pills { display: flex; gap: 4px; background: rgba(0,0,0,0.4); padding: 3px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.06); }
[data-sf-block="sf-service-teaser"] .sf-dash-pills .pill {
  background: transparent; border: 0; color: rgba(255,255,255,0.6);
  font-size: 11.5px; font-weight: 600; padding: 5px 12px; border-radius: 6px; cursor: pointer;
}
[data-sf-block="sf-service-teaser"] .sf-dash-pills .pill.active { background: rgba(232,54,66,0.18); color: #fff; }

[data-sf-block="sf-service-teaser"] .sf-dash-funnel {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px;
  background: rgba(0,0,0,0.2); border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px; padding: 14px; margin-bottom: 18px;
}
[data-sf-block="sf-service-teaser"] .funnel-cell { padding: 0 6px; border-right: 1px solid rgba(255,255,255,0.05); }
[data-sf-block="sf-service-teaser"] .funnel-cell:last-child { border-right: 0; }
[data-sf-block="sf-service-teaser"] .funnel-cell .stage { font-size: 10.5px; font-weight: 600; color: rgba(255,255,255,0.5); text-transform: uppercase; letter-spacing: 0.6px; margin-bottom: 6px; }
[data-sf-block="sf-service-teaser"] .funnel-cell .stage b { color: var(--sf-st-accent); font-weight: 800; }
[data-sf-block="sf-service-teaser"] .funnel-cell .num { font-size: 19px; font-weight: 800; color: #fff; line-height: 1; }
[data-sf-block="sf-service-teaser"] .funnel-cell .delta { font-size: 11px; font-weight: 700; margin-top: 4px; }
[data-sf-block="sf-service-teaser"] .funnel-cell .delta.up { color: #5fd49b; }
[data-sf-block="sf-service-teaser"] .funnel-cell .delta.down { color: #ff7c7c; }

[data-sf-block="sf-service-teaser"] .sf-dash-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
[data-sf-block="sf-service-teaser"] .sf-dash-card { background: rgba(0,0,0,0.25); border: 1px solid rgba(255,255,255,0.05); border-radius: 12px; padding: 16px; }
[data-sf-block="sf-service-teaser"] .sf-dash-card h5 { font-size: 13.5px; font-weight: 700; color: #fff; margin: 0 0 2px; }
[data-sf-block="sf-service-teaser"] .sf-dash-card .h5-sub { font-size: 11px; color: rgba(255,255,255,0.4); margin-bottom: 12px; }
[data-sf-block="sf-service-teaser"] .sf-dash-card .chart-wrap { width: 100%; height: 130px; }
[data-sf-block="sf-service-teaser"] .sf-dash-card .chart-wrap svg { width: 100%; height: 100%; display: block; }
[data-sf-block="sf-service-teaser"] .sf-dash-card .chart-grid line { stroke: rgba(255,255,255,0.05); stroke-dasharray: 2 4; }

[data-sf-block="sf-service-teaser"] .sf-work-list { display: flex; flex-direction: column; gap: 8px; }
[data-sf-block="sf-service-teaser"] .work-item {
  display: grid; grid-template-columns: 78px 1fr auto; gap: 12px; align-items: center;
  padding: 10px 12px; border-radius: 8px; background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.04);
}
[data-sf-block="sf-service-teaser"] .work-item .key { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 10.5px; color: rgba(255,255,255,0.5); }
[data-sf-block="sf-service-teaser"] .work-item .title { font-size: 12.5px; font-weight: 600; color: #fff; line-height: 1.3; }
[data-sf-block="sf-service-teaser"] .work-item .title small { display: block; font-size: 10.5px; font-weight: 500; color: rgba(255,255,255,0.4); margin-top: 2px; }
[data-sf-block="sf-service-teaser"] .work-item .status { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; padding: 3px 8px; border-radius: 4px; white-space: nowrap; }
[data-sf-block="sf-service-teaser"] .work-item .status.doing { background: rgba(96,165,250,0.18); color: #93c5fd; }
[data-sf-block="sf-service-teaser"] .work-item .status.review { background: rgba(255,179,71,0.18); color: #ffd28a; }
[data-sf-block="sf-service-teaser"] .work-item .status.todo { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.6); }
[data-sf-block="sf-service-teaser"] .work-item .status.done { background: rgba(95,212,155,0.18); color: #8eebbb; }

@media (max-width: 900px) {
  [data-sf-block="sf-service-teaser"] .sf-dash-body { grid-template-columns: 1fr; }
  [data-sf-block="sf-service-teaser"] .sf-dash-side { display: none; }
  [data-sf-block="sf-service-teaser"] .sf-dash-funnel { grid-template-columns: repeat(3, 1fr); }
  [data-sf-block="sf-service-teaser"] .funnel-cell:nth-child(3n) { border-right: 0; }
  [data-sf-block="sf-service-teaser"] .sf-dash-cols { grid-template-columns: 1fr; }
  [data-sf-block="sf-service-teaser"] .sf-dash-url { font-size: 10.5px; }
}

/* ── Analytics feature dashboard (replaces feature-img) ── */
[data-sf-block="sf-service-teaser"] .feature-dash { padding: 0 !important; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-dash { max-width: none !important; margin: 0 !important; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-funnel .funnel-cell .num { font-size: 16px; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-topline h3 { font-size: 14.5px; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-card .chart-wrap { height: 120px; }
@media (max-width: 1100px) {
  [data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-side { display: none; }
  [data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-body { grid-template-columns: 1fr; min-height: 0; }
  [data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-funnel { grid-template-columns: repeat(3, 1fr); gap: 4px; }
  [data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-funnel .funnel-cell { border-bottom: 1px solid rgba(255,255,255,0.05); }
  [data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-funnel .funnel-cell:nth-child(3n) { border-right: 0; }
  [data-sf-block="sf-service-teaser"] .feature-dash .sf-dash-funnel .funnel-cell:nth-child(n+4) { border-bottom: 0; }
}

/* ── Tighter work items inside the analytics dash ── */
[data-sf-block="sf-service-teaser"] .feature-dash .sf-work-list .work-item {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 7px 9px;
  min-width: 0;
}
[data-sf-block="sf-service-teaser"] .feature-dash .sf-work-list .work-item .key { display: none; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-work-list .work-item .title { font-size: 12px; min-width: 0; overflow: hidden; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-work-list .work-item .title small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
[data-sf-block="sf-service-teaser"] .feature-dash .sf-work-list .work-item .status { font-size: 9.5px; padding: 2px 6px; }

/* ── Kanban board (kanban preset) ── */
[data-sf-block="sf-service-teaser"] .feature-board { padding: 0 !important; }
[data-sf-block="sf-service-teaser"] .feature-board .sf-dash { max-width: none !important; margin: 0 !important; }
[data-sf-block="sf-service-teaser"] .feature-board .kanban { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
[data-sf-block="sf-service-teaser"] .feature-board .kanban-col {
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 10px;
  padding: 10px 8px;
  display: flex; flex-direction: column; gap: 8px;
  min-width: 0;
}
[data-sf-block="sf-service-teaser"] .feature-board .kb-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.5px;
  text-transform: uppercase; color: rgba(255,255,255,0.7);
  padding: 0 4px 6px; border-bottom: 1px solid rgba(255,255,255,0.04);
}
[data-sf-block="sf-service-teaser"] .feature-board .kb-dot { width: 7px; height: 7px; border-radius: 50%; }
[data-sf-block="sf-service-teaser"] .feature-board .kb-dot-todo   { background: rgba(255,255,255,0.5); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-dot-doing  { background: #93c5fd; box-shadow: 0 0 6px rgba(147,197,253,0.7); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-dot-review { background: #ffd28a; box-shadow: 0 0 6px rgba(255,210,138,0.7); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-dot-done   { background: #5fd49b; box-shadow: 0 0 6px rgba(95,212,155,0.7); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-title { flex: 1; }
[data-sf-block="sf-service-teaser"] .feature-board .kb-count {
  background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.7);
  font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 999px;
}
[data-sf-block="sf-service-teaser"] .feature-board .kb-card {
  background: linear-gradient(180deg, #1c1f29 0%, #14171f 100%);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 8px;
  padding: 9px 10px;
  display: flex; flex-direction: column; gap: 7px;
  cursor: grab;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  transition: transform 0.15s ease, border-color 0.15s ease;
}
[data-sf-block="sf-service-teaser"] .feature-board .kb-card:hover { transform: translateY(-1px); border-color: rgba(230,57,70,0.3); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-card-done { opacity: 0.55; }
[data-sf-block="sf-service-teaser"] .feature-board .kb-card-done .kb-text { text-decoration: line-through; }
[data-sf-block="sf-service-teaser"] .feature-board .kb-tag {
  align-self: flex-start;
  font-size: 9px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase;
  padding: 2px 7px; border-radius: 999px;
}
[data-sf-block="sf-service-teaser"] .feature-board .tag-purple { background: rgba(167,139,250,0.18); color: #c4b5fd; border: 1px solid rgba(167,139,250,0.32); }
[data-sf-block="sf-service-teaser"] .feature-board .tag-blue   { background: rgba(96,165,250,0.18);  color: #93c5fd; border: 1px solid rgba(96,165,250,0.32); }
[data-sf-block="sf-service-teaser"] .feature-board .tag-red    { background: rgba(230,57,70,0.18);   color: #fca5a5; border: 1px solid rgba(230,57,70,0.4); }
[data-sf-block="sf-service-teaser"] .feature-board .tag-orange { background: rgba(255,179,71,0.18);  color: #ffd28a; border: 1px solid rgba(255,179,71,0.32); }
[data-sf-block="sf-service-teaser"] .feature-board .tag-green  { background: rgba(95,212,155,0.18);  color: #8eebbb; border: 1px solid rgba(95,212,155,0.32); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-text { font-size: 12px; font-weight: 600; color: #fff; line-height: 1.35; }
[data-sf-block="sf-service-teaser"] .feature-board .kb-meta { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
[data-sf-block="sf-service-teaser"] .feature-board .kb-avatar {
  width: 20px; height: 20px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 9px; font-weight: 800; color: #fff; letter-spacing: 0.3px;
  border: 1.5px solid rgba(0,0,0,0.4);
}
[data-sf-block="sf-service-teaser"] .feature-board .a-1 { background: linear-gradient(135deg, #e63946, #ff7043); }
[data-sf-block="sf-service-teaser"] .feature-board .a-2 { background: linear-gradient(135deg, #5AA9FF, #1F4A8B); }
[data-sf-block="sf-service-teaser"] .feature-board .a-3 { background: linear-gradient(135deg, #B78CFF, #5A3FB7); }
[data-sf-block="sf-service-teaser"] .feature-board .kb-priority {
  font-size: 9px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase;
  padding: 2px 6px; border-radius: 4px;
}
[data-sf-block="sf-service-teaser"] .feature-board .kb-priority.high { background: rgba(230,57,70,0.25); color: #fca5a5; }

@media (max-width: 1100px) {
  [data-sf-block="sf-service-teaser"] .feature-board .sf-dash-side { display: none; }
  [data-sf-block="sf-service-teaser"] .feature-board .sf-dash-body { grid-template-columns: 1fr; min-height: 0; }
  [data-sf-block="sf-service-teaser"] .feature-board .kanban { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  [data-sf-block="sf-service-teaser"] .feature-board .kanban { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  [data-sf-block="sf-service-teaser"] .feature-row { flex-direction: column; gap: 48px; padding: 80px 24px; }
}
