/* ═══════════════════════════════════════════════════════════
   sirlo-auth.css
   Login + Register combined page
   Base: 1rem = 10px  (html { font-size: 62.5%; })
   ═══════════════════════════════════════════════════════════ */

/* ── Layout: split screen ──────────────────────── */
.sirlo-login {
  display: flex;
  min-height: 100vh;
  min-height: 100dvh;
}

.sirlo-login__left-block {
  flex: 1 1 50%;
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  padding: 4.8rem 2.4rem;
  background-color: #fff;
  overflow-y: auto;
}

.sirlo-login__left-block--inner {
  width: 100%;
  max-width: 48rem; /* 480px */
  border-radius: 1rem;
  border: 1px solid var(--border);
  background-color: var(--card);
  padding: 2.4rem;
  box-shadow: 0 4px 20px -4px hsl(152 55% 30% / 0.15);
}

.sirlo-login__right-block {
  flex: 1 1 50%;
  position: relative;
  overflow: hidden;
  display: none;
}

.sirlo-login__right-block img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (min-width: 900px) {
  .sirlo-login__right-block {
    display: block;
  }
}

/* ── Tabs ──────────────────────────────────────── */
.sirlo-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: #f4f4f5; /* zinc-100 */
  border-radius: 0.8rem;
  padding: 0.4rem;
  margin-bottom: 2.4rem;
}

.sirlo-tabs__trigger {
  all: unset;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 3.6rem;
  font-size: 1.4rem;
  font-weight: 500;
  color: #71717a; /* zinc-500 */
  border-radius: 0.6rem;
  cursor: pointer;
  transition:
    color 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
  box-sizing: border-box;
}

.sirlo-tabs__trigger:hover {
  color: #333;
}

.sirlo-tabs__trigger.is-active {
  background: #fff;
  color: #111;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* ── Tab panels ────────────────────────────────── */
.sirlo-tab-panel {
  display: none;
}

.sirlo-tab-panel.is-active {
  display: block;
}

/* ── Auth form shared ──────────────────────────── */
.sirlo-auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

/* ── Single field ──────────────────────────────── */
.sirlo-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin: 0;
}

.sirlo-field__label {
  font-size: 1.4rem;
  font-weight: 500;
  color: #333;
  line-height: 1.4;
}

.sirlo-field__optional {
  font-weight: 400;
  color: #999;
}

/* ── Inputs & selects ──────────────────────────── */
.sirlo-field__input,
.sirlo-field__select {
  height: 4.4rem;
  padding: 0 1.2rem;
  border: 1px solid #d4d4d8;
  border-radius: 0.6rem;
  font-size: 1.4rem;
  color: #111;
  background: #fff;
  outline: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
  width: 100%;
  box-sizing: border-box;
}

.sirlo-field__input::placeholder {
  color: #a1a1aa;
}

.sirlo-field__input:focus,
.sirlo-field__select:focus {
  border-color: #3b9b6b;
  box-shadow: 0 0 0 3px rgba(59, 155, 107, 0.15);
}

/* ── Select wrapper ────────────────────────────── */
.sirlo-select-wrap {
  position: relative;
  display: block;
}

.sirlo-select-wrap .sirlo-field__select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 3.6rem;
  cursor: pointer;
}

.sirlo-select-wrap::after {
  content: "";
  position: absolute;
  right: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 0.5rem solid transparent;
  border-right: 0.5rem solid transparent;
  border-top: 0.5rem solid #71717a;
  pointer-events: none;
}

/* ── Phone group ───────────────────────────────── */
.sirlo-phone-group {
  display: flex;
  gap: 0.8rem;
  align-items: center;
}

.sirlo-phone-group__prefix {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 4.4rem;
  padding: 0 1.2rem;
  border: 1px solid #d4d4d8;
  border-radius: 0.6rem;
  background: #f4f4f5;
  font-size: 1.4rem;
  color: #71717a;
  white-space: nowrap;
  flex-shrink: 0;
}

.sirlo-phone-group .sirlo-field__input {
  flex: 1;
}

/* ── Two-column row ────────────────────────────── */
.sirlo-field-row--half {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}

/* ── Add this to the bottom of your sirlo-auth.css ──────── */

/* ── Input error state (client-side validation) ──── */
.sirlo-field__input--error,
.sirlo-field__input--error:focus {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

/* ── Toastify overrides (rem base = 10px) ──────── */
.toastify {
  font-family: inherit;
}

@media (max-width: 480px) {
  .sirlo-field-row--half {
    grid-template-columns: 1fr;
  }
}

/* ── Password wrapper ──────────────────────────── */
.sirlo-password-wrap {
  position: relative;
  display: block;
}

.sirlo-password-wrap .sirlo-field__input {
  padding-right: 4.2rem;
}

.sirlo-password-toggle {
  position: absolute;
  right: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: #a1a1aa;
  transition: color 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sirlo-password-toggle:hover {
  color: #333;
}

.sirlo-icon {
  display: block;
  width: 1.6rem;
  height: 1.6rem;
}

/* ── Submit button ─────────────────────────────── */
.sirlo-field--submit {
  margin-top: 0.8rem;
}

.sirlo-btn--primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  width: 100%;
  height: 4.4rem;
  border: none;
  border-radius: 0.6rem;
  font-size: 1.5rem;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  transition:
    opacity 0.15s ease,
    transform 0.1s ease;
  background: linear-gradient(135deg, #3b9b6b 0%, #2d7d56 100%);
}

.sirlo-btn--primary:hover {
  opacity: 0.92;
}

.sirlo-btn--primary:active {
  transform: scale(0.985);
}

.sirlo-btn--primary svg {
  width: 1.6rem;
  height: 1.6rem;
  flex-shrink: 0;
}

/* ── Lost password link ────────────────────────── */
.sirlo-lost-pw {
  text-align: center;
}

.sirlo-lost-pw a {
  font-size: 1.3rem;
  color: #71717a;
  text-decoration: none;
}

.sirlo-lost-pw a:hover {
  color: #3b9b6b;
  text-decoration: underline;
}

/* ── Privacy checkbox (WooCommerce hook) ───────── */
.sirlo-auth-form .privacy {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  font-size: 1.3rem;
  color: #555;
  line-height: 1.5;
}

.sirlo-auth-form .privacy input[type="checkbox"] {
  margin-top: 0.3rem;
  width: 1.6rem;
  height: 1.6rem;
  accent-color: #3b9b6b;
}

.sirlo-auth-form .privacy a {
  color: #3b9b6b;
  text-decoration: underline;
}

/* ── WooCommerce notices ───────────────────────── */
.woocommerce-error,
.woocommerce-message,
.woocommerce-info {
  font-size: 1.4rem;
  border-radius: 0.6rem;
  padding: 1.2rem 1.6rem;
  margin-bottom: 2rem;
  list-style: none;
}

.woocommerce-error {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

/* ── Bottom links (hook output) ────────────────── */
.bb-register-login {
  text-align: center;
  font-size: 1.4rem;
  color: #71717a;
  margin-top: 2rem;
}

.bb-register-login a {
  color: #3b9b6b;
  font-weight: 500;
  text-decoration: none;
}

.bb-register-login a:hover {
  text-decoration: underline;
}
