/* ============================================================
   言和商城 · 暖调编辑风主题 (Warm Editorial Theme)
   米纸底色 / 松绿主色 / 陶土点缀 / 衬线标题
   本文件在 tailwind.css 之后加载，同名工具类在此完成主题化
   ============================================================ */

:root {
    /* 色彩体系 */
    --paper: #faf5ea;          /* 页面底色（米纸） */
    --card: #fffdf6;           /* 卡片纸面 */
    --cream: #f3ecdc;          /* 交替区块（浅奶油） */
    --ink: #27211a;            /* 墨色文字 */
    --muted: #857763;          /* 次级文字（暖灰褐） */
    --line: #e6dcc8;           /* 描边 */
    --pine: #1d5c46;           /* 主色：松绿 */
    --pine-deep: #0f3b2c;      /* 次色：深林绿 */
    --clay: #bc5a28;           /* 点缀：陶土橙 */
    --amber: #d9a13b;          /* 点缀：琥珀 */
    --price: #c23a1f;          /* 价格红（暖） */
    --pine-rgb: 29 92 70;
    --clay-rgb: 188 90 40;
    --pine-deep-rgb: 15 59 44;
}

/* ---------- 基础 ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    border-color: var(--line);
}

*, ::before, ::after {
    border-color: #e9dfcb;
}

html {
    scroll-behavior: smooth;
}

body {
    scroll-behavior: smooth;
}

::selection {
    background: rgb(var(--pine-rgb) / 0.18);
}

/* 标题统一衬线，营造编辑风 */
h1, h2, h3, h4, .font-display {
    font-family: 'Noto Serif SC', 'Songti SC', 'STSong', serif;
}

.font-display {
    font-weight: 700;
    letter-spacing: 0.01em;
}

/* ---------- Tailwind 品牌类主题化 ---------- */
.font-sans {
    font-family: 'Nunito', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
}

.bg-light {
    background-color: var(--paper);
    background-image: radial-gradient(rgb(var(--pine-rgb) / 0.05) 1px, transparent 1px);
    background-size: 22px 22px;
}

.bg-white {
    background-color: var(--card);
}

.bg-gray-50 {
    background-color: var(--cream);
}

.bg-gray-200 {
    background-color: #eadfc9;
}

.bg-dark {
    background-color: #14261e;
}

.bg-gray-800 {
    background-color: #22332b;
}

.text-dark {
    color: var(--ink);
}

.bg-primary,
.hover\:bg-primary:hover {
    --tw-bg-opacity: 1;
    background-color: rgb(var(--pine-rgb) / var(--tw-bg-opacity, 1));
}

.bg-primary\/10 {
    background-color: rgb(var(--pine-rgb) / 0.1);
}

.bg-primary\/5,
.hover\:bg-primary\/5:hover {
    background-color: rgb(var(--pine-rgb) / 0.06);
}

.hover\:bg-primary\/90:hover {
    background-color: rgb(var(--pine-rgb) / 0.9);
}

.text-primary,
.hover\:text-primary:hover {
    --tw-text-opacity: 1;
    color: rgb(var(--pine-rgb) / var(--tw-text-opacity, 1));
}

.border-primary {
    --tw-border-opacity: 1;
    border-color: rgb(var(--pine-rgb) / var(--tw-border-opacity, 1));
}

.accent-primary {
    accent-color: var(--pine);
}

.focus\:border-primary:focus {
    border-color: rgb(var(--pine-rgb) / 1);
}

.focus\:ring-primary:focus {
    --tw-ring-color: rgb(var(--pine-rgb) / 0.5);
}

.group:hover .group-hover\:bg-primary {
    --tw-bg-opacity: 1;
    background-color: rgb(var(--pine-rgb) / var(--tw-bg-opacity, 1));
}

/* 渐变 */
.from-primary {
    --tw-gradient-from: #1d5c46 var(--tw-gradient-from-position);
    --tw-gradient-to: rgb(var(--pine-rgb) / 0) var(--tw-gradient-to-position);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);
}

.from-primary\/20 {
    --tw-gradient-from: rgb(var(--pine-rgb) / 0.2) var(--tw-gradient-from-position);
    --tw-gradient-to: rgb(var(--pine-rgb) / 0) var(--tw-gradient-to-position);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);
}

.from-primary\/5 {
    --tw-gradient-from: rgb(var(--pine-rgb) / 0.05) var(--tw-gradient-from-position);
    --tw-gradient-to: rgb(var(--pine-rgb) / 0) var(--tw-gradient-to-position);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);
}

.to-secondary {
    --tw-gradient-to: #0f3b2c var(--tw-gradient-to-position);
}

.to-secondary\/20 {
    --tw-gradient-to: rgb(var(--pine-deep-rgb) / 0.2);
}

.to-secondary\/5 {
    --tw-gradient-to: rgb(var(--pine-deep-rgb) / 0.05);
}

/* 毛玻璃导航 → 米色玻璃 */
.bg-glass {
    background: rgb(250 245 234 / 0.88);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid rgb(var(--pine-rgb) / 0.12);
}

/* 暖灰文字 */
.text-gray-400 { color: #a89b85; }
.text-gray-500 { color: #8a7c67; }
.text-gray-600 { color: #6f6350; }

/* ---------- 动画 ---------- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ---------- 滚动条 ---------- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--cream); }
::-webkit-scrollbar-thumb {
    background: #c8b995;
    border-radius: 6px;
    border: 2px solid var(--cream);
}
::-webkit-scrollbar-thumb:hover { background: #a89874; }

/* ---------- 按钮 ---------- */
.btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    border-radius: 50px;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    outline: none;
}

.btn-primary {
    background-color: var(--pine);
    color: white;
    box-shadow: 0 4px 14px 0 rgb(var(--pine-rgb) / 0.35);
}
.btn-primary:hover {
    background-color: var(--pine-deep);
    box-shadow: 0 6px 20px 0 rgb(var(--pine-rgb) / 0.45);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--pine);
    border: 2px solid var(--pine);
}
.btn-secondary:hover {
    background-color: rgb(var(--pine-rgb) / 0.06);
    transform: translateY(-2px);
}

/* ---------- 卡片 ---------- */
.card {
    background-color: var(--card);
    border-radius: 16px;
    border: 1px solid var(--line);
    box-shadow: 0 2px 10px rgb(39 33 26 / 0.05);
    transition: all 0.3s ease;
    overflow: hidden;
}
.card:hover {
    box-shadow: 0 10px 28px rgb(39 33 26 / 0.1);
    transform: translateY(-5px);
}

/* ---------- 表单 ---------- */
.form-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px;
    border: 1.5px solid var(--line);
    border-radius: 10px;
    background: var(--card);
    transition: all 0.3s ease;
    outline: none;
    color: var(--ink);
}
.form-input:focus {
    border-color: var(--pine);
    box-shadow: 0 0 0 3px rgb(var(--pine-rgb) / 0.12);
}
.form-input::placeholder {
    color: #b3a68e;
}

/* ---------- 标题 ---------- */
.section-title {
    font-size: clamp(1.8rem, 4vw, 3rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1rem;
}
.section-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--muted);
    margin-bottom: 3rem;
}

/* ---------- 渐变工具 ---------- */
.bg-gradient-primary {
    background: linear-gradient(135deg, #1d5c46 0%, #0f3b2c 100%);
}
.bg-gradient-accent {
    background: linear-gradient(135deg, #bc5a28 0%, #1d5c46 100%);
}
.text-gradient-primary {
    background: linear-gradient(135deg, #1d5c46 0%, #0f3b2c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.text-shadow {
    text-shadow: 0 2px 4px rgb(39 33 26 / 0.08);
}

.section-padding {
    padding-top: clamp(3rem, 8vw, 6rem);
    padding-bottom: clamp(3rem, 8vw, 6rem);
}

/* ---------- 响应式 ---------- */
@media (max-width: 768px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* ---------- 加载动画 ---------- */
.loading-spinner {
    border: 3px solid rgb(var(--pine-rgb) / 0.12);
    border-radius: 50%;
    border-top: 3px solid var(--pine);
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
}

/* ---------- 工具类 ---------- */
.text-balance { text-wrap: balance; }
.content-auto { content-visibility: auto; }

#scroll-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background-color: var(--pine);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 14px rgb(var(--pine-rgb) / 0.35);
    transition: all 0.3s ease;
    z-index: 100;
}
#scroll-to-top:hover {
    background-color: var(--pine-deep);
    transform: translateY(-5px);
}

.progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    z-index: 9999;
}
.progress-bar {
    height: 4px;
    background: linear-gradient(90deg, var(--pine), var(--clay));
    width: 0%;
}

/* 全局过渡 */
* {
    transition: color 0.25s ease, background-color 0.25s ease, border-color 0.25s ease;
}

img {
    max-width: 100%;
    height: auto;
}

.aspect-video { aspect-ratio: 16 / 9; }
.aspect-square { aspect-ratio: 1 / 1; }

/* 骨架屏 */
.skeleton {
    background: linear-gradient(90deg, #efe7d5 25%, #e4d9c0 50%, #efe7d5 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* 可访问性 */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
@media (prefers-contrast: high) {
    .card { border: 2px solid #000; }
    .btn { border: 2px solid #000; }
}

/* ============================================================
   电商组件
   ============================================================ */

/* 商品卡片 - 纸面卡片 + 描边 */
.product-card-wrapper {
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: var(--card);
    transition: border-color 0.3s ease;
}
.product-card-wrapper:hover {
    border-color: rgb(var(--pine-rgb) / 0.45);
}
.product-card-wrapper .product-card {
    box-shadow: none;
}
.product-card-wrapper .product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 26px rgb(39 33 26 / 0.1);
}

.product-card {
    background-color: var(--card);
    border-radius: 14px;
    box-shadow: 0 2px 10px rgb(39 33 26 / 0.05);
    transition: all 0.3s ease;
    overflow: hidden;
    position: relative;
}
.product-card:hover {
    box-shadow: 0 10px 26px rgb(39 33 26 / 0.1);
    transform: translateY(-5px);
}
.product-card .product-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.product-card:hover .product-image {
    transform: scale(1.05);
}
.product-card .product-image-wrapper {
    overflow: hidden;
    position: relative;
    background: var(--cream);
}
.product-card .product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--clay);
    color: white;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
}

/* 价格 */
.product-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.product-price .current-price {
    font-size: 24px;
    font-weight: 700;
    color: var(--price);
    font-family: 'Nunito', sans-serif;
}
.product-price .original-price {
    font-size: 14px;
    color: #b0a48d;
    text-decoration: line-through;
}
.product-price .discount-tag {
    font-size: 12px;
    background-color: #faeee3;
    color: var(--clay);
    padding: 2px 6px;
    border-radius: 4px;
}

/* 商品详情缩略图 */
.thumbnail-gallery {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}
.thumbnail-gallery img {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: border-color 0.3s ease;
}
.thumbnail-gallery img.active,
.thumbnail-gallery img:hover {
    border-color: var(--pine);
}

/* 数量选择器 */
.quantity-selector {
    display: flex;
    align-items: center;
    gap: 0;
    border: 1.5px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    width: fit-content;
    background: var(--card);
}
.quantity-selector button {
    width: 40px;
    height: 40px;
    border: none;
    background-color: var(--cream);
    font-size: 18px;
    cursor: pointer;
    transition: background-color 0.2s;
    color: #6f6350;
}
.quantity-selector button:hover {
    background-color: #e9dfc9;
}
.quantity-selector button:disabled {
    color: #cfc4ab;
    cursor: not-allowed;
}
.quantity-selector input {
    width: 60px;
    height: 40px;
    text-align: center;
    border: none;
    border-left: 1.5px solid var(--line);
    border-right: 1.5px solid var(--line);
    font-size: 16px;
    outline: none;
    background: var(--card);
    color: var(--ink);
}

/* 加入购物车：松绿实心 */
.btn-add-cart {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    font-size: 16px;
    font-weight: 600;
    background-color: var(--pine);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px 0 rgb(var(--pine-rgb) / 0.35);
}
.btn-add-cart:hover {
    background-color: var(--pine-deep);
    box-shadow: 0 6px 20px 0 rgb(var(--pine-rgb) / 0.45);
    transform: translateY(-2px);
}
.btn-add-cart:active {
    transform: translateY(0);
}
.btn-add-cart.added {
    background-color: #3e7d33;
    box-shadow: 0 4px 14px 0 rgb(62 125 51 / 0.35);
}

/* 立即购买：陶土暖调 */
.btn-buy-now {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, #c96a35 0%, #bc5a28 55%, #9c451c 100%);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px 0 rgb(var(--clay-rgb) / 0.35);
}
.btn-buy-now:hover {
    box-shadow: 0 6px 20px 0 rgb(var(--clay-rgb) / 0.45);
    transform: translateY(-2px);
}

/* 排序按钮（商品列表页） */
.sort-btn {
    border: 1px solid var(--line);
    background: var(--card);
    color: #6f6350;
    cursor: pointer;
}
.sort-btn:hover {
    border-color: rgb(var(--pine-rgb) / 0.5);
    color: var(--pine);
}
.sort-btn.active {
    background: var(--pine);
    border-color: var(--pine);
    color: white;
}

/* 购物车条目 */
.cart-item {
    display: flex;
    align-items: center;
    padding: 20px;
    background-color: var(--card);
    border: 1px solid var(--line);
    border-radius: 14px;
    margin-bottom: 16px;
    transition: box-shadow 0.3s ease;
}
.cart-item:hover {
    box-shadow: 0 6px 20px rgb(39 33 26 / 0.08);
}
.cart-item .cart-checkbox {
    width: 22px;
    height: 22px;
    margin-right: 16px;
    accent-color: var(--pine);
    cursor: pointer;
    flex-shrink: 0;
}
.cart-item .cart-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 10px;
    margin-right: 20px;
    flex-shrink: 0;
    background: var(--cream);
}
.cart-item .cart-info {
    flex: 1;
    min-width: 0;
}
.cart-item .cart-info h4 {
    font-weight: 600;
    margin-bottom: 8px;
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.cart-item .cart-info .price {
    color: var(--price);
    font-weight: 700;
    font-size: 18px;
}
.cart-item .cart-remove {
    padding: 8px 16px;
    background-color: #f9e9e2;
    color: var(--price);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s;
}
.cart-item .cart-remove:hover {
    background-color: #f3dbd0;
}

/* 购物车结算栏 */
.cart-footer {
    position: sticky;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--card);
    border-top: 1px solid var(--line);
    padding: 16px 0;
    z-index: 50;
    box-shadow: 0 -4px 20px rgb(39 33 26 / 0.06);
}

/* 付款弹窗 */
.payment-modal {
    position: fixed;
    inset: 0;
    background-color: rgb(20 26 22 / 0.55);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.payment-modal:not(.hidden) {
    display: flex !important;
}
.payment-modal .modal-content {
    background-color: var(--card);
    border-radius: 18px;
    border: 1px solid var(--line);
    padding: 40px 32px 32px;
    max-width: 480px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 40px rgb(39 33 26 / 0.25);
}
.payment-modal .modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #8a7c67;
}
.payment-option {
    display: flex;
    align-items: center;
    padding: 16px;
    border: 1.5px solid var(--line);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 12px;
    background: var(--card);
}
.payment-option:hover,
.payment-option.selected {
    border-color: var(--pine);
    background-color: rgb(var(--pine-rgb) / 0.05);
}
.payment-option .payment-icon {
    font-size: 32px;
    margin-right: 16px;
}
.qr-placeholder {
    width: 200px;
    height: 200px;
    background-color: var(--cream);
    border: 2px dashed #cbbc9b;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 16px auto;
    color: #8a7c67;
    font-size: 14px;
    text-align: center;
}

/* 付费阅读卡片 */
.paid-article-card {
    background-color: var(--card);
    border-radius: 16px;
    border: 1px solid var(--line);
    box-shadow: 0 2px 10px rgb(39 33 26 / 0.05);
    transition: all 0.3s ease;
    overflow: hidden;
    position: relative;
}
.paid-article-card:hover {
    box-shadow: 0 10px 26px rgb(39 33 26 / 0.1);
    transform: translateY(-5px);
    border-color: rgb(var(--pine-rgb) / 0.4);
}
.paid-article-card .lock-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 30%, rgb(20 26 22 / 0.8) 100%);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    transition: opacity 0.3s;
}
.paid-article-card:hover .lock-overlay {
    opacity: 1;
}
.paid-price-tag {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgb(39 33 26 / 0.72);
    color: #fdf8ee;
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    backdrop-filter: blur(4px);
}
.paid-price-tag::before {
    content: '\f023';
    font-family: 'FontAwesome';
    margin-right: 6px;
}

/* 商家入驻表单 */
.merchant-form-card {
    background-color: var(--card);
    border-radius: 16px;
    border: 1px solid var(--line);
    box-shadow: 0 2px 10px rgb(39 33 26 / 0.05);
    padding: 40px;
}
.merchant-form-card .form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #4d4436;
    margin-bottom: 6px;
}
.merchant-form-card .form-group {
    margin-bottom: 24px;
}
.merchant-form-card .form-help {
    font-size: 12px;
    color: #a89b85;
    margin-top: 4px;
}
.merchant-form-card input:focus,
.merchant-form-card select:focus,
.merchant-form-card textarea:focus {
    outline: none;
    border-color: var(--pine);
    box-shadow: 0 0 0 3px rgb(var(--pine-rgb) / 0.12);
}

/* 用户评价 */
.review-item {
    padding: 20px 0;
    border-bottom: 1px solid #efe7d5;
}
.review-item:last-child {
    border-bottom: none;
}

/* 猜你喜欢 */
.guess-card {
    background-color: var(--card);
    border-radius: 12px;
    border: 1px solid var(--line);
    transition: all 0.3s ease;
    overflow: hidden;
    cursor: pointer;
}
.guess-card:hover {
    box-shadow: 0 6px 20px rgb(39 33 26 / 0.1);
    transform: translateY(-3px);
    border-color: rgb(var(--pine-rgb) / 0.4);
}

/* 商品详情内容 */
.detail-content h3 {
    font-size: 20px;
    font-weight: 700;
    margin-top: 24px;
    margin-bottom: 12px;
    color: var(--ink);
}
.detail-content ul {
    padding-left: 20px;
    margin-bottom: 16px;
}
.detail-content ul li {
    margin-bottom: 8px;
    color: #6f6350;
}
.detail-content p {
    color: #6f6350;
    margin-bottom: 16px;
    line-height: 1.8;
}

/* 分类标签 */
.category-tabs {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 24px;
}
.category-tab {
    padding: 8px 20px;
    border-radius: 50px;
    border: 1.5px solid var(--line);
    background-color: var(--card);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    color: #6f6350;
}
.category-tab:hover {
    border-color: var(--pine);
    color: var(--pine);
}
.category-tab.active {
    background-color: var(--pine);
    border-color: var(--pine);
    color: white;
}

/* 导航栏登录文字 */
.auth-login-text {
    font-size: 15px;
    font-weight: 500;
    color: inherit;
}

/* 导航栏用户菜单 */
.auth-user-menu {
    position: relative;
}
.auth-menu-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: -8px;
    min-width: 190px;
    background: var(--card);
    border-radius: 14px;
    box-shadow: 0 12px 40px rgb(39 33 26 / 0.16);
    overflow: hidden;
    z-index: 999;
    border: 1px solid var(--line);
    animation: dropdownFadeIn 0.15s ease;
}
.auth-menu-dropdown::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 16px;
    width: 12px;
    height: 12px;
    background: var(--card);
    border-left: 1px solid var(--line);
    border-top: 1px solid var(--line);
    transform: rotate(45deg);
}
.auth-menu-dropdown a,
.auth-menu-dropdown button {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 12px 20px;
    font-size: 14px;
    color: #4d4436;
    background: none;
    border: none;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
    text-align: left;
}
.auth-menu-dropdown a:hover {
    background: rgb(var(--pine-rgb) / 0.06);
    color: var(--pine);
}
.auth-menu-dropdown a:hover i {
    color: var(--pine);
}
.auth-menu-dropdown button:hover {
    background: #f9e9e2;
    color: var(--price);
}
.auth-menu-dropdown i {
    color: #a89b85;
    transition: color 0.15s ease;
    width: 20px;
    text-align: center;
}

@keyframes dropdownFadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 导航栏购物车徽标 */
.cart-badge {
    position: relative;
}
.cart-badge .badge-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--clay);
    color: white;
    font-size: 10px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* 文章统计条 */
.article-stats {
    display: flex;
    gap: 24px;
    padding: 16px 0;
    border-top: 1px solid #efe7d5;
    border-bottom: 1px solid #efe7d5;
    margin-top: 16px;
    flex-wrap: wrap;
}
.article-stats .stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #6f6350;
    font-size: 14px;
}
.article-stats .stat-item i {
    color: var(--pine);
}

/* 文本截断 */
.line-clamp-2 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

/* 付款成功动画 */
.payment-success-overlay {
    position: fixed;
    inset: 0;
    background: rgb(20 26 22 / 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    animation: fadeIn 0.3s ease;
}
.payment-success-card {
    background: var(--card);
    border-radius: 24px;
    padding: 48px 40px 36px;
    text-align: center;
    max-width: 360px;
    width: 90%;
    box-shadow: 0 20px 60px rgb(39 33 26 / 0.28);
    animation: successPop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes successPop {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}
.success-checkmark {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4c8a3f, #35682b);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: checkBounce 0.6s ease 0.2s both;
}
.success-checkmark i {
    color: white;
    font-size: 40px;
}
@keyframes checkBounce {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}
.payment-success-card h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 12px;
    animation: fadeInUp 0.4s ease 0.4s both;
}
.payment-success-card p {
    color: #6f6350;
    font-size: 16px;
    margin-bottom: 8px;
    animation: fadeInUp 0.4s ease 0.5s both;
}
.payment-success-card .success-amount {
    font-size: 28px;
    font-weight: 700;
    color: #3e7d33;
    margin: 16px 0 24px;
    animation: fadeInUp 0.4s ease 0.6s both;
}
.payment-success-card .btn-ok {
    padding: 12px 48px;
    background: linear-gradient(135deg, #4c8a3f, #35682b);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px rgb(62 125 51 / 0.4);
    animation: fadeInUp 0.4s ease 0.7s both;
}
.payment-success-card .btn-ok:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgb(62 125 51 / 0.5);
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
