.member-report-body {
  background: #f3f6f5;
}

.order-address-detail:empty {
  display: none;
}

.member-order-page {
  max-width: 1160px;
  margin-top: 28px;
}

.member-report-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  padding: 25px 28px;
  margin-bottom: 16px;
  border: 1px solid #dfe8e4;
  border-radius: 14px;
  background: #fff;
}

.member-report-hero-copy {
  min-width: 0;
}

.member-report-hero h1 {
  margin: 5px 0 6px;
  color: #1d332d;
  font-size: 29px;
}

.member-report-hero p {
  margin: 0;
  color: #7a8984;
  font-size: 13px;
}

.member-report-steps {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.member-report-steps li {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid #e3ebe8;
  border-radius: 8px;
  background: #f8fbfa;
  color: #6f807a;
  font-size: 11px;
  white-space: nowrap;
}

.member-report-steps b {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #e7f3ee;
  color: #147a62;
  font-size: 10px;
}

.member-order-page > .announcement {
  margin-bottom: 16px;
  border-radius: 10px;
  background: #fffdf5;
  border-color: #eadfbd;
  border-left-color: #b78a2c;
}

.member-order-page > .announcement strong {
  color: #8a671e;
}

.member-order-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 286px;
  grid-template-areas:
    "shipping guide"
    "plans guide";
  gap: 16px;
  align-items: start;
}

.member-order-form > .card {
  margin-bottom: 0;
  border-color: #dfe8e4;
  border-radius: 13px;
  padding: 22px;
  box-shadow: none;
}

.member-shipping-card {
  grid-area: shipping;
}

.member-plans-card {
  grid-area: plans;
}

.member-order-form .section-title {
  position: relative;
  flex-wrap: wrap;
  gap: 8px 11px;
  margin-bottom: 17px;
  padding-bottom: 13px;
  border-bottom: 1px solid #edf1ef;
}

.member-order-form .section-title h2 {
  margin: 0;
  color: #213730;
  font-size: 18px;
}

.member-section-sub {
  width: 100%;
  padding-left: 40px;
  color: #85938f;
  font-size: 11px;
}

.member-order-form input,
.member-order-form select,
.member-order-form textarea {
  border-color: #dbe4e0;
}

.member-order-form input:focus,
.member-order-form select:focus,
.member-order-form textarea:focus {
  border-color: #5b9d89;
  outline: 3px solid #147a6215;
}

.member-plan-head {
  padding: 8px 12px;
  margin-bottom: 9px !important;
  border-radius: 7px;
  background: #f5f8f7;
  color: #87948f;
  font-size: 10px;
}

.member-plan-row {
  grid-template-columns: minmax(0, 1fr) 132px 90px;
  gap: 12px;
  padding: 13px 12px;
  margin-bottom: 8px;
  border: 1px solid #e5ece9;
  border-radius: 9px;
  background: #fff;
  transition: border-color .15s ease, background .15s ease;
}

.member-plan-row:hover {
  border-color: #c9dcd5;
  background: #fbfdfc;
}

.member-plan-row .plan-name-button {
  color: #213730;
}

.member-plan-row .qty-control button {
  border-color: #d7e3de;
  background: #f8fbfa;
}

.member-plan-row .qty-control input {
  border-color: #cfded8;
  background: #fff;
  font-weight: 700;
}

.member-plan-row .line-total {
  color: #147a62;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.member-order-form .plan-search-box {
  padding: 8px;
  border: 1px solid #e1e9e6;
  border-radius: 9px;
  background: #f8fbfa;
}

.member-order-form .plan-search-box input {
  border: 0;
  background: transparent;
}

.member-order-form .plan-search-box button {
  border-color: #dbe5e1;
  background: #fff;
}

.plan-date-layout {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.plan-date-rail {
  position: sticky;
  top: 86px;
  max-height: min(520px, 68vh);
  overflow: auto;
  padding: 8px;
  border: 1px solid #dfe8e4;
  border-radius: 10px;
  background: #f6f9f8;
}

.plan-date-rail-title {
  padding: 4px 6px 9px;
  border-bottom: 1px solid #e1e9e5;
  margin-bottom: 6px;
}

.plan-date-rail-title strong,
.plan-date-rail-title small {
  display: block;
}

.plan-date-rail-title strong {
  color: #263c35;
  font-size: 13px;
}

.plan-date-rail-title small {
  color: #88958f;
  font-size: 10px;
}

.plan-date-rail > button {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  width: 100%;
  min-height: 54px;
  margin-bottom: 6px;
  padding: 7px 8px;
  border-color: transparent;
  background: transparent;
  text-align: left;
}

.plan-date-rail > button:hover {
  background: #eef5f2;
}

.plan-date-rail > button.active {
  border-color: #9fc8b9;
  background: #e4f3ed;
  color: #126c58;
}

.plan-date-rail > button > span {
  text-align: center;
}

.plan-date-rail > button > span b,
.plan-date-rail > button > span small,
.plan-date-rail > button > em,
.plan-date-rail > button > em small {
  display: block;
  font-style: normal;
}

.plan-date-rail > button > span b {
  font-size: 21px;
  line-height: 1;
}

.plan-date-rail > button > span small {
  margin-top: 3px;
  color: #7e8d87;
  font-size: 9px;
}

.plan-date-rail > button > em {
  min-width: 0;
  color: #52645e;
  font-size: 11px;
}

.plan-date-rail > button > em small {
  margin-top: 3px;
  color: #8b9792;
  font-size: 9px;
}

.plan-date-content {
  min-width: 0;
}

.selected-plan-date-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 11px;
  padding: 9px 11px;
  border-left: 3px solid #147a62;
  background: #f4f9f7;
}

.selected-plan-date-heading h3 {
  margin: 1px 0 0;
  color: #263c35;
  font-size: 16px;
}

.selected-plan-date-heading > span {
  flex: 0 0 auto;
  color: #6f817a;
  font-size: 11px;
}

.same-plan-batch-entry {
  width: 100%;
  margin-bottom: 10px;
  border-color: #9fc8b9;
  background: #edf8f3;
  color: #147a62;
}

.same-plan-batch-row {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  gap: 12px;
}

.same-plan-batch textarea,
.same-plan-batch select,
.same-plan-batch input {
  width: 100%;
}

.batch-policy p {
  margin: 10px 0;
  line-height: 1.75;
}

.plan-date-loading,
.plan-date-empty,
.plan-date-empty-result {
  padding: 20px 10px;
  color: #87948f;
  font-size: 12px;
  text-align: center;
}

.plan-date-empty-result strong,
.plan-date-empty-result span {
  display: block;
}

.plan-date-empty-result strong {
  color: #486058;
}

.member-order-form .total {
  margin-top: 17px;
  padding: 17px 3px 0;
}

.member-order-form .submit {
  margin-top: 16px;
}

.member-order-guide {
  grid-area: guide;
  position: sticky;
  top: 88px;
  padding: 18px;
  border: 1px solid #dfe8e4;
  border-radius: 12px;
  background: #fff;
}

.member-order-guide h3 {
  margin: 5px 0 15px;
  color: #223831;
  font-size: 17px;
}

.member-order-guide ol {
  display: flex;
  flex-direction: column;
  gap: 13px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.member-order-guide li {
  position: relative;
  padding-left: 28px;
}

.member-order-guide li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 1px;
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: #e9f4ef;
  color: #147a62;
  font-size: 10px;
  font-weight: 800;
}

.member-order-guide li b,
.member-order-guide li span {
  display: block;
}

.member-order-guide li b {
  color: #283e37;
  font-size: 12px;
}

.member-order-guide li span {
  margin-top: 2px;
  color: #81908b;
  font-size: 11px;
  line-height: 1.55;
}

.member-guide-tip {
  margin-top: 17px;
  padding: 11px 12px;
  border-radius: 8px;
  background: #f4f8f6;
  color: #71817b;
  font-size: 11px;
  line-height: 1.6;
}

.member-guide-tip strong,
.member-guide-tip span {
  display: block;
}

.member-guide-tip strong {
  margin-bottom: 2px;
  color: #3b544b;
}

.member-mobile-submit {
  display: none;
}

@media (max-width: 980px) {
  .member-report-hero {
    grid-template-columns: 1fr;
  }

  .member-report-steps {
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .member-order-form {
    grid-template-columns: minmax(0, 1fr) 240px;
  }
}

@media (max-width: 760px) {
  .member-report-body {
    padding-bottom: 82px;
  }

  .member-order-page {
    margin-top: 14px;
    padding: 0 12px;
  }

  .member-report-hero {
    padding: 18px;
    gap: 15px;
  }

  .member-report-hero h1 {
    font-size: 24px;
  }

  .member-report-steps li {
    padding: 7px 8px;
  }

  .member-order-form {
    grid-template-columns: 1fr;
    grid-template-areas:
      "shipping"
      "guide"
      "plans";
    gap: 12px;
  }

  .member-order-form > .card {
    padding: 17px 14px;
  }

  .member-order-guide {
    position: static;
    padding: 15px;
  }

  .member-order-guide ol {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .member-plan-head {
    display: none;
  }

  .plan-date-layout {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 8px;
  }

  .same-plan-batch-row {
    grid-template-columns: 1fr;
  }

  .plan-date-rail {
    top: 62px;
    max-height: 58vh;
    padding: 5px;
  }

  .plan-date-rail-title {
    padding: 3px 3px 7px;
  }

  .plan-date-rail-title small {
    display: none;
  }

  .plan-date-rail > button {
    grid-template-columns: 1fr;
    min-height: 48px;
    gap: 2px;
    padding: 5px 3px;
    text-align: center;
  }

  .plan-date-rail > button > span b {
    font-size: 19px;
  }

  .plan-date-rail > button > em {
    font-size: 9px;
  }

  .plan-date-rail > button > em small {
    display: none;
  }

  .selected-plan-date-heading {
    align-items: flex-start;
    padding: 8px;
  }

  .selected-plan-date-heading h3 {
    font-size: 14px;
  }

  .selected-plan-date-heading > span {
    font-size: 10px;
  }

  .member-plan-row {
    grid-template-columns: minmax(0, 1fr) 112px;
    gap: 9px;
    padding: 12px 10px;
  }

  .member-plan-row .line-total {
    grid-column: 1 / -1;
    padding-top: 7px;
    border-top: 1px solid #edf1ef;
    text-align: right;
  }

  .member-order-form .total {
    align-items: flex-end;
  }

  .member-mobile-submit {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 55;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    border-top: 1px solid #dfe7e4;
    background: #fffffff2;
    box-shadow: 0 -8px 24px #122b2214;
    backdrop-filter: blur(12px);
  }

  .member-mobile-submit div {
    min-width: 0;
  }

  .member-mobile-submit span,
  .member-mobile-submit strong {
    display: block;
  }

  .member-mobile-submit span {
    color: #81908b;
    font-size: 10px;
  }

  .member-mobile-submit strong {
    color: #147a62;
    font-size: 19px;
  }

  .member-mobile-submit button {
    min-width: 128px;
    padding: 10px 14px;
  }
}

.member-report-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.member-report-summary > div {
  padding: 14px 16px;
  border: 1px solid #dce9e3;
  border-radius: 14px;
  background:
    radial-gradient(circle at 100% 0, #e7f6ef 0, transparent 8rem),
    #fff;
  box-shadow: 0 8px 24px #173d2e08;
}

.member-report-summary span,
.member-report-summary strong {
  display: block;
}

.member-report-summary span {
  color: #7c8e87;
  font-size: 11px;
}

.member-report-summary strong {
  margin-top: 5px;
  color: #1c3b31;
  font-size: 19px;
}

.member-order-review {
  display: grid;
  gap: 14px;
}

.member-order-review h2,
.member-order-review p {
  margin: 0;
}

.member-review-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid #dfeae5;
  border-radius: 12px;
  background: #dfeae5;
}

.member-review-grid > div {
  min-width: 0;
  padding: 12px;
  background: #f8fbfa;
}

.member-review-grid span,
.member-review-grid strong {
  display: block;
}

.member-review-grid span {
  color: #81918b;
  font-size: 10px;
}

.member-review-grid strong {
  margin-top: 3px;
  color: #203b33;
  font-size: 14px;
  overflow-wrap: anywhere;
}

.member-review-grid .member-review-total {
  color: #11755f;
  font-size: 20px;
}

.member-review-section {
  display: grid;
  gap: 7px;
}

.member-review-section > span {
  color: #7a8b84;
  font-size: 11px;
  font-weight: 700;
}

.member-review-address,
.member-review-plans {
  padding: 12px 14px;
  border: 1px solid #e1ebe6;
  border-radius: 11px;
  background: #fbfdfc;
  color: #354d44;
  font-size: 13px;
  line-height: 1.65;
}

.member-review-children {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.member-review-children b {
  padding: 6px 9px;
  border-radius: 8px;
  background: #edf5f2;
  color: #31594d;
  font-size: 12px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.member-review-plan {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px dashed #e3ebe7;
}

.member-review-plan:last-child {
  border-bottom: 0;
}

.member-review-plan div strong,
.member-review-plan div small {
  display: block;
}

.member-review-plan div strong {
  color: #263e35;
  font-size: 13px;
}

.member-review-plan div small {
  margin-top: 2px;
  color: #85938e;
  font-size: 10px;
}

.member-review-plan > span {
  color: #52665e;
  font-size: 12px;
}

.member-review-plan > strong {
  color: #1b715d;
  font-size: 13px;
}

.member-review-warning {
  padding: 11px 13px;
  border: 1px solid #f0d8a8;
  border-radius: 10px;
  background: #fff9ed;
  color: #805b18;
  font-size: 12px;
  line-height: 1.6;
}

#submit-same-plan-batch.is-loading {
  cursor: wait;
}

#submit-same-plan-batch.is-loading::after {
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-left: 8px;
  border: 2px solid #ffffff70;
  border-top-color: #fff;
  border-radius: 50%;
  vertical-align: -2px;
  animation: member-review-spin .7s linear infinite;
  content: "";
}

@keyframes member-review-spin {
  to {
    transform: rotate(360deg);
  }
}

.member-deduction-note {
  display: inline-block;
  margin-top: 5px;
  padding: 3px 7px;
  border-radius: 6px;
  background: #fff0ee;
  color: #a44139;
  font-size: 10px;
  font-weight: 700;
}

@media (max-width: 760px) {
  .member-report-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .member-review-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .member-review-plan {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .member-review-plan > strong {
    grid-column: 1 / -1;
    text-align: right;
  }
}

.member-report-body {
  background:
    radial-gradient(circle at 8% 0%, #dff2e9 0, transparent 26rem),
    linear-gradient(180deg, #f8fbfa 0, #f2f6f4 42rem);
}

.member-report-body header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding-top: 10px;
  padding-bottom: 10px;
  border-bottom-color: #e2ebe7;
  background: #fffffff2;
  box-shadow: 0 6px 22px #1d3a300a;
  backdrop-filter: blur(16px);
}

.member-report-body .brand {
  color: #17372e;
}

.member-order-page > .member-report-hero {
  overflow: hidden;
  background:
    radial-gradient(circle at 100% 0%, #d9f1e7 0, transparent 19rem),
    #fff;
  box-shadow: 0 9px 30px #1c49370b;
}

.member-report-hero h1 {
  letter-spacing: -.7px;
}

.member-order-form > .card {
  background: #fffffff5;
  box-shadow: 0 8px 28px #1e473508;
}

.member-order-form .section-title .step {
  box-shadow: 0 5px 12px #167b641c;
}

.member-report-cards {
  display: grid;
  gap: 13px;
}

.member-report-card {
  position: relative;
  overflow: hidden;
  padding: 16px;
  border: 1px solid #dbe7e1;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 8px 24px #173d2e0a;
}

.member-report-card::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 4px;
  background: linear-gradient(#1a8b6e, #6cc4a7);
  content: "";
}

.member-report-card.cancelled {
  opacity: .72;
}

.member-report-card.cancelled::before {
  background: #a3ada8;
}

.report-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.report-card-head small,
.report-card-head strong,
.report-card-head span {
  display: block;
}

.report-card-head small {
  color: #82918b;
  font-size: 10px;
  letter-spacing: .4px;
}

.report-card-head strong {
  margin: 2px 0 3px;
  color: #1d3b32;
  font-size: 18px;
  letter-spacing: .3px;
  overflow-wrap: anywhere;
}

.report-card-head > div > span {
  color: #8a9691;
  font-size: 11px;
}

.report-amount-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 1px;
  margin: 14px 0 9px;
  overflow: hidden;
  border: 1px solid #e1ebe6;
  border-radius: 10px;
  background: #e1ebe6;
}

.report-amount-grid > div {
  min-width: 0;
  padding: 9px 10px;
  background: #f7fbf9;
}

.report-amount-grid span,
.report-amount-grid strong,
.report-amount-grid b {
  display: block;
}

.report-amount-grid span {
  color: #7e8e87;
  font-size: 10px;
}

.report-amount-grid strong {
  margin-top: 2px;
  color: #166e5a;
  font-size: 17px;
}

.report-amount-grid b {
  margin-top: 2px;
  color: #3e534b;
  font-size: 13px;
}

.report-amount-grid b.pending {
  color: #b06b26;
}

.report-progress {
  height: 4px;
  overflow: hidden;
  margin-bottom: 13px;
  border-radius: 999px;
  background: #edf2ef;
}

.report-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #147a62, #65c3a3);
}

.report-card-items {
  overflow: hidden;
  border: 1px solid #e5ece9;
  border-radius: 10px;
}

.report-card-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 10px 11px;
  border-bottom: 1px solid #edf1ef;
}

.report-card-item:last-child {
  border-bottom: 0;
}

.report-card-item strong,
.report-card-item small {
  display: block;
}

.report-card-item strong {
  color: #2a4038;
  font-size: 14px;
  line-height: 1.45;
}

.report-card-item small {
  margin-top: 3px;
  color: #84918c;
  font-size: 11px;
}

.report-card-item > span {
  align-self: center;
  color: #176e5a;
  font-size: 14px;
  font-weight: 750;
  white-space: nowrap;
}

.report-state-row {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 11px;
}

.report-logistics {
  padding: 3px 7px;
  border-radius: 5px;
  background: #f1f4f2;
  color: #77857f;
  font-size: 10px;
}

.report-logistics.delivered {
  background: #e9f3ff;
  color: #346a9a;
}

.report-card-details {
  margin-top: 10px;
  border-top: 1px dashed #e2e9e5;
}

.report-card-details summary {
  padding: 10px 0 4px;
  color: #647770;
  font-size: 11px;
  font-weight: 650;
  cursor: pointer;
}

.report-card-details > div {
  margin-top: 7px;
}

.report-card-details span {
  color: #84928c;
  font-size: 10px;
}

.report-card-details p {
  margin: 2px 0 0;
  color: #40564d;
  font-size: 12px;
  line-height: 1.6;
}

.report-card-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 11px;
}

.report-card-actions button {
  min-height: 36px;
  padding: 6px 12px;
  font-size: 12px;
}

.member-order-empty {
  padding: 55px 20px;
  border: 1px dashed #cfddd6;
  border-radius: 15px;
  background: #fff;
  text-align: center;
}

.member-order-empty > span {
  font-size: 34px;
}

.member-order-empty strong {
  display: block;
  margin-top: 8px;
  color: #29453b;
  font-size: 17px;
}

.member-order-empty p {
  margin: 5px 0 0;
  color: #84918c;
}

@media (max-width: 760px) {
  .member-report-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
    gap: 6px;
    overflow: visible;
  }

  .member-report-steps li {
    justify-content: center;
    min-width: 0;
    padding: 7px 4px;
    font-size: 10px;
    white-space: normal;
    text-align: center;
  }

  .member-report-steps b {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
  }

  .plan-date-layout {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 7px;
  }

  .plan-date-rail {
    border-radius: 9px;
  }

  .selected-plan-date-heading {
    min-height: 54px;
  }

  .same-plan-batch-entry {
    min-height: 42px;
    font-size: 12px;
    background: #fff;
  }

  .plan-date-content .plan-search-box {
    margin-bottom: 10px;
  }

  .plan-date-content .plan-search-box input {
    font-size: 12px;
  }

  .member-plan-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding: 12px;
    border-color: #dce8e2;
    box-shadow: 0 4px 13px #173d2e08;
  }

  .member-plan-row .plan-choice {
    grid-column: 1 / -1;
  }

  .member-plan-row .plan-name-button {
    font-size: 16px;
    line-height: 1.45;
  }

  .member-plan-row .qty-control {
    justify-self: start;
  }

  .member-plan-row .line-total {
    grid-column: 2;
    align-self: center;
    padding: 0;
    border: 0;
  }

  #order-address-detail:empty {
    display: none;
  }

  dialog:has(.same-plan-batch) {
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
    max-height: 92dvh;
    padding: 18px 14px;
    overflow: auto;
  }

  .same-plan-batch h2 {
    font-size: 22px;
  }

  .same-plan-batch textarea {
    min-height: 150px;
    font-size: 16px;
    line-height: 1.55;
  }
}
