/* ==========================================================================
   Afluex software product pages — page-specific visuals and layouts.
   Loaded after assets/css/afluex.css by the product pages only.
   ========================================================================== */

/* ------------------------------------------------------- shared helpers */

.page-hero .viz {
    max-width: 600px;
    justify-self: center;
    width: 100%;
}

.duo {
    margin-top: clamp(32px, 4vw, 56px);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.results-card {
    padding: 26px;
}

.results-card__head {
    display: flex;
    align-items: center;
    gap: 14px;
}

.results-card__head img {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.results-card__head h3 {
    font-size: 1.15rem;
}

.results-card p {
    margin-top: 12px;
    font-size: 15px;
}

.results-card .results {
    margin-top: 16px;
}

.why-media {
    display: grid;
    gap: 16px;
}

/* a 200px animated icon: shown at its own size, never upscaled */
.why-gif {
    justify-self: center;
    width: min(100%, 240px);
}

/* ======================================================================
   CRM
   ====================================================================== */

/* hero: lead flow */
.lf {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.3fr);
    gap: 12px;
}

.lf h4 {
    font-family: var(--mono);
    font-size: 10.5px;
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-3);
    margin: 0 2px 10px;
}

.lf-inbox {
    padding: 10px 8px;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: rgba(148, 214, 224, 0.04);
}

.lf-inbox__list {
    display: grid;
    gap: 8px;
}

.lf-lead {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: rgba(13, 26, 38, 0.95);
    transition: transform 0.6s var(--ease), opacity 0.5s;
}

.lf-lead>i {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(140deg, #6bc7d1, #3f90b5);
    flex-shrink: 0;
}

.lf-lead span {
    flex: 1;
    display: grid;
    gap: 5px;
}

.lf-lead .chip {
    padding: 2px 7px;
    font-size: 10px;
}

.lf-lead.is-leaving {
    transform: translateX(60%) scale(0.9);
    opacity: 0;
}

.lf-record {
    padding: 14px;
    border-radius: 12px;
    border: 1px solid var(--line-2);
    background: linear-gradient(160deg, rgba(107, 199, 209, 0.1), rgba(13, 26, 38, 0.9));
}

.lf-record__head {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lf-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(140deg, #9cf0f6, #3f90b5);
    box-shadow: 0 0 0 4px rgba(107, 199, 209, 0.15), 0 0 24px -4px var(--aqua);
    flex-shrink: 0;
}

.lf-record__name {
    flex: 1;
    display: grid;
    gap: 6px;
}

.lf-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 12px 0 14px;
}

.lf-history {
    display: grid;
    gap: 7px;
    min-height: 104px;
}

.lf-history li {
    display: grid;
    grid-template-columns: 8px minmax(0, 1fr) 30%;
    align-items: center;
    gap: 9px;
    font-size: 11.5px;
    color: var(--text);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.45s, transform 0.45s var(--ease);
}

.lf-history li.is-in {
    opacity: 1;
    transform: none;
}

.lf-history li>i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--aqua);
    box-shadow: 0 0 8px var(--aqua);
}

.lf-history li span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lf-stages {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
}

.lf-stage {
    position: relative;
    padding: 8px 6px 8px 14px;
    font-size: 11px;
    color: var(--text-3);
    background: rgba(148, 214, 224, 0.05);
    clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 50%, calc(100% - 9px) 100%, 0 100%, 9px 50%);
    transition: background-color 0.5s, color 0.5s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lf-stage.is-on {
    color: #03141a;
    background: linear-gradient(120deg, #9cf0f6, #6bc7d1);
}

.lf-stage:last-child.is-on {
    background: linear-gradient(120deg, #b9f3df, #4fd1a5);
}

/* overview: relationship map */
.rmap {
    position: relative;
    aspect-ratio: 1;
    max-width: 520px;
    width: 100%;
    margin-inline: auto;
}

.rmap svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.rmap__ring {
    fill: none;
    stroke: var(--line);
    stroke-dasharray: 2 6;
}

.rmap__spoke {
    stroke: var(--line-2);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
}

.rmap__flow {
    fill: none;
    stroke: var(--aqua-2);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 6 120;
    vector-effect: non-scaling-stroke;
    animation: rmap-flow 2.4s linear infinite;
    opacity: 0.25;
}

.rmap [data-node].is-on .rmap__flow,
.rmap__flow.is-on {
    opacity: 1;
}

@keyframes rmap-flow {
    from {
        stroke-dashoffset: 126;
    }

    to {
        stroke-dashoffset: 0;
    }
}

.rmap__core {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 27%;
    aspect-ratio: 1;
    transform: translate(-50%, -50%);
    display: grid;
    place-items: center;
    align-content: center;
    gap: 6px;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    background: radial-gradient(circle at 35% 30%, rgba(156, 240, 246, 0.25), rgba(8, 17, 26, 0.95) 70%);
    box-shadow: 0 0 60px -10px rgba(107, 199, 209, 0.55);
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
}

.rmap__core .lf-avatar {
    width: 34%;
    height: auto;
    aspect-ratio: 1;
}

.rmap__node {
    position: absolute;
    transform: translate(-50%, -50%);
    width: 31%;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(9, 18, 27, 0.92);
    font-size: 12.5px;
    line-height: 1.3;
    color: var(--text-2);
    text-align: center;
    transition: border-color 0.4s, color 0.4s, box-shadow 0.4s, transform 0.5s var(--ease);
}

.rmap__node.is-on {
    color: var(--text);
    border-color: var(--aqua);
    box-shadow: 0 0 34px -8px var(--aqua);
    transform: translate(-50%, -50%) scale(1.06);
}

[data-map-key] {
    border-radius: var(--r-sm);
    transition: background-color 0.3s;
}

.points [data-map-key] {
    padding: 10px 12px;
    margin: -10px -12px;
}

[data-map-key].is-on {
    background: rgba(107, 199, 209, 0.07);
}

/* features: pipeline lanes */
.lanes {
    --lane: 0;
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.lane {
    display: flex;
    flex-direction: column;
    border-radius: var(--r);
    border: 1px solid var(--line);
    background: rgba(148, 214, 224, 0.03);
    transition: border-color 0.4s, background-color 0.4s;
}

.lane__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 16px;
    border-bottom: 1px dashed var(--line);
    font-family: var(--mono);
    font-size: 11.5px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-3);
}

.lane__head b {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    transition: background-color 0.4s, box-shadow 0.4s;
}

.lane .feature {
    margin: 12px;
    flex: 1;
    border-radius: var(--r-sm);
}

.lane.is-on {
    border-color: var(--line-2);
    background: rgba(107, 199, 209, 0.06);
}

.lane.is-on .lane__head b {
    background: linear-gradient(140deg, #9cf0f6, #3f90b5);
    box-shadow: 0 0 18px -2px var(--aqua);
}

.lanes__track {
    position: absolute;
    left: 0;
    right: 0;
    top: -26px;
    height: 2px;
    border-radius: 2px;
    background: var(--line);
}

.lanes__track::after {
    content: "";
    position: absolute;
    top: -5px;
    left: calc((100% + 12px) / 4 * var(--lane) + (100% - 36px) / 8 - 6px);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--aqua-2);
    box-shadow: 0 0 16px var(--aqua);
    transition: left 0.9s var(--ease);
}

.lanes:not(.is-live) .lanes__track {
    display: none;
}

/* process: deal-stage chevrons */
.stagebar {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 18px;
}

.stagebar [role="tab"] {
    position: relative;
    min-height: 64px;
    padding: 10px 26px 10px 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--glass-2);
    color: var(--text-2);
    clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 0 100%, 18px 50%);
    text-align: left;
    transition: background-color 0.3s, color 0.3s;
}

.stagebar [role="tab"]:first-child {
    clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 0 100%);
    padding-left: 20px;
    border-radius: 14px 0 0 14px;
}

.stagebar [role="tab"]:focus-visible {
    outline-offset: -4px;
}

.stagebar .process-tab__no {
    border-color: var(--line-2);
}

.stagebar [role="tab"][aria-selected="true"] {
    color: #03141a;
    background: linear-gradient(120deg, #9cf0f6, #6bc7d1 60%, #3fa4ad);
}

.stagebar [role="tab"][aria-selected="true"] .process-tab__no {
    border-color: rgba(3, 20, 26, 0.4);
    color: #03141a;
}

.stage-steps {
    padding: clamp(20px, 3vw, 32px);
}

.stage-steps[hidden] {
    display: none;
}

.stage-steps ol {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    counter-reset: step;
}

.stage-steps li {
    counter-increment: step;
    padding: 18px;
    border-radius: var(--r);
    border: 1px solid var(--line);
    background: rgba(4, 8, 12, 0.35);
}

.stage-steps li::before {
    content: counter(step, decimal-leading-zero);
    display: block;
    font-family: var(--mono);
    font-size: 12px;
    color: var(--aqua);
    margin-bottom: 10px;
}

.stage-steps h3 {
    font-size: 1.05rem;
    margin-bottom: 6px;
}

.stage-steps p {
    font-size: 14.5px;
}

html:not(.enhanced) .stagebar {
    display: none;
}

html:not(.enhanced) .stage-steps[hidden] {
    display: block;
}

/* ======================================================================
   ERP
   ====================================================================== */

/* hero: departments on one operations floor */
.floor-wrap {
    position: relative;
    aspect-ratio: 1.12;
    transform-style: preserve-3d;
}

.floor {
    position: absolute;
    inset: 13% 15%;
    transform: rotateX(56deg) rotateZ(-36deg);
    transform-style: preserve-3d;
    border-radius: 22px;
    border: 1px solid var(--line-2);
    background:
        linear-gradient(rgba(140, 214, 224, 0.07) 1px, transparent 1px) 0 0 / 10% 10%,
        linear-gradient(90deg, rgba(140, 214, 224, 0.07) 1px, transparent 1px) 0 0 / 10% 10%,
        radial-gradient(circle at 50% 50%, rgba(107, 199, 209, 0.18), rgba(8, 17, 26, 0.92) 70%);
    box-shadow: 0 0 80px -20px rgba(107, 199, 209, 0.45);
}

.floor__lines {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.floor__lines line {
    stroke: rgba(156, 240, 246, 0.45);
    stroke-width: 1.4;
    stroke-dasharray: 3 4;
    vector-effect: non-scaling-stroke;
}

.blk {
    --h: 48px;
    position: absolute;
    width: 17%;
    aspect-ratio: 1;
    transform: translate(-50%, -50%);
    transform-style: preserve-3d;
}

.blk--core {
    width: 22%;
}

.blk i {
    position: absolute;
    display: block;
}

.blk__top {
    inset: 0;
    transform: translateZ(var(--h));
    border-radius: 6px;
    border: 1px solid rgba(156, 240, 246, 0.55);
    background: linear-gradient(140deg, rgba(156, 240, 246, 0.5), rgba(63, 144, 181, 0.45));
    display: grid;
    place-items: center;
    transition: background-color 0.4s, box-shadow 0.4s;
}

.blk__top img {
    width: 58%;
    border-radius: 8px;
    transform: rotateZ(36deg);
}

.blk__s--a {
    left: 0;
    top: 100%;
    width: 100%;
    height: var(--h);
    transform-origin: top;
    transform: rotateX(90deg);
    background: linear-gradient(rgba(63, 144, 181, 0.75), rgba(13, 32, 46, 0.95));
}

.blk__s--b {
    left: 100%;
    top: 0;
    width: var(--h);
    height: 100%;
    transform-origin: left;
    transform: rotateY(-90deg);
    background: linear-gradient(90deg, rgba(42, 112, 140, 0.85), rgba(10, 26, 38, 0.95));
}

.blk--core .blk__top {
    background: linear-gradient(140deg, rgba(180, 246, 250, 0.7), rgba(63, 144, 181, 0.6));
    box-shadow: 0 0 40px rgba(107, 199, 209, 0.6);
}

.blk.is-on .blk__top {
    box-shadow: 0 0 36px rgba(156, 240, 246, 0.8);
    background: linear-gradient(140deg, rgba(200, 250, 252, 0.8), rgba(107, 199, 209, 0.6));
}

.blk__label {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) translateZ(calc(var(--h) + 30px)) rotateZ(36deg) rotateX(-56deg);
    padding: 5px 9px;
    border-radius: 8px;
    border: 1px solid var(--line-2);
    background: rgba(7, 14, 21, 0.92);
    font-size: 11.5px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    transition: border-color 0.4s, box-shadow 0.4s;
}

.blk.is-on .blk__label {
    border-color: var(--aqua);
    box-shadow: 0 0 20px -4px var(--aqua);
}

.pkt {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 9px;
    height: 9px;
    margin: -4.5px 0 0 -4.5px;
    border-radius: 50%;
    background: var(--aqua-2);
    box-shadow: 0 0 12px var(--aqua);
    transform: translateZ(4px);
    animation: pkt 2.8s var(--d, 0s) ease-in-out infinite;
}

@keyframes pkt {
    0% {
        left: 50%;
        top: 50%;
        opacity: 0;
    }

    15% {
        opacity: 1;
    }

    50% {
        left: calc(50% + var(--x) * 1%);
        top: calc(50% + var(--y) * 1%);
        opacity: 1;
    }

    85% {
        opacity: 1;
    }

    100% {
        left: 50%;
        top: 50%;
        opacity: 0;
    }
}

/* overview: an automated workflow */
.wf {
    --at: 0;
    position: relative;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    padding: 22px;
}

.wf__track {
    position: absolute;
    left: calc(22px + (100% - 44px) / 10);
    right: calc(22px + (100% - 44px) / 10);
    top: 50px;
    height: 2px;
    background: var(--line);
}

.wf__track::after {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: calc(100% * min(var(--at), 4) / 4);
    background: var(--grad);
    transition: width 0.8s var(--ease);
}

.wf__step {
    position: relative;
    display: grid;
    justify-items: center;
    gap: 10px;
    text-align: center;
    font-size: 13px;
    line-height: 1.3;
    color: var(--text-2);
}

.wf__icon {
    position: relative;
    z-index: 1;
    width: 56px;
    height: 56px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    border: 1px solid var(--line-2);
    background: var(--ink-2);
    transition: background-color 0.4s, box-shadow 0.4s, border-color 0.4s;
}

.wf__icon svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: var(--aqua-2);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.wf__step.is-on .wf__icon {
    border-color: var(--aqua);
    background: rgba(107, 199, 209, 0.18);
    box-shadow: 0 0 30px -6px var(--aqua);
}

.wf__step.is-done .wf__icon {
    border-color: rgba(79, 209, 165, 0.6);
}

.wf__step.is-on,
.wf__step.is-done {
    color: var(--text);
}

/* features: modules around the core */
.modhub {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(160px, 0.6fr) minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 18px 28px;
    align-items: center;
}

/* opaque so the connecting wires never run through the text */
.modhub>.feature {
    background-color: var(--ink-1);
}

.modhub>.feature:nth-of-type(1) {
    grid-area: 1 / 1;
}

.modhub>.feature:nth-of-type(2) {
    grid-area: 1 / 3;
}

.modhub>.feature:nth-of-type(3) {
    grid-area: 2 / 1;
}

.modhub>.feature:nth-of-type(4) {
    grid-area: 2 / 3;
}

.modhub__core {
    grid-area: 1 / 2 / 3 / 3;
    position: relative;
    z-index: 1;
    justify-self: center;
    width: 100%;
    max-width: 200px;
    aspect-ratio: 1;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 10px;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    background: radial-gradient(circle at 35% 30%, rgba(156, 240, 246, 0.22), rgba(8, 17, 26, 0.96) 70%);
    box-shadow: 0 0 80px -16px rgba(107, 199, 209, 0.6);
    font-weight: 600;
    color: var(--text);
    text-align: center;
}

.modhub__core img {
    width: 38%;
    border-radius: 12px;
}

.modhub__core::before {
    content: "";
    position: absolute;
    inset: -14px;
    border-radius: 50%;
    border: 1px dashed var(--line-2);
    animation: spin 30s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.modhub__wires {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.modhub__wires path {
    fill: none;
    stroke: var(--line-2);
    stroke-width: 1.2;
    vector-effect: non-scaling-stroke;
}

.modhub__wires .flow {
    stroke: var(--aqua-2);
    stroke-width: 2;
    stroke-dasharray: 5 60;
    animation: rmap-flow 2.2s linear infinite;
}

/* process: rollout timeline */
.rail {
    --fill: 0;
    position: relative;
    display: grid;
    gap: 22px;
    padding-left: 56px;
}

.rail::before,
.rail::after {
    content: "";
    position: absolute;
    left: 19px;
    top: 10px;
    bottom: 10px;
    width: 2px;
    border-radius: 2px;
    background: var(--line);
}

.rail::after {
    background: var(--grad);
    transform-origin: top;
    transform: scaleY(var(--fill));
}

.rail__stage {
    position: relative;
    padding: clamp(20px, 2.6vw, 28px);
}

.rail__stage::before {
    content: attr(data-no);
    position: absolute;
    left: -56px;
    top: 22px;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    background: var(--ink-1);
    font-family: var(--mono);
    font-size: 13px;
    color: var(--aqua);
    z-index: 1;
    transition: background-color 0.4s, color 0.4s, box-shadow 0.4s;
}

.rail__stage.is-on::before {
    background: var(--grad-btn);
    color: #03141a;
    border-color: transparent;
    box-shadow: 0 0 24px -4px var(--aqua);
}

.rail__stage h3 {
    font-size: 1.3rem;
    margin-bottom: 16px;
}

.rail__stage ol {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.rail__stage ol h4 {
    font-size: 1rem;
    margin-bottom: 6px;
}

.rail__stage ol p {
    font-size: 14.5px;
}

/* ======================================================================
   School management
   ====================================================================== */

/* hero: three role panels stacked in depth */
.sp-stack {
    position: relative;
    aspect-ratio: 1.08;
    transform-style: preserve-3d;
}

.sp {
    position: absolute;
    width: 62%;
    transition: transform 0.9s var(--ease), opacity 0.9s, filter 0.9s;
}

.sp .win__body {
    padding: 14px;
    min-height: 210px;
}

.sp[data-depth="2"] {
    transform: translate3d(0, 0, -120px);
    left: 0;
    top: 0;
    opacity: 0.55;
    filter: saturate(0.6);
}

.sp[data-depth="1"] {
    transform: translate3d(30%, 26%, -50px);
    left: 0;
    top: 0;
    opacity: 0.8;
}

.sp[data-depth="0"] {
    transform: translate3d(60%, 52%, 30px);
    left: 0;
    top: 0;
    z-index: 2;
}

.sp-cap,
.sp small {
    display: block;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-3);
    margin-bottom: 8px;
}

.sp-kpis {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.sp-kpi {
    padding: 10px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: rgba(148, 214, 224, 0.04);
}

.sp-kpi small {
    font-size: 10px;
    letter-spacing: 0.04em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sp-fee {
    margin-top: 14px;
}

.sp-fee__bar {
    display: block;
    height: 10px;
    border-radius: 6px;
    background: rgba(148, 214, 224, 0.08);
    overflow: hidden;
}

.sp-fee__bar i {
    display: block;
    height: 100%;
    width: 30%;
    border-radius: inherit;
    background: var(--grad);
    animation: fee 4s var(--ease) infinite alternate;
}

@keyframes fee {
    to {
        width: 86%;
    }
}

.sp-reg {
    display: grid;
    grid-template-columns: 1.6fr repeat(6, minmax(0, 1fr));
    gap: 6px;
    align-items: center;
}

.sp-reg b {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 400;
    color: var(--text-3);
    text-align: center;
}

.sp-reg i {
    aspect-ratio: 1;
    border-radius: 5px;
    border: 1px solid var(--line);
    transition: background-color 0.3s, border-color 0.3s;
}

.sp-reg i.is-p {
    background: rgba(79, 209, 165, 0.35);
    border-color: rgba(79, 209, 165, 0.6);
}

.sp-reg i.is-a {
    background: rgba(255, 181, 71, 0.3);
    border-color: rgba(255, 181, 71, 0.6);
}

.sp-tt {
    display: grid;
    gap: 6px;
}

.sp-tt li {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 8px;
    border: 1px solid var(--line);
}

.sp-tt li:nth-child(2) {
    border-color: var(--aqua);
    background: rgba(107, 199, 209, 0.1);
}

.sp-tt b {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--aqua);
}

.sp-sms {
    margin-top: 12px;
    padding: 10px;
    display: grid;
    gap: 6px;
    border-radius: 10px 10px 10px 2px;
    background: rgba(107, 199, 209, 0.12);
    border: 1px solid var(--line-2);
}

/* features: notice board */
.board {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    padding: clamp(18px, 3vw, 32px);
    border-radius: 28px;
    border: 1px solid var(--line);
    background:
        radial-gradient(rgba(140, 214, 224, 0.07) 1px, transparent 1px) 0 0 / 18px 18px,
        linear-gradient(160deg, rgba(13, 24, 35, 0.8), rgba(6, 12, 18, 0.9));
}

.board .feature {
    --tilt: -0.8deg;
    transform: rotate(var(--tilt));
    transition: transform 0.4s var(--ease), border-color 0.3s;
}

.board .feature:nth-child(3n+2) {
    --tilt: 0.7deg;
}

.board .feature:nth-child(3n) {
    --tilt: -0.4deg;
}

.board .feature:hover {
    transform: rotate(0) translateY(-4px);
    border-color: var(--line-2);
}

.board .feature::before {
    content: "";
    position: absolute;
    top: -6px;
    left: 50%;
    width: 12px;
    height: 12px;
    margin-left: -6px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #c9fbff, var(--aqua) 60%, #2a6f7a);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.6);
}

@media (min-width: 961px) {
    .sticky-media {
        position: sticky;
        top: calc(var(--header-h) + 24px);
    }
}

/* process: four report cards */
.terms {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    counter-reset: term;
}

.term {
    padding: 22px;
    counter-increment: term;
}

.term h3 {
    display: flex;
    align-items: baseline;
    gap: 10px;
    font-size: 1.2rem;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px dashed var(--line-2);
}

.term h3::before {
    content: counter(term, decimal-leading-zero);
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 400;
    color: var(--aqua);
}

.term ol {
    display: grid;
    gap: 14px;
}

.term h4 {
    font-size: 0.98rem;
    margin-bottom: 4px;
}

.term p {
    font-size: 14px;
}

/* ======================================================================
   Real estate
   ====================================================================== */

/* hero: site layout of plots */
.site-wrap {
    position: relative;
    aspect-ratio: 1.3;
    transform-style: preserve-3d;
}

.site {
    position: absolute;
    inset: 4% 4% 14% 4%;
    transform: rotateX(42deg) rotateZ(-8deg);
    transform-style: preserve-3d;
    padding: 4%;
    border-radius: 18px;
    border: 1px solid var(--line-2);
    background: linear-gradient(160deg, rgba(16, 32, 44, 0.95), rgba(6, 13, 19, 0.98));
    box-shadow: 0 60px 90px -40px rgba(0, 0, 0, 0.9), 0 0 60px -20px rgba(107, 199, 209, 0.35);
}

.site__grid {
    height: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr)) 14% repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(4, minmax(0, 1fr));
    gap: 6px;
    transform-style: preserve-3d;
}

.site__road {
    grid-column: 4;
    grid-row: 1 / -1;
    border-inline: 1px dashed rgba(156, 240, 246, 0.25);
    background: linear-gradient(90deg, transparent 47%, rgba(156, 240, 246, 0.2) 47% 53%, transparent 53%);
}

.plot {
    display: block;
    border-radius: 4px;
    border: 1px solid rgba(156, 240, 246, 0.35);
    background: rgba(148, 214, 224, 0.04);
    transition: transform 0.6s var(--ease), background-color 0.5s, box-shadow 0.5s;
}

.plot.is-booked {
    background: rgba(255, 181, 71, 0.22);
    border-color: rgba(255, 181, 71, 0.55);
}

.plot.is-allotted {
    background: rgba(107, 199, 209, 0.35);
    border-color: rgba(156, 240, 246, 0.7);
}

.plot.is-sel {
    transform: translateZ(18px);
    background: linear-gradient(140deg, #b4f6fa, #6bc7d1);
    box-shadow: 0 0 30px rgba(156, 240, 246, 0.8);
}

.plot-card {
    position: absolute;
    right: -2%;
    bottom: 10%;
    width: 52%;
    padding: 14px;
    display: grid;
    gap: 9px;
    border-radius: 14px;
    border: 1px solid var(--line-2);
    background: rgba(9, 18, 27, 0.95);
    box-shadow: 0 30px 50px -24px rgba(0, 0, 0, 0.9), 0 0 30px -12px rgba(107, 199, 209, 0.4);
    transform: translateZ(190px);
    font-size: 12px;
    color: var(--text);
}

.plot-card__head {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
}

.plot-card__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.plot-card__row small {
    font-size: 11px;
    color: var(--text-3);
}

.plot-card__row .chip {
    padding: 2px 8px;
    font-size: 10.5px;
}

.emi {
    display: flex;
    gap: 3px;
}

.emi i {
    width: 12px;
    height: 12px;
    border-radius: 3px;
    border: 1px solid var(--line-2);
    transition: background-color 0.4s;
}

.emi i.is-paid {
    background: var(--ok);
    border-color: var(--ok);
}

.emi i.is-due {
    background: var(--amber);
    border-color: var(--amber);
    box-shadow: 0 0 10px var(--amber);
}

.site-legend {
    position: absolute;
    left: 2%;
    bottom: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    font-size: 11.5px;
    color: var(--text-2);
}

.site-legend span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.site-legend .plot {
    width: 12px;
    height: 12px;
}

.plot-toast {
    opacity: 0;
    transition: opacity 0.4s;
}

.plot-toast.is-on {
    opacity: 1;
}

/* features: payment ledger */
.ledger {
    padding: clamp(18px, 2.6vw, 26px);
}

.ledger__head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
    font-family: var(--mono);
    font-size: 11.5px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-3);
}

.ledger__row {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-top: 1px solid var(--line);
    font-size: 14px;
}

.ledger__row b {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 400;
    color: var(--text-2);
}

.ledger__state {
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid var(--line-2);
    font-size: 12px;
    white-space: nowrap;
    transition: background-color 0.4s, color 0.4s, border-color 0.4s;
}

.ledger__row[data-state="paid"] .ledger__state {
    color: #b9f3df;
    border-color: rgba(79, 209, 165, 0.6);
    background: rgba(79, 209, 165, 0.12);
}

.ledger__row[data-state="due"] .ledger__state {
    color: #ffe2b0;
    border-color: rgba(255, 181, 71, 0.65);
    background: rgba(255, 181, 71, 0.14);
    box-shadow: 0 0 18px -6px var(--amber);
}

.ledger__row .sk {
    max-width: 100%;
}

.feature-list {
    display: grid;
    gap: 12px;
}

.feature-list li {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 14px;
    padding: 16px 18px;
    border-radius: var(--r);
    border: 1px solid var(--line);
    background: var(--glass);
}

.feature-list .feature__no {
    padding-top: 3px;
}

.feature-list h3 {
    font-size: 1.02rem;
    margin-bottom: 4px;
}

.feature-list p {
    font-size: 14.5px;
}

.roles {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

/* ======================================================================
   E-commerce
   ====================================================================== */

/* hero: storefront */
.shop-top {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.shop-search {
    flex: 1;
    padding: 9px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
}

.cart {
    position: relative;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    border: 1px solid var(--line-2);
}

.cart svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: var(--aqua-2);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.cart b {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 17px;
    height: 17px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--grad-btn);
    color: #03141a;
    font-size: 10px;
}

.pcs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.pc {
    position: relative;
    display: grid;
    gap: 6px;
    padding: 7px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: rgba(13, 26, 38, 0.95);
    transition: transform 0.4s var(--ease), border-color 0.3s, box-shadow 0.3s;
}

.pc__img {
    aspect-ratio: 1.25;
    border-radius: 7px;
    background: linear-gradient(150deg, hsl(var(--h) 45% 32%), hsl(calc(var(--h) + 30) 40% 16%));
}

.pc__tag {
    position: absolute;
    top: 11px;
    left: 11px;
    padding: 2px 7px;
    border-radius: 999px;
    background: rgba(4, 8, 12, 0.8);
    border: 1px solid var(--line-2);
    font-size: 10px;
    font-weight: 600;
    color: var(--aqua-2);
}

.pc.is-added {
    transform: translateY(-4px) scale(1.03);
    border-color: var(--aqua);
    box-shadow: 0 0 22px -6px var(--aqua);
}

.track {
    margin-top: 12px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
}

.track span {
    position: relative;
    padding-top: 12px;
    font-size: 10.5px;
    color: var(--text-3);
    transition: color 0.4s;
}

.track span::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 4px;
    border-radius: 3px;
    background: rgba(148, 214, 224, 0.1);
    transition: background-color 0.4s;
}

.track span.is-on {
    color: var(--text);
}

.track span.is-on::before {
    background: var(--aqua);
    box-shadow: 0 0 10px var(--aqua);
}

/* features grouped by tabs */
.seg {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 5px;
    margin-bottom: 22px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--glass);
}

.seg [role="tab"] {
    min-height: 40px;
    padding: 0 18px;
    border-radius: 999px;
    font-size: 14.5px;
    font-weight: 600;
    color: var(--text-2);
    transition: background-color 0.25s, color 0.25s;
}

.seg [role="tab"][aria-selected="true"] {
    background: var(--grad-btn);
    color: #03141a;
}

.seg-panel[hidden] {
    display: none;
}

html:not(.enhanced) .seg {
    display: none;
}

html:not(.enhanced) .seg-panel[hidden] {
    display: grid;
    margin-top: 16px;
}

/* order journey */
.oj {
    --at: 0;
    --pad: clamp(20px, 3vw, 32px);
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    padding: var(--pad);
}

/* runs from the centre of the first stop to the centre of the last */
.oj__belt {
    position: absolute;
    left: calc(var(--pad) + (100% - 2 * var(--pad) - 36px) / 8);
    right: calc(var(--pad) + (100% - 2 * var(--pad) - 36px) / 8);
    top: calc(var(--pad) + 22px);
    height: 4px;
    border-radius: 3px;
    background: repeating-linear-gradient(90deg, rgba(140, 214, 224, 0.25) 0 10px, transparent 10px 18px);
}

.oj__box {
    position: absolute;
    top: -12px;
    left: calc(100% * min(var(--at), 3) / 3);
    width: 28px;
    height: 28px;
    margin-left: -14px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: var(--grad-btn);
    box-shadow: 0 0 20px -4px var(--aqua);
    transition: left 1s var(--ease);
}

.oj__box svg,
.oj__icon svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: #03141a;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.oj:not(.is-live) .oj__box {
    display: none;
}

.oj__stop {
    position: relative;
    display: grid;
    justify-items: center;
    gap: 10px;
    text-align: center;
    font-size: 14px;
    color: var(--text-2);
}

.oj__icon {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    background: var(--ink-2);
    transition: background-color 0.4s, box-shadow 0.4s;
}

.oj__icon svg {
    width: 20px;
    height: 20px;
    stroke: var(--aqua-2);
    stroke-width: 1.8;
}

.oj__stop strong {
    display: block;
    color: var(--text);
    font-size: 1.02rem;
}

.oj__stop.is-on .oj__icon,
.oj__stop.is-done .oj__icon {
    background: rgba(107, 199, 209, 0.2);
    box-shadow: 0 0 26px -6px var(--aqua);
}

/* ------------------------------------------------------------ responsive */

@media (max-width: 1100px) {

    .terms {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .lanes {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .lanes__track {
        display: none;
    }

    .stagebar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .stagebar [role="tab"],
    .stagebar [role="tab"]:first-child {
        clip-path: none;
        border-radius: 14px;
        padding: 10px 14px;
    }
}

@media (max-width: 960px) {

    .rmap {
        max-width: 440px;
    }

    .stage-steps ol,
    .rail__stage ol {
        grid-template-columns: minmax(0, 1fr);
    }

    .modhub {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .modhub__core {
        grid-area: auto;
        grid-column: 1 / -1;
        order: -1;
        max-width: 160px;
    }

    .modhub>.feature:nth-of-type(n) {
        grid-area: auto;
    }

    .modhub__wires {
        display: none;
    }
}

@media (max-width: 760px) {

    .wf {
        grid-template-columns: minmax(0, 1fr);
        justify-items: start;
        gap: 14px;
    }

    .wf__track {
        left: 49px;
        right: auto;
        top: 40px;
        bottom: 40px;
        width: 2px;
        height: auto;
    }

    .wf__track::after {
        inset: 0 0 auto 0;
        width: auto;
        height: calc(100% * min(var(--at), 4) / 4);
        transition: height 0.8s var(--ease);
    }

    .wf__step {
        grid-template-columns: 56px minmax(0, 1fr);
        justify-items: start;
        align-items: center;
        gap: 14px;
        text-align: left;
    }
}

@media (max-width: 640px) {

    .lanes,
    .duo,
    .modhub {
        grid-template-columns: minmax(0, 1fr);
    }

    .lf {
        grid-template-columns: minmax(0, 1fr);
    }

    .lf-inbox {
        display: none;
    }

    .lf-stage {
        padding: 7px 2px 7px 11px;
        font-size: 10px;
        text-overflow: clip;
    }

    /* the floor needs the full width on phones; its two notes would cover the labels */
    .viz[data-pviz="erp-floor"] .float {
        display: none;
    }

    .floor {
        inset: 14% 12%;
    }

    .blk--core .blk__label {
        display: none;
    }

    .viz[data-pviz="shop-flow"] .float,
    .viz[data-pviz="school-panels"] .float {
        display: none;
    }

    .sp .win__bar {
        white-space: nowrap;
        font-size: 10px;
        letter-spacing: 0.02em;
        gap: 6px;
    }

    .sp .win__brand {
        display: none;
    }

    .rmap__node {
        width: 38%;
        padding: 8px;
        font-size: 11px;
    }

    .blk__label {
        font-size: 10px;
        padding: 4px 6px;
    }

    .rail {
        padding-left: 0;
    }

    .rail::before,
    .rail::after {
        display: none;
    }

    .rail__stage::before {
        position: static;
        margin-bottom: 12px;
    }
}

@media (max-width: 400px) {
    .stagebar {
        grid-template-columns: minmax(0, 1fr);
    }

    .stagebar [role="tab"] {
        min-height: 52px;
    }
}

@media (max-width: 960px) {
    .board {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {

    .board,
    .terms {
        grid-template-columns: minmax(0, 1fr);
    }

    .board .feature {
        --tilt: 0deg;
    }

    .oj {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 22px;
    }

    .oj__belt {
        display: none;
    }

    .sp {
        width: 70%;
    }

    .sp[data-depth="1"] {
        transform: translate3d(20%, 20%, -50px);
    }

    .sp[data-depth="0"] {
        transform: translate3d(40%, 40%, 30px);
    }

    .sp-stack {
        aspect-ratio: 0.66;
    }

    .plot-card {
        width: 62%;
        right: 0;
        padding: 10px;
        font-size: 11px;
    }

    .ledger__row {
        grid-template-columns: 56px minmax(0, 1fr);
    }

    .ledger__row .sk {
        display: none;
    }
}

/* ---------------------------------------------------------- reduced motion */

@media (prefers-reduced-motion: reduce) {

    .rmap__flow,
    .modhub__wires .flow,
    .modhub__core::before,
    .sp-fee__bar i,
    .pkt {
        animation: none;
    }

    .sp-fee__bar i {
        width: 70%;
    }

    .sp,
    .board .feature {
        transition: none;
    }

    .pkt {
        display: none;
    }

    .rmap__flow {
        opacity: 0.6;
    }
}
