/* AWS Lambda page only. Loaded via `extra: crm, p-aws-lambda`. Every class is scoped with .palm- */

/* ---------- hero: event sources pulse into one function ---------- */
.palm-hero .palm-hero__grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); }
.palm-hero .pg-h1 { font-size: clamp(34px, 1.3rem + 2.4vw, 54px); }
.palm-hero .crm-sub { max-width: 46ch; }
.palm-chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 0; padding: 0; list-style: none; }
.palm-chips li { display: flex; flex-direction: column; gap: 3px; min-width: 120px; padding: 10px 14px; border-radius: 12px; background: #fff; border: 1px solid #DCE7EF; box-shadow: 0 10px 20px -16px rgba(8,34,56,.5); }
.palm-chips b { font: 800 18px/1 var(--f-display); letter-spacing: -.02em; color: #E07B00; }
.palm-chips span { font: 500 12.5px/1.25 var(--f-body); color: #64748B; }
.palm-badge img { width: 64px !important; padding: 6px 8px; border-radius: 10px; background: #fff; border: 1px solid #E2E8F0; }

.palm-ev { position: relative; margin: 0; }
.palm-ev__stage { position: relative; aspect-ratio: 520 / 380; border-radius: 24px; background: radial-gradient(circle at 50% 50%, rgba(255,153,0,.13), transparent 42%), linear-gradient(160deg, #0B2540, #0A3A63 60%, #0B4F5C); box-shadow: 0 50px 90px -48px rgba(8,34,56,.65), inset 0 0 0 1px rgba(255,255,255,.08); overflow: hidden; }
.palm-ev__wires { position: absolute; inset: 0; width: 100%; height: 100%; }
.palm-w { fill: none; stroke: rgba(159,192,216,.35); stroke-width: 2; stroke-dasharray: 4 7; vector-effect: non-scaling-stroke; transition: stroke .3s; }
.palm-w.is-hot { stroke: #FFB81C; stroke-dasharray: none; }
.palm-w--out.is-hot { stroke: #5FD3F3; }
.palm-dot { fill: #FFB81C; opacity: 0; filter: drop-shadow(0 0 6px rgba(255,184,28,.9)); }
.palm-ev__src, .palm-ev__out { position: absolute; top: 0; bottom: 0; display: flex; flex-direction: column; justify-content: space-around; margin: 0; padding: 4% 0; list-style: none; width: 30%; }
.palm-ev__src { left: 2.5%; }
.palm-ev__out { right: 2.5%; }
.palm-ev__src li, .palm-ev__out li { display: flex; align-items: center; gap: 8px; padding: 8px 9px; border-radius: 12px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); color: #DCE8F2; font: 400 11px/1.25 var(--f-body); transition: background .3s, border-color .3s, transform .35s cubic-bezier(.2,1.4,.4,1); }
.palm-ev__src img, .palm-ev__out img, .palm-ev__src svg { flex: none; width: 24px; height: 24px; padding: 3px; border-radius: 7px; background: #fff; }
.palm-ev__src svg { fill: none; stroke: #1D3F8F; stroke-width: 2; stroke-linecap: round; }
.palm-ev__src b, .palm-ev__out b { display: block; font: 700 12px/1.2 var(--f-body); color: #fff; }
.palm-ev__src span, .palm-ev__out span { min-width: 0; overflow-wrap: anywhere; }
.palm-ev__src li.is-hot { background: rgba(255,184,28,.16); border-color: rgba(255,184,28,.6); transform: translateX(4px); }
.palm-ev__out li { opacity: .55; }
.palm-ev__out li.is-hot { opacity: 1; background: rgba(95,211,243,.14); border-color: rgba(95,211,243,.6); transform: translateX(-4px); }
.palm-ev__fn { position: absolute; left: 50%; top: 50%; width: 17%; aspect-ratio: 1; transform: translate(-50%, -50%); display: grid; place-items: center; border-radius: 22px; background: #fff; box-shadow: 0 0 0 6px rgba(255,153,0,.18), 0 20px 40px -18px rgba(0,0,0,.6); }
.palm-ev__fn img { width: 72%; height: auto; }
.palm-ev__ring { position: absolute; inset: -6px; border-radius: 26px; border: 2px solid #FFB81C; opacity: 0; }
.palm-ev__fn.is-hot .palm-ev__ring { animation: palm-ring .7s ease-out; }
@keyframes palm-ring { from { opacity: 1; transform: scale(1); } to { opacity: 0; transform: scale(1.45); } }
.palm-ev__ms { position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%); padding: 4px 9px; border-radius: 999px; background: rgba(8,34,56,.75); border: 1px solid rgba(255,255,255,.16); font: 600 10.5px/1 ui-monospace, SFMono-Regular, Menlo, monospace; color: #FFD27A; white-space: nowrap; }
.palm-ev__cap { display: flex; align-items: center; gap: 10px; margin-top: 12px; font: 500 13px/1.4 var(--f-body); color: #64748B; }
.palm-ev__cap span { padding: 3px 8px; border-radius: 999px; background: #FFF6DB; border: 1px solid #F8DF9A; font: 700 10.5px/1 var(--f-body); letter-spacing: .06em; text-transform: uppercase; color: #92400E; }

/* ---------- what it's good for ---------- */
.palm-fit__grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 22px; margin-top: 40px; }
.palm-fit__col { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; align-content: start; }
.palm-fit__col--yes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.palm-fit__col li { position: relative; padding: 22px 22px 22px 58px; border-radius: 18px; background: #fff; border: 1px solid #E2E8F0; }
.palm-fit__col li::before { content: ""; position: absolute; left: 20px; top: 22px; width: 24px; height: 24px; border-radius: 8px; background: #DDF4EF center / 14px no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230D9488' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7'/%3E%3C/svg%3E"); }
.palm-fit__col--no li { background: #FBFCFD; border-style: dashed; border-color: #CBD5E1; }
.palm-fit__col--no li::before { background-color: #FDECEC; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23C2410C' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M7 7l10 10M17 7L7 17'/%3E%3C/svg%3E"); }
.palm-fit__col b { display: block; margin-bottom: 6px; font: 700 17px/1.3 var(--f-display); color: #082238; }
.palm-fit__col p { margin: 0; font-size: 15px; line-height: 1.6; }

/* ---------- services ---------- */
.palm-svc { background: linear-gradient(180deg, #F3F7F9, #fff); }
.palm-svc__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; margin-top: 40px; }
.palm-svc__card { grid-column: span 2; display: flex; flex-direction: column; padding: 24px; border-radius: 20px; background: #fff; border: 1px solid #E2E8F0; border-top: 4px solid var(--c); transition: transform .35s cubic-bezier(.2,.7,.1,1), box-shadow .35s; }
.palm-svc__card:nth-child(4), .palm-svc__card:nth-child(5) { grid-column: span 3; }
.palm-svc__card:hover { transform: translateY(-4px); box-shadow: 0 24px 40px -28px rgba(8,34,56,.45); }
.palm-svc__ic { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: var(--bg); }
.palm-svc__ic svg { width: 24px; height: 24px; fill: none; stroke: var(--c); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.palm-svc__card h3 { margin: 16px 0 8px; font: 700 19px/1.3 var(--f-display); color: #082238; }
.palm-svc__card p { margin: 0; font-size: 15px; line-height: 1.6; }
.palm-svc__card .palm-svc__tag { margin-top: auto; padding-top: 16px; font: 600 12.5px/1.35 var(--f-body); color: var(--c); }

/* ---------- story: the trace ---------- */
.palm-trace { margin-top: 40px; padding: 24px 24px 18px; border-radius: 22px; background: #0B1F33; color: #DCE8F2; box-shadow: 0 40px 70px -48px rgba(8,34,56,.7); }
.palm-trace__head { display: flex; justify-content: space-between; margin-left: 170px; margin-right: 130px; padding-bottom: 10px; border-bottom: 1px solid rgba(255,255,255,.1); font: 600 10.5px/1 ui-monospace, SFMono-Regular, Menlo, monospace; color: #7F9DB5; }
.palm-trace__row { display: grid; grid-template-columns: 170px minmax(0, 1fr) 130px; align-items: center; gap: 0; padding: 16px 0; border-bottom: 1px dashed rgba(255,255,255,.1); }
.palm-trace__lbl { margin: 0; font: 400 12px/1.3 var(--f-body); color: #8FB3CC; }
.palm-trace__lbl b { display: block; font: 700 15px/1.2 var(--f-display); color: #fff; }
.palm-trace__bars { position: relative; height: 92px; margin: 0; padding: 0; list-style: none; background-image: linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px); background-size: 25% 100%; }
.palm-bar { position: absolute; left: calc(var(--s) * 1%); width: calc(var(--w) * 1%); height: 16px; border-radius: 4px; background: var(--bc); transform-origin: left center; transition: transform .6s cubic-bezier(.6,.1,.3,1) calc(var(--s) * 12ms); }
.palm-bar:nth-child(1) { top: 0; } .palm-bar:nth-child(2) { top: 19px; } .palm-bar:nth-child(3) { top: 38px; } .palm-bar:nth-child(4) { top: 57px; } .palm-bar:nth-child(5) { top: 76px; }
.palm-trace__row:nth-of-type(3) .palm-bar:nth-child(2) { top: 30px; }
.palm-trace__row:nth-of-type(3) .palm-bar:nth-child(3) { top: 60px; }
.palm-bar span { position: absolute; left: calc(100% + 8px); top: 50%; transform: translateY(-50%); white-space: nowrap; font: 600 11px/1 var(--f-body); color: #DCE8F2; }
.palm-bar--gw { --bc: #8B5CF6; } .palm-bar--init { --bc: #FFB81C; } .palm-bar--sec { --bc: #3FB97A; } .palm-bar--zoho { --bc: #00A3D9; } .palm-bar--ok { --bc: #94A3B8; }
.palm-bar--init span { left: 10px; color: #082238; }
.palm-bar--zoho span { left: 10px; color: #04263F; }
.palm-trace__sum { margin: 0; text-align: right; font: 400 11.5px/1.35 var(--f-body); color: #8FB3CC; }
.palm-trace__sum b { display: block; font: 800 20px/1 var(--f-display); color: #FFD27A; }
.palm-trace__note { margin: 12px 0 0; font: 400 12px/1.4 var(--f-body); color: #7F9DB5; }
.palm-trace.is-arm .palm-bar { transform: scaleX(0); }
.palm-trace.is-in .palm-bar { transform: scaleX(1); }

.palm-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 28px 0 0; padding: 0; list-style: none; counter-reset: ps; }
.palm-steps li { position: relative; padding: 20px; border-radius: 18px; background: #fff; border: 1px solid #E2E8F0; }
.palm-steps li::after { content: ""; position: absolute; top: 31px; right: -13px; width: 10px; height: 2px; background: #CBD5E1; }
.palm-steps li:last-child::after { display: none; }
.palm-steps li:nth-child(2) { background: #FFF8E6; border-color: #FFE0A0; }
.palm-steps__t { display: inline-block; padding: 4px 9px; border-radius: 999px; background: #0B1F33; font: 700 11px/1 ui-monospace, SFMono-Regular, Menlo, monospace; color: #FFD27A; }
.palm-steps h3 { margin: 12px 0 6px; font: 700 17px/1.3 var(--f-display); color: #082238; }
.palm-steps p { margin: 0; font-size: 14.5px; line-height: 1.6; }
.palm-trip__fix { margin: 22px 0 0; padding: 16px 20px; border-left: 4px solid #FFB81C; border-radius: 0 14px 14px 0; background: #F3F7F9; font-size: 15px; line-height: 1.6; max-width: 90ch; }

/* ---------- interactive: cost calculator ---------- */
.palm-calc__box { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 0; margin-top: 40px; border-radius: 24px; overflow: hidden; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.05); }
.palm-calc__in { padding: 28px; }
.palm-calc__presets { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 24px; font: 600 12px/1 var(--f-body); color: #9FC0D8; letter-spacing: .04em; text-transform: uppercase; }
.palm-calc__presets button { padding: 8px 12px; border-radius: 999px; border: 1px solid rgba(255,255,255,.22); background: transparent; color: #fff; font: 600 13px/1 var(--f-body); text-transform: none; letter-spacing: 0; cursor: pointer; transition: background .2s, border-color .2s; }
.palm-calc__presets button:hover, .palm-calc__presets button.is-on { background: rgba(255,184,28,.16); border-color: #FFB81C; }
.palm-calc__presets button:focus-visible { outline: 2px solid #FFB81C; outline-offset: 2px; }
.palm-sl { display: block; margin: 0 0 22px; }
.palm-sl > span { display: flex; justify-content: space-between; gap: 10px; font: 600 14.5px/1.3 var(--f-body); color: #fff; }
.palm-sl b { color: #FFB81C; font-variant-numeric: tabular-nums; white-space: nowrap; }
.palm-sl small { display: block; margin-top: 4px; font: 400 12.5px/1.4 var(--f-body); color: #8FB3CC; }
.palm-sl input[type=range] { width: 100%; margin: 10px 0 0; accent-color: #FFB81C; cursor: pointer; }
.palm-calc__opts { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.palm-seg { display: inline-flex; padding: 4px; border-radius: 12px; background: rgba(0,0,0,.25); border: 1px solid rgba(255,255,255,.12); }
.palm-seg label { position: relative; cursor: pointer; }
.palm-seg input, .palm-tog input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.palm-seg span { display: block; padding: 8px 14px; border-radius: 9px; font: 600 13.5px/1 var(--f-body); color: #BFD3E2; transition: background .2s, color .2s; }
.palm-seg input:checked + span { background: #FFB81C; color: #082238; }
.palm-seg input:focus-visible + span, .palm-tog input:focus-visible + span { outline: 2px solid #5FD3F3; outline-offset: 2px; }
.palm-tog { position: relative; display: inline-flex; cursor: pointer; }
.palm-tog span { display: inline-flex; align-items: center; gap: 10px; font: 600 13.5px/1.2 var(--f-body); color: #DCE8F2; }
.palm-tog span::before { content: ""; flex: none; width: 36px; height: 20px; border-radius: 999px; background: rgba(255,255,255,.2); box-shadow: inset 0 0 0 2px transparent; transition: background .2s; }
.palm-tog span::after { content: ""; position: absolute; left: 3px; top: 50%; width: 14px; height: 14px; margin-top: -7px; border-radius: 50%; background: #fff; transition: transform .2s; }
.palm-tog input:checked + span::before { background: #3FB97A; }
.palm-tog input:checked + span::after { transform: translateX(16px); }

.palm-calc__out { display: flex; flex-direction: column; padding: 28px; background: rgba(4,18,32,.45); border-left: 1px solid rgba(255,255,255,.1); color: #DCE8F2; }
.palm-calc__big { margin: 0; }
.palm-calc__big small { display: block; font: 600 12px/1 var(--f-body); letter-spacing: .08em; text-transform: uppercase; color: #9FC0D8; }
.palm-calc__big b { display: block; margin: 10px 0 2px; font: 800 clamp(40px, 2rem + 2vw, 58px)/1 var(--f-display); letter-spacing: -.03em; color: #fff; font-variant-numeric: tabular-nums; }
.palm-calc__big span { font: 500 14px/1 var(--f-body); color: #8FB3CC; }
.palm-calc__lines { margin: 22px 0 0; display: grid; gap: 8px; }
.palm-calc__lines div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,.1); }
.palm-calc__lines dt { font: 600 14px/1.3 var(--f-body); color: #fff; }
.palm-calc__lines dt small { display: block; font: 400 12px/1.3 var(--f-body); color: #8FB3CC; }
.palm-calc__lines dd { margin: 0; font: 700 15px/1.3 var(--f-body); color: #FFD27A; font-variant-numeric: tabular-nums; }
.palm-calc__meter { display: flex; height: 10px; margin-top: 20px; border-radius: 999px; overflow: hidden; background: rgba(255,255,255,.1); }
.palm-calc__meter i { display: block; height: 100%; width: 0; transition: width .35s ease; }
.palm-calc__meter i:first-child { background: #3FB97A; }
.palm-calc__meter i:last-child { background: #FFB81C; }
.palm-calc__legend { display: flex; gap: 16px; margin: 8px 0 0; font: 500 12px/1.2 var(--f-body); color: #9FC0D8; }
.palm-calc__legend span::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 2px; vertical-align: 1px; }
.palm-calc__legend .is-free::before { background: #3FB97A; }
.palm-calc__legend .is-paid::before { background: #FFB81C; }
.palm-calc__say { margin: 18px 0 0; font: 400 14.5px/1.55 var(--f-body); color: #DCE8F2; }
.palm-calc__say b { color: #fff; }
.palm-calc__arm { margin: 10px 0 0; font: 500 13px/1.5 var(--f-body); color: #7EE0B0; }
.palm-calc__arm:empty { display: none; }
.palm-calc__fine { margin: 18px 0 0; font: 400 12.5px/1.55 var(--f-body); color: #8FB3CC; max-width: 90ch; }

/* ---------- Lambda + Zoho ---------- */
.palm-zoho__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 40px; }
.palm-pat { padding: 22px; border-radius: 20px; background: #fff; border: 1px solid #E2E8F0; box-shadow: 0 18px 34px -30px rgba(8,34,56,.5); }
.palm-pat__n { margin: 0; font: 700 11px/1 var(--f-body); letter-spacing: .1em; text-transform: uppercase; color: #E07B00; }
.palm-pat h3 { margin: 8px 0 14px; font: 700 18px/1.3 var(--f-display); color: #082238; }
.palm-pat dl { position: relative; margin: 0; display: grid; gap: 14px; }
.palm-pat dl::before { content: ""; position: absolute; left: 13px; top: 30px; bottom: 30px; width: 2px; background: repeating-linear-gradient(180deg, #F0A400 0 4px, transparent 4px 8px); }
.palm-pat dt { font: 700 10.5px/1 var(--f-body); letter-spacing: .08em; text-transform: uppercase; color: #94A3B8; padding-left: 38px; }
.palm-pat dd { position: relative; margin: 5px 0 0; padding-left: 38px; font-size: 14px; line-height: 1.45; color: #334155; }
.palm-pat dd img, .palm-pat dd svg { position: absolute; left: 0; top: -14px; width: 28px; height: 28px; padding: 4px; border-radius: 8px; background: #fff; border: 1px solid #E2E8F0; }
.palm-pat dd svg { fill: none; stroke: #1D3F8F; stroke-width: 2; stroke-linecap: round; }
.palm-zoho__more { margin: 26px 0 0; font-size: 15.5px; line-height: 1.65; max-width: 90ch; }
.palm-zoho__more a, .palm-fit a { color: #0A6FA8; font-weight: 600; }

/* ---------- pricing ---------- */
.palm-price .crm-vs__wrap { margin-top: 36px; }
.palm-rates th small { display: block; margin-top: 3px; font: 400 12px/1.35 var(--f-body); color: #64748B; }
.palm-rates td { font-variant-numeric: tabular-nums; }
.palm-rates thead th:first-child, .palm-rates tbody th { width: 34%; }
.palm-rates thead th + th { width: 33%; }
.palm-price__notes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 22px; }
.palm-price__notes p { margin: 0; padding: 18px 20px; border-radius: 16px; background: #F3F7F9; font-size: 14.5px; line-height: 1.6; }
.palm-price__notes p:last-child { background: #FFF8E6; border: 1px solid #FFE0A0; }
.palm-price__notes b { display: block; margin-bottom: 4px; font: 700 15px/1.3 var(--f-display); color: #082238; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .palm-zoho__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .palm-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .palm-steps li::after { display: none; }
}
@media (max-width: 980px) {
  .palm-hero .palm-hero__grid { grid-template-columns: 1fr; }
  .palm-fit__grid { grid-template-columns: 1fr; }
  .palm-svc__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .palm-svc__card, .palm-svc__card:nth-child(4), .palm-svc__card:nth-child(5) { grid-column: auto; }
  .palm-svc__card:nth-child(5) { grid-column: 1 / -1; }
  .palm-calc__box { grid-template-columns: 1fr; }
  .palm-calc__out { border-left: 0; border-top: 1px solid rgba(255,255,255,.1); }
  .palm-price__notes { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .palm-fit__col--yes { grid-template-columns: 1fr; }
  .palm-svc__grid, .palm-zoho__grid, .palm-steps { grid-template-columns: 1fr; }
  .palm-svc__card:nth-child(5) { grid-column: auto; }
  .palm-ev__stage { aspect-ratio: 360 / 330; }
  .palm-ev__src li, .palm-ev__out li { padding: 6px; gap: 6px; font-size: 9.5px; }
  .palm-ev__src b, .palm-ev__out b { font-size: 10.5px; }
  .palm-ev__src img, .palm-ev__out img, .palm-ev__src svg { width: 20px; height: 20px; padding: 2px; }
  .palm-ev__fn { width: 22%; border-radius: 16px; }
  .palm-ev__ms { font-size: 9.5px; }
  .palm-trace { padding: 18px 14px 14px; }
  .palm-trace__head { display: none; }
  .palm-trace__row { grid-template-columns: 1fr auto; gap: 10px 12px; }
  .palm-trace__lbl { grid-column: 1; grid-row: 1; }
  .palm-trace__sum { grid-column: 2; grid-row: 1; }
  .palm-trace__bars { grid-column: 1 / -1; }
  .palm-bar span { font-size: 10px; }
  .palm-bar--init span { left: calc(100% + 8px); color: #DCE8F2; }
  .palm-calc__in, .palm-calc__out { padding: 20px 16px; }
  .palm-fit__col li { padding: 18px 16px 18px 52px; }
  .palm-fit__col li::before { left: 16px; top: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  .palm-trace.is-arm .palm-bar { transform: none; }
  .palm-bar, .palm-svc__card, .palm-ev__src li, .palm-ev__out li, .palm-calc__meter i { transition: none; }
  .palm-ev__fn.is-hot .palm-ev__ring { animation: none; }
}
