/* White Rabbit Vault — visual-only Vaultwarden theme. Load AFTER the stock CSS. */
:root { --wr-ink:#0a101d; --wr-panel:rgba(9,15,29,.92); --wr-gold:#d6a85b; --wr-cream:#f9f0e2; }
/* Background on the unauthenticated layout only. No application logic modified. */
body.layout_frontend { color:var(--wr-cream); background:#050811 url('/images/login-background-1920x1080.webp') center center / cover fixed no-repeat !important; }
body.layout_frontend app-root { position:relative; isolation:isolate; }
/* Overlay improves text readability without altering click handling. */
body.layout_frontend app-root::before { content:''; position:fixed; inset:0; z-index:-1; pointer-events:none; background:linear-gradient(90deg,rgba(3,6,14,.50),rgba(4,7,17,.2) 65%,rgba(3,6,14,.18)); }
/* Remove only decorative corner illustrations from the login landing page. */
body.layout_frontend app-root .tw-fill-illustration-bg-primary,
body.layout_frontend app-root .tw-fill-illustration-bg-secondary,
body.layout_frontend app-root .tw-fill-illustration-bg-tertiary,
body.layout_frontend app-root .tw-fill-illustration-outline,
body.layout_frontend app-root .tw-fill-illustration-logo { opacity:0!important; }
/* Stock logo is an img without src in the user-supplied shell and may be assigned dynamically. */
body.layout_frontend img.new-logo-themed { box-sizing:border-box!important; width:300px!important; max-width:min(300px,70vw)!important; height:100px!important; padding-left:300px!important; background:url('/images/white-rabbit-vault-wordmark.webp') no-repeat left center / contain!important; object-fit:contain; }
/* Login panel: target common stock card and Tailwind utility surfaces. */
body.layout_frontend .card, body.layout_frontend .tw-bg-background, body.layout_frontend .tw-bg-card { background:var(--wr-panel)!important; border:1px solid rgba(220,172,94,.32)!important; border-radius:16px!important; box-shadow:0 18px 65px rgba(0,0,0,.48)!important; backdrop-filter:blur(14px); }
body.layout_frontend h1,body.layout_frontend h2,body.layout_frontend h3,body.layout_frontend label { color:var(--wr-cream)!important; }
body.layout_frontend input:not([type=checkbox]),body.layout_frontend select { background:rgba(25,35,54,.96)!important; border:1px solid rgba(230,187,119,.40)!important; color:#fff9f0!important; border-radius:9px!important; }
body.layout_frontend input::placeholder { color:#bbb4aa!important; }
body.layout_frontend input:focus-visible,body.layout_frontend button:focus-visible,body.layout_frontend a:focus-visible { outline:2px solid #f1cb81!important; outline-offset:2px; }
body.layout_frontend button[type=submit],body.layout_frontend .btn-primary { background:linear-gradient(110deg,#f2cb81,#cf973e)!important; color:#171108!important; border:1px solid #d3a359!important; font-weight:650!important; }
body.layout_frontend a { color:#f1ca83!important; }
body.layout_frontend button[type=submit]:hover,body.layout_frontend .btn-primary:hover { filter:brightness(1.09); }
@media(max-width:768px) { body.layout_frontend { background-position:57% center!important;background-attachment:scroll!important; } body.layout_frontend .card {background:rgba(8,14,27,.96)!important;} }
@media(prefers-reduced-motion:reduce) {body.layout_frontend *,body.layout_frontend *::before,body.layout_frontend *::after {animation:none!important; transition:none!important;} }

/* ---- adapters for the Vaultwarden web 2026.7 build (added 2026-10-19) ----
   The theme was authored against a different DOM. These rules make the
   authored look apply to the shell this server actually serves. Remove this
   block wholesale if a future build matches the original selectors again. */
/* 1. Page surface: this build paints with .tw-bg-background-alt, not .tw-bg-background. */
html:has(body.layout_frontend) { background:#050811 !important; }
body.layout_frontend .tw-bg-background-alt { background:transparent !important; }
/* 2. Logo: inline <svg> inside a fixed-size box, not img.new-logo-themed. */
body.layout_frontend div.tw-content-center.tw-size-20 {
  width:300px !important; max-width:min(300px,70vw) !important; height:100px !important;
  margin-inline:auto !important;
  background:url('/images/white-rabbit-vault-wordmark.webp') no-repeat center / contain !important;
}
body.layout_frontend div.tw-content-center.tw-size-20 svg { display:none !important; }
/* 3. Primary button: type="button" with a test id, so button[type=submit] never matched. */
body.layout_frontend button[data-testid="login-continue-button"] {
  background:linear-gradient(110deg,#f2cb81,#cf973e) !important;
  color:#171108 !important; border:1px solid #d3a359 !important; font-weight:650 !important;
}
/* 4. "Remember email" is a bit-label inside .tw-text-fg-heading, not a <label>. */
body.layout_frontend .tw-text-fg-heading,
body.layout_frontend bit-label { color:var(--wr-cream) !important; }
/* 5. Top-left marketing logo is an inline <svg> (.tw-fill-marketing-logo), not an <img>. */
body.layout_frontend .tw-fill-marketing-logo { display:none !important; }
body.layout_frontend bit-svg:has(.tw-fill-marketing-logo) { display:none !important; }
