/* ──────────────────────────────────────────────────────────────────
 * Brindemais — Login / Register (My Account) experience
 * Self-contained styling (no Tailwind build step in this theme), built
 * on the brand palette so it stays in sync with the rest of the site.
 * ────────────────────────────────────────────────────────────────── */

.bm-login {
  --bm-ink: #151142;
  --bm-indigo: #26206f;
  --bm-flame: #e8512e;
  --bm-flame-deep: #c23d1d;
  --bm-lav: #b2b0ff;
  --bm-lavpale: #ecebff;
  --bm-cream: #f7f3ec;
  --bm-creamsoft: #fbf7f0;
  --bm-line: rgba(21, 17, 66, 0.1);

  margin-left: auto;
  margin-right: auto;
  max-width: 1040px;
}

/* WooCommerce notices look at home inside the page shell. */
.bm-login .woocommerce-notices-wrapper:empty {
  display: none;
}

/* ── The split card ─────────────────────────────────────────────── */
.bm-login__card {
  display: grid;
  grid-template-columns: 1fr;
  overflow: hidden;
  border: 1px solid rgba(21, 17, 66, 0.08);
  border-radius: 1.75rem;
  background: #fff;
  box-shadow: 0 28px 70px rgba(21, 17, 66, 0.14);
}

@media (min-width: 900px) {
  .bm-login__card {
    grid-template-columns: 0.85fr 1.15fr;
  }
}

/* ── Brand / welcome panel ──────────────────────────────────────── */
.bm-login__aside {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.5rem;
  padding: 2.5rem;
  color: #fff;
  background:
    radial-gradient(120% 120% at 0% 0%, rgba(232, 81, 46, 0.35) 0%, rgba(232, 81, 46, 0) 45%),
    radial-gradient(140% 140% at 100% 100%, rgba(178, 176, 255, 0.4) 0%, rgba(178, 176, 255, 0) 50%),
    linear-gradient(150deg, var(--bm-ink) 0%, var(--bm-indigo) 100%);
  isolation: isolate;
}

@media (min-width: 900px) {
  .bm-login__aside {
    padding: 3rem;
  }
}

.bm-login__aside::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.5;
  z-index: -1;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 80%);
          mask-image: linear-gradient(180deg, #000 0%, transparent 80%);
}

.bm-login__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: -moz-fit-content;
  width: fit-content;
  padding: 0.4rem 0.85rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.bm-login__badge svg {
  width: 1rem;
  height: 1rem;
  color: var(--bm-lav);
}

.bm-login__aside h2 {
  margin: 0;
  font-size: clamp(1.7rem, 1.2rem + 1.5vw, 2.35rem);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.bm-login__aside p {
  margin: 0;
  max-width: 34ch;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.98rem;
  line-height: 1.6;
}

.bm-login__perks {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.bm-login__perks li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.92rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.92);
}

.bm-login__perks svg {
  flex: none;
  width: 1.5rem;
  height: 1.5rem;
  padding: 0.3rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--bm-lav);
}

/* ── Form side ──────────────────────────────────────────────────── */
.bm-login__main {
  padding: 2.25rem 1.75rem;
}

@media (min-width: 640px) {
  .bm-login__main {
    padding: 2.75rem 2.5rem;
  }
}

/* Tabs (CSS-only toggle between login / register) */
.bm-login__tabradio {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.bm-login__tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem;
  padding: 0.35rem;
  margin-bottom: 1.75rem;
  border-radius: 9999px;
  background: var(--bm-cream);
  border: 1px solid var(--bm-line);
}

.bm-login__tab {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1rem;
  border-radius: 9999px;
  font-size: 0.9rem;
  font-weight: 700;
  color: rgba(21, 17, 66, 0.55);
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.bm-login__tab:hover {
  color: var(--bm-ink);
}

#bm-tab-login:checked ~ .bm-login__tabs .bm-login__tab[for="bm-tab-login"],
#bm-tab-register:checked ~ .bm-login__tabs .bm-login__tab[for="bm-tab-register"] {
  color: #fff;
  background: var(--bm-ink);
  box-shadow: 0 8px 18px rgba(21, 17, 66, 0.22);
}

/* Single form (registration disabled): pane is always visible.
   When tabbed, the inactive pane is hidden and revealed via :checked. */
.bm-login__pane {
  display: block;
}

.bm-login__main--tabbed .bm-login__pane {
  display: none;
  animation: bm-login-fade 0.35s ease;
}

#bm-tab-login:checked ~ .bm-login__pane--login,
#bm-tab-register:checked ~ .bm-login__pane--register {
  display: block;
}

@keyframes bm-login-fade {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.bm-login__heading {
  margin: 0 0 0.4rem;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--bm-ink);
}

.bm-login__sub {
  margin: 0 0 1.75rem;
  font-size: 0.95rem;
  color: rgba(21, 17, 66, 0.6);
}

/* Form rows */
.bm-login .woocommerce-form__field,
.bm-login .woocommerce-form-row {
  margin: 0 0 1.1rem;
}

.bm-login label {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--bm-ink);
}

.bm-login .required {
  color: var(--bm-flame);
  border: 0;
}

.bm-login input[type="text"],
.bm-login input[type="email"],
.bm-login input[type="password"] {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(21, 17, 66, 0.15);
  border-radius: 0.85rem;
  background: var(--bm-creamsoft);
  font-size: 0.95rem;
  color: var(--bm-ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  -webkit-appearance: none;
          appearance: none;
}

.bm-login input::placeholder {
  color: rgba(21, 17, 66, 0.4);
}

.bm-login input[type="text"]:focus,
.bm-login input[type="email"]:focus,
.bm-login input[type="password"]:focus {
  outline: none;
  background: #fff;
  border-color: var(--bm-flame);
  box-shadow: 0 0 0 4px rgba(232, 81, 46, 0.14);
}

/* Password field with reveal toggle */
.bm-login__password {
  position: relative;
}

.bm-login__password input {
  padding-right: 3rem;
}

.bm-login__reveal {
  position: absolute;
  right: 0.6rem;
  bottom: 0.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 9999px;
  background: transparent;
  color: rgba(21, 17, 66, 0.5);
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.bm-login__reveal:hover {
  color: var(--bm-flame);
  background: rgba(232, 81, 46, 0.08);
}

.bm-login__reveal svg {
  width: 1.2rem;
  height: 1.2rem;
}

.bm-login__reveal .bm-login__eye-off {
  display: none;
}

.bm-login__reveal[aria-pressed="true"] .bm-login__eye {
  display: none;
}

.bm-login__reveal[aria-pressed="true"] .bm-login__eye-off {
  display: block;
}

/* Remember-me + lost password row */
.bm-login__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0.25rem 0 1.5rem;
}

.bm-login__remember {
  display: inline-flex !important;
  align-items: center;
  gap: 0.5rem;
  margin: 0 !important;
  font-size: 0.88rem;
  font-weight: 500 !important;
  color: rgba(21, 17, 66, 0.7);
  cursor: pointer;
}

.bm-login__remember input {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--bm-flame);
}

.bm-login__lost {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--bm-flame);
  text-decoration: none;
}

.bm-login__lost:hover {
  text-decoration: underline;
}

/* Submit button */
.bm-login button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.95rem 1.5rem;
  border: 0;
  border-radius: 9999px;
  background: var(--bm-flame);
  color: #fff;
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 14px 30px rgba(232, 81, 46, 0.28);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.bm-login button[type="submit"]:hover {
  background: var(--bm-flame-deep);
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(232, 81, 46, 0.34);
}

.bm-login button[type="submit"]:active {
  transform: translateY(0);
}

.bm-login__note {
  margin: 1.25rem 0 0;
  font-size: 0.82rem;
  line-height: 1.6;
  color: rgba(21, 17, 66, 0.55);
}

.bm-login__note a {
  color: var(--bm-flame);
  font-weight: 600;
  text-decoration: none;
}

.bm-login__note a:hover {
  text-decoration: underline;
}

/* Switch hint under a form ("Não tem conta? Criar") */
.bm-login__switch {
  margin: 1.5rem 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--bm-line);
  text-align: center;
  font-size: 0.9rem;
  color: rgba(21, 17, 66, 0.6);
}

.bm-login__switch label {
  display: inline;
  margin: 0;
  color: var(--bm-flame);
  font-weight: 700;
  cursor: pointer;
}

.bm-login__switch label:hover {
  text-decoration: underline;
}
