/* ==========================================================================
   orgmap.css — Org Map product page. Builds on colors_and_type.css + styles.css
   + pages.css (loaded first). Org Map lives in the XO OS / Campaigns blue
   family; --om is its base accent, --om-deep its slightly deeper identity tone.
   ========================================================================== */
:root {
  --om: var(--accent-xos);
  --om-deep: var(--xos-primary-700);
  --om-soft: var(--accent-xos-soft);
}

/* eyebrow + active nav */
.eyebrow.xos .dot { background: var(--om); }
.drawer-item.is-active { background: var(--om-soft); }
.drawer-item.is-active .drawer-ti { color: var(--om-deep); }
.drawer-current {
  position: absolute; top: 12px; right: 12px;
  font-size: 9.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--om-deep); background: oklch(1 0 0 / 0.7); border: 1px solid var(--om);
  padding: 2px 6px; border-radius: 6px;
}

/* ---------- Hero visual: compact org tree on dark card ---------- */
.dark-card.xos::before {
  background: radial-gradient(ellipse 52% 42% at 82% 8%, oklch(0.66 0.13 229 / 0.4), transparent 60%),
              radial-gradient(ellipse 46% 40% at 8% 92%, oklch(0.53 0.1 230 / 0.32), transparent 60%);
}
.dark-card.xos .dc-label .dot { background: var(--om); }

.om-tree { display: flex; align-items: center; gap: 0; }
.om-root {
  flex-shrink: 0; width: 132px; position: relative; z-index: 2;
  background: linear-gradient(180deg, var(--om), var(--om-deep));
  border-radius: 13px; padding: 16px 14px; color: white;
  box-shadow: 0 8px 22px oklch(0.5 0.1 230 / 0.45);
}
.om-root .rt-k { font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.8; }
.om-root .rt-n { font-size: 15px; font-weight: 700; line-height: 1.2; margin-top: 3px; }
.om-root .rt-m { font-size: 11px; opacity: 0.85; margin-top: 8px; display: flex; align-items: center; gap: 5px; }
.om-root::after {
  content: ""; position: absolute; left: 100%; top: 50%; transform: translateY(-50%);
  width: 40px; height: 2px; background: oklch(0.72 0.12 224 / 0.5);
}
.om-stack { flex-shrink: 0; width: 150px; display: flex; flex-direction: column; position: relative; z-index: 2; }
.om-stack .om-root { width: auto; }
.om-ghost {
  display: flex; align-items: center; gap: 8px;
  background: oklch(1 0 0 / 0.05); border: 1px solid oklch(1 0 0 / 0.1);
  border-radius: 11px; padding: 9px 12px; margin: 0 10px;
  color: var(--slate-400); font-size: 12px; font-weight: 700; white-space: nowrap;
  opacity: 0.6; transform: scale(0.9);
}
.om-ghost:first-child { margin-bottom: -8px; }
.om-ghost:last-child { margin-top: -8px; }
.om-ghost .og-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--slate-500); flex-shrink: 0; }
.om-branches { flex: 1; position: relative; padding-left: 40px; display: flex; flex-direction: column; gap: 9px; }
.om-branches::before {
  content: ""; position: absolute; left: 40px; top: 18px; bottom: 18px; width: 2px;
  background: oklch(0.72 0.12 224 / 0.5);
}
.om-leaf {
  position: relative; margin-left: 22px;
  background: oklch(1 0 0 / 0.06); border: 1px solid oklch(1 0 0 / 0.1);
  border-radius: 10px; padding: 10px 12px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.om-leaf::before {
  content: ""; position: absolute; left: -22px; top: 50%; transform: translateY(-50%);
  width: 22px; height: 2px; background: oklch(0.72 0.12 224 / 0.5);
}
.om-leaf::after {
  content: ""; position: absolute; left: -22px; top: 50%; transform: translate(-50%, -50%);
  width: 9px; height: 9px; border-radius: 50%; background: var(--om);
  box-shadow: 0 0 0 3px var(--slate-950);
}
.om-leaf .lf-n { font-size: 13px; font-weight: 500; color: var(--slate-100); }
.om-badge {
  flex-shrink: 0; font-size: 11px; font-weight: 700; color: var(--om);
  background: oklch(0.66 0.13 229 / 0.16); border: 1px solid oklch(0.66 0.13 229 / 0.4);
  border-radius: 9999px; padding: 3px 9px;
}
@media (max-width: 480px) {
  .om-tree { flex-direction: column; align-items: stretch; gap: 18px; }
  .om-root { width: auto; }
  .om-stack { width: auto; }
  .om-root::after { display: none; }
  .om-branches { padding-left: 0; }
  .om-branches::before { left: 22px; }
}

/* ---------- Hero logo ---------- */
.om-hero-logo {
  height: 48px;
  width: auto;
  display: block;
}

/* ---------- Problem: pain cards ---------- */
.pain-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 880px) { .pain-grid { grid-template-columns: 1fr; } }
.pain-card {
  background: white; border: 1px solid var(--slate-200); border-radius: 16px;
  padding: 26px 24px; transition: box-shadow var(--dur-base) var(--ease), transform var(--dur-base) var(--ease);
}
.pain-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.pain-card .pc-num {
  width: 34px; height: 34px; border-radius: 9px; margin-bottom: 16px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px; color: var(--om-deep);
  background: var(--om-soft); border: 1px solid oklch(0.66 0.13 229 / 0.25);
}
.pain-card h4 { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; margin: 0 0 9px; color: var(--slate-950); }
.pain-card p { font-size: 14px; line-height: 1.6; color: var(--slate-600); margin: 0; }

/* ---------- Process steps (XOS-themed, on dark card) ---------- */
.om-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 900px) { .om-steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .om-steps { grid-template-columns: 1fr; } }
.om-step {
  position: relative; background: oklch(1 0 0 / 0.04); border: 1px solid oklch(1 0 0 / 0.09);
  border-radius: 14px; padding: 22px 20px; display: flex; flex-direction: column; gap: 11px;
}
.om-step-header {
  display: flex; align-items: center; gap: 9px;
}
.om-step .st-num {
  width: 26px; height: 26px; border-radius: 8px; flex-shrink: 0;
  background: var(--om); color: white;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px;
}
.om-step .st-ic { color: var(--om); flex-shrink: 0; }
.om-step .st-ic svg { width: 18px; height: 18px; }
.om-step h4 { font-size: 15px; font-weight: 600; margin: 0; color: var(--slate-50); }
.om-step p { font-size: 13px; line-height: 1.55; color: var(--slate-400); margin: 0; }

/* ---------- Strategic Account Plan mock (What You Get) ---------- */
.plan-doc {
  background: white; border: 1px solid var(--slate-200); border-radius: 16px;
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.plan-doc .pd-head {
  padding: 18px 20px; border-bottom: 1px solid var(--slate-200);
  display: flex; align-items: center; gap: 12px; background: var(--om-soft);
}
.plan-doc .pd-ic {
  width: 36px; height: 36px; border-radius: 9px; flex-shrink: 0;
  background: linear-gradient(180deg, var(--om), var(--om-deep)); color: white;
  display: flex; align-items: center; justify-content: center;
}
.plan-doc .pd-ic svg { width: 19px; height: 19px; }
.plan-doc .pd-t { font-size: 14px; font-weight: 700; color: var(--slate-950); }
.plan-doc .pd-s { font-size: 11.5px; color: var(--slate-600); margin-top: 1px; }
.plan-doc .pd-body { padding: 16px 20px 20px; }
.plan-div {
  border: 1px solid var(--slate-200); border-radius: 11px; padding: 12px 14px; margin-bottom: 10px;
}
.plan-div:last-child { margin-bottom: 0; }
.plan-div .pdv-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.plan-div .pdv-n { font-size: 13.5px; font-weight: 700; color: var(--slate-900); }
.plan-div .pdv-tag {
  font-size: 10.5px; font-weight: 700; color: var(--om-deep);
  background: var(--om-soft); border-radius: 9999px; padding: 3px 9px;
  white-space: nowrap; flex-shrink: 0;
}
.plan-contacts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.plan-contact {
  display: flex; align-items: center; gap: 7px;
  font-size: 11.5px; font-weight: 500; color: var(--slate-700);
  background: var(--slate-50); border: 1px solid var(--slate-200); border-radius: 8px; padding: 5px 9px;
}
.plan-contact .pc-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--om); flex-shrink: 0; }
.plan-bar {
  display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 6px;
  margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--slate-200);
  font-size: 12px; color: var(--slate-600); line-height: 1.5;
}
.plan-bar b { color: var(--slate-950); }
.plan-bar span:last-child { max-width: 220px; }

/* Mobile: h1-section wraps cleanly */
@media (max-width: 640px) {
  .section-head .h1-section { white-space: normal !important; overflow-wrap: break-word; }
  .plan-bar span:last-child { max-width: 100%; }
}

/* product screenshot frame (What You Get) */
.plan-shot {
  border-radius: 14px; overflow: hidden;
  border: 1px solid var(--slate-200); box-shadow: var(--shadow-lg); background: white;
}
.plan-shot img { display: block; width: 100%; height: auto; }

/* ---------- Signature Division Map ---------- */
.divmap-wrap {
  background: white; border: 1px solid var(--slate-200); border-radius: 20px;
  box-shadow: var(--shadow-md); padding: clamp(24px, 4vw, 48px);
  position: relative; overflow: hidden;
}
.divmap-wrap::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
  background-image: linear-gradient(var(--slate-100) 1px, transparent 1px),
                    linear-gradient(90deg, var(--slate-100) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 20%, transparent 80%);
  mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 20%, transparent 80%);
}
.divmap { position: relative; display: flex; align-items: center; gap: 0; }
.divmap-center { flex-shrink: 0; width: 196px; margin-right: 76px; position: relative; z-index: 2; }
.dm-stack { display: flex; flex-direction: column; }
.dm-ghost {
  display: flex; align-items: center; gap: 9px;
  background: var(--slate-100); border: 1px solid var(--slate-200); border-radius: 13px;
  padding: 11px 15px; margin: 0 12px;
  font-size: 13px; font-weight: 700; color: var(--slate-500);
  opacity: 0.72; transform: scale(0.93);
}
.dm-ghost:first-child { margin-bottom: -10px; }
.dm-ghost:last-child { margin-top: -10px; }
.dm-ghost .dg-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--slate-400); flex-shrink: 0; }
.dm-ghost .dg-hint { margin-left: auto; font-size: 10.5px; font-weight: 600; color: var(--slate-400); white-space: nowrap; }
.dm-root {
  position: relative; z-index: 2;
  background: linear-gradient(180deg, var(--om), var(--om-deep)); color: white;
  border-radius: 16px; padding: 22px 20px; box-shadow: 0 14px 34px oklch(0.5 0.1 230 / 0.32);
}
.dm-root .dr-k { font-size: 10.5px; font-weight: 600; letter-spacing: 0.07em; text-transform: uppercase; opacity: 0.82; }
.dm-root .dr-n { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; margin-top: 5px; }
.dm-root .dr-stats { display: flex; gap: 16px; margin-top: 18px; }
.dm-root .dr-stat .v { font-size: 19px; font-weight: 800; line-height: 1; }
.dm-root .dr-stat .l { font-size: 10px; opacity: 0.85; margin-top: 4px; letter-spacing: 0.03em; }
.divmap-center::after {
  content: ""; position: absolute; left: 100%; top: 50%; transform: translateY(-50%);
  width: 76px; height: 2px; background: oklch(0.78 0.1 224 / 0.65); z-index: 1;
}

.divmap-branches { flex: 1; position: relative; display: flex; flex-direction: column; gap: 10px; }
.divmap-branches::before {
  content: ""; position: absolute; left: 0; top: 30px; bottom: 30px; width: 2px;
  background: linear-gradient(180deg, var(--om), oklch(0.78 0.1 224 / 0.5));
}
.branch {
  position: relative; margin-left: 44px; min-height: 60px;
  background: white; border: 1px solid var(--slate-200); border-radius: 12px;
  padding: 12px 16px; display: flex; align-items: center; justify-content: space-between; gap: 14px;
  transition: border-color var(--dur-base) var(--ease), box-shadow var(--dur-base) var(--ease), transform var(--dur-base) var(--ease);
  cursor: default;
}
.branch::before {
  content: ""; position: absolute; left: -44px; top: 50%; transform: translateY(-50%);
  width: 44px; height: 2px; background: oklch(0.78 0.1 224 / 0.65);
}
.branch::after {
  content: ""; position: absolute; left: -44px; top: 50%; transform: translate(-50%, -50%);
  width: 12px; height: 12px; border-radius: 50%; background: var(--om);
  box-shadow: 0 0 0 4px white, 0 0 0 5px var(--slate-200);
  transition: transform var(--dur-base) var(--ease);
}
.branch:hover {
  border-color: var(--om); box-shadow: 0 10px 26px oklch(0.5 0.1 230 / 0.16); transform: translateX(3px); z-index: 5;
}
.branch:hover::after { transform: translate(-50%, -50%) scale(1.25); }
.branch .br-l { min-width: 0; }
.branch .br-n { font-size: 14.5px; font-weight: 700; color: var(--slate-950); letter-spacing: -0.01em; }
.branch .br-f { font-size: 12px; color: var(--slate-500); margin-top: 2px; }
.branch .br-badge {
  flex-shrink: 0; display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; color: var(--om-deep);
  background: var(--om-soft); border: 1px solid oklch(0.66 0.13 229 / 0.3);
  border-radius: 9999px; padding: 5px 11px;
}
.branch .br-badge svg { width: 12px; height: 12px; }
/* hover popover with sample titles — overlay, does not affect layout */
.branch .br-pop {
  position: absolute; left: 16px; right: 16px; top: calc(100% - 4px); z-index: 20;
  background: var(--slate-950); color: var(--slate-100);
  border-radius: 11px; padding: 12px 14px; box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity var(--dur-base) var(--ease), transform var(--dur-base) var(--ease), visibility var(--dur-base);
}
.branch:hover .br-pop { opacity: 1; visibility: visible; transform: translateY(0); }
.br-pop .bp-k { font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--slate-500); margin-bottom: 8px; }
.br-pop .bp-titles { display: flex; flex-wrap: wrap; gap: 6px; }
.br-pop .bp-t {
  font-size: 11.5px; font-weight: 500; color: var(--slate-200);
  background: oklch(1 0 0 / 0.07); border: 1px solid oklch(1 0 0 / 0.1);
  border-radius: 7px; padding: 4px 8px;
}
.branch:nth-last-child(-n+3) .br-pop { top: auto; bottom: calc(100% - 4px); transform: translateY(6px); }
.branch:nth-last-child(-n+3):hover .br-pop { transform: translateY(0); }
@media (max-width: 760px) {
  .divmap { flex-direction: column; align-items: stretch; gap: 22px; }
  .divmap-center { width: auto; margin-right: 0; }
  .divmap-center::after { display: none; }
  .divmap-branches::before { left: 22px; }
  .dm-root .dr-n { font-size: 20px; }
}

/* ---------- Use cases ---------- */
.usecase-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 880px) { .usecase-grid { grid-template-columns: 1fr; } }
.usecase {
  background: white; border: 1px solid var(--slate-200); border-radius: 16px; padding: 26px 24px;
  display: flex; flex-direction: column; gap: 12px;
  transition: box-shadow var(--dur-base) var(--ease), transform var(--dur-base) var(--ease), border-color var(--dur-base) var(--ease);
}
.usecase:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); border-color: oklch(0.66 0.13 229 / 0.4); }
.usecase .uc-ic {
  width: 40px; height: 40px; border-radius: 11px;
  background: var(--om-soft); color: var(--om-deep);
  display: flex; align-items: center; justify-content: center;
}
.usecase .uc-ic svg { width: 21px; height: 21px; }
.usecase h4 { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; margin: 0; color: var(--slate-950); }
.usecase p { font-size: 14px; line-height: 1.6; color: var(--slate-600); margin: 0; }

/* ---------- Org Map vs Campaigns ---------- */
.vs-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; position: relative; }
@media (max-width: 820px) { .vs-grid { grid-template-columns: 1fr; } }
.vs-card {
  background: white; border: 1px solid var(--slate-200); border-radius: 18px; padding: 30px 28px;
  display: flex; flex-direction: column;
}
.vs-card.is-om { border-color: var(--om); box-shadow: 0 12px 30px oklch(0.5 0.1 230 / 0.12); }
.vs-card .vs-head { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.vs-card .vs-logo {
  width: 40px; height: 40px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  background: var(--slate-50); border: 1px solid var(--slate-200);
}
.vs-card .vs-logo img { width: 26px; height: 26px; object-fit: contain; }
.vs-card.is-om .vs-logo { background: var(--om-soft); border-color: transparent; }
.vs-card .vs-name { font-size: 18px; font-weight: 800; letter-spacing: -0.02em; color: var(--slate-950); }
.vs-card .vs-tag { font-size: 12.5px; font-weight: 600; color: var(--slate-500); }
.vs-card.is-om .vs-tag { color: var(--om-deep); }
.vs-list { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 12px; }
.vs-list li {
  display: flex; gap: 11px; align-items: flex-start;
  font-size: 14.5px; line-height: 1.5; color: var(--slate-700);
}
.vs-list li::before { content: "→"; color: var(--slate-400); font-weight: 700; flex-shrink: 0; }
.vs-card.is-om .vs-list li::before { color: var(--om); }
.vs-closing {
  text-align: center; max-width: 640px; margin: 34px auto 0;
  font-size: clamp(16px, 1.7vw, 19px); font-weight: 600; color: var(--slate-950); letter-spacing: -0.01em;
  text-wrap: balance;
}
.vs-closing .hl { color: var(--om-deep); }
