.fms-admin-login-actions { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.fms-admin-login-actions .admin-login-wrapper { width: auto; }
.fms-passkey-login-button { margin: 10px 0 10px auto; display: block; background: linear-gradient(135deg, #28c667 0%, #079f8c 52%, #087ab7 100%) !important; color: #fff !important; }
.fms-passkey-login-button:hover { background: linear-gradient(135deg, #39dc78 0%, #08bda5 52%, #0b91d6 100%) !important; }

.accounts .login-section-buttons {
    align-items: center;
    gap: 10px;
    justify-content: center;
}

.accounts .login-section-buttons .sign-in-btn,
.accounts .login-section-buttons .cancel-btn,
.accounts .login-section-buttons .fms-passkey-login-button {
    margin: 0;
}

.accounts .login-section-buttons > .clearfix {
    display: none;
}

.accounts .login-section-buttons .fms-passkey-login-button {
    border: 1px solid rgba(255, 255, 255, .68);
    border-radius: 10px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, .34), 0 0 24px rgba(47, 239, 178, .2), inset 0 1px 0 rgba(255, 255, 255, .25);
    filter: none;
    font-size: 20px;
    font-weight: 800;
    line-height: normal;
    min-width: min(100%, 330px);
    padding: 15px 22px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .4);
    transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.accounts .login-section-buttons .fms-passkey-login-button:hover,
.accounts .login-section-buttons .fms-passkey-login-button:focus-visible {
    box-shadow: 0 13px 34px rgba(0, 0, 0, .4), 0 0 30px rgba(47, 239, 178, .34), inset 0 1px 0 rgba(255, 255, 255, .3);
    transform: translateY(-2px);
}
.accounts .login-section-buttons .fms-passkey-login-button i {
    font-size: 24px;
    margin-right: 8px;
}
.fms-passkey-manager-button { flex: 0 0 auto; }
.fms-passkey-manager-button:hover,
.fms-passkey-manager-button:focus-visible { background: rgba(8, 17, 20, .98); }
.fms-passkey-login-control { display: inline-flex; }
.fms-passkey-login-control.is-disabled { cursor: not-allowed; }
.fms-passkey-login-control.is-disabled .fms-passkey-login-button {
    filter: grayscale(1);
    opacity: .55;
    cursor: not-allowed;
}
.fms-passkey-login-hero {
    align-items: center;
    display: none;
    gap: 14px;
    justify-content: center;
    margin: 2px auto 12px;
    max-width: 470px;
    text-align: left;
}
.fms-passkey-first-enabled:not(.is-password-mode) .fms-passkey-login-hero { display: flex; }
.fms-passkey-login-hero-icon {
    align-items: center;
    background: linear-gradient(145deg, rgba(48, 222, 123, .28), rgba(3, 121, 181, .3));
    border: 1px solid rgba(123, 255, 197, .68);
    border-radius: 50%;
    box-shadow: 0 0 22px rgba(70, 239, 168, .25);
    color: #7bffc5;
    display: inline-flex;
    flex: 0 0 58px;
    font-size: 30px;
    height: 58px;
    justify-content: center;
}
.fms-passkey-login-hero-copy { color: #fff; display: flex; flex-direction: column; line-height: 1.25; }
.fms-passkey-login-hero-copy strong { font-size: 21px; font-weight: 800; }
.fms-passkey-login-hero-copy small { color: rgba(255, 255, 255, .82); font-size: 14px; margin-top: 3px; }
.fms-password-login-toggle {
    align-items: center;
    background: #26343b;
    border: 1px solid #4b5d65;
    border-radius: 10px;
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    font-size: 15px;
    font-weight: 700;
    gap: 7px;
    justify-content: center;
    line-height: 1.2;
    margin: 10px 0;
    padding: 10px 12px;
}
.fms-password-login-toggle:hover,
.fms-password-login-toggle:focus-visible {
    background: #354a54;
    border-color: #6d8792;
}
.fms-passkey-first-enabled:not(.is-password-mode) .login-input-wrapper,
.fms-passkey-first-enabled:not(.is-password-mode) #admin-login-remember-me-wrapper,
.fms-passkey-first-enabled:not(.is-password-mode) .fms-admin-login-actions .admin-login-wrapper,
.fms-passkey-first-enabled:not(.is-password-mode) .login-section-inputs,
.fms-passkey-first-enabled:not(.is-password-mode) .login-section-buttons .sign-in-btn,
.fms-passkey-first-enabled:not(.is-password-mode) .login-section-buttons .cancel-btn {
    display: none !important;
}
.fms-passkey-first-enabled.is-password-mode .fms-passkey-login-control {
    display: none;
}
.fms-passkey-first-enabled:not(.is-password-mode) .fms-admin-login-actions,
.fms-passkey-first-enabled:not(.is-password-mode) .login-section-buttons {
    justify-content: center;
}
.accounts .fms-passkey-first-enabled:not(.is-password-mode) .login-section-buttons {
    flex-direction: column;
    padding: 15px 12px 12px;
}
.fms-passkey-first-time-help {
    align-items: flex-start;
    background: rgba(7, 18, 28, .42);
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 9px;
    color: rgba(255, 255, 255, .84);
    display: none;
    font-size: 13px;
    gap: 8px;
    line-height: 1.35;
    margin: 7px auto 0;
    max-width: 430px;
    padding: 9px 11px;
    text-align: left;
}
.fms-passkey-first-enabled:not(.is-password-mode) .fms-passkey-first-time-help { display: flex; }
.fms-passkey-first-time-help i { color: #80eec5; margin-top: 2px; }
.fms-passkey-first-time-help strong { color: #fff; }
.accounts .fms-password-login-toggle {
    background: linear-gradient(135deg, rgba(25, 39, 58, .82), rgba(41, 55, 78, .8));
    border: 1px solid rgba(255, 255, 255, .38);
    border-radius: 10px;
    box-shadow: 0 5px 14px rgba(0, 0, 0, .28), inset 0 1px 0 rgba(255, 255, 255, .1);
    color: rgba(255, 255, 255, .94);
    filter: none;
    font-size: 14px;
    font-weight: 750;
    gap: 8px;
    margin: 7px 0 2px;
    padding: 10px 14px;
    text-decoration: none;
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.accounts .fms-password-login-toggle i {
    color: #b9d5ff;
    font-size: 16px;
}
.accounts .fms-password-login-toggle:hover,
.accounts .fms-password-login-toggle:focus-visible {
    background: linear-gradient(135deg, rgba(42, 63, 91, .94), rgba(50, 73, 104, .92));
    border-color: rgba(185, 213, 255, .72);
    box-shadow: 0 7px 18px rgba(0, 0, 0, .34), 0 0 16px rgba(83, 155, 255, .14), inset 0 1px 0 rgba(255, 255, 255, .14);
    color: #fff;
    transform: translateY(-1px);
}
.accounts .fms-passkey-first-enabled.is-password-mode .fms-password-login-toggle {
    background: linear-gradient(135deg, rgba(18, 152, 108, .92), rgba(8, 105, 154, .94));
    border: 1px solid rgba(128, 255, 205, .72);
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .34), 0 0 14px rgba(47, 239, 178, .16);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    margin: 0;
    padding: 10px 12px;
    text-decoration: none;
    white-space: nowrap;
}
.accounts .fms-passkey-first-enabled.is-password-mode .fms-password-login-toggle:hover,
.accounts .fms-passkey-first-enabled.is-password-mode .fms-password-login-toggle:focus-visible {
    background: linear-gradient(135deg, #18b978, #087fba);
    border-color: #a2ffdc;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .4), 0 0 18px rgba(47, 239, 178, .28);
    transform: translateY(-1px);
}
.sign-in-header .sign-in-title,
.sign-in-header .sign-in-subtitle {
    display: block;
    flex: 0 0 100%;
    width: 100%;
}
.account-passkey-shortcut {
    color: #69ef63;
    font-size: 38px;
    line-height: 1;
    opacity: .82;
    filter: drop-shadow(0 3px 5px rgba(0, 0, 0, .55));
}
.account-passkey-shortcut i {
    display: flex;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    transform: none;
}
.account-passkey-shortcut:hover,
.account-passkey-shortcut:focus {
    color: #8dff82;
    opacity: 1;
    outline: none;
}
.fms-passkey-modal {
    position: fixed;
    inset: 0;
    z-index: 11000;
    display: none;
    place-items: center;
    box-sizing: border-box;
    padding: 20px;
    background: rgba(0, 0, 0, .82);
    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
    align-items: flex-start;
    overflow-y: auto;
    overscroll-behavior: contain;
}
.fms-passkey-modal.is-open { display: grid; }
.fms-passkey-modal .fms-passkey-panel {
    position: relative;
    box-sizing: border-box;
    width: min(780px, 100%);
    max-height: none;
    margin: auto 0;
    overflow: visible;
    padding: 22px;
    border: 2px solid #31bd38 !important;
    border-radius: 18px !important;
    background: linear-gradient(145deg, rgba(16, 30, 24, .98), rgba(5, 12, 14, .98)) !important;
    box-shadow: 0 18px 55px rgba(0, 0, 0, .72), 0 0 0 5px rgba(49, 189, 56, .12) !important;
    color: #fff;
    text-align: left;
}
.fms-passkey-modal .fms-passkey-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 42px;
    height: 42px;
    padding: 0 !important;
    border: 1px solid rgba(255, 255, 255, .25) !important;
    border-radius: 10px !important;
    background: linear-gradient(#df2533, #a30e19) !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .4) !important;
    color: #fff !important;
    font-size: 26px;
    font-weight: 800;
    line-height: 1;
}
.fms-passkey-modal .fms-passkey-close:hover { background: linear-gradient(#ef3643, #bd1421) !important; }
.fms-passkey-panel h2 { margin: 0 48px 6px 0; }
.fms-passkey-modal .fms-passkey-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px; margin: 10px 0; border: 1px solid #385048; border-radius: 10px; background: rgba(2, 10, 10, .72); }
.fms-passkey-item small { display: block; margin-top: 4px; color: #c7d0d3; }
.fms-passkey-help { margin: 12px 0 0; color: #d7dfe2; }
.fms-passkey-modal .fms-passkey-empty { margin: 10px 0; padding: 12px; color: #d7dfe2; border: 1px solid #385048; border-radius: 10px; background: rgba(2, 10, 10, .62); }
.fms-passkey-modal button.green-button,
.fms-passkey-modal #fms-passkey-add {
    min-height: 42px;
    padding: 9px 14px !important;
    border: 1px solid rgba(255, 255, 255, .22) !important;
    border-radius: 10px !important;
    background: linear-gradient(#24bd42, #087b25) !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .38) !important;
    color: #fff !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    text-transform: uppercase;
    cursor: pointer;
    transition: filter .16s ease, transform .16s ease, box-shadow .16s ease;
}
.fms-passkey-modal button.green-button:hover,
.fms-passkey-modal #fms-passkey-add:hover {
    background: linear-gradient(#36d653, #0b9430) !important;
    filter: brightness(1.08);
    transform: translateY(-1px);
}
.fms-passkey-modal button.red-button,
.fms-passkey-modal #fms-session-remove-all {
    min-height: 42px;
    padding: 9px 14px !important;
    border: 1px solid rgba(255, 255, 255, .22) !important;
    border-radius: 10px !important;
    background: linear-gradient(#d62936, #94101a) !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .38) !important;
    color: #fff !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    text-transform: uppercase;
    cursor: pointer;
    transition: filter .16s ease, transform .16s ease, box-shadow .16s ease;
}
.fms-passkey-modal button.red-button:hover,
.fms-passkey-modal #fms-session-remove-all:hover {
    background: linear-gradient(#eb3a47, #ad1521) !important;
    filter: brightness(1.08);
    transform: translateY(-1px);
}
.fms-passkey-modal button:disabled {
    cursor: not-allowed !important;
    filter: grayscale(.7);
    opacity: .58;
    transform: none !important;
}
.fms-passkey-modal #fms-passkey-add { margin-top: 10px; }
.fms-passkey-modal #fms-passkey-add,
.fms-passkey-modal #fms-session-remove-all { margin-bottom: 10px; }
.fms-passkey-modal .fms-security-manager-section { margin-top: 14px; padding: 14px; border: 1px solid #385048; border-radius: 12px; background: rgba(6, 18, 17, .82); }
.fms-security-manager-section h3 { margin: 0 0 4px; }
.fms-security-manager-section > p { margin: 0 0 10px; }
.fms-current-session { display: inline-block; margin-left: 6px; padding: 3px 6px; border-radius: 5px; background: #148b35; color: #fff; font-size: .72rem; vertical-align: middle; }

/* The public studios site shares the security workflow with FMS but uses the
   brighter GRS purple/green visual language. */
body[data-fms-passkey-account="public"] .fms-passkey-modal {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    align-items: flex-start;
    overflow-y: auto;
    overscroll-behavior: contain;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-close {
    top: 18px;
    right: 30px;
}
body.fms-passkey-modal-open {
    overflow: hidden !important;
}
body.fms-passkey-modal-open .swal2-container {
    z-index: 12000 !important;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-panel {
    width: min(680px, 100%);
    max-height: none;
    margin: auto 0;
    padding: 30px;
    border: 7px solid #2dcc39 !important;
    border-radius: 46px !important;
    background: #f5f5fb !important;
    box-shadow:
        0 18px 48px rgba(15, 0, 28, .48),
        0 4px 0 rgba(0, 0, 0, .2) !important;
    color: #555 !important;
    overflow: visible;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-panel > h2 {
    margin: 0 48px 16px;
    color: #555;
    text-align: center;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-security-manager-section {
    border-color: #d2d2dc;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(42, 35, 55, .09);
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-item,
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-empty {
    border-color: #d3d3dd;
    background: #f1f1f6;
    color: #555;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-item small,
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-help {
    color: #666;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal button.green-button,
body[data-fms-passkey-account="public"] .fms-passkey-modal #fms-passkey-add {
    background: linear-gradient(#55e94f, #10a839) !important;
    box-shadow: 0 5px 12px rgba(4, 45, 11, .45), 0 0 12px rgba(90, 255, 77, .22) !important;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal button.green-button:hover,
body[data-fms-passkey-account="public"] .fms-passkey-modal #fms-passkey-add:hover {
    background: linear-gradient(#71ff69, #16c647) !important;
}
body[data-fms-passkey-account="public"] .fms-current-session {
    background: linear-gradient(#54e64d, #13983a);
    box-shadow: 0 2px 7px rgba(0, 0, 0, .3);
}
body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-close {
    background: linear-gradient(#ff4654, #bf1220) !important;
}
body[data-fms-passkey-account="public"] .fms-passkey-modal button.red-button,
body[data-fms-passkey-account="public"] .fms-passkey-modal #fms-session-remove-all {
    background: linear-gradient(#f33d4b, #ad101c) !important;
}
@media (max-width: 900px) {
    .fms-passkey-login-hero { gap: 10px; text-align: center; }
    .fms-passkey-login-hero-icon { flex-basis: 50px; font-size: 25px; height: 50px; }
    .fms-passkey-login-hero-copy strong { font-size: 18px; }
    .fms-passkey-login-hero-copy small { font-size: 13px; }
    .accounts .login-section-buttons .fms-passkey-login-button { font-size: 17px; min-width: 0; width: 100%; }
    .fms-passkey-manager-button {
        flex: 0 0 44px;
        height: 44px;
        justify-content: center;
        padding: 0;
        width: 44px;
    }
    .fms-passkey-item { align-items: flex-start; flex-direction: column; }
    .fms-admin-login-actions { flex-wrap: wrap; }
    .fms-passkey-login-button { margin-left: 0; }
    .fms-passkey-modal { padding: 10px; }
    .fms-passkey-modal .fms-passkey-panel { max-height: none; overflow: visible; padding: 16px; border-radius: 14px !important; }
    body[data-fms-passkey-account="public"] .fms-passkey-modal .fms-passkey-panel {
        padding: 22px 16px;
        border-width: 5px !important;
        border-radius: 30px !important;
    }
}
