:root {
  --red: #df3f42;
  --red-dark: #bd242a;
  --orange: #ff8a3d;
  --blue: #275bd8;
  --green: #168a68;
  --ink: #171923;
  --muted: #6e7482;
  --line: #e4e7ee;
  --soft: #f5f7fa;
  --card: #ffffff;
  --bg: #eef1f5;
  --sidebar: #202431;
  --shadow: 0 18px 50px rgba(23, 25, 35, 0.12);
  --neon-cyan: #16f4ff;
  --neon-magenta: #ff2bd6;
  --acid-yellow: #f7ff3c;
  --electric-violet: #8b5cff;
  --deep-space: #070914;
  --panel-glass: rgba(12, 18, 38, 0.78);
  --cyber-line: rgba(22, 244, 255, 0.28);
  --sakura-pink: #ff75b7;
  --star-violet: #8f78ff;
  --pearl-white: #fff7fb;
  --evening-blue: #8fc7ff;
  --reward-gold: #ffd66b;
  --mint-glow: #85f0df;
  --dream-ink: #32275f;
  --dream-muted: #7d7394;
  --dream-line: rgba(143, 120, 255, 0.2);
  --h5-safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body {
  background: linear-gradient(135deg, #f9fafc 0%, #edf1f5 100%);
  color: var(--ink);
  font-family: Arial, "Microsoft YaHei", sans-serif;
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3,
p {
  margin: 0;
}

[hidden] {
  display: none !important;
}

.hidden {
  display: none !important;
}

.entry-shell {
  display: grid;
  gap: 22px;
  grid-template-columns: minmax(320px, 520px) minmax(280px, 420px);
  margin: 0 auto;
  max-width: 1040px;
  min-height: 100vh;
  padding: 42px 24px;
  place-content: center;
}

.login-panel,
.login-preview,
.panel,
.metric-card,
.admin-overview article {
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.92);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login-panel {
  display: grid;
  gap: 18px;
  padding: 26px;
}

.brand-line,
.section-kicker,
.compact-row,
.topbar,
.section-title,
.section-label,
.panel-heading,
.workspace-heading,
.metric-head,
.metric-strip,
.item-header,
.card-actions,
.task-meta,
.nav-row,
.inline-form {
  align-items: center;
  display: flex;
}

.brand-line {
  gap: 12px;
}

.brand-mark {
  align-items: center;
  background: linear-gradient(135deg, var(--red), var(--orange));
  border-radius: 8px;
  color: #fff;
  display: flex;
  flex: 0 0 auto;
  font-size: 23px;
  font-weight: 900;
  height: 44px;
  justify-content: center;
  width: 44px;
}

.brand-line span,
.eyebrow,
.metric-card span,
.item p,
.item small,
.task-meta,
.admin-overview span {
  color: var(--muted);
}

.eyebrow {
  display: block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  margin-bottom: 6px;
}

.eyebrow.dark {
  color: #8a4a20;
}

.login-copy h1 {
  font-size: 32px;
  line-height: 1.2;
}

.section-kicker,
.section-label,
.panel-heading,
.metric-head,
.task-meta {
  gap: 8px;
}

.section-kicker {
  justify-content: flex-start;
}

.compact-row,
.metric-head,
.panel-heading,
.task-meta {
  justify-content: space-between;
}

.compact-alert {
  align-items: center;
  background: #fff0e6;
  border: 1px solid #ffd8c5;
  border-radius: 8px;
  color: #8b3d16;
  display: flex;
  justify-content: space-between;
  padding: 12px;
}

[data-tooltip] {
  position: relative;
}

[data-tooltip]::after {
  background: var(--ink);
  border-radius: 8px;
  bottom: calc(100% + 10px);
  box-shadow: 0 12px 28px rgba(23, 25, 35, 0.18);
  color: #fff;
  content: attr(data-tooltip);
  font-size: 12px;
  font-weight: 500;
  left: 50%;
  line-height: 1.55;
  max-width: min(280px, calc(100vw - 40px));
  opacity: 0;
  padding: 9px 11px;
  pointer-events: none;
  position: absolute;
  text-align: left;
  transform: translate(-50%, 6px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  visibility: hidden;
  white-space: normal;
  width: max-content;
  z-index: 40;
}

[data-tooltip]:hover::after,
[data-tooltip]:focus::after,
[data-tooltip]:focus-visible::after {
  opacity: 1;
  transform: translate(-50%, 0);
  visibility: visible;
}

.info-tip,
.info-dot {
  align-items: center;
  border-radius: 999px;
  display: inline-flex;
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 900;
  height: 22px;
  justify-content: center;
  width: 22px;
}

.info-tip {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--muted);
  min-height: 22px;
  padding: 0;
}

.info-tip.light,
.info-dot {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
}

.info-dot {
  font-size: 11px;
}

.auth-switch {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  grid-template-columns: 1fr 1fr;
  padding: 4px;
}

.auth-switch button {
  background: transparent;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  font-weight: 800;
  min-height: 38px;
}

.auth-switch button.active {
  background: #fff;
  box-shadow: 0 4px 14px rgba(23, 25, 35, 0.08);
  color: var(--ink);
}

.login-form,
.form-grid {
  display: grid;
  gap: 12px;
}

.register-fields {
  display: grid;
  gap: 12px;
}

label {
  color: var(--muted);
  display: grid;
  font-size: 13px;
  gap: 7px;
}

input,
textarea,
select {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  min-height: 42px;
  outline: 0;
  padding: 10px 11px;
}

textarea {
  resize: vertical;
}

.primary-button,
.secondary-button,
.card-button {
  border-radius: 8px;
  font-weight: 800;
  min-height: 40px;
  padding: 0 14px;
}

.primary-button {
  background: linear-gradient(135deg, var(--red), var(--orange));
  border: 0;
  color: #fff;
}

.secondary-button,
.card-button {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
}

.card-button.danger {
  border-color: #ffd0d0;
  color: var(--red);
}

.login-preview {
  align-self: stretch;
  display: grid;
  gap: 14px;
  padding: 18px;
}

.login-preview img {
  background: #fff6ef;
  border: 1px solid #ffe0cf;
  border-radius: 8px;
  height: 220px;
  object-fit: cover;
  width: 100%;
}

.preview-card {
  background: #202431;
  border-radius: 8px;
  color: #fff;
  padding: 16px;
}

.preview-card strong {
  display: block;
  font-size: 24px;
  margin: 6px 0 0;
}

.preview-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, 1fr);
}

.preview-grid div {
  align-items: center;
  background: var(--soft);
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  padding: 12px;
}

.preview-grid strong {
  display: block;
}

.workspace-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  background: var(--sidebar);
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 18px;
}

.sidebar .brand-line span,
.sidebar .side-card {
  color: rgba(255, 255, 255, 0.66);
}

.side-nav {
  display: grid;
  gap: 8px;
}

.sidebar-guide {
  aspect-ratio: 4 / 5;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 8px;
  box-shadow: 0 18px 42px rgba(143, 120, 255, 0.18);
  margin: 0;
  min-height: 0;
  overflow: hidden;
  position: relative;
}

.sidebar-guide::after {
  background:
    radial-gradient(circle at 24% 18%, rgba(255, 255, 255, 0.7), transparent 18%),
    linear-gradient(180deg, transparent 54%, rgba(56, 39, 112, 0.28));
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.sidebar-guide img {
  display: block;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  width: 100%;
}

.side-nav button {
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.72);
  display: block;
  min-height: 50px;
  padding: 10px 12px;
  text-align: left;
}

.side-nav button.active {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.side-nav span {
  font-weight: 900;
}

.nav-row {
  justify-content: space-between;
  width: 100%;
}

.side-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  margin-top: auto;
  padding: 14px;
}

.side-card span {
  color: #fff;
  font-weight: 900;
}

.workspace-main {
  padding: 24px;
}

.topbar,
.workspace-heading,
.section-title {
  justify-content: space-between;
}

.topbar {
  gap: 16px;
  margin-bottom: 16px;
}

.topbar h1 {
  font-size: 30px;
}

.top-actions {
  align-items: stretch;
  display: flex;
  gap: 10px;
}

.top-profile {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  min-width: 132px;
  padding: 12px;
  text-align: right;
}

.top-profile-button {
  color: var(--dream-ink);
  min-height: 42px;
}

.top-profile-button:hover,
.top-profile-button:focus-visible {
  border-color: rgba(143, 120, 255, 0.42);
  box-shadow: 0 10px 26px rgba(143, 120, 255, 0.18);
}

.logout-button {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-weight: 900;
  min-height: 42px;
  padding: 0 14px;
}

.logout-button:hover,
.logout-button:focus-visible {
  border-color: rgba(143, 120, 255, 0.34);
  color: var(--dream-ink);
}

.top-profile strong,
.top-profile span {
  display: block;
}

.top-profile span {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px;
}

.metric-strip {
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr);
  margin-bottom: 10px;
}

.metric-card {
  box-shadow: none;
  min-height: 58px;
  padding: 10px 12px;
}

.metric-card .metric-head {
  gap: 6px;
}

.metric-card span {
  font-size: 12px;
}

.metric-card .info-tip {
  font-size: 11px;
  height: 18px;
  min-height: 18px;
  width: 18px;
}

.metric-card strong {
  display: block;
  font-size: 20px;
  line-height: 1.1;
  margin: 2px 0 0;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.workspace-heading {
  gap: 14px;
  margin: 4px 0 14px;
}

.workspace-heading h2 {
  font-size: 24px;
}

.h5-guide-hero {
  align-items: center;
  background:
    radial-gradient(circle at 12% 16%, rgba(255, 255, 255, 0.92), transparent 24%),
    linear-gradient(135deg, rgba(255, 235, 249, 0.9), rgba(233, 242, 255, 0.8));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 16px;
  box-shadow: 0 18px 48px rgba(143, 120, 255, 0.16);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) 96px;
  margin: 0 0 14px;
  min-height: 118px;
  overflow: hidden;
  padding: 14px 14px 14px 16px;
  position: relative;
}

.h5-guide-hero::before {
  animation: guideGlow 4.8s ease-in-out infinite;
  background: linear-gradient(90deg, rgba(255, 117, 183, 0.42), rgba(143, 120, 255, 0.34), rgba(133, 240, 223, 0.28));
  content: "";
  height: 3px;
  inset: 0 0 auto;
  position: absolute;
}

.h5-guide-copy {
  min-width: 0;
  position: relative;
  z-index: 1;
}

.h5-guide-copy h3 {
  color: var(--dream-ink);
  font-size: 20px;
  line-height: 1.18;
}

.h5-guide-copy p {
  color: var(--dream-muted);
  font-size: 13px;
  line-height: 1.55;
  margin-top: 7px;
  transition: opacity 0.2s ease;
}

.guide-tip-text {
  transition: opacity 0.2s ease;
}

.work-panel-tabs {
  display: flex;
  gap: 8px;
  min-width: 0;
  overflow-x: auto;
  padding: 2px 2px 8px;
  scrollbar-width: none;
}

.work-panel-tabs::-webkit-scrollbar {
  display: none;
}

.work-panel-tab {
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(143, 120, 255, 0.18);
  border-radius: 999px;
  color: var(--dream-muted);
  flex: 0 0 auto;
  font-weight: 900;
  min-height: 36px;
  padding: 0 14px;
  text-align: center;
  white-space: nowrap;
}

.work-panel-tab.active,
.work-panel-tab:hover,
.work-panel-tab:focus-visible {
  background: linear-gradient(135deg, rgba(255, 117, 183, 0.22), rgba(143, 120, 255, 0.18));
  border-color: rgba(143, 120, 255, 0.36);
  color: var(--dream-ink);
}

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

.module-layout {
  display: grid;
  grid-template-columns: minmax(128px, 180px) minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.module-sidebar {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(143, 120, 255, 0.18);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 16px 34px rgba(119, 82, 190, 0.12);
  position: sticky;
  top: 14px;
}

.module-content {
  min-width: 0;
}

.profile-module-layout,
.publisher-module-layout,
.admin-module-layout {
  margin-top: 14px;
}

.work-panel-tabs + .task-lobby-panel {
  min-width: 0;
}

.h5-guide-hero img {
  align-self: end;
  animation: guideFloat 3.6s ease-in-out infinite;
  filter: drop-shadow(0 14px 20px rgba(143, 120, 255, 0.24));
  height: 118px;
  justify-self: end;
  object-fit: cover;
  object-position: 50% 14%;
  width: 96px;
}

@keyframes guideFloat {
  0%,
  100% {
    transform: translateY(2px);
  }
  50% {
    transform: translateY(-6px);
  }
}

@keyframes guideGlow {
  0%,
  100% {
    opacity: 0.56;
  }
  50% {
    opacity: 1;
  }
}

.insight-grid,
.publisher-layout {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
}

.insight-grid.bottom {
  grid-template-columns: 1fr 1fr;
  margin-top: 14px;
}

.publisher-layout {
  align-items: start;
  margin-bottom: 14px;
}

.panel {
  box-shadow: none;
  padding: 16px;
}

.panel.wide {
  min-height: 430px;
}

.task-lobby-panel {
  display: grid;
  gap: 16px;
}

.task-lobby-section {
  min-width: 0;
}

.panel h3 {
  font-size: 18px;
}

.status-pill {
  background: #fff0e6;
  border-radius: 8px;
  color: #9a4717;
  display: inline-flex;
  font-size: 12px;
  padding: 6px 9px;
  white-space: nowrap;
}

.task-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0;
}

.task-toolbar span {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #4b5060;
  font-size: 13px;
  padding: 7px 10px;
}

.list {
  display: grid;
  gap: 10px;
}

.compact-list {
  margin-top: 12px;
}

.task-list {
  margin-top: 12px;
}

.task-module-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.task-group-stack {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.task-group-module {
  display: grid;
  gap: 8px;
}

.task-group-head h4 {
  color: var(--dream-ink);
  font-size: 14px;
  margin: 0;
}

.external-task-block {
  border-top: 1px dashed rgba(174, 129, 255, 0.35);
  margin-top: 18px;
  padding-top: 16px;
}

.external-task-hint {
  background: rgba(255, 246, 216, 0.58);
  border: 1px solid rgba(255, 214, 107, 0.42);
  border-radius: 8px;
  color: #7a5519;
  font-size: 13px;
  line-height: 1.5;
  margin: 10px 0 0;
  padding: 9px 10px;
}

.external-task-pager {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  margin-top: 10px;
}

.external-task-pager .secondary-button {
  min-height: 40px;
  padding: 0 12px;
}

.external-task-pager .secondary-button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.external-task-pager .status-pill {
  justify-content: center;
  min-width: 76px;
}

.external-task-card {
  background:
    linear-gradient(135deg, rgba(255, 247, 253, 0.96), rgba(239, 245, 255, 0.92)),
    var(--soft);
}

.external-task-title {
  align-items: center;
  display: flex;
  gap: 10px;
  min-width: 0;
}

.external-task-title img {
  border: 1px solid rgba(174, 129, 255, 0.35);
  border-radius: 8px;
  height: 42px;
  object-fit: cover;
  width: 42px;
}

.external-task-title div {
  min-width: 0;
}

.external-task-title h3,
.external-task-title p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.external-task-card .card-button {
  min-height: 44px;
}

.compact-task-card {
  gap: 8px;
  padding: 10px;
}

.compact-task-card .item-header {
  align-items: start;
  display: grid;
  gap: 8px;
}

.compact-task-card .external-task-title {
  width: 100%;
}

.compact-task-card h3 {
  display: -webkit-box;
  font-size: 14px;
  line-height: 1.32;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.compact-task-card p {
  display: -webkit-box;
  font-size: 12px;
  line-height: 1.35;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.compact-task-card .reward {
  font-size: 13px;
  justify-self: start;
  padding: 6px 8px;
}

.compact-task-card .task-meta {
  font-size: 12px;
}

.compact-task-card .task-progress {
  height: 5px;
}

.compact-task-card .card-actions {
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) auto;
}

.compact-task-card .card-button {
  min-height: 36px;
  padding: 0 10px;
}

.compact-task-card .status-pill {
  align-items: center;
  padding: 5px 7px;
}

.task-type-dock {
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 16px;
  box-shadow: 0 12px 26px rgba(143, 120, 255, 0.12);
  order: -1;
}

.task-list-rows {
  display: grid;
  gap: 8px;
}

.task-list-row {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  min-height: 72px;
  padding: 10px 12px;
}

.task-list-row.source-highlight {
  border-color: rgba(255, 117, 183, 0.72);
  box-shadow: 0 0 0 3px rgba(255, 117, 183, 0.18), 0 12px 28px rgba(143, 120, 255, 0.18);
}

.claim-task-card.claim-task-complete {
  background: linear-gradient(135deg, rgba(232, 255, 239, 0.92), rgba(246, 255, 251, 0.78));
  border-color: rgba(46, 180, 111, 0.42);
  box-shadow: 0 12px 26px rgba(46, 180, 111, 0.12);
}

.task-status-approved {
  background: rgba(46, 180, 111, 0.14);
  border-color: rgba(46, 180, 111, 0.28);
  color: #16804d;
}

.item-time {
  color: rgba(78, 74, 124, 0.68);
  font-size: 12px;
  font-weight: 800;
  margin-top: 8px;
}

.claim-time,
.message-time {
  letter-spacing: 0;
}

.task-row-icon {
  border-radius: 11px;
  height: 44px;
  object-fit: cover;
  width: 44px;
}

.task-row-icon-local {
  align-items: center;
  background: linear-gradient(135deg, rgba(255, 117, 183, 0.95), rgba(143, 120, 255, 0.9));
  color: #fff;
  display: flex;
  font-weight: 1000;
  justify-content: center;
}

.task-row-main {
  min-width: 0;
}

.task-row-title-line {
  align-items: center;
  display: flex;
  gap: 7px;
  min-width: 0;
}

.task-row-title-line h3 {
  color: var(--dream-ink);
  font-size: 14px;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-row-main p {
  color: var(--dream-muted);
  font-size: 12px;
  line-height: 1.3;
  margin-top: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-row-badge,
.task-row-tags span {
  background: rgba(143, 120, 255, 0.1);
  border: 1px solid rgba(143, 120, 255, 0.12);
  border-radius: 999px;
  color: #7467c8;
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 900;
  padding: 3px 7px;
}

.task-row-tags {
  display: flex;
  gap: 6px;
  margin-top: 6px;
  min-width: 0;
  overflow: hidden;
}

.task-row-side {
  align-items: end;
  display: grid;
  gap: 6px;
  justify-items: end;
}

.task-row-reward {
  color: #ff4b88;
  font-size: 15px;
  white-space: nowrap;
}

.task-row-action {
  min-height: 30px;
  padding: 0 12px;
}

.external-task-card.task-list-row {
  align-items: center;
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 68px;
  padding: 8px 10px;
}

.external-task-card.task-list-row .item-header {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) auto;
  min-width: 0;
}

.external-task-card.task-list-row .external-task-title img {
  border-radius: 11px;
  height: 42px;
  width: 42px;
}

.external-task-card.task-list-row .reward {
  background: transparent;
  border: 0;
  color: #ff4b88;
  font-size: 15px;
  padding: 0;
  white-space: nowrap;
}

.external-task-card.task-list-row .task-meta {
  display: none;
  gap: 6px;
  grid-column: 1;
  margin: 0 0 0 57px;
  overflow: hidden;
}

.external-task-card.task-list-row .task-meta span {
  background: rgba(143, 120, 255, 0.1);
  border-radius: 999px;
  color: #7467c8;
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 900;
  padding: 3px 7px;
}

.external-task-card.task-list-row .card-actions {
  align-self: center;
  display: grid;
  gap: 5px;
  grid-column: 2;
  grid-row: 1 / span 2;
  justify-items: end;
}

.external-task-card.task-list-row .card-actions .status-pill {
  display: none;
}

.external-task-card.task-list-row .card-button {
  min-height: 30px;
  padding: 0 12px;
}

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

.profile-card {
  align-content: start;
  display: grid;
  gap: 14px;
}

.profile-facts {
  display: grid;
  gap: 8px;
  margin: 0;
}

.profile-facts div {
  align-items: center;
  background: rgba(255, 255, 255, 0.56);
  border: 1px solid rgba(143, 120, 255, 0.16);
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  padding: 10px 11px;
}

.profile-facts dt {
  color: var(--dream-muted);
  font-size: 12px;
  font-weight: 800;
}

.profile-facts dd {
  color: var(--dream-ink);
  font-weight: 900;
  margin: 0;
}

.claim-range-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

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

.captain-stat-card,
.captain-level-card,
.settings-row,
.audit-config-panel {
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(143, 120, 255, 0.18);
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(146, 118, 255, 0.08);
}

.captain-stat-card {
  display: grid;
  gap: 5px;
  padding: 12px;
}

.captain-stat-card span,
.settings-row span,
.captain-level-card span {
  color: var(--dream-muted);
  font-size: 12px;
  font-weight: 800;
}

.captain-stat-card strong {
  color: var(--dream-ink);
  font-size: 18px;
}

.captain-level-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
}

.captain-level-card {
  display: grid;
  gap: 4px;
  padding: 10px;
}

.captain-level-card.active {
  background: linear-gradient(135deg, rgba(255, 238, 186, 0.94), rgba(255, 197, 236, 0.74));
  border-color: rgba(232, 175, 64, 0.5);
}

.captain-level-card em {
  color: var(--sakura-pink);
  font-style: normal;
  font-weight: 900;
}

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

.settings-row {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 12px;
}

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

.audit-config-panel {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.audit-config-panel label {
  display: grid;
  gap: 6px;
}

.publisher-audit-card {
  overflow: hidden;
}

.audit-material-image {
  border: 1px solid rgba(143, 120, 255, 0.18);
  border-radius: 8px;
  display: block;
  overflow: hidden;
  width: min(220px, 100%);
}

.audit-material-image img {
  display: block;
  height: auto;
  width: 100%;
}

.audit-material-link a {
  color: var(--violet);
  font-weight: 900;
}

.task-progress {
  background: #e8ebf2;
  border-radius: 999px;
  height: 7px;
  overflow: hidden;
}

.task-progress span {
  background: linear-gradient(90deg, var(--red), var(--orange));
  display: block;
  height: 100%;
}

.item {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 10px;
  padding: 13px;
}

.item h3 {
  font-size: 16px;
}

.item p {
  line-height: 1.55;
}

.reward {
  background: #fff0e6;
  border-radius: 8px;
  color: var(--red-dark);
  font-weight: 900;
  padding: 6px 8px;
  white-space: nowrap;
}

.card-actions {
  flex-wrap: wrap;
  gap: 8px;
}

.form-row {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr 1fr;
}

.admin-overview {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 14px;
}

.admin-overview article {
  box-shadow: none;
  padding: 14px;
}

.admin-overview strong {
  display: block;
  margin-top: 5px;
}

.payout-panel {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.inline-form {
  align-items: end;
  flex-wrap: wrap;
  gap: 10px;
}

.inline-form label {
  min-width: 220px;
}

.toast {
  background: var(--ink);
  border-radius: 8px;
  bottom: 22px;
  color: #fff;
  display: none;
  left: 50%;
  max-width: calc(100vw - 40px);
  padding: 12px 16px;
  position: fixed;
  transform: translateX(-50%);
  z-index: 20;
}

.toast.show {
  display: block;
}

@media (max-width: 980px) {
  .entry-shell,
  .workspace-shell,
  .insight-grid,
  .insight-grid.bottom,
  .publisher-layout,
  .admin-overview {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

  .sidebar-guide {
    display: none;
  }

  .side-card {
    display: none;
  }

  .metric-strip {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .profile-center-grid,
  .task-lobby-grid,
  .module-layout {
    grid-template-columns: 1fr;
  }

  .module-sidebar {
    display: flex;
    overflow-x: auto;
    position: static;
  }

  .top-actions {
    justify-content: end;
  }

  .top-profile {
    flex: 0 0 auto;
  }
}

@media (max-width: 620px) {
  .entry-shell,
  .workspace-main {
    padding: 14px;
  }

  .login-copy h1,
  .topbar h1 {
    font-size: 24px;
  }

  .topbar,
  .workspace-heading,
  .metric-strip,
  .form-row {
    align-items: stretch;
    flex-direction: column;
    grid-template-columns: 1fr;
  }

  .metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .top-profile {
    text-align: left;
  }
}

@media (max-width: 760px) {
  body.is-authenticated {
    background-attachment: fixed;
  }

  .h5-workspace {
    display: block;
    min-height: 100vh;
    padding-bottom: calc(74px + var(--h5-safe-bottom));
  }

  .h5-workspace .sidebar {
    background: transparent;
    display: block;
    padding: 0;
  }

  .h5-workspace .sidebar > .brand-line,
  .h5-workspace .sidebar-guide,
  .h5-workspace .side-card {
    display: none;
  }

  .h5-bottom-nav {
    backdrop-filter: blur(18px);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(143, 120, 255, 0.2);
    border-radius: 18px 18px 0 0;
    bottom: 0;
    box-shadow: 0 -10px 30px rgba(143, 120, 255, 0.16);
    display: grid;
    gap: 6px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    left: 0;
    padding: 8px 10px calc(8px + var(--h5-safe-bottom));
    position: fixed;
    right: 0;
    z-index: 30;
  }

  .h5-bottom-nav button {
    align-items: center;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 12px;
    color: var(--dream-muted);
    display: flex;
    justify-content: center;
    min-height: 48px;
    padding: 5px 4px;
    text-align: center;
  }

  .h5-bottom-nav button.active {
    background: linear-gradient(135deg, rgba(255, 117, 183, 0.16), rgba(143, 120, 255, 0.14));
    border-color: rgba(143, 120, 255, 0.2);
    color: var(--dream-ink);
  }

  .h5-bottom-nav .nav-row {
    display: block;
    width: auto;
  }

  .h5-bottom-nav .info-dot {
    display: none;
  }

  .workspace-main {
    padding: 12px 10px;
  }

  .topbar {
    align-items: stretch;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.64);
    border-radius: 14px;
    gap: 10px;
    margin-bottom: 10px;
    padding: 10px;
    position: sticky;
    top: 0;
    z-index: 12;
  }

  .topbar h1 {
    font-size: 20px;
    line-height: 1.18;
  }

  .top-actions {
    display: flex;
    justify-content: flex-end;
    width: auto;
  }

  .top-profile {
    min-width: 0;
    padding: 9px 10px;
    text-align: left;
  }

  .top-profile span {
    font-size: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .logout-button {
    min-height: 44px;
    padding: 0 10px;
  }

  .metric-strip {
    margin-bottom: 8px;
  }

  .h5-guide-hero {
    grid-template-columns: minmax(0, 1fr) 82px;
    min-height: 104px;
    padding: 12px;
  }

  .h5-guide-copy h3 {
    font-size: 17px;
  }

  .h5-guide-copy p {
    font-size: 12px;
  }

  .h5-guide-hero img {
    height: 104px;
    width: 82px;
  }

  .workspace-heading {
    align-items: center;
    display: grid;
    gap: 8px;
    grid-template-columns: minmax(0, 1fr) auto;
    margin: 0 0 10px;
  }

  .workspace-heading h2 {
    font-size: 21px;
  }

  .workspace-heading .secondary-button {
    min-height: 42px;
    padding: 0 12px;
  }

  .panel {
    border-radius: 12px;
    padding: 12px;
  }

  .panel.wide {
    min-height: 0;
  }

  .task-toolbar {
    flex-wrap: nowrap;
    margin: 10px -2px;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .task-toolbar span {
    flex: 0 0 auto;
  }

  .item {
    border-radius: 12px;
    padding: 12px;
  }

  .task-module-grid {
    grid-template-columns: 1fr;
  }

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

  .work-panel-tabs {
    display: flex;
    gap: 8px;
    margin: 0;
    min-width: 0;
    overflow-x: auto;
    padding: 2px 2px 8px;
  }

  .work-panel-tab {
    min-height: 34px;
    padding: 0 12px;
    text-align: center;
    white-space: nowrap;
  }

  .compact-task-card {
    padding: 9px;
  }

  .compact-task-card .item-header {
    display: grid;
    gap: 7px;
  }

  .compact-task-card h3 {
    font-size: 13px;
  }

  .compact-task-card p,
  .compact-task-card .task-meta {
    font-size: 11px;
  }

  .compact-task-card .reward {
    justify-self: start;
  }

  .compact-task-card .card-actions {
    grid-template-columns: 1fr;
  }

  .compact-task-card .status-pill {
    display: none;
  }

  .task-list-row {
    gap: 8px;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    min-height: 62px;
    padding: 8px 9px;
  }

  .task-row-icon,
  .external-task-card.task-list-row .external-task-title img {
    border-radius: 9px;
    height: 38px;
    width: 38px;
  }

  .task-row-title-line h3 {
    font-size: 13px;
  }

  .task-row-main p {
    font-size: 11px;
  }

  .task-row-tags {
    margin-top: 4px;
  }

  .task-row-tags span,
  .external-task-card.task-list-row .task-meta span {
    font-size: 10px;
    padding: 2px 6px;
  }

  .task-row-reward,
  .external-task-card.task-list-row .reward {
    font-size: 13px;
  }

  .external-task-card.task-list-row .task-meta {
    margin-left: 49px;
  }

  .profile-center-grid {
    gap: 10px;
    grid-template-columns: 1fr;
  }

  .item-header {
    align-items: start;
    gap: 10px;
  }

  .item h3 {
    font-size: 15px;
    line-height: 1.32;
  }

  .reward {
    font-size: 13px;
    padding: 6px 7px;
  }

  .card-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .card-button,
  .primary-button,
  .secondary-button {
    min-height: 46px;
  }

  .external-task-block {
    margin-top: 14px;
    padding-top: 14px;
  }

  .external-task-pager {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  }

  .external-task-pager .secondary-button {
    min-height: 44px;
    padding: 0 10px;
  }

  .external-task-block .section-title {
    align-items: center;
    display: grid;
    gap: 8px;
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .external-task-title {
    gap: 9px;
  }

  .external-task-title img {
    height: 46px;
    width: 46px;
  }

  .external-task-card .card-actions {
    grid-template-columns: minmax(0, 1fr) 42px;
  }

  .external-task-card .card-button {
    background: linear-gradient(135deg, var(--sakura-pink), var(--star-violet));
    color: #fff;
    min-height: 48px;
  }
}

/* Premium anime wallpaper theme */
.theme-anime-dream {
  background:
    linear-gradient(180deg, rgba(255, 247, 251, 0.36), rgba(244, 236, 255, 0.68)),
    var(--pearl-white);
  color: var(--dream-ink);
  overflow-x: hidden;
}

.anime-wallpaper {
  background-position: center;
  background-size: cover;
  inset: 0;
  opacity: 1;
  pointer-events: none;
  position: fixed;
  transform: scale(1);
  transition: opacity 0.55s ease, transform 0.55s ease;
  z-index: 0;
}

.anime-wallpaper-login {
  background-image:
    linear-gradient(90deg, rgba(255, 247, 251, 0.9) 0%, rgba(255, 247, 251, 0.46) 34%, rgba(255, 247, 251, 0.18) 64%, rgba(255, 247, 251, 0.52) 100%),
    url("./assets/zhuanzhuan-premium-anime-wallpaper-2026-05-30.png");
}

.anime-wallpaper-lobby {
  background-image:
    linear-gradient(90deg, rgba(246, 244, 255, 0.72) 0%, rgba(248, 247, 255, 0.36) 36%, rgba(245, 255, 252, 0.2) 64%, rgba(246, 244, 255, 0.58) 100%),
    url("./assets/zhuanzhuan-task-hall-anime-wallpaper-2026-06-02.png");
  opacity: 0;
  transform: scale(1.018);
}

body.is-authenticated .anime-wallpaper-login {
  opacity: 0;
  transform: scale(1);
}

body.is-authenticated .anime-wallpaper-lobby {
  opacity: 1;
  transform: scale(1);
}

.anime-sky-layer {
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 117, 183, 0.24), transparent 22%),
    radial-gradient(circle at 86% 18%, rgba(133, 240, 223, 0.2), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 247, 251, 0.72));
  inset: 0;
  pointer-events: none;
  position: fixed;
  z-index: 1;
}

.theme-anime-dream .entry-shell,
.theme-anime-dream .workspace-shell {
  position: relative;
  z-index: 2;
}

.theme-anime-dream .entry-shell {
  max-width: 1160px;
  grid-template-columns: minmax(320px, 480px) minmax(360px, 520px);
}

.theme-anime-dream .login-panel,
.theme-anime-dream .login-preview,
.theme-anime-dream .panel,
.theme-anime-dream .metric-card,
.theme-anime-dream .admin-overview article,
.theme-anime-dream .top-profile,
.theme-anime-dream .item {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(255, 242, 251, 0.76)),
    rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow:
    0 18px 48px rgba(143, 120, 255, 0.16),
    0 1px 0 rgba(255, 255, 255, 0.82) inset;
  color: var(--dream-ink);
  position: relative;
}

.theme-anime-dream .login-panel::before,
.theme-anime-dream .panel::before,
.theme-anime-dream .metric-card::before {
  background: linear-gradient(90deg, var(--sakura-pink), var(--star-violet), var(--mint-glow));
  border-radius: 999px;
  content: "";
  height: 3px;
  left: 16px;
  opacity: 0.72;
  position: absolute;
  right: 16px;
  top: 0;
}

.theme-anime-dream .brand-mark {
  background:
    radial-gradient(circle at 30% 22%, #fff 0 12%, transparent 13%),
    linear-gradient(135deg, var(--sakura-pink), var(--star-violet));
  border: 2px solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 24px rgba(255, 117, 183, 0.32);
  color: #fff;
  text-shadow: 0 2px 8px rgba(50, 39, 95, 0.28);
}

.theme-anime-dream .brand-line strong,
.theme-anime-dream .login-copy h1,
.theme-anime-dream .topbar h1,
.theme-anime-dream .workspace-heading h2,
.theme-anime-dream .panel h3 {
  color: var(--dream-ink);
  text-shadow: 0 2px 18px rgba(255, 255, 255, 0.82);
}

.theme-anime-dream .brand-line span,
.theme-anime-dream .eyebrow,
.theme-anime-dream label,
.theme-anime-dream .metric-card span,
.theme-anime-dream .task-meta,
.theme-anime-dream .top-profile span,
.theme-anime-dream .admin-overview span,
.theme-anime-dream .item p,
.theme-anime-dream .item small {
  color: var(--dream-muted);
}

.theme-anime-dream .eyebrow,
.theme-anime-dream .eyebrow.dark {
  color: #9c6af4;
}

.theme-anime-dream .compact-alert {
  background: rgba(255, 246, 216, 0.76);
  border-color: rgba(255, 214, 107, 0.6);
  color: #7a5519;
}

.theme-anime-dream .auth-switch {
  background: rgba(255, 255, 255, 0.66);
  border-color: var(--dream-line);
}

.theme-anime-dream .auth-switch button.active {
  background: linear-gradient(135deg, #fff, #fff0f8);
  box-shadow: 0 8px 18px rgba(255, 117, 183, 0.18);
  color: var(--sakura-pink);
}

.theme-anime-dream input,
.theme-anime-dream textarea,
.theme-anime-dream select {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(143, 120, 255, 0.22);
  color: var(--dream-ink);
}

.theme-anime-dream input:focus,
.theme-anime-dream textarea:focus,
.theme-anime-dream select:focus {
  border-color: var(--star-violet);
  box-shadow: 0 0 0 3px rgba(143, 120, 255, 0.14);
}

.theme-anime-dream .primary-button {
  background: linear-gradient(135deg, var(--sakura-pink), var(--star-violet));
  border: 0;
  box-shadow: 0 12px 26px rgba(255, 117, 183, 0.32);
  color: #fff;
}

.theme-anime-dream .secondary-button,
.theme-anime-dream .card-button {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(143, 120, 255, 0.24);
  color: var(--dream-ink);
}

.theme-anime-dream .card-button.danger {
  border-color: rgba(255, 117, 183, 0.46);
  color: #cf407f;
}

.theme-anime-dream .login-preview {
  overflow: hidden;
}

.theme-anime-dream .login-preview img {
  background: linear-gradient(135deg, #fff7fb, #edf5ff);
  border-color: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 34px rgba(143, 120, 255, 0.14);
}

.theme-anime-dream .preview-card {
  background: linear-gradient(135deg, rgba(255, 117, 183, 0.9), rgba(143, 120, 255, 0.88));
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 14px 30px rgba(143, 120, 255, 0.18);
}

.theme-anime-dream .preview-grid div,
.theme-anime-dream .task-toolbar span,
.theme-anime-dream .status-pill,
.theme-anime-dream .reward {
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(143, 120, 255, 0.18);
  color: var(--dream-ink);
}

.theme-anime-dream .status-pill,
.theme-anime-dream .reward,
.theme-anime-dream .metric-card strong {
  color: #8b5ce8;
}

.theme-anime-dream .reward {
  background: linear-gradient(135deg, rgba(255, 246, 216, 0.94), rgba(255, 226, 154, 0.74));
  color: #9c6710;
}

.theme-anime-dream .sidebar {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(255, 239, 248, 0.72)),
    rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(20px);
  border-right: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: 12px 0 34px rgba(143, 120, 255, 0.14);
  color: var(--dream-ink);
}

.theme-anime-dream .sidebar .brand-line span,
.theme-anime-dream .sidebar .side-card {
  color: var(--dream-muted);
}

.theme-anime-dream .side-nav button {
  background: rgba(255, 255, 255, 0.52);
  border-color: rgba(143, 120, 255, 0.12);
  color: var(--dream-muted);
}

.theme-anime-dream .side-nav button.active {
  background: linear-gradient(90deg, rgba(255, 117, 183, 0.18), rgba(143, 120, 255, 0.14));
  border-color: rgba(255, 117, 183, 0.34);
  color: var(--dream-ink);
}

.theme-anime-dream .side-card {
  background: rgba(255, 255, 255, 0.52);
  border-color: rgba(255, 214, 107, 0.32);
}

.theme-anime-dream .side-card span {
  color: var(--dream-ink);
}

.theme-anime-dream .info-tip,
.theme-anime-dream .info-dot {
  background: rgba(255, 255, 255, 0.74);
  border-color: rgba(143, 120, 255, 0.26);
  color: var(--star-violet);
  box-shadow: 0 8px 18px rgba(143, 120, 255, 0.12);
}

.theme-anime-dream .info-tip.light,
.theme-anime-dream .info-dot {
  background: rgba(255, 255, 255, 0.3);
  color: #fff;
}

.theme-anime-dream [data-tooltip]::after {
  background: var(--dream-ink);
  border: 1px solid rgba(255, 255, 255, 0.26);
  color: #fff;
  box-shadow: 0 18px 30px rgba(50, 39, 95, 0.22);
}

.theme-anime-dream .task-progress {
  background: rgba(143, 120, 255, 0.12);
}

.theme-anime-dream .task-progress span {
  background: linear-gradient(90deg, var(--sakura-pink), var(--reward-gold), var(--mint-glow));
  box-shadow: 0 0 14px rgba(255, 117, 183, 0.2);
}

.theme-anime-dream .toast {
  background: var(--dream-ink);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: 0 18px 34px rgba(50, 39, 95, 0.24);
}

.mascot-orb {
  align-items: center;
  background:
    radial-gradient(circle at 34% 24%, #fff 0 13%, transparent 14%),
    linear-gradient(135deg, #fff, #ffe8f5 44%, #e9e3ff);
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  box-shadow: 0 18px 40px rgba(255, 117, 183, 0.26);
  color: var(--sakura-pink);
  display: flex;
  font-size: 28px;
  font-weight: 900;
  height: 74px;
  justify-content: center;
  position: absolute;
  right: 22px;
  top: 22px;
  width: 74px;
  z-index: 2;
}

.mascot-orb::before,
.mascot-orb::after {
  background: #fff;
  border-radius: 999px;
  content: "";
  height: 18px;
  position: absolute;
  top: -4px;
  width: 30px;
}

.mascot-orb::before {
  left: 12px;
  transform: rotate(-28deg);
}

.mascot-orb::after {
  right: 12px;
  transform: rotate(28deg);
}

.sparkle-trail {
  background:
    radial-gradient(circle, rgba(255, 214, 107, 0.9) 0 18%, transparent 20%),
    radial-gradient(circle at 70% 24%, rgba(255, 117, 183, 0.74) 0 10%, transparent 12%),
    radial-gradient(circle at 28% 74%, rgba(133, 240, 223, 0.74) 0 9%, transparent 11%);
  height: 160px;
  pointer-events: none;
  position: absolute;
  right: 4px;
  top: 4px;
  width: 190px;
  z-index: 1;
}

@media (max-width: 980px) {
  .theme-anime-dream .entry-shell {
    grid-template-columns: 1fr;
  }

  .theme-anime-dream .sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.72);
  }
}

@media (max-width: 620px) {
  .anime-wallpaper {
    background-position: 58% center;
  }

  .mascot-orb {
    height: 56px;
    right: 16px;
    top: 16px;
    width: 56px;
  }
}

@media (max-width: 760px) {
  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .theme-anime-dream .h5-workspace {
    overflow-x: clip;
    width: 100%;
  }

  .theme-anime-dream .h5-workspace .sidebar {
    backdrop-filter: none;
    background: transparent;
    border: 0;
    box-shadow: none;
    color: var(--dream-ink);
  }

  .theme-anime-dream .h5-bottom-nav {
    background: rgba(255, 255, 255, 0.92);
    bottom: 0;
    left: 0;
    max-width: 100vw;
    position: fixed;
    right: 0;
    top: auto;
    transform: translateZ(0);
    width: 100vw;
  }

  .theme-anime-dream .workspace-main,
  .theme-anime-dream .panel,
  .theme-anime-dream .item,
  .theme-anime-dream .external-task-card {
    max-width: 100%;
    min-width: 0;
  }
}

.local-task-detail-panel {
  display: grid;
  gap: 14px;
}

.local-task-detail-panel.hidden {
  display: none;
}

.local-task-detail-card {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 244, 252, 0.82)),
    radial-gradient(circle at 14% 8%, rgba(255, 117, 183, 0.2), transparent 32%),
    radial-gradient(circle at 88% 18%, rgba(133, 240, 223, 0.2), transparent 30%);
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-radius: 18px;
  box-shadow: 0 24px 52px rgba(132, 79, 181, 0.18);
  display: grid;
  gap: 16px;
  overflow: hidden;
  padding: 18px;
  position: relative;
}

.local-task-detail-card::before {
  background: linear-gradient(90deg, var(--sakura-pink), var(--star-violet), var(--mint));
  content: "";
  height: 3px;
  left: 18px;
  position: absolute;
  right: 18px;
  top: 0;
}

.local-detail-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.local-detail-status {
  background: rgba(255, 248, 229, 0.9);
  border: 1px solid rgba(255, 206, 99, 0.48);
  border-radius: 14px;
  color: #6d4b12;
  display: grid;
  gap: 10px;
  padding: 12px;
}

.pdd-detail-section {
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(143, 120, 255, 0.16);
  border-radius: 14px;
  display: grid;
  gap: 10px;
  padding: 12px;
}

.pdd-detail-section h4 {
  color: var(--dream-ink);
  font-size: 14px;
  margin: 0;
}

.pdd-info-row {
  align-items: start;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 12px;
  display: grid;
  gap: 4px;
  grid-template-columns: 92px minmax(0, 1fr);
  padding: 10px;
}

.pdd-info-row strong {
  color: var(--dream-ink);
  font-size: 13px;
}

.pdd-info-row span {
  color: var(--dream-muted);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.pdd-proof-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.proof-upload-row {
  background: rgba(255, 255, 255, 0.7);
  border: 1px dashed rgba(143, 120, 255, 0.34);
  border-radius: 14px;
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 10px;
}

.proof-upload-row span {
  color: var(--dream-ink);
  font-size: 13px;
  font-weight: 800;
}

.proof-upload-row input[type="file"] {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(143, 120, 255, 0.18);
  border-radius: 10px;
  color: var(--dream-muted);
  font-size: 12px;
  min-width: 0;
  padding: 8px;
}

.local-detail-proof-form {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 16px;
  padding: 12px;
}

@media (max-width: 620px) {
  .local-task-detail-card {
    border-radius: 14px;
    padding: 14px;
  }

  .pdd-info-row {
    grid-template-columns: 1fr;
  }
}
