/* ==========================================================================
   Roxan — the public site. Type, space and thin lines; motion only where
   something is alive. Every state is also readable without the motion.
   ========================================================================== */

:root {
  --col: 1040px;
  --gut: clamp(22px, 5vw, 64px);
  --space: clamp(110px, 13vw, 200px);
  --gbar: 44px;
  --lbar: 52px;
}
html { scroll-padding-top: calc(var(--lbar) + 24px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { overflow-x: clip; }
.wrap { max-width: calc(var(--col) + 2 * var(--gut)); margin-inline: auto; padding-inline: var(--gut); }

/* ------------------------------------------------------------ Bars: Oplo's, then Roxan's */
.gbar { position: relative; z-index: 30; height: var(--gbar); border-bottom: 1px solid rgba(255, 255, 255, .08); background: var(--bg); }
.gbar-in { height: 100%; display: flex; align-items: center; gap: 24px; }
.gbar-in::after { content: ""; width: 22px; flex: none; }
.gbar-brand { display: grid; place-items: center; width: 22px; height: 20px; color: #f5f5f5; flex: none; }
.gbar-brand svg { width: 100%; height: 100%; fill: currentColor; }
.gbar nav { flex: 1; }
.gbar ul { display: flex; justify-content: center; gap: clamp(18px, 3vw, 44px); }
.gbar a:not(.gbar-brand) { font: 400 12px/1 var(--fb); color: #a1a1a6; transition: color .3s; }
.gbar a:not(.gbar-brand):hover { color: #fff; }

.lbar { position: sticky; top: 0; z-index: 40; height: var(--lbar); border-bottom: 1px solid var(--line); background: rgba(0, 0, 0, .72); -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px); }
.lbar-in { height: 100%; display: flex; align-items: center; gap: 20px; }
.lbar-brand { display: flex; align-items: center; gap: 10px; font: 300 17px/1 var(--fd); letter-spacing: -.04em; }
.lbar-nav { margin-left: auto; }
.lbar-nav ul { display: flex; gap: 4px; }
.lbar-nav a { display: block; padding: 9px 13px; border-radius: 999px; font: 400 13.5px/1 var(--fb); color: var(--muted); transition: color .3s; }
.lbar-nav a:hover, .lbar-nav a[aria-current] { color: #fff; }
.lbar-toggle { display: none; width: 34px; height: 34px; position: relative; }
.lbar-toggle i { position: absolute; left: 9px; right: 9px; height: 1px; background: #fff; transition: transform .5s var(--out); }
.lbar-toggle i:first-of-type { top: 14px; }
.lbar-toggle i:last-of-type { top: 20px; }
.lbar-toggle[aria-expanded="true"] i:first-of-type { transform: translateY(3px) rotate(45deg); }
.lbar-toggle[aria-expanded="true"] i:last-of-type { transform: translateY(-3px) rotate(-45deg); }

@media (max-width: 860px) {
  .gbar nav { display: none; }
  .gbar-in::after { display: none; }
  .lbar-toggle { display: block; order: 3; }
  .lbar .btn { margin-left: auto; }
  .lbar-nav { position: absolute; left: 0; right: 0; top: 100%; display: none; margin: 0; padding: 8px var(--gut) 20px; border-bottom: 1px solid var(--line); background: #000; }
  .lbar-nav.open { display: block; }
  .lbar-nav ul { flex-direction: column; gap: 0; }
  .lbar-nav a { padding: 15px 0; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 17px; }
}

/* ------------------------------------------------------------ The one entrance: a page heading rises into place, line by line. Only when script runs, so nothing is ever hidden without it. */
.ln { display: block; overflow: hidden; padding: 0 .06em .16em; margin: 0 -.06em -.16em; }
.ln > span { display: block; }
@media (scripting: enabled) {
  .ln > span { transform: translate3d(0, 112%, 0); transition: transform 1.2s var(--out); }
  .ln + .ln > span { transition-delay: .1s; }
  .in .ln > span { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .ln > span { transform: none !important; transition: none !important; }
}

/* ------------------------------------------------------------ Hero */
.hero { padding: clamp(72px, 10vw, 140px) 0 clamp(70px, 9vw, 130px); }
.hero h1 { font: 300 clamp(42px, 6.4vw, 96px)/1.02 var(--fd); letter-spacing: -.055em; margin-bottom: clamp(30px, 3.6vw, 48px); }
.hero .wrap > .lead { margin-bottom: 38px; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 30px; }
.cta .btn { height: 46px; padding: 0 26px; font-size: 15px; }
.hero .wrap > .fine { margin-top: 22px; }
.hero-demo { margin-top: clamp(56px, 7vw, 96px); }

.demo { border: 1px solid var(--line-2); border-radius: 22px; background: var(--panel); overflow: hidden; }
.demo-bar { display: flex; justify-content: space-between; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.demo-bar .t { display: flex; align-items: center; gap: 10px; font: 400 14px/1 var(--fb); color: var(--muted); }
.demo-body { padding: 22px clamp(16px, 3vw, 32px); }
.demo-body.ready { height: clamp(440px, 40vw, 470px); overflow: hidden; }
.scene { transition: opacity .6s var(--io); }
.scene.out { opacity: 0; }
.scene + .scene { margin-top: 36px; }
.demo-body.ready .scene + .scene { margin-top: 0; }
.demo .msg, .demo .act, .demo .mem { animation: rise .8s var(--out) both; }
@keyframes rise { from { opacity: 0; transform: translate3d(0, 14px, 0); } to { opacity: 1; transform: none; } }
.demo .btn.pressed { transform: scale(.95); opacity: .65; }
.demo .caret::after { content: ""; display: inline-block; width: 1px; height: 1em; margin-left: 2px; vertical-align: -.15em; background: currentColor; animation: breathe 1s var(--io) infinite; }

/* ------------------------------------------------------------ Sections */
.sec { position: relative; padding-top: var(--space); }
.sec-head { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
@media (min-width: 900px) {
  .split { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
  .split.flip > :first-child { order: 2; }
}
.sec .h2 { margin-bottom: 26px; }
.split .h2 { font-size: clamp(28px, 3vw, 42px); line-height: 1.12; }
.points { margin-top: 38px; border-top: 1px solid var(--line); }
.points li { padding: 15px 0; border-bottom: 1px solid var(--line); font-size: 15.5px; color: var(--muted); }
.points li b { color: var(--text); font-weight: 400; }

/* A real example, drawn small. Labelled as one. */
.ex { position: relative; }
.ex > .label { position: absolute; top: -26px; right: 2px; }
.ledger { border: 1px solid var(--line-2); border-radius: 18px; background: var(--panel); overflow: hidden; }
.ledger-h { display: flex; justify-content: space-between; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.ledger li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 18px; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.ledger li:last-child { border-bottom: 0; }
.ledger .t { font: 400 15.5px/1.4 var(--fb); }
.ledger .src { grid-column: 1; font: 400 12.5px/1.4 var(--fb); color: var(--dim); }
.ledger .ops { grid-column: 2; grid-row: 1 / span 2; display: flex; gap: 14px; font: 400 12.5px/1 var(--fb); color: var(--dim); }
.ledger .ops .on { color: #fff; }
.webx { display: block; width: 100%; height: auto; padding: 14px 14px 4px; border-bottom: 1px solid var(--line); }
.webx .e { stroke: var(--line-3); }
.webx circle { fill: var(--panel); stroke: var(--muted); }
.webx .me { stroke: #fff; }
.webx text { fill: var(--muted); font: 400 11px var(--fb); }
.rooms { display: grid; gap: 14px; }
.room { padding: 20px 22px; border: 1px solid var(--line-2); border-radius: 18px; background: var(--panel); }
.room h3 { margin-bottom: 6px; font: 400 16px/1.3 var(--fb); }
.room p { font-size: 14.5px; color: var(--muted); }
.room .label { display: block; margin-top: 14px; }
.pair { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) { .pair { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.card { display: flex; flex-direction: column; gap: 14px; padding: 24px 24px 22px; border: 1px solid var(--line-2); border-radius: 18px; background: var(--panel); }
.card header { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.card h3 { font: 400 17px/1.35 var(--fb); }
.card p { font-size: 15px; color: var(--muted); }
.card.later { border-color: var(--line); border-style: dashed; }
.card svg { width: 100%; height: auto; color: var(--text); }
.sched li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.sched li span:last-child { font: 400 13px/1.6 var(--fb); color: var(--dim); white-space: nowrap; }

.band { margin-top: var(--space); padding: var(--space) 0; border-top: 1px solid var(--line); }
.band .h2 { margin-bottom: 34px; }

/* ------------------------------------------------------------ Inner pages */
.page-hero { padding: clamp(64px, 9vw, 120px) 0 clamp(40px, 6vw, 80px); }
.page-hero h1 { font: 300 clamp(38px, 5.4vw, 80px)/1.04 var(--fd); letter-spacing: -.05em; margin-bottom: 30px; }
.rows { border-top: 1px solid var(--line); }
.row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px 48px; padding: 38px 0; border-bottom: 1px solid var(--line); }
@media (min-width: 860px) { .row { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); } }
.row h2 { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; font: 300 clamp(20px, 2vw, 27px)/1.2 var(--fd); letter-spacing: -.035em; }
.row .body > * + * { margin-top: 14px; }
.row p, .row li { color: var(--muted); max-width: 64ch; }
.row ul.plain { padding-left: 0; }
.row ul.plain li { position: relative; padding-left: 20px; }
.row ul.plain li + li { margin-top: 8px; }
.row ul.plain li::before { content: ""; position: absolute; left: 0; top: .85em; width: 8px; height: 1px; background: var(--dim); }
.row a.u, .page a.u { text-decoration: underline; text-decoration-color: var(--line-3); text-underline-offset: 4px; }
.row a.u:hover, .page a.u:hover { text-decoration-color: #fff; }
.kbd { display: inline-block; min-width: 24px; padding: 3px 7px; border: 1px solid var(--line-2); border-radius: 6px; font: 400 12px/1.2 var(--fm); text-align: center; color: var(--text); }
.keys li { display: flex; justify-content: space-between; gap: 18px; padding: 10px 0; border-top: 1px solid var(--line); max-width: 420px; }
.keys li:first-child { border-top: 0; }
details.q { border-top: 1px solid var(--line); padding: 4px 0; }
details.q:last-of-type { border-bottom: 1px solid var(--line); }
details.q summary { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 18px 0; cursor: pointer; list-style: none; font: 400 17px/1.4 var(--fb); }
details.q summary::-webkit-details-marker { display: none; }
details.q summary::after { content: "+"; font: 300 22px/1 var(--fb); color: var(--dim); transition: transform .5s var(--out); }
details.q[open] summary::after { transform: rotate(45deg); }
details.q p { padding: 0 0 22px; color: var(--muted); max-width: 64ch; }
.plan { display: grid; gap: 28px; padding: 34px 34px 30px; border: 1px solid var(--line-2); border-radius: 22px; background: var(--panel); }
@media (min-width: 860px) { .plan { grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); gap: 56px; } }
.plan .price { font: 300 clamp(56px, 7vw, 96px)/1 var(--fd); letter-spacing: -.06em; }
.plan .price small { font: 400 14px/1 var(--fb); color: var(--dim); margin-left: 12px; }
.plan ul li { padding: 12px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 15.5px; }
.plan ul li:first-child { border-top: 0; padding-top: 0; }
.checks li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 20px; padding: 22px 0; border-top: 1px solid var(--line); }
.checks li:last-child { border-bottom: 1px solid var(--line); }
.checks .name { font: 400 17px/1.4 var(--fb); }
.checks .note { grid-column: 1; font-size: 14px; color: var(--dim); }
.checks .st { grid-column: 2; grid-row: 1 / span 2; align-self: center; text-align: right; font: 400 13px/1.5 var(--fb); color: var(--muted); }
.checks .st b { display: block; font-weight: 400; color: #fff; }

/* ------------------------------------------------------------ Footer */
.foot { margin-top: 0; padding: 56px 0 44px; border-top: 1px solid var(--line); font: 400 12.5px/1.6 var(--fb); color: var(--dim); }
.foot-note { max-width: 64ch; margin-bottom: 44px; }
.foot-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; padding-bottom: 40px; border-bottom: 1px solid var(--line); }
@media (max-width: 640px) { .foot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.foot h2 { margin-bottom: 16px; }
.foot li + li { margin-top: 9px; }
.foot a { color: var(--muted); transition: color .3s; }
.foot a:hover { color: #fff; }
.foot-bar { padding-top: 22px; }

.act.flush { margin-left: 0; }
.lead.gap-l { margin-bottom: 56px; }
.lead.gap-m { margin-bottom: 34px; }
/* The example is hidden until its script has taken charge, so it never flashes its last frame. */
@media (scripting: enabled) and (prefers-reduced-motion: no-preference) { .demo-body:not(.ready) > * { visibility: hidden; } }
