.iam-fab {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1800;
  background: #ffffff;
  border-radius: 12px 0 0 12px;
  box-shadow: -2px 2px 16px rgba(26,62,111,0.15);
  padding: 14px 14px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  border: none;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transition: box-shadow 0.3s;
}

.iam-fab:hover {
  box-shadow: -4px 4px 24px rgba(26,62,111,0.22);
}

.iam-fab-icon {
  width: 44px;
  height: 44px;
  position: relative;
}

.iam-fab-icon svg:first-child {
  position: absolute;
  top: 0;
  left: 10px;
  width: 24px;
  height: 24px;
}

.iam-fab-icon svg:last-child {
  position: absolute;
  bottom: 0;
  left: 4px;
  width: 36px;
  height: 24px;
}

.iam-fab span {
  font-size: 0.7rem;
  font-weight: 700;
  color: #1a2b3c;
  letter-spacing: 0.5px;
}

.iam-panel-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 1900;
  backdrop-filter: blur(3px);
}

.iam-panel-overlay.active { display: block; }

.iam-panel {
  position: fixed;
  right: -360px;
  top: 0;
  bottom: 0;
  width: 340px;
  max-width: 90vw;
  background: #ffffff;
  z-index: 2000;
  box-shadow: -4px 0 24px rgba(26,62,111,0.15);
  transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.iam-panel.active { right: 0; }

.iam-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 24px 20px;
  border-bottom: 1px solid #dce4ed;
}

.iam-panel-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1a2b3c;
}

.iam-panel-close {
  background: #f5f8fc;
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  color: #5a6d7e;
  transition: background 0.2s;
}

.iam-panel-close:hover { background: #dce4ed; color: #1a2b3c; }

.iam-roles {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.iam-role-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: #f5f8fc;
  border: 1.5px solid #dce4ed;
  border-radius: 10px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1a2b3c;
  transition: all 0.2s;
}

.iam-role-btn:hover {
  border-color: #1a3e6f;
  background: #e6eef7;
  color: #1a3e6f;
}

.iam-role-btn svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.iam-submenu {
  display: none;
  padding: 10px 24px 24px;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  overflow-y: auto;
}

.iam-submenu.active { display: flex; }

.iam-back {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: #1a3e6f;
  padding: 8px 0;
  margin-bottom: 8px;
}

.iam-back:hover { text-decoration: underline; }

.iam-submenu-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #5a6d7e;
  margin-bottom: 8px;
}

.iam-submenu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 0.92rem;
  font-weight: 500;
  color: #1a2b3c;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.iam-submenu a:hover {
  background: #e6eef7;
  color: #1a3e6f;
}

.iam-submenu a svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

@media (max-width: 768px) {
  .iam-fab { padding: 10px 10px; }
  .iam-fab-icon { width: 36px; height: 36px; }
  .iam-fab-icon svg:first-child { width: 20px; height: 20px; left: 8px; }
  .iam-fab-icon svg:last-child { width: 30px; height: 20px; left: 3px; }
  .iam-fab span { font-size: 0.6rem; }
}
