:root {
    --site-bg: #f6f8fb;
    --site-card: #ffffff;
    --site-text: #182230;
    --site-muted: #667085;
    --site-border: #dfe7f1;
    --site-primary: #176b5b;
    --site-primary-dark: #115346;
    --site-accent: #2563eb;
    --site-success: #0f9d77;
    --site-warning: #d97706;
    --site-danger: #e5484d;
    --site-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
    --site-radius: 8px;
}

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

body {
    padding-top: 0 !important;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.72) 0, rgba(246, 248, 251, 0) 240px),
        var(--site-bg);
    color: var(--site-text);
    font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--site-primary);
    transition: all 0.2s ease;
}

a:hover,
a:focus {
    color: var(--site-primary-dark);
    text-decoration: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid rgba(23, 107, 91, 0.18);
    outline-offset: 2px;
}

img {
    max-width: 100%;
}

.hide {
    display: none !important;
}

.site-shell {
    min-height: 100vh;
}

.site-wrap,
.page-shell {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(16px);
    background: rgba(255, 255, 255, 0.9);
    border-bottom: 1px solid rgba(223, 231, 241, 0.9);
}

.site-header-top,
.site-header-bottom {
    display: flex;
    align-items: center;
}

.site-header-top {
    justify-content: space-between;
    gap: 24px;
    min-height: 72px;
    padding: 14px 0 12px;
}

.site-header-bottom {
    justify-content: space-between;
    gap: 24px;
    padding: 0 0 14px;
}

.site-brand {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 230px;
    color: var(--site-text);
}

.site-brand-mark,
.site-brand-logo {
    width: 48px;
    height: 48px;
    border-radius: 8px;
}

.site-brand-mark {
    background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    letter-spacing: 1px;
    box-shadow: 0 10px 22px rgba(23, 107, 91, 0.22);
}

.site-brand-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 48px;
    background: #fff;
    border: 1px solid var(--site-border);
    overflow: hidden;
}

.site-brand-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.site-brand-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.site-brand-text strong {
    font-size: 20px;
    line-height: 1.1;
}

.site-brand-text em {
    font-style: normal;
    color: var(--site-muted);
    font-size: 13px;
}

.site-nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    flex: 1;
}

.site-nav a {
    padding: 10px 13px;
    border-radius: 8px;
    color: var(--site-text);
    font-size: 14px;
    white-space: nowrap;
}

.site-nav a:hover,
.site-nav a:focus {
    background: #edf7f4;
    color: var(--site-primary);
}

.site-search {
    display: flex;
    align-items: center;
    width: min(360px, 34vw);
    min-width: 300px;
    background: #fff;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    padding: 4px;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.04);
}

.site-search input,
.form-control,
.field-control,
.site-field input,
.site-field select,
.site-field textarea {
    width: 100%;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    background: #fff;
    color: var(--site-text);
    min-height: 48px;
    padding: 12px 14px;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.site-search input {
    border: 0;
    min-height: 40px;
    padding: 0 12px;
}

.site-search input:focus,
.form-control:focus,
.field-control:focus,
.site-field input:focus,
.site-field select:focus,
.site-field textarea:focus {
    border-color: rgba(23, 107, 91, 0.45);
    box-shadow: 0 0 0 4px rgba(23, 107, 91, 0.09);
    outline: 0;
}

.site-search button,
.btn,
button.btn,
input[type="submit"].btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.site-search button,
.btn-primary,
.btn.btn-primary {
    background: linear-gradient(135deg, var(--site-primary), #23856f);
    color: #fff;
    box-shadow: 0 12px 22px rgba(23, 107, 91, 0.18);
}

.site-search button:hover,
.btn-primary:hover,
.btn.btn-primary:hover {
    color: #fff;
    transform: translateY(-1px);
}

.btn-light,
.btn-default,
.btn.btn-default {
    background: #fff;
    border: 1px solid var(--site-border);
    color: var(--site-text);
}

.btn-light:hover,
.btn-default:hover,
.btn.btn-default:hover {
    color: var(--site-primary);
    border-color: rgba(23, 107, 91, 0.35);
}

.btn-ghost {
    background: rgba(23, 107, 91, 0.09);
    color: var(--site-primary);
}

.btn-danger,
.btn.btn-danger {
    background: rgba(225, 29, 72, 0.08);
    color: var(--site-danger);
}

.btn-warning,
.btn.btn-warning {
    background: linear-gradient(135deg, #d97706, #f59e0b);
    color: #fff;
}

.btn-link {
    background: transparent;
    color: var(--site-primary);
    padding: 0;
    min-height: auto;
}

.btn-block {
    width: 100%;
}

.btn-lg {
    min-height: 50px;
    border-radius: 8px;
}

.btn-xs {
    min-height: 34px;
    padding: 0 12px;
    border-radius: 8px;
    font-size: 12px;
}

.site-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-shrink: 0;
}

.user-menu {
    position: relative;
}

.user-menu::after {
    content: "";
    position: absolute;
    top: 100%;
    right: 0;
    width: max(100%, 190px);
    height: 12px;
    display: none;
}

.user-menu:hover::after,
.user-menu:focus-within::after {
    display: block;
}

.user-menu-trigger {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid var(--site-border);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.05);
    color: var(--site-text);
}

.site-avatar,
.avatar-img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #dbeafe;
}

.site-avatar img,
.avatar-img img,
.profile-user-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-menu-name {
    max-width: 96px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-menu-panel {
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    z-index: 20;
    min-width: 190px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid var(--site-border);
    border-radius: 8px;
    box-shadow: var(--site-shadow);
    display: none;
}

.user-menu:hover .user-menu-panel {
    display: block;
}

.user-menu:focus-within .user-menu-panel {
    display: block;
}

.user-menu-panel a {
    display: block;
    padding: 10px 12px;
    border-radius: 8px;
    color: var(--site-text);
}

.user-menu-panel a:hover {
    background: #edf7f4;
    color: var(--site-primary);
}

.site-main {
    padding: 36px 0 64px;
}

.page-shell {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(17, 83, 70, 0.96), rgba(37, 99, 235, 0.92)),
        linear-gradient(90deg, #115346, #2563eb);
    color: #fff;
    padding: 44px;
    box-shadow: 0 22px 48px rgba(17, 83, 70, 0.2);
}

.page-hero::before {
    display: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.9fr);
    gap: 28px;
    position: relative;
    z-index: 1;
}

.page-hero h1,
.page-hero h2,
.section-title h3,
.section-head h2 {
    margin: 0;
}

.page-hero h1 {
    font-size: 40px;
    line-height: 1.2;
    font-weight: 700;
    margin-bottom: 16px;
}

.page-hero p {
    color: rgba(255, 255, 255, 0.82);
    font-size: 15px;
    line-height: 1.8;
    margin-bottom: 18px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hero-actions .btn-light {
    background: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.18);
    color: #fff;
}

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

.hero-entry-card {
    display: block;
    padding: 18px 20px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #fff;
}

.hero-entry-card strong {
    display: block;
    margin-bottom: 8px;
    font-size: 16px;
}

.hero-entry-card span {
    display: block;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.7;
}

.hero-entry-card:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    transform: translateY(-2px);
}

.stats-grid,
.card-grid,
.compact-grid,
.account-stats {
    display: grid;
    gap: 18px;
}

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

.card-grid.goods-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

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

.page-card,
.section-card,
.surface-card,
.goods-card,
.merchant-card,
.info-card,
.order-card,
.shop-stat,
.metric-card,
.account-sidenav,
.auth-panel {
    background: var(--site-card);
    border: 1px solid rgba(230, 235, 242, 0.92);
    border-radius: var(--site-radius);
    box-shadow: var(--site-shadow);
}

.page-card,
.section-card,
.surface-card,
.auth-panel {
    padding: 26px;
}

.metric-card,
.shop-stat {
    padding: 22px;
}

.metric-card .metric-label,
.shop-stat .metric-label {
    color: var(--site-muted);
    font-size: 13px;
    margin-bottom: 8px;
}

.metric-card .metric-value,
.shop-stat .metric-value {
    font-size: 30px;
    font-weight: 700;
}

.metric-card .metric-note {
    margin-top: 8px;
    color: var(--site-muted);
    font-size: 13px;
}

.section-head,
.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 20px;
}

.section-head h2,
.section-title h3 {
    font-size: 24px;
    font-weight: 700;
}

.section-head p,
.section-title p {
    margin: 6px 0 0;
    color: var(--site-muted);
}

.head-side,
.section-head-side {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.goods-card,
.merchant-card,
.info-card,
.order-card {
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.goods-card:hover,
.merchant-card:hover,
.info-card:hover,
.order-card:hover {
    border-color: rgba(23, 107, 91, 0.18);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.1);
    transform: translateY(-2px);
}

.goods-card .cover,
.merchant-card .cover {
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #eef2f7;
}

.goods-card .cover img,
.merchant-card .cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.goods-card:hover .cover img,
.merchant-card:hover .cover img {
    transform: scale(1.04);
}

.goods-card .body,
.merchant-card .body,
.info-card .body,
.order-card .body {
    padding: 18px;
}

.card-title {
    margin: 0 0 10px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.5;
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-title a {
    color: var(--site-text);
}

.card-title a:hover {
    color: var(--site-primary);
}

.card-meta,
.text-muted,
.help-block,
.field-help {
    color: var(--site-muted) !important;
    line-height: 1.75;
}

.card-meta {
    margin-bottom: 10px;
    font-size: 14px;
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.price-line {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin: 14px 0 8px;
}

.price-line .current {
    color: var(--site-danger);
    font-size: 24px;
    font-weight: 700;
}

.price-line .origin {
    color: #98a2b3;
    text-decoration: line-through;
    font-size: 14px;
}

.chip,
.label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.chip-primary,
.label-info,
.label-primary {
    background: rgba(23, 107, 91, 0.1);
    color: var(--site-primary);
}

.chip-success,
.label-success {
    background: rgba(15, 157, 119, 0.1);
    color: var(--site-success);
}

.chip-warning,
.label-warning,
.label-default {
    background: rgba(245, 158, 11, 0.12);
    color: #b45309;
}

.empty-state {
    padding: 30px 18px;
    text-align: center;
    color: var(--site-muted);
    border: 1px dashed var(--site-border);
    border-radius: 8px;
    background: #fbfcfe;
}

.filter-panel {
    display: grid;
    gap: 16px;
    padding: 24px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(230, 235, 242, 0.9);
    border-radius: 8px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

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

.filter-span-2 {
    grid-column: span 2;
}

.filter-span-3 {
    grid-column: span 3;
}

.filter-span-4 {
    grid-column: span 4;
}

.filter-span-5 {
    grid-column: span 5;
}

.filter-span-6 {
    grid-column: span 6;
}

.filter-actions {
    display: flex;
    gap: 12px;
    align-items: flex-end;
}

.filter-actions .btn {
    min-height: 48px;
}

.site-field label,
.form-label,
.control-label {
    display: block;
    margin-bottom: 8px;
    color: #344054;
    font-size: 14px;
    font-weight: 600;
}

.site-field textarea,
textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

.auth-shell {
    width: min(1040px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
    gap: 28px;
    align-items: stretch;
}

.auth-aside {
    border-radius: 8px;
    padding: 36px;
    background: linear-gradient(135deg, #12211f, #176b5b 56%, #2563eb);
    color: #fff;
    box-shadow: 0 28px 56px rgba(17, 24, 39, 0.22);
}

.auth-aside h1 {
    margin: 0 0 16px;
    font-size: 34px;
    line-height: 1.3;
}

.auth-aside p {
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.85;
}

.auth-points {
    display: grid;
    gap: 14px;
    margin-top: 24px;
}

.auth-point {
    padding: 16px 18px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
}

.auth-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100%;
}

.auth-tabs {
    display: inline-flex;
    gap: 8px;
    padding: 6px;
    background: #f4f6fb;
    border-radius: 8px;
    margin-bottom: 24px;
}

.auth-tabs a {
    padding: 10px 18px;
    border-radius: 8px;
    color: var(--site-muted);
    font-weight: 600;
}

.auth-tabs a.active {
    background: #fff;
    color: var(--site-text);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.auth-title {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 700;
}

.auth-subtitle {
    margin: 0 0 24px;
    color: var(--site-muted);
}

.site-form {
    display: grid;
    gap: 18px;
}

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

.form-grid .full-span {
    grid-column: 1 / -1;
}

.choice-group,
.radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.choice-chip,
.radio-inline,
.checkbox.inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px;
    background: #f8fafc;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    margin: 0;
}

.choice-chip input,
.radio-inline input,
.checkbox.inline input,
.checkbox input {
    margin: 0;
}

.checkbox {
    margin: 0;
}

.account-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 22px;
}

.account-sidenav {
    padding: 24px;
}

.account-sidenav h3 {
    margin: 0 0 10px;
    font-size: 20px;
}

.account-sidenav p {
    margin: 0 0 20px;
    color: var(--site-muted);
    line-height: 1.7;
}

.account-nav {
    display: grid;
    gap: 10px;
}

.account-nav a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-radius: 8px;
    color: var(--site-text);
    background: #fff;
    border: 1px solid transparent;
}

.account-nav a:hover,
.account-nav .active a,
.account-nav .active {
    background: #edf7f4;
    border-color: rgba(23, 107, 91, 0.18);
    color: var(--site-primary);
}

.account-main {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

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

.profile-hero {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 20px;
    align-items: center;
}

.profile-avatar-container {
    position: relative;
    width: 112px;
    height: 112px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.12);
}

.profile-avatar-text {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(17, 24, 39, 0.56);
    color: #fff;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.profile-avatar-container:hover .profile-avatar-text {
    opacity: 1;
}

.profile-avatar-container button {
    position: absolute;
    inset: 0;
    opacity: 0;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(340px, 0.9fr);
    gap: 24px;
}

.detail-gallery {
    padding: 20px;
}

.detail-gallery-main {
    overflow: hidden;
    border-radius: 8px;
    background: #edf2f7;
}

.detail-gallery-main img {
    width: 100%;
    display: block;
    aspect-ratio: 4 / 3;
    max-height: 520px;
    object-fit: cover;
}

.thumb-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.thumb-item {
    display: block;
    width: 100%;
    padding: 0;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid transparent;
    background: #f3f6fb;
    cursor: pointer;
}

.thumb-item img {
    width: 100%;
    height: 94px;
    object-fit: cover;
}

.thumb-item.active {
    border-color: rgba(23, 107, 91, 0.55);
}

.detail-info {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.detail-actions {
    display: grid;
    gap: 14px;
}

.action-card {
    padding: 18px;
    border-radius: 8px;
    background: #f8fafc;
    border: 1px solid var(--site-border);
}

.action-card form {
    display: grid;
    gap: 12px;
}

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

.meta-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 0;
    border-bottom: 1px solid #eef2f6;
}

.meta-row:last-child {
    border-bottom: 0;
}

.prose-card {
    line-height: 1.9;
}

.prose-card h4 {
    margin: 24px 0 10px;
    font-size: 18px;
}

.info-list,
.result-list,
.stack-list {
    display: grid;
    gap: 16px;
}

.info-filter-panel {
    gap: 12px;
    padding: 18px;
    box-shadow: none;
}

.info-filter-panel .filter-grid {
    gap: 12px;
    align-items: end;
}

.info-filter-panel .site-field label {
    margin-bottom: 6px;
}

.info-filter-panel .filter-actions .btn {
    min-height: 42px;
}

.info-compact-list {
    gap: 10px;
}

.info-compact-card {
    border-color: rgba(230, 235, 242, 0.86);
    border-radius: 8px;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.info-compact-card:hover {
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
    transform: none;
}

.info-card.info-compact-card .body {
    min-height: auto;
    padding: 14px 16px;
    gap: 8px;
}

.card-head.info-row-head {
    align-items: center;
    gap: 10px;
}

.info-row-head .card-title {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
    -webkit-line-clamp: 1;
}

.info-row-head .chip {
    flex: 0 0 auto;
    white-space: nowrap;
}

.info-row-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 18px;
    color: var(--site-muted);
    font-size: 13px;
    line-height: 1.6;
}

.info-row-meta span {
    min-width: 0;
    max-width: 100%;
}

.info-card .body,
.order-card .body {
    display: grid;
    gap: 10px;
}

.card-head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
}

.cart-item,
.order-item {
    padding: 18px;
    border-radius: 8px;
    background: #f8fafc;
    border: 1px solid var(--site-border);
}

.cart-item-grid {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
}

.cart-item .checkbox {
    padding-top: 4px;
}

.rich-editor-box {
    border: 1px solid var(--site-border);
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.rich-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px;
    border-bottom: 1px solid var(--site-border);
    background: #f8fafc;
}

.rich-toolbar .btn {
    min-height: 34px;
    padding: 0 12px;
    background: #fff;
    border: 1px solid var(--site-border);
    color: var(--site-text);
    box-shadow: none;
}

.rich-editor {
    min-height: 220px;
    padding: 16px;
    outline: 0;
    line-height: 1.8;
}

.upload-inline {
    display: flex;
    gap: 10px;
}

.upload-inline .form-control {
    flex: 1;
}

.well,
.well-sm {
    border: 1px solid var(--site-border);
    border-radius: 8px;
    background: #f8fafc;
    box-shadow: none;
    margin-bottom: 10px;
}

.pagination-wrap,
.text-center {
    text-align: center;
}

.pagination {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 8px 0 0;
}

.pagination > li {
    display: inline-flex;
}

.pagination > li > a,
.pagination > li > span {
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid var(--site-border);
    background: #fff;
    color: var(--site-text);
}

.pagination > .active > a,
.pagination > .active > span {
    background: linear-gradient(135deg, var(--site-primary), #23856f);
    border-color: transparent;
    color: #fff;
}

.site-footer {
    border-top: 1px solid rgba(230, 235, 242, 0.9);
    background: rgba(255, 255, 255, 0.8);
}

.site-footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 0 28px;
}

.site-footer p {
    margin: 6px 0 0;
    color: var(--site-muted);
}

.site-footer-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    color: var(--site-muted);
}

.audit-doc h4 {
    margin-top: 24px;
}

.checkout-items,
.address-grid,
.pay-methods,
.shop-action-grid,
.shop-product-list {
    display: grid;
    gap: 14px;
}

.checkout-item {
    display: grid;
    grid-template-columns: 84px minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    background: #fbfcfe;
}

.checkout-item img,
.shop-product-row img {
    width: 84px;
    height: 84px;
    object-fit: cover;
    border-radius: 8px;
    background: #eef2f7;
}

.address-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 16px;
}

.address-card,
.pay-method-card {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 16px;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
}

.address-card input,
.pay-method-card input {
    margin-top: 3px;
}

.address-card span,
.pay-method-card span {
    display: grid;
    gap: 5px;
}

.address-card em,
.pay-method-card em {
    font-style: normal;
    color: var(--site-muted);
    line-height: 1.7;
}

.address-card small {
    width: fit-content;
    padding: 3px 8px;
    color: var(--site-primary);
    background: #edf7f4;
    border-radius: 8px;
}

.address-new-card {
    padding: 16px;
    border: 1px dashed var(--site-border);
    border-radius: 8px;
    background: #fbfcfe;
}

.pay-methods {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 18px;
}

.checkout-submit {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 18px;
    border-top: 1px solid var(--site-border);
}

.checkout-submit span {
    display: block;
    color: var(--site-muted);
}

.checkout-submit strong {
    color: var(--site-danger);
    font-size: 26px;
}

.shop-workbench-hero {
    background: linear-gradient(135deg, #fff, #f7fbfa);
}

.shop-alert {
    padding: 12px 14px;
    color: #9a3412;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-radius: 8px;
}

.shop-tabbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.shop-tabbar a {
    padding: 10px 14px;
    color: var(--site-text);
    background: #fff;
    border: 1px solid var(--site-border);
    border-radius: 8px;
}

.shop-tabbar a:hover,
.shop-tabbar a.active {
    color: var(--site-primary);
    background: #edf7f4;
    border-color: rgba(23, 107, 91, 0.22);
}

.shop-action-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.shop-action-card {
    display: grid;
    gap: 10px;
    min-height: 160px;
    padding: 20px;
    color: var(--site-text);
    background: #fff;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    box-shadow: var(--site-shadow);
}

.shop-action-card strong {
    font-size: 18px;
}

.shop-action-card span {
    color: var(--site-muted);
    line-height: 1.7;
}

.shop-action-card em {
    align-self: end;
    font-style: normal;
    color: var(--site-primary);
    font-weight: 700;
}

.shop-action-card.primary {
    color: #fff;
    background: linear-gradient(135deg, var(--site-primary), #23856f);
}

.shop-action-card.primary span,
.shop-action-card.primary em {
    color: rgba(255, 255, 255, 0.86);
}

.shop-form-card .section-title {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--site-border);
}

.shop-product-row {
    display: grid;
    grid-template-columns: 84px minmax(0, 1fr) 120px 120px auto;
    gap: 16px;
    align-items: center;
    padding: 16px;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    background: #fff;
}

.shop-product-tags,
.shop-product-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.shop-product-metric {
    display: grid;
    gap: 4px;
}

.shop-product-metric span,
.shop-product-metric em {
    color: var(--site-muted);
    font-style: normal;
}

.shop-product-metric strong {
    font-size: 20px;
}

.goods-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.goods-card .body {
    display: flex;
    flex: 1;
    flex-direction: column;
}

.goods-card .price-line {
    margin-top: auto;
}

.merchant-card .body,
.info-card .body {
    min-height: 100%;
}

.table {
    overflow: hidden;
    border: 1px solid var(--site-border);
    border-radius: 8px;
    background: #fff;
}

.table > thead > tr > th {
    border-bottom: 1px solid var(--site-border);
    background: #f8fafc;
    color: #344054;
    font-weight: 700;
}

.table > tbody > tr > td {
    border-top: 1px solid #eef2f6;
    vertical-align: middle;
}

.table > tbody > tr:hover > td {
    background: #fbfdfc;
}

.input-group .form-control:first-child,
.input-group-addon:first-child,
.input-group-btn:first-child > .btn {
    border-radius: 8px 0 0 8px;
}

.input-group .form-control:last-child,
.input-group-addon:last-child,
.input-group-btn:last-child > .btn {
    border-radius: 0 8px 8px 0;
}

.auth-panel .input-group,
.form-layer .input-group {
    display: flex;
    align-items: stretch;
    width: 100%;
}

.auth-panel .input-group .form-control,
.form-layer .input-group .form-control {
    flex: 1 1 auto;
    min-width: 0;
    height: 48px;
}

.auth-panel .input-group-btn,
.form-layer .input-group-btn {
    display: inline-flex;
    flex: 0 0 auto;
    width: auto;
    vertical-align: top;
}

.auth-panel .input-group-btn .btn,
.form-layer .input-group-btn .btn {
    min-width: 112px;
    height: 48px;
    min-height: 48px;
    padding: 0 14px;
    white-space: nowrap;
    border-radius: 0 8px 8px 0;
    box-shadow: none;
}

.auth-panel .input-group-btn img,
.form-layer .input-group-btn img {
    display: block;
    width: 100px;
    height: 40px;
    margin: 4px;
    object-fit: cover;
    cursor: pointer;
    border-radius: 6px;
}

.auth-panel .input-group .form-control:first-child,
.form-layer .input-group .form-control:first-child {
    border-radius: 8px 0 0 8px;
}

.form-layer .form-body {
    padding: 20px 18px 8px;
}

.form-layer .form-footer {
    padding: 0 18px 18px;
}

.layui-layer-fast,
.layui-layer-dialog {
    border-radius: 8px !important;
    overflow: hidden;
}

.msg-box,
.nice-validator {
    line-height: 1.7;
}

@media (max-width: 1199px) {
    .card-grid.goods-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

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

    .shop-product-row {
        grid-template-columns: 84px minmax(0, 1fr) 120px;
    }

    .shop-product-actions {
        grid-column: 2 / -1;
    }

    .hero-grid,
    .detail-layout,
    .auth-shell,
    .account-layout {
        grid-template-columns: 1fr;
    }

    .site-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 2px;
        scrollbar-width: none;
    }

    .site-nav::-webkit-scrollbar {
        display: none;
    }

    .site-header-bottom {
        align-items: stretch;
    }

    .site-search {
        width: min(320px, 38vw);
        min-width: 280px;
    }
}

@media (max-width: 991px) {
    .filter-span-2,
    .filter-span-3,
    .filter-span-4,
    .filter-span-5,
    .filter-span-6 {
        grid-column: span 12;
    }

    .form-grid,
    .stats-grid,
    .compact-grid,
    .account-stats,
    .card-grid.goods-grid,
    .card-grid.merchant-grid {
        grid-template-columns: 1fr 1fr;
    }

    .page-hero {
        padding: 32px 24px;
    }

    .page-hero h1 {
        font-size: 32px;
    }

    .address-grid,
    .pay-methods {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767px) {
    .site-wrap,
    .page-shell,
    .auth-shell {
        width: min(100% - 24px, 100%);
    }

    .site-header-top {
        flex-wrap: wrap;
        gap: 12px;
        min-height: auto;
        padding: 12px 0 10px;
    }

    .site-header-bottom {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding-bottom: 12px;
    }

    .site-brand {
        min-width: 0;
        flex: 1 1 auto;
        gap: 10px;
    }

    .site-brand-logo {
        width: 42px;
        height: 42px;
        flex-basis: 42px;
    }

    .site-nav {
        flex-direction: row;
        align-items: center;
    }

    .site-actions {
        flex-direction: row;
        flex-wrap: wrap;
        margin-left: auto;
    }

    .site-actions .btn {
        flex: 1 1 auto;
    }

    .site-actions .user-menu {
        width: 100%;
    }

    .info-filter-panel {
        padding: 14px;
    }

    .info-card.info-compact-card .body {
        padding: 13px 14px;
        gap: 7px;
    }

    .card-head.info-row-head {
        flex-direction: row;
        align-items: flex-start;
        gap: 8px;
    }

    .info-row-head .card-title {
        font-size: 15px;
        -webkit-line-clamp: 2;
    }

    .info-row-meta {
        display: grid;
        gap: 3px;
        font-size: 13px;
    }

    .site-search button {
        padding-inline: 12px;
    }

    .site-search {
        width: 100%;
        min-width: 100%;
    }

    .user-menu-trigger {
        justify-content: center;
    }

    .user-menu-panel {
        position: static;
        display: grid;
        margin-top: 10px;
    }

    .page-card,
    .section-card,
    .surface-card,
    .auth-panel,
    .account-sidenav {
        padding: 22px 18px;
    }

    .auth-aside,
    .page-hero {
        padding: 28px 20px;
    }

    .page-hero h1 {
        font-size: 28px;
    }

    .form-grid,
    .stats-grid,
    .compact-grid,
    .account-stats,
    .card-grid.goods-grid,
    .card-grid.merchant-grid,
    .thumb-list {
        grid-template-columns: 1fr;
    }

    .cart-item-grid,
    .profile-hero,
    .checkout-item,
    .shop-product-row {
        grid-template-columns: 1fr;
    }

    .checkout-item img,
    .shop-product-row img {
        width: 100%;
        height: auto;
        aspect-ratio: 4 / 3;
    }

    .checkout-submit {
        flex-direction: column;
        align-items: stretch;
    }

    .shop-action-grid {
        grid-template-columns: 1fr;
    }

    .shop-product-actions {
        grid-column: auto;
    }

    .section-head,
    .section-title,
    .card-head,
    .meta-row,
    .site-footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .site-footer-meta {
        align-items: flex-start;
    }

    .upload-inline {
        flex-direction: column;
    }
}
