/* The upgrade to suite button with the floor rising like a lift. One pill of deep ink lacquer (.up__body, moved only
   by GSAP) on pure white: a dark base, a soft light under the pointer, a fine grain and a 1px edge; on the left the
   small amber display of a lift with its floor number and two chevrons, then the words, then a plus that becomes a
   tick. The thin line of light (.up__door-line) is the lift doors opening on arrival. */
:root {
  --page: #ffffff;             /* the page */
  --lacquer: #151821;          /* the body of the button */
  --lacquer-hi: #262b38;       /* the top of the lacquer, where it catches the light */
  --ink: #f5f2ec;              /* the words */
  --muted: rgba(245, 242, 236, 0.58); /* the small words */
  --amber: #ffb25e;            /* the light of the lift display */
  --lcd: #0b0c10;              /* the glass of the display */
  --focus: #151821;            /* the keyboard focus ring */
}

* {
  box-sizing: border-box;
}

html {
  touch-action: manipulation;
}

html,
body {
  margin: 0;
  overflow-x: clip;
}

body {
  min-height: 100svh;
  background: var(--page);
  color: var(--ink);
  font-family: 'Mona Sans Variable', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.stage {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 24px 0;
}

.up {
  position: relative;
  width: min(86vw, 318px);
  height: 60px;
}

/* the soft shadow on the floor, it tightens when pressed and warms on arrival */
.up__floor {
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: -14px;
  height: 26px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(21, 24, 33, 0.28), rgba(21, 24, 33, 0));
  filter: blur(6px);
  pointer-events: none;
}

.up__btn {
  all: unset;
  position: relative;
  display: block;
  width: 100%;
  height: 60px;
  border-radius: 30px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.up__btn:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 4px;
}

.up__body {
  position: absolute;
  inset: 0;
  border-radius: 30px;
  overflow: hidden;
  isolation: isolate;
  box-shadow:
    0 1px 1px rgba(21, 24, 33, 0.16),
    0 6px 14px -6px rgba(21, 24, 33, 0.34),
    0 20px 34px -18px rgba(21, 24, 33, 0.42);
}

.up__base {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--lacquer-hi) 0%, var(--lacquer) 54%, #10121a 100%);
}

/* the light under the pointer */
.up__shine {
  --mx: 30%;
  --my: 0%;
  position: absolute;
  inset: 0;
  opacity: 0;
  background: radial-gradient(160px 90px at var(--mx) var(--my), rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0) 70%);
}

/* the grain and the 1px edge: light on top, a hair of amber at the bottom */
.up__grain {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.1' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.06 0'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 -1px 0 rgba(255, 178, 94, 0.08);
  pointer-events: none;
}

/* the lift doors: a thin bright line that opens into a wide warm band and fades */
.up__doors {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.up__door-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100%;
  margin-left: -50%;
  transform: scaleX(0);
  opacity: 0;
  background: linear-gradient(90deg, rgba(255, 178, 94, 0) 0%, rgba(255, 178, 94, 0.22) 30%, rgba(255, 226, 186, 0.38) 50%, rgba(255, 178, 94, 0.22) 70%, rgba(255, 178, 94, 0) 100%);
  mix-blend-mode: screen;
}

.up__row {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 14px 0 10px;
  gap: 13px;
}

/* the lift display: a small rounded window of dark glass with the amber floor number */
.up__display {
  position: relative;
  flex: none;
  width: 52px;
  height: 40px;
  border-radius: 20px;
  background: var(--lcd);
  box-shadow:
    inset 0 1px 2px rgba(0, 0, 0, 0.7),
    inset 0 0 0 1px rgba(255, 255, 255, 0.04),
    0 1px 0 rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  padding-left: 7px;
  overflow: hidden;
}

.up__lcd {
  position: relative;
  width: 25px;
  height: 22px;
  overflow: hidden;
  mask-image: linear-gradient(180deg, transparent 0, #000 22%, #000 78%, transparent 100%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 22%, #000 78%, transparent 100%);
}

.up__strip {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  display: flex;
  flex-direction: column;
}

.up__strip span {
  display: block;
  height: 22px;
  line-height: 22px;
  text-align: center;
  font-size: 17px;
  font-weight: 640;
  font-variation-settings: 'wdth' 88;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  color: var(--amber);
  text-shadow: 0 0 6px rgba(255, 178, 94, 0.55);
}

.up__chev {
  position: relative;
  width: 12px;
  height: 22px;
  margin-left: 1px;
  overflow: hidden;
}

.up__chev svg {
  position: absolute;
  left: 0;
  top: 7px;
  width: 12px;
  height: 8px;
  overflow: visible;
}

.up__chev path {
  fill: none;
  stroke: var(--amber);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 2px rgba(255, 178, 94, 0.6));
}

/* the warm haze of the display, it grows while the lift runs */
.up__haze {
  position: absolute;
  inset: 0;
  opacity: 0.25;
  background: radial-gradient(80% 70% at 35% 110%, rgba(255, 178, 94, 0.45), rgba(255, 178, 94, 0) 70%);
  pointer-events: none;
}

/* the reflection on the glass of the display */
.up__glass {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 42%);
  pointer-events: none;
}

.up__words {
  position: relative;
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 1px;
}

.up__stack {
  display: grid;
  overflow: hidden;
}

.up__label,
.up__sub {
  grid-area: 1 / 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.up__label {
  font-size: 15.5px;
  line-height: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  font-variation-settings: 'wdth' 100;
}

.up__sub {
  font-size: 11.5px;
  line-height: 15px;
  font-weight: 460;
  color: var(--muted);
}

.up__price {
  color: var(--amber);
  font-weight: 560;
}

.up__end {
  flex: none;
  width: 26px;
  height: 26px;
}

.up__end svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.up__end-ring {
  fill: rgba(255, 255, 255, 0.04);
  stroke: rgba(255, 255, 255, 0.18);
  stroke-width: 1;
}

.up__end-plus,
.up__end-tick {
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.up__end-tick {
  stroke: var(--amber);
}

@media (max-width: 360px) {
  .up__sub {
    font-size: 11px;
  }
}
