/* NEX eSIM My Account Cards - Frontend only */
.woocommerce-account .woocommerce-MyAccount-content {
  color: #101827;
}

/* Hide default orders table only if any theme still outputs it */
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-orders-table {
  display: none !important;
}

.nex-orders-dashboard,
.nex-orders-dashboard * {
  box-sizing: border-box;
}

.nex-orders-dashboard {
  width: 100%;
  background: #ffffff;
  border: 1px solid #e8edf5;
  border-radius: 22px;
  padding: 26px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.06);
}

.nex-orders-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.nex-orders-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #06b6d4;
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 6px;
}

.nex-orders-header h2 {
  margin: 0 0 6px !important;
  font-size: 30px !important;
  line-height: 1.15 !important;
  font-weight: 900 !important;
  letter-spacing: -0.04em;
  color: #0f172a;
}

.nex-orders-header p {
  margin: 0;
  color: #64748b;
  font-size: 15px;
  line-height: 1.55;
}

.nex-orders-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 14px;
  margin: 20px 0 24px;
}

.nex-order-tab {
  appearance: none;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  border-radius: 14px;
  padding: 12px 16px;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  font-weight: 800;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease, color .18s ease;
}

.nex-order-tab span {
  font-size: 13px;
  white-space: nowrap;
}

.nex-order-tab strong {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  color: #334155;
  font-size: 12px;
}

.nex-order-tab:hover {
  transform: translateY(-1px);
  border-color: #22d3ee;
  box-shadow: 0 12px 25px rgba(15, 23, 42, .08);
}

.nex-order-tab.is-active {
  color: #ffffff;
  border-color: transparent;
  background: linear-gradient(135deg, #00F5A0 0%, #00D9F5 50%, #B388FF 100%);
  box-shadow: 0 15px 30px rgba(0, 217, 245, .24);
}

.nex-order-tab.is-active strong {
  background: rgba(255,255,255,.22);
  color: #ffffff;
}

.nex-orders-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.nex-order-card {
  position: relative;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: #ffffff;
  border: 1px solid #e6edf5;
  border-radius: 18px;
  padding: 22px 20px 20px;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .10);
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.nex-order-card:before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(90deg, #05d9d6, #2563eb, #a78bfa);
}

.nex-order-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 45px rgba(15, 23, 42, .13);
  border-color: #d4e3f3;
}

.nex-order-card[hidden] {
  display: none !important;
}

.nex-order-card-icon {
  width: 46px;
  height: 46px;
  border-radius: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #ecfeff, #eff6ff);
  color: #2563eb;
  font-size: 25px;
  line-height: 1;
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .10);
}

.nex-order-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.nex-order-card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.nex-order-number {
  color: #2563eb !important;
  font-size: 15px;
  font-weight: 900;
  text-decoration: none !important;
}

.nex-order-number:hover {
  color: #06b6d4 !important;
}

.nex-order-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #475569;
  background: #f1f5f9;
}

.nex-status-processing {
  color: #0f766e;
  background: #ccfbf1;
}

.nex-status-completed {
  color: #047857;
  background: #d1fae5;
}

.nex-status-cancelled,
.nex-status-canceled {
  color: #b91c1c;
  background: #fee2e2;
}

.nex-order-product-title {
  margin: 0 0 16px !important;
  color: #0f172a;
  font-size: 21px !important;
  line-height: 1.22 !important;
  font-weight: 900 !important;
  letter-spacing: -0.03em;
}

.nex-order-product-title span {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

.nex-order-meta-list {
  display: grid;
  gap: 9px;
  margin-bottom: 18px;
}

.nex-order-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: #334155;
  font-size: 14px;
  line-height: 1.35;
}

.nex-order-meta-row span {
  color: #64748b;
  font-weight: 700;
}

.nex-order-meta-row strong {
  color: #111827;
  font-weight: 800;
  text-align: right;
}

.nex-order-view-btn,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-button,
.woocommerce-account .woocommerce-MyAccount-content a.button,
.woocommerce-account .woocommerce-MyAccount-content button.button {
  border: 0 !important;
  border-radius: 10px !important;
  padding: 11px 18px !important;
  background: linear-gradient(135deg, #00F5A0 0%, #00D9F5 50%, #B388FF 100%) !important;
  color: #ffffff !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  line-height: 1.2 !important;
  text-decoration: none !important;
  box-shadow: 0 12px 24px rgba(0, 217, 245, 0.22);
  transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
  align-self: flex-start;
  margin-top: auto;
}

.nex-order-view-btn:hover,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-button:hover,
.woocommerce-account .woocommerce-MyAccount-content a.button:hover,
.woocommerce-account .woocommerce-MyAccount-content button.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(0, 217, 245, 0.28);
  opacity: .96;
}

.nex-orders-empty-filter {
  background: #ffffff;
  border: 1px solid #e6eef5;
  border-radius: 18px;
  padding: 26px;
  text-align: center;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.nex-orders-empty-filter[hidden] {
  display: none !important;
}

.nex-orders-empty-filter h3 {
  margin: 0 0 8px !important;
  font-size: 22px !important;
  font-weight: 900 !important;
  color: #0f172a;
}

.nex-orders-empty-filter p {
  margin: 0 0 16px;
  color: #64748b;
}

/* View order page cards / polish */
.woocommerce-account .woocommerce-MyAccount-content > p:first-child,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-notices-wrapper + p {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  padding: 18px 22px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
  margin-bottom: 22px;
}

.woocommerce-account .woocommerce-MyAccount-content > p mark,
.woocommerce-account .woocommerce-MyAccount-content > p strong {
  background: #eef6ff;
  color: #1d4ed8;
  border-radius: 8px;
  padding: 2px 7px;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-order-details__title,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-column__title,
.woocommerce-account .woocommerce-MyAccount-content h2,
.woocommerce-account .woocommerce-MyAccount-content h3 {
  color: #08111f;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-order-details,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-customer-details {
  background: #ffffff;
  border: 1px solid #e6eef5;
  border-radius: 22px;
  padding: 24px;
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.07);
  margin: 24px 0;
  overflow: hidden;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-table--order-details,
.woocommerce-account .woocommerce-MyAccount-content .shop_table.order_details {
  border: 0 !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  overflow: hidden;
  border-radius: 16px;
  background: #f8fafc;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-table--order-details thead th,
.woocommerce-account .woocommerce-MyAccount-content .shop_table.order_details thead th {
  background: #eff6ff;
  color: #0f172a;
  font-weight: 800;
  border: 0 !important;
  padding: 15px 16px !important;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-table--order-details td,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-table--order-details th,
.woocommerce-account .woocommerce-MyAccount-content .shop_table.order_details td,
.woocommerce-account .woocommerce-MyAccount-content .shop_table.order_details th {
  border-color: #e2e8f0 !important;
  padding: 14px 16px !important;
  vertical-align: middle;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-table--order-details tfoot th,
.woocommerce-account .woocommerce-MyAccount-content .shop_table.order_details tfoot th {
  color: #0f172a;
  font-weight: 800;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-table--order-details a,
.woocommerce-account .woocommerce-MyAccount-content .shop_table.order_details a {
  color: #2563eb;
  font-weight: 700;
  text-decoration: none;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-customer-details address,
.woocommerce-account .woocommerce-MyAccount-content address {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 20px 22px !important;
  line-height: 1.8;
  color: #1f2937;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.65);
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-customer-details--phone,
.woocommerce-account .woocommerce-MyAccount-content .woocommerce-customer-details--email {
  margin-top: 10px;
  color: #0f172a;
}

.woocommerce-account .woocommerce-MyAccount-content .woocommerce-info {
  background: #ffffff;
  border: 1px solid #e6eef5;
  border-radius: 18px;
  padding: 18px 22px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

@media (max-width: 920px) {
  .nex-orders-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nex-orders-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575px) {
  .nex-orders-dashboard {
    padding: 18px;
    border-radius: 18px;
  }

  .nex-orders-header h2 {
    font-size: 25px !important;
  }

  .nex-orders-tabs {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .nex-order-card {
    min-height: auto;
    padding: 20px 17px 18px;
  }

  .nex-order-card-topline,
  .nex-order-meta-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .nex-order-meta-row strong {
    text-align: left;
  }

  .woocommerce-account .woocommerce-MyAccount-content .woocommerce-order-details,
  .woocommerce-account .woocommerce-MyAccount-content .woocommerce-customer-details {
    border-radius: 18px;
    padding: 18px;
  }
}

/* Final requested layout refinements */
.nex-order-card-icon,
.nex-order-card-topline,
.nex-order-number {
  display: none !important;
}

.nex-order-card-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 10px;
  margin-bottom: 20px;
  padding-top: 8px;
}

.nex-order-product-title {
  width: 100%;
  margin: 0 !important;
  text-align: center;
}

.nex-order-status,
.nex-status-processing,
.nex-status-completed,
.nex-status-cancelled,
.nex-status-canceled {
  background: linear-gradient(135deg, #00F5A0 0%, #00D9F5 50%, #B388FF 100%) !important;
  color: #ffffff !important;
  padding: 8px 16px;
  box-shadow: 0 10px 22px rgba(0, 217, 245, .20);
}

.nex-order-meta-list {
  margin-top: 2px;
}
