/* ============================================================
   foxlink-sso.css — the Foxlink SSO sign-in button, and nothing
   else. Page-scoped (loaded via login.blade.php's
   @section('pagecss')).

   This is a 1:1 rebuild of the corporate spec at
   https://ssot.foxlink.com.tw/sso-button, so that an employee meets
   the same button here as in every other Foxlink system. It is the
   outline variant — the solid blue one is only for systems where SSO
   is the one way in, and this page also takes a password.

   The values below are literal on purpose. They do NOT come from
   custom.css or from --brand: #0078C0 is the SSO mark's blue, not
   this product's, and the two must not be folded together. Colour,
   type size, weight and spacing are fixed by the spec and are not
   ours to adjust.

   The spec allows three heights and no others — 40 compact / 48
   standard / 56 mobile, each with its own type and mark size. This
   page uses 40, stepping up to 48 on phones where a 40px tap target
   is on the small side.

   The button keeps its place at the bottom of the form. The spec asks
   for it above the other login methods; here SSO is the other login
   method — employee number and password is how people sign in — so it
   stays where it is. That is the only deviation; nothing about the
   button itself departs from the spec.
   ============================================================ */

.foxlink-sso-btn{
  display:flex; align-items:center; justify-content:center; gap:10px;
  width:100%;                 /* spec: inside a form, full width, contents centred */
  height:40px; padding:0 22px;              /* compact tier */
  border:1px solid #D2D9DF; border-left:3px solid #0078C0; border-radius:4px;
  background:#FFFFFF; color:#16202B; font-size:14px; text-decoration:none;
  transition:background 140ms ease, border-color 140ms ease;
}
.foxlink-sso-btn img{ flex:0 0 auto; width:20px; height:20px; }
.foxlink-sso-btn .brand{ font-weight:700; color:#16202B; }
.foxlink-sso-btn .action{ font-weight:500; color:#4C5A67; }

/* the border-color shorthand would take the left marker bar with it,
   so every state restates border-left-color — the spec calls this out
   as the usual way to get this button wrong. */
.foxlink-sso-btn:hover{
  background:#F7FAFC; border-color:#0078C0; border-left-color:#0078C0; color:#16202B;
}
.foxlink-sso-btn:active{
  background:#EDF3F8; border-color:#005285; border-left-color:#005285;
}
.foxlink-sso-btn:focus-visible{
  outline:3px solid rgba(0,120,192,.3); outline-offset:2px;
}

/* loading: the mark swaps for an 18px spinner, the action word becomes
   "signing in", and the link stops taking clicks so the authorize
   redirect cannot fire twice. */
.foxlink-sso-btn.is-loading{
  background:#FFFFFF; border-color:#D2D9DF; border-left-color:#0078C0;
  pointer-events:none;
}
.foxlink-sso-btn.is-loading .action{ color:#6B7885; }
.foxlink-sso-spinner{
  flex:0 0 auto; width:18px; height:18px; border-radius:50%;
  border:2px solid #DCE3E8; border-top-color:#0078C0;
  animation:foxlink-sso-spin .7s linear infinite;
}
@keyframes foxlink-sso-spin{ to{ transform:rotate(360deg); } }

@media (max-width:575.98px){
  /* spec size tier: step up to the 48px standard on phones —
     15px type, 22px mark — so the tap target stays comfortable. */
  .foxlink-sso-btn{ height:48px; font-size:15px; }
  .foxlink-sso-btn img{ width:22px; height:22px; }
}
@media (prefers-reduced-motion:reduce){
  .foxlink-sso-btn{ transition:none; }
  .foxlink-sso-spinner{ animation:none; }
}
