/* ========== 祝福系统 - 全局样式 ========== */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #a5b4fc;
    --accent: #f472b6;
    --accent-light: #fbcfe8;
    --success: #22c55e;
    --danger: #ef4444;
    --warning: #f59e0b;
    --bg: #f8fafc;
    --card: #ffffff;
    --text: #1e293b;
    --text-light: #64748b;
    --border: #e2e8f0;
    --shadow: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 30px rgba(0,0,0,0.1);
    --radius: 12px;
    --radius-sm: 8px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }

/* ========== 导航栏 ========== */
.navbar {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}
.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}
.nav-logo {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary) !important;
    white-space: nowrap;
}
.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}
.nav-links a {
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    transition: all 0.2s;
}
.nav-links a:hover {
    background: var(--primary);
    color: #fff;
}
.nav-user { position: relative; }
.nav-user-name {
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: block;
}
.nav-user:hover .nav-dropdown { display: block; }
.nav-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    min-width: 140px;
    overflow: hidden;
}
.nav-dropdown a {
    display: block;
    padding: 10px 16px;
    font-size: 13px;
    border-radius: 0 !important;
    white-space: nowrap;
}
.nav-dropdown a:hover {
    background: var(--primary);
    color: #fff;
}
.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    color: var(--text);
}

/* ========== 主内容区 ========== */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 20px;
    min-height: calc(100vh - 64px - 60px);
}

/* ========== 按钮 ========== */
.btn {
    display: inline-block;
    padding: 10px 24px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s;
    text-decoration: none;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: #ec4899; color: #fff; }
.btn-success { background: var(--success); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-outline {
    background: #fff;
    color: var(--primary);
    border: 2px solid var(--primary);
}
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-lg { padding: 14px 32px; font-size: 16px; }
.btn-block { display: block; width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* ========== 卡片 ========== */
.card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 20px;
}
.card-header {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

/* ========== 表单 ========== */
.form-group {
    margin-bottom: 20px;
}
.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text);
}
.form-input, .form-textarea, .form-select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: border-color 0.2s;
    background: #fff;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.form-textarea { resize: vertical; min-height: 100px; }
.form-hint { font-size: 12px; color: var(--text-light); margin-top: 4px; }

/* ========== 首页 Hero ========== */
.hero {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 50%, #f472b615 100%);
    border-radius: var(--radius);
    margin-bottom: 40px;
}
.hero h1 {
    font-size: 36px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
}
.hero p {
    font-size: 18px;
    color: var(--text-light);
    margin-bottom: 24px;
}
.hero-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ========== 模板选择区 ========== */
.template-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
}
.template-card {
    background: #fff;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}
.template-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}
.template-card.selected {
    border-color: var(--primary);
    background: #eef2ff;
    box-shadow: 0 0 0 3px rgba(99,102,241,0.15);
}
.template-card.selected::after {
    content: '✓';
    position: absolute;
    top: 8px;
    right: 12px;
    background: var(--primary);
    color: #fff;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.template-icon {
    font-size: 40px;
    margin-bottom: 8px;
    display: block;
}
.template-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
}
.template-category {
    font-size: 11px;
    color: var(--text-light);
    margin-top: 2px;
}

/* ========== 贺卡展示页（仿微信贺卡） ========== */
.card-container {
    max-width: 420px;
    margin: 0 auto;
    padding: 8px 12px 20px;
}
    min-height: calc(100vh - 140px);
}

.card-body {
    border-radius: 16px;
    overflow: hidden;
    background: #f0e6d6;
}
.expired-card, .claimed-card {
    text-align: center;
    padding: 60px 30px 50px;
    background: linear-gradient(180deg,#fef3c7 0%,#fde68a 100%);
    min-height: 400px;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
}
.claimed-card { background: #f1f5f9; }
.expired-card .notice-icon,
.claimed-card .notice-icon { font-size:56px; margin-bottom:16px; }
.expired-card h2, .claimed-card h2 { font-size:22px; color:#1e293b; margin-bottom:8px; }
.expired-card p, .claimed-card p { color:#64748b; font-size:14px; line-height:1.8; }
.claim-sub { font-size:13px !important; opacity:.7; }

/* 背景区域 */
.card-bg-area {
    position: relative;
    min-height: 480px;
}
.card-bg-img {
    position:absolute; top:0; left:0; width:100%; height:100%;
    object-fit: cover;
}
.card-bg-color {
    position:absolute; top:0; left:0; width:100%; height:100%;
    background: linear-gradient(160deg, #f59e0b 0%, #fbbf24 30%, #fcd34d 60%, #fef3c7 100%);
}
.card-overlay {
    position:absolute; top:0; left:0; width:100%; height:100%;
    background: linear-gradient(180deg, rgba(0,0,0,.05) 40%, rgba(0,0,0,.35) 85%);
}

/* 顶部返回 */
.card-top-bar {
    position:relative; z-index:2;
    display:flex; align-items:center; justify-content:space-between;
    padding:10px 14px;
}
.card-back-btn {
    display:inline-flex; align-items:center; justify-content:center;
    width:36px; height:36px; border-radius:50%;
    background:rgba(255,255,255,.3); backdrop-filter:blur(4px);
    color:#fff; font-size:20px; text-decoration:none;
}

/* 贺卡核心内容 */
.card-core {
    position:relative; z-index:2;
    text-align:center;
    padding: 0 24px 36px;
    color:#fff;
}
.card-icon {
    display:block; font-size:52px; margin:4px 0 12px; filter:drop-shadow(0 2px 8px rgba(0,0,0,.15));
}
.card-title {
    font-size:26px; font-weight:800;
    letter-spacing:1px;
    text-shadow:0 2px 12px rgba(0,0,0,.2);
    margin:0 0 6px; line-height:1.3;
}
.card-to {
    font-size:17px; opacity:.92; margin:0 0 18px;
    letter-spacing:.5px;
}
.card-msg {
    font-size:14.5px; line-height:1.9;
    padding:16px 16px;
    background:rgba(255,255,255,.18);
    backdrop-filter:blur(8px);
    border-radius:14px;
    white-space:pre-wrap;
    word-break:break-all;
    box-shadow: inset 0 0 0 .5px rgba(255,255,255,.2);
}

/* 媒体列表 */
.card-media-list {
    margin-top:16px; display:flex; gap:8px; overflow-x:auto;
    scrollbar-width:none; -ms-overflow-style:none;
}
.card-media-list::-webkit-scrollbar{display:none;}
.card-media-list img, .card-media-list video {
    flex-shrink:0; width:120px; height:90px;
    object-fit:cover; border-radius:10px;
    border:2px solid rgba(255,255,255,.5);
}

/* 底部统计 */
.card-meta {
    display:flex; flex-wrap:wrap; gap:6px;
    justify-content:center;
    margin-top:18px; font-size:11.5px; opacity:.75;
}
.card-meta span {
    background:rgba(255,255,255,.2);
    padding:3px 10px; border-radius:20px;
}

/* 底部制作者信息 */
.card-footer-info {
    display:flex; flex-direction:column; align-items:center;
    padding:22px 20px 28px; background:#efe5d5;
}
.footer-avatar {
    width:54px; height:54px; border-radius:50%;
    background:#ddd; margin-bottom:8px; overflow:hidden;
    display:flex; align-items:center; justify-content:center;
}
.footer-avatar svg {width:34px; height:34px; }
.footer-name {
    font-size:15px; color:#333; font-weight:600; margin:0 0 2px;
}
.footer-date {
    font-size:13px; color:#888; margin:0 0 4px;
}
.footer-tag {
    font-size:12px; color:#aaa; margin:0;
}

/* ========== 礼物/红包区域 ========== */
.gift-teaser {
    text-align: center;
    margin: 16px 0;
}
.gift-teaser-btn {
    background: linear-gradient(135deg, #f59e0b, #f472b6);
    color: #fff;
    border: none;
    padding: 16px 40px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(244,114,182,0.4);
    transition: all 0.3s;
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0%, 100% { box-shadow: 0 6px 20px rgba(244,114,182,0.4); }
    50% { box-shadow: 0 6px 40px rgba(244,114,182,0.7); }
}
.gift-teaser-btn:hover {
    transform: scale(1.05);
    animation: none;
}
.gift-detail {
    display: none;
}
.shipping-form-wrap {
    margin-top: 12px;
}
.gift-detail.show { display: block; }
.gift-section {
    margin-bottom: 16px;
    padding: 20px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.gift-show-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid #f1f5f9;
}
.gift-show-icon {
    font-size: 22px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg,#fbbf24,#f59e0b);
    border-radius: 10px;
    flex-shrink: 0;
}
.gift-show-title {
    font-size: 17px;
    font-weight: 700;
    color: #334155;
}
.gift-list { text-align: center; }
.gift-show-img {
    width: 100%;
    max-width: 200px;
    border-radius: 12px;
    margin: 0 auto 14px;
    display: block;
    box-shadow: 0 3px 12px rgba(0,0,0,0.08);
}

/* 礼物信息行 */
.gift-item-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid #f8fafc;
    text-align: left;
}
.gi-badge {
    font-size: 18px;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    flex-shrink: 0;
}
.gi-purple { background: #f0e7ff; }
.gi-blue   { background: #e0f2fe; }
.gi-content { min-width: 0; }
.gi-label {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 2px;
}
.gi-value {
    font-size: 15px;
    color: #334155;
    font-weight: 600;
    word-break: break-all;
}

/* 收货信息卡片 - 白底内嵌 */
.shipping-info-card {
    background: #fafbfc;
    border-radius: 12px;
    padding: 18px;
    margin-top: 16px;
    border: 1px solid #edf2f7;
}
.shipping-info-title {
    font-size: 14px;
    font-weight: 700;
    color: #475569;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
}
.shipping-info-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 0;
}
.shipping-info-row:not(:last-child) { border-bottom: 1px solid #f1f5f9; }
.si-badge {
    font-size: 17px;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    flex-shrink: 0;
}
.si-person { background: #ede9fe; }
.si-phone  { background: #dbeafe; }
.si-addr   { background: #fef3c7; }
.si-text { min-width: 0; }
.si-label {
    display: block;
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 1px;
}
.si-val {
    display: block;
    font-size: 14px;
    color: #334155;
    font-weight: 600;
    word-break: break-all;
}
.redpacket-body { text-align: center; }
.redpacket-qrcode {
    max-width: 180px;
    border-radius: 10px;
    margin: 8px auto;
    display: block;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}
.redpacket-keyword {
    font-size: 20px;
    font-weight: 700;
    color: #dc2626;
    letter-spacing: 3px;
    padding: 12px 24px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 10px;
    display: inline-block;
    margin: 10px auto;
    user-select: all;
}
.redpacket-hint {
    font-size: 12px;
    color: #94a3b8;
    margin-top: 6px;
}
.keyword-hint {
    font-size: 18px;
    font-weight: 700;
    color: #dc2626;
    margin: 16px 0 4px;
}
.redpacket-amount {
    font-size: 24px;
    color: #dc2626;
    font-weight: 800;
    margin-bottom: 6px;
}
.redpacket-remark {
    font-size: 13px;
    color: #94a3b8;
    margin-top: 10px;
}

/* 二维码上传区域 */
.qr-upload-box {
    background: #f8fafc;
    border: 2px dashed #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
}
.qr-upload-title {
    font-size: 15px;
    font-weight: 700;
    color: #334155;
    margin-bottom: 4px;
}
.qr-upload-desc {
    font-size: 13px;
    color: #94a3b8;
    margin-bottom: 14px;
}
.qr-upload-form { text-align: left; }
.qr-file-label {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: border 0.2s;
}
.qr-file-label:hover { border-color: #cbd5e1; }
.qr-file-label input[type="file"] { display: none; }
.qr-file-label span {
    font-size: 14px;
    color: #64748b;
}

/* ========== 已领取提示 ========== */
/* ========== 已领取 / 过期 ========== */
.claimed-notice {
    text-align:center; padding:60px 30px 50px;
}
.make-similar {
    text-align: center;
    margin: 20px 0;
}
.make-similar a {
    display: inline-block;
    padding: 13px 32px;
    border: 2px dashed #f9a8d4;
    border-radius: 50px;
    color: #db2777;
    font-weight: 650;
    font-size: 15px;
    background: #fdf2f8;
    transition: all 0.3s ease;
}
.make-similar a:hover {
    background: #fce7f3;
    border-color: #ec4899;
    transform: translateY(-1px);
}

/* ========== 创建表单 ========== */
.create-container {
    max-width: 700px;
    margin: 0 auto;
}
.section-title {
    font-size: 16px;
    font-weight: 700;
    margin: 24px 0 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--primary);
    color: var(--primary);
}
.toggle-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}
.toggle-switch {
    position: relative;
    width: 48px;
    height: 26px;
}
.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background: #ccc;
    border-radius: 26px;
    transition: 0.3s;
}
.toggle-slider::before {
    content: '';
    position: absolute;
    height: 20px; width: 20px;
    left: 3px; bottom: 3px;
    background: #fff;
    border-radius: 50%;
    transition: 0.3s;
}
input:checked + .toggle-slider { background: var(--primary); }
input:checked + .toggle-slider::before { transform: translateX(22px); }
.toggle-label { font-size: 14px; font-weight: 500; }

.media-upload-area {
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    padding: 30px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 12px;
}
.media-upload-area:hover {
    border-color: var(--primary);
    background: #f8faff;
}
.media-upload-area .upload-icon {
    font-size: 40px;
    margin-bottom: 8px;
}
.media-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
}
.media-preview-item {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 8px;
    overflow: hidden;
}
.media-preview-item img, .media-preview-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.media-preview-item .remove-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
}

/* ========== 我的祝福列表 ========== */
.blessing-list { display: flex; flex-direction: column; gap: 16px; }
.blessing-item {
    background: #fff;
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s;
}
.blessing-item:hover { box-shadow: var(--shadow-lg); }
.blessing-item-left { flex: 1; }
.blessing-item-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}
.blessing-item-info {
    font-size: 13px;
    color: var(--text-light);
}
.blessing-item-actions { display: flex; gap: 8px; flex-shrink: 0; }
.badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}
.badge-success { background: #d1fae5; color: #065f46; }
.badge-warning { background: #fef3c7; color: #92400e; }
.badge-danger { background: #fee2e2; color: #991b1b; }
.badge-info { background: #dbeafe; color: #1e40af; }

/* ========== 提示消息 ========== */
.alert {
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    font-size: 14px;
}
.alert-success { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.alert-error { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.alert-info { background: #dbeafe; color: #1e40af; border: 1px solid #bfdbfe; }

/* ========== 底部 ========== */
.footer {
    text-align: center;
    padding: 20px;
    color: var(--text-light);
    font-size: 13px;
    border-top: 1px solid var(--border);
}
.footer-content { max-width: 1200px; margin: 0 auto; }
.footer-icp { margin-top: 4px; font-size: 12px; }
.footer-icp a { color: var(--text-light); text-decoration: none; }
.footer-icp a:hover { color: var(--primary); }

/* ========== 登录/注册 ========== */
.auth-container {
    max-width: 420px;
    margin: 40px auto;
}
.auth-card {
    background: #fff;
    border-radius: 20px;
    padding: 40px;
    box-shadow: var(--shadow-lg);
}
.auth-card h2 {
    text-align: center;
    margin-bottom: 8px;
    font-size: 24px;
}
.auth-card .auth-sub {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 24px;
    font-size: 14px;
}
.auth-footer {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: var(--text-light);
}

/* ========== 响应式 ========== */
@media (max-width: 768px) {
    .nav-links { 
        display: none; 
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        padding: 10px;
        box-shadow: var(--shadow-lg);
    }
    .nav-links.open { display: flex; }
    .nav-toggle { display: block; }
    .hero h1 { font-size: 28px; }
    .hero p { font-size: 15px; }
    .template-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); }
    .blessing-item { flex-direction: column; gap: 12px; }
    .blessing-item-actions { width: 100%; }
    .gift-item-row, .shipping-info-row { gap: 10px; }
    .gi-value, .si-val { font-size: 13px; }
}

/* ========== 分页 ========== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 24px;
}
.pagination a, .pagination span {
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
    border: 1px solid var(--border);
}
.pagination a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination .active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ========== 文件上传 ========== */
input[type="file"] { display: none; }
.file-upload-label {
    display: inline-block;
    padding: 10px 20px;
    background: var(--primary);
    color: #fff;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
}
.file-upload-label:hover { background: var(--primary-dark); }

/* ========== 弹窗 ========== */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}
.modal-overlay.show { display: flex; }
.modal {
    background: #fff;
    border-radius: var(--radius);
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}
.modal h3 { margin-bottom: 16px; }

/* ========== 后台 ========== */
.admin-layout { display: flex; }
.admin-sidebar {
    width: 220px;
    background: #1e293b;
    min-height: calc(100vh - 64px);
    padding: 20px 0;
}
.admin-sidebar a {
    display: block;
    padding: 12px 24px;
    color: #94a3b8;
    font-size: 14px;
    transition: all 0.2s;
}
.admin-sidebar a:hover, .admin-sidebar a.active {
    background: #334155;
    color: #fff;
}
.admin-content { flex: 1; padding: 24px; }
.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: var(--radius);
    overflow: hidden;
}
.admin-table th, .admin-table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}
.admin-table th {
    background: #f8fafc;
    font-weight: 600;
}
.admin-table tr:hover td { background: #f8fafc; }
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}
.admin-stat-card {
    background: #fff;
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
}
.admin-stat-card .stat-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary);
}
.admin-stat-card .stat-label {
    font-size: 13px;
    color: var(--text-light);
    margin-top: 4px;
}

/* 红包类型选择 */
.redpacket-type-selector {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}
.redpacket-type-option {
    flex: 1;
    padding: 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}
.redpacket-type-option:hover, .redpacket-type-option.selected {
    border-color: var(--primary);
    background: #eef2ff;
}
.redpacket-type-option .type-icon { font-size: 28px; display: block; margin-bottom: 6px; }
.redpacket-type-option .type-name { font-size: 14px; font-weight: 600; }
.redpacket-type-form { display: none; }
.redpacket-type-form.active { display: block; }

/* ========== 烟花祝福音乐字段 ========== */
.firework-music-field {
    background: linear-gradient(135deg, #fef9c3 0%, #fde68a 100%);
    border: 2px dashed #f59e0b;
    border-radius: var(--radius);
    padding: 18px 20px;
    margin-bottom: 20px;
    animation: fireworkFieldIn .4s ease;
}
@keyframes fireworkFieldIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}
.firework-music-field .form-label {
    color: #92400e;
}
.firework-music-field .form-input {
    border-color: #fcd34d;
}
.firework-music-field .form-input:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245,158,11,.15);
}
