/*
 * Desktop workspace navigation prototype.
 *
 * Wide screens use one global, collapsible navigation rail. Search, saved
 * creators, and filters remain page-level tools in a separate drawer. Tablets
 * and phones use the same hamburger drawer instead of a third navigation mode.
 */

.workspace-sidebar {
  display: contents;
}

.desktop-sidebar-label,
.desktop-sidebar-toggle,
.desktop-sidebar-mark,
.desktop-sidebar-identity,
.desktop-context-toggle,
.desktop-context-backdrop,
.desktop-context-head,
.profile-filter-trigger {
  display: none;
}

.desktop-sidebar-identity[hidden],
.desktop-context-toggle[hidden],
.desktop-context-backdrop[hidden] {
  display: none !important;
}

.desktop-nav-group {
  display: contents;
}

.desktop-nav-group-label {
  display: none;
}

.workspace-sidebar .role-switch {
  display: none !important;
}

.app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] {
  grid-template-columns: minmax(0, 1fr) !important;
}

.app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] .web-sidebar,
.app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] .web-workspace,
.app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] .web-feed-controls {
  display: none !important;
}

.app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] .web-discovery {
  grid-column: 1 / -1 !important;
  grid-row: 2 !important;
  display: block;
  min-width: 0;
  min-height: 0;
  overflow: auto;
}

.app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] .web-video-pane {
  display: block;
  width: 100%;
  min-height: 100%;
  overflow: visible;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-page {
  display: grid;
  align-content: start;
  gap: 18px;
  min-height: 100%;
  padding: 0;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-hero,
.app-shell[data-screen="app"][data-role="client"] .brand-account-card {
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: #ffffff;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-hero {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-hero > header {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-hero img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: #ffffff;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-hero h1 {
  margin: 4px 0;
  color: var(--ink);
  font: 900 clamp(38px, 4vw, 58px)/0.95 var(--font-heading);
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-hero p,
.app-shell[data-screen="app"][data-role="client"] .brand-account-card p {
  margin: 0;
  color: var(--ink-dim);
  line-height: 1.5;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-card {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 20px;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-type-card > div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 24px;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-type-card svg {
  width: 24px;
  height: 24px;
  color: var(--accent);
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-card dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-card dl > div {
  display: grid;
  gap: 3px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-card dt {
  color: var(--ink-faint);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-card dd {
  margin: 0;
  color: var(--ink);
  font-weight: 800;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.app-shell[data-screen="app"][data-role="client"] .brand-account-platforms span {
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(107, 63, 160, 0.1);
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

/* A creator profile is a destination, never a permanent second column. */
.app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] {
  grid-template-columns: minmax(0, 1fr) !important;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-sidebar,
.app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-aside {
  display: none !important;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-main {
  grid-column: 1 !important;
  width: 100% !important;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-page {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 300px);
  align-items: start;
  gap: 18px;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-primary,
.app-shell[data-screen="app"][data-role="creator"] .creator-profile-account-card {
  min-width: 0;
  padding: 22px;
  border: 2px solid var(--ink);
  border-radius: 8px;
  background: #ffffff;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-primary .creator-profile-card {
  gap: 22px !important;
  border: 0 !important;
  box-shadow: none !important;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-account-card {
  display: grid;
  gap: 16px;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-account-card > div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 20px;
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-account-card > div svg {
  width: 22px;
  height: 22px;
  color: var(--accent);
}

.app-shell[data-screen="app"][data-role="creator"] .creator-profile-account-card p {
  margin: 0;
  color: var(--ink-dim);
  font-size: 14px;
  line-height: 1.5;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-card {
  display: grid;
  gap: 18px;
  padding: 22px;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: #ffffff;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-head {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-head > img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: #ffffff;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-identity {
  min-width: 0;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-identity h1 {
  margin: 4px 0;
  color: var(--ink);
  font: 900 clamp(30px, 3vw, 44px)/0.95 var(--font-heading);
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-identity p,
.app-shell[data-screen="app"][data-role="client"] .profile-overview-bio {
  margin: 0;
  color: var(--ink-dim);
  line-height: 1.45;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-actions .deal-action {
  width: auto;
  min-width: 112px;
  padding: 0 14px;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 0 10px;
  border: 0;
  background: transparent;
  color: var(--ink-dim);
  font-weight: 800;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-back:hover {
  color: var(--accent);
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-meta > div {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(168, 213, 186, 0.16);
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-meta span {
  color: var(--ink-faint);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-meta strong {
  color: var(--ink);
  font-size: 15px;
}

.app-shell[data-screen="app"][data-role="client"] .profile-overview-tags {
  margin: 0;
}

@media (max-width: 900px) {
  .app-shell[data-screen="app"][data-role="creator"] .creator-profile-page {
    grid-template-columns: minmax(0, 1fr);
  }

  .app-shell[data-screen="app"][data-role="client"] .profile-overview-head {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .app-shell[data-screen="app"][data-role="client"] .profile-overview-head > img {
    width: 58px;
    height: 58px;
  }

  .app-shell[data-screen="app"][data-role="client"] .profile-overview-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .app-shell[data-screen="app"][data-role="client"] .profile-overview-meta {
    grid-template-columns: minmax(0, 1fr);
  }

  .app-shell[data-screen="app"][data-role="client"] .brand-account-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (min-width: 1000px) {
  .app-shell[data-screen="app"] {
    --workspace-sidebar-width: 224px;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] {
    --workspace-sidebar-width: 64px;
  }

  .app-shell[data-screen="app"] .web-stage,
  .app-shell[data-screen="app"][data-role="client"] .web-stage {
    grid-template-columns: var(--workspace-sidebar-width) minmax(320px, 1fr) minmax(280px, 420px) !important;
    grid-template-rows: minmax(0, 1fr) !important;
    gap: 16px !important;
    transition: grid-template-columns 180ms ease;
  }

  /* Global navigation rail. */
  .app-shell[data-screen="app"] .workspace-sidebar {
    position: relative;
    z-index: 90;
    grid-column: 1;
    grid-row: 1;
    display: block;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-topbar {
    position: relative;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto minmax(0, 1fr) auto !important;
    gap: 12px !important;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    margin: 0 !important;
    padding: 20px !important;
    overflow: visible;
    border: 2px solid var(--ink) !important;
    border-radius: 8px !important;
    background: var(--panel-solid, #ffffff) !important;
    box-shadow: 8px 8px 0 rgba(107, 63, 160, 0.12) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-menu-panel {
    display: contents !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .mobile-menu-button,
  .app-shell[data-screen="app"] .workspace-sidebar .mobile-menu-backdrop,
  .app-shell[data-screen="app"] .workspace-sidebar .mobile-menu-head {
    display: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-toggle {
    position: absolute;
    top: 20px;
    right: -15px;
    z-index: 8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 2px solid var(--ink);
    border-radius: 999px;
    background: #ffffff;
    color: var(--ink);
    box-shadow: 3px 3px 0 rgba(107, 63, 160, 0.18);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-toggle:hover {
    background: var(--accent-2);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-toggle svg {
    width: 16px;
    height: 16px;
  }

  .app-shell[data-screen="app"] .desktop-sidebar-toggle-expand {
    display: none;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-brand {
    grid-column: 1;
    grid-row: 1;
    justify-self: start !important;
    width: fit-content;
    padding: 2px 0 8px;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-brand .site-logo {
    width: auto;
    height: 36px;
    max-width: 148px;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-mark {
    display: none;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-identity:not([hidden]) {
    grid-column: 1;
    grid-row: 2;
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    width: 100%;
    min-width: 0;
    min-height: 52px;
    padding: 6px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--ink);
    text-align: left;
    box-shadow: none;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-identity:hover {
    border-color: rgba(107, 63, 160, 0.34);
    background: rgba(168, 213, 186, 0.26);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-identity.is-active {
    border-color: rgba(107, 63, 160, 0.5);
    background: rgba(107, 63, 160, 0.1);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-sidebar-identity img {
    width: 38px;
    height: 38px;
    object-fit: cover;
    border: 1px solid var(--line-strong);
    border-radius: 7px;
    background: #ffffff;
  }

  .app-shell[data-screen="app"] .desktop-sidebar-identity-name {
    overflow: hidden;
    font-size: 14px;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .app-shell[data-screen="app"] .desktop-sidebar-label {
    display: none;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-top-actions,
  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] .workspace-sidebar .web-top-actions {
    grid-column: 1;
    grid-row: 3;
    align-self: start;
    justify-self: stretch;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr);
    gap: 6px !important;
    width: 100% !important;
    max-width: none !important;
    padding: 0 !important;
    overflow: visible;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-nav-group {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
    width: 100%;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-nav-group + .desktop-nav-group {
    margin-top: 12px;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-nav-group.compact-only-nav-group {
    display: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .desktop-nav-group-label {
    display: block;
    padding: 0 8px 5px;
    color: var(--ink-faint);
    font-family: "Geist Mono", ui-monospace, monospace;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.08em;
    line-height: 1;
    text-transform: uppercase;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-filter-button,
  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] .workspace-sidebar .web-filter-button {
    display: flex;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
    min-width: 0 !important;
    min-height: 46px;
    padding: 0 14px !important;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: var(--ink-dim);
    box-shadow: none;
    font-size: 14px;
    text-align: left;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-filter-button svg {
    flex: 0 0 auto;
    width: 19px;
    height: 19px;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-filter-button:hover {
    border-color: rgba(107, 63, 160, 0.14);
    background: rgba(168, 213, 186, 0.3);
    color: var(--ink);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-filter-button.is-active {
    border-color: var(--accent);
    background: var(--accent);
    color: #ffffff;
    box-shadow: 0 8px 18px rgba(107, 63, 160, 0.2);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-account-actions,
  .app-shell[data-screen="app"][data-role="creator"] .workspace-sidebar .web-account-actions {
    grid-column: 1;
    grid-row: 4;
    align-self: end;
    justify-self: stretch;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
    min-width: 0;
    padding-top: 14px;
    border-top: 1px solid var(--line);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-account-actions::before {
    content: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .role-switch,
  .app-shell[data-screen="app"][data-role="creator"] .workspace-sidebar .role-switch {
    display: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .app-logout-button,
  .app-shell[data-screen="app"][data-role="creator"] .workspace-sidebar .app-logout-button {
    justify-content: flex-start;
    gap: 12px;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 44px !important;
    height: auto !important;
    padding: 0 14px;
    border: 1px solid var(--line-strong) !important;
    border-radius: 8px !important;
    background: #ffffff;
    box-shadow: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .app-logout-button:hover {
    border-color: rgba(107, 63, 160, 0.42) !important;
    background: rgba(255, 212, 163, 0.34);
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="expanded"] .workspace-sidebar .app-logout-button span {
    display: inline !important;
  }

  /* Page-level tools: independent from the global navigation rail. */
  .app-shell[data-screen="app"] .desktop-context-toggle:not([hidden]) {
    position: fixed;
    top: 50%;
    left: calc(18px + var(--workspace-sidebar-width) + 16px);
    z-index: 55;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 0 14px;
    border: 2px solid var(--ink);
    border-radius: 0 999px 999px 0;
    background: #ffffff;
    color: var(--ink);
    font-weight: 800;
    box-shadow: 4px 4px 0 rgba(107, 63, 160, 0.14);
    transform: translateY(-50%);
    transition: left 180ms ease, opacity 160ms ease;
  }

  .app-shell[data-screen="app"] .desktop-context-toggle svg {
    width: 18px;
    height: 18px;
  }

  .app-shell[data-screen="app"] .desktop-context-toggle:hover {
    background: var(--accent-2);
  }

  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] > .desktop-context-toggle {
    display: none !important;
  }

  .app-shell[data-screen="app"] .brand-package-storefront-actions {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
  }

  .app-shell[data-screen="app"] .brand-package-storefront-actions > strong {
    padding: 7px 10px;
    border: 1px solid #d6cde2;
    border-radius: 999px;
    color: var(--ink-dim);
    font-size: 12px;
  }

  .app-shell[data-screen="app"] .profile-filter-trigger {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 34px;
    padding: 0 11px;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    background: #ffffff;
    color: var(--ink);
    font-size: 12px;
    font-weight: 800;
  }

  .app-shell[data-screen="app"] .profile-filter-trigger:hover {
    border-color: rgba(107, 63, 160, 0.42);
    background: var(--accent-2);
  }

  .app-shell[data-screen="app"] .profile-filter-trigger svg {
    width: 15px;
    height: 15px;
  }

  .app-shell[data-screen="app"].desktop-context-open .desktop-context-toggle {
    opacity: 0;
    pointer-events: none;
  }

  .app-shell[data-screen="app"] .desktop-context-backdrop:not([hidden]) {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: block;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(42, 31, 61, 0.16);
  }

  .app-shell[data-screen="app"] .web-stage > .web-sidebar {
    position: fixed !important;
    top: 18px;
    bottom: 18px;
    left: calc(18px + var(--workspace-sidebar-width) + 16px);
    z-index: 80;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto auto auto minmax(0, 1fr) auto auto !important;
    align-content: start !important;
    gap: 12px !important;
    width: min(340px, calc(100vw - var(--workspace-sidebar-width) - 70px));
    min-width: 0;
    min-height: 0;
    padding: 16px !important;
    overflow: hidden !important;
    border: 2px solid var(--ink) !important;
    border-radius: 8px !important;
    background: #ffffff !important;
    box-shadow: 12px 12px 0 rgba(107, 63, 160, 0.14) !important;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(-12px);
    transition: left 180ms ease, opacity 160ms ease, transform 160ms ease, visibility 160ms ease;
  }

  .app-shell[data-screen="app"].desktop-context-open .web-stage > .web-sidebar {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(0);
  }

  .app-shell[data-screen="app"] .web-stage:not([data-focus="discover"]):not([data-focus="saved"]):not([data-focus="profile"]) > .web-sidebar,
  .app-shell[data-screen="app"][data-role="creator"] .web-stage > .web-sidebar {
    display: none !important;
  }

  .app-shell[data-screen="app"] .desktop-context-head {
    order: -10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
    color: var(--ink);
    font-size: 15px;
    font-weight: 900;
  }

  .app-shell[data-screen="app"] .desktop-context-head button {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 1px solid var(--line-strong);
    border-radius: 7px;
    background: #ffffff;
    color: var(--ink);
  }

  .app-shell[data-screen="app"] .web-stage > .web-sidebar .web-search {
    min-height: 42px;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: none;
  }

  .app-shell[data-screen="app"] .web-stage > .web-sidebar .web-category-list {
    max-height: none;
    overflow-y: auto;
  }

  .app-shell[data-screen="app"] .web-stage > .web-sidebar .web-category-button,
  .app-shell[data-screen="app"] .web-stage > .web-sidebar .web-creator-row,
  .app-shell[data-screen="app"] .web-stage > .web-sidebar .web-saved-row,
  .app-shell[data-screen="app"] .web-stage > .web-sidebar .client-filter-section {
    box-shadow: none;
  }

  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] > .web-sidebar .web-saved-label,
  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] > .web-sidebar .web-saved-list,
  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] > .web-sidebar .web-ranked-label,
  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="profile"] > .web-sidebar .web-creator-list {
    display: none !important;
  }

  /* Main content placement after the global navigation rail. */
  .app-shell[data-screen="app"] .web-discovery {
    grid-column: 2;
    grid-row: 1;
  }

  .app-shell[data-screen="app"] .web-workspace {
    grid-column: 3;
    grid-row: 1;
  }

  .app-shell[data-screen="app"][data-role="client"] .web-stage:is(
      [data-focus="campaigns"],
      [data-focus="purchases"],
      [data-focus="profile"],
      [data-focus="brand-account"],
      [data-focus="brand-onboarding"],
      [data-focus="inbox"],
      [data-focus="deal"]
    ) {
    grid-template-columns: var(--workspace-sidebar-width) minmax(0, 1fr) !important;
  }

  .app-shell[data-screen="app"][data-role="client"] .web-stage:is(
      [data-focus="campaigns"],
      [data-focus="purchases"],
      [data-focus="profile"],
      [data-focus="brand-account"],
      [data-focus="brand-onboarding"]
    ) .web-discovery {
    grid-column: 2 / -1 !important;
    grid-row: 1 !important;
  }

  .app-shell[data-screen="app"][data-role="client"] .web-stage[data-focus="brand-account"] .web-discovery {
    grid-column: 2 / -1 !important;
    grid-row: 1 !important;
  }

  .app-shell[data-screen="app"][data-role="client"] .web-stage:is([data-focus="inbox"], [data-focus="deal"]) .web-workspace {
    grid-column: 2 / -1 !important;
    grid-row: 1 !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .web-stage {
    grid-template-columns: var(--workspace-sidebar-width) minmax(0, 1fr) !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-stage {
    grid-column: 2 / -1 !important;
    grid-row: 1 !important;
    min-width: 0;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 14px !important;
    padding: 0 !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-main {
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 24px !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-main-head h1 {
    font-size: clamp(52px, 4.5vw, 64px) !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-main-head p {
    max-width: 640px !important;
    font-size: 17px !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-stage[data-mode="workspace"] .creator-main-head.creator-packages-head {
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: end !important;
    gap: 20px !important;
    min-height: 150px !important;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-packages-head .creator-head-actions {
    justify-content: flex-end !important;
    width: auto;
  }

  .app-shell[data-screen="app"][data-role="creator"] .creator-packages-head .creator-head-actions .deal-action {
    width: 164px !important;
    min-width: 164px !important;
    height: 48px !important;
  }

  /* Compact icon rail. */
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-topbar {
    grid-template-rows: auto auto minmax(0, 1fr) auto !important;
    gap: 12px !important;
    padding: 16px 6px !important;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-brand {
    justify-self: center !important;
    padding: 0;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-brand .site-logo {
    display: none;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .desktop-sidebar-mark {
    display: block;
    width: 42px;
    height: 42px;
    object-fit: contain;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .desktop-sidebar-toggle-collapse {
    display: none;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .desktop-sidebar-toggle-expand {
    display: inline-flex;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .desktop-sidebar-identity:not([hidden]) {
    grid-row: 2;
    justify-self: center;
    display: grid;
    grid-template-columns: 40px;
    place-items: center;
    width: 48px;
    min-height: 48px;
    padding: 3px;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .desktop-sidebar-identity img {
    width: 40px;
    height: 40px;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .desktop-sidebar-identity-name,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .desktop-sidebar-label,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-filter-label,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .app-logout-button span {
    display: none !important;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-top-actions,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .web-stage[data-focus="profile"] .workspace-sidebar .web-top-actions {
    grid-row: 3;
    justify-items: center;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .desktop-nav-group {
    justify-items: center;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .desktop-nav-group + .desktop-nav-group {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--line);
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .desktop-nav-group-label {
    display: none;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher-list {
    justify-items: center;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher-option,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher > button {
    grid-template-columns: 1fr;
    place-items: center;
    width: 48px;
    min-height: 48px;
    padding: 0;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher-option > span,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher > button > span,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .company-switcher > small {
    display: none;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-filter-button,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .web-stage[data-focus="profile"] .workspace-sidebar .web-filter-button {
    justify-content: center;
    width: 48px;
    min-height: 48px;
    padding: 0 !important;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .web-account-actions,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"][data-role="creator"] .workspace-sidebar .web-account-actions {
    grid-row: 4;
    justify-items: center;
    padding-top: 12px;
  }

  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"] .workspace-sidebar .app-logout-button,
  .app-shell[data-screen="app"][data-desktop-sidebar="collapsed"][data-role="creator"] .workspace-sidebar .app-logout-button {
    justify-content: center;
    width: 48px !important;
    min-width: 48px !important;
    height: 48px !important;
    min-height: 48px !important;
    padding: 0;
  }
}

@media (max-width: 999px) {
  html:has(.app-shell[data-screen="app"]),
  body:has(.app-shell[data-screen="app"]) {
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .app-shell[data-screen="app"] {
    position: relative;
    inset: auto;
    height: auto;
    min-height: 100svh;
    overflow: visible;
  }

  .app-shell[data-screen="app"] .web-stage,
  .app-shell[data-screen="app"][data-role="client"] .web-stage,
  .app-shell[data-screen="app"][data-role="creator"] .web-stage {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: 84px auto !important;
    align-content: start;
    width: 100%;
    height: auto;
    min-height: calc(100svh - 24px);
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-topbar {
    grid-column: 1 / -1 !important;
    grid-row: auto !important;
    height: 84px !important;
    min-height: 84px !important;
    background: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  .app-shell[data-screen="app"] .creator-stage {
    grid-column: 1 / -1 !important;
    grid-row: auto !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-menu-panel .role-switch {
    display: none !important;
  }

  .app-shell[data-screen="app"] .workspace-sidebar .web-menu-panel .web-account-actions {
    grid-template-rows: minmax(0, 1fr) !important;
  }
}

@media (max-width: 599px) {
  .app-shell[data-screen="app"] {
    padding-inline: 10px !important;
  }
}

@media (max-width: 560px) {
  .app-shell[data-screen="app"] .web-stage,
  .app-shell[data-screen="app"][data-role="client"] .web-stage,
  .app-shell[data-screen="app"][data-role="creator"] .web-stage {
    display: grid !important;
    min-height: 100svh;
  }

  .app-shell[data-screen="app"] .phone-stage {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .app-shell[data-screen="app"] .web-stage,
  .desktop-context-toggle,
  .web-stage > .web-sidebar {
    transition: none !important;
  }
}
