:root {
  --backdrop-image: url("./assets/f3d-painterly-night.webp");
  --paper: #07111f;
  --panel: rgba(7, 17, 31, 0.66);
  --panel-soft: rgba(10, 22, 38, 0.54);
  --ink: #f7fbff;
  --muted: #c4cfdd;
  --line: rgba(245, 214, 130, 0.2);
  --line-strong: rgba(245, 214, 130, 0.34);
  --mint: #f3c95f;
  --mint-dark: #ffe08a;
  --coral: #ff8b6d;
  --amber: #f1b84d;
  --violet: #74a8ff;
  --graphite: rgba(9, 19, 33, 0.76);
  --glass: rgba(7, 17, 31, 0.56);
  --glass-strong: rgba(7, 17, 31, 0.72);
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
  --radius: 8px;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  background: #07111f;
  color: var(--ink);
  font-family:
    Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  letter-spacing: 0;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}

body::before {
  z-index: -2;
  background-image: var(--backdrop-image);
  background-position: center;
  background-size: cover;
  transform: scale(1.02);
}

body::after {
  z-index: -1;
  background:
    radial-gradient(circle at 50% 26%, rgba(255, 214, 113, 0.12), transparent 30%),
    linear-gradient(90deg, rgba(3, 8, 14, 0.84), rgba(4, 10, 20, 0.48) 46%, rgba(3, 8, 14, 0.82)),
    linear-gradient(180deg, rgba(2, 6, 12, 0.28), rgba(2, 6, 12, 0.82));
}

body[data-view="studio"] .community-view,
body:not([data-view="studio"]) .left-panel,
body:not([data-view="studio"]) .workspace,
body:not([data-view="studio"]) .quote-panel {
  display: none;
}

body:not([data-view="studio"]) .app-shell {
  grid-template-columns: 1fr;
  grid-template-areas:
    "top"
    "community";
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
  display: grid;
  gap: 12px;
  grid-template-columns: 320px minmax(420px, 1fr) 360px;
  grid-template-rows: 58px minmax(0, 1fr);
  grid-template-areas:
    "top top top"
    "left workspace right";
  padding: 12px;
}

.topbar {
  grid-area: top;
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
  padding: 10px 16px;
  background: rgba(13, 17, 23, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
  z-index: 3;
}

.product-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.nav-button {
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
}

.nav-button.active {
  background: var(--graphite);
  color: #ffffff;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 170px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  background: var(--graphite);
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
}

.brand strong,
.brand span {
  display: block;
  line-height: 1.15;
}

.brand strong {
  font-size: 16px;
}

.brand span {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

.topbar-stats {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
}

.topbar-stats span,
.topbar-stats strong {
  min-width: 86px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  text-align: center;
  white-space: nowrap;
}

.topbar-stats strong {
  color: var(--ink);
  min-width: 120px;
}

.side-panel {
  min-height: 0;
  overflow-y: auto;
  background: var(--panel);
  border-right: 1px solid var(--line);
}

.left-panel {
  grid-area: left;
}

.quote-panel {
  grid-area: right;
  border-right: 0;
  border-left: 1px solid var(--line);
}

.community-view {
  grid-area: community;
  min-height: 0;
  overflow-y: auto;
  padding: 22px;
  background: var(--paper);
}

.community-layout {
  width: min(1180px, 100%);
  margin: 0 auto;
}

.community-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.community-header h1 {
  margin: 0 0 4px;
  font-size: 28px;
  line-height: 1.1;
}

.community-header p {
  margin: 0;
  color: var(--muted);
}

.feed-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.feed-card,
.creator-card,
.publication-card,
.wallet-card,
.map-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.feed-card {
  display: grid;
  overflow: hidden;
}

.model-preview {
  min-height: 170px;
  display: grid;
  place-items: center;
  background:
    linear-gradient(90deg, rgba(139, 148, 158, 0.16) 1px, transparent 1px),
    linear-gradient(rgba(139, 148, 158, 0.16) 1px, transparent 1px),
    var(--panel-soft);
  background-size: 18px 18px;
}

.model-preview.has-photo {
  background-color: var(--panel-soft);
  background-position: center;
  background-size: cover;
}

.model-preview.has-photo .model-preview-shape {
  display: none;
}

.model-preview-shape {
  width: 104px;
  height: 74px;
  border-radius: 8px 8px 4px 4px;
  background: var(--mint);
  box-shadow:
    28px -22px 0 -8px rgba(201, 147, 44, 0.9),
    -22px -10px 0 -12px rgba(216, 104, 76, 0.9);
  transform: skewY(-10deg) rotate(-2deg);
}

.feed-card-body {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.feed-card h3 {
  margin: 0;
  font-size: 17px;
}

.feed-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.feed-assets,
.feed-print-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.asset-pill,
.print-spec {
  min-width: 0;
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.asset-pill {
  color: var(--graphite);
}

.print-spec {
  border-radius: 6px;
}

.feed-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
}

.feed-recommendations,
.project-detail {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.recommendation-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.recommendation-card {
  min-width: 0;
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.recommendation-photo,
.feed-photo-button,
.project-photo {
  width: 100%;
  min-height: 100%;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: inherit;
  cursor: pointer;
}

.feed-photo-button {
  min-height: 170px;
}

.recommendation-photo {
  min-height: 132px;
}

.recommendation-body {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 7px;
  padding: 10px;
}

.recommendation-body strong,
.recommendation-body small {
  display: block;
  min-width: 0;
}

.recommendation-body strong {
  font-size: 14px;
  line-height: 1.2;
}

.recommendation-body small {
  color: var(--muted);
  font-size: 12px;
}

.recommendation-body .command-button {
  min-height: 32px;
  padding: 0 9px;
}

.feed-title-button {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 800;
  text-align: left;
}

.feed-title-button:hover,
.feed-photo-button:hover,
.recommendation-photo:hover,
.project-photo:hover {
  filter: brightness(1.08);
}

.project-back {
  justify-self: start;
}

.project-detail-card,
.project-print-card,
.project-recommendations {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.project-detail-card {
  display: grid;
  grid-template-columns: minmax(280px, 0.92fr) minmax(0, 1.08fr);
  overflow: hidden;
}

.project-photo {
  min-height: 360px;
}

.project-info {
  display: grid;
  align-content: center;
  gap: 14px;
  padding: 18px;
}

.project-info h1 {
  margin: 0;
  font-size: 32px;
  line-height: 1.05;
}

.project-description {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.project-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.project-auth-note {
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 13px;
}

.project-print-card,
.project-recommendations {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.project-spec-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.project-spec-grid div,
.project-notes div {
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.project-spec-grid span,
.project-spec-grid strong,
.project-notes strong,
.project-notes span {
  display: block;
  min-width: 0;
}

.project-spec-grid span,
.project-notes strong {
  color: var(--muted);
  font-size: 12px;
}

.project-spec-grid strong {
  margin-top: 3px;
}

.project-notes {
  display: grid;
  gap: 8px;
}

.project-notes span {
  margin-top: 4px;
  line-height: 1.35;
}

.account-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr) minmax(280px, 360px);
  gap: 12px;
}

.creator-card,
.publication-card,
.wallet-card {
  padding: 16px;
}

.creator-card {
  grid-column: 1;
}

.wallet-card {
  grid-column: 2;
}

.publish-card {
  grid-column: 3;
  grid-row: 1 / span 2;
}

.my-publications-card {
  grid-column: 1 / span 2;
}

.orders-card {
  grid-column: 1 / span 2;
}

.author-flow {
  display: grid;
  gap: 7px;
  margin-top: 14px;
}

.author-flow-step {
  min-height: 38px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.author-flow-step > span {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--line);
  color: var(--muted);
  font-weight: 800;
}

.author-flow-step.done > span {
  background: rgba(88, 214, 189, 0.16);
  color: var(--mint);
}

.author-flow-step strong,
.author-flow-step small {
  display: block;
}

.author-flow-step small {
  color: var(--muted);
  font-size: 12px;
}

.wallet-balance {
  display: grid;
  gap: 4px;
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid rgba(88, 214, 189, 0.28);
  border-radius: var(--radius);
  background: rgba(88, 214, 189, 0.08);
}

.wallet-balance span,
.wallet-balance small {
  color: var(--muted);
  font-size: 12px;
}

.wallet-balance strong {
  font-size: 30px;
  line-height: 1;
}

.checkbox-line {
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.checkbox-line input {
  width: 18px;
  min-height: 18px;
  padding: 0;
}

.wallet-message {
  min-height: 36px;
  display: grid;
  align-content: center;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 12px;
}

.wallet-ledger {
  display: grid;
  gap: 6px;
  margin-top: 12px;
}

.wallet-ledger-row {
  min-height: 42px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.wallet-ledger-row strong,
.wallet-ledger-row span {
  display: block;
  min-width: 0;
}

.wallet-ledger-row span {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

.order-tracker {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  margin-bottom: 10px;
}

.order-track-result,
.order-history {
  display: grid;
  gap: 8px;
}

.order-track-result:not(:empty) {
  margin-bottom: 10px;
}

.order-card {
  display: grid;
  gap: 9px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.order-card.status-cancelled {
  border-color: rgba(216, 104, 76, 0.46);
}

.order-card-head,
.order-card-meta,
.order-history-log div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.order-card-head strong,
.order-card-head span,
.order-card-meta span,
.order-history-log strong,
.order-history-log span {
  display: block;
  min-width: 0;
}

.order-card-head strong {
  font-size: 14px;
}

.order-card-head span,
.order-card-meta,
.order-history-log {
  color: var(--muted);
  font-size: 12px;
}

.order-card-head b {
  flex: 0 0 auto;
  padding: 5px 7px;
  border-radius: 999px;
  background: rgba(88, 214, 189, 0.12);
  color: var(--mint-dark);
  font-size: 11px;
}

.status-cancelled .order-card-head b {
  background: rgba(216, 104, 76, 0.16);
  color: var(--coral);
}

.order-card-meta {
  flex-wrap: wrap;
  justify-content: flex-start;
}

.order-card-meta span {
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
}

.order-timeline {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
}

.order-timeline span {
  height: 5px;
  border-radius: 999px;
  background: var(--line);
}

.order-timeline span.done {
  background: rgba(88, 214, 189, 0.45);
}

.order-timeline span.current {
  background: var(--mint);
}

.order-timeline.cancelled span.current,
.order-timeline.cancelled span.done {
  background: var(--coral);
}

.order-history-log {
  display: grid;
  gap: 4px;
}

.order-history-log strong {
  color: var(--ink);
  font-size: 12px;
  text-align: right;
}

.publish-upload-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.publish-file-drop {
  display: grid;
  place-items: center;
  gap: 7px;
  min-height: 112px;
  padding: 12px;
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--muted);
  text-align: center;
}

.publish-file-drop:focus-within {
  border-color: var(--mint);
  box-shadow: 0 0 0 3px rgba(47, 143, 131, 0.16);
}

.publish-file-drop input {
  display: none;
}

.publish-file-drop svg {
  width: 24px;
  height: 24px;
}

.publish-file-drop span,
.publish-file-drop small {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.publish-file-drop span {
  color: var(--ink);
  font-weight: 800;
}

.publish-file-drop small {
  font-size: 11px;
  white-space: nowrap;
}

.creator-profile {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.creator-avatar {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  background: var(--graphite);
  color: #ffffff;
  font-weight: 800;
}

.creator-avatar.has-photo {
  background-position: center;
  background-size: cover;
}

.creator-profile strong,
.creator-profile span {
  display: block;
}

.creator-profile span {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

.telegram-auth-panel {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.telegram-auth-panel strong,
.telegram-auth-panel span {
  display: block;
  min-width: 0;
}

.telegram-auth-panel strong {
  font-size: 13px;
}

.telegram-auth-panel span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  margin-top: 3px;
}

.telegram-auth-panel.authenticated {
  border-color: rgba(88, 214, 189, 0.42);
  background: rgba(88, 214, 189, 0.08);
}

.telegram-login-slot {
  min-height: 40px;
  display: grid;
  align-items: center;
  overflow: hidden;
}

.map-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.map-card {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.map-card span {
  color: var(--muted);
  line-height: 1.4;
}

.panel-section {
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.section-title h2 {
  margin: 0;
  font-size: 15px;
  line-height: 1.2;
}

.section-title span {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.drop-zone {
  display: grid;
  place-items: center;
  gap: 7px;
  min-height: 124px;
  padding: 18px;
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel-soft);
  text-align: center;
  color: var(--muted);
  transition:
    border-color 160ms ease,
    background 160ms ease,
    color 160ms ease;
}

.drop-zone.drag-over {
  border-color: var(--mint);
  background: rgba(88, 214, 189, 0.12);
  color: var(--mint-dark);
}

.drop-zone input {
  display: none;
}

.drop-zone i,
.drop-zone svg {
  width: 28px;
  height: 28px;
}

.drop-zone span {
  color: var(--ink);
  font-weight: 700;
}

.drop-zone small {
  font-size: 12px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.metric-grid.compact {
  margin-top: 10px;
}

.metric-grid div {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.metric-grid span,
.metric-grid strong {
  display: block;
  min-width: 0;
}

.metric-grid span {
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 4px;
}

.metric-grid strong {
  font-size: 14px;
  overflow-wrap: anywhere;
}

.plate-panel {
  display: grid;
  gap: 9px;
  margin-top: 12px;
}

.plate-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  gap: 8px;
  align-items: center;
}

.plate-list {
  display: grid;
  gap: 6px;
}

.plate-tab {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--ink);
  text-align: left;
}

.plate-tab.active {
  border-color: var(--mint);
  background: rgba(88, 214, 189, 0.1);
}

.plate-tab strong,
.plate-tab span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.plate-tab strong {
  font-size: 13px;
}

.plate-tab span {
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
}

.plate-tab em {
  font-style: normal;
  padding: 5px 7px;
  border-radius: 999px;
  background: var(--panel);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.tool-button,
.command-button,
.icon-button {
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--ink);
  transition:
    transform 120ms ease,
    border-color 120ms ease,
    background 120ms ease;
}

.tool-button:hover,
.command-button:hover,
.icon-button:hover {
  border-color: var(--mint);
  background: rgba(88, 214, 189, 0.1);
}

.tool-button:active,
.command-button:active,
.icon-button:active {
  transform: translateY(1px);
}

.tool-button {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 9px;
  min-height: 42px;
  padding: 9px 10px;
  border-radius: var(--radius);
}

.tool-button svg,
.command-button svg,
.icon-button svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: var(--radius);
}

.command-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--radius);
  font-weight: 700;
  white-space: nowrap;
}

.command-button.accent {
  border-color: var(--mint);
  background: var(--mint);
  color: #ffffff;
}

.command-button.accent:hover {
  background: var(--mint-dark);
  border-color: var(--mint-dark);
}

.full-width {
  width: 100%;
}

.inline-actions,
.button-group,
.transform-toolbar,
.arrange-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.transform-toolbar {
  display: grid;
  grid-template-columns: repeat(4, 36px);
  justify-content: space-between;
}

.arrange-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 10px;
}

.arrange-actions .command-button {
  min-width: 0;
  padding: 0 8px;
}

.empty-state {
  min-height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  background: var(--panel-soft);
  font-size: 13px;
}

.controls-stack {
  display: grid;
  gap: 11px;
}

.controls-stack label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.controls-stack label > span {
  color: var(--muted);
  font-size: 12px;
}

input,
select,
textarea {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--ink);
  padding: 8px 10px;
  outline: none;
}

textarea {
  resize: vertical;
  min-height: 88px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--mint);
  box-shadow: 0 0 0 3px rgba(47, 143, 131, 0.16);
}

input[type="range"] {
  min-height: 24px;
  padding: 0;
  accent-color: var(--mint);
}

.swatch-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.swatch {
  height: 32px;
  border: 1px solid rgba(240, 243, 246, 0.18);
  border-radius: var(--radius);
}

.swatch.mint {
  background: var(--mint);
}

.swatch.coral {
  background: var(--coral);
}

.swatch.amber {
  background: var(--amber);
}

.swatch.graphite {
  background: var(--graphite);
}

.object-list {
  display: grid;
  gap: 6px;
}

.object-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.object-row.active {
  border-color: var(--mint);
  background: rgba(88, 214, 189, 0.1);
}

.object-row button {
  min-width: 0;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  text-align: left;
}

.object-row strong,
.object-row span {
  display: block;
  min-width: 0;
}

.object-row strong {
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.object-row span {
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
}

.color-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(240, 243, 246, 0.2);
}

.workspace {
  grid-area: workspace;
  min-width: 0;
  min-height: 0;
  position: relative;
  overflow: hidden;
  background: #0b0f14;
}

#scene-root {
  position: absolute;
  inset: 0;
}

#scene-root canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}

#scene-root canvas.is-dragging {
  cursor: grabbing;
}

.viewport-toolbar,
.scene-footer {
  position: absolute;
  left: 14px;
  right: 14px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  pointer-events: none;
}

.viewport-toolbar {
  top: 14px;
}

.scene-footer {
  bottom: 14px;
}

.viewport-toolbar > *,
.scene-footer > * {
  pointer-events: auto;
}

.scene-status,
.scene-footer span {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 8px 10px;
  border: 1px solid rgba(188, 199, 194, 0.75);
  border-radius: var(--radius);
  background: rgba(22, 27, 34, 0.82);
  color: var(--muted);
  font-size: 12px;
  backdrop-filter: blur(12px);
}

#scene-warning:not(:empty) {
  color: #f0745f;
  border-color: rgba(216, 104, 76, 0.5);
  background: rgba(74, 28, 22, 0.9);
}

.segmented {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 3px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.segmented button {
  min-width: 0;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
}

.segmented button.active {
  background: var(--graphite);
  color: #ffffff;
}

.cad-mode {
  grid-template-columns: repeat(2, 1fr);
  margin-bottom: 10px;
}

.sketch-mode {
  margin-bottom: 10px;
}

.cad-sketch-tools {
  display: grid;
  gap: 10px;
}

#sketch-canvas {
  width: 100%;
  aspect-ratio: 13 / 9;
  display: block;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #0b0f14;
  cursor: crosshair;
}

.sketch-controls {
  gap: 9px;
}

.sketch-actions {
  display: grid;
  grid-template-columns: 36px 36px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.sketch-status {
  min-height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 12px;
}

.split-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 9px;
}

.advanced-print-settings {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.advanced-print-settings summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 8px 10px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.advanced-print-settings .controls-stack {
  padding: 0 10px 10px;
}

.toggle-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
}

.toggle-list label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--ink);
}

.toggle-list input {
  width: 18px;
  min-height: 18px;
  accent-color: var(--mint);
}

.fulfillment-note {
  min-height: 42px;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid rgba(88, 214, 189, 0.32);
  border-radius: var(--radius);
  background: rgba(88, 214, 189, 0.1);
  color: var(--mint-dark);
  font-size: 13px;
  line-height: 1.25;
}

.fulfillment-note svg {
  width: 18px;
  height: 18px;
}

.quote-summary {
  background: var(--panel);
}

.price-line {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.price-line span {
  color: var(--muted);
}

.price-line strong {
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1;
  text-align: right;
}

.cost-breakdown {
  display: grid;
  gap: 6px;
  margin-top: 12px;
}

.cost-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 30px;
  color: var(--muted);
  font-size: 13px;
  border-bottom: 1px solid var(--line);
}

.cost-row:last-child {
  border-bottom: 0;
}

.cost-label {
  position: relative;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cost-help {
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--muted);
}

.cost-help svg {
  width: 12px;
  height: 12px;
}

.cost-tooltip {
  position: absolute;
  left: 0;
  bottom: calc(100% + 8px);
  z-index: 5;
  width: min(270px, 78vw);
  display: none;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(7, 17, 31, 0.96);
  color: #ffffff;
  box-shadow: var(--shadow);
  font-size: 12px;
  line-height: 1.35;
}

.cost-label:focus-within .cost-tooltip,
.cost-label:hover .cost-tooltip {
  display: block;
}

.slice-summary {
  width: 100%;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--ink);
  text-align: left;
}

.slice-summary span,
.slice-summary strong,
.slice-summary small {
  display: block;
  min-width: 0;
}

.slice-summary small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.slice-summary b {
  flex: 0 0 auto;
  padding: 6px 8px;
  border-radius: 999px;
  background: rgba(116, 168, 255, 0.16);
  color: #b9d1ff;
  font-size: 12px;
}

.slice-summary.active {
  border-color: var(--mint);
}

.quote-panel.checkout-closed .delivery-section,
.quote-panel.checkout-closed .order-section {
  display: none;
}

.checkout-cta-wrap {
  position: sticky;
  bottom: 0;
  z-index: 3;
  margin-top: 12px;
  padding-top: 10px;
  background: linear-gradient(180deg, transparent, var(--panel) 36%);
}

.checkout-cta {
  min-height: 48px;
}

.delivery-section {
  background: var(--panel);
}

.delivery-result {
  min-height: 42px;
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 13px;
}

.delivery-result strong {
  color: var(--ink);
  font-size: 16px;
}

.check-section {
  background: var(--panel);
}

.section-title span[data-status="ok"] {
  color: var(--mint);
}

.section-title span[data-status="warning"] {
  color: var(--amber);
}

.section-title span[data-status="danger"] {
  color: var(--coral);
}

.check-list {
  display: grid;
  gap: 6px;
}

.check-item {
  min-height: 42px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.check-item > span {
  width: 22px;
  height: 22px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--line);
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}

.check-item strong,
.check-item small {
  display: block;
}

.check-item small {
  color: var(--muted);
  font-size: 12px;
}

.check-item.ok > span {
  background: rgba(88, 214, 189, 0.16);
  color: var(--mint);
}

.check-item.info > span {
  background: rgba(66, 125, 166, 0.16);
  color: #79c0ff;
}

.check-item.warning > span {
  background: rgba(211, 151, 55, 0.18);
  color: var(--amber);
}

.check-item.danger > span {
  background: rgba(216, 104, 76, 0.18);
  color: var(--coral);
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 10;
  max-width: min(380px, calc(100vw - 36px));
  min-height: 42px;
  display: none;
  align-items: center;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--graphite);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.toast.visible {
  display: flex;
}

/* Painterly glass theme */
.topbar,
.side-panel,
.workspace,
.feed-card,
.recommendation-card,
.project-detail-card,
.project-print-card,
.project-recommendations,
.creator-card,
.publication-card,
.wallet-card,
.map-card,
.order-card,
.panel-section,
.telegram-auth-panel,
.publish-file-drop,
.drop-zone,
.metric-grid div,
.object-row,
.toast {
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px) saturate(1.18);
}

.topbar {
  border-bottom: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(7, 17, 31, 0.64);
}

.product-nav,
.topbar-stats span,
.topbar-stats strong {
  border-color: var(--line);
  background: rgba(247, 251, 255, 0.08);
}

.nav-button {
  border-radius: 999px;
}

.nav-button.active {
  background: rgba(243, 201, 95, 0.18);
  color: #fff5d2;
}

.brand-mark {
  background:
    linear-gradient(135deg, rgba(255, 224, 138, 0.94), rgba(116, 168, 255, 0.74)),
    rgba(247, 251, 255, 0.08);
  color: #07111f;
  box-shadow: 0 10px 28px rgba(243, 201, 95, 0.24);
}

.side-panel {
  background: var(--glass-strong);
  border-right: 1px solid var(--line);
  border-radius: var(--radius);
}

.quote-panel {
  border-left: 1px solid var(--line);
}

.community-view {
  background: transparent;
}

.workspace {
  border-radius: var(--radius);
  background: rgba(4, 10, 19, 0.48);
  isolation: isolate;
}

.workspace::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(180deg, rgba(6, 13, 24, 0.42), rgba(6, 13, 24, 0.76)),
    var(--backdrop-image) center / cover;
  opacity: 0.58;
}

#scene-root {
  z-index: 1;
}

.viewport-toolbar,
.scene-footer {
  z-index: 2;
}

.panel-section {
  background: rgba(7, 17, 31, 0.38);
  border-right: 0;
  border-left: 0;
  box-shadow: none;
}

.feed-card,
.recommendation-card,
.project-detail-card,
.project-print-card,
.project-recommendations,
.creator-card,
.publication-card,
.wallet-card,
.map-card,
.order-card,
.telegram-auth-panel,
.publish-file-drop,
.drop-zone,
.metric-grid div,
.object-row {
  background: rgba(8, 18, 32, 0.62);
}

.feed-card:hover,
.object-row.active,
.drop-zone.drag-over,
.publish-file-drop:focus-within {
  border-color: var(--line-strong);
  background: rgba(14, 30, 52, 0.72);
}

.model-preview {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255, 224, 138, 0.16), rgba(116, 168, 255, 0.18)),
    rgba(7, 17, 31, 0.62);
}

.model-preview::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 70% 20%, rgba(255, 224, 138, 0.24), transparent 32%);
  pointer-events: none;
}

input,
select,
textarea {
  border-color: var(--line);
  background: rgba(2, 8, 16, 0.5);
  color: var(--ink);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--mint);
  box-shadow: 0 0 0 3px rgba(243, 201, 95, 0.16);
}

.command-button,
.icon-button {
  border-color: var(--line);
  background: rgba(247, 251, 255, 0.08);
  color: var(--ink);
}

.command-button:hover,
.icon-button:hover {
  border-color: var(--line-strong);
  background: rgba(247, 251, 255, 0.12);
}

.command-button.accent {
  border-color: rgba(255, 224, 138, 0.64);
  background: linear-gradient(135deg, rgba(243, 201, 95, 0.98), rgba(255, 224, 138, 0.88));
  color: #07111f;
}

.command-button.accent:hover {
  background: linear-gradient(135deg, #ffe08a, #f3c95f);
}

.check-item.ok > span {
  background: rgba(243, 201, 95, 0.16);
  color: var(--mint-dark);
}

.check-item.info > span {
  background: rgba(116, 168, 255, 0.18);
  color: #b9d1ff;
}

.toast {
  background: rgba(7, 17, 31, 0.86);
}

@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 310px minmax(420px, 1fr);
    grid-template-rows: 64px minmax(460px, 1fr) auto;
    grid-template-areas:
      "top top"
      "left workspace"
      "right right";
  }

  .quote-panel {
    border-left: 0;
    border-top: 1px solid var(--line);
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow: visible;
  }

  .quote-panel .panel-section {
    border-right: 1px solid var(--line);
    border-bottom: 0;
  }

  .feed-grid,
  .map-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .recommendation-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-detail-card {
    grid-template-columns: 1fr;
  }

  .project-photo {
    min-height: 320px;
  }

  .account-layout {
    grid-template-columns: 1fr;
  }

  .creator-card,
  .wallet-card,
  .publish-card,
  .my-publications-card,
  .orders-card {
    grid-column: auto;
    grid-row: auto;
  }
}

@media (max-width: 820px) {
  .app-shell {
    height: auto;
    grid-template-columns: 1fr;
    grid-template-rows: auto 70vh auto auto;
    overflow: visible;
    grid-template-areas:
      "top"
      "workspace"
      "left"
      "right";
  }

  .topbar {
    flex-wrap: wrap;
  }

  .product-nav {
    order: 2;
    flex: 1 1 auto;
    overflow-x: auto;
  }

  .topbar-stats {
    order: 4;
    flex: 0 0 100%;
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
  }

  .topbar-stats span,
  .topbar-stats strong {
    min-width: max-content;
  }

  .side-panel,
  .quote-panel {
    border-left: 0;
    border-right: 0;
    overflow: visible;
  }

  .quote-panel {
    display: block;
  }

  .quote-panel .panel-section {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .community-view {
    padding: 14px;
  }

  .community-header {
    align-items: stretch;
    flex-direction: column;
  }

  .feed-grid,
  .map-grid {
    grid-template-columns: 1fr;
  }

  .recommendation-strip,
  .project-spec-grid {
    grid-template-columns: 1fr;
  }

  .project-info h1 {
    font-size: 26px;
  }

  .project-actions {
    display: grid;
  }

  .viewport-toolbar,
  .scene-footer {
    left: 10px;
    right: 10px;
  }

  .scene-status {
    display: none;
  }
}

@media (max-width: 480px) {
  .panel-section {
    padding: 14px;
  }

  .brand {
    min-width: 0;
  }

  .command-button {
    padding: 0 10px;
  }

  .tool-grid,
  .metric-grid,
  .publish-upload-grid,
  .split-row {
    grid-template-columns: 1fr;
  }

  .scene-footer {
    align-items: stretch;
    flex-direction: column;
  }
}

/* Product dashboard architecture */
@media (min-width: 1101px) {
  body::after {
    background:
      radial-gradient(circle at 48% 18%, rgba(255, 214, 113, 0.1), transparent 25%),
      linear-gradient(90deg, rgba(3, 8, 14, 0.62), rgba(245, 248, 252, 0.9) 210px, rgba(246, 249, 253, 0.78) 62%, rgba(3, 8, 14, 0.66)),
      linear-gradient(180deg, rgba(2, 6, 12, 0.2), rgba(2, 6, 12, 0.58));
  }

  .app-shell {
    grid-template-columns: 188px 300px minmax(430px, 1fr) 316px;
    grid-template-rows: minmax(0, 1fr);
    grid-template-areas: "top left workspace right";
    gap: 14px;
    padding: 14px;
  }

  body:not([data-view="studio"]) .app-shell {
    grid-template-columns: 188px minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    grid-template-areas: "top community";
  }

  .topbar {
    min-height: 0;
    height: calc(100vh - 28px);
    align-self: stretch;
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
    padding: 18px 14px;
    border-radius: 0;
    background: rgba(3, 12, 25, 0.94);
    border-color: rgba(116, 168, 255, 0.24);
    box-shadow: 20px 0 70px rgba(0, 0, 0, 0.28);
  }

  .brand {
    min-width: 0;
    align-items: center;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .product-nav,
  .sidebar-extra-nav {
    display: grid;
    gap: 6px;
    padding: 0;
    border: 0;
    background: transparent;
  }

  .sidebar-extra-nav {
    padding-top: 4px;
    border-top: 1px solid rgba(247, 251, 255, 0.08);
  }

  .nav-button,
  .sidebar-link {
    min-height: 38px;
    width: 100%;
    justify-content: flex-start;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 0 10px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: #c7d3e4;
    font-size: 13px;
    font-weight: 700;
    text-align: left;
  }

  .nav-button svg,
  .sidebar-link svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
  }

  .nav-button.active,
  .nav-button:hover,
  .sidebar-link:hover {
    border-color: rgba(116, 168, 255, 0.24);
    background: rgba(46, 111, 255, 0.24);
    color: #ffffff;
  }

  .topbar-stats {
    flex: 0 0 auto;
    width: 100%;
    display: grid;
    gap: 7px;
    margin-top: auto;
    color: #c7d3e4;
  }

  .topbar-stats span,
  .topbar-stats strong {
    min-width: 0;
    width: 100%;
    padding: 9px 10px;
    border-color: rgba(116, 168, 255, 0.2);
    background: rgba(247, 251, 255, 0.07);
    text-align: left;
  }

  .topbar-stats strong {
    color: #ffffff;
  }

  #top-order-button {
    width: 100%;
    justify-content: center;
  }

  .left-panel,
  .workspace,
  .quote-panel,
  .community-view {
    border-radius: 12px;
  }

  .left-panel,
  .quote-panel {
    background: rgba(255, 255, 255, 0.74);
    color: #0d1726;
    border-color: rgba(9, 19, 33, 0.1);
    box-shadow: 0 24px 70px rgba(7, 17, 31, 0.16);
  }

  .left-panel .panel-section,
  .quote-panel .panel-section {
    background: rgba(255, 255, 255, 0.42);
    border-color: rgba(9, 19, 33, 0.09);
    box-shadow: none;
  }

  .left-panel h2,
  .quote-panel h2,
  .left-panel strong,
  .quote-panel strong {
    color: #0b1220;
  }

  .left-panel span,
  .quote-panel span,
  .left-panel small,
  .quote-panel small,
  .quote-panel .check-item small {
    color: #5c6675;
  }

  .workspace {
    background: rgba(247, 250, 255, 0.62);
    border-color: rgba(9, 19, 33, 0.12);
    box-shadow: 0 24px 70px rgba(7, 17, 31, 0.18);
  }

  .workspace::before {
    background:
      linear-gradient(180deg, rgba(247, 250, 255, 0.54), rgba(235, 241, 250, 0.74)),
      var(--backdrop-image) center / cover;
    opacity: 0.52;
  }

  .community-view {
    padding: 24px;
    background: rgba(247, 250, 255, 0.68);
    color: #0d1726;
    border: 1px solid rgba(9, 19, 33, 0.08);
    box-shadow: 0 24px 70px rgba(7, 17, 31, 0.16);
  }

  .community-layout {
    width: min(1220px, 100%);
  }

  #feed-view .community-header {
    position: relative;
    min-height: 238px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    align-items: center;
    overflow: hidden;
    padding: 28px;
    border: 1px solid rgba(9, 19, 33, 0.08);
    border-radius: 12px;
    background:
      linear-gradient(110deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.62)),
      rgba(255, 255, 255, 0.72);
    box-shadow: 0 20px 60px rgba(7, 17, 31, 0.1);
  }

  #feed-view .community-header::after {
    content: "";
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: stretch;
    min-height: 190px;
    border-radius: 12px;
    background:
      radial-gradient(circle at 58% 42%, rgba(116, 168, 255, 0.28), transparent 38%),
      linear-gradient(135deg, rgba(13, 23, 38, 0.1), rgba(255, 255, 255, 0.7)),
      var(--backdrop-image) center / cover;
    box-shadow: inset 0 0 0 1px rgba(9, 19, 33, 0.08);
  }

  #feed-view .community-header h1 {
    max-width: 440px;
    color: #0b1220;
    font-size: 31px;
  }

  #feed-view .community-header p {
    max-width: 470px;
    color: #556171;
  }

  #feed-view .community-header .command-button {
    grid-column: 1;
    justify-self: start;
  }

  #feed-view .community-header > div {
    grid-column: 1;
  }

  .feed-recommendations,
  .feed-workflow {
    margin-top: 18px;
  }

  .feed-card,
  .recommendation-card,
  .project-detail-card,
  .project-print-card,
  .project-recommendations,
  .workflow-step,
  .creator-card,
  .publication-card,
  .wallet-card,
  .map-card,
  .order-card {
    background: rgba(255, 255, 255, 0.78);
    border-color: rgba(9, 19, 33, 0.08);
    box-shadow: 0 16px 44px rgba(7, 17, 31, 0.08);
  }

  .feed-card h3,
  .feed-title-button,
  .recommendation-body strong,
  .project-info h1,
  .project-spec-grid strong,
  .project-notes span,
  .community-header h1,
  .workflow-step strong {
    color: #0b1220;
  }

  .feed-card p,
  .feed-meta,
  .recommendation-body small,
  .project-description,
  .project-auth-note,
  .workflow-step span {
    color: #596678;
  }

  .asset-pill,
  .print-spec,
  .project-spec-grid div,
  .project-notes div,
  .project-auth-note {
    background: rgba(244, 247, 252, 0.88);
    border-color: rgba(9, 19, 33, 0.08);
  }

  .left-panel input,
  .left-panel select,
  .left-panel textarea,
  .quote-panel input,
  .quote-panel select,
  .quote-panel textarea,
  .community-view input,
  .community-view select,
  .community-view textarea {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(9, 19, 33, 0.12);
    color: #0b1220;
  }

  .left-panel .command-button:not(.accent),
  .left-panel .icon-button,
  .quote-panel .command-button:not(.accent),
  .quote-panel .icon-button,
  .community-view .command-button:not(.accent),
  .community-view .icon-button {
    background: rgba(255, 255, 255, 0.88);
    border-color: rgba(9, 19, 33, 0.12);
    color: #0b1220;
  }

  .left-panel .command-button.accent,
  .quote-panel .command-button.accent,
  .community-view .command-button.accent,
  #top-order-button {
    border-color: rgba(46, 111, 255, 0.42);
    background: linear-gradient(135deg, #2e6fff, #1857d9);
    color: #ffffff;
  }

  .left-panel .command-button.accent:hover,
  .quote-panel .command-button.accent:hover,
  .community-view .command-button.accent:hover,
  #top-order-button:hover {
    background: linear-gradient(135deg, #4a83ff, #2465f0);
  }

  .asset-pill {
    color: #2e6fff;
  }

  .quote-panel .price-line span,
  .quote-panel .metric-grid span,
  .quote-panel .cost-row,
  .quote-panel .section-title span,
  .quote-panel .slice-summary small {
    color: #3f4a5a;
  }

  .quote-panel .cost-row strong,
  .quote-panel .price-line strong,
  .quote-panel .slice-summary strong {
    color: #0b1220;
  }

  .quote-panel .slice-summary,
  .quote-panel .cost-help {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(9, 19, 33, 0.12);
    color: #0b1220;
  }

  .quote-panel .slice-summary b {
    background: rgba(46, 111, 255, 0.12);
    color: #1857d9;
  }

  .quote-panel .cost-tooltip {
    background: #0b1220;
    color: #ffffff;
  }

  .quote-panel .checkout-cta-wrap {
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.96) 36%);
  }

  .left-panel .drop-zone,
  .left-panel .metric-grid div,
  .left-panel .object-row,
  .left-panel .tool-button,
  .left-panel .segmented,
  .left-panel .sketch-status,
  .quote-panel .metric-grid div,
  .quote-panel .toggle-list label,
  .quote-panel .advanced-print-settings,
  .quote-panel .fulfillment-note,
  .quote-panel .delivery-result,
  .quote-panel .check-item,
  .quote-panel .cost-breakdown div {
    background: rgba(255, 255, 255, 0.86);
    border-color: rgba(9, 19, 33, 0.1);
    color: #0b1220;
  }

  .left-panel .tool-button,
  .left-panel .segmented button,
  .quote-panel .segmented button,
  .quote-panel .toggle-list label {
    color: #4d5a6b;
  }

  .left-panel .segmented button.active,
  .quote-panel .segmented button.active {
    background: #102033;
    color: #ffffff;
  }

  .workflow-steps {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
  }

  .workflow-step {
    min-width: 0;
    display: grid;
    gap: 10px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
  }

  .workflow-visual {
    width: 100%;
    aspect-ratio: 1.75;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background:
      linear-gradient(135deg, rgba(46, 111, 255, 0.14), rgba(243, 201, 95, 0.2)),
      rgba(255, 255, 255, 0.82);
    color: #2e6fff;
  }

  .workflow-visual svg {
    width: 30px;
    height: 30px;
  }

  .workflow-step strong,
  .workflow-step span {
    display: block;
    min-width: 0;
  }

  .workflow-step span {
    margin-top: 5px;
    font-size: 12px;
    line-height: 1.35;
  }
}

@media (max-width: 1100px) {
  .sidebar-extra-nav {
    display: none;
  }
}

@media (max-width: 900px) {
  .app-shell,
  body[data-view="studio"] .app-shell,
  body:not([data-view="studio"]) .app-shell {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(520px, 72vh) auto auto;
    grid-template-areas:
      "top"
      "workspace"
      "left"
      "right";
    padding: 12px;
  }

  body:not([data-view="studio"]) .app-shell {
    grid-template-rows: auto minmax(0, 1fr);
    grid-template-areas:
      "top"
      "community";
  }

  .topbar {
    height: auto;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
  }

  .product-nav {
    order: 3;
    flex: 1 1 100%;
    overflow-x: auto;
  }

  .nav-button {
    white-space: nowrap;
  }

  .topbar-stats {
    order: 4;
  }

  .recommendation-strip,
  .workflow-steps {
    grid-template-columns: 1fr;
  }

  #feed-view .community-header {
    display: grid;
    gap: 14px;
  }
}
