/* Billing Info page (subscription + payment history) */

.billing-info-page {
  width: 100%;
}

.billing-section {
  margin-top: 28px;
}

.billing-section + .billing-section {
  margin-top: 40px;
}

.billing-section-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--color-accent, #fb580c);
  color: #fff;
}

.billing-section-bar-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
  color: #fff;
}

.billing-print-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
}

.billing-print-btn:hover {
  opacity: 0.9;
}

.billing-empty {
  margin: 16px 4px 0;
}

.billing-info-table {
  width: 100%;
}

.billing-info-table th {
  padding-top: 18px;
}

.billing-renewal-cell {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 48px;
}

.billing-renewal-status {
  color: #585858;
}

.billing-cancel-link {
  margin-left: auto;
  padding: 0;
  border: 0;
  background: transparent;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--color-accent, #fb580c);
  text-decoration: none;
  cursor: pointer;
}

.billing-cancel-link:hover {
  text-decoration: underline;
  color: var(--color-accent, #fb580c);
}

a.billing-cancel-link {
  color: var(--color-accent, #fb580c) !important;
  text-decoration: none !important;
}

a.billing-cancel-link:hover {
  text-decoration: underline !important;
}

.billing-currency {
  display: inline-block;
  margin-left: 4px;
  font-size: 12px;
  text-transform: uppercase;
  color: #a3a3a3;
}

.payment-history-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

.payment-history-table-wrap .account-table {
  width: max-content;
  min-width: max(100%, 760px);
  border-collapse: collapse;
}

.payment-history-table-wrap .account-table th,
.payment-history-table-wrap .account-table td {
  white-space: nowrap;
  padding-right: 28px;
  vertical-align: top;
}

.payment-history-table-wrap .account-table th:last-child,
.payment-history-table-wrap .account-table td:last-child {
  padding-right: 0;
}

@media (max-width: 767px) {
  .billing-section-bar {
    flex-wrap: wrap;
    padding: 12px 14px;
  }

  .billing-print-btn {
    font-size: 12px;
  }

  .payment-history-table-wrap {
    margin-right: -8px;
    padding-bottom: 4px;
  }

  .payment-history-table-wrap .account-table {
    min-width: 720px;
  }

  .payment-history-table-wrap .account-table th,
  .payment-history-table-wrap .account-table td {
    padding-right: 20px;
  }
}

@media print {
  @page {
    margin: 16mm;
  }

  body.is-printing-billing-history {
    background: #fff !important;
  }

  body.is-printing-billing-history .account-header,
  body.is-printing-billing-history .account-sidebar,
  body.is-printing-billing-history .site-footer,
  body.is-printing-billing-history .account-page-title,
  body.is-printing-billing-history .account-page-subtitle,
  body.is-printing-billing-history .account-status,
  body.is-printing-billing-history .billing-section:not(.billing-history-section),
  body.is-printing-billing-history .billing-print-btn,
  body.is-printing-billing-history .billing-history-pagination,
  body.is-printing-billing-history .account-modal-backdrop {
    display: none !important;
  }

  body.is-printing-billing-history .account-main,
  body.is-printing-billing-history .account-shell,
  body.is-printing-billing-history .account-panels,
  body.is-printing-billing-history .account-content,
  body.is-printing-billing-history .billing-info-page {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: visible !important;
    background: #fff !important;
    min-height: 0 !important;
  }

  body.is-printing-billing-history .billing-history-section {
    display: block !important;
    margin: 0 !important;
  }

  body.is-printing-billing-history .billing-section-bar {
    display: flex !important;
    background: #fb580c !important;
    color: #fff !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  body.is-printing-billing-history .billing-history-table-wrap,
  body.is-printing-billing-history .payment-history-table-wrap {
    overflow: visible !important;
    margin: 0 !important;
    max-width: none !important;
  }

  body.is-printing-billing-history .payment-history-table-wrap .account-table,
  body.is-printing-billing-history .billing-info-table {
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    table-layout: auto;
  }

  body.is-printing-billing-history .payment-history-table-wrap .account-table th,
  body.is-printing-billing-history .payment-history-table-wrap .account-table td {
    white-space: normal !important;
    padding: 10px 12px 10px 0 !important;
    font-size: 12px !important;
  }

  body.is-printing-billing-history .account-link {
    color: #000 !important;
    text-decoration: none !important;
  }
}

