/* WooWeb Membership — frontend */

.ww-member-badge,
span.onsale.ww-member-badge {
  display: inline-block;
  background: #0f766e;
  color: #fff !important;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: none;
  padding: 0.4em 0.75em;
  border-radius: 6px;
  line-height: 1.25;
  min-height: 0;
  min-width: 0;
  z-index: 3;
  box-shadow: none;
}

span.onsale.ww-member-badge {
  position: absolute;
  top: 0.65rem;
  left: 0.65rem;
  right: auto;
  border-radius: 6px !important;
}

.ww-member-thumb {
  position: relative;
  display: block;
}

.ww-member-badge-wrap--loop {
  position: absolute;
  top: 0.65rem;
  left: 0.65rem;
  right: auto;
  z-index: 3;
  pointer-events: none;
}

.ww-member-badge-wrap--price {
  display: block;
  margin: 0 0 0.35em;
  position: static;
}

.ww-member-badge-wrap--single {
  margin: 0 0 0.75rem;
}

/* Hide WooCommerce Memberships oval badge — we use our own */
.wc-memberships-member-discount,
.woocommerce span.wc-memberships-member-discount,
ul.products li.product .wc-memberships-member-discount,
.wc-block-grid__product .wc-memberships-member-discount {
  display: none !important;
}

/* Precio miembro arriba, original tachado abajo (listado + ficha) */
.ww-member-price {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2em;
  line-height: 1.25;
}

.single-product .ww-member-price,
.single-product .woocommerce-variation-price .ww-member-price {
  align-items: flex-start;
}

.ww-member-price__current {
  font-weight: 700;
  display: block;
}

.ww-member-price__was {
  display: block;
  font-size: 0.78em;
  font-weight: 400;
  opacity: 0.65;
  line-height: 1.2;
}

.ww-member-price__was del {
  text-decoration: line-through;
}

.ww-member-price ins {
  text-decoration: none;
  font-weight: 700;
}

/* Product Collection / block grid cards */
.wc-block-grid__product,
.wc-block-product,
.wp-block-woocommerce-product-template .wc-block-product {
  position: relative;
}

.single-product .woocommerce-product-gallery {
  position: relative;
}

/* Mi cuenta — campos de marca */
.woocommerce-MyAccount-content .ww-account-fields {
  margin: 1.5rem 0 1rem;
  padding: 0;
  border: 0;
}

.woocommerce-MyAccount-content .ww-account-fields legend {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 0.75rem;
  padding: 0;
}

.woocommerce-MyAccount-content .ww-account-fields-grid {
  margin: 0;
  max-width: none;
}

.woocommerce-MyAccount-content .ww-account-fields-form {
  max-width: 720px;
}

/* Reto registration form (similar to registro de marca) */
.ww-reto-form {
  max-width: 720px;
  margin: 1.25rem 0 2rem;
}

.ww-reto-form__note {
  margin: 0 0 1rem;
  font-weight: 600;
}

.ww-reto-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem 1.25rem;
  margin-bottom: 0.85rem;
}

.ww-reto-form__row--full {
  grid-template-columns: 1fr;
}

.ww-reto-form__row--check {
  margin-top: 0.35rem;
}

.ww-reto-form label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 700;
  line-height: 1.3;
}

.ww-reto-form .required {
  color: #c00;
}

.ww-reto-form input[type="text"],
.ww-reto-form input[type="email"],
.ww-reto-form input[type="url"],
.ww-reto-form input[type="tel"],
.ww-reto-form input[type="password"] {
  width: 100%;
  max-width: none;
  box-sizing: border-box;
  padding: 0.55rem 0.7rem;
  border: 1px solid #cfcfcf;
  border-radius: 4px;
  background: #fff;
  font: inherit;
}

.ww-reto-form__check {
  display: flex !important;
  align-items: flex-start;
  gap: 0.5rem;
  font-weight: 600 !important;
  cursor: pointer;
}

.ww-reto-form__check input {
  margin-top: 0.2rem;
}

.ww-reto-form__flash {
  margin-bottom: 1rem;
}

.ww-reto-form__field-error {
  display: block;
  margin-top: 0.35rem;
  color: #b91c1c;
  font-size: 0.85rem;
  line-height: 1.3;
}

.ww-reto-form input.is-invalid,
.ww-reto-form input[aria-invalid="true"] {
  border-color: #b91c1c !important;
  box-shadow: 0 0 0 1px rgba(185, 28, 28, 0.15);
}

.ww-reto-form__check:has(input.is-invalid) {
  outline: 1px solid #b91c1c;
  outline-offset: 4px;
  border-radius: 4px;
}

.ww-reto-form__actions {
  margin-top: 1.25rem;
}

/* Don't override theme button colors — only ensure it can receive theme rules */
.ww-reto-form-wrap.woocommerce .ww-reto-form__actions .button,
.ww-reto-form__actions .woocommerce-button,
.ww-reto-form__actions .wp-element-button {
  display: inline-block;
  cursor: pointer;
  text-decoration: none;
}

@media (max-width: 600px) {
  .ww-reto-form__row {
    grid-template-columns: 1fr;
  }
}

/* Reto / membership status panel (no Woo notice icon — avoids overlap) */
.ww-reto-status {
  margin: 1rem 0 1.5rem;
  padding: 1rem 1.25rem;
  background: #f6f7f7;
  border: 1px solid #e2e4e7;
  border-left: 4px solid #0f766e;
  border-radius: 4px;
  position: relative;
}

.ww-reto-status::before,
.ww-reto-status::after {
  content: none !important;
  display: none !important;
}

.ww-reto-status__title {
  margin: 0 0 0.35rem;
  font-weight: 700;
  padding-left: 0;
}

.ww-reto-status__name {
  margin: 0 0 0.75rem;
}

.ww-reto-progress {
  height: 10px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 999px;
  overflow: hidden;
  margin: 0 0 0.65rem;
}

.ww-reto-progress__bar {
  height: 100%;
  background: #0f766e;
  border-radius: 999px;
  transition: width 0.35s ease;
}

.ww-reto-status[data-status="won"] .ww-reto-progress__bar {
  background: #15803d;
}

.ww-reto-status[data-status="lost"] .ww-reto-progress__bar {
  background: #78716c;
}

.ww-reto-status__meta,
.ww-reto-status__dates,
.ww-reto-status__link {
  margin: 0.25rem 0 0;
  font-size: 0.95em;
}

.ww-reto-account-page .ww-reto-status {
  margin-bottom: 1.25rem;
}

/* My Account — membership card (single panel, no stacked alerts) */
.ww-membership-card {
  margin: 1rem 0 1.5rem;
  padding: 1.15rem 1.25rem 1.25rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

.ww-membership-card__eyebrow {
  margin: 0 0 0.25rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #0f766e;
}

.ww-membership-card--expired .ww-membership-card__eyebrow,
.ww-membership-card--renew .ww-membership-card__eyebrow {
  color: #9a3412;
}

.ww-membership-card--grace .ww-membership-card__eyebrow {
  color: #a16207;
}

.ww-membership-card__title {
  margin: 0 0 0.85rem;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
}

.ww-membership-card__dates {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.65rem 1.25rem;
  margin: 0;
}

.ww-membership-card__dates div {
  margin: 0;
}

.ww-membership-card__dates dt {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.ww-membership-card__dates dd {
  margin: 0.15rem 0 0;
  font-weight: 600;
  color: #0f172a;
}

.ww-membership-card__action {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}

.ww-membership-card__action p {
  margin: 0;
  flex: 1 1 220px;
  font-size: 0.95em;
  color: #475569;
  line-height: 1.4;
}

.ww-membership-card--expired .ww-membership-card__action p,
.ww-membership-card--renew .ww-membership-card__action p {
  color: #9a3412;
}

.ww-membership-card--grace .ww-membership-card__action p {
  color: #854d0e;
}

.ww-membership-card__btn {
  margin: 0 !important;
  flex: 0 0 auto;
}

.ww-membership-card--expired {
  background: #fffaf7;
  border-color: #fed7aa;
}

.ww-membership-card--renew {
  background: #fffbeb;
  border-color: #fde68a;
}

.ww-membership-card--grace {
  background: #fffbeb;
  border-color: #fcd34d;
}

.ww-membership-assign-list {
  margin: 0.5rem 0 0;
  padding-left: 1.15em;
  color: #475569;
}

.ww-membership-assign-list li {
  margin: 0.35rem 0;
}

/* Site-wide renewal banner (overdue subscription) */
.ww-membership-site-banner {
  position: relative;
  z-index: 99990;
  background: #9a3412;
  color: #fff;
  font-size: 0.95rem;
  line-height: 1.4;
}

.ww-membership-site-banner__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.65rem 1.25rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.7rem 1rem;
}

.ww-membership-site-banner__text {
  margin: 0;
  flex: 1 1 240px;
  text-align: center;
}

.ww-membership-site-banner__btn {
  flex: 0 0 auto;
  display: inline-block;
  padding: 0.45rem 0.95rem;
  border-radius: 6px;
  background: #fff;
  color: #9a3412 !important;
  font-weight: 700;
  text-decoration: none !important;
  line-height: 1.2;
}

.ww-membership-site-banner__btn:hover,
.ww-membership-site-banner__btn:focus {
  background: #fff7ed;
  color: #7c2d12 !important;
}

.ww-membership-site-banner--fallback {
  position: sticky;
  top: 0;
}

