@import url('https://fonts.googleapis.com/css2?family=Sora:wght@400;500;600;700;800&family=Noto+Sans+SC:wght@400;500;700;800&display=swap');

:root {
    --bg: #f6f0e6;
    --bg-deep: #ede2d0;
    --surface: rgba(255, 251, 245, 0.82);
    --surface-solid: #fffaf2;
    --surface-muted: #f5ecdf;
    --surface-dark: #182126;
    --surface-dark-soft: #23313a;
    --text: #171412;
    --text-soft: #62584e;
    --text-faint: #8a7d71;
    --line: rgba(51, 39, 28, 0.10);
    --line-strong: rgba(51, 39, 28, 0.18);
    --brand: #214d43;
    --brand-strong: #163730;
    --brand-soft: #dceae5;
    --accent: #b56f3c;
    --accent-strong: #8f5227;
    --accent-soft: #f3e3d4;
    --ok: #2b734f;
    --ok-soft: #e4f3e8;
    --warn: #9c6a2b;
    --warn-soft: #f8eddc;
    --err: #b14c42;
    --err-soft: #f8e6e2;
    --radius: 30px;
    --radius-lg: 38px;
    --radius-md: 22px;
    --radius-sm: 16px;
    --shadow: 0 20px 50px rgba(44, 28, 16, 0.08);
    --shadow-strong: 0 30px 100px rgba(27, 17, 10, 0.14);
    --content-width: 1180px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    min-height: 100%;
}

body {
    font-family: "Sora", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
    background:
        radial-gradient(circle at 12% 12%, rgba(181, 111, 60, 0.14), transparent 26%),
        radial-gradient(circle at 78% 0%, rgba(33, 77, 67, 0.12), transparent 24%),
        radial-gradient(circle at 100% 90%, rgba(33, 77, 67, 0.08), transparent 22%),
        linear-gradient(180deg, #f8f2e8 0%, #efe4d3 100%);
    color: var(--text);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

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

button {
    cursor: pointer;
    border: 0;
    background: none;
}

img {
    display: block;
    max-width: 100%;
}

ul {
    list-style: none;
}

[hidden] {
    display: none !important;
}

.app-shell {
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
    overflow-y: visible;
}

body.overlay-open {
    overflow: hidden;
}

.ambient {
    position: fixed;
    z-index: 0;
    border-radius: 999px;
    filter: blur(44px);
    opacity: 0.72;
    pointer-events: none;
}

.ambient-one {
    top: -120px;
    right: -110px;
    width: 340px;
    height: 340px;
    background: rgba(33, 77, 67, 0.16);
}

.ambient-two {
    bottom: 90px;
    left: -110px;
    width: 280px;
    height: 280px;
    background: rgba(181, 111, 60, 0.16);
}

.ambient-three {
    top: 34%;
    left: 42%;
    width: 180px;
    height: 180px;
    background: rgba(255, 255, 255, 0.22);
}

.topbar,
.main-content,
.bottom-tabs {
    position: relative;
    z-index: 1;
}

.topbar {
    position: sticky;
    top: 0;
    backdrop-filter: blur(18px);
    background: rgba(248, 242, 233, 0.70);
    border-bottom: 1px solid rgba(51, 39, 28, 0.08);
}

.topbar-inner {
    width: min(var(--content-width), calc(100% - 32px));
    margin: 0 auto;
    min-height: 80px;
    display: flex;
    align-items: center;
    gap: 28px;
}

.brand,
.auth-brand {
    display: flex;
    align-items: center;
    gap: 14px;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    background:
        linear-gradient(145deg, #234d45 0%, #b56f3c 100%);
    color: #fff;
    font-size: 18px;
    font-weight: 800;
    box-shadow: 0 14px 30px rgba(33, 77, 67, 0.24);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.brand-copy strong {
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.brand-copy small {
    color: var(--text-faint);
    font-size: 12px;
}

.topnav {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
}

.topnav a {
    padding: 10px 16px;
    border-radius: 999px;
    color: var(--text-soft);
    font-size: 14px;
    font-weight: 600;
    transition: 0.2s ease;
}

.topnav a:hover,
.topnav a.active {
    background: rgba(33, 77, 67, 0.08);
    color: var(--brand);
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.member-chip {
    display: inline-flex;
    flex-direction: column;
    gap: 2px;
    padding: 9px 14px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(33, 77, 67, 0.10), rgba(181, 111, 60, 0.12));
    border: 1px solid rgba(51, 39, 28, 0.08);
    color: var(--text-soft);
    line-height: 1.2;
}

.member-chip-button {
    appearance: none;
    border: 0;
    cursor: pointer;
    font: inherit;
    text-align: left;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.member-chip-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 30px rgba(23, 32, 28, 0.10);
    border-color: rgba(33, 77, 67, 0.16);
}

.member-chip-label {
    font-size: 11px;
    color: var(--text-faint);
}

.member-chip strong {
    font-size: 13px;
    color: var(--text);
}

.user-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(41, 33, 25, 0.08);
    color: var(--text-soft);
    font-size: 13px;
}

.user-dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--brand);
}

.main-content {
    width: min(var(--content-width), calc(100% - 32px));
    margin: 0 auto;
    padding: 38px 0 60px;
}

.flash-stack {
    display: grid;
    gap: 12px;
    margin-bottom: 20px;
}

.flash-toast {
    position: fixed;
    top: calc(82px + env(safe-area-inset-top, 0px));
    left: 50%;
    width: min(420px, calc(100vw - 32px));
    z-index: 1200;
    pointer-events: none;
    transform: translate3d(-50%, 0, 0);
    animation: toast-slide-in 0.22s ease both;
}

.flash-toast.is-hiding {
    animation: toast-slide-out 0.22s ease both;
}

.alert {
    position: relative;
    border-radius: var(--radius-md);
    padding: 16px 18px;
    border: 1px solid transparent;
    box-shadow: var(--shadow);
}

.flash-toast .alert {
    pointer-events: auto;
    padding-right: 48px;
}

.alert-success {
    background: var(--ok-soft);
    border-color: rgba(36, 113, 77, 0.15);
    color: var(--ok);
}

.alert-error {
    background: var(--err-soft);
    border-color: rgba(178, 75, 68, 0.12);
    color: var(--err);
}

.alert-title {
    font-weight: 700;
    margin-bottom: 8px;
}

.toast-close {
    position: absolute;
    top: 10px;
    right: 10px;
    border: 0;
    background: transparent;
    color: inherit;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    padding: 4px;
    opacity: 0.68;
}

.toast-close:hover {
    opacity: 1;
}

@keyframes toast-slide-in {
    from {
        opacity: 0;
        transform: translate3d(-50%, -10px, 0);
    }

    to {
        opacity: 1;
        transform: translate3d(-50%, 0, 0);
    }
}

@keyframes toast-slide-out {
    from {
        opacity: 1;
        transform: translate3d(-50%, 0, 0);
    }

    to {
        opacity: 0;
        transform: translate3d(-50%, -10px, 0);
    }
}

.alert ul {
    display: grid;
    gap: 4px;
    padding-left: 2px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--brand);
    background: rgba(33, 77, 67, 0.08);
    border: 1px solid rgba(33, 77, 67, 0.10);
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.page-title {
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.page-sub {
    color: var(--text-soft);
    font-size: 15px;
}

.section-block {
    margin-top: 28px;
}

.section-heading {
    max-width: 760px;
    margin-bottom: 20px;
}

.section-heading h2 {
    margin-top: 14px;
    font-size: clamp(26px, 4vw, 38px);
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.section-heading p {
    margin-top: 12px;
    color: var(--text-soft);
}

.hero-panel,
.dashboard-hero,
.workspace-hero {
    background:
        linear-gradient(140deg, rgba(255, 250, 243, 0.96) 0%, rgba(241, 232, 219, 0.88) 100%);
    border: 1px solid rgba(51, 39, 28, 0.08);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-strong);
    position: relative;
    overflow: hidden;
}

.hero-panel::before,
.dashboard-hero::before,
.workspace-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(120deg, rgba(255, 255, 255, 0.18), transparent 38%),
        radial-gradient(circle at right top, rgba(181, 111, 60, 0.14), transparent 28%);
    pointer-events: none;
}

.hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
    gap: 32px;
    padding: 38px;
}

.hero-panel-premium .hero-copy {
    position: relative;
    z-index: 1;
}

.hero-copy h1 {
    margin-top: 18px;
    font-size: clamp(36px, 6vw, 68px);
    line-height: 1.02;
    letter-spacing: -0.06em;
    max-width: 760px;
}

.hero-copy p {
    max-width: 640px;
    margin-top: 18px;
    color: var(--text-soft);
    font-size: 16px;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 24px;
}

.hero-actions form,
.workspace-actions form,
.work-actions form {
    display: inline-flex;
}

.hero-side {
    display: grid;
    gap: 18px;
}

.hero-metric-card,
.hero-summary-card,
.stat-card,
.feature,
.journey-step,
.account-card,
.work-card,
.batch-status-card,
.preview-panel,
.drawer-panel,
.toolbar,
.empty-state,
.auth-panel {
    background: rgba(255, 251, 245, 0.74);
    border: 1px solid rgba(51, 39, 28, 0.08);
    box-shadow: var(--shadow);
}

.hero-metric-card,
.hero-summary-card {
    border-radius: var(--radius);
    padding: 24px;
    position: relative;
}

.spotlight-card {
    backdrop-filter: blur(10px);
}

.spotlight-card::after {
    content: "";
    position: absolute;
    inset: 1px;
    border-radius: inherit;
    border: 1px solid rgba(255, 255, 255, 0.45);
    pointer-events: none;
}

.hero-metric-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--text-soft);
    font-size: 14px;
}

.hero-metric-head strong {
    color: var(--text);
    font-weight: 700;
}

.hero-metric-grid {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.hero-metric-grid div {
    padding: 18px;
    border-radius: var(--radius-md);
    background: linear-gradient(180deg, rgba(255,255,255,0.88), rgba(245, 237, 226, 0.94));
    border: 1px solid rgba(51, 39, 28, 0.06);
}

.hero-metric-grid strong {
    display: block;
    font-size: 24px;
    color: var(--brand);
}

.hero-metric-grid span {
    display: block;
    margin-top: 6px;
    color: var(--text-soft);
    font-size: 13px;
}

.stats-grid {
    margin-top: 22px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.stats-grid.compact {
    margin-top: 16px;
}

.stat-card {
    border-radius: var(--radius);
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: "";
    position: absolute;
    inset: auto -10% -55% auto;
    width: 140px;
    height: 140px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(181, 111, 60, 0.12), transparent 70%);
    pointer-events: none;
}

.stat-card strong {
    display: block;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1;
    font-weight: 800;
}

.stat-card span {
    display: block;
    margin-top: 10px;
    color: var(--text-soft);
    font-size: 14px;
}

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

.feature-grid.refined {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature {
    border-radius: var(--radius);
    padding: 24px;
}

.feature-wide {
    grid-column: span 3;
    display: grid;
    gap: 10px;
    background: linear-gradient(135deg, rgba(33, 77, 67, 0.09), rgba(181, 111, 60, 0.12));
}

.feature-tag {
    display: inline-flex;
    width: fit-content;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.66);
    color: var(--brand);
    font-size: 12px;
    font-weight: 700;
}

.feature h3 {
    margin-top: 12px;
    font-size: 20px;
    line-height: 1.3;
}

.feature p {
    margin-top: 10px;
    color: var(--text-soft);
    font-size: 14px;
}

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

.journey-step {
    border-radius: var(--radius);
    padding: 24px;
}

.journey-step strong {
    display: inline-flex;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(33, 77, 67, 0.10), rgba(181, 111, 60, 0.12));
    color: var(--brand);
    font-size: 14px;
}

.journey-step h3 {
    margin-top: 18px;
    font-size: 20px;
}

.journey-step p {
    margin-top: 10px;
    color: var(--text-soft);
    font-size: 14px;
}

.dashboard-hero,
.workspace-hero {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    align-items: flex-start;
    padding: 30px;
}

.workspace-hero {
    align-items: flex-end;
}

.workspace-hero-main,
.workspace-hero-title,
.workspace-actions {
    display: grid;
    gap: 14px;
}

.workspace-hero-title {
    align-items: start;
}

.crumb-link {
    color: var(--text-faint);
    font-size: 14px;
    transition: 0.2s ease;
}

.crumb-link:hover {
    color: var(--brand);
}

.toolbar {
    padding: 20px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 16px;
    justify-content: space-between;
    margin-bottom: 18px;
}

.toolbar-main {
    flex: 1;
}

.toolbar-search {
    background: rgba(255,255,255,0.76);
}

.toolbar-filters {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-chip {
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--text-soft);
    background: rgba(255,255,255,0.72);
    border: 1px solid rgba(41, 33, 25, 0.08);
    font-size: 13px;
    font-weight: 700;
    transition: 0.2s ease;
}

.filter-chip:hover,
.filter-chip.is-active {
    background: var(--brand);
    color: #fff;
    border-color: var(--brand);
    box-shadow: 0 10px 24px rgba(33, 77, 67, 0.18);
}

.account-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 18px;
}

.account-card {
    display: grid;
    gap: 20px;
    border-radius: var(--radius);
    padding: 22px;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    position: relative;
    overflow: hidden;
}

.account-card:hover {
    transform: translateY(-6px);
    border-color: rgba(33, 77, 67, 0.18);
    box-shadow: var(--shadow-strong);
}

.account-card::after {
    content: "";
    position: absolute;
    inset: auto -35px -35px auto;
    width: 130px;
    height: 130px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(33, 77, 67, 0.10), transparent 72%);
    pointer-events: none;
}

.account-card-head,
.account-card-foot,
.preview-panel-head,
.work-main-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.account-avatar {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(33, 77, 67, 0.14), rgba(181, 111, 60, 0.18));
    color: var(--brand);
    font-weight: 800;
    letter-spacing: 0.06em;
    overflow: hidden;
}

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

.account-card-body h3 {
    font-size: 22px;
    line-height: 1.2;
}

.account-card-body p {
    margin-top: 10px;
    color: var(--text-soft);
    font-size: 14px;
}

.account-card-foot {
    color: var(--text-faint);
    font-size: 13px;
    font-weight: 600;
}

.batch-status-card {
    margin-top: 18px;
    border-radius: var(--radius);
    padding: 18px 20px;
}

.work-list {
    display: grid;
    gap: 18px;
}

.work-card {
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(255, 251, 245, 0.82);
}

.work-card-top {
    display: grid;
    grid-template-columns: 136px minmax(0, 1fr);
    gap: 20px;
    padding: 22px;
}

.work-cover-wrap {
    position: relative;
}

.work-cover,
.work-cover-ph {
    width: 100%;
    aspect-ratio: 4 / 5;
    border-radius: 22px;
    object-fit: cover;
    background: linear-gradient(135deg, rgba(33,77,67,0.10), rgba(181,111,60,0.14));
}

.work-cover-ph {
    display: grid;
    place-items: center;
    color: var(--brand);
    font-size: 28px;
    font-weight: 800;
}

.work-main {
    display: grid;
    gap: 14px;
    min-width: 0;
}

.work-title {
    font-size: 22px;
    line-height: 1.25;
}

.work-desc {
    color: var(--text-soft);
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.work-meta,
.drawer-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    color: var(--text-faint);
    font-size: 13px;
}

.text-link {
    color: var(--brand);
    font-weight: 700;
}

.text-link:hover,
.btn-text:hover {
    color: var(--brand-strong);
}

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

.work-foot {
    border-top: 1px solid rgba(41, 33, 25, 0.08);
    padding: 18px 22px 22px;
    display: grid;
    gap: 14px;
}

.preview-panel {
    border-radius: var(--radius-md);
    padding: 18px;
}

.preview-panel.muted {
    background: rgba(255, 249, 241, 0.78);
}

.preview-panel h3 {
    margin-top: 10px;
    font-size: 18px;
}

.preview-panel p {
    margin-top: 8px;
    color: var(--text-soft);
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.mini-inspiration-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255,255,255,0.72);
    border: 1px solid rgba(41, 33, 25, 0.08);
}

.mini-inspiration-item strong {
    display: block;
    font-size: 15px;
}

.mini-inspiration-item span {
    display: block;
    margin-top: 6px;
    color: var(--text-soft);
    font-size: 13px;
}

.status-error-box {
    display: none;
    padding: 14px 16px;
    border-radius: 18px;
    background: var(--err-soft);
    color: var(--err);
    font-size: 14px;
}

.status-error-box.is-visible {
    display: block;
}

.progress-card {
    display: none;
    padding: 16px;
    border-radius: 18px;
    border: 1px solid rgba(33, 77, 67, 0.10);
    background: linear-gradient(180deg, rgba(255,255,255,0.88) 0%, rgba(234, 242, 239, 0.78) 100%);
}

.progress-card.is-visible {
    display: block;
}

.progress-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    font-size: 13px;
}

.progress-head strong {
    color: var(--text);
}

.progress-head span {
    color: var(--brand);
    font-weight: 800;
}

.progress-track {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: rgba(31, 79, 70, 0.10);
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--brand) 0%, var(--accent) 100%);
    transition: width 0.35s ease;
}

.progress-sub {
    margin-top: 10px;
    color: var(--text-soft);
    font-size: 13px;
}

.drawer-mask,
.modal-mask {
    position: fixed;
    inset: 0;
    display: none;
    padding: clamp(16px, 3vw, 28px);
    z-index: 500;
    background: rgba(23, 18, 13, 0.50);
    backdrop-filter: blur(14px);
    overflow-y: auto;
    overscroll-behavior: contain;
    place-items: center;
}

.drawer-mask.show,
.modal-mask.show {
    display: grid;
}

.drawer-mask {
    align-items: center;
    justify-items: center;
}

.modal-mask {
    align-items: center;
    justify-items: center;
}

.drawer {
    width: min(920px, 100%);
    max-height: calc(100vh - 56px);
    background: var(--surface-solid);
    border-radius: 32px;
    border: 1px solid rgba(51, 39, 28, 0.08);
    box-shadow: var(--shadow-strong);
    display: grid;
    grid-template-rows: auto 1fr;
    overflow: hidden;
    align-self: center;
    justify-self: center;
}

.drawer-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    padding: 24px 24px 18px;
    border-bottom: 1px solid rgba(41, 33, 25, 0.08);
}

.drawer-head h2 {
    margin-top: 10px;
    font-size: 28px;
    line-height: 1.15;
}

.drawer-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 56px;
    min-height: 34px;
    padding: 0 10px;
    flex-shrink: 0;
    white-space: nowrap;
    color: var(--text-soft);
    font-size: 14px;
    line-height: 1;
}

.drawer-body {
    overflow: auto;
    padding: 22px;
    display: grid;
    gap: 16px;
}

.drawer-panel {
    border-radius: 24px;
    padding: 20px;
}

.drawer-panel-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.drawer-panel-head h3,
.drawer-panel-head h4 {
    font-size: 18px;
}

.drawer-desc {
    margin-top: 12px;
    color: var(--text-soft);
}

.drawer-content {
    margin-top: 14px;
    white-space: pre-wrap;
    font-size: 14px;
    color: var(--text-soft);
}

.drawer-count {
    color: var(--text-faint);
    font-size: 13px;
}

.drawer-inspirations {
    margin-top: 14px;
    display: grid;
    gap: 12px;
}

.drawer-inspiration-item {
    padding: 16px;
    border-radius: 18px;
    background: rgba(255,255,255,0.72);
    border: 1px solid rgba(41, 33, 25, 0.08);
}

.drawer-inspiration-item p {
    margin-top: 10px;
    color: var(--text-soft);
    font-size: 14px;
}

.modal {
    width: min(520px, 100%);
    border-radius: 30px;
    background: var(--surface-solid);
    border: 1px solid rgba(51, 39, 28, 0.08);
    box-shadow: var(--shadow-strong);
    padding: 28px;
    max-height: calc(100vh - 56px);
    overflow: auto;
    align-self: center;
    justify-self: center;
}

.modal-wide {
    width: min(620px, 100%);
}

.membership-modal {
    display: grid;
    gap: 20px;
}

.membership-modal-wide {
    width: min(1080px, 100%);
    padding: 24px;
}

.membership-modal-head,
.membership-service-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
}

.membership-period-switch {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.76);
    border: 1px solid rgba(51, 39, 28, 0.08);
}

.membership-period-switch button {
    border: 0;
    background: transparent;
    color: var(--text-soft);
    padding: 10px 18px;
    border-radius: 999px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: 0.18s ease;
}

.membership-period-switch button.is-active {
    background: linear-gradient(135deg, #214d43, #183730);
    color: #fff;
    box-shadow: 0 10px 24px rgba(33, 77, 67, 0.22);
}

.membership-sheet-wrap {
    overflow-x: auto;
    padding-bottom: 2px;
}

.membership-sheet {
    min-width: 900px;
    display: grid;
    grid-template-columns: 180px repeat(3, minmax(220px, 1fr));
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid rgba(51, 39, 28, 0.08);
    background: rgba(255, 251, 245, 0.84);
    box-shadow: var(--shadow);
}

.membership-sheet-feature,
.membership-sheet-cell,
.membership-sheet-plan {
    border-right: 1px solid rgba(51, 39, 28, 0.06);
    border-bottom: 1px solid rgba(51, 39, 28, 0.06);
}

.membership-sheet > :nth-child(4n) {
    border-right: 0;
}

.membership-sheet-feature {
    padding: 20px 18px;
    background: rgba(247, 241, 231, 0.92);
    color: var(--text);
    font-size: 14px;
    font-weight: 800;
    display: flex;
    align-items: center;
}

.membership-sheet-header {
    justify-content: center;
    font-size: 15px;
}

.membership-sheet-cell {
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    font-size: 14px;
    color: var(--text-soft);
    background: rgba(255, 255, 255, 0.78);
}

.membership-sheet-cell small {
    color: var(--text-faint);
    font-size: 12px;
}

.membership-sheet-plan {
    padding: 20px;
    display: grid;
    gap: 12px;
    align-content: start;
    background:
        radial-gradient(circle at top right, rgba(255, 216, 168, 0.18), transparent 34%),
        rgba(255, 255, 255, 0.84);
}

.membership-sheet-plan.is-current {
    background:
        radial-gradient(circle at top right, rgba(33, 77, 67, 0.16), transparent 34%),
        linear-gradient(180deg, rgba(246, 253, 250, 0.92), rgba(255, 255, 255, 0.88));
}

.membership-plan-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-height: 28px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(33, 77, 67, 0.10);
    color: var(--brand);
    font-size: 12px;
    font-weight: 800;
}

.membership-sheet-plan h3 {
    margin: 0;
    font-size: 22px;
    color: var(--text);
}

.membership-plan-price {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    color: var(--text);
}

.membership-plan-currency {
    font-size: 18px;
    font-weight: 800;
    transform: translateY(-4px);
}

.membership-plan-price strong {
    font-size: 42px;
    line-height: 0.9;
    letter-spacing: -0.04em;
}

.membership-plan-price-sub {
    color: var(--text-soft);
    font-size: 13px;
    font-weight: 700;
}

.membership-plan-note {
    color: var(--text-faint);
    font-size: 13px;
    min-height: 36px;
}

.membership-plan-btn {
    margin-top: 4px;
}

.membership-plan-btn[disabled] {
    opacity: 1;
    cursor: default;
}

.membership-modal-foot {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    color: var(--text-faint);
    font-size: 13px;
}

.membership-service-modal {
    width: min(440px, 100%);
    display: grid;
    gap: 16px;
}

.membership-service-qr-wrap {
    display: grid;
    place-items: center;
    padding: 10px 0 4px;
}

.membership-service-qr {
    width: min(280px, 78vw);
    max-width: 100%;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 16px 36px rgba(20, 18, 15, 0.14);
}

.membership-service-note {
    text-align: center;
    color: var(--text);
    font-size: 14px;
    font-weight: 700;
}

body.template-app-mobile .membership-modal-mobile {
    width: min(100%, 520px);
    padding: 20px;
    gap: 16px;
}

body.template-app-mobile .membership-period-switch-mobile {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
}

body.template-app-mobile .membership-period-switch-mobile::-webkit-scrollbar {
    display: none;
}

body.template-app-mobile .membership-period-switch-mobile button {
    flex: 0 0 auto;
    white-space: nowrap;
}

body.template-app-mobile .membership-mobile-plan-list {
    display: grid;
    gap: 14px;
}

body.template-app-mobile .membership-sheet-plan-mobile {
    border: 1px solid rgba(51, 39, 28, 0.08);
    border-radius: 24px;
    padding: 18px;
    background:
        radial-gradient(circle at top right, rgba(255, 216, 168, 0.16), transparent 34%),
        rgba(255, 255, 255, 0.84);
    display: grid;
    gap: 14px;
}

body.template-app-mobile .membership-sheet-plan-mobile.is-current {
    background:
        radial-gradient(circle at top right, rgba(33, 77, 67, 0.14), transparent 34%),
        linear-gradient(180deg, rgba(246, 253, 250, 0.94), rgba(255, 255, 255, 0.88));
}

body.template-app-mobile .membership-mobile-plan-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

body.template-app-mobile .membership-mobile-plan-copy {
    display: grid;
    gap: 10px;
}

body.template-app-mobile .membership-mobile-current {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(33, 77, 67, 0.10);
    color: var(--brand);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}

body.template-app-mobile .membership-mobile-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

body.template-app-mobile .membership-mobile-fact {
    padding: 14px;
    border-radius: 16px;
    background: rgba(255, 251, 245, 0.86);
    border: 1px solid rgba(51, 39, 28, 0.06);
    display: grid;
    gap: 6px;
}

body.template-app-mobile .membership-mobile-fact span {
    color: var(--text-soft);
    font-size: 12px;
}

body.template-app-mobile .membership-mobile-fact strong {
    color: var(--text);
    font-size: 15px;
    line-height: 1.45;
}

body.template-app-mobile .membership-mobile-open-way {
    color: var(--text-soft);
    font-size: 13px;
    line-height: 1.7;
}

body.template-app-mobile .membership-service-modal-mobile {
    width: min(100%, 420px);
}

.modal-title {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.modal-sub {
    margin-top: 8px;
    color: var(--text-soft);
    font-size: 14px;
}

.modal-actions {
    margin-top: 18px;
    display: flex;
    gap: 12px;
}

.modal-actions .btn {
    flex: 1;
}

.field {
    margin-top: 18px;
}

.field label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 700;
}

.input,
.textarea,
select.input {
    width: 100%;
    border-radius: 18px;
    border: 1px solid rgba(41, 33, 25, 0.12);
    background: rgba(255,255,255,0.76);
    padding: 14px 16px;
    color: var(--text);
    transition: 0.2s ease;
}

.textarea {
    min-height: 120px;
    resize: vertical;
}

.input:focus,
.textarea:focus,
select.input:focus {
    outline: none;
    border-color: rgba(31, 79, 70, 0.28);
    box-shadow: 0 0 0 4px rgba(31, 79, 70, 0.10);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--brand) 0%, var(--accent) 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    transition: 0.2s ease;
}

.btn:hover {
    background: linear-gradient(135deg, var(--brand-strong) 0%, var(--accent-strong) 100%);
}

.btn-lg {
    min-height: 52px;
    padding-inline: 24px;
}

.btn-sm {
    padding: 9px 14px;
    font-size: 13px;
}

.btn-line {
    background: rgba(255,255,255,0.76);
    color: var(--text-soft);
    border: 1px solid rgba(41, 33, 25, 0.10);
}

.btn-line:hover {
    background: rgba(255,255,255,0.96);
    color: var(--brand);
    border-color: rgba(31, 79, 70, 0.18);
}

.btn-ghost {
    background: var(--brand-soft);
    color: var(--brand);
}

.btn-ghost:hover {
    background: #d4e6df;
}

.btn-danger-soft {
    background: var(--err-soft);
    color: var(--err);
}

.btn-danger-soft:hover {
    background: #f3d9d5;
}

.btn-block {
    width: 100%;
}

.btn-text {
    color: var(--text-faint);
    font-size: 13px;
    font-weight: 700;
}

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    background: rgba(41, 33, 25, 0.06);
    color: var(--text-soft);
}

.badge-douyin {
    background: #171717;
    color: #fff;
}

.badge-kuaishou {
    background: #ff7b2d;
    color: #fff;
}

.badge-ok {
    background: var(--ok-soft);
    color: var(--ok);
}

.badge-processing {
    background: var(--brand-soft);
    color: var(--brand);
}

.badge-wait {
    background: var(--warn-soft);
    color: var(--warn);
}

.badge-err {
    background: var(--err-soft);
    color: var(--err);
}

.empty-state {
    margin-top: 18px;
    border-radius: var(--radius);
    padding: 40px 26px;
    text-align: center;
}

.empty-mark {
    width: 68px;
    height: 68px;
    margin: 0 auto 18px;
    display: grid;
    place-items: center;
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(31, 79, 70, 0.12), rgba(197, 122, 71, 0.16));
    color: var(--brand);
    font-size: 28px;
    font-weight: 800;
}

.empty-state h2 {
    font-size: 28px;
    letter-spacing: -0.03em;
}

.empty-state p {
    max-width: 560px;
    margin: 12px auto 20px;
    color: var(--text-soft);
}

.empty-inline {
    margin-top: 16px;
    text-align: center;
    color: var(--text-faint);
    font-size: 14px;
}

.auth-layout {
    position: relative;
    min-height: 100vh;
    padding: 28px 16px;
    display: grid;
    place-items: center;
    overflow: hidden;
    background:
        radial-gradient(circle at 18% 16%, rgba(33, 77, 67, 0.14), transparent 30%),
        radial-gradient(circle at 80% 82%, rgba(181, 111, 60, 0.16), transparent 26%),
        linear-gradient(180deg, #f8f2e8 0%, #ece1cf 100%);
}

.auth-layout::before,
.auth-layout::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
    filter: blur(4px);
}

.auth-layout::before {
    width: 320px;
    height: 320px;
    top: -120px;
    left: -80px;
    background: rgba(33, 77, 67, 0.14);
}

.auth-layout::after {
    width: 360px;
    height: 360px;
    right: -140px;
    bottom: -140px;
    background: rgba(181, 111, 60, 0.16);
}

.auth-panel {
    position: relative;
    z-index: 1;
    width: min(560px, 100%);
    padding: 38px;
    margin: 0;
    border-radius: 36px;
    background: rgba(255, 250, 243, 0.88);
    backdrop-filter: blur(14px);
    box-shadow: var(--shadow-strong);
    display: grid;
    gap: 24px;
}

.auth-panel-centered {
    align-self: center;
}

.auth-brand-centered {
    justify-content: center;
    margin-bottom: 0;
}

.auth-intro {
    display: grid;
    gap: 14px;
    text-align: center;
}

.auth-intro .eyebrow {
    margin: 0 auto;
}

.auth-intro h1 {
    margin: 0;
    font-size: clamp(30px, 4.5vw, 42px);
    line-height: 1.08;
    letter-spacing: -0.05em;
}

.auth-intro p {
    max-width: 460px;
    margin: 0 auto;
    color: var(--text-soft);
}

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

.auth-point {
    display: grid;
    justify-items: center;
    align-content: start;
    gap: 12px;
    min-height: 116px;
    padding: 18px 14px;
    text-align: center;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(51, 39, 28, 0.08);
}

.auth-point strong {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--brand-soft);
    color: var(--brand);
}

.auth-point span {
    color: var(--text-soft);
    font-size: 13px;
    line-height: 1.5;
}

.auth-panel .alert {
    margin: 0;
}

.auth-brand {
    margin-bottom: 28px;
}

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

.btn-code {
    padding: 0 18px;
    border-radius: 18px;
    background: var(--brand-soft);
    color: var(--brand);
    font-weight: 700;
}

.btn-code:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.dev-tip {
    min-height: 20px;
    margin-top: 8px;
    color: var(--accent);
    font-size: 12px;
    font-weight: 700;
}

.mobile-topbar {
    position: sticky;
    top: 0;
    z-index: 45;
    backdrop-filter: blur(18px);
    background: rgba(248, 242, 233, 0.84);
    border-bottom: 1px solid rgba(51, 39, 28, 0.08);
}

.mobile-topbar-inner {
    width: min(920px, calc(100% - 24px));
    margin: 0 auto;
    min-height: 72px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.mobile-topbar-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mobile-topbar-link,
.mobile-topbar-member {
    min-height: 40px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    font-size: 13px;
    font-weight: 700;
    transition: 0.2s ease;
}

.mobile-topbar-link {
    background: rgba(33, 77, 67, 0.08);
    color: var(--brand);
}

.mobile-topbar-link.active {
    background: var(--brand);
    color: #fff;
}

.mobile-topbar-member {
    gap: 8px;
    border: 1px solid rgba(51, 39, 28, 0.08);
    background: linear-gradient(135deg, rgba(33, 77, 67, 0.10), rgba(181, 111, 60, 0.12));
    color: var(--text);
}

body.template-app-mobile .main-content {
    width: min(920px, calc(100% - 24px));
    padding: 20px 0 98px;
}

body.template-app-mobile .bottom-tabs {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 60;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 10px;
    border-radius: 22px;
    background: rgba(255, 250, 243, 0.94);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(51, 39, 28, 0.08);
    box-shadow: var(--shadow);
}

body.template-app-mobile .bottom-tabs > a,
body.template-app-mobile .bottom-tabs button {
    display: grid;
    place-items: center;
    min-height: 42px;
    border-radius: 14px;
    color: var(--text-soft);
    font-size: 13px;
    font-weight: 700;
}

body.template-app-mobile .bottom-tabs > a.active,
body.template-app-mobile .bottom-tabs button:active {
    background: var(--brand);
    color: #fff;
}

.auth-layout-mobile {
    padding-top: 22px;
    padding-bottom: 22px;
}

.bottom-tabs {
    display: none;
}

.tab-form button {
    width: 100%;
    height: 100%;
}

@media (max-width: 1080px) {
    .hero-panel {
        grid-template-columns: 1fr;
    }

    .journey-grid,
    .feature-grid.refined,
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .feature-wide {
        grid-column: span 2;
    }
}

@media (max-width: 820px) {
    .topbar {
        display: none;
    }

    .mobile-topbar-inner {
        width: min(100%, calc(100% - 24px));
    }

    .main-content {
        width: min(var(--content-width), calc(100% - 24px));
        padding: 18px 0 96px;
    }

    .dashboard-hero,
    .workspace-hero,
    .hero-panel,
    .toolbar,
    .work-card-top,
    .modal-actions,
    .account-card-foot,
    .preview-panel-head,
    .work-main-head {
        grid-template-columns: 1fr;
        display: grid;
    }

    .dashboard-hero,
    .workspace-hero {
        padding: 22px;
    }

    .workspace-hero {
        align-items: stretch;
    }

    .hero-copy h1,
    .page-title {
        font-size: clamp(30px, 8vw, 42px);
    }

    .stats-grid,
    .journey-grid,
    .feature-grid.refined {
        grid-template-columns: 1fr;
    }

    .feature-wide {
        grid-column: span 1;
    }

    .work-card-top {
        gap: 16px;
    }

    .work-cover-wrap {
        max-width: 160px;
    }

    .drawer-mask {
        padding: 12px;
    }

    .drawer {
        width: 100%;
        max-height: calc(100vh - 24px);
        border-radius: 26px;
    }

    .auth-layout {
        padding: 16px;
    }

    .auth-panel {
        padding: 24px;
    }

    .mobile-topbar-actions {
        gap: 8px;
    }

    .mobile-topbar-member {
        padding: 0 12px;
    }

    .auth-point-grid {
        grid-template-columns: 1fr;
    }

    .bottom-tabs {
        position: fixed;
        left: 12px;
        right: 12px;
        bottom: 12px;
        z-index: 60;
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
        padding: 10px;
        border-radius: 22px;
        background: rgba(255, 250, 243, 0.94);
        backdrop-filter: blur(16px);
        border: 1px solid rgba(51, 39, 28, 0.08);
        box-shadow: var(--shadow);
    }

    .bottom-tabs > a,
    .bottom-tabs button {
        display: grid;
        place-items: center;
        min-height: 42px;
        border-radius: 14px;
        color: var(--text-soft);
        font-size: 13px;
        font-weight: 700;
    }

    .bottom-tabs > a.active,
    .bottom-tabs button:active {
        background: var(--brand);
        color: #fff;
    }
}

.hero-inline-note {
    margin-top: 16px;
    color: var(--text-soft);
    font-size: 14px;
}

.member-strip {
    margin-top: 22px;
    display: grid;
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
    gap: 16px;
}

.member-card {
    background: linear-gradient(135deg, rgba(255, 250, 243, 0.92), rgba(241, 232, 219, 0.88));
    border: 1px solid rgba(51, 39, 28, 0.08);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 22px;
}

.member-card h3 {
    font-size: 20px;
    margin-top: 10px;
}

.member-card p {
    margin-top: 8px;
    color: var(--text-soft);
    font-size: 14px;
}

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

.limit-pill {
    padding: 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(51, 39, 28, 0.08);
}

.limit-pill strong {
    display: block;
    font-size: 28px;
    line-height: 1;
}

.limit-pill span {
    display: block;
    margin-top: 8px;
    color: var(--text-soft);
    font-size: 13px;
}

@media (max-width: 1080px) {
    .member-strip,
    .limit-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .modal-mask,
    .drawer-mask {
        padding: 12px;
    }

    .modal,
    .drawer-head,
    .drawer-body,
    .auth-panel {
        padding-inline: 18px;
    }

    .modal {
        max-height: calc(100vh - 24px);
        border-radius: 26px;
    }

    .work-card-top,
    .work-foot,
    .batch-status-card,
    .toolbar {
        padding-inline: 16px;
    }

    .hero-panel,
    .dashboard-hero,
    .workspace-hero,
    .stat-card,
    .feature,
    .journey-step,
    .account-card,
    .empty-state {
        padding: 18px;
    }

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

    .btn-code {
        min-height: 48px;
    }

    body.template-app-mobile .membership-mobile-facts {
        grid-template-columns: 1fr;
    }
}
