.note-v2 { width:min(960px,100%); height:min(820px,calc(100dvh - 32px)); display:flex; flex-direction:column; background:#fff; color:#1e293b; border:1px solid #e5e7eb; border-radius:20px; box-shadow:0 24px 60px #0003; overflow:hidden; font-size:13px; }
.note-v2-full { position:fixed; inset:0; width:100%; height:100dvh; border-radius:0; z-index:100; }
.note-v2 button { min-height:44px; padding:8px 12px; border-radius:9px; font-size:12px; font-weight:600; }
.note-v2 button:hover { background:#eff6ff; }
.note-v2 button:focus-visible,.note-v2 input:focus-visible { outline:2px solid #3b82f6; outline-offset:-2px; }
.note-v2 button:disabled { opacity:.45; cursor:not-allowed; }
.note-v2-header { display:flex; align-items:center; flex-shrink:0; gap:4px; padding:8px 16px; border-bottom:1px solid #f1f5f9; }
.note-v2-label { font-weight:700; white-space:nowrap; }
.note-v2-status { margin-left:auto; color:#64748b; font-size:11px; }
.note-v2-title { flex-shrink:0; padding:20px 32px 12px; width:100%; background:transparent; font-size:24px; font-weight:700; border:0; outline:none; }
.note-v2-toolbar { display:flex; align-items:center; flex-shrink:0; gap:4px; padding:0 24px 8px; border-bottom:1px solid #e5e7eb; }
.note-v2-toolbar button { min-width:44px; }
.note-v2 button[aria-pressed=true] { background:#dbeafe; color:#1d4ed8; }
.note-v2-menu,.note-v2-link { display:flex; flex-wrap:wrap; gap:4px; padding:8px 24px; border-bottom:1px solid #e5e7eb; flex-shrink:0; }
.note-v2-link label { flex:1; min-width:200px; }.note-v2-link input { width:100%; padding:10px; border:1px solid #cbd5e1; border-radius:8px; background:transparent; }
.note-v2-scroll { min-height:0; overflow-y:auto; overscroll-behavior:contain; flex:1; }
.note-v2-canvas { min-height:320px; padding:24px 32px 40px; font-size:16px; line-height:1.7; outline:none; white-space:pre-wrap; overflow-wrap:anywhere; }
.note-v2-canvas p { margin:.35em 0; }.note-v2-canvas h2 { font-size:1.5em; font-weight:700; margin:.8em 0 .3em; }.note-v2-canvas h3 { font-size:1.2em; font-weight:700; margin:.7em 0 .3em; }
.note-v2-canvas ul { list-style:disc; padding-left:1.6em; }.note-v2-canvas ol { list-style:decimal; padding-left:1.6em; }.note-v2-canvas li p { margin:0; }
.note-v2-canvas blockquote { border-left:3px solid #93c5fd; padding-left:1em; margin:1em 0; color:#64748b; }.note-v2-canvas a { color:#2563eb; text-decoration:underline; cursor:text; }
/* TaskItem NodeViews omit data-type; the parent TaskList identifies both live and serialized rows. */
.note-v2-canvas ul[data-type=taskList] { padding-left:0; list-style:none; }.note-v2-canvas ul[data-type=taskList]>li { display:flex; gap:.6em; align-items:flex-start; }.note-v2-canvas ul[data-type=taskList]>li>label { display:flex; align-items:center; min-height:32px; min-width:32px; cursor:pointer; }.note-v2-canvas ul[data-type=taskList]>li>div { flex:1; min-width:0; }.note-v2-canvas input[type=checkbox] { width:18px; height:18px; accent-color:#3b82f6; }
.note-v2-details-toggle { width:100%; text-align:left; border-top:1px solid #e5e7eb; color:#64748b; padding-left:32px!important; }.note-v2-details { padding:16px 32px; display:grid; gap:14px; }
.note-v2-footer { display:flex; align-items:center; justify-content:space-between; flex-shrink:0; padding:8px 24px max(8px,env(safe-area-inset-bottom)); border-top:1px solid #e5e7eb; }.note-v2 .note-v2-save { background:#3b82f6; color:white; min-width:100px; }.note-v2-message { margin:0; padding:8px 24px; color:#92400e; background:#fffbeb; font-size:12px; }
.dark .note-v2 { background:#111827; color:#e5e7eb; border-color:#374151; }.dark .note-v2-header,.dark .note-v2-toolbar,.dark .note-v2-footer,.dark .note-v2-details-toggle { border-color:#374151; }.dark .note-v2 button:hover { background:#1f2937; }.dark .note-v2 button[aria-pressed=true] { background:#1e3a5f; color:#93c5fd; }
@media(max-width:767px) { .note-v2 { height:calc(100dvh - 16px); border-radius:14px; }.note-v2-full { height:100dvh; border-radius:0; }.note-v2-header { padding:4px 8px; flex-wrap:wrap; }.note-v2-label { display:none; }.note-v2-title { padding:14px 18px 10px; font-size:21px!important; }.note-v2-toolbar { padding:0 12px 6px; gap:2px; }.note-v2-canvas { padding:16px 18px 28px; min-height:45dvh; }.note-v2-details { padding:12px 18px; }.note-v2-menu,.note-v2-link { padding:6px 12px; }.note-v2-canvas ul[data-type=taskList]>li>label { min-height:44px; min-width:36px; }.note-v2-canvas ul[data-type=taskList]>li>div { padding-top:7px; } }

/* Canvas also runs inside a ShadowRoot to isolate the existing runtime CSS scanner. */
.note-v2-canvas, .note-v2-canvas * { box-sizing:border-box; }
.note-v2-canvas { font-family:inherit; color:inherit; }

/* Embedded body shares the Note engine without its title/modal/metadata shell. */
.note-v2.rich-content-embedded { width:100%; height:auto; min-width:0; border-radius:12px; box-shadow:none; }
.rich-content-embedded .note-v2-scroll { max-height:55dvh; min-height:180px; }

.note-v2-embedded-status { margin:0; min-height:24px; padding:4px 16px; color:#64748b; font-size:11px; line-height:16px; }
