﻿.modal-card[data-modal="notes"] .modal-body,
.modal-card[data-modal="privacy"] .modal-body,
.modal-card[data-modal="licenses"] .modal-body {
  padding: 0;
  background: transparent;
}

.app-notes {
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 0;
  background: #11161d;
  overflow: hidden;
}

.notes-tabs {
  min-height: 1.9rem;
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 0.2rem;
  padding: 0 0 0 0.16rem;
  border: none;
  background: #252033;
}

.notes-tab-group {
  min-width: 0;
  display: inline-flex;
  align-items: flex-end;
  gap: 0.2rem;
}

.notes-tab {
  min-height: 1.62rem;
  min-width: 8rem;
  border: none;
  border-radius: 0.42rem 0.42rem 0 0;
  background: #223041;
  color: #f2f6ff;
  font-size: 0.66rem;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.46rem;
  padding: 0 0.56rem;
}

.notes-tab-label {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.34rem;
}

.notes-tab-label span:last-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notes-tab-icon {
  width: 0.98rem;
  height: 0.98rem;
  filter: none;
  flex: 0 0 auto;
}

.notes-tab-close {
  min-width: 1rem;
  min-height: 1rem;
  border: none;
  border-radius: 0.2rem;
  background: transparent;
  color: #d7deee;
  font-size: 0.66rem;
  line-height: 1;
  display: inline-grid;
  place-items: center;
  padding: 0;
}

.notes-tab-close:hover {
  background: rgba(255, 255, 255, 0.12);
}

.notes-tab-close:active {
  background: rgba(255, 255, 255, 0.07);
}

.notes-tabs .win-controls {
  flex: 0 0 auto;
}

.notes-tabs .win-btn {
  width: 2.18rem;
  height: 1.9rem;
  font-size: 0.78rem;
}

.notes-tabs .win-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.notes-tabs .win-btn:active {
  background: rgba(255, 255, 255, 0.07);
}

.notes-tabs .win-btn.win-close:hover {
  background: var(--win-red-0);
  color: #fff;
}

.notes-tabs .win-btn.win-close:active {
  background: rgba(255, 77, 91, 0.7);
  color: #fff;
}

.notes-topbar {
  min-height: 1.72rem;
  display: flex;
  align-items: center;
  gap: 0.16rem;
  padding: 0.2rem 0.2rem 0.2rem 0.16rem;
  border: none;
  border-bottom: 1px solid rgba(168, 189, 215, 0.24);
  background: #223041;
  color: #d7e8ff;
  position: relative;
  overflow: visible;
  z-index: 2;
}

.notes-menu {
  position: relative;
}

.notes-top-btn {
  height: 1.28rem;
  border: none;
  border-radius: 0.24rem;
  padding: 0 0.38rem;
  background: transparent;
  color: #e5f2ff;
  font-size: 0.64rem;
}

.notes-top-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.notes-top-btn:active {
  background: rgba(255, 255, 255, 0.07);
}

.notes-top-btn[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.18);
}

.notes-menu-panel {
  position: absolute;
  top: calc(100% + 0.14rem);
  left: 0;
  min-width: 10rem;
  border: 1px solid rgba(168, 189, 215, 0.28);
  border-radius: 0.34rem;
  background: #1a2330;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.36);
  padding: 0.3rem;
  display: grid;
  gap: 0.2rem;
  z-index: 6;
}

.notes-menu-panel[hidden] {
  display: none;
}

.notes-filter-menu {
  min-width: 13.2rem;
  gap: 0.34rem;
  padding: 0.42rem;
}

.notes-filter-head {
  display: grid;
  gap: 0;
  padding: 0;
  margin: 0;
}

.notes-filter-title {
  margin: 0;
  color: #e8f3ff;
  font-size: 0.66rem;
  letter-spacing: 0.01em;
}

.notes-filter-subtitle {
  margin: 0;
  color: #9eb4d2;
  font-size: 0.58rem;
  line-height: 1.3;
}

p.notes-filter-title,
p.notes-filter-subtitle {
  margin: 0;
}

.notes-menu-label {
  color: #b9cde9;
  font-size: 0.62rem;
  padding: 0 0.1rem;
}

.modal-body .notes-menu-input {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 100%;
  height: 1.46rem;
  border: 1px solid rgba(170, 191, 221, 0.35);
  border-radius: 0.24rem;
  background-color: #101824;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath fill='%23bfd6ff' d='M3.2 4.8a.8.8 0 0 1 1.13 0L7 7.47 9.67 4.8a.8.8 0 0 1 1.13 1.13l-3.23 3.24a.8.8 0 0 1-1.14 0L3.2 5.93a.8.8 0 0 1 0-1.13z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.42rem center;
  background-size: 0.72rem 0.72rem;
  color: #e5f2ff;
  font-size: 0.68rem;
  padding: 0 1.32rem 0 0.4rem;
}

.modal-body .notes-menu-input::-ms-expand {
  display: none;
}

.modal-body .notes-menu-input:focus {
  outline: none;
  border-color: rgba(114, 182, 255, 0.85);
  box-shadow: 0 0 0 1px rgba(114, 182, 255, 0.22);
}

.notes-menu-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.2rem;
}

.notes-menu-action {
  min-height: 1.34rem;
  border: none;
  border-radius: 0.24rem;
  background: transparent;
  color: #e5f2ff;
  font-size: 0.64rem;
  text-align: left;
  padding: 0 0.4rem;
}

.notes-filter-actions .notes-menu-action {
  justify-content: center;
  text-align: center;
}

.notes-menu-action.is-primary {
  background: rgba(72, 151, 255, 0.22);
  color: #eaf4ff;
}

.notes-menu-action.is-primary:hover {
  background: rgba(86, 162, 255, 0.38);
}

.notes-menu-action.is-primary:active {
  background: rgba(77, 156, 255, 0.3);
}

.notes-menu-action:hover {
  background: rgba(255, 255, 255, 0.12);
}

.notes-menu-action:active {
  background: rgba(255, 255, 255, 0.07);
}

.notes-menu-action.is-active {
  background: rgba(77, 156, 255, 0.22);
}

.notes-font-option.is-active {
  background: rgba(77, 156, 255, 0.22);
}

.notes-menu-check {
  min-height: 1.34rem;
  border-radius: 0.24rem;
  display: flex;
  align-items: center;
  gap: 0.36rem;
  padding: 0 0.4rem;
  color: #e5f2ff;
  font-size: 0.64rem;
}

.notes-menu-check:hover {
  background: rgba(255, 255, 255, 0.12);
}

.notes-menu-check input {
  margin: 0;
}

.notes-doc-chip {
  margin-left: auto;
  color: #a6bbd8;
  font-size: 0.62rem;
  padding-right: 0.12rem;
}

.notes-editor-wrap {
  min-height: 0;
  display: block;
  overflow: auto;
  position: relative;
  background: #0f141b;
}

.notes-editor {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 1px;
  border: none;
  border-radius: 0;
  background: transparent;
  color: transparent;
  font-size: 1px;
  padding: 0;
  margin: 0;
  opacity: 0;
  pointer-events: none;
  resize: none;
}

.notes-markdown {
  min-height: 100%;
  color: #e5f2ff;
  font: 0.78rem/1.62 "Segoe UI", "Yu Gothic UI", "Meiryo", sans-serif;
  padding: 0.82rem 0.94rem;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.notes-markdown.is-nowrap {
  white-space: normal;
  overflow-wrap: normal;
  word-break: normal;
}

.notes-markdown.is-nowrap h1,
.notes-markdown.is-nowrap h2,
.notes-markdown.is-nowrap h3,
.notes-markdown.is-nowrap p,
.notes-markdown.is-nowrap li,
.notes-markdown.is-nowrap .notes-log-meta,
.notes-markdown.is-nowrap .notes-log-colon,
.notes-markdown.is-nowrap .notes-log-text,
.notes-markdown.is-nowrap a,
.notes-markdown.is-nowrap strong,
.notes-markdown.is-nowrap code {
  white-space: nowrap;
}

.notes-markdown h1,
.notes-markdown h2,
.notes-markdown h3 {
  margin: 0 0 0.42rem;
  line-height: 1.3;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.notes-markdown h1 {
  font-size: 0.96rem;
}

.notes-markdown h2 {
  margin-top: 0.78rem;
  font-size: 0.84rem;
  color: #d7e8ff;
}

.notes-markdown h3 {
  margin-top: 0.66rem;
  font-size: 0.78rem;
  color: #c8dbf8;
}

.notes-markdown p {
  margin: 0 0 0.48rem;
}

.notes-markdown ul {
  margin: 0.14rem 0 0.54rem 1.08rem;
  padding: 0;
}

.notes-markdown .notes-log-list {
  margin: 0.14rem 0 0.54rem 0;
  padding: 0;
}

.notes-markdown li {
  margin: 0 0 0.28rem;
}

.notes-markdown .notes-log-item {
  margin: 0 0 0.18rem;
  display: grid;
  grid-template-columns: 132px 8px minmax(0, 1fr);
  column-gap: 2px;
  align-items: baseline;
  list-style: none;
  font-size: 14px;
  line-height: 1.6;
}

.notes-markdown .notes-log-meta {
  font-variant-numeric: tabular-nums;
  color: #dce8fb;
  min-width: 0;
  justify-self: end;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, "Courier New", monospace;
  white-space: nowrap;
}

.notes-markdown .notes-log-colon {
  color: #9eb8dc;
  justify-self: center;
  white-space: nowrap;
}

.notes-markdown .notes-log-text {
  min-width: 0;
  padding-left: 0;
}

.notes-markdown a {
  color: #8fc3ff;
  text-decoration: none;
  border-bottom: none;
}

.notes-markdown a:hover {
  color: #a8d2ff;
  text-decoration: none;
  border-bottom: none;
}

.notes-markdown strong {
  color: #f1f7ff;
}

.notes-markdown code {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 0.2rem;
  padding: 0.03rem 0.25rem;
}

.notes-editor:focus {
  outline: none;
}

.notes-status {
  min-height: 1.36rem;
  border: none;
  background: #14191f;
  color: #a6bbd8;
  font-size: 0.62rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 0.52rem 0 0.36rem;
}

@media (max-width: 620px) {
  .notes-topbar {
    gap: 0.1rem;
  }

  .notes-top-btn {
    padding: 0 0.3rem;
    font-size: 0.6rem;
  }

  .notes-menu-panel {
    min-width: 8.8rem;
  }

  .notes-filter-menu {
    min-width: 11.2rem;
  }
}



