/* ============================================================
   便签记录 notes.s1.css
   琥珀黄渐变主题 + 玻璃拟态，彩色便签卡片，移动端单列自适应
   ============================================================ */

.note-card {
    background: linear-gradient(160deg, rgba(255,255,255,0.96), rgba(254,243,199,0.92));
    border: 1px solid rgba(234, 179, 8, 0.35);
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(234, 179, 8, 0.10);
    padding: 22px;
    position: relative;
    overflow: hidden;
}
.note-card::before {
    content: '';
    position: absolute;
    top: -60px; right: -60px;
    width: 200px; height: 200px;
    background: radial-gradient(circle, rgba(245,158,11,0.10), transparent 70%);
    pointer-events: none;
}
.note-card::after {
    content: '';
    position: absolute;
    bottom: -40px; left: -40px;
    width: 180px; height: 180px;
    background: radial-gradient(circle, rgba(234,179,8,0.08), transparent 70%);
    pointer-events: none;
}
.note-icon {
    background: linear-gradient(135deg, #eab308 0%, #f59e0b 100%) !important;
    box-shadow: 0 6px 18px rgba(234, 179, 8, 0.35);
    animation: note-breath 3s ease-in-out infinite;
}
@keyframes note-breath {
    0%, 100% { box-shadow: 0 6px 18px rgba(234,179,8,0.35); }
    50% { box-shadow: 0 6px 26px rgba(245,158,11,0.55); }
}

/* ---------- 登录引导 ---------- */
.note-login-guide { text-align: center; padding: 34px 16px 26px; position: relative; z-index: 1; }
.note-login-guide i { font-size: 40px; background: linear-gradient(135deg,#eab308,#f59e0b); -webkit-background-clip: text; background-clip: text; color: transparent; }
.note-login-guide h3 { margin: 12px 0 6px; font-size: 1.05rem; color: #1e293b; }
.note-login-guide p { margin: 0 0 18px; font-size: 0.85rem; color: #64748b; }
.note-login-btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.note-login-btns a {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 10px 26px; border-radius: 999px; text-decoration: none;
    font-size: 0.9rem; font-weight: 600; transition: all .25s ease;
}
.note-login-btns a.main { background: linear-gradient(135deg,#eab308,#f59e0b); color: #fff; box-shadow: 0 6px 16px rgba(234,179,8,0.35); }
.note-login-btns a.main:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(245,158,11,0.45); }
.note-login-btns a.ghost { border: 1.5px solid rgba(234,179,8,0.45); color: #b45309; background: rgba(255,255,255,0.7); }
.note-login-btns a.ghost:hover { background: rgba(234,179,8,0.08); }

/* ---------- 统计条 ---------- */
.note-stats-bar {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    margin: 6px 0 14px; position: relative; z-index: 1;
}
.note-stat-chip {
    display: inline-flex; align-items: center; gap: 6px;
    background: rgba(255,255,255,0.7); border: 1px solid rgba(234,179,8,0.22);
    padding: 7px 14px; border-radius: 999px;
    font-size: 0.8rem; color: #92400e; font-weight: 500;
}
.note-stat-chip i { color: #eab308; }
.note-stat-chip b { color: #b45309; font-weight: 700; }
.note-stat-chip.pinned i { color: #ef4444; }
.note-stat-chip.category i { color: #8b5cf6; }
.note-add-btn {
    margin-left: auto; border: none; cursor: pointer;
    padding: 9px 18px; border-radius: 999px;
    font-size: 0.85rem; font-weight: 600; color: #fff;
    background: linear-gradient(135deg,#eab308,#f59e0b);
    box-shadow: 0 4px 12px rgba(234,179,8,0.3);
    display: inline-flex; align-items: center; gap: 6px;
    transition: all .25s ease;
}
.note-add-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 18px rgba(245,158,11,0.4); }

/* ---------- Tabs ---------- */
.note-tabs {
    display: flex; gap: 5px; margin: 0 0 16px;
    background: rgba(254,243,199,0.55); border: 1px solid rgba(234,179,8,0.28);
    padding: 5px; border-radius: 14px;
    position: relative; z-index: 1;
    overflow-x: auto; -webkit-overflow-scrolling: touch;
}
.note-tabs::-webkit-scrollbar { display: none; }
.note-tab {
    flex: 1 0 auto; border: none; background: transparent; cursor: pointer;
    padding: 9px 12px; border-radius: 10px; font-size: 0.85rem; font-weight: 600;
    color: #94a3b8; display: inline-flex; align-items: center; justify-content: center; gap: 5px;
    transition: all .22s ease; white-space: nowrap;
}
.note-tab i { font-size: 0.8rem; }
.note-tab:hover { color: #b45309; }
.note-tab.active {
    background: linear-gradient(135deg,#eab308,#f59e0b); color: #fff;
    box-shadow: 0 4px 14px rgba(234,179,8,0.35);
}
.note-pane { display: none; animation: note-slide-in .3s ease; position: relative; z-index: 1; }
.note-pane.active { display: block; }
@keyframes note-slide-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- 便签墙网格 ---------- */
.note-wall-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
}
.note-card-item {
    position: relative;
    border-radius: 14px;
    padding: 14px 14px 16px;
    min-height: 130px;
    display: flex; flex-direction: column;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
    transition: transform .2s ease, box-shadow .2s ease;
    cursor: pointer;
    border: 1px solid rgba(0,0,0,0.04);
    overflow: hidden;
}
.note-card-item:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(0,0,0,0.12); }
.note-card-item.pinned {
    box-shadow: 0 6px 20px rgba(239,68,68,0.18);
    border: 1.5px solid rgba(239,68,68,0.35);
}
.note-card-item.pinned::before {
    content: '\f08d';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute; top: 8px; right: 10px;
    font-size: 0.75rem; color: #ef4444;
    transform: rotate(20deg);
}
.note-card-title {
    font-size: 0.92rem; font-weight: 700; color: #1e293b;
    margin-bottom: 6px; padding-right: 18px;
    word-break: break-word; line-height: 1.4;
}
.note-card-title:empty::before { content: '无标题'; color: #94a3b8; font-weight: 500; }
.note-card-content {
    font-size: 0.82rem; color: #475569; line-height: 1.55;
    flex: 1; word-break: break-word;
    display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical;
    overflow: hidden;
}
.note-card-content:empty::before { content: '无内容'; color: #94a3b8; }
.note-card-meta {
    display: flex; align-items: center; justify-content: space-between;
    margin-top: 10px; font-size: 0.7rem; color: #64748b;
}
.note-card-cat {
    display: inline-flex; align-items: center; gap: 3px;
    background: rgba(255,255,255,0.6); padding: 2px 8px; border-radius: 999px;
    max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.note-card-actions {
    display: flex; gap: 4px;
}
.note-card-actions button {
    border: none; background: rgba(255,255,255,0.7); cursor: pointer;
    width: 24px; height: 24px; border-radius: 6px;
    font-size: 0.7rem; color: #64748b;
    display: inline-flex; align-items: center; justify-content: center;
    transition: all .15s;
}
.note-card-actions button:hover { background: rgba(255,255,255,0.95); color: #b45309; }
.note-card-actions button.pin.on { color: #ef4444; }
.note-card-actions button.del:hover { color: #ef4444; }

/* ---------- 全部列表 ---------- */
.note-all-list { display: flex; flex-direction: column; gap: 10px; }
.note-all-item {
    display: flex; align-items: center; gap: 12px;
    background: rgba(255,255,255,0.8); border: 1px solid rgba(234,179,8,0.18);
    border-radius: 12px; padding: 12px 14px;
    transition: all .2s;
}
.note-all-item:hover { box-shadow: 0 4px 14px rgba(234,179,8,0.12); transform: translateX(2px); }
.note-all-dot { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }
.note-all-info { flex: 1; min-width: 0; }
.note-all-title { font-size: 0.88rem; font-weight: 600; color: #1e293b; word-break: break-word; }
.note-all-title:empty::before { content: '无标题'; color: #94a3b8; font-weight: 500; }
.note-all-meta { font-size: 0.72rem; color: #94a3b8; margin-top: 3px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.note-all-pin { color: #ef4444; font-size: 0.68rem; }
.note-all-actions { display: flex; gap: 6px; flex-shrink: 0; }
.note-all-btn { border: none; background: rgba(234,179,8,0.08); color: #b45309; width: 30px; height: 30px; border-radius: 8px; cursor: pointer; font-size: 0.8rem; transition: all .2s; }
.note-all-btn:hover { background: rgba(234,179,8,0.18); }
.note-all-btn.del { color: #ef4444; background: rgba(239,68,68,0.08); }
.note-all-btn.del:hover { background: rgba(239,68,68,0.18); }
.note-all-btn.pin.on { color: #ef4444; }

/* ---------- 分类Tab ---------- */
.note-cat-tabs {
    display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px;
}
.note-cat-tab {
    border: 1.5px solid rgba(234,179,8,0.3); background: rgba(255,255,255,0.7);
    color: #92400e; padding: 6px 14px; border-radius: 999px;
    font-size: 0.8rem; font-weight: 500; cursor: pointer; transition: all .2s;
}
.note-cat-tab:hover { background: rgba(234,179,8,0.1); }
.note-cat-tab.active { background: linear-gradient(135deg,#eab308,#f59e0b); color: #fff; border-color: transparent; }

/* ---------- 空状态 ---------- */
.note-empty { text-align: center; padding: 40px 16px; color: #94a3b8; }
.note-empty i { font-size: 2.4rem; margin-bottom: 10px; opacity: 0.4; color: #eab308; }
.note-empty div { font-size: 0.88rem; }

/* ---------- 表单弹窗 ---------- */
.note-modal-mask {
    position: fixed; inset: 0; background: rgba(15,23,42,0.45);
    z-index: 999998; display: flex; align-items: center; justify-content: center;
    padding: 16px; animation: note-fade .2s ease;
}
@keyframes note-fade { from { opacity: 0; } to { opacity: 1; } }
.note-modal {
    background: #fff; border-radius: 18px; max-width: 480px; width: 100%;
    padding: 22px; box-shadow: 0 20px 60px rgba(0,0,0,0.25);
    animation: note-pop .25s ease;
    max-height: 88vh; overflow-y: auto;
}
@keyframes note-pop { from { opacity: 0; transform: scale(0.92); } to { opacity: 1; transform: scale(1); } }
.note-modal-title { font-size: 1.05rem; font-weight: 700; color: #92400e; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.note-modal-title i { color: #eab308; }
.note-field { margin-bottom: 14px; }
.note-field label { display: block; font-size: 0.82rem; font-weight: 600; color: #475569; margin-bottom: 7px; }
.note-field label i { color: #eab308; margin-right: 4px; }
.note-field input[type="text"] {
    width: 100%; box-sizing: border-box;
    padding: 10px 12px; border: 1.5px solid rgba(234,179,8,0.25);
    border-radius: 10px; font-size: 0.88rem; color: #1e293b;
    background: #fff; transition: border-color .2s, box-shadow .2s;
}
.note-field input:focus { outline: none; border-color: #eab308; box-shadow: 0 0 0 3px rgba(234,179,8,0.12); }
.note-field textarea {
    width: 100%; box-sizing: border-box;
    padding: 11px 12px; border: 1.5px solid rgba(234,179,8,0.25);
    border-radius: 10px; font-size: 0.88rem; color: #1e293b;
    background: #fff; resize: vertical; min-height: 110px; font-family: inherit;
    transition: border-color .2s, box-shadow .2s;
}
.note-field textarea:focus { outline: none; border-color: #eab308; box-shadow: 0 0 0 3px rgba(234,179,8,0.12); }

/* 颜色选择 */
.note-color-grid { display: flex; gap: 8px; flex-wrap: wrap; }
.note-color-item {
    width: 32px; height: 32px; border-radius: 50%; cursor: pointer;
    border: 2px solid transparent; transition: all .2s;
    position: relative;
}
.note-color-item.active { border-color: #1e293b; transform: scale(1.1); }
.note-color-item.active::after {
    content: '\f00c'; font-family: 'Font Awesome 6 Free'; font-weight: 900;
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    font-size: 0.7rem; color: rgba(0,0,0,0.5);
}

.note-save-row { display: flex; gap: 10px; margin-top: 18px; }
.note-save-btn {
    flex: 1; border: none; cursor: pointer;
    padding: 12px 20px; border-radius: 12px;
    font-size: 0.92rem; font-weight: 600; color: #fff;
    background: linear-gradient(135deg,#eab308,#f59e0b);
    box-shadow: 0 6px 16px rgba(234,179,8,0.35);
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    transition: all .25s ease;
}
.note-save-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(245,158,11,0.45); }
.note-cancel-btn {
    border: 1.5px solid rgba(234,179,8,0.4); cursor: pointer;
    padding: 12px 20px; border-radius: 12px;
    font-size: 0.92rem; font-weight: 600; color: #b45309; background: rgba(255,255,255,0.7);
    transition: all .2s;
}
.note-cancel-btn:hover { background: rgba(234,179,8,0.08); }

/* ---------- 详情弹窗 ---------- */
.note-detail-modal .note-detail-title { font-size: 1.1rem; font-weight: 700; color: #1e293b; margin-bottom: 10px; word-break: break-word; line-height: 1.4; }
.note-detail-modal .note-detail-content { font-size: 0.88rem; color: #475569; line-height: 1.7; word-break: break-word; white-space: pre-wrap; margin-bottom: 14px; }
.note-detail-modal .note-detail-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: 0.75rem; color: #94a3b8; padding-top: 12px; border-top: 1px solid #f1f5f9; }
.note-detail-modal .note-detail-meta span { display: inline-flex; align-items: center; gap: 4px; }

/* ---------- Toast ---------- */
.note-toast {
    position: fixed; top: 20px; left: 50%; transform: translateX(-50%);
    background: #fff; padding: 12px 20px; border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    display: flex; align-items: center; gap: 10px;
    font-size: 0.88rem; font-weight: 500; z-index: 999999;
    border-left: 4px solid #eab308;
    animation: note-toast-in .3s ease;
    max-width: 90vw;
}
.note-toast.success { border-left-color: #10b981; }
.note-toast.error { border-left-color: #ef4444; }
.note-toast.warning { border-left-color: #f59e0b; }
.note-toast.info { border-left-color: #3b82f6; }
.note-toast i { font-size: 1rem; }
.note-toast.success i { color: #10b981; }
.note-toast.error i { color: #ef4444; }
.note-toast.warning i { color: #f59e0b; }
.note-toast.info i { color: #3b82f6; }
@keyframes note-toast-in { from { opacity: 0; transform: translateX(-50%) translateY(-15px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }

/* ---------- 响应式 ---------- */
@media (max-width: 600px) {
    .note-card { padding: 14px; border-radius: 16px; }
    .note-tab { padding: 8px 10px; font-size: 0.78rem; }
    .note-tab i { display: none; }
    .note-stats-bar { gap: 6px; }
    .note-stat-chip { padding: 5px 10px; font-size: 0.72rem; }
    .note-add-btn { padding: 7px 14px; font-size: 0.78rem; }
    .note-wall-grid { grid-template-columns: 1fr; gap: 10px; }
    .note-card-item { min-height: 100px; padding: 12px; }
    .note-modal { padding: 16px; }
}
