/* =================================
   MEMBERS PAGE
================================= */

.members-page {
  display: grid;
  grid-template-columns: 250px 430px minmax(0, 1fr);
  height: 100%;
  min-height: 0;
  min-width: 0;
}

.members-page__list {
  border-right: 1px solid #ececec;
  padding: 20px;
  overflow-y: auto;
  min-width: 0;
}

.members-page__profile {
  border-right: 1px solid #ececec;
  padding: 24px;
  overflow-y: auto;
  min-width: 0;
}

.members-page__history {
  padding: 24px;
  overflow-y: auto;
  overflow-x: hidden;
  min-width: 0;
  background: #fafafa;
}

.members-page__header {
  margin-bottom: 16px;
}

.members-page__header input {
  width: 100%;
  height: 40px;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 0 12px;
  font-size: 14px;
  box-sizing: border-box;
}

#memberProfile,
#memberHistoryPanel {
  min-height: 100%;
  box-sizing: border-box;
}

/* =================================
   MEMBERS LIST
================================= */

.member-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 12px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: background 0.15s ease;
}

.member-row:hover {
  background: #f6f8ff;
}

.member-row--active {
  background: #eef2ff;
}

.member-row__info {
  min-width: 0;
  flex: 1;
}

.member-row__name {
  font-weight: 600;
  font-size: 14px;
}

.member-row__meta {
  font-size: 13px;
  color: #777;
  margin-top: 4px;
}

.member-row__reserve {
  flex-shrink: 0;
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 6px;
  border: 1px solid #dcdcdc;
  background: #f8f8f8;
  cursor: pointer;
  transition:
    background 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

.member-row__reserve:hover {
  background: #f1f3f7;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

/* =================================
   PROFILE SUMMARY CARDS
================================= */

.member-summary-card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  min-width: 0;
  box-sizing: border-box;
}

.member-summary-card__label {
  font-size: 11px;
  color: #888;
  margin-bottom: 6px;
}

.member-summary-card__value {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.member-top-grid {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 12px;
  margin-bottom: 18px;
  align-items: start;
}

.member-summary-card--coords {
  grid-column: 1 / span 2;
  padding: 18px 20px;
}

.member-summary-card--credits {
  grid-column: 1;
  padding: 12px 10px;
  min-height: 105px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.member-summary-card--credits .member-summary-card__label {
  margin-bottom: 8px;
}

.member-summary-card--credits .member-summary-card__value {
  font-size: 22px;
  font-weight: 700;
  line-height: 1;
  margin: 0;
}

.member-summary-card--validity {
  grid-column: 2;
  min-height: 105px;
  margin-bottom: 0;
}

.member-summary-card--validity .member-validity__current {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 0px;
}

.member-summary-card--validity .member-validity__edit {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.member-summary-card--validity .member-validity__edit-label {
  font-size: 13px;
  color: #777;
}

.member-summary-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.member-coords {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 24px;
}

.member-coord-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.member-coord-row--full {
  grid-column: 1 / -1;
}

.member-coord-label {
  font-size: 12px;
  font-weight: 500;
  color: #8a8a8a;
  line-height: 1.2;
}

.member-coord-value {
  font-size: 15px;
  font-weight: 600;
  color: #1f1f1f;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.member-edit-btn {
  background: none;
  border: none;
  padding: 0;
  font-size: 13px;
  font-weight: 500;
  color: #7a7a7a;
  cursor: pointer;
}

.member-edit-btn:hover {
  color: #111;
}

.member-coord-value {
  font-size: 14px;
  font-weight: 600;
  color: #1f1f1f;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.member-coord-row:nth-child(3) .member-coord-value {
  max-width: 280px;
}

/* =================================
   VALIDITY
================================= */

.member-summary-card--validity {
  margin-bottom: 0px;
}

.member-validity__current {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.member-validity__edit {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.member-validity__edit-label {
  font-size: 13px;
  color: #777;
}

.member-validity__edit input {
  max-width: 130px;
}

.expiry-warning {
  color: #f59e0b;
}

.expiry-expired {
  color: #dc2626;
}

.credits-warning {
  color: #f59e0b;
}

.credits-empty {
  color: #dc2626;
}

/* =================================
   QUICK CREDIT BUTTONS
================================= */

.member-actions__buttons {
  display: flex;
  gap: 10px;
  flex-wrap: nowrap;
  margin-top: 8px;
}

.member-credit-btn {
  flex: 1;
  min-width: 0;
  height: 42px;
  padding: 0 14px;
  border: 1px solid #dcdcdc;
  border-radius: 12px;
  background: #f3f3f3;
  color: #2f2f2f;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.member-credit-btn:hover {
  background: #ebebeb;
  border-color: #cfcfcf;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

.member-credit-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.member-credit-btn::before {
  content: none;
}

.btn-icon {
  font-size: 16px;
  line-height: 1;
  opacity: 0.95;
}

/* =================================
   MANUAL ADJUSTMENT CARD
================================= */

.member-manual-credits {
  margin-top: 24px;
}

.member-manual-credits--card {
  max-width: 440px;
  padding: 20px;
  border: 1px solid #e7e3dd;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: none;
}

.member-manual-credits--card h3 {
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 700;
  color: #1f1f1f;
}

.member-manual-credits__label {
  margin-bottom: 10px;
  font-size: 13px;
  font-weight: 500;
  color: #5f5a54;
}

.member-manual-credits__row {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.credits-stepper {
  display: flex;
  align-items: center;
  gap: 10px;
}

.credits-stepper button {
  width: 42px;
  height: 42px;
  border: 1px solid #dddddd;
  border-radius: 12px;
  background: #f8f8f8;
  color: #2b2b2b;
  font-size: 22px;
  font-weight: 600;
}

.credits-stepper button:hover {
  background: #e2ddd6;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
}

#creditsAdjustQty {
  width: 86px;
  height: 42px;
  border: 1px solid #ddd7cf;
  border-radius: 12px;
  background: #fff;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  color: #1f1f1f;
}

#manualCreditsPrice,
#manualCreditsReason,
#manualCreditsNote {
  height: 42px;
  border: 1px solid #ddd7cf;
  border-radius: 12px;
  background: #fff;
  padding: 0 14px;
  font-size: 14px;
  box-sizing: border-box;
}

#manualCreditsPrice {
  width: 160px;
}

#manualCreditsReason {
  width: 170px;
}

#manualCreditsReason {
  height: 42px;
  border: 1px solid #d9d9d9;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 14px;
  background: #f5f5f5;
  cursor: pointer;
}

#manualCreditsReason:hover {
  background: #ededed;
}

#manualCreditsNote {
  flex: 1;
  min-width: 0;
}

#manualCreditsPrice:focus,
#manualCreditsReason:focus,
#manualCreditsNote:focus,
#creditsAdjustQty:focus {
  outline: none;
  border-color: #c8bfb4;
  box-shadow: 0 0 0 3px rgba(143, 133, 123, 0.1);
}

#manualCreditsReason {
  height: 42px;
  width: 180px;
  border: 1px solid #d9d9d9;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 14px;
  background: #f5f5f5;
  color: #333;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

#manualCreditsReason:hover {
  background: #ededed;
}

#manualCreditsReason {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24'%3E%3Cpath fill='%23666' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

#saveManualCreditsBtn {
  height: 40px;
  min-width: 104px;
  padding: 0 16px;
  border: 1px solid #d9d9d9;
  border-radius: 10px;
  background: #f3f3f3;
  color: #333;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

#saveManualCreditsBtn:hover {
  background: #ebebeb;
  border-color: #cfcfcf;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

#saveManualCreditsBtn:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

#manualCreditsNote {
  flex: 1;
  min-width: 0;
}

.member-manual-credits__row:last-child {
  align-items: stretch;
}

/* =================================
   CRM SUMMARY
================================= */

.member-crm-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}

.member-crm-item {
  min-width: 0;
}

.member-crm-item {
  background: #fff;
  border: 1px solid #eaeaea;
  border-radius: 10px;
  padding: 14px 16px;
}

.member-crm-item__label {
  font-size: 12px;
  color: #777;
  margin-bottom: 4px;
}

.member-crm-item__value {
  font-size: 18px;
  font-weight: 600;
}

.member-crm-item__sub {
  margin-top: 4px;
  font-size: 12px;
  color: #777;
}

.member-crm-title {
  font-size: 13px;
  color: #777;
  margin-bottom: 10px;
}

/* =================================
   MOVEMENTS HISTORY
================================= */

.member-movement-row {
  display: grid;
  grid-template-columns: 110px 120px minmax(0, 1fr) 90px 36px;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
  font-size: 14px;
  align-items: center;
}

.movement-plus {
  color: #16a34a;
  font-weight: 600;
}

.movement-minus {
  color: #dc2626;
  font-weight: 600;
}

.movement-note-cell {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.movement-note-btn {
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 16px;
  opacity: 0.75;
  padding: 0;
  line-height: 1;
}

.movement-note-btn:hover,
.movement-note-btn:focus {
  opacity: 1;
}

.movement-note-btn.no-note {
  opacity: 0.35;
}

.movement-note-btn.has-note {
  opacity: 1;
}

.movement-note-pop {
  position: absolute;
  right: 0;
  top: 28px;
  min-width: 180px;
  max-width: 260px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #111827;
  color: #fff;
  font-size: 13px;
  line-height: 1.35;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px);
  transition: 0.15s ease;
  z-index: 20;
}

.movement-note-cell:hover .movement-note-pop,
.movement-note-btn:focus + .movement-note-pop {
  opacity: 1;
  transform: translateY(0);
}

.member-movement-row div:last-child {
  text-align: center;
}

.movement-year-group {
  margin-bottom: 18px;
}

.movement-year-title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  padding-bottom: 6px;
  border-bottom: 1px solid #ddd;
  cursor: pointer;
  user-select: none;
}

.movement-year-arrow {
  display: inline-block;
  width: 14px;
}

.movement-year-count {
  color: #777;
  font-weight: 500;
  font-size: 13px;
}

.movement-year-list {
  display: flex;
  flex-direction: column;
}

.movement-month-group {
  margin: 8px 0 14px;
}

.movement-month-title {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  color: #444;
  text-transform: capitalize;
  cursor: pointer;
  user-select: none;
}

.movement-month-arrow {
  display: inline-block;
  width: 14px;
}

.movement-month-list {
  display: flex;
  flex-direction: column;
}

.is-collapsed {
  display: none !important;
}

/* =================================
   MANUAL ADJUSTMENT CARD
================================= */

.member-manual-credits {
  margin-top: 24px;
}

.member-manual-credits--card {
  max-width: 440px;
  padding: 20px;
  border: 1px solid #e7e3dd;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: none;
}

.member-manual-credits--card h3 {
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 700;
  color: #1f1f1f;
}

.member-manual-credits__label {
  margin-bottom: 10px;
  font-size: 13px;
  font-weight: 500;
  color: #5f5a54;
}

.member-manual-credits__row {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.credits-stepper {
  display: flex;
  align-items: center;
  gap: 10px;
}

.credits-stepper button {
  width: 42px;
  height: 42px;
  border: 1px solid #dddddd;
  border-radius: 12px;
  background: #f8f8f8;
  color: #2b2b2b;
  font-size: 22px;
  font-weight: 600;
}

.credits-stepper button:hover {
  background: #e2ddd6;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
}

#creditsAdjustQty {
  width: 86px;
  height: 42px;
  border: 1px solid #ddd7cf;
  border-radius: 12px;
  background: #fff;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  color: #1f1f1f;
}

#manualCreditsPrice,
#manualCreditsReason,
#manualCreditsNote {
  height: 42px;
  border: 1px solid #ddd7cf;
  border-radius: 12px;
  background: #fff;
  padding: 0 14px;
  font-size: 14px;
  box-sizing: border-box;
}

#manualCreditsPrice {
  width: 160px;
}

#manualCreditsReason {
  width: 170px;
}

#manualCreditsReason {
  height: 42px;
  border: 1px solid #d9d9d9;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 14px;
  background: #f5f5f5;
  cursor: pointer;
}

#manualCreditsReason:hover {
  background: #ededed;
}

#manualCreditsNote {
  flex: 1;
  min-width: 0;
}

#manualCreditsPrice:focus,
#manualCreditsReason:focus,
#manualCreditsNote:focus,
#creditsAdjustQty:focus {
  outline: none;
  border-color: #c8bfb4;
  box-shadow: 0 0 0 3px rgba(143, 133, 123, 0.1);
}

#manualCreditsReason {
  height: 42px;
  width: 180px;
  border: 1px solid #d9d9d9;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 14px;
  background: #f5f5f5;
  color: #333;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

#manualCreditsReason:hover {
  background: #ededed;
}

#manualCreditsReason {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24'%3E%3Cpath fill='%23666' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

#saveManualCreditsBtn {
  height: 40px;
  min-width: 104px;
  padding: 0 16px;
  border: 1px solid #d9d9d9;
  border-radius: 10px;
  background: #f3f3f3;
  color: #333;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

#saveManualCreditsBtn:hover {
  background: #ebebeb;
  border-color: #cfcfcf;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

#saveManualCreditsBtn:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

#manualCreditsNote {
  flex: 1;
  min-width: 0;
}

.member-manual-credits__row:last-child {
  align-items: stretch;
}

/* =================================
   SESSIONS HISTORY
================================= */

.member-session-row {
  display: grid;
  grid-template-columns: 110px 60px minmax(0, 1fr) 90px;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  font-size: 14px;
  align-items: center;
}

.session-year-group {
  margin-top: 10px;
}

.session-year-title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  padding-bottom: 6px;
  border-bottom: 1px solid #ddd;
  cursor: pointer;
  user-select: none;
}

.session-year-arrow {
  display: inline-block;
  width: 14px;
}

.session-year-list {
  display: flex;
  flex-direction: column;
}

.session-month-group {
  margin: 8px 0 14px;
}

.session-month-title {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  color: #444;
  text-transform: capitalize;
  cursor: pointer;
  user-select: none;
}

.session-month-arrow {
  display: inline-block;
  width: 14px;
}

.session-month-list {
  display: flex;
  flex-direction: column;
}

.session-status-reserved {
  color: #2b6cff;
  font-weight: 500;
}

.session-status-done {
  color: #777;
}

.session-status-waitlist {
  color: #f59e0b;
  font-weight: 600;
}

.member-crm-item,
.alert-section {
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.member-crm-item:hover,
.alert-section:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.alerts-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.alert-section {
  background: #fff;
  border: 1px solid #f2f2f2;
  border-radius: 12px;
  padding: 12px 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.alert-section.highlight {
  background: #fffaf2;
  border: 1px solid #fed7aa;
}

.alert-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 8px;
  color: #111827;
}

.alert-list div {
  font-size: 14px;
  line-height: 1.45;
  padding: 4px 0;
}

.alert-list div:not(:last-child) {
  border-bottom: 1px solid #f8f8f8;
  margin-bottom: 6px;
  padding-bottom: 6px;
}

.member-crm-item,
.alert-section {
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.member-crm-item:hover,
.alert-section:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.btn-extend-validity {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: auto;
  align-self: flex-start;

  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);

  background: #111827;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  line-height: 1;

  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-extend-validity:hover {
  background: #1f2937;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.14);
}

.btn-extend-validity:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn-icon {
  font-size: 16px;
  line-height: 1;
  opacity: 0.95;
}

.alert-member-link,
.alert-action-link {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  font-weight: 600;
  color: inherit;
  cursor: pointer;
  text-align: left;
}

.alert-member-link:hover,
.alert-action-link:hover {
  text-decoration: underline;
}

.alert-section--focus {
  box-shadow:
    0 0 0 2px rgba(245, 158, 11, 0.35),
    0 8px 20px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.participants-section {
  margin-top: 4px;
}

.participants-title {
  font-size: 14px;
  font-weight: 700;
  color: #111827;
  margin-bottom: 8px;
}

.participants-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.participant-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.04);
}

.participant-name {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.participant-phone {
  font-size: 13px;
  color: #6b7280;
  white-space: nowrap;
}

.participant-empty {
  font-size: 13px;
  color: #6b7280;
}

#participantsModal .modal__box {
  background: linear-gradient(180deg, #111827 0%, #0f172a 100%);
  color: #f9fafb;
}

#participantsModal .modal__header h3 {
  color: #ffffff;
}

#participantsModal .participants-title {
  color: #f9fafb;
}

#participantsModal .participant-row {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

#participantsModal .participant-name {
  color: #ffffff;
}

#participantsModal .participant-phone {
  color: #cbd5e1;
}

#participantsModal .participant-empty {
  color: #cbd5e1;
}

#historyFull {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.history-empty {
  font-size: 14px;
  color: #6b7280;
}

.history-year-group {
  margin-bottom: 18px;
}

.history-year-title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  padding-bottom: 6px;
  border-bottom: 1px solid #ddd;
  cursor: pointer;
  user-select: none;
  color: #111827;
}

.history-year-arrow,
.history-month-arrow {
  display: inline-block;
  width: 14px;
}

.history-year-count {
  color: #777;
  font-weight: 500;
  font-size: 13px;
}

.history-year-list {
  display: flex;
  flex-direction: column;
}

.history-month-group {
  margin: 8px 0 14px;
}

.history-month-title {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  color: #444;
  text-transform: capitalize;
  cursor: pointer;
  user-select: none;
}

.history-month-list {
  display: flex;
  flex-direction: column;
}

.history-session-row {
  display: grid;
  grid-template-columns: 110px 60px minmax(0, 1fr);
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  font-size: 14px;
  align-items: center;
}

.history-session-date,
.history-session-hour {
  color: #6b7280;
}

.history-session-title {
  color: #111827;
  font-weight: 600;
}

.is-collapsed {
  display: none !important;
}

.member-reminder-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #555;
}

.member-reminder-text {
  font-weight: 500;
}

.member-reminder-date {
  opacity: 0.7;
}

.member-reminder-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #555;
}

.member-reminder-label {
  font-weight: 600;
  color: #222;
  margin-right: 4px;
}

.reminder-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.reminder-dot.is-on {
  background: #2ecc71;
}

.reminder-dot.is-off {
  background: #e74c3c;
}

.member-reminder-date {
  opacity: 0.7;
}

.member-top-grid {
  align-items: start;
}

.member-reminder-sent {
  font-size: 12px;
  color: #888;
}

.member-reminder-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 13px;
}

.member-reminder-label {
  font-weight: 500;
  color: #555;
}

.member-reminder-text {
  font-weight: 500;
}

.member-reminder-sent {
  color: #888;
  font-size: 12px;
}

.movement-paid-status {
  margin-top: 4px;
  font-size: 12px;
  opacity: 0.7;
}

.movement-amount-cell {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  white-space: nowrap;
}

.movement-paid-badge {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  font-size: 11px;
  padding: 3px 7px;
  border-radius: 999px;
  font-weight: 600;
  background: #dcfce7;
  color: #166534;
}

.movement-paid-badge:has(:contains("Payé")) {
  background: #dcfce7;
  color: #166534;
}

.movement-paid-badge:has(:contains("Non")) {
  background: #fee2e2;
  color: #991b1b;
}

.movement-unpaid-badge {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  font-size: 11px;
  padding: 3px 7px;
  border-radius: 999px;
  font-weight: 600;
  background: #fee2e2;
  color: #991b1b;
}

.movement-paid-badge,
.movement-unpaid-badge {
  border: 0;
  cursor: pointer;
}

@media (max-width: 768px) {
  .member-movement-row {
    grid-template-columns: 92px 1fr auto;
    grid-template-areas:
      "date credits note"
      "reason amount amount";
    row-gap: 4px;
    column-gap: 10px;
    align-items: center;
  }

  .movement-amount-cell {
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: flex-start;
  }

  .member-movement-row > div:nth-child(1) {
    grid-area: date;
  }

  .member-movement-row > div:nth-child(2) {
    grid-area: credits;
  }

  .member-movement-row > div:nth-child(3) {
    grid-area: reason;
  }

  .member-movement-row > div:nth-child(4) {
    grid-area: amount;
  }

  .member-movement-row > div:nth-child(5) {
    grid-area: note;
  }

  .movement-amount-cell {
    justify-content: flex-start;
    gap: 8px;
    white-space: nowrap;
  }

  .movement-note-cell {
    justify-content: flex-end;
  }
}

.movement-edit-btn {
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 14px;
  padding: 0;
}

.member-movement-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.movement-amount-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.movement-note-cell {
  display: flex;
  align-items: center;
  gap: 6px;
}

.member-top-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-items: stretch;
}

.member-summary-card--coords {
  grid-column: 1 / -1;
}

.member-summary-card--credits,
.member-summary-card--validity {
  min-height: 155px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px 16px;
}

.member-summary-card__label--center {
  text-align: center;
  font-size: 14px;
  line-height: 1.2;
  color: #6b7280;
  margin-bottom: 10px;
}

.member-summary-card__value--center,
.member-validity__current--center {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-weight: 700;
  line-height: 1.1;
}

.member-summary-card__value--center {
  font-size: 38px;
}

.member-validity__current--center {
  font-size: 28px;
}

.member-summary-card__actions--center {
  display: flex;
  justify-content: center;
  margin-top: 12px;
}

.member-expired-btn,
.member-edit-btn--card {
  min-width: 140px;
  min-height: 38px;
  border-radius: 10px;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 600;
}

.member-expired-btn {
  border: 1px solid rgba(185, 28, 28, 0.18);
  background: rgba(185, 28, 28, 0.08);
  color: #b91c1c;
}

.member-expired-btn:hover {
  background: rgba(185, 28, 28, 0.12);
  border-color: rgba(185, 28, 28, 0.28);
}

.member-edit-btn--card {
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: rgba(15, 23, 42, 0.04);
  color: #334155;
}

.member-edit-btn--card:hover {
  background: rgba(15, 23, 42, 0.08);
}

.member-summary-card__actions--center {
  display: flex;
  justify-content: center;
  margin-top: 8px;
}

.members-count {
  font-size: 13px;
  opacity: 0.6;
  margin-bottom: 6px;
}

@media (min-width: 901px) and (max-width: 1200px) {
  .members-page {
    grid-template-columns: 1fr !important;
  }

  .members-page__list,
  .members-page__profile,
  .members-page__history {
    min-width: 0 !important;
    width: 100% !important;
  }
}
@media (min-width: 901px) and (max-width: 1250px) {
  body.page-members .app-main,
  body.page-members .members-page {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  body.page-members * {
    box-sizing: border-box;
  }
}
.alert-member-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid #ececec;
}

.alert-member-row:last-child {
  border-bottom: none;
}

.alert-member-link {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.25;
  color: #111827;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.15s ease;
  text-align: left;
}

.alert-member-link:hover {
  opacity: 0.7;
}

.alert-credit-badge,
.alert-expiry-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.alert-credit-badge {
  background: #fff3eb;
  color: #f28c00;
}

.alert-expiry-badge {
  background: #f5f5f5;
  color: #374151;
}

.alert-expiry-badge.is-warning {
  background: #fff3eb;
  color: #f28c00;
}

.alert-expiry-badge.is-danger {
  background: #fff0f0;
  color: #dc2626;
}
