.energy-ledger {
  position: relative;
  margin-top: 18px;
  padding: 18px;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 100% 0, rgba(157, 114, 238, 0.24), transparent 9rem),
    linear-gradient(145deg, #21123d, #2e1d50);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  box-shadow: 0 16px 30px rgba(64, 26, 80, 0.16);
}

.energy-ledger__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.energy-ledger__eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 5px;
  color: #e7a682;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.1em;
  line-height: 1.3;
  text-transform: uppercase;
}

.energy-ledger__eyebrow > span {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #f52f72;
  box-shadow: 0 0 0 4px rgba(245, 47, 114, 0.16);
}

.energy-ledger__heading h3 {
  margin: 0;
  color: #fff;
  font-size: 17px;
  font-weight: 850;
  letter-spacing: -0.045em;
  line-height: 1.05;
}

.energy-ledger__badge {
  flex: 0 0 auto;
  padding: 5px 7px;
  color: #c2b7cb;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 999px;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.energy-ledger__result {
  display: grid;
  min-width: 0;
  align-items: end;
  column-gap: 10px;
  padding: 13px 14px 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  grid-template-columns: minmax(0, 1fr) auto;
}

.energy-ledger__result-label {
  min-width: 0;
  overflow: hidden;
  color: #d4cadb;
  font-size: 11px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.energy-ledger__result-label small {
  color: #91869e;
  font-size: 9px;
  font-weight: 650;
}

.energy-ledger__result strong {
  grid-column: 2;
  grid-row: 1 / span 2;
  color: #fff;
  font-size: 30px;
  font-weight: 850;
  letter-spacing: -0.07em;
  line-height: 0.95;
  white-space: nowrap;
}

.energy-ledger__result strong small {
  color: #c2b7cb;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
}

.energy-ledger__result-note {
  min-width: 0;
  margin-top: 4px;
  color: #b7aac1;
  font-size: 10px;
  line-height: 1.35;
}

.energy-ledger__result--deficit strong {
  color: #ff9d65;
}

.energy-ledger__result--surplus strong {
  color: #ff84ac;
}

.energy-ledger__result--even strong {
  color: #bca4f4;
}

.energy-ledger__result--unknown strong {
  color: #c2b7cb;
}

.energy-ledger__formula {
  margin: 13px 2px 8px;
  color: #b7a6c6;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.075em;
  line-height: 1.35;
  text-transform: uppercase;
}

.energy-ledger__formula span {
  padding: 0 3px;
  color: #ff9d65;
  font-size: 12px;
  font-weight: 850;
}

.energy-ledger__rows {
  display: grid;
  gap: 5px;
  margin: 0;
}

.energy-ledger__row {
  display: grid;
  min-width: 0;
  min-height: 40px;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 11px;
  grid-template-columns: minmax(0, 1fr) auto;
}

.energy-ledger__row dt {
  display: flex;
  min-width: 0;
  align-items: flex-start;
  gap: 8px;
  color: #e8deef;
  font-size: 11px;
  line-height: 1.2;
}

.energy-ledger__row dt i {
  display: grid;
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  place-items: center;
  color: #ff9d65;
  background: rgba(255, 104, 47, 0.16);
  border-radius: 50%;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
  line-height: 1;
}

.energy-ledger__row:not(.energy-ledger__row--in) dt i {
  color: #d9c5ff;
  background: rgba(157, 114, 238, 0.2);
}

.energy-ledger__row:last-child dt i {
  color: #ff84ac;
  background: rgba(245, 47, 114, 0.18);
}

.energy-ledger__row dt span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.energy-ledger__row dt small {
  display: block;
  margin-top: 2px;
  overflow: hidden;
  color: #b2a4bc;
  font-size: 9px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.energy-ledger__row dd {
  display: flex;
  align-items: baseline;
  gap: 4px;
  min-width: 0;
  margin: 0;
  color: #fff;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  white-space: nowrap;
}

.energy-ledger__row dd small {
  color: #c0b3c9;
  font-size: 9px;
  font-weight: 700;
}

.energy-ledger__value--muted {
  color: #a99bb5 !important;
  font-size: 10px !important;
  font-weight: 700 !important;
}

.energy-ledger__hint {
  margin: 11px 2px 0;
  padding-top: 10px;
  color: #c2b7cb;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 10px;
  line-height: 1.45;
}

.workspace-discuss--icon {
  width: auto;
  min-width: 68px;
  padding: 0 10px;
  font-size: 10px;
}

.diary-subtabs {
  display: grid;
  gap: 5px;
  margin: -4px 0 15px;
  padding: 4px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  background: #f0e9ef;
  border-radius: 11px;
}

.diary-subtab {
  min-height: 40px;
  color: #8d7c92;
  background: transparent;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 750;
}

.diary-subtab.is-active {
  color: #67327f;
  background: #fff;
  box-shadow: 0 4px 12px rgba(61, 29, 83, 0.08);
}

.diary-subpanel[hidden] {
  display: none;
}

.workout-list {
  display: grid;
  gap: 9px;
}

.workout-card {
  overflow: hidden;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--line);
  border-radius: 15px;
}

.workout-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 12px;
}

.workout-card__header time,
.workout-card__header span {
  display: block;
  color: var(--ink-soft);
  font-size: 9px;
}

.workout-card__header h3 {
  margin: 3px 0 2px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.2;
}

.workout-card__header > strong {
  flex: 0 0 auto;
  color: #9a3c5e;
  font-size: 10px;
  white-space: nowrap;
}

.workout-card__details {
  border-top: 1px solid rgba(64, 34, 94, 0.08);
}

.workout-card__details summary {
  padding: 9px 12px;
  color: #733b8e;
  cursor: pointer;
  font-size: 10px;
  font-weight: 720;
  list-style-position: inside;
}

.workout-exercises {
  display: grid;
  gap: 9px;
  padding: 0 12px 11px;
}

.workout-exercise {
  padding-top: 9px;
  border-top: 1px solid rgba(64, 34, 94, 0.07);
}

.workout-exercise > strong,
.workout-exercise > span {
  display: block;
}

.workout-exercise > strong {
  color: #51345e;
  font-size: 10px;
}

.workout-exercise > span {
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 9px;
}

.workout-sets {
  display: grid;
  gap: 3px 7px;
  margin-top: 5px;
  grid-template-columns: 18px minmax(0, 1fr);
  color: var(--ink-soft);
  font-size: 9px;
}

.workout-sets span {
  color: #a28eaa;
  font-variant-numeric: tabular-nums;
}

.workout-sets b {
  color: #65516e;
  font-weight: 650;
}

.workout-card__discuss {
  min-height: 35px;
  margin: 0 12px 12px;
  font-size: 10px;
}

.workouts-load-more {
  margin-top: 11px;
}

.memory-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.memory-row__body {
  min-width: 0;
}

.memory-row__delete {
  flex: 0 0 auto;
  min-height: 40px;
  padding: 7px 10px;
  color: #a34463;
  background: #fff5f7;
  border: 1px solid rgba(245, 47, 114, 0.13);
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 720;
}

.memory-row__delete:hover,
.memory-row__delete:focus-visible {
  color: #812642;
  border-color: rgba(245, 47, 114, 0.3);
}

@media (max-width: 390px) {
  .energy-ledger {
    padding: 15px;
  }

  .energy-ledger__result strong {
    font-size: 27px;
  }
}
.profile-connections {
  display: grid;
  gap: 0.75rem;
}

.profile-connection {
  gap: 0.75rem;
}

.profile-connection--max .profile-telegram__icon {
  width: 2.75rem;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.profile-connection--vk .profile-telegram__icon {
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(39, 119, 255, 0.2);
}

.profile-connection--vk .profile-telegram__icon img {
  display: block;
  width: 1.6rem;
  height: 1.6rem;
}

.profile-connection__action,
.profile-connection-link a,
.profile-connection-link button {
  border: 0;
  border-radius: 999px;
  background: #ff5a35;
  color: #fff;
  padding: 0.55rem 0.8rem;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}

.profile-connection__action--quiet {
  background: transparent;
  color: #755e55;
  box-shadow: inset 0 0 0 1px rgba(117, 94, 85, 0.24);
}

.profile-connection__notifications {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.78rem;
}

.profile-connection-link {
  display: grid;
  gap: 0.55rem;
  padding: 0.85rem;
  border: 1px solid rgba(255, 90, 53, 0.25);
  border-radius: 1rem;
  background: rgba(255, 90, 53, 0.06);
}

.profile-connection-link[hidden] {
  display: none;
}

.profile-connection-link a,
.profile-connection-link button {
  justify-self: start;
  text-decoration: none;
}

.profile-connection-link code {
  overflow-wrap: anywhere;
  border-radius: 0.5rem;
  background: #fff;
  padding: 0.55rem;
}
