/* Canonical saasland.io components and layouts; tokens live in design-tokens.css. */
@import url("./design-tokens.css");
.runtime-session-recovery { max-width: calc(100% - 28px); flex-wrap: wrap; }
.runtime-session-recovery .button { min-height: 44px; }
.tester-list code {
  min-width: 0;
  overflow-wrap: anywhere;
}
.tester-list .button {
  flex-shrink: 0;
}
.shared-apps {
  margin-top: 24px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
input,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
a {
  color: inherit;
  text-decoration: none;
}
a,
button,
input,
textarea,
select {
  outline-offset: 5px;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--violet);
}
button {
  color: inherit;
}
svg {
  flex-shrink: 0;
  vertical-align: middle;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1,
h2,
h3 {
  font-family: var(--font-heading);
}
h1 {
  letter-spacing: -0.035em;
  font-size: 38px;
  line-height: 1.12;
  font-weight: 750;
}
h2 {
  font-size: 23px;
  letter-spacing: -0.025em;
  font-weight: 720;
}
h3 {
  font-size: 16px;
  letter-spacing: -0.01em;
  font-weight: 680;
}
p {
  line-height: 1.65;
}
small {
  line-height: 1.5;
}
::selection {
  background: var(--lime);
  color: var(--on-lime);
}
.skip-link {
  position: fixed;
  top: -70px;
  left: 16px;
  background: var(--ink);
  color: white;
  padding: 12px 20px;
  z-index: 100;
}
.skip-link:focus {
  top: 16px;
}
.boot {
  min-height: 100vh;
  display: grid;
  place-content: center;
  text-align: center;
  gap: 20px;
}
.boot p {
  color: var(--muted);
  font-size: 14px;
}
.brand {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  color: var(--ink);
  font-family: var(--font-heading);
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -2px;
  line-height: 1;
}
.brand-dot {
  color: var(--violet);
}
.brand-logo {
  display: block;
  width: 5em;
  height: auto;
  max-width: 100%;
  overflow: visible;
}
.brand-accent { fill: var(--violet); }
.brand-name {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.eyebrow {
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--violet);
}
.muted {
  color: var(--muted);
}
.mono {
  font-family: var(--font-mono);
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--paper);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.4;
  transition:
    background 0.15s,
    border-color 0.15s,
    transform 0.25s var(--motion-spring),
    box-shadow 0.2s;
  white-space: nowrap;
}
.button:hover:not(:disabled) {
  background: #eeedf3;
}
.button:active:not(:disabled) {
  transform: scale(0.97);
}
.button.primary {
  background: linear-gradient(120deg, var(--violet) 0%, #a23be8 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--shadow-pop);
}
.button.primary:hover:not(:disabled) {
  background: linear-gradient(120deg, var(--violet-dark) 0%, #9433d8 100%);
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgb(108 71 255 / 25%), 0 22px 44px -16px rgb(226 62 196 / 55%);
}
.button.dark {
  background: var(--ink);
  border-color: var(--ink);
  color: white;
}
.button.dark:hover:not(:disabled) {
  background: #2c2838;
}
.button.ghost {
  background: transparent;
  border-color: transparent;
}
.button.ghost:hover:not(:disabled) {
  background: #e9e7ee;
}
.button.danger {
  color: #b03940;
  border-color: #ead4d5;
}
.button.small {
  min-height: 34px;
  padding: 7px 11px;
  font-size: 12px;
}
.button.large {
  min-height: 50px;
  padding: 14px 22px;
  font-size: 14px;
}
.button svg {
  width: 16px;
  height: 16px;
}
.text-link {
  color: var(--violet);
  font-weight: 550;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.text-link:hover {
  text-decoration: underline;
}
/* A text link that is really a button keeps the link look, not the browser's button box. */
button.text-link { padding: 0; border: 0; background: none; font-family: inherit; cursor: pointer; }
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: var(--radius-control);
  transition: background 0.15s, transform 0.25s var(--motion-spring);
}
.icon-button:hover {
  background: var(--base);
}
.icon {
  width: 20px;
  height: 20px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: var(--radius-pill);
  background: #ecebf1;
  color: #6f6d77;
  font-size: 10px;
  font-weight: 600;
  padding: 5px 8px;
  white-space: nowrap;
  letter-spacing: 0.1px;
}
.badge.violet {
  background: var(--violet-light);
  color: var(--violet);
}
.badge.green {
  background: var(--green-light);
  color: var(--green);
}
.badge.amber, .settings-diff {
  background: #fff3d9;
  color: #8f681a;
}
.badge.red {
  background: #fae9e9;
  color: #a54949;
}
.status-dot {
  height: 5px;
  width: 5px;
  border-radius: 50%;
  background: currentColor;
}
.divider {
  height: 1px;
  background: var(--line);
}
.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.section-head h2 {
  margin: 0;
}
.section-head .subtitle {
  font-size: 13px;
  color: var(--muted);
  margin: 7px 0 0;
}
.notice {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  padding: 15px 18px;
  border: 1px solid #e6d9b9;
  background: #f5f2ff;
  color: #796331;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.55;
  margin: 0 0 24px;
}
.notice.error {
  color: #9b4141;
  background: #fff4f3;
  border-color: #ecd7d4;
}
.notice.info {
  color: #65548d;
  background: #f5f1fc;
  border-color: #e7dff7;
}
.notice p {
  margin: 0;
}
.notice .button {
  margin-left: auto;
  align-self: center;
}
.notice svg {
  width: 18px;
  margin-top: 1px;
  flex-shrink: 0;
}
.empty {
  padding: 38px 24px;
  text-align: center;
}
.empty-symbol {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f9f8fb;
  margin: 0 auto 18px;
  color: #73707b;
  box-shadow: 0 3px 0 #eae8ef;
}
.empty-symbol svg {
  width: 23px;
  height: 23px;
}
.empty h3 {
  font-size: 16px;
  margin-bottom: 8px;
}
.empty p {
  font-size: 13px;
  color: var(--muted);
  max-width: 360px;
  margin: 0 auto 20px;
}
.empty p:last-child {
  margin-bottom: 0;
}
.loading-placeholder {
  min-height: 125px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 13px;
}
.spinner {
  width: 15px;
  height: 15px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.fade-in {
  animation: appear 0.28s ease both;
}
@keyframes appear {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Public home */
.site-header {
  height: 96px;
  padding: 0 6.2%;
  max-width: 1600px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.site-header .brand {
  font-size: 36px;
}
.site-nav {
  display: flex;
  flex-wrap: wrap;
  min-width: 0;
  margin-left: auto;
  gap: 30px;
  align-items: center;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}
.site-nav > a:not(.button) {
  color: #726f79;
}
.site-nav > a:hover {
  color: var(--ink);
}
.landing-main {
  max-width: 1440px;
  margin: auto;
  padding: 0 6.9%;
}
.hero {
  display: grid;
  grid-template-columns: 1.08fr 1fr;
  gap: 7%;
  padding: 94px 0 99px;
  align-items: center;
}
.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #625187;
  font-size: 12px;
  font-weight: 500;
  background: #ece7f5;
  border: 1px solid #e5def0;
  border-radius: 30px;
  padding: 7px 11px;
  margin-bottom: 26px;
}
.hero-label span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--violet);
}
.hero h1 {
  font-size: clamp(48px, 4.9vw, 70px);
  font-weight: 550;
  letter-spacing: -3.5px;
  line-height: 1.1;
  margin-bottom: 25px;
}
.hero h1 em {
  font-style: normal;
  color: var(--violet);
}
.hero-copy > p {
  font-size: 16px;
  line-height: 1.85;
  max-width: 435px;
  color: #76737d;
  margin-bottom: 29px;
}
.hero-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}
.hero-note {
  font-size: 11px;
  color: #86838d;
  margin: 17px 0 0 !important;
}
.hero-visual {
  position: relative;
  padding: 15px 5px 26px;
}
.visual-grid {
  position: absolute;
  inset: -30px -30px -12px;
  background-image:
    linear-gradient(#dedbe866 1px, transparent 1px),
    linear-gradient(90deg, #dedbe866 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(ellipse, black 25%, transparent 70%);
  z-index: -1;
}
.workspace-preview {
  background: #fff;
  border: 1px solid #d6d3dd;
  border-radius: 14px;
  box-shadow:
    0 20px 55px #1c18300c,
    0 3px 5px #1c183003;
  transform: rotate(-2deg);
  overflow: hidden;
}
.preview-top {
  padding: 18px 20px;
  border-bottom: 1px solid #e9e8ee;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.preview-top > span {
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 650;
}
.preview-dots {
  display: flex;
  gap: 5px;
}
.preview-dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #dddbe3;
}
.preview-body {
  padding: 23px 21px 24px;
}
.preview-label {
  font-size: 10px;
  color: #85838c;
  font-weight: 600;
  margin-bottom: 15px;
}
.preview-app {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  margin-bottom: 10px;
}
.preview-app:last-child {
  margin-bottom: 0;
}
.app-symbol {
  display: grid;
  place-items: center;
  background: #f0ecfb;
  color: var(--violet);
  border-radius: var(--radius-card);
  width: 42px;
  height: 42px;
  font-weight: 650;
  font-size: 17px;
  flex-shrink: 0;
  font-family: var(--font-heading);
}
.app-symbol.green {
  background: #e8e5f2;
  color: #635981;
}
.app-symbol.peach {
  background: #f9eee6;
  color: #b18c70;
}
.preview-app .app-symbol {
  width: 37px;
  height: 37px;
  border-radius: 9px;
}
.preview-app .app-symbol svg {
  width: 18px;
  height: 18px;
}
.preview-app-text {
  flex: 1;
}
.preview-app-text strong {
  font-size: 11px;
  display: block;
  margin-bottom: 4px;
  font-weight: 600;
}
.preview-app-text span {
  font-size: 9px;
  color: #85828e;
}
.preview-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8f8fb;
  padding: 14px 20px;
  font-size: 10px;
  color: #85828e;
  border-top: 1px solid #e9e8ee;
}
.preview-bottom svg {
  width: 13px;
  height: 13px;
  margin-right: 5px;
  color: #837e91;
}
.floating-note {
  position: absolute;
  bottom: 0;
  right: -12px;
  background: #eee9fb;
  border: 1px solid #dfd5f5;
  padding: 16px 19px;
  border-radius: var(--radius-card);
  box-shadow: 0 8px 20px #4233590b;
  display: flex;
  align-items: center;
  gap: 11px;
  transform: rotate(3deg);
}
.floating-note .note-icon {
  width: 30px;
  height: 30px;
  background: #e4dbf8;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--violet);
}
.floating-note strong {
  display: block;
  font-size: 11px;
  font-weight: 650;
}
.floating-note small {
  display: block;
  font-size: 10px;
  color: #9584b6;
  margin-top: 3px;
}
.platform-strip {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 25px 0;
  gap: 20px;
}
.platform-strip > div {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 500;
  color: #615e68;
}
.platform-strip svg {
  width: 17px;
  height: 17px;
  color: #827e8d;
}
.landing-section {
  padding: 78px 0;
}
.landing-section .section-head {
  align-items: end;
  margin-bottom: 32px;
}
.landing-section h2 {
  font-size: 34px;
  letter-spacing: -1.3px;
  margin-bottom: 0;
  margin-top: 10px;
  font-weight: 550;
}
.landing-section .section-head > p {
  margin: 0;
  max-width: 320px;
  color: var(--muted);
  font-size: 13px;
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.feature-card {
  background: #fafafd;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 27px;
}
.feature-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  background: #e9e7ef;
  color: #757182;
  border-radius: 10px;
  margin-bottom: 23px;
}
.feature-card h3 {
  font-size: 15px;
  margin-bottom: 9px;
}
.feature-card p {
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
  margin: 0;
}
.landing-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  background: #eeeaf6;
  border: 1px solid #e3ddee;
  border-radius: 16px;
  padding: 36px 40px;
  margin: 0 0 60px;
}
.landing-cta h2 {
  font-size: 25px;
  margin-bottom: 8px;
  letter-spacing: -0.7px;
}
.landing-cta p {
  margin: 0;
  color: #8a7c9e;
  font-size: 13px;
}
.site-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 24px 32px;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding: 27px 0 32px;
  color: var(--muted);
  font-size: 11px;
}
.site-footer .brand {
  font-size: 23px;
  letter-spacing: -1.3px;
}
.site-footer > div {
  display: flex;
  flex-wrap: wrap;
  min-width: 0;
  align-items: center;
  gap: 24px;
}
.public-guide {
  max-width: 900px;
  margin: 42px auto 80px;
  padding: 0 30px;
}

/* Workspace */
.app-shell {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  min-height: 100vh;
}
.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: 232px;
  background: #f9f9fc;
  border-right: 1px solid var(--line);
  padding: 32px 20px 19px;
  display: flex;
  flex-direction: column;
  z-index: 30;
}
.sidebar .brand {
  padding-left: 12px;
  font-size: 33px;
  margin-bottom: 37px;
}
.workspace-switch {
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: var(--radius-control);
  padding: 11px 10px;
  margin-bottom: 27px;
  min-width: 0;
}
.workspace-switch > div {
  flex: 1;
  min-width: 0;
}
.workspace-switch strong {
  display: block;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.workspace-switch small {
  display: block;
  font-size: 10px;
  color: #8a8794;
  margin-top: 3px;
}
.workspace-avatar {
  display: grid;
  place-items: center;
  width: 29px;
  height: 29px;
  background: #ede8f8;
  color: var(--violet);
  border: 1px solid #e3daf1;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 600;
}
.workspace-switch > svg {
  width: 13px;
  height: 13px;
  color: #94909e;
}
.nav-label {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #9a96a5;
  padding: 0 12px;
  margin-bottom: 10px;
}
.nav-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 12px;
  border-radius: 7px;
  color: #797584;
  font-size: 12px;
  font-weight: 450;
  border: 0;
  background: transparent;
  text-align: left;
  transition:
    background 0.15s,
    color 0.15s;
}
.nav-item svg {
  width: 17px;
  height: 17px;
  stroke-width: 1.6;
}
.nav-item:hover {
  background: #ebe9f0;
  color: #494653;
}
.nav-item.active {
  background: #eee9fb;
  color: var(--violet);
  font-weight: 600;
}
.nav-item .nav-count {
  margin-left: auto;
  min-width: 19px;
  padding: 2px 5px;
  font-size: 9px;
  border-radius: 4px;
  background: #e2d9f7;
  color: var(--violet);
  text-align: center;
}
.sidebar-bottom {
  margin-top: auto;
  padding-top: 36px;
}
.sidebar-bottom .nav-item {
  font-size: 11px;
}
.credit-mini {
  background: #eeecf3;
  border: 1px solid #dedae8;
  border-radius: 9px;
  padding: 14px;
  margin: 20px 0 17px;
}
.credit-mini-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 10px;
  color: #827e8e;
  margin-bottom: 9px;
}
.credit-mini strong {
  font-size: 20px;
  font-weight: 550;
  letter-spacing: -0.5px;
}
.credit-mini strong small {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0;
  color: #878394;
}
.credit-mini .text-link {
  font-size: 10px;
  display: flex;
  justify-content: space-between;
  border-top: 1px solid #d9d5e4;
  padding-top: 10px;
  margin-top: 12px;
}
.user-row {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 2px 3px;
}
.user-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #dcd8e8;
  color: #655b81;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}
.user-details {
  min-width: 0;
  flex: 1;
}
.user-details strong {
  display: block;
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-details small {
  display: block;
  font-size: 9px;
  color: #9894a3;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-row .icon-button {
  border: 0;
  background: none;
  color: #868294;
  width: 25px;
  height: 27px;
}
.user-row .icon-button svg {
  width: 14px;
  height: 14px;
}
.main-shell {
  grid-column: 2;
  min-width: 0;
}
.topbar {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 42px;
  border-bottom: 1px solid var(--line);
  background: #f6f5f9;
}
.breadcrumb {
  font-size: 11px;
  color: var(--muted);
  display: flex;
  gap: 11px;
  align-items: center;
}
.breadcrumb > span:last-child {
  color: #625f6d;
}
.breadcrumb svg {
  width: 11px;
  height: 11px;
}
.topbar-actions {
  display: flex;
  gap: 17px;
  align-items: center;
  font-size: 10px;
  color: #847f91;
}
.topbar-actions .text-link {
  font-size: 10px;
  color: #817d8d;
}
.topbar-status {
  display: flex;
  align-items: center;
  gap: 6px;
}
.topbar-status .status-dot {
  background: #8e85a8;
}
.mobile-menu {
  display: none;
}
.workspace-main {
  padding: 38px 42px 32px;
  max-width: 1510px;
  margin: auto;
}
.page-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  margin-bottom: 30px;
}
.page-heading h1 {
  font-size: 29px;
  font-weight: 550;
  letter-spacing: -1.1px;
  margin-bottom: 9px;
}
.page-heading p {
  font-size: 12px;
  color: #84808e;
  line-height: 1.65;
  margin: 0;
}
.page-heading .button {
  font-size: 11px;
  min-height: 38px;
}
.page-heading > div:first-child {
  min-width: 0;
  flex: 1 1 240px;
}
.workspace-hero {
  background: #eeeaf7;
  border: 1px solid #e3ddef;
  border-radius: 13px;
  padding: 26px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  margin-bottom: 26px;
  position: relative;
  overflow: hidden;
}
.workspace-hero .eyebrow {
  color: #a395b8;
  font-size: 8px;
  letter-spacing: 1.4px;
  display: block;
  margin-bottom: 9px;
}
.workspace-hero h2 {
  font-size: 22px;
  font-weight: 550;
  letter-spacing: -0.65px;
  margin-bottom: 9px;
  max-width: 440px;
}
.workspace-hero p {
  font-size: 11px;
  color: #998aaf;
  max-width: 445px;
  margin-bottom: 15px;
  line-height: 1.75;
}
.workspace-hero .button {
  font-size: 10px;
  min-height: 32px;
  padding: 8px 12px;
}
.hero-tiles {
  position: relative;
  width: 185px;
  min-width: 185px;
  height: 122px;
  margin: 0 35px 0 0;
}
.hero-tile {
  width: 65px;
  height: 65px;
  background: #fff;
  border: 1px solid #ddd5ed;
  border-radius: 15px;
  box-shadow: 0 6px 12px #7864990a;
  position: absolute;
  display: grid;
  place-items: center;
  color: #a18bca;
  transform: rotate(-12deg);
}
.hero-tile svg {
  width: 27px;
  height: 27px;
  stroke-width: 1.4;
}
.hero-tile:nth-child(1) {
  left: 5px;
  top: 38px;
  transform: rotate(-15deg);
  background: #f9f7fd;
}
.hero-tile:nth-child(2) {
  left: 57px;
  top: 2px;
  z-index: 1;
  background: #dcd0ef;
  color: #8466b9;
  transform: rotate(6deg);
}
.hero-tile:nth-child(3) {
  left: 109px;
  top: 48px;
  transform: rotate(19deg);
  background: #fff;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
  margin-bottom: 32px;
}
.stats-grid.usage-health { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 640px; }
.stat-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fafafd;
  padding: 18px 19px;
}
.stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #898496;
  font-size: 10px;
  margin-bottom: 16px;
}
.stat-top svg {
  width: 15px;
  height: 15px;
  color: #a19dad;
}
.stat-value {
  font-family: var(--font-heading);
  font-size: 27px;
  font-weight: 500;
  letter-spacing: -0.8px;
  line-height: 1;
  margin-bottom: 11px;
}
.stat-foot {
  font-size: 9px;
  color: #9691a4;
}
.stat-foot a {
  color: var(--violet);
}
.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(245px, 1fr);
  gap: 25px;
}
.workspace-main .section-head h2 {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.4px;
}
.workspace-main .section-head .text-link {
  font-size: 10px;
  color: #868195;
}
.workspace-main .section-head {
  margin-bottom: 17px;
}
.app-list-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fafafd;
  overflow: hidden;
}
.app-row {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 20px;
  transition: background 0.15s;
}
.app-row + .app-row {
  border-top: 1px solid #e5e3ec;
}
.app-row:hover {
  background: #f0eef5;
}
.app-row .app-symbol {
  width: 38px;
  height: 38px;
  font-size: 15px;
  border-radius: 10px;
}
.app-row-text {
  flex: 1;
  min-width: 0;
}
.app-row-text strong {
  display: block;
  font-size: 12px;
  font-weight: 550;
  margin-bottom: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.app-row-text small {
  display: block;
  font-size: 9px;
  color: #8d889c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.app-row > svg {
  width: 13px;
  height: 13px;
  color: #a49fb1;
}
.checklist {
  background: #fafafd;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 8px 20px;
}
.checklist-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 18px 0;
}
.checklist-item + .checklist-item {
  border-top: 1px solid #e5e3ec;
}
.step-indicator {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: #eceaf2;
  color: #a39eb3;
  border: 1px solid #dcd8e7;
  border-radius: 50%;
  font-size: 9px;
  margin-top: 1px;
}
.step-indicator.complete {
  background: #e3dfef;
  border-color: #dad5e9;
  color: #796e9b;
}
.step-indicator svg {
  width: 12px;
  height: 12px;
}
.checklist-item strong {
  display: block;
  font-size: 11px;
  font-weight: 550;
  margin-bottom: 5px;
}
.checklist-item p {
  font-size: 10px;
  line-height: 1.7;
  color: #938ea3;
  margin: 0;
}
.checklist-item .text-link {
  font-size: 10px;
  margin-top: 9px;
}
.workspace-bottom {
  margin-top: 29px;
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 25px;
}
.resource-card {
  border: 1px solid var(--line);
  background: #ebe9f2;
  border-radius: var(--radius-card);
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 13px;
}
.resource-card .resource-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  background: #dedaea;
  color: #7b7392;
  border-radius: var(--radius-control);
}
.resource-card .resource-icon svg {
  width: 17px;
  height: 17px;
}
.resource-card strong {
  font-size: 11px;
  font-weight: 550;
  display: block;
  margin-bottom: 5px;
}
.resource-card p {
  font-size: 9px;
  color: #938da5;
  margin: 0;
}
.resource-card > svg {
  margin-left: auto;
  width: 14px;
  height: 14px;
  color: #9089a5;
}
.workspace-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  justify-content: space-between;
  color: #9d98ac;
  font-size: 9px;
  margin-top: 38px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.workspace-footer > div {
  display: flex;
  flex-wrap: wrap;
  min-width: 0;
  gap: 17px;
}
.workspace-main .empty {
  padding: 31px 22px;
}
.workspace-main .empty h3 {
  font-size: 13px;
}
.workspace-main .empty p {
  font-size: 11px;
  max-width: 285px;
}
.workspace-main .empty .button {
  font-size: 10px;
  min-height: 34px;
}
.workspace-main .empty-symbol {
  width: 43px;
  height: 43px;
  border-radius: 12px;
  margin-bottom: 17px;
}
.workspace-main .empty-symbol svg {
  width: 19px;
  height: 19px;
}
.apps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.app-card {
  padding: 22px;
  background: #fafafd;
  border: 1px solid var(--line);
  border-radius: 13px;
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}
.app-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px #16131f07;
}
.app-card-top {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: 21px;
}
.app-symbol img { width: 100%; height: 100%; object-fit: contain; border-radius: inherit; }
.app-artwork { aspect-ratio: 16 / 9; overflow: hidden; border-radius: 8px; background: var(--paper); margin-bottom: 20px; }
.app-artwork img { display: block; width: 100%; height: 100%; object-fit: contain; }
.app-media-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.app-media-grid .form-field { min-width: 0; }
.app-media-grid input { max-width: 100%; }
.app-media-grid small { overflow-wrap: anywhere; }
.app-media-preview { display: flex; align-items: center; justify-content: center; aspect-ratio: 16 / 9; background: var(--base); border: 1px solid var(--line); border-radius: 8px; color: var(--muted); overflow: hidden; margin-bottom: 12px; }
.app-media-preview.logo { aspect-ratio: 1; max-width: 160px; }
.app-media-preview img { display: block; width: 100%; height: 100%; object-fit: contain; }
.app-media-summary { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 20px; margin: 4px 0 20px; }
.app-media-summary-item { margin: 0; min-width: 0; max-width: 100%; }
.app-media-summary-item.logo { width: 96px; }
.app-media-summary-item.image { width: 280px; }
.app-media-summary-item figcaption { margin-bottom: 8px; font-size: 12px; font-weight: 600; }
.app-media-summary .app-media-preview { width: 100%; margin: 0; font-size: 12px; text-align: center; }
.app-media-summary .app-media-preview > span { padding: 8px; }
[data-app-artwork] > .code-head { flex-wrap: wrap; gap: 8px; }
@media (max-width: 760px) { .app-media-grid { grid-template-columns: minmax(0, 1fr); } }
.app-card h3 {
  font-size: 14px;
  margin-bottom: 7px;
}
.app-card p {
  font-size: 11px;
  line-height: 1.75;
  min-height: 38px;
  color: #8b859b;
  margin: 0 0 20px;
  overflow-wrap: anywhere;
}
.app-card-bottom {
  border-top: 1px solid var(--line);
  padding-top: 13px;
  display: flex;
  justify-content: space-between;
  font-size: 9px;
  color: #958fa7;
  gap: 10px;
}
.app-card-bottom .mono {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.app-card-bottom svg {
  width: 13px;
  height: 13px;
}
.app-security {
  margin: 0 0 14px;
}
.security-counts {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}
.security-details {
  margin-top: 12px;
}
.security-details summary {
  cursor: pointer;
  font-weight: 600;
}
.security-findings {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.security-finding {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  overflow-wrap: anywhere;
}
.security-finding p {
  margin: 2px 0 0;
}
.security-finding > .badge {
  min-width: 58px;
  justify-content: center;
}
.card-create {
  background: transparent;
  border: 1px dashed #cdc9d9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 220px;
  color: #8c869d;
  padding: 30px;
  border-radius: 13px;
  text-align: center;
}
.card-create:hover {
  background: #e9e7f0;
  border-color: #bdb3d8;
}
.card-create > span {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid #d5d2df;
  background: #f7f6fb;
  border-radius: var(--radius-card);
  margin-bottom: 16px;
}
.card-create strong {
  font-size: 12px;
  font-weight: 500;
}
.card-create small {
  font-size: 10px;
  margin-top: 8px;
  line-height: 1.7;
}
.filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
.creator-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin-bottom: 24px;
}
.creator-links > * {
  flex: 0 0 auto;
  max-width: 100%;
}
.creator-links .button {
  white-space: normal;
}
.search-field {
  position: relative;
  max-width: 320px;
  width: 100%;
}
.search-field svg {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 15px;
  height: 15px;
  color: #908ba1;
}
.search-field input {
  width: 100%;
  background: #fafafd;
  border: 1px solid var(--line);
  border-radius: var(--radius-control);
  min-height: 39px;
  padding: 9px 12px 9px 35px;
  font-size: 11px;
  color: var(--ink);
}
.filter-bar .badge {
  margin-left: auto;
}
.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(240px, 1fr);
  gap: 24px;
}
.detail-layout > div { min-width: 0; }
/* Rarely needed app settings: one closed group at the end of the settings column. */
.advanced-settings { margin-bottom: 22px; min-width: 0; }
.advanced-settings > summary { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 14px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow-soft); cursor: pointer; list-style: none; }
.advanced-settings > summary::-webkit-details-marker { display: none; }
.advanced-settings > summary > span:first-child { display: grid; gap: 2px; margin-right: auto; min-width: 0; }
.advanced-settings > summary strong { font-family: var(--font-heading); font-size: 16px; }
.advanced-settings > summary small { color: var(--muted); font-size: 12px; }
.advanced-settings > summary > svg { flex: none; width: 16px; height: 16px; color: var(--muted); transform: rotate(90deg); transition: transform var(--motion-fast, 120ms) ease; }
.advanced-settings[open] > summary > svg { transform: rotate(-90deg); }
.advanced-settings[open] > summary { margin-bottom: 22px; }
.advanced-settings > summary:hover { border-color: var(--muted); }
.advanced-settings > .content-panel:last-child { margin-bottom: 0; }
.content-panel {
  padding: 25px;
  margin-bottom: 22px;
}
.content-panel h2 {
  font-size: 16px;
  margin-bottom: 17px;
}
.content-panel h3 {
  font-size: 13px;
}
.content-panel > p {
  color: var(--muted);
  font-size: 13px;
}
/* Short label/value facts in a panel: a responsive grid instead of sentences. */
.finance-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}
@media (max-width: 760px) { .finance-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } }
.finance-facts > div {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-control);
  background: var(--base);
}
.finance-facts dt { display: flex; align-items: center; color: var(--muted); font-size: 12px; }
.finance-facts dd { margin: 4px 0 0; font-size: 14px; font-weight: 600; color: var(--ink); }
.finance-facts .app-preview-address { overflow-wrap: anywhere; }
.detail-title {
  display: flex;
  align-items: center;
  gap: 14px;
}
.detail-title h1 {
  margin-bottom: 6px;
}
.detail-title .app-symbol {
  width: 49px;
  height: 49px;
  font-size: 21px;
}
.detail-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.key-value {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: start;
  font-size: 11px;
  line-height: 1.6;
  padding: 13px 0;
}
.key-value + .key-value {
  border-top: 1px solid #e8e6ee;
}
.key-value > span:first-child {
  color: var(--muted);
}
.key-value > span:last-child {
  text-align: right;
  overflow-wrap: anywhere;
  min-width: 0;
}
.key-value a {
  color: var(--violet);
}
.code-block {
  background: #f0eff5;
  border: 1px solid #dedae8;
  border-radius: 9px;
  padding: 18px 20px;
  overflow: auto;
  font-size: 11px;
  line-height: 1.9;
  color: #69637b;
  margin: 14px 0 0;
  tab-size: 2;
}
.code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}
.code-head h2 {
  margin: 0;
}
.danger-zone {
  border-color: #e9dad5;
}
.danger-zone h2 {
  color: #a65e56;
}
.danger-zone .button {
  font-size: 11px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.credit-icon {
  display: inline-block;
  width: 1.35em;
  height: 1.35em;
  min-width: 20px;
  min-height: 20px;
  flex: 0 0 auto;
  vertical-align: -0.3em;
  background-color: currentColor;
  mask: url("./credits-coin-black.svg") center / contain no-repeat;
}
.credit-icon-black { background-color: #000; }
.credit-icon-white { background-color: #fff; }
.credit-icon-color {
  background: url("./credits-coin.svg") center / contain no-repeat;
  mask: none;
}
.credit-amount {
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  white-space: nowrap;
  vertical-align: middle;
  font-variant-numeric: tabular-nums;
}
.credit-amount .credit-icon { width: 1.15em; height: 1.15em; }
.button:has(.credit-amount) { min-height: 44px; }
@media (forced-colors: active) {
  .credit-icon { forced-color-adjust: none; background: CanvasText; mask: url("./credits-coin-black.svg") center / contain no-repeat; }
  .button .credit-icon { background-color: ButtonText; }
}
.wallet-layout {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 24px;
  align-items: start;
}
.balance-card {
  padding: 28px;
  background: #eee9f8;
  border: 1px solid #e2daef;
  border-radius: 14px;
}
.balance-card .eyebrow {
  font-size: 9px;
  color: var(--muted);
}
.balance-value {
  font-family: var(--font-heading);
  font-size: 55px;
  letter-spacing: -2px;
  line-height: 1.1;
  font-weight: 550;
  margin: 25px 0 9px;
}
.balance-value small {
  font-family: "DM Sans", sans-serif;
  font-size: 13px;
  letter-spacing: 0;
  font-weight: 400;
  color: #a493ba;
}
.balance-card > p {
  font-size: 11px;
  color: #a493ba;
  margin-bottom: 25px;
}
.balance-info {
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
  border-top: 1px solid #dcd3eb;
  padding-top: 17px;
}
.topup-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 20px 0;
}
.topup-choice {
  background: #f8f8fb;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 15px 8px;
  text-align: center;
}
.topup-choice strong {
  display: block;
  font-size: 20px;
  font-family: var(--font-heading);
  font-weight: 500;
  margin-bottom: 7px;
}
.topup-choice small {
  font-size: 9px;
  color: var(--muted);
}
.topup-choice.selected {
  background: #f2edfc;
  border-color: #aa94e7;
  color: var(--violet);
}
.full-width {
  width: 100%;
}
.fine-print {
  font-size: 12px !important;
  color: #958fa5 !important;
  margin-top: 10px !important;
  line-height: 1.55 !important;
}
/* Info tips: a small "i" beside a label or heading; the bubble is fixed-positioned by ui.js. */
.info-tip {
  display: inline-flex;
  vertical-align: middle;
  margin-left: 4px;
  position: relative;
  line-height: 1;
}
.info-tip-button {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--muted);
  cursor: help;
}
/* 44px touch target without changing the visual size. */
.info-tip-button::before { content: ""; position: absolute; inset: -11px; }
.info-tip-button .icon { width: 17px; height: 17px; }
.info-tip-button:hover,
.info-tip.open .info-tip-button { color: var(--violet); background: var(--violet-light); }
.info-tip-button:focus-visible { outline: 2px solid var(--violet); outline-offset: 2px; }
.info-tip-bubble {
  position: fixed;
  z-index: 1300; /* above the cookie banner (1100) and cookie dialog (1200) */
  max-width: calc(100vw - 24px);
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-control);
  background: var(--paper);
  color: var(--ink);
  box-shadow: var(--shadow-pop);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0;
  text-align: left;
  text-transform: none;
  white-space: normal;
  pointer-events: none;
}
.info-tip-bubble[hidden] { display: none; }
@media (forced-colors: active) { .info-tip-bubble { border-color: CanvasText; } }
.transaction-row,
.event-row {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 17px 22px;
}
.transaction-row + .transaction-row,
.event-row + .event-row {
  border-top: 1px solid #e5e3ec;
}
.transaction-icon,
.event-icon {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-control);
  background: #eae8f1;
  color: #8880a1;
  flex-shrink: 0;
}
.transaction-icon svg,
.event-icon svg {
  width: 14px;
  height: 14px;
}
.transaction-row > div:nth-child(2),
.event-row > div:nth-child(2) {
  flex: 1;
  min-width: 0;
}
.transaction-row strong,
.event-row strong {
  display: block;
  font-size: 11px;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.transaction-row small,
.event-row small {
  font-size: 9px;
  color: #958fa5;
  display: block;
  margin-top: 5px;
  overflow-wrap: anywhere;
}
.transaction-amount {
  font-size: 12px;
  font-weight: 500;
}
.transaction-amount.positive {
  color: var(--green);
}
.table-wrap {
  /* Positioned, so screen-reader-only units in cells stay inside the scroll area. */
  position: relative;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: #fafafd;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  font-size: 11px;
}
th {
  font-weight: 500;
  color: var(--muted);
  font-size: 9px;
  padding: 14px 20px;
  background: #eeecf4;
  white-space: nowrap;
}
td {
  padding: 18px 20px;
  border-top: 1px solid var(--line);
  vertical-align: middle;
}
td .muted {
  font-size: 10px;
}
.storage-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.storage-card {
  padding: 27px;
}
.storage-card > .feature-icon {
  background: #e7e4f0;
}
.storage-card h2 {
  font-size: 16px;
}
.storage-card p {
  font-size: 12px;
  color: var(--muted);
}
.storage-card .code-block {
  font-size: 10px;
}
.guide-intro {
  max-width: 610px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 28px;
}
.guide-grid {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}
.guide-nav {
  position: sticky;
  top: 25px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.guide-nav a {
  font-size: 11px;
  color: #8b859c;
  padding: 9px 0;
}
.guide-nav a:hover {
  color: var(--violet);
}
.guide-article {
  min-width: 0;
  overflow-wrap: anywhere;
}
.guide-article section {
  scroll-margin-top: 25px;
}
.guide-article .content-panel {
  padding: 27px;
}
.guide-article h2 {
  font-size: 18px;
  margin-bottom: 12px;
}
.guide-article p,
.guide-article li {
  font-size: 12px;
  line-height: 1.85;
  color: var(--muted);
}
.guide-article ul,
.guide-article ol {
  padding-left: 20px;
}
.guide-article li {
  margin-bottom: 8px;
}
.guide-article code:not(.code-block) {
  background: #eae8f0;
  padding: 2px 4px;
  border-radius: 3px;
  font-size: 10px;
  overflow-wrap: anywhere;
}
.guide-article .notice {
  font-size: 11px;
  margin: 17px 0 0;
}
.mobile-backdrop {
  display: none;
}
.sign-in-panel {
  max-width: 460px;
  text-align: center;
  margin: 60px auto;
  padding: 40px;
}
.sign-in-panel h2 {
  margin: 20px 0 10px;
}
.sign-in-panel p {
  font-size: 13px;
  color: var(--muted);
}

/* Dialogs and feedback */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: #16131f65;
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 100;
}
.modal {
  background: #fafafd;
  border: 1px solid #dbd7e5;
  border-radius: 17px;
  max-width: 1000px;
  width: 100%;
  max-height: calc(100dvh - 48px);
  overflow-y: auto;
  padding: 28px;
  box-shadow: 0 25px 100px #16131f25;
}
.modal-backdrop.app-logs-backdrop {
  padding: 8px;
}
.modal.app-logs-modal {
  max-width: none;
  max-height: calc(100dvh - 16px);
  padding: 20px;
}
.app-logs-modal #app-log-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.app-logs-modal .form-field {
  min-width: 0;
  margin-bottom: 0;
}
.app-logs-modal .form-field :is(input, select) {
  width: 100%;
  min-width: 0;
}
.app-logs-modal :is(.form-error, #app-log-form > .modal-actions) {
  grid-column: 1 / -1;
}
.app-logs-modal .form-error:empty {
  display: none;
}
.app-logs-modal .modal-actions {
  flex-wrap: wrap;
  align-items: center;
  margin-top: 0;
  padding-top: 12px;
}
.app-logs-modal .app-log-output {
  max-height: 60dvh;
  padding: 12px;
  font-size: 12px;
}
@media (max-width: 1000px) {
  .app-logs-modal #app-log-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 480px) {
  .modal.app-logs-modal {
    padding: 12px;
  }
  .app-logs-modal #app-log-form {
    grid-template-columns: minmax(0, 1fr);
  }
}
.modal-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 24px;
}
.modal-head h2 {
  font-size: 23px;
  font-weight: 600;
  margin-bottom: 8px;
}
.modal-head p {
  font-size: 12px;
  color: var(--muted);
  margin: 0;
  max-width: 335px;
}
.modal-head .icon-button {
  width: 29px;
  height: 29px;
  border-color: transparent;
  background: transparent;
}
.modal-head svg {
  width: 17px;
  height: 17px;
}
.form-field {
  margin-bottom: 19px;
}
.form-field label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 8px;
}
.form-field input,
.form-field textarea,
.form-field select {
  font-size: 12px;
}
.form-field input,
.form-field textarea {
  width: 100%;
  min-height: 42px;
  background: white;
  border: 1px solid #d6d3e0;
  border-radius: 7px;
  padding: 11px 12px;
  color: var(--ink);
  resize: vertical;
}
.form-field textarea {
  min-height: 82px;
}
/* Style the native file button without replacing file selection or its label. */
input[type="file"] {
  max-width: 100%;
  min-width: 0;
  min-height: 58px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: var(--paper);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  text-overflow: ellipsis;
  cursor: pointer;
}
input[type="file"]::file-selector-button {
  min-height: 44px;
  max-width: 100%;
  margin: 0 12px 0 0;
  padding: 10px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-control);
  background: var(--violet-light);
  color: var(--violet);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
input[type="file"]:not(:disabled):hover::file-selector-button,
input[type="file"]:focus-visible::file-selector-button {
  border-color: var(--violet);
}
input[type="file"]:not(:disabled):active::file-selector-button {
  background: var(--paper);
}
input[type="file"]:disabled {
  opacity: .6;
  cursor: not-allowed;
}
input[type="file"]:disabled::file-selector-button { cursor: not-allowed; }
@media (forced-colors: active) {
  input[type="file"]::file-selector-button { border-color: ButtonText; }
  input[type="file"]:disabled::file-selector-button { border-color: GrayText; color: GrayText; }
}
.form-field input::placeholder,
.form-field textarea::placeholder {
  color: #a8a4b5;
}
.form-field small {
  font-size: 10px;
  color: #938da5;
  display: block;
  margin-top: 7px;
}
/* Read-only values are shown as text, not as editable fields. The control stays
   for form submission, selection and copy fallbacks. */
.form-field input[readonly],
:root[data-color-scheme="dark"] .form-field input[readonly],
.form-field.value-locked :is(input, select):disabled,
:root[data-color-scheme="dark"] .form-field.value-locked :is(input, select):disabled {
  min-height: 0;
  padding: 2px 0;
  border-color: transparent;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  cursor: text;
}
/* Saved values that are locked read as text: no field chrome, no dropdown arrow, no help line. */
.form-field.value-locked :is(input, select):disabled { opacity: 1; -webkit-text-fill-color: var(--ink); appearance: none; background-image: none; cursor: default; }
.form-field.value-locked select:disabled::picker-icon { display: none; }
.form-field.value-locked small[data-supplier-help] { display: none; }
.form-field textarea[readonly],
:root[data-color-scheme="dark"] .form-field textarea[readonly] {
  border-color: transparent;
  background: #f0eff5;
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.8;
  resize: none;
  cursor: text;
}
:root[data-color-scheme="dark"] .form-field textarea[readonly] { background: #161a21; }
.form-field :is(input, textarea)[readonly]:focus-visible {
  outline: 1px dashed var(--muted);
  outline-offset: 4px;
}
.input-suffix {
  display: flex;
  align-items: center;
  background: #eeecf3;
  border: 1px solid #d6d3e0;
  border-radius: 7px;
  overflow: hidden;
}
.input-suffix input {
  border: none;
  border-radius: 0;
  min-width: 0;
}
.input-suffix > span {
  padding: 0 12px;
  font-size: 11px;
  color: #88819b;
  white-space: nowrap;
}
.input-suffix:focus-within {
  outline: 2px solid var(--violet);
  outline-offset: 3px;
}
.input-suffix input:focus {
  outline: 0;
}
.template-option {
  display: flex;
  gap: 11px;
  border: 1px solid #b6a4e5;
  background: #f4f0fb;
  border-radius: var(--radius-control);
  padding: 14px;
}
.template-option > svg {
  width: 19px;
  height: 19px;
  color: var(--violet);
}
.template-option strong {
  display: block;
  font-size: 11px;
  font-weight: 550;
  color: #77618f;
}
.template-option small {
  font-size: 10px;
  color: #a08db6;
  display: block;
  margin-top: 5px;
  line-height: 1.65;
}
.template-option > span {
  margin-left: auto;
  width: 14px;
  height: 14px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--violet);
  color: white;
  flex-shrink: 0;
}
.template-option > span svg {
  width: 10px;
  height: 10px;
}
.modal-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.modal-actions .button {
  font-size: 11px;
  min-width: 0;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}
.form-error {
  color: #a14141;
  font-size: 11px;
  line-height: 1.6;
  padding: 11px 13px;
  background: #fcedeb;
  border: 1px solid #edd3ce;
  border-radius: 7px;
  margin: 0 0 18px;
}
.form-error:empty {
  display: none;
}
.confirm-description {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.8;
  overflow-wrap: anywhere;
}
.toast-stack {
  position: fixed;
  bottom: 23px;
  right: 24px;
  z-index: 150;
  max-width: calc(100vw - 48px);
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.toast {
  background: #2e2c34;
  color: white;
  border: 1px solid #403c4a;
  padding: 14px 18px;
  border-radius: 10px;
  box-shadow: 0 5px 22px #2221261a;
  font-size: 12px;
  display: flex;
  gap: 10px;
  align-items: center;
  max-width: 450px;
  animation: appear 0.2s ease both;
}
.toast svg {
  width: 16px;
  height: 16px;
  color: #988fb2;
}
.toast.error {
  background: #703c39;
  border-color: #8e5652;
}
.toast.error svg {
  color: #f0b7af;
}
/* Low hosting balance popup (low-credit-warning.js). Sits under the phone
   menu (25/30) and dialogs (100) so it never blocks navigation, and starts
   right of the fixed sidebar (232/210/192 px) until the sidebar folds away. */
#low-credit-root {
  position: fixed;
  left: 256px;
  bottom: 23px;
  z-index: 24;
  max-width: min(480px, calc(100vw - 280px));
}
.low-credit-warning {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 14px 14px 16px;
  border: 1px solid var(--permission-line);
  background: var(--permission-paper);
  color: var(--permission-muted);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-soft), 0 12px 32px -12px rgb(22 19 31 / 30%);
  animation: appear 0.2s ease both;
}
.low-credit-warning.is-suspended {
  color: #9b4141;
  background: #fff4f3;
  border-color: #ecd7d4;
}
.low-credit-icon svg {
  width: 20px;
  height: 20px;
  margin-top: 2px;
}
.low-credit-body {
  flex: 1;
  min-width: 0;
}
.low-credit-body h2 {
  margin: 0 0 2px;
  font-size: 14px;
  line-height: 1.4;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 2px;
}
.low-credit-body p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
}
.low-credit-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  align-self: center;
}
.low-credit-actions .button {
  min-height: 44px;
}
.low-credit-actions .icon-button {
  width: 44px;
  height: 44px;
  color: inherit;
}
:root[data-color-scheme="dark"] .low-credit-warning.is-suspended {
  background: #40272d;
  color: #ffb1ba;
  border-color: #704349;
}
@media (max-width: 1200px) {
  #low-credit-root {
    left: 234px;
  }
}
@media (max-width: 1000px) {
  #low-credit-root {
    left: 216px;
  }
}
@media (max-width: 760px) {
  #low-credit-root {
    left: 16px;
    right: 16px;
    bottom: 16px;
    max-width: none;
  }
  .low-credit-warning {
    flex-wrap: wrap;
  }
  .low-credit-icon {
    display: none;
  }
}
.noscript {
  padding: 25px;
  text-align: center;
}

@media (min-width: 1500px) {
  .workspace-main {
    padding-top: 45px;
  }
  .workspace-hero {
    padding: 33px;
  }
  .workspace-hero h2 {
    font-size: 27px;
  }
  .workspace-hero p {
    font-size: 12px;
  }
  .app-row {
    padding: 24px;
  }
  .checklist-item {
    padding: 22px 0;
  }
}
@media (max-width: 1200px) {
  .app-shell {
    grid-template-columns: 210px minmax(0, 1fr);
  }
  .sidebar {
    width: 210px;
    padding-left: 15px;
    padding-right: 15px;
  }
  .topbar {
    padding: 0 28px;
  }
  .workspace-main {
    padding: 30px 28px;
  }
  .dashboard-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(220px, 1fr);
    gap: 20px;
  }
  .workspace-bottom {
    grid-template-columns: 1.4fr 1fr;
    gap: 20px;
  }
  .stats-grid {
    gap: 10px;
  }
  .stat-card {
    padding: 16px 15px;
  }
  .hero-tiles {
    margin-right: 0;
    min-width: 157px;
    transform: scale(0.88);
    transform-origin: right center;
  }
  .apps-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hero {
    gap: 5%;
    padding-top: 70px;
    padding-bottom: 85px;
  }
  .hero h1 {
    font-size: 57px;
  }
  .hero-copy > p {
    font-size: 14px;
  }
  .site-header {
    padding: 0 6%;
  }
  .landing-main {
    padding: 0 6%;
  }
  .landing-cta {
    padding: 32px;
  }
  .detail-layout {
    grid-template-columns: minmax(0, 1.5fr) minmax(220px, 1fr);
  }
  .guide-grid {
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 22px;
  }
}
@media (max-width: 1000px) {
  .app-shell {
    grid-template-columns: 192px minmax(0, 1fr);
  }
  .sidebar {
    width: 192px;
    padding-left: 12px;
    padding-right: 12px;
  }
  .sidebar .brand {
    font-size: 30px;
    padding-left: 10px;
  }
  .workspace-switch {
    padding: 10px 8px;
  }
  .nav-item {
    padding: 11px 10px;
  }
  .topbar {
    padding: 0 23px;
  }
  .workspace-main {
    padding: 29px 23px;
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .workspace-bottom {
    grid-template-columns: 1fr 1fr;
    gap: 18px;
  }
  .checklist {
    display: flex;
    padding: 0 18px;
    gap: 18px;
  }
  .checklist-item {
    flex: 1;
    padding: 20px 0;
    gap: 9px;
  }
  .checklist-item + .checklist-item {
    border-top: 0;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .workspace-hero {
    padding: 23px;
  }
  .workspace-hero h2 {
    font-size: 21px;
  }
  .hero-tiles {
    min-width: 135px;
    transform: scale(0.73);
    margin-left: -15px;
  }
  .workspace-hero p {
    max-width: 310px;
  }
  .page-heading h1 {
    font-size: 27px;
  }
  .hero h1 {
    font-size: 48px;
    letter-spacing: -2.5px;
  }
  .hero-copy > p {
    font-size: 13px;
  }
  .hero-actions .button {
    padding: 12px 15px;
    font-size: 12px;
  }
  .site-nav {
    gap: 22px;
  }
  .hero {
    padding-top: 60px;
    padding-bottom: 76px;
    gap: 6%;
  }
  .preview-body {
    padding: 19px 15px;
  }
  .preview-top {
    padding: 15px;
  }
  .floating-note {
    right: -3px;
    padding: 13px 14px;
  }
  .feature-card {
    padding: 23px;
  }
  .landing-section .section-head > p {
    max-width: 265px;
    font-size: 12px;
  }
  .landing-section h2 {
    font-size: 29px;
  }
  .wallet-layout,
  .detail-layout {
    grid-template-columns: 1fr;
  }
  /* One column: publishing status leads, so phones see the main action first. */
  .detail-layout[data-app-settings] { display: flex; flex-direction: column; gap: 0; }
  .detail-layout[data-app-settings] > div { display: contents; }
  .detail-layout[data-app-settings] [data-publication-panel] { order: -1; }
  .balance-value {
    margin-top: 19px;
  }
  /* minmax keeps wide tables inside their own scroll area on phones. */
  .guide-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .guide-nav {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px 19px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
  }
  .guide-nav a {
    font-size: 10px;
    padding: 3px 0;
  }
}
@media (max-width: 760px) {
  .site-header {
    height: auto;
    min-height: 82px;
    padding: 16px 6%;
    flex-wrap: wrap;
    gap: 8px 16px;
  }
  .site-header .brand {
    font-size: 30px;
  }
  .site-nav {
    gap: 17px;
  }
  .site-nav > a:not(.button) {
    font-size: 11px;
  }
  .site-nav .button,
  .site-header-action {
    font-size: 11px;
    min-height: 44px;
    padding: 8px 13px;
  }
  .hero {
    grid-template-columns: 1fr;
    gap: 48px;
    padding: 45px 0 57px;
  }
  .hero-copy {
    text-align: center;
  }
  .hero h1 {
    font-size: 55px;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
    letter-spacing: -2.8px;
  }
  .hero-copy > p {
    font-size: 14px;
    max-width: 430px;
    margin-left: auto;
    margin-right: auto;
  }
  .hero-label {
    margin-bottom: 22px;
  }
  .hero-actions {
    justify-content: center;
  }
  .hero-note {
    font-size: 10px !important;
  }
  .hero-visual {
    max-width: 430px;
    width: 100%;
    margin: auto;
    padding-left: 12px;
    padding-right: 12px;
  }
  .visual-grid {
    inset: -17px -5px;
  }
  .preview-top {
    padding: 18px 20px;
  }
  .preview-body {
    padding: 23px 21px;
  }
  .floating-note {
    right: 0;
  }
  .platform-strip {
    grid-template-columns: repeat(2, 1fr);
    padding: 22px 0;
    gap: 22px 10px;
  }
  .platform-strip > div {
    font-size: 11px;
    justify-content: start;
    padding-left: 10px;
  }
  .landing-section {
    padding: 50px 0;
  }
  .landing-section .section-head {
    display: block;
  }
  .landing-section .section-head > p {
    margin-top: 16px;
    max-width: 400px;
  }
  .landing-section h2 {
    font-size: 29px;
  }
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .feature-card {
    padding: 25px;
    display: grid;
    grid-template-columns: 40px 1fr;
    gap: 0 20px;
  }
  .feature-icon {
    grid-row: span 2;
    margin: 0;
  }
  .feature-card h3 {
    margin-bottom: 7px;
  }
  .feature-card p {
    max-width: 400px;
  }
  .landing-cta {
    padding: 29px;
    display: block;
  }
  .landing-cta h2 {
    font-size: 23px;
  }
  .landing-cta p {
    font-size: 12px;
  }
  .landing-cta .button {
    margin-top: 20px;
  }
  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    font-size: 12px;
    gap: 20px;
  }
  .site-footer > div {
    gap: 12px 24px;
    width: 100%;
  }
  .site-footer > div:last-child > a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
  .site-footer > div:last-child > span {
    flex-basis: 100%;
  }
  .site-footer .brand {
    font-size: 23px;
  }
  .app-shell {
    display: block;
  }
  .sidebar {
    width: 240px;
    transform: translateX(-100%);
    transition: transform 0.2s;
  }
  .app-shell.menu-open .sidebar {
    transform: translateX(0);
  }
  .mobile-backdrop {
    position: fixed;
    inset: 0;
    background: #22212660;
    z-index: 25;
    border: 0;
  }
  .app-shell.menu-open .mobile-backdrop {
    display: block;
  }
  .main-shell {
    width: 100%;
  }
  .topbar {
    height: 61px;
    padding: 0 20px;
    gap: 15px;
    justify-content: flex-start;
  }
  .mobile-menu {
    display: inline-flex;
    width: 29px;
    height: 29px;
    background: none;
    border: 0;
    padding: 0;
  }
  .mobile-menu svg {
    width: 19px;
    height: 19px;
  }
  .topbar-actions {
    margin-left: auto;
  }
  .topbar-status {
    display: none;
  }
  .workspace-main {
    padding: 28px 20px;
  }
  .page-heading h1 {
    font-size: 27px;
  }
  .page-heading p {
    font-size: 11px;
    max-width: 280px;
  }
  .page-heading {
    gap: 15px;
    margin-bottom: 25px;
  }
  .page-heading > .button {
    font-size: 10px;
    padding: 10px 12px;
  }
  .workspace-hero {
    padding: 23px;
  }
  .workspace-hero h2 {
    font-size: 22px;
    max-width: 320px;
  }
  .workspace-hero p {
    font-size: 11px;
    max-width: 330px;
  }
  .hero-tiles {
    transform: scale(0.9);
    min-width: 170px;
  }
  .stats-grid {
    gap: 12px;
  }
  .stat-card {
    padding: 19px;
  }
  .stat-top {
    font-size: 10px;
    margin-bottom: 15px;
  }
  .stat-value {
    font-size: 27px;
  }
  .stat-foot {
    font-size: 9px;
  }
  .dashboard-grid {
    gap: 27px;
  }
  .apps-grid {
    gap: 13px;
  }
  .app-card {
    padding: 18px;
  }
  .app-card p {
    font-size: 11px;
  }
  .guide-article .content-panel {
    padding: 23px;
  }
  .wallet-layout {
    gap: 20px;
  }
  .detail-title {
    gap: 11px;
  }
  .detail-title h1 {
    font-size: 24px;
  }
  .detail-title .app-symbol {
    width: 43px;
    height: 43px;
  }
  .detail-page-heading {
    align-items: flex-start;
    flex-direction: column;
  }
  .storage-grid {
    grid-template-columns: 1fr;
  }
  .workspace-footer {
    font-size: 9px;
  }
  .public-guide {
    margin-top: 25px;
    padding: 0 6%;
  }
}
@media (max-width: 480px) {
  .site-header:has(.site-header-action) {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 16px;
  }
  .site-header .brand { font-size: clamp(22px, 6.67vw, 26px); }
  .site-header-action { grid-column: 2; grid-row: 1; }
  .site-header:has(.site-header-action) .site-nav {
    grid-column: 1 / -1;
    margin-left: 0;
    gap: 12px 24px;
  }
  .site-nav > a:not(.button) {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 13px;
  }
  .hero {
    padding-top: 32px;
    gap: 38px;
  }
  .hero h1 {
    font-size: 46px;
    letter-spacing: -2.6px;
  }
  .hero-copy > p {
    font-size: 13px;
  }
  .site-nav {
    gap: 8px;
  }
  .hero-visual {
    padding: 8px 7px 25px;
  }
  .workspace-preview {
    transform: rotate(-1.5deg);
  }
  .hero-actions {
    gap: 9px;
  }
  .hero-actions .button {
    padding: 12px 15px;
  }
  .floating-note {
    padding: 12px 14px;
    right: 0;
    bottom: 0;
  }
  .landing-cta {
    padding: 25px;
  }
  .site-footer > div:last-child {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .site-footer .footer-tagline {
    display: none;
  }
  .workspace-main {
    padding: 25px 17px;
  }
  .topbar {
    padding: 0 17px;
    gap: 10px;
  }
  .page-heading h1 {
    font-size: 25px;
    letter-spacing: -0.9px;
  }
  .page-heading p {
    font-size: 12px;
    max-width: none;
  }
  .page-heading > .button {
    font-size: 10px;
    padding: 9px 10px;
    min-height: 44px;
    gap: 4px;
  }
  .page-heading > .button svg {
    width: 13px;
    height: 13px;
  }
  .creator-links {
    gap: 8px 24px;
  }
  .creator-links > a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 13px;
  }
  .creator-links > .button {
    min-height: 44px;
    font-size: 12px;
  }
  .workspace-hero {
    padding: 23px 22px;
  }
  .workspace-hero h2 {
    font-size: 24px;
    max-width: 280px;
  }
  .workspace-hero p {
    max-width: 265px;
    font-size: 11px;
  }
  .hero-tiles {
    display: none;
  }
  .workspace-hero .eyebrow {
    font-size: 8px;
  }
  .workspace-hero .button {
    margin-top: 2px;
  }
  .stats-grid {
    gap: 10px;
    margin-bottom: 28px;
  }
  .stat-card {
    padding: 17px;
  }
  .stat-top {
    font-size: 9px;
  }
  .stat-value {
    font-size: 25px;
  }
  .stat-foot {
    font-size: 8px;
  }
  .app-row {
    padding: 17px;
  }
  .app-row .badge {
    font-size: 8px;
    padding: 4px 6px;
  }
  .app-row-text strong {
    font-size: 11px;
  }
  .app-row-text small {
    font-size: 8px;
  }
  .checklist {
    display: block;
    padding: 0 19px;
  }
  .checklist-item {
    padding: 18px 0;
    gap: 12px;
  }
  .checklist-item + .checklist-item {
    border-top: 1px solid #e5e3ec;
  }
  .checklist-item strong {
    font-size: 11px;
  }
  .checklist-item p {
    font-size: 10px;
  }
  .workspace-bottom {
    grid-template-columns: 1fr;
    gap: 13px;
  }
  .resource-card {
    padding: 18px;
  }
  .apps-grid {
    grid-template-columns: 1fr;
  }
  .app-card {
    padding: 23px;
  }
  .card-create {
    min-height: 170px;
  }
  .app-card h3 {
    font-size: 15px;
  }
  .app-card p {
    min-height: 0;
  }
  .content-panel {
    padding: 22px;
  }
  .wallet-layout .content-panel {
    padding: 23px;
  }
  .topup-options {
    gap: 8px;
  }
  .topup-choice {
    padding: 15px 6px;
  }
  .topup-choice strong {
    font-size: 19px;
  }
  .topup-choice small {
    font-size: 8px;
  }
  .modal-backdrop {
    padding: 14px;
  }
  .modal {
    padding: 24px;
    max-height: calc(100dvh - 28px);
  }
  .modal-head h2 {
    font-size: 21px;
  }
  .modal-head p {
    font-size: 11px;
  }
  .input-suffix > span {
    padding: 0 9px;
    font-size: 10px;
  }
  .modal-actions .button {
    font-size: 11px;
    padding: 10px 12px;
    min-height: 44px;
  }
  .modal-actions > .button {
    flex: 1 1 100%;
  }
  .notice {
    font-size: 11px;
    padding: 13px;
  }
  .notice .button {
    font-size: 10px;
    padding: 6px 8px;
  }
  .workspace-footer > div {
    gap: 11px;
  }
  .code-block {
    padding: 15px;
    font-size: 10px;
  }
  .guide-article .content-panel {
    padding: 21px;
  }
  .table-wrap table {
    font-size: 10px;
  }
  th,
  td {
    padding: 14px 16px;
  }
  .toast-stack {
    bottom: 14px;
    right: 14px;
    max-width: calc(100vw - 28px);
  }
  .toast {
    font-size: 11px;
    padding: 13px 16px;
  }
  .sign-in-panel {
    padding: 30px;
    margin-top: 35px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* Keep secondary copy readable and long addresses contained. */
.page-heading p,
.stat-top,
.stat-foot,
.workspace-footer,
.app-row-text small,
.app-card p,
.app-card-bottom,
.checklist-item p,
.resource-card p,
.user-details small,
.nav-label,
.fine-print,
.form-field small,
.transaction-row small,
.event-row small {
  color: #706b7d !important;
}
.workspace-hero p,
.balance-card > p,
.topup-choice small {
  color: #80718f;
}
.balance-info {
  color: var(--muted);
}
.credit-mini-top,
.credit-mini strong small,
.guide-nav a,
.filter-bar .eyebrow {
  color: #716c7f;
}
.app-card,
.detail-title,
.detail-title > div,
.storage-card,
.content-panel {
  min-width: 0;
}
.detail-title h1,
.app-card h3 {
  overflow-wrap: anywhere;
}
@media (max-width: 480px) {
  .filter-bar:has(#storage-app) {
    flex-wrap: wrap;
    gap: 10px;
  }
  .filter-bar #storage-app {
    flex: 1;
    min-width: 0;
    max-width: calc(100% - 40px);
  }
  .filter-bar:has(#storage-app) .badge {
    margin-left: 0;
  }
  .filter-bar:has(#storage-app) [data-action="upload"] {
    margin-left: auto;
  }
  .sidebar {
    overflow-y: auto;
  }
  .sidebar-bottom {
    padding-top: 25px;
  }
}

/* Account panels share one width, including profile, preferences and tester ID. */
.profile-panel,
.appearance-panel,
.app-user-id-panel {
  max-width: 760px;
}
.form-field small:empty { display: none; }
.appearance-panel .form-field {
  margin-top: 25px;
}
.form-field select {
  display: block;
  max-width: 100%;
  min-width: 0;
  min-height: 44px;
  width: 320px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-control);
  background: var(--paper);
  color: var(--ink);
}
/* Keep the real select's semantics, validation and keyboard behavior. Browsers
   without customizable selects retain their native picker. */
select:enabled { cursor: pointer; }
select:disabled { cursor: not-allowed; opacity: .6; }
@supports (appearance: base-select) {
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]),
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"])::picker(select) {
    appearance: base-select;
  }
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) {
    display: flex;
    align-items: center;
    gap: 12px;
    line-height: 1.5;
    text-align: start;
    overflow-wrap: anywhere;
  }
  select::picker-icon {
    content: "";
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    margin-inline: auto 3px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    color: var(--muted);
    transform: translateY(-2px) rotate(45deg);
  }
  select:open::picker-icon {
    color: var(--violet);
    transform: translateY(2px) rotate(225deg);
  }
  select::picker(select) {
    box-sizing: border-box;
    inline-size: anchor-size(self-inline);
    max-inline-size: calc(100vw - 16px);
    max-block-size: min(320px, 60dvh);
    margin-block: 6px;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--paper);
    color: var(--ink);
    box-shadow: 0 12px 32px rgb(0 0 0 / .14), 0 2px 6px rgb(0 0 0 / .06);
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
  }
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) option {
    display: flex;
    align-items: center;
    gap: 12px;
    min-block-size: 44px;
    padding: 10px 12px;
    border-radius: var(--radius-control);
    font: inherit;
    font-weight: 400;
    color: var(--ink);
    line-height: 1.5;
    white-space: normal;
    overflow-wrap: anywhere;
    cursor: pointer;
  }
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) option:checked {
    background: var(--violet-light);
    color: var(--violet);
    font-weight: 600;
  }
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) option:not(:disabled):is(:hover, :focus-visible) {
    background: var(--violet-light);
    color: var(--violet);
    outline: 1px solid var(--violet);
    outline-offset: -1px;
  }
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) option:disabled { color: var(--muted); cursor: not-allowed; }
  select option::checkmark { order: 1; margin-inline-start: auto; color: var(--violet); }
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) optgroup { padding: 4px; color: var(--muted); }
  @media (forced-colors: active) {
    select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) option:checked { background: Highlight; color: HighlightText; }
    select option::checkmark { color: inherit; }
    select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) option:not(:disabled):is(:hover, :focus-visible) { outline-color: Highlight; }
  }
}
:root[data-color-scheme="dark"] .button,
:root[data-color-scheme="dark"] .icon-button,
:root[data-color-scheme="dark"] .panel,
:root[data-color-scheme="dark"] .workspace-preview,
:root[data-color-scheme="dark"] .feature-card,
:root[data-color-scheme="dark"] .stat-card,
:root[data-color-scheme="dark"] .app-list-panel,
:root[data-color-scheme="dark"] .checklist,
:root[data-color-scheme="dark"] .app-card,
:root[data-color-scheme="dark"] .table-wrap,
:root[data-color-scheme="dark"] .modal,
:root[data-color-scheme="dark"] .topup-choice,
:root[data-color-scheme="dark"] .search-field input,
:root[data-color-scheme="dark"] .form-field input,
:root[data-color-scheme="dark"] .form-field textarea,
:root[data-color-scheme="dark"] .form-field select {
  background: var(--paper);
  border-color: var(--line);
}
:root[data-color-scheme="dark"] .sidebar,
:root[data-color-scheme="dark"] .topbar {
  background: #15111f;
}
:root[data-color-scheme="dark"] .button:hover:not(:disabled),
:root[data-color-scheme="dark"] .button.ghost:hover:not(:disabled),
:root[data-color-scheme="dark"] .nav-item:hover,
:root[data-color-scheme="dark"] .app-row:hover,
:root[data-color-scheme="dark"] .card-create:hover {
  background: #2a2340;
  color: var(--ink);
}
:root[data-color-scheme="dark"] .button.primary,
:root[data-color-scheme="dark"] .button.primary:hover:not(:disabled) {
  background: linear-gradient(120deg, #6c47ff 0%, #a23be8 100%);
  border-color: transparent;
  color: #fff;
}
:root[data-color-scheme="dark"] .button.dark,
:root[data-color-scheme="dark"] .button.dark:hover:not(:disabled) {
  background: #e5e2ef;
  color: #22202b;
  border-color: #e5e2ef;
}
:root[data-color-scheme="dark"] .button.ghost {
  background: transparent;
  border-color: transparent;
}
:root[data-color-scheme="dark"] .button.danger,
:root[data-color-scheme="dark"] .danger-zone h2 {
  color: #ffadb3;
  border-color: #704349;
}
:root[data-color-scheme="dark"] .badge,
:root[data-color-scheme="dark"] .empty-symbol,
:root[data-color-scheme="dark"] .feature-icon,
:root[data-color-scheme="dark"] .credit-mini,
:root[data-color-scheme="dark"] .resource-card,
:root[data-color-scheme="dark"] .card-create > span,
:root[data-color-scheme="dark"] .step-indicator,
:root[data-color-scheme="dark"] .transaction-icon,
:root[data-color-scheme="dark"] .event-icon,
:root[data-color-scheme="dark"] .input-suffix,
:root[data-color-scheme="dark"] th,
:root[data-color-scheme="dark"] .guide-article code:not(.code-block),
:root[data-color-scheme="dark"] .preview-bottom {
  background: #241e33;
  color: var(--muted);
  border-color: var(--line);
}
:root[data-color-scheme="dark"] .badge.green,
:root[data-color-scheme="dark"] .app-symbol.green,
:root[data-color-scheme="dark"] .step-indicator.complete,
:root[data-color-scheme="dark"] .user-avatar {
  background: var(--green-light);
  color: var(--green);
  border-color: #365747;
}
:root[data-color-scheme="dark"] .badge.amber,
:root[data-color-scheme="dark"] .settings-diff,
:root[data-color-scheme="dark"] .notice {
  background: #2c2936;
  color: #efca80;
  border-color: #463f5b;
}
:root[data-color-scheme="dark"] .badge.red,
:root[data-color-scheme="dark"] .notice.error,
:root[data-color-scheme="dark"] .form-error {
  background: #40272d;
  color: #ffb1ba;
  border-color: #704349;
}
:root[data-color-scheme="dark"] .notice.info,
:root[data-color-scheme="dark"] .app-symbol,
:root[data-color-scheme="dark"] .workspace-avatar,
:root[data-color-scheme="dark"] .hero-label,
:root[data-color-scheme="dark"] .floating-note,
:root[data-color-scheme="dark"] .landing-cta,
:root[data-color-scheme="dark"] .workspace-hero,
:root[data-color-scheme="dark"] .balance-card,
:root[data-color-scheme="dark"] .template-option,
:root[data-color-scheme="dark"] .topup-choice.selected,
:root[data-color-scheme="dark"] .nav-item.active {
  background: var(--violet-light);
  color: var(--ink);
  border-color: #4b4065;
}
:root[data-color-scheme="dark"] .nav-item.active,
:root[data-color-scheme="dark"] .topup-choice.selected,
:root[data-color-scheme="dark"] .workspace-avatar,
:root[data-color-scheme="dark"] .app-symbol {
  color: var(--violet);
}
:root[data-color-scheme="dark"] .nav-item .nav-count,
:root[data-color-scheme="dark"] .floating-note .note-icon {
  background: #483961;
  color: #dccaff;
}
:root[data-color-scheme="dark"] .app-symbol.peach {
  background: #43332b;
  color: #edbd9b;
}
:root[data-color-scheme="dark"] .hero-tile,
:root[data-color-scheme="dark"] .hero-tile:nth-child(1),
:root[data-color-scheme="dark"] .hero-tile:nth-child(2),
:root[data-color-scheme="dark"] .hero-tile:nth-child(3) {
  background: #3c324e;
  border-color: #615076;
  color: #d6b8ff;
}
:root[data-color-scheme="dark"] .resource-card .resource-icon,
:root[data-color-scheme="dark"] .storage-card > .feature-icon {
  background: #354137;
  color: #b4cc9b;
}
:root[data-color-scheme="dark"] .code-block {
  background: #161a21;
  border-color: var(--line);
  color: #c2bdd1;
}
:root[data-color-scheme="dark"] .card-create,
:root[data-color-scheme="dark"] .key-value + .key-value,
:root[data-color-scheme="dark"] .transaction-row + .transaction-row,
:root[data-color-scheme="dark"] .event-row + .event-row,
:root[data-color-scheme="dark"] .app-row + .app-row,
:root[data-color-scheme="dark"] .checklist-item + .checklist-item,
:root[data-color-scheme="dark"] .preview-top,
:root[data-color-scheme="dark"] .preview-bottom,
:root[data-color-scheme="dark"] .credit-mini .text-link,
:root[data-color-scheme="dark"] .balance-info {
  border-color: var(--line);
}
:root[data-color-scheme="dark"] .site-nav > a:not(.button),
:root[data-color-scheme="dark"] .hero-copy > p,
:root[data-color-scheme="dark"] .hero-note,
:root[data-color-scheme="dark"] .preview-label,
:root[data-color-scheme="dark"] .preview-app-text span,
:root[data-color-scheme="dark"] .preview-bottom svg,
:root[data-color-scheme="dark"] .floating-note small,
:root[data-color-scheme="dark"] .platform-strip > div,
:root[data-color-scheme="dark"] .platform-strip svg,
:root[data-color-scheme="dark"] .landing-cta p,
:root[data-color-scheme="dark"] .workspace-switch small,
:root[data-color-scheme="dark"] .nav-item,
:root[data-color-scheme="dark"] .breadcrumb,
:root[data-color-scheme="dark"] .breadcrumb > span:last-child,
:root[data-color-scheme="dark"] .topbar-actions,
:root[data-color-scheme="dark"] .topbar-actions .text-link,
:root[data-color-scheme="dark"] .workspace-hero .eyebrow,
:root[data-color-scheme="dark"] .stat-top svg,
:root[data-color-scheme="dark"] .workspace-main .section-head .text-link,
:root[data-color-scheme="dark"] .app-row > svg,
:root[data-color-scheme="dark"] .resource-card > svg,
:root[data-color-scheme="dark"] .card-create,
:root[data-color-scheme="dark"] .search-field svg,
:root[data-color-scheme="dark"] .balance-card .eyebrow,
:root[data-color-scheme="dark"] .balance-value small,
:root[data-color-scheme="dark"] .input-suffix > span,
:root[data-color-scheme="dark"] .template-option small,
:root[data-color-scheme="dark"] .template-option strong {
  color: var(--muted);
}
:root[data-color-scheme="dark"] .page-heading p,
:root[data-color-scheme="dark"] .stat-top,
:root[data-color-scheme="dark"] .stat-foot,
:root[data-color-scheme="dark"] .workspace-footer,
:root[data-color-scheme="dark"] .app-row-text small,
:root[data-color-scheme="dark"] .app-card p,
:root[data-color-scheme="dark"] .app-card-bottom,
:root[data-color-scheme="dark"] .checklist-item p,
:root[data-color-scheme="dark"] .resource-card p,
:root[data-color-scheme="dark"] .user-details small,
:root[data-color-scheme="dark"] .nav-label,
:root[data-color-scheme="dark"] .fine-print,
:root[data-color-scheme="dark"] .form-field small,
:root[data-color-scheme="dark"] .transaction-row small,
:root[data-color-scheme="dark"] .event-row small {
  color: var(--muted) !important;
}
:root[data-color-scheme="dark"] .workspace-hero p,
:root[data-color-scheme="dark"] .balance-card > p,
:root[data-color-scheme="dark"] .balance-info,
:root[data-color-scheme="dark"] .topup-choice small,
:root[data-color-scheme="dark"] .credit-mini-top,
:root[data-color-scheme="dark"] .credit-mini strong small,
:root[data-color-scheme="dark"] .guide-nav a,
:root[data-color-scheme="dark"] .filter-bar .eyebrow {
  color: var(--muted);
}
:root[data-color-scheme="dark"] .form-field input::placeholder,
:root[data-color-scheme="dark"] .form-field textarea::placeholder {
  color: #929aab;
}
:root[data-color-scheme="dark"] .user-row .icon-button,
:root[data-color-scheme="dark"] .modal-head .icon-button,
:root[data-color-scheme="dark"] .mobile-menu {
  background: transparent;
}

/* App shell: platform navigation surrounds the app's separate document. */
.runtime-shell { height: 100vh; height: 100dvh; overflow: hidden; }
/* The tenant host already reserves all device insets around embedded shells. */
.runtime-shell.runtime-embedded { --runtime-safe-top: 0px; --runtime-safe-bottom: 0px; }
.runtime-surface { position: relative; height: 100%; display: grid; grid-template-columns: minmax(0, 1fr); }
.runtime-header { position: absolute; left: 0; top: 50%; transform: translateY(-50%); display: flex; align-items: center; justify-content: center; background: transparent; pointer-events: none; z-index: 1; }
/* Desktop edge handle: a small brand-gradient tab with the S mark that slides out a little on hover. */
:root .runtime-menu-button.button { position: relative; isolation: isolate; width: 26px; min-width: 26px; height: 52px; min-height: 52px; padding: 0; border: 0; border-radius: 0 14px 14px 0; color: #fff; background: transparent; pointer-events: auto; overflow: visible; transition: width .18s ease, transform .12s ease; }
:root .runtime-menu-button.button:hover:not(:disabled) { background: transparent; color: #fff; }
.runtime-menu-button::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, #7b5cff 0%, #ff4fd8 60%, #ffa53d 100%); border-radius: inherit; box-shadow: 0 4px 14px rgba(108, 71, 255, .32), inset -1px 0 0 rgba(255, 255, 255, .28); transition: box-shadow .18s ease, filter .18s ease; }
/* Invisible extra touch area so a fingertip finds the handle without it covering more app. */
.runtime-menu-button::after { content: ""; position: absolute; top: -6px; bottom: -6px; left: 0; width: 44px; }
:root .runtime-menu-button.button:is(:hover, :focus-visible) { width: 34px; }
.runtime-menu-button:is(:hover, :focus-visible)::before { box-shadow: 0 6px 20px rgba(108, 71, 255, .45), inset -1px 0 0 rgba(255, 255, 255, .35); filter: saturate(1.15) brightness(1.05); }
:root .runtime-menu-button.button:active:not(:disabled) { transform: scale(.94); transform-origin: left center; }
:root .runtime-menu-button.button:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }
:root[data-color-scheme="dark"] .runtime-menu-button::before { box-shadow: 0 4px 16px rgba(0, 0, 0, .5), inset -1px 0 0 rgba(255, 255, 255, .22); }
.runtime-menu-button>span,.runtime-app-name,.runtime-brand { display: none; }
.runtime-menu-button>.runtime-desktop-icon { display: block; width: 18px; height: 18px; flex-shrink: 0; filter: drop-shadow(0 1px 1px rgba(22, 19, 31, .25)); }
@media (prefers-reduced-motion: reduce) { :root .runtime-menu-button.button, .runtime-menu-button::before { transition: none; } }
.runtime-menu-button>.runtime-mobile-icon { display: none; }
.runtime-stage { position: relative; min-width: 0; min-height: 0; height: 100%; }
.runtime-frame { width: 100%; height: 100%; border: 0; display: block; background: var(--base); }
.runtime-opening { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; padding: 60px 40px; color: var(--muted); }
.runtime-stage>.runtime-opening:has(+iframe) { position: absolute; inset: 0; pointer-events: none; }
.runtime-recovery { position: absolute; bottom: 16px; right: 16px; display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: var(--paper); border: 1px solid var(--line); border-radius: 12px; font-size: 12px; }
:is(.runtime-dialog-root, .runtime-docked-menu) .modal-backdrop { padding: 0; display: block; }
:is(.runtime-dialog-root, .runtime-docked-menu) .modal,.runtime-docked-menu { display: flex; flex-direction: column; gap: 18px; width: 336px; max-width: calc(100vw - 24px); height: 100vh; height: 100dvh; max-height: 100dvh; padding: max(24px, var(--runtime-safe-top, env(safe-area-inset-top, 0px))) 22px max(20px, var(--runtime-safe-bottom, env(safe-area-inset-bottom, 0px))); border-radius: 0 18px 18px 0; overflow: hidden; }
:is(.runtime-dialog-root, .runtime-docked-menu) .modal-head { margin: 0; flex-shrink: 0; }
:is(.runtime-dialog-root, .runtime-docked-menu) .modal-head h2 { margin: 8px 0 0; }
:is(.runtime-dialog-root, .runtime-docked-menu) .icon-button,:is(.runtime-dialog-root, .runtime-docked-menu) .nav-item { min-height: 44px; }
:is(.runtime-dialog-root, .runtime-docked-menu) .icon-button { min-width: 44px; }
:is(.runtime-dialog-root, .runtime-docked-menu) .nav-item { width: 100%; border: 0; background: transparent; text-align: left; }
:is(.runtime-dialog-root, .runtime-docked-menu) .nav-item.active { background: var(--violet-light); color: var(--violet); }
:is(.runtime-dialog-root, .runtime-docked-menu) .nav-item:hover { background: var(--base); }
.runtime-app-nav { flex-shrink: 0; max-height: 27dvh; overflow-y: auto; }
.runtime-os-nav { border-top: 1px solid var(--line); padding-top: 18px; flex: 1; min-height: 60px; overflow-y: auto; }
.runtime-os-nav>.brand { display: flex; width: fit-content; font-size: 24px; margin: 0 12px 16px; }
.runtime-credit { flex-shrink: 0; margin: 0; }
.runtime-credit>small { display: block; margin-top: 10px; font-size: 10px; color: var(--muted); }
.runtime-credit button.text-link { border: 0; padding: 6px 0; background: transparent; }
.runtime-menu-footer { display: flex; flex-wrap: wrap; justify-content: center; column-gap: 16px; flex-shrink: 0; margin-top: -10px; }
.runtime-menu-footer button.text-link { min-height: 44px; border: 0; padding: 0 4px; background: transparent; color: var(--muted); font-size: 12px; font-weight: 400; }
.runtime-menu-footer button.text-link:hover { color: var(--violet); }
.runtime-app-info { min-height: 0; overflow-y: auto; overflow-wrap: anywhere; }
.runtime-app-info h3 { margin: 0 0 8px; font-size: 16px; }
.runtime-app-info ul { margin: 12px 0 0; padding-left: 20px; }
.runtime-app-info li { margin: 6px 0; }
:is(.runtime-dialog-root, .runtime-docked-menu) [data-wallet-content] { min-height: 0; overflow-y: auto; }
.runtime-wallet { margin: 16px 0 24px; padding: 24px; }
.runtime-wallet .balance-value { font-size: 40px; }
.runtime-wallet .balance-value small { font-size: 14px; }
.runtime-transaction { display: flex; justify-content: space-between; gap: 14px; border-bottom: 1px solid var(--line); padding: 14px 0; font-size: 12px; }
.runtime-transaction strong { white-space: nowrap; }
:is(.runtime-dialog-root, .runtime-docked-menu) [data-wallet-content]>.button { margin-top: 24px; }
:is(.runtime-dialog-root, .runtime-docked-menu) [data-wallet-content]>.fine-print { margin-top: 12px; }
@media (max-width: 760px) {
  .runtime-surface { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .runtime-header { position: static; transform: none; min-height: 60px; justify-content: flex-start; gap: 12px; padding: var(--runtime-safe-top, env(safe-area-inset-top, 0px)) 12px 0; background: var(--paper); border-bottom: 1px solid var(--line); pointer-events: auto; }
  :root .runtime-menu-button.button { width: auto; min-width: 44px; height: auto; min-height: 44px; border-radius: 8px; padding: 10px 12px; border: 1px solid var(--line); color: var(--violet); background: var(--violet-light); transform: none; }
  :root .runtime-menu-button.button:is(:hover, :focus-visible) { width: auto; }
  :root .runtime-menu-button.button:hover:not(:disabled) { color: var(--violet); background: var(--violet-light); }
  .runtime-menu-button::before,.runtime-menu-button::after,.runtime-menu-button>.runtime-desktop-icon { display: none; }
  .runtime-menu-button>.runtime-mobile-icon { display: block; }
  .runtime-menu-button>span,.runtime-app-name { display: inline; }
  .runtime-app-name { font-size: 14px; font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .runtime-brand.brand { display: inline; font-size: 18px; letter-spacing: -.7px; margin-left: auto; flex-shrink: 0; }
  .runtime-opening { padding: 32px 22px; }
}
@media (max-height: 600px) {
  :is(.runtime-dialog-root, .runtime-docked-menu) .modal,.runtime-docked-menu { overflow-y: auto; }
  .runtime-os-nav { flex: none; overflow: visible; }
  .runtime-app-nav { max-height: none; }
}
.runtime-preview-label { height: 28px; display: flex; align-items: center; justify-content: center; padding: 0 8px; background: var(--violet-light); color: var(--violet); font-size: 11px; white-space: nowrap; }
.runtime-preview .runtime-surface { height: calc(100% - 28px); }
.runtime-pinned { grid-template-columns: 288px minmax(0, 1fr); }
.runtime-pinned>.runtime-header { display: none; }
.runtime-docked-menu { width: 288px; max-width: none; height: 100%; max-height: 100%; padding: 22px 18px; border-right: 1px solid var(--line); border-radius: 0; background: var(--paper); }
.runtime-docked-menu[hidden] { display: none; }
.runtime-docked-menu .modal-head h2 { font-size: 20px; }
.runtime-docked-menu .runtime-wallet { padding: 18px; }
.runtime-docked-menu .balance-value { font-size: 32px; }
.runtime-menu-preference { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.runtime-menu-preference:has(small:empty):not(:has(button)) { display: none; }
.runtime-menu-preference small { font-size: 11px; color: var(--muted); }
:root .button.runtime-pin-toggle[aria-pressed="true"], :root .button.runtime-pin-toggle[aria-pressed="true"]:hover:not(:disabled) { color: var(--violet); background: var(--violet-light); border-color: var(--violet); }
.runtime-pin-toggle[aria-pressed="true"] svg { transform: rotate(-45deg); }
.app-menu-choice { display: flex; align-items: center; gap: 12px; min-height: 44px; cursor: pointer; margin-bottom: 12px; }
.app-menu-choice input { width: 20px; height: 20px; accent-color: var(--violet); flex-shrink: 0; }
[data-menu-retry][hidden] { display: none; }
/* Account profile layouts reuse the shared forms, panels, buttons and colors. */
.profile-panel { margin-bottom: 24px; }
.profile-onboarding { max-width: 840px; }
.profile-username-row, .profile-avatar-row { display: flex; align-items: center; gap: 16px; }
.profile-username-row input { min-width: 0; flex: 1; }
.user-id-field { min-width: 0; }
.user-id-field .button { min-height: 44px; flex: none; }
/* The ID is a fixed value: show it as wrapped monospace text beside Copy ID, not as a field. */
.user-id-field > label { display: inline-block; }
.user-id-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 4px; }
.form-field.user-id-field textarea[readonly],
:root[data-color-scheme="dark"] .form-field.user-id-field textarea[readonly] { flex: 1 1 220px; min-width: 0; min-height: 0; padding: 2px 0; background: transparent; font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; field-sizing: content; margin-top: 0 !important; }
.profile-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.profile-fields .form-field { min-width: 0; }
.profile-fields input, .profile-fields select { width: 100%; min-width: 0; }
.profile-avatar-form { border-top: 1px solid var(--line); margin-top: 28px; padding-top: 24px; }
.profile-avatar-row .form-field { min-width: 0; flex: 1; }
.profile-avatar { display: flex; align-items: center; justify-content: center; width: 96px; height: 96px; flex-shrink: 0; border-radius: 50%; overflow: hidden; background: var(--violet-light); color: var(--violet); font-weight: 700; }
.profile-avatar img, .user-avatar img, .workspace-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.profile-panel input[type="file"] { max-width: 100%; }
@media (max-width: 760px) {
  .profile-fields { grid-template-columns: 1fr; gap: 0; }
  .profile-username-row { align-items: stretch; flex-direction: column; gap: 8px; }
  .profile-avatar-row { align-items: flex-start; flex-direction: column; }
}
/* Consumer showroom and the separate developer entry, using the shared kit. */
.showroom-apps { padding: 20px 0 52px; scroll-margin-top: 24px; }
.showroom .landing-cta { flex-wrap: wrap; }
.showroom .app-card .mono { overflow-wrap: anywhere; }
.consumer-account { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 32px; }
.consumer-account h2 { margin: 12px 0 4px; overflow-wrap: anywhere; }
.consumer-account small { font-size: 16px; color: var(--muted); }
.developer-onboarding { max-width: 900px; }
.developer-document { max-height: 440px; overflow: auto; overscroll-behavior: contain; border: 1px solid var(--line); border-radius: 11px; padding: 24px; margin: 20px 0; background: var(--base); }
.developer-document section + section { margin-top: 24px; }
.developer-document h2 { font-size: 18px; }
.developer-document p { margin: 12px 0; }
.developer-choice { display: flex; align-items: flex-start; gap: 12px; margin: 14px 0; cursor: pointer; font-size: 14px; line-height: 1.55; }
.developer-choice input { flex: 0 0 auto; width: 18px; height: 18px; margin-top: 2px; accent-color: var(--violet); }
.realtime-settings .button, #realtime-form .developer-choice { min-height: 44px; }
#realtime-form .developer-choice { align-items: center; }
#realtime-form .modal-actions { flex-wrap: wrap; }
.modal:has(.developer-agreements, .hosting-review) { padding: 0; overflow: hidden; }
.developer-agreements, .hosting-review { display: flex; flex-direction: column; max-height: calc(100dvh - 50px); min-height: 0; }
.agreement-header { flex: none; padding: 24px 28px 20px; border-bottom: 1px solid var(--line); }
.agreement-header h2 { font-size: 24px; margin: 6px 0; line-height: 1.3; }
.agreement-header h2:focus { outline: none; }
.agreement-header p { font-size: 13px; color: var(--muted); margin: 0; }
.agreement-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 4px 28px 20px; overflow-wrap: anywhere; }
.agreement-section { padding: 20px 0 4px; border-bottom: 1px solid var(--line); }
.agreement-section h3 { font-size: 17px; margin: 0 0 4px; }
.agreement-section .content-panel { padding: 0; border: 0; background: transparent; box-shadow: none; }
.agreement-document { margin: 16px 0; }
.agreement-document summary { cursor: pointer; color: var(--violet); font-weight: 600; min-height: 44px; display: list-item; align-content: center; }
.agreement-copy { padding: 0 0 8px; font-size: 14px; line-height: 1.7; }
.agreement-copy h2 { font-size: 17px; }
.agreement-copy p, .hosting-review .agreement-scroll > p { font-size: 14px; line-height: 1.7; margin: 16px 0; }
.developer-agreements .developer-choice { min-height: 44px; font-size: 13px; line-height: 1.6; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.developer-agreements .developer-choice input { margin-top: 2px; }
.agreement-footer { flex: none; padding: 16px 28px 20px; border-top: 1px solid var(--line); background: var(--paper); }
.agreement-footer > p { margin: 0 0 10px; }
.agreement-footer .modal-actions { margin: 0; border: 0; padding: 0; }
@media (max-width: 480px) {
  .modal:has(.developer-agreements, .hosting-review) { max-height: calc(100dvh - 24px); }
  .developer-agreements, .hosting-review { max-height: calc(100dvh - 26px); }
  .agreement-header { padding: 18px 18px 14px; }
  .agreement-header h2 { font-size: 21px; }
  .agreement-scroll { padding: 0 18px 16px; }
  .agreement-footer { padding: 12px 18px 16px; }
}
/* Platform-owned permission review and app-scoped permission management. */
.permissions-page { max-width: 1050px; }
.permission-app, .permission-devices { margin-bottom: 24px; }
.permission-app h2, .permission-developer p, .permission-origin { overflow-wrap: anywhere; }
.permission-row { padding: 24px 0; border-top: 1px solid var(--line); }
.permission-row:last-child { padding-bottom: 0; }
.permission-row-heading, .permission-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.permission-row-heading h3 { margin: 0; }
.permission-row p { margin: 12px 0; }
.permission-facts { display: flex; gap: 24px; flex-wrap: wrap; margin: 20px 0; }
.permission-filter { max-width: 360px; margin-bottom: 20px; }
.permissions-table { width: 100%; font-size: 13px; }
.permissions-table th, .permissions-table td { padding: 12px 16px; vertical-align: top; text-align: left; }
.permissions-table .permission-date { white-space: nowrap; color: var(--muted); }
.permissions-table td:last-child { width: 1%; white-space: nowrap; }
.permission-info { min-width: 200px; }
.permission-info summary { cursor: pointer; }
.permission-info summary .badge { margin-left: 8px; }
.permission-info p { margin: 8px 0; font-size: 12px; }
.permission-info .permission-developer { margin: 12px 0; }
.permission-devices { margin-top: 20px; }
.permission-facts dt { color: var(--muted); font-size: 12px; }
.permission-facts dd { margin: 4px 0 0; }
.permission-developer { margin: 20px 0; }
.permission-developer p { margin: 4px 0; }
.permission-developer nav { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 12px; font-size: 13px; }
.permission-developer nav .icon, .permission-footer .icon { width: 14px; height: 14px; }
.permission-review { max-width: 780px; padding-top: 32px; }
.permission-review h1 { margin: 12px 0; font-size: 28px; overflow-wrap: anywhere; }
.permission-scope { margin: 24px 0; padding: 20px; border: 1px solid var(--line); border-radius: 11px; background: var(--base); }
.permission-scope h2 { font-size: 20px; line-height: 1.5; margin: 0; }
.permission-fields { min-width: 0; margin: 24px 0; padding: 20px; border: 1px solid var(--line); border-radius: 11px; }
.permission-fields legend { font-weight: 700; padding: 0 8px; }
.permission-fields h3 { font-size: 16px; }
.permission-fields .developer-choice { min-height: 44px; }
.modal:has(#app-permissions-form) { max-width: 1160px; }
.firewall-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 32px; }
.firewall-columns > section { min-width: 0; }
.firewall-columns h3 { margin-top: 0; }
.firewall-columns textarea { width: 100%; min-height: 230px; resize: vertical; }
.firewall-columns code { overflow-wrap: anywhere; }
.outgoing-firewall .notice { margin-top: 20px; }
.content-rating-questions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 20px 24px;
  margin: 24px 0;
}
.content-rating-questions .form-field { min-width: 0; margin: 0; }
.content-rating-questions select { width: 100%; max-width: none; }
.content-rating-audiences {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 128px), 1fr));
  gap: 8px 12px;
}
.content-rating-audiences .developer-choice { align-items: center; min-height: 44px; margin: 0; }
.content-rating-audiences .developer-choice input { margin-top: 0; }
.content-rating-audience-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 8px 12px; }
.content-rating-audience-choice .developer-choice { min-height: 44px; margin: 0; padding: 12px; border: 1px solid var(--line); border-radius: 12px; }
.content-rating-audience-choice .developer-choice:has(input:checked) { border-color: var(--violet); background: var(--violet-light); }
[data-rating-block="adults"] .permission-fields .developer-choice { margin: 6px 0; }
.modal:has(#go-live-form) { max-width: 960px; }
.go-live-step { padding: 20px 0; border-top: 1px solid var(--line); }
.go-live-step:first-of-type { border-top: 0; padding-top: 8px; }
.go-live-step h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; }
.go-live-number { display: inline-grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--violet-light); color: var(--violet); font-size: 14px; font-weight: 700; }
.go-live-number .icon { width: 16px; height: 16px; }
.go-live-storage { margin: 0 0 12px; padding-left: 20px; }
.go-live-storage li { overflow-wrap: anywhere; }
.go-live .form-field input, .go-live .form-field textarea, .go-live .form-field select { width: 100%; max-width: none; }
/* Optional age self-check (2026-10-10): a native disclosure that stays out of the form until opened. */
.content-rating-optional { margin: 16px 0 0; border-top: 1px solid var(--line); }
.content-rating-optional > summary { cursor: pointer; color: var(--violet); font-weight: 600; min-height: 44px; display: list-item; align-content: center; }
.content-rating-optional > [data-content-rating] { margin-top: 8px; }
.permission-age-check { margin: 16px 0 0; }
.permission-trust { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.permission-footer { margin-top: 20px; font-size: 13px; }
/* A trusted top sheet; the app stays mounted and inert underneath it. */
.permission-dialog-root .modal-backdrop { align-items: flex-start; padding: 0 16px 16px; }
:root .permission-dialog-root .modal { max-height: calc(100dvh - 16px); padding: 0; border: 1px solid var(--permission-line); border-top: 0; border-radius: 0 0 20px 20px; background: var(--permission-paper); overflow: hidden; animation: permission-slide-down .24s ease-out; }
.permission-sheet { display: flex; flex-direction: column; min-height: 0; max-height: calc(100dvh - 16px); color: var(--ink); background: var(--permission-paper); }
.permission-sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: max(24px, env(safe-area-inset-top)) 28px 16px; flex-shrink: 0; }
.permission-sheet h1 { margin: 10px 0 0; font-size: 24px; letter-spacing: -.4px; line-height: 1.35; overflow-wrap: anywhere; }
.permission-sheet .permission-trust { color: var(--permission-muted); max-width: none; font-weight: 700; }
.permission-sheet .icon-button { flex-shrink: 0; min-width: 44px; min-height: 44px; }
.permission-body { min-height: 0; padding: 0 28px; overflow-y: auto; overscroll-behavior: contain; overflow-wrap: anywhere; }
.permission-sheet .fine-print, .permission-sheet .permission-facts dt { color: var(--permission-muted); }
.permission-sheet .permission-origin { margin: 0 0 16px; }
.permission-sheet .permission-scope { background: transparent; border: 0; padding: 0; margin: 0 0 20px; }
.permission-sheet .permission-scope h2 { margin: 8px 0; font-size: 18px; }
.permission-sheet .permission-scope p { margin: 8px 0; font-size: 14px; }
.permission-app-message { margin: 14px 0 0; padding: 10px 14px; border-left: 3px solid var(--permission-line); border-radius: 0 8px 8px 0; background: color-mix(in srgb, var(--paper) 45%, transparent); font-size: 14px; white-space: pre-wrap; }
/* The new request is one card; what the app can already do sits below it, quieter. */
.permission-ask { position: relative; margin: 0 0 20px; padding: 18px; border: 2px solid var(--violet); border-radius: 16px; background: var(--paper); }
.permission-new { position: absolute; top: -11px; left: 16px; padding: 2px 10px; border-radius: 999px; background: var(--violet); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; }
.permission-ask-head { display: flex; gap: 14px; align-items: flex-start; }
.permission-ask-icon { display: grid; place-items: center; flex-shrink: 0; width: 40px; height: 40px; border-radius: 12px; background: var(--violet-light, color-mix(in srgb, var(--violet) 14%, transparent)); color: var(--violet); }
.permission-ask h2 { margin: 6px 0 6px; font-size: 19px; line-height: 1.35; }
.permission-ask-head p { margin: 4px 0 0; font-size: 14px; }
.permission-ask > .fine-print { margin: 12px 0 0; }
.permission-choices { min-width: 0; margin: 14px 0 0; padding: 0; border: 0; }
.permission-choice-list { display: grid; gap: 8px; }
.permission-choice { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 56px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--base); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.permission-choice strong, .permission-choice small { display: block; }
.permission-choice small { margin-top: 2px; color: var(--muted); font-size: 12px; }
.permission-choice:focus-visible { outline: 3px solid var(--violet); outline-offset: 2px; }
.permission-choice[aria-pressed="true"]:not(.is-granted) { border-color: var(--green); background: var(--green-light); }
.permission-choice[aria-pressed="true"]:not(.is-granted) small { color: var(--green); font-weight: 600; }
.permission-choice:disabled { cursor: default; color: var(--ink); }
.permission-choice:disabled:not(.is-granted) { opacity: .6; }
.permission-choice.is-granted:disabled { opacity: 1; }
/* A switch, not a checkbox look: off is grey with the knob left, on is green with the knob right. */
.permission-switch { position: relative; flex-shrink: 0; width: 46px; height: 28px; border-radius: 999px; background: color-mix(in srgb, var(--muted) 35%, transparent); transition: background .15s ease; }
.permission-switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / .25); transition: transform .15s ease; }
.permission-choice[aria-pressed="true"] .permission-switch { background: var(--green); }
.permission-choice[aria-pressed="true"] .permission-switch::after { transform: translateX(18px); }
.permission-choice.is-granted .permission-switch { display: grid; place-items: center; width: 28px; background: transparent; color: var(--green); }
.permission-choice.is-granted .permission-switch::after { display: none; }
@media (prefers-reduced-motion: reduce) { .permission-switch, .permission-switch::after { transition: none; } }
.permission-sheet .permission-consent { margin: 0 0 20px; padding: 16px 18px; border: 1px solid var(--permission-line); border-radius: 14px; }
.permission-consent legend { display: flex; align-items: center; gap: 4px; padding: 0 6px; }
.permission-consent .developer-choice { margin: 6px 0; }
.permission-current { margin: 0 0 20px; padding: 14px 18px; border: 1px dashed var(--permission-line); border-radius: 14px; }
.permission-current h3 { display: flex; align-items: center; gap: 4px; margin: 0 0 8px; font-size: 14px; }
.permission-current ul { display: grid; gap: 6px; margin: 0 0 10px; padding: 0; list-style: none; font-size: 14px; }
.permission-current li { display: flex; gap: 8px; align-items: flex-start; }
.permission-current li > .icon { flex-shrink: 0; width: 16px; height: 16px; margin-top: 3px; color: var(--green); }
.permission-current .fine-print { margin: 0 0 10px; }
.permission-manage { display: inline-flex; align-items: center; gap: 4px; min-height: 32px; font-size: 13px; }
.permission-manage .icon { width: 14px; height: 14px; }
.permission-seller { margin: 0 0 20px; font-size: 13px; }
.permission-seller .permission-developer { margin: 0; }
.permission-seller-line { display: flex; align-items: center; gap: 4px; margin: 0 0 4px; font-weight: 700; }
.permission-hint { margin: 0 0 10px; color: var(--permission-muted); font-size: 13px; text-align: right; }
.permission-hint[hidden] { display: none; }
.permission-sheet-footer { flex-shrink: 0; padding: 16px 28px max(20px, env(safe-area-inset-bottom)); border-top: 1px solid var(--permission-line); background: var(--permission-paper); }
.permission-sheet-footer:empty { display: none; }
.permission-sheet-footer .notice { margin: 0 0 12px; }
.permission-sheet-footer .permission-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0; padding: 0; border: 0; }
.permission-actions .button { min-height: 48px; margin: 0; white-space: normal; }
.permission-window .permission-sheet { max-height: none; border: 1px solid var(--permission-line); border-radius: 0 0 20px 20px; overflow: clip; }
/* In its own window the page scrolls, so keep the decision buttons in reach at the bottom. */
.permission-window .permission-sheet-footer { position: sticky; bottom: 0; z-index: 2; box-shadow: 0 -8px 16px -12px rgb(0 0 0 / .35); }
@keyframes permission-slide-down { from { transform: translateY(-100%); } to { transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { :root .permission-dialog-root .modal { animation: none; } }
/* Repeat one-time payments: a short sheet that comes up from the bottom (owner request 2026-10-13).
   Details expands it in place into the full review, still anchored to the bottom. */
.permission-dialog-root:has(.from-bottom) .modal-backdrop { align-items: flex-end; padding: 16px 16px 0; }
:root .permission-dialog-root:has(.from-bottom) .modal { border-top: 1px solid var(--permission-line); border-bottom: 0; border-radius: 20px 20px 0 0; animation: permission-slide-up .24s ease-out; }
:root .permission-dialog-root:has(.permission-quick) .modal { max-width: 560px; }
@keyframes permission-slide-up { from { transform: translateY(100%); } to { transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { :root .permission-dialog-root:has(.from-bottom) .modal { animation: none; } }
.permission-quick-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 24px 0; }
.permission-quick-head .permission-trust { min-width: 0; overflow-wrap: anywhere; }
.permission-expand { flex-shrink: 0; min-height: 44px; gap: 6px; }
.permission-expand .icon { width: 16px; height: 16px; }
.permission-quick-body { padding: 4px 24px 16px; }
.permission-sheet.permission-quick h1 { margin: 4px 0 0; font-size: 22px; }
.permission-quick-for { margin: 2px 0 0; font-size: 15px; overflow-wrap: anywhere; }
.permission-quick-terms { margin: 10px 0 0; color: var(--permission-muted); font-size: 13px; }
.permission-quick .permission-sheet-footer { padding-top: 14px; }
.permission-window .permission-sheet.permission-quick { max-width: 560px; margin: 0 auto; border-radius: 20px; }
.permission-window .permission-quick .permission-sheet-footer { position: static; box-shadow: none; }
@media (max-width: 480px) {
  .permission-dialog-root .modal-backdrop { padding: 0 8px 8px; }
  :root .permission-dialog-root .modal, .permission-sheet { max-height: calc(100dvh - 8px); }
  .permission-sheet-head { padding: max(16px, env(safe-area-inset-top)) 16px 12px; gap: 8px; }
  .permission-sheet h1 { font-size: 21px; }
  .permission-body { padding: 0 16px; }
  .permission-sheet-footer { padding: 12px 16px max(16px, env(safe-area-inset-bottom)); }
  .permission-ask, .permission-current, .permission-sheet .permission-consent { padding: 14px; }
  .permission-ask h2 { font-size: 17px; }
  .permission-ask-icon { width: 34px; height: 34px; }
  .permission-hint { text-align: left; }
  .permission-dialog-root:has(.from-bottom) .modal-backdrop { padding: 8px 0 0; }
  .permission-quick-head { padding: 12px 16px 0; }
  .permission-quick-body { padding: 4px 16px 14px; }
}
@media (max-width: 760px) {
  .permissions-page .page-heading { flex-wrap: wrap; }
  .permission-window .site-header { padding-left: 20px; padding-right: 20px; gap: 20px; }
  .permission-trust { max-width: 140px; line-height: 1.5; }
  .permission-review { padding: 20px 16px 40px; }
  .permission-review .content-panel, .permission-scope, .permission-fields { padding: 16px; }
  .permission-review h1 { font-size: 24px; }
  .permission-review .modal-actions { flex-wrap: wrap; }
}
@media (max-width: 760px) {
  .showroom .section-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .showroom .section-head > p { margin: 0; }
  .consumer-account { grid-template-columns: 1fr; gap: 12px; }
  .developer-document { padding: 16px; max-height: 360px; }
}
/* Marketplace discovery uses the shared cards, controls and theme tokens. */
.recommended-apps { margin-bottom: 36px; }
.recommended-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.recommended-grid .app-card { background: linear-gradient(145deg, var(--violet-light), var(--paper) 70%); }
.recommended-grid .app-card:first-child { border-color: var(--violet); }
.marketplace-filters { display: grid; gap: 16px; margin-bottom: 24px; }
.marketplace-filters .search-field { width: 100%; max-width: none; }
.category-filters, .app-category-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.category-filters .button { border-radius: 999px; min-height: 36px; }
.app-category-tags { margin: 8px 0 12px; }
.app-category-tags .badge { white-space: normal; }
.marketplace-status { text-align: center; padding: 24px 0 8px; }
.marketplace-status .notice { text-align: left; }
.marketplace-status .empty { margin-bottom: 16px; }
.private-apps { margin-top: 32px; }
.app-category-fields { min-width: 0; margin: 20px 0; padding: 16px; border: 1px solid var(--line); border-radius: 11px; }
.app-category-fields legend { font-weight: 700; padding: 0 6px; }
.category-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 16px; }
.category-choices .developer-choice { margin: 0; }
@media (max-width: 1000px) { .recommended-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .recommended-grid { display: grid; grid-auto-flow: column; grid-auto-columns: min(82vw, 310px); grid-template-columns: none; overflow-x: auto; padding: 2px 2px 12px; scroll-snap-type: x proximity; }
  .recommended-grid .app-card { scroll-snap-align: start; }
  .recommended-apps .section-head { display: block; }
  .recommended-apps .section-head p { margin-top: 8px; }
  .category-filters { gap: 8px; }
}
@media (max-width: 480px) { .category-choices { grid-template-columns: 1fr; } }

/* App change review uses full-size controls at every viewport. */
.modal:has(#publication-confirm, #publication-check) .button { min-height: 44px; }
[data-unpublished-changes] .code-head { flex-wrap: wrap; }
[data-unpublished-changes] .code-block { max-width: 100%; overflow-x: auto; }

.modal:has(#publication-check) details { margin-block: 16px; }
[data-unpublished-changes] .detail-actions { margin-top: 16px; }

.settings-diff { border-radius: 3px; }

.settings-comparison { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.settings-comparison > section { min-width: 0; max-width: 100%; }
.settings-comparison .code-block { white-space: pre-wrap; overflow-wrap: anywhere; }
@media (max-width: 760px) { .settings-comparison { grid-template-columns: minmax(0, 1fr); } }

/* saasland.io 2.0 — live, dynamic public surfaces and shared polish (2026-10-04). */
.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: normal;
}
.brand-logo { width: 4.6em; }
.app-card {
  position: relative;
  border-radius: var(--radius-card);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  isolation: isolate;
  transition: transform 0.35s var(--motion-spring), box-shadow 0.25s, border-color 0.2s;
}
.app-card::before,
[data-spotlight]::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.25s;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgb(108 71 255 / 14%), transparent 65%);
  pointer-events: none;
}
.app-card:hover::before,
[data-spotlight]:hover::before { opacity: 1; }
.app-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--violet) 35%, var(--line));
  box-shadow: var(--shadow-pop);
}
.nav-item.active { box-shadow: inset 3px 0 0 var(--violet); }

/* Public header: floating glass pill. */
.site-header {
  position: sticky;
  top: 12px;
  z-index: 20;
  height: 68px;
  width: min(1240px, calc(100% - 32px));
  margin: 12px auto 0;
  padding: 0 12px 0 22px;
  border: 1px solid color-mix(in srgb, var(--line) 80%, transparent);
  border-radius: var(--radius-pill);
  background: var(--glass);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  backdrop-filter: blur(18px) saturate(1.6);
  box-shadow: var(--shadow-soft);
}
.site-header .brand { font-size: 30px; }
.site-nav > a:not(.button) { color: var(--muted); font-weight: 600; transition: color 0.15s; }
.site-nav > a:not(.button):hover { color: var(--ink); }

/* Ambient aurora behind the public pages. */
.land-aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(circle at 1px 1px, color-mix(in srgb, var(--ink) 9%, transparent) 1px, transparent 0) 0 0 / 28px 28px,
    var(--base);
}
.land-aurora span {
  position: absolute;
  width: 46vmax;
  height: 46vmax;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.38;
  animation: aurora-drift 22s ease-in-out infinite alternate;
}
.land-aurora span:nth-child(1) { background: #7b5cff; top: -18vmax; right: -10vmax; }
.land-aurora span:nth-child(2) { background: #ff4fd8; bottom: -24vmax; left: -14vmax; animation-delay: -7s; opacity: 0.26; }
.land-aurora span:nth-child(3) { background: #d7ff3a; top: 38%; right: 18%; width: 22vmax; height: 22vmax; animation-delay: -13s; opacity: 0.2; }
:root[data-color-scheme="dark"] .land-aurora span { opacity: 0.3; }
:root[data-color-scheme="dark"] .land-aurora span:nth-child(3) { opacity: 0.12; }
@keyframes aurora-drift {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-6vmax, 4vmax, 0) scale(1.12); }
  100% { transform: translate3d(5vmax, -3vmax, 0) scale(0.94); }
}

/* Hero */
.land-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 40px;
  min-height: min(720px, calc(100vh - 100px));
  padding: 56px 0 40px;
}
.land-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px 7px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--glass);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font-size: 13px;
  font-weight: 650;
}
.live-dot {
  position: relative;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #22c55e;
}
.live-dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: inherit;
  animation: live-ping 1.8s cubic-bezier(0, 0, 0.2, 1) infinite;
}
@keyframes live-ping { 75%, 100% { transform: scale(2.6); opacity: 0; } }
.land-hero h1 {
  margin: 22px 0 14px;
  font-size: clamp(48px, 8.4vw, 112px);
  line-height: 0.95;
  letter-spacing: -0.035em;
  font-weight: 800;
}
.land-rotator {
  margin: 0 0 18px;
  font-family: var(--font-heading);
  font-size: clamp(22px, 2.6vw, 32px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.rotator {
  display: inline-block;
  height: 1.25em;
  overflow: hidden;
  vertical-align: bottom;
}
.rotator-track {
  display: flex;
  flex-direction: column;
  animation: rotate-words 12.5s cubic-bezier(0.7, 0, 0.3, 1) infinite;
}
.rotator-track > span {
  display: block;
  height: 1.25em;
  padding: 0 0.12em;
  border-radius: 10px;
  background: var(--lime);
  color: var(--on-lime);
}
@keyframes rotate-words {
  0%, 16% { transform: translateY(0); }
  20%, 36% { transform: translateY(-1.25em); }
  40%, 56% { transform: translateY(-2.5em); }
  60%, 76% { transform: translateY(-3.75em); }
  80%, 96% { transform: translateY(-5em); }
  100% { transform: translateY(-6.25em); }
}
.land-lede {
  max-width: 540px;
  margin: 0 0 28px;
  font-size: 18px;
  color: var(--muted);
}
.land-hero .hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }
.land-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}
.land-chips li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--paper);
  font-size: 13px;
  font-weight: 600;
}
.land-chips .icon { width: 18px; height: 18px; color: var(--violet); }

/* Orbiting brand planet */
.land-orbit {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  position: relative;
  aspect-ratio: 1;
  width: min(100%, 520px);
  justify-self: center;
  transform: perspective(900px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transition: transform 0.4s ease-out;
}
.orbit-glow {
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  background: var(--gradient-brand);
  filter: blur(60px);
  opacity: 0.45;
  animation: glow-pulse 5s ease-in-out infinite;
}
@keyframes glow-pulse { 50% { opacity: 0.7; transform: scale(1.08); } }
.orbit-core {
  position: absolute;
  inset: 37%;
  display: grid;
  place-items: center;
  animation: core-float 6s ease-in-out infinite;
}
.orbit-core img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 24px 40px rgb(108 71 255 / 45%));
}
@keyframes core-float { 50% { transform: translateY(-10px) rotate(-4deg); } }
.orbit-ring {
  position: absolute;
  border: 1.5px dashed color-mix(in srgb, var(--violet) 40%, transparent);
  border-radius: 50%;
  animation: orbit-spin 28s linear infinite;
}
.ring-1 { inset: 22%; }
.ring-2 { inset: 4%; animation-duration: 44s; animation-direction: reverse; }
@keyframes orbit-spin { to { transform: rotate(360deg); } }
.orbit-node {
  position: absolute;
  top: -24px;
  left: calc(50% - 24px);
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--paper);
  color: var(--violet);
  box-shadow: var(--shadow-pop);
  animation: orbit-spin 28s linear infinite reverse;
}
.ring-2 .orbit-node { animation-duration: 44s; animation-direction: normal; }
.orbit-node .icon { width: 24px; height: 24px; }
.orbit-node.node-b { top: auto; bottom: -24px; }
.orbit-node.node-c { top: calc(50% - 24px); left: -24px; }
.orbit-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px 10px 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow-pop);
  animation: core-float 7s ease-in-out infinite;
}
.orbit-card > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: var(--lime);
  color: var(--on-lime);
}
.orbit-card .coin-chip { background: var(--violet-light); }
.orbit-card strong { display: block; font-size: 13px; }
.orbit-card small { color: var(--muted); font-size: 11px; }
.card-a { top: 12%; left: -4%; }
.card-b { bottom: 10%; right: -2%; animation-delay: -3s; }

/* Category marquee */
.land-marquee {
  position: relative;
  margin: 8px calc(-6.9vw) 24px;
  padding: 16px 0;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background: var(--ink);
  color: var(--base);
  transform: rotate(-1.2deg);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex;
  gap: 28px;
  width: max-content;
  font-family: var(--font-heading);
  font-size: clamp(22px, 3vw, 34px);
  font-weight: 750;
  letter-spacing: -0.02em;
  white-space: nowrap;
  animation: marquee 38s linear infinite;
}
.marquee-track i { color: var(--lime); font-style: normal; }
.land-marquee:hover .marquee-track,
.land-marquee:focus-within .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.showroom-apps { padding: 44px 0 40px; scroll-margin-top: 100px; }
.showroom .section-head h2,
.land-section .section-head h2 { font-size: clamp(30px, 4vw, 48px); line-height: 1; }

/* Bento features */
.land-section { padding: 40px 0 56px; }
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: minmax(190px, auto);
  gap: 16px;
}
.bento-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
  transition: transform 0.35s var(--motion-spring), box-shadow 0.25s;
}
.bento-card:hover { transform: translateY(-4px) rotate(-0.4deg); box-shadow: var(--shadow-pop); }
.bento-card h3 { margin: 18px 0 8px; font-size: 24px; letter-spacing: -0.03em; }
.bento-card p { margin: 0; color: var(--muted); max-width: 46ch; }
.bento-wide { grid-column: span 2; }
.bento-tall { grid-row: span 2; display: flex; flex-direction: column; justify-content: flex-end; }
.bento-accent { border-color: transparent; background: var(--gradient-brand); color: #fff; }
.bento-accent p { color: rgb(255 255 255 / 88%); }
.bento-accent h3 { font-size: 32px; }
.bento-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: var(--violet-light);
  color: var(--violet);
}
.bento-icon .icon { width: 28px; height: 28px; }
.bento-accent .bento-icon { width: 76px; height: 76px; border-radius: 24px; background: rgb(255 255 255 / 18%); color: #fff; }
.bento-accent .bento-icon .icon { width: 44px; height: 44px; }

/* Builder band */
.land-builder {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px 40px;
  margin: 8px 0 56px;
  padding: clamp(28px, 5vw, 56px);
  border-radius: calc(var(--radius) + 8px);
  background: var(--ink);
  color: var(--base);
}
.land-builder::after {
  content: "";
  position: absolute;
  inset: auto -10% -60% 40%;
  height: 120%;
  z-index: -1;
  border-radius: 50%;
  background: var(--gradient-brand);
  filter: blur(70px);
  opacity: 0.55;
}
.land-builder h2 { margin: 10px 0; font-size: clamp(30px, 4.4vw, 52px); line-height: 1; color: inherit; }
.land-builder p { max-width: 560px; margin: 0; color: color-mix(in srgb, var(--base) 78%, transparent); }
.land-builder .eyebrow { color: var(--lime); }
.land-builder-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; }
.land-builder .text-link { color: var(--base); }
.land-builder .button.primary { background: var(--lime); color: var(--on-lime); box-shadow: 0 18px 40px -14px rgb(215 255 58 / 55%); }
.land-builder .button.primary:hover:not(:disabled) { background: #e4ff7a; }

/* Scroll reveal: only hidden once motion is known to be available. */
@media (prefers-reduced-motion: no-preference) {
  [data-reveal]:not(.is-visible) { opacity: 0; transform: translateY(24px); }
  [data-reveal] { transition: opacity 0.7s ease, transform 0.7s var(--motion-spring); transition-delay: var(--reveal-delay, 0ms); }
}
@media (prefers-reduced-motion: reduce) {
  .land-aurora span,
  .live-dot::after,
  .rotator-track,
  .orbit-glow,
  .orbit-core,
  .orbit-ring,
  .orbit-node,
  .orbit-card,
  .marquee-track { animation: none; }
  .land-orbit { transform: none; }
}

@media (max-width: 900px) {
  .land-hero { grid-template-columns: 1fr; min-height: 0; padding-top: 36px; gap: 12px; }
  .land-orbit { width: min(86%, 420px); order: -1; margin-bottom: 24px; }
  .bento-grid { grid-template-columns: 1fr 1fr; }
  .bento-tall { grid-row: auto; }
}
@media (max-width: 640px) {
  .site-header { top: 8px; width: calc(100% - 16px); height: auto; min-height: 60px; padding: 8px 8px 6px 16px; border-radius: 24px; }
  .site-header .brand { font-size: 24px; }
  .land-hero h1 { font-size: clamp(46px, 15vw, 72px); }
  .land-lede { font-size: 16px; }
  .land-orbit { width: 78%; }
  .orbit-card { display: none; }
  .bento-grid { grid-template-columns: 1fr; }
  .bento-wide { grid-column: auto; }
  .land-marquee { margin-inline: -16px; }
}
/* Phone public header: one slim row, with the navigation behind a menu button. */
.site-menu-toggle { display: none; }
@media (max-width: 640px) {
  .site-header:has(.site-menu-toggle) {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
    min-height: 60px;
    padding: 7px 7px 7px 16px;
    border-radius: var(--radius-pill);
  }
  .site-header:has(.site-menu-toggle) .brand { margin-right: auto; min-width: 0; }
  .site-header:has(.site-menu-toggle) .site-header-action { min-height: 44px; padding: 8px 14px; font-size: 13px; }
  .site-menu-toggle {
    display: inline-flex;
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    color: var(--ink);
  }
  .site-header:has(.site-menu-toggle) .site-nav { display: none; }
  .site-header.site-menu-open .site-nav {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    margin: 0;
    padding: 8px;
    border: 1px solid color-mix(in srgb, var(--line) 80%, transparent);
    border-radius: var(--radius-card);
    background: var(--paper);
    box-shadow: var(--shadow-soft);
  }
  .site-header.site-menu-open .site-nav > a {
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 0 14px;
    border-radius: var(--radius-control);
    font-size: 16px;
  }
  .site-header.site-menu-open .site-nav > a:not(.button):hover,
  .site-header.site-menu-open .site-nav > a[aria-current="page"] { display: flex; background: var(--base); color: var(--ink); }
  .site-header.site-menu-open .site-nav > .button { justify-content: center; margin-top: 6px; }
}
@media (forced-colors: active) {
  .gradient-text { color: CanvasText; background: none; }
  .rotator-track > span { background: Canvas; color: CanvasText; }
}
.landing-main.showroom { overflow-x: clip; }

/* Workspace polish: same brand energy, calmer motion for daily use. */
.page-heading h1 { font-size: clamp(30px, 3.2vw, 42px); }
.credit-mini {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--paper), var(--paper)) padding-box,
    var(--gradient-brand) border-box;
  border-radius: 16px;
}
.stat-card { border-radius: var(--radius-card); box-shadow: var(--shadow-soft); }
.stat-value { font-family: var(--font-heading); letter-spacing: -0.03em; }
.card-create:hover { border-color: var(--violet); }
.modal { border-radius: var(--radius); }

/* Second mobile review, 2026-10-05. */
.balance-info a { color: var(--violet); text-decoration: underline; text-underline-offset: 2px; }
.balance-info p { margin: 0 0 6px; }
.bento-accent { background: linear-gradient(rgb(20 10 40 / 32%), rgb(20 10 40 / 32%)), var(--gradient-brand); }
.bento-accent p { color: #fff; }
@media (max-width: 760px) {
  .detail-page-heading > div:first-child { flex: 0 0 auto; }
  .mobile-menu { width: 44px; height: 44px; margin-left: -8px; flex: none; }
  .topbar { gap: 8px; }
  .breadcrumb { min-width: 0; overflow: hidden; white-space: nowrap; }
  .breadcrumb > * { flex-shrink: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .breadcrumb > svg { flex: none; }
  .breadcrumb .text-link { font-size: inherit; }
  .topbar-actions .text-link { display: inline-flex; align-items: center; min-height: 44px; white-space: nowrap; }
  .button.small,
  .page-heading .button,
  .category-filters .button { min-height: 44px; }
  /* One swipeable row of categories instead of three wrapped lines. */
  .category-filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 6px; mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent); }
  .category-filters::-webkit-scrollbar { display: none; }
  .category-filters .button { flex: 0 0 auto; }
  .balance-info a { display: inline-block; padding: 10px 0; }
  .app-row-text small { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
}
@media (max-width: 480px) {
  /* Deeper pages drop the leading Workspace crumb so both names stay readable. */
  .breadcrumb:has(.text-link) > span:first-child,
  .breadcrumb:has(.text-link) > span:first-child + svg { display: none; }
}

/* Phones: deployment log shortcuts sit two per row instead of five full-width rows. */
@media (max-width: 480px) {
  .modal-actions.deployment-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .modal-actions.deployment-actions .button { width: 100%; }
}

/* Compact marketplace cards (Karlis, 2026-10-13): full-bleed promo image, logo overlapping it,
   two-line description, one meta line, and a NEW corner ribbon for apps under 30 days old. */
[data-marketplace] .apps-grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
[data-marketplace] .recommended-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.market-card { display: flex; flex-direction: column; padding: 0; color: inherit; text-decoration: none; }
.market-cover { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, var(--violet-light), color-mix(in srgb, var(--violet) 22%, var(--paper))); }
.market-card.no-artwork .market-cover { background: radial-gradient(circle at 1px 1px, color-mix(in srgb, var(--violet) 18%, transparent) 1px, transparent 0) 0 0 / 14px 14px, linear-gradient(135deg, var(--violet-light), color-mix(in srgb, var(--violet) 22%, var(--paper))); }
.market-cover .app-artwork { margin: 0; border-radius: 0; aspect-ratio: auto; height: 100%; background: none; }
.market-cover .app-artwork img { object-fit: cover; transition: transform 0.4s var(--motion-spring); }
.market-card:hover .market-cover img { transform: scale(1.04); }
.market-body { display: flex; flex-direction: column; gap: 6px; padding: 0 14px 12px; min-width: 0; flex: 1; }
.market-title { display: flex; align-items: flex-end; gap: 10px; min-width: 0; }
.market-title .app-symbol { width: 52px; height: 52px; margin-top: -26px; border: 3px solid var(--paper); border-radius: 15px; box-shadow: 0 4px 14px rgb(22 19 31 / 14%); background-clip: padding-box; position: relative; }
.market-title h3 { flex: 1; min-width: 0; margin: 0 0 2px; font-size: 15px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.market-meta > .market-rating { flex-shrink: 0; padding: 0 6px; background: none; border: 1px solid var(--line); border-radius: 6px; font-size: 10px; font-weight: 700; color: var(--muted); }
.app-card.market-card p { margin: 0; min-height: 0; font-size: 12px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.market-card > .market-body > .badge { align-self: flex-start; }
.market-meta { display: flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 4px; min-width: 0; overflow: hidden; white-space: nowrap; font-size: 10.5px; color: var(--muted); }
.market-meta > span:not(.market-rating) { flex-shrink: 0; padding: 1px 7px; border-radius: 999px; background: var(--violet-light); color: var(--violet); font-weight: 600; }
.market-ribbon { position: absolute; z-index: 2; top: 13px; right: -30px; width: 110px; padding: 3px 0; transform: rotate(45deg); background: var(--lime); color: #16131f; font-size: 10px; font-weight: 800; letter-spacing: 0.12em; text-align: center; text-transform: uppercase; box-shadow: 0 2px 8px rgb(22 19 31 / 25%); pointer-events: none; }
.recommended-grid .market-card .market-body { background: none; }
/* Home shelves (New, Popular): one row of cards that scrolls sideways, so they never push the marketplace far down. */
.app-shelf { margin-bottom: 32px; min-width: 0; }
.apps-shelf { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(210px, calc((100% - 3 * 14px) / 4)); gap: 14px; overflow-x: auto; padding: 2px 2px 12px; scroll-snap-type: x proximity; overscroll-behavior-x: contain; scrollbar-width: thin; }
.apps-shelf > div { display: grid; min-width: 0; scroll-snap-align: start; }
@media (max-width: 760px) {
  .apps-shelf { grid-auto-columns: min(62vw, 230px); gap: 10px; }
  .app-shelf .section-head { display: block; }
  [data-marketplace] .apps-grid:not(.recommended-grid) { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  [data-marketplace] .recommended-grid { grid-template-columns: none; grid-auto-columns: min(68vw, 250px); }
  .market-body { padding: 0 10px 10px; gap: 4px; }
  .market-title { gap: 8px; }
  .market-title .app-symbol { width: 42px; height: 42px; margin-top: -21px; border-radius: 12px; }
  .market-title h3 { font-size: 14px; }
  .app-card.market-card p { font-size: 11.5px; }
  .market-meta > span:not(.market-rating) ~ span { display: none; }
}
@media (max-width: 340px) { [data-marketplace] .apps-grid:not(.recommended-grid) { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .market-cover .app-artwork img { transition: none; } .market-card:hover .market-cover img { transform: none; } }

/* Stepped runtime controls share the form tokens and work at narrow widths. */
.runtime-controls { min-width: 0; }
.runtime-controls input[type="range"] { width: 100%; min-height: 44px; padding: 0; margin-block: 8px; accent-color: var(--violet); }
.runtime-controls input[type="range"]:disabled { opacity: .45; cursor: not-allowed; }
.runtime-ticks { position: relative; display: flex; justify-content: space-between; gap: .5rem; font-size: .8rem; color: var(--muted); }
.runtime-ticks span { text-align: center; white-space: nowrap; }
.runtime-ticks span:first-child { text-align: left; }
.runtime-ticks span:last-child { text-align: right; }
.runtime-ticks span:nth-child(2):not(:last-child) { position: absolute; left: 33.333%; transform: translateX(-50%); }
.runtime-ticks span:nth-child(3):not(:last-child) { position: absolute; left: 66.667%; transform: translateX(-50%); }
.runtime-controls output { display: block; font-weight: 600; }

/* Personal library uses the same compact marketplace cards. */
.consumer-app-card { min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.consumer-app-card > .app-card { flex: 1; }
.library-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.library-actions .button { min-height: 44px; padding-inline: 14px; white-space: normal; }
.library-actions [aria-pressed="true"] { color: var(--violet); background: var(--violet-light); border-color: var(--violet); }
.library-actions [aria-pressed="true"] .icon { fill: currentColor; }
/* One row under each card: Open app plus icon-only favorite/save toggles. */
.consumer-card-actions { display: flex; align-items: center; gap: 6px; }
.consumer-card-actions > .button { flex: 1; min-height: 44px; justify-content: center; }
.library-actions.compact { flex-wrap: nowrap; }
.library-actions .icon-toggle { width: 44px; padding: 0; justify-content: center; }
.pick-reason { display: flex; gap: 6px; align-items: flex-start; margin: 0 4px; font-size: 13px; color: var(--muted); }
.pick-reason .icon { flex-shrink: 0; width: 16px; height: 16px; margin-top: 2px; color: var(--violet); }
.consumer-library-section { margin-block: 24px 36px; }
@media (max-width: 760px) { .recommended-grid > .consumer-app-card { width: 250px; flex: 0 0 250px; } }

.app-preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.app-preview-art { max-width: 900px; margin: 24px 0; }
/* Feature list: checkmarks at body size instead of default browser bullets. */
.app-preview-grid .content-panel > ul { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 8px; font-size: 14px; }
.app-preview-grid .content-panel > ul > li { position: relative; padding-left: 26px; overflow-wrap: anywhere; }
.app-preview-grid .content-panel > ul > li::before { content: ""; position: absolute; left: 2px; top: .3em; width: 14px; height: 8px; border-left: 2px solid var(--violet); border-bottom: 2px solid var(--violet); transform: rotate(-45deg) scale(.8); }
.app-preview-grid .content-panel { margin-bottom: 0; }
.app-preview-art .app-artwork { border-radius: var(--radius-card, 18px); }
.app-preview .detail-title { min-width: 0; align-items: flex-start; }
.app-preview h1, .app-preview p { overflow-wrap: anywhere; }
@media (max-width: 760px) { .app-preview-grid { grid-template-columns: 1fr; } }

.editorial-pick { min-width: 0; }
.editorial-pick > .fine-print { margin: 10px 4px 0; }
@media (max-width: 760px) { .recommended-grid > .editorial-pick { width: 250px; flex: 0 0 250px; } }

.app-storage-information { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 10px 16px; background: var(--paper); border-bottom: 1px solid var(--line); font-size: 14px; }
.app-storage-information small { display: block; }
.app-storage-information .button { flex-shrink: 0; min-height: 44px; }
.wallet-outlook { margin: 24px 0 2px; align-items: start; }
.wallet-layout > .content-panel, .wallet-side > .content-panel, .wallet-outlook .content-panel { margin-bottom: 0; }

.messages-filters { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; margin-bottom: 24px; }
.messages-filters .form-field { margin: 0; min-width: 0; }
.messages-filters .developer-choice { grid-column: 1 / -1; justify-self: start; }
.support-choices { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 24px; }
@media (max-width: 760px) { .messages-filters { grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; } .messages-filters .form-field:first-child { grid-column: 1 / -1; } .support-choices .button { flex: 1 1 100%; } }

.app-preview .detail-actions { flex-wrap: wrap; }
.library-history .detail-actions { margin-top: 12px; }
.consumer-library-empty { margin-bottom: 24px; }

/* AI builder chat: conversation above, message box at the bottom. */
.ai-heading-actions { display: flex; gap: var(--space-2); flex-wrap: wrap; }
/* One chat per app: the app list on the left, the open chat on the right. */
.ai-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: var(--space-4); align-items: start; }
.ai-apps { border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--paper); padding: 8px; max-height: max(460px, calc(100dvh - 290px)); overflow-y: auto; overscroll-behavior: contain; }
.ai-apps ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.ai-apps-title { display: flex; align-items: center; gap: 4px; margin: 4px 8px 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.ai-apps-empty { margin: 8px; }
.ai-app-item { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 6px 8px; border: 0; border-radius: var(--radius-control); background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.ai-app-item:hover { background: var(--base); }
.ai-app-item[aria-current="true"] { background: var(--violet-light); }
.ai-app-icon { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 32px; height: 32px; border-radius: 10px; background: var(--violet-light); color: var(--violet); font-weight: 700; font-size: 14px; }
.ai-app-item[aria-current="true"] .ai-app-icon { background: var(--paper); }
.ai-app-icon .icon { width: 18px; height: 18px; }
.ai-app-text { min-width: 0; display: flex; flex-direction: column; }
.ai-app-text strong { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-app-text small { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; }
.ai-chat-head { display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; padding: 0 2px var(--space-3); border-bottom: 1px solid var(--line); }
.ai-chat-title { min-width: 0; flex: 1 1 200px; }
.ai-chat-title h2 { margin: 0; font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-chat-title p { margin: 2px 0 0; }
.ai-chat-title p .info-tip, .ai-chat-title p button { vertical-align: middle; }
.ai-head-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ai-head-actions:empty { display: none; }
.ai-all-apps { display: none; }
.ai-chat > .loading-placeholder { margin-top: var(--space-4); }
.ai-queue { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.ai-queued { display: flex; align-items: center; gap: 8px; max-width: min(640px, 88%); padding: 4px 4px 4px 12px; border: 1px dashed var(--line); border-radius: var(--radius-card); color: var(--muted); font-size: 14px; }
.ai-queued-label { display: inline-flex; align-items: center; gap: 4px; flex: none; font-size: 12px; font-weight: 600; }
.ai-queued-label .icon { width: 14px; height: 14px; }
.ai-queued-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.ai-queued .icon-button { flex: none; width: 36px; height: 36px; border: 0; }
.ai-moved { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; }
.ai-chat { display: flex; flex-direction: column; height: max(460px, calc(100dvh - 290px)); min-width: 0; }
.ai-log { flex: 1; overflow-y: auto; padding: var(--space-2) 2px var(--space-4); display: flex; flex-direction: column; gap: var(--space-4); overscroll-behavior: contain; }
.ai-message { display: flex; flex-direction: column; gap: var(--space-2); max-width: 100%; }
.ai-message.user { align-items: flex-end; }
.ai-bubble { background: var(--violet-light); color: var(--ink); border-radius: var(--radius-card) var(--radius-card) 6px var(--radius-card); padding: 10px 14px; max-width: min(640px, 88%); overflow-wrap: anywhere; }
.ai-bubble p, .ai-text p { margin: 0 0 8px; }
.ai-bubble p:last-child, .ai-text p:last-child { margin-bottom: 0; }
.ai-text { line-height: 1.6; overflow-wrap: anywhere; }
.ai-text ul, .ai-text ol { margin: 0 0 8px; padding-left: 22px; }
.ai-text code, .ai-bubble code { font-family: var(--font-mono); font-size: 0.9em; background: var(--base); border: 1px solid var(--line); border-radius: 6px; padding: 1px 5px; }
.ai-text pre code { border: 0; padding: 0; background: none; }
.ai-text .code-block { margin: 8px 0; font-size: 12px; line-height: 1.6; max-height: 360px; }
:root[data-color-scheme="dark"] .ai-text .code-block { background: var(--base); border-color: var(--line); color: var(--ink); }
.ai-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.ai-step { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; color: var(--muted); font-size: 14px; }
.ai-step .icon { width: 16px; height: 16px; color: var(--green); flex: none; }
.ai-step.failed .icon { color: #c2410c; }
.ai-step .button { margin-left: 4px; }
.ai-notice { align-self: center; text-align: center; color: var(--muted); font-size: 14px; margin: 0; max-width: 560px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; }
.ai-notice > .icon { width: 16px; height: 16px; flex: none; }
.ai-notice.saved > .icon { color: var(--green); }
.ai-notice.error { color: #b42318; }
.ai-notice.warning { color: #b54708; background: #fffaeb; border: 1px solid #fedf89; border-radius: var(--radius-control); padding: 8px 12px; }
:root[data-color-scheme="dark"] .ai-notice.warning { color: #fec84b; background: transparent; border-color: #7a4a0c; }
:root[data-color-scheme="dark"] .ai-notice.error { color: #ff9b8a; }
.ai-working { display: flex; align-items: center; gap: 8px; color: var(--muted); margin: 0; font-size: 14px; }
.ai-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--violet); animation: ai-pulse 1.2s ease-in-out infinite; flex: none; }
@keyframes ai-pulse { 50% { opacity: 0.3; transform: scale(0.8); } }
@media (prefers-reduced-motion: reduce) { .ai-dot { animation: none; } }
.ai-attachments { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.ai-attachments img { max-width: 180px; max-height: 140px; border-radius: 10px; border: 1px solid var(--line); object-fit: cover; }
.ai-attachments.pending { margin: 0 0 6px; }
.ai-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 6px 4px 10px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--paper); font-size: 13px; max-width: 100%; overflow-wrap: anywhere; }
.ai-chip .icon { width: 16px; height: 16px; flex: none; }
.ai-chip .icon-button { width: 28px; height: 28px; border: 0; }
.ai-empty { margin: auto; text-align: center; max-width: 560px; padding: var(--space-6) 0; }
.ai-empty h2 { margin: var(--space-3) 0 var(--space-2); }
.ai-empty p { color: var(--muted); margin: 0 0 var(--space-4); }
.ai-empty-icon { display: inline-flex; width: 52px; height: 52px; border-radius: 16px; align-items: center; justify-content: center; background: var(--gradient-brand); color: #fff; }
.ai-empty-icon .icon { width: 26px; height: 26px; }
.ai-examples { display: grid; gap: var(--space-2); }
.ai-example { text-align: left; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--paper); color: var(--ink); font: inherit; cursor: pointer; min-height: 44px; }
.ai-example:hover { border-color: var(--violet); }
.ai-composer { border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--paper); padding: 10px 10px 6px; box-shadow: var(--shadow-soft); }
.ai-composer:focus-within { border-color: var(--violet); }
.ai-composer textarea { width: 100%; border: 0; resize: none; background: transparent; color: var(--ink); font: inherit; font-size: 16px; line-height: 1.5; padding: 4px 6px; outline: none; max-height: 240px; }
.ai-composer-bar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ai-composer-bar .icon-button { width: 40px; height: 40px; cursor: pointer; }
.ai-composer-bar .icon-button.recording { background: #fde2e1; border-color: #f4a09b; color: #b42318; }
.ai-send { margin-left: auto; }
.ai-composer-bar .icon-button.primary { background: var(--violet); border-color: var(--violet); color: #fff; }
:root[data-color-scheme="dark"] .ai-composer-bar .icon-button.primary { color: #16131f; }
.ai-composer-bar .icon-button.primary:disabled { opacity: 0.5; }
.ai-composer-bar > .button { margin-left: auto; }
.ai-model { min-height: 40px; max-width: 220px; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--paper); color: var(--ink); padding: 0 8px; font: inherit; font-size: 14px; }
.ai-limit { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; color: var(--muted); }
.ai-limit input { width: 76px; min-height: 40px; border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--paper); color: var(--ink); padding: 0 8px; font: inherit; font-size: 14px; }
.ai-limit .icon, .ai-limit svg { width: 18px; height: 18px; }
.ai-fine { margin: 6px 4px 0; }
.ai-limit.capped input { border-color: #d92d20; box-shadow: 0 0 0 1px #d92d20; }
.ai-limit-note { margin: 6px 4px 0; font-size: 13px; color: #b42318; }
.ai-limit-note a { color: inherit; font-weight: 600; }
:root[data-color-scheme="dark"] .ai-limit-note { color: #ff9b8a; }
:root[data-color-scheme="dark"] .ai-limit.capped input { border-color: #ff9b8a; box-shadow: 0 0 0 1px #ff9b8a; }
.ai-used { margin: calc(-1 * var(--space-2)) 0 0; color: var(--muted); font-size: 13px; }
@media (max-width: 960px) {
  .ai-layout { grid-template-columns: minmax(0, 1fr); }
  .ai-apps { display: none; max-height: none; }
  .ai-layout.list-open .ai-apps { display: block; }
  .ai-layout.list-open .ai-chat { display: none; }
  .ai-all-apps { display: inline-flex; }
}
@media (max-width: 760px) {
  .ai-chat { height: max(420px, calc(100dvh - 250px)); }
  .ai-chat-head { gap: 6px; padding-bottom: var(--space-2); }
  .ai-chat-title { flex-basis: 0; }
  .ai-chat-title h2 { font-size: 16px; }
  .ai-head-word { display: none; }
  .ai-head-actions { width: 100%; }
  .ai-stop-label { display: none; }
  .ai-composer-bar > .ai-stop { padding: 0; width: 40px; justify-content: center; }
  .ai-bubble { max-width: 92%; }
  .ai-model { flex: 1 1 0; min-width: 0; max-width: none; white-space: nowrap; text-overflow: ellipsis; }
  .ai-composer-bar { gap: 4px; flex-wrap: nowrap; }
  .ai-composer-bar > * { flex: none; }
  .ai-composer-bar > .ai-model { flex: 1 1 0; padding-right: 26px; }
  .ai-limit .icon, .ai-limit svg { display: none; }
  .ai-limit span { display: none; }
  .ai-limit input { width: 56px; padding: 0 6px; appearance: textfield; }
  .ai-limit input::-webkit-inner-spin-button, .ai-limit input::-webkit-outer-spin-button { appearance: none; margin: 0; }
}

/* App page Versions dialog: every saved source ZIP, newest first. */
.version-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.version-row { padding: var(--space-3) 0; border-top: 1px solid var(--line); }
.version-row:first-child { border-top: 0; padding-top: 0; }
.version-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.version-meta { margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.version-note { margin: 6px 0 0; padding: 6px 10px; border-left: 3px solid var(--violet-light); color: var(--ink); font-size: 14px; overflow-wrap: anywhere; }
.version-warning { display: flex; align-items: center; gap: 4px; margin: 6px 0 0; color: #b54708; font-size: 13px; }
.version-warning > .icon { width: 16px; height: 16px; flex: none; }
:root[data-color-scheme="dark"] .version-warning { color: #fec84b; }
.version-row .detail-actions { margin-top: var(--space-2); }
.version-changes { margin-top: var(--space-2); padding: var(--space-2) var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--base); }
.version-changes p { margin: 0 0 6px; }
.version-change-group h4 { margin: 8px 0 4px; font-size: 13px; }
.version-change-group ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.version-change-group li { display: flex; align-items: baseline; gap: 6px; font-size: 13px; min-width: 0; }
.version-change-group code { font-family: var(--font-mono); font-size: 12px; overflow-wrap: anywhere; }
.version-mark { flex: none; width: 12px; text-align: center; font-weight: 700; }
.version-mark.added { color: var(--green); }
.version-mark.removed { color: #b42318; }
:root[data-color-scheme="dark"] .version-mark.removed { color: #ff9b8a; }
.source-versions > .button { margin-top: var(--space-3); }
