/* 规矩便签 - Google Keep 风格彩色便签墙（黑白主题 + 柔和纸色） */
:root {
    --fg: #1a1a1a;
    --bg: #ffffff;
    --muted: #8a8a8a;
    --border: #e5e5e5;
}

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

body {
    font-family: Arial, "Microsoft YaHei", sans-serif;
    background: var(--bg);
    color: var(--fg);
    padding-bottom: 90px;
}

.nt-wrap { max-width: 720px; margin: 0 auto; padding: 26px 16px 10px; }

.nt-head { text-align: center; margin-bottom: 18px; }
.nt-head h1 { font-size: 1.6rem; letter-spacing: 4px; }
.nt-sub { color: var(--muted); font-size: 0.78rem; margin-top: 8px; letter-spacing: 1px; }

/* 编辑器 */
.nt-composer {
    border: 2px solid var(--fg); border-radius: 10px;
    padding: 12px; margin-bottom: 20px;
}
.nt-composer textarea {
    width: 100%; border: none; resize: vertical; outline: none;
    font: inherit; font-size: 0.92rem; line-height: 1.7; min-height: 72px;
    background: transparent; color: var(--fg);
}
.nt-composer-bar { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }

.nt-colors { display: flex; gap: 8px; }
.nt-dot {
    width: 22px; height: 22px; border-radius: 50%;
    border: 1.5px solid #bbb; cursor: pointer; background: #fff;
}
.nt-dot.c1 { background: #f6efdd; }
.nt-dot.c2 { background: #e8efe6; }
.nt-dot.c3 { background: #f5eaea; }
.nt-dot.c4 { background: #ececec; }
.nt-dot.active { border-color: var(--fg); box-shadow: 0 0 0 2px var(--bg) inset, 0 0 0 1.5px var(--fg); }

.nt-add {
    background: var(--fg); color: var(--bg); border: none;
    padding: 8px 20px; border-radius: 8px; font-size: 0.85rem; cursor: pointer;
}
.nt-add:hover { opacity: 0.85; }

/* 便签墙：两列瀑布 */
.nt-grid { columns: 2; column-gap: 10px; }
.nt-note {
    break-inside: avoid; margin-bottom: 10px;
    border: 1.5px solid rgba(0,0,0,0.18); border-radius: 10px;
    padding: 12px 12px 8px; position: relative;
    background: var(--note-bg, #fff);
    box-shadow: 0 1px 3px rgba(0,0,0,0.07);
}
.nt-note.c0 { --note-bg: #ffffff; }
.nt-note.c1 { --note-bg: #f6efdd; }
.nt-note.c2 { --note-bg: #e8efe6; }
.nt-note.c3 { --note-bg: #f5eaea; }
.nt-note.c4 { --note-bg: #ececec; }

.nt-note .nn-pin {
    position: absolute; top: 8px; right: 8px;
    background: none; border: none; cursor: pointer;
    font-size: 0.95rem; opacity: 0.4; padding: 2px 4px;
}
.nt-note .nn-pin.on { opacity: 1; }

.nt-note .nn-body { font-size: 0.85rem; line-height: 1.8; word-break: break-word; }
.nt-note .nn-line { display: flex; gap: 6px; align-items: flex-start; }
.nt-note .nn-check {
    flex: none; width: 15px; height: 15px; margin-top: 4px;
    border: 1.5px solid rgba(0,0,0,0.45); border-radius: 4px;
    cursor: pointer; text-align: center; line-height: 13px; font-size: 11px;
    user-select: none;
}
.nt-note .nn-line.done .nn-text { text-decoration: line-through; opacity: 0.5; }
.nt-note .nn-line.done .nn-check { background: rgba(0,0,0,0.65); color: #fff; }
.nt-note .nn-text { flex: 1; white-space: pre-wrap; }

.nt-note .nn-foot {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 8px; font-size: 0.64rem; color: rgba(0,0,0,0.4);
}
.nt-note .nn-del { background: none; border: none; cursor: pointer; font-size: 0.78rem; color: rgba(0,0,0,0.4); padding: 2px 4px; }
.nt-note .nn-del:hover { color: #c0392b; }
.nt-note .nn-time { letter-spacing: 0.3px; }

/* 空态 */
.nt-empty { text-align: center; color: var(--muted); padding: 40px 0; }
.nt-empty .ne-icon { font-size: 2rem; }
.nt-empty p { font-size: 0.8rem; margin-top: 10px; }

@media (max-width: 420px) {
    .nt-grid { columns: 2; column-gap: 8px; }
    .nt-note { padding: 10px 10px 7px; }
    .nt-note .nn-body { font-size: 0.8rem; }
}
