body.woocommerce-account {
  background: #f8fafc;
}

.hp-account-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 12px 42px;
  display: grid;
  grid-template-columns: minmax(250px, 300px) 1fr;
  gap: 16px;
}

/* Safeguard against duplicate renders of the entire account block. */
.hp-account-shell + .hp-account-shell {
  display: none !important;
}

/* Hide any legacy/default account markup when logged-in; keep only our shell. */
.logged-in .woocommerce-account .account-container,
.logged-in .woocommerce-account .u-columns,
.logged-in .woocommerce-account .woocommerce > .woocommerce-notices-wrapper + .u-columns {
  display: none !important;
}

/* Hide theme page titles / headers that add extra "ברוך הבא" above our design. */
.logged-in.woocommerce-account .entry-header,
.logged-in.woocommerce-account .page-title,
.logged-in.woocommerce-account .title-page,
.logged-in.woocommerce-account .page-header,
.logged-in.woocommerce-account .woocommerce-breadcrumb {
  display: none !important;
}

.hp-account-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 18px;
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.06);
  padding: 18px;
}

.hp-account-main {
  display: grid;
  gap: 16px;
}

.hp-account-nav {
  position: sticky;
  top: 80px;
  align-self: start;
}

.hp-account-user {
  display: grid;
  gap: 4px;
  margin-bottom: 10px;
}

.hp-account-user strong {
  font-size: 17px;
  color: #0f172a;
}

.hp-account-user small {
  color: #475569;
  font-size: 12px;
}

.hp-account-nav-mobile {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 14px;
  background: #f8fafc;
  padding: 0;
  margin: 0;
}

.hp-account-nav-mobile summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  gap: 2px;
  padding: 12px 14px;
  font-weight: 700;
  color: #0f172a;
  position: relative;
}

.hp-account-nav-mobile summary::-webkit-details-marker {
  display: none;
}

.hp-nav-label {
  font-size: 15px;
}

.hp-nav-sub {
  font-size: 12px;
  color: #475569;
}

.hp-nav-chevron {
  position: absolute;
  inset-inline-start: 12px;
  top: 50%;
  width: 10px;
  height: 10px;
  border: 2px solid #0f172a;
  border-width: 0 0 2px 2px;
  transform: translateY(-50%) rotate(-45deg);
  transition: transform 0.2s ease;
}

.hp-account-nav-mobile[open] .hp-nav-chevron {
  transform: translateY(-50%) rotate(135deg);
}

.hp-account-nav-panel {
  padding: 6px 10px 12px;
}

.hp-account-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.hp-account-links a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  color: #0f172a;
  text-decoration: none;
  border: 1px solid rgba(15, 23, 42, 0.06);
  background: #fff;
  transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}

.hp-account-links a:hover,
.hp-account-links .is-active a {
  border-color: #0f172a;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.12);
  transform: translateY(-1px);
}

.hp-account-links .hp-tag {
  font-size: 11px;
  color: #475569;
  background: #e2e8f0;
  border-radius: 999px;
  padding: 4px 8px;
}

.hp-account-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
  border: 1px solid rgba(15, 23, 42, 0.05);
}

.hp-account-hero-text h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
}

.hp-eyebrow {
  margin: 0 0 4px;
  font-size: 12px;
  color: #2563eb;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.hp-sub {
  margin: 6px 0 12px;
  color: #475569;
}

.hp-account-hero-meta {
  display: grid;
  gap: 12px;
}

.hp-hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #0f172a;
  color: #fff;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
  width: fit-content;
}

.hp-hero-pill .dot {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  display: inline-block;
}

.hp-hero-pill.is-off {
  background: #f97316;
}

.hp-hero-pill.is-off .dot {
  background: #fde68a;
}

.hp-account-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.hp-account-metric .label {
  color: #475569;
  font-size: 12px;
}

.hp-account-metric .value {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  margin: 2px 0 4px;
}

.hp-account-metric .meta {
  color: #475569;
  font-size: 12px;
}

.hp-account-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.hp-account-actions .button {
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 700;
  white-space: nowrap;
}

@media (min-width: 981px) {
  .hp-account-nav-mobile {
    border: none;
    background: transparent;
    padding: 0;
  }
  .hp-account-nav-mobile summary {
    display: none;
  }
  .hp-account-nav-panel {
    padding: 0;
  }
}

@media (max-width: 980px) {
  .hp-account-shell {
    grid-template-columns: 1fr;
    padding: 12px 10px 40px;
  }

  .hp-account-card {
    padding: 14px;
    border-radius: 14px;
  }

  .hp-account-nav {
    position: static;
  }

  .hp-account-actions {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
  }
}
