:root {
  color-scheme: dark;
  --pp-bg: #04070c;
  --pp-bg-soft: #0b1220;
  --pp-panel: rgba(8, 14, 24, 0.78);
  --pp-panel-strong: rgba(10, 18, 31, 0.94);
  --pp-line: rgba(166, 210, 255, 0.15);
  --pp-line-strong: rgba(255, 255, 255, 0.24);
  --pp-text: #f2f7ff;
  --pp-muted: rgba(214, 228, 246, 0.72);
  --pp-accent: #ffcb68;
  --pp-accent-strong: #ffe1a2;
  --pp-shadow: 0 28px 72px rgba(0, 0, 0, 0.4);
  --fiume-footer-bg: rgba(7, 12, 18, 0.72);
  --fiume-footer-border: var(--pp-line);
  --fiume-footer-text: var(--pp-text);
  --fiume-footer-muted: var(--pp-muted);
  --fiume-footer-accent: var(--pp-accent-strong);
  --fiume-footer-shadow: 0 12px 24px rgba(0, 0, 0, 0.24);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

/* App Plus keeps the same visual language that Pro Plus used to provide,
   but now owns the stylesheet locally so there is no runtime dependency on /pro-plus. */
body.pro-plus-page {
  min-height: 100vh;
  font-family: "Avenir Next", "Futura", "Segoe UI", sans-serif;
  color: var(--pp-text);
  background:
    radial-gradient(circle at 14% 18%, rgba(255, 117, 117, 0.16), transparent 22%),
    radial-gradient(circle at 82% 12%, rgba(255, 204, 102, 0.13), transparent 20%),
    radial-gradient(circle at 62% 74%, rgba(67, 156, 255, 0.15), transparent 28%),
    linear-gradient(180deg, #08111f 0%, #04070c 42%, #020306 100%);
}

body.pro-plus-page::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at center, black 30%, transparent 88%);
  pointer-events: none;
}

a {
  color: inherit;
}

code {
  font-family: "SFMono-Regular", "Menlo", "Consolas", monospace;
  font-size: 0.95em;
}

.pro-plus-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100dvh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-bottom: var(--fiume-footer-reserved);
  box-sizing: border-box;
}

.pro-plus-stage-panel {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 10%, rgba(255, 193, 93, 0.08), transparent 22%),
    radial-gradient(circle at 74% 16%, rgba(93, 165, 255, 0.11), transparent 24%),
    linear-gradient(180deg, rgba(8, 12, 18, 0.42), rgba(4, 6, 10, 0.84));
}

.pro-plus-stage,
.pro-plus-stage-guides {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.pro-plus-stage {
  z-index: 0;
  image-rendering: auto;
}

.pro-plus-stage-guides {
  z-index: 2;
  pointer-events: none;
}

.pro-plus-brand,
.pro-plus-mode-link,
.pro-plus-hero-button {
  backdrop-filter: blur(18px);
}

.pro-plus-kicker,
.pro-plus-status,
.pro-plus-meta {
  margin: 0;
}

.pro-plus-kicker {
  color: #ffd487;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  font-weight: 700;
}

.pro-plus-empty-state {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 20px;
  padding: 24px;
  text-align: center;
  background:
    radial-gradient(circle at center, rgba(5, 10, 15, 0.12), rgba(5, 10, 15, 0.34) 58%, rgba(5, 10, 15, 0.56) 100%);
  transition:
    opacity 180ms ease,
    visibility 180ms ease,
    transform 180ms ease;
}

.pro-plus-stage-panel.is-live .pro-plus-empty-state,
.pro-plus-stage-panel.has-history .pro-plus-empty-state {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px);
}

.pro-plus-empty-brand {
  display: grid;
  justify-items: center;
  gap: 18px;
}

.pro-plus-empty-brand-mark {
  width: clamp(86px, 10vw, 116px);
  height: clamp(86px, 10vw, 116px);
  border-radius: 28px;
  display: inline-grid;
  place-items: center;
  color: var(--pp-accent-strong);
  background: linear-gradient(180deg, rgba(255, 203, 104, 0.24), rgba(113, 196, 255, 0.1));
  border: 1px solid rgba(255, 232, 182, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 18px 40px rgba(0, 0, 0, 0.28);
}

.pro-plus-empty-brand-mark svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pro-plus-empty-brand-copy {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.pro-plus-empty-title {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  font-weight: 760;
  line-height: 0.94;
  letter-spacing: -0.06em;
}

.pro-plus-empty-brand-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255, 203, 104, 0.16);
  color: var(--pp-accent-strong);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pro-plus-empty-tagline {
  max-width: 28ch;
  margin: 0;
  color: var(--pp-muted);
  font-size: clamp(1rem, 1.8vw, 1.22rem);
  line-height: 1.5;
}

.pro-plus-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 32px;
  padding: 3px 12px 3px 3px;
  border: 1px solid var(--pp-line);
  border-radius: 999px;
  background: rgba(7, 12, 18, 0.74);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}

.pro-plus-brand-mark {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  display: inline-grid;
  place-items: center;
  color: var(--pp-accent-strong);
  background: linear-gradient(180deg, rgba(255, 203, 104, 0.18), rgba(113, 196, 255, 0.1));
  border: 1px solid rgba(255, 232, 182, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  flex: 0 0 auto;
}

.pro-plus-brand-mark svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pro-plus-brand-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 16px;
  padding: 0 6px;
  border-radius: 999px;
  background: rgba(255, 203, 104, 0.16);
  color: var(--pp-accent-strong);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
}

.pro-plus-nav {
  display: inline-flex;
  flex-wrap: nowrap;
  gap: 8px;
}

.pro-plus-mode-link,
.pro-plus-hero-button {
  appearance: none;
  border-radius: 999px;
  font: inherit;
  cursor: pointer;
  transition:
    transform 140ms ease,
    border-color 140ms ease,
    background-color 140ms ease,
    color 140ms ease,
    box-shadow 140ms ease;
}

.pro-plus-mode-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 11px;
  border: 1px solid var(--pp-line);
  background: rgba(7, 12, 18, 0.72);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.16);
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.pro-plus-mode-link-button {
  font-family: "Avenir Next", "Futura", "Segoe UI", sans-serif;
  color: inherit;
}

.pro-plus-mode-link-button[aria-pressed="true"] {
  border-color: rgba(255, 203, 104, 0.42);
  background: rgba(18, 30, 48, 0.88);
  color: var(--pp-accent-strong);
}

.pro-plus-mode-link-button[aria-pressed="false"] {
  opacity: 0.72;
}

.fiume-mode-switcher {
  position: absolute;
  left: max(18px, env(safe-area-inset-left));
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 4;
  display: inline-flex;
  gap: 6px;
  padding: 5px;
  border: 1px solid var(--pp-line);
  border-radius: 999px;
  background: rgba(7, 12, 18, 0.72);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(18px);
}

.fiume-mode-switcher-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  min-width: 54px;
  padding: 0 11px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--pp-muted);
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.08em;
  transition:
    transform 140ms ease,
    border-color 140ms ease,
    background-color 140ms ease,
    color 140ms ease,
    box-shadow 140ms ease;
}

.fiume-mode-switcher-link:hover,
.fiume-mode-switcher-link:focus-visible {
  border-color: rgba(255, 203, 104, 0.42);
  background: rgba(18, 30, 48, 0.88);
  color: var(--pp-accent-strong);
  outline: none;
  transform: translateY(-1px);
}

.fiume-mode-switcher-link[aria-current="page"] {
  border-color: rgba(255, 203, 104, 0.42);
  background: linear-gradient(135deg, rgba(255, 203, 104, 0.18), rgba(113, 196, 255, 0.1));
  color: var(--pp-accent-strong);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.fiume-mode-switcher-link[aria-current="page"]:hover,
.fiume-mode-switcher-link[aria-current="page"]:focus-visible {
  transform: none;
}

.pro-plus-hero-button {
  border: 0;
  min-height: 52px;
  padding: 0 24px;
  background: linear-gradient(135deg, rgba(255, 122, 71, 0.95), rgba(255, 212, 122, 0.95));
  color: #150f06;
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  box-shadow: 0 18px 30px rgba(255, 158, 89, 0.26);
}

.pro-plus-mode-link:disabled,
.pro-plus-hero-button:disabled {
  cursor: progress;
  opacity: 0.78;
  transform: none;
}

.pro-plus-sr-status {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.pro-plus-status {
  font-size: 0.9rem;
  font-weight: 700;
}

.pro-plus-meta {
  color: var(--pp-muted);
  font-size: 0.76rem;
  line-height: 1.35;
}

.pro-plus-brand:hover,
.pro-plus-brand:focus-visible,
.pro-plus-mode-link:hover,
.pro-plus-mode-link:focus-visible,
.pro-plus-hero-button:hover,
.pro-plus-hero-button:focus-visible {
  transform: translateY(-1px);
  outline: none;
}

@media (max-width: 720px) {
  .pro-plus-brand {
    gap: 8px;
    min-height: 28px;
    padding: 2px 10px 2px 2px;
    font-size: 0.68rem;
    letter-spacing: 0.1em;
  }

  .pro-plus-brand-mark {
    width: 22px;
    height: 22px;
    border-radius: 6px;
  }

  .pro-plus-brand-badge {
    min-height: 14px;
    padding: 0 5px;
    font-size: 0.61rem;
  }

  .pro-plus-mode-link {
    min-height: 28px;
    padding: 0 9px;
    font-size: 0.68rem;
    letter-spacing: 0.07em;
  }

  .fiume-mode-switcher {
    left: max(12px, env(safe-area-inset-left));
    bottom: max(12px, env(safe-area-inset-bottom));
    gap: 4px;
    padding: 4px;
  }

  .fiume-mode-switcher-link {
    min-height: 28px;
    min-width: 50px;
    padding: 0 9px;
    font-size: 0.68rem;
    letter-spacing: 0.07em;
  }

  .pro-plus-empty-title {
    gap: 10px;
    font-size: clamp(2rem, 9vw, 2.9rem);
  }

  .pro-plus-empty-brand-mark {
    width: 76px;
    height: 76px;
    border-radius: 24px;
  }

  .pro-plus-empty-tagline {
    font-size: 0.94rem;
  }
}
