/* ============================================================
   XPLUG.SMARTNOTIFIER — section components (extends soc.css)
   Colour carries state here: amber = escalating, green =
   acknowledged, red = critical. Never decorative.
   ============================================================ */

/* ---- subpage header (lighter than the product .phero) ---- */
.pagehead { padding-top: clamp(32px, 4.5vw, 56px); padding-bottom: clamp(28px, 4vw, 48px); }
.pagehead h1 { font-size: clamp(32px, 4.6vw, 54px); line-height: 1.05; letter-spacing: -0.03em; font-weight: 600; margin: 0 0 18px; max-width: 20ch; }
.pagehead .lede { font-size: 17px; color: var(--text-2); line-height: 1.65; margin: 0; max-width: 68ch; }
.pagehead .lede + .lede { margin-top: 14px; }

/* ---- escalation timeline ---- */
.tl { list-style: none; margin: 0; padding: 0; position: relative; }
.tl::before { content: ""; position: absolute; left: 6px; top: 10px; bottom: 10px; width: 1px; background: var(--line-2); }
.tl-row { display: grid; grid-template-columns: 14px 78px 1fr; gap: 14px; align-items: start; padding: 11px 0; position: relative; }
.tl-row .pin { width: 13px; height: 13px; border-radius: 50%; border: 2px solid var(--line-3); background: var(--bg-1); margin-top: 3px; position: relative; z-index: 1; }
.tl-row .at { font-family: var(--mono); font-size: 11px; letter-spacing: 0.02em; color: var(--text-3); margin-top: 3px; white-space: nowrap; }
.tl-row .ev { font-size: 13.5px; color: var(--text); line-height: 1.45; font-weight: 500; }
.tl-row .sub { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.03em; color: var(--text-3); margin-top: 4px; line-height: 1.5; }

.tl-row.is-alarm .pin { border-color: var(--red); }
.tl-row.is-sent  .pin { border-color: var(--line-3); }
.tl-row.is-esc   .pin { border-color: var(--orange); background: rgba(255,122,26,0.18); }
.tl-row.is-esc .ev { color: var(--orange); }
.tl-row.is-ack   .pin { border-color: var(--green); background: var(--green); }
.tl-row.is-ack .ev { color: var(--green); }
.sev-crit { color: var(--red); font-weight: 600; }

.tl-cap { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--text-3); line-height: 1.6; max-width: 62ch; }

/* one orchestrated moment: the timeline reveals line by line, once */
.tl-anim .tl-row { opacity: 0; animation: tlIn .5s cubic-bezier(.2,.8,.2,1) both; animation-delay: calc(var(--i) * 260ms + 200ms); }
@keyframes tlIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---- the problem: four flat statements, no cards ---- */
.probs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.prob { background: var(--bg); padding: 26px 24px 26px 0; }
.prob .n { font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; color: var(--text-4); margin-bottom: 12px; }
.prob p { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--text-2); }

/* ---- two-up platform cards ---- */
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.duo-card { background: var(--bg-1); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 28px; }
.duo-card h3 { font-size: 20px; font-weight: 600; letter-spacing: -0.015em; margin: 0 0 6px; }
.duo-card .sup { font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--cyan); margin-bottom: 16px; }
.duo-card p { font-size: 14px; color: var(--text-2); line-height: 1.6; margin: 0 0 16px; }
.duo-card p:last-child { margin-bottom: 0; }

/* ---- key/value fact rows inside a card ---- */
.facts { border-top: 1px solid var(--line); }
.facts .f { display: grid; grid-template-columns: 132px 1fr; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.facts .f .k { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.facts .f .v { font-size: 13.5px; color: var(--text); line-height: 1.5; }
.facts .f .v code { font-family: var(--mono); font-size: 11.5px; color: var(--cyan); background: var(--bg-3); border: 1px solid var(--line-2); border-radius: 4px; padding: 1px 6px; }

/* ---- quiet channel row (not a feature showcase) ---- */
.chanrow { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.chanrow .c { background: var(--bg-1); padding: 20px 22px; display: flex; gap: 13px; align-items: flex-start; }
.chanrow .c .mk { width: 28px; height: 28px; border-radius: 7px; display: grid; place-items: center; flex: none; background: var(--bg-3); border: 1px solid var(--line-2); }
.chanrow .c .mk svg { width: 15px; height: 15px; }
.chanrow .c .nm { font-size: 14px; font-weight: 500; margin-bottom: 3px; }
.chanrow .c .ln { font-size: 12.5px; color: var(--text-2); line-height: 1.5; }

/* ---- plain data table (severity mapping etc.) ---- */
.dtable-wrap { overflow-x: auto; }
.dtable { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 460px; }
.dtable th, .dtable td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.dtable thead th { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3); font-weight: 500; background: var(--bg-2); border-bottom-color: var(--line-2); }
.dtable tbody td { color: var(--text-2); }
.dtable tbody td:first-child { color: var(--text); font-weight: 500; }
.dtable tbody td.num { font-family: var(--mono); font-size: 12px; }
.dtable tbody tr:last-child td { border-bottom: 0; }
.dtable-wrap { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; overflow-x: auto; }

/* ---- long-form block: heading + prose + optional list ---- */
.blocks { display: flex; flex-direction: column; gap: clamp(36px, 4vw, 56px); max-width: 74ch; }
.block h3 { font-size: 21px; font-weight: 600; letter-spacing: -0.015em; margin: 0 0 14px; }
.block p { font-size: 15.5px; line-height: 1.7; color: var(--text-2); margin: 0 0 16px; }
.block p:last-child { margin-bottom: 0; }
.block p strong { color: var(--text); font-weight: 600; }
.block code { font-family: var(--mono); font-size: 0.86em; background: var(--bg-3); border: 1px solid var(--line-2); border-radius: 4px; padding: 1px 6px; color: var(--cyan); }
.block .lead-in { font-size: 16.5px; color: var(--text); }

/* ---- rule / definition list ---- */
.deflist { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.deflist li { display: grid; grid-template-columns: 190px 1fr; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.deflist .t { font-size: 14.5px; font-weight: 600; color: var(--text); }
.deflist .d { font-size: 14px; color: var(--text-2); line-height: 1.6; }
.deflist .d code { font-family: var(--mono); font-size: 12px; background: var(--bg-3); border: 1px solid var(--line-2); border-radius: 4px; padding: 1px 6px; color: var(--cyan); }

/* ---- plain bullet list with cyan markers ---- */
.plain { margin: 0; padding-left: 20px; font-size: 15px; line-height: 1.7; color: var(--text-2); }
.plain li { margin-bottom: 9px; }
.plain li::marker { color: var(--cyan); }
.plain strong { color: var(--text); font-weight: 600; }
.plain code { font-family: var(--mono); font-size: 0.86em; background: var(--bg-3); border: 1px solid var(--line-2); border-radius: 4px; padding: 1px 6px; color: var(--cyan); }

/* ---- pull note / caveat ---- */
.note-line { margin-top: 26px; padding: 18px 20px; background: var(--bg-1); border: 1px solid var(--line); border-left: 2px solid var(--cyan-d); border-radius: 0 var(--r-lg) var(--r-lg) 0; font-size: 14.5px; line-height: 1.65; color: var(--text-2); max-width: 74ch; }
.note-line strong { color: var(--text); font-weight: 600; }

/* grid items default to min-width:auto, so a wide max-width on a child can
   push the column past its container on a phone */
.contact > * { min-width: 0; }

/* ---- active section nav link ---- */
.nav-links a.here { color: var(--cyan); }

/* ---- responsive ---- */
@media (max-width: 1080px) {
  .probs { grid-template-columns: 1fr 1fr; }
  .chanrow { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .duo { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  /* several CTAs in this section are full sentences — .btn's nowrap would
     otherwise widen the page rather than the label wrapping */
  .btn { white-space: normal; }
  .probs { grid-template-columns: 1fr; }
  .prob { padding-right: 0; }
  .chanrow { grid-template-columns: 1fr; }
  /* .ev/.sub are not grid items — the wrapper div is the one to place */
  .tl-row { grid-template-columns: 14px 1fr; row-gap: 3px; }
  .tl-row .at { grid-column: 2; margin-top: 0; }
  .tl-row > div { grid-column: 2; min-width: 0; }
  .deflist li { grid-template-columns: 1fr; gap: 6px; }
  .facts .f { grid-template-columns: 1fr; gap: 4px; }
}

/* the reduced-motion block in soc.css shortens durations but not delays,
   which would strand a staggered row at opacity 0 — clear both here. */
@media (prefers-reduced-motion: reduce) {
  .tl-anim .tl-row { opacity: 1; animation: none !important; animation-delay: 0ms !important; }
}
