html:not(.auth-authorized) body > :not(#dwr-auth-root) {
  display: none !important;
}

html.auth-authorized #dwr-auth-root {
  display: none !important;
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: grid;
  place-items: center;
  min-height: 100dvh;
  overflow: auto;
  padding: 28px 18px;
  background: #13251c;
  color: #17291f;
}

.auth-backdrop {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(12, 35, 24, .94), rgba(18, 53, 37, .79)),
    url("assets/ranch-hero.jpg") center / cover no-repeat;
}

.auth-card {
  position: relative;
  width: min(100%, 470px);
  border: 1px solid rgba(255, 255, 255, .58);
  border-radius: 26px;
  padding: clamp(26px, 6vw, 42px);
  background: rgba(255, 255, 255, .97);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .32);
}

.auth-brand {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  margin-bottom: 20px;
  border-radius: 18px;
  background: #17291f;
  color: #fff;
  font-size: 28px;
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .15);
}

.auth-test-badge {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  background: #fff0c7;
  color: #6f4c00;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
}

.auth-card h1 {
  margin: 16px 0 10px;
  font-size: clamp(28px, 7vw, 38px);
  line-height: 1.08;
  letter-spacing: -.035em;
}

.auth-intro,
.auth-footnote,
.auth-status {
  margin: 0;
  color: #56645c;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.55;
}

.auth-form {
  margin: 26px 0 16px;
}

.auth-form fieldset {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
}

.auth-form label {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.auth-form input {
  width: 100%;
  min-height: 52px;
  border: 1px solid #bdc9c1;
  border-radius: 13px;
  padding: 0 15px;
  background: #fff;
  color: #17291f;
  font: inherit;
  font-weight: 700;
}

.auth-form input:focus {
  border-color: #087f70;
  outline: 3px solid rgba(8, 127, 112, .16);
}

.auth-form button {
  min-height: 52px;
  border: 0;
  border-radius: 13px;
  padding: 0 18px;
  background: #087f70;
  color: #fff;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.auth-form button:disabled,
.auth-form fieldset:disabled button {
  cursor: wait;
  opacity: .62;
}

.auth-status {
  min-height: 23px;
  color: #087f70;
}

.auth-status[data-tone="error"] {
  color: #a12626;
}

.auth-status[data-tone="success"] {
  color: #05675c;
}

.auth-footnote {
  margin-top: 18px;
  border-top: 1px solid #e1e6e2;
  padding-top: 18px;
  font-size: 12px;
}

.auth-sign-out {
  margin-top: 10px;
}

@media (max-width: 760px) {
  .auth-gate { align-items: end; padding: 12px; }
  .auth-card { border-radius: 24px 24px 18px 18px; }
}

