/* ═══════════════════════════════════════════════════════════════════
   CENDRIUM · TYPE, LAYOUT HELPERS, REVEAL, BUTTONS
   ═══════════════════════════════════════════════════════════════════ */

.cx-wrap { width: min(1220px, 100% - 3rem); margin-inline: auto; }
.cx-section { position: relative; padding: clamp(4.5rem, 10vw, 8.5rem) 0; }
.cx-center { text-align: center; }
.cx-label { display: inline-flex; align-items: center; gap: .7rem; font-family: var(--font-mono); font-size: .7rem; font-weight: 500; letter-spacing: .22em; text-transform: uppercase; color: var(--ember); margin-bottom: 1.3rem; }
.cx-label::before { content: ""; width: 34px; height: 1px; background: var(--grad); }
.cx-center .cx-label::after { content: ""; width: 34px; height: 1px; background: var(--grad); }
.cx-h1, .cx-h2, .cx-h3 { font-family: var(--font-disp); margin: 0; letter-spacing: -.035em; font-weight: 650; color: var(--text); }
.cx-h1 { font-size: clamp(2.9rem, 7.4vw, 6.4rem); line-height: .98; }
.cx-h2 { font-size: clamp(2.1rem, 4.8vw, 3.9rem); line-height: 1.04; }
.cx-h3 { font-size: 1.28rem; line-height: 1.25; letter-spacing: -.02em; }
.cx-h1 em, .cx-h2 em, .cx-grad { font-style: normal; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; }
.cx-lead { font-size: clamp(1.02rem, 1.5vw, 1.2rem); color: var(--text2); max-width: 58ch; line-height: 1.75; }
.cx-center .cx-lead { margin-inline: auto; }
.cx-mono { font-family: var(--font-mono); }

/* split-text headline mask (JS wraps words in .w > .wi) */
.cx-body .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .14em; margin-bottom: -.14em; }
.cx-body .wi { display: inline-block; transform: translateY(112%) rotate(4deg); transform-origin: 0 100%; transition: transform 1s var(--ease-out); transition-delay: calc(var(--wi, 0) * 55ms + 120ms); }
.cx-body .is-in .wi, .cx-body .wi.is-in { transform: none; }
html:not(.js) .wi { transform: none; }
.cx-body em .wi, .cx-body .cx-grad .wi { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; }

/* reveal on scroll */
/* Keyframe-driven (not transition-driven) so it never fights an element's own
   hover/tilt transitions. `backwards` fill = no residual transform afterwards. */
[data-reveal] { --rv: translate3d(0, 34px, 0) scale(.985); opacity: 0; }
[data-reveal="left"]  { --rv: translate3d(-40px, 0, 0); }
[data-reveal="right"] { --rv: translate3d(40px, 0, 0); }
[data-reveal="zoom"]  { --rv: scale(.9); }
[data-reveal].is-in { opacity: 1; animation: cxReveal .95s var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 90ms); }
@keyframes cxReveal { from { opacity: 0; transform: var(--rv); filter: blur(8px); } }
html:not(.js) [data-reveal] { opacity: 1; }

/* ── Buttons ─────────────────────────────────────────────────────── */
.cx-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: .65rem; padding: .95rem 1.7rem; border-radius: 999px; border: 0; cursor: pointer; font-family: var(--font-body); font-weight: 600; font-size: .95rem; letter-spacing: .01em; color: var(--on-accent); background: var(--grad); overflow: hidden; isolation: isolate; box-shadow: 0 8px 28px rgba(var(--accent-rgb), .32), inset 0 1px 0 rgba(255,255,255,.35); transition: transform .35s var(--ease-out), box-shadow .35s ease; will-change: transform; }
.cx-btn::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(105deg, transparent 30%, rgba(255,255,255,.55) 50%, transparent 70%); transform: translateX(-120%); transition: transform .8s var(--ease-out); }
.cx-btn:hover { box-shadow: 0 14px 42px rgba(var(--accent-rgb), .5), inset 0 1px 0 rgba(255,255,255,.4); }
.cx-btn:hover::before { transform: translateX(120%); }
.cx-btn:active { transform: scale(.97) !important; }
.cx-btn svg { width: 15px; height: 15px; transition: transform .35s var(--ease-out); }
.cx-btn:hover svg { transform: translateX(4px); }
.cx-btn--ghost { background: var(--glass); color: var(--text); border: 1px solid var(--glass-brd); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: none; }
.cx-btn--ghost:hover { border-color: rgba(var(--accent-rgb), .6); box-shadow: 0 10px 30px rgba(var(--accent-rgb), .16); }
.cx-btn--sm { padding: .62rem 1.15rem; font-size: .84rem; }
.cx-btn--block { width: 100%; }
.cx-textlink { display: inline-flex; align-items: center; gap: .6rem; font-weight: 600; color: var(--text); border-bottom: 1px solid var(--border2); padding-bottom: .25rem; transition: gap .3s var(--ease-out), border-color .3s, color .3s; }
.cx-textlink:hover { gap: 1rem; border-color: var(--ember); color: var(--ember); }
