/* ========================================
   Memo App Styles
   メモ
   ======================================== */

/* 备忘录容器 */
.memo-app {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: linear-gradient(180deg,
        rgba(20, 18, 28, 0.95) 0%,
        rgba(30, 25, 40, 0.98) 100%);
}

/* ========================================
   备忘录列表视图
   ======================================== */
.memo-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px 16px;
}

.memo-list::-webkit-scrollbar {
    width: 4px;
}

.memo-list::-webkit-scrollbar-track {
    background: transparent;
}

.memo-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
}

/* 备忘录卡片 */
.memo-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.memo-card:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.1);
}

.memo-card:active {
    transform: scale(0.98);
}

.memo-card-title {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.memo-card-preview {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.memo-card-date {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.25);
    margin-top: 8px;
}

/* 重要/危险备忘录标记 */
.memo-card.danger {
    border-left: 3px solid rgba(200, 100, 100, 0.5);
    background: rgba(200, 100, 100, 0.05);
}

.memo-card.danger:hover {
    background: rgba(200, 100, 100, 0.08);
}

.memo-card.important {
    border-left: 3px solid rgba(200, 160, 100, 0.5);
    background: rgba(200, 160, 100, 0.05);
}

.memo-card.important:hover {
    background: rgba(200, 160, 100, 0.08);
}

/* ========================================
   备忘录详情视图
   ======================================== */
.memo-detail {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.memo-detail-header {
    padding: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    flex-shrink: 0;
}

.memo-detail-title {
    font-size: 18px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 4px;
}

.memo-detail-date {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.35);
}

.memo-detail-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
}

.memo-detail-content::-webkit-scrollbar {
    width: 4px;
}

.memo-detail-content::-webkit-scrollbar-track {
    background: transparent;
}

.memo-detail-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
}

/* 备忘录内容样式 */
.memo-detail-content h3 {
    font-size: 15px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    margin: 0 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.memo-detail-content p {
    margin: 0 0 12px 0;
}

.memo-detail-content strong {
    color: rgba(255, 255, 255, 0.95);
    font-weight: 500;
}

/* 清单样式 */
.memo-detail-content ul {
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
}

.memo-detail-content li {
    position: relative;
    padding: 8px 0 8px 28px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-size: 13px;
}

.memo-detail-content li:last-child {
    border-bottom: none;
}

/* 复选框样式 */
.memo-detail-content li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    background: transparent;
}

.memo-detail-content li.checked::before {
    background: rgba(200, 160, 100, 0.3);
    border-color: rgba(200, 160, 100, 0.6);
}

.memo-detail-content li.checked::after {
    content: '✓';
    position: absolute;
    left: 3px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 11px;
    color: #c9a86c;
}

.memo-detail-content li.checked {
    color: rgba(255, 255, 255, 0.4);
    text-decoration: line-through;
    text-decoration-color: rgba(255, 255, 255, 0.2);
}

/* 未完成任务 */
.memo-detail-content li.unchecked::before {
    border-color: rgba(255, 255, 255, 0.25);
}

/* 警告/注意文字 */
.memo-warning {
    color: rgba(220, 120, 120, 0.9);
    font-weight: 500;
}

.memo-highlight {
    color: #c9a86c;
}

/* 小标题 */
.memo-section-title {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    margin: 20px 0 10px 0;
    letter-spacing: 0.5px;
}

.memo-section-title:first-child {
    margin-top: 0;
}

/* 备忘录底部返回按钮 */
.memo-back-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 16px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.2s ease;
}

.memo-back-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.9);
}

.memo-back-btn svg {
    width: 16px;
    height: 16px;
}

/* 删除线文字（用于删除预定的内容） */
.memo-deleted {
    text-decoration: line-through;
    text-decoration-color: rgba(220, 120, 120, 0.5);
    color: rgba(255, 255, 255, 0.35);
}

/* 移动端适配 */
@media (max-width: 380px) {
    .memo-list {
        padding: 8px 12px;
    }

    .memo-card {
        padding: 12px 14px;
    }

    .memo-card-title {
        font-size: 13px;
    }

    .memo-detail-content {
        padding: 14px;
        font-size: 13px;
    }
}
