/* ===== Checkout isolado – layout escuro, compacto e responsivo ===== */

/* Garante que tudo dentro do checkout respeite o box-sizing */
body.woocommerce-checkout .wc-block-checkout,
body.woocommerce-checkout .wc-block-checkout * {
  box-sizing: border-box;
}

/* Fundo geral */
body.woocommerce-checkout {
  background: radial-gradient(circle at top, #111827 0, #020617 55%, #000 100%);
  color: #e5e7eb;
}

/* Some título padrão da página */
body.woocommerce-checkout .entry-header {
  display: none;
}

/* Área principal */
body.woocommerce-checkout #primary.site-main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 16px 10px 32px;
}

/* Card principal (bloco checkout) */
body.woocommerce-checkout .entry-content > .wp-block-woocommerce-checkout.wc-block-checkout {
  background: rgba(15, 23, 42, 0.96);
  border-radius: 20px;
  padding: 18px 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.35);
}

/* ========== LAYOUT RESPONSIVO ========== */

/* MOBILE até 480px – tudo mais compacto */
@media (max-width: 480px) {
  body.woocommerce-checkout #primary.site-main {
    padding: 10px 8px 24px;
  }

  body.woocommerce-checkout .entry-content > .wp-block-woocommerce-checkout.wc-block-checkout {
    padding: 14px 10px;
    border-radius: 16px;
  }

  /* Checkout em coluna única, sem grid apertado */
  body.woocommerce-checkout .wp-block-woocommerce-checkout.wc-block-checkout {
    display: block;
  }

  /* Seções um pouco mais compactas */
  body.woocommerce-checkout .wc-block-components-checkout-step,
  body.woocommerce-checkout .wc-block-components-panel {
    padding: 10px 10px 12px;
    margin-bottom: 10px;
  }

  /* Fonte um pouco menor em geral */
  body.woocommerce-checkout .wc-block-checkout p,
  body.woocommerce-checkout .wc-block-checkout span,
  body.woocommerce-checkout .wc-block-checkout label,
  body.woocommerce-checkout .wc-block-checkout li,
  body.woocommerce-checkout .wc-block-checkout small {
    font-size: 0.85rem;
  }

  /* Botões ocupando largura total em mobile */
  body.woocommerce-checkout .wc-block-checkout button,
  body.woocommerce-checkout .wc-block-checkout .wc-block-components-button {
    width: 100%;
    justify-content: center;
  }

  /* Resumo do pedido: evita esmagar texto e imagens */
  body.woocommerce-checkout .wc-block-components-order-summary-item__image img {
    max-width: 48px;
    height: auto;
  }
}

/* TABLET: 481px a 899px – tudo em coluna, mas com respiro */
@media (min-width: 481px) and (max-width: 899px) {
  body.woocommerce-checkout .wp-block-woocommerce-checkout.wc-block-checkout {
    display: block;
  }

  body.woocommerce-checkout .entry-content > .wp-block-woocommerce-checkout.wc-block-checkout {
    padding: 20px 18px;
  }

  body.woocommerce-checkout .wc-block-components-checkout-step,
  body.woocommerce-checkout .wc-block-components-panel {
    padding: 12px 12px 14px;
    margin-bottom: 12px;
  }

  body.woocommerce-checkout .wc-block-checkout p,
  body.woocommerce-checkout .wc-block-checkout span,
  body.woocommerce-checkout .wc-block-checkout label,
  body.woocommerce-checkout .wc-block-checkout li,
  body.woocommerce-checkout .wc-block-checkout small {
    font-size: 0.9rem;
  }

  body.woocommerce-checkout .wc-block-checkout button,
  body.woocommerce-checkout .wc-block-checkout .wc-block-components-button {
    width: auto;
    min-width: 180px;
  }
}

/* DESKTOP – duas colunas: dados | resumo */
@media (min-width: 1200px) {
  body.woocommerce-checkout .entry-content > .wp-block-woocommerce-checkout.wc-block-checkout {
    padding: 26px 24px;
  }

  body.woocommerce-checkout .wp-block-woocommerce-checkout.wc-block-checkout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.25fr);
    gap: 22px;
    align-items: flex-start;
  }

  /* Garante que o conteúdo principal e sidebar se comportem bem no grid */
  body.woocommerce-checkout .wc-block-checkout .wc-block-components-main,
  body.woocommerce-checkout .wc-block-checkout .wc-block-components-sidebar {
    gap: 25px;
  }
}

/* ========== TIPOGRAFIA ========== */

body.woocommerce-checkout .wc-block-checkout h1,
body.woocommerce-checkout .wc-block-checkout h2,
body.woocommerce-checkout .wc-block-checkout h3,
body.woocommerce-checkout .wc-block-checkout h4,
body.woocommerce-checkout .wc-block-checkout h5,
body.woocommerce-checkout .wc-block-checkout h6 {
  color: #f9fafb;
  margin-top: 0;
  margin-bottom: 10px;
  font-weight: 600;
}

body.woocommerce-checkout .wc-block-checkout p,
body.woocommerce-checkout .wc-block-checkout span,
body.woocommerce-checkout .wc-block-checkout label,
body.woocommerce-checkout .wc-block-checkout li,
body.woocommerce-checkout .wc-block-checkout small {
  color: #e5e7eb;
  font-size: 0.9rem;
}

/* Títulos das seções */
body.woocommerce-checkout .wc-block-components-checkout-step__title,
body.woocommerce-checkout .wc-block-components-title {
  font-size: 0.96rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #f9fafb;
}

/* ========== BLOCOS / SEÇÕES ========== */

body.woocommerce-checkout .wc-block-components-checkout-step,
body.woocommerce-checkout .wc-block-components-panel {
  background: rgba(15, 23, 42, 0.88);
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  padding: 14px 14px 16px;
  margin-bottom: 14px;
}

/* Resumo do pedido */
body.woocommerce-checkout .wp-block-woocommerce-checkout-totals-block,
body.woocommerce-checkout .wc-block-components-order-summary {
  background: rgba(15, 23, 42, 0.9);
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  padding: 14px 14px 10px;
}

body.woocommerce-checkout .wc-block-components-order-summary-item__description,
body.woocommerce-checkout .wc-block-components-order-summary-item__total {
  color: #e5e7eb;
  font-size: 0.88rem;
}

/* Linhas de totais */
body.woocommerce-checkout .wc-block-components-totals-item__label,
body.woocommerce-checkout .wc-block-components-totals-item__value {
  color: #f9fafb;
  font-weight: 600;
}

/* ========== CAMPOS ========== */

body.woocommerce-checkout .wc-block-checkout input[type="text"],
body.woocommerce-checkout .wc-block-checkout input[type="tel"],
body.woocommerce-checkout .wc-block-checkout input[type="email"],
body.woocommerce-checkout .wc-block-checkout input[type="password"],
body.woocommerce-checkout .wc-block-checkout input[type="number"],
body.woocommerce-checkout .wc-block-checkout select,
body.woocommerce-checkout .wc-block-checkout textarea {
  background: #020617;
  border: 1px solid #4b5563;
  border-radius: 8px;
  padding: 8px 10px;
  color: #f9fafb;
  font-size: 0.9rem;
  width: 100%;
  box-shadow: none;
}

body.woocommerce-checkout .wc-block-checkout input::placeholder,
body.woocommerce-checkout .wc-block-checkout textarea::placeholder {
  color: #6b7280;
}

body.woocommerce-checkout .wc-block-checkout input:focus,
body.woocommerce-checkout .wc-block-checkout select:focus,
body.woocommerce-checkout .wc-block-checkout textarea:focus {
  outline: 2px solid #38bdf8;
  outline-offset: 1px;
  border-color: #38bdf8;
}

/* Checkboxes / radio */
body.woocommerce-checkout .wc-block-checkout input[type="checkbox"],
body.woocommerce-checkout .wc-block-checkout input[type="radio"] {
  accent-color: #22c55e;
}

/* ========== BOTÕES E LINKS ========== */

body.woocommerce-checkout .wc-block-checkout button,
body.woocommerce-checkout .wc-block-checkout .wc-block-components-button {
  background: linear-gradient(135deg, #22c55e, #4ade80);
  color: #022c22;
  border-radius: 999px;
  border: none;
  padding: 10px 18px;
  font-weight: 600;
  font-size: 0.94rem;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(34, 197, 94, 0.35);
  transition: transform 0.08s ease, box-shadow 0.12s ease, filter 0.12s ease;
}

body.woocommerce-checkout .wc-block-checkout button:hover,
body.woocommerce-checkout .wc-block-checkout .wc-block-components-button:hover {
  filter: brightness(1.05);
  box-shadow: 0 10px 26px rgba(34, 197, 94, 0.45);
  transform: translateY(-1px);
}

body.woocommerce-checkout .wc-block-checkout button:disabled,
body.woocommerce-checkout .wc-block-checkout .wc-block-components-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

body.woocommerce-checkout .wc-block-checkout a {
  color: #38bdf8;
}

body.woocommerce-checkout .wc-block-checkout a:hover {
  text-decoration: underline;
}

/* ========== AVISOS ========== */

body.woocommerce-checkout .wc-block-components-notice-banner,
body.woocommerce-checkout .woocommerce-error,
body.woocommerce-checkout .woocommerce-message,
body.woocommerce-checkout .woocommerce-info {
  border-radius: 10px;
  margin-bottom: 16px;
}

/* ===== Ajuste resumo do pedido – manter preço alinhado e dentro do card ===== */

/* Cada item do resumo em flex, com wrap e espaçamento */
body.woocommerce-checkout .wc-block-components-order-summary-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;           /* deixa quebrar linha no mobile */
}

/* Descrição ocupa o espaço flexível, sem empurrar pra fora */
body.woocommerce-checkout .wc-block-components-order-summary-item__description {
  flex: 1 1 auto;
  min-width: 0;              /* evita “esticar” demais e cortar o preço */
}

/* Preço sempre grudado à direita, sem sair do card */
body.woocommerce-checkout .wc-block-components-order-summary-item__total {
  flex: 0 0 auto;
  white-space: nowrap;       /* mantém valor em uma linha só */
  text-align: right;
  font-weight: 600;
}

/* Telas bem pequenas: diminui fonte do preço pra não estourar */
@media (max-width: 480px) {
  body.woocommerce-checkout .wc-block-components-order-summary-item__total {
    font-size: 0.85rem;
  }
}


/* 1) Esconde o preço unitário da linha (deixa só o total à direita) */
.wc-block-components-order-summary-item__individual-prices {
  display: none !important;
}

/* 2) Garante que textos apenas de acessibilidade fiquem invisíveis visualmente */
.wc-block-components-visually-hidden,
.screen-reader-text {
  border: 0 !important;
  clip: rect(1px, 1px, 1px, 1px) !important;
  clip-path: inset(50%) !important;
  height: 1px !important;
  margin: -1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  width: 1px !important;
  white-space: nowrap !important;
}

