:root{
    --panel-width: 300px;       /* width when open */
    --handle-size: 50px;        /* visible circle when collapsed */
    --radius: 5px;
    --bg: #9C3D3F;
    --text: #fff;
    --muted: #64748b;
    --accent: #666666;          /* brand color for the handle + CTA */
    --shadow: 0 10px 20px rgba(0,0,0,.12), 0 3px 6px rgba(0,0,0,.08);
  }

  /* Root widget */
  .floating-login{
    position: fixed;
    top: 65px;           /* requested offset */
    right: 0;
    width: var(--panel-width);
    transform: translateX(calc(90% - var(--handle-size)));
    transition: transform .28s cubic-bezier(.2,.7,.2,1);
    z-index: 9999;
    -webkit-tap-highlight-color: transparent;
  }
  /* Open states: hover (for pointer/keyboard), focus, and data attribute */
  @media (hover: hover){
    .floating-login:hover { transform: translateX(0); }
  }
  .floating-login:focus-within,
  .floating-login[data-open="true"]{
    transform: translateX(0);
  }
  @media (prefers-reduced-motion: reduce){
    .floating-login{ transition: none; }
  }
  
    @media (max-width: 768px), (hover: none) and (pointer: coarse){
    .floating-login{ display: none !important; }
  }

  /* Panel shell */
  .login-shell{
    position: relative;
    display: flex;
    align-items: center;
    gap: .5rem;
    width: 100%;
    height: var(--handle-size);
    padding-left: .95rem;
    padding-right: calc(var(--handle-size) + .25rem); /* space for the handle */
    background: var(--bg);
    color: var(--text);
    border-radius: var(--radius) 0 0 var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid rgba(15,23,42,.06);
  }

  /* The round “lock” handle that stays visible */
  .login-handle{
    position: absolute;
    inset: 0 0 0 auto; /* stick to the right */
    width: var(--handle-size);
    height: var(--handle-size);
    margin: 0;
    border: none;
    border-radius: var(--radius);
    background: var(--accent);
    color: #fff;
    display: grid;
    place-items: center;
    cursor: pointer;
    box-shadow: var(--shadow);
  }
  .login-handle:focus-visible{
    outline: 3px solid #93c5fd;
    outline-offset: 2px;
  }

  /* Text shown when expanded */
  .login-label{
    font: 600 1.5rem/1 'Raleway', Arial, sans-serif;
    white-space: nowrap;
    opacity: .9;
  }
  .login-hint{
    font: 500 .8rem/1.1 'Raleway', Arial, sans-serif;
    color: var(--muted);
    display: none;
  }
  @media (min-width: 480px){
    .login-hint{ display: inline; }
  }

  /* The actual Login CTA inside the drawer */
  .login-cta {
    margin-left: auto;
    margin-right: -30px;
    height: 36px;
    padding: 0 10px;
    border-radius: 5px;
    border: 1px solid transparent;
    background: var(--accent);
    color: #fff;
    font: 600 1.5rem/36px 'Raleway', Arial, sans-serif;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(37,99,235,.25);
  }
  .login-cta:focus-visible{
    outline: 3px solid #93c5fd;
    outline-offset: 2px;
  }
  .login-cta:active{
    transform: translateY(1px);
  }
