.tools-desktop-shell {
  display: grid;
  gap: 24px;
  padding-top: 10px;
}

.tools-overview-panel {
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.58);
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.08);
  padding: 24px 28px;
}

.tools-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(320px, 1fr);
  gap: 24px;
  align-items: start;
}

.tools-calendar-pane,
.tools-memo-pane {
  min-width: 0;
  height: auto;
}

.tools-calendar-pane {
  display: grid;
  grid-template-rows: auto auto 1fr;
  min-height: 0;
}

.tools-memo-pane {
  display: grid;
  grid-template-rows: auto auto minmax(0, auto);
  min-height: 0;
  padding-left: 24px;
  border-left: 1px solid rgba(15, 23, 42, 0.08);
}

.tools-pane-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.tools-pane-title {
  font-size: 18px;
  font-weight: 700;
  color: #1d1d1f;
}

.tools-pane-meta {
  font-size: 13px;
  color: #6e6e73;
}

.tools-pane-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.tools-export-btn {
  height: 34px;
  padding: 0 14px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: #1d1d1f;
  font: inherit;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.tools-export-btn:hover {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(52, 199, 89, 0.16);
  transform: translateY(-1px);
}

.tools-export-btn:active {
  transform: translateY(0);
}

.tools-export-btn[disabled] {
  opacity: 0.6;
  cursor: default;
}

.tools-entry {
  width: 132px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 0;
  margin: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
}

.tools-app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, 132px);
  gap: 28px 36px;
  justify-content: start;
  align-items: start;
}

.tools-app {
  width: 132px;
  height: 132px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  appearance: none;
  box-sizing: border-box;
  cursor: pointer;
}

.tools-app-icon-wrap {
  width: 88px;
  height: 88px;
  border: 1.5px solid rgba(15, 23, 42, 0.12);
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 8px 8px;
  box-sizing: border-box;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
}

.tools-app-icon {
  width: 36px;
  height: 36px;
  font-size: 24px;
  line-height: 1;
  color: #2c2c2e;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.tools-app-icon-svg svg {
  width: 36px;
  height: 36px;
  display: block;
}

.tools-app-icon-image {
  width: 42px;
  height: 42px;
}

.tools-app-icon-image-full {
  width: 100%;
  height: 100%;
}

.tools-app-icon-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  border-radius: 12px;
}

.tools-app-icon-image-full img {
  border-radius: 22px;
}

.tools-app-icon-wrap-image-only {
  padding: 0;
  gap: 0;
  overflow: hidden;
}

.tools-app-title {
  font-size: 16px;
  line-height: 1.2;
  font-weight: 700;
  color: #2c2c2e;
  text-align: center;
  width: 100%;
}

.tools-app-fullname {
  width: 132px;
  font-size: 14px;
  line-height: 1.45;
  color: #5c5c62;
  text-align: center;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 60px;
}

.tools-modal-shell {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
}

.tools-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.24);
  backdrop-filter: blur(4px);
}

.tools-modal-center {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
}

.tools-modal-card {
  width: min(600px, 100%);
  max-height: min(80vh, 760px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 28px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.12);
}

.tools-modal-header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.96);
}

.tools-modal-title {
  font-size: 18px;
  font-weight: 700;
  color: #1d1d1f;
}

.tools-modal-close {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.84);
  cursor: pointer;
}

.tools-modal-body {
  padding: 20px;
  overflow: auto;
  flex: 1;
  min-height: 0;
}

.tools-calendar-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: nowrap;
}

.tools-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
}

.tools-calendar-week {
  margin-bottom: 12px;
}

.tools-calendar-week-label {
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: #8e8e93;
}

.tools-calendar-week-label.is-weekend {
  color: #9aaa84;
}

.tools-calendar-days {
  align-content: start;
}

.tools-calendar-day {
  min-height: 68px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  color: #1d1d1f;
  font: inherit;
  cursor: pointer;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.tools-calendar-day:hover:not(.is-empty) {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.08);
}

.tools-calendar-day.is-empty {
  background: transparent;
  border-color: transparent;
  cursor: default;
}

.tools-calendar-day.is-weekend {
  background: rgba(151, 201, 160, 0.06);
}

.tools-calendar-day.has-open-memo {
  border-color: rgba(255, 170, 51, 0.38);
  background: rgba(255, 193, 94, 0.14);
}

.tools-calendar-day.is-selected {
  border-color: rgba(52, 199, 89, 0.22);
  background: rgba(52, 199, 89, 0.14);
  color: #17351f;
  box-shadow: inset 0 0 0 1px rgba(52, 199, 89, 0.08);
}

.tools-calendar-day.is-selected.has-open-memo {
  border-color: rgba(255, 170, 51, 0.46);
  background: rgba(255, 193, 94, 0.20);
  color: #5b3b00;
}

.tools-calendar-day.is-today {
  border-color: rgba(52, 199, 89, 0.62) !important;
  box-shadow:
    0 0 0 2px rgba(52, 199, 89, 0.18),
    0 0 16px rgba(52, 199, 89, 0.18) !important;
}

.tools-calendar-day.is-selected.is-today {
  box-shadow:
    0 0 0 2px rgba(52, 199, 89, 0.22),
    0 0 16px rgba(52, 199, 89, 0.22) !important;
}

.tools-calendar-solar {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.1;
}

.tools-calendar-lunar {
  font-size: 12px;
  color: #8e8e93;
  line-height: 1.1;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tools-calendar-today-btn,
.tools-calendar-year-inline,
.tools-calendar-month-inline {
  height: 40px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  color: #2c2c2e;
  font: inherit;
  font-size: 16px;
  line-height: 1;
}

.tools-calendar-today-btn {
  padding: 0 18px;
  cursor: pointer;
}

.tools-calendar-year-inline,
.tools-calendar-month-inline {
  padding: 0 14px;
  min-width: 120px;
}

.tools-calendar-month-inline {
  min-width: 92px;
}

.tools-memo-textarea {
  width: 100%;
  min-height: 180px;
  height: 180px;
  resize: none;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.74);
  padding: 14px 16px;
  font: inherit;
  line-height: 1.6;
  color: #1d1d1f;
  outline: none;
  margin-bottom: 14px;
}

.tools-memo-textarea:focus {
  border-color: rgba(52, 199, 89, 0.28);
  box-shadow: 0 0 0 4px rgba(52, 199, 89, 0.10);
}

.tools-memo-history {
  min-height: 0;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 10px;
}

.tools-memo-history-title {
  font-size: 14px;
  font-weight: 700;
  color: #3a3a3c;
}

.tools-memo-history-empty {
  font-size: 13px;
  color: #8e8e93;
}

.tools-memo-history-list {
  min-height: 0;
  overflow: auto;
  padding-right: 4px;
  display: grid;
  gap: 8px;
  max-height: 300px;
}

.tools-memo-history-row {
  display: grid !important;
  grid-template-columns: 28px minmax(0, 1fr) 34px !important;
  gap: 10px !important;
  align-items: center !important;
}

.tools-memo-history-row.is-done {
  opacity: 0.68;
}

.tools-memo-history-check {
  display: flex;
  align-items: center;
  justify-content: center;
}

.tools-memo-history-check input {
  width: 16px;
  height: 16px;
  margin: 0;
  cursor: pointer;
}

.tools-memo-history-checkmark {
  display: none;
}

.tools-memo-history-item {
  width: 100% !important;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
  padding: 8px 12px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  text-align: left;
  cursor: pointer;
}

.tools-memo-history-date {
  font-size: 13px;
  font-weight: 700;
  color: #4b4b50;
  white-space: nowrap;
}

.tools-memo-history-text {
  font-size: 13px;
  color: #5b5b60;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.tools-memo-history-delete {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 14px;
  line-height: 1;
}

.tools-groups {
  display: grid;
  gap: 24px;
}

.tools-group {
  display: grid;
  gap: 14px;
}

.tools-group-header {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 22px;
}

.tools-group-title {
  font-size: 16px;
  font-weight: 700;
  color: #1d1d1f;
  flex: 0 0 auto;
}

.tools-group-hint {
  min-width: 0;
  max-width: 360px;
  font-size: 12px;
  line-height: 1.35;
  color: #9ca3af;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tools-group-hint[hidden] {
  display: none !important;
}

.tools-app:hover .tools-app-icon-wrap {
  transform: translateY(-2px);
  border-color: rgba(52, 199, 89, 0.14);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 26px rgba(15, 23, 42, 0.08);
}

@media (max-width: 980px) {
  .tools-calendar-toolbar {
    justify-content: flex-start;
    flex-wrap: wrap;
  }
}

@media (max-width: 640px) {
  .tools-desktop-shell {
    padding-top: 6px;
  }

  .tools-overview-panel {
    padding: 16px;
    border-radius: 24px;
  }

  .tools-calendar-grid {
    gap: 8px;
  }

  .tools-calendar-day {
    min-height: 56px;
    border-radius: 14px;
    padding: 6px 6px;
  }

  .tools-calendar-solar {
    font-size: 16px;
  }

  .tools-calendar-lunar {
    font-size: 11px;
  }

  .tools-memo-textarea {
    min-height: 150px;
    height: 150px;
  }

  .tools-app-grid {
    grid-template-columns: repeat(auto-fill, 112px);
    gap: 20px 20px;
  }

  .tools-app {
    width: 112px;
    height: 112px;
  }

  .tools-entry,
  .tools-app-fullname {
    width: 112px;
  }

  .tools-app-icon-wrap {
    width: 76px;
    height: 76px;
    border-radius: 20px;
  }

  .tools-app-title {
    font-size: 14px;
  }

  .tools-app-fullname {
    font-size: 13px;
    min-height: 56px;
  }
}
