/* ==========================================================================
   FlutterGo Features showcase — premium glass bento + interactive demos
   ========================================================================== */

.fgx {
  position: relative;
  padding: 64px 0 56px;
  overflow: hidden;
  isolation: isolate;
}

.fgx__ambient {
  display: none;
}

.fgx__mesh {
  display: none;
}

.fgx__orb {
  display: none;
}

.fgx__orb--a {
  width: 420px;
  height: 420px;
  top: 8%;
  left: -8%;
  background: rgba(10, 108, 255, 0.28);
  animation: fgx-orb-a 22s ease-in-out infinite alternate;
}

.fgx__orb--b {
  width: 360px;
  height: 360px;
  right: -6%;
  bottom: 12%;
  background: rgba(124, 92, 255, 0.22);
  animation: fgx-orb-b 26s ease-in-out infinite alternate;
}

@keyframes fgx-mesh-drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(1.5%, -1.2%, 0) scale(1.03); }
}

@keyframes fgx-orb-a {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(40px, 28px, 0); }
}

@keyframes fgx-orb-b {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-32px, -24px, 0); }
}

.fgx > .fgs-container {
  position: relative;
  z-index: 1;
}

.fgx__head {
  max-width: 640px;
  margin: 0 auto 56px;
  text-align: center;
}

.fgx__title {
  margin: 14px 0 16px;
  font-size: clamp(32px, 4.2vw, 48px);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.12;
  color: var(--text-strong, #f4f7fb);
}

.fgx__lead {
  margin: 0 auto;
  max-width: 52ch;
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-muted, rgba(244, 247, 251, 0.62));
}

/* ---- Grid rhythm ------------------------------------------------------- */

.fgx__grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 20px;
  align-items: stretch;
}

.fgx-card--lg { grid-column: span 3; }
.fgx-card { grid-column: span 2; }
.fgx-card--wide { grid-column: span 6; }

/* ---- Glass card -------------------------------------------------------- */

.fgx-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: 24px;
  padding: 0;
  overflow: hidden;
  background: #0a101b;
  border: 1px solid rgba(13, 12, 10, 0.1);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 14px 36px -22px rgba(13, 12, 10, 0.18);
  transform: translate3d(0, 0, 0) scale(1);
  transform-style: preserve-3d;
  will-change: transform, box-shadow;
  transition:
    transform 520ms cubic-bezier(0.23, 1, 0.32, 1),
    box-shadow 520ms cubic-bezier(0.23, 1, 0.32, 1);
}

.fgx-card.is-lifted,
.fgx-card:hover {
  transform: translate3d(0, -6px, 0) scale(1.01);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 22px 48px -24px rgba(13, 12, 10, 0.22);
}

/* Soft edge highlight — no blue rainbow border */
.fgx-card__border {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.5),
    rgba(13, 12, 10, 0.06),
    rgba(255, 255, 255, 0.2)
  );
  background-size: 100% 100%;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.35;
  animation: none;
  transition: opacity 420ms cubic-bezier(0.23, 1, 0.32, 1);
}

.fgx-card:hover .fgx-card__border,
.fgx-card.is-lifted .fgx-card__border {
  opacity: 1;
  animation-duration: 4.5s;
}

@keyframes fgx-border-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Soft sheen / reflection */
.fgx-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    115deg,
    transparent 30%,
    rgba(255, 255, 255, 0.07) 48%,
    transparent 62%
  );
  background-size: 220% 100%;
  background-position: 120% 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 400ms ease, background-position 900ms cubic-bezier(0.23, 1, 0.32, 1);
  z-index: 2;
}

.fgx-card:hover::after,
.fgx-card.is-lifted::after {
  opacity: 1;
  background-position: -40% 0;
}

.fgx-card__viz {
  position: relative;
  z-index: 1;
  min-height: 220px;
  padding: 28px 28px 8px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 18px;
  background: #0d1524;
  overflow: hidden;
}

/* Site sets `svg { max-width: 100% }` — that explodes demo icons into black blobs. */
.fgx-card__viz svg {
  max-width: none !important;
  max-height: none !important;
  flex-shrink: 0;
}

.fgx-card__viz--compact {
  min-height: 176px;
  padding-bottom: 8px;
  align-items: center;
}

.fgx-card__body {
  position: relative;
  z-index: 1;
  padding: 8px 28px 28px;
}

.fgx-card--wide .fgx-card__body {
  padding: 0;
}

.fgx-card__icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  color: #7eb6ff;
  background: color-mix(in srgb, #0a6cff 16%, transparent);
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, #0a6cff 28%, transparent),
    0 0 20px rgba(10, 108, 255, 0.18);
  animation: fgx-icon-pulse 3.6s ease-in-out infinite;
}

.fgx-card__icon--sky {
  color: #8fd4ff;
  background: color-mix(in srgb, #38bdf8 14%, transparent);
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, #38bdf8 28%, transparent),
    0 0 20px rgba(56, 189, 248, 0.16);
}

.fgx-card__icon--mint {
  color: #6ee7c5;
  background: color-mix(in srgb, #00c2a8 14%, transparent);
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, #00c2a8 28%, transparent),
    0 0 20px rgba(0, 194, 168, 0.16);
}

.fgx-card__icon svg {
  width: 20px;
  height: 20px;
}

@keyframes fgx-icon-pulse {
  0%, 100% { box-shadow: inset 0 0 0 1px color-mix(in srgb, #0a6cff 28%, transparent), 0 0 14px rgba(10, 108, 255, 0.12); }
  50% { box-shadow: inset 0 0 0 1px color-mix(in srgb, #0a6cff 40%, transparent), 0 0 26px rgba(10, 108, 255, 0.32); }
}

.fgx-card h3 {
  margin: 0 0 10px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-strong, #e9eef9);
}

.fgx-card p {
  margin: 0;
  font-size: 15px;
  line-height: 1.62;
  color: var(--text-muted, #94a0b6);
}

.fgx-card code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  color: #9ec5ff;
  background: rgba(10, 108, 255, 0.12);
  padding: 0.1em 0.35em;
  border-radius: 5px;
}

/* ---- Wide deploy layout ------------------------------------------------ */

.fgx-card__wide {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 28px;
  align-items: center;
  padding: 32px 36px;
}

.fgx-ticks {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.fgx-ticks li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-muted, #94a0b6);
}

.fgx-ticks li::before {
  content: "";
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  border-radius: 50%;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230a6cff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E")
    center / 10px no-repeat,
    color-mix(in srgb, #0a6cff 12%, #0a101b);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, #0a6cff 22%, transparent);
}

/* ---- Demo: brand phone + theme tokens ---------------------------------- */

.fgx-card__viz--brand {
  min-height: 260px;
  align-items: center;
  padding: 28px 24px 20px;
}

.fgx-brand {
  --accent: #5bc8ff;
  --accent-soft: #e8f1ff;
  display: flex;
  align-items: center;
  gap: 20px;
  width: 100%;
  max-width: 340px;
  animation: fgx-theme-cycle 8s ease-in-out infinite;
}

@keyframes fgx-theme-cycle {
  0%, 20% { --accent: #5bc8ff; --accent-soft: #e8f1ff; }
  25%, 45% { --accent: #9d8cff; --accent-soft: #f0ecff; }
  50%, 70% { --accent: #00c2a8; --accent-soft: #e6faf6; }
  75%, 100% { --accent: #ff6b4a; --accent-soft: #fff0ec; }
}

.fgx-brand__phone {
  flex: 0 0 auto;
  transform: rotate(-6deg);
  filter: drop-shadow(0 22px 28px rgba(13, 12, 10, 0.18));
}

.fgx-brand__bezel {
  width: 148px;
  height: 252px;
  border-radius: 28px;
  padding: 11px 10px 10px;
  background: #0a101b;
  border: 1.5px solid rgba(13, 12, 10, 0.1);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 0 0 5px #eceae4;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: hidden;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
}

.fgx-brand__island {
  width: 48px;
  height: 12px;
  margin: 0 auto;
  border-radius: 99px;
  background: #d4d1c9;
}

.fgx-brand__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.fgx-brand__bar em {
  display: block;
  font-style: normal;
  font-size: 8px;
  color: #77839b;
}

.fgx-brand__bar b {
  display: block;
  font-size: 13px;
  font-weight: 750;
  letter-spacing: -0.02em;
  color: #e9eef9;
}

.fgx-brand__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 8px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(145deg, var(--accent), color-mix(in srgb, var(--accent) 50%, #0a101b));
  box-shadow: 0 6px 12px -6px color-mix(in srgb, var(--accent) 55%, transparent);
}

.fgx-brand__card {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 8px;
  align-items: center;
  padding: 9px;
  border-radius: 14px;
  background: linear-gradient(145deg, var(--accent-soft), #0a101b 72%);
  border: 1px solid color-mix(in srgb, var(--accent) 18%, transparent);
}

.fgx-brand__ring {
  position: relative;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    conic-gradient(from -90deg, var(--accent) 0 78%, color-mix(in srgb, var(--accent) 16%, #0a101b) 78% 100%);
}

.fgx-brand__ring::before {
  content: '';
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  background: #0a101b;
}

.fgx-brand__ring span {
  position: relative;
  z-index: 1;
  font-size: 9px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.03em;
}

.fgx-brand__card em {
  display: block;
  font-style: normal;
  font-size: 8px;
  font-weight: 650;
  color: #77839b;
}

.fgx-brand__card strong {
  display: block;
  margin-top: 2px;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #e9eef9;
  line-height: 1.1;
}

.fgx-brand__card strong small {
  font-size: 8px;
  font-weight: 600;
  color: #77839b;
}

.fgx-brand__meter {
  margin-top: 7px;
  height: 4px;
  border-radius: 99px;
  background: color-mix(in srgb, var(--accent) 14%, #0a101b);
  overflow: hidden;
}

.fgx-brand__meter i {
  display: block;
  height: 100%;
  width: 72%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--accent) 50%, #0a101b));
  animation: fgx-meter 8s ease-in-out infinite;
}

@keyframes fgx-meter {
  0%, 20% { width: 72%; }
  25%, 45% { width: 58%; }
  50%, 70% { width: 84%; }
  75%, 100% { width: 66%; }
}

.fgx-brand__metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
}

.fgx-brand__metrics div {
  padding: 7px 4px;
  border-radius: 10px;
  background: #0a101b;
  border: 1px solid rgba(13, 12, 10, 0.06);
  text-align: center;
}

.fgx-brand__metrics b {
  display: block;
  font-size: 12px;
  font-weight: 800;
  color: #e9eef9;
  letter-spacing: -0.02em;
}

.fgx-brand__metrics span {
  font-size: 7px;
  font-weight: 650;
  color: #77839b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.fgx-brand__dock {
  margin-top: auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  padding-top: 6px;
  border-top: 1px solid rgba(13, 12, 10, 0.06);
}

.fgx-brand__dock i {
  height: 4px;
  width: 16px;
  margin: 6px auto;
  border-radius: 99px;
  background: #d4d1c9;
}

.fgx-brand__dock i.on {
  background: var(--accent);
}

.fgx-brand__tokens {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.fgx-brand__token {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border-radius: 14px;
  background: #0a101b;
  border: 1px solid #e6e4df;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 10px 18px -14px rgba(13, 12, 10, 0.25);
  transform: rotateX(6deg) rotateY(-10deg);
  animation: fgx-token-pop 8s ease-in-out infinite;
}

.fgx-brand__token:nth-child(1) { animation-delay: 0s; }
.fgx-brand__token:nth-child(2) { animation-delay: 2s; }
.fgx-brand__token:nth-child(3) { animation-delay: 4s; }
.fgx-brand__token:nth-child(4) { animation-delay: 6s; }

.fgx-brand__token span {
  width: 22px;
  height: 22px;
  border-radius: 8px;
  background: var(--c);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.35) inset,
    0 6px 10px -4px color-mix(in srgb, var(--c) 55%, transparent);
  flex-shrink: 0;
}

.fgx-brand__token em {
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
  color: #e9eef9;
  letter-spacing: -0.01em;
}

@keyframes fgx-token-pop {
  0%, 18%, 100% { transform: rotateX(6deg) rotateY(-10deg) scale(1); border-color: #e6e4df; }
  8%, 12% {
    transform: rotateX(2deg) rotateY(-4deg) scale(1.04) translateX(3px);
    border-color: color-mix(in srgb, var(--c) 40%, #e6e4df);
  }
}

/* ---- Demo: light IDE + run terminal ------------------------------------ */

.fgx-card__viz--code {
  min-height: 250px;
  align-items: center;
  padding: 24px;
}

.fgx-codeviz {
  position: relative;
  width: 100%;
  max-width: 420px;
}

.fgx-codeviz__badge {
  position: absolute;
  right: -4px;
  top: -8px;
  z-index: 3;
  padding: 7px 12px;
  border-radius: 999px;
  background: #0a101b;
  border: 1px solid rgba(10, 108, 255, 0.2);
  color: #5bc8ff;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 12px 22px -14px rgba(10, 108, 255, 0.4);
  transform: rotate(2deg);
}

.fgx-ide,
.fgx-ide--light {
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  background: #0a101b !important;
  border: 1px solid #e6e4df;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 18px 40px -18px rgba(13, 12, 10, 0.22);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  line-height: 1.55;
}

.fgx-ide__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  background: #0d1524;
  border-bottom: 1px solid #e6e4df;
}

.fgx-ide:not(.fgx-ide--light) .fgx-ide__bar {
  background: rgba(255, 255, 255, 0.03);
  border-bottom-color: rgba(255, 255, 255, 0.06);
}

.fgx-ide__bar i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d4d1c9;
}

.fgx-ide__bar i:nth-child(1) { background: #ff5f57; }
.fgx-ide__bar i:nth-child(2) { background: #febc2e; }
.fgx-ide__bar i:nth-child(3) { background: #28c840; }

.fgx-ide__bar span {
  margin-left: 8px;
  color: #77839b;
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fgx-ide__body {
  display: grid;
  grid-template-columns: 78px 1fr;
  min-height: 150px;
}

.fgx-ide__tree {
  padding: 10px 8px;
  border-right: 1px solid #eef0f3;
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #77839b;
  font-size: 10px;
  font-weight: 600;
}

.fgx-ide__tree .is-on {
  color: #5bc8ff;
  background: rgba(91, 200, 255, 0.1);
  border-radius: 5px;
  padding: 3px 5px;
  margin: 0 -2px;
}

.fgx-ide__code {
  margin: 0;
  padding: 10px 12px;
  overflow: hidden;
  color: #c2cde1;
  white-space: pre;
}

.fgx-ide__code .k { color: #9d8cff; }
.fgx-ide__code .t { color: #5bc8ff; }

.fgx-ide:not(.fgx-ide--light) .fgx-ide__code { color: rgba(230, 237, 245, 0.82); }
.fgx-ide:not(.fgx-ide--light) .fgx-ide__code .k { color: #c792ea; }
.fgx-ide:not(.fgx-ide--light) .fgx-ide__code .t { color: #82aaff; }
.fgx-ide:not(.fgx-ide--light) .fgx-ide__tree { color: rgba(255, 255, 255, 0.35); border-right-color: rgba(255, 255, 255, 0.05); }
.fgx-ide:not(.fgx-ide--light) .fgx-ide__tree .is-on { color: #9ec5ff; background: rgba(10, 108, 255, 0.14); }
.fgx-ide:not(.fgx-ide--light) .fgx-ide__bar span { color: rgba(255, 255, 255, 0.45); }

.fgx-caret {
  display: inline-block;
  width: 6px;
  height: 12px;
  margin-left: 1px;
  vertical-align: -1px;
  background: #0a6cff;
  animation: fgx-caret-blink 1.05s steps(1) infinite;
}

@keyframes fgx-caret-blink {
  0%, 45% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

.fgx-ide__code code {
  display: inline-block;
  animation: fgx-type-reveal 6s steps(48, end) infinite;
  max-width: 100%;
  overflow: hidden;
  background: none;
  padding: 0;
  color: inherit;
}

@keyframes fgx-type-reveal {
  0% { clip-path: inset(0 100% 0 0); }
  45%, 85% { clip-path: inset(0 0 0 0); }
  100% { clip-path: inset(0 100% 0 0); }
}

.fgx-ide__term {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  background: rgba(91, 200, 255, 0.1);
  color: #e9eef9;
  font-size: 11px;
  border-top: 1px solid rgba(10, 108, 255, 0.14);
}

.fgx-ide__prompt {
  color: #5bc8ff;
  font-weight: 700;
}

.fgx-ide__term b {
  margin-left: auto;
  color: #059669;
  font-weight: 750;
}

/* ---- Demo: backend stack ----------------------------------------------- */

.fgx-card__viz--stack {
  min-height: 200px;
  padding: 22px 20px;
}

.fgx-stack {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
}

.fgx-stack__phone {
  flex: 0 0 88px;
  width: 88px;
  height: 160px;
  border-radius: 18px;
  padding: 8px 7px;
  background: #0a101b;
  border: 1.5px solid rgba(13, 12, 10, 0.1);
  box-shadow:
    0 0 0 3px #eceae4,
    0 16px 28px -14px rgba(13, 12, 10, 0.28);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fgx-stack__island {
  width: 28px;
  height: 8px;
  margin: 0 auto;
  border-radius: 99px;
  background: #d4d1c9;
}

.fgx-stack__screen {
  flex: 1;
  border-radius: 12px;
  padding: 10px 8px;
  background: linear-gradient(160deg, rgba(91, 200, 255, 0.1), #0a101b 70%);
  border: 1px solid rgba(10, 108, 255, 0.14);
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.fgx-stack__screen b {
  font-size: 10px;
  font-weight: 750;
  color: #e9eef9;
}

.fgx-stack__screen em {
  font-style: normal;
  font-size: 7.5px;
  color: #77839b;
}

.fgx-stack__bars {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.fgx-stack__bars i {
  height: 6px;
  border-radius: 99px;
  background: rgba(10, 108, 255, 0.14);
}

.fgx-stack__bars i:nth-child(1) { width: 100%; background: #0a6cff; }
.fgx-stack__bars i:nth-child(2) { width: 78%; }
.fgx-stack__bars i:nth-child(3) { width: 58%; }

.fgx-stack__services {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.fgx-stack__svc {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 14px;
  background: #0a101b;
  border: 1px solid #e6e4df;
  box-shadow: 0 10px 18px -14px rgba(13, 12, 10, 0.22);
  animation: fgx-svc-in 3.6s cubic-bezier(0.23, 1, 0.32, 1) infinite;
}

.fgx-stack__svc:nth-child(2) { animation-delay: 0.25s; }
.fgx-stack__svc:nth-child(3) { animation-delay: 0.5s; }

@keyframes fgx-svc-in {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(3px); }
}

.fgx-stack__ico {
  width: 34px;
  height: 34px;
  min-width: 34px;
  min-height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(145deg, #3b9bff, #0a6cff);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.28) inset,
    0 6px 0 -1px #7eb6ff,
    0 8px 0 0 #0553c7;
}

.fgx-stack__svc--auth .fgx-stack__ico {
  color: #34d399;
  background: linear-gradient(145deg, rgba(52, 211, 153, 0.1), #6ee7b7);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.7) inset,
    0 6px 0 -1px #6ee7b7,
    0 8px 0 0 #10b981;
}

.fgx-stack__svc--db .fgx-stack__ico {
  color: #fff;
  background: linear-gradient(145deg, #3b9bff, #0a6cff);
}

.fgx-stack__svc--files .fgx-stack__ico {
  color: #ff9a5c;
  background: linear-gradient(145deg, rgba(255, 90, 90, 0.1), #fdba74);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.7) inset,
    0 6px 0 -1px #fdba74,
    0 8px 0 0 #ea580c;
}

.fgx-stack__ico svg {
  width: 16px !important;
  height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
  display: block;
  fill: none;
}

.fgx-stack__svc strong {
  display: block;
  font-size: 12px;
  font-weight: 750;
  color: #e9eef9;
  letter-spacing: -0.01em;
}

.fgx-stack__svc em {
  display: block;
  font-style: normal;
  font-size: 10px;
  color: #77839b;
  margin-top: 1px;
}

/* ---- Demo: live preview + auto-repair (light) -------------------------- */

.fgx-card__viz--live {
  min-height: 200px;
  padding: 22px 18px;
}

.fgx-live {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
}

.fgx-live__phone {
  position: relative;
  flex: 0 0 96px;
  width: 96px;
  height: 168px;
  border-radius: 20px;
  padding: 9px 8px 8px;
  background: #0a101b;
  border: 1.5px solid rgba(13, 12, 10, 0.1);
  box-shadow:
    0 0 0 4px #eceae4,
    0 18px 32px -16px rgba(13, 12, 10, 0.28);
  overflow: hidden;
}

.fgx-live__island {
  width: 34px;
  height: 9px;
  margin: 0 auto 6px;
  border-radius: 99px;
  background: #d4d1c9;
}

.fgx-live__broken,
.fgx-live__app {
  position: absolute;
  left: 8px;
  right: 8px;
  top: 28px;
  bottom: 8px;
  border-radius: 12px;
}

.fgx-live__broken {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #0d1524;
  border: 1px solid rgba(225, 29, 72, 0.22);
  animation: fgx-broken-out 5.5s ease-in-out infinite;
  z-index: 2;
}

.fgx-live__broken span {
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  color: #fff;
  background: #e11d48;
  box-shadow: 0 8px 16px -8px rgba(225, 29, 72, 0.55);
}

.fgx-live__broken em {
  font-style: normal;
  font-size: 9px;
  font-weight: 700;
  color: #ff7a92;
}

.fgx-live__app {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px;
  background: linear-gradient(160deg, rgba(91, 200, 255, 0.1), #0a101b 70%);
  border: 1px solid rgba(10, 108, 255, 0.14);
  animation: fgx-app-in 5.5s ease-in-out infinite;
  z-index: 1;
}

.fgx-live__hdr {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.fgx-live__hdr b {
  width: 38px;
  height: 6px;
  border-radius: 3px;
  background: #0a6cff;
}

.fgx-live__hdr i {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(145deg, #3b9bff, #0a6cff);
}

.fgx-live__hero {
  flex: 1;
  min-height: 36px;
  border-radius: 9px;
  background: linear-gradient(145deg, #0a6cff, #44d1fd);
  box-shadow: 0 8px 14px -10px rgba(10, 108, 255, 0.55);
}

.fgx-live__rows {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.fgx-live__rows span {
  height: 20px;
  border-radius: 6px;
  background: #0a101b;
  border: 1px solid rgba(13, 12, 10, 0.06);
}

.fgx-live__dock {
  display: flex;
  justify-content: space-around;
  padding-top: 2px;
}

.fgx-live__dock i {
  width: 14px;
  height: 3px;
  border-radius: 99px;
  background: #d4d1c9;
}

.fgx-live__dock i.on {
  background: #0a6cff;
}

@keyframes fgx-broken-out {
  0%, 38% { opacity: 1; transform: scale(1); }
  48%, 100% { opacity: 0; transform: scale(0.94); pointer-events: none; }
}

@keyframes fgx-app-in {
  0%, 40% { opacity: 0; transform: scale(0.96); }
  52%, 100% { opacity: 1; transform: scale(1); }
}

.fgx-live__panel {
  flex: 1;
  min-width: 0;
  border-radius: 16px;
  padding: 10px;
  background: #0a101b;
  border: 1px solid #e6e4df;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 16px 28px -16px rgba(13, 12, 10, 0.22);
}

.fgx-live__tab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 8px;
  font-size: 10px;
  font-weight: 750;
  color: #5bc8ff;
}

.fgx-live__tab svg {
  width: 12px !important;
  height: 12px !important;
  max-width: 12px !important;
  max-height: 12px !important;
  fill: none;
}

.fgx-live__log {
  font-size: 10px;
  font-weight: 650;
  padding: 7px 8px;
  border-radius: 9px;
  margin-bottom: 6px;
  line-height: 1.3;
}

.fgx-live__log.is-err {
  color: #ff7a92;
  background: rgba(255, 90, 90, 0.1);
  border: 1px solid rgba(225, 29, 72, 0.18);
  animation: fgx-err-cycle 5.5s ease-in-out infinite;
}

.fgx-live__log.is-ok {
  color: #34d399;
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.22);
  animation: fgx-ok-cycle 5.5s ease-in-out infinite;
}

.fgx-live__diff {
  display: grid;
  gap: 4px;
  margin-top: 2px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.fgx-live__diff span {
  display: block;
  font-size: 9px;
  font-weight: 650;
  padding: 5px 7px;
  border-radius: 7px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fgx-live__diff .del {
  color: #ff7a92;
  background: rgba(255, 90, 90, 0.1);
  animation: fgx-err-cycle 5.5s ease-in-out infinite;
}

.fgx-live__diff .add {
  color: #34d399;
  background: rgba(52, 211, 153, 0.1);
  animation: fgx-ok-cycle 5.5s ease-in-out infinite;
}

@keyframes fgx-err-cycle {
  0%, 36% { opacity: 1; }
  46%, 100% { opacity: 0.28; }
}

@keyframes fgx-ok-cycle {
  0%, 40% { opacity: 0.25; }
  52%, 100% { opacity: 1; }
}

/* ---- Demo: icons / splash / store assets ------------------------------- */

.fgx-card__viz--assets {
  min-height: 200px;
  padding: 22px 18px;
}

.fgx-assets {
  width: 100%;
  max-width: 280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.fgx-assets__icons {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 12px;
  perspective: 600px;
}

.fgx-assets__icon {
  width: 52px;
  height: 52px;
  min-width: 52px;
  min-height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: #fff;
  transform: rotateX(12deg) rotateY(-12deg);
  animation: fgx-asset-float 4.5s cubic-bezier(0.23, 1, 0.32, 1) infinite;
}

.fgx-assets__icon svg {
  width: 28px !important;
  height: 28px !important;
  max-width: 28px !important;
  max-height: 28px !important;
  display: block;
  fill: none;
}

.fgx-assets__icon--fit {
  background: linear-gradient(145deg, #3b9bff, #0a6cff);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3) inset,
    0 8px 0 -1px #7eb6ff,
    0 10px 0 0 #0553c7,
    0 18px 22px -12px rgba(10, 108, 255, 0.45);
  animation-delay: 0s;
}

.fgx-assets__icon--pay {
  width: 60px;
  height: 60px;
  border-radius: 18px;
  background: linear-gradient(145deg, #34d399, #059669);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3) inset,
    0 8px 0 -1px #6ee7b7,
    0 10px 0 0 #047857,
    0 18px 22px -12px rgba(5, 150, 105, 0.45);
  animation-delay: 0.35s;
  z-index: 2;
}

.fgx-assets__icon--food {
  background: linear-gradient(145deg, #fb923c, #ea580c);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3) inset,
    0 8px 0 -1px #fdba74,
    0 10px 0 0 #c2410c,
    0 18px 22px -12px rgba(234, 88, 12, 0.45);
  animation-delay: 0.7s;
}

.fgx-assets__row {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: center;
}

.fgx-assets__splash {
  width: 108px;
  height: 72px;
  border-radius: 16px;
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: linear-gradient(160deg, rgba(91, 200, 255, 0.1) 0%, #0a101b 70%);
  border: 1px solid rgba(10, 108, 255, 0.16);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 14px 24px -16px rgba(10, 108, 255, 0.3);
}

.fgx-assets__logo {
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: linear-gradient(145deg, #3b9bff, #0a6cff);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3) inset,
    0 6px 10px -4px rgba(10, 108, 255, 0.5);
}

.fgx-assets__splash strong {
  font-size: 11px;
  font-weight: 750;
  color: #e9eef9;
  letter-spacing: -0.01em;
}

.fgx-assets__splash i {
  width: 28px;
  height: 3px;
  border-radius: 99px;
  background: rgba(10, 108, 255, 0.2);
}

.fgx-assets__labels {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fgx-assets__labels span {
  font-size: 11px;
  font-weight: 700;
  color: #5bc8ff;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(91, 200, 255, 0.1);
  border: 1px solid rgba(10, 108, 255, 0.14);
  white-space: nowrap;
}

@keyframes fgx-asset-float {
  0%, 100% { transform: rotateX(12deg) rotateY(-12deg) translateY(0); }
  50% { transform: rotateX(6deg) rotateY(-6deg) translateY(-5px); }
}

/* ---- Demo: pipeline ---------------------------------------------------- */

.fgx-pipeline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  padding: 18px 8px;
}

.fgx-pipeline__step {
  flex: 0 0 auto;
  min-width: 64px;
  padding: 12px 10px;
  border-radius: 14px;
  text-align: center;
  font-size: 11px;
  font-weight: 650;
  color: #94a0b6;
  background: #0d1524;
  border: 1px solid rgba(13, 12, 10, 0.1);
  position: relative;
}

.fgx-pipeline__step span { position: relative; z-index: 1; }

.fgx-pipeline__step.is-done {
  color: #0c8a4d;
  border-color: color-mix(in srgb, #0c8a4d 28%, transparent);
  background: color-mix(in srgb, #0c8a4d 10%, #0a101b);
}

.fgx-pipeline__step.is-active {
  color: #5bc8ff;
  border-color: color-mix(in srgb, #0a6cff 35%, transparent);
  background: color-mix(in srgb, #0a6cff 10%, #0a101b);
  box-shadow: 0 0 0 1px color-mix(in srgb, #0a6cff 12%, transparent);
  animation: none;
}

.fgx-pipeline__beam {
  flex: 1;
  height: 2px;
  min-width: 18px;
  border-radius: 99px;
  background: rgba(13, 12, 10, 0.1);
  position: relative;
  overflow: hidden;
}

.fgx-pipeline__beam::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, #7eb6ff, transparent);
  transform: translateX(-100%);
  animation: fgx-beam 2.2s ease-in-out infinite;
}

.fgx-pipeline__beam:nth-of-type(2)::after { animation-delay: 0.2s; }
.fgx-pipeline__beam:nth-of-type(4)::after { animation-delay: 0.45s; }
.fgx-pipeline__beam:nth-of-type(6)::after { animation-delay: 0.7s; }

@keyframes fgx-beam {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* ---- Responsive -------------------------------------------------------- */

@media (max-width: 980px) {
  .fgx__grid { grid-template-columns: repeat(2, 1fr); }
  .fgx-card,
  .fgx-card--lg { grid-column: span 1; }
  .fgx-card--wide { grid-column: span 2; }
  .fgx-card__wide {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 640px) {
  .fgx { padding: 48px 0 40px; }
  .fgx__grid { grid-template-columns: 1fr; gap: 14px; }
  .fgx-card,
  .fgx-card--lg,
  .fgx-card--wide { grid-column: span 1; }
  .fgx-card__viz { min-height: 180px; }
  .fgx-brand { gap: 14px; }
  .fgx-brand__bezel { width: 132px; height: 230px; }
  .fgx-brand__token em { font-size: 11px; }
  .fgx-codeviz__badge { right: 8px; top: 4px; }
  .fgx-pipeline {
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
  }
  .fgx-pipeline__beam { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .fgx__mesh,
  .fgx__orb,
  .fgx-card__border,
  .fgx-card__icon,
  .fgx-brand,
  .fgx-brand__meter i,
  .fgx-brand__token,
  .fgx-stack__svc,
  .fgx-caret,
  .fgx-ide__code code,
  .fgx-live__broken,
  .fgx-live__app,
  .fgx-live__log,
  .fgx-live__diff span,
  .fgx-assets__icon,
  .fgx-pipeline__step.is-active,
  .fgx-pipeline__beam::after {
    animation: none !important;
  }

  .fgx-card,
  .fgx-card:hover,
  .fgx-card.is-lifted {
    transition: none;
    transform: none;
  }

  .fgx-live__broken { opacity: 0; }
  .fgx-live__app { opacity: 1; }
  .fgx-live__log.is-err,
  .fgx-live__diff .del { opacity: 0.25; }
  .fgx-live__log.is-ok,
  .fgx-live__diff .add { opacity: 1; }
}
