/* Add here all your CSS customizations */

[x-cloak] {
    display: none !important;
}

/* Form fields were pure white on a white card background, with only a
   1px near-white border — inputs were essentially invisible and long forms
   (unlock request, trade-in, etc.) looked like one undifferentiated block.
   Give every field a clearly visible frame so each one reads as its own box. */
.form-control,
.custom-select,
select.form-control {
    background-color: #eef0f3 !important;
    border: 1px solid #c1c7d0 !important;
    box-shadow: inset 0 1px 2px rgba(16, 22, 31, .06);
}

.form-control:focus,
.custom-select:focus {
    background-color: #fff !important;
    border-color: #ff6d0c !important;
    box-shadow: 0 0 0 .2rem rgba(255, 109, 12, .2);
}

.form-control::placeholder {
    color: #7c828b;
}

.checkbox-custom label:before {
    background-color: #eef0f3;
    border: 1px solid #c1c7d0;
}

.custom-control-input:checked ~ .custom-control-label::before,
.custom-radio .custom-control-input:checked ~ .custom-control-label::before,
.custom-checkbox .custom-control-input:checked ~ .custom-control-label::before {
    color: #fff;
    border-color: #ff6d0c;
    background-color: #ff6d0c;
}

.custom-control-input:focus ~ .custom-control-label::before {
    box-shadow: 0 0 0 1px #fff, 0 0 0 .2rem rgba(255, 109, 12, .25);
}

.custom-control-input:focus:not(:checked) ~ .custom-control-label::before {
    border-color: #ff9147;
}

.custom-control-input:active ~ .custom-control-label::before,
.custom-radio .custom-control-input:active ~ .custom-control-label::before,
.custom-checkbox .custom-control-input:active ~ .custom-control-label::before {
    color: #fff;
    background-color: #ff9147;
    border-color: #ff9147;
}

.custom-radio .custom-control-input:disabled:checked ~ .custom-control-label::before,
.custom-checkbox .custom-control-input:disabled:checked ~ .custom-control-label::before {
    background-color: rgba(255, 109, 12, .5);
}

.custom-select:focus {
    border-color: #ff9147;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .075), 0 0 5px rgba(255, 145, 71, .5);
}

.spin-win-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1030;
    width: 78px;
    height: 78px;
    border-radius: 50%;
    background-color: #ff6d0c;
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 6px 20px rgba(255, 109, 12, .5);
    animation: spin-win-pulse 2.2s infinite;
    transition: transform .2s ease;
}

.spin-win-float:hover,
.spin-win-float:focus {
    color: #fff;
    text-decoration: none;
    transform: scale(1.08);
    animation-play-state: paused;
}

.spin-win-float-icon {
    font-size: 20px;
    line-height: 1;
    margin-bottom: 3px;
}

.spin-win-float-text {
    font-size: 11px;
    font-weight: 700;
    line-height: 1.15;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .02em;
}

@keyframes spin-win-pulse {
    0% { box-shadow: 0 6px 20px rgba(255, 109, 12, .5), 0 0 0 0 rgba(255, 109, 12, .55); }
    70% { box-shadow: 0 6px 20px rgba(255, 109, 12, .5), 0 0 0 16px rgba(255, 109, 12, 0); }
    100% { box-shadow: 0 6px 20px rgba(255, 109, 12, .5), 0 0 0 0 rgba(255, 109, 12, 0); }
}

@media (max-width: 575.98px) {
    .spin-win-float {
        width: 64px;
        height: 64px;
        bottom: 16px;
        right: 16px;
    }

    .spin-win-float-icon {
        font-size: 16px;
    }

    .spin-win-float-text {
        font-size: 9px;
    }
}

/* Scrolling promo strip (partials/promo-marquee.blade.php) — an ad-style ticker
   under the header. Two identical groups sit side by side and the track slides
   left by exactly one group's width, so the loop is seamless. */
.promo-marquee {
    overflow: hidden;
    background: #ff6d0c;
    color: #fff;
    white-space: nowrap;
}

.promo-marquee-track {
    display: flex;
    width: max-content;
    animation: promo-marquee-slide 45s linear infinite;
}

.promo-marquee:hover .promo-marquee-track,
.promo-marquee:focus-within .promo-marquee-track {
    animation-play-state: paused;
}

.promo-marquee-group {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    margin: 0;
    padding: 0;
    list-style: none;
}

.promo-marquee-group li {
    display: flex;
    align-items: center;
    padding: 9px 0;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.promo-marquee-group li::after {
    content: '\2022';
    margin: 0 22px;
    opacity: .7;
}

.promo-marquee-group a,
.promo-marquee-group a:hover,
.promo-marquee-group a:focus {
    color: #fff !important;
    text-decoration: none;
}

.promo-marquee-group a:hover {
    text-decoration: underline;
}

@keyframes promo-marquee-slide {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@media (max-width: 575.98px) {
    .promo-marquee-group li {
        padding: 7px 0;
        font-size: 11px;
    }

    .promo-marquee-group li::after {
        margin: 0 14px;
    }
}

/* Respect "reduce motion": no sliding, just a scrollable single row. */
@media (prefers-reduced-motion: reduce) {
    .promo-marquee {
        overflow-x: auto;
    }

    .promo-marquee-track {
        animation: none;
    }

    .promo-marquee-group[aria-hidden="true"] {
        display: none;
    }
}

/* ---------------------------------------------------------------------------
   Signature hero: the "repair beam" phone (partials/repair-phone.blade.php)
   Palette is the site's own: charcoal #1b1e21, orange #ff6d0c, deep brown #2d1200.
   --------------------------------------------------------------------------- */
.repair-phone-wrap {
    --br: 96px; /* beam radius */
    display: flex;
    flex-direction: column;
    align-items: center;
    perspective: 1100px;
}

.repair-phone-float {
    animation: repair-phone-float 6s ease-in-out infinite;
}

.repair-phone {
    width: min(262px, 66vw);
    transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
    transition: transform .25s ease-out;
}

.repair-phone-body {
    position: relative;
    aspect-ratio: 9 / 18.6;
    padding: 10px;
    border-radius: 42px;
    background: #0b0c0e;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, .1),
        0 38px 90px -22px rgba(255, 109, 12, .5),
        0 18px 40px -18px rgba(0, 0, 0, .8);
}

.repair-phone-notch {
    position: absolute;
    top: 17px;
    left: 50%;
    z-index: 5;
    width: 74px;
    height: 20px;
    border-radius: 20px;
    background: #050506;
    transform: translateX(-50%);
}

.repair-phone-screen {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 33px;
    background: #1b1e21;
    cursor: crosshair;
    touch-action: pan-y; /* vertical swipes still scroll the page */
    user-select: none;
    -webkit-user-select: none;
}

.repair-phone-cracked,
.repair-phone-fixed {
    position: absolute;
    inset: 0;
}

.repair-phone-cracked {
    background:
        radial-gradient(circle at 60% 36%, rgba(0, 0, 0, .55), transparent 46%),
        linear-gradient(160deg, #2a2d31, #15171a);
}

.repair-phone-cracked svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.repair-phone-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent 38%, rgba(255, 255, 255, .06) 46%, transparent 54%);
}

.repair-phone-fixed {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 58px 18px 18px;
    color: #fff;
    background:
        radial-gradient(130% 62% at 50% 0%, #ff6d0c 0%, #b34200 30%, #2d1200 66%, #130d09 100%);
    -webkit-mask-image: radial-gradient(circle var(--br) at var(--bx, 50%) var(--by, 50%), #000 60%, transparent 100%);
    mask-image: radial-gradient(circle var(--br) at var(--bx, 50%) var(--by, 50%), #000 60%, transparent 100%);
}

.rp-time {
    font-size: 54px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -.02em;
}

.rp-date {
    margin-top: 6px;
    font-size: 11px;
    letter-spacing: .18em;
    text-transform: uppercase;
    opacity: .85;
}

.rp-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-top: 44px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, .13);
    border: 1px solid rgba(255, 255, 255, .22);
}

.rp-card strong {
    font-size: 15px;
}

.rp-card span {
    margin-top: 2px;
    font-size: 12px;
    opacity: .8;
}

.rp-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 14px;
}

.rp-chips span {
    padding: 5px 11px;
    border-radius: 99px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .04em;
    background: rgba(0, 0, 0, .35);
    border: 1px solid rgba(255, 255, 255, .2);
}

.rp-home {
    position: absolute;
    bottom: 9px;
    left: 50%;
    width: 84px;
    height: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, .75);
    transform: translateX(-50%);
}

.repair-phone-beam {
    position: absolute;
    left: var(--bx, 50%);
    top: var(--by, 50%);
    width: calc(var(--br) * 1.7);
    height: calc(var(--br) * 1.7);
    border: 2px solid rgba(255, 109, 12, .9);
    border-radius: 50%;
    box-shadow: 0 0 26px rgba(255, 109, 12, .65), inset 0 0 26px rgba(255, 109, 12, .3);
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.repair-phone-hint {
    margin: 22px 0 0;
    font-size: 12px;
    letter-spacing: .08em;
    text-align: center;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .6);
}

.rp-hint-touch {
    display: none;
}

@media (hover: none) {
    .rp-hint-pointer { display: none; }
    .rp-hint-touch { display: inline; }
}

@keyframes repair-phone-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@media (max-width: 575.98px) {
    .repair-phone-wrap { --br: 80px; }
}

/* Reduce motion: show the phone already repaired, perfectly still. */
.repair-phone-wrap.is-repaired .repair-phone-fixed {
    -webkit-mask-image: none;
    mask-image: none;
}

.repair-phone-wrap.is-repaired .repair-phone-beam {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    .repair-phone-float { animation: none; }
    .repair-phone { transition: none; }
}

/* ---------------------------------------------------------------------------
   "Charging" scroll battery: segmented cells fill as you read, charging stripes
   flow while you scroll, a bolt-headed spark rides the edge, a % tag follows it,
   and the terminal lights up with a flash when you reach the bottom.
   Driven by --cp (0-100) set from custom.js.
   --------------------------------------------------------------------------- */
.charge-bar {
    --cp: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100000;
    height: 9px;
    border-bottom: 1px solid rgba(255, 109, 12, .4);
    background:
        repeating-linear-gradient(90deg, transparent 0 18px, rgba(255, 255, 255, .09) 18px 20px),
        linear-gradient(180deg, rgba(27, 30, 33, .95), rgba(27, 30, 33, .82));
    pointer-events: none;
}

.charge-bar-fill {
    position: relative;
    display: block;
    width: calc(var(--cp) * 1%);
    height: 100%;
    background:
        repeating-linear-gradient(90deg, transparent 0 18px, rgba(27, 30, 33, .92) 18px 20px),
        linear-gradient(180deg, #ff9147 0%, #ff6d0c 55%, #d85500 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .4), 0 0 10px rgba(255, 109, 12, .65);
    transition: width .12s linear;
}

/* flowing "energy" stripes, only moving while the page is being scrolled */
.charge-bar-fill::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(115deg, rgba(255, 255, 255, .34) 0 5px, transparent 5px 14px);
    background-size: 28px 100%;
    opacity: .55;
    animation: charge-flow .7s linear infinite;
    animation-play-state: paused;
}

.charge-bar.is-charging .charge-bar-fill::before { animation-play-state: running; }

/* the spark at the leading edge */
.charge-bar-head {
    position: absolute;
    top: 50%;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 19px;
    height: 19px;
    margin-right: -9px;
    border-radius: 50%;
    background: radial-gradient(circle, #fff 0 28%, #ff9147 30% 56%, rgba(255, 109, 12, 0) 74%);
    box-shadow: 0 0 14px 4px rgba(255, 109, 12, .8);
    font-size: 9px;
    color: #1b1e21;
    transform: translateY(-50%);
    animation: charge-pulse 1.4s ease-in-out infinite;
}

.charge-bar.is-charging .charge-bar-head { animation-duration: .6s; }

/* battery terminal at the far end */
.charge-bar-nub {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 6px;
    border-left: 1px solid rgba(255, 109, 12, .55);
    background: rgba(255, 109, 12, .22);
    transition: background .3s, box-shadow .3s;
}

/* % tag that follows the spark while you scroll */
.charge-bar-tag {
    position: absolute;
    top: 100%;
    left: clamp(42px, calc(var(--cp) * 1%), calc(100% - 42px));
    margin-top: 5px;
    padding: 2px 9px 2px 7px;
    border: 1px solid #ff6d0c;
    border-radius: 99px;
    background: #1b1e21;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.35;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    color: #fff;
    opacity: 0;
    transform: translateX(-50%) translateY(-5px);
    transition: opacity .25s, transform .25s;
}

.charge-bar-tag i { color: #ff6d0c; }
.charge-bar.is-charging .charge-bar-tag { opacity: 1; transform: translateX(-50%); }

/* fully charged */
.charge-bar.is-full .charge-bar-nub { background: #ff6d0c; box-shadow: 0 0 12px 2px rgba(255, 109, 12, .9); }
.charge-bar.is-full .charge-bar-fill { animation: charge-full 1.2s ease-out; }
.charge-bar.is-full .charge-bar-unit { display: none; }

@keyframes charge-flow { to { background-position: 28px 0; } }
@keyframes charge-pulse {
    0%, 100% { opacity: 1; transform: translateY(-50%) scale(1); }
    50% { opacity: .65; transform: translateY(-50%) scale(.78); }
}
@keyframes charge-full {
    0% { filter: brightness(1); }
    25% { filter: brightness(1.8) saturate(1.2); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6), 0 0 22px 6px rgba(255, 109, 12, .95); }
    100% { filter: brightness(1); }
}

@media (prefers-reduced-motion: reduce) {
    .charge-bar-fill { transition: none; }
    .charge-bar-fill::before, .charge-bar-head, .charge-bar.is-full .charge-bar-fill { animation: none; }
    .charge-bar-tag { display: none; }
}

/* ===========================================================================
   Animation pack — palette stays the site's own (charcoal #1b1e21, orange
   #ff6d0c, deep brown #2d1200, white). Behaviour: public/vendor/ezy/js/custom.js
   =========================================================================== */

/* ---- Scroll reveal ------------------------------------------------------ */
html.js [data-reveal] {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity .7s ease var(--rd, 0ms), transform .7s cubic-bezier(.2, .7, .2, 1) var(--rd, 0ms);
}

html.js [data-reveal].is-visible {
    opacity: 1;
    transform: none;
}

/* ---- Card tilt + glare -------------------------------------------------- */
@media (hover: hover) and (pointer: fine) {
    [data-tilt] {
        position: relative;
        transform: perspective(900px) rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg));
        transition: transform .18s ease-out, box-shadow .25s;
        will-change: transform;
    }

    [data-tilt]::after {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        pointer-events: none;
        opacity: 0;
        transition: opacity .2s;
        background: radial-gradient(circle at var(--gx, 50%) var(--gy, 50%), rgba(255, 255, 255, .3), transparent 55%);
    }

    [data-tilt].is-tilting {
        box-shadow: 0 18px 38px -14px rgba(27, 30, 33, .38);
    }

    [data-tilt].is-tilting::after {
        opacity: 1;
    }
}

/* ---- Stars that fill in ------------------------------------------------- */
.stars i {
    margin-right: 2px;
    font-size: 15px;
    color: #dfe2e6;
    transform: scale(.6);
    transition: color .35s calc(var(--si, 1) * .13s), transform .45s calc(var(--si, 1) * .13s) cubic-bezier(.3, 1.6, .5, 1);
}

.stars i:not(.is-on) {
    transform: none;
}

[data-reveal].is-visible .stars i.is-on,
html:not(.js) .stars i.is-on {
    color: #ff6d0c;
    transform: scale(1);
}

/* ---- Hero rotating word ------------------------------------------------- */
.rotator {
    min-height: 1.6em;
    font-size: clamp(1.15rem, 2.4vw, 1.6rem);
}

.rotator-word {
    position: relative;
    display: inline-block;
    min-width: 1ch;
    color: #ff6d0c;
}

.rotator-caret {
    display: inline-block;
    width: 2px;
    height: 1.05em;
    margin-left: 3px;
    vertical-align: -.15em;
    background: #ff6d0c;
    animation: caret-blink 1s steps(1) infinite;
}

.rotator-word.is-cracking {
    animation: rot-shake .56s steps(2);
}

.rotator-word.is-cracking::before,
.rotator-word.is-cracking::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    white-space: nowrap;
}

.rotator-word.is-cracking::before {
    color: #fff;
    clip-path: polygon(0 0, 100% 0, 100% 48%, 0 60%);
    transform: translate(-3px, -2px);
}

.rotator-word.is-cracking::after {
    color: #ff9147;
    clip-path: polygon(0 58%, 100% 46%, 100% 100%, 0 100%);
    transform: translate(3px, 2px);
}

@keyframes caret-blink { 50% { opacity: 0; } }
@keyframes rot-shake {
    0% { transform: translateX(0); }
    25% { transform: translateX(-2px); }
    50% { transform: translateX(2px); }
    75% { transform: translateX(-1px); }
    100% { transform: none; }
}

/* ---- Circuit-board background ------------------------------------------ */
.circuit-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.circuit-bg .cb-trace {
    fill: none;
    stroke: rgba(255, 255, 255, .07);
    stroke-width: 1.5;
}

.circuit-bg .cb-via {
    fill: #1b1e21;
    stroke: rgba(255, 255, 255, .14);
    stroke-width: 1.5;
}

.circuit-bg .cb-pulse {
    fill: none;
    stroke: #ff6d0c;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-dasharray: 70 930;
    stroke-dashoffset: 1000;
    filter: drop-shadow(0 0 4px rgba(255, 109, 12, .9));
    animation: cb-run 7s linear infinite;
}

@keyframes cb-run { to { stroke-dashoffset: 0; } }

/* ---- Slide to unlock ---------------------------------------------------- */
.slide-unlock {
    max-width: 420px;
    margin: 0 auto;
    user-select: none;
    -webkit-user-select: none;
}

.slide-unlock-track {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 60px;
    overflow: hidden;
    border: 1px solid rgba(255, 109, 12, .5);
    border-radius: 60px;
    background: #1b1e21;
    box-shadow: inset 0 0 22px rgba(255, 109, 12, .12), 0 10px 26px -14px rgba(27, 30, 33, .6);
}

.slide-unlock-track::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: calc(var(--p, 0) * 100%);
    background: linear-gradient(90deg, rgba(255, 109, 12, 0), rgba(255, 109, 12, .5));
    pointer-events: none;
}

.slide-unlock-label {
    padding-left: 44px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .85);
}

@supports ((-webkit-background-clip: text) or (background-clip: text)) {
    .slide-unlock-label {
        background: linear-gradient(90deg, rgba(255, 255, 255, .3) 0%, #fff 50%, rgba(255, 255, 255, .3) 100%) 0 0 / 200% 100%;
        -webkit-background-clip: text;
        background-clip: text;
        -webkit-text-fill-color: transparent;
        color: transparent;
        animation: su-shimmer 2.4s linear infinite;
    }
}

.slide-unlock-handle {
    position: absolute;
    top: 4px;
    left: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #ff6d0c;
    box-shadow: 0 6px 18px rgba(255, 109, 12, .5);
    color: #fff;
    font-size: 18px;
    cursor: grab;
    touch-action: none;
    transition: transform .28s cubic-bezier(.2, .9, .3, 1.2);
}

.slide-unlock.is-dragging .slide-unlock-handle { cursor: grabbing; }
.slide-unlock.is-done .slide-unlock-track { border-color: #ff6d0c; box-shadow: 0 0 28px rgba(255, 109, 12, .55); }
.slide-unlock.is-nudge .slide-unlock-handle { animation: su-nudge .6s ease; }

@keyframes su-shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@keyframes su-nudge { 0%, 100% { transform: translateX(0); } 40% { transform: translateX(28px); } }

/* ---- Inside-your-phone explode view ------------------------------------
   Seven layers (back glass, frame, bottom assembly, logic board, battery,
   OLED, cover glass) pulled apart by --p (0 → 1), set from scroll in custom.js.
   NOTE: layers must never get opacity/filter/overflow/clip-path — any of those
   flatten the 3D context and the lifted chips/screws would collapse.
   ------------------------------------------------------------------------ */
.xv-section {
    --p: 1;
    position: relative;
    height: 260vh;
    background: #1b1e21;
    color: #fff;
}

.xv-pin {
    position: relative;
    display: flex;
    align-items: center;
    height: 100vh;
    padding-top: 90px;
}

.xv-inner { width: 100%; }

.xv-stage {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: min(72vh, 600px);
    perspective: 1600px;
}

.xv-phone {
    --w: min(200px, 44vw);
    --s: 52px;
    --r: calc(var(--w) * .135);
    position: relative;
    width: var(--w);
    aspect-ratio: 9 / 18.6;
    font-size: calc(var(--w) / 19);
    transform-style: preserve-3d;
    transform: rotateX(calc(12deg + 46deg * var(--p))) rotateZ(calc(-4deg - 28deg * var(--p)));
    will-change: transform;
}

.xv-layer {
    position: absolute;
    inset: 0;
    border-radius: var(--r);
    transform-style: preserve-3d;
    transform: translateZ(calc((var(--i) - 3) * var(--s) * var(--p) + var(--i) * .5px));
    transition: box-shadow .45s;
}

.xv-layer > * { position: absolute; }

/* dim overlay: how a layer steps back while another one is being talked about */
.xv-layer::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: #1b1e21;
    opacity: 0;
    pointer-events: none;
    transition: opacity .45s;
}

.xv-shadow {
    position: absolute;
    inset: 4% -6%;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, .6), transparent 68%);
    opacity: var(--p);
    transform: translateZ(calc(-3 * var(--s) * var(--p) - 18px));
}

.xv-glare {
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(115deg, transparent 28%, rgba(255, 255, 255, .16) 42%, transparent 54%);
    transform: translateX(calc((var(--p) - .5) * 40%));
    pointer-events: none;
}

/* 0 · back glass + camera island */
.xv-l-back {
    --i: 0;
    border: 1.5px solid rgba(255, 255, 255, .18);
    background: linear-gradient(155deg, #4b2309 0%, #2d1200 52%, #190a00 100%);
}

.xv-coil { top: 46%; left: 50%; width: 46%; aspect-ratio: 1; transform: translate(-50%, -50%); }
.xv-coil i { position: absolute; border: 1.2px solid rgba(255, 145, 71, .24); border-radius: 50%; }
.xv-coil i:nth-child(1) { inset: 0; }
.xv-coil i:nth-child(2) { inset: 16%; }
.xv-coil i:nth-child(3) { inset: 32%; }

.xv-mark { top: 60%; left: 50%; font-size: 2.6em; color: rgba(255, 255, 255, .13); transform: translate(-50%, -50%); }

.xv-etch {
    right: 0;
    bottom: 4.2%;
    left: 0;
    font-size: .5em;
    letter-spacing: .28em;
    text-align: center;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .3);
}

.xv-cam {
    top: 3.2%;
    left: 7%;
    width: 50%;
    height: 22%;
    border: 1.5px solid rgba(255, 255, 255, .2);
    border-radius: 24%;
    background: rgba(27, 30, 33, .92);
    box-shadow: 0 .3em .8em rgba(0, 0, 0, .45);
    transform-style: preserve-3d;
}

.xv-cam > * { position: absolute; }

.xv-lens {
    width: 38%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle, #05060a 0 22%, #3a3f46 24% 28%, #0c0d10 30% 52%, #8f959c 54% 58%, #1b1e21 60% 100%);
    box-shadow: 0 0 0 .18em rgba(255, 255, 255, .3), 0 .25em .6em rgba(0, 0, 0, .5);
    transform: translateZ(calc(var(--p) * 7px + 1px));
}

.xv-lens-1 { top: 7%; left: 8%; }
.xv-lens-2 { top: 53%; left: 8%; }
.xv-lens-3 { top: 30%; left: 54%; }

.xv-flash {
    top: 6%;
    left: 62%;
    width: 14%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: #fff3e0;
    box-shadow: 0 0 .6em rgba(255, 145, 71, .9);
    animation: xv-flash 3.6s ease-in-out infinite;
}

.xv-lidar { top: 80%; left: 80%; width: 12%; aspect-ratio: 1; border-radius: 50%; background: #05060a; box-shadow: 0 0 0 1px rgba(255, 255, 255, .3); }
.xv-mic { top: 84%; left: 62%; width: 6%; aspect-ratio: 1; border-radius: 50%; background: #05060a; }

/* 1 · frame: rails, antenna bands, buttons, SIM tray */
.xv-l-frame {
    --i: 1;
    border: .38em solid #7d848c;
    box-shadow: inset 0 0 0 1px rgba(27, 30, 33, .9), 0 0 0 1px rgba(255, 255, 255, .18);
}

.xv-mid { inset: 1.4%; border: 1px dashed rgba(255, 255, 255, .16); border-radius: calc(var(--r) * .8); background: rgba(255, 255, 255, .03); }

.xv-band { background: #1b1e21; }
.xv-band-t1 { top: -.38em; left: 20%; width: .5em; height: .38em; }
.xv-band-t2 { top: -.38em; right: 20%; width: .5em; height: .38em; }
.xv-band-l { top: 68%; left: -.38em; width: .38em; height: .5em; }
.xv-band-r { top: 68%; right: -.38em; width: .38em; height: .5em; }

.xv-btn { width: .42em; border-radius: .2em; background: linear-gradient(90deg, #a4aab2, #6b7179); box-shadow: 0 0 .25em rgba(0, 0, 0, .5); }
.xv-btn-act { top: 12%; left: -.78em; height: 3%; transform: translateX(calc(var(--p) * -.5em)); }
.xv-btn-up { top: 20%; left: -.78em; height: 6.5%; transform: translateX(calc(var(--p) * -.5em)); }
.xv-btn-down { top: 28.5%; left: -.78em; height: 6.5%; transform: translateX(calc(var(--p) * -.5em)); }
.xv-btn-pwr { top: 24%; right: -.78em; height: 10%; transform: translateX(calc(var(--p) * .5em)); }

.xv-sim {
    bottom: -.38em;
    left: 20%;
    width: 14%;
    height: .38em;
    border-radius: 0 0 .15em .15em;
    background: linear-gradient(180deg, #a4aab2, #6b7179);
    transform: translateY(calc(var(--p) * 1em));
}

.xv-sim i { position: absolute; top: 50%; left: 50%; width: .8em; height: .5em; border: 1px solid #ff9147; border-radius: .1em; background: rgba(255, 109, 12, .4); transform: translate(-50%, -20%); }

.xv-post { width: 3.4%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, #1b1e21 40%, #8f959c 42%); }
.xv-post-1 { top: 2%; left: 4%; }
.xv-post-2 { top: 2%; right: 4%; }
.xv-post-3 { bottom: 1.4%; left: 4%; }
.xv-post-4 { bottom: 1.4%; right: 4%; }

/* 2 · charging port + bottom assembly */
.xv-l-port { --i: 2; }

.xv-plate {
    top: 82%;
    right: 5%;
    bottom: 2%;
    left: 5%;
    border: 1.5px dashed rgba(255, 255, 255, .28);
    border-radius: 0 0 calc(var(--r) * .8) calc(var(--r) * .8);
    background: rgba(27, 30, 33, .55);
}

.xv-taptic { top: 84.2%; left: 10%; width: 38%; height: 5.6%; border: 1px solid rgba(255, 255, 255, .25); border-radius: .4em; background: rgba(255, 255, 255, .08); transform: translateZ(calc(var(--p) * 5px + 1px)); }
.xv-taptic i { position: absolute; inset: 22% 10%; border-radius: .25em; background: repeating-linear-gradient(90deg, rgba(255, 145, 71, .55) 0 .22em, transparent .22em .5em); }

.xv-grille { top: 91.6%; width: 22%; height: 3.4%; background: radial-gradient(circle, #ff9147 .13em, transparent .2em) 0 0 / .6em .6em; opacity: .75; }
.xv-grille-l { left: 9%; }
.xv-grille-r { left: 69%; }

.xv-usbc { top: 91.4%; left: 50%; width: 15%; height: 3.6%; border: .15em solid #9aa0a8; border-radius: 99px; background: #0b0c0e; transform: translateX(-50%) translateZ(calc(var(--p) * 6px + 1px)); }
.xv-usbc i { position: absolute; inset: 36% 14%; background: repeating-linear-gradient(90deg, #ff9147 0 .2em, transparent .2em .4em); animation: xv-pins 2.6s ease-in-out infinite; }
.xv-usbc-tag { top: 88%; left: 50%; font-size: .5em; letter-spacing: .2em; color: rgba(255, 255, 255, .55); transform: translateX(-50%); }

.xv-mic2 { top: 94.2%; left: 38%; width: .5em; height: .5em; border: 1px solid #ff9147; border-radius: 50%; background: #0b0c0e; }
.xv-mic2-b { left: 60%; }

.xv-flex-port {
    top: 62%;
    left: 85%;
    width: 5%;
    height: 29%;
    border-radius: .3em;
    background: repeating-linear-gradient(90deg, rgba(27, 30, 33, .55) 0 1px, transparent 1px 3px), linear-gradient(180deg, rgba(255, 145, 71, .6), rgba(255, 109, 12, .3));
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22);
}

/* 3 · logic board */
.xv-l-board { --i: 3; }

.xv-pcb { top: 0; left: 0; width: 100%; height: 100%; }
.xv-pcb-body { fill: #14171a; stroke: rgba(255, 109, 12, .75); stroke-width: .9; stroke-linejoin: round; }
.xv-pcb-traces path { fill: none; stroke: rgba(255, 145, 71, .4); stroke-width: .6; stroke-linejoin: round; }
.xv-pcb-vias circle { fill: #14171a; stroke: #ff9147; stroke-width: .5; }

.xv-chip {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, .28);
    border-radius: .25em;
    background: linear-gradient(145deg, #2b3036, #16191c);
    box-shadow: 0 .2em .5em rgba(0, 0, 0, .55);
    transform: translateZ(calc(var(--p) * 9px + 1px));
}

.xv-chip b { font-size: .55em; font-weight: 700; letter-spacing: .14em; color: rgba(255, 255, 255, .72); }

.xv-soc { top: 8.7%; left: 16%; width: 30%; height: 11.6%; align-items: flex-end; transform: translateZ(calc(var(--p) * 12px + 1px)); }
.xv-soc b { margin-bottom: .45em; }
.xv-soc i { position: absolute; inset: 16% 18% 34%; border: 1px solid rgba(255, 109, 12, .85); background: rgba(255, 109, 12, .12); animation: xv-die 2.4s ease-in-out infinite; }
.xv-ram { top: 10.2%; left: 20%; width: 22%; height: 4.8%; transform: translateZ(calc(var(--p) * 24px + 3px)); }
.xv-nand { top: 8.7%; left: 52%; width: 30%; height: 7.7%; }
.xv-modem { top: 18.4%; left: 52%; width: 30%; height: 8.7%; }
.xv-pmic { top: 21.7%; left: 16%; width: 14%; height: 5.8%; }
.xv-wifi { top: 22.5%; left: 36%; width: 12%; height: 4.8%; }
.xv-codec { top: 55%; left: 13%; width: 17%; height: 5.5%; }
.xv-pmu { top: 75.5%; left: 14%; width: 20%; height: 8%; }
.xv-hdrv { top: 75.5%; left: 38%; width: 20%; height: 7%; }

.xv-can {
    top: 40%;
    left: 12.5%;
    width: 19%;
    height: 12%;
    border: 1px dashed rgba(255, 255, 255, .38);
    background: repeating-linear-gradient(45deg, rgba(255, 255, 255, .14) 0 .3em, rgba(255, 255, 255, .04) .3em .6em);
    transform: translateZ(calc(var(--p) * 15px + 1px));
}

.xv-conn { border: 1px solid #ff9147; border-radius: .15em; background: #0c0e10; transform: translateZ(calc(var(--p) * 3px + 1px)); }
.xv-conn-c1 { top: 4.6%; left: 14%; width: 8%; height: 2.2%; }
.xv-conn-c2 { top: 4.6%; left: 24%; width: 8%; height: 2.2%; }
.xv-conn-c3 { top: 4.6%; left: 34%; width: 8%; height: 2.2%; }
.xv-conn-disp { top: 4.6%; left: 72%; width: 14%; height: 2.2%; }
.xv-conn-batt { top: 31.5%; left: 24%; width: 8%; height: 2.6%; }
.xv-conn-port { top: 90.5%; left: 20%; width: 30%; height: 2.6%; }

.xv-caps { height: 1.6%; border-radius: .1em; background: repeating-linear-gradient(90deg, rgba(255, 145, 71, .7) 0 .35em, transparent .35em .7em); transform: translateZ(calc(var(--p) * 4px + 1px)); }
.xv-caps-1 { top: 86.2%; left: 14%; width: 40%; }
.xv-caps-2 { top: 28.6%; left: 52%; width: 30%; }
.xv-caps-3 { top: 64%; left: 13%; width: 15%; }

.xv-screw {
    width: 5%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #c4c9cf, #5b6168 60%, #2c3035);
    box-shadow: 0 .25em .5em rgba(0, 0, 0, .6);
    transform: translateZ(calc(var(--p) * 26px + 2px)) rotate(calc(var(--p) * -540deg));
}

.xv-screw::before,
.xv-screw::after { content: ''; position: absolute; top: 50%; left: 14%; width: 72%; height: 1.5px; background: #1b1e21; transform: translateY(-50%); }
.xv-screw::after { transform: translateY(-50%) rotate(90deg); }

/* 4 · battery */
.xv-l-battery { --i: 4; }

.xv-cell {
    top: 31.5%;
    left: 36%;
    width: 54%;
    height: 38.7%;
    overflow: hidden;
    border: 1.5px solid rgba(255, 255, 255, .3);
    border-radius: .9em;
    background: linear-gradient(160deg, #2a2f35, #1b1e21 60%);
    box-shadow: 0 .4em 1em rgba(0, 0, 0, .5);
}

.xv-cell > * { position: absolute; }
.xv-cell-sep { top: 0; bottom: 0; width: 1px; background: rgba(255, 255, 255, .14); }
.xv-cell-sep-1 { left: 33%; }
.xv-cell-sep-2 { left: 66%; }
.xv-cell-charge { right: 0; bottom: 0; left: 0; height: 100%; background: linear-gradient(0deg, rgba(255, 109, 12, .55), rgba(255, 109, 12, 0) 70%); transform: translateY(100%); animation: xv-charge 3.4s ease-in-out infinite; }
.xv-cell-label { top: 34%; right: 0; left: 0; font-size: .95em; font-weight: 800; letter-spacing: .04em; text-align: center; color: #fff; }
.xv-cell-label i { color: #ff6d0c; }
.xv-cell-spec { top: 56%; right: 0; left: 0; font-size: .55em; letter-spacing: .1em; text-align: center; text-transform: uppercase; color: rgba(255, 255, 255, .6); }
.xv-cell-warn { top: 8%; left: 8%; font-size: .85em; color: #ff6d0c; }
.xv-cell-code { right: 8%; bottom: 8%; width: 34%; height: 10%; opacity: .55; background: repeating-linear-gradient(90deg, #fff 0 1px, transparent 1px 3px, #fff 3px 5px, transparent 5px 6px); }

.xv-tab { top: 69%; width: 5%; height: 13%; border-radius: 0 0 .3em .3em; background: linear-gradient(180deg, #fff, #cfd3d8); box-shadow: 0 0 .4em rgba(255, 255, 255, .3); transform: translateY(calc(var(--p) * .9em)); }
.xv-tab-1 { left: 48%; }
.xv-tab-2 { left: 70%; }

.xv-bflex { top: 33.2%; left: 24%; width: 13%; height: 1.6%; border-radius: .2em; background: linear-gradient(90deg, rgba(255, 145, 71, .7), rgba(255, 109, 12, .35)); }

/* 5 · OLED panel */
.xv-l-oled {
    --i: 5;
    border: 1px solid rgba(255, 255, 255, .18);
    background: rgba(10, 10, 12, .9);
}

.xv-ui {
    inset: 2.2% 3.6%;
    overflow: hidden;
    border-radius: calc(var(--r) * .78);
    background: radial-gradient(120% 62% at 50% 0%, #ff6d0c 0%, #a63f00 26%, #2d1200 60%, #130d09 100%);
}

.xv-ui > * { position: absolute; }

.xv-scan { top: 0; right: 0; left: 0; height: 14%; background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .14), transparent); transform: translateY(-100%); animation: xv-scan 4.5s linear infinite; }

.xv-island { top: 1.3%; left: 50%; width: 26%; height: 3.4%; border-radius: 99px; background: #000; transform: translateX(-50%); }
.xv-island i { position: absolute; top: 50%; width: .55em; height: .55em; border-radius: 50%; transform: translateY(-50%); }
.xv-island i:nth-child(1) { right: 12%; background: #3a3f46; box-shadow: inset 0 0 0 1px #ff6d0c; }
.xv-island i:nth-child(2) { left: 14%; width: .38em; height: .38em; background: #2a2f35; }

.xv-stat-time { top: 2.1%; left: 9%; font-size: .85em; font-weight: 700; }
.xv-stat-icons { top: 2.2%; right: 8%; display: flex; align-items: center; gap: .3em; font-size: .7em; }
.xv-sig { display: inline-flex; align-items: flex-end; gap: 1px; height: .8em; }
.xv-sig i { width: 2px; background: #fff; }
.xv-sig i:nth-child(1) { height: 35%; }
.xv-sig i:nth-child(2) { height: 55%; }
.xv-sig i:nth-child(3) { height: 75%; }
.xv-sig i:nth-child(4) { height: 100%; }
.xv-batt { position: relative; display: inline-block; width: 1.4em; height: .7em; border: 1px solid rgba(255, 255, 255, .8); border-radius: .2em; }
.xv-batt i { position: absolute; inset: 1px; width: 80%; background: #fff; }

.xv-date { top: 11%; right: 0; left: 0; font-size: .6em; font-weight: 600; letter-spacing: .06em; text-align: center; opacity: .85; }
.xv-clock { top: 13.2%; right: 0; left: 0; font-size: 3.2em; font-weight: 800; line-height: 1; text-align: center; }
.xv-widgets { top: 31%; right: 6%; left: 6%; display: grid; grid-template-columns: 1fr 1fr; gap: .4em; }
.xv-widget { padding: .5em; border-radius: .7em; background: rgba(27, 30, 33, .5); font-size: .6em; font-weight: 700; text-align: center; }
.xv-widget i { color: #ff9147; }

.xv-apps { top: 44%; right: 6%; left: 6%; display: grid; grid-template-columns: repeat(4, 1fr); gap: .55em .35em; }
.xv-dock { right: 5%; bottom: 5%; left: 5%; display: grid; grid-template-columns: repeat(4, 1fr); gap: .35em; padding: .4em; border-radius: 1em; background: rgba(255, 255, 255, .14); }
.xv-app { display: flex; align-items: center; justify-content: center; aspect-ratio: 1; border-radius: .55em; font-size: .85em; color: #fff; }
.xv-app-0 { background: rgba(255, 255, 255, .16); }
.xv-app-1 { background: #ff6d0c; }
.xv-app-2 { background: #1b1e21; }
.xv-app-3 { background: linear-gradient(160deg, #ff9147, #ff6d0c); }
.xv-homebar { bottom: 1.6%; left: 50%; width: 30%; height: .25em; border-radius: 9em; background: rgba(255, 255, 255, .7); transform: translateX(-50%); }

.xv-dflex {
    top: 98.6%;
    left: 36%;
    width: 28%;
    height: 4.5%;
    border-radius: 0 0 .5em .5em;
    background: repeating-linear-gradient(90deg, rgba(255, 145, 71, .7) 0 .3em, rgba(255, 109, 12, .25) .3em .6em);
    transform: translateY(calc(var(--p) * .6em));
}

/* 6 · cover glass */
.xv-l-glass {
    --i: 6;
    border: 1.5px solid rgba(255, 255, 255, .42);
    background: linear-gradient(135deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .015) 50%, rgba(255, 255, 255, .06));
    box-shadow: inset 0 0 0 .3em rgba(255, 255, 255, .05);
}

.xv-cracks { top: 0; left: 0; width: 100%; height: 100%; opacity: clamp(.12, calc(var(--p) * 1.1), 1); }
.xv-cracks path { fill: none; stroke: rgba(255, 255, 255, .75); stroke-width: 1; stroke-linejoin: bevel; vector-effect: non-scaling-stroke; }

/* flex pins that stretch between layers as they separate */
.xv-link {
    position: absolute;
    width: 3px;
    height: calc(var(--n) * var(--s) * var(--p));
    margin-left: -1.5px;
    background: repeating-linear-gradient(180deg, #ff6d0c 0 5px, rgba(255, 109, 12, .15) 5px 9px);
    box-shadow: 0 0 9px rgba(255, 109, 12, .85);
    opacity: clamp(0, calc(var(--p) * 3 - .4), 1);
    pointer-events: none;
    transform-origin: 50% 0;
    transform: translateZ(calc((var(--f) - 3) * var(--s) * var(--p) + var(--f) * .5px)) rotateX(90deg);
}

.xv-link-disp { top: 20%; left: 86%; }
.xv-link-batt { top: 33.5%; left: 30%; }
.xv-link-port { top: 91%; left: 40%; }
.xv-link-glass { top: 97.5%; left: 50%; }

/* the layer being talked about lights up, the rest step back */
.xv-phone[data-active] .xv-layer::after { opacity: .58; }

.xv-phone[data-active="1"] :is(.xv-l-oled, .xv-l-glass)::after,
.xv-phone[data-active="2"] .xv-l-battery::after,
.xv-phone[data-active="3"] .xv-l-board::after,
.xv-phone[data-active="4"] .xv-l-port::after,
.xv-phone[data-active="5"] :is(.xv-l-back, .xv-l-frame)::after { opacity: 0; }

.xv-phone[data-active="1"] :is(.xv-l-oled, .xv-l-glass),
.xv-phone[data-active="2"] .xv-l-battery,
.xv-phone[data-active="3"] .xv-l-board,
.xv-phone[data-active="4"] .xv-l-port,
.xv-phone[data-active="5"] :is(.xv-l-back, .xv-l-frame),
.xv-section:has(.xv-legend li:nth-child(1):hover) :is(.xv-l-oled, .xv-l-glass),
.xv-section:has(.xv-legend li:nth-child(2):hover) .xv-l-battery,
.xv-section:has(.xv-legend li:nth-child(3):hover) .xv-l-board,
.xv-section:has(.xv-legend li:nth-child(4):hover) .xv-l-port,
.xv-section:has(.xv-legend li:nth-child(5):hover) :is(.xv-l-back, .xv-l-frame) {
    box-shadow: 0 0 2.6em rgba(255, 109, 12, .7), inset 0 0 0 2px #ff6d0c;
}

/* readout in the corner of the stage */
.xv-hud { position: absolute; top: 0; left: 0; z-index: 2; display: grid; gap: .35rem; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: rgba(255, 255, 255, .65); }
.xv-hud-v { font-size: 26px; font-weight: 800; line-height: 1; letter-spacing: 0; font-variant-numeric: tabular-nums; color: #ff6d0c; }
.xv-hud-bar { display: block; width: 96px; height: 3px; overflow: hidden; border-radius: 3px; background: rgba(255, 255, 255, .14); }
.xv-hud-bar i { display: block; width: calc(var(--p) * 100%); height: 100%; background: #ff6d0c; }
.xv-hud-name { font-weight: 700; color: #fff; }

.xv-badge {
    position: absolute;
    bottom: 0;
    left: 50%;
    padding: .5em 1em;
    border: 1px solid #ff6d0c;
    border-radius: 99px;
    background: rgba(27, 30, 33, .92);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    color: #fff;
    opacity: 0;
    transform: translate(-50%, 12px);
    transition: opacity .5s, transform .5s;
}

.xv-badge i { color: #ff6d0c; }
.xv-section.is-complete .xv-badge,
html:not(.js) .xv-badge { opacity: 1; transform: translate(-50%, 0); }

/* keyframes for the "alive" details; paused whenever the section is off-screen */
@keyframes xv-die { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
@keyframes xv-charge { 0% { transform: translateY(100%); } 55%, 70% { transform: translateY(0); } 100% { transform: translateY(100%); } }
@keyframes xv-scan { to { transform: translateY(720%); } }
@keyframes xv-flash { 0%, 100% { opacity: .65; } 50% { opacity: 1; } }
@keyframes xv-pins { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }

.xv-section:not(.is-live) .xv-phone *,
.xv-section:not(.is-live) .xv-hud * { animation-play-state: paused; }

/* legend */
.xv-legend { margin: 0; padding: 0; }

.xv-legend li {
    display: flex;
    gap: 14px;
    padding: 9px 0 9px 14px;
    border-left: 3px solid rgba(255, 255, 255, .12);
    opacity: .38;
    transform: translateX(-6px);
    transition: opacity .4s, border-color .4s, transform .4s;
}

.xv-legend li.is-on,
html:not(.js) .xv-legend li {
    border-left-color: #ff6d0c;
    opacity: 1;
    transform: none;
}

.xv-num {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #ff6d0c;
    font-size: 12px;
    font-weight: 800;
    color: #fff;
}

.xv-legend strong { display: block; font-size: 15px; color: #fff; }
.xv-legend div span { display: block; font-size: 13px; color: rgba(255, 255, 255, .64); }
.xv-legend a { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #ff6d0c; }


/* ---- Health result: animated ring + ECG line --------------------------- */
@property --hs {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 0%;
}

.health-ring {
    --hs: var(--hs-target, 0%);
    background: conic-gradient(#ff6d0c var(--hs), #eee var(--hs) 100%);
    animation: hs-fill 1.6s cubic-bezier(.2, .7, .2, 1) both;
}

@keyframes hs-fill {
    from { --hs: 0%; }
    to { --hs: var(--hs-target, 0%); }
}

.ecg {
    display: block;
    width: min(300px, 80%);
    height: 60px;
    margin: 0 auto 14px;
    overflow: visible;
}

.ecg-line {
    fill: none;
    stroke: #ff6d0c;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    filter: drop-shadow(0 0 4px rgba(255, 109, 12, .55));
    animation: ecg-draw 1.8s ease-out .15s forwards;
}

@keyframes ecg-draw { to { stroke-dashoffset: 0; } }

/* ---- Unlock / IMEI form extras ----------------------------------------- */
.price-ticker-box {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 10px;
    margin: -4px 0 18px;
    padding: 14px 18px;
    border: 1px solid rgba(255, 109, 12, .45);
    border-radius: 14px;
    background: #1b1e21;
    color: #fff;
}

.price-ticker-label { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.price-ticker { font-size: 30px; font-weight: 800; line-height: 1; color: #ff6d0c; font-variant-numeric: tabular-nums; }
.price-ticker-note { margin-left: auto; font-size: 12px; opacity: .7; }

.imei-wrap { position: relative; overflow: hidden; border-radius: .25rem; }

.imei-scanline {
    position: absolute;
    top: 0;
    bottom: 0;
    left: -30%;
    width: 30%;
    opacity: 0;
    pointer-events: none;
    background: linear-gradient(90deg, transparent, rgba(255, 109, 12, .55), transparent);
}

.imei-scanline.run { animation: imei-sweep .9s ease-out forwards; }
@keyframes imei-sweep { 0% { left: -30%; opacity: 1; } 100% { left: 100%; opacity: 0; } }

.imei-status { min-height: 20px; margin-top: 6px; font-size: 12px; font-weight: 700; letter-spacing: .03em; color: #7c828b; }
.imei-status.is-ok { color: #ff6d0c; }
.imei-status.is-bad { color: #dc3545; }

.imei-art-body {
    position: relative;
    display: block;
    width: 78px;
    height: 132px;
    margin: 0 auto;
    overflow: hidden;
    border: 3px solid #1b1e21;
    border-radius: 14px;
    background: linear-gradient(160deg, #fff, #f4f5f7);
    box-shadow: 0 8px 18px rgba(255, 109, 12, .18);
}

.imei-art-code {
    position: absolute;
    top: 50%;
    right: 0;
    left: 0;
    padding: 0 6px;
    font: 700 7.5px/1.3 monospace;
    letter-spacing: .04em;
    text-align: center;
    color: #1b1e21;
    transform: translateY(-50%);
}

.imei-art-sweep {
    position: absolute;
    right: 0;
    left: 0;
    top: -22px;
    height: 22px;
    border-bottom: 2px solid #ff6d0c;
    background: linear-gradient(180deg, transparent, rgba(255, 109, 12, .55));
    animation: imei-art-scan 2.6s ease-in-out infinite;
}

@keyframes imei-art-scan { 0%, 100% { top: -22px; } 50% { top: 100%; } }

/* ---- Thank-you check mark + confetti canvas ----------------------------- */
.thank-check { display: inline-block; width: 72px; height: 72px; margin-bottom: 14px; }
.thank-check svg { width: 100%; height: 100%; }

.tc-circle {
    fill: none;
    stroke: #ff6d0c;
    stroke-width: 3;
    stroke-dasharray: 145;
    stroke-dashoffset: 145;
    transform: rotate(-90deg);
    transform-box: fill-box;
    transform-origin: center;
    animation: tc-draw .7s ease-out .1s forwards;
}

.tc-tick {
    fill: none;
    stroke: #ff6d0c;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 44;
    stroke-dashoffset: 44;
    animation: tc-draw .45s ease-out .75s forwards;
}

@keyframes tc-draw { to { stroke-dashoffset: 0; } }

.pra-confetti {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 200001;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* ---- One-time "powering on" splash (home, first visit per session) ------ */
#boot-screen {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200000;
    align-items: center;
    justify-content: center;
    background: #1b1e21;
    color: #fff;
    opacity: 1;
    transition: opacity .45s ease;
    /* failsafe: even if JS never runs, the splash removes itself */
    animation: boot-failsafe .01s 2.6s forwards;
}

html.is-booting #boot-screen { display: flex; }
html.is-boot-done #boot-screen { opacity: 0; pointer-events: none; }

.boot-inner { text-align: center; }
.boot-logo { display: block; font-size: clamp(22px, 5vw, 34px); font-weight: 800; letter-spacing: .04em; }

.boot-bar {
    display: block;
    width: min(220px, 60vw);
    height: 4px;
    margin: 20px auto 14px;
    overflow: hidden;
    border-radius: 4px;
    background: rgba(255, 255, 255, .12);
}

.boot-bar i {
    display: block;
    width: 0;
    height: 100%;
    background: #ff6d0c;
    box-shadow: 0 0 12px rgba(255, 109, 12, .8);
    animation: boot-fill 1s ease-out forwards;
}

.boot-note { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; opacity: .6; }

@keyframes boot-fill { to { width: 100%; } }
@keyframes boot-failsafe { to { opacity: 0; visibility: hidden; pointer-events: none; } }

/* ---- Reduced motion: everything above settles into its finished state --- */
@media (prefers-reduced-motion: reduce) {
    html.js [data-reveal] { opacity: 1; transform: none; transition: none; }
    [data-tilt] { transform: none !important; transition: none; }
    .stars i { transition: none; }
    .rotator-caret, .circuit-bg .cb-pulse, .slide-unlock-label, .imei-art-sweep { animation: none; }
    .circuit-bg .cb-pulse { display: none; }
    .xv-section { height: auto; padding: 70px 0; }
    .xv-pin { position: static; display: block; height: auto; padding-top: 0; }
    .health-ring { animation: none; }
    .ecg-line, .tc-circle, .tc-tick { animation: none; stroke-dashoffset: 0; }
    .boot-bar i { animation: none; width: 100%; }
    .xv-section * { animation: none !important; }
}

/* ---- Header nav: nine links must stay on ONE line ----------------------- */
@media (min-width: 992px) {
    #header .header-nav-main nav > ul { flex-wrap: nowrap; }
    #header .header-nav-main nav > ul > li > a { white-space: nowrap; }
    #header .header-container .header-row > .header-column:nth-child(2) { flex: 0 0 auto; }
    #header .header-logo a { white-space: nowrap; }
}

/* laptops: slightly tighter links so the row (logo + 9 links + quote button) fits the 1140px container */
@media (min-width: 992px) and (max-width: 1399.98px) {
    #header .header-nav-main.header-nav-main-uppercase nav > ul > li > a {
        padding-left: .62em;
        padding-right: .62em;
        font-size: .7rem;
        letter-spacing: 0;
    }
    #header .header-button .btn { padding-left: 1.1rem; padding-right: 1.1rem; font-size: .75rem; }
}

/* small laptops / tablets landscape: the quote button gives way (it's in the hero, top bar and every page) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    #header .header-button { display: none !important; }
    #header .header-nav-main.header-nav-main-uppercase nav > ul > li > a { padding-left: .5em; padding-right: .5em; }
}

/* ---- Explode view, round 2: props, scan beam, callouts, linked legend ---- */
@property --az {
    syntax: '<number>';
    inherits: true;
    initial-value: 3;
}

.xv-phone {
    --az: 3;
    --w: min(176px, 44vw);
    margin-left: 17%;
    transition: --az .55s cubic-bezier(.3, .7, .3, 1);
}

/* the layer edge each callout line points at */
.xv-probe { top: 50%; right: 0; width: 1px; height: 1px; pointer-events: none; }

/* ambient glow + floor grid under the stack */
.xv-glow {
    position: absolute;
    inset: -30% -60%;
    background: radial-gradient(closest-side, rgba(255, 109, 12, .38), transparent 72%);
    opacity: calc(.15 + var(--p) * .85);
    transform: translateZ(calc(-3 * var(--s) * var(--p) - 40px));
}

.xv-floor {
    position: absolute;
    inset: -45% -85%;
    background:
        repeating-linear-gradient(0deg, rgba(255, 109, 12, .22) 0 1px, transparent 1px 28px),
        repeating-linear-gradient(90deg, rgba(255, 109, 12, .22) 0 1px, transparent 1px 28px);
    -webkit-mask-image: radial-gradient(closest-side, #000 18%, transparent 100%);
    mask-image: radial-gradient(closest-side, #000 18%, transparent 100%);
    opacity: var(--p);
    transform: translateZ(calc(-3 * var(--s) * var(--p) - 26px));
}

/* technician's props -------------------------------------------------- */

/* suction cup that lifts the glass */
.xv-cup-shadow { top: 80%; left: 38%; width: 24%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, rgba(0, 0, 0, .4), transparent 70%); }

.xv-cup {
    top: 80%;
    left: 38%;
    width: 24%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle at 38% 32%, #ff9147, #ff6d0c 55%, #a63f00);
    box-shadow: 0 .3em .7em rgba(0, 0, 0, .5), inset 0 0 0 .22em rgba(255, 255, 255, .25);
    transform: translateZ(calc(var(--p) * 34px + 3px));
}

.xv-cup i { position: absolute; top: 50%; left: 50%; width: 38%; height: 38%; border-radius: 50%; background: #1b1e21; box-shadow: 0 0 0 .18em rgba(255, 255, 255, .55); transform: translate(-50%, -50%); }

/* precision screwdriver hovering over the first screw (shown while the board is being discussed) */
.xv-driver {
    top: 7.6%;
    left: 15%;
    width: 8px;
    height: 70px;
    margin-left: -4px;
    opacity: 0;
    transform-origin: 50% 0;
    transform: translateZ(calc(var(--p) * 26px + 5px)) rotateX(90deg);
    transition: opacity .4s;
    background-image:
        repeating-linear-gradient(90deg, rgba(27, 30, 33, .65) 0 1px, transparent 1px 2px),
        linear-gradient(#ff6d0c, #ff6d0c),
        linear-gradient(90deg, transparent 0 36%, #aeb4bb 36% 64%, transparent 64%);
    background-size: 100% 62%, 100% 62%, 100% 38%;
    background-position: 0 100%, 0 100%, 0 0;
    background-repeat: repeat-x, no-repeat, no-repeat;
    animation: xv-grip .9s linear infinite;
}

.xv-phone[data-active="3"] .xv-driver { opacity: 1; }

/* corrosion found on the board while it is being inspected */
.xv-rust {
    border-radius: 50%;
    opacity: 0;
    background: radial-gradient(circle, rgba(255, 109, 12, .65), rgba(120, 50, 0, .4) 48%, transparent 72%);
    transform: translateZ(calc(var(--p) * 2px + 1px));
}

.xv-rust-1 { top: 20%; left: 46%; width: 14%; aspect-ratio: 1; }
.xv-rust-2 { top: 54%; left: 10%; width: 11%; aspect-ratio: 1; }
.xv-rust-3 { top: 79%; left: 36%; width: 12%; aspect-ratio: 1; }
.xv-phone[data-active="3"] .xv-rust { animation: xv-rust 1.8s ease-in-out infinite; }
.xv-phone[data-active="3"] .xv-rust-2 { animation-delay: .4s; }
.xv-phone[data-active="3"] .xv-rust-3 { animation-delay: .8s; }

/* diagnostic beam: a plane that glides to the active layer */
.xv-beam {
    position: absolute;
    inset: -3% -5%;
    overflow: hidden;
    border: 1.5px solid rgba(255, 109, 12, .9);
    border-radius: var(--r);
    background: linear-gradient(180deg, rgba(255, 109, 12, 0), rgba(255, 109, 12, .13));
    box-shadow: 0 0 22px rgba(255, 109, 12, .55);
    opacity: 0;
    pointer-events: none;
    transition: opacity .35s;
    transform: translateZ(calc((var(--az) - 3) * var(--s) * var(--p) + 9px));
}

.xv-beam::before {
    content: '';
    position: absolute;
    right: 0;
    left: 0;
    height: 16%;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .5), transparent);
    transform: translateY(-100%);
    animation: xv-beam 2.2s linear infinite;
}

.xv-phone[data-active] .xv-beam { opacity: 1; }

@keyframes xv-grip { to { background-position: 2px 100%, 0 100%, 0 0; } }
@keyframes xv-rust { 0%, 100% { opacity: .15; } 50% { opacity: .95; } }
@keyframes xv-beam { to { transform: translateY(640%); } }

/* callout column */
.xv-tags { position: absolute; inset: 0; z-index: 2; pointer-events: none; }

.xv-tag {
    --tx: 0px;
    --ty: 0px;
    --lw: 0px;
    --to: 0;
    position: absolute;
    top: 0;
    left: 0;
    padding-left: 10px;
    white-space: nowrap;
    opacity: var(--to);
    transform: translate(var(--tx), calc(var(--ty) - 50%));
    transition: opacity .3s, color .3s;
}

.xv-tag::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 100%;
    width: var(--lw);
    height: 1px;
    background: linear-gradient(90deg, rgba(255, 109, 12, 0), rgba(255, 109, 12, .85));
}

.xv-tag::after {
    content: '';
    position: absolute;
    top: 50%;
    right: calc(100% + var(--lw));
    width: 6px;
    height: 6px;
    margin: -3px -3px 0 0;
    border-radius: 50%;
    background: #ff6d0c;
    box-shadow: 0 0 8px rgba(255, 109, 12, .9);
}

.xv-tag b { display: block; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .78); transition: color .3s; }
.xv-tag em { display: block; font-size: 10px; font-style: normal; letter-spacing: .02em; color: rgba(255, 255, 255, .5); }
.xv-tag.is-active b { color: #ff6d0c; }
.xv-tag.is-active em { color: rgba(255, 255, 255, .85); }

@media (max-width: 1199.98px) { .xv-tag em { display: none; } }
@media (max-width: 991.98px) {
    .xv-tags { display: none; }
    .xv-phone { margin-left: 0; }
}

/* legend rows are links: the whole row is clickable, extra services sit on top of it */
.xv-legend li { position: relative; cursor: pointer; }
.xv-legend li:hover { opacity: 1; }
.xv-legend strong a { color: #fff; text-decoration: none; transition: color .25s; }
.xv-legend strong a::after { content: ''; position: absolute; inset: 0; z-index: 0; }
.xv-legend li:hover strong a { color: #ff6d0c; }
.xv-legend div > span.xv-meta { display: inline-block; margin: 3px 0 2px; padding: 1px 9px; border: 1px solid rgba(255, 109, 12, .6); border-radius: 99px; font-size: 11px; font-weight: 700; letter-spacing: .03em; color: #ff9147; }
.xv-links { position: relative; z-index: 1; display: flex !important; flex-wrap: wrap; gap: 2px 16px; margin-top: 2px; }
.xv-links a:hover { color: #ff9147; text-decoration: underline; }

/* landing on a service card from the home page */
.service-card { scroll-margin-top: 130px; }
.service-card:target { animation: svc-flash 2.6s ease-out; }
@keyframes svc-flash {
    0%, 35% { box-shadow: 0 0 0 3px #ff6d0c, 0 0 34px rgba(255, 109, 12, .55); }
    100% { box-shadow: 0 0 0 0 rgba(255, 109, 12, 0), 0 0 0 rgba(255, 109, 12, 0); }
}

@media (prefers-reduced-motion: reduce) {
    .xv-phone { transition: none; }
    .service-card:target { animation: none; box-shadow: 0 0 0 3px #ff6d0c; }
    .xv-driver, .xv-rust, .xv-beam::before { animation: none; }
}

/* ===========================================================================
   Mobile + touch round: the same animations on phones
   =========================================================================== */

/* Explode view pin. position:sticky is unreliable here (the theme sets overflow on body/html, which
   breaks it in Safari/iOS), so custom.js switches the pin between normal / fixed / bottom-docked. */
.xv-section.is-fixed .xv-pin { position: fixed; top: 0; right: 0; left: 0; z-index: 1; }
.xv-section.is-end .xv-pin { position: absolute; top: auto; right: 0; bottom: 0; left: 0; }

@media (max-width: 991.98px) {
    .xv-section { height: 240vh; }
    .xv-pin { height: 100vh; padding-top: 74px; }
    .xv-inner { height: 100%; }
    .xv-inner > .row { height: 100%; align-content: center; }
    .xv-inner .col-lg-6.mb-4 { margin-bottom: .4rem !important; }

    .xv-stage { height: 36vh; min-height: 230px; }
    .xv-phone { --w: min(118px, 32vw); --s: 25px; margin-left: 0; }
    .xv-hud { gap: .2rem; font-size: 9px; }
    .xv-hud-v { font-size: 18px; }
    .xv-hud-bar { width: 64px; }
    .xv-badge { font-size: 10px; }

    .xv-copy > p { display: none; }
    .xv-copy .top-sub-title { margin-bottom: 2px; font-size: 11px; }
    .xv-copy h2 { margin-bottom: .5rem !important; font-size: 1.3rem; }
    .xv-legend { margin-bottom: .7rem !important; }
    .xv-legend li { align-items: center; padding: 5px 0 5px 12px; }
    .xv-legend strong { margin: 0; font-size: 14px; }
    .xv-num { width: 22px; height: 22px; font-size: 11px; }
    /* one row open at a time: the one the scroll is currently on */
    .xv-legend li:not(.is-current) div > span { display: none !important; }
    .xv-legend li.is-current { border-left-color: #ff6d0c; opacity: 1; transform: none; }
    .xv-copy .btn { padding: .55rem 1.4rem; font-size: .8rem; }
}

@supports (height: 1svh) {
    @media (max-width: 991.98px) {
        .xv-section { height: 240svh; }
        .xv-pin { height: 100svh; }
        .xv-stage { height: 36svh; }
    }
}

/* short phones: drop the extras so the open row + phone still fit */
@media (max-width: 991.98px) and (max-height: 700px) {
    .xv-copy .top-sub-title, .xv-copy .btn { display: none; }
}

/* Touch devices have no hover, so cards sway with scroll position and dip when pressed */
@media (hover: none), (pointer: coarse) {
    [data-tilt] {
        position: relative;
        transform: perspective(900px) rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg)) scale(var(--ts, 1));
        transition: transform .14s linear;
    }

    [data-tilt]::after {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        pointer-events: none;
        opacity: var(--go, 0);
        background: radial-gradient(circle at var(--gx, 50%) var(--gy, 50%), rgba(255, 255, 255, .3), transparent 55%);
    }

    [data-tilt].is-pressed { --ts: .972; }
}

/* Reduced motion / no JS: the explode view is a plain, fully-expanded static block again */
@media (prefers-reduced-motion: reduce) {
    .xv-section { height: auto; padding: 70px 0; }
    .xv-pin { position: static; display: block; height: auto; padding-top: 0; }
    .xv-stage { height: 440px; }
    .xv-copy > p { display: block; }
    .xv-legend li:not(.is-current) div > span { display: block !important; }
    .xv-legend li:not(.is-current) div > span.xv-meta { display: inline-block !important; }
    .xv-legend li:not(.is-current) div > span.xv-links { display: flex !important; }
    [data-tilt] { transform: none !important; }
}

html:not(.js) .xv-section { height: auto; padding: 70px 0; }
html:not(.js) .xv-pin { position: static; display: block; height: auto; padding-top: 0; }
html:not(.js) .xv-stage { height: 440px; }
html:not(.js) .xv-copy > p { display: block; }
html:not(.js) .xv-legend li div > span { display: block !important; }
html:not(.js) .xv-legend li div > span.xv-meta { display: inline-block !important; }
html:not(.js) .xv-legend li div > span.xv-links { display: flex !important; }
