* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: Arial, "Segoe UI", Roboto, sans-serif; background: #fff; color: #333; }
a { color: inherit; text-decoration: none; }

header.mc-header {
  background: #009edf;
  padding: 14px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  position: relative;
}
header.mc-header img { height: 34px; }
.mc-header-tagline {
  color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .02em;
  line-height: 1.5; text-align: center;
}
@media (min-width: 768px) {
  header.mc-header { flex-direction: row; }
  .mc-header-tagline { position: absolute; right: 24px; top: 50%; transform: translateY(-50%); text-align: right; }
}

.mc-topbar {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 16px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.mc-topbar .mc-saudacao { font-size: 16px; color: #333; }
.mc-topbar .mc-saudacao b { font-weight: 700; }
.mc-topbar .mc-saudacao a { color: #009edf; font-weight: 700; }
.mc-btn-voltar {
  background: #009edf; color: #fff; font-weight: 700; font-size: 13px;
  padding: 10px 18px; border-radius: 4px; border: none; cursor: pointer;
}

.mc-wrap {
  max-width: 1200px;
  margin: 18px auto 40px;
  padding: 0 16px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
@media (min-width: 1024px) {
  .mc-wrap { grid-template-columns: 280px 1fr; }
}

.mc-sidebar { background: #fff; border: 1px solid #eee; border-radius: 4px; overflow: hidden; }
.mc-sidebar a, .mc-sidebar-breve {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px; font-size: 16px; color: #009edf; border-bottom: 1px solid #f1f1f1;
}
.mc-sidebar a:last-child { border-bottom: none; }
.mc-sidebar a.ativo { background: #f1f1f1; font-weight: 700; }
.mc-sidebar a:hover { background: #f7f7f7; }
.mc-sidebar a.mc-sair { color: #009edf; }
.mc-sidebar-icon { width: 20px; height: 20px; flex-shrink: 0; display: inline-flex; }
.mc-sidebar-icon svg, .mc-timeline-bola svg { width: 100%; height: 100%; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.mc-sidebar-breve { cursor: default; }

/* 768-1023px: igual ao site real — o menu vira uma linha horizontal com
   quebra, ocupando a largura toda (não vira coluna, nem fica escondido
   atrás do botão — isso só acontece abaixo de 768px). */
@media (min-width: 768px) and (max-width: 1023px) {
  .mc-sidebar { display: flex; flex-wrap: wrap; }
  .mc-sidebar a, .mc-sidebar-breve {
    flex: 0 0 auto; border-bottom: none; padding: 14px 16px; font-size: 14px;
  }
  .mc-sidebar a.ativo { border-radius: 4px; }
}

.mc-sidebar-toggle { display: none; }
@media (max-width: 767px) {
  .mc-sidebar-toggle {
    display: flex; align-items: center; gap: 12px; width: 100%;
    background: #fff; border: 1px solid #eee; border-radius: 4px; padding: 14px 16px;
    font-size: 15px; font-weight: 700; color: #333; cursor: pointer; text-align: left;
  }
  .mc-sidebar-toggle-seta { margin-left: auto; width: 16px; height: 16px; flex-shrink: 0; transition: transform .15s; }
  .mc-sidebar-toggle-seta svg { width: 100%; height: 100%; stroke: #888; fill: none; stroke-width: 2; }
  .mc-sidebar-toggle.mc-aberto .mc-sidebar-toggle-seta { transform: rotate(180deg); }
  .mc-sidebar { display: none; margin-top: 8px; }
  .mc-sidebar.mc-aberta { display: block; }
}

.mc-content { background: #fff; border: 1px solid #eee; border-radius: 4px; min-width: 0; }
.mc-content-titulo { background: #f1f1f1; padding: 16px 24px; font-weight: 700; font-size: 16px; color: #333; }
.mc-content-body { padding: 24px; overflow-x: auto; }

.mc-empty { text-align: center; padding: 40px 0; color: #888; font-size: 14px; }

/* Pedidos: barra de filtro */
.mc-filtro-barra {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 18px;
}
.mc-filtro-barra select, .mc-filtro-barra input[type="text"] {
  padding: 9px 10px; border: 1px solid #ccc; border-radius: 4px; font-size: 13px; font-family: inherit; color: #555;
}
.mc-filtro-barra input[type="text"] { flex: 1; min-width: 160px; }
.mc-filtro-periodo { margin-left: auto; }
.mc-btn-limpar {
  background: #e2002e; color: #fff; border: none; width: 34px; height: 34px; border-radius: 4px;
  font-size: 13px; font-weight: 700; cursor: pointer; flex-shrink: 0;
}
.mc-btn-buscar {
  background: #ececec; color: #333; border: none; padding: 0 18px; height: 34px; border-radius: 4px;
  font-size: 13px; font-weight: 700; cursor: pointer; flex-shrink: 0;
}
.mc-pedido-detalhe-row td { background: #fafcfe; padding: 14px 12px; border-bottom: 1px solid #f1f1f1; }

/* Pedidos: tabela */
.mc-pedidos-tabela { width: 100%; border-collapse: collapse; font-size: 16px; table-layout: auto; }
.mc-pedidos-tabela th {
  text-align: left; font-size: 13px; color: #888; font-weight: 700; text-transform: uppercase;
  letter-spacing: .03em; padding: 14px 16px; border-bottom: 2px solid #f1f1f1; white-space: nowrap;
}
.mc-pedidos-tabela td { padding: 22px 16px; border-bottom: 1px solid #f1f1f1; vertical-align: top; color: #333; }
.mc-pedidos-tabela tr:last-child td { border-bottom: none; }
.mc-pedido-codigo { color: #009edf; font-weight: 700; font-size: 16px; white-space: nowrap; }
.mc-pedido-data { display: block; color: #999; font-size: 13px; margin-top: 4px; white-space: nowrap; }
.mc-pedido-itens-mini { color: #666; font-size: 13px; margin-top: 4px; line-height: 1.5; }
.mc-pedido-valor { white-space: nowrap; }
.mc-pedido-mensagem { font-size: 13px; color: #555; max-width: 220px; line-height: 1.5; }
.mc-status { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; padding: 6px 14px; border-radius: 20px; white-space: nowrap; }
.mc-status.aprovado, .mc-status.enviado { background: #e6f7e6; color: #2ab523; }
.mc-status.pendente { background: #fff8e1; color: #b8860b; }
.mc-status.expirado, .mc-status.cancelado, .mc-status.recusado { background: #fdeaea; color: #d0021b; }
.mc-pedido-rastreio { font-size: 12px; margin-top: 6px; }
.mc-pedido-rastreio a { color: #009edf; font-weight: 700; }
.mc-btn-detalhes {
  background: #f1f1f1; color: #333; border: none; padding: 12px 20px; border-radius: 4px;
  font-size: 14px; font-weight: 700; cursor: pointer; white-space: nowrap; display: inline-block; text-decoration: none;
}
@media (max-width: 640px) {
  .mc-pedidos-tabela thead { display: none; }
  .mc-pedidos-tabela, .mc-pedidos-tabela tbody, .mc-pedidos-tabela tr, .mc-pedidos-tabela td { display: block; width: 100%; }
  .mc-pedidos-tabela tr { border-bottom: 1px solid #eee; padding: 12px 0; }
  .mc-pedidos-tabela td { border-bottom: none; padding: 4px 0; }
}

/* Forms (dados pessoais / senha / endereco) */
.mc-subtitulo { font-size: 14px; font-weight: 700; color: #333; margin: 24px 0 14px; padding-top: 14px; border-top: 1px solid #eee; }
.mc-field { margin-bottom: 14px; max-width: 420px; }
.mc-field label { display: block; font-size: 13px; color: #555; margin-bottom: 4px; }
.mc-field input, .mc-field select {
  width: 100%; padding: 11px; border: 1px solid #ccc; border-radius: 4px; font-size: 14px; font-family: inherit;
}
.mc-field input:disabled { background: #f5f5f5; color: #888; }
.mc-row { display: flex; gap: 12px; max-width: 420px; }
.mc-row .mc-field { flex: 1; }
.mc-save-btn {
  background: #2ab523; color: #fff; font-weight: 700; font-size: 14px;
  padding: 11px 24px; border: none; border-radius: 4px; cursor: pointer;
}
.mc-save-btn:disabled { opacity: .6; cursor: not-allowed; }
.mc-msg { font-size: 13px; margin-top: 10px; display: none; }
.mc-msg.ok { color: #2ab523; display: block; }
.mc-msg.erro { color: #d0021b; display: block; }

/* Enderecos */
.mc-endereco-card { border: 1px solid #eee; border-radius: 4px; padding: 14px 16px; margin-bottom: 12px; position: relative; }
.mc-endereco-card.principal { border-color: #009edf; }
.mc-endereco-titulo { font-size: 15px; font-weight: 700; color: #333; margin-bottom: 10px; }
.mc-endereco-tag { display: inline-block; font-size: 11px; font-weight: 700; color: #009edf; background: #eaf6fc; padding: 3px 9px; border-radius: 12px; margin-left: 6px; vertical-align: middle; }
.mc-endereco-box { border: 1px solid #eee; border-radius: 4px; padding: 12px 14px; background: #fafcfe; }
.mc-endereco-linha { font-size: 13px; color: #444; margin-top: 4px; }
.mc-endereco-linha:first-child { margin-top: 0; }
.mc-endereco-acoes { margin-top: 10px; display: flex; gap: 14px; font-size: 12px; }
.mc-endereco-acoes a { color: #009edf; font-weight: 700; cursor: pointer; }
.mc-endereco-acoes a.excluir { color: #d0021b; }
.mc-add-endereco-btn {
  background: #fff; color: #009edf; border: 1px solid #009edf; font-weight: 700;
  font-size: 13px; padding: 10px 18px; border-radius: 4px; cursor: pointer; margin-top: 6px;
}

.mc-footer { text-align: center; padding: 24px 16px; color: #999; font-size: 12px; }

/* Modal de detalhe do pedido */
.mc-modal-backdrop {
  position: fixed; inset: 0; background: rgba(0,0,0,.5); display: none;
  align-items: flex-start; justify-content: center; padding: 40px 16px; overflow-y: auto; z-index: 1000;
}
.mc-modal-backdrop.aberto { display: flex; }
.mc-modal {
  background: #fff; border-radius: 8px; max-width: 900px; width: 100%;
  box-shadow: 0 10px 40px rgba(0,0,0,.2);
}
.mc-modal-topo {
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px 24px; border-bottom: 1px solid #eee;
}
.mc-modal-topo h3 { font-size: 16px; color: #333; }
.mc-modal-fechar { background: none; border: none; font-size: 22px; color: #999; cursor: pointer; line-height: 1; }
.mc-modal-body { padding: 22px 24px; }

.mc-timeline { display: flex; justify-content: space-between; margin-bottom: 20px; position: relative; padding: 10px 6px 0; }
.mc-timeline::before {
  content: ''; position: absolute; top: 32px; left: 6px; right: 6px; height: 4px; background: #eee; z-index: 0;
}
.mc-timeline-cancelada::before {
  background: linear-gradient(to right, #eee 0%, #eee 80%, #d0021b 80%, #d0021b 100%);
}
.mc-timeline-passo { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; flex: 1; }
.mc-timeline-bola {
  width: 30px; height: 30px; border-radius: 50%; background: transparent; color: #ccc;
  display: flex; align-items: center; justify-content: center; margin-bottom: 8px; font-size: 15px;
  padding: 6px; box-sizing: border-box; opacity: .55;
}
.mc-timeline-passo.ativo .mc-timeline-bola,
.mc-timeline-passo.cancelado .mc-timeline-bola {
  width: 40px; height: 40px; padding: 9px; background: #009edf; color: #fff; opacity: 1;
}
.mc-timeline-passo.cancelado .mc-timeline-bola { background: #d0021b; }
.mc-timeline-passo span { font-size: 11px; color: #999; text-align: center; max-width: 90px; }
.mc-timeline-passo.ativo span, .mc-timeline-passo.cancelado span { color: #333; font-weight: 700; }
.mc-timeline-passo small { font-size: 10px; color: #ccc; margin-top: 2px; }

@media (max-width: 480px) {
  .mc-timeline { padding: 4px 0 0; margin-bottom: 14px; }
  .mc-timeline::before { top: 18px; left: 0; right: 0; }
  .mc-timeline-bola { width: 22px; height: 22px; padding: 4px; margin-bottom: 5px; }
  .mc-timeline-passo.ativo .mc-timeline-bola,
  .mc-timeline-passo.cancelado .mc-timeline-bola { width: 28px; height: 28px; padding: 6px; }
  .mc-timeline-passo span { font-size: 8px; line-height: 1.15; max-width: 44px; }
  .mc-timeline-passo small { display: none; }
}

.mc-badge-pagamento { display: inline-block; font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 4px; }
.mc-badge-pagamento.cancelado { background: #fdeaea; color: #d0021b; }
.mc-badge-pagamento.aprovado { background: #e6f7e6; color: #2ab523; }
.mc-badge-pagamento.pendente { background: #fff8e1; color: #b8860b; }

.mc-detalhe-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 640px) { .mc-detalhe-grid { grid-template-columns: 1fr 1fr; } }
.mc-detalhe-card { border: 1px solid #eee; border-radius: 6px; overflow: hidden; }
.mc-detalhe-card-titulo { background: #f7f7f7; padding: 10px 14px; font-size: 13px; font-weight: 700; color: #555; }
.mc-detalhe-card-corpo { padding: 12px 14px; font-size: 13px; color: #444; line-height: 1.6; }

.mc-item-produto { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid #f1f1f1; }
.mc-item-produto:last-child { border-bottom: none; }
.mc-item-produto img { width: 52px; height: 52px; object-fit: contain; border-radius: 6px; border: 1px solid #eee; background: #fafafa; flex-shrink: 0; }
.mc-item-produto-placeholder { width: 52px; height: 52px; border-radius: 6px; border: 1px solid #eee; background: #fafafa; flex-shrink: 0; }
.mc-item-produto-info { flex: 1; font-size: 13px; color: #333; }
.mc-item-produto-info .qtd { color: #888; font-size: 12px; }
.mc-item-produto-preco { font-size: 13px; font-weight: 700; color: #333; white-space: nowrap; }

.mc-totais { margin-top: 4px; }
.mc-totais-linha { display: flex; justify-content: space-between; font-size: 13px; color: #666; padding: 5px 0; }
.mc-totais-linha.total { font-weight: 700; color: #333; font-size: 14px; border-top: 1px solid #eee; margin-top: 4px; padding-top: 10px; }
