/* ==========================================================================
   YARSAHOME PRO — WOOCOMMERCE MY ACCOUNT STYLESHEET
   Theme release 3.2.4 | RTL-First | Mobile App Experience
   Accessible | Grid Architecture | Clean Overrides
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. PAGE WRAPPER & NOTICES
   -------------------------------------------------------------------------- */
body.woocommerce-account .yarsa-page-content {
  width: min(calc(100% - 32px), 1260px);
  margin-block: 28px 60px;
  margin-inline: auto;
}

body.woocommerce-account .yarsa-page-hero { 
  padding-block: 22px; 
}

body.woocommerce-account .yarsa-entry-content,
body.woocommerce-account .yarsa-entry-content > .woocommerce,
body.woocommerce-account .yarsa-account-shell,
body.woocommerce-account .woocommerce-MyAccount-navigation,
body.woocommerce-account .woocommerce-MyAccount-content {
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

body.woocommerce-account .yarsa-entry-content { 
  line-height: 1.85; 
}

body.woocommerce-account.logged-in .yarsa-entry-content > .woocommerce { 
  display: block !important; 
}

body.woocommerce-account:not(.logged-in) .yarsa-entry-content > .woocommerce {
  display: block;
  max-width: 580px;
  margin-inline: auto;
}

/* حذف تمامی شناوری‌ها و عناصر قبل/بعد ووکامرس */
body.woocommerce-account .yarsa-entry-content > .woocommerce::before,
body.woocommerce-account .yarsa-entry-content > .woocommerce::after,
body.woocommerce-account .yarsa-account-shell::before,
body.woocommerce-account .yarsa-account-shell::after,
body.woocommerce-account .woocommerce-Addresses::before,
body.woocommerce-account .woocommerce-Addresses::after,
body.woocommerce-account .woocommerce-columns::before,
body.woocommerce-account .woocommerce-columns::after {
  display: none !important;
  content: none !important;
}

body.woocommerce-account .yarsa-entry-content > .woocommerce > .woocommerce-notices-wrapper,
body.woocommerce-account .yarsa-entry-content > .woocommerce > .woocommerce-error,
body.woocommerce-account .yarsa-entry-content > .woocommerce > .woocommerce-message,
body.woocommerce-account .yarsa-entry-content > .woocommerce > .woocommerce-info {
  width: 100%;
  margin-bottom: 20px;
}

/* --------------------------------------------------------------------------
   2. MAIN ACCOUNT SHELL & GRID
   -------------------------------------------------------------------------- */
body.woocommerce-account .yarsa-account-shell {
  display: grid !important;
  grid-template-columns: minmax(250px, 280px) minmax(0, 1fr);
  align-items: start;
  gap: 24px;
  direction: rtl;
}

body.woocommerce-account .woocommerce-MyAccount-navigation,
body.woocommerce-account .woocommerce-MyAccount-content {
  float: none !important;
  margin: 0 !important;
}

body.woocommerce-account .woocommerce-MyAccount-navigation {
  position: sticky;
  top: 24px;
  overflow: hidden;
  border: 1px solid var(--yarsa-line);
  border-radius: var(--yarsa-radius-lg);
  background: var(--yarsa-white);
  box-shadow: var(--yarsa-shadow-sm);
  z-index: 10;
}

body.admin-bar.woocommerce-account .woocommerce-MyAccount-navigation { 
  top: 56px; 
}

body.woocommerce-account .woocommerce-MyAccount-content {
  padding: clamp(20px, 2.8vw, 32px);
  overflow: hidden;
  overflow-wrap: anywhere;
  border: 1px solid var(--yarsa-line);
  border-radius: var(--yarsa-radius-lg);
  background: var(--yarsa-white);
  box-shadow: var(--yarsa-shadow-sm);
}

body.woocommerce-account .woocommerce-MyAccount-content > :last-child { 
  margin-bottom: 0; 
}

/* --------------------------------------------------------------------------
   3. PROFILE SUMMARY & NAVIGATION MENU
   -------------------------------------------------------------------------- */
body.woocommerce-account .yarsa-account-profile-summary {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 22px 18px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--yarsa-green) 0%, var(--yarsa-green-dark) 100%);
  color: var(--yarsa-white);
}

body.woocommerce-account .yarsa-account-profile-summary::after {
  position: absolute;
  inset-inline-end: -30px;
  inset-block-end: -40px;
  width: 110px;
  height: 110px;
  border: 18px solid rgba(194, 119, 61, 0.25);
  border-radius: 50%;
  content: '';
  pointer-events: none;
}

body.woocommerce-account .yarsa-account-profile-summary__icon {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--yarsa-white);
  font-size: 20px;
}

body.woocommerce-account .yarsa-account-profile-summary__copy {
  position: relative;
  z-index: 1;
  display: grid;
  min-width: 0;
  line-height: 1.6;
}

body.woocommerce-account .yarsa-account-profile-summary__copy > span {
  color: rgba(255, 255, 255, 0.75);
  font-size: 11px;
}

body.woocommerce-account .yarsa-account-profile-summary__copy strong {
  max-width: 100%;
  overflow: hidden;
  color: var(--yarsa-white);
  font-size: 14px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.woocommerce-account .yarsa-account-profile-summary__copy bdi {
  color: rgba(255, 255, 255, 0.9);
  font-size: 12px;
  direction: ltr;
  text-align: right;
}

body.woocommerce-account .woocommerce-MyAccount-navigation ul {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 10px;
  list-style: none;
}

body.woocommerce-account .woocommerce-MyAccount-navigation li {
  min-width: 0;
  margin: 0;
}

body.woocommerce-account .woocommerce-MyAccount-navigation a {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 48px;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--yarsa-muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.5;
  transition: all var(--yarsa-transition);
}

body.woocommerce-account .yarsa-account-nav__icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--yarsa-soft-green);
  color: var(--yarsa-green);
  font-size: 14px;
  transition: all var(--yarsa-transition);
}

body.woocommerce-account .woocommerce-MyAccount-navigation a:hover {
  border-color: var(--yarsa-line);
  background: var(--yarsa-soft-green);
  color: var(--yarsa-green-dark);
}

body.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a {
  border-color: rgba(30, 98, 83, 0.16);
  background: var(--yarsa-soft-green);
  color: var(--yarsa-green-dark);
}

body.woocommerce-account .woocommerce-MyAccount-navigation li.is-active .yarsa-account-nav__icon {
  background: var(--yarsa-green);
  color: var(--yarsa-white);
}

body.woocommerce-account .woocommerce-MyAccount-navigation li[data-yarsa-account-endpoint="customer-logout"] a {
  color: var(--yarsa-tan-hover);
}

body.woocommerce-account .woocommerce-MyAccount-navigation li[data-yarsa-account-endpoint="customer-logout"] .yarsa-account-nav__icon {
  background: var(--yarsa-soft-tan);
  color: var(--yarsa-tan-hover);
}

body.woocommerce-account .woocommerce-MyAccount-navigation a:focus-visible {
  outline: 2px solid var(--yarsa-tan);
  outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   4. ENDPOINT HEADER & TYPOGRAPHY
   -------------------------------------------------------------------------- */
body.woocommerce-account .yarsa-account-heading {
  position: relative;
  margin: 0 0 24px;
  padding-inline-start: 16px;
  padding-block: 0 18px;
  border-bottom: 1px solid var(--yarsa-line);
}

body.woocommerce-account .yarsa-account-heading::before {
  position: absolute;
  inset-inline-start: 0;
  inset-block-start: 4px;
  width: 4px;
  height: 44px;
  border-radius: 4px;
  background: var(--yarsa-tan);
  content: '';
}

body.woocommerce-account .yarsa-account-heading__eyebrow {
  display: block;
  margin-bottom: 3px;
  color: var(--yarsa-tan);
  font-size: 11px;
  font-weight: 800;
}

body.woocommerce-account .yarsa-account-heading h2 {
  margin: 0;
  color: var(--yarsa-green-dark);
  font-size: clamp(20px, 2.2vw, 26px);
  font-weight: 900;
  line-height: 1.5;
}

body.woocommerce-account .yarsa-account-heading > p:last-child {
  margin: 4px 0 0;
  color: var(--yarsa-muted);
  font-size: 12.5px;
}

body.woocommerce-account .woocommerce-MyAccount-content h2,
body.woocommerce-account .woocommerce-MyAccount-content h3 {
  color: var(--yarsa-green-dark);
  font-weight: 900;
  line-height: 1.6;
}

body.woocommerce-account .woocommerce-MyAccount-content h2 {
  margin-block: 0 16px;
  font-size: clamp(18px, 2vw, 22px);
}

body.woocommerce-account .woocommerce-MyAccount-content h3 {
  margin-block: 0 12px;
  font-size: 16px;
}

body.woocommerce-account .woocommerce-MyAccount-content a:not(.button) {
  color: var(--yarsa-green);
  font-weight: 800;
  text-decoration-color: rgba(194, 119, 61, 0.4);
  text-underline-offset: 4px;
}

body.woocommerce-account .woocommerce-MyAccount-content a:not(.button):hover {
  color: var(--yarsa-tan);
}

/* --------------------------------------------------------------------------
   5. DASHBOARD WELCOME & QUICK ACTIONS
   -------------------------------------------------------------------------- */
body.woocommerce-account .yarsa-account-welcome {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-width: 0;
  margin-bottom: 22px;
  padding: clamp(20px, 2.5vw, 28px);
  overflow: hidden;
  border-radius: 14px;
  background: var(--yarsa-green);
  color: var(--yarsa-white);
}

body.woocommerce-account .yarsa-account-welcome::after {
  position: absolute;
  inset-inline-end: -50px;
  inset-block-start: -60px;
  width: 160px;
  height: 160px;
  border: 24px solid rgba(194, 119, 61, 0.18);
  border-radius: 50%;
  content: '';
  pointer-events: none;
}

body.woocommerce-account .yarsa-account-welcome__copy {
  position: relative;
  z-index: 1;
  min-width: 0;
}

body.woocommerce-account .yarsa-account-welcome__copy > span {
  display: block;
  margin-bottom: 4px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 11px;
  font-weight: 700;
}

body.woocommerce-account .yarsa-account-welcome__copy h3 {
  margin: 0 0 6px;
  color: var(--yarsa-white);
  font-size: clamp(18px, 2.2vw, 24px);
}

body.woocommerce-account .yarsa-account-welcome__copy p {
  max-width: 600px;
  margin: 0;
  color: rgba(255, 255, 255, 0.85);
  font-size: 13px;
  line-height: 1.8;
}

body.woocommerce-account .woocommerce-MyAccount-content .yarsa-account-welcome__shop {
  position: relative;
  z-index: 1;
  flex: 0 0 auto;
  min-height: 44px;
  padding-inline: 18px !important;
  border-color: var(--yarsa-tan) !important;
  background: var(--yarsa-tan) !important;
}

body.woocommerce-account .yarsa-account-quick-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

body.woocommerce-account .yarsa-account-quick-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 14px;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 84px;
  padding: 12px 14px;
  border: 1px solid var(--yarsa-line);
  border-radius: 12px;
  background: var(--yarsa-white);
  text-decoration: none !important;
  box-shadow: var(--yarsa-shadow-sm);
  transition: all var(--yarsa-transition);
}

body.woocommerce-account .yarsa-account-quick-card:hover {
  border-color: var(--yarsa-tan);
  transform: translateY(-3px);
  box-shadow: var(--yarsa-shadow);
}

body.woocommerce-account .yarsa-account-quick-card__icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--yarsa-soft-green);
  color: var(--yarsa-green);
  font-size: 16px;
}

body.woocommerce-account .yarsa-account-quick-card__copy {
  display: grid;
  min-width: 0;
  line-height: 1.5;
}

body.woocommerce-account .yarsa-account-quick-card__copy strong {
  color: var(--yarsa-green-dark);
  font-size: 13px;
  font-weight: 800;
}

body.woocommerce-account .yarsa-account-quick-card__copy small {
  color: var(--yarsa-muted);
  font-size: 10.5px;
}

body.woocommerce-account .yarsa-account-quick-card__arrow {
  color: var(--yarsa-tan);
  font-size: 11px;
}

/* --------------------------------------------------------------------------
   6. TABLES (Orders, Downloads, Payment Methods)
   -------------------------------------------------------------------------- */
body.woocommerce-account .woocommerce-MyAccount-content table.shop_table {
  width: 100%;
  max-width: 100%;
  margin: 0 0 22px;
  overflow: hidden;
  border: 1px solid var(--yarsa-line) !important;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 14px !important;
  background: var(--yarsa-white);
}

body.woocommerce-account .woocommerce-MyAccount-content table.shop_table thead th {
  padding: 12px 14px !important;
  border: 0 !important;
  border-bottom: 1px solid var(--yarsa-line) !important;
  background: var(--yarsa-soft-green) !important;
  color: var(--yarsa-green-dark);
  font-size: 12px;
  font-weight: 800;
  text-align: right;
}

body.woocommerce-account .woocommerce-MyAccount-content table.shop_table tbody td,
body.woocommerce-account .woocommerce-MyAccount-content table.shop_table tbody th {
  padding: 14px 12px !important;
  border: 0 !important;
  border-bottom: 1px solid var(--yarsa-line) !important;
  background: transparent !important;
  color: var(--yarsa-green-dark);
  font-size: 13px;
  vertical-align: middle;
  text-align: right;
}

body.woocommerce-account .woocommerce-MyAccount-content table.shop_table tbody tr:last-child > * { 
  border-bottom: 0 !important; 
}

body.woocommerce-account .woocommerce-MyAccount-content table.shop_table tbody tr:hover > * { 
  background: var(--yarsa-bg-light) !important; 
}

body.woocommerce-account .woocommerce-orders-table__cell-order-number a {
  direction: ltr;
  display: inline-block;
  font-weight: 800;
}

body.woocommerce-account .woocommerce-orders-table__cell-order-status {
  color: var(--yarsa-green);
  font-weight: 800;
}

body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button,
body.woocommerce-account .woocommerce-MyAccount-paymentMethods .button,
body.woocommerce-account .woocommerce-table--order-downloads .button {
  min-height: 38px !important;
  padding: 6px 12px !important;
  font-size: 11.5px !important;
  border-radius: 8px !important;
}

body.woocommerce-account .woocommerce-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 18px;
}

/* --------------------------------------------------------------------------
   7. ADDRESSES & VIEW ORDER
   -------------------------------------------------------------------------- */
body.woocommerce-account .woocommerce-Addresses,
body.woocommerce-account .woocommerce-columns--addresses,
body.woocommerce-account .woocommerce-customer-details .woocommerce-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  width: 100%;
  min-width: 0;
}

body.woocommerce-account .woocommerce-Addresses .woocommerce-Address,
body.woocommerce-account .woocommerce-columns--addresses .woocommerce-column,
body.woocommerce-account .woocommerce-customer-details .woocommerce-column {
  float: none;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--yarsa-line);
  border-radius: var(--yarsa-radius);
  background: var(--yarsa-bg-light);
}

body.woocommerce-account .woocommerce-Address-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

body.woocommerce-account .woocommerce-Address-title h2,
body.woocommerce-account .woocommerce-Address-title h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
}

body.woocommerce-account .woocommerce-Address-title .edit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 4px 12px;
  border: 1px solid var(--yarsa-tan);
  border-radius: 8px;
  background: var(--yarsa-white);
  color: var(--yarsa-tan-hover);
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
  transition: all var(--yarsa-transition);
}

body.woocommerce-account .woocommerce-Address-title .edit:hover {
  background: var(--yarsa-tan);
  color: var(--yarsa-white);
}

body.woocommerce-account .woocommerce-Address address,
body.woocommerce-account .woocommerce-customer-details address {
  margin: 0;
  color: var(--yarsa-green-dark);
  font-style: normal;
  line-height: 2;
  overflow-wrap: anywhere;
}

/* --------------------------------------------------------------------------
   8. FORMS (Edit Account, Address Forms, OTP)
   -------------------------------------------------------------------------- */
body.woocommerce-account .woocommerce-address-fields__field-wrapper,
body.woocommerce-account .woocommerce-EditAccountForm,
body.woocommerce-account .hidy-account-form,
body.woocommerce-account .yarsa-account-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 16px;
}

body.woocommerce-account .woocommerce-address-fields__field-wrapper .form-row,
body.woocommerce-account .woocommerce-EditAccountForm .form-row,
body.woocommerce-account .hidy-account-field,
body.woocommerce-account .yarsa-account-field {
  float: none;
  width: auto;
  min-width: 0;
  margin: 0;
}

body.woocommerce-account .woocommerce-address-fields__field-wrapper .form-row-wide,
body.woocommerce-account .woocommerce-EditAccountForm .form-row-wide,
body.woocommerce-account .woocommerce-EditAccountForm fieldset,
body.woocommerce-account .woocommerce-address-fields > p,
body.woocommerce-account .woocommerce-EditAccountForm > p:last-child,
body.woocommerce-account .hidy-account-form > .hidy-otp-primary,
body.woocommerce-account .yarsa-account-form > .yarsa-account-primary {
  grid-column: 1 / -1;
}

body.woocommerce-account .woocommerce-EditAccountForm fieldset {
  min-width: 0;
  margin: 10px 0 0;
  padding: 16px;
  border: 1px solid var(--yarsa-line);
  border-radius: 12px;
}

body.woocommerce-account .woocommerce-EditAccountForm legend {
  padding-inline: 8px;
  color: var(--yarsa-green-dark);
  font-weight: 800;
}

body.woocommerce-account .woocommerce form .form-row label,
body.woocommerce-account .hidy-account-field label,
body.woocommerce-account .yarsa-account-field label {
  display: block;
  margin-bottom: 6px;
  color: var(--yarsa-green-dark);
  font-size: 12px;
  font-weight: 800;
}

body.woocommerce-account .woocommerce form .form-row input.input-text,
body.woocommerce-account .woocommerce form .form-row textarea,
body.woocommerce-account .woocommerce form .form-row select,
body.woocommerce-account .hidy-account-form input:not([type="hidden"]),
body.woocommerce-account .yarsa-account-form input:not([type="hidden"]) {
  width: 100%;
  min-width: 0;
  min-height: 48px !important;
  padding: 8px 12px !important;
  border: 1px solid var(--yarsa-line) !important;
  border-radius: var(--yarsa-radius-sm) !important;
  background: var(--yarsa-white) !important;
  color: var(--yarsa-green-dark) !important;
  font-size: 13.5px;
  outline: none;
  box-shadow: none !important;
  transition: border-color var(--yarsa-transition), box-shadow var(--yarsa-transition);
}

body.woocommerce-account .woocommerce form .form-row input.input-text:focus,
body.woocommerce-account .woocommerce form .form-row textarea:focus,
body.woocommerce-account .woocommerce form .form-row select:focus,
body.woocommerce-account .hidy-account-form input:not([type="hidden"]):focus,
body.woocommerce-account .yarsa-account-form input:not([type="hidden"]):focus {
  border-color: var(--yarsa-tan) !important;
  box-shadow: 0 0 0 3px rgba(194, 119, 61, 0.15) !important;
}

body.woocommerce-account .yarsa-account-phone {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 18px;
  padding: 12px 16px;
  border: 1px solid var(--yarsa-line);
  border-radius: 10px;
  background: var(--yarsa-soft-green);
  color: var(--yarsa-green-dark);
}

body.woocommerce-account .yarsa-account-phone bdi {
  direction: ltr;
  font-weight: 800;
}

/* --------------------------------------------------------------------------
   9. RESPONSIVE BREAKPOINTS
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  body.woocommerce-account .yarsa-account-shell {
    grid-template-columns: minmax(220px, 250px) minmax(0, 1fr);
    gap: 18px;
  }
  body.woocommerce-account .yarsa-account-quick-actions { 
    grid-template-columns: repeat(2, minmax(0, 1fr)); 
  }
}

@media (max-width: 900px) {
  body.woocommerce-account .yarsa-account-shell {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  body.woocommerce-account .woocommerce-MyAccount-navigation {
    position: static;
    top: auto;
  }

  body.woocommerce-account .woocommerce-MyAccount-navigation ul {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  body.woocommerce-account .woocommerce-MyAccount-navigation a {
    grid-template-columns: 32px minmax(0, 1fr);
    min-height: 46px;
    padding: 6px 8px;
    font-size: 12px;
  }

  body.woocommerce-account .yarsa-account-nav__icon {
    width: 32px;
    height: 32px;
  }
}

@media (max-width: 700px) {
  body.woocommerce-account .yarsa-page-content {
    width: calc(100% - 20px);
    margin-block: 16px 36px;
  }

  body.woocommerce-account .woocommerce-MyAccount-content {
    padding: 16px;
    border-radius: var(--yarsa-radius);
  }

  body.woocommerce-account .woocommerce-MyAccount-navigation ul { 
    grid-template-columns: repeat(2, minmax(0, 1fr)); 
  }
  
  body.woocommerce-account .woocommerce-MyAccount-navigation li[data-yarsa-account-endpoint="customer-logout"] { 
    grid-column: 1 / -1; 
  }

  body.woocommerce-account .yarsa-account-welcome {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 18px;
  }

  body.woocommerce-account .yarsa-account-quick-actions {
    grid-template-columns: 1fr;
  }

  body.woocommerce-account .woocommerce-Addresses,
  body.woocommerce-account .woocommerce-columns--addresses,
  body.woocommerce-account .woocommerce-customer-details .woocommerce-columns,
  body.woocommerce-account .woocommerce-address-fields__field-wrapper,
  body.woocommerce-account .woocommerce-EditAccountForm,
  body.woocommerce-account .hidy-account-form,
  body.woocommerce-account .yarsa-account-form { 
    grid-template-columns: minmax(0, 1fr); 
  }

  /* تبدیل جداول سفارشات و دانلودها به کارت در موبایل */
  body.woocommerce-account table.woocommerce-orders-table,
  body.woocommerce-account table.woocommerce-table--order-downloads,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods {
    display: block;
    border: 0 !important;
    background: transparent !important;
  }

  body.woocommerce-account table.woocommerce-orders-table thead,
  body.woocommerce-account table.woocommerce-table--order-downloads thead,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods thead {
    display: none !important;
  }

  body.woocommerce-account table.woocommerce-orders-table tbody,
  body.woocommerce-account table.woocommerce-table--order-downloads tbody,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods tbody {
    display: grid;
    gap: 12px;
    width: 100%;
  }

  body.woocommerce-account table.woocommerce-orders-table tbody > tr,
  body.woocommerce-account table.woocommerce-table--order-downloads tbody > tr,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods tbody > tr {
    display: grid;
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--yarsa-line);
    border-radius: var(--yarsa-radius);
    background: var(--yarsa-white);
    box-shadow: var(--yarsa-shadow-sm);
  }

  body.woocommerce-account table.woocommerce-orders-table tbody td,
  body.woocommerce-account table.woocommerce-orders-table tbody th,
  body.woocommerce-account table.woocommerce-table--order-downloads tbody td,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods tbody td {
    display: grid !important;
    grid-template-columns: minmax(90px, 0.4fr) minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 8px 0 !important;
    border: 0 !important;
    border-bottom: 1px dashed var(--yarsa-line) !important;
    text-align: right !important;
  }

  body.woocommerce-account table.woocommerce-orders-table tbody > tr > :last-child,
  body.woocommerce-account table.woocommerce-table--order-downloads tbody > tr > :last-child,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods tbody > tr > :last-child { 
    border-bottom: 0 !important; 
  }

  body.woocommerce-account table.woocommerce-orders-table tbody td::before,
  body.woocommerce-account table.woocommerce-orders-table tbody th::before,
  body.woocommerce-account table.woocommerce-table--order-downloads tbody td::before,
  body.woocommerce-account table.woocommerce-MyAccount-paymentMethods tbody td::before {
    color: var(--yarsa-muted);
    font-size: 11px;
    font-weight: 800;
    content: attr(data-title);
  }

  body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions,
  body.woocommerce-account table.woocommerce-table--order-downloads .download-file {
    grid-template-columns: minmax(0, 1fr);
    padding-top: 10px !important;
  }

  body.woocommerce-account .woocommerce-orders-table__cell-order-actions .button,
  body.woocommerce-account .woocommerce-table--order-downloads .button {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  body.woocommerce-account .woocommerce-MyAccount-navigation a {
    font-size: 11px;
    padding: 4px 6px;
  }
  
  body.woocommerce-account .yarsa-account-heading h2 { 
    font-size: 18px; 
  }

  body.woocommerce-account .woocommerce-Address-title {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  body.woocommerce-account .woocommerce-Address-title .edit {
    width: 100%;
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.woocommerce-account * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}