/* Pedagógica B2C — Minha Conta.
   Extraído verbatim de main.css (carregado só nesta rota, depois de main.css). */

/* =====================================================================
   BARRA DE NAVEGAÇÃO MINHA CONTA (desktop — aparece após o header)
   ===================================================================== */

.ped-account-nav {
  background: var(--ped-navbar-bg);
  border-top: 1px solid rgba(255,255,255,.1);
}

.ped-account-nav__list {
  display: flex;
  align-items: stretch;
  list-style: none;
  margin: 0;
  padding: 0;
  height: 46px;
}

.ped-account-nav__item a {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 18px;
  height: 100%;
  color: rgba(255,255,255,.82);
  font-size: .83rem;
  font-weight: 500;
  text-decoration: none;
  border-bottom: 3px solid transparent;
  transition: all var(--ped-transition);
  white-space: nowrap;
}

.ped-account-nav__item a:hover {
  color: var(--ped-white);
  background: rgba(255,255,255,.1);
  border-bottom-color: rgba(255,255,255,.4);
}

.ped-account-nav__item.is-active a {
  color: var(--ped-white);
  font-weight: 700;
  background: rgba(255,255,255,.15);
  border-bottom-color: var(--ped-white);
}

/* Ícones — reutiliza os mesmos ::before definidos abaixo para o sidebar */
.ped-account-nav__item a::before {
  font-family: bootstrap-icons;
  font-size: .9rem;
  flex-shrink: 0;
  color: rgba(255,255,255,.7);
}

.ped-account-nav__item.is-active a::before,
.ped-account-nav__item a:hover::before {
  color: var(--ped-white);
}

/* Sair — empurrado para a direita e em vermelho suave */
.ped-account-nav__item.woocommerce-MyAccount-navigation-link--customer-logout {
  margin-left: auto;
}

.ped-account-nav__item.woocommerce-MyAccount-navigation-link--customer-logout a {
  color: rgba(255,160,160,.9);
  border-left: 1px solid rgba(255,255,255,.15);
}

.ped-account-nav__item.woocommerce-MyAccount-navigation-link--customer-logout a::before {
  color: rgba(255,120,120,.8);
}

.ped-account-nav__item.woocommerce-MyAccount-navigation-link--customer-logout a:hover {
  color: #ffb3b3;
  background: rgba(229,57,53,.18);
  border-bottom-color: #e57373;
}

/* =====================================================================
   MINHA CONTA (WooCommerce My Account)
   ===================================================================== */

.woocommerce-account .ped-wc-wrapper { padding-top: 0; padding-bottom: 48px; }

.woocommerce-account .woocommerce {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  align-items: start;
}

/* ── Dashboard: saudação ──────────────────────────────────────────── */
.ped-account-dashboard { display: flex; flex-direction: column; gap: 24px; }

.ped-account-greeting {
  display: flex;
  align-items: center;
  gap: 16px;
  background: linear-gradient(135deg, var(--ped-primary) 0%, var(--ped-primary-light) 100%);
  color: var(--ped-white);
  padding: 28px 32px;
  border-radius: var(--ped-radius);
}

.ped-account-greeting__avatar {
  font-size: 3rem;
  line-height: 1;
  opacity: .85;
  flex-shrink: 0;
}

.ped-account-greeting__info { flex: 1; min-width: 0; }

.ped-account-greeting__name {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 4px;
  color: var(--ped-white);
}

.ped-account-greeting__email {
  font-size: .83rem;
  margin: 0;
  opacity: .75;
}

.ped-account-greeting__logout {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,.75);
  font-size: .82rem;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,.3);
  border-radius: var(--ped-radius-sm);
  padding: 7px 14px;
  transition: all var(--ped-transition);
  flex-shrink: 0;
}

.ped-account-greeting__logout:hover {
  background: rgba(255,255,255,.15);
  color: var(--ped-white);
}

/* ── Dashboard: acesso rápido ─────────────────────────────────────── */
.ped-account-quicklinks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.ped-account-quicklink {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--ped-white);
  border: 1px solid var(--ped-gray-border);
  border-radius: var(--ped-radius);
  padding: 18px 18px;
  text-decoration: none;
  color: var(--ped-text);
  transition: all var(--ped-transition);
  box-shadow: var(--ped-shadow);
  min-height: 76px;
}

.ped-account-quicklink:hover {
  border-color: var(--ped-primary-light);

  transform: translateY(-2px);
  color: var(--ped-primary);
}

.ped-account-quicklink__icon {
  width: 44px;
  height: 44px;
  background: #eef1fb;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--ped-primary);
  flex-shrink: 0;
  transition: background var(--ped-transition);
}

.ped-account-quicklink:hover .ped-account-quicklink__icon {
  background: var(--ped-primary);
  color: var(--ped-white);
}

.ped-account-quicklink__label {
  flex: 1;
  font-size: .9rem;
  font-weight: 600;
}

.ped-account-quicklink__arrow {
  color: var(--ped-gray-text);
  font-size: .8rem;
  flex-shrink: 0;
}

/* ── Título das seções de conta ───────────────────────────────────── */
.woocommerce-MyAccount-content > h2,
.woocommerce-MyAccount-content > .woocommerce-column__title,
.woocommerce-MyAccount-content .woocommerce-EditAccountForm legend {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ped-primary);
  padding: 20px 0 14px;
  border-bottom: 2px solid var(--ped-gray-border);
  margin-bottom: 20px;
}

/* ── Remove padding duplo na área de conteúdo ─────────────────────── */
.woocommerce-MyAccount-content { padding-top: 24px; }

/* Navegacao lateral — oculta no desktop (substituída pela barra do header) */
.woocommerce-MyAccount-navigation {
  display: none;
  background: var(--ped-white);
  border: 1px solid var(--ped-gray-border);
  border-radius: var(--ped-radius);
  overflow: hidden;
  box-shadow: var(--ped-shadow);
  position: sticky;
  top: 16px;
}

.woocommerce-MyAccount-navigation::before {
  content: "";
  display: block;
  background: var(--ped-primary);
  height: 4px;
}

.woocommerce-MyAccount-navigation ul { list-style: none; margin: 0; padding: 8px 0; }
.woocommerce-MyAccount-navigation ul li { margin: 0; }

.woocommerce-MyAccount-navigation ul li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 20px;
  color: var(--ped-text);
  font-size: .9rem;
  font-weight: 500;
  border-left: 3px solid transparent;
  transition: all var(--ped-transition);
  text-decoration: none;
}

.woocommerce-MyAccount-navigation ul li a:hover {
  background: var(--ped-gray-bg);
  color: var(--ped-primary);
  border-left-color: var(--ped-primary-light);
}

.woocommerce-MyAccount-navigation ul li.is-active a {
  background: #eef1fb;
  color: var(--ped-primary);
  font-weight: 700;
  border-left-color: var(--ped-primary);
}

.woocommerce-MyAccount-navigation ul li a::before {
  font-family: bootstrap-icons;
  font-size: 1rem;
  color: var(--ped-primary);
  flex-shrink: 0;
  width: 18px;
  text-align: center;
}

.woocommerce-MyAccount-navigation-link--dashboard a::before        { content: "\F425"; }
.woocommerce-MyAccount-navigation-link--orders a::before           { content: "\F3D1"; }
.woocommerce-MyAccount-navigation-link--downloads a::before        { content: "\F30A"; }
.woocommerce-MyAccount-navigation-link--edit-address a::before     { content: "\F1A2"; }
.woocommerce-MyAccount-navigation-link--payment-methods a::before  { content: "\F3D8"; }
.woocommerce-MyAccount-navigation-link--edit-account a::before     { content: "\F4DA"; }
.woocommerce-MyAccount-navigation-link--customer-logout a::before  { content: "\F1B1"; color: #e53935; }

.woocommerce-MyAccount-navigation-link--customer-logout {
  border-top: 1px solid var(--ped-gray-border);
  margin-top: 4px;
  padding-top: 4px;
}

.woocommerce-MyAccount-navigation-link--customer-logout a { color: #e53935; }
.woocommerce-MyAccount-navigation-link--customer-logout a:hover { background: #fef2f2; color: #e53935; border-left-color: #e53935; }

.woocommerce-MyAccount-content { min-width: 0; }

/* Tabela de pedidos */
.woocommerce-orders-table,
.woocommerce-MyAccount-content table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--ped-gray-border);
  border-radius: var(--ped-radius);
  overflow: hidden;
  font-size: .875rem;
  box-shadow: var(--ped-shadow);
}

.woocommerce-orders-table thead,
.woocommerce-MyAccount-content table thead { background: var(--ped-primary); }

.woocommerce-orders-table thead th,
.woocommerce-MyAccount-content table thead th {
  padding: 12px 16px;
  font-weight: 600;
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--ped-white);
  border: none;
}

.woocommerce-orders-table tbody tr:nth-child(even),
.woocommerce-MyAccount-content table tbody tr:nth-child(even) { background: var(--ped-gray-bg); }

.woocommerce-orders-table tbody tr:hover,
.woocommerce-MyAccount-content table tbody tr:hover { background: #eef1fb; }

.woocommerce-orders-table tbody td,
.woocommerce-MyAccount-content table tbody td {
  padding: 12px 16px;
  border-top: 1px solid var(--ped-gray-border);
  color: var(--ped-text);
  vertical-align: middle;
}

/* Status badges */
mark.order-status { padding: 4px 10px; border-radius: 20px; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; background: none; box-shadow: none; }
mark.order-status.status-processing { background: #dbeafe; color: #1d4ed8; }
mark.order-status.status-completed  { background: #dcfce7; color: #15803d; }
mark.order-status.status-on-hold    { background: #fef9c3; color: #92400e; }
mark.order-status.status-cancelled  { background: #fee2e2; color: #b91c1c; }
mark.order-status.status-pending    { background: #f3f4f6; color: #374151; }
mark.order-status.status-refunded   { background: #ede9fe; color: #6d28d9; }

/* Enderecos */
.woocommerce-account .woocommerce-Addresses { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }

.woocommerce-account .woocommerce-Address {
  background: var(--ped-white); border: 1px solid var(--ped-gray-border);
  border-radius: var(--ped-radius); padding: 24px; box-shadow: var(--ped-shadow);
}

.woocommerce-account .woocommerce-Address-title {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 16px; padding-bottom: 12px; border-bottom: 2px solid var(--ped-gray-border);
}

.woocommerce-account .woocommerce-Address-title h3 { font-size: 1rem; font-weight: 700; color: var(--ped-primary); margin: 0; }
.woocommerce-account address { font-style: normal; font-size: .875rem; color: var(--ped-gray-text); line-height: 1.7; }

@media (max-width: 991px) {
  .ped-account-quicklinks { grid-template-columns: repeat(2, 1fr); }
  .ped-account-greeting { padding: 20px; }
  .ped-account-greeting__name { font-size: 1.1rem; }

  .woocommerce-account .woocommerce { grid-template-columns: 1fr; }
  .woocommerce-account:not(.logged-in) .col2-set { flex-direction: column; }
  .woocommerce-account:not(.logged-in) .col2-set .col-1,
  .woocommerce-account:not(.logged-in) .col2-set .col-2 { width: 100%; }

  /* Mostra o nav lateral no mobile (a barra do header fica oculta) */
  .woocommerce-MyAccount-navigation {
    display: block;
    position: static;
    overflow-x: auto;
    margin-bottom: 8px;
  }

  .woocommerce-MyAccount-navigation ul { display: flex; flex-wrap: nowrap; padding: 0; }
  .woocommerce-MyAccount-navigation ul li a { white-space: nowrap; border-left: none; border-bottom: 3px solid transparent; padding: 12px 16px; font-size: .82rem; }
  .woocommerce-MyAccount-navigation ul li a:hover,
  .woocommerce-MyAccount-navigation ul li.is-active a { border-left-color: transparent; border-bottom-color: var(--ped-primary); background: #eef1fb; }
  .woocommerce-MyAccount-navigation-link--customer-logout { border-top: none; border-left: 1px solid var(--ped-gray-border); margin-top: 0; padding-top: 0; margin-left: auto; }
  .woocommerce-account .woocommerce-Addresses { grid-template-columns: 1fr; }
  .woocommerce-account:not(.logged-in) .woocommerce { grid-template-columns: 1fr; max-width: 100%; }
}

@media (max-width: 575px) {
  .ped-account-quicklinks { grid-template-columns: 1fr; }
  .ped-account-greeting__logout { display: none; }

  .woocommerce-orders-table thead { display: none; }
  .woocommerce-orders-table tbody tr { display: block; border: 1px solid var(--ped-gray-border); border-radius: var(--ped-radius-sm); margin-bottom: 12px; padding: 12px; background: var(--ped-white) !important; }
  .woocommerce-orders-table tbody td { display: flex; justify-content: space-between; align-items: center; border-top: none; padding: 6px 0; font-size: .82rem; }
  .woocommerce-orders-table tbody td::before { content: attr(data-title); font-weight: 700; color: var(--ped-gray-text); font-size: .75rem; text-transform: uppercase; letter-spacing: .4px; }
}

/* ══════════════════════════════════════════
   MINHA CONTA — Título da página (ped-page__title)
   ══════════════════════════════════════════ */
.woocommerce-MyAccount-content > .ped-page__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ped-primary);
  padding: 0 0 14px;
  border-bottom: 2px solid var(--ped-gray-border);
  margin: 0 0 20px;
}

/* ══════════════════════════════════════════
   MINHA CONTA — Endereços
   ══════════════════════════════════════════ */
.ped-addresses__intro {
  color: var(--ped-gray-text);
  margin-bottom: 24px;
  font-size: 14px;
}

.ped-address-box {
  border: 1px solid var(--ped-gray-border);
  border-radius: var(--ped-radius);
  overflow: hidden;
  height: 100%;
  background: var(--ped-white);
  box-shadow: var(--ped-shadow);
}

.ped-address-box__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: var(--ped-gray-bg);
  border-bottom: 1px solid var(--ped-gray-border);
}

.ped-address-box__title {
  font-size: 15px;
  font-weight: 700;
  color: var(--ped-primary);
  margin: 0;
}

.ped-address-box__edit {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ped-primary);
  text-decoration: none;
  padding: 4px 10px;
  border-radius: var(--ped-radius-sm);
  transition: background var(--ped-transition);
}
.ped-address-box__edit:hover { background: rgba(39,59,155,.08); color: var(--ped-primary); }

.ped-address-box__body {
  padding: 20px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--ped-text);
}

.ped-address-box__body address { font-style: normal; }

.ped-address-box__empty {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ped-gray-text);
  font-size: 13px;
  margin: 0;
}
.ped-address-box__empty i { font-size: 18px; }
