:root {
  --ink: #17140e;
  --muted: #746f62;
  --line: #ddd6c7;
  --bg: #f7f4ed;
  --panel: #ffffff;
  --accent: #a7792b;
  --accent-2: #b73535;
  --gold: #d6a847;
  --blue: #315f9f;
  --charcoal: #11100d;
  --shadow: 0 18px 50px rgba(23, 20, 14, 0.08);
}

/* Payment, membership and entitlement center */
.membership-commerce-hero,
.payment-result-panel,
.membership-orders,
.payment-provider-status,
.admin-payment-center,
.locked-resource-page {
  border: 1px solid rgba(180, 142, 66, 0.28);
  border-radius: 24px;
  background: color-mix(in srgb, var(--panel, #ffffff) 94%, #d6aa54 6%);
  box-shadow: 0 18px 48px rgba(20, 24, 35, 0.08);
}

.membership-commerce-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  gap: 28px;
  align-items: center;
  padding: clamp(24px, 5vw, 54px);
  margin-bottom: 24px;
}

.membership-commerce-hero h2 {
  margin: 6px 0 14px;
  font-size: clamp(30px, 4vw, 54px);
}

.membership-status-card {
  padding: 24px;
  border-radius: 20px;
  background: rgba(18, 24, 34, 0.92);
  color: #fff;
}

.membership-status-card.is-active {
  background: linear-gradient(145deg, #32230a, #9b6b20);
}

.membership-status-card span,
.membership-status-card p {
  display: block;
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.76);
}

.membership-status-card strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

.membership-plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 20px;
  margin: 24px 0;
}

.membership-pricing-shell {
  --membership-cyan: #55d8ff;
  --membership-blue: #3178ff;
  --membership-panel: #141719;
  --membership-panel-soft: #1b1f22;
  display: flow-root;
  min-width: 0;
  padding: clamp(18px, 3vw, 38px);
  border: 1px solid rgba(123, 159, 183, 0.16);
  border-radius: 28px;
  background:
    radial-gradient(circle at 78% 8%, rgba(51, 121, 183, 0.18), transparent 25%),
    linear-gradient(180deg, #080a0c 0%, #050607 60%, #090b0d 100%);
  color: #f7f9fb;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.28);
}

.membership-pricing-shell .membership-commerce-hero {
  position: relative;
  overflow: hidden;
  margin-bottom: 24px;
  border-color: rgba(100, 187, 227, 0.18);
  background:
    linear-gradient(90deg, rgba(12, 23, 31, 0.97), rgba(18, 38, 52, 0.82) 56%, rgba(15, 22, 27, 0.96)),
    url("/media/workbench/studio-bg-scifi.jpg") center / cover;
  box-shadow: none;
}

.membership-pricing-shell .membership-commerce-hero h2,
.membership-pricing-shell .membership-commerce-hero p {
  color: inherit;
}

.membership-pricing-shell .membership-commerce-hero p {
  max-width: 760px;
  color: rgba(241, 247, 250, 0.76);
}

.membership-rate-badge {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: center;
  padding: 11px 16px;
  margin-top: 12px;
  border: 1px solid rgba(85, 216, 255, 0.42);
  border-radius: 999px;
  background: rgba(9, 21, 29, 0.78);
}

.membership-rate-badge strong {
  color: var(--membership-cyan);
  font-size: 18px;
}

.membership-rate-badge span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.membership-kind-tabs {
  display: flex;
  justify-content: center;
  gap: clamp(28px, 8vw, 90px);
  margin: 8px 0 26px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.11);
}

.membership-kind-tabs button {
  position: relative;
  min-width: 150px;
  padding: 14px 20px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.58);
  font: inherit;
  font-size: 18px;
  cursor: pointer;
}

.membership-kind-tabs button.is-active {
  color: #fff;
  font-weight: 700;
}

.membership-kind-tabs button.is-active::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: #fff;
  content: "";
}

.membership-cycle-tabs {
  display: flex;
  width: fit-content;
  max-width: 100%;
  padding: 3px;
  margin: 0 auto 24px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
  background: #202223;
}

.membership-cycle-tabs button {
  min-width: 138px;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(255, 255, 255, 0.66);
  font: inherit;
  cursor: pointer;
}

.membership-cycle-tabs button.is-active {
  background: #3c3e40;
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.membership-pricing-intro {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
}

.membership-pricing-intro div {
  display: grid;
  gap: 4px;
}

.membership-pricing-intro strong {
  color: #fff;
  font-size: 15px;
}

.membership-pricing-shell .membership-plan-grid {
  grid-template-columns: repeat(5, minmax(168px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding: 4px 2px 14px;
  scrollbar-color: rgba(85, 216, 255, 0.55) rgba(255, 255, 255, 0.08);
}

.membership-pricing-shell .membership-plan-card {
  min-width: 168px;
  min-height: 520px;
  gap: 16px;
  padding: 24px clamp(16px, 1.3vw, 22px);
  border-color: rgba(255, 255, 255, 0.11);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.045), transparent 48%),
    #17191a;
  color: #f8f9fa;
}

.membership-pricing-shell .membership-plan-card.is-featured {
  border-color: rgba(85, 216, 255, 0.46);
  background:
    linear-gradient(145deg, rgba(46, 139, 190, 0.16), transparent 48%),
    #14202a;
  box-shadow: none;
}

.membership-pricing-shell .membership-plan-card.is-premium {
  border-color: rgba(49, 120, 255, 0.68);
  background:
    linear-gradient(145deg, rgba(49, 120, 255, 0.22), transparent 54%),
    #101b2c;
}

.membership-plan-heading {
  display: flex;
  gap: 12px;
  align-items: start;
  justify-content: space-between;
}

.membership-plan-heading > div {
  display: grid;
  gap: 8px;
}

.membership-plan-heading span {
  min-height: 36px;
  color: rgba(255, 255, 255, 0.52);
  font-size: 12px;
  line-height: 1.5;
}

.membership-plan-heading h3 {
  font-size: 24px;
}

.membership-plan-heading > b {
  flex: 0 0 auto;
  padding: 6px 9px;
  border-radius: 8px;
  background: rgba(85, 216, 255, 0.13);
  color: var(--membership-cyan);
  font-size: 12px;
}

.membership-pricing-shell .membership-price {
  flex-wrap: wrap;
  gap: 6px;
}

.membership-pricing-shell .membership-price strong {
  font-size: clamp(34px, 3vw, 46px);
  letter-spacing: -0.04em;
}

.membership-pricing-shell .membership-price span,
.membership-pricing-shell .membership-price del {
  color: rgba(255, 255, 255, 0.52);
  font-size: 13px;
}

.membership-seat-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
}

.membership-seat-row > div {
  display: flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.membership-seat-row button {
  width: 32px;
  height: 30px;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.membership-seat-row strong {
  min-width: 64px;
  text-align: center;
}

.membership-seat-row > b {
  grid-column: 1 / -1;
  color: #fff;
  text-align: right;
}

.membership-points-value {
  display: grid;
  gap: 5px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.2);
}

.membership-points-value span,
.membership-points-value small {
  color: rgba(255, 255, 255, 0.55);
  font-size: 12px;
}

.membership-points-value strong {
  color: #fff;
  font-size: 22px;
}

.membership-pricing-shell .membership-plan-card ul {
  gap: 7px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
  line-height: 1.5;
}

@media (min-width: 761px) and (max-width: 1400px) {
  .membership-pricing-shell .membership-plan-card {
    padding: 22px 14px;
  }

  .membership-plan-heading h3 {
    font-size: 21px;
  }

  .membership-pricing-shell .membership-price strong {
    font-size: 30px;
  }

  .membership-points-value {
    padding: 12px 10px;
  }

  .membership-points-value strong {
    font-size: 18px;
  }

  .membership-pricing-shell .membership-plan-card ul {
    font-size: 11px;
  }
}

.membership-plan-cta {
  width: 100%;
  min-height: 44px;
  padding: 10px 18px;
  margin-top: auto;
  border: 0;
  border-radius: 999px;
  background: #f7f8f9;
  color: #101214;
  font: inherit;
  font-weight: 750;
  cursor: pointer;
}

.membership-plan-card.is-premium .membership-plan-cta:not(:disabled) {
  background: var(--membership-blue);
  color: #fff;
}

.membership-plan-cta:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.membership-plan-checkout {
  display: grid;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.membership-pricing-shell .payment-agreement-check {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.7);
}

.membership-test-plans {
  margin: 18px 0;
  color: rgba(255, 255, 255, 0.72);
}

.membership-test-plans summary {
  cursor: pointer;
}

.membership-pricing-shell .payment-provider-status,
.membership-pricing-shell .membership-orders,
.membership-pricing-shell .payment-result-panel {
  border-color: rgba(255, 255, 255, 0.1);
  background: #121517;
  color: #f7f9fb;
  box-shadow: none;
}

.membership-pricing-shell .membership-policy-grid article {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.045);
}

.membership-pricing-shell .membership-policy-grid p,
.membership-pricing-shell .membership-order-row span {
  color: rgba(255, 255, 255, 0.62);
}

.membership-plan-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 26px;
  border: 1px solid rgba(132, 139, 154, 0.22);
  border-radius: 22px;
  background: var(--panel, #fff);
}

.membership-plan-card.is-featured {
  border-color: rgba(190, 143, 48, 0.7);
  box-shadow: 0 18px 50px rgba(151, 103, 21, 0.15);
}

.membership-plan-card h3,
.membership-plan-card p,
.membership-plan-card ul {
  margin: 0;
}

.membership-plan-card ul {
  display: grid;
  gap: 8px;
  padding-left: 20px;
}

.membership-price {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.membership-price strong {
  font-size: 36px;
}

.membership-price del {
  opacity: 0.55;
}

.payment-agreement-check {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 9px;
  align-items: start;
  padding: 12px;
  border-radius: 14px;
  background: rgba(132, 139, 154, 0.08);
  font-size: 13px;
  line-height: 1.55;
}

.payment-agreement-check input {
  margin-top: 3px;
}

.payment-provider-actions,
.payment-result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.payment-provider-actions button:disabled {
  cursor: not-allowed;
  filter: grayscale(1);
  opacity: 0.45;
}

.payment-provider-status {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  padding: 18px 22px;
  margin: 18px 0;
}

.payment-result-panel {
  display: grid;
  gap: 20px;
  padding: clamp(22px, 4vw, 36px);
  margin: 24px 0;
  scroll-margin-top: 100px;
}

.payment-qr-card {
  display: grid;
  justify-items: start;
  gap: 10px;
}

.payment-qr-card img {
  width: min(300px, 100%);
  padding: 12px;
  border-radius: 16px;
  background: #fff;
}

.bank-payment-card {
  display: grid;
  gap: 8px;
  padding: 20px;
  border-radius: 18px;
  background: rgba(132, 139, 154, 0.09);
}

.bank-payment-card p,
.bank-payment-card h4 {
  margin: 0;
}

.bank-payment-card form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.bank-payment-card input,
.admin-payment-center input,
.admin-payment-center select,
.admin-payment-center textarea {
  min-width: 0;
  padding: 11px 13px;
  border: 1px solid rgba(132, 139, 154, 0.3);
  border-radius: 10px;
  background: var(--panel, #fff);
  color: inherit;
}

.membership-policy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 26px 0;
}

.membership-policy-grid article {
  padding: 20px;
  border-radius: 18px;
  background: rgba(132, 139, 154, 0.09);
}

.membership-policy-grid p {
  margin-bottom: 0;
  line-height: 1.7;
}

.membership-orders {
  padding: 24px;
}

.membership-order-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 100px 120px auto;
  gap: 14px;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid rgba(132, 139, 154, 0.18);
}

.membership-order-row div {
  display: grid;
  gap: 4px;
}

.membership-order-row span {
  overflow-wrap: anywhere;
}

.locked-resource-page {
  max-width: 880px;
  padding: clamp(24px, 5vw, 52px);
  margin: 30px auto;
}

.locked-resource-page > img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 22px;
}

.payment-admin-row {
  grid-template-columns: minmax(200px, 1.4fr) minmax(160px, 1fr) minmax(150px, 1fr) auto auto;
}

@media (max-width: 760px) {
  .membership-commerce-hero {
    grid-template-columns: 1fr;
  }

  .membership-order-row,
  .payment-admin-row {
    grid-template-columns: 1fr;
  }

  .bank-payment-card form {
    grid-template-columns: 1fr;
  }

  .payment-provider-actions > * {
    flex: 1 1 130px;
    text-align: center;
  }

  .membership-pricing-shell {
    padding: 14px;
    border-radius: 20px;
  }

  .membership-kind-tabs {
    gap: 8px;
  }

  .membership-kind-tabs button {
    min-width: 0;
    flex: 1;
  }

  .membership-cycle-tabs {
    width: 100%;
  }

  .membership-cycle-tabs button {
    min-width: 0;
    flex: 1;
    padding-inline: 8px;
  }

  .membership-pricing-intro {
    display: grid;
  }

  .membership-pricing-shell .membership-plan-grid {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(270px, 86vw);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #f6eddc;
  --muted: #c8b993;
  --line: rgba(255, 224, 150, 0.16);
  --bg: #0b0a08;
  --panel: #15120d;
  --accent: #d6a847;
  --accent-2: #e06a5f;
  --gold: #e0b95d;
  --blue: #7aa7e8;
  --charcoal: #090805;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.32);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

body.guest-mode {
  user-select: none;
}

body.guest-mode input,
body.guest-mode textarea {
  user-select: text;
}

.guest-permission-notice {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  border: 1px solid rgba(214, 168, 71, 0.34);
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.12);
  color: var(--ink);
  padding: 12px 14px;
  box-shadow: var(--shadow);
}

.guest-permission-notice strong {
  color: var(--accent);
}

.guest-permission-notice span {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.guest-membership-callout,
.guest-upgrade-card {
  border: 1px solid rgba(214, 168, 71, 0.38);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.18), rgba(49, 95, 159, 0.08)),
    var(--panel);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.guest-membership-callout {
  display: grid;
  gap: 6px;
  margin-bottom: 18px;
  padding: 16px 18px;
}

.guest-membership-callout strong,
.guest-upgrade-card h3 {
  color: var(--accent);
}

.guest-membership-callout span,
.guest-upgrade-card p {
  color: var(--muted);
  line-height: 1.65;
}

.guest-upgrade-card {
  min-height: 220px;
  display: grid;
  align-content: center;
  gap: 10px;
  padding: 20px;
}

.guest-upgrade-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.guest-upgrade-card h3,
.guest-upgrade-card p {
  margin: 0;
}

body.guest-mode [data-copy],
body.guest-mode [data-copy-current-url],
body.guest-mode a[download] {
  cursor: not-allowed;
  opacity: 0.56;
}

button,
input,
textarea,
select {
  font: inherit;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
}

.sidebar {
  background: #11100d;
  color: #f8f3e7;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.projects-mode .sidebar {
  background: #11100d;
  background-image: none;
}

.projects-mode .community-hero,
.projects-mode .project-source-strip,
.projects-mode .community-card,
.projects-mode .community-image-placeholder,
.projects-mode .project-waterfall-progress span {
  background-image: none;
}

.projects-mode .community-card {
  background-color: #17140f;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.22);
}

.brand-home-link {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  border-radius: 8px;
}

.brand-home-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: #f1efe5;
  color: #11100d;
  font-weight: 800;
  border-radius: 8px;
}

.brand-mark.image-mark {
  overflow: hidden;
  padding: 0;
  border-color: rgba(214, 168, 71, 0.65);
  background: #090805;
  box-shadow: 0 0 0 3px rgba(214, 168, 71, 0.08);
}

.brand-mark.image-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.brand strong,
.brand span {
  display: block;
}

.brand span {
  color: #c9b98e;
  font-size: 13px;
  margin-top: 4px;
}

.nav {
  display: grid;
  gap: 8px;
}

.nav-item {
  border: 0;
  background: transparent;
  color: #e7dfcf;
  text-align: left;
  padding: 11px 12px;
  border-radius: 8px;
  cursor: pointer;
}

.nav-item:hover,
.nav-item.active {
  background: rgba(214, 168, 71, 0.16);
  color: #ffffff;
}

body.clean-ui {
  background:
    radial-gradient(circle at 72% -8%, rgba(214, 168, 71, 0.12), transparent 32%),
    linear-gradient(180deg, var(--bg), color-mix(in srgb, var(--bg) 88%, #000 12%));
}

body.clean-ui .app-shell {
  grid-template-columns: 88px minmax(0, 1fr);
}

body.clean-ui .sidebar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 100vh;
  gap: 16px;
  overflow: hidden;
  padding: 18px 14px;
  transition: width 180ms ease, padding 180ms ease, box-shadow 180ms ease;
}

body.clean-ui .sidebar:hover,
body.clean-ui .sidebar:focus-within {
  width: 260px;
  overflow-y: auto;
  box-shadow: 18px 0 54px rgba(0, 0, 0, 0.24);
}

body.clean-ui .brand {
  min-height: 54px;
  justify-content: center;
  padding-bottom: 10px;
}

body.clean-ui .brand > div:last-child {
  width: 0;
  overflow: hidden;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 160ms ease, width 160ms ease;
}

body.clean-ui .sidebar:hover .brand,
body.clean-ui .sidebar:focus-within .brand {
  justify-content: flex-start;
}

body.clean-ui .sidebar:hover .brand > div:last-child,
body.clean-ui .sidebar:focus-within .brand > div:last-child {
  width: 160px;
  opacity: 1;
}

body.clean-ui .brand-mark {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
}

body.clean-ui .nav {
  gap: 6px;
}

body.clean-ui .nav-item {
  position: relative;
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
  padding: 10px;
  white-space: nowrap;
  font-size: 0;
}

body.clean-ui .nav-item::before {
  content: attr(data-icon);
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  color: #f6d78d;
  background: rgba(255, 255, 255, 0.045);
  font-size: 18px;
  line-height: 1;
}

body.clean-ui .sidebar:hover .nav-item,
body.clean-ui .sidebar:focus-within .nav-item {
  font-size: 15px;
  font-weight: 800;
}

body.clean-ui .nav-item.active::before,
body.clean-ui .nav-item:hover::before {
  border-color: rgba(214, 168, 71, 0.56);
  color: #11100d;
  background: #d6a847;
}

body.clean-ui .cost-rule {
  min-height: 54px;
  display: grid;
  place-items: center;
  margin-top: auto;
  padding: 10px;
}

body.clean-ui .cost-rule::before {
  content: "i";
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 71, 0.26);
  border-radius: 50%;
  color: #f3dfad;
  font-weight: 900;
}

body.clean-ui .cost-rule > * {
  display: none;
}

body.clean-ui .sidebar:hover .cost-rule,
body.clean-ui .sidebar:focus-within .cost-rule {
  place-items: stretch;
}

body.clean-ui .sidebar:hover .cost-rule::before,
body.clean-ui .sidebar:focus-within .cost-rule::before {
  display: none;
}

body.clean-ui .sidebar:hover .cost-rule > *,
body.clean-ui .sidebar:focus-within .cost-rule > * {
  display: block;
}

body.clean-ui .sidebar:hover .cost-rule .legal-mini-links,
body.clean-ui .sidebar:focus-within .cost-rule .legal-mini-links {
  display: grid;
}

body.clean-ui .main {
  padding: 22px 24px 36px;
}

body.clean-ui .topbar {
  min-height: 54px;
  margin-bottom: 16px;
  padding: 10px 12px;
  border: 1px solid rgba(214, 168, 71, 0.12);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 86%, transparent);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(16px);
}

body.clean-ui .topbar .eyebrow,
body.clean-ui .top-logo-home {
  display: none;
}

body.clean-ui .topbar h1 {
  font-size: 24px;
}

body.clean-ui #global-search {
  width: min(360px, 30vw);
  min-height: 42px;
  border-radius: 999px;
}

body.clean-ui .icon-refresh-btn {
  width: 42px;
  min-width: 42px;
  height: 42px;
  overflow: hidden;
  padding: 0;
  border-radius: 50%;
  color: transparent;
}

body.clean-ui .icon-refresh-btn::before {
  content: "↻";
  color: #11100d;
  font-size: 20px;
  font-weight: 900;
}

body.clean-ui .view-root {
  display: grid;
  gap: 18px;
}

body.clean-ui .guest-permission-notice,
body.clean-ui .registered-permission-notice {
  width: fit-content;
  min-height: 0;
  align-items: center;
  margin-bottom: 0;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1;
}

body.clean-ui .guest-permission-notice span,
body.clean-ui .registered-permission-notice span {
  display: none;
}

body.clean-ui:not(.login-index-mode) .eyebrow {
  margin-bottom: 6px;
  font-size: 11px;
  letter-spacing: 0;
  text-transform: uppercase;
}

body.clean-ui .panel,
body.clean-ui .home-section,
body.clean-ui .fusion-section,
body.clean-ui .resource-board-head,
body.clean-ui .community-hero,
body.clean-ui .project-source-strip,
body.clean-ui .admin-data-console,
body.clean-ui .settings-panel,
body.clean-ui .fusion-card,
body.clean-ui .portal-card,
body.clean-ui .masonry-card,
body.clean-ui .admin-board {
  border-radius: 8px;
}

body.clean-ui .panel-header,
body.clean-ui .feed-head,
body.clean-ui .resource-board-head,
body.clean-ui .admin-board-head {
  margin-bottom: 12px;
}

body.clean-ui .feed-head,
body.clean-ui .resource-board-head,
body.clean-ui .panel-header {
  align-items: center;
}

body.clean-ui .feed-head p,
body.clean-ui .panel-header p,
body.clean-ui .resource-board-head p,
body.clean-ui .fusion-hero.compact p:not(.eyebrow),
body.clean-ui .fusion-hero-copy p,
body.clean-ui .fusion-card p,
body.clean-ui .fusion-source-grid p,
body.clean-ui .settings-panel p,
body.clean-ui .learning-pillar-card p,
body.clean-ui .learning-resource-card .portal-body p,
body.clean-ui .portal-body p,
body.clean-ui .masonry-body p,
body.clean-ui .community-hero p:not(.eyebrow),
body.clean-ui .workbench-hero p:not(.eyebrow),
body.clean-ui .workbench-note span,
body.clean-ui .student-hero p,
body.clean-ui .student-lock span,
body.clean-ui .ops-hero p,
body.clean-ui .skill-repo-header p,
body.clean-ui .skill-repo-path em,
body.clean-ui .project-source-strip span,
body.clean-ui .antpower-guide-copy p:not(.eyebrow),
body.clean-ui .ops-gateway-card p,
body.clean-ui .theory-feature-copy p,
body.clean-ui .legal-overview-card p,
body.clean-ui .admin-access p {
  display: none;
}

body.clean-ui .inspiration-rules,
body.clean-ui .director-picks-pending .feed-head p,
body.clean-ui .skill-submit-note,
body.clean-ui .skill-release-note {
  display: none;
}

.inline-info {
  position: relative;
  z-index: 12;
  display: inline-flex;
  align-items: center;
  width: max-content;
  max-width: 100%;
  margin-top: 8px;
}

.inline-info summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 32px;
  min-height: 32px;
  border: 1px solid rgba(216, 168, 75, 0.34);
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(12, 11, 9, 0.8);
  color: #ffd36a;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  list-style: none;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
}

.inline-info summary::-webkit-details-marker {
  display: none;
}

.inline-info summary span {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 211, 106, 0.45);
  font-style: normal;
  line-height: 1;
}

.inline-info summary em {
  color: rgba(255, 247, 228, 0.86);
  font-style: normal;
}

.inline-info[open] {
  z-index: 120;
}

.inline-info > div {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: min(380px, calc(100vw - 48px));
  padding: 14px;
  border: 1px solid rgba(216, 168, 75, 0.34);
  border-radius: 14px;
  background: rgba(12, 11, 9, 0.96);
  color: #fff4da;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(16px);
}

.inline-info > div strong {
  display: block;
  margin-bottom: 6px;
  color: #ffd36a;
  font-size: 14px;
}

.inline-info > div p {
  display: block !important;
  margin: 0 !important;
  color: rgba(255, 247, 228, 0.78) !important;
  font-size: 13px !important;
  line-height: 1.65 !important;
}

body.clean-ui .inline-info,
body.clean-ui .inline-info summary,
body.clean-ui .inline-info > div,
body.clean-ui .inline-info > div p {
  display: inline-flex;
}

body.clean-ui .inline-info > div {
  display: block;
}

body.clean-ui .inline-info > div p {
  display: block !important;
}

body.clean-ui .fusion-hero.compact,
body.clean-ui .resource-board-head,
body.clean-ui .community-hero,
body.clean-ui .workbench-gallery-panel {
  box-shadow: 0 20px 64px rgba(0, 0, 0, 0.16);
}

body.clean-ui .fusion-hero.compact {
  min-height: 168px;
  align-items: center;
  padding: 22px;
}

body.clean-ui .fusion-hero.compact h2,
body.clean-ui .community-hero h2,
body.clean-ui .resource-board-head h2 {
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.05;
}

body.clean-ui .home-section {
  padding: 18px;
  border: 1px solid rgba(214, 168, 71, 0.13);
  background: color-mix(in srgb, var(--panel) 92%, transparent);
}

body.clean-ui .feed-head .hero-btn,
body.clean-ui .feed-head .asset-link,
body.clean-ui .resource-board-head .asset-link,
body.clean-ui .panel-header .asset-link,
body.clean-ui .studio-launch-actions .asset-link,
body.clean-ui .studio-launch-actions .primary-btn {
  min-height: 40px;
}

body.clean-ui .feed-head .hero-btn.ghost,
body.clean-ui .feed-head .asset-link {
  width: 42px;
  min-width: 42px;
  height: 42px;
  overflow: hidden;
  padding: 0;
  border-radius: 50%;
  color: transparent;
}

body.clean-ui .feed-head .hero-btn.ghost::before,
body.clean-ui .feed-head .asset-link::before {
  content: "↗";
  color: var(--accent);
  font-size: 18px;
  font-weight: 900;
}

body.clean-ui .home-card-grid,
body.clean-ui .fusion-card-grid,
body.clean-ui .learning-pillar-grid,
body.clean-ui .ops-gateway-grid {
  gap: 14px;
}

body.clean-ui .portal-card {
  min-height: auto;
  overflow: hidden;
  border-color: rgba(214, 168, 71, 0.15);
  background: #15130f;
  color: #fff7dd;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.18);
}

body.clean-ui .portal-card:hover,
body.clean-ui .masonry-card:hover,
body.clean-ui .fusion-card:hover,
body.clean-ui .settings-panel:hover {
  border-color: rgba(214, 168, 71, 0.56);
  transform: translateY(-2px);
}

body.clean-ui .portal-body {
  padding: 12px;
}

body.clean-ui .portal-body h3,
body.clean-ui .masonry-body h3,
body.clean-ui .fusion-card h3 {
  margin-bottom: 6px;
  line-height: 1.25;
}

body.clean-ui .portal-meta {
  gap: 6px;
}

body.clean-ui .portal-meta span,
body.clean-ui .meta-row .pill,
body.clean-ui .pill {
  border-radius: 999px;
  font-size: 11px;
}

body.clean-ui .fusion-card,
body.clean-ui .settings-panel,
body.clean-ui .admin-board,
body.clean-ui .admin-content-form {
  position: relative;
  overflow: hidden;
  border-color: rgba(214, 168, 71, 0.16);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 38%),
    var(--panel);
  transition: transform 160ms ease, border-color 160ms ease;
}

body.clean-ui .fusion-card > span,
body.clean-ui .settings-panel > span {
  width: fit-content;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--accent);
  background: rgba(214, 168, 71, 0.08);
}

body.clean-ui .settings-section-grid,
body.clean-ui .fusion-card-grid.compact-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

body.clean-ui .settings-panel {
  min-height: 148px;
  align-content: space-between;
}

body.clean-ui .settings-action-row,
body.clean-ui .studio-launch-actions {
  gap: 8px;
}

body.clean-ui .project-source-strip {
  display: none;
}

body.clean-ui .antpower-start-guide {
  display: none;
}

body.clean-ui .admin-access {
  grid-template-columns: minmax(220px, 1fr) auto auto;
  align-items: end;
}

body.clean-ui .admin-access label {
  min-width: 0;
}

body.clean-ui .admin-metrics .metric span,
body.clean-ui .metric p,
body.clean-ui .metric small {
  display: none;
}

body.clean-ui .admin-form-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

body.clean-ui .admin-content-form textarea {
  min-height: 96px;
}

body.clean-ui .legal-document section:last-child {
  display: none;
}

body.clean-ui .fusion-source-grid article {
  min-height: 112px;
}

body.clean-ui .learning-pillar-card {
  overflow: hidden;
  border-radius: 8px;
}

body.clean-ui .view-root {
  gap: 14px;
}

body.clean-ui .main {
  padding: 18px 20px 32px;
}

body.clean-ui .topbar {
  min-height: 48px;
  margin-bottom: 12px;
  padding: 8px 10px;
}

body.clean-ui .topbar h1 {
  font-size: clamp(18px, 1.65vw, 23px);
}

body.clean-ui #global-search {
  width: min(260px, 23vw);
  min-height: 34px;
  padding: 7px 12px;
  font-size: 13px;
  transition: width 160ms ease, border-color 160ms ease;
}

body.clean-ui #global-search:focus {
  width: min(420px, 38vw);
}

body.clean-ui .icon-refresh-btn {
  width: 34px;
  min-width: 34px;
  height: 34px;
}

body.clean-ui .panel,
body.clean-ui .home-section,
body.clean-ui .fusion-section,
body.clean-ui .settings-panel,
body.clean-ui .admin-board,
body.clean-ui .workflow-gateway-section,
body.clean-ui .compute-platform-shell > section {
  padding: 14px;
}

body.clean-ui .feed-head,
body.clean-ui .panel-header,
body.clean-ui .account-canvas-section-head,
body.clean-ui .resource-board-head,
body.clean-ui .admin-board-head {
  min-height: 34px;
  margin-bottom: 8px;
}

body.clean-ui .feed-head h2,
body.clean-ui .panel-header h2,
body.clean-ui .account-canvas-section-head h2,
body.clean-ui .resource-board-head h2 {
  font-size: clamp(20px, 2.2vw, 30px);
}

body.clean-ui :where(.primary-btn, .asset-link, .hero-btn, .copy-btn, .category-chip, .payment-provider-actions button, .canvas-action-row button, .canvas-action-row a, .compute-card-actions .asset-link, .compute-action-row .asset-link) {
  min-height: 30px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1;
}

body.clean-ui :where(.form-grid input, .form-grid select, .admin-access input, .account-canvas-searchbar input, .student-access input, .login-dialog input, .login-index-card input) {
  min-height: 34px;
  padding: 7px 10px;
  border-radius: 12px;
  font-size: 13px;
}

body.clean-ui :where(.form-grid textarea, .admin-content-form textarea, .student-access textarea) {
  min-height: 72px;
  max-height: 120px;
  padding: 8px 10px;
  font-size: 13px;
}

body.clean-ui .category-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
}

body.clean-ui .category-chip {
  flex: 0 0 auto;
}

body.clean-ui .home-card-grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
}

body.clean-ui .portal-card {
  min-height: 190px;
  aspect-ratio: 16 / 10;
}

body.clean-ui .portal-body {
  padding: 42px 10px 10px;
}

body.clean-ui .portal-body h3 {
  font-size: clamp(16px, 1.35vw, 20px);
}

body.clean-ui .portal-meta {
  max-height: 26px;
  overflow: hidden;
}

body.clean-ui .portal-meta span:nth-child(n+4),
body.clean-ui .meta-row .pill:nth-child(n+4) {
  display: none;
}

body.clean-ui .masonry-feed {
  column-gap: 12px;
}

body.clean-ui .masonry-body {
  padding: 10px;
}

body.clean-ui .masonry-body h3 {
  margin: 6px 0 4px;
  font-size: 16px;
  line-height: 1.25;
}

body.clean-ui .creator-line,
body.clean-ui .masonry-body .meta-row,
body.clean-ui .portal-body p,
body.clean-ui .prompt-effect-badge {
  font-size: 11px;
}

body.clean-ui .copy-btn.dark,
body.clean-ui .masonry-body .copy-btn {
  min-height: 28px;
  padding: 5px 9px;
  font-size: 11px;
}

body.clean-ui .inline-info {
  margin-top: 4px;
}

body.clean-ui .inline-info summary {
  min-width: 28px;
  min-height: 28px;
  padding: 4px 8px;
  font-size: 11px;
}

body.clean-ui .inline-info summary span {
  width: 16px;
  height: 16px;
}

body.clean-ui .inline-info > div {
  width: min(300px, calc(100vw - 48px));
  padding: 10px;
}

body.clean-ui .inline-info > div p {
  font-size: 12px !important;
  line-height: 1.5 !important;
}

body.clean-ui .account-canvas-searchbar {
  width: min(360px, 100%);
  min-height: 36px;
  margin-left: auto;
  margin-right: 0;
  padding-inline: 12px;
}

body.clean-ui .account-canvas-recent-strip,
body.clean-ui .account-canvas-gallery {
  gap: 10px;
}

body.clean-ui .account-canvas-card-caption,
body.clean-ui .account-canvas-gallery-caption {
  padding: 8px;
}

body.clean-ui .account-canvas-card-actions button,
body.clean-ui .account-canvas-card-actions span {
  width: 28px;
  height: 28px;
  min-height: 28px;
  padding: 0;
}

body.clean-ui .account-canvas-mini-meta span,
body.clean-ui .compute-provider-models span,
body.clean-ui .cli-mini-meta span,
body.clean-ui .cli-tool-strip span {
  padding: 4px 7px;
  font-size: 11px;
}

body.clean-ui .compute-provider-card {
  min-height: 196px;
  gap: 10px;
  padding: 12px;
}

body.clean-ui .compute-provider-card h3 {
  font-size: 18px;
}

body.clean-ui .compute-provider-card .status-list {
  display: none;
}

body.clean-ui .compute-card-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

body.clean-ui .cli-center-shell {
  max-width: 1180px;
  gap: 10px;
}

body.clean-ui .cli-launch-card {
  min-height: 270px;
  padding: 14px;
  grid-template-columns: minmax(280px, 0.6fr) minmax(360px, 1fr);
}

body.clean-ui .cli-launch-copy h2 {
  font-size: clamp(30px, 4vw, 50px);
}

body.clean-ui .cli-command-block.large {
  min-height: 220px;
}

body.clean-ui .cli-download-card {
  min-height: 84px;
  padding: 12px;
}

body.clean-ui .cli-download-card button,
body.clean-ui .cli-download-card a {
  min-height: 30px;
  padding: 6px 10px;
  font-size: 11px;
}

.cost-rule {
  margin-top: auto;
  padding: 16px;
  border: 1px solid rgba(214, 168, 71, 0.22);
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.08);
}

.cost-rule span {
  color: #c9b98e;
  font-size: 12px;
}

.cost-rule strong {
  display: block;
  margin: 6px 0;
  font-size: 18px;
}

.legal-mini-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.legal-mini-links a {
  min-width: 0;
  border: 1px solid rgba(214, 168, 71, 0.24);
  border-radius: 8px;
  padding: 7px 8px;
  color: #f3dfad;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.04);
}

.legal-mini-links a:hover,
.legal-mini-links a:focus-visible {
  border-color: rgba(214, 168, 71, 0.62);
  color: #fff;
  outline: none;
}

.disabled-link {
  cursor: default;
  opacity: 0.58;
  pointer-events: none;
}

.cost-rule p {
  margin: 0;
  color: #e2d8bf;
  font-size: 13px;
  line-height: 1.6;
}

.cost-rule .content-safety-rule {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(214, 168, 71, 0.2);
  color: #ffe6a7;
  font-weight: 700;
}

:root[data-theme="light"] .sidebar,
:root[data-theme="light"].projects-mode .sidebar {
  background: #ffffff;
  color: #17140e;
  border-right: 1px solid var(--line);
}

:root[data-theme="light"] .brand {
  border-bottom-color: var(--line);
}

:root[data-theme="light"] .brand span,
:root[data-theme="light"] .cost-rule span {
  color: var(--muted);
}

:root[data-theme="light"] .nav-item {
  color: var(--ink);
}

:root[data-theme="light"] .nav-item:hover,
:root[data-theme="light"] .nav-item.active {
  background: rgba(167, 121, 43, 0.12);
  color: var(--ink);
}

:root[data-theme="light"] .cost-rule {
  border-color: var(--line);
  background: #fffaf0;
}

:root[data-theme="light"] .cost-rule p {
  color: var(--muted);
}

:root[data-theme="light"] .cost-rule .content-safety-rule {
  border-top-color: rgba(167, 121, 43, 0.22);
  color: #7c4b00;
}

.platform-info-card p + p {
  margin-top: 5px;
}

.main {
  min-width: 0;
  padding: 28px;
}

.topbar {
  position: relative;
  z-index: 620;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
  overflow: visible;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

h1,
h2,
h3,
p {
  letter-spacing: 0;
}

h1 {
  margin: 0;
  font-size: 30px;
}

h2 {
  margin: 0;
  font-size: 18px;
}

.top-actions {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 10px;
  align-items: center;
  overflow: visible;
}

.top-logo-home {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.5);
  border-radius: 8px;
  background: #090805;
  box-shadow: 0 0 0 3px rgba(214, 168, 71, 0.08);
}

.top-logo-home img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.top-logo-home:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.auth-actions {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow: visible;
}

.auth-btn {
  white-space: nowrap;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: 8px;
  padding: 10px 13px;
  cursor: pointer;
  font-weight: 700;
}

.auth-btn.register {
  color: #fff;
  border-color: var(--charcoal);
  background: var(--charcoal);
}

.top-finance-pill,
.top-avatar-button,
.top-logout-button {
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(214, 168, 71, 0.22);
  background: rgba(17, 16, 13, 0.82);
  color: #fff3d2;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.top-finance-pill {
  gap: 6px;
  border-radius: 14px;
  padding: 0 14px;
}

.top-finance-pill.is-member {
  border-color: rgba(255, 199, 91, 0.28);
  background:
    linear-gradient(135deg, rgba(255, 190, 69, 0.18), rgba(16, 15, 12, 0.88)),
    rgba(17, 16, 13, 0.92);
  color: #ffd879;
}

.top-finance-pill.is-credit {
  min-width: 82px;
  color: #f4f7ff;
}

.top-avatar-button {
  min-width: 138px;
  gap: 10px;
  border-radius: 16px;
  padding: 3px 12px 3px 5px;
  color: #f8f5ec;
  text-align: left;
}

.top-account-wrap {
  position: relative;
  z-index: 3;
}

.top-avatar-media {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  overflow: hidden;
  border: 1px solid rgba(255, 218, 139, 0.45);
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 229, 166, 0.9), rgba(180, 119, 34, 0.52) 46%, rgba(17, 16, 13, 0.95));
  color: #150f05;
  font-size: 15px;
  font-weight: 1000;
}

.top-avatar-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.top-avatar-copy {
  display: grid;
  gap: 1px;
  line-height: 1.1;
}

.top-avatar-copy b,
.top-avatar-copy small {
  max-width: 88px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-avatar-copy b {
  color: #ffffff;
  font-size: 13px;
}

.top-avatar-copy small {
  color: rgba(255, 226, 159, 0.82);
  font-size: 11px;
  font-weight: 800;
}

.top-logout-button {
  border-radius: 14px;
  padding: 0 12px;
  color: rgba(255, 255, 255, 0.74);
}

.top-account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 680;
  width: min(440px, calc(100vw - 28px));
  max-height: min(720px, calc(100vh - 92px));
  overflow: auto;
  border: 1px solid rgba(255, 216, 126, 0.18);
  border-radius: 18px;
  background:
    radial-gradient(circle at 20% 0%, rgba(0, 178, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(36, 34, 31, 0.98), rgba(18, 18, 16, 0.98));
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.52);
  padding: 18px;
  color: #f7f1df;
}

.top-account-menu[hidden] {
  display: none;
}

.top-account-profile,
.top-account-vip,
.top-account-stat {
  border: 1px solid rgba(255, 221, 139, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
}

.top-account-profile {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
}

.top-account-profile-avatar {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 2px solid rgba(255, 245, 215, 0.74);
  border-radius: 50%;
  background: #fff;
  color: #101010;
  font-weight: 1000;
}

.top-account-profile-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.top-account-profile strong,
.top-account-stat strong {
  display: block;
  overflow: hidden;
  color: #fffaf0;
  font-size: 17px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-account-profile small,
.top-account-stat small {
  display: block;
  margin-top: 5px;
  overflow: hidden;
  color: rgba(232, 221, 198, 0.68);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-account-profile button,
.top-account-vip button,
.top-account-list button {
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
}

.top-account-profile button {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff3c6;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 900;
}

.top-account-vip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  background:
    linear-gradient(135deg, rgba(117, 83, 31, 0.32), rgba(32, 24, 13, 0.74)),
    rgba(255, 188, 68, 0.07);
  padding: 14px 16px;
}

.top-account-vip span {
  color: #f0c76c;
  font-size: 15px;
  font-weight: 900;
}

.top-account-vip button {
  border-radius: 999px;
  background: #0f0f0e;
  color: #ffe7a0;
  padding: 8px 13px;
  font-weight: 900;
}

.top-account-stat {
  width: 100%;
  display: grid;
  gap: 4px;
  margin-top: 10px;
  padding: 14px 16px;
  text-align: left;
}

.top-account-stat span {
  color: rgba(232, 221, 198, 0.72);
  font-size: 13px;
}

.top-account-list {
  display: grid;
  gap: 2px;
  margin-top: 14px;
  padding-top: 8px;
}

.top-account-list button {
  position: relative;
  min-height: 42px;
  border-radius: 10px;
  padding: 0 10px;
  color: #f4efe2;
  font-size: 16px;
  font-weight: 900;
  text-align: left;
}

.top-account-list button:hover,
.top-account-list button:focus-visible,
.top-account-profile button:hover,
.top-account-profile button:focus-visible,
.top-account-vip button:hover,
.top-account-vip button:focus-visible,
.top-account-stat:hover,
.top-account-stat:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  outline: none;
}

.top-account-list button.has-dot::after {
  content: "1";
  display: inline-grid;
  place-items: center;
  width: 17px;
  height: 17px;
  margin-left: 8px;
  border-radius: 50%;
  background: #ff4657;
  color: #fff;
  font-size: 11px;
}

.top-finance-pill:hover,
.top-finance-pill:focus-visible,
.top-avatar-button:hover,
.top-avatar-button:focus-visible,
.top-logout-button:hover,
.top-logout-button:focus-visible {
  border-color: rgba(255, 221, 139, 0.68);
  background: rgba(36, 33, 26, 0.96);
  color: #fff7df;
  outline: none;
}

.login-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(14, 13, 11, 0.48);
}

.login-dialog {
  position: relative;
  width: min(380px, 100%);
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
}

.login-dialog h2 {
  margin: 0;
  font-size: 24px;
}

.login-dialog label {
  display: grid;
  gap: 7px;
  font-size: 13px;
  font-weight: 800;
  color: var(--muted);
}

.login-dialog input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.login-dialog p:last-child {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.auth-message {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
  font-size: 13px;
}

.email-code-panel {
  display: grid;
  gap: 10px;
  margin-top: 6px;
}

.email-code-panel p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.email-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.email-code-row input {
  min-width: 0;
  letter-spacing: 4px;
  text-align: center;
}

.email-code-row button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  padding: 0 14px;
  background: linear-gradient(135deg, #f09a3c, #ffbf67);
  color: #07101e;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.email-code-row button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.login-page-panel {
  align-items: center;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
}

.login-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 4px;
}

.login-legal-links a {
  color: #786c57;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.login-legal-links a:hover,
.login-legal-links a:focus-visible {
  color: #17140e;
  outline: none;
}

.embedded-login-dialog {
  width: 100%;
  box-shadow: none;
}

body.login-index-mode {
  min-height: 100vh;
  overflow: hidden;
  background: #090805;
}

body.login-index-mode .app-shell {
  display: block;
  min-height: 100vh;
}

body.login-index-mode .sidebar,
body.login-index-mode .topbar,
body.login-index-mode .theme-toggle,
body.login-index-mode .settings-dock {
  display: none;
}

body.login-index-mode .main {
  min-height: 100vh;
  padding: 0;
}

body.login-index-mode .view-root {
  min-height: 100vh;
  padding: 0;
}

.login-index-page {
  position: relative;
  min-height: 100vh;
  width: 100%;
  display: grid;
  align-items: center;
  justify-items: start;
  padding: clamp(24px, 5vw, 56px);
  padding-left: clamp(28px, 10vw, 140px);
  background: #090805;
}

.login-hero {
  position: absolute;
  inset: 0;
  overflow: hidden;
  color: #fff7df;
}

.login-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  filter: none;
}

.login-hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(1, 6, 16, 0.82) 0%, rgba(1, 6, 16, 0.42) 42%, rgba(1, 6, 16, 0.28) 62%, rgba(1, 6, 16, 0.74) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.05) 48%, rgba(0, 0, 0, 0.72) 100%);
}

.login-hero-copy {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  width: min(680px, 100%);
  display: grid;
  align-content: end;
  gap: 14px;
  padding: clamp(32px, 6vw, 80px);
}

.login-hero-copy h1 {
  max-width: 560px;
  margin: 0;
  color: #fff7df;
  font-size: clamp(32px, 4.8vw, 56px);
  line-height: 1.08;
}

.login-hero-copy p {
  max-width: 520px;
  margin: 0;
  color: rgba(255, 247, 223, 0.78);
  line-height: 1.8;
}

.login-index-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #f8f3e7;
  text-align: left;
}

.login-index-brand img {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  background: #090805;
}

.login-index-brand strong,
.login-index-brand span {
  display: block;
}

.login-index-brand span {
  margin-top: 3px;
  color: rgba(206, 226, 255, 0.82);
  font-size: 13px;
}

.login-panel {
  position: relative;
  z-index: 2;
  width: min(340px, 100%);
  display: grid;
  align-items: center;
  margin-top: 0;
  padding: 18px;
  border: 1px solid rgba(255, 231, 170, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(3, 9, 18, 0.7), rgba(2, 7, 14, 0.62));
  box-shadow:
    0 18px 50px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(255, 212, 113, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

@media (min-width: 1400px) {
  .login-index-page {
    padding-left: clamp(280px, 18.5vw, 350px);
  }

  .login-panel {
    width: min(360px, 100%);
  }
}

.login-panel-inner {
  width: 100%;
  display: grid;
  gap: 12px;
}

.login-panel-head {
  display: grid;
  gap: 4px;
}

.login-panel-head h2 {
  margin: 0;
  color: #f8fbff;
  font-size: 22px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  border: 1px solid rgba(255, 231, 170, 0.18);
  border-radius: 8px;
  padding: 5px;
  background: rgba(2, 8, 18, 0.42);
}

.auth-tab {
  min-height: 38px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: rgba(206, 226, 255, 0.76);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.auth-tab.active {
  background: linear-gradient(135deg, #f09a3c, #ffbf67);
  color: #07101e;
  box-shadow: 0 10px 24px rgba(240, 154, 60, 0.22);
}

.auth-panel[hidden] {
  display: none;
}

.login-index-card {
  width: 100%;
  border-color: transparent;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.login-index-card label {
  color: rgba(206, 226, 255, 0.82);
}

.login-index-card input {
  min-height: 42px;
  border-color: rgba(255, 231, 170, 0.16);
  background: rgba(1, 7, 17, 0.54);
  color: #f8fbff;
}

.login-index-card input::placeholder {
  color: rgba(206, 226, 255, 0.45);
}

.login-index-card .primary-btn {
  width: 100%;
  min-height: 42px;
  justify-content: center;
  margin-top: 2px;
  background: linear-gradient(135deg, #f09a3c, #ffbf67);
  color: #07101e;
  box-shadow: 0 14px 36px rgba(240, 154, 60, 0.24);
}

.login-index-card p:last-child {
  color: rgba(206, 226, 255, 0.68);
}

.login-index-card .auth-message,
.login-index-card .email-code-panel p {
  color: rgba(206, 226, 255, 0.68);
}

@media (max-width: 860px) {
  body.login-index-mode {
    overflow: auto;
  }

  .login-index-page {
    min-height: 100vh;
    padding: 22px;
    justify-items: center;
  }

  .login-hero {
    min-height: 100vh;
  }

  .login-hero-copy {
    min-height: 100vh;
    padding: 24px;
  }

  .login-hero-copy h1 {
    font-size: 30px;
  }

  .login-panel {
    min-height: auto;
    padding: 24px;
    margin-top: 0;
  }
}

.theme-toggle {
  position: fixed;
  right: 82px;
  bottom: 22px;
  z-index: 80;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 71, 0.42);
  border-radius: 50%;
  padding: 0;
  background: #11100d;
  color: #fff7dd;
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.26);
  cursor: pointer;
}

.theme-icon {
  width: 22px;
  height: 22px;
  display: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

:root[data-theme="dark"] .theme-icon-on,
:root[data-theme="light"] .theme-icon-off {
  display: block;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  border-color: rgba(255, 224, 150, 0.74);
  outline: none;
}

:root[data-theme="light"] .theme-toggle {
  background: #ffffff;
  color: #17140e;
}

.settings-dock {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
}

.settings-toggle {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 71, 0.42);
  border-radius: 50%;
  padding: 0;
  background: #11100d;
  color: #fff7dd;
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.26);
  cursor: pointer;
}

.settings-toggle svg,
.settings-menu svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.settings-toggle:hover,
.settings-toggle:focus-visible {
  border-color: rgba(255, 224, 150, 0.74);
  outline: none;
}

.settings-menu {
  position: absolute;
  right: 0;
  bottom: 58px;
  width: 168px;
  display: grid;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.24);
}

.settings-menu[hidden] {
  display: none;
}

.settings-menu button {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 8px;
  padding: 10px;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  text-align: left;
}

.settings-menu button:hover,
.settings-menu button:focus-visible {
  background: rgba(214, 168, 71, 0.16);
  outline: none;
}

.settings-section-grid,
.legal-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.settings-panel,
.legal-overview-card,
.legal-document {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.settings-panel,
.legal-overview-card {
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 20px;
}

.settings-panel span,
.legal-overview-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.settings-panel h3,
.legal-overview-card h3 {
  margin: 0;
}

.settings-panel p,
.legal-overview-card p,
.legal-document p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.settings-action-row,
.legal-inline-links,
.legal-nav,
.legal-document-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.legal-inline-links a,
.legal-nav a {
  border: 1px solid var(--button-border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--button-text);
  font-weight: 800;
  text-decoration: none;
  background: var(--button-surface);
}

.legal-inline-links a:hover,
.legal-inline-links a:focus-visible,
.legal-nav a:hover,
.legal-nav a:focus-visible,
.legal-nav a.active {
  border-color: var(--button-primary-bg);
  background: var(--button-surface-hover);
  outline: none;
}

.legal-nav {
  margin: 4px 0 20px;
}

.legal-document {
  display: grid;
  gap: 22px;
  padding: 26px;
}

.legal-document section {
  display: grid;
  gap: 8px;
}

.legal-document h3 {
  margin: 0;
  font-size: 18px;
}

.legal-document-meta {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.legal-document-meta span {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.learning-entry-grid article {
  cursor: pointer;
}

.learning-pillar-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  margin: 24px 0 34px;
}

.learning-pillar-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(51, 43, 29, 0.92);
  border-radius: 8px;
  background: #15130f;
  color: #f8f1df;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease;
}

.learning-pillar-card:hover,
.learning-pillar-card:focus-visible {
  border-color: rgba(214, 168, 71, 0.76);
  outline: none;
  transform: translateY(-2px);
}

.learning-pillar-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  background: #0f0e0b;
}

.learning-pillar-card > div {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.learning-pillar-card span {
  color: #d6a847;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.learning-pillar-card h3 {
  margin: 0;
  font-size: 17px;
  line-height: 1.28;
}

.learning-pillar-card p {
  min-height: 72px;
  margin: 0;
  color: #c9c0ad;
  font-size: 13px;
  line-height: 1.55;
}

.learning-pillar-card strong {
  color: #fff;
  font-size: 13px;
}

.learning-section {
  margin-top: 34px;
}

.learning-resource-card .portal-body {
  gap: 8px;
}

.learning-resource-card .portal-body p {
  margin: 0;
  color: #c9c0ad;
  font-size: 13px;
  line-height: 1.55;
}

.learning-resource-card.static {
  cursor: default;
}

.current-url-strip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin: -8px 0 18px;
  padding: 9px 12px;
  border: 1px solid rgba(167, 121, 43, 0.18);
  border-radius: 8px;
  background: rgba(251, 252, 250, 0.86);
}

.current-url-strip span {
  color: var(--muted);
  font-size: 12px;
}

.current-url-strip a {
  min-width: 0;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  text-decoration: none;
}

.current-url-strip a:hover {
  text-decoration: underline;
}

.current-url-strip .copy-btn {
  width: auto;
  margin: 0;
  padding: 7px 10px;
  font-size: 12px;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 11px;
  background: #fff;
  color: var(--ink);
}

:root[data-theme="dark"] input,
:root[data-theme="dark"] textarea,
:root[data-theme="dark"] select,
:root[data-theme="dark"] .auth-btn {
  background: #12100c;
  color: var(--ink);
  border-color: var(--line);
}

textarea {
  resize: vertical;
}

#global-search {
  width: min(360px, 40vw);
}

.primary-btn {
  border: 0;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  padding: 10px 14px;
  cursor: pointer;
  font-weight: 700;
}

.primary-btn:hover {
  background: #8f6623;
}

.view-root {
  display: grid;
  gap: 18px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.metric {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.metric span {
  color: var(--muted);
  font-size: 13px;
}

.metric strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

.metric p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.content-grid {
  display: grid;
  gap: 18px;
}

.content-grid.two {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.panel-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.panel-header span {
  color: var(--muted);
  font-size: 13px;
}

.stack {
  display: grid;
  gap: 10px;
}

.item {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px;
  background: #fbfcfa;
}

.item h3 {
  margin: 0 0 6px;
  font-size: 16px;
}

.item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 14px;
}

:root[data-theme="dark"] .main,
:root[data-theme="dark"] .view-root {
  background: var(--bg);
}

:root[data-theme="dark"] .topbar {
  color: var(--ink);
}

:root[data-theme="dark"] .current-url-strip,
:root[data-theme="dark"] .metric,
:root[data-theme="dark"] .panel,
:root[data-theme="dark"] .item,
:root[data-theme="dark"] .portal-card,
:root[data-theme="dark"] .prompt-content-block,
:root[data-theme="dark"] .prompt-media-section,
:root[data-theme="dark"] .case-reading-shell,
:root[data-theme="dark"] .reading-download-list,
:root[data-theme="dark"] .pending-prompt-list article {
  border-color: var(--line);
  background: var(--panel);
  color: var(--ink);
  box-shadow: var(--shadow);
}

:root[data-theme="dark"] .portal-body h3,
:root[data-theme="dark"] .masonry-body h3,
:root[data-theme="dark"] .detail-content h2,
:root[data-theme="dark"] .reading-hero h1,
:root[data-theme="dark"] .case-reading-shell h1,
:root[data-theme="dark"] .prompt-section-head h2,
:root[data-theme="dark"] .prompt-content-block h2,
:root[data-theme="dark"] .pending-prompt-list strong {
  color: var(--ink);
}

:root[data-theme="dark"] .portal-body p,
:root[data-theme="dark"] .masonry-body p,
:root[data-theme="dark"] .reading-hero p,
:root[data-theme="dark"] .detail-content p,
:root[data-theme="dark"] .pending-prompt-list small {
  color: var(--muted);
}

:root[data-theme="dark"] .prompt-content-head,
:root[data-theme="dark"] .prompt-section-head,
:root[data-theme="dark"] .reading-hero,
:root[data-theme="dark"] .panel-header {
  border-color: var(--line);
}

:root[data-theme="dark"] .pill {
  color: var(--muted);
  border-color: var(--line);
  background: #1c1811;
}

:root[data-theme="dark"] .category-chip {
  color: var(--ink);
  border-color: var(--line);
  background: #15120d;
}

:root[data-theme="dark"] .category-chip span {
  color: var(--muted);
}

:root[data-theme="dark"] .category-chip.active,
:root[data-theme="dark"] .category-chip:hover {
  color: #11100d;
  background: var(--gold);
}

:root[data-theme="dark"] .masonry-card,
:root[data-theme="dark"] .community-card,
:root[data-theme="dark"] .project-community-card {
  border-color: rgba(255, 224, 150, 0.16);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 34%),
    #15120d;
  color: var(--ink);
}

:root[data-theme="dark"] .masonry-card img,
:root[data-theme="dark"] .portal-media,
:root[data-theme="dark"] .reading-image-grid img {
  background: #090805;
}

:root[data-theme="dark"] .reading-article,
:root[data-theme="dark"] .reading-layout,
:root[data-theme="dark"] .reading-shell,
:root[data-theme="dark"] .prompt-reading-shell {
  color: var(--ink);
}

:root[data-theme="dark"] .reading-breadcrumb {
  color: var(--muted);
}

:root[data-theme="dark"] .reading-image-grid figcaption,
:root[data-theme="dark"] .reading-download-list a,
:root[data-theme="dark"] .knowledge-stats article,
:root[data-theme="dark"] .knowledge-source-card,
:root[data-theme="dark"] .knowledge-doc-card,
:root[data-theme="dark"] .admin-access,
:root[data-theme="dark"] .ops-message {
  border-color: var(--line);
  background: var(--panel);
  color: var(--ink);
}

:root[data-theme="dark"] .knowledge-nav a {
  border-color: var(--line);
  background: #15120d;
  color: var(--ink);
}

:root[data-theme="dark"] .knowledge-nav a.active {
  border-color: rgba(214, 168, 71, 0.52);
  background: var(--gold);
  color: #11100d;
}

:root[data-theme="dark"] .zhangdao-doc-grid .knowledge-doc-card {
  background: #1c1811;
}

:root[data-theme="dark"] .knowledge-layer {
  color: #f0d189;
  background: rgba(214, 168, 71, 0.14);
}

:root[data-theme="dark"] .knowledge-layer.risk-low {
  color: #8ee0b0;
  background: rgba(58, 142, 91, 0.18);
}

:root[data-theme="dark"] .knowledge-layer.risk-medium {
  color: #f0d189;
}

:root[data-theme="dark"] .current-url-strip a,
:root[data-theme="dark"] .reading-download-list a span,
:root[data-theme="dark"] .knowledge-source-card h3,
:root[data-theme="dark"] .knowledge-doc-card h3 {
  color: var(--ink);
}

:root[data-theme="light"] .masonry-card,
:root[data-theme="light"] .community-card,
:root[data-theme="light"] .project-community-card {
  border-color: var(--line);
  background: #ffffff;
  color: var(--ink);
  box-shadow: var(--shadow);
}

:root[data-theme="light"] .masonry-body h3,
:root[data-theme="light"] .creator-line {
  color: var(--ink);
}

:root[data-theme="light"] .masonry-body p,
:root[data-theme="light"] .creator-line small,
:root[data-theme="light"] .project-community-card p {
  color: var(--muted);
}

:root[data-theme="light"] .copy-btn.dark {
  border-color: rgba(167, 121, 43, 0.28);
  background: rgba(167, 121, 43, 0.08);
  color: var(--accent);
}

:root[data-theme="light"] .project-source-strip,
:root[data-theme="light"] .project-community-hero,
:root[data-theme="light"] .community-reading-hero,
:root[data-theme="light"] .community-reading-panel {
  border-color: var(--line);
  background: #ffffff;
  color: var(--ink);
}

:root[data-theme="light"] .community-reading-shell,
:root[data-theme="light"] .community-reading-copy h1,
:root[data-theme="light"] .community-reading-panel h2,
:root[data-theme="light"] .post-head strong,
:root[data-theme="light"] .inspiration-post h3 {
  color: var(--ink);
}

:root[data-theme="light"] .community-reading-copy p,
:root[data-theme="light"] .community-reading-panel p:not(.eyebrow),
:root[data-theme="light"] .inspiration-post p,
:root[data-theme="light"] .post-head,
:root[data-theme="light"] .post-head small {
  color: var(--muted);
}

:root[data-theme="light"] .post-media,
:root[data-theme="light"] .post-tags span,
:root[data-theme="light"] .post-actions,
:root[data-theme="light"] .post-actions button {
  border-color: var(--line);
}

:root[data-theme="light"] .post-tags span,
:root[data-theme="light"] .post-actions button {
  color: var(--muted);
  background: #fffaf0;
}

:root[data-theme="light"] .zhangdao-knowledge-feature {
  border-color: rgba(167, 121, 43, 0.24);
  background: #ffffff;
  color: var(--ink);
}

:root[data-theme="light"] .zhangdao-feature-copy p {
  color: var(--muted);
}

:root[data-theme="light"] .zhangdao-feature-copy .asset-link,
:root[data-theme="light"] .dark-link {
  color: var(--accent);
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: #fff;
  font-size: 12px;
}

.pill.strong {
  color: var(--accent);
  border-color: rgba(167, 121, 43, 0.24);
  background: rgba(167, 121, 43, 0.08);
}

.copy-btn {
  margin-top: 12px;
  border: 1px solid rgba(167, 121, 43, 0.28);
  background: rgba(167, 121, 43, 0.08);
  color: var(--accent);
  border-radius: 8px;
  padding: 8px 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
}

.copy-btn:hover {
  background: rgba(167, 121, 43, 0.14);
}

.progress {
  height: 8px;
  background: #e7ebe7;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 12px;
}

.progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--gold));
}

.project-list {
  display: grid;
  gap: 14px;
}

.project-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #fbfcfa;
}

.project-cover {
  width: 100%;
  max-height: 220px;
  object-fit: cover;
  display: block;
  border-radius: 8px;
  margin-bottom: 14px;
  background: #211d15;
}

.project-card h3 {
  margin: 0;
  font-size: 18px;
}

.asset-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  margin-top: 12px;
  border: 1px solid rgba(167, 121, 43, 0.28);
  border-radius: 8px;
  padding: 8px 11px;
  color: var(--accent);
  background: rgba(167, 121, 43, 0.08);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}

.asset-link:hover {
  background: rgba(167, 121, 43, 0.14);
}

.stage-row {
  display: grid;
  grid-template-columns: repeat(8, minmax(80px, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.stage {
  min-height: 42px;
  border-radius: 8px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  background: #fff;
}

.stage.done {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.stage.active {
  color: #fff;
  background: var(--blue);
  border-color: var(--blue);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.form-grid label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.wide {
  grid-column: 1 / -1;
}

.timeline {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.timeline div {
  min-height: 110px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fbfcfa;
}

.timeline b {
  color: var(--accent-2);
  display: block;
  margin-bottom: 8px;
}

.timeline span {
  color: var(--ink);
  line-height: 1.55;
  font-size: 14px;
}

.empty {
  color: var(--muted);
  padding: 20px;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
}

.ops-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
  align-items: stretch;
}

.ops-hero > div > p:last-child,
.workbench-hero > div > p:last-child {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.workbench-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  align-items: stretch;
}

.workbench-note {
  border: 1px solid rgba(167, 121, 43, 0.24);
  border-radius: 8px;
  background: rgba(167, 121, 43, 0.08);
  padding: 16px;
  display: grid;
  align-content: center;
  gap: 8px;
}

.workbench-note strong {
  color: var(--accent);
  font-size: 18px;
}

.workbench-note span,
.form-hint {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.workbench-entry-panel,
.workbench-console-panel,
.workbench-config-panel {
  display: grid;
  gap: 16px;
  border-color: rgba(23, 20, 14, 0.12);
  background: color-mix(in srgb, var(--paper) 94%, #ffffff);
}

.workbench-entry-head,
.workbench-config-head {
  align-items: end;
}

.workbench-entry-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.workbench-entry-grid.single {
  grid-template-columns: minmax(0, 1fr);
}

.workbench-entry-grid.channels {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.workbench-entry-card,
.workbench-config-section {
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #fbfcfa;
}

.workbench-entry-card h3 {
  margin: 10px 0 0;
  color: var(--ink);
  font-size: 22px;
}

.workbench-entry-card p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.workbench-entry-card .status-list {
  gap: 6px;
}

.workbench-entry-card .studio-launch-actions {
  margin-top: 2px;
}

.workflow-channel-card {
  min-height: 100%;
  align-content: space-between;
  position: relative;
  overflow: hidden;
}

.workflow-channel-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 0%, rgba(214, 168, 71, 0.18), transparent 34%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 40%);
  opacity: 0.8;
}

.workflow-channel-card > * {
  position: relative;
  z-index: 1;
}

.entry-brand-lockup {
  margin: 0;
  background: rgba(214, 168, 71, 0.08);
}

.studio-entry {
  border-color: rgba(214, 168, 71, 0.3);
  background: color-mix(in srgb, #fbfcfa 88%, rgba(214, 168, 71, 0.16));
}

.libtv-entry {
  border-color: rgba(49, 95, 159, 0.18);
  background: color-mix(in srgb, #fbfcfa 92%, rgba(49, 95, 159, 0.08));
}

.api-entry {
  border-color: rgba(76, 132, 109, 0.22);
  background: color-mix(in srgb, #fbfcfa 90%, rgba(76, 132, 109, 0.12));
}

.future-entry {
  border-style: dashed;
}

.future-entry .primary-btn:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

@media (max-width: 1320px) {
  .workbench-entry-grid.channels {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.workbench-config-grid {
  align-items: start;
}

.workbench-project-list {
  display: grid;
  gap: 10px;
}

.workbench-project-entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 12px;
}

.workbench-project-entry strong,
.workbench-project-entry span {
  display: block;
}

.workbench-project-entry strong {
  color: var(--ink);
  font-size: 15px;
}

.workbench-project-entry span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.workbench-gallery-panel {
  min-height: 68vh;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  padding: clamp(12px, 1.6vw, 20px);
  background:
    radial-gradient(circle at 18% 0%, rgba(214, 168, 71, 0.16), transparent 30%),
    radial-gradient(circle at 88% 18%, rgba(49, 95, 159, 0.16), transparent 26%),
    linear-gradient(135deg, #08090d, #14110d 52%, #090a0d);
}

.workbench-preview-masonry {
  column-count: 4;
  column-gap: clamp(12px, 1.4vw, 18px);
}

.workbench-preview-card {
  position: relative;
  display: inline-block;
  width: 100%;
  margin: 0 0 clamp(12px, 1.4vw, 18px);
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  background: #11100d;
  break-inside: avoid;
  cursor: pointer;
  box-shadow: 0 22px 54px rgba(0, 0, 0, 0.28);
  transform: translateZ(0);
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.workbench-preview-card:nth-child(5n + 1) img {
  aspect-ratio: 16 / 10;
}

.workbench-preview-card:nth-child(5n + 2) img {
  aspect-ratio: 4 / 5;
}

.workbench-preview-card:nth-child(5n + 3) img {
  aspect-ratio: 1 / 1;
}

.workbench-preview-card:nth-child(5n + 4) img {
  aspect-ratio: 3 / 4;
}

.workbench-preview-card:nth-child(5n) img {
  aspect-ratio: 16 / 12;
}

.workbench-preview-card img {
  width: 100%;
  display: block;
  object-fit: cover;
  background: #17140f;
  filter: saturate(1.08) contrast(1.04) brightness(1.02);
  transform: scale(1.001);
  transition: transform 420ms ease, filter 420ms ease;
}

.workbench-preview-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), transparent 38%, rgba(0, 0, 0, 0.78)),
    radial-gradient(circle at 72% 8%, rgba(214, 168, 71, 0.18), transparent 28%);
}

.workbench-preview-card:hover,
.workbench-preview-card:focus-visible {
  border-color: rgba(214, 168, 71, 0.64);
  box-shadow: 0 28px 76px rgba(0, 0, 0, 0.42);
  outline: none;
  transform: translateY(-3px);
}

.workbench-preview-card:hover img,
.workbench-preview-card:focus-visible img {
  filter: saturate(1.14) contrast(1.08) brightness(1.08);
  transform: scale(1.035);
}

.workbench-preview-overlay {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  z-index: 1;
  display: grid;
  gap: 7px;
  color: #fff7dd;
}

.workbench-preview-overlay span {
  width: fit-content;
  max-width: 100%;
  overflow: hidden;
  border: 1px solid rgba(255, 226, 160, 0.28);
  border-radius: 999px;
  padding: 5px 8px;
  color: #f5d88a;
  background: rgba(9, 8, 6, 0.54);
  backdrop-filter: blur(10px);
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workbench-preview-overlay strong {
  overflow-wrap: anywhere;
  color: #fff;
  font-size: clamp(20px, 2.2vw, 34px);
  line-height: 1.05;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.68);
}

.workbench-preview-progress {
  width: min(210px, 72%);
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.workbench-preview-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #d6a847, #fff1a6);
}

.workbench-maintenance-panel {
  padding: 0;
  overflow: hidden;
}

.workbench-maintenance-panel > summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  cursor: pointer;
  padding: 16px;
  list-style: none;
}

.workbench-maintenance-panel > summary::-webkit-details-marker {
  display: none;
}

.workbench-maintenance-panel > summary span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0;
}

.workbench-maintenance-panel > summary strong {
  color: var(--ink);
  font-size: 18px;
}

.workbench-maintenance-panel > summary small {
  color: var(--muted);
  font-size: 12px;
}

.workbench-maintenance-panel[open] {
  padding-bottom: 16px;
}

.workbench-maintenance-panel[open] > .workbench-config-grid,
.workbench-maintenance-panel[open] > .workbench-config-section {
  margin: 0 16px 16px;
}

.workbench-stage-section {
  padding: 16px;
}

.workbench-stage-section .workflow-rail {
  margin-top: 2px;
}

.ant-agent-canvas-panel {
  position: relative;
  display: block;
  min-height: calc(100vh - 96px);
  overflow: hidden;
  border-color: rgba(214, 168, 71, 0.26);
  background:
    radial-gradient(circle at 12% 0%, rgba(214, 168, 71, 0.16), transparent 30%),
    radial-gradient(circle at 82% 16%, rgba(40, 111, 193, 0.12), transparent 28%),
    linear-gradient(135deg, #101015, #181511 50%, #090b12);
  color: #f9efd3;
}

.ant-agent-canvas-panel .ant-agent-canvas-header,
.ant-agent-canvas-panel .ant-agent-canvas-status,
.ant-agent-canvas-panel .ant-agent-canvas-toolbar,
.ant-agent-canvas-panel .ant-agent-runtime-strip,
.ant-agent-canvas-panel .ant-agent-interface-panel {
  display: none;
}

body.ant-agent-canvas-fullscreen {
  overflow: hidden;
}

.ant-agent-canvas-panel.is-local-fullscreen,
.ant-agent-canvas-panel.is-browser-fullscreen,
.ant-agent-canvas-panel:fullscreen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  width: 100vw;
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
  border-radius: 0;
  padding: 14px;
  background:
    radial-gradient(circle at 12% 0%, rgba(214, 168, 71, 0.18), transparent 30%),
    radial-gradient(circle at 82% 16%, rgba(40, 111, 193, 0.16), transparent 28%),
    linear-gradient(135deg, #08090f, #17130f 54%, #05070d);
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-eval,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-eval,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-eval,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-runtime-strip,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-runtime-strip,
.ant-agent-canvas-panel:fullscreen .ant-agent-runtime-strip,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-interface-panel,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-interface-panel,
.ant-agent-canvas-panel:fullscreen .ant-agent-interface-panel {
  display: none;
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-header,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-header,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-header {
  grid-template-columns: minmax(0, 1fr) auto;
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-header p:not(.eyebrow),
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-header p:not(.eyebrow),
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-header p:not(.eyebrow) {
  max-width: 92ch;
  -webkit-line-clamp: 1;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-layout,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-layout,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-layout {
  min-height: 0;
  height: calc(100vh - 28px);
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-sidebar,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-sidebar,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-sidebar,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-stage,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-stage,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-stage,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-inspector,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-inspector,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-inspector {
  min-height: 0;
  height: 100%;
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-node-library,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-node-library,
.ant-agent-canvas-panel:fullscreen .ant-agent-node-library,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-model-pool,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-model-pool,
.ant-agent-canvas-panel:fullscreen .ant-agent-model-pool,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-asset-shelf,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-asset-shelf,
.ant-agent-canvas-panel:fullscreen .ant-agent-asset-shelf,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-template-shelf,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-template-shelf,
.ant-agent-canvas-panel:fullscreen .ant-agent-template-shelf,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-inspector,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-inspector,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-inspector {
  overflow: auto;
}

.ant-agent-standalone-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 16px;
  align-items: center;
  border-color: rgba(214, 168, 71, 0.26);
  background:
    radial-gradient(circle at 14% 0%, rgba(214, 168, 71, 0.2), transparent 30%),
    radial-gradient(circle at 86% 10%, rgba(40, 111, 193, 0.12), transparent 28%),
    linear-gradient(135deg, #111016, #1a1510 54%, #080b12);
  color: #f9efd3;
}

.ant-agent-standalone-hero h2 {
  margin: 6px 0 0;
  color: #fff5d7;
  font-size: clamp(32px, 4.5vw, 60px);
  line-height: 1.05;
}

.ant-agent-standalone-hero p:not(.eyebrow) {
  max-width: 72ch;
  margin: 12px 0 0;
  color: rgba(255, 246, 220, 0.72);
  line-height: 1.75;
}

.ant-agent-standalone-hero .status-list div {
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 226, 153, 0.14);
}

.ant-agent-standalone-hero .status-list span {
  color: rgba(255, 246, 220, 0.58);
}

.ant-agent-standalone-hero .status-list strong {
  color: #fff1c8;
}

.ant-agent-canvas-header {
  align-items: end;
}

.ant-agent-canvas-header h2,
.ant-agent-canvas-inspector h3,
.ant-agent-interface-panel summary strong {
  color: #fff5d7;
}

.ant-agent-canvas-header p:not(.eyebrow) {
  max-width: 76ch;
  margin: 8px 0 0;
  color: rgba(255, 246, 220, 0.72);
  font-size: 15px;
  line-height: 1.65;
}

.ant-agent-canvas-header > span {
  color: #f4c96d;
  border-color: rgba(244, 201, 109, 0.28);
  background: rgba(244, 201, 109, 0.08);
}

.ant-agent-canvas-eval {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.ant-agent-canvas-eval > div {
  display: grid;
  gap: 6px;
  min-height: 92px;
  border: 1px solid rgba(255, 225, 151, 0.18);
  border-radius: 8px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.045);
}

.ant-agent-canvas-eval strong {
  color: #ffd886;
  font-size: 15px;
}

.ant-agent-canvas-eval span {
  color: rgba(255, 246, 220, 0.7);
  font-size: 13px;
  line-height: 1.6;
}

.ant-agent-canvas-status {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ant-agent-canvas-status span {
  border: 1px solid rgba(255, 225, 151, 0.18);
  border-radius: 999px;
  padding: 8px 12px;
  color: rgba(255, 246, 220, 0.74);
  background: rgba(255, 255, 255, 0.05);
  font-size: 14px;
  font-weight: 900;
}

.ant-agent-canvas-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 225, 151, 0.16);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.18);
}

.ant-agent-canvas-toolbar .asset-link,
.ant-agent-canvas-toolbar .primary-btn {
  min-height: 42px;
}

.ant-agent-canvas-toolbar .icon-btn {
  width: 42px;
  min-width: 42px;
  padding: 0;
  justify-content: center;
  font-size: 20px;
  line-height: 1;
}

.ant-agent-canvas-toolbar .asset-link {
  color: #f7e9c5;
  border-color: rgba(255, 225, 151, 0.2);
  background: rgba(255, 255, 255, 0.06);
}

.ant-agent-canvas-layout {
  position: relative;
  display: block;
  min-height: calc(100vh - 132px);
}

.ant-agent-canvas-sidebar {
  position: absolute;
  left: 68px;
  top: 16px;
  bottom: 16px;
  z-index: 24;
  display: grid;
  align-content: start;
  gap: 12px;
  width: min(340px, calc(100% - 116px));
  min-height: 0;
  overflow: auto;
  border: 1px solid rgba(255, 226, 153, 0.18);
  border-radius: 8px;
  padding: 12px;
  background: rgba(5, 7, 11, 0.9);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
  transform: translateX(calc(-100% - 86px));
  opacity: 0;
  pointer-events: none;
  backdrop-filter: blur(16px);
  transition: transform 160ms ease, opacity 160ms ease;
}

.ant-agent-canvas-panel.is-side-open .ant-agent-canvas-sidebar {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.ant-agent-sidebar-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
}

.ant-agent-sidebar-tabs button {
  min-height: 42px;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  color: rgba(255, 246, 220, 0.66);
  background: rgba(255, 255, 255, 0.04);
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

.ant-agent-sidebar-tabs button span {
  font-size: 18px;
  line-height: 1;
}

.ant-agent-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 226, 153, 0.12);
}

.ant-agent-drawer-head strong {
  overflow: hidden;
  color: #ffd37a;
  font-size: 16px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-drawer-head button {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 226, 153, 0.16);
  border-radius: 8px;
  color: #fff6da;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.ant-agent-drawer-head button:hover,
.ant-agent-drawer-head button:focus-visible {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.72);
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-canvas-rail,
.ant-agent-canvas-dock {
  position: absolute;
  z-index: 32;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  background: rgba(20, 22, 24, 0.82);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(14px);
}

.ant-agent-canvas-window-actions {
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 34;
  display: none;
  grid-template-columns: repeat(2, 48px);
  gap: 8px;
}

.ant-agent-canvas-fullscreen-fab,
.ant-agent-canvas-open-window-fab {
  position: relative;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 226, 153, 0.22);
  border-radius: 8px;
  color: #fff6da;
  background: rgba(20, 22, 24, 0.88);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.36);
  cursor: pointer;
  font: inherit;
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
  backdrop-filter: blur(14px);
}

.ant-agent-canvas-fullscreen-fab:hover,
.ant-agent-canvas-fullscreen-fab:focus-visible,
.ant-agent-canvas-open-window-fab:hover,
.ant-agent-canvas-open-window-fab:focus-visible {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.78);
  background: linear-gradient(135deg, #ffe196, #b77a24);
  outline: none;
}

.ant-agent-canvas-rail {
  left: 14px;
  top: 50%;
  display: grid;
  gap: 8px;
  padding: 8px;
  transform: translateY(-50%);
}

.ant-agent-canvas-dock {
  left: 50%;
  bottom: 14px;
  display: flex;
  gap: 8px;
  padding: 8px;
  transform: translateX(-50%);
}

.ant-agent-canvas-rail button,
.ant-agent-canvas-dock button {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 8px;
  color: rgba(255, 246, 220, 0.86);
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
}

.ant-agent-canvas-dock .ant-agent-canvas-fit-node-button {
  grid-template-columns: auto auto;
  gap: 6px;
  width: auto;
  min-width: 96px;
  padding: 0 12px;
  font-size: 17px;
}

.ant-agent-canvas-fit-node-button span {
  font-size: 12px;
  white-space: nowrap;
}

.ant-agent-canvas-rail button:hover,
.ant-agent-canvas-rail button:focus-visible,
.ant-agent-canvas-rail button.active,
.ant-agent-canvas-dock button:hover,
.ant-agent-canvas-dock button:focus-visible,
.ant-agent-canvas-dock button.active {
  color: #15100a;
  background: linear-gradient(135deg, #ffe196, #b77a24);
  outline: none;
}

.ant-agent-sidebar-tabs button.active {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.72);
  background: linear-gradient(135deg, #ffd37a, #b77a24);
}

.ant-agent-node-library,
.ant-agent-model-pool,
.ant-agent-asset-shelf,
.ant-agent-template-shelf {
  display: grid;
  gap: 10px;
  max-height: 430px;
  overflow: auto;
  padding-right: 2px;
}

.ant-agent-node-library section {
  display: grid;
  gap: 8px;
}

.ant-agent-side-head {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}

.ant-agent-side-head strong {
  color: #ffd37a;
  font-size: 15px;
}

.ant-agent-side-head span {
  color: rgba(255, 246, 220, 0.55);
  font-size: 13px;
}

.ant-agent-palette-node,
.ant-agent-template-shelf button {
  display: grid;
  gap: 6px;
  width: 100%;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 12px;
  text-align: left;
  background: rgba(255, 255, 255, 0.045);
  cursor: pointer;
}

.ant-agent-node-library.is-simple {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.ant-agent-palette-node.is-simple {
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 44px;
  padding: 8px;
}

.ant-agent-palette-node:hover,
.ant-agent-template-shelf button:hover {
  border-color: rgba(255, 211, 122, 0.46);
  background: rgba(255, 211, 122, 0.08);
}

.ant-agent-palette-node span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  padding: 0;
  color: #12100c;
  background: #ffd37a;
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-palette-node strong,
.ant-agent-template-shelf strong,
.ant-agent-model-pool strong,
.ant-agent-asset-shelf strong {
  color: #fff6da;
  font-size: 15px;
  line-height: 1.35;
}

.ant-agent-palette-node.is-simple strong {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-palette-node small,
.ant-agent-template-shelf span,
.ant-agent-asset-shelf small,
.ant-agent-model-pool p {
  margin: 0;
  color: rgba(255, 246, 220, 0.62);
  font-size: 13px;
  line-height: 1.45;
}

.ant-agent-palette-node small,
.ant-agent-template-shelf span {
  display: none;
}

.ant-agent-model-pool,
.ant-agent-asset-shelf {
  gap: 8px;
}

.ant-agent-asset-upload {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
  border: 1px dashed rgba(255, 211, 122, 0.42);
  border-radius: 10px;
  padding: 12px;
  background: rgba(255, 211, 122, 0.06);
}

.ant-agent-asset-upload button,
.ant-agent-asset-upload label {
  display: grid;
  place-items: center;
  min-height: 40px;
  border: 1px solid rgba(255, 211, 122, 0.5);
  border-radius: 8px;
  padding: 0 10px;
  color: #15100a;
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
}

.ant-agent-asset-upload small {
  color: rgba(255, 246, 220, 0.66);
  font-size: 12px;
  line-height: 1.5;
}

.ant-agent-model-pool article,
.ant-agent-asset-shelf article {
  display: grid;
  gap: 7px;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.045);
}

.ant-agent-asset-shelf .ant-agent-asset-preview,
.ant-agent-node-preview-thumb {
  display: grid;
  width: 100%;
  overflow: hidden;
  border: 1px solid rgba(255, 211, 122, 0.2);
  border-radius: 10px;
  padding: 0;
  color: #fff6da;
  background: rgba(0, 0, 0, 0.28);
  cursor: pointer;
}

.ant-agent-node-media-shell {
  position: relative;
  isolation: isolate;
}

.ant-agent-node-media-toolbar {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 5px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  padding: 4px;
  background: rgba(12, 14, 17, 0.78);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(14px);
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.16s ease, transform 0.16s ease;
  pointer-events: none;
}

.ant-agent-node:hover .ant-agent-node-media-toolbar,
.ant-agent-node.selected .ant-agent-node-media-toolbar,
.ant-agent-node.is-expanded .ant-agent-node-media-toolbar,
.ant-agent-node-media-toolbar:focus-within {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.ant-agent-node-media-toolbar button,
.ant-agent-preview-toolbar button {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  padding: 0;
  color: #fff9e7;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-size: 16px;
  font-weight: 900;
  line-height: 1;
}

.ant-agent-node-media-toolbar button:hover,
.ant-agent-node-media-toolbar button:focus-visible,
.ant-agent-preview-toolbar button:hover,
.ant-agent-preview-toolbar button:focus-visible {
  color: #15100a;
  background: linear-gradient(135deg, #ffe19a, #c78a2e);
  outline: none;
}

.ant-agent-node-play-button {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 231, 177, 0.46);
  border-radius: 999px;
  padding: 0;
  color: #fff8df;
  background:
    radial-gradient(circle at 35% 25%, rgba(255, 232, 166, 0.34), transparent 36%),
    rgba(10, 12, 15, 0.72);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.42), 0 0 0 1px rgba(0, 0, 0, 0.28);
  transform: translate(-50%, -50%);
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
  opacity: 0.92;
  backdrop-filter: blur(12px);
  transition: opacity 0.16s ease, transform 0.16s ease, background 0.16s ease;
}

.ant-agent-node-play-button.is-image {
  opacity: 0.76;
}

.ant-agent-node:hover .ant-agent-node-play-button,
.ant-agent-node.selected .ant-agent-node-play-button,
.ant-agent-node.is-expanded .ant-agent-node-play-button,
.ant-agent-node-play-button:focus-visible {
  opacity: 1;
}

.ant-agent-node-play-button:hover,
.ant-agent-node-play-button:focus-visible {
  color: #171006;
  background: linear-gradient(135deg, #ffe19a, #c78a2e);
  outline: none;
  transform: translate(-50%, -50%) scale(1.06);
}

.ant-agent-asset-shelf .ant-agent-asset-preview:hover,
.ant-agent-asset-shelf .ant-agent-asset-preview:focus-visible,
.ant-agent-node-preview-thumb:hover,
.ant-agent-node-preview-thumb:focus-visible {
  border-color: rgba(255, 211, 122, 0.76);
  outline: none;
  box-shadow: 0 0 0 2px rgba(255, 211, 122, 0.12);
}

.ant-agent-asset-thumb,
.ant-agent-node-preview-thumb img,
.ant-agent-node-preview-thumb video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 640px;
  object-fit: contain;
  background: rgba(0, 0, 0, 0.2);
}

.ant-agent-node-preview-thumb small {
  display: none;
}

.ant-agent-node.is-media-node .ant-agent-node-preview-thumb {
  border-color: rgba(218, 232, 255, 0.26);
  background: rgba(10, 12, 15, 0.34);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.22);
}

.ant-agent-node.is-media-node.is-expanded .ant-agent-node-preview-thumb {
  border-color: rgba(255, 218, 126, 0.82);
  box-shadow:
    0 0 0 2px rgba(255, 205, 104, 0.2),
    0 20px 58px rgba(0, 0, 0, 0.38);
}

.ant-agent-node.is-media-node .ant-agent-node-preview-thumb img,
.ant-agent-node.is-media-node .ant-agent-node-preview-thumb video {
  display: block;
  width: 100%;
  height: auto;
}

.ant-agent-model-pool span,
.ant-agent-asset-shelf span {
  width: fit-content;
  border-radius: 999px;
  padding: 4px 8px;
  color: #d8e6ff;
  background: rgba(65, 112, 190, 0.16);
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-asset-shelf button {
  width: fit-content;
  min-height: 34px;
  border: 1px solid rgba(255, 211, 122, 0.2);
  border-radius: 8px;
  padding: 0 9px;
  color: #fff6da;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
}

.ant-agent-asset-shelf button:hover,
.ant-agent-asset-shelf button:focus-visible {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.76);
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-task-queue {
  display: grid;
  gap: 8px;
  border-top: 1px solid rgba(255, 226, 153, 0.12);
  padding-top: 12px;
}

.ant-agent-task-queue.compact {
  grid-template-columns: minmax(0, 1fr);
}

.ant-agent-task-queue.compact button {
  min-height: 40px;
  border: 1px solid rgba(255, 211, 122, 0.24);
  border-radius: 8px;
  color: #fff6da;
  background: rgba(255, 255, 255, 0.055);
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 900;
}

.ant-agent-task-queue.compact button:hover,
.ant-agent-task-queue.compact button:focus-visible {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.76);
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-job {
  display: grid;
  gap: 5px;
  border: 1px solid rgba(255, 226, 153, 0.12);
  border-radius: 8px;
  padding: 9px;
  background: rgba(0, 0, 0, 0.16);
}

.ant-agent-job span {
  width: fit-content;
  border-radius: 999px;
  padding: 4px 8px;
  color: #15100a;
  background: #ffd37a;
  font-size: 11px;
  font-weight: 900;
}

.ant-agent-job strong {
  color: #fff6da;
  font-size: 12px;
}

.ant-agent-job small {
  color: rgba(255, 246, 220, 0.58);
  font-size: 11px;
}

.ant-agent-canvas-stage {
  position: relative;
  min-height: calc(100vh - 132px);
  overflow: hidden;
  border: 1px solid rgba(255, 225, 151, 0.18);
  border-radius: 8px;
  background:
    radial-gradient(circle at 52% 42%, rgba(255, 202, 91, 0.16), transparent 16%),
    radial-gradient(circle at 62% 36%, rgba(47, 112, 211, 0.16), transparent 23%),
    #070910;
  touch-action: none;
  cursor: grab;
}

.ant-agent-canvas-panel.is-space-panning .ant-agent-canvas-stage,
.ant-agent-canvas-panel.is-space-panning .ant-agent-node {
  cursor: grab;
}

.ant-agent-canvas-panel.is-canvas-panning .ant-agent-canvas-stage,
.ant-agent-canvas-panel.is-canvas-panning .ant-agent-canvas-stage *,
.ant-agent-canvas-panel.is-canvas-panning .ant-agent-node {
  cursor: grabbing;
}

.ant-agent-canvas-panel.is-standalone .ant-agent-canvas-stage {
  min-height: calc(100vh - 42px);
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-stage,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-stage,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-stage {
  min-height: 0;
  height: 100%;
}

.ant-agent-canvas-stage:active {
  cursor: grabbing;
}

.ant-agent-file-drop-hint {
  position: absolute;
  inset: 18px;
  z-index: 48;
  display: grid;
  place-content: center;
  gap: 9px;
  border: 2px dashed rgba(130, 194, 255, 0.74);
  border-radius: 18px;
  color: #eff8ff;
  background: rgba(4, 13, 25, 0.88);
  box-shadow: inset 0 0 80px rgba(66, 148, 238, 0.16);
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.985);
  transition: opacity 140ms ease, transform 140ms ease, border-color 140ms ease;
  backdrop-filter: blur(10px);
}

.ant-agent-file-drop-hint strong {
  font-size: 24px;
}

.ant-agent-file-drop-hint span {
  color: rgba(214, 234, 255, 0.8);
  font-size: 14px;
}

.ant-agent-file-drop-hint small {
  color: rgba(255, 220, 144, 0.84);
  font-size: 12px;
}

.ant-agent-canvas-stage.is-file-dragging .ant-agent-file-drop-hint {
  opacity: 1;
  transform: scale(1);
}

.ant-agent-canvas-stage.is-file-over-node .ant-agent-file-drop-hint {
  border-color: rgba(86, 230, 161, 0.92);
  box-shadow: inset 0 0 100px rgba(44, 188, 126, 0.18);
}

.ant-agent-file-transfer-status {
  position: absolute;
  top: 22px;
  left: 50%;
  z-index: 61;
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: min(420px, calc(100% - 48px));
  max-width: min(620px, calc(100% - 48px));
  padding: 12px 15px;
  border: 1px solid rgba(124, 193, 255, 0.42);
  border-radius: 14px;
  color: #eef8ff;
  background: rgba(5, 14, 27, 0.94);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.34);
  transform: translateX(-50%);
  backdrop-filter: blur(14px);
}

.ant-agent-file-transfer-status[hidden] {
  display: none;
}

.ant-agent-file-transfer-status > span {
  display: grid;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #08111f;
  background: #7fc4ff;
  font-size: 18px;
  font-weight: 950;
}

.ant-agent-file-transfer-status > div {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.ant-agent-file-transfer-status strong,
.ant-agent-file-transfer-status small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-file-transfer-status small {
  color: rgba(218, 235, 251, 0.72);
}

.ant-agent-file-transfer-status[data-phase="success"] {
  border-color: rgba(76, 222, 153, 0.5);
  background: rgba(5, 34, 27, 0.96);
}

.ant-agent-file-transfer-status[data-phase="success"] > span {
  background: #58e09b;
}

.ant-agent-file-transfer-status[data-phase="error"] {
  border-color: rgba(255, 111, 124, 0.58);
  background: rgba(47, 12, 20, 0.96);
}

.ant-agent-file-transfer-status[data-phase="error"] > span {
  color: #fff;
  background: #f05f74;
}

.ant-agent-canvas-stage.is-file-uploading::after {
  content: "正在上传并创建素材节点…";
  position: absolute;
  left: 50%;
  bottom: 22px;
  z-index: 49;
  transform: translateX(-50%);
  border: 1px solid rgba(126, 192, 255, 0.34);
  border-radius: 999px;
  padding: 10px 16px;
  color: #edf7ff;
  background: rgba(4, 12, 23, 0.9);
  font-size: 12px;
  font-weight: 900;
  pointer-events: none;
}

.ant-agent-run-hud {
  position: absolute;
  top: 10px;
  right: 76px;
  z-index: 23;
  width: min(332px, calc(100% - 154px));
  border: 1px solid rgba(120, 185, 255, 0.34);
  border-radius: 999px;
  padding: 5px 6px 5px 9px;
  color: #f5f8ff;
  background: rgba(5, 11, 21, 0.82);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3), 0 0 22px rgba(63, 139, 229, 0.1);
  pointer-events: auto;
  backdrop-filter: blur(14px);
}

.ant-agent-run-hud.is-succeeded {
  border-color: rgba(83, 222, 154, 0.38);
}

.ant-agent-run-hud.is-preview {
  border-color: rgba(255, 194, 92, 0.46);
  background: rgba(31, 22, 8, 0.86);
}

.ant-agent-run-hud.is-failed {
  border-color: rgba(255, 116, 92, 0.44);
}

.ant-agent-run-hud.is-empty {
  display: flex;
  align-items: center;
  gap: 7px;
  width: auto;
  color: rgba(230, 240, 255, 0.66);
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(5, 9, 16, 0.7);
}

.ant-agent-run-hud.is-empty strong {
  color: #e8f2ff;
  font-size: 12px;
}

.ant-agent-run-hud-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 4px;
  margin-left: 2px;
}

.ant-agent-run-hud button {
  min-width: 27px;
  height: 27px;
  border: 1px solid rgba(123, 182, 255, 0.28);
  border-radius: 999px;
  padding: 0 7px;
  color: #edf6ff;
  background: rgba(75, 132, 205, 0.14);
  cursor: pointer;
  font: inherit;
  font-size: 10px;
  font-weight: 900;
}

.ant-agent-run-hud button.is-primary {
  min-width: 39px;
}

.ant-agent-run-hud button:hover,
.ant-agent-run-hud button:focus-visible {
  color: #07111e;
  border-color: rgba(149, 204, 255, 0.78);
  background: #91caff;
  outline: none;
}

.ant-agent-run-hud-summary {
  min-width: 0;
  min-height: 29px;
}

.ant-agent-run-hud-summary > strong {
  flex: 1 1 auto;
}

.ant-agent-run-hud-summary > time:empty {
  display: none;
}

@media (max-width: 720px) {
  .ant-agent-run-hud {
    right: 58px;
    width: min(270px, calc(100% - 76px));
  }

  .ant-agent-run-hud-summary > time {
    display: none;
  }
}

.ant-agent-canvas-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 226, 153, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 226, 153, 0.08) 1px, transparent 1px),
    radial-gradient(circle, rgba(91, 150, 255, 0.18) 1px, transparent 1.5px);
  background-size: 48px 48px, 48px 48px, 16px 16px;
  mask-image: radial-gradient(circle at center, black, transparent 86%);
  pointer-events: none;
}

.ant-agent-canvas-starter {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 8;
  display: grid;
  justify-items: center;
  gap: 24px;
  width: min(860px, calc(100% - 48px));
  transform: translate(-50%, -36%);
  pointer-events: none;
}

.ant-agent-canvas-starter-hint {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 7px 12px;
  color: rgba(255, 248, 230, 0.68);
  background: rgba(8, 10, 12, 0.34);
  font-size: 15px;
  font-weight: 800;
  backdrop-filter: blur(10px);
}

.ant-agent-canvas-starter-hint::before {
  content: "+";
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 1px solid rgba(255, 246, 220, 0.56);
  border-radius: 999px;
  color: rgba(255, 246, 220, 0.9);
  background: rgba(255, 255, 255, 0.1);
  font-size: 16px;
  line-height: 1;
}

.ant-agent-canvas-reload-server {
  border: 1px solid rgba(255, 211, 122, 0.56);
  border-radius: 999px;
  padding: 12px 22px;
  color: #171109;
  background: linear-gradient(135deg, #ffe7a8, #c88b2e);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.34), 0 0 32px rgba(255, 196, 91, 0.2);
  cursor: pointer;
  font: inherit;
  font-size: 16px;
  font-weight: 900;
  pointer-events: auto;
}

.ant-agent-canvas-reload-server:disabled {
  cursor: wait;
  opacity: 0.76;
}

.ant-agent-canvas-reload-server:hover,
.ant-agent-canvas-reload-server:focus-visible {
  filter: brightness(1.08);
  outline: none;
}

.ant-agent-canvas-starter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  width: 100%;
  pointer-events: auto;
}

.ant-agent-canvas-starter-card {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 62px;
  overflow: hidden;
  border: 1px solid rgba(255, 232, 176, 0.22);
  border-radius: 8px;
  padding: 0 18px;
  color: #fff6de;
  background:
    linear-gradient(90deg, rgba(13, 15, 18, 0.92), rgba(13, 15, 18, 0.54) 58%, rgba(13, 15, 18, 0.2)),
    var(--starter-image) center / cover;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.ant-agent-canvas-starter-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(255, 197, 84, 0.09), rgba(80, 146, 255, 0.08));
  opacity: 0;
  transition: opacity 160ms ease;
}

.ant-agent-canvas-starter-card span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  border-radius: 8px;
  color: #11130f;
  background: #fff9e8;
  font-size: 17px;
  font-weight: 900;
}

.ant-agent-canvas-starter-card strong {
  min-width: 0;
  overflow: hidden;
  font-size: 16px;
  font-weight: 900;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-canvas-starter-card:hover,
.ant-agent-canvas-starter-card:focus-visible {
  border-color: rgba(255, 213, 120, 0.72);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.38), 0 0 0 1px rgba(255, 213, 120, 0.18) inset;
  outline: none;
  transform: translateY(-2px);
}

.ant-agent-canvas-starter-card:hover::after,
.ant-agent-canvas-starter-card:focus-visible::after {
  opacity: 1;
}

@media (max-width: 960px) {
  .ant-agent-canvas-starter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .ant-agent-canvas-starter {
    transform: translate(-50%, -42%);
  }

  .ant-agent-canvas-starter-grid {
    grid-template-columns: 1fr;
  }
}

.ant-agent-canvas-world {
  position: absolute;
  left: 0;
  top: 0;
  width: 2360px;
  height: 1340px;
  transform-origin: 0 0;
}

.ant-agent-edge-layer,
.ant-agent-node-layer {
  position: absolute;
  inset: 0;
}

.ant-agent-edge-layer {
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: auto;
}

.ant-agent-edge-group {
  cursor: pointer;
}

.ant-agent-edge-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 18;
  stroke-linecap: round;
  pointer-events: stroke;
}

.ant-agent-edge {
  fill: none;
  stroke: rgba(255, 205, 104, 0.62);
  stroke-width: 2.4;
  stroke-linecap: round;
  filter: drop-shadow(0 0 8px rgba(244, 164, 62, 0.2));
  pointer-events: none;
}

.ant-agent-edge-arrow {
  fill: rgba(255, 205, 104, 0.88);
}

.ant-agent-edge-arrow-active {
  fill: #8be4ff;
  filter: drop-shadow(0 0 5px rgba(82, 190, 255, 0.88));
}

.ant-agent-edge-flow {
  fill: none;
  stroke: #8be4ff;
  stroke-width: 3.4;
  stroke-linecap: round;
  stroke-dasharray: 9 12;
  opacity: 0;
  filter: drop-shadow(0 0 9px rgba(82, 190, 255, 0.56));
  pointer-events: none;
}

.ant-agent-edge-group.is-previewing .ant-agent-edge-flow {
  opacity: 0.7;
  animation: ant-agent-edge-flow-loop 2.8s linear infinite;
}

.ant-agent-edge-group.is-running .ant-agent-edge-flow {
  stroke: #73ecff;
  stroke-width: 4.8;
  stroke-dasharray: 7 10;
  opacity: 1;
  animation: ant-agent-edge-flow-loop 1.05s linear infinite;
}

.ant-agent-edge-group.is-running text {
  fill: #d8fbff;
  filter: drop-shadow(0 0 8px rgba(82, 190, 255, 0.8));
}

.ant-agent-edge-group.is-complete .ant-agent-edge,
.ant-agent-edge-group.is-complete .ant-agent-edge-flow {
  stroke: #86f1a8;
  opacity: 1;
  animation: ant-agent-edge-complete-pulse 0.8s ease-out 2;
}

.ant-agent-edge-particle {
  fill: #e8fdff;
  stroke: #5edaf5;
  stroke-width: 1.5;
  filter: drop-shadow(0 0 8px rgba(105, 230, 255, 0.95));
  pointer-events: none;
}

@keyframes ant-agent-edge-flow-loop {
  to {
    stroke-dashoffset: -42;
  }
}

@keyframes ant-agent-edge-complete-pulse {
  0% {
    opacity: 0.25;
    stroke-width: 2.5;
  }
  55% {
    opacity: 1;
    stroke-width: 6;
  }
  100% {
    opacity: 0.72;
    stroke-width: 3;
  }
}

.ant-agent-edge-group:hover .ant-agent-edge,
.ant-agent-edge-group.selected .ant-agent-edge {
  stroke: rgba(118, 190, 255, 0.96);
  stroke-width: 3.5;
  filter: drop-shadow(0 0 12px rgba(82, 168, 255, 0.44));
}

@media (prefers-reduced-motion: reduce) {
  .ant-agent-edge-group .ant-agent-edge-flow,
  .ant-agent-edge-group.is-running .ant-agent-edge-flow,
  .ant-agent-edge-group.is-complete .ant-agent-edge,
  .ant-agent-edge-group.is-complete .ant-agent-edge-flow {
    animation: none;
  }

  .ant-agent-edge-particle {
    display: none;
  }
}

.ant-agent-edge-group text {
  fill: rgba(255, 246, 220, 0.76);
  font-size: 12px;
  font-weight: 800;
  paint-order: stroke;
  stroke: rgba(5, 7, 11, 0.9);
  stroke-width: 4px;
  stroke-linejoin: round;
  pointer-events: none;
}

.ant-agent-edge-group.selected text {
  fill: #c7efff;
}

.ant-agent-edge-delete {
  pointer-events: all;
  cursor: pointer;
}

.ant-agent-edge-delete circle {
  fill: rgba(8, 10, 14, 0.94);
  stroke: rgba(118, 190, 255, 0.92);
  stroke-width: 1.5;
  filter: drop-shadow(0 0 10px rgba(82, 168, 255, 0.4));
}

.ant-agent-edge-delete text {
  fill: #fff6da;
  stroke: none;
  text-anchor: middle;
  font-size: 20px;
  font-weight: 900;
  pointer-events: none;
}

.ant-agent-edge-delete:hover circle {
  fill: #ffd37a;
  stroke: #fff6da;
}

.ant-agent-edge-delete:hover text {
  fill: #15100a;
}

.ant-agent-edge-draft {
  stroke: rgba(114, 184, 255, 0.92);
  stroke-width: 3;
  stroke-dasharray: 8 8;
  filter: drop-shadow(0 0 10px rgba(92, 164, 255, 0.42));
}

.ant-agent-edge-draft-group circle {
  fill: #72b8ff;
  stroke: rgba(255, 246, 220, 0.82);
  stroke-width: 2;
  filter: drop-shadow(0 0 12px rgba(92, 164, 255, 0.62));
}

.ant-agent-node {
  position: absolute;
  z-index: 2;
  display: block;
  border-radius: 8px;
  padding: 0;
  background: transparent;
  box-shadow: none;
  cursor: grab;
  user-select: none;
}

.ant-agent-node.is-logic-node {
  display: grid;
  gap: 6px;
  min-height: 116px;
  border: 1px solid rgba(255, 226, 153, 0.2);
  padding: 10px;
  background:
    linear-gradient(145deg, rgba(29, 32, 42, 0.92), rgba(9, 12, 19, 0.9)),
    radial-gradient(circle at 20% 0%, rgba(255, 205, 104, 0.14), transparent 34%);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
}

.ant-agent-node.is-media-node {
  width: fit-content;
  max-width: 860px;
}

.ant-agent-port {
  position: absolute;
  top: 50%;
  z-index: 8;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  border: 1px solid rgba(218, 232, 255, 0.58);
  border-radius: 50%;
  background: rgba(7, 10, 15, 0.92);
  box-shadow: 0 0 0 3px rgba(44, 117, 212, 0.12), 0 0 18px rgba(88, 165, 255, 0.28);
}

.ant-agent-port.input-port {
  left: -11px;
  width: 20px;
  height: 20px;
}

.ant-agent-port.input-port::after {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(184, 211, 255, 0.76);
}

.ant-agent-port.input-port:hover {
  border-color: rgba(118, 190, 255, 0.9);
  box-shadow: 0 0 0 5px rgba(82, 168, 255, 0.18), 0 0 20px rgba(88, 165, 255, 0.36);
}

.ant-agent-port.output-port {
  right: -17px;
  width: 34px;
  height: 34px;
  color: #f8f3e7;
  background: linear-gradient(135deg, rgba(20, 30, 45, 0.96), rgba(7, 10, 15, 0.96));
  cursor: pointer;
  font-size: 24px;
  font-weight: 500;
  line-height: 1;
}

.ant-agent-port.output-port:hover,
.ant-agent-port.output-port:focus-visible {
  border-color: rgba(255, 217, 126, 0.9);
  color: #15100a;
  background: linear-gradient(135deg, #ffe196, #c48428);
  outline: none;
}

.ant-agent-node-add-menu {
  position: absolute;
  top: 44px;
  right: -210px;
  z-index: 12;
  width: 220px;
  display: grid;
  gap: 5px;
  border: 1px solid rgba(255, 226, 153, 0.16);
  border-radius: 8px;
  padding: 10px;
  background: rgba(28, 28, 26, 0.96);
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(14px);
}

.ant-agent-node-add-menu.drop-menu {
  right: auto;
  transform: translate(0, 0);
}

.ant-agent-node-add-menu.node-type-menu {
  width: 190px;
  padding: 8px;
  gap: 4px;
}

.ant-agent-node-add-menu.context-menu {
  right: auto;
  z-index: 24;
  min-width: 176px;
  max-height: calc(100vh - 90px);
  overflow-y: auto;
}

.ant-agent-node-add-menu strong {
  color: rgba(255, 246, 220, 0.64);
  font-size: 14px;
  font-weight: 700;
}

.ant-agent-node-add-menu button {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  padding: 0 7px;
  color: #f4efe2;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.ant-agent-node-add-menu button:hover,
.ant-agent-node-add-menu button:focus-visible {
  color: #15100a;
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-node-add-menu button span {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  font-style: normal;
}

.ant-agent-node-add-menu button em {
  overflow: hidden;
  font-style: normal;
  font-size: 14px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-node-floating-toolbar {
  position: absolute;
  z-index: 28;
  display: grid;
  gap: 6px;
  width: 50px;
  overflow: visible;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 5px;
  background: rgba(38, 38, 36, 0.96);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(14px);
}

.ant-agent-node-floating-toolbar button,
.ant-agent-node-floating-toolbar summary {
  position: relative;
  display: inline-grid;
  place-items: center;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: 40px;
  min-width: 40px;
  height: 40px;
  min-height: 40px;
  border: 0;
  border-radius: 8px;
  padding: 0;
  color: rgba(255, 246, 220, 0.86);
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-size: 17px;
  font-weight: 800;
  list-style: none;
  user-select: none;
}

.ant-agent-node-floating-toolbar summary::-webkit-details-marker {
  display: none;
}

.ant-agent-node-floating-toolbar button:hover,
.ant-agent-node-floating-toolbar button:focus-visible,
.ant-agent-node-floating-toolbar summary:hover,
.ant-agent-node-floating-toolbar summary:focus-visible {
  color: #15100a;
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-node-floating-toolbar span,
.ant-agent-node-floating-toolbar em,
.ant-agent-node-floating-toolbar b {
  font-style: normal;
  line-height: 1;
}

.ant-agent-node-floating-toolbar button em {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.ant-agent-node-floating-toolbar b {
  position: absolute;
  right: 2px;
  top: 2px;
  border-radius: 999px;
  padding: 3px 6px;
  color: #c7f9ff;
  background: rgba(39, 172, 190, 0.32);
  font-size: 10px;
}

.ant-agent-node-floating-toolbar .icon-only {
  width: 40px;
  min-width: 40px;
  padding: 0;
  font-size: 19px;
}

.ant-agent-node-floating-toolbar .close {
  color: #f9f5e7;
  background: rgba(255, 255, 255, 0.1);
  font-size: 18px;
}

.ant-agent-node-floating-toolbar.is-readonly {
  width: 50px;
}

.ant-agent-node-floating-toolbar.is-chip {
  width: 50px;
  padding: 5px;
}

.ant-agent-node-floating-toolbar .toolbar-grip {
  color: rgba(255, 246, 220, 0.42);
  cursor: grab;
}

.ant-agent-node-floating-toolbar .toolbar-grip:active {
  cursor: grabbing;
}

.ant-agent-toolbar-more {
  position: relative;
  display: grid;
}

.ant-agent-toolbar-grid {
  position: absolute;
  top: 0;
  left: 52px;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(4, 40px);
  gap: 6px;
  width: max-content;
  max-width: min(208px, calc(100vw - 96px));
  max-height: min(360px, calc(100vh - 96px));
  overflow: auto;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 8px;
  background: rgba(28, 28, 26, 0.98);
  box-shadow: 0 20px 54px rgba(0, 0, 0, 0.45);
}

.ant-agent-node-floating-toolbar.opens-left .ant-agent-toolbar-grid {
  right: 52px;
  left: auto;
}

.ant-agent-toolbar-grid button {
  background: rgba(255, 255, 255, 0.055);
}

.ant-agent-edge-floating-toolbar {
  position: absolute;
  z-index: 22;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: min(360px, calc(100% - 24px));
  min-height: 44px;
  border: 1px solid rgba(118, 190, 255, 0.34);
  border-radius: 8px;
  padding: 6px 7px 6px 12px;
  color: #dff6ff;
  background:
    linear-gradient(135deg, rgba(27, 34, 43, 0.97), rgba(8, 10, 14, 0.96));
  box-shadow:
    0 18px 42px rgba(0, 0, 0, 0.42),
    0 0 18px rgba(82, 168, 255, 0.22);
  backdrop-filter: blur(14px);
}

.ant-agent-edge-floating-toolbar span {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 5px 8px;
  color: #15100a;
  background: linear-gradient(135deg, #c7efff, #5b9dff);
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-edge-floating-toolbar strong {
  min-width: 0;
  max-width: 220px;
  overflow: hidden;
  color: #fff6da;
  font-size: 14px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-edge-floating-toolbar button {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 226, 153, 0.26);
  border-radius: 8px;
  color: #fff6da;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.ant-agent-edge-floating-toolbar button:hover,
.ant-agent-edge-floating-toolbar button:focus-visible {
  border-color: rgba(255, 226, 153, 0.88);
  color: #15100a;
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-port.output-port.is-readonly {
  cursor: default;
  opacity: 0.52;
}

.ant-agent-port.output-port.is-readonly:hover,
.ant-agent-port.output-port.is-readonly:focus-visible {
  border-color: rgba(218, 232, 255, 0.58);
  color: rgba(255, 246, 220, 0.72);
  background: linear-gradient(135deg, rgba(20, 30, 45, 0.96), rgba(7, 10, 15, 0.96));
}

.ant-agent-node.selected {
  z-index: 12;
}

.ant-agent-node.is-logic-node.selected {
  border-color: rgba(255, 218, 126, 0.84);
  box-shadow: 0 0 0 2px rgba(255, 205, 104, 0.2), 0 18px 44px rgba(0, 0, 0, 0.36);
}

.ant-agent-node.is-run-located {
  animation: ant-agent-node-located 0.85s ease-in-out 2;
}

@keyframes ant-agent-node-located {
  50% {
    border-color: #8fc9ff;
    box-shadow: 0 0 0 5px rgba(95, 170, 255, 0.28), 0 0 58px rgba(80, 157, 255, 0.38);
  }
}

.ant-agent-node-head,
.ant-agent-node-foot {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}

.ant-agent-node-label {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 6px;
  align-items: center;
  min-height: 24px;
  margin-bottom: 4px;
  color: rgba(226, 235, 250, 0.62);
  font-size: 12px;
  line-height: 1;
}

.ant-agent-node-label span {
  color: rgba(238, 246, 255, 0.72);
}

.ant-agent-node-label strong {
  min-width: 0;
  overflow: hidden;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-node-label small {
  color: rgba(238, 246, 255, 0.45);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.ant-agent-node.is-logic-node > .ant-agent-node-label {
  display: none;
}

.ant-agent-node-logic-body {
  display: grid;
  gap: 8px;
  min-height: 82px;
  cursor: pointer;
}

.ant-agent-node-head span {
  display: inline-grid;
  place-items: center;
  min-width: 42px;
  min-height: 26px;
  border-radius: 999px;
  color: #15100a;
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-node-head em {
  font-style: normal;
  color: rgba(255, 246, 220, 0.72);
  font-size: 12px;
  font-weight: 800;
}

.ant-agent-node h3 {
  margin: 0;
  color: #fff6da;
  font-size: 17px;
  line-height: 1.22;
}

.ant-agent-node-drawer {
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  z-index: 24;
  display: none;
  width: max(100%, min(520px, calc(100vw - 120px)));
  min-width: 360px;
  transform: translateX(-50%);
  gap: 7px;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 10px;
  background: rgba(31, 31, 29, 0.96);
  box-shadow: 0 22px 58px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(16px);
}

.ant-agent-node.is-expanded .ant-agent-node-drawer {
  display: grid;
}

.ant-agent-node p {
  display: none;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  color: rgba(255, 246, 220, 0.68);
  font-size: 15px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.ant-agent-node-io {
  display: none;
  grid-template-columns: auto minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  border: 1px solid rgba(184, 211, 255, 0.12);
  border-radius: 8px;
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.035);
}

.ant-agent-node-io span {
  color: rgba(184, 211, 255, 0.66);
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-node-io strong {
  overflow: hidden;
  color: #e9f1ff;
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-node-controls,
.ant-agent-node-params {
  display: grid;
  gap: 6px;
}

.ant-agent-node-controls {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
}

.ant-agent-node-params {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ant-agent-node-prompt-shell,
.ant-agent-prompt-editor-body {
  position: relative;
  display: grid;
  gap: 6px;
  min-width: 0;
}

.ant-agent-prompt-toolbar {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}

.ant-agent-prompt-toolbar > div {
  display: flex;
  gap: 5px;
  align-items: center;
  min-width: 0;
}

.ant-agent-prompt-toolbar strong,
.ant-agent-prompt-toolbar em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-prompt-toolbar strong {
  max-width: 260px;
  color: #fff6da;
  font-size: 15px;
  font-weight: 900;
}

.ant-agent-prompt-toolbar em {
  max-width: 230px;
  color: rgba(255, 224, 155, 0.68);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.ant-agent-prompt-toolbar button {
  display: inline-flex;
  gap: 4px;
  align-items: center;
  min-height: 28px;
  border: 1px solid rgba(190, 215, 255, 0.14);
  border-radius: 999px;
  padding: 0 8px;
  color: rgba(235, 244, 255, 0.74);
  background: rgba(255, 255, 255, 0.055);
  cursor: pointer;
  font: inherit;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.ant-agent-prompt-toolbar button:hover,
.ant-agent-prompt-toolbar button:focus-visible {
  color: #07111e;
  border-color: rgba(145, 202, 255, 0.72);
  background: #91caff;
  outline: none;
}

.ant-agent-prompt-toolbar button b {
  display: grid;
  place-items: center;
  min-width: 16px;
  height: 16px;
  border-radius: 999px;
  color: #08111e;
  background: #7dd4ff;
  font-size: 9px;
}

.ant-agent-prompt-toolbar .icon-only {
  justify-content: center;
  width: 30px;
  padding: 0;
  border-radius: 8px;
}

.ant-agent-prompt-toolbar small {
  color: rgba(214, 230, 255, 0.58);
  font-size: 9px;
  font-variant-numeric: tabular-nums;
}

.ant-agent-prompt-reference-tray {
  display: flex;
  gap: 7px;
  align-items: center;
  min-width: 0;
  border: 1px solid rgba(91, 205, 255, 0.16);
  border-radius: 9px;
  padding: 4px 6px;
  background: rgba(20, 94, 132, 0.08);
}

.ant-agent-prompt-reference-list {
  display: flex;
  gap: 5px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: thin;
}

.ant-agent-prompt-reference-item {
  display: inline-flex;
  gap: 4px;
  align-items: center;
  flex: 0 0 auto;
  max-width: 142px;
  height: 32px;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(172, 205, 240, 0.16);
  border-radius: 6px;
  padding: 2px 7px 2px 2px;
  color: rgba(225, 239, 255, 0.72);
  background: rgba(255, 255, 255, 0.045);
  font-size: 10px;
  white-space: nowrap;
}

.ant-agent-prompt-reference-item.is-mentioned {
  border-color: rgba(91, 205, 255, 0.46);
  color: #e8f8ff;
  background: rgba(36, 133, 184, 0.18);
}

.ant-agent-prompt-reference-thumb {
  position: relative;
  display: block;
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  overflow: hidden;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
}

.ant-agent-prompt-reference-thumb img,
.ant-agent-prompt-reference-thumb video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.ant-agent-prompt-reference-thumb i {
  position: absolute;
  top: 1px;
  left: 1px;
  display: grid;
  place-items: center;
  min-width: 13px;
  height: 13px;
  border-radius: 999px;
  padding: 0 3px;
  color: #fff;
  background: rgba(8, 16, 28, 0.84);
  font-size: 8px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

.ant-agent-prompt-reference-item figcaption {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.ant-agent-prompt-reference-item b,
.ant-agent-prompt-reference-item small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-prompt-reference-item b {
  font-size: 10px;
  font-weight: 850;
}

.ant-agent-prompt-reference-item small {
  color: rgba(209, 225, 245, 0.48);
  font-size: 8px;
}

.ant-agent-prompt-reference-item.is-mentioned b {
  color: #75d5ff;
}

.ant-agent-prompt-reference-tray > small {
  flex: 0 0 auto;
  color: rgba(189, 214, 244, 0.46);
  font-size: 9px;
  font-variant-numeric: tabular-nums;
}

.ant-agent-prompt-reference-tray.is-expanded {
  margin: 10px 12px 0;
  padding: 8px 10px;
}

.ant-agent-prompt-reference-tray.is-expanded .ant-agent-prompt-reference-list {
  gap: 8px;
}

.ant-agent-prompt-reference-tray.is-expanded .ant-agent-prompt-reference-item {
  display: grid;
  grid-template-rows: 54px auto;
  justify-items: center;
  width: 64px;
  max-width: none;
  height: 76px;
  padding: 3px;
  font-size: 12px;
}

.ant-agent-prompt-reference-tray.is-expanded .ant-agent-prompt-reference-thumb {
  flex-basis: 54px;
  width: 56px;
  height: 54px;
  border-radius: 6px;
}

.ant-agent-prompt-reference-tray.is-expanded .ant-agent-prompt-reference-thumb i {
  min-width: 16px;
  height: 16px;
  font-size: 9px;
}

.ant-agent-prompt-reference-tray.is-expanded figcaption {
  width: 100%;
  text-align: center;
}

.ant-agent-prompt-reference-tray.is-expanded b {
  font-size: 10px;
}

.ant-agent-prompt-reference-tray.is-expanded figcaption small {
  display: none;
}

.ant-agent-prompt-menu {
  position: absolute;
  left: 0;
  top: 34px;
  z-index: 36;
  display: grid;
  gap: 5px;
  width: min(300px, 94%);
  max-height: 260px;
  overflow: auto;
  border: 1px solid rgba(126, 192, 255, 0.28);
  border-radius: 10px;
  padding: 9px;
  color: #edf7ff;
  background: rgba(5, 13, 24, 0.97);
  box-shadow: 0 20px 58px rgba(0, 0, 0, 0.52);
  backdrop-filter: blur(14px);
}

.ant-agent-prompt-menu.is-reference-mention {
  top: 76px;
}

.ant-agent-prompt-menu > header {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}

.ant-agent-prompt-menu > header strong,
.ant-agent-prompt-menu > p {
  display: block;
  margin: 0;
  color: rgba(218, 234, 255, 0.66);
  font-size: 11px;
  line-height: 1.45;
}

.ant-agent-prompt-menu button {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 7px;
  align-items: center;
  min-height: 36px;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 0 8px;
  color: #edf6ff;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  text-align: left;
}

.ant-agent-prompt-menu button:hover,
.ant-agent-prompt-menu button.selected {
  border-color: rgba(103, 205, 255, 0.38);
  background: rgba(50, 154, 211, 0.16);
}

.ant-agent-prompt-menu button span {
  color: #7bd7ff;
  font-weight: 900;
}

.ant-agent-prompt-menu button b {
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-prompt-menu button small {
  color: rgba(215, 230, 250, 0.52);
  font-size: 9px;
  white-space: nowrap;
}

.ant-agent-prompt-menu > header [data-agent-prompt-menu-close] {
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
  flex: 0 0 26px;
  width: 26px;
  min-height: 26px;
  border-color: rgba(126, 192, 255, 0.2);
  padding: 0;
  color: rgba(231, 241, 255, 0.76);
  font-size: 17px;
  line-height: 1;
  text-align: center;
}

.ant-agent-prompt-menu > header [data-agent-prompt-menu-close]:hover,
.ant-agent-prompt-menu > header [data-agent-prompt-menu-close]:focus-visible {
  border-color: rgba(103, 205, 255, 0.5);
  color: #fff;
  background: rgba(50, 154, 211, 0.2);
  outline: none;
}

.ant-agent-node select,
.ant-agent-node textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 10px;
  color: #fff6da;
  background: rgba(0, 0, 0, 0.32);
  font: inherit;
  user-select: text;
}

.ant-agent-node select {
  min-height: 34px;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 800;
}

.ant-agent-node textarea {
  min-height: 76px;
  max-height: 130px;
  resize: vertical;
  padding: 9px;
  color: rgba(255, 246, 220, 0.86);
  font-size: calc(13px * var(--prompt-scale, 1));
  line-height: 1.5;
}

.ant-agent-node select:focus,
.ant-agent-node textarea:focus {
  border-color: rgba(255, 211, 122, 0.58);
  outline: none;
  box-shadow: 0 0 0 2px rgba(255, 211, 122, 0.12);
}

.ant-agent-node-actionbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.ant-agent-node-run-card {
  position: relative;
  display: grid;
  gap: 7px;
  overflow: hidden;
  border: 1px solid rgba(122, 178, 255, 0.24);
  border-radius: 10px;
  padding: 9px;
  background: linear-gradient(135deg, rgba(18, 42, 73, 0.72), rgba(7, 11, 20, 0.78));
}

.ant-agent-node-drawer .ant-agent-node-run-card {
  gap: 4px;
  padding: 7px 8px;
}

.ant-agent-node-drawer .ant-agent-node-run-grid,
.ant-agent-node-drawer .ant-agent-node-run-card > p {
  display: none;
}

.ant-agent-node-run-card.is-succeeded {
  border-color: rgba(83, 222, 154, 0.34);
  background: linear-gradient(135deg, rgba(16, 69, 49, 0.66), rgba(7, 18, 15, 0.8));
}

.ant-agent-node-run-card.is-preview {
  border-color: rgba(255, 194, 92, 0.42);
  background: linear-gradient(135deg, rgba(87, 58, 13, 0.68), rgba(27, 17, 5, 0.82));
}

.ant-agent-node-run-card.is-dirty {
  border-color: rgba(255, 211, 122, 0.46);
  background: linear-gradient(135deg, rgba(112, 78, 19, 0.66), rgba(30, 21, 7, 0.84));
}

.ant-agent-node-run-card.is-timeout {
  border-color: rgba(255, 211, 122, 0.38);
  background: linear-gradient(135deg, rgba(82, 62, 28, 0.66), rgba(21, 18, 11, 0.84));
}

.ant-agent-node-run-card.is-failed {
  border-color: rgba(255, 116, 92, 0.38);
  background: linear-gradient(135deg, rgba(91, 30, 25, 0.66), rgba(24, 9, 8, 0.82));
}

.ant-agent-node-run-card header,
.ant-agent-run-hud header {
  display: flex;
  gap: 7px;
  align-items: center;
}

.ant-agent-node-run-card header strong,
.ant-agent-run-hud header strong {
  min-width: 0;
  overflow: hidden;
  color: #f7fbff;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-node-run-card time,
.ant-agent-run-hud time {
  margin-left: auto;
  color: rgba(217, 235, 255, 0.72);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.ant-agent-run-pulse {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #78b9ff;
  box-shadow: 0 0 0 0 rgba(120, 185, 255, 0.55);
}

.is-submitting .ant-agent-run-pulse,
.is-queued .ant-agent-run-pulse,
.is-running .ant-agent-run-pulse {
  animation: ant-agent-run-pulse 1.2s ease-out infinite;
}

.is-succeeded .ant-agent-run-pulse {
  background: #55e19b;
}

.is-preview .ant-agent-run-pulse {
  background: #ffc25c;
}

.is-timeout .ant-agent-run-pulse {
  background: #ffd37a;
}

.is-failed .ant-agent-run-pulse {
  background: #ff765f;
}

@keyframes ant-agent-run-pulse {
  70% { box-shadow: 0 0 0 8px rgba(120, 185, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(120, 185, 255, 0); }
}

.ant-agent-node-run-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.ant-agent-node-run-grid span {
  display: grid;
  gap: 2px;
  min-width: 0;
  border-radius: 7px;
  padding: 6px;
  background: rgba(255, 255, 255, 0.045);
}

.ant-agent-node-run-grid small {
  color: rgba(184, 211, 255, 0.58);
  font-size: 9px;
}

.ant-agent-node-run-grid b {
  overflow: hidden;
  color: rgba(247, 251, 255, 0.88);
  font-size: 10px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-node-run-card > p {
  display: block;
  min-height: 0;
  margin: 0;
  color: rgba(220, 235, 255, 0.72);
  font-size: 10px;
  line-height: 1.35;
  -webkit-line-clamp: 2;
}

.ant-agent-run-progress {
  display: block;
  width: 100%;
  height: 3px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
}

.ant-agent-run-progress::after {
  content: "";
  display: block;
  width: 42%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, transparent, #78b9ff, transparent);
  animation: ant-agent-run-progress 1.25s ease-in-out infinite;
}

@keyframes ant-agent-run-progress {
  from { transform: translateX(-115%); }
  to { transform: translateX(340%); }
}

.ant-agent-node-actionbar button {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 226, 153, 0.16);
  border-radius: 8px;
  color: #f8f1dc;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  font-size: 18px;
}

.ant-agent-node-actionbar .ant-agent-run-button {
  grid-template-columns: auto auto;
  gap: 6px;
  width: auto;
  min-width: 102px;
  padding: 0 11px;
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-run-button i {
  width: 13px;
  min-height: 13px;
  display: grid;
  place-items: center;
  font-style: normal;
  font-size: 14px;
}

.ant-agent-run-button.is-submitting i,
.ant-agent-run-button.is-queued i,
.ant-agent-run-button.is-running i {
  border: 2px solid rgba(255, 255, 255, 0.28);
  border-top-color: #eef7ff;
  border-radius: 50%;
  animation: ant-agent-run-spin 0.75s linear infinite;
}

.ant-agent-run-button.is-succeeded {
  color: #dbfff0;
  border-color: rgba(83, 222, 154, 0.46);
  background: rgba(44, 154, 105, 0.2);
}

.ant-agent-run-button.is-preview {
  color: #fff3d3;
  border-color: rgba(255, 194, 92, 0.54);
  background: rgba(180, 115, 20, 0.24);
}

.ant-agent-run-button.is-dirty {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.72);
  background: linear-gradient(135deg, #ffd37a, #b77a24);
}

.ant-agent-run-button.is-timeout {
  color: #fff4d5;
  border-color: rgba(255, 211, 122, 0.5);
  background: rgba(176, 116, 32, 0.22);
}

.ant-agent-run-button.is-failed {
  color: #ffe3dc;
  border-color: rgba(255, 116, 92, 0.48);
  background: rgba(170, 55, 37, 0.2);
}

.ant-agent-run-button:disabled {
  cursor: wait;
  opacity: 0.9;
}

@keyframes ant-agent-run-spin {
  to { transform: rotate(360deg); }
}

.ant-agent-node-actionbar button:hover,
.ant-agent-node-actionbar button:focus-visible {
  color: #15100a;
  border-color: rgba(255, 211, 122, 0.72);
  background: linear-gradient(135deg, #ffd37a, #b77a24);
  outline: none;
}

.ant-agent-node-readonly {
  display: grid;
  gap: 4px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.ant-agent-node-readonly span,
.ant-agent-node-readonly small {
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  font-weight: 800;
}

.ant-agent-node-readonly strong {
  color: #fff7dd;
  font-size: 14px;
}

.ant-agent-node-prompt-text {
  display: -webkit-box;
  overflow: hidden;
  min-height: 72px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.ant-agent-node-foot {
  align-items: end;
}

.ant-agent-node-foot strong {
  color: #ffd37a;
  font-size: 12px;
}

.ant-agent-node-foot small {
  max-width: 160px;
  overflow: hidden;
  color: rgba(184, 211, 255, 0.74);
  font-size: 11px;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-canvas-hint {
  display: none;
  position: absolute;
  left: 14px;
  bottom: 14px;
  z-index: 4;
  max-width: calc(100% - 28px);
  border: 1px solid rgba(255, 226, 153, 0.16);
  border-radius: 999px;
  padding: 10px 14px;
  color: rgba(255, 246, 220, 0.76);
  background: rgba(0, 0, 0, 0.42);
  font-size: 14px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.ant-agent-minimap {
  display: none;
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 5;
  width: 168px;
  height: 86px;
  border: 1px solid rgba(255, 226, 153, 0.22);
  border-radius: 8px;
  background:
    linear-gradient(rgba(255, 226, 153, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 226, 153, 0.05) 1px, transparent 1px),
    rgba(1, 3, 9, 0.72);
  background-size: 16px 16px;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(8px);
}

.ant-agent-minimap span {
  position: absolute;
  border-radius: 2px;
  background: rgba(255, 211, 122, 0.42);
}

.ant-agent-minimap span.selected {
  background: #ffd37a;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.45);
}

.ant-agent-canvas-inspector {
  position: absolute;
  right: 68px;
  top: 16px;
  bottom: 16px;
  z-index: 24;
  display: grid;
  align-content: start;
  gap: 14px;
  width: min(390px, calc(100% - 116px));
  min-height: 0;
  overflow: auto;
  border: 1px solid rgba(255, 226, 153, 0.18);
  border-radius: 8px;
  padding: 18px;
  background: rgba(5, 7, 11, 0.9);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
  transform: translateX(calc(100% + 86px));
  opacity: 0;
  pointer-events: none;
  backdrop-filter: blur(16px);
  transition: transform 160ms ease, opacity 160ms ease;
}

.ant-agent-canvas-panel.is-inspector-open .ant-agent-canvas-inspector {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-sidebar,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-sidebar,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-sidebar,
.ant-agent-canvas-panel.is-local-fullscreen .ant-agent-canvas-inspector,
.ant-agent-canvas-panel.is-browser-fullscreen .ant-agent-canvas-inspector,
.ant-agent-canvas-panel:fullscreen .ant-agent-canvas-inspector {
  height: auto;
}

.ant-agent-inspector-head {
  display: grid;
  gap: 8px;
}

.ant-agent-inspector-head span {
  width: fit-content;
  border: 1px solid rgba(255, 211, 122, 0.3);
  border-radius: 999px;
  padding: 6px 10px;
  color: #ffd37a;
  font-size: 14px;
  font-weight: 900;
}

.ant-agent-inspector-head h3 {
  margin: 0;
  font-size: 24px;
}

.ant-agent-inspector-head p {
  margin: 0;
  color: rgba(255, 246, 220, 0.72);
  font-size: 15px;
  line-height: 1.65;
}

.ant-agent-canvas-inspector .status-list {
  border-color: rgba(255, 226, 153, 0.14);
}

.ant-agent-canvas-inspector .status-list div {
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 226, 153, 0.12);
}

.ant-agent-canvas-inspector .status-list span {
  color: rgba(255, 246, 220, 0.58);
  font-size: 13px;
}

.ant-agent-canvas-inspector .status-list strong {
  color: #fff1c8;
  font-size: 14px;
}

.ant-agent-output-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ant-agent-output-list strong {
  width: 100%;
  color: #ffd37a;
  font-size: 15px;
}

.ant-agent-output-list span {
  border: 1px solid rgba(184, 211, 255, 0.18);
  border-radius: 999px;
  padding: 7px 10px;
  color: #d8e6ff;
  background: rgba(65, 112, 190, 0.12);
  font-size: 13px;
}

.ant-agent-reference-list span {
  border-color: rgba(118, 190, 255, 0.3);
  color: #dff6ff;
  background: rgba(82, 168, 255, 0.14);
}

.ant-agent-node-config,
.ant-agent-result-preview,
.ant-agent-task-config {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.04);
}

.ant-agent-node-config strong,
.ant-agent-result-preview strong {
  color: #ffd37a;
  font-size: 15px;
}

.ant-agent-task-config {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ant-agent-task-config label {
  display: grid;
  gap: 6px;
  color: rgba(255, 246, 220, 0.62);
  font-size: 14px;
}

.ant-agent-task-config select {
  min-height: 42px;
  border: 1px solid rgba(255, 226, 153, 0.18);
  border-radius: 8px;
  padding: 0 10px;
  color: #fff6da;
  background: rgba(0, 0, 0, 0.28);
  font-size: 14px;
  font-weight: 800;
}

.ant-agent-task-config p {
  grid-column: 1 / -1;
  margin: 0;
  color: rgba(255, 246, 220, 0.66);
  font-size: 14px;
  line-height: 1.55;
}

.ant-agent-node-config pre {
  max-height: 170px;
  overflow: auto;
  margin: 0;
  border-radius: 8px;
  padding: 12px;
  color: #d8e6ff;
  background: rgba(0, 0, 0, 0.32);
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
}

.ant-agent-result-preview p,
.ant-agent-result-preview small {
  margin: 0;
  color: rgba(255, 246, 220, 0.68);
  font-size: 14px;
  line-height: 1.6;
}

.ant-agent-result-preview small {
  font-size: 12px;
}

.ant-agent-prompt-editor-overlay {
  position: absolute;
  inset: 0;
  z-index: 88;
  display: grid;
  place-items: center;
  padding: clamp(12px, 2.2vw, 28px);
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(10px);
}

.ant-agent-prompt-editor-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  width: min(1440px, calc(100vw - 36px), calc(100% - 20px));
  height: min(900px, calc(100vh - 36px), calc(100% - 20px));
  min-height: min(760px, calc(100% - 20px));
  overflow: hidden;
  border: 1px solid rgba(255, 211, 122, 0.18);
  border-radius: 20px;
  padding: clamp(14px, 1.5vw, 22px);
  color: #f4f7fb;
  background:
    linear-gradient(135deg, rgba(44, 39, 28, 0.96), rgba(16, 18, 22, 0.98) 42%, rgba(6, 10, 16, 0.98)),
    #171717;
  box-shadow: 0 46px 140px rgba(0, 0, 0, 0.76), inset 0 1px 0 rgba(255, 235, 190, 0.08);
}

.ant-agent-prompt-editor-panel > .ant-agent-prompt-toolbar {
  padding-bottom: 12px;
}

.ant-agent-prompt-toolbar.is-expanded button {
  min-height: 34px;
  padding: 0 11px;
  font-size: 12px;
}

.ant-agent-prompt-toolbar.is-expanded .icon-only.is-close {
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(255, 246, 220, 0.82);
  background: rgba(255, 255, 255, 0.06);
  font-size: 20px;
}

.ant-agent-prompt-editor-body {
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 226, 153, 0.12);
  border-radius: 16px;
  background:
    radial-gradient(circle at 18% 0%, rgba(255, 190, 88, 0.08), transparent 35%),
    linear-gradient(180deg, rgba(11, 12, 15, 0.78), rgba(5, 6, 8, 0.88));
}

.ant-agent-prompt-editor-body textarea {
  width: 100%;
  min-height: 0;
  height: 100%;
  resize: none;
  border: 0;
  padding: clamp(22px, 2.2vw, 36px);
  color: #fff8e8;
  background: transparent;
  outline: none;
  font: inherit;
  font-size: calc(20px * var(--prompt-scale, 1));
  font-weight: 650;
  line-height: 1.85;
  user-select: text;
  scrollbar-color: rgba(255, 211, 122, 0.48) rgba(255, 255, 255, 0.06);
}

.ant-agent-prompt-editor-body .ant-agent-prompt-menu {
  top: 22px;
  left: 22px;
  width: min(420px, calc(100% - 44px));
}

.ant-agent-prompt-editor-body .ant-agent-prompt-menu.is-reference-mention {
  top: 112px;
  left: 22px;
}

.ant-agent-prompt-editor-panel footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding-top: 14px;
}

.ant-agent-prompt-editor-panel footer > div {
  display: flex;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.ant-agent-prompt-editor-panel footer strong {
  min-width: 0;
  overflow: hidden;
  color: #fff6da;
  font-size: 14px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ant-agent-prompt-editor-panel footer span,
.ant-agent-prompt-editor-panel footer small {
  color: rgba(238, 242, 248, 0.62);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.ant-agent-prompt-editor-panel footer button {
  min-height: 42px;
  border: 1px solid rgba(255, 211, 122, 0.35);
  border-radius: 12px;
  padding: 0 22px;
  color: #120d06;
  background: linear-gradient(135deg, #ffe2a0, #cf9135);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
}

.ant-agent-prompt-editor-panel footer button.secondary {
  color: rgba(255, 246, 220, 0.82);
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.055);
}

.ant-agent-prompt-editor-panel footer button:disabled {
  cursor: wait;
  opacity: 0.62;
}

.ant-agent-preview-overlay {
  position: absolute;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 48px;
  background: rgba(0, 0, 0, 0.86);
  backdrop-filter: blur(8px);
}

.ant-agent-preview-close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: #fff6da;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  font-size: 26px;
}

.ant-agent-preview-toolbar {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  display: flex;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  padding: 6px;
  background: rgba(12, 14, 17, 0.72);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(16px);
}

.ant-agent-preview-toolbar button {
  width: 38px;
  height: 38px;
  font-size: 18px;
}

.ant-agent-preview-frame {
  position: relative;
  width: min(78vw, 1280px);
  max-width: calc(100% - 72px);
  margin: 0;
}

.ant-agent-preview-frame img,
.ant-agent-preview-frame video {
  width: 100%;
  max-height: min(76vh, 760px);
  object-fit: contain;
  display: block;
  border-radius: 8px;
  background: #05070b;
  box-shadow: 0 34px 100px rgba(0, 0, 0, 0.62);
}

.ant-agent-preview-text,
.ant-agent-preview-audio {
  display: grid;
  gap: 18px;
  max-height: min(76vh, 760px);
  overflow: auto;
  border: 1px solid rgba(132, 187, 255, 0.24);
  border-radius: 12px;
  padding: 28px;
  color: #f2f7ff;
  background: rgba(5, 10, 18, 0.94);
  box-shadow: 0 34px 100px rgba(0, 0, 0, 0.62);
}

.ant-agent-preview-text p {
  margin: 0;
  white-space: pre-wrap;
  user-select: text;
  font-size: 16px;
  line-height: 1.75;
}

.ant-agent-preview-audio audio {
  width: 100%;
}

.ant-agent-preview-frame figcaption {
  display: grid;
  gap: 5px;
  margin-top: 12px;
  color: rgba(255, 246, 220, 0.72);
  text-align: left;
}

.ant-agent-preview-frame figcaption strong {
  color: #fff6da;
  font-size: 18px;
}

.ant-agent-preview-frame figcaption span {
  font-size: 14px;
}

.ant-agent-preview-info {
  position: absolute;
  left: 24px;
  bottom: 24px;
  width: min(360px, calc(100% - 48px));
  display: none;
  gap: 8px;
  border: 1px solid rgba(255, 226, 153, 0.16);
  border-radius: 8px;
  padding: 12px;
  background: rgba(12, 13, 15, 0.72);
  color: rgba(255, 246, 220, 0.72);
}

.ant-agent-preview-info span {
  width: fit-content;
  border-radius: 999px;
  padding: 5px 8px;
  color: #15100a;
  background: #ffd37a;
  font-size: 13px;
  font-weight: 900;
}

.ant-agent-preview-info p {
  margin: 0;
  font-size: 14px;
  line-height: 1.58;
}

.ant-agent-connect-row {
  display: grid;
  gap: 6px;
  color: rgba(255, 246, 220, 0.62);
  font-size: 12px;
}

.ant-agent-connect-row select {
  min-height: 38px;
  border: 1px solid rgba(255, 226, 153, 0.18);
  border-radius: 8px;
  padding: 0 10px;
  color: #fff6da;
  background: rgba(0, 0, 0, 0.28);
}

.danger-link {
  color: #ffd7c7 !important;
  border-color: rgba(255, 146, 96, 0.22) !important;
}

.ant-agent-runtime-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 12px;
  background: rgba(0, 0, 0, 0.18);
}

.ant-agent-runtime-strip span {
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 999px;
  padding: 7px 10px;
  color: rgba(255, 246, 220, 0.68);
  background: rgba(255, 255, 255, 0.045);
  font-size: 12px;
}

.ant-agent-inspector-empty {
  display: grid;
  gap: 8px;
  place-items: center;
  min-height: 240px;
  color: rgba(255, 246, 220, 0.62);
  text-align: center;
}

.ant-agent-interface-panel {
  overflow: hidden;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.ant-agent-interface-panel summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
}

.ant-agent-interface-panel summary::-webkit-details-marker {
  display: none;
}

.ant-agent-interface-panel summary span,
.ant-agent-interface-panel summary small {
  color: rgba(255, 246, 220, 0.58);
  font-size: 12px;
}

.ant-agent-interface-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 0 16px 16px;
}

.ant-agent-interface-grid article {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(255, 226, 153, 0.14);
  border-radius: 8px;
  padding: 13px;
  background: rgba(5, 7, 12, 0.46);
}

.ant-agent-interface-grid span {
  color: #ffd37a;
  font-size: 12px;
  font-weight: 900;
}

.ant-agent-interface-grid strong {
  display: block;
  margin-top: 4px;
  color: #fff6da;
  font-size: 15px;
}

.ant-agent-interface-grid code {
  overflow-wrap: anywhere;
  color: #b8d3ff;
  font-size: 12px;
}

.ant-agent-interface-grid p {
  margin: 0;
  color: rgba(255, 246, 220, 0.66);
  font-size: 12px;
  line-height: 1.55;
}

@media (max-width: 1320px) {
  .ant-agent-standalone-hero,
  .ant-agent-canvas-eval {
    grid-template-columns: minmax(0, 1fr);
  }

  .ant-agent-canvas-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .ant-agent-canvas-inspector {
    min-height: auto;
  }

  .ant-agent-canvas-sidebar {
    min-height: auto;
  }

  .ant-agent-interface-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .ant-agent-canvas-stage {
    min-height: 500px;
  }

  .ant-agent-interface-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.studio-launch-panel {
  display: grid;
  gap: 16px;
}

.studio-brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  border: 1px solid rgba(214, 168, 71, 0.34);
  border-radius: 8px;
  padding: 8px 12px 8px 8px;
  background: rgba(17, 16, 13, 0.08);
  color: #11100d;
  font-weight: 900;
  line-height: 1;
}

.studio-brand-lockup img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  display: block;
}

.banner-brand-lockup {
  margin-bottom: 14px;
  border-color: rgba(255, 223, 143, 0.38);
  background: rgba(0, 0, 0, 0.32);
  color: #fff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.26);
}

.banner-brand-lockup img {
  width: 44px;
  height: 44px;
}

.hero-brand-lockup,
.launch-brand-lockup {
  margin-bottom: 14px;
}

.studio-launch-banner {
  overflow: hidden;
  border: 1px solid rgba(95, 123, 255, 0.22);
  border-radius: 8px;
  background: #080a0d;
  aspect-ratio: 2048 / 720;
}

.studio-launch-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.studio-logo-stage {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(132px, 210px) minmax(0, 1fr);
  align-items: center;
  gap: clamp(18px, 3.4vw, 42px);
  min-height: clamp(360px, 34vw, 520px);
  overflow: hidden;
  border: 1px solid rgba(255, 218, 142, 0.36);
  border-radius: 8px;
  padding: clamp(24px, 4.2vw, 54px);
  background: #050607;
  color: #f8edc9;
  box-shadow: 0 28px 90px rgba(5, 7, 10, 0.36);
}

.studio-logo-stage::before,
.studio-logo-stage::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
}

.studio-logo-stage::before {
  background:
    linear-gradient(90deg, rgba(3, 4, 7, 0.94), rgba(3, 4, 7, 0.68) 34%, rgba(3, 4, 7, 0.28) 62%, rgba(3, 4, 7, 0.74)),
    radial-gradient(circle at 22% 48%, rgba(214, 168, 71, 0.42), transparent 32%),
    radial-gradient(circle at 78% 18%, rgba(54, 111, 207, 0.22), transparent 34%);
}

.studio-logo-stage::after {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.12), transparent 26%),
    linear-gradient(135deg, transparent 0 45%, rgba(255, 218, 142, 0.18) 45.2% 45.6%, transparent 46% 100%);
  mix-blend-mode: screen;
  opacity: 0.52;
}

.studio-bg-carousel,
.studio-bg-slide,
.studio-bg-slide img {
  position: absolute;
  inset: 0;
}

.studio-bg-carousel {
  z-index: -2;
  background: #050607;
}

.studio-bg-slide {
  margin: 0;
  opacity: 0;
  animation: studioBackdropFade 18s ease-in-out infinite;
  animation-delay: calc(var(--slide-index) * 6s);
}

.studio-bg-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.02);
}

.studio-logo-orbit {
  width: min(28vw, 190px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 226, 153, 0.3);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.34);
  box-shadow:
    0 22px 70px rgba(0, 0, 0, 0.48),
    inset 0 0 32px rgba(214, 168, 71, 0.16);
  backdrop-filter: blur(7px);
}

.studio-logo-orbit img {
  width: 86%;
  aspect-ratio: 1;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.56));
}

.studio-logo-copy {
  max-width: 720px;
}

.studio-logo-copy span {
  display: block;
  color: #ffe091;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.68);
}

.studio-logo-copy strong {
  display: block;
  margin-top: 10px;
  color: #fff7dd;
  font-size: clamp(38px, 5.4vw, 78px);
  line-height: 0.98;
  text-shadow: 0 18px 46px rgba(0, 0, 0, 0.72);
}

.studio-logo-copy p {
  max-width: 42ch;
  margin: 14px 0 0;
  color: #fff3d0;
  font-size: clamp(15px, 1.3vw, 18px);
  line-height: 1.7;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.78);
}

.studio-logo-copy small {
  display: inline-flex;
  width: fit-content;
  margin-top: 18px;
  border: 1px solid rgba(255, 226, 153, 0.26);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(0, 0, 0, 0.38);
  color: rgba(255, 244, 211, 0.82);
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(7px);
}

.studio-carousel-dots {
  position: absolute;
  left: clamp(24px, 4.2vw, 54px);
  bottom: clamp(18px, 3vw, 32px);
  display: flex;
  gap: 8px;
}

.studio-carousel-dots span {
  width: 28px;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 241, 205, 0.26);
  animation: studioDotPulse 18s ease-in-out infinite;
  animation-delay: calc(var(--slide-index) * 6s);
}

@keyframes studioBackdropFade {
  0%,
  30% {
    opacity: 1;
  }
  36%,
  94% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@keyframes studioDotPulse {
  0%,
  30% {
    background: #ffe091;
    box-shadow: 0 0 14px rgba(255, 224, 145, 0.7);
  }
  36%,
  94% {
    background: rgba(255, 241, 205, 0.26);
    box-shadow: none;
  }
  100% {
    background: #ffe091;
    box-shadow: 0 0 14px rgba(255, 224, 145, 0.7);
  }
}

.studio-launch-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
}

.studio-launch-content h2 {
  margin: 0;
  font-size: 28px;
}

.studio-launch-content p:last-child {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.studio-launch-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.studio-launch-actions .primary-btn,
.studio-launch-actions .asset-link {
  margin: 0;
  text-decoration: none;
  white-space: nowrap;
}

.studio-launch-status {
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.workflow-rail {
  display: grid;
  grid-template-columns: repeat(7, minmax(170px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.workflow-stage {
  min-height: 210px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
  display: grid;
  align-content: start;
  gap: 8px;
}

.workflow-stage > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--accent);
  background: rgba(167, 121, 43, 0.1);
  font-weight: 900;
  font-size: 13px;
}

.workflow-stage h3,
.connector-card h3 {
  margin: 0;
  font-size: 16px;
}

.workflow-stage p,
.connector-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.connector-list {
  display: grid;
  gap: 12px;
}

.connector-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
  display: grid;
  gap: 10px;
}

.external-workflow-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.external-workflow-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 16px;
  display: grid;
  gap: 12px;
}

.workflow-card-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.workflow-card-head h3 {
  margin: 0;
  font-size: 18px;
}

.workflow-card-head > span {
  white-space: nowrap;
  border: 1px solid rgba(49, 95, 159, 0.18);
  border-radius: 8px;
  padding: 6px 8px;
  color: var(--blue);
  background: rgba(49, 95, 159, 0.08);
  font-size: 12px;
  font-weight: 800;
}

.external-workflow-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.external-workflow-card .status-list.compact div {
  grid-template-columns: minmax(0, 120px) minmax(0, 1fr);
}

.external-workflow-card .status-list span,
.external-workflow-card .status-list strong {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.command-list {
  display: grid;
  gap: 6px;
}

.command-list code {
  display: block;
  overflow-wrap: anywhere;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  background: #11100d;
  color: #f8f3e7;
  font-size: 12px;
  line-height: 1.5;
}

.role-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(180px, 1fr));
  gap: 14px;
  overflow-x: auto;
}

.role-card {
  min-height: 430px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 16px;
  display: grid;
  align-content: start;
  gap: 10px;
}

.role-card > span {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #11100d;
  background: var(--gold);
  font-weight: 900;
}

.role-card h3 {
  margin: 0;
  font-size: 18px;
}

.role-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.content-safety-panel {
  border-color: rgba(214, 168, 71, 0.28);
}

.content-safety-panel p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.safety-topic-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.safety-topic-row span {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 7px 10px;
  background: #fbfcfa;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.agent-grid {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  overflow-x: visible;
}

.agent-card {
  min-height: 220px;
}

.skill-repo-shell {
  display: grid;
  gap: 0;
  border: 1px solid rgba(214, 168, 71, 0.24);
  border-radius: 10px;
  overflow: hidden;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.08), transparent 42%),
    #11100d;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.skill-repo-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  padding: 18px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.18);
}

.skill-repo-path {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: #c8b993;
  font-size: 14px;
}

.skill-repo-path strong {
  color: #f6eddc;
  font-size: 20px;
}

.skill-repo-path em {
  border: 1px solid rgba(214, 168, 71, 0.3);
  border-radius: 999px;
  padding: 3px 8px;
  color: #f6d98c;
  font-style: normal;
  font-size: 12px;
}

.skill-repo-header p {
  margin: 8px 0 0;
  color: #c8b993;
  line-height: 1.7;
}

.skill-repo-actions,
.skill-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.skill-repo-tabs {
  display: flex;
  gap: 2px;
  padding: 0 18px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.18);
  background: rgba(0, 0, 0, 0.18);
}

.skill-repo-tabs span {
  padding: 13px 14px;
  border-bottom: 2px solid transparent;
  color: #c8b993;
  font-size: 13px;
  font-weight: 800;
}

.skill-repo-tabs span.active {
  border-bottom-color: #d6a847;
  color: #f6eddc;
}

.skill-repo-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  padding: 18px;
}

.skill-visual-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  padding: 18px 18px 0;
}

.skill-visual-card {
  position: relative;
  overflow: hidden;
  min-height: 280px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  background: #10151f;
  cursor: pointer;
}

.skill-visual-card img {
  width: 100%;
  aspect-ratio: 8 / 5;
  object-fit: cover;
  display: block;
  background: #10151f;
}

.skill-visual-card > div {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.skill-visual-card span,
.skill-visual-card em {
  color: #f6d98c;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.skill-visual-card h3 {
  margin: 0;
  color: #f6eddc;
  font-size: 15px;
  line-height: 1.35;
}

.skill-visual-card p {
  margin: 0;
  color: #c8b993;
  font-size: 12px;
  line-height: 1.55;
}

.skill-visual-card em {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 8px;
  border: 1px solid rgba(214, 168, 71, 0.26);
  border-radius: 999px;
  background: rgba(10, 10, 12, 0.72);
}

.skill-file-panel,
.skill-readme-panel {
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(10, 10, 12, 0.64);
}

.skill-file-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.18);
  color: #f6eddc;
  font-weight: 900;
}

.skill-file-toolbar span {
  color: #a99b7d;
  font-size: 12px;
}

.skill-gallery-panel {
  overflow: visible;
}

.skill-waterfall-grid {
  column-count: 3;
  column-gap: 14px;
  padding: 14px;
}

.skill-waterfall-card {
  position: relative;
  display: inline-block;
  width: 100%;
  margin: 0 0 14px;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(13, 15, 19, 0.92);
  break-inside: avoid;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.skill-waterfall-card:hover,
.skill-waterfall-card:focus-visible {
  border-color: rgba(214, 168, 71, 0.42);
  outline: none;
  transform: translateY(-2px);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

.skill-waterfall-cover {
  position: relative;
  background: #10151f;
}

.skill-waterfall-cover img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  background: #10151f;
}

.skill-waterfall-cover span {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 4px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: #fff7df;
  background: rgba(0, 0, 0, 0.56);
  font-size: 11px;
  font-weight: 900;
  backdrop-filter: blur(10px);
}

.skill-waterfall-body {
  display: grid;
  gap: 8px;
  padding: 11px 12px 12px;
}

.skill-waterfall-name {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
}

.skill-waterfall-name strong {
  color: #f6eddc;
  font-size: 14px;
  line-height: 1.3;
}

.skill-waterfall-name em {
  padding: 3px 7px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 999px;
  color: #f6d98c;
  background: rgba(214, 168, 71, 0.08);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.skill-waterfall-name em.installed {
  border-color: rgba(74, 222, 128, 0.24);
  color: #9af2bb;
  background: rgba(74, 222, 128, 0.1);
}

.skill-waterfall-body p {
  margin: 0;
  color: rgba(200, 185, 147, 0.84);
  font-size: 12px;
  line-height: 1.55;
}

.skill-waterfall-meta {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  max-height: 25px;
  overflow: hidden;
}

.skill-waterfall-body > small {
  overflow: hidden;
  color: rgba(169, 155, 125, 0.78);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.skill-file-row {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr) 160px;
  gap: 14px;
  align-items: start;
  padding: 14px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.12);
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
}

.skill-file-row:hover,
.skill-file-row:focus-visible {
  background: rgba(214, 168, 71, 0.08);
  outline: none;
}

.skill-file-cover {
  width: 132px;
  aspect-ratio: 8 / 5;
  object-fit: cover;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  background: #10151f;
}

.skill-file-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(214, 168, 71, 0.3);
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.12);
  color: #f6d98c;
  font-size: 12px;
  font-weight: 900;
}

.skill-file-main strong {
  display: block;
  color: #f6eddc;
  font-size: 15px;
}

.skill-file-main p {
  margin: 4px 0 10px;
  color: #c8b993;
  font-size: 13px;
  line-height: 1.6;
}

.skill-file-side {
  display: grid;
  gap: 7px;
  justify-items: end;
  color: #a99b7d;
  font-size: 12px;
  text-align: right;
}

.skill-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.skill-row-actions a,
.skill-row-actions button {
  border: 1px solid rgba(214, 168, 71, 0.22);
  border-radius: 8px;
  padding: 7px 9px;
  background: rgba(214, 168, 71, 0.08);
  color: #f6d98c;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}

.skill-row-actions a:hover,
.skill-row-actions button:hover {
  background: rgba(214, 168, 71, 0.16);
}

.skill-detail-actions .asset-link.primary-link {
  border-color: rgba(214, 168, 71, 0.52);
  background: linear-gradient(135deg, #d6a847, #f4d37d);
  color: #11100d;
}

.skill-detail-actions .asset-link.muted-link {
  opacity: 0.72;
}

:root[data-theme] .skill-detail-actions .asset-link.primary-link {
  border-color: rgba(214, 168, 71, 0.52);
  background: linear-gradient(135deg, #d6a847, #f4d37d);
  color: #11100d;
}

:root[data-theme] .skill-detail-actions .asset-link.muted-link {
  opacity: 0.72;
}

.skill-install-state {
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 999px;
  padding: 5px 9px;
  color: #f6d98c;
  background: rgba(214, 168, 71, 0.08);
  font-weight: 900;
}

.skill-install-state.installed,
.copy-btn.is-installed {
  border-color: rgba(94, 234, 142, 0.42);
  color: #b7f7c8;
  background: rgba(22, 101, 52, 0.34);
}

.skill-readme-panel {
  padding: 16px;
  color: #c8b993;
}

.skill-readme-panel h3 {
  margin: 0 0 10px;
  color: #f6eddc;
}

.skill-readme-panel p,
.skill-readme-panel dd {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
}

.skill-readme-panel dl {
  display: grid;
  gap: 12px;
  margin: 16px 0 0;
}

.skill-readme-panel dt {
  color: #f6d98c;
  font-size: 12px;
  font-weight: 900;
}

.skill-category-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.skill-category-cloud span,
.skill-file-tree span {
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  padding: 6px 8px;
  color: #f6eddc;
  background: rgba(255, 255, 255, 0.04);
  font-size: 12px;
  font-weight: 800;
}

body.clean-ui .skill-repo-shell {
  border-radius: 8px;
  background: rgba(10, 10, 12, 0.72);
  box-shadow: 0 18px 58px rgba(0, 0, 0, 0.2);
}

body.clean-ui .skill-repo-header {
  align-items: center;
  padding: 12px 14px;
}

body.clean-ui .skill-repo-title {
  display: grid;
  gap: 6px;
  min-width: 0;
}

body.clean-ui .skill-repo-path {
  gap: 7px;
  font-size: 13px;
}

body.clean-ui .skill-repo-path strong {
  font-size: clamp(19px, 2vw, 25px);
}

body.clean-ui .skill-repo-path em {
  display: inline-flex;
  padding: 2px 7px;
  font-size: 11px;
}

body.clean-ui .skill-repo-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: rgba(246, 237, 220, 0.58);
  font-size: 12px;
  font-weight: 800;
}

body.clean-ui .skill-repo-actions .asset-link,
body.clean-ui .skill-repo-actions button {
  min-height: 30px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
}

body.clean-ui .skill-repo-tabs {
  padding: 0 14px;
}

body.clean-ui .skill-repo-tabs span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 38px;
  padding: 0 11px;
  font-size: 12px;
}

body.clean-ui .skill-repo-tabs b {
  display: inline-grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 999px;
  color: rgba(246, 237, 220, 0.72);
  background: rgba(255, 255, 255, 0.08);
  font-size: 11px;
}

body.clean-ui .skill-repo-layout {
  grid-template-columns: minmax(0, 1fr) 292px;
  gap: 14px;
  padding: 14px;
}

body.clean-ui .skill-file-panel,
body.clean-ui .skill-readme-panel {
  border-radius: 8px;
  background: rgba(8, 9, 12, 0.64);
}

body.clean-ui .skill-file-toolbar {
  min-height: 40px;
  padding: 9px 12px;
}

body.clean-ui .skill-file-row {
  grid-template-columns: 82px minmax(0, 1fr) 132px;
  gap: 11px;
  align-items: center;
  min-height: 94px;
  padding: 10px 12px;
}

body.clean-ui .skill-file-cover {
  width: 82px;
  aspect-ratio: 16 / 10;
  border-radius: 6px;
}

body.clean-ui .skill-file-main strong {
  font-size: 14px;
  line-height: 1.25;
}

body.clean-ui .skill-file-main p {
  margin: 3px 0 7px;
  overflow: hidden;
  color: rgba(200, 185, 147, 0.82);
  font-size: 12px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.clean-ui .skill-file-main .meta-row {
  gap: 5px;
  max-height: 24px;
  overflow: hidden;
}

body.clean-ui .skill-row-actions {
  gap: 6px;
  margin-top: 7px;
}

body.clean-ui .skill-row-actions a,
body.clean-ui .skill-row-actions button {
  min-height: 26px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 11px;
}

body.clean-ui .skill-file-side {
  gap: 4px;
  font-size: 11px;
}

body.clean-ui .skill-file-side small {
  max-width: 128px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.clean-ui .skill-install-state {
  padding: 4px 8px;
  font-size: 11px;
}

body.clean-ui .skill-readme-panel {
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 0;
}

body.clean-ui .skill-about-card {
  display: grid;
  gap: 9px;
  padding: 12px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.14);
}

body.clean-ui .skill-about-card:last-child {
  border-bottom: 0;
}

body.clean-ui .skill-about-card h3 {
  margin: 0;
  color: #f6eddc;
  font-size: 14px;
}

body.clean-ui .skill-about-card p {
  display: block;
  margin: 0;
  color: rgba(200, 185, 147, 0.82);
  font-size: 12px;
  line-height: 1.55;
}

body.clean-ui .skill-about-card code {
  display: block;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.14);
  border-radius: 8px;
  padding: 8px;
  color: #f8d985;
  background: rgba(0, 0, 0, 0.3);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.clean-ui .skill-about-card .asset-link {
  width: fit-content;
}

body.clean-ui .skill-release-mini {
  display: grid;
  gap: 3px;
  border: 1px solid rgba(214, 168, 71, 0.13);
  border-radius: 8px;
  padding: 8px;
  color: #f6eddc;
  background: rgba(255, 255, 255, 0.035);
  text-decoration: none;
}

body.clean-ui .skill-release-mini strong {
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.clean-ui .skill-release-mini span {
  color: rgba(200, 185, 147, 0.72);
  font-size: 11px;
}

body.clean-ui .skill-category-cloud {
  gap: 6px;
  margin-top: 0;
}

body.clean-ui .skill-category-cloud span {
  padding: 4px 7px;
  border-radius: 999px;
  font-size: 11px;
}

body.clean-ui .skill-gallery-panel {
  overflow: visible;
}

body.clean-ui .skill-waterfall-grid {
  column-gap: 12px;
  padding: 12px;
}

body.clean-ui .skill-waterfall-card {
  margin-bottom: 12px;
  border-radius: 7px;
}

body.clean-ui .skill-waterfall-body {
  gap: 7px;
  padding: 10px;
}

body.clean-ui .skill-waterfall-name strong {
  font-size: 13px;
}

body.clean-ui .skill-waterfall-body p {
  font-size: 12px;
}

.skill-detail-dialog .detail-media {
  background:
    radial-gradient(circle at 50% 28%, rgba(214, 168, 71, 0.3), transparent 34%),
    linear-gradient(145deg, #0b1220, #17140f);
}

.skill-detail-dialog {
  width: min(1320px, 100%);
  grid-template-columns: minmax(420px, 0.95fr) minmax(420px, 1.05fr);
}

.skill-detail-dialog .detail-media > img {
  max-height: calc(100vh - 96px);
  padding: 18px;
  object-fit: contain;
}

.skill-page-shell {
  display: grid;
  gap: 18px;
  max-width: 1420px;
  margin: 0 auto;
}

.skill-page-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: #9d8d70;
  font-size: 13px;
  font-weight: 800;
}

.skill-page-breadcrumb a {
  color: #f6d98c;
  text-decoration: none;
}

.skill-page-breadcrumb strong {
  color: #f6eddc;
}

.skill-page-hero {
  display: grid;
  grid-template-columns: minmax(420px, 0.95fr) minmax(460px, 1.05fr);
  gap: 24px;
  align-items: stretch;
  padding: 18px;
  border: 1px solid rgba(214, 168, 71, 0.22);
  border-radius: 10px;
  background:
    radial-gradient(circle at 18% 18%, rgba(30, 112, 214, 0.18), transparent 36%),
    radial-gradient(circle at 78% 22%, rgba(214, 168, 71, 0.13), transparent 34%),
    linear-gradient(135deg, rgba(12, 16, 24, 0.96), rgba(19, 16, 11, 0.94));
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

.skill-page-visual-panel,
.skill-page-copy-panel {
  min-width: 0;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 10px;
  background: rgba(4, 7, 12, 0.54);
}

.skill-page-visual-panel {
  display: grid;
  align-content: start;
  overflow: hidden;
}

.skill-page-visual-panel > img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  padding: 0;
  background:
    radial-gradient(circle at 50% 20%, rgba(214, 168, 71, 0.18), transparent 36%),
    linear-gradient(145deg, rgba(10, 17, 31, 0.95), rgba(8, 8, 10, 0.98));
  filter: brightness(1.12) contrast(1.04);
}

.skill-page-visual-caption {
  display: grid;
  gap: 5px;
  padding: 14px 16px 16px;
  border-top: 1px solid rgba(214, 168, 71, 0.14);
}

.skill-page-visual-caption strong,
.skill-purpose-callout strong,
.skill-page-sidebar span {
  color: #f6d98c;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.skill-page-visual-caption span {
  color: #c8b993;
  font-size: 13px;
  line-height: 1.65;
}

.skill-page-copy-panel {
  padding: 24px;
}

.skill-page-copy-panel h2 {
  margin: 16px 0 10px;
  color: #fff7e8;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.05;
  letter-spacing: 0;
}

.skill-page-shell-wide-visual,
.skill-page-shell[data-skill-id="storyboard-creation"] {
  max-width: 1500px;
}

.skill-page-shell-wide-visual .skill-page-hero,
.skill-page-shell[data-skill-id="storyboard-creation"] .skill-page-hero {
  grid-template-columns: 1fr;
  padding: 22px;
}

.skill-page-shell-wide-visual .skill-page-visual-panel,
.skill-page-shell[data-skill-id="storyboard-creation"] .skill-page-visual-panel {
  background: #f8fbff;
  border-color: rgba(18, 104, 243, 0.18);
  box-shadow: 0 22px 70px rgba(15, 23, 42, 0.28);
}

.skill-page-shell-wide-visual .skill-page-visual-panel > img,
.skill-page-shell[data-skill-id="storyboard-creation"] .skill-page-visual-panel > img {
  aspect-ratio: 1920 / 820;
  object-fit: contain;
  background: #f8fbff;
  filter: none;
}

.skill-page-shell-wide-visual .skill-page-visual-caption,
.skill-page-shell[data-skill-id="storyboard-creation"] .skill-page-visual-caption {
  background: linear-gradient(135deg, rgba(7, 19, 38, 0.96), rgba(16, 24, 38, 0.94));
}

.skill-page-shell-wide-visual .skill-page-copy-panel,
.skill-page-shell[data-skill-id="storyboard-creation"] .skill-page-copy-panel {
  display: grid;
  gap: 14px;
}

.skill-page-shell-wide-visual .skill-page-copy-panel h2,
.skill-page-shell[data-skill-id="storyboard-creation"] .skill-page-copy-panel h2 {
  margin-top: 2px;
  font-size: clamp(32px, 4vw, 56px);
}

.skill-purpose-callout {
  display: grid;
  gap: 8px;
  margin: 18px 0 0;
  padding: 16px;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.12), rgba(30, 112, 214, 0.07)),
    rgba(255, 255, 255, 0.035);
}

.skill-purpose-callout p {
  margin: 0;
  color: #eadbbe;
  font-size: 14px;
  line-height: 1.7;
}

.skill-page-github-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.skill-page-sidebar {
  position: sticky;
  top: 88px;
  display: grid;
  gap: 10px;
}

.skill-page-sidebar article,
.skill-page-main {
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 10px;
  background: rgba(8, 9, 12, 0.68);
}

.skill-page-sidebar article {
  display: grid;
  gap: 7px;
  padding: 14px;
}

.skill-page-sidebar strong {
  color: #f6eddc;
  font-size: 14px;
}

.skill-page-sidebar p {
  margin: 0;
  color: #c8b993;
  font-size: 12px;
  line-height: 1.6;
  word-break: break-word;
}

.skill-page-main {
  min-width: 0;
  overflow: hidden;
}

.skill-page-main .skill-detail-tabs {
  margin: 0;
  padding: 0 14px;
  background: rgba(255, 255, 255, 0.025);
}

.skill-page-main .detail-section {
  margin: 0;
  border-right: 0;
  border-left: 0;
  border-radius: 0;
  background: transparent;
}

.skill-page-main .detail-section:last-child {
  border-bottom: 0;
}

.skill-side-summary {
  display: grid;
  gap: 12px;
  width: calc(100% - 36px);
  margin: 0 18px 18px;
  padding: 14px;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  background: rgba(8, 10, 14, 0.76);
  color: #d8c8a8;
}

.skill-side-summary strong {
  color: #f6eddc;
  font-size: 15px;
}

.skill-side-summary span {
  color: #c8b993;
  font-size: 13px;
  line-height: 1.6;
}

.skill-side-summary dl {
  display: grid;
  gap: 8px;
  margin: 0;
}

.skill-side-summary div {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 10px;
}

.skill-side-summary dt,
.skill-side-summary dd {
  margin: 0;
  font-size: 12px;
}

.skill-side-summary dt {
  color: #f6d98c;
  font-weight: 900;
}

.skill-repository-topline {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin: 6px 0 10px;
  padding: 10px 12px;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: #c8b993;
  font-size: 13px;
}

.skill-repository-topline strong,
.skill-repository-topline em {
  color: #f6d98c;
  font-style: normal;
  font-weight: 900;
}

.skill-mirror-note {
  display: grid;
  gap: 6px;
  margin-top: 14px;
  padding: 12px 13px;
  border: 1px solid rgba(94, 234, 142, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(94, 234, 142, 0.12), transparent 56%),
    rgba(255, 255, 255, 0.035);
}

.skill-mirror-note strong {
  color: #b7f7c8;
  font-size: 13px;
  font-weight: 900;
}

.skill-mirror-note span {
  color: #d8c8a8;
  font-size: 13px;
  line-height: 1.65;
}

.skill-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0 0;
}

.skill-overview-grid article {
  min-height: 132px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  padding: 13px;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.08), rgba(44, 90, 156, 0.06)),
    rgba(10, 13, 19, 0.66);
}

.skill-overview-grid h3 {
  margin: 0 0 8px;
  color: #f6d98c;
  font-size: 13px;
}

.skill-overview-grid ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.skill-overview-grid li {
  position: relative;
  padding-left: 14px;
  color: #d8c8a8;
  font-size: 12px;
  line-height: 1.55;
}

.skill-overview-grid li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #d6a847;
  box-shadow: 0 0 14px rgba(214, 168, 71, 0.45);
}

.skill-detail-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin-top: 16px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.18);
}

.skill-detail-tabs a {
  padding: 11px 12px;
  border-bottom: 2px solid transparent;
  color: #c8b993;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.skill-detail-tabs a.active,
.skill-detail-tabs a:hover {
  border-bottom-color: #d6a847;
  color: #f6eddc;
}

.skill-code-table {
  display: grid;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
}

.skill-code-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 11px 12px;
  border-bottom: 1px solid rgba(214, 168, 71, 0.12);
  background: rgba(255, 255, 255, 0.028);
}

.skill-code-row:last-child {
  border-bottom: 0;
}

.skill-code-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.14);
  color: #f6d98c;
  font-size: 10px;
  font-weight: 900;
}

.skill-code-row a,
.skill-code-row strong {
  display: block;
  color: #f6eddc;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.skill-code-row small {
  display: block;
  margin-top: 3px;
  color: #a99b7d;
  font-size: 12px;
  line-height: 1.45;
}

.skill-code-row em {
  color: #c8b993;
  font-size: 12px;
  font-style: normal;
}

.skill-download-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.skill-download-grid a {
  display: grid;
  gap: 6px;
  padding: 13px;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.12), transparent 62%),
    rgba(255, 255, 255, 0.035);
  color: #f6eddc;
  text-decoration: none;
}

.skill-download-grid a:hover {
  border-color: rgba(214, 168, 71, 0.42);
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.18), transparent 62%),
    rgba(255, 255, 255, 0.055);
}

.skill-download-grid span {
  color: #c8b993;
  font-size: 12px;
}

.skill-submit-section {
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.06), rgba(30, 112, 214, 0.04)),
    rgba(8, 9, 12, 0.72);
}

.skill-submit-link-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px;
}

.skill-submit-link-grid a {
  display: grid;
  gap: 7px;
  min-width: 0;
  padding: 13px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.1), rgba(44, 90, 156, 0.06)),
    rgba(255, 255, 255, 0.035);
  color: #f6eddc;
  text-decoration: none;
}

.skill-submit-link-grid a:hover {
  border-color: rgba(214, 168, 71, 0.45);
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.16), rgba(44, 90, 156, 0.1)),
    rgba(255, 255, 255, 0.055);
}

.skill-submit-link-grid span {
  width: max-content;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(214, 168, 71, 0.14);
  color: #f6d98c;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.skill-submit-link-grid strong {
  color: #fff6e5;
  font-size: 14px;
}

.skill-submit-link-grid small {
  color: #c8b993;
  font-size: 12px;
  line-height: 1.55;
}

.skill-submit-link-grid em {
  overflow-wrap: anywhere;
  color: #91a7c2;
  font-size: 11px;
  font-style: normal;
  line-height: 1.45;
}

.skill-edit-targets {
  display: grid;
  gap: 10px;
  padding: 0 14px 14px;
}

.skill-edit-targets h4 {
  margin: 4px 0 0;
  color: #f6d98c;
  font-size: 13px;
}

.skill-edit-targets div {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr) minmax(180px, 0.9fr) auto;
  gap: 10px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid rgba(214, 168, 71, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.028);
}

.skill-edit-targets span {
  color: #f6d98c;
  font-size: 12px;
  font-weight: 900;
}

.skill-edit-targets code {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #f6eddc;
  font-size: 12px;
}

.skill-edit-targets small {
  color: #a99b7d;
  font-size: 12px;
  line-height: 1.45;
}

.skill-release-list {
  display: grid;
  gap: 10px;
}

.skill-release-card {
  display: grid;
  gap: 10px;
  padding: 13px;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.skill-release-card span {
  display: inline-flex;
  width: max-content;
  margin-bottom: 6px;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(214, 168, 71, 0.14);
  color: #f6d98c;
  font-size: 11px;
  font-weight: 900;
}

.skill-release-card h4 {
  margin: 0;
  color: #f6eddc;
  font-size: 14px;
}

.skill-release-card small {
  color: #a99b7d;
  font-size: 12px;
}

.skill-release-card ul {
  margin: 0;
  padding-left: 18px;
  color: #d8c8a8;
  font-size: 13px;
  line-height: 1.7;
}

.skill-command-block {
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: center !important;
}

.skill-command-block code {
  overflow: auto;
  white-space: nowrap;
  color: #f6eddc;
  font-size: 12px;
}

.skill-file-tree {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-usage-steps {
  display: grid;
  gap: 10px;
}

.skill-usage-steps div:not(.detail-section-head) {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.skill-usage-steps b {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #d6a847;
  color: #11100d;
  font-size: 14px;
}

.skill-usage-steps span {
  color: #d8c8a8;
  font-size: 13px;
  line-height: 1.55;
}

.skill-effect-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.skill-effect-grid a {
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: #d8c8a8;
  text-decoration: none;
}

.skill-effect-grid img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
  background: #10151f;
}

.skill-effect-grid span {
  display: block;
  padding: 8px 10px;
  color: #d8c8a8;
  font-size: 12px;
  font-weight: 800;
}

.clickable-card {
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.clickable-card:hover,
.clickable-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(214, 168, 71, 0.58);
  box-shadow: 0 18px 42px rgba(17, 16, 13, 0.12);
  outline: none;
}

.role-columns {
  display: grid;
  gap: 10px;
}

.role-columns div {
  display: grid;
  gap: 6px;
  align-content: start;
}

.role-columns strong {
  color: var(--ink);
  font-size: 13px;
}

.role-columns em {
  display: block;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 8px;
  color: var(--muted);
  background: #fbfcfa;
  font-style: normal;
  font-size: 12px;
  line-height: 1.45;
}

.visibility-table {
  display: grid;
  grid-template-columns: repeat(7, minmax(150px, 1fr));
  gap: 10px;
  overflow-x: auto;
}

.visibility-table div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfcfa;
}

.visibility-table strong,
.visibility-table span {
  display: block;
}

.visibility-table strong {
  color: var(--ink);
  margin-bottom: 6px;
}

.visibility-table span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.admin-access {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
  padding: 16px;
  display: grid;
  gap: 10px;
}

.admin-access label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.admin-access .copy-btn {
  margin-top: 0;
}

.admin-access p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.ops-stack {
  display: grid;
  gap: 18px;
}

.ops-message {
  border: 1px solid rgba(167, 121, 43, 0.28);
  border-radius: 8px;
  padding: 12px 14px;
  color: var(--accent);
  background: rgba(167, 121, 43, 0.08);
  font-weight: 700;
}

.antpower-start-guide {
  display: grid;
  grid-template-columns: minmax(280px, 0.88fr) minmax(420px, 1.12fr);
  gap: 18px;
  align-items: stretch;
  margin-bottom: 18px;
  background:
    linear-gradient(135deg, rgba(17, 16, 13, 0.96), rgba(42, 32, 18, 0.9)),
    radial-gradient(circle at 80% 18%, rgba(214, 168, 71, 0.22), transparent 32%);
  color: #fff7dd;
}

.antpower-guide-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
}

.antpower-guide-copy h2 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 46px);
  line-height: 1.02;
}

.antpower-guide-copy p {
  margin: 0;
  color: #e7d8b8;
  line-height: 1.7;
}

.antpower-guide-steps {
  display: grid;
  gap: 10px;
}

.antpower-guide-steps div {
  display: grid;
  grid-template-columns: 54px minmax(100px, 0.34fr) minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border: 1px solid rgba(255, 224, 150, 0.2);
  border-radius: 8px;
  padding: 13px 14px;
  background: rgba(0, 0, 0, 0.22);
}

.antpower-guide-steps b {
  color: #d6a847;
  font-size: 22px;
}

.antpower-guide-steps strong {
  color: #fff;
}

.antpower-guide-steps span {
  color: #dfcfaa;
  line-height: 1.55;
  font-size: 13px;
}

.antpower-start-guide .studio-launch-actions {
  margin-top: 4px;
}

.antpower-start-guide .asset-link {
  color: #f4d589;
  background: rgba(255, 255, 255, 0.05);
}

.status-list {
  display: grid;
  gap: 10px;
}

.status-list div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px 12px;
  background: #fbfcfa;
}

.status-list.compact {
  gap: 6px;
}

.status-list.compact div {
  grid-template-columns: 86px minmax(0, 1fr);
  padding: 8px 9px;
}

.status-list span {
  color: var(--muted);
  font-size: 13px;
}

.status-list strong {
  color: var(--ink);
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.backup-list {
  display: grid;
  gap: 10px;
}

.home-mode {
  background: #0f0e0b;
}

.home-mode .sidebar {
  background:
    linear-gradient(180deg, rgba(214, 168, 71, 0.14), transparent 30%),
    #090805;
  border-right: 1px solid #2a2418;
}

.home-mode .main {
  background: #0f0e0b;
  color: #f8f3e7;
}

.home-mode .topbar {
  border-bottom: 1px solid #2a2418;
  padding-bottom: 18px;
}

.home-mode .eyebrow {
  color: #d6a847;
}

.home-mode #global-search {
  background: #17140f;
  color: #f8f3e7;
  border-color: #332b1d;
}

.home-mode #global-search::placeholder {
  color: #84897d;
}

.home-mode .auth-btn {
  color: #f8f3e7;
  border-color: #332b1d;
  background: #17140f;
}

.home-mode .auth-btn.register {
  color: #11100d;
  border-color: #d6a847;
  background: #d6a847;
}

.home-mode .view-root {
  gap: 42px;
}

.home-top-info {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 18px;
  align-items: stretch;
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 8px;
  padding: 24px;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.14), transparent 42%),
    linear-gradient(320deg, rgba(49, 95, 159, 0.18), transparent 46%),
    #15130f;
}

.home-top-copy {
  display: grid;
  align-content: center;
  gap: 14px;
}

.home-top-copy h2 {
  margin: 0;
  color: #fff;
  font-size: 34px;
  line-height: 1.18;
}

.home-top-copy p {
  max-width: 780px;
  margin: 0;
  color: #d6ccb7;
  font-size: 15px;
  line-height: 1.75;
}

.status-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-chip-row span,
.quick-entry {
  border: 1px solid #332b1d;
  border-radius: 8px;
  color: #d6ccb7;
  background: rgba(17, 16, 13, 0.62);
}

.status-chip-row span {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  padding: 8px 10px;
  font-size: 12px;
}

.status-chip-row strong {
  color: #f0c25a;
}

.quick-entry-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.quick-entry {
  min-height: 44px;
  padding: 10px 12px;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  text-align: left;
}

.quick-entry:hover,
.quick-entry:focus-visible {
  border-color: rgba(214, 168, 71, 0.58);
  color: #fff;
  outline: none;
}

.quick-entry.primary {
  color: #11100d;
  border-color: #d6a847;
  background: #d6a847;
}

.home-banner {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(240, 194, 90, 0.58);
  border-radius: 12px;
  background:
    radial-gradient(circle at 74% 50%, rgba(240, 194, 90, 0.42), transparent 33%),
    radial-gradient(circle at 34% 16%, rgba(49, 95, 159, 0.48), transparent 34%),
    linear-gradient(135deg, #08090d 0%, #111926 48%, #2b120e 100%);
  box-shadow: 0 34px 100px rgba(0, 0, 0, 0.42);
}

.home-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(112deg, rgba(240, 194, 90, 0.16), transparent 26%),
    linear-gradient(72deg, transparent 44%, rgba(255, 255, 255, 0.16) 45%, transparent 46%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.026) 0 1px, transparent 1px 72px);
  mix-blend-mode: screen;
}

.banner-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  scroll-behavior: smooth;
}

.banner-track::-webkit-scrollbar {
  display: none;
}

.banner-slide {
  position: relative;
  height: clamp(500px, 43vw, 700px);
  min-height: 500px;
  scroll-snap-align: start;
  overflow: hidden;
  cursor: pointer;
  background:
    linear-gradient(118deg, rgba(9, 7, 4, 0.38) 0%, rgba(14, 15, 21, 0.18) 42%, rgba(10, 8, 5, 0.14) 100%);
}

.banner-slide .banner-panorama,
.banner-slide .portal-placeholder {
  width: 100%;
  height: 100%;
  min-height: 500px;
  display: block;
}

.banner-slide .banner-panorama {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: center;
  opacity: 1;
  filter: saturate(1.32) contrast(1.12) brightness(1.24);
  transform: scale(1.012);
}

.banner-shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(circle at 50% 48%, rgba(255, 188, 74, 0.08) 0%, transparent 44%, rgba(0, 0, 0, 0.24) 100%),
    linear-gradient(90deg, rgba(3, 3, 4, 0.16), rgba(6, 6, 8, 0.05) 26%, transparent 62%, rgba(4, 4, 5, 0.12)),
    linear-gradient(180deg, rgba(255, 225, 155, 0.08), transparent 54%, rgba(8, 6, 4, 0.34));
}

.banner-cinematic-panel {
  display: none;
}

.banner-cinematic-panel span,
.banner-cinematic-panel small {
  color: rgba(255, 224, 150, 0.74);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.banner-cinematic-panel strong {
  color: #fff7dd;
  font-size: clamp(20px, 1.8vw, 30px);
  line-height: 1.08;
}

.banner-copy {
  position: absolute;
  z-index: 3;
  left: clamp(20px, 3vw, 38px);
  top: clamp(20px, 3vw, 38px);
  width: min(380px, 31%);
  padding: 11px 13px 13px;
  border: 1px solid rgba(255, 224, 150, 0.22);
  border-left: 3px solid #d6a847;
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(8, 9, 12, 0.58), rgba(8, 9, 12, 0.24)),
    rgba(0, 0, 0, 0.12);
  color: #fff;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(7px);
}

.banner-copy h2 {
  max-width: 13ch;
  margin: 9px 0 7px;
  font-size: clamp(26px, 2.3vw, 36px);
  line-height: 1.04;
  text-wrap: balance;
  text-shadow: 0 14px 38px rgba(0, 0, 0, 0.7);
}

.banner-copy p {
  margin: 0 0 12px;
  max-width: 40ch;
  color: #eee0c5;
  font-size: 13px;
  line-height: 1.52;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  text-shadow: 0 10px 28px rgba(0, 0, 0, 0.7);
}

.banner-copy .live-badge {
  min-height: 22px;
  padding: 4px 10px;
  font-size: 11px;
}

.banner-copy .hero-btn {
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 10px;
  box-shadow: 0 10px 26px rgba(214, 168, 71, 0.24);
}

.banner-slide-zhangdao-method .banner-panorama {
  object-position: 62% center;
  filter: saturate(1.22) contrast(1.08) brightness(1.16);
}

.banner-slide-zhangdao-method .banner-shade {
  background:
    radial-gradient(circle at 62% 42%, transparent 0%, transparent 43%, rgba(0, 0, 0, 0.12) 100%),
    linear-gradient(90deg, rgba(3, 2, 1, 0.56), rgba(3, 2, 1, 0.2) 35%, transparent 62%, rgba(0, 0, 0, 0.04)),
    linear-gradient(180deg, rgba(255, 224, 154, 0.08), transparent 62%, rgba(0, 0, 0, 0.16));
}

.banner-slide-zhangdao-method .banner-copy {
  left: clamp(24px, 3.4vw, 46px);
  top: clamp(24px, 3.4vw, 46px);
  width: min(310px, 26%);
  padding: 10px 12px 12px;
  background:
    linear-gradient(135deg, rgba(10, 8, 4, 0.48), rgba(10, 8, 4, 0.18)),
    rgba(0, 0, 0, 0.06);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(4px);
}

.banner-slide-zhangdao-method .banner-copy h2 {
  max-width: none;
  font-size: clamp(22px, 1.85vw, 29px);
}

.banner-slide-zhangdao-method .banner-copy p {
  max-width: 30ch;
  -webkit-line-clamp: 1;
}

.banner-book-intro {
  position: absolute;
  z-index: 3;
  left: clamp(26px, 3.4vw, 48px);
  top: clamp(178px, 16vw, 236px);
  width: min(430px, 32vw);
  display: grid;
  gap: 13px;
  padding: clamp(18px, 2vw, 28px);
  border: 1px solid rgba(255, 224, 150, 0.26);
  border-left: 4px solid rgba(214, 168, 71, 0.82);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(10, 11, 15, 0.78), rgba(10, 11, 15, 0.42) 58%, rgba(214, 168, 71, 0.1)),
    rgba(0, 0, 0, 0.18);
  color: #fff7dd;
  box-shadow:
    0 28px 78px rgba(0, 0, 0, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.banner-book-intro::before {
  content: "";
  position: absolute;
  inset: 12px;
  z-index: -1;
  border-radius: 12px;
  background:
    radial-gradient(circle at 18% 18%, rgba(240, 194, 90, 0.26), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), transparent 44%);
}

.banner-book-intro span {
  width: fit-content;
  padding: 6px 10px;
  border: 1px solid rgba(214, 168, 71, 0.42);
  border-radius: 999px;
  color: #f4d991;
  background: rgba(214, 168, 71, 0.1);
  font-size: 12px;
  font-weight: 900;
}

.banner-book-intro strong {
  max-width: 11ch;
  color: #fffaf0;
  font-size: clamp(34px, 3.5vw, 58px);
  font-weight: 950;
  line-height: 0.98;
  letter-spacing: 0;
  text-shadow: 0 18px 42px rgba(0, 0, 0, 0.62);
}

.banner-book-intro p {
  margin: 0;
  max-width: 34ch;
  color: #f0dfb9;
  font-size: clamp(15px, 1.08vw, 18px);
  font-weight: 700;
  line-height: 1.72;
  text-shadow: 0 12px 30px rgba(0, 0, 0, 0.58);
}

.banner-book-intro div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 3px;
}

.banner-book-intro em {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border: 1px solid rgba(255, 224, 150, 0.2);
  border-radius: 999px;
  color: #11100d;
  background: linear-gradient(135deg, #f5d582, #d6a847);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.banner-nav {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 225, 154, 0.38);
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(8, 9, 12, 0.62), rgba(8, 9, 12, 0.28)),
    rgba(0, 0, 0, 0.16);
  color: #ffe09a;
  cursor: pointer;
  transform: translateY(-50%);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(9px);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.banner-nav span {
  display: block;
  margin-top: -2px;
  font-size: 34px;
  font-weight: 400;
  line-height: 1;
}

.banner-nav:hover,
.banner-nav:focus-visible {
  border-color: rgba(255, 225, 154, 0.78);
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.7), rgba(15, 12, 7, 0.36)),
    rgba(0, 0, 0, 0.18);
  color: #fff7dd;
  outline: none;
  transform: translateY(-50%) scale(1.04);
}

.banner-nav-prev {
  left: clamp(12px, 1.8vw, 24px);
}

.banner-nav-next {
  right: clamp(12px, 1.8vw, 24px);
}

.banner-dots {
  position: absolute;
  z-index: 4;
  right: 28px;
  bottom: 24px;
  display: flex;
  gap: 8px;
}

.banner-dots span {
  width: 18px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
}

.banner-dots span.active {
  width: 34px;
  background: #d6a847;
}

.home-section {
  content-visibility: auto;
  contain-intrinsic-size: 720px;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(280px, 0.75fr) minmax(420px, 1.25fr);
  gap: 18px;
  align-items: stretch;
  min-height: 360px;
}

.hero-copy {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.22), transparent 42%),
    linear-gradient(320deg, rgba(183, 53, 53, 0.16), transparent 44%),
    #15130f;
}

.hero-copy::before {
  content: "";
  position: absolute;
  inset: 18px 18px auto auto;
  width: 148px;
  aspect-ratio: 1;
  background: url("/media/brand/ant-power-logo.png") center / contain no-repeat;
  opacity: 0.16;
  pointer-events: none;
}

.hero-copy > * {
  position: relative;
  z-index: 1;
}

.live-badge {
  align-self: flex-start;
  color: #11100d;
  background: #d6a847;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
}

.hero-copy h2 {
  margin: 18px 0 12px;
  font-size: 36px;
  line-height: 1.12;
  max-width: 680px;
}

.hero-copy p {
  margin: 0;
  color: #c9c0ad;
  line-height: 1.7;
  max-width: 620px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.hero-btn {
  border: 0;
  border-radius: 8px;
  background: #d6a847;
  color: #11120f;
  cursor: pointer;
  font-weight: 800;
  padding: 10px 14px;
}

.hero-btn.ghost {
  color: #f8f3e7;
  background: #211d15;
  border: 1px solid #3b3120;
}

.hero-showcase {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 12px;
  height: 360px;
  min-height: 360px;
}

.showcase-card {
  position: relative;
  overflow: hidden;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #17140f;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease;
}

.showcase-card:hover,
.showcase-card:focus-visible,
.masonry-card:hover,
.masonry-card:focus-visible {
  border-color: rgba(214, 168, 71, 0.72);
  transform: translateY(-2px);
  outline: none;
}

.showcase-card.wide {
  grid-row: span 2;
}

.showcase-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.04) contrast(1.04);
}

.showcase-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.76));
}

.showcase-card div {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 1;
}

.showcase-card span,
.showcase-card strong {
  display: block;
}

.showcase-card span {
  color: #f0c25a;
  font-size: 12px;
  margin-bottom: 6px;
}

.showcase-card strong {
  color: #fff;
  font-size: 18px;
}

.recent-strip {
  display: grid;
  grid-template-columns: 240px repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.recent-create,
.recent-project {
  min-height: 138px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #17140f;
  padding: 16px;
}

.recent-create {
  display: grid;
  place-items: center;
  text-align: center;
}

.recent-create button {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 8px;
  background: #2a2418;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}

.recent-create span,
.recent-project strong {
  color: #fff;
  display: block;
  margin-top: 10px;
}

.recent-create small,
.recent-project span {
  color: #9a927f;
  display: block;
  margin-top: 6px;
  font-size: 13px;
}

.recent-thumb {
  height: 70px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #11100d;
  font-weight: 900;
  background:
    linear-gradient(135deg, #f2d37c, #d6a847 52%, #b73535);
}

.student-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 18px;
  align-items: stretch;
  border: 1px solid #332b1d;
  border-radius: 8px;
  padding: 28px;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.18), transparent 38%),
    linear-gradient(320deg, rgba(183, 53, 53, 0.16), transparent 42%),
    #15130f;
}

.student-hero h2 {
  color: #fff;
  font-size: 36px;
  margin: 18px 0 10px;
}

.student-hero p {
  max-width: 720px;
  color: #c9c0ad;
  line-height: 1.7;
  margin: 0;
}

.student-lock {
  border: 1px solid #3b3120;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.18);
  padding: 18px;
  display: grid;
  align-content: center;
  gap: 8px;
}

.student-lock strong {
  color: #d6a847;
  font-size: 20px;
}

.student-lock span {
  color: #9ea69a;
  line-height: 1.6;
  font-size: 13px;
}

.student-lock .hero-btn {
  justify-self: start;
  margin-top: 8px;
}

.access-hero {
  min-height: 360px;
}

.student-access {
  border: 1px solid #3b3120;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.2);
  padding: 18px;
  display: grid;
  align-content: center;
  gap: 12px;
}

.student-access label {
  display: grid;
  gap: 8px;
  color: #d6ccb7;
  font-size: 13px;
}

.student-access input {
  background: #17140f;
  color: #f8f3e7;
  border-color: #3b3120;
}

.student-access p {
  color: #9a927f;
  font-size: 13px;
  line-height: 1.6;
  margin: 0;
}

.student-access button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.student-card {
  border-color: rgba(214, 168, 71, 0.24);
}

.student-text-thumb {
  min-height: 180px;
  display: grid;
  place-items: center;
  text-align: center;
  color: #11100d;
  font-weight: 900;
  line-height: 1.35;
  background:
    linear-gradient(135deg, #f2d37c, #d6a847 52%, #b73535);
}

.student-text-thumb.large {
  height: 100%;
  min-height: 420px;
  font-size: 42px;
}

.home-feed {
  display: grid;
  gap: 14px;
}

.home-section {
  display: grid;
  gap: 22px;
  padding-top: 10px;
}

.feed-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 22px;
}

.feed-head h2 {
  color: #fff;
  font-size: 24px;
}

.feed-head p {
  margin: 6px 0 0;
  color: #9a927f;
}

.home-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.portal-card {
  position: relative;
  min-width: 0;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #17140f;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease;
}

.portal-card:hover,
.portal-card:focus-visible,
.banner-slide:hover,
.banner-slide:focus-visible {
  border-color: rgba(214, 168, 71, 0.72);
  transform: translateY(-2px);
  outline: none;
}

.portal-action-card {
  border-color: rgba(214, 168, 71, 0.56);
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.16), transparent 48%),
    #15130f;
}

.portal-action-media {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    linear-gradient(145deg, rgba(49, 95, 159, 0.22), transparent 46%),
    linear-gradient(320deg, rgba(183, 53, 53, 0.14), transparent 42%),
    #17140f;
}

.portal-action-media span {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 71, 0.55);
  border-radius: 50%;
  color: #11100d;
  background: #d6a847;
  font-size: 42px;
  font-weight: 900;
  line-height: 1;
}

.workflow-gateway-section {
  padding: 24px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(49, 95, 159, 0.14), transparent 42%),
    linear-gradient(320deg, rgba(214, 168, 71, 0.14), transparent 48%),
    #15130f;
}

.ops-gateway-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.ops-gateway-card {
  position: relative;
  min-height: 310px;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 8px;
  color: #fff7e5;
  background: #090805;
  text-decoration: none;
  box-shadow: 0 22px 58px rgba(0, 0, 0, 0.24);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.ops-gateway-card:hover,
.ops-gateway-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(240, 194, 90, 0.72);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.34);
  outline: none;
}

.ops-gateway-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.08) contrast(1.04) brightness(0.82);
  transform: scale(1.01);
  transition: transform 240ms ease;
}

.ops-gateway-card:hover img,
.ops-gateway-card:focus-visible img {
  transform: scale(1.045);
}

.ops-gateway-card::before,
.ops-gateway-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.ops-gateway-card::before {
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(4, 4, 5, 0.1), rgba(4, 4, 5, 0.88)),
    linear-gradient(110deg, rgba(9, 7, 4, 0.88), rgba(9, 7, 4, 0.24) 56%, rgba(9, 7, 4, 0.64));
}

.ops-gateway-card::after {
  z-index: 2;
  border: 1px solid rgba(255, 235, 178, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 235, 178, 0.18), transparent 26%),
    linear-gradient(315deg, rgba(49, 95, 159, 0.18), transparent 34%);
}

.ops-card-index {
  position: absolute;
  z-index: 3;
  top: 16px;
  right: 16px;
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 229, 158, 0.48);
  border-radius: 50%;
  color: #11100d;
  background: rgba(214, 168, 71, 0.94);
  font-weight: 900;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.32);
}

.ops-gateway-card > div {
  position: absolute;
  z-index: 3;
  left: 20px;
  right: 20px;
  bottom: 20px;
  display: grid;
  gap: 9px;
}

.ops-gateway-card small {
  color: #f0c25a;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.ops-gateway-card h3 {
  margin: 0;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.1;
}

.ops-gateway-card p {
  margin: 0;
  max-width: 36em;
  color: rgba(255, 247, 229, 0.78);
  line-height: 1.65;
  font-size: 14px;
}

.studio-banner-card {
  overflow: hidden;
  border: 1px solid rgba(95, 123, 255, 0.22);
  border-radius: 8px;
  background: #080a0d;
  aspect-ratio: 2048 / 720;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.2);
}

.studio-banner-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.workflow-gateway-card {
  border-color: rgba(49, 95, 159, 0.48);
}

.workflow-gateway-media {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.12), transparent 44%),
    linear-gradient(320deg, rgba(49, 95, 159, 0.2), transparent 46%),
    #11100d;
}

.workflow-gateway-media::before,
.workflow-gateway-media::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(214, 168, 71, 0.22);
}

.workflow-gateway-media::before {
  width: 72%;
  height: 1px;
  top: 42%;
}

.workflow-gateway-media::after {
  width: 1px;
  height: 62%;
  left: 54%;
}

.workflow-gateway-media span {
  z-index: 1;
  min-width: 76px;
  height: 54px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 71, 0.7);
  border-radius: 8px;
  color: #11100d;
  background: #d6a847;
  font-size: 24px;
  font-weight: 900;
}

.workflow-gateway-media img {
  z-index: 1;
  width: min(58%, 150px);
  aspect-ratio: 1;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 18px 28px rgba(0, 0, 0, 0.34));
}

.tutorial-placeholder-card {
  cursor: default;
  border-style: dashed;
  border-color: rgba(214, 168, 71, 0.36);
}

.tutorial-placeholder-card:hover,
.tutorial-placeholder-card:focus-visible {
  transform: none;
}

.tutorial-placeholder-media {
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.12), transparent 44%),
    linear-gradient(320deg, rgba(95, 123, 255, 0.16), transparent 46%),
    #17140f;
}

.tutorial-placeholder-media span {
  color: rgba(214, 168, 71, 0.82);
  background: rgba(17, 16, 13, 0.64);
}

.portal-media {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: #211d15;
}

.portal-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 220ms ease;
}

.portal-card:hover .portal-media img,
.portal-card:focus-visible .portal-media img {
  transform: scale(1.035);
}

.portal-card.libtv-card {
  border-color: rgba(95, 123, 255, 0.42);
}

.portal-card.libtv-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(145deg, rgba(95, 123, 255, 0.24), transparent 38%),
    linear-gradient(320deg, rgba(214, 168, 71, 0.16), transparent 44%);
}

.card-source-badge {
  position: absolute;
  z-index: 3;
  top: 10px;
  left: 10px;
  padding: 5px 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  color: #fff;
  background: rgba(16, 16, 22, 0.62);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
  backdrop-filter: blur(10px);
}

.portal-placeholder,
.detail-placeholder {
  display: grid;
  place-items: center;
  text-align: center;
  color: #11100d;
  font-weight: 900;
  background:
    linear-gradient(135deg, #f2d37c, #d6a847 52%, #b73535);
}

.portal-placeholder {
  width: 100%;
  height: 100%;
  font-size: 30px;
}

.portal-body {
  position: absolute;
  inset: auto 0 0;
  padding: 34px 12px 12px;
  background: linear-gradient(180deg, transparent, rgba(8, 7, 5, 0.88));
}

.portal-body h3 {
  margin: 0;
  color: #fff;
  font-size: 15px;
  line-height: 1.45;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.portal-body p {
  margin: 6px 0 0;
  color: #c9c0ad;
  font-size: 12px;
  line-height: 1.45;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.portal-meta {
  display: flex;
  gap: 6px;
  overflow: hidden;
  margin-top: 10px;
}

.portal-meta span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border: 1px solid #3b3120;
  border-radius: 999px;
  background: #211d15;
  color: #d6ccb7;
  padding: 4px 8px;
  font-size: 12px;
}

.card-lock-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  border: 1px solid rgba(214, 168, 71, 0.52);
  border-radius: 999px;
  padding: 5px 8px;
  color: #11100d;
  background: rgba(214, 168, 71, 0.92);
  font-size: 12px;
  font-weight: 900;
}

.tutorial-portal-card .portal-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(49, 95, 159, 0.18), transparent 46%);
  pointer-events: none;
}

.tutorial-private {
  display: grid;
  gap: 8px;
  padding: 16px;
}

.tutorial-private strong {
  color: #f0c25a;
}

.tutorial-private p {
  margin: 0;
  color: #c9c0ad;
  line-height: 1.65;
}

.tutorial-status-list {
  padding: 14px;
}

.tutorial-status-list div {
  border-color: rgba(214, 168, 71, 0.18);
  background: rgba(255, 255, 255, 0.04);
}

.tutorial-status-list strong {
  color: #f4ead8;
}

.dark-empty {
  border-color: #332b1d;
  background: #17140f;
  color: #9a927f;
}

.category-row {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.category-chip {
  white-space: nowrap;
  border: 1px solid #332b1d;
  background: #17140f;
  color: #d6ccb7;
  border-radius: 8px;
  padding: 9px 12px;
  cursor: pointer;
}

.category-chip span {
  margin-left: 6px;
  color: #9a927f;
  font-size: 12px;
}

.category-chip.active,
.category-chip:hover {
  color: #11100d;
  background: #d6a847;
  border-color: #d6a847;
}

.category-chip.active span,
.category-chip:hover span {
  color: rgba(17, 16, 13, 0.72);
}

.masonry-feed {
  column-count: 3;
  column-gap: 18px;
}

.community-hero {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(180px, 260px);
  gap: 18px;
  align-items: end;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 8px;
  padding: clamp(22px, 4vw, 46px);
  margin-bottom: 16px;
  color: #fff7dd;
  background:
    linear-gradient(112deg, rgba(6, 5, 4, 0.94), rgba(29, 21, 12, 0.78)),
    radial-gradient(circle at 78% 12%, rgba(214, 168, 71, 0.26), transparent 34%),
    #11100d;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.22);
}

.community-hero h2 {
  margin: 0;
  font-size: clamp(34px, 5vw, 72px);
  line-height: 0.98;
}

.community-hero p:not(.eyebrow) {
  max-width: 760px;
  margin: 14px 0 0;
  color: #e4d4b4;
  font-size: 16px;
  line-height: 1.75;
}

.director-picks-hero {
  grid-template-columns: minmax(320px, 1fr) minmax(150px, 220px) minmax(180px, 260px);
  align-items: center;
}

.director-picks-avatar {
  display: grid;
  gap: 10px;
  justify-items: center;
  align-self: stretch;
  margin: 0;
}

.director-picks-avatar img {
  width: min(100%, 240px);
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(255, 224, 150, 0.24);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.28);
}

.director-picks-avatar figcaption {
  color: #d6a847;
  font-size: 13px;
  font-weight: 900;
}

.prompt-community-hero {
  background:
    linear-gradient(112deg, rgba(7, 5, 10, 0.95), rgba(28, 21, 10, 0.76)),
    radial-gradient(circle at 80% 12%, rgba(146, 111, 255, 0.18), transparent 34%),
    radial-gradient(circle at 20% 70%, rgba(214, 168, 71, 0.2), transparent 30%),
    #11100d;
}

.case-community-hero {
  background:
    linear-gradient(112deg, rgba(5, 6, 8, 0.95), rgba(37, 24, 13, 0.78)),
    radial-gradient(circle at 78% 18%, rgba(58, 123, 213, 0.2), transparent 34%),
    radial-gradient(circle at 22% 74%, rgba(214, 168, 71, 0.22), transparent 30%),
    #11100d;
}

.inspiration-hero {
  margin-bottom: 0;
  background:
    linear-gradient(112deg, rgba(5, 6, 8, 0.96), rgba(19, 14, 10, 0.8)),
    radial-gradient(circle at 76% 14%, rgba(214, 168, 71, 0.24), transparent 34%),
    radial-gradient(circle at 18% 76%, rgba(49, 95, 159, 0.22), transparent 32%),
    #11100d;
}

.inspiration-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.inspiration-sidebar {
  position: sticky;
  top: 24px;
  display: grid;
  gap: 16px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  padding: 16px;
  background: #15130f;
}

.inspiration-sidebar h3 {
  margin: 0;
  color: #fff;
  font-size: 18px;
}

.inspiration-category-row {
  display: grid;
  gap: 8px;
  margin: 0;
}

.inspiration-category-row .category-chip {
  width: 100%;
  justify-content: space-between;
}

.inspiration-rules {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.08);
}

.inspiration-rules strong {
  color: #f0c25a;
}

.inspiration-rules span {
  color: #b7ad99;
  font-size: 13px;
  line-height: 1.6;
}

.inspiration-feed {
  display: grid;
  gap: 14px;
}

.inspiration-composer,
.inspiration-post {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 14px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  padding: 16px;
  background: #17140f;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.16);
}

.composer-avatar,
.post-avatar {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 71, 0.54);
  border-radius: 50%;
  color: #11100d;
  background: #d6a847;
  font-weight: 900;
}

.composer-fields {
  display: grid;
  gap: 12px;
}

.inspiration-composer textarea,
.inspiration-composer input,
.inspiration-composer select {
  width: 100%;
  border: 1px solid #332b1d;
  border-radius: 8px;
  color: #f8f3e7;
  background: #0f0e0b;
}

.inspiration-composer textarea {
  min-height: 104px;
  padding: 12px;
  line-height: 1.65;
}

.inspiration-composer input,
.inspiration-composer select {
  min-height: 42px;
  padding: 9px 10px;
}

.composer-row {
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) 120px minmax(180px, 1fr) auto;
  gap: 10px;
}

.inspiration-post {
  transition: border-color 160ms ease, transform 160ms ease;
  cursor: pointer;
}

.inspiration-post:hover {
  border-color: rgba(214, 168, 71, 0.48);
  transform: translateY(-1px);
}

.inspiration-post:focus-visible {
  border-color: rgba(214, 168, 71, 0.72);
  outline: 2px solid rgba(214, 168, 71, 0.34);
  outline-offset: 2px;
}

.community-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.community-reading-shell {
  display: grid;
  gap: 18px;
  color: #fff7e5;
}

.community-reading-breadcrumb {
  color: #b7ad99;
}

.community-reading-breadcrumb a {
  color: #f0c25a;
}

.community-reading-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: clamp(18px, 3vw, 30px);
  align-items: stretch;
  border: 1px solid #332b1d;
  border-radius: 8px;
  padding: clamp(18px, 3vw, 28px);
  background: #15130f;
}

.community-reading-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.community-reading-copy h1 {
  margin: 14px 0 12px;
  color: #fff;
  font-size: clamp(34px, 4.8vw, 64px);
  line-height: 1.02;
}

.community-reading-copy p {
  margin: 0;
  color: #d6ccb7;
  font-size: 16px;
  line-height: 1.78;
}

.community-reading-media {
  min-height: 360px;
  overflow: hidden;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #090805;
}

.community-reading-media img,
.community-reading-media video {
  width: 100%;
  height: 100%;
  max-height: 720px;
  display: block;
  object-fit: contain;
}

.community-reading-placeholder {
  min-height: 360px;
  display: grid;
  place-items: center;
  color: #11100d;
  background: #d6a847;
  font-size: 42px;
  font-weight: 900;
}

.community-reading-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.7fr);
  gap: 14px;
}

.community-reading-panel {
  border: 1px solid #332b1d;
  border-radius: 8px;
  padding: clamp(16px, 2.4vw, 24px);
  background: #17140f;
}

.community-reading-panel h2 {
  margin: 0 0 10px;
  color: #fff;
  font-size: 24px;
}

.community-reading-panel p:not(.eyebrow) {
  margin: 0;
  color: #c9c0ad;
  line-height: 1.75;
}

.post-main {
  min-width: 0;
}

.post-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: #d8c8a8;
  font-size: 13px;
}

.post-head strong {
  color: #fff;
  font-size: 15px;
}

.post-head span {
  color: #f0c25a;
  font-weight: 900;
}

.post-head small {
  color: #858b7f;
}

.inspiration-post h3 {
  margin: 8px 0 6px;
  color: #fff;
  font-size: 20px;
  line-height: 1.35;
}

.inspiration-post p {
  margin: 0;
  color: #c9c0ad;
  line-height: 1.72;
}

.post-media {
  overflow: hidden;
  margin-top: 12px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #090805;
}

.post-media img,
.post-media video {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  display: block;
}

.post-tags,
.post-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.post-tags span {
  border: 1px solid #3b3120;
  border-radius: 999px;
  padding: 4px 8px;
  color: #d6ccb7;
  background: #211d15;
  font-size: 12px;
}

.post-actions {
  padding-top: 12px;
  border-top: 1px solid #2a2418;
}

.post-actions button {
  border: 1px solid #332b1d;
  border-radius: 999px;
  padding: 7px 10px;
  color: #d6ccb7;
  background: rgba(17, 16, 13, 0.68);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
}

.post-actions button:hover,
.post-actions button:focus-visible {
  border-color: rgba(214, 168, 71, 0.58);
  color: #fff;
  outline: none;
}

.community-stats {
  display: grid;
  gap: 6px;
  border: 1px solid rgba(255, 224, 150, 0.22);
  border-radius: 8px;
  padding: 18px;
  background: rgba(0, 0, 0, 0.24);
}

.community-stats strong {
  color: #fff;
  font-size: 42px;
  line-height: 1;
}

.community-stats span {
  color: #d6a847;
  font-weight: 900;
}

.community-stats small {
  color: #d8c8a8;
  line-height: 1.5;
}

.community-category-row {
  margin: 0 0 18px;
}

.community-masonry {
  column-count: 4;
}

.masonry-card {
  position: relative;
  display: inline-block;
  width: 100%;
  margin: 0 0 18px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  overflow: hidden;
  background: #17140f;
  break-inside: avoid;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease;
}

.community-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 36%),
    #17140f;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
}

.masonry-card img {
  width: 100%;
  height: auto;
  max-height: none;
  object-fit: contain;
  display: block;
  background: #211d15;
}

.masonry-card.tall img {
  height: auto;
}

.community-image-placeholder {
  min-height: 220px;
  display: grid;
  place-items: center;
  color: #11100d;
  background:
    radial-gradient(circle at 68% 20%, rgba(255, 255, 255, 0.38), transparent 28%),
    linear-gradient(135deg, #d6a847, #7c5a24);
  font-size: 30px;
  font-weight: 900;
}

.community-image-placeholder.prompt-placeholder {
  background:
    radial-gradient(circle at 26% 20%, rgba(255, 255, 255, 0.36), transparent 28%),
    linear-gradient(135deg, #111827, #d6a847);
  color: #f6e7bd;
  letter-spacing: 0;
}

.prompt-effect-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border: 1px solid rgba(255, 225, 160, 0.42);
  border-radius: 999px;
  background: rgba(10, 10, 12, 0.66);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.28);
  color: #f6d98c;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  backdrop-filter: blur(10px);
}

.project-community-hero {
  background: #10110f;
}

.project-source-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin: 0 0 18px;
  padding: 14px 16px;
  border: 1px solid rgba(214, 168, 71, 0.24);
  border-radius: 8px;
  background: #17140f;
  color: #d8c8a8;
}

.project-source-strip strong,
.project-source-strip span {
  display: block;
}

.project-source-strip strong {
  color: #fff7dd;
  margin-bottom: 4px;
}

.project-source-strip.online {
  border-color: rgba(89, 196, 154, 0.34);
}

.project-source-strip.offline {
  border-color: rgba(214, 168, 71, 0.28);
}

.community-image-placeholder.project-placeholder {
  min-height: 240px;
  background: #15140f;
  color: #fff7dd;
}

.project-placeholder span {
  display: block;
  font-size: 56px;
  line-height: 1;
}

.project-placeholder small {
  display: block;
  margin-top: 8px;
  color: rgba(255, 247, 221, 0.72);
  font-size: 11px;
  letter-spacing: 0;
}

.project-community-card .masonry-body {
  padding: 15px;
}

.project-community-card h3 {
  margin: 12px 0 8px;
}

.project-community-card p {
  color: #c8b99b;
}

.project-waterfall-progress {
  height: 7px;
  margin-top: 13px;
  overflow: hidden;
  border-radius: 999px;
  background: #2b2418;
}

.project-waterfall-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #7f724f;
}

.project-card-action {
  margin-top: 12px;
  color: #d6a847;
  font-size: 13px;
  font-weight: 900;
}

.masonry-body {
  padding: 13px;
}

.creator-line {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #daddd6;
  font-size: 13px;
}

.creator-line small {
  color: #858b7f;
  margin-left: auto;
}

.avatar-dot {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #11100d;
  background: #d6a847;
  font-size: 12px;
  font-weight: 900;
}

.masonry-body h3 {
  color: #fff;
  margin: 10px 0 6px;
  font-size: 16px;
  line-height: 1.45;
}

.masonry-body p {
  color: #b7ad99;
  line-height: 1.6;
  font-size: 13px;
  margin: 0;
}

.home-mode .pill {
  color: #d6ccb7;
  background: #211d15;
  border-color: #3b3120;
}

.copy-btn.dark {
  width: 100%;
  color: #f0c25a;
  background: rgba(214, 168, 71, 0.08);
  border-color: rgba(214, 168, 71, 0.28);
}

.detail-open {
  overflow: hidden;
}

.detail-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(10px);
}

.detail-dialog {
  position: relative;
  width: min(1180px, 100%);
  max-height: min(820px, calc(100vh - 56px));
  display: grid;
  grid-template-columns: minmax(360px, 1.1fr) minmax(340px, 0.9fr);
  overflow: hidden;
  border: 1px solid #3b3120;
  border-radius: 8px;
  background: #12100c;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.46);
}

.detail-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  color: #fff;
  background: rgba(0, 0, 0, 0.5);
  cursor: pointer;
  font-size: 22px;
}

.detail-media {
  min-height: 0;
  background: #090805;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.detail-media > img {
  width: 100%;
  height: 100%;
  max-height: calc(100vh - 150px);
  object-fit: contain;
}

.tutorial-video-player {
  width: 100%;
  height: 100%;
  max-height: calc(100vh - 150px);
  display: block;
  object-fit: contain;
  background: #050505;
}

.tutorial-reading-shell {
  color: #fff7e5;
  gap: 14px;
}

.tutorial-reading-shell .reading-breadcrumb,
.tutorial-reading-shell .reading-hero p,
.tutorial-reading-shell .reading-article p,
.tutorial-reading-shell .reading-article li {
  color: #d6ccb7;
}

.tutorial-reading-shell .reading-hero {
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 18px;
  padding: 10px 0 12px;
  border-bottom-color: #332b1d;
}

.tutorial-reading-shell .reading-hero h1 {
  margin: 8px 0 8px;
  font-size: clamp(28px, 3.2vw, 42px);
}

.tutorial-reading-shell .reading-hero p {
  max-width: 920px;
  font-size: 15px;
  line-height: 1.58;
}

.tutorial-reading-shell .reading-article,
.tutorial-reading-shell .reading-article h2,
.tutorial-reading-shell .reading-article h3,
.tutorial-reading-shell .reading-side dd {
  color: #fff7e5;
}

.tutorial-watch {
  aspect-ratio: 16 / 9;
  max-height: min(64vh, 680px);
  overflow: hidden;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #050505;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.tutorial-watch img,
.tutorial-watch video {
  width: 100%;
  height: 100%;
  max-height: 680px;
  object-fit: cover;
  display: block;
}

.tutorial-watch .tutorial-video-player {
  max-height: none;
  object-fit: contain;
}

.tutorial-reading-shell .reading-side {
  border-color: #332b1d;
  background: #15130f;
}

.tutorial-reading-shell .reading-side dt {
  color: #9a927f;
}

.reading-access-note {
  margin-top: 24px;
}

.detail-placeholder {
  min-height: 420px;
  font-size: 46px;
}

.detail-thumbs {
  display: flex;
  gap: 8px;
  padding: 10px;
  overflow-x: auto;
  border-top: 1px solid #2a2418;
}

.detail-thumbs img {
  width: 86px;
  height: 56px;
  object-fit: cover;
  border: 1px solid #3b3120;
  border-radius: 8px;
  cursor: pointer;
  opacity: 0.72;
}

.detail-thumbs img.active,
.detail-thumbs img:hover {
  opacity: 1;
  border-color: #d6a847;
}

.detail-content {
  min-height: 0;
  padding: 24px;
  overflow-y: auto;
  color: #f3f4ef;
}

.detail-content h2 {
  margin: 18px 0 10px;
  color: #fff;
  font-size: 28px;
  line-height: 1.22;
}

.detail-summary {
  margin: 0;
  color: #c9c0ad;
  line-height: 1.7;
}

.detail-section {
  margin-top: 20px;
  border: 1px solid #332b1d;
  border-radius: 8px;
  background: #17140f;
}

.detail-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border-bottom: 1px solid #332b1d;
}

.detail-section-head h3 {
  margin: 0;
  color: #fff;
  font-size: 16px;
}

.detail-section-head p {
  margin: 5px 0 0;
  color: #b6a783;
  font-size: 12px;
  line-height: 1.55;
}

.detail-section-head .copy-btn {
  width: auto;
  margin: 0;
}

.detail-section pre {
  max-height: 300px;
  margin: 0;
  padding: 14px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  color: #e7dfcf;
  font-size: 13px;
  line-height: 1.65;
}

.detail-url-section {
  background: #11100d;
}

.detail-url-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.detail-url-row {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.detail-url-row span {
  color: #d7c08d;
  font-size: 12px;
}

.detail-url-row a {
  min-width: 0;
  color: #f1e4c0;
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  text-decoration: none;
}

.detail-url-row a:hover {
  text-decoration: underline;
}

.detail-url-row .copy-btn {
  width: auto;
  margin: 0;
  padding: 7px 10px;
  font-size: 12px;
}

.detail-source {
  display: grid;
  gap: 6px;
  margin-top: 16px;
  color: #9a927f;
  font-size: 13px;
}

.detail-stage-row,
.detail-chain {
  padding: 14px;
}

.case-reading-shell {
  display: grid;
  gap: 22px;
  width: min(1260px, 100%);
  min-width: 0;
  max-width: 100%;
  margin: 0 auto 42px;
}

.case-reading-shell > *,
.case-reading-shell :where(.case-reading-hero, .case-hero-media, .case-hero-copy, .case-overview-grid, .case-reading-section, .case-chain, .case-dimension-grid, .case-video-frame, .case-gallery-grid, .case-asset-list, .case-prompt-code-wrap) {
  min-width: 0;
  max-width: 100%;
}

.case-reading-shell .reading-breadcrumb {
  margin-bottom: 2px;
}

.case-reading-hero {
  display: grid;
  grid-template-columns: minmax(360px, 0.58fr) minmax(0, 0.42fr);
  gap: 0;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.24);
  border-radius: 8px;
  background: #11100d;
  color: #fff7e5;
  box-shadow: 0 28px 80px rgba(23, 20, 14, 0.18);
}

.case-hero-media {
  height: clamp(320px, 42vw, 560px);
  min-height: 0;
  background: #050505;
}

.case-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-hero-media video {
  width: 100%;
  height: 100%;
  min-height: clamp(380px, 44vw, 620px);
  object-fit: contain;
  display: block;
  background: #050505;
}

.case-hero-copy {
  display: grid;
  align-content: center;
  gap: 16px;
  padding: clamp(24px, 4vw, 46px);
}

.case-hero-copy h1 {
  margin: 0;
  font-size: clamp(34px, 4.8vw, 62px);
  line-height: 1.04;
}

.case-hero-copy p:not(.eyebrow) {
  margin: 0;
  color: #d8c8a8;
  font-size: 16px;
  line-height: 1.75;
}

.case-hero-actions,
.case-section-head {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.case-hero-actions {
  margin-top: 4px;
}

.case-overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.case-overview-grid div,
.case-reading-section,
.case-dimension-card,
.case-chain div,
.case-asset-list a {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.case-overview-grid div {
  min-height: 118px;
  padding: 16px;
}

.case-overview-grid span,
.case-dimension-card span,
.case-chain b,
.case-asset-list small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.case-overview-grid strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.35;
}

.case-reading-section {
  padding: clamp(18px, 3vw, 26px);
}

.case-section-head {
  justify-content: space-between;
  margin-bottom: 18px;
}

.case-section-head h2 {
  width: 100%;
  margin: 0;
  color: var(--ink);
  font-size: clamp(26px, 3.2vw, 38px);
}

.case-section-head p:not(.eyebrow) {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.case-chain {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.case-chain div,
.case-dimension-card {
  padding: 16px;
}

.case-chain strong,
.case-dimension-card h3 {
  display: block;
  margin-top: 10px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.35;
}

.case-chain span,
.case-dimension-card p {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.case-dimension-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.case-video-frame {
  overflow: hidden;
  border: 1px solid #211d15;
  border-radius: 8px;
  background: #050505;
}

.case-video-frame video {
  width: 100%;
  max-height: 720px;
  display: block;
}

.case-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.case-gallery-grid figure {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #11100d;
}

.case-gallery-grid img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  display: block;
}

.case-gallery-grid figcaption {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  background: #fff;
  color: var(--muted);
  font-size: 13px;
}

.case-gallery-grid a,
.case-asset-list a {
  color: var(--accent);
  font-weight: 900;
  text-decoration: none;
}

.case-asset-list {
  display: grid;
  gap: 10px;
}

.case-asset-list a {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 13px 14px;
}

.case-asset-list span {
  color: var(--ink);
  font-weight: 900;
}

.case-asset-list small {
  overflow-wrap: anywhere;
}

.project-reading-progress {
  height: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 224, 150, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
}

.project-reading-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #d6a847, #f0c25a);
}

.project-stage-status {
  display: inline-flex;
  width: fit-content;
  margin-top: 12px;
  padding: 3px 8px;
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 999px;
  color: var(--accent);
  background: rgba(214, 168, 71, 0.08);
  font-size: 12px;
  font-weight: 900;
}

.case-file-index {
  margin-top: 18px;
}

.case-file-index h3 {
  margin: 0 0 12px;
  color: var(--ink);
  font-size: 20px;
}

.case-file-index > div {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.case-file-index a {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf0;
  color: inherit;
  text-decoration: none;
}

.case-file-index span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.case-file-index strong {
  min-width: 0;
  color: var(--ink);
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.case-file-index small {
  min-width: 0;
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.dark-link {
  color: #f0c25a;
}

.theory-feature-section {
  margin-bottom: 26px;
}

.theory-feature-card {
  display: grid;
  grid-template-columns: minmax(180px, 0.28fr) minmax(0, 0.72fr);
  gap: 0;
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 8px;
  background: #11100d;
  color: #fff7e5;
  box-shadow: var(--shadow);
}

.theory-feature-media {
  min-height: 180px;
  background: #050505;
}

.theory-feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.theory-feature-copy {
  display: grid;
  align-content: center;
  gap: 12px;
  padding: 22px;
}

.theory-feature-copy h3 {
  margin: 0;
  font-size: clamp(24px, 2.6vw, 34px);
  line-height: 1.12;
}

.theory-feature-copy p {
  margin: 0;
  max-width: 780px;
  color: rgba(255, 247, 229, 0.76);
  line-height: 1.65;
  font-size: 14px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.theory-feature-copy .asset-link {
  color: #f0c25a;
}

.knowledge-hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: 300px;
  margin-bottom: 18px;
  border: 1px solid rgba(17, 16, 13, 0.12);
  border-radius: 8px;
  overflow: hidden;
  background: #12100c;
  color: #fff7e5;
  box-shadow: var(--shadow);
}

.knowledge-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(17, 16, 13, 0.92), rgba(17, 16, 13, 0.68) 52%, rgba(17, 16, 13, 0.18)),
    linear-gradient(0deg, rgba(17, 16, 13, 0.45), transparent 48%);
  pointer-events: none;
}

.knowledge-hero-copy {
  position: relative;
  z-index: 2;
  padding: 22px 26px;
  display: grid;
  align-content: center;
  gap: 16px;
  max-width: 760px;
}

.knowledge-hero-copy h2 {
  margin: 0;
  max-width: 740px;
  font-size: clamp(30px, 4.2vw, 52px);
  line-height: 1.02;
}

.knowledge-hero-copy p {
  margin: 0;
  max-width: 720px;
  color: rgba(255, 247, 229, 0.74);
  font-size: 16px;
  line-height: 1.75;
}

.knowledge-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.knowledge-hero-media {
  position: absolute;
  inset: 0;
  min-height: 0;
  overflow: hidden;
}

.knowledge-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center right;
  display: block;
  opacity: 0.86;
}

.knowledge-hero-media div {
  position: absolute;
  z-index: 2;
  right: 18px;
  bottom: 18px;
  min-width: 150px;
  padding: 16px;
  border: 1px solid rgba(255, 247, 229, 0.24);
  border-radius: 8px;
  background: rgba(17, 16, 13, 0.72);
  backdrop-filter: blur(12px);
}

.knowledge-hero-media strong {
  display: block;
  font-size: 44px;
  line-height: 1;
}

.knowledge-hero-media span {
  color: rgba(255, 247, 229, 0.72);
}

.knowledge-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.knowledge-stats article {
  min-height: 118px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 15px;
  background: #fff;
  box-shadow: var(--shadow);
}

.knowledge-stats strong {
  display: block;
  font-size: 32px;
}

.knowledge-stats span {
  display: block;
  margin-top: 3px;
  font-weight: 800;
}

.knowledge-stats small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.45;
}

.knowledge-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.knowledge-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
}

.knowledge-nav a.active {
  border-color: rgba(167, 121, 43, 0.42);
  background: var(--charcoal);
  color: #f7e3aa;
}

.knowledge-section {
  margin-bottom: 18px;
}

.knowledge-section .panel-header p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.zhangdao-knowledge-feature {
  border-color: rgba(214, 168, 71, 0.3);
  background:
    linear-gradient(135deg, rgba(17, 16, 13, 0.96), rgba(38, 30, 16, 0.92)),
    #11100d;
  color: #fff7e5;
}

.zhangdao-feature-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.38fr) minmax(0, 0.62fr);
  gap: 22px;
  align-items: center;
  margin-bottom: 18px;
}

.zhangdao-feature-cover {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid rgba(255, 247, 229, 0.18);
  background: #050505;
}

.zhangdao-feature-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.zhangdao-feature-copy {
  display: grid;
  gap: 14px;
}

.zhangdao-feature-copy h2 {
  margin: 0;
  font-size: clamp(32px, 4.8vw, 58px);
  line-height: 1;
}

.zhangdao-feature-copy p {
  margin: 0;
  max-width: 850px;
  color: rgba(255, 247, 229, 0.76);
  line-height: 1.8;
}

.zhangdao-feature-copy .asset-link {
  color: #f0c25a;
}

.zhangdao-doc-grid .knowledge-doc-card {
  background: rgba(255, 247, 229, 0.96);
}

.knowledge-source-grid,
.knowledge-doc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.knowledge-source-card,
.knowledge-doc-card {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 230px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 15px;
  background: #fbfcfa;
}

.knowledge-doc-card {
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.knowledge-doc-card:hover,
.knowledge-doc-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(167, 121, 43, 0.42);
  box-shadow: 0 18px 40px rgba(23, 20, 14, 0.12);
  outline: none;
}

.knowledge-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.knowledge-layer {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  color: #5d4111;
  background: rgba(214, 168, 71, 0.16);
}

.knowledge-layer.risk-low {
  color: #22513b;
  background: rgba(58, 142, 91, 0.14);
}

.knowledge-layer.risk-medium {
  color: #7b5a12;
  background: rgba(214, 168, 71, 0.18);
}

.knowledge-layer.risk-high {
  color: #8a2727;
  background: rgba(183, 53, 53, 0.14);
}

.knowledge-layer.risk-internal {
  color: #2d4c83;
  background: rgba(49, 95, 159, 0.14);
}

.knowledge-source-card h3,
.knowledge-doc-card h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
}

.knowledge-source-card p,
.knowledge-doc-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}

.knowledge-action-preview {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.knowledge-action-preview li {
  position: relative;
  padding-left: 18px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.5;
}

.knowledge-action-preview li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--gold);
}

.knowledge-meta-list {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.knowledge-source-line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.knowledge-admin-panel {
  margin-bottom: 18px;
  border-color: rgba(167, 121, 43, 0.28);
  background: #fffaf0;
}

.knowledge-admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.knowledge-admin-grid > div,
.knowledge-admin-list {
  border: 1px solid rgba(167, 121, 43, 0.18);
  border-radius: 8px;
  padding: 14px;
  background: #fff;
}

.knowledge-admin-grid h3 {
  margin: 0 0 10px;
}

.knowledge-admin-grid p,
.knowledge-admin-list div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin: 0;
  padding: 8px 0;
  border-top: 1px solid var(--line);
}

.knowledge-admin-grid p:first-of-type,
.knowledge-admin-list div:first-child {
  border-top: 0;
}

.knowledge-admin-grid strong {
  font-size: 18px;
}

.knowledge-admin-list div {
  grid-template-columns: minmax(0, 1fr) minmax(160px, auto) auto auto;
}

.knowledge-admin-list small {
  color: var(--muted);
}

.knowledge-admin-list .copy-btn {
  margin-top: 0;
}

.knowledge-admin-list .copy-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.knowledge-license-notice {
  border: 1px solid rgba(49, 95, 159, 0.18);
  border-radius: 8px;
  padding: 16px;
  background: rgba(49, 95, 159, 0.08);
  color: #22324d;
  line-height: 1.7;
}

.knowledge-license-notice strong {
  display: block;
  margin-bottom: 6px;
}

.knowledge-license-notice p {
  margin: 0;
}

.reading-shell {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 22px;
}

.reading-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.reading-breadcrumb a {
  color: var(--accent);
  font-weight: 800;
  text-decoration: none;
}

.reading-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 24px;
  align-items: end;
  padding: 26px 0 28px;
  border-bottom: 1px solid rgba(23, 20, 14, 0.14);
}

.reading-hero h1 {
  margin: 12px 0 12px;
  max-width: 980px;
  font-size: clamp(32px, 4.2vw, 56px);
  line-height: 1.12;
}

.reading-hero p {
  margin: 0;
  max-width: 860px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.reading-actions {
  display: grid;
  gap: 10px;
  justify-items: stretch;
}

.reading-actions .copy-btn,
.reading-actions .asset-link {
  margin: 0;
  justify-content: center;
  text-align: center;
}

.prompt-reading-shell {
  color: var(--ink);
}

.prompt-reading-hero {
  grid-template-columns: minmax(0, 1fr) 240px;
  align-items: center;
}

.prompt-reading-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: start;
}

.prompt-reading-main {
  display: grid;
  gap: 22px;
  min-width: 0;
}

.prompt-content-block,
.prompt-media-section,
.prompt-reading-side {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.prompt-content-head,
.prompt-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.prompt-content-block h2,
.prompt-section-head h2,
.prompt-reading-side h2 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
}

.prompt-reading-side h2 {
  color: #fff7dd;
}

.prompt-content-block pre {
  margin: 0;
  padding: 46px clamp(18px, 3vw, 28px) clamp(18px, 3vw, 28px);
  overflow-x: auto;
  color: #f7ead0;
  background: #11100d;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 15px;
  line-height: 1.85;
  white-space: pre-wrap;
  word-break: break-word;
}

.prompt-code-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 0 0 8px 8px;
  background: #11100d;
}

.prompt-code-wrap pre {
  max-width: 100%;
  margin: 0;
  padding: 46px clamp(18px, 3vw, 28px) clamp(18px, 3vw, 28px);
  overflow-x: auto;
  color: #f7ead0;
  background: #11100d;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 15px;
  line-height: 1.85;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.prompt-code-wrap code {
  white-space: inherit;
  overflow-wrap: inherit;
  word-break: inherit;
}

.prompt-code-copy {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1;
  width: 34px;
  height: 34px;
  min-height: 34px;
  display: grid;
  place-items: center;
  margin: 0;
  padding: 0;
  border-radius: 8px;
}

.prompt-code-copy svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.copy-btn.dark.prompt-code-copy {
  width: 34px;
}

.prompt-code-copy.is-copied svg {
  display: none;
}

.prompt-code-copy.is-copied::after {
  content: "";
  width: 14px;
  height: 8px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg) translate(1px, -1px);
}

.prompt-content-block code {
  color: inherit;
  font: inherit;
}

.prompt-content-block .code-key {
  color: #f2c96d;
}

.prompt-content-block .code-string {
  color: #9dd6a8;
}

.prompt-content-block .code-number {
  color: #8ecbff;
}

.prompt-content-block .code-boolean,
.prompt-content-block .code-null {
  color: #f39f8f;
}

.prompt-media-section {
  padding-bottom: 16px;
}

.prompt-media-section .reading-image-grid {
  padding: 16px;
}

.prompt-player-list {
  padding: 16px;
}

.prompt-media-missing {
  padding-bottom: 0;
  background: #fffaf0;
}

.prompt-media-missing p {
  margin: 0;
  padding: 16px;
  color: var(--muted);
  line-height: 1.7;
  overflow-wrap: anywhere;
}

.prompt-reading-side {
  position: sticky;
  top: 22px;
  display: grid;
  gap: 14px;
  padding: 16px;
  border-color: rgba(214, 168, 71, 0.24);
  background:
    linear-gradient(180deg, rgba(255, 224, 150, 0.06), transparent 38%),
    #12100c;
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.22);
}

.prompt-reading-side dl {
  display: grid;
  gap: 12px;
  margin: 0;
}

.prompt-reading-side dl div {
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 224, 150, 0.14);
}

.prompt-reading-side dt {
  margin-bottom: 5px;
  color: #d6a847;
  font-size: 12px;
  font-weight: 900;
}

.prompt-reading-side dd {
  margin: 0;
  color: #f5ead4;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.prompt-side-media,
.prompt-director-picks,
.prompt-side-links {
  display: grid;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 224, 150, 0.14);
}

.prompt-side-media h3,
.prompt-director-picks h3,
.prompt-side-links h3 {
  margin: 0;
  color: #fff7dd;
  font-size: 16px;
}

.prompt-director-picks > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.prompt-director-picks > div a {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.prompt-director-card {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 8px;
  border-radius: 8px;
  border: 1px solid rgba(255, 224, 150, 0.14);
  background: #1b1710;
  cursor: pointer;
}

.prompt-director-card img,
.prompt-director-card > span {
  width: 72px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: #0c0b08;
  color: #d6a847;
  font-size: 13px;
  font-weight: 900;
}

.prompt-director-card div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.prompt-director-card strong,
.prompt-director-card small,
.prompt-director-picks p {
  margin: 0;
  overflow-wrap: anywhere;
}

.prompt-director-card strong {
  color: #fff7dd;
  font-size: 13px;
  line-height: 1.35;
}

.prompt-director-card small,
.prompt-director-picks p {
  color: #cbb990;
  font-size: 12px;
  line-height: 1.45;
}

.director-picks-pending {
  display: grid;
  gap: 16px;
  margin-top: 28px;
}

.pending-prompt-list {
  display: grid;
  gap: 10px;
}

.pending-prompt-list article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf0;
  cursor: pointer;
}

.pending-prompt-list strong,
.pending-prompt-list small {
  overflow-wrap: anywhere;
}

.pending-prompt-list strong {
  color: var(--ink);
}

.pending-prompt-list span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.pending-prompt-list small {
  grid-column: 1 / -1;
  color: var(--muted);
}

.prompt-side-thumbs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.prompt-side-thumb {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: #f5ead4;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.prompt-side-thumb img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid rgba(255, 224, 150, 0.12);
  background: #0c0b08;
}

.prompt-side-thumb span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.prompt-side-links a {
  display: block;
  min-width: 0;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
  overflow-wrap: anywhere;
  text-decoration: none;
}

:root[data-theme="light"] .prompt-reading-side {
  border-color: var(--line);
  background: #fff;
  box-shadow: none;
}

:root[data-theme="light"] .prompt-reading-side h2,
:root[data-theme="light"] .prompt-side-media h3,
:root[data-theme="light"] .prompt-director-picks h3,
:root[data-theme="light"] .prompt-side-links h3,
:root[data-theme="light"] .prompt-director-card strong {
  color: var(--ink);
}

:root[data-theme="light"] .prompt-reading-side dl div,
:root[data-theme="light"] .prompt-side-media,
:root[data-theme="light"] .prompt-director-picks,
:root[data-theme="light"] .prompt-side-links {
  border-color: var(--line);
}

:root[data-theme="light"] .prompt-reading-side dt,
:root[data-theme="light"] .prompt-side-links a {
  color: var(--accent);
}

:root[data-theme="light"] .prompt-reading-side dd,
:root[data-theme="light"] .prompt-side-thumb {
  color: var(--ink);
}

:root[data-theme="light"] .prompt-director-card {
  border-color: var(--line);
  background: #fffaf0;
}

:root[data-theme="light"] .prompt-director-card img,
:root[data-theme="light"] .prompt-director-card > span,
:root[data-theme="light"] .prompt-side-thumb img {
  background: #fff;
}

:root[data-theme="light"] .prompt-director-card small,
:root[data-theme="light"] .prompt-director-picks p {
  color: var(--muted);
}

.reading-assets {
  display: grid;
  gap: 16px;
}

.reading-image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.reading-image-grid figure {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #11100d;
}

.reading-image-grid img {
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  display: block;
  background: #050505;
}

.prompt-media-section .reading-image-grid {
  grid-template-columns: 1fr;
}

.prompt-media-section .reading-image-grid figure {
  overflow: visible;
  border: 0;
  background: transparent;
}

.prompt-media-section .reading-image-grid img {
  max-height: 720px;
  background: transparent;
}

.reading-image-grid figcaption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background: #fff;
  color: var(--muted);
  font-size: 13px;
}

.reading-image-grid figcaption span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reading-image-grid figcaption a,
.reading-download-list a {
  color: var(--accent);
  font-weight: 800;
  text-decoration: none;
}

.reading-player-list {
  display: grid;
  gap: 14px;
}

.reading-player-list video,
.reading-player-list audio {
  width: 100%;
  border-radius: 8px;
  background: #050505;
}

.reading-player-list video {
  max-height: 640px;
}

.reading-download-list {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid rgba(167, 121, 43, 0.2);
  border-radius: 8px;
  background: #fffaf0;
}

.reading-download-list h2 {
  margin: 0 0 4px;
  font-size: 20px;
}

.reading-download-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.reading-download-list small {
  color: var(--muted);
  font-weight: 900;
}

.reading-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 34px;
  align-items: start;
}

.reading-article {
  min-width: 0;
  padding: 8px 0 28px;
  color: #211d15;
  font-size: 17px;
  line-height: 1.95;
}

.reading-article h2,
.reading-article h3,
.reading-article h4,
.reading-article h5 {
  margin: 34px 0 12px;
  color: var(--ink);
  line-height: 1.32;
}

.reading-article h2 {
  font-size: 28px;
}

.reading-article h3 {
  font-size: 23px;
}

.reading-article h4,
.reading-article h5 {
  font-size: 20px;
}

.reading-article p,
.reading-article ul,
.reading-article ol {
  margin: 0 0 18px;
}

.reading-article ul,
.reading-article ol {
  padding-left: 1.35em;
}

.reading-article li {
  margin: 6px 0;
}

.reading-code-block {
  overflow: hidden;
  margin: 22px 0;
  border: 1px solid rgba(255, 247, 229, 0.12);
  border-radius: 8px;
  background: #11100d;
  color: #fff7e5;
}

.reading-code-block > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 247, 229, 0.12);
  color: #f0c25a;
  font-size: 13px;
  font-weight: 900;
}

.reading-code-block .copy-btn {
  margin: 0;
  border-color: rgba(240, 194, 90, 0.4);
  color: #f7e3aa;
  background: rgba(240, 194, 90, 0.08);
}

.reading-code-block pre {
  margin: 0;
  padding: 18px;
  overflow-x: auto;
}

.reading-code-block code {
  color: #f7f0df;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 14px;
  line-height: 1.75;
  white-space: pre;
}

.reading-side {
  position: sticky;
  top: 22px;
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.reading-side h2 {
  margin: 0;
  font-size: 18px;
}

.reading-side dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.reading-side dl div {
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.reading-side dt {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.reading-side dd {
  margin: 0;
  color: var(--ink);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

@media (max-width: 1080px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

  .nav {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .cost-rule {
    display: none;
  }

  .content-grid.two,
  .metric-grid,
  .timeline,
  .recent-strip,
  .learning-pillar-grid,
  .home-card-grid,
  .ops-hero,
  .workbench-hero,
  .student-hero,
  .studio-logo-stage {
    grid-template-columns: 1fr 1fr;
  }

  .home-hero {
    grid-template-columns: 1fr;
  }

  .home-top-info {
    grid-template-columns: 1fr;
  }

  .community-hero {
    grid-template-columns: 1fr;
  }

  .workbench-entry-grid,
  .workbench-entry-grid.channels,
  .workbench-config-grid,
  .external-workflow-grid,
  .skill-repo-layout,
  .settings-section-grid,
  .legal-overview-grid {
    grid-template-columns: 1fr;
  }

  .skill-repo-header {
    flex-direction: column;
  }

  .skill-repo-actions {
    justify-content: flex-start;
  }

  .skill-visual-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .skill-waterfall-grid {
    column-count: 2;
  }

  .skill-file-row {
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .skill-file-side {
    grid-column: 2;
    justify-items: start;
    text-align: left;
  }

  .inspiration-layout {
    grid-template-columns: 1fr;
  }

  .inspiration-sidebar {
    position: static;
  }

  .masonry-feed {
    column-count: 2;
  }

  .role-grid {
    grid-template-columns: repeat(3, minmax(220px, 1fr));
  }

  .detail-dialog {
    grid-template-columns: 1fr;
  }

  .detail-media > img {
    max-height: 360px;
  }

	  .reading-hero,
	  .reading-layout,
	  .case-reading-hero,
	  .community-reading-hero,
	  .community-reading-grid,
	  .prompt-reading-hero,
	  .prompt-reading-layout {
	    grid-template-columns: 1fr;
	  }

	  .prompt-reading-side {
	    position: static;
	  }

  .case-overview-grid,
  .case-chain,
  .case-dimension-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .reading-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .reading-side {
    position: static;
  }
}

@media (max-width: 720px) {
  .main {
    padding: 18px;
  }

  .topbar,
  .top-actions {
    align-items: stretch;
    flex-direction: column;
  }

  #global-search {
    width: 100%;
  }

  .nav,
  .content-grid.two,
  .metric-grid,
    .timeline,
  .form-grid,
  .home-top-info,
  .home-hero,
  .hero-showcase,
  .recent-strip,
  .learning-pillar-grid,
  .home-card-grid,
  .antpower-start-guide,
  .ops-hero,
  .workbench-hero,
  .student-hero {
    grid-template-columns: 1fr;
  }

  .legal-document {
    padding: 18px;
  }

  .legal-mini-links {
    grid-template-columns: 1fr;
  }

  .antpower-guide-steps div {
    grid-template-columns: 46px minmax(0, 1fr);
  }

  .antpower-guide-steps span {
    grid-column: 1 / -1;
  }

  .skill-visual-grid,
  .skill-file-row {
    grid-template-columns: 1fr;
  }

  .skill-waterfall-grid {
    column-count: 1;
    padding: 10px;
  }

  .skill-file-cover {
    width: 100%;
  }

  .skill-file-side {
    grid-column: auto;
  }

  .skill-download-grid,
  .skill-submit-link-grid,
  .skill-edit-targets div,
  .skill-code-row,
  .skill-command-block {
    grid-template-columns: 1fr !important;
  }

  .skill-page-hero,
  .skill-page-github-layout {
    grid-template-columns: 1fr;
  }

  .skill-page-hero {
    padding: 12px;
  }

  .skill-page-copy-panel {
    padding: 18px;
  }

  .skill-page-visual-panel > img {
    aspect-ratio: 16 / 9;
  }

  .skill-page-sidebar {
    position: static;
  }

  .skill-repository-topline,
  .skill-side-summary div,
  .skill-overview-grid {
    grid-template-columns: 1fr;
  }

  .skill-repository-topline {
    display: grid;
  }

  .skill-detail-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .skill-code-row em {
    justify-self: start;
  }

  .banner-slide,
  .banner-slide .banner-panorama,
  .banner-slide .portal-placeholder {
    height: 480px;
    min-height: 480px;
  }

  .banner-slide .banner-panorama {
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
    filter: saturate(1.24) contrast(1.1) brightness(1.16);
  }

  .banner-copy {
    left: 18px;
    right: 18px;
    top: auto;
    bottom: 20px;
    width: auto;
    max-width: 440px;
    padding: 12px 14px;
  }

  .banner-copy h2 {
    max-width: none;
    font-size: clamp(28px, 6vw, 36px);
  }

  .banner-cinematic-panel {
    display: none;
  }

  .banner-dots {
    display: none;
  }

  .banner-nav {
    width: 38px;
    height: 38px;
  }

  .banner-nav span {
    font-size: 29px;
  }

  .status-list div {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    min-height: 300px;
  }

  .hero-copy h2 {
    font-size: 28px;
  }

  .feed-head {
    align-items: stretch;
    flex-direction: column;
  }

  .inspiration-composer,
  .inspiration-post {
    grid-template-columns: 1fr;
  }

  .composer-avatar,
  .post-avatar {
    width: 42px;
    height: 42px;
  }

	  .composer-row {
	    grid-template-columns: 1fr;
	  }

	  .community-reading-hero {
	    padding: 16px;
	  }

	  .community-reading-copy h1 {
	    font-size: clamp(30px, 8vw, 44px);
	  }

	  .community-reading-media,
	  .community-reading-placeholder {
	    min-height: 260px;
	  }

	  .masonry-feed {
	    column-count: 1;
	  }

  .role-grid,
  .visibility-table {
    grid-template-columns: 1fr;
  }

  .detail-overlay {
    padding: 12px;
  }

  .detail-content {
    padding: 18px;
  }

  .detail-content h2 {
    font-size: 22px;
  }

  .stage-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .knowledge-hero,
  .theory-feature-card,
  .zhangdao-feature-layout,
  .knowledge-admin-grid {
    grid-template-columns: 1fr;
  }

  .knowledge-hero {
    gap: 0;
    min-height: 260px;
  }

  .knowledge-hero-copy {
    padding: 18px 20px;
  }

  .knowledge-hero-copy h2 {
    font-size: clamp(26px, 4vw, 40px);
  }

  .knowledge-hero-media {
    min-height: 0;
    max-height: none;
  }

  .knowledge-stats,
  .knowledge-source-grid,
  .knowledge-doc-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .knowledge-admin-list div {
    grid-template-columns: minmax(0, 1fr) auto;
  }

	  .reading-hero h1 {
	    font-size: clamp(30px, 8vw, 44px);
	  }

		  .prompt-content-head,
		  .prompt-section-head {
		    align-items: stretch;
		    flex-direction: column;
		  }

	  .prompt-content-block pre {
	    font-size: 13px;
	  }

	  .reading-actions {
	    grid-template-columns: 1fr;
	  }

  .reading-image-grid {
    grid-template-columns: 1fr;
  }

  .case-overview-grid,
  .case-chain,
  .case-dimension-grid,
  .case-asset-list a {
    grid-template-columns: 1fr;
  }

  .case-hero-media {
    height: min(64vh, 360px);
    min-height: 240px;
  }

  .case-gallery-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .studio-logo-stage {
    grid-template-columns: 1fr;
    min-height: 0;
    text-align: center;
  }

  .studio-logo-orbit {
    width: min(48vw, 180px);
    justify-self: center;
  }

  .studio-logo-copy p {
    margin-inline: auto;
  }

  .studio-logo-copy small {
    margin-inline: auto;
  }

  .studio-carousel-dots {
    left: 50%;
    transform: translateX(-50%);
  }

  .knowledge-hero-copy {
    padding: 22px;
  }

  .knowledge-hero-media {
    min-height: 0;
    max-height: none;
  }

  .theory-feature-media {
    min-height: 190px;
  }

  .theory-feature-copy {
    padding: 18px;
  }

  .zhangdao-feature-cover {
    max-width: 260px;
  }

  .knowledge-stats,
  .knowledge-source-grid,
  .knowledge-doc-grid,
  .ops-gateway-grid {
    grid-template-columns: 1fr;
  }

  .ops-gateway-card {
    min-height: 260px;
  }

  .knowledge-admin-list div {
    grid-template-columns: 1fr;
  }

  .reading-article {
    font-size: 16px;
    line-height: 1.9;
  }

  .reading-image-grid figcaption,
  .reading-download-list a {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Final sitewide theme layer: keep dark/light modes coherent after legacy page styles. */
:root[data-theme="dark"] body {
  background: #0b0a08;
  color: #f6eddc;
}

:root[data-theme="dark"] .main,
:root[data-theme="dark"] .view-root {
  background: #0b0a08;
  color: #f6eddc;
}

:root[data-theme="dark"] .sidebar,
:root[data-theme="dark"] body.home-mode .sidebar,
:root[data-theme="dark"] body.projects-mode .sidebar {
  background: #11100d;
  color: #f8f3e7;
  border-right: 1px solid rgba(255, 224, 150, 0.12);
}

:root[data-theme="dark"] .topbar,
:root[data-theme="dark"] .current-url-strip,
:root[data-theme="dark"] .metric,
:root[data-theme="dark"] .panel,
:root[data-theme="dark"] .item,
:root[data-theme="dark"] .portal-card,
:root[data-theme="dark"] .masonry-card,
:root[data-theme="dark"] .community-card,
:root[data-theme="dark"] .project-community-card,
:root[data-theme="dark"] .reading-shell,
:root[data-theme="dark"] .case-reading-shell,
:root[data-theme="dark"] .prompt-content-block,
:root[data-theme="dark"] .prompt-media-section,
:root[data-theme="dark"] .prompt-reading-side,
:root[data-theme="dark"] .community-reading-hero,
:root[data-theme="dark"] .community-reading-panel,
:root[data-theme="dark"] .knowledge-stats article,
:root[data-theme="dark"] .knowledge-source-card,
:root[data-theme="dark"] .knowledge-doc-card,
:root[data-theme="dark"] .knowledge-nav a,
:root[data-theme="dark"] .reading-download-list,
:root[data-theme="dark"] .reading-download-list a,
:root[data-theme="dark"] .case-file-index a,
:root[data-theme="dark"] .pending-prompt-list article {
  border-color: rgba(255, 224, 150, 0.16);
  background-color: #15120d;
  color: #f6eddc;
}

:root[data-theme="dark"] .community-hero,
:root[data-theme="dark"] .director-picks-hero,
:root[data-theme="dark"] .project-community-hero,
:root[data-theme="dark"] .zhangdao-knowledge-feature,
:root[data-theme="dark"] .antpower-start-guide,
:root[data-theme="dark"] .studio-launch,
:root[data-theme="dark"] .knowledge-hero {
  border-color: rgba(255, 224, 150, 0.22);
  background-color: #11100d;
  color: #fff7dd;
}

:root[data-theme="dark"] h1,
:root[data-theme="dark"] h2,
:root[data-theme="dark"] h3,
:root[data-theme="dark"] .portal-body h3,
:root[data-theme="dark"] .masonry-body h3,
:root[data-theme="dark"] .reading-article h2,
:root[data-theme="dark"] .reading-article h3,
:root[data-theme="dark"] .reading-article h4,
:root[data-theme="dark"] .reading-article h5,
:root[data-theme="dark"] .knowledge-doc-card h3,
:root[data-theme="dark"] .knowledge-source-card h3,
:root[data-theme="dark"] .prompt-reading-side h2,
:root[data-theme="dark"] .prompt-section-head h2,
:root[data-theme="dark"] .prompt-content-block h2,
:root[data-theme="dark"] .community-reading-copy h1,
:root[data-theme="dark"] .community-reading-panel h2,
:root[data-theme="dark"] .inspiration-post h3 {
  color: #f6eddc;
}

:root[data-theme="dark"] p,
:root[data-theme="dark"] .portal-body p,
:root[data-theme="dark"] .masonry-body p,
:root[data-theme="dark"] .reading-hero p,
:root[data-theme="dark"] .reading-article,
:root[data-theme="dark"] .knowledge-doc-card p,
:root[data-theme="dark"] .knowledge-source-card p,
:root[data-theme="dark"] .knowledge-stats small,
:root[data-theme="dark"] .community-reading-copy p,
:root[data-theme="dark"] .community-reading-panel p:not(.eyebrow),
:root[data-theme="dark"] .inspiration-post p,
:root[data-theme="dark"] .creator-line,
:root[data-theme="dark"] .creator-line small,
:root[data-theme="dark"] .prompt-reading-side dd,
:root[data-theme="dark"] .prompt-director-card small,
:root[data-theme="dark"] .prompt-director-picks p {
  color: #c8b993;
}

:root[data-theme="dark"] .pill,
:root[data-theme="dark"] .portal-meta span,
:root[data-theme="dark"] .post-tags span,
:root[data-theme="dark"] .post-actions button,
:root[data-theme="dark"] .category-chip {
  border-color: rgba(255, 224, 150, 0.16);
  background: #1c1811;
  color: #c8b993;
}

:root[data-theme="dark"] input,
:root[data-theme="dark"] textarea,
:root[data-theme="dark"] select,
:root[data-theme="dark"] #global-search {
  border-color: rgba(255, 224, 150, 0.18);
  background: #12100c;
  color: #f6eddc;
}

:root[data-theme="dark"] input::placeholder,
:root[data-theme="dark"] textarea::placeholder {
  color: rgba(246, 237, 220, 0.52);
}

:root[data-theme="dark"] .reading-image-grid figcaption,
:root[data-theme="dark"] .prompt-director-card,
:root[data-theme="dark"] .prompt-side-thumb img,
:root[data-theme="dark"] .post-media,
:root[data-theme="dark"] .community-reading-media,
:root[data-theme="dark"] .case-hero-media,
:root[data-theme="dark"] .case-gallery-grid figure,
:root[data-theme="dark"] .case-gallery-grid figcaption,
:root[data-theme="dark"] .case-overview-grid div,
:root[data-theme="dark"] .case-reading-section,
:root[data-theme="dark"] .case-chain div,
:root[data-theme="dark"] .case-dimension-card,
:root[data-theme="dark"] .case-video-frame,
:root[data-theme="dark"] .case-asset-list a,
:root[data-theme="dark"] .case-file-index,
:root[data-theme="dark"] .case-file-index a {
  border-color: rgba(255, 224, 150, 0.14);
  background: #0c0b08;
  color: #f6eddc;
}

:root[data-theme="dark"] .case-section-head h2,
:root[data-theme="dark"] .case-overview-grid strong,
:root[data-theme="dark"] .case-chain strong,
:root[data-theme="dark"] .case-dimension-card h3,
:root[data-theme="dark"] .case-asset-list span,
:root[data-theme="dark"] .case-file-index h3,
:root[data-theme="dark"] .case-file-index strong,
:root[data-theme="dark"] .case-gallery-grid figcaption span {
  color: #f6eddc;
}

:root[data-theme="dark"] .case-section-head p,
:root[data-theme="dark"] .case-chain span,
:root[data-theme="dark"] .case-dimension-card p,
:root[data-theme="dark"] .case-overview-grid span,
:root[data-theme="dark"] .case-dimension-card span,
:root[data-theme="dark"] .case-asset-list small,
:root[data-theme="dark"] .case-file-index small {
  color: #c8b993;
}

:root[data-theme="light"] body {
  background: #f7f4ed;
  color: #17140e;
}

:root[data-theme="light"] .main,
:root[data-theme="light"] .view-root {
  background: #f7f4ed;
  color: #17140e;
}

:root[data-theme="light"] .sidebar,
:root[data-theme="light"] body.home-mode .sidebar,
:root[data-theme="light"] body.projects-mode .sidebar {
  background: #ffffff;
  color: #17140e;
  border-right: 1px solid #ddd6c7;
}

:root[data-theme="light"] .topbar,
:root[data-theme="light"] .current-url-strip,
:root[data-theme="light"] .metric,
:root[data-theme="light"] .panel,
:root[data-theme="light"] .item,
:root[data-theme="light"] .portal-card,
:root[data-theme="light"] .masonry-card,
:root[data-theme="light"] .community-card,
:root[data-theme="light"] .project-community-card,
:root[data-theme="light"] .reading-shell,
:root[data-theme="light"] .case-reading-shell,
:root[data-theme="light"] .prompt-content-block,
:root[data-theme="light"] .prompt-media-section,
:root[data-theme="light"] .prompt-reading-side,
:root[data-theme="light"] .community-reading-hero,
:root[data-theme="light"] .community-reading-panel,
:root[data-theme="light"] .knowledge-stats article,
:root[data-theme="light"] .knowledge-source-card,
:root[data-theme="light"] .knowledge-doc-card,
:root[data-theme="light"] .knowledge-nav a,
:root[data-theme="light"] .reading-download-list,
:root[data-theme="light"] .reading-download-list a,
:root[data-theme="light"] .case-file-index a,
:root[data-theme="light"] .pending-prompt-list article,
:root[data-theme="light"] .zhangdao-knowledge-feature {
  border-color: #ddd6c7;
  background-color: #ffffff;
  color: #17140e;
}

:root[data-theme="light"] .community-hero,
:root[data-theme="light"] .director-picks-hero,
:root[data-theme="light"] .project-community-hero,
:root[data-theme="light"] .antpower-start-guide,
:root[data-theme="light"] .studio-launch,
:root[data-theme="light"] .knowledge-hero {
  border-color: rgba(167, 121, 43, 0.22);
  background-color: #fffaf0;
  color: #17140e;
}

:root[data-theme="light"] h1,
:root[data-theme="light"] h2,
:root[data-theme="light"] h3,
:root[data-theme="light"] .portal-body h3,
:root[data-theme="light"] .masonry-body h3,
:root[data-theme="light"] .reading-article h2,
:root[data-theme="light"] .reading-article h3,
:root[data-theme="light"] .reading-article h4,
:root[data-theme="light"] .reading-article h5,
:root[data-theme="light"] .knowledge-doc-card h3,
:root[data-theme="light"] .knowledge-source-card h3,
:root[data-theme="light"] .prompt-reading-side h2,
:root[data-theme="light"] .prompt-section-head h2,
:root[data-theme="light"] .prompt-content-block h2,
:root[data-theme="light"] .community-reading-copy h1,
:root[data-theme="light"] .community-reading-panel h2,
:root[data-theme="light"] .inspiration-post h3 {
  color: #17140e;
}

:root[data-theme="light"] p,
:root[data-theme="light"] .portal-body p,
:root[data-theme="light"] .masonry-body p,
:root[data-theme="light"] .reading-hero p,
:root[data-theme="light"] .reading-article,
:root[data-theme="light"] .knowledge-doc-card p,
:root[data-theme="light"] .knowledge-source-card p,
:root[data-theme="light"] .knowledge-stats small,
:root[data-theme="light"] .community-reading-copy p,
:root[data-theme="light"] .community-reading-panel p:not(.eyebrow),
:root[data-theme="light"] .inspiration-post p,
:root[data-theme="light"] .creator-line,
:root[data-theme="light"] .creator-line small,
:root[data-theme="light"] .prompt-reading-side dd,
:root[data-theme="light"] .prompt-director-card small,
:root[data-theme="light"] .prompt-director-picks p {
  color: #746f62;
}

:root[data-theme="light"] .pill,
:root[data-theme="light"] .portal-meta span,
:root[data-theme="light"] .post-tags span,
:root[data-theme="light"] .post-actions button,
:root[data-theme="light"] .category-chip {
  border-color: #ddd6c7;
  background: #fffaf0;
  color: #746f62;
}

:root[data-theme="light"] input,
:root[data-theme="light"] textarea,
:root[data-theme="light"] select,
:root[data-theme="light"] #global-search {
  border-color: #ddd6c7;
  background: #ffffff;
  color: #17140e;
}

:root[data-theme="light"] .reading-image-grid figcaption,
:root[data-theme="light"] .prompt-director-card,
:root[data-theme="light"] .prompt-side-thumb img,
:root[data-theme="light"] .post-media,
:root[data-theme="light"] .community-reading-media,
:root[data-theme="light"] .case-hero-media,
:root[data-theme="light"] .case-gallery-grid figure,
:root[data-theme="light"] .case-gallery-grid figcaption,
:root[data-theme="light"] .case-overview-grid div,
:root[data-theme="light"] .case-reading-section,
:root[data-theme="light"] .case-chain div,
:root[data-theme="light"] .case-dimension-card,
:root[data-theme="light"] .case-video-frame,
:root[data-theme="light"] .case-asset-list a,
:root[data-theme="light"] .case-file-index,
:root[data-theme="light"] .case-file-index a {
  border-color: #ddd6c7;
  background: #ffffff;
  color: #17140e;
}

:root[data-theme="light"] .case-section-head h2,
:root[data-theme="light"] .case-overview-grid strong,
:root[data-theme="light"] .case-chain strong,
:root[data-theme="light"] .case-dimension-card h3,
:root[data-theme="light"] .case-asset-list span,
:root[data-theme="light"] .case-file-index h3,
:root[data-theme="light"] .case-file-index strong,
:root[data-theme="light"] .case-gallery-grid figcaption span {
  color: #17140e;
}

:root[data-theme="light"] .case-section-head p,
:root[data-theme="light"] .case-chain span,
:root[data-theme="light"] .case-dimension-card p,
:root[data-theme="light"] .case-overview-grid span,
:root[data-theme="light"] .case-dimension-card span,
:root[data-theme="light"] .case-asset-list small,
:root[data-theme="light"] .case-file-index small {
  color: #746f62;
}

:root[data-theme="light"] .portal-body {
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.94));
}

/* Final button theme layer */
:root[data-theme="dark"] {
  --button-primary-bg: #d6a847;
  --button-primary-hover: #f0c25a;
  --button-primary-text: #11100d;
  --button-surface: #1b1710;
  --button-surface-hover: #2a2114;
  --button-border: rgba(255, 224, 150, 0.24);
  --button-border-hover: rgba(255, 224, 150, 0.5);
  --button-text: #f6eddc;
  --button-muted: #c8b993;
}

:root[data-theme="light"] {
  --button-primary-bg: #a7792b;
  --button-primary-hover: #8f6623;
  --button-primary-text: #ffffff;
  --button-surface: #ffffff;
  --button-surface-hover: #fff7e5;
  --button-border: #ddd6c7;
  --button-border-hover: rgba(167, 121, 43, 0.42);
  --button-text: #17140e;
  --button-muted: #746f62;
}

:root[data-theme] .primary-btn,
:root[data-theme] .hero-btn,
:root[data-theme] .student-access button:not(:disabled) {
  border: 1px solid var(--button-primary-bg);
  background: var(--button-primary-bg);
  color: var(--button-primary-text);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

:root[data-theme] .primary-btn:hover,
:root[data-theme] .primary-btn:focus-visible,
:root[data-theme] .hero-btn:hover,
:root[data-theme] .hero-btn:focus-visible,
:root[data-theme] .student-access button:not(:disabled):hover,
:root[data-theme] .student-access button:not(:disabled):focus-visible {
  border-color: var(--button-primary-hover);
  background: var(--button-primary-hover);
  color: var(--button-primary-text);
  outline: none;
}

:root[data-theme] .copy-btn,
:root[data-theme] .copy-btn.dark,
:root[data-theme] .asset-link,
:root[data-theme] .hero-btn.ghost,
:root[data-theme] .auth-btn,
:root[data-theme] .post-actions button,
:root[data-theme] .recent-create button,
:root[data-theme] .detail-close,
:root[data-theme] .dark-link,
:root[data-theme] .reading-code-block .copy-btn,
:root[data-theme] .knowledge-admin-list .copy-btn,
:root[data-theme] .detail-url-row .copy-btn,
:root[data-theme] .detail-section-head .copy-btn {
  border: 1px solid var(--button-border);
  background: var(--button-surface);
  color: var(--button-text);
  box-shadow: none;
}

:root[data-theme] .copy-btn:hover,
:root[data-theme] .copy-btn:focus-visible,
:root[data-theme] .copy-btn.dark:hover,
:root[data-theme] .copy-btn.dark:focus-visible,
:root[data-theme] .asset-link:hover,
:root[data-theme] .asset-link:focus-visible,
:root[data-theme] .hero-btn.ghost:hover,
:root[data-theme] .hero-btn.ghost:focus-visible,
:root[data-theme] .auth-btn:hover,
:root[data-theme] .auth-btn:focus-visible,
:root[data-theme] .post-actions button:hover,
:root[data-theme] .post-actions button:focus-visible,
:root[data-theme] .recent-create button:hover,
:root[data-theme] .recent-create button:focus-visible,
:root[data-theme] .detail-close:hover,
:root[data-theme] .detail-close:focus-visible,
:root[data-theme] .dark-link:hover,
:root[data-theme] .dark-link:focus-visible {
  border-color: var(--button-border-hover);
  background: var(--button-surface-hover);
  color: var(--button-text);
  outline: none;
}

:root[data-theme] .auth-btn.register {
  border-color: var(--button-primary-bg);
  background: var(--button-primary-bg);
  color: var(--button-primary-text);
}

:root[data-theme] .nav-item {
  border: 1px solid transparent;
  background: transparent;
  color: var(--button-muted);
}

:root[data-theme] .nav-item:hover,
:root[data-theme] .nav-item:focus-visible,
:root[data-theme] .nav-item.active {
  border-color: var(--button-border);
  background: color-mix(in srgb, var(--button-primary-bg) 16%, transparent);
  color: var(--button-text);
  outline: none;
}

:root[data-theme] .category-chip {
  border-color: var(--button-border);
  background: var(--button-surface);
  color: var(--button-text);
}

:root[data-theme] .category-chip span {
  color: var(--button-muted);
}

:root[data-theme] .category-chip.active,
:root[data-theme] .category-chip:hover,
:root[data-theme] .category-chip:focus-visible {
  border-color: var(--button-primary-bg);
  background: var(--button-primary-bg);
  color: var(--button-primary-text);
  outline: none;
}

:root[data-theme] .category-chip.active span,
:root[data-theme] .category-chip:hover span,
:root[data-theme] .category-chip:focus-visible span {
  color: color-mix(in srgb, var(--button-primary-text) 72%, transparent);
}

:root[data-theme] .theme-toggle {
  border-color: var(--button-border-hover);
  background: var(--button-surface);
  color: var(--button-text);
}

:root[data-theme] .theme-toggle:hover,
:root[data-theme] .theme-toggle:focus-visible {
  border-color: var(--button-primary-bg);
  background: var(--button-surface-hover);
  color: var(--button-text);
  outline: none;
}

:root[data-theme] .settings-toggle {
  border-color: var(--button-border-hover);
  background: var(--button-surface);
  color: var(--button-text);
}

:root[data-theme] .settings-toggle:hover,
:root[data-theme] .settings-toggle:focus-visible {
  border-color: var(--button-primary-bg);
  background: var(--button-surface-hover);
  color: var(--button-text);
  outline: none;
}

:root[data-theme] .settings-menu {
  border-color: var(--button-border);
  background: var(--button-surface);
  color: var(--button-text);
}

:root[data-theme] .settings-menu button:hover,
:root[data-theme] .settings-menu button:focus-visible {
  background: var(--button-surface-hover);
}

:root[data-theme] .workbench-entry-panel,
:root[data-theme] .workbench-config-panel,
:root[data-theme] .workbench-entry-card,
:root[data-theme] .workbench-config-section,
:root[data-theme] .workflow-stage,
:root[data-theme] .connector-card,
:root[data-theme] .external-workflow-card {
  border-color: var(--button-border);
  background: var(--button-surface);
  color: var(--button-text);
}

:root[data-theme] .libtv-entry {
  background: color-mix(in srgb, var(--button-surface) 92%, var(--button-primary-bg));
}

:root[data-theme] .workflow-stage > span {
  background: color-mix(in srgb, var(--button-primary-bg) 12%, transparent);
  color: var(--button-text);
}

:root[data-theme] button:disabled,
:root[data-theme] .copy-btn:disabled,
:root[data-theme] .primary-btn:disabled,
:root[data-theme] .hero-btn:disabled {
  cursor: not-allowed;
  opacity: 0.56;
}

/* Final tag theme layer */
:root[data-theme="dark"] .pill,
:root[data-theme="dark"] .portal-meta span,
:root[data-theme="dark"] .post-tags span {
  border-color: rgba(255, 224, 150, 0.34);
  background: linear-gradient(180deg, #17120b, #0c0a07);
  color: #fff4d2;
  box-shadow: inset 0 1px 0 rgba(255, 244, 210, 0.08);
}

:root[data-theme="dark"] .pill.strong {
  border-color: rgba(240, 194, 90, 0.66);
  background: #d6a847;
  color: #11100d;
}

:root[data-theme="light"] .pill,
:root[data-theme="light"] .portal-meta span,
:root[data-theme="light"] .post-tags span {
  border-color: #ddd6c7;
  background: #fffaf0;
  color: #5f5748;
  box-shadow: none;
}

:root[data-theme="light"] .pill.strong {
  border-color: rgba(167, 121, 43, 0.38);
  background: rgba(167, 121, 43, 0.1);
  color: #8f6623;
}

/* Final agent and detail theme layer */
:root[data-theme="dark"] .role-card,
:root[data-theme="dark"] .agent-card {
  border-color: rgba(255, 224, 150, 0.18);
  background: #15120d;
  color: #f6eddc;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}

:root[data-theme="dark"] .role-card:hover,
:root[data-theme="dark"] .role-card:focus-visible,
:root[data-theme="dark"] .agent-card:hover,
:root[data-theme="dark"] .agent-card:focus-visible {
  border-color: rgba(255, 224, 150, 0.52);
  box-shadow: 0 22px 56px rgba(0, 0, 0, 0.36);
}

:root[data-theme="dark"] .role-card h3 {
  color: #f6eddc;
}

:root[data-theme="dark"] .role-card p {
  color: #c8b993;
}

:root[data-theme="dark"] .role-card > span {
  border-color: rgba(255, 224, 150, 0.42);
  background: #d6a847;
  color: #11100d;
}

:root[data-theme="dark"] .workbench-note {
  border-color: rgba(255, 224, 150, 0.18);
  background: #0c0b08;
  color: #f6eddc;
}

:root[data-theme="dark"] .workbench-note strong {
  color: #fff4d2;
}

:root[data-theme="dark"] .workbench-note span {
  color: #c8b993;
}

:root[data-theme="dark"] .content-safety-panel {
  border-color: rgba(255, 224, 150, 0.22);
  background: #11100d;
  color: #f6eddc;
}

:root[data-theme="dark"] .content-safety-panel p {
  color: #d8c8a8;
}

:root[data-theme="dark"] .safety-topic-row span {
  border-color: rgba(255, 224, 150, 0.2);
  background: #18140e;
  color: #fff4d2;
}

:root[data-theme="dark"] .ops-hero,
:root[data-theme="dark"] #ops-health .panel {
  border-color: rgba(255, 224, 150, 0.18);
  background: #11100d;
}

:root[data-theme="dark"] .ops-hero input,
:root[data-theme="dark"] #global-search {
  color-scheme: dark;
  appearance: none;
  border-color: rgba(255, 224, 150, 0.28) !important;
  background: #090805 !important;
  color: #fff4d2 !important;
  caret-color: #d6a847;
  box-shadow: inset 0 0 0 1px rgba(255, 224, 150, 0.04) !important;
}

:root[data-theme="dark"] .ops-hero input:focus,
:root[data-theme="dark"] #global-search:focus {
  outline: 2px solid rgba(214, 168, 71, 0.46);
  outline-offset: 2px;
  background: #0c0b08 !important;
}

:root[data-theme="dark"] .ops-hero input:-webkit-autofill,
:root[data-theme="dark"] #global-search:-webkit-autofill {
  -webkit-text-fill-color: #fff4d2;
  box-shadow: 0 0 0 1000px #090805 inset !important;
  transition: background-color 9999s ease-out;
}

:root[data-theme="dark"] .status-list div {
  border-color: rgba(255, 224, 150, 0.14);
  background: #0c0b08;
  color: #f6eddc;
}

:root[data-theme="dark"] .status-list span,
:root[data-theme="dark"] .admin-access label,
:root[data-theme="dark"] .admin-access p,
:root[data-theme="dark"] .empty {
  color: #c8b993;
}

:root[data-theme="dark"] .status-list strong {
  color: #fff4d2;
}

:root[data-theme="dark"] #ops-health .empty {
  border-color: rgba(255, 224, 150, 0.18);
  background: #0c0b08;
}

:root[data-theme="dark"] .detail-dialog,
:root[data-theme="dark"] .detail-content,
:root[data-theme="dark"] .detail-section,
:root[data-theme="dark"] .detail-url-section {
  border-color: rgba(255, 224, 150, 0.16);
  background: #12100c;
  color: #f6eddc;
}

:root[data-theme="dark"] .detail-media,
:root[data-theme="dark"] .detail-placeholder {
  border-color: rgba(255, 224, 150, 0.14);
  background: #090805;
  color: #d6a847;
}

:root[data-theme="dark"] .detail-content h2,
:root[data-theme="dark"] .detail-section-head h3 {
  color: #f6eddc;
}

:root[data-theme="dark"] .detail-section-head {
  border-bottom-color: rgba(255, 224, 150, 0.16);
}

:root[data-theme="dark"] .detail-summary,
:root[data-theme="dark"] .detail-section pre,
:root[data-theme="dark"] .detail-url-row span {
  color: #c8b993;
}

:root[data-theme="dark"] .detail-url-row a {
  color: #fff4d2;
}

:root[data-theme="dark"] .project-reading-progress {
  border-color: rgba(255, 224, 150, 0.22);
  background: #0c0b08;
}

:root[data-theme="dark"] .project-stage-status {
  border-color: rgba(255, 224, 150, 0.26);
  background: #17120b;
  color: #fff4d2;
}

:root[data-theme="dark"] .project-reading-hero {
  border-color: rgba(255, 224, 150, 0.22);
  background: #11100d;
  color: #fff7e5;
}

:root[data-theme="dark"] .project-hero-copy p:not(.eyebrow) {
  color: #d8c8a8;
}

:root[data-theme="light"] .role-card,
:root[data-theme="light"] .agent-card {
  border-color: #ddd6c7;
  background: #ffffff;
  color: #17140e;
  box-shadow: 0 18px 50px rgba(23, 20, 14, 0.08);
}

:root[data-theme="light"] .role-card:hover,
:root[data-theme="light"] .role-card:focus-visible,
:root[data-theme="light"] .agent-card:hover,
:root[data-theme="light"] .agent-card:focus-visible {
  border-color: rgba(167, 121, 43, 0.42);
  box-shadow: 0 18px 42px rgba(23, 20, 14, 0.12);
}

:root[data-theme="light"] .role-card h3 {
  color: #17140e;
}

:root[data-theme="light"] .role-card p {
  color: #746f62;
}

:root[data-theme="light"] .role-card > span {
  border-color: rgba(167, 121, 43, 0.2);
  background: #d6a847;
  color: #11100d;
}

:root[data-theme="light"] .workbench-note {
  border-color: #ddd6c7;
  background: #fffaf0;
  color: #17140e;
}

:root[data-theme="light"] .workbench-note strong {
  color: #17140e;
}

:root[data-theme="light"] .workbench-note span {
  color: #746f62;
}

:root[data-theme="light"] .content-safety-panel {
  border-color: rgba(167, 121, 43, 0.24);
  background: #ffffff;
  color: #17140e;
}

:root[data-theme="light"] .content-safety-panel p {
  color: #625c4f;
}

:root[data-theme="light"] .safety-topic-row span {
  border-color: #ddd6c7;
  background: #fffaf0;
  color: #5d3b00;
}

:root[data-theme="light"] .detail-dialog,
:root[data-theme="light"] .detail-content,
:root[data-theme="light"] .detail-section,
:root[data-theme="light"] .detail-url-section {
  border-color: #ddd6c7;
  background: #ffffff;
  color: #17140e;
}

:root[data-theme="light"] .detail-media,
:root[data-theme="light"] .detail-placeholder {
  border-color: #ddd6c7;
  background: #fffaf0;
  color: #8f6623;
}

:root[data-theme="light"] .detail-content h2,
:root[data-theme="light"] .detail-section-head h3 {
  color: #17140e;
}

:root[data-theme="light"] .detail-section-head {
  border-bottom-color: #ddd6c7;
}

:root[data-theme="light"] .detail-summary,
:root[data-theme="light"] .detail-section pre,
:root[data-theme="light"] .detail-url-row span {
  color: #746f62;
}

:root[data-theme="light"] .detail-url-row a {
  color: #8f6623;
}

:root[data-theme="light"] .project-reading-progress {
  border-color: #ddd6c7;
  background: #fffaf0;
}

:root[data-theme="light"] .project-stage-status {
  border-color: rgba(167, 121, 43, 0.28);
  background: rgba(167, 121, 43, 0.08);
  color: #8f6623;
}

:root[data-theme="light"] .project-reading-hero {
  border-color: rgba(167, 121, 43, 0.22);
  background: #fffaf0;
  color: #17140e;
}

:root[data-theme="light"] .project-hero-copy p:not(.eyebrow) {
  color: #746f62;
}

.fusion-portal-hero {
  position: relative;
  overflow: hidden;
  min-height: min(72vh, 760px);
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(214, 168, 71, 0.26);
  border-radius: 8px;
  background: #080705;
  box-shadow: var(--shadow);
  color: #fff7e5;
}

.fusion-portal-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.56;
}

.fusion-hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 6, 4, 0.94), rgba(7, 6, 4, 0.56), rgba(7, 6, 4, 0.18)),
    linear-gradient(0deg, rgba(7, 6, 4, 0.9), transparent 48%);
}

.fusion-hero-copy {
  position: relative;
  z-index: 1;
  width: min(760px, 70%);
  padding: clamp(30px, 5vw, 72px);
  display: flex;
  min-height: 100%;
  flex-direction: column;
  justify-content: center;
}

.fusion-hero-copy h2,
.fusion-hero h2 {
  margin: 12px 0;
  color: #fff7e5;
  font-size: clamp(32px, 5vw, 72px);
  line-height: 1.05;
  letter-spacing: 0;
}

.fusion-hero-copy p,
.fusion-hero p {
  max-width: 720px;
  color: #e0d1ad;
  font-size: 17px;
  line-height: 1.8;
}

.fusion-hero-console {
  position: absolute;
  right: clamp(18px, 3vw, 42px);
  bottom: clamp(18px, 3vw, 42px);
  z-index: 1;
  display: grid;
  gap: 8px;
  width: min(320px, 34%);
  border: 1px solid rgba(214, 168, 71, 0.32);
  border-radius: 8px;
  background: rgba(9, 8, 5, 0.72);
  padding: 16px;
  backdrop-filter: blur(12px);
}

.fusion-hero-console strong,
.fusion-count-panel strong {
  color: #f0c66a;
  font-size: 18px;
}

.fusion-hero-console span {
  color: #d4c196;
  font-size: 13px;
}

.fusion-section,
.fusion-table-section,
.fusion-hero {
  margin-top: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 22px;
  box-shadow: var(--shadow);
}

.fusion-hero.compact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 34%);
  align-items: center;
  gap: 24px;
  background: #11100d;
  color: #fff7e5;
}

.fusion-hero.compact img {
  width: 100%;
  max-height: 320px;
  border-radius: 8px;
  object-fit: cover;
}

.fusion-card-grid,
.fusion-source-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.fusion-card-grid.compact-grid {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.admin-data-console {
  display: grid;
  gap: 18px;
  margin-top: 18px;
}

.admin-console-login {
  margin: 0;
}

.admin-metrics {
  margin-top: 0;
}

.admin-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
}

.admin-content-form,
.admin-board {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 18px;
  box-shadow: var(--shadow);
}

.admin-content-form h3,
.admin-board h3 {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
}

.admin-board-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.admin-board-head span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.admin-list {
  display: grid;
  gap: 8px;
}

.admin-list-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) minmax(120px, 0.8fr) minmax(100px, 0.6fr);
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(214, 168, 71, 0.05);
}

.admin-list-row.event-row {
  grid-template-columns: minmax(220px, 1.4fr) minmax(120px, 0.8fr) minmax(90px, 0.5fr) 110px;
}

.admin-list-row.entry-row {
  grid-template-columns: minmax(180px, 1.2fr) minmax(190px, 1.2fr) minmax(120px, 0.8fr) minmax(160px, 1fr);
}

.admin-list-row strong {
  color: var(--ink);
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.admin-list-row span {
  color: var(--muted);
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.admin-empty-line {
  border: 1px dashed var(--line);
  border-radius: 8px;
  padding: 16px;
  color: var(--muted);
  text-align: center;
}

.fusion-card,
.fusion-source-grid article,
.fusion-count-panel,
.production-timeline article {
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.07);
  padding: 18px;
}

.fusion-card > span,
.fusion-source-grid span,
.production-timeline article > span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.fusion-card h3,
.production-timeline h3 {
  margin: 9px 0;
  font-size: 20px;
  line-height: 1.3;
  color: var(--ink);
}

.fusion-card p,
.fusion-source-grid p {
  color: var(--muted);
  line-height: 1.7;
}

.fusion-source-grid strong {
  display: block;
  margin: 8px 0;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.account-command-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.account-profile-panel {
  position: relative;
  overflow: hidden;
  margin-top: 18px;
  border: 1px solid rgba(214, 168, 71, 0.24);
  border-radius: 14px;
  background:
    radial-gradient(circle at 18% 8%, rgba(224, 185, 93, 0.18), transparent 36%),
    rgba(13, 11, 7, 0.92);
  box-shadow: var(--shadow);
}

.account-profile-cover {
  height: 152px;
  overflow: hidden;
  background: #070706;
}

.account-profile-cover img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  opacity: 0.84;
}

.account-profile-main {
  position: relative;
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 0 22px 22px;
}

.account-profile-avatar {
  width: 96px;
  height: 96px;
  display: grid;
  place-items: center;
  overflow: hidden;
  margin-top: -42px;
  border: 4px solid #11100d;
  border-radius: 50%;
  background: #fff;
  color: #101010;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  font-size: 26px;
  font-weight: 1000;
}

.account-profile-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.account-profile-copy {
  display: grid;
  gap: 8px;
  padding-top: 16px;
}

.account-profile-copy > span {
  width: fit-content;
  border: 1px solid rgba(224, 185, 93, 0.25);
  border-radius: 999px;
  background: rgba(224, 185, 93, 0.1);
  color: #f0c66a;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 900;
}

.account-profile-copy h3 {
  margin: 0;
  color: #fff7e5;
  font-size: 30px;
  line-height: 1.12;
}

.account-profile-copy p {
  max-width: 760px;
  margin: 0;
  color: rgba(237, 229, 209, 0.76);
  line-height: 1.7;
}

.account-profile-meta,
.account-social-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.account-profile-meta small,
.account-social-row a,
.account-social-row span {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  color: rgba(246, 238, 218, 0.7);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.account-social-row a:hover,
.account-social-row a:focus-visible {
  border-color: rgba(224, 185, 93, 0.45);
  color: #ffdd89;
  outline: none;
}

.account-profile-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 20px;
}

.account-profile-editor-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.74);
  backdrop-filter: blur(10px);
}

.account-profile-editor-dialog {
  position: relative;
  width: min(520px, calc(100vw - 30px));
  max-height: min(760px, calc(100vh - 36px));
  overflow: hidden;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: #111116;
  color: #f5f2ea;
  box-shadow: 0 36px 120px rgba(0, 0, 0, 0.62);
}

.profile-editor-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  cursor: pointer;
  font-size: 20px;
}

.account-profile-editor-cover {
  height: 118px;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 18%, rgba(0, 181, 255, 0.5), transparent 30%),
    linear-gradient(135deg, #08103a, #22104b 55%, #111116);
}

.account-profile-editor-cover img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  opacity: 0.62;
}

.account-editor-avatar-stack {
  display: grid;
  place-items: center;
  gap: 10px;
  margin-top: -46px;
  padding-bottom: 8px;
}

.account-editor-avatar-preview {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 4px solid #f6f7ff;
  border-radius: 50%;
  background: #fff;
  color: #111116;
  font-size: 24px;
  font-weight: 1000;
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.35);
}

.account-editor-avatar-preview img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.profile-avatar-change {
  border-radius: 8px;
  background: #242634;
  color: #fff;
  padding: 12px 24px;
  cursor: pointer;
  font-weight: 900;
}

.account-profile-form-scroll {
  overflow: auto;
  display: grid;
  gap: 16px;
  padding: 8px 20px 16px;
}

.profile-field,
.profile-social-fields,
.profile-social-fields label {
  display: grid;
  gap: 8px;
}

.profile-field > span,
.profile-social-fields > span {
  color: #f8f3e8;
  font-size: 14px;
  font-weight: 900;
}

.profile-field b {
  color: #ff6b79;
}

.profile-field input,
.profile-field textarea,
.profile-social-fields input {
  width: 100%;
  border: 1px solid transparent;
  border-radius: 8px;
  background: #282a31;
  color: #f8f6ef;
  padding: 14px 16px;
  font: inherit;
  outline: none;
}

.profile-field textarea {
  resize: vertical;
  min-height: 96px;
}

.profile-field input:focus,
.profile-field textarea:focus,
.profile-social-fields input:focus {
  border-color: #2f86ff;
  box-shadow: 0 0 0 3px rgba(47, 134, 255, 0.18);
}

.profile-field small,
.profile-editor-message {
  margin: 0;
  color: rgba(238, 233, 222, 0.56);
  font-size: 12px;
  line-height: 1.5;
}

.profile-social-fields {
  gap: 10px;
}

.profile-social-fields label {
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  gap: 0;
  overflow: hidden;
  border-radius: 8px;
  background: #282a31;
}

.profile-social-fields label b {
  height: 100%;
  display: grid;
  place-items: center;
  background: #3a3c4c;
  color: rgba(255, 255, 255, 0.74);
  font-size: 13px;
}

.profile-social-fields label input {
  border-radius: 0;
  background: transparent;
}

.account-profile-editor-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  padding: 12px 16px 16px;
  background: #111116;
}

.account-profile-editor-actions .asset-link,
.account-profile-editor-actions .primary-btn {
  justify-content: center;
  min-height: 48px;
  border-radius: 8px;
}

.account-command-card,
.account-quick-panel,
.credit-section,
.credit-rule-panel {
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(214, 168, 71, 0.09), rgba(49, 95, 159, 0.05)),
    var(--panel);
  box-shadow: var(--shadow);
}

.account-command-card {
  display: grid;
  gap: 9px;
  min-height: 180px;
  padding: 18px;
}

.account-command-card.is-gold {
  background:
    radial-gradient(circle at 12% 0%, rgba(224, 185, 93, 0.32), transparent 38%),
    linear-gradient(145deg, rgba(23, 20, 14, 0.98), rgba(92, 58, 14, 0.7));
  color: #fff7e5;
}

.account-command-card span,
.personal-canvas-body > span,
.account-site-card span,
.credit-product-card > span,
.model-credit-card > span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.account-command-card h3,
.account-section-head h3,
.personal-canvas-body h3,
.account-site-card h3,
.credit-section h3,
.credit-rule-panel h3,
.credit-product-card h3,
.model-credit-card h3 {
  margin: 0;
  color: var(--ink);
  line-height: 1.25;
}

.account-command-card.is-gold h3 {
  color: #fff7e5;
}

.account-command-card p,
.personal-canvas-body p,
.account-site-card p,
.credit-product-card p,
.model-credit-card p,
.credit-rule-list p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.account-command-card.is-gold p {
  color: #e6d0a0;
}

.account-quick-panel,
.credit-section,
.credit-rule-panel {
  margin-top: 18px;
  padding: 18px;
}

.account-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.account-canvas-page {
  display: grid;
  gap: 28px;
  color: #fff7e5;
}

.account-canvas-hero-strip {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 1.24fr) minmax(0, 1.06fr);
  align-items: center;
  gap: 18px;
  padding: 16px 0 4px;
}

.account-canvas-feature-card,
.account-canvas-recent-card,
.account-canvas-gallery-card,
.account-canvas-create-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(245, 210, 131, 0.15);
  border-radius: 8px;
  background: #14120e;
  box-shadow: 0 18px 56px rgba(0, 0, 0, 0.2);
}

.account-canvas-feature-card {
  min-height: 190px;
}

.account-canvas-feature-card.is-active {
  border-color: rgba(245, 210, 131, 0.36);
  box-shadow: 0 22px 72px rgba(0, 0, 0, 0.34), 0 0 0 1px rgba(245, 210, 131, 0.08);
  transform: translateY(-8px);
}

.account-canvas-card-media {
  position: relative;
  overflow: hidden;
  min-height: 132px;
  background:
    radial-gradient(circle at 20% 10%, rgba(214, 168, 71, 0.2), transparent 36%),
    #080706;
}

.account-canvas-feature-card .account-canvas-card-media {
  height: 100%;
  min-height: 210px;
}

.account-canvas-recent-card .account-canvas-card-media {
  aspect-ratio: 16 / 9;
}

.account-canvas-gallery-card .account-canvas-card-media {
  aspect-ratio: 16 / 9;
}

.account-canvas-card-media img,
.account-canvas-card-media video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #080706;
  transition: transform 180ms ease, filter 180ms ease;
}

.account-canvas-gallery-card:hover .account-canvas-card-media img,
.account-canvas-gallery-card:hover .account-canvas-card-media video,
.account-canvas-recent-card:hover .account-canvas-card-media img,
.account-canvas-recent-card:hover .account-canvas-card-media video,
.account-canvas-feature-card:hover .account-canvas-card-media img,
.account-canvas-feature-card:hover .account-canvas-card-media video {
  transform: scale(1.025);
  filter: brightness(1.08);
}

.account-canvas-open-hit {
  position: absolute;
  inset: 0;
  z-index: 1;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.account-canvas-media-kind,
.account-canvas-card-tool {
  position: absolute;
  z-index: 3;
}

.account-canvas-media-kind {
  left: 10px;
  bottom: 10px;
  border-radius: 999px;
  padding: 4px 8px;
  color: #101010;
  background: rgba(245, 210, 131, 0.92);
  font-size: 12px;
  font-weight: 900;
}

.account-canvas-card-tool {
  right: 10px;
  top: 10px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(245, 210, 131, 0.26);
  border-radius: 999px;
  color: #fff7e5;
  background: rgba(7, 6, 4, 0.76);
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 160ms ease, transform 160ms ease, background 160ms ease;
}

.account-canvas-card-media:hover .account-canvas-card-tool,
.account-canvas-card-tool:focus-visible {
  opacity: 1;
  transform: translateY(0);
}

.account-canvas-card-tool:hover,
.account-canvas-card-tool:focus-visible {
  background: rgba(214, 168, 71, 0.24);
  outline: none;
}

.account-canvas-feature-copy {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  display: grid;
  gap: 5px;
  pointer-events: none;
}

.account-canvas-feature-copy strong {
  overflow: hidden;
  color: #fff7e5;
  font-size: 18px;
  line-height: 1.24;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.8);
}

.account-canvas-feature-copy span {
  overflow: hidden;
  color: rgba(255, 235, 183, 0.8);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.72);
}

.account-canvas-feature-card::after {
  position: absolute;
  inset: auto 0 0;
  height: 52%;
  content: "";
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.74));
}

.account-canvas-section {
  display: grid;
  gap: 14px;
}

.account-canvas-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.account-canvas-section-head h2 {
  margin: 0;
  color: #fff7e5;
  font-size: 18px;
  line-height: 1.2;
}

.account-canvas-section-head span {
  color: rgba(245, 210, 131, 0.72);
  font-size: 13px;
  font-weight: 900;
}

.account-canvas-recent-strip {
  display: grid;
  grid-auto-columns: minmax(212px, 264px);
  grid-auto-flow: column;
  gap: 12px;
  overflow-x: auto;
  padding: 2px 0 10px;
  scrollbar-color: rgba(245, 210, 131, 0.38) rgba(255, 255, 255, 0.04);
}

.account-canvas-create-card {
  min-height: 202px;
}

.account-canvas-create-card button,
.account-canvas-create-card a {
  display: grid;
  width: 100%;
  height: 100%;
  min-height: 202px;
  place-items: center;
  align-content: center;
  gap: 8px;
  border: 0;
  color: #fff7e5;
  background:
    radial-gradient(circle at 50% 18%, rgba(245, 210, 131, 0.18), transparent 34%),
    #24211a;
  cursor: pointer;
  text-decoration: none;
}

.account-canvas-create-card span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: #14120e;
  background: #f3c65e;
  font-size: 30px;
  line-height: 1;
}

.account-canvas-create-card strong {
  font-size: 17px;
}

.account-canvas-create-card small {
  color: rgba(255, 247, 229, 0.62);
}

.account-canvas-card-caption,
.account-canvas-gallery-caption {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.account-canvas-card-caption h3,
.account-canvas-gallery-caption strong {
  overflow: hidden;
  margin: 0;
  color: #fff7e5;
  font-size: 14px;
  line-height: 1.34;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-canvas-card-caption > div:first-of-type,
.account-canvas-gallery-caption span {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: rgba(214, 204, 183, 0.74);
  font-size: 12px;
}

.account-canvas-card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.account-canvas-card-actions button,
.account-canvas-disabled-action {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(245, 210, 131, 0.16);
  border-radius: 999px;
  color: rgba(255, 247, 229, 0.88);
  background: rgba(255, 255, 255, 0.055);
  cursor: pointer;
  font-size: 15px;
  font-weight: 900;
  line-height: 1;
}

.account-canvas-card-actions button:hover,
.account-canvas-card-actions button:focus-visible {
  border-color: rgba(245, 210, 131, 0.48);
  color: #14120e;
  background: #f3c65e;
  outline: none;
}

.account-canvas-card-actions button.danger:hover,
.account-canvas-card-actions button.danger:focus-visible {
  border-color: rgba(255, 118, 118, 0.64);
  color: #fff;
  background: #8f2f24;
}

.account-canvas-disabled-action {
  opacity: 0.42;
  cursor: not-allowed;
}

.account-canvas-searchbar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  width: min(720px, 100%);
  min-height: 46px;
  margin: 0 auto;
  border: 1px solid rgba(245, 210, 131, 0.12);
  border-radius: 999px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.07);
}

.account-canvas-searchbar span {
  color: rgba(245, 210, 131, 0.72);
  font-size: 18px;
}

.account-canvas-searchbar input {
  width: 100%;
  border: 0;
  color: #fff7e5;
  background: transparent;
  padding: 0 10px;
  font: inherit;
  font-size: 14px;
  outline: none;
}

.account-canvas-searchbar input::placeholder {
  color: rgba(214, 204, 183, 0.54);
}

.account-canvas-gallery {
  column-count: 4;
  column-gap: 14px;
}

.account-canvas-gallery-card {
  display: inline-block;
  width: 100%;
  margin: 0 0 14px;
  break-inside: avoid;
}

.account-canvas-gallery-card.is-wide .account-canvas-card-media {
  aspect-ratio: 16 / 10;
}

.account-canvas-mini-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.account-canvas-mini-meta span {
  border: 1px solid rgba(245, 210, 131, 0.12);
  border-radius: 999px;
  padding: 3px 7px;
  color: rgba(245, 210, 131, 0.76);
  background: rgba(245, 210, 131, 0.06);
  font-size: 11px;
  font-weight: 900;
}

.account-canvas-empty,
.account-canvas-empty-stage {
  display: grid;
  min-height: 180px;
  place-items: center;
  color: rgba(255, 247, 229, 0.72);
  background:
    radial-gradient(circle at 50% 30%, rgba(214, 168, 71, 0.18), transparent 42%),
    #15130f;
  font-weight: 900;
}

.personal-canvas-grid,
.account-site-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.personal-canvas-grid.compact {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  margin-top: 0;
}

.personal-canvas-card,
.account-site-card,
.credit-product-card,
.model-credit-card {
  overflow: hidden;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  background: rgba(13, 11, 7, 0.82);
  box-shadow: var(--shadow);
}

.personal-canvas-cover {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 10%, rgba(214, 168, 71, 0.24), transparent 42%),
    #090805;
}

.personal-canvas-cover img,
.personal-canvas-cover video,
.account-site-card img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #090805;
}

.personal-canvas-cover video {
  pointer-events: none;
}

.personal-canvas-cover-kind,
.personal-canvas-cover-menu-btn {
  position: absolute;
  z-index: 2;
}

.personal-canvas-cover-kind {
  left: 10px;
  bottom: 10px;
  border: 1px solid rgba(214, 168, 71, 0.35);
  border-radius: 999px;
  background: rgba(7, 6, 4, 0.72);
  color: #f5d283;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 900;
}

.personal-canvas-cover-menu-btn {
  right: 10px;
  top: 10px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(245, 210, 131, 0.34);
  border-radius: 999px;
  background: rgba(8, 7, 5, 0.76);
  color: #ffe6a3;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.personal-canvas-card:hover .personal-canvas-cover-menu-btn,
.personal-canvas-cover-menu-btn:focus-visible {
  opacity: 1;
  transform: translateY(0);
}

.personal-canvas-cover-menu-btn:hover,
.personal-canvas-cover-menu-btn:focus-visible {
  background: rgba(214, 168, 71, 0.24);
}

.personal-canvas-body,
.account-site-card > div {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.canvas-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.canvas-meta-row span,
.credit-cost-row small {
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 999px;
  background: rgba(214, 168, 71, 0.08);
  color: var(--muted);
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
}

.canvas-action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.canvas-action-row .primary-btn,
.canvas-action-row .asset-link,
.credit-product-card .primary-btn,
.model-credit-card .asset-link {
  min-height: 38px;
  padding: 9px 12px;
  font-size: 13px;
}

.muted-link {
  opacity: 0.74;
}

.public-canvas-card small {
  color: rgba(224, 185, 93, 0.78);
  line-height: 1.5;
}

.personal-canvas-cover-menu {
  position: fixed;
  z-index: 80;
  width: min(320px, calc(100vw - 24px));
  padding: 12px;
  border: 1px solid rgba(245, 210, 131, 0.28);
  border-radius: 12px;
  background:
    linear-gradient(145deg, rgba(28, 22, 12, 0.98), rgba(8, 7, 5, 0.96));
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
  color: #fff7e5;
}

.personal-canvas-cover-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.personal-canvas-cover-menu-head strong {
  font-size: 14px;
}

.personal-canvas-cover-menu-head button,
.personal-canvas-cover-auto {
  border: 1px solid rgba(245, 210, 131, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #fff7e5;
  cursor: pointer;
}

.personal-canvas-cover-menu-head button {
  width: 30px;
  height: 30px;
}

.personal-canvas-cover-auto {
  width: 100%;
  min-height: 36px;
  margin-bottom: 10px;
  font-weight: 900;
}

.personal-canvas-cover-auto:hover,
.personal-canvas-cover-auto:focus-visible,
.personal-canvas-cover-choice:hover,
.personal-canvas-cover-choice:focus-visible {
  border-color: rgba(245, 210, 131, 0.52);
  background: rgba(214, 168, 71, 0.16);
}

.personal-canvas-cover-choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  max-height: 250px;
  overflow: auto;
}

.personal-canvas-cover-choice {
  display: grid;
  gap: 6px;
  padding: 6px;
  border: 1px solid rgba(245, 210, 131, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: #fff7e5;
  cursor: pointer;
}

.personal-canvas-cover-choice.is-current {
  border-color: rgba(245, 210, 131, 0.64);
}

.personal-canvas-cover-choice img,
.personal-canvas-cover-choice video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 6px;
  background: #050403;
}

.personal-canvas-cover-choice span,
.personal-canvas-cover-empty {
  overflow: hidden;
  color: rgba(255, 247, 229, 0.78);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.credits-shell {
  display: grid;
  gap: 18px;
}

.credits-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  align-items: stretch;
  gap: 18px;
  border: 1px solid rgba(214, 168, 71, 0.26);
  border-radius: 8px;
  background:
    radial-gradient(circle at 72% 18%, rgba(224, 185, 93, 0.24), transparent 34%),
    linear-gradient(135deg, #090805, #17100a 55%, #231709);
  padding: 22px;
  box-shadow: var(--shadow);
  color: #fff7e5;
}

.credits-hero h2 {
  margin: 8px 0;
  color: #fff7e5;
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1.08;
}

.credits-hero p {
  max-width: 720px;
  color: #e0d1ad;
  line-height: 1.7;
}

.credit-balance-card {
  display: grid;
  align-content: center;
  gap: 10px;
  border: 1px solid rgba(224, 185, 93, 0.3);
  border-radius: 8px;
  background: rgba(255, 247, 229, 0.06);
  padding: 18px;
}

.credit-balance-card span,
.credit-balance-card small {
  color: #d8c490;
}

.credit-balance-card strong {
  color: #f7cd69;
  font-size: clamp(28px, 4vw, 48px);
}

.credit-product-grid,
.model-credit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.credit-product-card,
.model-credit-card {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.credit-product-card strong {
  color: #f0c66a;
  font-size: 30px;
}

.credit-cost-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.credit-cost-row strong {
  color: #f0c66a;
  font-size: 20px;
}

.credit-rules-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 18px;
}

.credit-rule-list,
.credit-ledger-list {
  display: grid;
  gap: 10px;
}

.credit-rule-list details {
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 8px;
  background: rgba(255, 247, 229, 0.04);
  padding: 12px;
}

.credit-rule-list summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 900;
}

.credit-ledger-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 8px;
  background: rgba(214, 168, 71, 0.05);
  padding: 12px;
}

.credit-ledger-row div {
  display: grid;
  gap: 4px;
}

.credit-ledger-row strong {
  color: var(--ink);
}

.credit-ledger-row span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.credit-ledger-row b {
  color: #f0c66a;
  white-space: nowrap;
}

.fusion-mini-dl {
  display: grid;
  gap: 9px;
  margin: 12px 0 0;
}

.fusion-mini-dl div {
  display: grid;
  gap: 3px;
}

.fusion-mini-dl dt {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.fusion-mini-dl dd {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.fusion-table {
  display: grid;
  gap: 8px;
  overflow-x: auto;
}

.fusion-table-head,
.fusion-table-row {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1fr 0.7fr 0.8fr 0.9fr 1.4fr;
  min-width: 980px;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.mapping-table .fusion-table-head,
.mapping-table .fusion-table-row {
  grid-template-columns: 1.6fr 1fr 0.8fr 1fr 1fr 1fr 0.9fr;
}

.fusion-table-head {
  background: rgba(214, 168, 71, 0.16);
  color: var(--accent);
  font-weight: 800;
}

.fusion-table-row strong {
  color: var(--ink);
}

.fusion-table-row span {
  color: var(--muted);
  line-height: 1.45;
}

.production-timeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.production-timeline article > span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: #d6a847;
  color: #11100d;
  font-size: 16px;
}

.production-timeline article {
  display: grid;
  align-content: start;
  gap: 10px;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.production-timeline article:hover,
.production-timeline article:focus-visible {
  border-color: rgba(214, 168, 71, 0.5);
  background: rgba(214, 168, 71, 0.11);
  outline: none;
  transform: translateY(-1px);
}

.production-timeline .asset-link {
  width: fit-content;
  margin-top: 4px;
}

.fusion-count-panel {
  display: grid;
  place-items: center;
  min-height: 170px;
  text-align: center;
}

.fusion-count-panel strong {
  display: block;
  font-size: 44px;
}

.fusion-count-panel span {
  color: #d4c196;
}

:root[data-theme="light"] .fusion-hero.compact {
  background: #fffaf0;
  color: #17140e;
}

:root[data-theme="light"] .fusion-hero h2,
:root[data-theme="light"] .fusion-hero p {
  color: #17140e;
}

:root[data-theme="light"] .fusion-hero p {
  color: #746f62;
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

  .fusion-portal-hero {
    aspect-ratio: auto;
    min-height: 680px;
  }

  .fusion-hero-copy {
    width: 100%;
    padding: 28px;
    justify-content: flex-start;
  }

  .fusion-hero-console {
    left: 28px;
    right: 28px;
    width: auto;
  }

  .fusion-hero.compact {
    grid-template-columns: 1fr;
  }
}

.resource-library-pack {
  display: grid;
  gap: 16px;
}

.resource-board-head,
.resource-shelf {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.resource-board-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  padding: 20px 22px;
}

.resource-board-head h2,
.resource-shelf-head h2 {
  margin: 4px 0 6px;
  color: var(--ink);
  font-size: 28px;
  line-height: 1.2;
}

.resource-board-head p,
.resource-shelf-head p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.resource-mini-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding: 0 2px;
}

.resource-mini-toolbar span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 11px;
  color: var(--muted);
  background: var(--panel);
  font-size: 13px;
}

.resource-shelf {
  padding: 18px;
}

.resource-shelf-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.resource-shelf-head .asset-link,
.resource-board-head .asset-link {
  flex: 0 0 auto;
  margin-top: 4px;
}

.resource-thumb-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.resource-thumb-card {
  position: relative;
  display: block;
  overflow: hidden;
  min-height: 0;
  aspect-ratio: 4 / 5;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #11100d;
  color: #fff;
  text-decoration: none;
  isolation: isolate;
}

.resource-thumb-card::after {
  content: "";
  position: absolute;
  inset: 45% 0 0;
  z-index: 1;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72));
}

.resource-thumb-card img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 0.22s ease;
}

.resource-thumb-card:hover img,
.resource-thumb-card:focus-visible img {
  transform: scale(1.025);
}

.resource-thumb-card span,
.resource-thumb-card strong {
  position: absolute;
  left: 12px;
  right: 12px;
  z-index: 2;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
}

.resource-thumb-card span {
  bottom: 42px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 800;
}

.resource-thumb-card strong {
  bottom: 14px;
  display: -webkit-box;
  overflow: hidden;
  color: #fff;
  font-size: 15px;
  line-height: 1.25;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.resource-library-intro {
  max-width: 980px;
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.resource-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.resource-summary-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: color-mix(in srgb, var(--panel) 88%, var(--gold));
}

.resource-summary-grid strong {
  display: block;
  color: var(--ink);
  font-size: 22px;
}

.resource-summary-grid span {
  color: var(--muted);
  font-size: 13px;
}

.resource-category-strip,
.resource-pack-actions,
.resource-pattern-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.resource-pattern-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.resource-pattern-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.resource-pattern-image {
  display: block;
  aspect-ratio: 1086 / 1448;
  background: #11100d;
}

.resource-pattern-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.resource-pattern-body {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.resource-pattern-kicker {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.resource-pattern-body h3 {
  margin: 0;
  font-size: 19px;
}

.resource-pattern-body p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.resource-pattern-body p strong {
  color: var(--ink);
}

.resource-pattern-en {
  font-size: 12px;
}

@media (max-width: 860px) {
  .resource-board-head,
  .resource-shelf-head {
    display: grid;
  }

  .resource-thumb-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .resource-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .resource-pattern-grid {
    grid-template-columns: 1fr;
  }
}

/* Mobile-only experience layer. Desktop/tablet layouts above 720px are untouched. */
@media (max-width: 720px) {
  html,
  body {
    width: 100%;
    overflow-x: hidden;
  }

  body:not(.login-index-mode) .app-shell {
    display: block;
    min-height: 100dvh;
  }

  body:not(.login-index-mode) .sidebar {
    position: sticky;
    top: 0;
    z-index: 60;
    gap: 10px;
    padding: max(10px, env(safe-area-inset-top)) 14px 8px;
    border-right: 0;
    border-bottom: 1px solid rgba(214, 168, 71, 0.2);
    background: rgba(9, 8, 5, 0.96);
    backdrop-filter: blur(14px);
  }

  body:not(.login-index-mode) .brand {
    gap: 10px;
    padding-bottom: 10px;
  }

  body:not(.login-index-mode) .brand-mark {
    width: 40px;
    height: 40px;
    flex: 0 0 auto;
  }

  body:not(.login-index-mode) .brand strong {
    font-size: 16px;
    line-height: 1.2;
  }

  body:not(.login-index-mode) .brand span {
    margin-top: 2px;
    font-size: 12px;
  }

  body:not(.login-index-mode) .nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    padding: 1px 2px 8px;
    margin: 0 -2px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  body:not(.login-index-mode) .nav::-webkit-scrollbar {
    display: none;
  }

  body:not(.login-index-mode) .nav-item {
    flex: 0 0 auto;
    min-height: 38px;
    scroll-snap-align: start;
    border: 1px solid rgba(214, 168, 71, 0.22);
    border-radius: 999px;
    padding: 8px 14px;
    white-space: nowrap;
    text-align: center;
    font-size: 14px;
    line-height: 1.2;
    background: rgba(255, 255, 255, 0.04);
  }

  body:not(.login-index-mode) .nav-item.active {
    border-color: rgba(214, 168, 71, 0.7);
    background: rgba(214, 168, 71, 0.22);
  }

  body:not(.login-index-mode) .cost-rule {
    display: none;
  }

  body:not(.login-index-mode) .main {
    padding: 14px 14px calc(84px + env(safe-area-inset-bottom));
  }

  .topbar {
    display: grid;
    gap: 10px;
    margin-bottom: 14px;
    padding-bottom: 12px;
  }

  .topbar > div:first-child {
    min-width: 0;
  }

  .topbar .eyebrow {
    display: none;
  }

  .topbar h1 {
    max-width: 100%;
    overflow: hidden;
    font-size: 24px;
    line-height: 1.22;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .top-actions {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    width: 100%;
  }

  .top-logo-home {
    order: 1;
    width: 38px;
    height: 38px;
  }

  .auth-actions {
    order: 2;
    flex: 1 1 auto;
    min-width: 0;
    gap: 6px;
  }

  .auth-actions .auth-btn {
    min-height: 38px;
    flex: 0 1 auto;
    max-width: 48%;
    overflow: hidden;
    padding: 8px 11px;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  #refresh-btn {
    order: 3;
    min-height: 38px;
    padding: 8px 10px;
    font-size: 13px;
  }

  #global-search {
    order: 4;
    width: 100%;
    min-height: 42px;
    flex: 0 0 100%;
  }

  .guest-permission-notice {
    margin-bottom: 12px;
    padding: 10px 12px;
    gap: 5px;
  }

  .guest-permission-notice strong {
    width: 100%;
    font-size: 15px;
  }

  .guest-permission-notice span {
    font-size: 13px;
    line-height: 1.5;
  }

  body.login-index-mode .guest-permission-notice {
    display: none;
  }

  body.login-index-mode {
    min-height: 100dvh;
    overflow: auto;
  }

  body.login-index-mode .main,
  body.login-index-mode .view-root {
    min-height: 100dvh;
  }

  .login-index-page {
    min-height: 100dvh;
    display: grid;
    grid-template-rows: auto 1fr;
    align-items: start;
    justify-items: stretch;
    gap: 14px;
    padding: max(14px, env(safe-area-inset-top)) 14px max(18px, env(safe-area-inset-bottom));
    background:
      radial-gradient(circle at 82% 0%, rgba(240, 154, 60, 0.16), transparent 34%),
      linear-gradient(180deg, #050914 0%, #070a10 48%, #090805 100%);
  }

  .login-hero {
    position: relative;
    min-height: 0;
    overflow: hidden;
    border: 1px solid rgba(255, 231, 170, 0.16);
    border-radius: 8px;
    background: rgba(2, 8, 18, 0.72);
  }

  .login-hero > img,
  .login-hero-shade {
    display: none;
  }

  .login-hero-copy {
    min-height: 0;
    width: 100%;
    align-content: start;
    gap: 8px;
    padding: 14px;
  }

  .login-hero-copy .eyebrow {
    margin-top: 2px;
    font-size: 11px;
  }

  .login-hero-copy p:not(.eyebrow) {
    max-width: none;
    font-size: 13px;
    line-height: 1.45;
  }

  .login-index-brand img {
    width: 38px;
    height: 38px;
  }

  .login-index-brand strong {
    font-size: 15px;
    line-height: 1.2;
  }

  .login-index-brand span {
    font-size: 12px;
  }

  .login-panel {
    width: 100%;
    align-items: start;
    margin: 0;
    padding: 16px;
  }

  .login-panel-inner {
    gap: 12px;
  }

  .login-panel-head h2 {
    font-size: 22px;
    line-height: 1.22;
  }

  .auth-tab,
  .login-index-card .primary-btn {
    min-height: 44px;
  }

  .login-index-card input {
    min-height: 46px;
    font-size: 16px;
  }

  .login-index-card p:last-child {
    font-size: 13px;
    line-height: 1.55;
  }

  .login-legal-links {
    gap: 8px 12px;
  }

  .login-legal-links a {
    font-size: 12px;
  }

  .view-root {
    gap: 16px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .view-root > *,
  .home-section,
  .home-banner,
  .community-hero,
  .project-source-strip,
  .masonry-feed,
  .home-card-grid,
  .ops-gateway-grid,
  .reading-layout,
  .prompt-reading-layout,
  .community-reading-grid,
  .case-reading-shell,
  .knowledge-hero,
  .resource-library-pack {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .panel,
  .home-top-info,
  .workflow-gateway-section,
  .community-hero,
  .project-source-strip,
  .workbench-entry-panel,
  .workbench-config-panel,
  .resource-board-head,
  .resource-shelf {
    padding: 16px;
  }

  .panel-header,
  .feed-head,
  .resource-board-head,
  .resource-shelf-head,
  .prompt-content-head,
  .prompt-section-head {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
  }

  .home-mode .view-root {
    gap: 24px;
  }

  .home-section {
    content-visibility: visible;
    contain-intrinsic-size: auto;
  }

  .home-top-copy h2,
  .student-hero h2,
  .community-hero h2 {
    font-size: clamp(28px, 8vw, 34px);
    line-height: 1.08;
  }

  .home-top-copy p,
  .community-hero p:not(.eyebrow),
  .feed-head p {
    font-size: 14px;
    line-height: 1.6;
  }

  .quick-entry-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-entry {
    min-height: 40px;
    padding: 9px 10px;
    font-size: 13px;
  }

  .banner-slide,
  .banner-slide .banner-panorama,
  .banner-slide .portal-placeholder {
    height: 420px;
    min-height: 420px;
  }

  .banner-slide .banner-panorama {
    opacity: 1;
    filter: saturate(1.2) contrast(1.08) brightness(1.14);
  }

  .banner-shade {
    background:
      linear-gradient(180deg, rgba(3, 3, 4, 0.06), rgba(3, 3, 4, 0.08) 48%, rgba(3, 3, 4, 0.54)),
      linear-gradient(90deg, rgba(3, 3, 4, 0.18), rgba(3, 3, 4, 0.04));
  }

  .banner-copy {
    left: 14px;
    right: 14px;
    top: auto;
    bottom: 16px;
    width: auto;
    padding: 11px 12px 12px;
  }

  .banner-copy h2 {
    max-width: none;
    margin: 7px 0 6px;
    font-size: clamp(25px, 7vw, 31px);
    line-height: 1.05;
  }

  .banner-copy p {
    margin-bottom: 12px;
    font-size: 13px;
    line-height: 1.55;
    -webkit-line-clamp: 1;
  }

  .banner-slide-zhangdao-method .banner-copy {
    top: 14px;
    bottom: auto;
    right: auto;
    width: min(280px, calc(100% - 28px));
  }

  .banner-slide-zhangdao-method .banner-copy p {
    -webkit-line-clamp: 1;
  }

  .banner-book-intro {
    left: 14px;
    right: auto;
    top: 128px;
    width: min(330px, calc(100% - 28px));
    gap: 8px;
    padding: 14px;
    border-left-width: 3px;
    border-right-width: 1px;
    border-radius: 13px;
  }

  .banner-book-intro strong {
    max-width: 12ch;
    font-size: clamp(25px, 7.5vw, 34px);
  }

  .banner-book-intro p {
    max-width: none;
    font-size: 13px;
    line-height: 1.52;
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .banner-book-intro span,
  .banner-book-intro em {
    font-size: 11px;
  }

  .hero-btn,
  .primary-btn,
  .asset-link,
  .copy-btn {
    min-height: 42px;
  }

  .home-card-grid,
  .ops-gateway-grid,
  .knowledge-source-grid,
  .knowledge-doc-grid,
  .resource-summary-grid,
  .resource-thumb-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .portal-card {
    aspect-ratio: 4 / 5;
  }

  .portal-body {
    padding: 40px 10px 10px;
  }

  .portal-body h3 {
    font-size: 14px;
    line-height: 1.35;
  }

  .portal-body p,
  .portal-meta {
    display: none;
  }

  .ops-gateway-card {
    min-height: 240px;
  }

  .ops-gateway-card > div {
    left: 14px;
    right: 14px;
    bottom: 14px;
  }

  .ops-card-index {
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
  }

  .masonry-feed {
    column-count: 1;
    column-gap: 0;
  }

  .masonry-card,
  .community-card,
  .project-community-card {
    max-width: 100%;
    min-width: 0;
    margin-bottom: 14px;
    break-inside: avoid;
  }

  .masonry-card *,
  .community-card *,
  .project-community-card * {
    min-width: 0;
  }

  .masonry-card img {
    max-height: none;
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
  }

  .masonry-card.tall img {
    aspect-ratio: auto;
  }

  .community-image-placeholder,
  .community-image-placeholder.project-placeholder {
    min-height: 150px;
    font-size: 22px;
  }

  .community-image-placeholder.prompt-placeholder {
    min-height: 112px;
  }

  .project-placeholder span {
    font-size: 40px;
  }

  .masonry-body,
  .project-community-card .masonry-body {
    padding: 11px;
  }

  .creator-line {
    gap: 6px;
    font-size: 12px;
  }

  .creator-line small {
    max-width: 46%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .masonry-body h3,
  .project-community-card h3 {
    display: -webkit-box;
    margin: 8px 0 6px;
    overflow: hidden;
    font-size: 15px;
    line-height: 1.35;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .masonry-body p,
  .project-community-card p {
    display: -webkit-box;
    overflow: hidden;
    font-size: 12.5px;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
  }

  .meta-row {
    max-height: 56px;
    gap: 5px;
    overflow: hidden;
    margin-top: 8px;
  }

  .pill {
    min-height: 22px;
    max-width: 100%;
    overflow: hidden;
    padding: 2px 7px;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .project-card-action {
    margin-top: 9px;
    font-size: 12px;
  }

  .category-row {
    margin: 0 -14px;
    padding: 0 14px 6px;
    scroll-padding-inline: 14px;
  }

  .category-chip {
    min-height: 38px;
    padding: 8px 11px;
    font-size: 13px;
  }

  .detail-overlay {
    align-items: end;
    place-items: end stretch;
    padding: 0;
  }

  .detail-dialog {
    width: 100%;
    max-height: 100dvh;
    grid-template-columns: 1fr;
    grid-template-rows: minmax(180px, 42dvh) minmax(0, 1fr);
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 14px 14px 0 0;
  }

  .detail-close {
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
  }

  .detail-media {
    min-height: 180px;
  }

  .detail-media > img,
  .tutorial-video-player {
    max-height: 42dvh;
  }

  .detail-placeholder {
    min-height: 220px;
    font-size: 32px;
  }

  .detail-thumbs {
    padding: 8px;
  }

  .detail-thumbs img {
    width: 72px;
    height: 48px;
  }

  .detail-content {
    padding: 16px;
  }

  .detail-content h2 {
    margin-top: 8px;
    font-size: 23px;
  }

  .reading-layout,
  .prompt-reading-layout,
  .community-reading-grid,
  .case-reading-hero,
  .project-reading-hero,
  .fusion-hero.compact {
    grid-template-columns: 1fr;
  }

  .reading-hero,
  .community-reading-hero,
  .prompt-reading-hero,
  .knowledge-hero {
    padding: 16px;
  }

  .reading-hero h1,
  .community-reading-copy h1 {
    font-size: clamp(28px, 8.5vw, 38px);
    line-height: 1.12;
  }

  .reading-article {
    font-size: 16px;
    line-height: 1.82;
  }

  .prompt-code-wrap pre,
  .prompt-content-block pre,
  .reading-code-block pre {
    max-width: 100%;
    padding: 44px 14px 16px;
    font-size: 13px;
    line-height: 1.7;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .reading-image-grid,
  .case-gallery-grid,
  .resource-pattern-grid {
    grid-template-columns: 1fr;
  }

  .reading-image-grid img,
  .prompt-media-section .reading-image-grid img {
    max-height: 70dvh;
  }

  .reading-image-grid figcaption {
    align-items: flex-start;
    flex-direction: column;
  }

  .settings-dock {
    right: 14px;
    bottom: calc(14px + env(safe-area-inset-bottom));
  }

  .theme-toggle {
    right: 68px;
    bottom: calc(14px + env(safe-area-inset-bottom));
  }

  .settings-toggle,
  .theme-toggle {
    width: 44px;
    height: 44px;
  }
}

@media (max-width: 430px) {
  .home-card-grid,
  .ops-gateway-grid,
  .resource-summary-grid,
  .resource-thumb-grid {
    gap: 10px;
  }

  .portal-card {
    aspect-ratio: 3 / 4;
  }

  .auth-actions .auth-btn {
    max-width: 50%;
  }

  .admin-form-grid {
    grid-template-columns: 1fr;
  }

  .admin-list-row,
  .admin-list-row.event-row,
  .admin-list-row.entry-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1420px) {
  .workbench-preview-masonry {
    column-count: 3;
  }
}

@media (max-width: 980px) {
  .workbench-preview-masonry {
    column-count: 2;
  }

  .workbench-gallery-panel {
    min-height: auto;
  }
}

@media (max-width: 620px) {
  .workbench-preview-masonry {
    column-count: 1;
  }

  .workbench-preview-overlay strong {
    font-size: 24px;
  }
}

@media (max-width: 1080px) {
  body.clean-ui:not(.login-index-mode) .app-shell {
    display: block;
    grid-template-columns: 1fr;
  }

  body.clean-ui:not(.login-index-mode) .sidebar {
    position: sticky;
    top: 0;
    z-index: 70;
    width: auto;
    height: auto;
    gap: 8px;
    overflow: hidden;
    padding: max(10px, env(safe-area-inset-top)) 12px 8px;
    border-right: 0;
    border-bottom: 1px solid rgba(214, 168, 71, 0.16);
    background: rgba(9, 8, 5, 0.96);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(16px);
  }

  body.clean-ui:not(.login-index-mode) .sidebar:hover,
  body.clean-ui:not(.login-index-mode) .sidebar:focus-within {
    width: auto;
    overflow: hidden;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
  }

  body.clean-ui:not(.login-index-mode) .brand {
    min-height: 42px;
    justify-content: flex-start;
    padding-bottom: 6px;
  }

  body.clean-ui:not(.login-index-mode) .brand > div:last-child,
  body.clean-ui:not(.login-index-mode) .sidebar:hover .brand > div:last-child,
  body.clean-ui:not(.login-index-mode) .sidebar:focus-within .brand > div:last-child {
    width: auto;
    max-width: calc(100vw - 86px);
    opacity: 1;
  }

  body.clean-ui:not(.login-index-mode) .brand span {
    display: none;
  }

  body.clean-ui:not(.login-index-mode) .brand-mark {
    width: 38px;
    height: 38px;
  }

  body.clean-ui:not(.login-index-mode) .nav {
    display: flex;
    grid-template-columns: none;
    gap: 8px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    padding: 0 2px 6px;
    margin: 0 -2px;
    scrollbar-width: none;
  }

  body.clean-ui:not(.login-index-mode) .nav::-webkit-scrollbar {
    display: none;
  }

  body.clean-ui:not(.login-index-mode) .nav-item,
  body.clean-ui:not(.login-index-mode) .sidebar:hover .nav-item,
  body.clean-ui:not(.login-index-mode) .sidebar:focus-within .nav-item {
    width: 46px;
    min-width: 46px;
    min-height: 46px;
    flex: 0 0 46px;
    justify-content: center;
    padding: 5px;
    border-radius: 999px;
    font-size: 0;
  }

  body.clean-ui:not(.login-index-mode) .nav-item::before {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    border-radius: 50%;
  }

  body.clean-ui:not(.login-index-mode) .cost-rule {
    display: none;
  }

  body.clean-ui:not(.login-index-mode) .main {
    padding: 14px 14px calc(80px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 720px) {
  body.clean-ui:not(.login-index-mode) .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-height: 50px;
    padding: 8px;
    border-radius: 10px;
  }

  body.clean-ui:not(.login-index-mode) .topbar h1 {
    font-size: 20px;
  }

  body.clean-ui:not(.login-index-mode) .top-actions {
    justify-content: flex-end;
    gap: 6px;
  }

  body.clean-ui:not(.login-index-mode) .auth-actions {
    flex: 0 0 auto;
    gap: 5px;
  }

  body.clean-ui:not(.login-index-mode) .top-finance-pill {
    height: 38px;
    min-width: 38px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
  }

  body.clean-ui:not(.login-index-mode) .top-finance-pill.is-member {
    max-width: 72px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  body.clean-ui:not(.login-index-mode) .top-avatar-button {
    width: 38px;
    min-width: 38px;
    height: 38px;
    padding: 2px;
    border-radius: 50%;
  }

  body.clean-ui:not(.login-index-mode) .top-avatar-media {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  body.clean-ui:not(.login-index-mode) .top-avatar-copy {
    display: none;
  }

  body.clean-ui:not(.login-index-mode) .top-account-wrap {
    position: static;
  }

  body.clean-ui:not(.login-index-mode) .top-account-menu {
    position: fixed;
    top: 64px;
    right: 10px;
    left: 10px;
    z-index: 680;
    width: auto;
    max-height: calc(100dvh - 86px);
    border-radius: 14px;
    padding: 14px;
  }

  body.clean-ui:not(.login-index-mode) .top-account-profile {
    grid-template-columns: 46px minmax(0, 1fr);
  }

  body.clean-ui:not(.login-index-mode) .top-account-profile button {
    grid-column: 1 / -1;
    width: 100%;
  }

  body.clean-ui:not(.login-index-mode) .top-logout-button {
    width: 38px;
    min-width: 38px;
    height: 38px;
    overflow: hidden;
    padding: 0;
    border-radius: 50%;
    color: transparent;
  }

  body.clean-ui:not(.login-index-mode) .top-logout-button::before {
    content: "×";
    color: #fff1d0;
    font-size: 18px;
    font-weight: 900;
  }

  body.clean-ui:not(.login-index-mode) .auth-actions .auth-btn {
    width: 38px;
    max-width: 38px;
    height: 38px;
    min-height: 38px;
    overflow: hidden;
    padding: 0;
    border-radius: 50%;
    color: transparent;
  }

  body.clean-ui:not(.login-index-mode) .auth-actions .auth-btn::before {
    color: #11100d;
    font-size: 15px;
    font-weight: 900;
  }

  body.clean-ui:not(.login-index-mode) .auth-actions .auth-btn.register::before {
    content: "+";
  }

  body.clean-ui:not(.login-index-mode) .auth-actions .auth-btn:not(.register)::before {
    content: "↗";
  }

  body.clean-ui:not(.login-index-mode) #refresh-btn.icon-refresh-btn {
    width: 38px;
    min-width: 38px;
    height: 38px;
  }

  body.clean-ui:not(.login-index-mode) #global-search {
    order: 5;
    width: 100%;
    min-height: 40px;
    flex: 0 0 100%;
  }

  body.clean-ui:not(.login-index-mode) .guest-permission-notice,
  body.clean-ui:not(.login-index-mode) .registered-permission-notice {
    border-radius: 999px;
  }

  body.clean-ui:not(.login-index-mode) .timeline span,
  body.clean-ui:not(.login-index-mode) .admin-list-row small,
  body.clean-ui:not(.login-index-mode) .status-row small {
    display: none;
  }
}

.workbench-entry-grid.channels {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.workbench-reserved-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.workflow-channel-card {
  min-height: 210px;
  gap: 12px;
}

.workflow-channel-card.main-channel h3 {
  font-size: 24px;
}

.workflow-channel-card.main-channel p:not(.eyebrow) {
  font-size: 14px;
  line-height: 1.58;
}

.workflow-channel-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.workflow-channel-tags span {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(214, 168, 71, 0.22);
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--accent);
  background: rgba(214, 168, 71, 0.08);
  font-size: 12px;
  font-weight: 900;
}

.compute-entry {
  border-color: rgba(76, 132, 109, 0.3);
  background: color-mix(in srgb, #fbfcfa 88%, rgba(76, 132, 109, 0.16));
}

.beta-entry {
  border-color: rgba(49, 95, 159, 0.3);
  background: color-mix(in srgb, #fbfcfa 88%, rgba(49, 95, 159, 0.16));
}

.reserved-channel {
  min-height: 150px;
  border-style: dashed;
  border-color: rgba(23, 20, 14, 0.16);
  background: color-mix(in srgb, var(--paper) 92%, #d8d8d8);
  opacity: 0.74;
}

.reserved-channel::before {
  opacity: 0.32;
  filter: grayscale(1);
}

.reserved-channel .primary-btn:disabled {
  cursor: not-allowed;
  opacity: 0.54;
  filter: grayscale(1);
}

.libtv-native-shell {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(280px, 0.72fr) minmax(360px, 1fr);
  align-items: stretch;
  gap: clamp(18px, 3vw, 32px);
  min-height: min(68vh, 660px);
  padding: clamp(22px, 4vw, 44px);
  border-color: rgba(214, 168, 71, 0.28);
  background:
    radial-gradient(circle at 74% 30%, rgba(214, 168, 71, 0.24), transparent 28%),
    radial-gradient(circle at 18% 18%, rgba(43, 113, 171, 0.28), transparent 34%),
    linear-gradient(135deg, #06070a 0%, #11100d 46%, #1a1207 100%);
  color: #fff8e3;
}

.libtv-native-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.12), transparent 22%, transparent 74%, rgba(214, 168, 71, 0.1)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.06) 0 1px, transparent 1px 42px);
  mask-image: radial-gradient(circle at 70% 44%, black, transparent 74%);
  opacity: 0.4;
}

.libtv-beta-denied {
  grid-template-columns: minmax(0, 720px);
  align-content: center;
}

.libtv-native-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
}

.libtv-native-copy h2 {
  max-width: 9em;
  margin: 0;
  color: #fff8e3;
  font-size: clamp(34px, 5vw, 72px);
  line-height: 1.02;
}

.libtv-native-copy p:not(.eyebrow) {
  max-width: 34em;
  margin: 0;
  color: rgba(255, 248, 227, 0.76);
  font-size: 17px;
  line-height: 1.72;
}

.libtv-native-preview {
  position: relative;
  z-index: 1;
  overflow: hidden;
  min-height: 440px;
  border: 1px solid rgba(214, 168, 71, 0.22);
  border-radius: 18px;
  background:
    radial-gradient(circle at 56% 42%, rgba(64, 145, 216, 0.24), transparent 22%),
    radial-gradient(circle at 76% 70%, rgba(214, 168, 71, 0.2), transparent 24%),
    linear-gradient(135deg, rgba(4, 5, 8, 0.96), rgba(16, 17, 19, 0.86));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 28px 70px rgba(0, 0, 0, 0.38);
}

.libtv-native-mask {
  position: absolute;
  top: 16px;
  left: 16px;
  right: 16px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  padding: 0 18px;
  border: 1px solid rgba(214, 168, 71, 0.28);
  border-radius: 15px;
  background: linear-gradient(90deg, rgba(8, 8, 8, 0.96), rgba(25, 20, 12, 0.94));
  color: #fff7dd;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.32);
}

.libtv-native-mask span {
  color: rgba(255, 247, 221, 0.64);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.libtv-native-mask strong {
  font-size: 15px;
}

.libtv-native-canvas-grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.28;
}

.libtv-native-node {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(36, 37, 39, 0.96), rgba(14, 15, 17, 0.94));
  box-shadow: 0 24px 62px rgba(0, 0, 0, 0.42);
}

.libtv-native-node::before {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(214, 168, 71, 0.22), transparent),
    radial-gradient(circle at 70% 30%, rgba(54, 139, 226, 0.32), transparent 36%);
}

.libtv-native-node.node-a {
  left: 9%;
  top: 29%;
  width: 44%;
  height: 31%;
}

.libtv-native-node.node-b {
  right: 8%;
  top: 36%;
  width: 34%;
  height: 24%;
}

.libtv-native-node.node-c {
  left: 40%;
  bottom: 13%;
  width: 36%;
  height: 22%;
}

.libtv-native-rail {
  position: absolute;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(92, 171, 255, 0.9), rgba(214, 168, 71, 0.74), transparent);
  transform-origin: left center;
  opacity: 0.72;
}

.libtv-native-rail.rail-a {
  left: 49%;
  top: 45%;
  width: 34%;
  transform: rotate(-6deg);
}

.libtv-native-rail.rail-b {
  left: 38%;
  top: 56%;
  width: 38%;
  transform: rotate(30deg);
}

.libtv-native-rail.rail-c {
  left: 52%;
  top: 62%;
  width: 28%;
  transform: rotate(-33deg);
}

.libtv-native-caption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  background: rgba(8, 9, 11, 0.78);
  backdrop-filter: blur(18px);
}

.libtv-native-caption strong,
.libtv-native-caption span {
  display: block;
}

.libtv-native-caption span {
  color: rgba(255, 248, 227, 0.62);
  font-size: 13px;
  font-weight: 800;
}

.compute-platform-shell {
  display: grid;
  gap: 18px;
}

.compute-platform-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px;
  min-height: 230px;
  padding: clamp(22px, 3vw, 34px);
  border-color: rgba(214, 168, 71, 0.28);
  background:
    radial-gradient(circle at 78% 28%, rgba(214, 168, 71, 0.26), transparent 30%),
    radial-gradient(circle at 16% 18%, rgba(49, 95, 159, 0.34), transparent 34%),
    linear-gradient(135deg, #090a0d, #17110a 55%, #0a0b0f);
  color: #fff7dd;
}

.compute-platform-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 70% 50%, black, transparent 72%);
  opacity: 0.35;
}

.compute-platform-hero > * {
  position: relative;
  z-index: 1;
}

.compute-platform-hero h2 {
  max-width: 780px;
  margin: 6px 0 0;
  font-size: clamp(34px, 5vw, 68px);
  line-height: 1.02;
}

.compute-platform-hero p:not(.eyebrow) {
  max-width: 760px;
  margin: 14px 0 0;
  color: rgba(255, 247, 221, 0.74);
  font-size: 17px;
  line-height: 1.68;
}

.compute-hero-actions,
.compute-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.compute-provider-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.compute-provider-card {
  display: grid;
  gap: 14px;
  align-content: space-between;
  min-height: 250px;
  border: 1px solid rgba(214, 168, 71, 0.18);
  border-radius: 10px;
  padding: 16px;
  background:
    radial-gradient(circle at 92% 8%, rgba(214, 168, 71, 0.16), transparent 34%),
    linear-gradient(160deg, rgba(20, 18, 14, 0.98), rgba(11, 12, 16, 0.94));
  color: #fff7dd;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.18);
}

.compute-provider-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: rgba(255, 247, 221, 0.66);
  font-size: 12px;
  font-weight: 900;
}

.compute-provider-top strong {
  color: var(--gold);
  font-size: 14px;
}

.compute-provider-card h3 {
  margin: 0;
  font-size: 21px;
  line-height: 1.25;
}

.compute-provider-models {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.compute-provider-models span {
  border: 1px solid rgba(255, 247, 221, 0.14);
  border-radius: 999px;
  padding: 5px 9px;
  color: rgba(255, 247, 221, 0.76);
  background: rgba(255, 255, 255, 0.06);
  font-size: 12px;
  font-weight: 900;
}

.compute-provider-card .status-list > div {
  border-color: rgba(255, 247, 221, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.compute-provider-card .status-list span {
  color: rgba(255, 247, 221, 0.52);
}

.compute-provider-card .status-list strong {
  color: rgba(255, 247, 221, 0.86);
}

.compute-card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

.compute-card-actions .asset-link {
  justify-content: center;
  min-height: 38px;
  padding-inline: 8px;
  font-size: 12px;
}

.compute-live-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  margin-top: 10px;
  padding: 8px 12px;
  border: 1px solid rgba(214, 174, 96, 0.36);
  border-radius: 999px;
  background: rgba(10, 10, 12, 0.48);
  color: rgba(248, 236, 205, 0.9);
  font-size: 13px;
  font-weight: 850;
}

.compute-live-toggle input {
  accent-color: #d6ae60;
}

.compute-config-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.55fr);
  gap: 16px;
  align-items: start;
}

.compute-config-form,
.compute-policy-panel {
  border-color: rgba(214, 168, 71, 0.18);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 251, 240, 0.94)),
    var(--paper);
}

.compute-form-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.compute-form-head h3 {
  margin: 3px 0 0;
  font-size: 26px;
}

.compute-form-head > span {
  border: 1px solid rgba(214, 168, 71, 0.26);
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--accent);
  background: rgba(214, 168, 71, 0.08);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.compute-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.compute-form-grid.single-row {
  grid-template-columns: 1fr;
  margin-top: 12px;
}

.compute-form-grid label,
.compute-model-picker label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.compute-form-grid input,
.compute-form-grid select,
.compute-form-grid textarea {
  width: 100%;
  border: 1px solid rgba(23, 20, 14, 0.16);
  border-radius: 10px;
  padding: 11px 12px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  font: inherit;
  font-size: 14px;
  outline: none;
}

.compute-form-grid textarea {
  min-height: 94px;
  resize: vertical;
  line-height: 1.55;
}

.compute-form-grid .wide {
  grid-column: 1 / -1;
}

.compute-model-picker {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0 0;
  border: 1px solid rgba(23, 20, 14, 0.12);
  border-radius: 12px;
  padding: 14px;
}

.compute-model-picker legend {
  padding: 0 8px;
  color: var(--ink);
  font-weight: 900;
}

.compute-model-picker label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  border: 1px solid rgba(214, 168, 71, 0.16);
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(214, 168, 71, 0.06);
  color: var(--ink);
}

.compute-task-tester {
  display: grid;
  gap: 12px;
  margin: 16px 0 0;
  border: 1px solid rgba(23, 20, 14, 0.12);
  border-radius: 12px;
  padding: 14px;
  background: rgba(23, 20, 14, 0.03);
}

.compute-task-tester legend {
  padding: 0 8px;
  color: var(--ink);
  font-weight: 900;
}

.compute-payload {
  overflow: auto;
  max-height: 280px;
  margin: 0;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 12px;
  padding: 14px;
  background: #0a0b0e;
  color: #fff7dd;
  font-size: 12px;
  line-height: 1.62;
  white-space: pre;
}

.compute-action-row {
  margin-top: 14px;
}

.compute-result {
  margin-top: 14px;
  border: 1px solid rgba(23, 20, 14, 0.12);
  border-radius: 10px;
  padding: 12px 13px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.68);
  font-weight: 800;
  line-height: 1.6;
}

.compute-result.success {
  border-color: rgba(76, 132, 109, 0.28);
  color: #2f6e56;
  background: rgba(76, 132, 109, 0.1);
}

.compute-result.warning {
  border-color: rgba(181, 98, 37, 0.28);
  color: #9a4f1c;
  background: rgba(181, 98, 37, 0.1);
}

.compute-route-stack {
  display: grid;
  gap: 8px;
}

.compute-safety-note {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  border: 1px solid rgba(214, 168, 71, 0.2);
  border-radius: 12px;
  padding: 13px;
  background: rgba(214, 168, 71, 0.07);
}

.compute-safety-note strong,
.compute-saved-list h4 {
  color: var(--ink);
}

.compute-safety-note span {
  color: var(--muted);
  line-height: 1.62;
  font-weight: 800;
}

.compute-saved-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.compute-saved-list h4 {
  margin: 0;
  font-size: 18px;
}

.compute-saved-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(23, 20, 14, 0.1);
  border-radius: 10px;
  padding: 11px;
  background: rgba(255, 255, 255, 0.58);
}

.compute-saved-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.compute-saved-actions button {
  border: 1px solid rgba(23, 20, 14, 0.12);
  border-radius: 999px;
  padding: 6px 9px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.68);
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.compute-saved-actions button:hover {
  border-color: rgba(214, 168, 71, 0.34);
  background: rgba(214, 168, 71, 0.12);
}

.compute-saved-row strong,
.compute-saved-row span {
  display: block;
}

.compute-saved-row span,
.compute-saved-row small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

:root[data-theme="dark"] .compute-config-form,
:root[data-theme="dark"] .compute-policy-panel {
  background:
    linear-gradient(180deg, rgba(24, 21, 15, 0.94), rgba(13, 13, 15, 0.96)),
    var(--panel);
}

:root[data-theme="dark"] .compute-form-grid input,
:root[data-theme="dark"] .compute-form-grid select,
:root[data-theme="dark"] .compute-form-grid textarea,
:root[data-theme="dark"] .compute-result,
:root[data-theme="dark"] .compute-saved-row,
:root[data-theme="dark"] .compute-task-tester,
:root[data-theme="dark"] .compute-saved-actions button {
  border-color: rgba(255, 247, 221, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--ink);
}

:root[data-theme="dark"] .compute-model-picker,
:root[data-theme="dark"] .compute-model-picker label {
  border-color: rgba(255, 247, 221, 0.13);
}

body.agent-canvas-focus-mode,
body.agent-canvas-window-mode {
  overflow: hidden;
  background: #05070d;
}

body.agent-canvas-focus-mode .app-shell,
body.agent-canvas-window-mode .app-shell {
  display: block;
  min-height: 100vh;
}

body.agent-canvas-focus-mode .sidebar,
body.agent-canvas-focus-mode .topbar,
body.agent-canvas-focus-mode .theme-toggle,
body.agent-canvas-focus-mode .settings-dock,
body.agent-canvas-focus-mode .guest-permission-notice,
body.agent-canvas-focus-mode .registered-permission-notice,
body.agent-canvas-window-mode .sidebar,
body.agent-canvas-window-mode .topbar,
body.agent-canvas-window-mode .theme-toggle,
body.agent-canvas-window-mode .settings-dock,
body.agent-canvas-window-mode .guest-permission-notice,
body.agent-canvas-window-mode .registered-permission-notice {
  display: none !important;
}

body.agent-canvas-focus-mode .main,
body.agent-canvas-window-mode .main {
  min-height: 100vh;
  padding: 0;
}

body.agent-canvas-focus-mode .view-root,
body.agent-canvas-window-mode .view-root {
  max-width: none;
  min-height: 100vh;
  padding: 0;
}

body.agent-canvas-focus-mode .ant-agent-canvas-panel,
body.agent-canvas-window-mode .ant-agent-canvas-panel {
  min-height: 100vh;
  height: 100vh;
  border: 0;
  border-radius: 0;
  padding: 0;
}

body.agent-canvas-focus-mode .ant-agent-canvas-layout,
body.agent-canvas-window-mode .ant-agent-canvas-layout {
  height: 100vh;
  min-height: 0;
}

body.agent-canvas-focus-mode .ant-agent-canvas-stage,
body.agent-canvas-window-mode .ant-agent-canvas-stage {
  min-height: 100vh;
  height: 100vh;
  border-radius: 0;
}

body.agent-canvas-focus-mode .ant-agent-canvas-window-actions,
body.agent-canvas-window-mode .ant-agent-canvas-window-actions {
  right: 16px;
  top: 16px;
  display: grid;
}

.ant-agent-canvas-focus-nav {
  position: absolute;
  top: 12px;
  left: 14px;
  z-index: 31;
  display: flex;
  align-items: center;
  gap: 9px;
  max-width: min(420px, calc(100% - 450px));
  min-height: 36px;
  border: 1px solid rgba(255, 224, 150, 0.2);
  border-radius: 999px;
  padding: 4px 10px 4px 4px;
  color: #f8edce;
  background: rgba(9, 10, 14, 0.84);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(14px);
}

.ant-agent-canvas-focus-nav button {
  min-height: 28px;
  border: 1px solid rgba(255, 218, 126, 0.24);
  border-radius: 999px;
  padding: 0 10px;
  color: #171108;
  background: linear-gradient(135deg, #ffe196, #d7a83f);
  cursor: pointer;
  font: inherit;
  font-size: 11px;
  font-weight: 900;
}

.ant-agent-canvas-focus-nav button:hover,
.ant-agent-canvas-focus-nav button:focus-visible {
  background: #fff0bd;
  outline: none;
}

.ant-agent-canvas-focus-nav strong {
  min-width: 0;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 760px) {
  .ant-agent-canvas-focus-nav {
    max-width: calc(100% - 180px);
  }

  .ant-agent-canvas-focus-nav strong {
    display: none;
  }
}

@media (min-width: 1081px) {
  body.clean-ui .app-shell {
    grid-template-columns: 248px minmax(0, 1fr);
  }

  body.clean-ui .sidebar,
  body.clean-ui .sidebar:hover,
  body.clean-ui .sidebar:focus-within {
    width: auto;
    overflow-y: auto;
    padding: 18px 16px;
    box-shadow: none;
  }

  body.clean-ui .brand,
  body.clean-ui .sidebar:hover .brand,
  body.clean-ui .sidebar:focus-within .brand {
    justify-content: flex-start;
  }

  body.clean-ui .brand > div:last-child,
  body.clean-ui .sidebar:hover .brand > div:last-child,
  body.clean-ui .sidebar:focus-within .brand > div:last-child {
    width: auto;
    opacity: 1;
  }

  body.clean-ui .nav-item,
  body.clean-ui .sidebar:hover .nav-item,
  body.clean-ui .sidebar:focus-within .nav-item {
    gap: 10px;
    padding: 8px 10px;
    font-size: 15px;
    font-weight: 800;
  }

  body.clean-ui .nav-item::before {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
    border-radius: 8px;
    font-size: 16px;
  }
}

@media (max-width: 1320px) {
  .workbench-entry-grid.channels {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-command-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .credit-rules-layout {
    grid-template-columns: 1fr;
  }

  .compute-config-layout {
    grid-template-columns: 1fr;
  }

  .compute-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .compute-model-picker {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .workbench-entry-grid.channels,
  .workbench-reserved-grid {
    grid-template-columns: 1fr;
  }

  .account-command-grid,
  .credits-hero {
    grid-template-columns: 1fr;
  }

  .account-profile-cover {
    height: 116px;
  }

  .account-profile-main {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 12px;
    padding: 0 14px 16px;
  }

  .account-profile-avatar {
    width: 72px;
    height: 72px;
    margin-top: -30px;
    border-width: 3px;
    font-size: 20px;
  }

  .account-profile-copy {
    padding-top: 12px;
  }

  .account-profile-copy h3 {
    font-size: 23px;
  }

  .account-profile-actions {
    grid-column: 1 / -1;
    justify-content: stretch;
    padding-top: 0;
  }

  .account-profile-actions .primary-btn,
  .account-profile-actions .asset-link {
    flex: 1 1 150px;
    justify-content: center;
  }

  .account-profile-editor-overlay {
    padding: 10px;
  }

  .account-profile-editor-dialog {
    width: 100%;
    max-height: calc(100dvh - 20px);
  }

  .profile-social-fields label {
    grid-template-columns: 68px minmax(0, 1fr);
  }

  .account-profile-editor-actions {
    padding: 10px;
  }

  .account-canvas-hero-strip {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .account-canvas-feature-card.is-active {
    transform: none;
  }

  .account-canvas-recent-strip {
    grid-auto-columns: minmax(232px, 78vw);
  }

  .account-canvas-gallery {
    column-count: 2;
  }

  .account-canvas-section-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
  }

  .account-section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .personal-canvas-grid,
  .account-site-grid,
  .credit-product-grid,
  .model-credit-grid {
    grid-template-columns: 1fr;
  }

  .libtv-native-shell {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .libtv-native-preview {
    min-height: 340px;
  }

  .libtv-native-caption {
    align-items: flex-start;
    flex-direction: column;
  }

  .compute-platform-hero {
    align-items: stretch;
    flex-direction: column;
    min-height: auto;
  }

  .compute-form-grid,
  .compute-model-picker {
    grid-template-columns: 1fr;
  }

  .compute-card-actions {
    grid-template-columns: 1fr;
  }

  .compute-form-head,
  .compute-saved-row {
    align-items: stretch;
    flex-direction: column;
  }

  .compute-saved-actions {
    justify-content: flex-start;
  }

  .compute-payload {
    max-height: 220px;
    font-size: 11px;
  }
}

.cli-center-shell {
  display: grid;
  gap: 14px;
  max-width: 1080px;
  margin: 0 auto;
}

.cli-launch-card {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(360px, 1fr);
  gap: 16px;
  align-items: stretch;
  min-height: 330px;
  padding: 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 200, 93, 0.38);
  border-radius: 22px;
  background:
    radial-gradient(circle at 8% 4%, rgba(255, 202, 94, 0.22), transparent 28%),
    radial-gradient(circle at 92% 16%, rgba(52, 122, 255, 0.14), transparent 30%),
    linear-gradient(135deg, #090806, #17120b 48%, #05070b);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.36);
}

.cli-launch-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 14px;
}

.cli-launch-copy h2 {
  margin: 6px 0 16px;
  color: #fff6df;
  font-size: clamp(32px, 4.4vw, 58px);
  line-height: 1.04;
  letter-spacing: 0;
}

.cli-mini-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cli-mini-meta span,
.cli-tool-strip span {
  border: 1px solid rgba(255, 215, 122, 0.22);
  border-radius: 999px;
  padding: 7px 11px;
  background: rgba(255, 255, 255, 0.055);
  color: rgba(255, 246, 223, 0.76);
  font-size: 13px;
}

.cli-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  overflow: hidden;
  min-height: 184px;
  border: 1px solid rgba(255, 200, 93, 0.4);
  border-radius: 18px;
  background:
    linear-gradient(115deg, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.72)),
    radial-gradient(circle at 20% 20%, rgba(255, 202, 94, 0.22), transparent 26%),
    radial-gradient(circle at 86% 12%, rgba(52, 122, 255, 0.18), transparent 30%),
    linear-gradient(135deg, #090806, #19140d 48%, #05070b);
  box-shadow: 0 22px 72px rgba(0, 0, 0, 0.34);
}

.cli-hero::after {
  content: "";
  position: absolute;
  inset: auto 26% -42% -12%;
  height: 170px;
  background: linear-gradient(90deg, transparent, rgba(255, 202, 94, 0.34), transparent);
  filter: blur(22px);
  transform: rotate(-7deg);
  pointer-events: none;
}

.cli-hero > div {
  position: relative;
  z-index: 1;
}

.cli-hero h2 {
  margin: 4px 0 8px;
  color: #fff6df;
  font-size: clamp(28px, 4vw, 50px);
  letter-spacing: 0;
}

.cli-hero p:not(.eyebrow) {
  max-width: 620px;
  margin: 0;
  color: rgba(255, 246, 223, 0.72);
  font-size: 16px;
  line-height: 1.7;
}

.cli-hero-badge {
  display: grid;
  min-width: 136px;
  gap: 6px;
  padding: 14px 16px;
  border: 1px solid rgba(216, 168, 75, 0.36);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(14px);
  text-align: right;
}

.cli-hero-badge strong {
  color: #ffd36a;
  font-size: 24px;
}

.cli-hero-badge span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.cli-download-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.cli-download-card {
  display: grid;
  gap: 8px;
  min-height: 94px;
  padding: 16px;
  border: 1px solid rgba(216, 168, 75, 0.22);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(18, 17, 15, 0.94);
  color: #fff7e4;
  text-decoration: none;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.2);
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.cli-download-card:hover {
  border-color: rgba(255, 210, 106, 0.62);
  transform: translateY(-2px);
}

.cli-download-card.primary {
  border-color: rgba(255, 202, 96, 0.7);
  background:
    radial-gradient(circle at 100% 0, rgba(255, 196, 76, 0.34), transparent 42%),
    linear-gradient(145deg, rgba(68, 43, 12, 0.96), rgba(20, 17, 13, 0.96));
}

.cli-download-card span {
  color: rgba(255, 247, 228, 0.62);
  font-size: 12px;
}

.cli-download-card strong {
  font-size: 19px;
}

.cli-download-card code {
  min-width: 0;
  overflow: hidden;
  color: rgba(255, 235, 185, 0.8);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cli-download-card div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.cli-download-card button,
.cli-download-card a {
  border: 1px solid rgba(255, 214, 118, 0.34);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 214, 118, 0.1);
  color: #ffd36a;
  font: inherit;
  font-size: 12px;
  text-decoration: none;
  cursor: pointer;
}

.cli-agent-panel {
  display: grid;
  grid-template-columns: 0.44fr minmax(0, 1fr);
  align-items: stretch;
  gap: 14px;
  border: 1px solid rgba(255, 202, 96, 0.26);
  border-radius: 18px;
  background:
    radial-gradient(circle at 0 0, rgba(255, 202, 96, 0.16), transparent 34%),
    linear-gradient(135deg, rgba(18, 16, 13, 0.96), rgba(8, 9, 12, 0.96));
}

.cli-agent-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 180px;
}

.cli-agent-copy h3 {
  margin: 2px 0 0;
  color: #fff3d6;
  font-size: clamp(22px, 2.8vw, 34px);
  letter-spacing: 0;
}

.cli-agent-command {
  position: relative;
  min-width: 0;
}

.cli-agent-command > button {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  border: 1px solid rgba(255, 214, 118, 0.45);
  border-radius: 999px;
  padding: 8px 14px;
  background: rgba(255, 214, 118, 0.12);
  color: #ffd36a;
  cursor: pointer;
}

.cli-step-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cli-command-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(216, 168, 75, 0.18);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(24, 23, 20, 0.96), rgba(13, 13, 13, 0.96));
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
}

.cli-command-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.cli-command-title strong {
  color: #fff3d6;
  font-size: 14px;
}

.cli-command-title button {
  border: 1px solid rgba(216, 168, 75, 0.3);
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(216, 168, 75, 0.1);
  color: #ffd36a;
  cursor: pointer;
}

.cli-command-block {
  min-height: 88px;
  margin: 0;
  padding: 12px 14px;
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: #060606;
  color: #f7ddb0;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.cli-command-block.large {
  min-height: 260px;
  padding-top: 46px;
  font-size: 14px;
}

.cli-command-card p {
  margin: 0;
  color: rgba(255, 247, 228, 0.58);
  font-size: 13px;
  line-height: 1.6;
}

.cli-quick-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.cli-quick-strip button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  border: 1px solid rgba(216, 168, 75, 0.2);
  border-radius: 14px;
  padding: 12px 13px;
  background: rgba(12, 12, 12, 0.86);
  color: rgba(255, 247, 228, 0.84);
  cursor: pointer;
}

.cli-quick-strip code {
  min-width: 0;
  overflow: hidden;
  color: #f7ddb0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cli-quick-strip span {
  color: #ffd36a;
  font-size: 12px;
  flex: 0 0 auto;
}

.cli-tool-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 4px 0;
}

.cli-more-panel {
  border: 1px solid rgba(216, 168, 75, 0.18);
  border-radius: 16px;
  background: rgba(13, 13, 13, 0.74);
}

.cli-more-panel > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  color: #fff3d6;
  cursor: pointer;
  list-style: none;
}

.cli-more-panel > summary::-webkit-details-marker {
  display: none;
}

.cli-more-panel > summary::after {
  content: "+";
  color: #ffd36a;
  font-size: 18px;
}

.cli-more-panel[open] > summary::after {
  content: "−";
}

.cli-more-panel > section {
  padding: 0 14px 14px;
}

@media (max-width: 1080px) {
  .cli-launch-card,
  .cli-hero,
  .cli-download-grid,
  .cli-step-grid,
  .cli-agent-panel,
  .cli-quick-strip {
    grid-template-columns: 1fr;
  }

  .cli-hero-badge {
    text-align: left;
  }
}

.payment-test-shell {
  display: grid;
  gap: 18px;
  max-width: 980px;
  margin: 0 auto;
  padding: 32px 18px 80px;
}

.payment-test-hero {
  min-height: 260px;
  display: grid;
  align-content: end;
  gap: 10px;
  border: 1px solid rgba(240, 192, 96, 0.22);
  border-radius: 18px;
  padding: 28px;
  background:
    linear-gradient(135deg, rgba(12, 10, 6, 0.2), rgba(10, 10, 14, 0.88)),
    url("/media/workbench/studio-bg-scifi.jpg") center / cover;
  box-shadow: 0 22px 80px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}

.payment-test-hero h2 {
  margin: 0;
  color: #fff7df;
  font-size: clamp(32px, 5vw, 62px);
  letter-spacing: 0;
}

.payment-test-hero p:not(.eyebrow) {
  max-width: 660px;
  margin: 0;
  color: rgba(255, 239, 204, 0.82);
  font-size: 16px;
}

.payment-test-status-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.payment-test-status-grid article {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(240, 192, 96, 0.18);
  border-radius: 16px;
  padding: 16px;
  background: rgba(16, 15, 13, 0.9);
}

.payment-test-status-grid span {
  color: rgba(255, 239, 204, 0.62);
  font-size: 13px;
}

.payment-test-status-grid strong {
  color: #fff4d6;
  font-size: 18px;
}

.payment-test-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  border: 1px solid rgba(240, 192, 96, 0.16);
  border-radius: 16px;
  padding: 14px;
  background: rgba(10, 10, 10, 0.72);
}

@media (max-width: 760px) {
  .payment-test-status-grid {
    grid-template-columns: 1fr;
  }
}
